[Feature] allow user to change label name
Regarding to this issue. How about add a possibility to just custom the existing label ? maybe using an optional @Input() ?
You can replace buttons. I guess it's enough )
For i18n, it would be much easier if we could globally inject the "OK" and "CANCEL" translations, maybe along with theme? What do you think?
Okey, I'll add it in the next release
@mstawick have you been able to add multilanguage?? how do you bind it with the existing label?
@YurvaneeshDassagne Sorry, I'm on vacation now far away from my code :) and can't remember what I ended up doing. I can check when I'm back in around a week.
@mstawick ok...thanks
@Agranom Do you have any idea about how to bind multilanguage labels?
@YurvaneeshDassagne You can provide custom buttons. Which i18n lib do you use ?
@YurvaneeshDassagne FYI, I've defined templates like so:
<ng-template #okButton>
<button mat-button color="primary" i18n>Save</button>
</ng-template>
<ng-template #cancelButton>
<button mat-button color="primary" i18n>Cancel</button>
</ng-template>
And then referenced them like so:
<ngx-material-timepicker #timePicker
[confirmBtnTmpl]="okButton"
[cancelBtnTmpl]="cancelButton"
.....></ngx-material-timepicker>
Thank you a lot :-)
On Tue, Sep 1, 2020 at 3:16 PM Michał Stawicki [email protected] wrote:
@YurvaneeshDassagne https://github.com/YurvaneeshDassagne FYI, I've defined templates like so:
<ng-template #okButton> <ng-template #cancelButton>
And then referenced them like so:
<ngx-material-timepicker #timePicker [confirmBtnTmpl]="okButton" [cancelBtnTmpl]="cancelButton" .....></ngx-material-timepicker>— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/Agranom/ngx-material-timepicker/issues/223#issuecomment-684776995, or unsubscribe https://github.com/notifications/unsubscribe-auth/AHOUEWXU6KSXG3SYQW5ND6DSDTJXDANCNFSM4IZJN6AA .