From 4b397cfe42ec193285550e4f0106744613c27c88 Mon Sep 17 00:00:00 2001 From: splincode Date: Tue, 13 Aug 2024 13:22:08 +0300 Subject: [PATCH] fix(i18n): redundant whitespace --- projects/i18n/languages/english/kit.ts | 2 +- projects/i18n/languages/german/kit.ts | 2 +- projects/i18n/languages/polish/kit.ts | 2 +- projects/i18n/languages/portuguese/kit.ts | 2 +- projects/i18n/languages/russian/kit.ts | 2 +- projects/i18n/languages/turkish/kit.ts | 2 +- projects/i18n/languages/ukrainian/kit.ts | 2 +- projects/i18n/languages/vietnamese/kit.ts | 2 +- .../input-files/max-size-rejection-error.pipe.ts | 7 +++++-- 9 files changed, 13 insertions(+), 10 deletions(-) diff --git a/projects/i18n/languages/english/kit.ts b/projects/i18n/languages/english/kit.ts index d62970d8ebb0e..e84800e849354 100644 --- a/projects/i18n/languages/english/kit.ts +++ b/projects/i18n/languages/english/kit.ts @@ -48,7 +48,7 @@ export const TUI_ENGLISH_LANGUAGE_KIT: TuiLanguageKit = { defaultLabelMultiple: 'or drop\u00A0them\u00A0here', defaultLinkSingle: 'Choose a file', defaultLinkMultiple: 'Choose files', - maxSizeRejectionReason: 'File is larger than ', + maxSizeRejectionReason: 'File is larger than', formatRejectionReason: 'Wrong file type', drop: 'Drop file here', dropMultiple: 'Drop files here', diff --git a/projects/i18n/languages/german/kit.ts b/projects/i18n/languages/german/kit.ts index 2b177933c7761..00bb2496fbb48 100644 --- a/projects/i18n/languages/german/kit.ts +++ b/projects/i18n/languages/german/kit.ts @@ -49,7 +49,7 @@ export const TUI_GERMAN_LANGUAGE_KIT: TuiLanguageKit = { defaultLinkSingle: 'Datei auswählen', defaultLinkMultiple: 'Dateien auswählen', maxSizeRejectionReason: - 'Die Dateigröße überschreitet die maximal zulässige Größe von ', + 'Die Dateigröße überschreitet die maximal zulässige Größe von', formatRejectionReason: 'Ungültiges Dateiformat', drop: 'Datei hier ablegen', dropMultiple: 'Dateien hier ablegen', diff --git a/projects/i18n/languages/polish/kit.ts b/projects/i18n/languages/polish/kit.ts index 253b3224f305d..bb72adb0f0bee 100644 --- a/projects/i18n/languages/polish/kit.ts +++ b/projects/i18n/languages/polish/kit.ts @@ -48,7 +48,7 @@ export const TUI_POLISH_LANGUAGE_KIT: TuiLanguageKit = { defaultLabelMultiple: 'lub przeciągnij\u00A0tutaj', defaultLinkSingle: 'Wybierz plik', defaultLinkMultiple: 'Wybierz pliki', - maxSizeRejectionReason: 'Plik przekracza rozmiar ', + maxSizeRejectionReason: 'Plik przekracza rozmiar', formatRejectionReason: 'Nieprawidłowy format pliku', drop: 'Przeciągnij plik tutaj', dropMultiple: 'Przeciągnij pliki tutaj', diff --git a/projects/i18n/languages/portuguese/kit.ts b/projects/i18n/languages/portuguese/kit.ts index 86df62592b459..420804296d1af 100644 --- a/projects/i18n/languages/portuguese/kit.ts +++ b/projects/i18n/languages/portuguese/kit.ts @@ -48,7 +48,7 @@ export const TUI_PORTUGUESE_LANGUAGE_KIT: TuiLanguageKit = { defaultLabelMultiple: 'ou arraste\u00A0eles\u00A0aqui', defaultLinkSingle: 'Escolha um arquivo', defaultLinkMultiple: 'Escolha os arquivos', - maxSizeRejectionReason: 'Arquivo ultrapassa o tamanho ', + maxSizeRejectionReason: 'Arquivo ultrapassa o tamanho', formatRejectionReason: 'Formato do arquivo inválido', drop: 'Solte o arquivo aqui', dropMultiple: 'Solte os arquivos aqui', diff --git a/projects/i18n/languages/russian/kit.ts b/projects/i18n/languages/russian/kit.ts index 93705cc01477d..0b0b9c825c5c6 100644 --- a/projects/i18n/languages/russian/kit.ts +++ b/projects/i18n/languages/russian/kit.ts @@ -48,7 +48,7 @@ export const TUI_RUSSIAN_LANGUAGE_KIT: TuiLanguageKit = { defaultLabelMultiple: 'или перетащите\u00A0их\u00A0сюда', defaultLinkSingle: 'Выберите файл', defaultLinkMultiple: 'Выберите файлы', - maxSizeRejectionReason: 'Файл превышает объем ', + maxSizeRejectionReason: 'Файл превышает объем', formatRejectionReason: 'Неверный формат файла', drop: 'Поместите файл сюда', dropMultiple: 'Поместите файлы сюда', diff --git a/projects/i18n/languages/turkish/kit.ts b/projects/i18n/languages/turkish/kit.ts index b1bf218d72031..628679a08091a 100644 --- a/projects/i18n/languages/turkish/kit.ts +++ b/projects/i18n/languages/turkish/kit.ts @@ -48,7 +48,7 @@ export const TUI_TURKISH_LANGUAGE_KIT: TuiLanguageKit = { defaultLabelMultiple: 'veya\u00A0buraya\u00A0sürükleyin', defaultLinkSingle: 'Dosya seç', defaultLinkMultiple: 'Dosyaları seç', - maxSizeRejectionReason: 'Dosya boyutu fazla ', + maxSizeRejectionReason: 'Dosya boyutu fazla', formatRejectionReason: 'Dosya formatı yanlış', drop: 'Dosyayı buraya bırakın', dropMultiple: 'Dosyaları buraya bırakın', diff --git a/projects/i18n/languages/ukrainian/kit.ts b/projects/i18n/languages/ukrainian/kit.ts index e88132e449595..ef495f8ec4fe3 100644 --- a/projects/i18n/languages/ukrainian/kit.ts +++ b/projects/i18n/languages/ukrainian/kit.ts @@ -48,7 +48,7 @@ export const TUI_UKRAINIAN_LANGUAGE_KIT: TuiLanguageKit = { defaultLabelMultiple: 'та перенесіть\u00A0їx\u00A0сюди', defaultLinkSingle: 'Виберіть файл', defaultLinkMultiple: 'Виберіть файли', - maxSizeRejectionReason: 'Файл перевищує розмір ', + maxSizeRejectionReason: 'Файл перевищує розмір', formatRejectionReason: 'Невірний формат файлу', drop: 'Помістіть файл сюди', dropMultiple: 'Помістіть файли сюди', diff --git a/projects/i18n/languages/vietnamese/kit.ts b/projects/i18n/languages/vietnamese/kit.ts index d5b9fe4d0b976..dc30b72ad54ed 100644 --- a/projects/i18n/languages/vietnamese/kit.ts +++ b/projects/i18n/languages/vietnamese/kit.ts @@ -48,7 +48,7 @@ export const TUI_VIETNAMESE_LANGUAGE_KIT: TuiLanguageKit = { defaultLabelMultiple: 'hoặc kéo nó vào đây', defaultLinkSingle: 'Chọn một tệp', defaultLinkMultiple: 'Chọn nhiều tệp', - maxSizeRejectionReason: 'Tệp vượt quá kích thước ', + maxSizeRejectionReason: 'Tệp vượt quá kích thước', formatRejectionReason: 'Tệp sai định dạng', drop: 'Thả tệp tại đây', dropMultiple: 'Thả nhiều tệp tại đây', diff --git a/projects/kit/components/input-files/max-size-rejection-error.pipe.ts b/projects/kit/components/input-files/max-size-rejection-error.pipe.ts index e57dce72b9f01..d80fbb31562df 100644 --- a/projects/kit/components/input-files/max-size-rejection-error.pipe.ts +++ b/projects/kit/components/input-files/max-size-rejection-error.pipe.ts @@ -1,5 +1,5 @@ import {Inject, Pipe, PipeTransform} from '@angular/core'; -import {TuiInjectionTokenType} from '@taiga-ui/cdk'; +import {CHAR_NO_BREAK_SPACE, TuiInjectionTokenType} from '@taiga-ui/cdk'; import {TUI_DIGITAL_INFORMATION_UNITS, TUI_INPUT_FILE_TEXTS} from '@taiga-ui/kit/tokens'; import {tuiFormatSize} from '@taiga-ui/kit/utils'; import {combineLatest, Observable} from 'rxjs'; @@ -22,7 +22,10 @@ export class TuiMaxSizeRejectionErrorPipe implements PipeTransform { return combineLatest([this.inputFileTexts$, this.units$]).pipe( map( ([{maxSizeRejectionReason}, units]) => - `${maxSizeRejectionReason}${tuiFormatSize(units, maxFileSize)}`, + `${maxSizeRejectionReason}${CHAR_NO_BREAK_SPACE}${tuiFormatSize( + units, + maxFileSize, + )}`, ), ); }