Skip to content

Commit 182426d

Browse files
fix: Missing internationalization for toggle wrapper (#1946)
1 parent 2b10169 commit 182426d

File tree

23 files changed

+68
-2
lines changed

23 files changed

+68
-2
lines changed

packages/core/src/blocks/ToggleWrapper/createToggleWrapper.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,8 @@ export const createToggleWrapper = (
7777
const toggleAddBlockButton = document.createElement("button");
7878
toggleAddBlockButton.className = "bn-toggle-add-block-button";
7979
toggleAddBlockButton.type = "button";
80-
toggleAddBlockButton.textContent = "Empty toggle. Click to add a block.";
80+
toggleAddBlockButton.textContent =
81+
editor.dictionary.toggle_blocks.add_block_button;
8182
const toggleAddBlockButtonMouseDown = (event: MouseEvent) =>
8283
event.preventDefault();
8384
toggleAddBlockButton.addEventListener(

packages/core/src/i18n/locales/ar.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,9 @@ export const ar: Dictionary = {
182182
add_button_text: "إضافة ملف",
183183
},
184184
},
185+
toggle_blocks: {
186+
add_block_button: "تبديل فارغ. انقر لإضافة كتلة.",
187+
},
185188
// from react package:
186189
side_menu: {
187190
add_block_label: "إضافة محتوي",

packages/core/src/i18n/locales/de.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -217,6 +217,10 @@ export const de: Dictionary = {
217217
add_button_text: "Datei hinzufügen",
218218
},
219219
},
220+
toggle_blocks: {
221+
add_block_button:
222+
"Leerer aufklappbarer Bereich. Klicken, um einen Block hinzuzufügen.",
223+
},
220224
side_menu: {
221225
add_block_label: "Block hinzufügen",
222226
drag_handle_label: "Blockmenü öffnen",

packages/core/src/i18n/locales/en.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -197,6 +197,9 @@ export const en = {
197197
add_button_text: "Add file",
198198
},
199199
},
200+
toggle_blocks: {
201+
add_block_button: "Empty toggle. Click to add a block.",
202+
},
200203
// from react package:
201204
side_menu: {
202205
add_block_label: "Add block",

packages/core/src/i18n/locales/es.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -197,6 +197,9 @@ export const es: Dictionary = {
197197
add_button_text: "Agregar archivo",
198198
},
199199
},
200+
toggle_blocks: {
201+
add_block_button: "Toggle vacío. Haz clic para añadir un bloque.",
202+
},
200203
side_menu: {
201204
add_block_label: "Agregar bloque",
202205
drag_handle_label: "Abrir menú de bloque",

packages/core/src/i18n/locales/fr.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -243,6 +243,9 @@ export const fr: Dictionary = {
243243
add_button_text: "Ajouter un fichier",
244244
},
245245
},
246+
toggle_blocks: {
247+
add_block_button: "Toggle vide. Cliquez pour ajouter un bloc.",
248+
},
246249
// from react package:
247250
side_menu: {
248251
add_block_label: "Ajouter un bloc",

packages/core/src/i18n/locales/he.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -199,6 +199,9 @@ export const he: Dictionary = {
199199
add_button_text: "הוסף קובץ",
200200
},
201201
},
202+
toggle_blocks: {
203+
add_block_button: "מתג ריק. לחץ כדי להוסיף בלוק.",
204+
},
202205
side_menu: {
203206
add_block_label: "הוסף בלוק",
204207
drag_handle_label: "פתח תפריט בלוק",

packages/core/src/i18n/locales/hr.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -210,6 +210,9 @@ export const hr: Dictionary = {
210210
add_button_text: "Dodaj datoteku",
211211
},
212212
},
213+
toggle_blocks: {
214+
add_block_button: "Prazan sklopivi blok. Klikni da dodaš sadržaj.",
215+
},
213216
// from react package:
214217
side_menu: {
215218
add_block_label: "Dodaj blok",

packages/core/src/i18n/locales/is.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -211,6 +211,9 @@ export const is: Dictionary = {
211211
add_button_text: "Bæta við skrá",
212212
},
213213
},
214+
toggle_blocks: {
215+
add_block_button: "Tóm fellilína. Smelltu til að bæta við blokk.",
216+
},
214217
side_menu: {
215218
add_block_label: "Bæta við blokki",
216219
drag_handle_label: "Opna blokkarvalmynd",

packages/core/src/i18n/locales/it.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -219,6 +219,9 @@ export const it: Dictionary = {
219219
add_button_text: "Aggiungi file",
220220
},
221221
},
222+
toggle_blocks: {
223+
add_block_button: "Toggle vuoto. Clicca per aggiungere un blocco.",
224+
},
222225
// from react package:
223226
side_menu: {
224227
add_block_label: "Aggiungi blocco",

0 commit comments

Comments
 (0)