-
Notifications
You must be signed in to change notification settings - Fork 471
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(i18n): finish i18n for packages (#126)
* feat(i18n): add i18n package * feat(i18n): add russian language * chore(ci): update CI with i18n * feat(cdk, core): `TuiMonthPipe` move from cdk to core, add i18n BREAKING CHANGE: import it from @taiga-ui/core library and use with async pipe * chore(all): add i18n * chore(tests): fix them all * chore(kit): fix calendars i18n * chore(demo): add i18n page * chore(i18n): bump version after merge main * chore(i18n): fix use before declaration error * chore(kit): fix build error * chore(all): fix comments * chore(kit): fix async issue * chore(kit): fix typing issue
- Loading branch information
Showing
155 changed files
with
1,490 additions
and
506 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -23,4 +23,4 @@ | |
"devDependencies": { | ||
"@taiga-ui/core": "2.1.3" | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,10 @@ | ||
import {InjectionToken} from '@angular/core'; | ||
import {extractI18n} from '@taiga-ui/i18n'; | ||
|
||
export const TUI_CARD_NUMBER_TEXTS = new InjectionToken<[string, string]>( | ||
`Number and card number i18n`, | ||
{ | ||
factory: () => ['Number', 'Card number'], | ||
}, | ||
); | ||
export const TUI_CARD_NUMBER_TEXTS = new InjectionToken(`Number and card number i18n`, { | ||
factory: extractI18n('cardNumber'), | ||
}); | ||
|
||
export const TUI_CARD_EXPIRY_TEXTS = new InjectionToken<[string, string]>( | ||
`Expiry and card expiry i18n`, | ||
{ | ||
factory: () => ['Expiry', 'Card expiry'], | ||
}, | ||
); | ||
export const TUI_CARD_EXPIRY_TEXTS = new InjectionToken(`Expiry and card expiry i18n`, { | ||
factory: extractI18n('cardExpiry'), | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,6 +10,6 @@ | |
<span class="initial"> | ||
<ng-content></ng-content> | ||
</span> | ||
{{texts[1]}} | ||
{{copiedMessage}} | ||
</span> | ||
</button> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
import {Provider} from '@angular/core'; | ||
import { | ||
TUI_DOC_DEMO_TEXTS, | ||
TUI_DOC_DOCUMENTATION_TEXTS, | ||
TUI_DOC_EXAMPLE_TEXTS, | ||
TUI_DOC_MENU_TEXT, | ||
TUI_DOC_SEARCH_TEXT, | ||
TUI_DOC_SEE_ALSO_TEXT, | ||
TUI_DOC_SOURCE_CODE_TEXT, | ||
} from '../tokens/i18n'; | ||
|
||
export const TUI_DOC_RUSSIAN: Provider[] = [ | ||
{ | ||
provide: TUI_DOC_DEMO_TEXTS, | ||
useValue: ['Сделано с помощью директивы: ', 'Фон', 'Детали формы'], | ||
}, | ||
{ | ||
provide: TUI_DOC_DOCUMENTATION_TEXTS, | ||
useValue: [ | ||
'Аргумент', | ||
'Тип', | ||
'Имя и описание', | ||
'Значение', | ||
'Для работы с динамическими шаблонами используется', | ||
], | ||
}, | ||
{ | ||
provide: TUI_DOC_EXAMPLE_TEXTS, | ||
useValue: ['Превью', 'Ссылка на пример скопирована', 'Готово'], | ||
}, | ||
{ | ||
provide: TUI_DOC_MENU_TEXT, | ||
useValue: 'Меню', | ||
}, | ||
{ | ||
provide: TUI_DOC_SEARCH_TEXT, | ||
useValue: 'Поиск', | ||
}, | ||
{ | ||
provide: TUI_DOC_SEE_ALSO_TEXT, | ||
useValue: 'Смотрите также', | ||
}, | ||
{ | ||
provide: TUI_DOC_SOURCE_CODE_TEXT, | ||
useValue: 'Исходный код', | ||
}, | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.