@docx-editor.dev/i18n 0.0.1 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +201 -0
- package/README.md +130 -2
- package/THIRD_PARTY_NOTICES.md +18 -0
- package/dist/de.d.mts +33 -0
- package/dist/de.d.ts +33 -0
- package/dist/de.js +1194 -0
- package/dist/de.mjs +1167 -0
- package/dist/en.d.mts +33 -0
- package/dist/en.d.ts +33 -0
- package/dist/en.js +1194 -0
- package/dist/en.mjs +1167 -0
- package/dist/fr.d.mts +33 -0
- package/dist/fr.d.ts +33 -0
- package/dist/fr.js +1194 -0
- package/dist/fr.mjs +1167 -0
- package/dist/he.d.mts +33 -0
- package/dist/he.d.ts +33 -0
- package/dist/he.js +1194 -0
- package/dist/he.mjs +1167 -0
- package/dist/hi.d.mts +33 -0
- package/dist/hi.d.ts +33 -0
- package/dist/hi.js +1194 -0
- package/dist/hi.mjs +1167 -0
- package/dist/id.d.mts +33 -0
- package/dist/id.d.ts +33 -0
- package/dist/id.js +1194 -0
- package/dist/id.mjs +1167 -0
- package/dist/index.d.mts +1396 -0
- package/dist/index.d.ts +1396 -0
- package/dist/index.js +11748 -0
- package/dist/index.mjs +11709 -0
- package/dist/pl.d.mts +33 -0
- package/dist/pl.d.ts +33 -0
- package/dist/pl.js +1194 -0
- package/dist/pl.mjs +1167 -0
- package/dist/pt-BR.d.mts +33 -0
- package/dist/pt-BR.d.ts +33 -0
- package/dist/pt-BR.js +1194 -0
- package/dist/pt-BR.mjs +1167 -0
- package/dist/tr.d.mts +33 -0
- package/dist/tr.d.ts +33 -0
- package/dist/tr.js +1194 -0
- package/dist/tr.mjs +1167 -0
- package/dist/zh-CN.d.mts +33 -0
- package/dist/zh-CN.d.ts +33 -0
- package/dist/zh-CN.js +1194 -0
- package/dist/zh-CN.mjs +1167 -0
- package/package.json +93 -5
- package/index.js +0 -1
package/dist/index.d.mts
ADDED
|
@@ -0,0 +1,1396 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Shared locale data, types, and runtime helpers for the @docx-editor.dev
|
|
3
|
+
* editor adapters.
|
|
4
|
+
*
|
|
5
|
+
* Import everything from the package root. `sideEffects: false` lets
|
|
6
|
+
* consumer bundlers tree-shake unused locales.
|
|
7
|
+
*
|
|
8
|
+
* ```ts
|
|
9
|
+
* import {
|
|
10
|
+
* en, de, pl, tr, he, ptBR, zhCN, // typed locale data
|
|
11
|
+
* locales, // record keyed by BCP-47 tag
|
|
12
|
+
* deepMerge, createT, // build a t() for custom hosts
|
|
13
|
+
* type LocaleStrings, // shape of `en` (source of truth)
|
|
14
|
+
* type Translations, // shape of a community partial
|
|
15
|
+
* type TranslationKey, // every valid `t()` key
|
|
16
|
+
* type LocaleCode, // 'en' | 'de' | 'pt-BR' | ...
|
|
17
|
+
* } from '@docx-editor.dev/i18n';
|
|
18
|
+
* ```
|
|
19
|
+
*
|
|
20
|
+
* The React and Vue adapters wrap `createT` in framework-native bindings
|
|
21
|
+
* (`useTranslation`, `LocaleProvider`, etc.); use those for app code.
|
|
22
|
+
* Reach for `createT` directly when building a non-React/Vue host.
|
|
23
|
+
*
|
|
24
|
+
* @packageDocumentation
|
|
25
|
+
* @public
|
|
26
|
+
*/
|
|
27
|
+
var _lang = "en";
|
|
28
|
+
var common = {
|
|
29
|
+
cancel: "Cancel",
|
|
30
|
+
insert: "Insert",
|
|
31
|
+
apply: "Apply",
|
|
32
|
+
close: "Close",
|
|
33
|
+
"delete": "Delete",
|
|
34
|
+
update: "Update",
|
|
35
|
+
save: "Save",
|
|
36
|
+
retry: "Retry",
|
|
37
|
+
send: "Send",
|
|
38
|
+
edit: "Edit",
|
|
39
|
+
comment: "Comment",
|
|
40
|
+
reply: "Reply",
|
|
41
|
+
accept: "Accept",
|
|
42
|
+
reject: "Reject",
|
|
43
|
+
dismiss: "Dismiss",
|
|
44
|
+
change: "Change",
|
|
45
|
+
clear: "Clear",
|
|
46
|
+
px: "px",
|
|
47
|
+
closeDialog: "Close dialog"
|
|
48
|
+
};
|
|
49
|
+
var toolbar = {
|
|
50
|
+
ariaLabel: "Formatting toolbar",
|
|
51
|
+
file: "File",
|
|
52
|
+
format: "Format",
|
|
53
|
+
insert: "Insert",
|
|
54
|
+
open: "Open",
|
|
55
|
+
openShortcut: "Ctrl+O",
|
|
56
|
+
save: "Save",
|
|
57
|
+
saveShortcut: "Ctrl+S",
|
|
58
|
+
print: "Print",
|
|
59
|
+
printShortcut: "Ctrl+P",
|
|
60
|
+
pageSetup: "Page setup",
|
|
61
|
+
leftToRight: "Left-to-right text",
|
|
62
|
+
rightToLeft: "Right-to-left text",
|
|
63
|
+
image: "Image",
|
|
64
|
+
table: "Table",
|
|
65
|
+
"break": "Break",
|
|
66
|
+
insertFootnote: "Insert Footnote",
|
|
67
|
+
insertEndnote: "Insert Endnote",
|
|
68
|
+
pageBreak: "Page break",
|
|
69
|
+
sectionBreakNextPage: "Section break (next page)",
|
|
70
|
+
sectionBreakContinuous: "Section break (continuous)",
|
|
71
|
+
tableOfContents: "Table of contents",
|
|
72
|
+
symbol: "Symbol",
|
|
73
|
+
watermark: "Watermark",
|
|
74
|
+
help: "Help",
|
|
75
|
+
reportIssue: "Report issue"
|
|
76
|
+
};
|
|
77
|
+
var toc = {
|
|
78
|
+
updatePrompt: "This document contains a table of contents that's out of date. Regenerate it now?",
|
|
79
|
+
refresh: "Refresh table of contents",
|
|
80
|
+
refreshPageNumbers: "Refresh page numbers"
|
|
81
|
+
};
|
|
82
|
+
var formattingBar = {
|
|
83
|
+
groups: {
|
|
84
|
+
history: "History",
|
|
85
|
+
zoom: "Zoom",
|
|
86
|
+
styles: "Styles",
|
|
87
|
+
font: "Font",
|
|
88
|
+
textFormatting: "Text formatting",
|
|
89
|
+
script: "Script",
|
|
90
|
+
alignment: "Alignment",
|
|
91
|
+
listFormatting: "List formatting",
|
|
92
|
+
image: "Image",
|
|
93
|
+
table: "Table",
|
|
94
|
+
insert: "Insert",
|
|
95
|
+
contentControl: "Content controls"
|
|
96
|
+
},
|
|
97
|
+
undo: "Undo",
|
|
98
|
+
undoShortcut: "Undo (Ctrl+Z)",
|
|
99
|
+
redo: "Redo",
|
|
100
|
+
redoShortcut: "Redo (Ctrl+Y)",
|
|
101
|
+
bold: "Bold",
|
|
102
|
+
boldShortcut: "Bold (Ctrl+B)",
|
|
103
|
+
italic: "Italic",
|
|
104
|
+
italicShortcut: "Italic (Ctrl+I)",
|
|
105
|
+
underline: "Underline",
|
|
106
|
+
underlineShortcut: "Underline (Ctrl+U)",
|
|
107
|
+
strikethrough: "Strikethrough",
|
|
108
|
+
fontColor: "Font Color",
|
|
109
|
+
highlightColor: "Text Highlight Color",
|
|
110
|
+
insertLink: "Insert link",
|
|
111
|
+
insertLinkShortcut: "Insert link (Ctrl+K)",
|
|
112
|
+
superscript: "Superscript",
|
|
113
|
+
superscriptShortcut: "Superscript (Ctrl+Shift+=)",
|
|
114
|
+
subscript: "Subscript",
|
|
115
|
+
subscriptShortcut: "Subscript (Ctrl+=)",
|
|
116
|
+
imageProperties: "Image properties",
|
|
117
|
+
imagePropertiesShortcut: "Image properties (alt text, border)...",
|
|
118
|
+
imageWrap: "Wrap text",
|
|
119
|
+
altText: "Alt text",
|
|
120
|
+
clearFormatting: "Clear formatting",
|
|
121
|
+
commentsAndChanges: "Comments & Changes",
|
|
122
|
+
more: "More",
|
|
123
|
+
moreItems: "{count, plural, one {# more item} other {# more items}}",
|
|
124
|
+
unavailableInPreview: "Not available in this preview build"
|
|
125
|
+
};
|
|
126
|
+
var alignment = {
|
|
127
|
+
alignLeft: "Align Left",
|
|
128
|
+
alignLeftShortcut: "Ctrl+L",
|
|
129
|
+
center: "Center",
|
|
130
|
+
centerShortcut: "Ctrl+E",
|
|
131
|
+
alignRight: "Align Right",
|
|
132
|
+
alignRightShortcut: "Ctrl+R",
|
|
133
|
+
justify: "Justify",
|
|
134
|
+
justifyShortcut: "Ctrl+J"
|
|
135
|
+
};
|
|
136
|
+
var lists = {
|
|
137
|
+
ariaLabel: "List formatting",
|
|
138
|
+
typeAriaLabel: "List type",
|
|
139
|
+
indentationAriaLabel: "List indentation",
|
|
140
|
+
bulletList: "Bullet List",
|
|
141
|
+
numberedList: "Numbered List",
|
|
142
|
+
decreaseIndent: "Decrease Indent",
|
|
143
|
+
increaseIndent: "Increase Indent"
|
|
144
|
+
};
|
|
145
|
+
var lineSpacing = {
|
|
146
|
+
label: "Line spacing",
|
|
147
|
+
single: "Single",
|
|
148
|
+
double: "Double",
|
|
149
|
+
lineSpacingTitle: "Line spacing: {label}",
|
|
150
|
+
blockSpacingRules: "Paragraph spacing",
|
|
151
|
+
addSpaceBefore: "Add space before paragraph",
|
|
152
|
+
removeSpaceBefore: "Remove space before paragraph",
|
|
153
|
+
addSpaceAfter: "Add space after paragraph",
|
|
154
|
+
removeSpaceAfter: "Remove space after paragraph"
|
|
155
|
+
};
|
|
156
|
+
var styles = {
|
|
157
|
+
selectAriaLabel: "Select paragraph style",
|
|
158
|
+
normalText: "Normal text",
|
|
159
|
+
title: "Title",
|
|
160
|
+
subtitle: "Subtitle",
|
|
161
|
+
heading1: "Heading 1",
|
|
162
|
+
heading2: "Heading 2",
|
|
163
|
+
heading3: "Heading 3"
|
|
164
|
+
};
|
|
165
|
+
var font = {
|
|
166
|
+
selectAriaLabel: "Select font family",
|
|
167
|
+
sansSerif: "Sans Serif",
|
|
168
|
+
serif: "Serif",
|
|
169
|
+
monospace: "Monospace",
|
|
170
|
+
other: "Other",
|
|
171
|
+
documentFonts: "Document fonts"
|
|
172
|
+
};
|
|
173
|
+
var fontSize = {
|
|
174
|
+
decrease: "Decrease font size",
|
|
175
|
+
increase: "Increase font size",
|
|
176
|
+
label: "Font size",
|
|
177
|
+
listLabel: "Font sizes"
|
|
178
|
+
};
|
|
179
|
+
var zoom = {
|
|
180
|
+
ariaLabel: "Zoom: {label}",
|
|
181
|
+
zoomOut: "Zoom out",
|
|
182
|
+
zoomIn: "Zoom in",
|
|
183
|
+
zoomLevel: "Zoom level"
|
|
184
|
+
};
|
|
185
|
+
var colorPicker = {
|
|
186
|
+
ariaLabel: "{type} color picker",
|
|
187
|
+
highlightColors: "Highlight Colors",
|
|
188
|
+
customColor: "Custom Color",
|
|
189
|
+
noColor: "No Color",
|
|
190
|
+
automatic: "Automatic",
|
|
191
|
+
themeColors: "Theme Colors",
|
|
192
|
+
theme: {
|
|
193
|
+
background1: "Background 1",
|
|
194
|
+
text1: "Text 1",
|
|
195
|
+
background2: "Background 2",
|
|
196
|
+
text2: "Text 2",
|
|
197
|
+
accent1: "Accent 1",
|
|
198
|
+
accent2: "Accent 2",
|
|
199
|
+
accent3: "Accent 3",
|
|
200
|
+
accent4: "Accent 4",
|
|
201
|
+
accent5: "Accent 5",
|
|
202
|
+
accent6: "Accent 6",
|
|
203
|
+
lighter80: "Lighter 80%",
|
|
204
|
+
lighter60: "Lighter 60%",
|
|
205
|
+
lighter40: "Lighter 40%",
|
|
206
|
+
darker25: "Darker 25%",
|
|
207
|
+
darker50: "Darker 50%",
|
|
208
|
+
lighter50: "Lighter 50%",
|
|
209
|
+
lighter35: "Lighter 35%",
|
|
210
|
+
lighter25: "Lighter 25%",
|
|
211
|
+
lighter15: "Lighter 15%",
|
|
212
|
+
lighter5: "Lighter 5%",
|
|
213
|
+
darker5: "Darker 5%",
|
|
214
|
+
darker10: "Darker 10%",
|
|
215
|
+
darker15: "Darker 15%",
|
|
216
|
+
darker35: "Darker 35%",
|
|
217
|
+
darker75: "Darker 75%",
|
|
218
|
+
darker90: "Darker 90%"
|
|
219
|
+
},
|
|
220
|
+
standardColors: "Standard Colors",
|
|
221
|
+
colors: {
|
|
222
|
+
black: "Black",
|
|
223
|
+
darkRed: "Dark Red",
|
|
224
|
+
red: "Red",
|
|
225
|
+
orange: "Orange",
|
|
226
|
+
yellow: "Yellow",
|
|
227
|
+
darkYellow: "Dark Yellow",
|
|
228
|
+
green: "Green",
|
|
229
|
+
darkGreen: "Dark Green",
|
|
230
|
+
teal: "Teal",
|
|
231
|
+
darkTeal: "Dark Teal",
|
|
232
|
+
blue: "Blue",
|
|
233
|
+
darkBlue: "Dark Blue",
|
|
234
|
+
purple: "Purple",
|
|
235
|
+
darkPurple: "Dark Purple",
|
|
236
|
+
brown: "Brown",
|
|
237
|
+
grey50: "Grey 50%",
|
|
238
|
+
grey25: "Grey 25%",
|
|
239
|
+
grey10: "Grey 10%",
|
|
240
|
+
white: "White",
|
|
241
|
+
lightRed: "Light Red",
|
|
242
|
+
lightOrange: "Light Orange",
|
|
243
|
+
lightYellow: "Light Yellow",
|
|
244
|
+
lightGreen: "Light Green",
|
|
245
|
+
lightBlue: "Light Blue",
|
|
246
|
+
lightPurple: "Light Purple",
|
|
247
|
+
pink: "Pink",
|
|
248
|
+
rose: "Rose",
|
|
249
|
+
gold: "Gold",
|
|
250
|
+
aqua: "Aqua",
|
|
251
|
+
lavender: "Lavender",
|
|
252
|
+
silver: "Silver",
|
|
253
|
+
darkOrange: "Dark Orange",
|
|
254
|
+
darkGray: "Dark Gray",
|
|
255
|
+
gray: "Gray",
|
|
256
|
+
cyan: "Cyan",
|
|
257
|
+
darkCyan: "Dark Cyan",
|
|
258
|
+
magenta: "Magenta",
|
|
259
|
+
darkMagenta: "Dark Magenta",
|
|
260
|
+
lightGray: "Light Gray",
|
|
261
|
+
paleGreen: "Pale Green",
|
|
262
|
+
lightCyan: "Light Cyan",
|
|
263
|
+
skyBlue: "Sky Blue",
|
|
264
|
+
lightBlue2: "Light Blue 2",
|
|
265
|
+
lightMagenta: "Light Magenta",
|
|
266
|
+
brightGreen: "Bright Green",
|
|
267
|
+
violet: "Violet"
|
|
268
|
+
},
|
|
269
|
+
apply: "Apply"
|
|
270
|
+
};
|
|
271
|
+
var dialogs = {
|
|
272
|
+
findReplace: {
|
|
273
|
+
titleFind: "Find",
|
|
274
|
+
titleFindReplace: "Find and Replace",
|
|
275
|
+
findLabel: "Find:",
|
|
276
|
+
findPlaceholder: "Enter text to find...",
|
|
277
|
+
findAriaLabel: "Find text",
|
|
278
|
+
findPrevious: "Find previous",
|
|
279
|
+
findPreviousTitle: "Find Previous (Shift+Enter)",
|
|
280
|
+
findNext: "Find next",
|
|
281
|
+
findNextTitle: "Find Next (Enter)",
|
|
282
|
+
matchCount: "{current} of {total} matches",
|
|
283
|
+
noResults: "No results found",
|
|
284
|
+
replaceLabel: "Replace:",
|
|
285
|
+
replacePlaceholder: "Enter replacement text...",
|
|
286
|
+
replaceAriaLabel: "Replace text",
|
|
287
|
+
replaceButton: "Replace",
|
|
288
|
+
replaceCurrentTitle: "Replace current match",
|
|
289
|
+
replaceAllButton: "Replace All",
|
|
290
|
+
replaceAllTitle: "Replace all matches",
|
|
291
|
+
matchCase: "Match case",
|
|
292
|
+
wholeWords: "Whole words",
|
|
293
|
+
matchesFound: "{total} matches",
|
|
294
|
+
toggleReplace: "+ Replace"
|
|
295
|
+
},
|
|
296
|
+
hyperlink: {
|
|
297
|
+
titleEdit: "Edit Hyperlink",
|
|
298
|
+
titleInsert: "Insert Hyperlink",
|
|
299
|
+
tabWebAddress: "Web Address",
|
|
300
|
+
tabBookmark: "Bookmark",
|
|
301
|
+
urlLabel: "URL",
|
|
302
|
+
urlPlaceholder: "https://example.com",
|
|
303
|
+
urlHint: "Enter a web address, email (mailto:), or phone (tel:)",
|
|
304
|
+
bookmarkLabel: "Bookmark",
|
|
305
|
+
bookmarkPlaceholder: "Select a bookmark...",
|
|
306
|
+
displayTextLabel: "Display Text",
|
|
307
|
+
displayTextPlaceholder: "Text to display (optional)",
|
|
308
|
+
displayTextHint: "Leave empty to use the selected text",
|
|
309
|
+
tooltipLabel: "Tooltip (optional)",
|
|
310
|
+
tooltipPlaceholder: "Text shown on hover",
|
|
311
|
+
removeLink: "Remove Link",
|
|
312
|
+
invalidUrl: "Please enter a valid URL",
|
|
313
|
+
urlRequired: "URL is required"
|
|
314
|
+
},
|
|
315
|
+
insertTable: {
|
|
316
|
+
title: "Insert Table",
|
|
317
|
+
hoverToSelect: "Hover to select size",
|
|
318
|
+
tableSize: "{cols} x {rows} Table",
|
|
319
|
+
orSpecifySize: "or specify size",
|
|
320
|
+
rowsLabel: "Rows:",
|
|
321
|
+
columnsLabel: "Columns:",
|
|
322
|
+
insertButton: "Insert Table",
|
|
323
|
+
sizeSelector: "Table size selector",
|
|
324
|
+
columnWidthLabel: "Column width",
|
|
325
|
+
fixedWidth: "Fixed",
|
|
326
|
+
autofit: "Auto-fit to contents",
|
|
327
|
+
tableStyleLabel: "Table style",
|
|
328
|
+
validationHint: "Rows: {minRows}-{maxRows}, Columns: {minCols}-{maxCols}"
|
|
329
|
+
},
|
|
330
|
+
watermark: {
|
|
331
|
+
title: "Watermark",
|
|
332
|
+
noWatermark: "No watermark",
|
|
333
|
+
picture: "Picture watermark",
|
|
334
|
+
text: "Text watermark",
|
|
335
|
+
selectPicture: "Select Picture...",
|
|
336
|
+
scale: "Scale",
|
|
337
|
+
washout: "Washout",
|
|
338
|
+
textLabel: "Text",
|
|
339
|
+
fontLabel: "Font",
|
|
340
|
+
sizeLabel: "Size",
|
|
341
|
+
sizeAuto: "Auto",
|
|
342
|
+
colorLabel: "Color",
|
|
343
|
+
layoutLabel: "Layout",
|
|
344
|
+
diagonal: "Diagonal",
|
|
345
|
+
horizontal: "Horizontal",
|
|
346
|
+
semitransparent: "Semitransparent",
|
|
347
|
+
presetLabel: "Preset",
|
|
348
|
+
applyButton: "Apply",
|
|
349
|
+
cancelButton: "Cancel"
|
|
350
|
+
},
|
|
351
|
+
splitCell: {
|
|
352
|
+
title: "Split Cell",
|
|
353
|
+
description: "Set how many rows and columns to split the selected cell into.",
|
|
354
|
+
rowsLabel: "Rows:",
|
|
355
|
+
columnsLabel: "Columns:",
|
|
356
|
+
currentMinimum: "Minimum from current span: {rows} row(s) x {cols} column(s)",
|
|
357
|
+
minValue: "Use at least {rows} row(s) and {cols} column(s).",
|
|
358
|
+
notOneByOne: "Choose at least two resulting cells."
|
|
359
|
+
},
|
|
360
|
+
insertImage: {
|
|
361
|
+
title: "Insert Image",
|
|
362
|
+
uploadAriaLabel: "Click or drag to upload image",
|
|
363
|
+
uploadText: "Click to select or drag and drop an image",
|
|
364
|
+
uploadSubtext: "PNG, JPG, GIF up to 10MB",
|
|
365
|
+
dimensions: "Dimensions",
|
|
366
|
+
widthLabel: "Width:",
|
|
367
|
+
heightLabel: "Height:",
|
|
368
|
+
aspectRatioLocked: "Aspect ratio locked",
|
|
369
|
+
aspectRatioUnlocked: "Aspect ratio unlocked",
|
|
370
|
+
altTextLabel: "Alt Text (optional)",
|
|
371
|
+
altTextPlaceholder: "Describe the image for accessibility",
|
|
372
|
+
insertButton: "Insert Image",
|
|
373
|
+
invalidFile: "Please select a valid image file",
|
|
374
|
+
fileTooLarge: "Image file is too large (max 10MB)",
|
|
375
|
+
readFailed: "Failed to read image file",
|
|
376
|
+
loadFailed: "Failed to load image",
|
|
377
|
+
preview: "Preview"
|
|
378
|
+
},
|
|
379
|
+
insertSymbol: {
|
|
380
|
+
title: "Insert Symbol",
|
|
381
|
+
searchPlaceholder: "Search symbols (character or Unicode)...",
|
|
382
|
+
noResultsEmpty: "No symbols found",
|
|
383
|
+
noResults: "No symbols found for \"{query}\"",
|
|
384
|
+
decimal: "Decimal: {value}",
|
|
385
|
+
recent: "Recent:",
|
|
386
|
+
categories: {
|
|
387
|
+
common: "Common",
|
|
388
|
+
arrows: "Arrows",
|
|
389
|
+
math: "Math",
|
|
390
|
+
greek: "Greek",
|
|
391
|
+
shapes: "Shapes",
|
|
392
|
+
punctuation: "Punctuation",
|
|
393
|
+
currency: "Currency",
|
|
394
|
+
music: "Music",
|
|
395
|
+
emoji: "Emoji"
|
|
396
|
+
}
|
|
397
|
+
},
|
|
398
|
+
imageProperties: {
|
|
399
|
+
title: "Image Properties",
|
|
400
|
+
altText: "Alt Text",
|
|
401
|
+
altTextPlaceholder: "Describe this image for accessibility...",
|
|
402
|
+
border: "Border",
|
|
403
|
+
width: "Width",
|
|
404
|
+
style: "Style",
|
|
405
|
+
color: "Color",
|
|
406
|
+
preview: "Preview",
|
|
407
|
+
textWrapping: "Text wrapping",
|
|
408
|
+
dimensions: "Dimensions",
|
|
409
|
+
widthLabel: "Width:",
|
|
410
|
+
heightLabel: "Height:",
|
|
411
|
+
lockAspectRatio: "Lock aspect ratio",
|
|
412
|
+
wrapOptions: {
|
|
413
|
+
inline: "Inline with text",
|
|
414
|
+
wrapRight: "Wrap text, float left",
|
|
415
|
+
wrapLeft: "Wrap text, float right",
|
|
416
|
+
topAndBottom: "Top and bottom",
|
|
417
|
+
behind: "Behind text",
|
|
418
|
+
inFront: "In front of text"
|
|
419
|
+
},
|
|
420
|
+
borderKinds: {
|
|
421
|
+
solid: "Solid",
|
|
422
|
+
dashed: "Dashed",
|
|
423
|
+
dotted: "Dotted",
|
|
424
|
+
double: "Double",
|
|
425
|
+
groove: "Groove",
|
|
426
|
+
ridge: "Ridge",
|
|
427
|
+
inset: "Inset",
|
|
428
|
+
outset: "Outset"
|
|
429
|
+
}
|
|
430
|
+
},
|
|
431
|
+
imagePosition: {
|
|
432
|
+
title: "Image Position",
|
|
433
|
+
horizontal: "Horizontal",
|
|
434
|
+
vertical: "Vertical",
|
|
435
|
+
position: "Position",
|
|
436
|
+
alignment: "Alignment",
|
|
437
|
+
offset: "Offset",
|
|
438
|
+
offsetPx: "Offset (px)",
|
|
439
|
+
align: "Align",
|
|
440
|
+
relativeTo: "Relative to",
|
|
441
|
+
alignOptions: {
|
|
442
|
+
left: "Left",
|
|
443
|
+
center: "Center",
|
|
444
|
+
right: "Right",
|
|
445
|
+
top: "Top",
|
|
446
|
+
bottom: "Bottom"
|
|
447
|
+
},
|
|
448
|
+
relativeOptions: {
|
|
449
|
+
page: "Page",
|
|
450
|
+
column: "Column",
|
|
451
|
+
margin: "Margin",
|
|
452
|
+
character: "Character",
|
|
453
|
+
paragraph: "Paragraph",
|
|
454
|
+
line: "Line"
|
|
455
|
+
}
|
|
456
|
+
},
|
|
457
|
+
pageSetup: {
|
|
458
|
+
title: "Page Setup",
|
|
459
|
+
pageSize: "PAGE SIZE",
|
|
460
|
+
sizeLabel: "Size",
|
|
461
|
+
custom: "Custom",
|
|
462
|
+
orientation: "Orientation",
|
|
463
|
+
portrait: "Portrait",
|
|
464
|
+
landscape: "Landscape",
|
|
465
|
+
margins: "MARGINS",
|
|
466
|
+
top: "Top",
|
|
467
|
+
bottom: "Bottom",
|
|
468
|
+
left: "Left",
|
|
469
|
+
right: "Right",
|
|
470
|
+
applyTo: "Apply to",
|
|
471
|
+
applyToDocument: "Whole document",
|
|
472
|
+
applyToSection: "This section",
|
|
473
|
+
pageSizes: {
|
|
474
|
+
letter: "Letter (8.5\" × 11\")",
|
|
475
|
+
a4: "A4 (8.27\" × 11.69\")",
|
|
476
|
+
legal: "Legal (8.5\" × 14\")",
|
|
477
|
+
a3: "A3 (11.69\" × 16.54\")",
|
|
478
|
+
a5: "A5 (5.83\" × 8.27\")",
|
|
479
|
+
b5: "B5 (6.93\" × 9.84\")",
|
|
480
|
+
executive: "Executive (7.25\" × 10.5\")"
|
|
481
|
+
}
|
|
482
|
+
},
|
|
483
|
+
tableProperties: {
|
|
484
|
+
title: "Table Properties",
|
|
485
|
+
widthType: "Width type",
|
|
486
|
+
widthLabel: "Width",
|
|
487
|
+
alignmentLabel: "Alignment",
|
|
488
|
+
widthTypes: {
|
|
489
|
+
auto: "Auto",
|
|
490
|
+
fixed: "Fixed (twips)",
|
|
491
|
+
percentage: "Percentage"
|
|
492
|
+
},
|
|
493
|
+
units: {
|
|
494
|
+
fiftiethsPercent: "(50ths of %)",
|
|
495
|
+
twips: "tw"
|
|
496
|
+
},
|
|
497
|
+
alignOptions: {
|
|
498
|
+
left: "Left",
|
|
499
|
+
center: "Center",
|
|
500
|
+
right: "Right"
|
|
501
|
+
}
|
|
502
|
+
},
|
|
503
|
+
pasteSpecial: {
|
|
504
|
+
title: "Paste Special",
|
|
505
|
+
keepFormatting: "Keep Source Formatting",
|
|
506
|
+
keepFormattingDescription: "Paste with original formatting",
|
|
507
|
+
keepFormattingShortcut: "Ctrl+V",
|
|
508
|
+
plainText: "Paste as Plain Text",
|
|
509
|
+
plainTextDescription: "Paste without any formatting",
|
|
510
|
+
plainTextShortcut: "Ctrl+Shift+V",
|
|
511
|
+
readingClipboard: "Reading clipboard...",
|
|
512
|
+
preview: "Preview:",
|
|
513
|
+
noContent: "No content available to paste",
|
|
514
|
+
clipboardError: "Unable to read clipboard. Please use Ctrl+V to paste."
|
|
515
|
+
},
|
|
516
|
+
footnoteProperties: {
|
|
517
|
+
title: "Footnote & Endnote Properties",
|
|
518
|
+
footnotes: "Footnotes",
|
|
519
|
+
endnotes: "Endnotes",
|
|
520
|
+
position: "Position",
|
|
521
|
+
numberFormat: "Number format",
|
|
522
|
+
startAt: "Start at",
|
|
523
|
+
numbering: "Numbering",
|
|
524
|
+
footnotePositions: {
|
|
525
|
+
bottomOfPage: "Bottom of page",
|
|
526
|
+
belowText: "Below text"
|
|
527
|
+
},
|
|
528
|
+
endnotePositions: {
|
|
529
|
+
endOfDocument: "End of document",
|
|
530
|
+
endOfSection: "End of section"
|
|
531
|
+
},
|
|
532
|
+
numberingOptions: {
|
|
533
|
+
continuous: "Continuous",
|
|
534
|
+
restartSection: "Restart each section",
|
|
535
|
+
restartPage: "Restart each page"
|
|
536
|
+
},
|
|
537
|
+
formats: {
|
|
538
|
+
decimal: "1, 2, 3, ...",
|
|
539
|
+
lowerRoman: "i, ii, iii, ...",
|
|
540
|
+
upperRoman: "I, II, III, ...",
|
|
541
|
+
symbols: "*, †, ‡, ..."
|
|
542
|
+
}
|
|
543
|
+
},
|
|
544
|
+
keyboardShortcuts: {
|
|
545
|
+
ariaLabel: "Keyboard Shortcuts",
|
|
546
|
+
searchPlaceholder: "Search shortcuts...",
|
|
547
|
+
categories: {
|
|
548
|
+
editing: "Editing",
|
|
549
|
+
formatting: "Formatting",
|
|
550
|
+
navigation: "Navigation",
|
|
551
|
+
clipboard: "Clipboard",
|
|
552
|
+
selection: "Selection",
|
|
553
|
+
view: "View",
|
|
554
|
+
file: "File",
|
|
555
|
+
other: "Other"
|
|
556
|
+
},
|
|
557
|
+
shortcuts: {
|
|
558
|
+
save: "Save",
|
|
559
|
+
saveDescription: "Save document",
|
|
560
|
+
print: "Print",
|
|
561
|
+
printDescription: "Print document",
|
|
562
|
+
undo: "Undo",
|
|
563
|
+
undoDescription: "Undo last action",
|
|
564
|
+
redo: "Redo",
|
|
565
|
+
redoDescription: "Redo last action",
|
|
566
|
+
"delete": "Delete",
|
|
567
|
+
deleteDescription: "Delete selected text",
|
|
568
|
+
find: "Find",
|
|
569
|
+
findDescription: "Find text in document",
|
|
570
|
+
findReplace: "Find & Replace",
|
|
571
|
+
findReplaceDescription: "Find and replace text",
|
|
572
|
+
cut: "Cut",
|
|
573
|
+
cutDescription: "Cut selected text",
|
|
574
|
+
copy: "Copy",
|
|
575
|
+
copyDescription: "Copy selected text",
|
|
576
|
+
paste: "Paste",
|
|
577
|
+
pasteDescription: "Paste from clipboard",
|
|
578
|
+
pastePlainText: "Paste as Plain Text",
|
|
579
|
+
pastePlainTextDescription: "Paste without formatting",
|
|
580
|
+
bold: "Bold",
|
|
581
|
+
boldDescription: "Toggle bold formatting",
|
|
582
|
+
italic: "Italic",
|
|
583
|
+
italicDescription: "Toggle italic formatting",
|
|
584
|
+
underline: "Underline",
|
|
585
|
+
underlineDescription: "Toggle underline formatting",
|
|
586
|
+
strikethrough: "Strikethrough",
|
|
587
|
+
strikethroughDescription: "Toggle strikethrough",
|
|
588
|
+
subscript: "Subscript",
|
|
589
|
+
subscriptDescription: "Toggle subscript",
|
|
590
|
+
superscript: "Superscript",
|
|
591
|
+
superscriptDescription: "Toggle superscript",
|
|
592
|
+
alignLeft: "Align Left",
|
|
593
|
+
alignLeftDescription: "Left align paragraph",
|
|
594
|
+
alignCenter: "Align Center",
|
|
595
|
+
alignCenterDescription: "Center align paragraph",
|
|
596
|
+
alignRight: "Align Right",
|
|
597
|
+
alignRightDescription: "Right align paragraph",
|
|
598
|
+
justify: "Justify",
|
|
599
|
+
justifyDescription: "Justify paragraph",
|
|
600
|
+
increaseIndent: "Increase Indent",
|
|
601
|
+
increaseIndentDescription: "Increase paragraph indent",
|
|
602
|
+
decreaseIndent: "Decrease Indent",
|
|
603
|
+
decreaseIndentDescription: "Decrease paragraph indent",
|
|
604
|
+
selectAll: "Select All",
|
|
605
|
+
selectAllDescription: "Select all content",
|
|
606
|
+
selectWord: "Select Word",
|
|
607
|
+
selectWordDescription: "Select current word",
|
|
608
|
+
selectParagraph: "Select Paragraph",
|
|
609
|
+
selectParagraphDescription: "Select current paragraph",
|
|
610
|
+
extendSelectionByWord: "Extend Selection by Word",
|
|
611
|
+
extendSelectionByWordDescription: "Extend selection to next/previous word",
|
|
612
|
+
extendSelectionToLineEdge: "Extend Selection to Line Edge",
|
|
613
|
+
extendSelectionToLineEdgeDescription: "Extend selection to line start/end",
|
|
614
|
+
moveByWord: "Move by Word",
|
|
615
|
+
moveByWordDescription: "Move cursor to next/previous word",
|
|
616
|
+
moveToLineStart: "Move to Line Start",
|
|
617
|
+
moveToLineStartDescription: "Move cursor to start of line",
|
|
618
|
+
moveToLineEnd: "Move to Line End",
|
|
619
|
+
moveToLineEndDescription: "Move cursor to end of line",
|
|
620
|
+
moveToDocumentStart: "Move to Document Start",
|
|
621
|
+
moveToDocumentStartDescription: "Move cursor to start of document",
|
|
622
|
+
moveToDocumentEnd: "Move to Document End",
|
|
623
|
+
moveToDocumentEndDescription: "Move cursor to end of document",
|
|
624
|
+
pageUp: "Page Up",
|
|
625
|
+
pageUpDescription: "Scroll up one page",
|
|
626
|
+
pageDown: "Page Down",
|
|
627
|
+
pageDownDescription: "Scroll down one page",
|
|
628
|
+
zoomIn: "Zoom In",
|
|
629
|
+
zoomInDescription: "Increase zoom level",
|
|
630
|
+
zoomOut: "Zoom Out",
|
|
631
|
+
zoomOutDescription: "Decrease zoom level",
|
|
632
|
+
resetZoom: "Reset Zoom",
|
|
633
|
+
resetZoomDescription: "Reset zoom to 100%",
|
|
634
|
+
keyboardShortcuts: "Keyboard Shortcuts",
|
|
635
|
+
keyboardShortcutsDescription: "Show this help dialog",
|
|
636
|
+
insertLink: "Insert Link",
|
|
637
|
+
insertLinkDescription: "Insert or edit hyperlink"
|
|
638
|
+
},
|
|
639
|
+
noResults: "No shortcuts found matching \"{query}\"",
|
|
640
|
+
pressEscToClose: "Press {key} to close",
|
|
641
|
+
or: "or"
|
|
642
|
+
}
|
|
643
|
+
};
|
|
644
|
+
var comments = {
|
|
645
|
+
resolved: "Resolved",
|
|
646
|
+
resolve: "Resolve",
|
|
647
|
+
reopen: "Reopen",
|
|
648
|
+
moreOptions: "More options",
|
|
649
|
+
unknown: "Unknown",
|
|
650
|
+
addComment: "Add a comment...",
|
|
651
|
+
replyPlaceholder: "Reply or add others with @",
|
|
652
|
+
replyCount: "{count, plural, one {# reply} other {# replies}}"
|
|
653
|
+
};
|
|
654
|
+
var trackedChanges = {
|
|
655
|
+
unknown: "Unknown",
|
|
656
|
+
replaced: "Replaced",
|
|
657
|
+
"with": "with",
|
|
658
|
+
added: "Added",
|
|
659
|
+
deleted: "Deleted"
|
|
660
|
+
};
|
|
661
|
+
var revisions = {
|
|
662
|
+
paragraphMarkInserted: "Inserted paragraph break",
|
|
663
|
+
paragraphMarkDeleted: "Deleted paragraph break",
|
|
664
|
+
paragraphPropertiesChanged: "Changed paragraph properties",
|
|
665
|
+
runPropertiesChanged: "Changed text formatting",
|
|
666
|
+
rowInserted: "Inserted row",
|
|
667
|
+
rowDeleted: "Deleted row",
|
|
668
|
+
rowPropertiesChanged: "Changed row properties",
|
|
669
|
+
cellInserted: "Inserted cell",
|
|
670
|
+
cellDeleted: "Deleted cell",
|
|
671
|
+
cellMerged: "Merged cells",
|
|
672
|
+
cellPropertiesChanged: "Changed cell properties",
|
|
673
|
+
tablePropertiesChanged: "Changed table properties",
|
|
674
|
+
tableInserted: "Inserted table",
|
|
675
|
+
tableDeleted: "Deleted table"
|
|
676
|
+
};
|
|
677
|
+
var contextMenu = {
|
|
678
|
+
ariaLabel: "Context menu",
|
|
679
|
+
textMenuAriaLabel: "Text editing menu",
|
|
680
|
+
customPromptPlaceholder: "Enter custom prompt...",
|
|
681
|
+
cut: "Cut",
|
|
682
|
+
cutShortcut: "Ctrl+X",
|
|
683
|
+
copy: "Copy",
|
|
684
|
+
copyShortcut: "Ctrl+C",
|
|
685
|
+
paste: "Paste",
|
|
686
|
+
pasteShortcut: "Ctrl+V",
|
|
687
|
+
pastePlainText: "Paste as Plain Text",
|
|
688
|
+
pastePlainTextShortcut: "Ctrl+Shift+V",
|
|
689
|
+
"delete": "Delete",
|
|
690
|
+
deleteShortcut: "Del",
|
|
691
|
+
updateTableOfContents: "Update table of contents",
|
|
692
|
+
selectAll: "Select All",
|
|
693
|
+
selectAllShortcut: "Ctrl+A",
|
|
694
|
+
selected: "Selected:",
|
|
695
|
+
aiActions: {
|
|
696
|
+
askAi: "Ask AI",
|
|
697
|
+
rewrite: "Rewrite",
|
|
698
|
+
expand: "Expand",
|
|
699
|
+
summarize: "Summarize",
|
|
700
|
+
translate: "Translate",
|
|
701
|
+
explain: "Explain",
|
|
702
|
+
fixGrammar: "Fix Grammar",
|
|
703
|
+
makeFormal: "Make Formal",
|
|
704
|
+
makeCasual: "Make Casual",
|
|
705
|
+
custom: "Custom"
|
|
706
|
+
},
|
|
707
|
+
editCustomNode: "Edit {label}",
|
|
708
|
+
removeCustomNode: "Remove {label}"
|
|
709
|
+
};
|
|
710
|
+
var documentOutline = {
|
|
711
|
+
ariaLabel: "Document outline",
|
|
712
|
+
closeAriaLabel: "Close outline",
|
|
713
|
+
closeTitle: "Close outline",
|
|
714
|
+
title: "Outline",
|
|
715
|
+
noHeadings: "No headings found. Add headings to your document to see them here."
|
|
716
|
+
};
|
|
717
|
+
var navigation = {
|
|
718
|
+
ariaLabel: "Document navigation",
|
|
719
|
+
title: "Navigation",
|
|
720
|
+
openAriaLabel: "Open navigation",
|
|
721
|
+
openTitle: "Navigation",
|
|
722
|
+
closeAriaLabel: "Close navigation",
|
|
723
|
+
closeTitle: "Close navigation",
|
|
724
|
+
tabs: {
|
|
725
|
+
headings: "Headings",
|
|
726
|
+
find: "Find"
|
|
727
|
+
},
|
|
728
|
+
headings: {
|
|
729
|
+
noHeadings: "No headings found. Add headings to your document to see them here."
|
|
730
|
+
},
|
|
731
|
+
find: {
|
|
732
|
+
placeholder: "Search document",
|
|
733
|
+
inputAriaLabel: "Search document",
|
|
734
|
+
clearAriaLabel: "Clear search",
|
|
735
|
+
previousAriaLabel: "Previous result",
|
|
736
|
+
nextAriaLabel: "Next result",
|
|
737
|
+
matchCase: "Match case",
|
|
738
|
+
wholeWord: "Whole words only",
|
|
739
|
+
optionsAriaLabel: "Search options",
|
|
740
|
+
resultsAriaLabel: "Search results",
|
|
741
|
+
noResults: "No results",
|
|
742
|
+
searching: "Searching…",
|
|
743
|
+
counter: "Result {current} of {total}",
|
|
744
|
+
counterTruncated: "Result {current} of {total}+",
|
|
745
|
+
total: "{total, plural, one {# result} other {# results}}",
|
|
746
|
+
totalTruncated: "{total, plural, other {#+ results}}"
|
|
747
|
+
}
|
|
748
|
+
};
|
|
749
|
+
var sidebar = {
|
|
750
|
+
ariaLabel: "Annotations sidebar"
|
|
751
|
+
};
|
|
752
|
+
var viewer = {
|
|
753
|
+
pageIndicator: "{current} of {total}"
|
|
754
|
+
};
|
|
755
|
+
var titleBar = {
|
|
756
|
+
untitled: "Untitled",
|
|
757
|
+
documentNameAriaLabel: "Document name",
|
|
758
|
+
menuBarAriaLabel: "Menu bar"
|
|
759
|
+
};
|
|
760
|
+
var errors = {
|
|
761
|
+
loadingDocument: "Loading document...",
|
|
762
|
+
noDocumentLoaded: "No document loaded",
|
|
763
|
+
failedToLoad: "Failed to Load Document",
|
|
764
|
+
unableToParse: "Unable to Parse Document",
|
|
765
|
+
somethingWentWrong: "Something went wrong",
|
|
766
|
+
errorDescription: "An error occurred while rendering this component. Please try again or contact support if the problem persists.",
|
|
767
|
+
errorLabel: "Error:",
|
|
768
|
+
componentStack: "Component Stack:",
|
|
769
|
+
tryAgain: "Try Again",
|
|
770
|
+
showDetails: "Show details",
|
|
771
|
+
hideDetails: "Hide details",
|
|
772
|
+
unsavedChanges: "You have unsaved changes. Are you sure you want to leave?"
|
|
773
|
+
};
|
|
774
|
+
var table = {
|
|
775
|
+
insertRowAbove: "Insert row above",
|
|
776
|
+
insertRowBelow: "Insert row below",
|
|
777
|
+
insertColumnLeft: "Insert column left",
|
|
778
|
+
insertColumnRight: "Insert column right",
|
|
779
|
+
deleteRow: "Delete row",
|
|
780
|
+
deleteColumn: "Delete column",
|
|
781
|
+
deleteTable: "Delete table",
|
|
782
|
+
selectTable: "Select entire table",
|
|
783
|
+
mergeCells: "Merge cells",
|
|
784
|
+
splitCell: "Split cell",
|
|
785
|
+
editingTools: "Table editing tools",
|
|
786
|
+
label: "Table:",
|
|
787
|
+
cellFillColor: "Cell Fill Color",
|
|
788
|
+
borderColor: "Border Color",
|
|
789
|
+
borderWidth: "Border width",
|
|
790
|
+
clearCellFill: "Clear cell fill",
|
|
791
|
+
borderStyles: {
|
|
792
|
+
single: "Solid",
|
|
793
|
+
dashed: "Dashed",
|
|
794
|
+
dotted: "Dotted",
|
|
795
|
+
double: "Double",
|
|
796
|
+
triple: "Triple",
|
|
797
|
+
thick: "Thick"
|
|
798
|
+
},
|
|
799
|
+
borderWidths: {
|
|
800
|
+
halfPt: "0.5 pt",
|
|
801
|
+
onePt: "1 pt",
|
|
802
|
+
oneHalfPt: "1.5 pt",
|
|
803
|
+
twoPt: "2 pt",
|
|
804
|
+
threePt: "3 pt"
|
|
805
|
+
},
|
|
806
|
+
unknownAction: "Unknown Action",
|
|
807
|
+
borders: {
|
|
808
|
+
all: "All borders",
|
|
809
|
+
outside: "Outside borders",
|
|
810
|
+
inside: "Inside borders",
|
|
811
|
+
none: "No borders",
|
|
812
|
+
remove: "Remove borders",
|
|
813
|
+
top: "Top border",
|
|
814
|
+
bottom: "Bottom border",
|
|
815
|
+
left: "Left border",
|
|
816
|
+
right: "Right border",
|
|
817
|
+
styleAriaLabel: "Border style",
|
|
818
|
+
tooltip: "Borders"
|
|
819
|
+
},
|
|
820
|
+
moreOptions: "More table options",
|
|
821
|
+
styles: {
|
|
822
|
+
title: "Table Styles",
|
|
823
|
+
label: "Styles",
|
|
824
|
+
normalTable: "Normal Table",
|
|
825
|
+
tableGrid: "Table Grid",
|
|
826
|
+
gridTableLight: "Grid Table Light",
|
|
827
|
+
plainTable1: "Plain Table 1",
|
|
828
|
+
plainTable2: "Plain Table 2",
|
|
829
|
+
plainTable3: "Plain Table 3",
|
|
830
|
+
plainTable4: "Plain Table 4",
|
|
831
|
+
gridTable1Light: "Grid Table 1 Light",
|
|
832
|
+
gridTable4Accent1: "Grid Table 4 Accent 1",
|
|
833
|
+
gridTable5Dark: "Grid Table 5 Dark",
|
|
834
|
+
listTable3Accent2: "List Table 3 Accent 2",
|
|
835
|
+
listTable4Accent3: "List Table 4 Accent 3",
|
|
836
|
+
gridTable4Accent5: "Grid Table 4 Accent 5",
|
|
837
|
+
gridTable4Accent6: "Grid Table 4 Accent 6"
|
|
838
|
+
}
|
|
839
|
+
};
|
|
840
|
+
var tableAdvanced = {
|
|
841
|
+
verticalAlignment: "Vertical alignment",
|
|
842
|
+
top: "Top",
|
|
843
|
+
middle: "Middle",
|
|
844
|
+
bottom: "Bottom",
|
|
845
|
+
cellMargins: "Cell margins",
|
|
846
|
+
textDirection: "Text direction",
|
|
847
|
+
textDirections: {
|
|
848
|
+
horizontal: "Horizontal (LR)",
|
|
849
|
+
verticalRL: "Vertical (top-bottom, RL)",
|
|
850
|
+
verticalLR: "Vertical (bottom-top, LR)"
|
|
851
|
+
},
|
|
852
|
+
toggleNoWrap: "Toggle no-wrap",
|
|
853
|
+
rowHeight: "Row height",
|
|
854
|
+
heightRules: {
|
|
855
|
+
auto: "Auto",
|
|
856
|
+
atLeast: "At least",
|
|
857
|
+
exact: "Exact"
|
|
858
|
+
},
|
|
859
|
+
rule: "Rule",
|
|
860
|
+
height: "Height",
|
|
861
|
+
toggleHeaderRow: "Toggle header row",
|
|
862
|
+
distributeColumns: "Distribute columns evenly",
|
|
863
|
+
autoFit: "Auto-fit to contents",
|
|
864
|
+
tableProperties: "Table properties...",
|
|
865
|
+
tableAlignment: "Table alignment",
|
|
866
|
+
alignTableLeft: "Align table left",
|
|
867
|
+
alignTableCenter: "Align table center",
|
|
868
|
+
alignTableRight: "Align table right",
|
|
869
|
+
tableOptionsMenu: "Table options menu",
|
|
870
|
+
tableOptions: "Table options"
|
|
871
|
+
};
|
|
872
|
+
var imageTransform = {
|
|
873
|
+
tooltip: "Transform",
|
|
874
|
+
rotateClockwise: "Rotate clockwise",
|
|
875
|
+
rotateCounterClockwise: "Rotate counter-clockwise",
|
|
876
|
+
flipHorizontal: "Flip horizontal",
|
|
877
|
+
flipVertical: "Flip vertical"
|
|
878
|
+
};
|
|
879
|
+
var imageWrap = {
|
|
880
|
+
inline: "In Line with Text",
|
|
881
|
+
square: "Square",
|
|
882
|
+
tight: "Tight",
|
|
883
|
+
through: "Through",
|
|
884
|
+
floatLeft: "Square Left",
|
|
885
|
+
floatRight: "Square Right",
|
|
886
|
+
topAndBottom: "Top and Bottom",
|
|
887
|
+
behindText: "Behind Text",
|
|
888
|
+
inFrontOfText: "In Front of Text",
|
|
889
|
+
tooltipPrefix: "Wrap: {label}",
|
|
890
|
+
targets: {
|
|
891
|
+
inline: "In Line with Text",
|
|
892
|
+
square: "Square",
|
|
893
|
+
squareLeft: "Square Left",
|
|
894
|
+
squareRight: "Square Right",
|
|
895
|
+
tight: "Tight",
|
|
896
|
+
through: "Through",
|
|
897
|
+
topAndBottom: "Top and Bottom",
|
|
898
|
+
behind: "Behind Text",
|
|
899
|
+
inFront: "In Front of Text"
|
|
900
|
+
},
|
|
901
|
+
menu: {
|
|
902
|
+
inLineWithText: "In Line with Text",
|
|
903
|
+
squareLeft: "Square Left",
|
|
904
|
+
squareRight: "Square Right",
|
|
905
|
+
behindText: "Behind Text",
|
|
906
|
+
inFrontOfText: "In Front of Text",
|
|
907
|
+
ariaLabel: "Image layout options",
|
|
908
|
+
imageProperties: "Image properties…"
|
|
909
|
+
},
|
|
910
|
+
menuDesc: {
|
|
911
|
+
inLineWithText: "Image flows in the line as a glyph",
|
|
912
|
+
squareLeft: "Image floats left, text wraps on the right",
|
|
913
|
+
squareRight: "Image floats right, text wraps on the left",
|
|
914
|
+
behindText: "Image paints behind body text",
|
|
915
|
+
inFrontOfText: "Image paints over body text"
|
|
916
|
+
}
|
|
917
|
+
};
|
|
918
|
+
var imageInsert = {
|
|
919
|
+
errors: {
|
|
920
|
+
emptyFile: "The selected file is empty.",
|
|
921
|
+
invalidSignature: "The file is not a supported PNG, JPEG, or GIF image.",
|
|
922
|
+
unsupportedFormat: "This image format is not supported for insertion.",
|
|
923
|
+
oversize: "The image exceeds the maximum allowed size.",
|
|
924
|
+
refused: "The image could not be inserted."
|
|
925
|
+
}
|
|
926
|
+
};
|
|
927
|
+
var imageProperties = {
|
|
928
|
+
units: {
|
|
929
|
+
points: "pt"
|
|
930
|
+
},
|
|
931
|
+
hyperlink: "Hyperlink",
|
|
932
|
+
crop: "Crop",
|
|
933
|
+
cropLeft: "Left (%)",
|
|
934
|
+
cropTop: "Top (%)",
|
|
935
|
+
cropRight: "Right (%)",
|
|
936
|
+
cropBottom: "Bottom (%)",
|
|
937
|
+
resetNaturalSize: "Reset to natural size",
|
|
938
|
+
nonPictureHint: "Crop and natural-size reset are available only for pictures.",
|
|
939
|
+
errors: {
|
|
940
|
+
invalidDimensions: "Enter positive width and height values.",
|
|
941
|
+
invalidCrop: "Crop values must be percentages from 0 to 100.",
|
|
942
|
+
invalidPosition: "Enter valid horizontal and vertical position values.",
|
|
943
|
+
refused: "These properties could not be applied."
|
|
944
|
+
},
|
|
945
|
+
position: "Position",
|
|
946
|
+
positionUnavailable: "Position is available only for floating images.",
|
|
947
|
+
positionLocked: "This drawing cannot be moved.",
|
|
948
|
+
horizontalOffset: "Horizontal offset",
|
|
949
|
+
verticalOffset: "Vertical offset",
|
|
950
|
+
relativeToHorizontal: "Relative to (horizontal)",
|
|
951
|
+
relativeToVertical: "Relative to (vertical)"
|
|
952
|
+
};
|
|
953
|
+
var imageAltText = {
|
|
954
|
+
panelTitle: "Alt text",
|
|
955
|
+
title: "Title",
|
|
956
|
+
description: "Description"
|
|
957
|
+
};
|
|
958
|
+
var responsePreview = {
|
|
959
|
+
loading: "{action}...",
|
|
960
|
+
result: "{action} Result",
|
|
961
|
+
closeEsc: "Close (Esc)",
|
|
962
|
+
editPrompt: "Edit the result before accepting:",
|
|
963
|
+
changes: "Changes:",
|
|
964
|
+
original: "Original:",
|
|
965
|
+
"new": "New:",
|
|
966
|
+
cancelEdit: "Cancel Edit"
|
|
967
|
+
};
|
|
968
|
+
var commentMarkers = {
|
|
969
|
+
resolvedComment: "Resolved comment",
|
|
970
|
+
comment: "Comment"
|
|
971
|
+
};
|
|
972
|
+
var editor = {
|
|
973
|
+
toggleCommentsSidebar: "Toggle comments sidebar",
|
|
974
|
+
showDocumentOutline: "Show document outline",
|
|
975
|
+
editing: "Editing",
|
|
976
|
+
editingDescription: "Edit document directly",
|
|
977
|
+
suggesting: "Suggesting",
|
|
978
|
+
suggestingDescription: "Edits become suggestions",
|
|
979
|
+
viewing: "Viewing",
|
|
980
|
+
viewingDescription: "Read-only, no edits",
|
|
981
|
+
failedToParse: "Failed to parse document",
|
|
982
|
+
linkRemoved: "Link removed",
|
|
983
|
+
linkCopied: "Link copied to clipboard",
|
|
984
|
+
failedToSave: "Failed to save document",
|
|
985
|
+
fontSubstitutionNotice: "Some fonts in this document aren't available, so substitutes are shown: {fonts}"
|
|
986
|
+
};
|
|
987
|
+
var hyperlinkPopup = {
|
|
988
|
+
displayTextPlaceholder: "Display text",
|
|
989
|
+
urlPlaceholder: "https://example.com",
|
|
990
|
+
urlLabel: "URL",
|
|
991
|
+
copyLink: "Copy link",
|
|
992
|
+
editLink: "Edit link",
|
|
993
|
+
removeLink: "Remove link",
|
|
994
|
+
openLink: "Open link",
|
|
995
|
+
apply: "Apply",
|
|
996
|
+
cancel: "Cancel",
|
|
997
|
+
insertTitle: "Insert link",
|
|
998
|
+
editTitle: "Edit link",
|
|
999
|
+
inertTarget: "This link points somewhere the editor will not open",
|
|
1000
|
+
bookmarkTarget: "Goes to a place in this document",
|
|
1001
|
+
refused: "That link could not be applied. Check the address and try again."
|
|
1002
|
+
};
|
|
1003
|
+
var contentControl = {
|
|
1004
|
+
group: "Content controls",
|
|
1005
|
+
showAll: "Show content control boundaries",
|
|
1006
|
+
formFill: "Form-fill mode",
|
|
1007
|
+
inspector: "Content control properties",
|
|
1008
|
+
remove: "Remove content control",
|
|
1009
|
+
noControl: "Place the caret inside a content control",
|
|
1010
|
+
inspectorPanel: {
|
|
1011
|
+
title: "Content control",
|
|
1012
|
+
alias: "Title",
|
|
1013
|
+
tag: "Tag",
|
|
1014
|
+
type: "Type",
|
|
1015
|
+
lock: "Lock",
|
|
1016
|
+
placeholder: "Placeholder",
|
|
1017
|
+
bound: "Data bound",
|
|
1018
|
+
empty: "—",
|
|
1019
|
+
yes: "Yes",
|
|
1020
|
+
no: "No",
|
|
1021
|
+
boundNote: "This control is bound to external data. Editing is refused.",
|
|
1022
|
+
lockedNote: "Content editing is locked on this control."
|
|
1023
|
+
},
|
|
1024
|
+
types: {
|
|
1025
|
+
richText: "Rich text",
|
|
1026
|
+
plainText: "Plain text",
|
|
1027
|
+
checkbox: "Checkbox",
|
|
1028
|
+
dropdown: "Dropdown list",
|
|
1029
|
+
comboBox: "Combo box",
|
|
1030
|
+
date: "Date",
|
|
1031
|
+
picture: "Picture",
|
|
1032
|
+
repeatingSection: "Repeating section"
|
|
1033
|
+
},
|
|
1034
|
+
lock: {
|
|
1035
|
+
unlocked: "Unlocked",
|
|
1036
|
+
sdtLocked: "Content control locked",
|
|
1037
|
+
contentLocked: "Contents locked",
|
|
1038
|
+
sdtContentLocked: "Content control and contents locked"
|
|
1039
|
+
}
|
|
1040
|
+
};
|
|
1041
|
+
var headerFooter = {
|
|
1042
|
+
chromeAriaLabel: "Header and footer editing",
|
|
1043
|
+
header: "Header",
|
|
1044
|
+
footer: "Footer",
|
|
1045
|
+
firstPageHeader: "First page header",
|
|
1046
|
+
firstPageFooter: "First page footer",
|
|
1047
|
+
evenPageHeader: "Even page header",
|
|
1048
|
+
evenPageFooter: "Even page footer",
|
|
1049
|
+
regionSection: "{region} — Section {section}",
|
|
1050
|
+
sameAsPrevious: "Same as previous",
|
|
1051
|
+
sameAsPreviousHint: "Edits apply to the preceding section's pages too.",
|
|
1052
|
+
options: "Options",
|
|
1053
|
+
differentFirstPage: "Different first page",
|
|
1054
|
+
differentOddEven: "Different odd and even pages",
|
|
1055
|
+
differentOddEvenHint: "Applies to the whole document.",
|
|
1056
|
+
linkToPrevious: "Link to previous",
|
|
1057
|
+
unlinkFromPrevious: "Unlink from previous",
|
|
1058
|
+
headerDistance: "Header distance from edge",
|
|
1059
|
+
footerDistance: "Footer distance from edge",
|
|
1060
|
+
removeHeader: "Remove header",
|
|
1061
|
+
removeFooter: "Remove footer",
|
|
1062
|
+
pageNumbers: "Page numbers",
|
|
1063
|
+
insertPageNumber: "Insert current page number",
|
|
1064
|
+
insertTotalPages: "Insert total page count",
|
|
1065
|
+
insertSectionPages: "Insert section page count",
|
|
1066
|
+
insertPageXofY: "Insert page X of Y",
|
|
1067
|
+
pageXofYLabel: "Page",
|
|
1068
|
+
pageXofYSeparator: "of",
|
|
1069
|
+
remove: "Remove {label}",
|
|
1070
|
+
closeEditing: "Close {label} editing"
|
|
1071
|
+
};
|
|
1072
|
+
var image = {
|
|
1073
|
+
placeholder: "Image placeholder",
|
|
1074
|
+
placeholderText: "[Image]",
|
|
1075
|
+
editableAriaLabel: "Editable image",
|
|
1076
|
+
unsupportedFormat: "Unsupported image format ({format})",
|
|
1077
|
+
nonPictureGraphic: "Unsupported graphic ({kind})",
|
|
1078
|
+
missingResource: "Image missing",
|
|
1079
|
+
externalResource: "External image not loaded",
|
|
1080
|
+
invalidResource: "Invalid image",
|
|
1081
|
+
contentMismatch: "Image content does not match its type",
|
|
1082
|
+
decodeFailed: "Image could not be decoded",
|
|
1083
|
+
resourceLimit: "Image exceeds size limits",
|
|
1084
|
+
pendingResource: "Loading image"
|
|
1085
|
+
};
|
|
1086
|
+
var imageOverlay = {
|
|
1087
|
+
selection: "Selected image",
|
|
1088
|
+
rotate: "Rotate",
|
|
1089
|
+
imageProperties: "Image properties",
|
|
1090
|
+
deleteImage: "Delete image",
|
|
1091
|
+
replaceImage: "Replace image…",
|
|
1092
|
+
handle: {
|
|
1093
|
+
n: "Resize top edge",
|
|
1094
|
+
ne: "Resize top-right corner",
|
|
1095
|
+
e: "Resize right edge",
|
|
1096
|
+
se: "Resize bottom-right corner",
|
|
1097
|
+
s: "Resize bottom edge",
|
|
1098
|
+
sw: "Resize bottom-left corner",
|
|
1099
|
+
w: "Resize left edge",
|
|
1100
|
+
nw: "Resize top-left corner"
|
|
1101
|
+
}
|
|
1102
|
+
};
|
|
1103
|
+
var ruler = {
|
|
1104
|
+
horizontal: "Horizontal ruler",
|
|
1105
|
+
vertical: "Vertical ruler",
|
|
1106
|
+
firstLineIndent: "First line indent",
|
|
1107
|
+
hangingIndent: "Hanging indent",
|
|
1108
|
+
leftIndent: "Left indent",
|
|
1109
|
+
rightIndent: "Right indent",
|
|
1110
|
+
topMargin: "Top margin",
|
|
1111
|
+
bottomMargin: "Bottom margin"
|
|
1112
|
+
};
|
|
1113
|
+
var print = {
|
|
1114
|
+
label: "Print",
|
|
1115
|
+
allPages: "All ({totalPages} pages)",
|
|
1116
|
+
singlePage: "Page {start}",
|
|
1117
|
+
pageRange: "Pages {start}-{end}"
|
|
1118
|
+
};
|
|
1119
|
+
var unsaved = {
|
|
1120
|
+
unsaved: "Unsaved",
|
|
1121
|
+
saved: "Saved",
|
|
1122
|
+
unsavedTitle: "Document has unsaved changes",
|
|
1123
|
+
savedTitle: "All changes saved",
|
|
1124
|
+
unsavedAriaLabel: "Unsaved changes",
|
|
1125
|
+
savedAriaLabel: "All changes saved"
|
|
1126
|
+
};
|
|
1127
|
+
var loading = {
|
|
1128
|
+
label: "Loading"
|
|
1129
|
+
};
|
|
1130
|
+
var notes = {
|
|
1131
|
+
editingBanner: "Editing note",
|
|
1132
|
+
closeNote: "Close note",
|
|
1133
|
+
"delete": "Delete note",
|
|
1134
|
+
convertToEndnote: "Convert to endnote",
|
|
1135
|
+
convertToFootnote: "Convert to footnote",
|
|
1136
|
+
scope: "Apply to",
|
|
1137
|
+
scopeDocument: "Whole document",
|
|
1138
|
+
scopeSection: "This section",
|
|
1139
|
+
previewFallback: "Footnote",
|
|
1140
|
+
chromeAriaLabel: "Note editing",
|
|
1141
|
+
editingRegion: "{kind} {number}",
|
|
1142
|
+
footnoteKind: "Footnote",
|
|
1143
|
+
endnoteKind: "Endnote",
|
|
1144
|
+
convertAllFootnotes: "Convert all footnotes to endnotes",
|
|
1145
|
+
convertAllEndnotes: "Convert all endnotes to footnotes",
|
|
1146
|
+
inheritedValue: "(inherited)"
|
|
1147
|
+
};
|
|
1148
|
+
var app = {
|
|
1149
|
+
name: "DOCX Editor",
|
|
1150
|
+
newDocument: "New",
|
|
1151
|
+
by: "by EigenPal",
|
|
1152
|
+
framework: "Framework",
|
|
1153
|
+
theme: "Theme"
|
|
1154
|
+
};
|
|
1155
|
+
var editingMode = {
|
|
1156
|
+
label: "Editing mode",
|
|
1157
|
+
editing: "Editing",
|
|
1158
|
+
editingHint: "Edit document directly",
|
|
1159
|
+
suggesting: "Suggesting",
|
|
1160
|
+
suggestingHint: "Edits become suggestions",
|
|
1161
|
+
viewing: "Viewing",
|
|
1162
|
+
viewingHint: "Read-only, no edits"
|
|
1163
|
+
};
|
|
1164
|
+
var review = {
|
|
1165
|
+
ariaLabel: "Review",
|
|
1166
|
+
empty: "No changes or comments",
|
|
1167
|
+
accept: "Accept",
|
|
1168
|
+
reject: "Reject",
|
|
1169
|
+
deleteComment: "Delete comment",
|
|
1170
|
+
discardChange: "Discard change",
|
|
1171
|
+
reply: "Reply",
|
|
1172
|
+
inserted: "Added",
|
|
1173
|
+
deleted: "Deleted",
|
|
1174
|
+
movedFrom: "Moved from here",
|
|
1175
|
+
movedTo: "Moved here",
|
|
1176
|
+
structural: "Changed the document structure",
|
|
1177
|
+
replyRefused: "Could not post the reply",
|
|
1178
|
+
showPane: "Show comments",
|
|
1179
|
+
replaced: "Replaced",
|
|
1180
|
+
replacedWith: "with",
|
|
1181
|
+
commentRefused: "Could not add the comment"
|
|
1182
|
+
};
|
|
1183
|
+
var enJson = {
|
|
1184
|
+
_lang: _lang,
|
|
1185
|
+
common: common,
|
|
1186
|
+
toolbar: toolbar,
|
|
1187
|
+
toc: toc,
|
|
1188
|
+
formattingBar: formattingBar,
|
|
1189
|
+
alignment: alignment,
|
|
1190
|
+
lists: lists,
|
|
1191
|
+
lineSpacing: lineSpacing,
|
|
1192
|
+
styles: styles,
|
|
1193
|
+
font: font,
|
|
1194
|
+
fontSize: fontSize,
|
|
1195
|
+
zoom: zoom,
|
|
1196
|
+
colorPicker: colorPicker,
|
|
1197
|
+
dialogs: dialogs,
|
|
1198
|
+
comments: comments,
|
|
1199
|
+
trackedChanges: trackedChanges,
|
|
1200
|
+
revisions: revisions,
|
|
1201
|
+
contextMenu: contextMenu,
|
|
1202
|
+
documentOutline: documentOutline,
|
|
1203
|
+
navigation: navigation,
|
|
1204
|
+
sidebar: sidebar,
|
|
1205
|
+
viewer: viewer,
|
|
1206
|
+
titleBar: titleBar,
|
|
1207
|
+
errors: errors,
|
|
1208
|
+
table: table,
|
|
1209
|
+
tableAdvanced: tableAdvanced,
|
|
1210
|
+
imageTransform: imageTransform,
|
|
1211
|
+
imageWrap: imageWrap,
|
|
1212
|
+
imageInsert: imageInsert,
|
|
1213
|
+
imageProperties: imageProperties,
|
|
1214
|
+
imageAltText: imageAltText,
|
|
1215
|
+
responsePreview: responsePreview,
|
|
1216
|
+
commentMarkers: commentMarkers,
|
|
1217
|
+
editor: editor,
|
|
1218
|
+
hyperlinkPopup: hyperlinkPopup,
|
|
1219
|
+
contentControl: contentControl,
|
|
1220
|
+
headerFooter: headerFooter,
|
|
1221
|
+
image: image,
|
|
1222
|
+
imageOverlay: imageOverlay,
|
|
1223
|
+
ruler: ruler,
|
|
1224
|
+
print: print,
|
|
1225
|
+
unsaved: unsaved,
|
|
1226
|
+
loading: loading,
|
|
1227
|
+
notes: notes,
|
|
1228
|
+
app: app,
|
|
1229
|
+
editingMode: editingMode,
|
|
1230
|
+
review: review
|
|
1231
|
+
};
|
|
1232
|
+
|
|
1233
|
+
/**
|
|
1234
|
+
* Shared locale data, types, and runtime helpers for the @docx-editor.dev
|
|
1235
|
+
* editor adapters.
|
|
1236
|
+
*
|
|
1237
|
+
* Import everything from the package root. `sideEffects: false` lets
|
|
1238
|
+
* consumer bundlers tree-shake unused locales.
|
|
1239
|
+
*
|
|
1240
|
+
* ```ts
|
|
1241
|
+
* import {
|
|
1242
|
+
* en, de, pl, tr, he, ptBR, zhCN, // typed locale data
|
|
1243
|
+
* locales, // record keyed by BCP-47 tag
|
|
1244
|
+
* deepMerge, createT, // build a t() for custom hosts
|
|
1245
|
+
* type LocaleStrings, // shape of `en` (source of truth)
|
|
1246
|
+
* type Translations, // shape of a community partial
|
|
1247
|
+
* type TranslationKey, // every valid `t()` key
|
|
1248
|
+
* type LocaleCode, // 'en' | 'de' | 'pt-BR' | ...
|
|
1249
|
+
* } from '@docx-editor.dev/i18n';
|
|
1250
|
+
* ```
|
|
1251
|
+
*
|
|
1252
|
+
* The React and Vue adapters wrap `createT` in framework-native bindings
|
|
1253
|
+
* (`useTranslation`, `LocaleProvider`, etc.); use those for app code.
|
|
1254
|
+
* Reach for `createT` directly when building a non-React/Vue host.
|
|
1255
|
+
*
|
|
1256
|
+
* @packageDocumentation
|
|
1257
|
+
* @public
|
|
1258
|
+
*/
|
|
1259
|
+
|
|
1260
|
+
/**
|
|
1261
|
+
* Full locale string set, auto-derived from `en.json` (the source of truth).
|
|
1262
|
+
* Every other locale is a `PartialLocaleStrings` against this shape.
|
|
1263
|
+
*
|
|
1264
|
+
* @public
|
|
1265
|
+
*/
|
|
1266
|
+
type LocaleStrings = typeof enJson;
|
|
1267
|
+
/**
|
|
1268
|
+
* Every locale code shipped from this package. Pass to `locales[code]`
|
|
1269
|
+
* for runtime lookup; assign to `_lang` to drive `Intl.PluralRules`.
|
|
1270
|
+
*
|
|
1271
|
+
* Custom codes are accepted at runtime ({@link PartialLocaleStrings._lang}
|
|
1272
|
+
* widens to any string), but the shipped union is the IDE-completion list.
|
|
1273
|
+
*
|
|
1274
|
+
* @public
|
|
1275
|
+
*/
|
|
1276
|
+
type LocaleCode = 'en' | 'de' | 'fr' | 'he' | 'hi' | 'id' | 'pl' | 'pt-BR' | 'tr' | 'zh-CN';
|
|
1277
|
+
/** English (`en`) — the source of truth, 100% covered. @public */
|
|
1278
|
+
declare const en: LocaleStrings;
|
|
1279
|
+
/** German (`de`). Community-maintained; null leaves fall back to English. @public */
|
|
1280
|
+
declare const de: PartialLocaleStrings;
|
|
1281
|
+
/** French (`fr`). Community-maintained; null leaves fall back to English. @public */
|
|
1282
|
+
declare const fr: PartialLocaleStrings;
|
|
1283
|
+
/** Hebrew (`he`). Community-maintained; null leaves fall back to English. @public */
|
|
1284
|
+
declare const he: PartialLocaleStrings;
|
|
1285
|
+
/** Hindi (`hi`). Community-maintained; null leaves fall back to English. @public */
|
|
1286
|
+
declare const hi: PartialLocaleStrings;
|
|
1287
|
+
/** Indonesian (`id`). Community-maintained; null leaves fall back to English. @public */
|
|
1288
|
+
declare const id: PartialLocaleStrings;
|
|
1289
|
+
/** Polish (`pl`). Community-maintained; null leaves fall back to English. @public */
|
|
1290
|
+
declare const pl: PartialLocaleStrings;
|
|
1291
|
+
/** Portuguese (Brazil) (`pt-BR`). Community-maintained; null leaves fall back to English. @public */
|
|
1292
|
+
declare const ptBR: PartialLocaleStrings;
|
|
1293
|
+
/** Turkish (`tr`). Community-maintained; null leaves fall back to English. @public */
|
|
1294
|
+
declare const tr: PartialLocaleStrings;
|
|
1295
|
+
/** Simplified Chinese (`zh-CN`). Community-maintained; null leaves fall back to English. @public */
|
|
1296
|
+
declare const zhCN: PartialLocaleStrings;
|
|
1297
|
+
/**
|
|
1298
|
+
* Every shipped locale, keyed by BCP-47 tag. Use for runtime locale
|
|
1299
|
+
* pickers and "look up the locale matching this user preference" code:
|
|
1300
|
+
*
|
|
1301
|
+
* ```ts
|
|
1302
|
+
* <DocxEditor i18n={locales[userLocale]} />
|
|
1303
|
+
* ```
|
|
1304
|
+
*
|
|
1305
|
+
* Importing `locales` defeats the per-locale tree-shake — the bundler
|
|
1306
|
+
* sees a static reference to every locale. If you only need one or two,
|
|
1307
|
+
* import them by name (`import { en, de } from '...'`) instead.
|
|
1308
|
+
*
|
|
1309
|
+
* @public
|
|
1310
|
+
*/
|
|
1311
|
+
declare const locales: Record<LocaleCode, PartialLocaleStrings>;
|
|
1312
|
+
/**
|
|
1313
|
+
* Recursive Partial that allows `null` at leaves to signal "not yet
|
|
1314
|
+
* translated, fall back to English." Community translations use this shape;
|
|
1315
|
+
* `bun run i18n:fix` keeps every locale aligned to `en.json` with `null`
|
|
1316
|
+
* placeholders for missing keys.
|
|
1317
|
+
*
|
|
1318
|
+
* @public
|
|
1319
|
+
*/
|
|
1320
|
+
type DeepPartial<T> = {
|
|
1321
|
+
[K in keyof T]?: T[K] extends object ? DeepPartial<T[K]> : T[K] | null;
|
|
1322
|
+
};
|
|
1323
|
+
/**
|
|
1324
|
+
* Partial locale strings — what consumers pass to the editor's `i18n` prop.
|
|
1325
|
+
* Missing keys fall back to English. Optional `_lang` carries the BCP-47
|
|
1326
|
+
* tag used by `Intl.PluralRules`; shipped codes autocomplete but custom
|
|
1327
|
+
* strings are accepted.
|
|
1328
|
+
*
|
|
1329
|
+
* @public
|
|
1330
|
+
*/
|
|
1331
|
+
type PartialLocaleStrings = DeepPartial<LocaleStrings> & {
|
|
1332
|
+
_lang?: LocaleCode | (string & {});
|
|
1333
|
+
};
|
|
1334
|
+
/**
|
|
1335
|
+
* Alias for `PartialLocaleStrings`. Prefer this name when typing the
|
|
1336
|
+
* consumer-facing `i18n` prop or function parameter.
|
|
1337
|
+
*
|
|
1338
|
+
* @public
|
|
1339
|
+
*/
|
|
1340
|
+
type Translations = PartialLocaleStrings;
|
|
1341
|
+
type DotPath<T, Prefix extends string = ''> = {
|
|
1342
|
+
[K in keyof T & string]: T[K] extends Record<string, unknown> ? DotPath<T[K], `${Prefix}${K}.`> : `${Prefix}${K}`;
|
|
1343
|
+
}[keyof T & string];
|
|
1344
|
+
/**
|
|
1345
|
+
* Every valid dot-notation key into `LocaleStrings`, e.g. `'toolbar.bold'`
|
|
1346
|
+
* or `'dialogs.findReplace.matchCount'`. Pass to `t(key, vars?)` for
|
|
1347
|
+
* compile-time-checked translation lookup.
|
|
1348
|
+
*
|
|
1349
|
+
* @public
|
|
1350
|
+
*/
|
|
1351
|
+
type TranslationKey = DotPath<LocaleStrings>;
|
|
1352
|
+
type AnyRecord = Record<string, unknown>;
|
|
1353
|
+
/**
|
|
1354
|
+
* Deep-merge a partial locale over a base locale. Null leaves in the
|
|
1355
|
+
* override are treated as "not translated" and fall back to the base.
|
|
1356
|
+
* Adapters call this once when the `i18n` prop changes, then hand the
|
|
1357
|
+
* result to {@link createT}.
|
|
1358
|
+
*
|
|
1359
|
+
* @public
|
|
1360
|
+
*/
|
|
1361
|
+
declare function deepMerge(base: AnyRecord, override: AnyRecord | undefined): AnyRecord;
|
|
1362
|
+
/**
|
|
1363
|
+
* The signature of `t()`: look up a translation by dot-notation key,
|
|
1364
|
+
* interpolate `{vars}`, and resolve ICU plurals.
|
|
1365
|
+
*
|
|
1366
|
+
* @public
|
|
1367
|
+
*/
|
|
1368
|
+
type TFunction = (key: TranslationKey, vars?: Record<string, string | number>) => string;
|
|
1369
|
+
/**
|
|
1370
|
+
* Build a typed `t(key, vars?)` function from a merged locale.
|
|
1371
|
+
*
|
|
1372
|
+
* - **Lookup**: dot-notation paths against the locale tree
|
|
1373
|
+
* (`'toolbar.bold'`, `'dialogs.findReplace.matchCount'`).
|
|
1374
|
+
* - **Interpolation**: `{name}` placeholders read from `vars`.
|
|
1375
|
+
* - **Plurals**: ICU `{count, plural, =0 {none} one {# item} other {# items}}`
|
|
1376
|
+
* with `Intl.PluralRules` for CLDR categories and `=N` for exact matches.
|
|
1377
|
+
* - **Fallback**: missing keys return the key string itself, useful for
|
|
1378
|
+
* spotting un-translated UI in development.
|
|
1379
|
+
*
|
|
1380
|
+
* The React/Vue adapters wrap this in `useTranslation()`; use it directly
|
|
1381
|
+
* when building a non-React/Vue host (server-rendered docs, CLI, etc.).
|
|
1382
|
+
*
|
|
1383
|
+
* @example
|
|
1384
|
+
* ```ts
|
|
1385
|
+
* import { deepMerge, createT, en, de } from '@docx-editor.dev/i18n';
|
|
1386
|
+
* const merged = deepMerge(en, de) as LocaleStrings;
|
|
1387
|
+
* const t = createT(merged, 'de');
|
|
1388
|
+
* t('toolbar.bold'); // → 'Fett'
|
|
1389
|
+
* t('dialogs.findReplace.matchCount', { current: 3, total: 15 });
|
|
1390
|
+
* ```
|
|
1391
|
+
*
|
|
1392
|
+
* @public
|
|
1393
|
+
*/
|
|
1394
|
+
declare function createT(strings: LocaleStrings, lang?: string): TFunction;
|
|
1395
|
+
|
|
1396
|
+
export { type DeepPartial, type LocaleCode, type LocaleStrings, type PartialLocaleStrings, type TFunction, type TranslationKey, type Translations, createT, de, deepMerge, en, fr, he, hi, id, locales, pl, ptBR, tr, zhCN };
|