@gram-lang/i18n 1.2.1 → 1.4.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/README.md +19 -1
- package/dist/index.d.ts +277 -4
- package/dist/index.js +578 -27
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
*Part of the [Gram monorepo](https://git.gram-lang.org/gram-lang/gram).*
|
|
7
7
|
|
|
8
|
-
The translation and normalization module
|
|
8
|
+
The translation and normalization module of the Gram recipe language: it normalizes units and time, and holds every word a reader sees, in English and French (the renderer's views and the playground), plus the category labels and the AI language instructions. It provides high-performance, O(1) lookup dictionaries and normalizers to translate locale-specific aliases (e.g., `càs`, `cuillère à soupe`, `teaspoon`) into standardized canonical representation units (e.g., `tbsp`, `tsp`).
|
|
9
9
|
|
|
10
10
|
---
|
|
11
11
|
|
|
@@ -42,6 +42,20 @@ console.log(resolveTimeUnit('heures', 'fr')); // 'h'
|
|
|
42
42
|
console.log(resolveTimeUnit('minutes')); // 'm'
|
|
43
43
|
```
|
|
44
44
|
|
|
45
|
+
### Words and templates
|
|
46
|
+
|
|
47
|
+
`getDictionary(lang)` returns the dictionary of a language (`en` or `fr`): the labels of the renderer's views (`renderer.*`, including the names of the outputs and of the formats), the units of durations (`renderer.durationUnits`, `1h 30min` or `1j 1h`) and the strings of the playground. `fillTemplate(template, values)` fills the `{name}` placeholders of a dictionary string (`"Serve at {time}"` becomes `"Serve at 20:00"`) and leaves a name with no value as written, so a missing value shows up instead of vanishing.
|
|
48
|
+
|
|
49
|
+
```javascript
|
|
50
|
+
import { getDictionary, fillTemplate } from '@gram-lang/i18n';
|
|
51
|
+
|
|
52
|
+
const t = getDictionary('fr');
|
|
53
|
+
console.log(t.renderer.durationUnits); // { day: 'j', hour: 'h', minute: 'min', second: 's' }
|
|
54
|
+
console.log(fillTemplate('Serve at {time}', { time: '20:00' })); // 'Serve at 20:00'
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
A key is added in both languages together: a surface never carries a word of its own.
|
|
58
|
+
|
|
45
59
|
### ⚙️ How it Works
|
|
46
60
|
|
|
47
61
|
To maintain maximum performance under load (e.g., when compiling/analyzing large numbers of recipes), the dictionaries are compiled once at initialization into flat hash maps using `compileDictionary`. Lookups are `O(1)` operations.
|
|
@@ -56,6 +70,10 @@ If a language-specific code (e.g., `'fr'`) is provided, the function checks the
|
|
|
56
70
|
* `src/dictionary.ts`: Dictionary compiler helper that transforms structured translations into flat `O(1)` maps.
|
|
57
71
|
* `src/units.ts`: Mass and volume unit dictionary (French & English) and normalizer.
|
|
58
72
|
* `src/time.ts`: Time unit dictionary (French & English) and normalizer.
|
|
73
|
+
* `src/locales/`: The `en` and `fr` dictionaries (renderer views, nutrients, playground) and `getDictionary()`.
|
|
74
|
+
* `src/template.ts`: `fillTemplate()`.
|
|
75
|
+
* `src/categories.ts`: Shopping list category keys and their labels per language.
|
|
76
|
+
* `src/ai.ts`: The language instruction added to AI prompts.
|
|
59
77
|
|
|
60
78
|
---
|
|
61
79
|
|
package/dist/index.d.ts
CHANGED
|
@@ -21,6 +21,13 @@ declare const UNIT_DICTIONARIES: {
|
|
|
21
21
|
};
|
|
22
22
|
declare const UNIT_BY_LANG: Record<string, CompiledDict>;
|
|
23
23
|
declare const UNIT_GLOBAL: CompiledDict;
|
|
24
|
+
/**
|
|
25
|
+
* Spelling-insensitive lookup key for a unit: lowercased, diacritics stripped,
|
|
26
|
+
* and abbreviation punctuation / spaces removed, so "c.à.s", "c. à s.", "c.a.s"
|
|
27
|
+
* and "càs" all collapse to "cas". Only used to *find* a canonical unit --
|
|
28
|
+
* unknown units are still returned as the author wrote them.
|
|
29
|
+
*/
|
|
30
|
+
declare function unitKey(raw: string): string;
|
|
24
31
|
interface UnitMap {
|
|
25
32
|
base: string;
|
|
26
33
|
map: Record<string, number>;
|
|
@@ -67,18 +74,162 @@ declare function getDefaultCategories(lang?: string): string[];
|
|
|
67
74
|
|
|
68
75
|
declare const en: {
|
|
69
76
|
renderer: {
|
|
77
|
+
viewsPaused: string;
|
|
78
|
+
viewsPausedDescription: string;
|
|
79
|
+
/** What a surface offers next to paused views: jump to the error. */
|
|
80
|
+
showError: string;
|
|
81
|
+
/** An output the recipe has nothing for (a run sheet with nothing to schedule). */
|
|
82
|
+
outputEmpty: string;
|
|
83
|
+
/** The serving time controls of a view laid out in time (the editor's panel). */
|
|
84
|
+
serving: {
|
|
85
|
+
label: string;
|
|
86
|
+
clear: string;
|
|
87
|
+
clearTitle: string;
|
|
88
|
+
suggest: string;
|
|
89
|
+
none: string;
|
|
90
|
+
whyNot: string;
|
|
91
|
+
earliest: string;
|
|
92
|
+
};
|
|
93
|
+
/** The session controls of a view (the editor's panel): scale, baker's reference, stock. */
|
|
94
|
+
session: {
|
|
95
|
+
title: string;
|
|
96
|
+
scale: string;
|
|
97
|
+
portions: string;
|
|
98
|
+
byIngredient: string;
|
|
99
|
+
ingredient: string;
|
|
100
|
+
qty: string;
|
|
101
|
+
unit: string;
|
|
102
|
+
apply: string;
|
|
103
|
+
bakersReference: string;
|
|
104
|
+
auto: string;
|
|
105
|
+
stock: string;
|
|
106
|
+
stockHint: string;
|
|
107
|
+
reset: string;
|
|
108
|
+
scaled: string;
|
|
109
|
+
inStock: string;
|
|
110
|
+
scaleError: string;
|
|
111
|
+
};
|
|
112
|
+
/** The name of each output of the renderer (`outputs`), by its id. */
|
|
113
|
+
outputs: Record<string, string>;
|
|
114
|
+
/** The name of each format a view can be written in (`FORMATS`). */
|
|
115
|
+
formats: Record<string, string>;
|
|
70
116
|
shoppingList: string;
|
|
117
|
+
/** The ingredients a section uses, above its steps. */
|
|
118
|
+
ingredients: string;
|
|
119
|
+
instructions: string;
|
|
120
|
+
/** The comments at the end of a line, gathered under the recipe. */
|
|
121
|
+
notes: string;
|
|
122
|
+
/** Between the options of an alternative (`@butter|oil`). */
|
|
123
|
+
or: string;
|
|
124
|
+
/** The head of the metadata block of the Markdown recipe. */
|
|
125
|
+
metadata: string;
|
|
126
|
+
/** Marks a composite ingredient (`@yolk<@egg`) in a list. */
|
|
127
|
+
composite: string;
|
|
128
|
+
/** Under a composite in the shopping list, the share of the item used whole (`@egg{1}` next to `@yolk<@egg`). */
|
|
129
|
+
directUse: string;
|
|
130
|
+
/** The label of the total mass in the recipe's header. */
|
|
131
|
+
totalMass: string;
|
|
132
|
+
incomplete: string;
|
|
133
|
+
/** After a timer that is a passive wait, and the short mark of an alternative. */
|
|
134
|
+
passive: string;
|
|
135
|
+
alt: string;
|
|
136
|
+
unknownIngredient: string;
|
|
137
|
+
unknownReference: string;
|
|
138
|
+
/** The portions of the recipe (`portions:`), and once it is scaled. */
|
|
139
|
+
servings: string;
|
|
140
|
+
servingsScaled: string;
|
|
141
|
+
/** The word after the portions stepper, by plural category (`Intl.PluralRules`). */
|
|
142
|
+
portionsUnit: {
|
|
143
|
+
one: string;
|
|
144
|
+
other: string;
|
|
145
|
+
};
|
|
146
|
+
/** The badge of a scaled recipe in the hero bar ("×1.5"). */
|
|
147
|
+
scaledRecipe: string;
|
|
148
|
+
/** The pencil button beside the portions, where the surface can change them. */
|
|
149
|
+
changePortions: string;
|
|
71
150
|
cookware: string;
|
|
72
151
|
equipment: string;
|
|
73
152
|
nutrition: string;
|
|
153
|
+
/** The units of a computed duration (`formatDuration`): "1d 2h", "1h 30min", "45s". */
|
|
154
|
+
durationUnits: {
|
|
155
|
+
day: string;
|
|
156
|
+
hour: string;
|
|
157
|
+
minute: string;
|
|
158
|
+
second: string;
|
|
159
|
+
};
|
|
74
160
|
totalTime: string;
|
|
75
161
|
idleTime: string;
|
|
76
162
|
activeTime: string;
|
|
77
163
|
prepTime: string;
|
|
78
164
|
totalTimeTooltip: string;
|
|
79
|
-
|
|
165
|
+
/** Under the total time's breakdown: where the hour-by-hour plan lives. */
|
|
166
|
+
totalTimeRunSheetHint: string;
|
|
80
167
|
activeTimeCardTooltip: string;
|
|
81
168
|
prepTimeTooltip: string;
|
|
169
|
+
miseEnPlace: string;
|
|
170
|
+
scheduleLabel: string;
|
|
171
|
+
restsLabel: string;
|
|
172
|
+
restsShortest: string;
|
|
173
|
+
restsBalanced: string;
|
|
174
|
+
restsLongest: string;
|
|
175
|
+
schedulePerSection: string;
|
|
176
|
+
scheduleUpfront: string;
|
|
177
|
+
schedulePerDay: string;
|
|
178
|
+
dayBefore: string;
|
|
179
|
+
dayToday: string;
|
|
180
|
+
runSheetStep: string;
|
|
181
|
+
runSheetRest: string;
|
|
182
|
+
runSheetUnnamedSection: string;
|
|
183
|
+
runSheetProblems: string;
|
|
184
|
+
runSheetOutside: string;
|
|
185
|
+
runSheetExceeds: string;
|
|
186
|
+
runSheetDayMismatch: string;
|
|
187
|
+
runSheetPast: string;
|
|
188
|
+
runSheetMulti: string;
|
|
189
|
+
runSheetTitle: string;
|
|
190
|
+
runSheetFor: string;
|
|
191
|
+
runSheetDays: string;
|
|
192
|
+
runSheetDaysMany: string;
|
|
193
|
+
runSheetVisits: string;
|
|
194
|
+
runSheetVisitsMany: string;
|
|
195
|
+
runSheetWork: string;
|
|
196
|
+
runSheetServe: string;
|
|
197
|
+
runSheetAbout: string;
|
|
198
|
+
runSheetKit: string;
|
|
199
|
+
runSheetLegendCook: string;
|
|
200
|
+
runSheetLegendThread: string;
|
|
201
|
+
runSheetProgram: string;
|
|
202
|
+
runSheetExecution: string;
|
|
203
|
+
runSheetIngredients: string;
|
|
204
|
+
runSheetStart: string;
|
|
205
|
+
runSheetContinued: string;
|
|
206
|
+
runSheetLeaving: string;
|
|
207
|
+
runSheetMadeOn: string;
|
|
208
|
+
runSheetMadeAt: string;
|
|
209
|
+
runSheetMadeEarlier: string;
|
|
210
|
+
runSheetInStock: string;
|
|
211
|
+
runSheetProgramStep: string;
|
|
212
|
+
runSheetProgramSteps: string;
|
|
213
|
+
runSheetRange: string;
|
|
214
|
+
runSheetPossibleFrom: string;
|
|
215
|
+
runSheetFixedService: string;
|
|
216
|
+
runSheetFixedVisit: string;
|
|
217
|
+
runSheetNextVisit: string;
|
|
218
|
+
runSheetNextVisitSameDay: string;
|
|
219
|
+
runSheetServeAt: string;
|
|
220
|
+
runSheetStretchedTo: string;
|
|
221
|
+
runSheetShortenedTo: string;
|
|
222
|
+
runSheetUntilClock: string;
|
|
223
|
+
runSheetNothing: string;
|
|
224
|
+
runSheetFindOk: string;
|
|
225
|
+
runSheetFindRejected: string;
|
|
226
|
+
runSheetFindStart: string;
|
|
227
|
+
runSheetFindNone: string;
|
|
228
|
+
runSheetAdjusted: string;
|
|
229
|
+
runSheetAdjustedMany: string;
|
|
230
|
+
runSheetNoAdjustment: string;
|
|
231
|
+
runSheetEarliest: string;
|
|
232
|
+
runSheetEarliestNone: string;
|
|
82
233
|
est: string;
|
|
83
234
|
passiveTimeTooltip: string;
|
|
84
235
|
activeTimeTooltip: string;
|
|
@@ -98,9 +249,14 @@ declare const en: {
|
|
|
98
249
|
breakdownPassive: string;
|
|
99
250
|
breakdownTimer: string;
|
|
100
251
|
breakdownPrep: string;
|
|
252
|
+
colon: string;
|
|
101
253
|
standardizedMass: string;
|
|
102
254
|
quantity: string;
|
|
103
255
|
intermediateIngredient: string;
|
|
256
|
+
tooltipMass: string;
|
|
257
|
+
tooltipPreparation: string;
|
|
258
|
+
tooltipBakers: string;
|
|
259
|
+
tooltipTakenFrom: string;
|
|
104
260
|
alternatives: string;
|
|
105
261
|
decreasePortions: string;
|
|
106
262
|
editPortions: string;
|
|
@@ -108,6 +264,9 @@ declare const en: {
|
|
|
108
264
|
returnToStep: string;
|
|
109
265
|
mixedUnitsTooltip: string;
|
|
110
266
|
mixedUnits: string;
|
|
267
|
+
copyShoppingList: string;
|
|
268
|
+
copied: string;
|
|
269
|
+
toggleStepDone: string;
|
|
111
270
|
purchasingWeight: string;
|
|
112
271
|
gross: string;
|
|
113
272
|
intermediateResult: string;
|
|
@@ -115,12 +274,29 @@ declare const en: {
|
|
|
115
274
|
estimatedSuffix: string;
|
|
116
275
|
missingMass: string;
|
|
117
276
|
someIngredients: string;
|
|
277
|
+
massTitle: string;
|
|
278
|
+
massSectionTitle: string;
|
|
279
|
+
massEstimated: string;
|
|
280
|
+
massEstimatedDetail: string;
|
|
281
|
+
massIncomplete: string;
|
|
282
|
+
massIncompleteDetail: string;
|
|
283
|
+
massMethodDensity: string;
|
|
284
|
+
massMethodUnitWeight: string;
|
|
285
|
+
massIncompleteHint: string;
|
|
118
286
|
nutritionWholeRecipe: string;
|
|
119
287
|
nutritionPerPortion: string;
|
|
120
288
|
nutritionPer100g: string;
|
|
121
289
|
nutritionRawMassNote: string;
|
|
122
290
|
nutritionRawMassNotePartial: string;
|
|
123
291
|
incompleteData: string;
|
|
292
|
+
/** Under the nutrition of the text format when a mass was estimated from a density. */
|
|
293
|
+
nutritionEstimated: string;
|
|
294
|
+
nutritionSalt: string;
|
|
295
|
+
nutritionTableTitle: string;
|
|
296
|
+
nutritionReferenceIntake: string;
|
|
297
|
+
nutritionReferenceIntakeNote: string;
|
|
298
|
+
nutritionNutrient: string;
|
|
299
|
+
nutritionWholeRecipeTotal: string;
|
|
124
300
|
ofWhich: string;
|
|
125
301
|
nutrients: {
|
|
126
302
|
calories: string;
|
|
@@ -142,9 +318,42 @@ declare const en: {
|
|
|
142
318
|
writePlaceholder: string;
|
|
143
319
|
outputTab: string;
|
|
144
320
|
viewLabel: string;
|
|
321
|
+
formatLabel: string;
|
|
145
322
|
loadExample: string;
|
|
146
323
|
recipe: string;
|
|
147
|
-
|
|
324
|
+
studioTitle: string;
|
|
325
|
+
settingsButton: string;
|
|
326
|
+
settingsHint: {
|
|
327
|
+
text: string;
|
|
328
|
+
dismiss: string;
|
|
329
|
+
};
|
|
330
|
+
activeOptionsBadge: string;
|
|
331
|
+
resetAll: string;
|
|
332
|
+
resetSection: string;
|
|
333
|
+
openScheduleSettings: string;
|
|
334
|
+
scheduleButton: string;
|
|
335
|
+
sections: {
|
|
336
|
+
schedule: string;
|
|
337
|
+
scale: string;
|
|
338
|
+
bakersMath: string;
|
|
339
|
+
display: string;
|
|
340
|
+
physics: string;
|
|
341
|
+
stock: string;
|
|
342
|
+
};
|
|
343
|
+
badges: {
|
|
344
|
+
default: string;
|
|
345
|
+
active: string;
|
|
346
|
+
inactive: string;
|
|
347
|
+
standardized: string;
|
|
348
|
+
nutritionActive: string;
|
|
349
|
+
byIngredient: string;
|
|
350
|
+
inStock: string;
|
|
351
|
+
serveAt: string;
|
|
352
|
+
customHours: string;
|
|
353
|
+
};
|
|
354
|
+
a11y: {
|
|
355
|
+
closeDrawer: string;
|
|
356
|
+
};
|
|
148
357
|
examples: {
|
|
149
358
|
newRecipe: string;
|
|
150
359
|
canneles: string;
|
|
@@ -156,7 +365,24 @@ declare const en: {
|
|
|
156
365
|
jsonTree: string;
|
|
157
366
|
markdown: string;
|
|
158
367
|
preview: string;
|
|
159
|
-
|
|
368
|
+
runSheet: string;
|
|
369
|
+
serveWhenTitle: string;
|
|
370
|
+
serveWhenNone: string;
|
|
371
|
+
serveWhenWhyNot: string;
|
|
372
|
+
earliestTitle: string;
|
|
373
|
+
earliestNone: string;
|
|
374
|
+
earliestUse: string;
|
|
375
|
+
planSummary: string;
|
|
376
|
+
planServeAt: string;
|
|
377
|
+
planTimeZone: string;
|
|
378
|
+
planAvailability: string;
|
|
379
|
+
planSpecificHours: string;
|
|
380
|
+
planDayUnavailable: string;
|
|
381
|
+
serveAtClear: string;
|
|
382
|
+
serveAtClearTitle: string;
|
|
383
|
+
serveOtherSlots: string;
|
|
384
|
+
planClear: string;
|
|
385
|
+
planInvalid: string;
|
|
160
386
|
gantt_active: string;
|
|
161
387
|
gantt_passive: string;
|
|
162
388
|
gantt_compact: string;
|
|
@@ -176,6 +402,7 @@ declare const en: {
|
|
|
176
402
|
};
|
|
177
403
|
options: {
|
|
178
404
|
scaleTitle: string;
|
|
405
|
+
scalePortions: string;
|
|
179
406
|
scaleGlobal: string;
|
|
180
407
|
scaleByIngredient: string;
|
|
181
408
|
selectIngredient: string;
|
|
@@ -186,6 +413,13 @@ declare const en: {
|
|
|
186
413
|
enableBakersMath: string;
|
|
187
414
|
bakersMathDesc: string;
|
|
188
415
|
hideAbsolute: string;
|
|
416
|
+
showComments: string;
|
|
417
|
+
commentsDesc: string;
|
|
418
|
+
showStepQuantities: string;
|
|
419
|
+
stepQuantitiesDesc: string;
|
|
420
|
+
nutritionBasis: string;
|
|
421
|
+
nutritionBasisAuto: string;
|
|
422
|
+
rejectedSlots: string;
|
|
189
423
|
forceReference: string;
|
|
190
424
|
autoDetect: string;
|
|
191
425
|
physicalAnalysis: string;
|
|
@@ -196,8 +430,38 @@ declare const en: {
|
|
|
196
430
|
stockTitle: string;
|
|
197
431
|
stockDesc: string;
|
|
198
432
|
};
|
|
433
|
+
help: {
|
|
434
|
+
schedule: string;
|
|
435
|
+
rests: string;
|
|
436
|
+
serveAt: string;
|
|
437
|
+
serveSuggestions: string;
|
|
438
|
+
timeZone: string;
|
|
439
|
+
availability: string;
|
|
440
|
+
scalePortions: string;
|
|
441
|
+
scaleGlobal: string;
|
|
442
|
+
scaleByIngredient: string;
|
|
443
|
+
bakersMath: string;
|
|
444
|
+
comments: string;
|
|
445
|
+
stepQuantities: string;
|
|
446
|
+
nutritionBasis: string;
|
|
447
|
+
bakersMathOnly: string;
|
|
448
|
+
bakersReference: string;
|
|
449
|
+
massStandardization: string;
|
|
450
|
+
yieldManagement: string;
|
|
451
|
+
nutrition: string;
|
|
452
|
+
/** The note of the "Schedule & Service" section: what these settings change in each view. */
|
|
453
|
+
scheduleNote: string;
|
|
454
|
+
scheduleNoteLink: string;
|
|
455
|
+
physicsDisclaimer: string;
|
|
456
|
+
stockItem: string;
|
|
457
|
+
};
|
|
199
458
|
output: {
|
|
200
459
|
copy: string;
|
|
460
|
+
print: string;
|
|
461
|
+
/** The tabs of the views of the recipe. */
|
|
462
|
+
views: string;
|
|
463
|
+
/** The tab of the inspectors (AST, JSON), apart from the views. */
|
|
464
|
+
inspect: string;
|
|
201
465
|
loading: string;
|
|
202
466
|
};
|
|
203
467
|
warnings: {
|
|
@@ -233,6 +497,8 @@ declare const en: {
|
|
|
233
497
|
editor: string;
|
|
234
498
|
preview: string;
|
|
235
499
|
};
|
|
500
|
+
fullscreen: string;
|
|
501
|
+
exitFullscreen: string;
|
|
236
502
|
analysisOptions: string;
|
|
237
503
|
analysis: string;
|
|
238
504
|
massNorm: string;
|
|
@@ -247,4 +513,11 @@ type GramLocale = typeof en;
|
|
|
247
513
|
|
|
248
514
|
declare function getDictionary(lang?: string): GramLocale;
|
|
249
515
|
|
|
250
|
-
|
|
516
|
+
/**
|
|
517
|
+
* A dictionary string with each `{name}` replaced from `values`
|
|
518
|
+
* ("Serve at {time}" → "Serve at 20:00"). A name with no value is left as
|
|
519
|
+
* written, so a missing value shows up instead of vanishing.
|
|
520
|
+
*/
|
|
521
|
+
declare function fillTemplate(template: string, values: Readonly<Record<string, string>>): string;
|
|
522
|
+
|
|
523
|
+
export { CATEGORY_KEYS, type CategoryKey, type CompiledDict, type GramLocale, type LanguageDict, TIME_BY_LANG, TIME_DICTIONARIES, TIME_GLOBAL, TIME_TO_MINUTES, UNIT_BY_LANG, UNIT_CONVERSIONS, UNIT_DICTIONARIES, UNIT_GLOBAL, type UnitMap, compileDictionary, fillTemplate, getAiLanguageInstruction, getCategoryLabels, getDefaultCategories, getDictionary, isCategoryKey, isCoarseUnit, normalizeUnit, resolveTimeUnit, unitKey };
|
package/dist/index.js
CHANGED
|
@@ -137,6 +137,14 @@ var fr2 = {
|
|
|
137
137
|
};
|
|
138
138
|
var UNIT_DICTIONARIES = { en: en2, fr: fr2 };
|
|
139
139
|
var { byLang: UNIT_BY_LANG, global: UNIT_GLOBAL } = compileDictionary(UNIT_DICTIONARIES);
|
|
140
|
+
function unitKey(raw) {
|
|
141
|
+
return raw.normalize("NFD").replace(/\p{M}/gu, "").toLowerCase().replace(/[.'’\s]/g, "");
|
|
142
|
+
}
|
|
143
|
+
var foldTable = (table) => Object.fromEntries(Object.entries(table).map(([k, v]) => [unitKey(k), v]));
|
|
144
|
+
var UNIT_BY_LANG_FOLDED = Object.fromEntries(
|
|
145
|
+
Object.entries(UNIT_BY_LANG).map(([lang, table]) => [lang, foldTable(table)])
|
|
146
|
+
);
|
|
147
|
+
var UNIT_GLOBAL_FOLDED = foldTable(UNIT_GLOBAL);
|
|
140
148
|
var UNIT_CONVERSIONS = {
|
|
141
149
|
mass: {
|
|
142
150
|
base: "g",
|
|
@@ -182,7 +190,9 @@ function normalizeUnit(rawUnit, lang) {
|
|
|
182
190
|
if (lang && UNIT_BY_LANG[lang]?.[clean]) {
|
|
183
191
|
return UNIT_BY_LANG[lang][clean];
|
|
184
192
|
}
|
|
185
|
-
|
|
193
|
+
if (UNIT_GLOBAL[clean]) return UNIT_GLOBAL[clean];
|
|
194
|
+
const key = unitKey(clean);
|
|
195
|
+
return lang && UNIT_BY_LANG_FOLDED[lang]?.[key] || UNIT_GLOBAL_FOLDED[key] || clean;
|
|
186
196
|
}
|
|
187
197
|
function isCoarseUnit(rawUnit) {
|
|
188
198
|
const normalized = normalizeUnit(rawUnit);
|
|
@@ -277,23 +287,174 @@ function getDefaultCategories(lang = "en") {
|
|
|
277
287
|
}
|
|
278
288
|
|
|
279
289
|
// src/locales/en.ts
|
|
290
|
+
var VIEWS_PAUSED = {
|
|
291
|
+
title: "Generation paused",
|
|
292
|
+
description: "The recipe contains blocking errors preventing preview generation."
|
|
293
|
+
};
|
|
280
294
|
var en3 = {
|
|
281
295
|
renderer: {
|
|
296
|
+
viewsPaused: VIEWS_PAUSED.title,
|
|
297
|
+
viewsPausedDescription: VIEWS_PAUSED.description,
|
|
298
|
+
/** What a surface offers next to paused views: jump to the error. */
|
|
299
|
+
showError: "Show the error",
|
|
300
|
+
/** An output the recipe has nothing for (a run sheet with nothing to schedule). */
|
|
301
|
+
outputEmpty: "Nothing to show for this recipe.",
|
|
302
|
+
/** The serving time controls of a view laid out in time (the editor's panel). */
|
|
303
|
+
serving: {
|
|
304
|
+
label: "Served at",
|
|
305
|
+
clear: "Clear",
|
|
306
|
+
clearTitle: "Back to the plan in days before the service",
|
|
307
|
+
suggest: "When to serve?",
|
|
308
|
+
none: "No serving time works in the next seven days.",
|
|
309
|
+
whyNot: "Why not the others?",
|
|
310
|
+
earliest: "Earliest: {when}"
|
|
311
|
+
},
|
|
312
|
+
/** The session controls of a view (the editor's panel): scale, baker's reference, stock. */
|
|
313
|
+
session: {
|
|
314
|
+
title: "Scale and stock",
|
|
315
|
+
scale: "Scale",
|
|
316
|
+
portions: "Portions",
|
|
317
|
+
byIngredient: "or by ingredient",
|
|
318
|
+
ingredient: "Choose an ingredient",
|
|
319
|
+
qty: "Quantity",
|
|
320
|
+
unit: "Unit",
|
|
321
|
+
apply: "Apply",
|
|
322
|
+
bakersReference: "Baker's reference",
|
|
323
|
+
auto: "Automatic (@*)",
|
|
324
|
+
stock: "In stock",
|
|
325
|
+
stockHint: "Already on hand: one shopping-list line, and its steps leave the plan.",
|
|
326
|
+
reset: "Reset",
|
|
327
|
+
scaled: "{factor} %",
|
|
328
|
+
inStock: "{n} in stock",
|
|
329
|
+
scaleError: "Scale not applied: {reason}"
|
|
330
|
+
},
|
|
331
|
+
/** The name of each output of the renderer (`outputs`), by its id. */
|
|
332
|
+
outputs: {
|
|
333
|
+
recipe: "Recipe",
|
|
334
|
+
runSheet: "Run sheet",
|
|
335
|
+
ast: "AST",
|
|
336
|
+
json: "JSON",
|
|
337
|
+
"json-tree": "JSON tree"
|
|
338
|
+
},
|
|
339
|
+
/** The name of each format a view can be written in (`FORMATS`). */
|
|
340
|
+
formats: {
|
|
341
|
+
html: "HTML",
|
|
342
|
+
markdown: "Markdown",
|
|
343
|
+
text: "Text",
|
|
344
|
+
print: "Print"
|
|
345
|
+
},
|
|
282
346
|
shoppingList: "Shopping List",
|
|
347
|
+
/** The ingredients a section uses, above its steps. */
|
|
348
|
+
ingredients: "Ingredients",
|
|
349
|
+
instructions: "Instructions",
|
|
350
|
+
/** The comments at the end of a line, gathered under the recipe. */
|
|
351
|
+
notes: "Notes",
|
|
352
|
+
/** Between the options of an alternative (`@butter|oil`). */
|
|
353
|
+
or: "or",
|
|
354
|
+
/** The head of the metadata block of the Markdown recipe. */
|
|
355
|
+
metadata: "Metadata",
|
|
356
|
+
/** Marks a composite ingredient (`@yolk<@egg`) in a list. */
|
|
357
|
+
composite: "Composite",
|
|
358
|
+
/** Under a composite in the shopping list, the share of the item used whole (`@egg{1}` next to `@yolk<@egg`). */
|
|
359
|
+
directUse: "Direct use",
|
|
360
|
+
/** The label of the total mass in the recipe's header. */
|
|
361
|
+
totalMass: "Total Mass",
|
|
362
|
+
incomplete: "Incomplete",
|
|
363
|
+
/** After a timer that is a passive wait, and the short mark of an alternative. */
|
|
364
|
+
passive: "passive",
|
|
365
|
+
alt: "alt",
|
|
366
|
+
unknownIngredient: "[Unknown Ingredient]",
|
|
367
|
+
unknownReference: "[Unknown Reference]",
|
|
368
|
+
/** The portions of the recipe (`portions:`), and once it is scaled. */
|
|
369
|
+
servings: "{count} portions",
|
|
370
|
+
servingsScaled: "{count} portions (\xD7{factor})",
|
|
371
|
+
/** The word after the portions stepper, by plural category (`Intl.PluralRules`). */
|
|
372
|
+
portionsUnit: { one: "portion", other: "portions" },
|
|
373
|
+
/** The badge of a scaled recipe in the hero bar ("×1.5"). */
|
|
374
|
+
scaledRecipe: "Scaled recipe",
|
|
375
|
+
/** The pencil button beside the portions, where the surface can change them. */
|
|
376
|
+
changePortions: "Change the portions",
|
|
283
377
|
cookware: "Cookware",
|
|
284
378
|
equipment: "Equipment",
|
|
285
379
|
nutrition: "Nutrition",
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
380
|
+
/** The units of a computed duration (`formatDuration`): "1d 2h", "1h 30min", "45s". */
|
|
381
|
+
durationUnits: { day: "d", hour: "h", minute: "min", second: "s" },
|
|
382
|
+
totalTime: "Total time",
|
|
383
|
+
idleTime: "Idle time",
|
|
384
|
+
activeTime: "Active time",
|
|
385
|
+
prepTime: "Prep time",
|
|
386
|
+
totalTimeTooltip: "Total time = prep + active + idle",
|
|
387
|
+
/** Under the total time's breakdown: where the hour-by-hour plan lives. */
|
|
388
|
+
totalTimeRunSheetHint: "For the hour-by-hour plan, see the {view}.",
|
|
389
|
+
activeTimeCardTooltip: "Active time = sum of manual work time",
|
|
390
|
+
prepTimeTooltip: "Prep time = time to gather and prepare ingredients and cookware",
|
|
391
|
+
miseEnPlace: "Mise en place",
|
|
392
|
+
scheduleLabel: "Mise en place",
|
|
393
|
+
restsLabel: "Waits",
|
|
394
|
+
restsShortest: "Shortest",
|
|
395
|
+
restsBalanced: "Middle",
|
|
396
|
+
restsLongest: "Longest",
|
|
397
|
+
schedulePerSection: "By section",
|
|
398
|
+
scheduleUpfront: "All at the start",
|
|
399
|
+
schedulePerDay: "By working day",
|
|
400
|
+
dayBefore: "D-",
|
|
401
|
+
dayToday: "Day D",
|
|
402
|
+
runSheetStep: "Step {n}",
|
|
403
|
+
runSheetRest: "Wait",
|
|
404
|
+
runSheetUnnamedSection: "Recipe",
|
|
405
|
+
runSheetProblems: "To fix",
|
|
406
|
+
runSheetOutside: "{task}, around {time}, falls when you are not available, and no wait can be moved to fix it.",
|
|
407
|
+
runSheetExceeds: "{task} takes {duration} without a break, more than your longest availability ({largest}): widen it.",
|
|
408
|
+
runSheetDayMismatch: "The work of {day} falls on {actual} instead of {expected}.",
|
|
409
|
+
runSheetPast: "The first task should have started {start}, and it is already {now}.",
|
|
410
|
+
runSheetMulti: "Only the first of {count} recipes is planned.",
|
|
411
|
+
runSheetTitle: "Run sheet",
|
|
412
|
+
runSheetFor: "For {date} at {time}",
|
|
413
|
+
runSheetDays: "{n} day",
|
|
414
|
+
runSheetDaysMany: "{n} days",
|
|
415
|
+
runSheetVisits: "{n} visit to the kitchen",
|
|
416
|
+
runSheetVisitsMany: "{n} visits to the kitchen",
|
|
417
|
+
runSheetWork: "{duration} of work in all",
|
|
418
|
+
runSheetServe: "Serve",
|
|
419
|
+
runSheetAbout: "~ {duration}",
|
|
420
|
+
runSheetKit: "To take out",
|
|
421
|
+
runSheetLegendCook: "in the kitchen",
|
|
422
|
+
runSheetLegendThread: "what goes on without you",
|
|
423
|
+
runSheetProgram: "To do",
|
|
424
|
+
runSheetExecution: "Execution",
|
|
425
|
+
runSheetIngredients: "Ingredients",
|
|
426
|
+
runSheetStart: "Start: {time}",
|
|
427
|
+
runSheetContinued: "continued",
|
|
428
|
+
runSheetLeaving: "Before leaving",
|
|
429
|
+
runSheetMadeOn: "made {day}",
|
|
430
|
+
runSheetMadeAt: "made at {time}",
|
|
431
|
+
runSheetMadeEarlier: "made earlier",
|
|
432
|
+
runSheetInStock: "in stock",
|
|
433
|
+
runSheetProgramStep: "step {n}",
|
|
434
|
+
runSheetProgramSteps: "steps {from} to {to}",
|
|
435
|
+
runSheetRange: "{min} to {max}",
|
|
436
|
+
runSheetPossibleFrom: "Possible from {time}.",
|
|
437
|
+
runSheetFixedService: "Can't start earlier: the \u201C{rest}\u201D wait ({section}) can't be longer than {length} and ends when you serve.",
|
|
438
|
+
runSheetFixedVisit: "Can't start earlier: the \u201C{rest}\u201D wait ({section}) can't be longer than {length} and must be over before {sections}.",
|
|
439
|
+
runSheetNextVisit: "Next visit: {when}",
|
|
440
|
+
runSheetNextVisitSameDay: "Next visit: later the same day",
|
|
441
|
+
runSheetServeAt: "Serve at {time}",
|
|
442
|
+
runSheetStretchedTo: "{wait} extended to {to} (planned {range}) so the work falls within your availability.",
|
|
443
|
+
runSheetShortenedTo: "{wait} shortened to {to} (planned {range}) so the work falls within your availability.",
|
|
444
|
+
runSheetUntilClock: "until {time}",
|
|
445
|
+
runSheetNothing: "Nothing to plan.",
|
|
446
|
+
runSheetFindOk: "{when} \u2014 start {start} \xB7 {visits} \xB7 {adjusted}",
|
|
447
|
+
runSheetFindRejected: "{when} \u2014 not possible. {reason}",
|
|
448
|
+
runSheetFindStart: "You would have to start {start}, which has passed.",
|
|
449
|
+
runSheetFindNone: "No serving time works between {from} and {to}.",
|
|
450
|
+
runSheetAdjusted: "{n} wait adjusted",
|
|
451
|
+
runSheetAdjustedMany: "{n} waits adjusted",
|
|
452
|
+
runSheetNoAdjustment: "no wait adjusted",
|
|
453
|
+
runSheetEarliest: "Ready as early as {when} if you start now.",
|
|
454
|
+
runSheetEarliestNone: "Nothing works in the next {days} days (searched until {until}).",
|
|
294
455
|
est: "(est.)",
|
|
295
456
|
passiveTimeTooltip: "Passive Time (Waiting, resting...)",
|
|
296
|
-
activeTimeTooltip: "Active
|
|
457
|
+
activeTimeTooltip: "Active time",
|
|
297
458
|
estimateTooltip: "Estimate",
|
|
298
459
|
coverageTooltip: "Coverage",
|
|
299
460
|
unknownCookware: "[Unknown Cookware]",
|
|
@@ -310,16 +471,28 @@ var en3 = {
|
|
|
310
471
|
breakdownPassive: "Passive",
|
|
311
472
|
breakdownTimer: "Timer",
|
|
312
473
|
breakdownPrep: "Preparation",
|
|
474
|
+
// What separates a label from its value: no space before the colon in English.
|
|
475
|
+
colon: ": ",
|
|
313
476
|
standardizedMass: "Standardized mass",
|
|
314
477
|
quantity: "Quantity",
|
|
315
|
-
intermediateIngredient: "Intermediate
|
|
478
|
+
intermediateIngredient: "Intermediate ingredient",
|
|
479
|
+
// The rows of the tooltip of an ingredient in a step.
|
|
480
|
+
tooltipMass: "Mass",
|
|
481
|
+
tooltipPreparation: "Preparation",
|
|
482
|
+
tooltipBakers: "Baker's %",
|
|
483
|
+
tooltipTakenFrom: "Taken from",
|
|
316
484
|
alternatives: "Alternatives",
|
|
485
|
+
// The deprecated portions stepper of the HTML recipe (`interactiveScaling`).
|
|
486
|
+
// @remove-in: 2.0.0 [renderer-interactive-scaling]
|
|
317
487
|
decreasePortions: "Decrease portions",
|
|
318
488
|
editPortions: "Edit portions directly",
|
|
319
489
|
increasePortions: "Increase portions",
|
|
320
490
|
returnToStep: "Return to step",
|
|
321
491
|
mixedUnitsTooltip: "Couldn't be combined into one total \u2014 add a density to the ingredient database to merge them",
|
|
322
492
|
mixedUnits: "Mixed units",
|
|
493
|
+
copyShoppingList: "Copy list",
|
|
494
|
+
copied: "Copied!",
|
|
495
|
+
toggleStepDone: "Toggle step completion",
|
|
323
496
|
purchasingWeight: "Purchasing Weight (including waste/peel)",
|
|
324
497
|
gross: "gross",
|
|
325
498
|
intermediateResult: "Intermediate result for this section",
|
|
@@ -327,6 +500,16 @@ var en3 = {
|
|
|
327
500
|
estimatedSuffix: " (Estimated)",
|
|
328
501
|
missingMass: " (Missing: ",
|
|
329
502
|
someIngredients: "some ingredients",
|
|
503
|
+
// The tooltip of a mass (the hero bar's total, a section's badge).
|
|
504
|
+
massTitle: "Ingredient mass, before cooking",
|
|
505
|
+
massSectionTitle: "Mass of this section's ingredients, before cooking",
|
|
506
|
+
massEstimated: "Estimated",
|
|
507
|
+
massEstimatedDetail: "converted with an average value",
|
|
508
|
+
massIncomplete: "Incomplete",
|
|
509
|
+
massIncompleteDetail: "no known mass",
|
|
510
|
+
massMethodDensity: "average density",
|
|
511
|
+
massMethodUnitWeight: "average unit weight",
|
|
512
|
+
massIncompleteHint: "Give these a weight in grams, or a density or unit weight in densities: or the ingredient database",
|
|
330
513
|
// Nutrition bases. Which one is shown is the renderer's
|
|
331
514
|
// `nutritionBasis` option; the analyzer computes all three.
|
|
332
515
|
nutritionWholeRecipe: "Whole recipe",
|
|
@@ -341,13 +524,23 @@ var en3 = {
|
|
|
341
524
|
nutritionRawMassNote: "Based on {mass} of ingredients, before cooking",
|
|
342
525
|
nutritionRawMassNotePartial: "Based on the {mass} with nutrition data, before cooking",
|
|
343
526
|
incompleteData: "Incomplete data",
|
|
527
|
+
/** Under the nutrition of the text format when a mass was estimated from a density. */
|
|
528
|
+
nutritionEstimated: "estimated values",
|
|
344
529
|
// One entry per key in @gram-lang/analyzer's NUTRIENTS table; the
|
|
345
530
|
// renderer test asserts the two stay in step. A sub-macro's label is
|
|
346
531
|
// prefixed with `ofWhich` at display time rather than baked in here,
|
|
347
532
|
// so the same string works standalone and nested.
|
|
533
|
+
// The nutrition table of the HTML recipe: salt is shown in place of
|
|
534
|
+
// sodium, and the reference intakes are the EU ones.
|
|
535
|
+
nutritionSalt: "Salt",
|
|
536
|
+
nutritionTableTitle: "Nutrition information",
|
|
537
|
+
nutritionReferenceIntake: "%RI",
|
|
538
|
+
nutritionReferenceIntakeNote: "Reference intake of an average adult (8,400 kJ / 2,000 kcal)",
|
|
539
|
+
nutritionNutrient: "Nutrient",
|
|
540
|
+
nutritionWholeRecipeTotal: "Whole recipe: {kcal}",
|
|
348
541
|
ofWhich: "of which",
|
|
349
542
|
nutrients: {
|
|
350
|
-
calories: "
|
|
543
|
+
calories: "Energy",
|
|
351
544
|
fat: "Fat",
|
|
352
545
|
sat_fat: "saturates",
|
|
353
546
|
mono_fat: "mono-unsaturates",
|
|
@@ -365,22 +558,78 @@ var en3 = {
|
|
|
365
558
|
inputTab: "Input (.gram)",
|
|
366
559
|
writePlaceholder: "Write your recipe here...",
|
|
367
560
|
outputTab: "Output",
|
|
561
|
+
// The label of the old view selector: the views are tabs now.
|
|
562
|
+
// @remove-in: 2.0.0 [i18n-playground-view-labels]
|
|
368
563
|
viewLabel: "View:",
|
|
564
|
+
formatLabel: "Format",
|
|
369
565
|
loadExample: "Load Example...",
|
|
370
566
|
recipe: "Recipe",
|
|
371
|
-
|
|
567
|
+
studioTitle: "Recipe settings",
|
|
568
|
+
settingsButton: "Settings",
|
|
569
|
+
settingsHint: {
|
|
570
|
+
text: "Adjust quantities, schedule service, customize the display\u2026 it all happens in Settings.",
|
|
571
|
+
dismiss: "Got it"
|
|
572
|
+
},
|
|
573
|
+
activeOptionsBadge: "{count} active",
|
|
574
|
+
resetAll: "Reset all",
|
|
575
|
+
resetSection: "Reset",
|
|
576
|
+
openScheduleSettings: "Adjust schedule",
|
|
577
|
+
scheduleButton: "Schedule",
|
|
578
|
+
sections: {
|
|
579
|
+
schedule: "Schedule",
|
|
580
|
+
scale: "Quantities",
|
|
581
|
+
bakersMath: "Baker's percentages",
|
|
582
|
+
display: "Display",
|
|
583
|
+
physics: "Nutrition and mass",
|
|
584
|
+
stock: "Stocked bases"
|
|
585
|
+
},
|
|
586
|
+
badges: {
|
|
587
|
+
default: "Default",
|
|
588
|
+
active: "Active",
|
|
589
|
+
inactive: "Inactive",
|
|
590
|
+
standardized: "Standardized",
|
|
591
|
+
nutritionActive: "Nutrition active",
|
|
592
|
+
byIngredient: "By ingredient",
|
|
593
|
+
inStock: "{count} in stock",
|
|
594
|
+
serveAt: "Served at {time}",
|
|
595
|
+
customHours: "Custom hours"
|
|
596
|
+
},
|
|
597
|
+
a11y: {
|
|
598
|
+
closeDrawer: "Close settings panel"
|
|
599
|
+
},
|
|
372
600
|
examples: {
|
|
373
601
|
newRecipe: "Blank (New Recipe)",
|
|
374
602
|
canneles: "Bordeaux Cannel\xE9s",
|
|
375
603
|
empanadas: "Beef Empanadas"
|
|
376
604
|
},
|
|
377
605
|
views: {
|
|
606
|
+
// The labels of the old view selector: the outputs are now named by
|
|
607
|
+
// `renderer.outputs`, and the formats by `renderer.formats`.
|
|
608
|
+
// @remove-in: 2.0.0 [i18n-playground-view-labels]
|
|
378
609
|
json: "JSON Output",
|
|
379
610
|
ast: "AST (Raw)",
|
|
380
611
|
jsonTree: "Interactive Tree",
|
|
381
612
|
markdown: "Markdown",
|
|
382
613
|
preview: "Preview (HTML)",
|
|
383
|
-
|
|
614
|
+
runSheet: "Run sheet",
|
|
615
|
+
serveWhenTitle: "When to serve?",
|
|
616
|
+
serveWhenNone: "No serving time works in the next seven days.",
|
|
617
|
+
serveWhenWhyNot: "Why not the others?",
|
|
618
|
+
earliestTitle: "Ready as early as",
|
|
619
|
+
earliestNone: "Nothing works in the next 14 days.",
|
|
620
|
+
earliestUse: "Serve then",
|
|
621
|
+
planSummary: "Plan",
|
|
622
|
+
planServeAt: "Serving time",
|
|
623
|
+
planTimeZone: "Time zone",
|
|
624
|
+
planAvailability: "Daily availability",
|
|
625
|
+
planSpecificHours: "Specific hours by day of the week",
|
|
626
|
+
planDayUnavailable: "Unavailable",
|
|
627
|
+
serveAtClear: "Clear",
|
|
628
|
+
serveAtClearTitle: "Clear serve time",
|
|
629
|
+
serveOtherSlots: "Other slots",
|
|
630
|
+
planClear: "Clear the plan",
|
|
631
|
+
planInvalid: "This plan can't be made: {message}",
|
|
632
|
+
// @remove-in: 2.0.0 [i18n-gantt-keys]
|
|
384
633
|
gantt_active: "Active Task",
|
|
385
634
|
gantt_passive: "Background Task",
|
|
386
635
|
gantt_compact: "Compact View",
|
|
@@ -400,6 +649,7 @@ var en3 = {
|
|
|
400
649
|
},
|
|
401
650
|
options: {
|
|
402
651
|
scaleTitle: "Modify Quantities",
|
|
652
|
+
scalePortions: "Portions",
|
|
403
653
|
scaleGlobal: "Overall Scale",
|
|
404
654
|
scaleByIngredient: "By Ingredient",
|
|
405
655
|
selectIngredient: "Select ingredient...",
|
|
@@ -410,6 +660,13 @@ var en3 = {
|
|
|
410
660
|
enableBakersMath: "Enable Baker's Math",
|
|
411
661
|
bakersMathDesc: "Shows ingredients as % of reference.",
|
|
412
662
|
hideAbsolute: "Hide absolute weights",
|
|
663
|
+
showComments: "Show comments",
|
|
664
|
+
commentsDesc: "The notes of the recipe (// like this), in the recipe and in the run sheet.",
|
|
665
|
+
showStepQuantities: "Quantities in the steps",
|
|
666
|
+
stepQuantitiesDesc: "Writes the quantity of each ingredient in the text of the steps, after its name.",
|
|
667
|
+
nutritionBasis: "Nutrition basis",
|
|
668
|
+
nutritionBasisAuto: "Automatic (every basis, side by side)",
|
|
669
|
+
rejectedSlots: "Unavailable slots:",
|
|
413
670
|
forceReference: "Force Reference:",
|
|
414
671
|
autoDetect: "Auto (detect @*)",
|
|
415
672
|
physicalAnalysis: "Physical Analysis",
|
|
@@ -420,8 +677,38 @@ var en3 = {
|
|
|
420
677
|
stockTitle: "Stock (skip steps)",
|
|
421
678
|
stockDesc: "Treat as already on hand \u2014 collapses to one shopping-list line, no timeline steps."
|
|
422
679
|
},
|
|
680
|
+
help: {
|
|
681
|
+
schedule: "Controls when ingredient prep and weighing take place in the schedule: right before each section, all upfront at the start of the recipe, or at the beginning of each working day.",
|
|
682
|
+
rests: "Sets the target duration for steps with a flexible time range (e.g. 2h to 12h): the minimum required time, the maximum allowed time, or a balanced midpoint.",
|
|
683
|
+
serveAt: "Target meal date and time. The schedule is calculated backwards from this deadline to tell you when to start and be ready right on time.",
|
|
684
|
+
serveSuggestions: "Recommended serving times. Gram evaluates rest ranges and your kitchen hours to suggest feasible meal times that require no overnight work.",
|
|
685
|
+
timeZone: "Sets the time zone used to display exact clock times on the run sheet and accurately handle day transitions.",
|
|
686
|
+
availability: "Your daily kitchen hours. The schedule organizes tasks so you never have to cook outside this window (such as overnight).",
|
|
687
|
+
scalePortions: "Sets how many portions the recipe makes: every quantity follows. The same as the overall scale, counted in portions.",
|
|
688
|
+
scaleGlobal: "Adjusts all ingredient quantities and portions according to the specified percentage (e.g. 200% to double, 50% to halve).",
|
|
689
|
+
scaleByIngredient: "Proportionally recalculates the entire recipe to match the exact quantity you have on hand for a specific ingredient (e.g. only 3 eggs or 250g of butter).",
|
|
690
|
+
bakersMath: "Expresses each ingredient as a percentage of a base ingredient set at 100% (typically flour, or any chosen ingredient), making ratios and formulation easy to evaluate.",
|
|
691
|
+
comments: "Shows or leaves out the comments written in the recipe with //: the notes alone on a line and the ones at the end of a line. They are set apart discreetly in the run sheet.",
|
|
692
|
+
stepQuantities: "Writes each quantity in the step that uses it, with its weight in grams when the masses are standardized. Leave it off for shorter steps: the quantities stay in the ingredient lists.",
|
|
693
|
+
nutritionBasis: "Which basis the nutrition panel shows, when the nutrition is estimated. Automatic shows per 100 g and per portion side by side, with the whole recipe under them, in every recipe format.",
|
|
694
|
+
bakersMathOnly: "Hides gram weights to display only relative percentages, turning the recipe into a pure ratio formula.",
|
|
695
|
+
bakersReference: "Manually selects which ingredient serves as the 100% baseline, overriding automatic detection of the @* ingredient in the recipe.",
|
|
696
|
+
massStandardization: "Converts volume measurements (spoons, cups, ml) into grams according to the database densities.",
|
|
697
|
+
yieldManagement: "Calculates gross purchasing weight to obtain the desired net quantity, accounting for peeling and trimming waste in the database.",
|
|
698
|
+
nutrition: "Estimates calories and macronutrients (protein, carbs, fat, fiber) per serving or per 100g via the nutritional tables in the database.",
|
|
699
|
+
/** The note of the "Schedule & Service" section: what these settings change in each view. */
|
|
700
|
+
scheduleNote: "These settings mostly shape the run sheet. In the recipe, only the total and idle times change.",
|
|
701
|
+
scheduleNoteLink: "See the run sheet",
|
|
702
|
+
physicsDisclaimer: "In this playground, physical and nutritional calculations rely on an ingredient database limited to example recipes.",
|
|
703
|
+
stockItem: "Marks this imported preparation as already on hand in your kitchen. Its prep steps are removed from the schedule, keeping only its final use."
|
|
704
|
+
},
|
|
423
705
|
output: {
|
|
424
706
|
copy: "Copy to clipboard",
|
|
707
|
+
print: "Print this view",
|
|
708
|
+
/** The tabs of the views of the recipe. */
|
|
709
|
+
views: "Views",
|
|
710
|
+
/** The tab of the inspectors (AST, JSON), apart from the views. */
|
|
711
|
+
inspect: "Inspect",
|
|
425
712
|
loading: "Loading viewer..."
|
|
426
713
|
},
|
|
427
714
|
warnings: {
|
|
@@ -438,8 +725,8 @@ var en3 = {
|
|
|
438
725
|
collapseConsole: "Collapse console"
|
|
439
726
|
},
|
|
440
727
|
errorState: {
|
|
441
|
-
title:
|
|
442
|
-
blockingDescription:
|
|
728
|
+
title: VIEWS_PAUSED.title,
|
|
729
|
+
blockingDescription: VIEWS_PAUSED.description,
|
|
443
730
|
jumpToError: "Jump to error",
|
|
444
731
|
line: "Line"
|
|
445
732
|
},
|
|
@@ -457,6 +744,8 @@ var en3 = {
|
|
|
457
744
|
editor: "Editor",
|
|
458
745
|
preview: "Preview"
|
|
459
746
|
},
|
|
747
|
+
fullscreen: "Fullscreen",
|
|
748
|
+
exitFullscreen: "Exit fullscreen",
|
|
460
749
|
analysisOptions: "Analysis Options",
|
|
461
750
|
analysis: "Analysis",
|
|
462
751
|
massNorm: "Mass Normalization",
|
|
@@ -469,20 +758,151 @@ var en3 = {
|
|
|
469
758
|
};
|
|
470
759
|
|
|
471
760
|
// src/locales/fr.ts
|
|
761
|
+
var VIEWS_PAUSED2 = {
|
|
762
|
+
title: "G\xE9n\xE9ration interrompue",
|
|
763
|
+
description: "La recette contient des erreurs bloquantes emp\xEAchant la g\xE9n\xE9ration de l'aper\xE7u."
|
|
764
|
+
};
|
|
472
765
|
var fr3 = {
|
|
473
766
|
renderer: {
|
|
767
|
+
viewsPaused: VIEWS_PAUSED2.title,
|
|
768
|
+
viewsPausedDescription: VIEWS_PAUSED2.description,
|
|
769
|
+
showError: "Voir l'erreur",
|
|
770
|
+
outputEmpty: "Rien \xE0 afficher pour cette recette.",
|
|
771
|
+
serving: {
|
|
772
|
+
label: "Service le",
|
|
773
|
+
clear: "Effacer",
|
|
774
|
+
clearTitle: "Revenir au plan de marche en jours avant le service",
|
|
775
|
+
suggest: "Quand servir ?",
|
|
776
|
+
none: "Aucune heure de service ne convient dans les sept prochains jours.",
|
|
777
|
+
whyNot: "Pourquoi pas les autres ?",
|
|
778
|
+
earliest: "Au plus t\xF4t : {when}"
|
|
779
|
+
},
|
|
780
|
+
session: {
|
|
781
|
+
title: "\xC9chelle et stock",
|
|
782
|
+
scale: "\xC9chelle",
|
|
783
|
+
portions: "Portions",
|
|
784
|
+
byIngredient: "ou par ingr\xE9dient",
|
|
785
|
+
ingredient: "Choisir un ingr\xE9dient",
|
|
786
|
+
qty: "Quantit\xE9",
|
|
787
|
+
unit: "Unit\xE9",
|
|
788
|
+
apply: "Appliquer",
|
|
789
|
+
bakersReference: "R\xE9f\xE9rence boulang\xE8re",
|
|
790
|
+
auto: "Automatique (@*)",
|
|
791
|
+
stock: "En stock",
|
|
792
|
+
stockHint: "D\xE9j\xE0 pr\xEAt : une seule ligne d'achat, et ses \xE9tapes quittent le plan de marche.",
|
|
793
|
+
reset: "R\xE9initialiser",
|
|
794
|
+
scaled: "{factor} %",
|
|
795
|
+
inStock: "{n} en stock",
|
|
796
|
+
scaleError: "\xC9chelle non appliqu\xE9e : {reason}"
|
|
797
|
+
},
|
|
798
|
+
outputs: {
|
|
799
|
+
recipe: "Recette",
|
|
800
|
+
runSheet: "Plan de marche",
|
|
801
|
+
ast: "AST",
|
|
802
|
+
json: "JSON",
|
|
803
|
+
"json-tree": "Arbre JSON"
|
|
804
|
+
},
|
|
805
|
+
formats: {
|
|
806
|
+
html: "HTML",
|
|
807
|
+
markdown: "Markdown",
|
|
808
|
+
text: "Texte",
|
|
809
|
+
print: "Impression"
|
|
810
|
+
},
|
|
474
811
|
shoppingList: "Liste de courses",
|
|
812
|
+
ingredients: "Ingr\xE9dients",
|
|
813
|
+
instructions: "\xC9tapes",
|
|
814
|
+
notes: "Notes",
|
|
815
|
+
or: "ou",
|
|
816
|
+
metadata: "M\xE9tadonn\xE9es",
|
|
817
|
+
composite: "Composite",
|
|
818
|
+
directUse: "Utilisation directe",
|
|
819
|
+
totalMass: "Masse totale",
|
|
820
|
+
incomplete: "Incomplet",
|
|
821
|
+
passive: "passif",
|
|
822
|
+
alt: "alt.",
|
|
823
|
+
unknownIngredient: "[Ingr\xE9dient inconnu]",
|
|
824
|
+
unknownReference: "[R\xE9f\xE9rence inconnue]",
|
|
825
|
+
servings: "{count} portions",
|
|
826
|
+
servingsScaled: "{count} portions (\xD7{factor})",
|
|
827
|
+
portionsUnit: { one: "portion", other: "portions" },
|
|
828
|
+
scaledRecipe: "Recette mise \xE0 l'\xE9chelle",
|
|
829
|
+
changePortions: "Modifier les portions",
|
|
475
830
|
cookware: "Mat\xE9riel",
|
|
476
831
|
equipment: "\xC9quipement",
|
|
477
832
|
nutrition: "Nutrition",
|
|
478
|
-
|
|
833
|
+
durationUnits: { day: "j", hour: "h", minute: "min", second: "s" },
|
|
834
|
+
totalTime: "Temps total",
|
|
479
835
|
idleTime: "Attente",
|
|
480
836
|
activeTime: "Actif",
|
|
481
837
|
prepTime: "Pr\xE9paration",
|
|
482
|
-
totalTimeTooltip: "Temps
|
|
483
|
-
|
|
484
|
-
activeTimeCardTooltip: "Temps
|
|
485
|
-
prepTimeTooltip: "Pr\xE9paration =
|
|
838
|
+
totalTimeTooltip: "Temps total = pr\xE9paration + actif + attente",
|
|
839
|
+
totalTimeRunSheetHint: "Le d\xE9roul\xE9 heure par heure est dans le {view}.",
|
|
840
|
+
activeTimeCardTooltip: "Temps actif = somme des temps de manipulation manuelle",
|
|
841
|
+
prepTimeTooltip: "Pr\xE9paration = temps pour rassembler et pr\xE9parer ingr\xE9dients et ustensiles",
|
|
842
|
+
miseEnPlace: "Mise en place",
|
|
843
|
+
scheduleLabel: "Mise en place",
|
|
844
|
+
restsLabel: "Attentes",
|
|
845
|
+
restsShortest: "Les plus courtes",
|
|
846
|
+
restsBalanced: "Au milieu",
|
|
847
|
+
restsLongest: "Les plus longues",
|
|
848
|
+
schedulePerSection: "Par section",
|
|
849
|
+
scheduleUpfront: "Tout au d\xE9but",
|
|
850
|
+
schedulePerDay: "Par journ\xE9e de travail",
|
|
851
|
+
dayBefore: "J-",
|
|
852
|
+
dayToday: "Jour J",
|
|
853
|
+
runSheetStep: "\xC9tape {n}",
|
|
854
|
+
runSheetRest: "Attente",
|
|
855
|
+
runSheetUnnamedSection: "Recette",
|
|
856
|
+
runSheetProblems: "\xC0 r\xE9gler",
|
|
857
|
+
runSheetOutside: "{task}, vers {time}, tombe quand vous n'\xEAtes pas disponible, et aucune attente ne peut bouger pour arranger \xE7a.",
|
|
858
|
+
runSheetExceeds: "{task} dure {duration} sans pause, plus que votre plus longue disponibilit\xE9 ({largest}) : \xE9largissez-la.",
|
|
859
|
+
runSheetDayMismatch: "Le travail de {day} tombe le {actual} au lieu du {expected}.",
|
|
860
|
+
runSheetPast: "La premi\xE8re t\xE2che aurait d\xFB commencer {start}, et nous sommes d\xE9j\xE0 {now}.",
|
|
861
|
+
runSheetMulti: "Seule la premi\xE8re des {count} recettes est planifi\xE9e.",
|
|
862
|
+
runSheetTitle: "Plan de marche",
|
|
863
|
+
runSheetFor: "Pour le {date} \xE0 {time}",
|
|
864
|
+
runSheetDays: "{n} jour",
|
|
865
|
+
runSheetDaysMany: "{n} jours",
|
|
866
|
+
runSheetVisits: "{n} passage en cuisine",
|
|
867
|
+
runSheetVisitsMany: "{n} passages en cuisine",
|
|
868
|
+
runSheetWork: "{duration} de travail en tout",
|
|
869
|
+
runSheetServe: "Servir",
|
|
870
|
+
runSheetAbout: "~ {duration}",
|
|
871
|
+
runSheetKit: "\xC0 sortir",
|
|
872
|
+
runSheetLegendCook: "en cuisine",
|
|
873
|
+
runSheetLegendThread: "ce qui continue sans vous",
|
|
874
|
+
runSheetProgram: "Au programme",
|
|
875
|
+
runSheetExecution: "Ex\xE9cution",
|
|
876
|
+
runSheetIngredients: "Ingr\xE9dients",
|
|
877
|
+
runSheetStart: "D\xE9but : {time}",
|
|
878
|
+
runSheetContinued: "suite",
|
|
879
|
+
runSheetLeaving: "En partant",
|
|
880
|
+
runSheetMadeOn: "fait {day}",
|
|
881
|
+
runSheetMadeAt: "fait \xE0 {time}",
|
|
882
|
+
runSheetMadeEarlier: "fait plus t\xF4t",
|
|
883
|
+
runSheetInStock: "en stock",
|
|
884
|
+
runSheetProgramStep: "\xE9tape {n}",
|
|
885
|
+
runSheetProgramSteps: "\xE9tapes {from} \xE0 {to}",
|
|
886
|
+
runSheetRange: "{min} \xE0 {max}",
|
|
887
|
+
runSheetPossibleFrom: "Possible d\xE8s {time}.",
|
|
888
|
+
runSheetFixedService: "D\xE9but non avan\xE7able : l'attente \xAB {rest} \xBB ({section}) ne peut pas d\xE9passer {length} et se termine au service.",
|
|
889
|
+
runSheetFixedVisit: "D\xE9but non avan\xE7able : l'attente \xAB {rest} \xBB ({section}) ne peut pas d\xE9passer {length} et doit \xEAtre termin\xE9e avant {sections}.",
|
|
890
|
+
runSheetNextVisit: "Prochain passage : {when}",
|
|
891
|
+
runSheetNextVisitSameDay: "Prochain passage : plus tard le m\xEAme jour",
|
|
892
|
+
runSheetServeAt: "Servir \xE0 {time}",
|
|
893
|
+
runSheetStretchedTo: "{wait} prolong\xE9 \xE0 {to} (pr\xE9vu {range}) pour que le travail tombe dans vos disponibilit\xE9s.",
|
|
894
|
+
runSheetShortenedTo: "{wait} raccourci \xE0 {to} (pr\xE9vu {range}) pour que le travail tombe dans vos disponibilit\xE9s.",
|
|
895
|
+
runSheetUntilClock: "jusqu'\xE0 {time}",
|
|
896
|
+
runSheetNothing: "Rien \xE0 planifier.",
|
|
897
|
+
runSheetFindOk: "{when} \u2014 d\xE9but {start} \xB7 {visits} \xB7 {adjusted}",
|
|
898
|
+
runSheetFindRejected: "{when} \u2014 impossible. {reason}",
|
|
899
|
+
runSheetFindStart: "Il faudrait commencer {start}, c'est d\xE9j\xE0 pass\xE9.",
|
|
900
|
+
runSheetFindNone: "Aucune heure de service ne convient entre {from} et {to}.",
|
|
901
|
+
runSheetAdjusted: "{n} attente ajust\xE9e",
|
|
902
|
+
runSheetAdjustedMany: "{n} attentes ajust\xE9es",
|
|
903
|
+
runSheetNoAdjustment: "aucune attente ajust\xE9e",
|
|
904
|
+
runSheetEarliest: "Pr\xEAt d\xE8s {when} si vous commencez maintenant.",
|
|
905
|
+
runSheetEarliestNone: "Rien ne convient dans les {days} prochains jours (cherch\xE9 jusqu'au {until}).",
|
|
486
906
|
est: "(est.)",
|
|
487
907
|
passiveTimeTooltip: "Temps passif (Repos, attente...)",
|
|
488
908
|
activeTimeTooltip: "Temps actif",
|
|
@@ -502,16 +922,28 @@ var fr3 = {
|
|
|
502
922
|
breakdownPassive: "Passif",
|
|
503
923
|
breakdownTimer: "Minuteur",
|
|
504
924
|
breakdownPrep: "Pr\xE9paration",
|
|
925
|
+
// What separates a label from its value: a space before the colon in French.
|
|
926
|
+
colon: " : ",
|
|
505
927
|
standardizedMass: "Masse standardis\xE9e",
|
|
506
928
|
quantity: "Quantit\xE9",
|
|
507
929
|
intermediateIngredient: "Ingr\xE9dient interm\xE9diaire",
|
|
930
|
+
// Les lignes de la bulle d'un ingrédient dans une étape.
|
|
931
|
+
tooltipMass: "Masse",
|
|
932
|
+
tooltipPreparation: "Pr\xE9paration",
|
|
933
|
+
tooltipBakers: "% boulanger",
|
|
934
|
+
tooltipTakenFrom: "Pr\xE9lev\xE9 sur",
|
|
508
935
|
alternatives: "Alternatives",
|
|
936
|
+
// The deprecated portions stepper of the HTML recipe (`interactiveScaling`).
|
|
937
|
+
// @remove-in: 2.0.0 [renderer-interactive-scaling]
|
|
509
938
|
decreasePortions: "Diminuer les portions",
|
|
510
939
|
editPortions: "Modifier directement les portions",
|
|
511
940
|
increasePortions: "Augmenter les portions",
|
|
512
941
|
returnToStep: "Retour \xE0 l'\xE9tape",
|
|
513
942
|
mixedUnitsTooltip: "Impossible de fusionner en un seul total \u2014 ajoutez une densit\xE9 \xE0 la base de donn\xE9es pour les convertir",
|
|
514
943
|
mixedUnits: "Unit\xE9s mixtes",
|
|
944
|
+
copyShoppingList: "Copier la liste",
|
|
945
|
+
copied: "Copi\xE9 !",
|
|
946
|
+
toggleStepDone: "Marquer l'\xE9tape comme termin\xE9e",
|
|
515
947
|
purchasingWeight: "Poids d'achat (incluant d\xE9chets/\xE9pluchures)",
|
|
516
948
|
gross: "brut",
|
|
517
949
|
intermediateResult: "R\xE9sultat interm\xE9diaire pour cette section",
|
|
@@ -519,15 +951,34 @@ var fr3 = {
|
|
|
519
951
|
estimatedSuffix: " (Estim\xE9)",
|
|
520
952
|
missingMass: " (Manquant : ",
|
|
521
953
|
someIngredients: "certains ingr\xE9dients",
|
|
954
|
+
// La bulle d'une masse (le total de la barre, le badge d'une section).
|
|
955
|
+
massTitle: "Masse des ingr\xE9dients, avant cuisson",
|
|
956
|
+
massSectionTitle: "Masse des ingr\xE9dients de cette section, avant cuisson",
|
|
957
|
+
massEstimated: "Estim\xE9e",
|
|
958
|
+
massEstimatedDetail: "convertis avec une valeur moyenne",
|
|
959
|
+
massIncomplete: "Incompl\xE8te",
|
|
960
|
+
massIncompleteDetail: "masse inconnue",
|
|
961
|
+
massMethodDensity: "densit\xE9 moyenne",
|
|
962
|
+
massMethodUnitWeight: "poids moyen \xE0 l'unit\xE9",
|
|
963
|
+
massIncompleteHint: "Indique leur poids en grammes, ou une densit\xE9 ou un poids \xE0 l'unit\xE9 dans densities: ou la base d'ingr\xE9dients",
|
|
522
964
|
nutritionWholeRecipe: "Recette enti\xE8re",
|
|
523
965
|
nutritionPerPortion: "Par portion",
|
|
524
966
|
nutritionPer100g: "Pour 100 g",
|
|
525
967
|
nutritionRawMassNote: "Sur {mass} d'ingr\xE9dients, avant cuisson",
|
|
526
968
|
nutritionRawMassNotePartial: "Sur les {mass} renseign\xE9s, avant cuisson",
|
|
527
969
|
incompleteData: "Donn\xE9es incompl\xE8tes",
|
|
970
|
+
nutritionEstimated: "valeurs estim\xE9es",
|
|
971
|
+
// The nutrition table of the HTML recipe: salt is shown in place of
|
|
972
|
+
// sodium, and the reference intakes are the EU ones.
|
|
973
|
+
nutritionSalt: "Sel",
|
|
974
|
+
nutritionTableTitle: "Valeurs nutritionnelles",
|
|
975
|
+
nutritionReferenceIntake: "%AR",
|
|
976
|
+
nutritionReferenceIntakeNote: "Apport de r\xE9f\xE9rence pour un adulte type (8 400 kJ / 2 000 kcal)",
|
|
977
|
+
nutritionNutrient: "Nutriment",
|
|
978
|
+
nutritionWholeRecipeTotal: "Recette enti\xE8re : {kcal}",
|
|
528
979
|
ofWhich: "dont",
|
|
529
980
|
nutrients: {
|
|
530
|
-
calories: "
|
|
981
|
+
calories: "\xC9nergie",
|
|
531
982
|
fat: "Mati\xE8res grasses",
|
|
532
983
|
sat_fat: "acides gras satur\xE9s",
|
|
533
984
|
mono_fat: "acides gras mono-insatur\xE9s",
|
|
@@ -545,22 +996,75 @@ var fr3 = {
|
|
|
545
996
|
inputTab: "Entr\xE9e (.gram)",
|
|
546
997
|
writePlaceholder: "\xC9crivez votre recette ici...",
|
|
547
998
|
outputTab: "Sortie",
|
|
999
|
+
// @remove-in: 2.0.0 [i18n-playground-view-labels]
|
|
548
1000
|
viewLabel: "Vue :",
|
|
1001
|
+
formatLabel: "Format",
|
|
549
1002
|
loadExample: "Charger un exemple...",
|
|
550
1003
|
recipe: "Recette",
|
|
551
|
-
|
|
1004
|
+
studioTitle: "R\xE9glages de la recette",
|
|
1005
|
+
settingsButton: "R\xE9glages",
|
|
1006
|
+
settingsHint: {
|
|
1007
|
+
text: "Ajuster les quantit\xE9s, planifier le service, personnaliser l'affichage\u2026 tout se passe dans les r\xE9glages.",
|
|
1008
|
+
dismiss: "Compris"
|
|
1009
|
+
},
|
|
1010
|
+
activeOptionsBadge: "{count} actifs",
|
|
1011
|
+
resetAll: "R\xE9initialiser tout",
|
|
1012
|
+
resetSection: "R\xE9initialiser",
|
|
1013
|
+
openScheduleSettings: "Ajuster la planification",
|
|
1014
|
+
scheduleButton: "Planifier",
|
|
1015
|
+
sections: {
|
|
1016
|
+
schedule: "Planification",
|
|
1017
|
+
scale: "Quantit\xE9s",
|
|
1018
|
+
bakersMath: "Pourcentages boulangers",
|
|
1019
|
+
display: "Affichage",
|
|
1020
|
+
physics: "Nutrition et masses",
|
|
1021
|
+
stock: "Bases en stock"
|
|
1022
|
+
},
|
|
1023
|
+
badges: {
|
|
1024
|
+
default: "Par d\xE9faut",
|
|
1025
|
+
active: "Actif",
|
|
1026
|
+
inactive: "Inactif",
|
|
1027
|
+
standardized: "Standardis\xE9",
|
|
1028
|
+
nutritionActive: "Nutrition active",
|
|
1029
|
+
byIngredient: "Par ingr\xE9dient",
|
|
1030
|
+
inStock: "{count} en stock",
|
|
1031
|
+
serveAt: "Service \xE0 {time}",
|
|
1032
|
+
customHours: "Horaires personnalis\xE9s"
|
|
1033
|
+
},
|
|
1034
|
+
a11y: {
|
|
1035
|
+
closeDrawer: "Fermer le panneau des r\xE9glages"
|
|
1036
|
+
},
|
|
552
1037
|
examples: {
|
|
553
1038
|
newRecipe: "Vide (Nouvelle recette)",
|
|
554
1039
|
canneles: "Cannel\xE9s Bordelais",
|
|
555
1040
|
empanadas: "Empanadas de Boeuf"
|
|
556
1041
|
},
|
|
557
1042
|
views: {
|
|
1043
|
+
// @remove-in: 2.0.0 [i18n-playground-view-labels]
|
|
558
1044
|
json: "Sortie JSON",
|
|
559
1045
|
ast: "AST (Brut)",
|
|
560
1046
|
jsonTree: "Arbre Interactif",
|
|
561
1047
|
markdown: "Markdown",
|
|
562
1048
|
preview: "Aper\xE7u (HTML)",
|
|
563
|
-
|
|
1049
|
+
runSheet: "Plan de marche",
|
|
1050
|
+
serveWhenTitle: "Quand servir ?",
|
|
1051
|
+
serveWhenNone: "Aucune heure de service ne convient dans les sept prochains jours.",
|
|
1052
|
+
serveWhenWhyNot: "Pourquoi pas les autres ?",
|
|
1053
|
+
earliestTitle: "Pr\xEAt d\xE8s",
|
|
1054
|
+
earliestNone: "Rien ne convient dans les 14 prochains jours.",
|
|
1055
|
+
earliestUse: "Servir \xE0 ce moment",
|
|
1056
|
+
planSummary: "Plan",
|
|
1057
|
+
planServeAt: "Heure de service",
|
|
1058
|
+
planTimeZone: "Fuseau horaire",
|
|
1059
|
+
planAvailability: "Disponibilit\xE9 quotidienne",
|
|
1060
|
+
planSpecificHours: "Horaires sp\xE9cifiques par jour",
|
|
1061
|
+
planDayUnavailable: "Indisponible",
|
|
1062
|
+
serveAtClear: "Effacer",
|
|
1063
|
+
serveAtClearTitle: "Effacer la date de service",
|
|
1064
|
+
serveOtherSlots: "Autres cr\xE9neaux",
|
|
1065
|
+
planClear: "Effacer le plan",
|
|
1066
|
+
planInvalid: "Ce plan est impossible \xE0 faire : {message}",
|
|
1067
|
+
// @remove-in: 2.0.0 [i18n-gantt-keys]
|
|
564
1068
|
gantt_active: "T\xE2che active",
|
|
565
1069
|
gantt_passive: "T\xE2che de fond",
|
|
566
1070
|
gantt_compact: "Vue compacte",
|
|
@@ -580,6 +1084,7 @@ var fr3 = {
|
|
|
580
1084
|
},
|
|
581
1085
|
options: {
|
|
582
1086
|
scaleTitle: "Modifier les quantit\xE9s",
|
|
1087
|
+
scalePortions: "Portions",
|
|
583
1088
|
scaleGlobal: "Au global",
|
|
584
1089
|
scaleByIngredient: "Par ingr\xE9dient",
|
|
585
1090
|
selectIngredient: "S\xE9lectionner un ingr\xE9dient...",
|
|
@@ -590,6 +1095,13 @@ var fr3 = {
|
|
|
590
1095
|
enableBakersMath: "Activer le pourcentage du boulanger",
|
|
591
1096
|
bakersMathDesc: "Affiche les ingr\xE9dients en % de la r\xE9f\xE9rence.",
|
|
592
1097
|
hideAbsolute: "Masquer les poids absolus",
|
|
1098
|
+
showComments: "Afficher les commentaires",
|
|
1099
|
+
commentsDesc: "Les notes de la recette (// comme ceci), dans la recette et dans le plan de marche.",
|
|
1100
|
+
showStepQuantities: "Quantit\xE9s dans les \xE9tapes",
|
|
1101
|
+
stepQuantitiesDesc: "\xC9crit la quantit\xE9 de chaque ingr\xE9dient dans le texte des \xE9tapes, juste apr\xE8s son nom.",
|
|
1102
|
+
nutritionBasis: "Base nutritionnelle",
|
|
1103
|
+
nutritionBasisAuto: "Automatique (toutes les bases c\xF4te \xE0 c\xF4te)",
|
|
1104
|
+
rejectedSlots: "Cr\xE9neaux non retenus :",
|
|
593
1105
|
forceReference: "Forcer la r\xE9f\xE9rence :",
|
|
594
1106
|
autoDetect: "Auto (d\xE9tecte @*)",
|
|
595
1107
|
physicalAnalysis: "Analyse physique",
|
|
@@ -600,8 +1112,35 @@ var fr3 = {
|
|
|
600
1112
|
stockTitle: "En stock (masquer les \xE9tapes)",
|
|
601
1113
|
stockDesc: "Consid\xE9r\xE9 comme d\xE9j\xE0 disponible \u2014 se r\xE9duit \xE0 une ligne d'achat, sans \xE9tapes sur la frise."
|
|
602
1114
|
},
|
|
1115
|
+
help: {
|
|
1116
|
+
schedule: "D\xE9termine \xE0 quel moment pr\xE9parer et peser les ingr\xE9dients dans le plan de marche : au fur et \xE0 mesure de chaque section, regroup\xE9 tout au d\xE9but de la recette, ou au d\xE9marrage de chaque journ\xE9e de travail.",
|
|
1117
|
+
rests: "D\xE9termine la dur\xE9e retenue pour les \xE9tapes qui acceptent une plage de temps (ex. 2h \xE0 12h) : la dur\xE9e minimale requise, la dur\xE9e maximale autoris\xE9e, ou une valeur m\xE9diane \xE9quilibr\xE9e.",
|
|
1118
|
+
serveAt: "Date et heure souhait\xE9es du repas. Le plan de marche est calcul\xE9 \xE0 rebours \xE0 partir de cette \xE9ch\xE9ance pour vous indiquer quand d\xE9marrer et \xEAtre pr\xEAt pile \xE0 l'heure.",
|
|
1119
|
+
serveSuggestions: "Horaires recommand\xE9s pour passer \xE0 table. Gram explore les plages de repos et vos disponibilit\xE9s pour vous proposer des cr\xE9neaux r\xE9alistes sans action nocturne.",
|
|
1120
|
+
timeZone: "D\xE9finit le fuseau horaire utilis\xE9 pour afficher les heures exactes sur le plan de marche et g\xE9rer correctement les passages de journ\xE9e.",
|
|
1121
|
+
availability: "Vos horaires de disponibilit\xE9 en cuisine. Le plan de marche s'organise pour que vous n'ayez rien \xE0 faire en dehors de cette plage (la nuit par exemple).",
|
|
1122
|
+
scalePortions: "Indique le nombre de portions voulu : toutes les quantit\xE9s suivent. C'est l'\xE9chelle globale, compt\xE9e en portions.",
|
|
1123
|
+
scaleGlobal: "Ajuste les quantit\xE9s de tous les ingr\xE9dients et le nombre de portions selon le pourcentage indiqu\xE9 (ex. 200 % pour doubler, 50 % pour diviser par deux).",
|
|
1124
|
+
scaleByIngredient: "Recalcule proportionnellement toute la recette pour l'ajuster \xE0 la quantit\xE9 exacte dont vous disposez pour un ingr\xE9dient donn\xE9 (ex. seulement 3 \u0153ufs ou 250 g de beurre).",
|
|
1125
|
+
bakersMath: "Exprime chaque ingr\xE9dient en pourcentage d'un ingr\xE9dient de base fix\xE9 \xE0 100 % (par d\xE9faut la farine, ou l'ingr\xE9dient de votre choix), facilitant l'\xE9valuation des \xE9quilibres et des ratios.",
|
|
1126
|
+
comments: "Affiche ou masque les commentaires \xE9crits dans la recette avec // : les notes seules sur une ligne et celles en fin de ligne. Dans le plan de marche, ils sont mis \xE0 part, discr\xE8tement.",
|
|
1127
|
+
stepQuantities: "Rappelle chaque quantit\xE9 dans l'\xE9tape qui l'utilise, avec son poids en grammes si les masses sont standardis\xE9es. D\xE9cochez pour des \xE9tapes plus courtes : les quantit\xE9s restent dans les listes d'ingr\xE9dients.",
|
|
1128
|
+
nutritionBasis: "La base du panneau nutritionnel, quand la nutrition est estim\xE9e. En automatique, pour 100 g et par portion c\xF4te \xE0 c\xF4te, la recette enti\xE8re en dessous, dans tous les formats de la recette.",
|
|
1129
|
+
bakersMathOnly: "Masque les poids en grammes pour n'afficher que les pourcentages relatifs, transformant la recette en une formule de proportions pure.",
|
|
1130
|
+
bakersReference: "Choisit manuellement l'ingr\xE9dient qui sert de base \xE0 100 %, \xE0 la place de la d\xE9tection automatique de l'ingr\xE9dient annot\xE9 @* dans la recette.",
|
|
1131
|
+
massStandardization: "Convertit les mesures de volume (cuill\xE8res, tasses, ml) en grammes selon les densit\xE9s renseign\xE9es en base.",
|
|
1132
|
+
yieldManagement: "Calcule le poids brut \xE0 acheter pour obtenir la quantit\xE9 nette voulue, en tenant compte des pertes \xE0 l'\xE9pluchage ou au parage renseign\xE9es en base.",
|
|
1133
|
+
nutrition: "Estime les calories et les macronutriments (prot\xE9ines, glucides, lipides, fibres) par portion ou pour 100 g via les tables de composition en base.",
|
|
1134
|
+
scheduleNote: "Ces r\xE9glages servent surtout au plan de marche. Dans la recette, seuls le temps total et le temps d'attente changent.",
|
|
1135
|
+
scheduleNoteLink: "Voir le plan de marche",
|
|
1136
|
+
physicsDisclaimer: "Dans ce playground, les calculs physiques et nutritionnels reposent sur une base restreinte aux recettes d'exemple.",
|
|
1137
|
+
stockItem: "D\xE9clare cette pr\xE9paration import\xE9e comme d\xE9j\xE0 pr\xEAte dans votre cuisine. Ses \xE9tapes de fabrication sont masqu\xE9es du plan de marche pour ne garder que son utilisation finale."
|
|
1138
|
+
},
|
|
603
1139
|
output: {
|
|
604
1140
|
copy: "Copier dans le presse-papier",
|
|
1141
|
+
print: "Imprimer cette vue",
|
|
1142
|
+
views: "Vues",
|
|
1143
|
+
inspect: "Inspecter",
|
|
605
1144
|
loading: "Chargement du lecteur..."
|
|
606
1145
|
},
|
|
607
1146
|
warnings: {
|
|
@@ -618,8 +1157,8 @@ var fr3 = {
|
|
|
618
1157
|
collapseConsole: "R\xE9duire la console"
|
|
619
1158
|
},
|
|
620
1159
|
errorState: {
|
|
621
|
-
title:
|
|
622
|
-
blockingDescription:
|
|
1160
|
+
title: VIEWS_PAUSED2.title,
|
|
1161
|
+
blockingDescription: VIEWS_PAUSED2.description,
|
|
623
1162
|
jumpToError: "Aller \xE0 l'erreur",
|
|
624
1163
|
line: "Ligne"
|
|
625
1164
|
},
|
|
@@ -637,6 +1176,8 @@ var fr3 = {
|
|
|
637
1176
|
editor: "\xC9diteur",
|
|
638
1177
|
preview: "Aper\xE7u"
|
|
639
1178
|
},
|
|
1179
|
+
fullscreen: "Plein \xE9cran",
|
|
1180
|
+
exitFullscreen: "Quitter le plein \xE9cran",
|
|
640
1181
|
analysisOptions: "Options d'Analyse",
|
|
641
1182
|
analysis: "Analyse",
|
|
642
1183
|
massNorm: "Standardisation des Masses",
|
|
@@ -658,6 +1199,14 @@ function getDictionary(lang) {
|
|
|
658
1199
|
const code = (parts[0] || "en").toLowerCase();
|
|
659
1200
|
return dictionaries[code] || en3;
|
|
660
1201
|
}
|
|
1202
|
+
|
|
1203
|
+
// src/template.ts
|
|
1204
|
+
function fillTemplate(template, values) {
|
|
1205
|
+
return template.replace(
|
|
1206
|
+
/\{(\w+)\}/g,
|
|
1207
|
+
(whole, key) => Object.hasOwn(values, key) ? values[key] : whole
|
|
1208
|
+
);
|
|
1209
|
+
}
|
|
661
1210
|
export {
|
|
662
1211
|
CATEGORY_KEYS,
|
|
663
1212
|
TIME_BY_LANG,
|
|
@@ -669,6 +1218,7 @@ export {
|
|
|
669
1218
|
UNIT_DICTIONARIES,
|
|
670
1219
|
UNIT_GLOBAL,
|
|
671
1220
|
compileDictionary,
|
|
1221
|
+
fillTemplate,
|
|
672
1222
|
getAiLanguageInstruction,
|
|
673
1223
|
getCategoryLabels,
|
|
674
1224
|
getDefaultCategories,
|
|
@@ -676,5 +1226,6 @@ export {
|
|
|
676
1226
|
isCategoryKey,
|
|
677
1227
|
isCoarseUnit,
|
|
678
1228
|
normalizeUnit,
|
|
679
|
-
resolveTimeUnit
|
|
1229
|
+
resolveTimeUnit,
|
|
1230
|
+
unitKey
|
|
680
1231
|
};
|