Liquid-JS / nxt-components

https://liquid-js.github.io/nxt-components/
MIT License
16 stars 2 forks source link

Localize "Set" and "Cancel" in Datetime Picker #5

Open ontec-xrail opened 2 weeks ago

ontec-xrail commented 2 weeks ago

Hi,

probably a stupid question but how can I localize the two strings "Set" and "Cancel"

I couldn't find a example in the documentation? Could you help me out?

image

Thanks Max

HitkoDev commented 1 week ago

The components use @angular/localize.

If you run ng extract-i18n, you'll see nxt-pick-datetime.cancel and nxt-pick-datetime.set in your output file, and you can change these values just like any other localised string. If you don't wish to use @angular/localize, you can also override the DateTimeIntl service to provide localised values.