Git Product home page Git Product logo

Comments (7)

madc avatar madc commented on August 23, 2024

This should be doable using bolt-labels. Have you tried that?

from translate.

Puddingboy avatar Puddingboy commented on August 23, 2024

bolt-labels is not really suitable for full sentences. I have my own snippet contenttype I use. Rather I wish errors had an error code so that I could fetch the proper translation to these messages based upon the errorcode.

from translate.

SahAssar avatar SahAssar commented on August 23, 2024

I think that labels is what you need to use for this. Translate will only handle content, not static text in configs/templates, that is what we use labels for.

Try changing https://github.com/bolt/boltforms/blob/d868af7f6286938f9554259045fa9e61cb351db1/templates/form/_form_theme.twig#L7 to {{ l(error.message) }} and then translating in labels.

from translate.

Puddingboy avatar Puddingboy commented on August 23, 2024

This sure helps. Do you know if there is some kind of overview going about with a list of possible error messages for form and fields?

from translate.

SahAssar avatar SahAssar commented on August 23, 2024

Sorry, no idea... I think you can set what errors to show in boltforms though, using the message key on each of the fields, and besides those it should just be the ones that you can set in the boltforms config.

from translate.

Puddingboy avatar Puddingboy commented on August 23, 2024

Thx anyways, I will root around some more

from translate.

madc avatar madc commented on August 23, 2024

Closing this, as it is solved and not directly related with bolt-translate.

from translate.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.