@eifi1/ui-kit 0.9.0 → 0.10.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 +21 -11
- package/dist/components/alert-banner.d.ts +32 -5
- package/dist/components/alert-banner.js +57 -14
- package/dist/components/alert-banner.js.map +1 -1
- package/dist/components/amount-input.d.ts +4 -0
- package/dist/components/breadcrumbs.d.ts +60 -0
- package/dist/components/breadcrumbs.js +88 -0
- package/dist/components/breadcrumbs.js.map +1 -0
- package/dist/components/bulk-action-bar.d.ts +66 -0
- package/dist/components/bulk-action-bar.js +149 -0
- package/dist/components/bulk-action-bar.js.map +1 -0
- package/dist/components/calculator.d.ts +4 -0
- package/dist/components/chip.d.ts +31 -5
- package/dist/components/chip.js +85 -5
- package/dist/components/chip.js.map +1 -1
- package/dist/components/copy-button.d.ts +13 -4
- package/dist/components/copy-button.js +17 -4
- package/dist/components/copy-button.js.map +1 -1
- package/dist/components/date-picker.d.ts +22 -2
- package/dist/components/date-picker.js +11 -3
- package/dist/components/date-picker.js.map +1 -1
- package/dist/components/description-list.d.ts +43 -6
- package/dist/components/description-list.js +91 -11
- package/dist/components/description-list.js.map +1 -1
- package/dist/components/dialog-frame.d.ts +7 -0
- package/dist/components/dialog-frame.js.map +1 -1
- package/dist/components/disclosure.d.ts +57 -2
- package/dist/components/disclosure.js +24 -12
- package/dist/components/disclosure.js.map +1 -1
- package/dist/components/file-dropzone.d.ts +3 -4
- package/dist/components/file-dropzone.js +2 -1
- package/dist/components/file-dropzone.js.map +1 -1
- package/dist/components/full-bleed-dialog.d.ts +23 -4
- package/dist/components/full-bleed-dialog.js +11 -2
- package/dist/components/full-bleed-dialog.js.map +1 -1
- package/dist/components/list.d.ts +174 -0
- package/dist/components/list.js +215 -0
- package/dist/components/list.js.map +1 -0
- package/dist/components/menu-item.d.ts +99 -0
- package/dist/components/menu-item.js +83 -0
- package/dist/components/menu-item.js.map +1 -0
- package/dist/components/modal.d.ts +23 -1
- package/dist/components/modal.js +36 -10
- package/dist/components/modal.js.map +1 -1
- package/dist/components/number-field.d.ts +4 -0
- package/dist/components/number-input.d.ts +4 -0
- package/dist/components/numpad-sheet.d.ts +4 -0
- package/dist/components/page-contents.js +1 -2
- package/dist/components/page-contents.js.map +1 -1
- package/dist/components/page-header.d.ts +37 -0
- package/dist/components/page-header.js +36 -0
- package/dist/components/page-header.js.map +1 -0
- package/dist/components/series-chart-labels.d.ts +3 -0
- package/dist/components/series-chart-labels.js +2 -1
- package/dist/components/series-chart-labels.js.map +1 -1
- package/dist/components/series-chart.d.ts +16 -0
- package/dist/components/series-chart.js +137 -3
- package/dist/components/series-chart.js.map +1 -1
- package/dist/components/status-dot.d.ts +49 -0
- package/dist/components/status-dot.js +52 -0
- package/dist/components/status-dot.js.map +1 -0
- package/dist/components/table.d.ts +39 -6
- package/dist/components/table.js +43 -4
- package/dist/components/table.js.map +1 -1
- package/dist/components/text.d.ts +63 -0
- package/dist/components/text.js +23 -0
- package/dist/components/text.js.map +1 -0
- package/dist/components/toast.d.ts +167 -0
- package/dist/components/toast.js +226 -0
- package/dist/components/toast.js.map +1 -0
- package/dist/components/toggle-group.d.ts +29 -1
- package/dist/components/toggle-group.js +52 -3
- package/dist/components/toggle-group.js.map +1 -1
- package/dist/components/tooltip.d.ts +38 -15
- package/dist/components/tooltip.js +85 -47
- package/dist/components/tooltip.js.map +1 -1
- package/dist/components/ui.d.ts +104 -4
- package/dist/components/ui.js +112 -8
- package/dist/components/ui.js.map +1 -1
- package/dist/hooks/use-close-transition.d.ts +7 -1
- package/dist/hooks/use-close-transition.js +5 -2
- package/dist/hooks/use-close-transition.js.map +1 -1
- package/dist/hooks/use-copy-to-clipboard.js +1 -1
- package/dist/hooks/use-copy-to-clipboard.js.map +1 -1
- package/dist/i18n/defaults.d.ts +4 -0
- package/dist/i18n/defaults.js +9 -1
- package/dist/i18n/defaults.js.map +1 -1
- package/dist/i18n/kit-labels.d.ts +8 -0
- package/dist/i18n/kit-labels.js.map +1 -1
- package/dist/i18n/locales/de-CH-informal.d.ts +4 -0
- package/dist/i18n/locales/de-CH.d.ts +4 -0
- package/dist/i18n/locales/de-informal.d.ts +4 -0
- package/dist/i18n/locales/de.d.ts +4 -0
- package/dist/i18n/locales/de.js +21 -1
- package/dist/i18n/locales/de.js.map +1 -1
- package/dist/i18n/locales/es.d.ts +4 -0
- package/dist/i18n/locales/es.js +21 -1
- package/dist/i18n/locales/es.js.map +1 -1
- package/dist/i18n/locales/fr.d.ts +4 -0
- package/dist/i18n/locales/fr.js +21 -1
- package/dist/i18n/locales/fr.js.map +1 -1
- package/dist/i18n/locales/hu.d.ts +4 -0
- package/dist/i18n/locales/hu.js +21 -1
- package/dist/i18n/locales/hu.js.map +1 -1
- package/dist/i18n/locales/it.d.ts +4 -0
- package/dist/i18n/locales/it.js +21 -1
- package/dist/i18n/locales/it.js.map +1 -1
- package/dist/i18n/locales/zh.d.ts +4 -0
- package/dist/i18n/locales/zh.js +21 -1
- package/dist/i18n/locales/zh.js.map +1 -1
- package/dist/index.d.ts +15 -7
- package/dist/index.js +12 -0
- package/dist/index.js.map +1 -1
- package/dist/lib/clipping.d.ts +9 -0
- package/dist/lib/clipping.js +14 -0
- package/dist/lib/clipping.js.map +1 -0
- package/dist/search/command-palette.d.ts +19 -2
- package/dist/search/command-palette.js +16 -5
- package/dist/search/command-palette.js.map +1 -1
- package/dist/search/global-search.d.ts +26 -1
- package/dist/search/global-search.js +29 -13
- package/dist/search/global-search.js.map +1 -1
- package/dist/search.d.ts +1 -1
- package/dist/wizard/stepper-nav.js +1 -1
- package/dist/wizard/stepper-nav.js.map +1 -1
- package/dist/wizard/types.d.ts +2 -2
- package/dist/wizard/types.js.map +1 -1
- package/dist/wizard/use-wizard.js +1 -1
- package/dist/wizard/use-wizard.js.map +1 -1
- package/dist/wizard/wizard-summary.js +3 -3
- package/dist/wizard/wizard-summary.js.map +1 -1
- package/package.json +16 -12
- package/src/components/alert-banner.tsx +117 -18
- package/src/components/breadcrumbs.tsx +168 -0
- package/src/components/bulk-action-bar.tsx +256 -0
- package/src/components/chip.tsx +128 -7
- package/src/components/copy-button.tsx +29 -7
- package/src/components/date-picker.tsx +49 -1
- package/src/components/description-list.tsx +168 -15
- package/src/components/dialog-frame.tsx +7 -0
- package/src/components/disclosure.tsx +93 -21
- package/src/components/file-dropzone.tsx +9 -10
- package/src/components/full-bleed-dialog.tsx +42 -5
- package/src/components/list.tsx +417 -0
- package/src/components/menu-item.tsx +214 -0
- package/src/components/modal.tsx +80 -17
- package/src/components/page-contents.tsx +4 -4
- package/src/components/page-header.tsx +68 -0
- package/src/components/series-chart-labels.ts +4 -0
- package/src/components/series-chart.tsx +253 -3
- package/src/components/status-dot.tsx +99 -0
- package/src/components/table.tsx +91 -6
- package/src/components/text.tsx +89 -0
- package/src/components/toast.tsx +441 -0
- package/src/components/toggle-group.tsx +82 -3
- package/src/components/tooltip.tsx +186 -100
- package/src/components/ui.tsx +237 -8
- package/src/hooks/use-close-transition.ts +14 -5
- package/src/hooks/use-copy-to-clipboard.ts +1 -1
- package/src/i18n/defaults.ts +8 -0
- package/src/i18n/kit-labels.tsx +8 -0
- package/src/i18n/locales/de.ts +20 -0
- package/src/i18n/locales/es.ts +20 -0
- package/src/i18n/locales/fr.ts +20 -0
- package/src/i18n/locales/hu.ts +20 -0
- package/src/i18n/locales/it.ts +20 -0
- package/src/i18n/locales/zh.ts +20 -0
- package/src/index.ts +26 -0
- package/src/lib/clipping.ts +16 -0
- package/src/search/command-palette.tsx +42 -5
- package/src/search/global-search.tsx +59 -18
- package/src/wizard/stepper-nav.tsx +2 -1
- package/src/wizard/types.ts +2 -2
- package/src/wizard/use-wizard.ts +3 -3
- package/src/wizard/wizard-summary.tsx +14 -10
- package/tokens.css +97 -0
|
@@ -3,6 +3,12 @@
|
|
|
3
3
|
* for. Exported so a test can advance a fake clock by the real number rather than
|
|
4
4
|
* by a copy of it. */
|
|
5
5
|
declare const OVERLAY_EXIT_MS = 220;
|
|
6
|
+
/**
|
|
7
|
+
* Whether the user has asked for no motion, read NOW. `true` where `matchMedia` is
|
|
8
|
+
* absent (jsdom, SSR): nothing is painting there, so "no animation" is the only
|
|
9
|
+
* correct answer. Shared by every exit timer in the package, so they agree.
|
|
10
|
+
*/
|
|
11
|
+
declare function prefersReducedMotion(): boolean;
|
|
6
12
|
/**
|
|
7
13
|
* The state machine an exit animation needs, written once for every overlay in this
|
|
8
14
|
* package (Keksdose live #320 rework: *"Recognized the opening transition. Choose
|
|
@@ -38,4 +44,4 @@ declare function useCloseTransition(onClose: () => void, ms?: number): {
|
|
|
38
44
|
requestClose: () => void;
|
|
39
45
|
};
|
|
40
46
|
|
|
41
|
-
export { OVERLAY_EXIT_MS, useCloseTransition };
|
|
47
|
+
export { OVERLAY_EXIT_MS, prefersReducedMotion, useCloseTransition };
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { useCallback, useEffect, useRef, useState } from "react";
|
|
3
3
|
const OVERLAY_EXIT_MS = 220;
|
|
4
|
+
function prefersReducedMotion() {
|
|
5
|
+
return typeof window === "undefined" || typeof window.matchMedia !== "function" || window.matchMedia("(prefers-reduced-motion: reduce)").matches;
|
|
6
|
+
}
|
|
4
7
|
function useCloseTransition(onClose, ms = OVERLAY_EXIT_MS) {
|
|
5
8
|
const [closing, setClosing] = useState(false);
|
|
6
9
|
const timer = useRef(null);
|
|
@@ -16,8 +19,7 @@ function useCloseTransition(onClose, ms = OVERLAY_EXIT_MS) {
|
|
|
16
19
|
);
|
|
17
20
|
const requestClose = useCallback(() => {
|
|
18
21
|
if (timer.current) return;
|
|
19
|
-
|
|
20
|
-
if (reduced || ms <= 0) {
|
|
22
|
+
if (prefersReducedMotion() || ms <= 0) {
|
|
21
23
|
latest.current();
|
|
22
24
|
return;
|
|
23
25
|
}
|
|
@@ -32,6 +34,7 @@ function useCloseTransition(onClose, ms = OVERLAY_EXIT_MS) {
|
|
|
32
34
|
}
|
|
33
35
|
export {
|
|
34
36
|
OVERLAY_EXIT_MS,
|
|
37
|
+
prefersReducedMotion,
|
|
35
38
|
useCloseTransition
|
|
36
39
|
};
|
|
37
40
|
//# sourceMappingURL=use-close-transition.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/hooks/use-close-transition.ts"],"sourcesContent":["import { useCallback, useEffect, useRef, useState } from \"react\";\n\n/** How long the exit animation runs, in ms. Mirrors `.animate-sheet-out` in\n * tokens.css — the sheet is the slower of the two, so it is what the unmount waits\n * for. Exported so a test can advance a fake clock by the real number rather than\n * by a copy of it. */\nexport const OVERLAY_EXIT_MS = 220;\n\n/**\n * The state machine an exit animation needs, written once for every overlay in this\n * package (Keksdose live #320 rework: *\"Recognized the opening transition. Choose\n * transition should be the same, only backwards\"*).\n *\n * ## Why a hook and not a class on the panel\n *\n * An enter animation is free: the element mounts, the keyframes run. An exit is not —\n * by the time the state says \"closed\" the element is already gone, so something has to\n * hold it on screen for exactly as long as the animation lasts. That something cannot\n * be the caller (every caller would need the same timer) and it cannot be the panel's\n * markup. It is this: the overlay's own affordances call {@link requestClose} instead\n * of `onClose`, render the `-out` classes while `closing` is true, and the real\n * `onClose` — the one that unmounts them — fires when the animation has finished.\n *\n * ## What it deliberately does not do\n *\n * It does not intercept a close the CALLER decides on. A dialog that closes itself\n * after a successful save sets its own state and unmounts, with no exit animation, and\n * that is the right trade: making it otherwise would mean every overlay owning an\n * `open` prop and every caller waiting on a callback to learn when its own state took\n * effect. What is animated is what the user dismissed — the X, the backdrop, Escape,\n * the Back gesture — which is the motion the row was about.\n *\n * ## Reduced motion\n *\n * Closes immediately, without the delay. A user who has asked for no motion must not\n * be made to wait 220ms for an animation they are not being shown, and the `-out`\n * classes are never applied, so tokens.css needs no reduced-motion rule for them.\n */\nexport function useCloseTransition(\n onClose: () => void,\n ms: number = OVERLAY_EXIT_MS,\n): { closing: boolean; requestClose: () => void } {\n const [closing, setClosing] = useState(false);\n const timer = useRef<ReturnType<typeof setTimeout> | null>(null);\n // Latest-ref rather than a dependency: callers pass inline arrows, so a dependency\n // would hand every render a new `requestClose` — and this one is read once, by a\n // timer that has already been scheduled. Assigned in an effect, never during render\n // (`react-hooks/refs`), matching `use-long-press.ts` next door.\n const latest = useRef(onClose);\n useEffect(() => {\n latest.current = onClose;\n });\n\n // One timer, ever. A second Escape while the panel is already leaving must not\n // schedule a second unmount — two `onClose` calls is a caller's state machine being\n // run twice, which is how a \"close\" ends up also discarding the row behind it.\n useEffect(\n () => () => {\n if (timer.current) clearTimeout(timer.current);\n },\n [],\n );\n\n const requestClose = useCallback(() => {\n if (timer.current) return;\n // Read at close time, not at mount: the setting can change under a long-lived\n // page, and `matchMedia` is absent in jsdom and in SSR — where \"no animation\" is\n // also the only correct answer, since nothing is painting.\n
|
|
1
|
+
{"version":3,"sources":["../../src/hooks/use-close-transition.ts"],"sourcesContent":["import { useCallback, useEffect, useRef, useState } from \"react\";\n\n/** How long the exit animation runs, in ms. Mirrors `.animate-sheet-out` in\n * tokens.css — the sheet is the slower of the two, so it is what the unmount waits\n * for. Exported so a test can advance a fake clock by the real number rather than\n * by a copy of it. */\nexport const OVERLAY_EXIT_MS = 220;\n\n/**\n * Whether the user has asked for no motion, read NOW. `true` where `matchMedia` is\n * absent (jsdom, SSR): nothing is painting there, so \"no animation\" is the only\n * correct answer. Shared by every exit timer in the package, so they agree.\n */\nexport function prefersReducedMotion(): boolean {\n return (\n typeof window === \"undefined\" ||\n typeof window.matchMedia !== \"function\" ||\n window.matchMedia(\"(prefers-reduced-motion: reduce)\").matches\n );\n}\n\n/**\n * The state machine an exit animation needs, written once for every overlay in this\n * package (Keksdose live #320 rework: *\"Recognized the opening transition. Choose\n * transition should be the same, only backwards\"*).\n *\n * ## Why a hook and not a class on the panel\n *\n * An enter animation is free: the element mounts, the keyframes run. An exit is not —\n * by the time the state says \"closed\" the element is already gone, so something has to\n * hold it on screen for exactly as long as the animation lasts. That something cannot\n * be the caller (every caller would need the same timer) and it cannot be the panel's\n * markup. It is this: the overlay's own affordances call {@link requestClose} instead\n * of `onClose`, render the `-out` classes while `closing` is true, and the real\n * `onClose` — the one that unmounts them — fires when the animation has finished.\n *\n * ## What it deliberately does not do\n *\n * It does not intercept a close the CALLER decides on. A dialog that closes itself\n * after a successful save sets its own state and unmounts, with no exit animation, and\n * that is the right trade: making it otherwise would mean every overlay owning an\n * `open` prop and every caller waiting on a callback to learn when its own state took\n * effect. What is animated is what the user dismissed — the X, the backdrop, Escape,\n * the Back gesture — which is the motion the row was about.\n *\n * ## Reduced motion\n *\n * Closes immediately, without the delay. A user who has asked for no motion must not\n * be made to wait 220ms for an animation they are not being shown, and the `-out`\n * classes are never applied, so tokens.css needs no reduced-motion rule for them.\n */\nexport function useCloseTransition(\n onClose: () => void,\n ms: number = OVERLAY_EXIT_MS,\n): { closing: boolean; requestClose: () => void } {\n const [closing, setClosing] = useState(false);\n const timer = useRef<ReturnType<typeof setTimeout> | null>(null);\n // Latest-ref rather than a dependency: callers pass inline arrows, so a dependency\n // would hand every render a new `requestClose` — and this one is read once, by a\n // timer that has already been scheduled. Assigned in an effect, never during render\n // (`react-hooks/refs`), matching `use-long-press.ts` next door.\n const latest = useRef(onClose);\n useEffect(() => {\n latest.current = onClose;\n });\n\n // One timer, ever. A second Escape while the panel is already leaving must not\n // schedule a second unmount — two `onClose` calls is a caller's state machine being\n // run twice, which is how a \"close\" ends up also discarding the row behind it.\n useEffect(\n () => () => {\n if (timer.current) clearTimeout(timer.current);\n },\n [],\n );\n\n const requestClose = useCallback(() => {\n if (timer.current) return;\n // Read at close time, not at mount: the setting can change under a long-lived\n // page, and `matchMedia` is absent in jsdom and in SSR — where \"no animation\" is\n // also the only correct answer, since nothing is painting.\n if (prefersReducedMotion() || ms <= 0) {\n latest.current();\n return;\n }\n setClosing(true);\n timer.current = setTimeout(() => {\n timer.current = null;\n // ⚠️ Reset BEFORE handing control back — reported from a phone within the hour\n // of the 0.4.52 deploy that first shipped this hook, against every table at once.\n // A panel that returns `null` while closed is still MOUNTED — `FullBleedDialog`\n // early-returns after its hooks, and DataTable renders it once and flips `open`\n // — so this state outlives the panel it describes. Left true, the NEXT open\n // rendered `animate-*-out` with `animation-fill-mode: forwards` on a sheet that\n // had only just arrived: it lowered itself off the screen in 220ms and stayed\n // there, invisible but still holding the backdrop's pointer events. Every table\n // on every phone, first open fine and every one after it not, until a route\n // change remounted the component.\n //\n // Batched with the `onClose` below, so a caller that unmounts on close still\n // renders exactly once and nothing flashes.\n setClosing(false);\n latest.current();\n }, ms);\n }, [ms]);\n\n return { closing, requestClose };\n}\n"],"mappings":";AAAA,SAAS,aAAa,WAAW,QAAQ,gBAAgB;AAMlD,MAAM,kBAAkB;AAOxB,SAAS,uBAAgC;AAC9C,SACE,OAAO,WAAW,eAClB,OAAO,OAAO,eAAe,cAC7B,OAAO,WAAW,kCAAkC,EAAE;AAE1D;AAgCO,SAAS,mBACd,SACA,KAAa,iBACmC;AAChD,QAAM,CAAC,SAAS,UAAU,IAAI,SAAS,KAAK;AAC5C,QAAM,QAAQ,OAA6C,IAAI;AAK/D,QAAM,SAAS,OAAO,OAAO;AAC7B,YAAU,MAAM;AACd,WAAO,UAAU;AAAA,EACnB,CAAC;AAKD;AAAA,IACE,MAAM,MAAM;AACV,UAAI,MAAM,QAAS,cAAa,MAAM,OAAO;AAAA,IAC/C;AAAA,IACA,CAAC;AAAA,EACH;AAEA,QAAM,eAAe,YAAY,MAAM;AACrC,QAAI,MAAM,QAAS;AAInB,QAAI,qBAAqB,KAAK,MAAM,GAAG;AACrC,aAAO,QAAQ;AACf;AAAA,IACF;AACA,eAAW,IAAI;AACf,UAAM,UAAU,WAAW,MAAM;AAC/B,YAAM,UAAU;AAchB,iBAAW,KAAK;AAChB,aAAO,QAAQ;AAAA,IACjB,GAAG,EAAE;AAAA,EACP,GAAG,CAAC,EAAE,CAAC;AAEP,SAAO,EAAE,SAAS,aAAa;AACjC;","names":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/hooks/use-copy-to-clipboard.ts"],"sourcesContent":["import { useCallback, useEffect, useRef, useState } from \"react\";\n\nexport type CopyState = \"idle\" | \"copied\" | \"failed\";\n\nexport interface UseCopyToClipboardOptions {\n /** How long `copied` / `failed` stays up before the state returns to `idle`, in\n * ms. `0` keeps it until the next copy or {@link UseCopyToClipboardReturn.reset}. */\n resetAfter?: number;\n}\n\nexport interface UseCopyToClipboardReturn {\n state: CopyState;\n /** Copy `text`. Resolves to whether it actually reached the clipboard — the same\n * answer `state` gives, for a caller that wants to act on it directly. */\n copy: (text: string) => Promise<boolean>;\n reset: () => void;\n}\n\n/**\n * The legacy path: select a throwaway `<textarea>` and ask the document to copy it.\n *\n * `navigator.clipboard` exists only in a secure context, so an app opened over plain\n * http on a LAN address (how keksdose is tested on a phone) has no Clipboard API at\n * all. `execCommand(\"copy\")` is deprecated but still implemented everywhere, and it\n * answers with a boolean, which is all this needs. Focus and the user's selection are\n * put back afterwards: copying must not move the keyboard.\n */\nfunction legacyCopy(text: string): boolean {\n if (typeof document === \"undefined\" || typeof document.execCommand !== \"function\") return false;\n const active = document.activeElement as HTMLElement | null;\n const selection = document.getSelection();\n const ranges: Range[] = [];\n if (selection) for (let i = 0; i < selection.rangeCount; i++) ranges.push(selection.getRangeAt(i));\n\n const area = document.createElement(\"textarea\");\n area.value = text;\n area.setAttribute(\"readonly\", \"\");\n // Off-screen but rendered: a `display: none` textarea cannot be selected.\n area.style.position = \"fixed\";\n area.style.top = \"0\";\n area.style.insetInlineStart = \"-9999px\";\n area.style.opacity = \"0\";\n document.body.appendChild(area);\n area.select();\n let ok
|
|
1
|
+
{"version":3,"sources":["../../src/hooks/use-copy-to-clipboard.ts"],"sourcesContent":["import { useCallback, useEffect, useRef, useState } from \"react\";\n\nexport type CopyState = \"idle\" | \"copied\" | \"failed\";\n\nexport interface UseCopyToClipboardOptions {\n /** How long `copied` / `failed` stays up before the state returns to `idle`, in\n * ms. `0` keeps it until the next copy or {@link UseCopyToClipboardReturn.reset}. */\n resetAfter?: number;\n}\n\nexport interface UseCopyToClipboardReturn {\n state: CopyState;\n /** Copy `text`. Resolves to whether it actually reached the clipboard — the same\n * answer `state` gives, for a caller that wants to act on it directly. */\n copy: (text: string) => Promise<boolean>;\n reset: () => void;\n}\n\n/**\n * The legacy path: select a throwaway `<textarea>` and ask the document to copy it.\n *\n * `navigator.clipboard` exists only in a secure context, so an app opened over plain\n * http on a LAN address (how keksdose is tested on a phone) has no Clipboard API at\n * all. `execCommand(\"copy\")` is deprecated but still implemented everywhere, and it\n * answers with a boolean, which is all this needs. Focus and the user's selection are\n * put back afterwards: copying must not move the keyboard.\n */\nfunction legacyCopy(text: string): boolean {\n if (typeof document === \"undefined\" || typeof document.execCommand !== \"function\") return false;\n const active = document.activeElement as HTMLElement | null;\n const selection = document.getSelection();\n const ranges: Range[] = [];\n if (selection) for (let i = 0; i < selection.rangeCount; i++) ranges.push(selection.getRangeAt(i));\n\n const area = document.createElement(\"textarea\");\n area.value = text;\n area.setAttribute(\"readonly\", \"\");\n // Off-screen but rendered: a `display: none` textarea cannot be selected.\n area.style.position = \"fixed\";\n area.style.top = \"0\";\n area.style.insetInlineStart = \"-9999px\";\n area.style.opacity = \"0\";\n document.body.appendChild(area);\n area.select();\n let ok: boolean;\n try {\n ok = document.execCommand(\"copy\");\n } catch {\n ok = false;\n }\n area.remove();\n if (selection) {\n selection.removeAllRanges();\n for (const r of ranges) selection.addRange(r);\n }\n active?.focus?.();\n return ok;\n}\n\n/** Copy `text`, by the Clipboard API when there is one and the legacy path when\n * there is not — or when the API refuses (a denied permission, a document that is\n * not focused). Never throws. */\nexport async function copyToClipboard(text: string): Promise<boolean> {\n const clipboard = typeof navigator !== \"undefined\" ? navigator.clipboard : undefined;\n if (clipboard && typeof clipboard.writeText === \"function\") {\n try {\n await clipboard.writeText(text);\n return true;\n } catch {\n // Fall through: the API exists but refused. The legacy path sometimes succeeds\n // where the permission prompt was dismissed.\n }\n }\n return legacyCopy(text);\n}\n\n/**\n * Copy text and KNOW whether it worked.\n *\n * keksdose had two copy buttons that flipped to \"Copied\" on click and never looked at\n * the promise — so on the http LAN build, where there is no Clipboard API, they\n * confirmed a copy that had not happened. The state here is set from the result, and\n * a failure is a state of its own rather than a quiet return to idle.\n */\nexport function useCopyToClipboard({ resetAfter = 2000 }: UseCopyToClipboardOptions = {}): UseCopyToClipboardReturn {\n const [state, setState] = useState<CopyState>(\"idle\");\n const timer = useRef<ReturnType<typeof setTimeout> | null>(null);\n const mounted = useRef(true);\n\n useEffect(() => {\n mounted.current = true;\n return () => {\n mounted.current = false;\n if (timer.current) clearTimeout(timer.current);\n };\n }, []);\n\n const reset = useCallback(() => {\n if (timer.current) clearTimeout(timer.current);\n timer.current = null;\n setState(\"idle\");\n }, []);\n\n const copy = useCallback(\n async (text: string) => {\n if (timer.current) clearTimeout(timer.current);\n const ok = await copyToClipboard(text);\n if (!mounted.current) return ok;\n setState(ok ? \"copied\" : \"failed\");\n if (resetAfter > 0) {\n timer.current = setTimeout(() => {\n timer.current = null;\n setState(\"idle\");\n }, resetAfter);\n }\n return ok;\n },\n [resetAfter],\n );\n\n return { state, copy, reset };\n}\n"],"mappings":";AAAA,SAAS,aAAa,WAAW,QAAQ,gBAAgB;AA2BzD,SAAS,WAAW,MAAuB;AACzC,MAAI,OAAO,aAAa,eAAe,OAAO,SAAS,gBAAgB,WAAY,QAAO;AAC1F,QAAM,SAAS,SAAS;AACxB,QAAM,YAAY,SAAS,aAAa;AACxC,QAAM,SAAkB,CAAC;AACzB,MAAI,UAAW,UAAS,IAAI,GAAG,IAAI,UAAU,YAAY,IAAK,QAAO,KAAK,UAAU,WAAW,CAAC,CAAC;AAEjG,QAAM,OAAO,SAAS,cAAc,UAAU;AAC9C,OAAK,QAAQ;AACb,OAAK,aAAa,YAAY,EAAE;AAEhC,OAAK,MAAM,WAAW;AACtB,OAAK,MAAM,MAAM;AACjB,OAAK,MAAM,mBAAmB;AAC9B,OAAK,MAAM,UA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AClB,cAAM,UAAU,WAAW,MAAM;AAC/B,gBAAM,UAAU;AAChB,mBAAS,MAAM;AAAA,QACjB,GAAG,UAAU;AAAA,MACf;AACA,aAAO;AAAA,IACT;AAAA,IACA,CAAC,UAAU;AAAA,EACb;AAEA,SAAO,EAAE,OAAO,MAAM,MAAM;AAC9B;","names":[]}
|
package/dist/i18n/defaults.d.ts
CHANGED
|
@@ -34,6 +34,10 @@ import '../feedback/feedback-dialog.js';
|
|
|
34
34
|
import '../components/confirm-dialog.js';
|
|
35
35
|
import '../components/floating-panel.js';
|
|
36
36
|
import '../components/copy-button.js';
|
|
37
|
+
import '../components/bulk-action-bar.js';
|
|
38
|
+
import '../components/list.js';
|
|
39
|
+
import '../components/breadcrumbs.js';
|
|
40
|
+
import '../components/toast.js';
|
|
37
41
|
|
|
38
42
|
/**
|
|
39
43
|
* The whole English tree in one object: what a translation is written against, and
|
package/dist/i18n/defaults.js
CHANGED
|
@@ -26,6 +26,10 @@ import { DEFAULT_CONFIRM_DIALOG_LABELS } from "../components/confirm-dialog.js";
|
|
|
26
26
|
import { DEFAULT_FLOATING_PANEL_LABELS } from "../components/floating-panel.js";
|
|
27
27
|
import { DEFAULT_FEEDBACK_ATTACHMENT_LABELS } from "../feedback/feedback-attachment.js";
|
|
28
28
|
import { DEFAULT_COPY_BUTTON_LABELS } from "../components/copy-button.js";
|
|
29
|
+
import { DEFAULT_BULK_ACTION_BAR_LABELS } from "../components/bulk-action-bar.js";
|
|
30
|
+
import { DEFAULT_LIST_LABELS } from "../components/list.js";
|
|
31
|
+
import { DEFAULT_BREADCRUMBS_LABELS } from "../components/breadcrumbs.js";
|
|
32
|
+
import { DEFAULT_TOAST_LABELS } from "../components/toast.js";
|
|
29
33
|
import {
|
|
30
34
|
DEFAULT_APP_SHELL_LABELS,
|
|
31
35
|
DEFAULT_CALCULATOR_LABELS,
|
|
@@ -78,7 +82,11 @@ const DEFAULT_UI_KIT_LABELS = {
|
|
|
78
82
|
feedbackAttachment: DEFAULT_FEEDBACK_ATTACHMENT_LABELS,
|
|
79
83
|
confirmDialog: DEFAULT_CONFIRM_DIALOG_LABELS,
|
|
80
84
|
floatingPanel: DEFAULT_FLOATING_PANEL_LABELS,
|
|
81
|
-
copyButton: DEFAULT_COPY_BUTTON_LABELS
|
|
85
|
+
copyButton: DEFAULT_COPY_BUTTON_LABELS,
|
|
86
|
+
bulkActionBar: DEFAULT_BULK_ACTION_BAR_LABELS,
|
|
87
|
+
list: DEFAULT_LIST_LABELS,
|
|
88
|
+
breadcrumbs: DEFAULT_BREADCRUMBS_LABELS,
|
|
89
|
+
toast: DEFAULT_TOAST_LABELS
|
|
82
90
|
};
|
|
83
91
|
export {
|
|
84
92
|
DEFAULT_UI_KIT_LABELS
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/i18n/defaults.ts"],"sourcesContent":["import { DEFAULT_DATA_TABLE_LABELS } from \"../components/data-table-labels\";\nimport { DEFAULT_MINI_CALENDAR_LABELS } from \"../components/mini-calendar\";\nimport { DEFAULT_MONTH_PICKER_LABELS } from \"../components/month-picker\";\nimport { DEFAULT_PAGE_CONTENTS_LABELS } from \"../components/page-contents\";\nimport { DEFAULT_POPOVER_LABELS } from \"../components/popover\";\nimport { DEFAULT_CHIP_INPUT_LABELS } from \"../components/chip\";\nimport { DEFAULT_FIELD_SYNC_LABELS } from \"../components/field-sync\";\nimport { DEFAULT_PASSWORD_REVEAL_LABELS, DEFAULT_TABS_LABELS } from \"../components/ui\";\nimport { DEFAULT_WIZARD_LABELS } from \"../wizard/types\";\nimport { DEFAULT_TOUR_LABELS } from \"../tour/tour\";\nimport { DEFAULT_COMMAND_PALETTE_LABELS } from \"../search/command-palette\";\nimport { DEFAULT_GLOBAL_SEARCH_LABELS } from \"../search/global-search\";\nimport { DEFAULT_SERIES_CHART_LABELS } from \"../components/series-chart-labels\";\nimport { DEFAULT_SPARKLINE_LABELS } from \"../components/sparkline\";\nimport { DEFAULT_STAT_TILE_LABELS } from \"../components/stat-tile\";\nimport { DEFAULT_SIGNATURE_PAD_LABELS } from \"../components/signature-pad\";\nimport { DEFAULT_PASSWORD_STRENGTH_LABELS } from \"../components/password-strength\";\nimport { DEFAULT_DANGER_CONFIRM_LABELS } from \"../components/danger-confirm\";\nimport { DEFAULT_SWATCH_PICKER_LABELS } from \"../components/swatch-picker\";\nimport { DEFAULT_ICON_PICKER_LABELS } from \"../components/icon-picker\";\nimport { DEFAULT_DIALOG_FRAME_LABELS } from \"../components/dialog-frame\";\nimport { DEFAULT_FILE_PICKER_LABELS } from \"../components/file-button\";\nimport { DEFAULT_MEASURED_GRID_LABELS } from \"../components/measured-grid\";\nimport { DEFAULT_CONFIRM_DIALOG_LABELS } from \"../components/confirm-dialog\";\nimport { DEFAULT_FLOATING_PANEL_LABELS } from \"../components/floating-panel\";\nimport { DEFAULT_FEEDBACK_ATTACHMENT_LABELS } from \"../feedback/feedback-attachment\";\nimport { DEFAULT_COPY_BUTTON_LABELS } from \"../components/copy-button\";\nimport {\n DEFAULT_APP_SHELL_LABELS,\n DEFAULT_CALCULATOR_LABELS,\n DEFAULT_COMBOBOX_LABELS,\n DEFAULT_COMMON_LABELS,\n DEFAULT_CURRENCY_LABELS,\n DEFAULT_DATE_PICKER_LABELS,\n DEFAULT_FILE_LABELS,\n DEFAULT_MULTI_SELECT_LABELS,\n DEFAULT_PICKER_SHEET_LABELS,\n DEFAULT_SWIPEABLE_ROW_LABELS,\n DEFAULT_TOP_BAR_LABELS,\n} from \"./kit-labels\";\nimport type { UiKitLabels } from \"./kit-labels\";\n\n/**\n * The whole English tree in one object: what a translation is written against, and\n * the `reference` for {@link missingKitLabels}.\n *\n * A separate module from the provider on purpose. Components import the provider's\n * hooks; this file imports the components' defaults. Kept together they would be an\n * import cycle through every component in the kit.\n */\nexport const DEFAULT_UI_KIT_LABELS: UiKitLabels = {\n common: DEFAULT_COMMON_LABELS,\n dataTable: DEFAULT_DATA_TABLE_LABELS,\n miniCalendar: DEFAULT_MINI_CALENDAR_LABELS,\n datePicker: DEFAULT_DATE_PICKER_LABELS,\n monthPicker: DEFAULT_MONTH_PICKER_LABELS,\n popover: DEFAULT_POPOVER_LABELS,\n combobox: DEFAULT_COMBOBOX_LABELS,\n multiSelect: DEFAULT_MULTI_SELECT_LABELS,\n calculator: DEFAULT_CALCULATOR_LABELS,\n currency: DEFAULT_CURRENCY_LABELS,\n chipInput: DEFAULT_CHIP_INPUT_LABELS,\n fieldSync: DEFAULT_FIELD_SYNC_LABELS,\n passwordReveal: DEFAULT_PASSWORD_REVEAL_LABELS,\n tabs: DEFAULT_TABS_LABELS,\n appShell: DEFAULT_APP_SHELL_LABELS,\n pageContents: DEFAULT_PAGE_CONTENTS_LABELS,\n topBar: DEFAULT_TOP_BAR_LABELS,\n pickerSheet: DEFAULT_PICKER_SHEET_LABELS,\n swipeableRow: DEFAULT_SWIPEABLE_ROW_LABELS,\n file: DEFAULT_FILE_LABELS,\n wizard: DEFAULT_WIZARD_LABELS,\n tour: DEFAULT_TOUR_LABELS,\n commandPalette: DEFAULT_COMMAND_PALETTE_LABELS,\n globalSearch: DEFAULT_GLOBAL_SEARCH_LABELS,\n seriesChart: DEFAULT_SERIES_CHART_LABELS,\n sparkline: DEFAULT_SPARKLINE_LABELS,\n statTile: DEFAULT_STAT_TILE_LABELS,\n signaturePad: DEFAULT_SIGNATURE_PAD_LABELS,\n passwordStrength: DEFAULT_PASSWORD_STRENGTH_LABELS,\n dangerConfirm: DEFAULT_DANGER_CONFIRM_LABELS,\n swatchPicker: DEFAULT_SWATCH_PICKER_LABELS,\n iconPicker: DEFAULT_ICON_PICKER_LABELS,\n dialogFrame: DEFAULT_DIALOG_FRAME_LABELS,\n filePicker: DEFAULT_FILE_PICKER_LABELS,\n measuredGrid: DEFAULT_MEASURED_GRID_LABELS,\n feedbackAttachment: DEFAULT_FEEDBACK_ATTACHMENT_LABELS,\n confirmDialog: DEFAULT_CONFIRM_DIALOG_LABELS,\n floatingPanel: DEFAULT_FLOAT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d,aAAa;AAAA,EACb,WAAW;AAAA,EACX,UAAU;AAAA,EACV,cAAc;AAAA,EACd,kBAAkB;AAAA,EAClB,eAAe;AAAA,EACf,cAAc;AAAA,EACd,YAAY;AAAA,EACZ,aAAa;AAAA,EACb,YAAY;AAAA,EACZ,cAAc;AAAA,EACd,oBAAoB;AAAA,EACpB,eAAe;AAAA,EACf,eAAe;AAAA,EACf,YAAY;
|
|
1
|
+
{"version":3,"sources":["../../src/i18n/defaults.ts"],"sourcesContent":["import { DEFAULT_DATA_TABLE_LABELS } from \"../components/data-table-labels\";\nimport { DEFAULT_MINI_CALENDAR_LABELS } from \"../components/mini-calendar\";\nimport { DEFAULT_MONTH_PICKER_LABELS } from \"../components/month-picker\";\nimport { DEFAULT_PAGE_CONTENTS_LABELS } from \"../components/page-contents\";\nimport { DEFAULT_POPOVER_LABELS } from \"../components/popover\";\nimport { DEFAULT_CHIP_INPUT_LABELS } from \"../components/chip\";\nimport { DEFAULT_FIELD_SYNC_LABELS } from \"../components/field-sync\";\nimport { DEFAULT_PASSWORD_REVEAL_LABELS, DEFAULT_TABS_LABELS } from \"../components/ui\";\nimport { DEFAULT_WIZARD_LABELS } from \"../wizard/types\";\nimport { DEFAULT_TOUR_LABELS } from \"../tour/tour\";\nimport { DEFAULT_COMMAND_PALETTE_LABELS } from \"../search/command-palette\";\nimport { DEFAULT_GLOBAL_SEARCH_LABELS } from \"../search/global-search\";\nimport { DEFAULT_SERIES_CHART_LABELS } from \"../components/series-chart-labels\";\nimport { DEFAULT_SPARKLINE_LABELS } from \"../components/sparkline\";\nimport { DEFAULT_STAT_TILE_LABELS } from \"../components/stat-tile\";\nimport { DEFAULT_SIGNATURE_PAD_LABELS } from \"../components/signature-pad\";\nimport { DEFAULT_PASSWORD_STRENGTH_LABELS } from \"../components/password-strength\";\nimport { DEFAULT_DANGER_CONFIRM_LABELS } from \"../components/danger-confirm\";\nimport { DEFAULT_SWATCH_PICKER_LABELS } from \"../components/swatch-picker\";\nimport { DEFAULT_ICON_PICKER_LABELS } from \"../components/icon-picker\";\nimport { DEFAULT_DIALOG_FRAME_LABELS } from \"../components/dialog-frame\";\nimport { DEFAULT_FILE_PICKER_LABELS } from \"../components/file-button\";\nimport { DEFAULT_MEASURED_GRID_LABELS } from \"../components/measured-grid\";\nimport { DEFAULT_CONFIRM_DIALOG_LABELS } from \"../components/confirm-dialog\";\nimport { DEFAULT_FLOATING_PANEL_LABELS } from \"../components/floating-panel\";\nimport { DEFAULT_FEEDBACK_ATTACHMENT_LABELS } from \"../feedback/feedback-attachment\";\nimport { DEFAULT_COPY_BUTTON_LABELS } from \"../components/copy-button\";\nimport { DEFAULT_BULK_ACTION_BAR_LABELS } from \"../components/bulk-action-bar\";\nimport { DEFAULT_LIST_LABELS } from \"../components/list\";\nimport { DEFAULT_BREADCRUMBS_LABELS } from \"../components/breadcrumbs\";\nimport { DEFAULT_TOAST_LABELS } from \"../components/toast\";\nimport {\n DEFAULT_APP_SHELL_LABELS,\n DEFAULT_CALCULATOR_LABELS,\n DEFAULT_COMBOBOX_LABELS,\n DEFAULT_COMMON_LABELS,\n DEFAULT_CURRENCY_LABELS,\n DEFAULT_DATE_PICKER_LABELS,\n DEFAULT_FILE_LABELS,\n DEFAULT_MULTI_SELECT_LABELS,\n DEFAULT_PICKER_SHEET_LABELS,\n DEFAULT_SWIPEABLE_ROW_LABELS,\n DEFAULT_TOP_BAR_LABELS,\n} from \"./kit-labels\";\nimport type { UiKitLabels } from \"./kit-labels\";\n\n/**\n * The whole English tree in one object: what a translation is written against, and\n * the `reference` for {@link missingKitLabels}.\n *\n * A separate module from the provider on purpose. Components import the provider's\n * hooks; this file imports the components' defaults. Kept together they would be an\n * import cycle through every component in the kit.\n */\nexport const DEFAULT_UI_KIT_LABELS: UiKitLabels = {\n common: DEFAULT_COMMON_LABELS,\n dataTable: DEFAULT_DATA_TABLE_LABELS,\n miniCalendar: DEFAULT_MINI_CALENDAR_LABELS,\n datePicker: DEFAULT_DATE_PICKER_LABELS,\n monthPicker: DEFAULT_MONTH_PICKER_LABELS,\n popover: DEFAULT_POPOVER_LABELS,\n combobox: DEFAULT_COMBOBOX_LABELS,\n multiSelect: DEFAULT_MULTI_SELECT_LABELS,\n calculator: DEFAULT_CALCULATOR_LABELS,\n currency: DEFAULT_CURRENCY_LABELS,\n chipInput: DEFAULT_CHIP_INPUT_LABELS,\n fieldSync: DEFAULT_FIELD_SYNC_LABELS,\n passwordReveal: DEFAULT_PASSWORD_REVEAL_LABELS,\n tabs: DEFAULT_TABS_LABELS,\n appShell: DEFAULT_APP_SHELL_LABELS,\n pageContents: DEFAULT_PAGE_CONTENTS_LABELS,\n topBar: DEFAULT_TOP_BAR_LABELS,\n pickerSheet: DEFAULT_PICKER_SHEET_LABELS,\n swipeableRow: DEFAULT_SWIPEABLE_ROW_LABELS,\n file: DEFAULT_FILE_LABELS,\n wizard: DEFAULT_WIZARD_LABELS,\n tour: DEFAULT_TOUR_LABELS,\n commandPalette: DEFAULT_COMMAND_PALETTE_LABELS,\n globalSearch: DEFAULT_GLOBAL_SEARCH_LABELS,\n seriesChart: DEFAULT_SERIES_CHART_LABELS,\n sparkline: DEFAULT_SPARKLINE_LABELS,\n statTile: DEFAULT_STAT_TILE_LABELS,\n signaturePad: DEFAULT_SIGNATURE_PAD_LABELS,\n passwordStrength: DEFAULT_PASSWORD_STRENGTH_LABELS,\n dangerConfirm: DEFAULT_DANGER_CONFIRM_LABELS,\n swatchPicker: DEFAULT_SWATCH_PICKER_LABELS,\n iconPicker: DEFAULT_ICON_PICKER_LABELS,\n dialogFrame: DEFAULT_DIALOG_FRAME_LABELS,\n filePicker: DEFAULT_FILE_PICKER_LABELS,\n measuredGrid: DEFAULT_MEASURED_GRID_LABELS,\n feedbackAttachment: DEFAULT_FEEDBACK_ATTACHMENT_LABELS,\n confirmDialog: DEFAULT_CONFIRM_DIALOG_LABELS,\n floatingPanel: DEFAULT_FLOATING_PANEL_LABELS,\n copyButton: DEFAULT_COPY_BUTTON_LABELS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;AAAA,EACV,cAAc;AAAA,EACd,QAAQ;AAAA,EACR,aAAa;AAAA,EACb,cAAc;AAAA,EACd,MAAM;AAAA,EACN,QAAQ;AAAA,EACR,MAAM;AAAA,EACN,gBAAgB;AAAA,EAChB,cAAc;AAAA,EACd,aAAa;AAAA,EACb,WAAW;AAAA,EACX,UAAU;AAAA,EACV,cAAc;AAAA,EACd,kBAAkB;AAAA,EAClB,eAAe;AAAA,EACf,cAAc;AAAA,EACd,YAAY;AAAA,EACZ,aAAa;AAAA,EACb,YAAY;AAAA,EACZ,cAAc;AAAA,EACd,oBAAoB;AAAA,EACpB,eAAe;AAAA,EACf,eAAe;AAAA,EACf,YAAY;AAAA,EACZ,eAAe;AAAA,EACf,MAAM;AAAA,EACN,aAAa;AAAA,EACb,OAAO;AACT;","names":[]}
|
|
@@ -27,6 +27,10 @@ import { FeedbackAttachmentFieldLabels } from '../feedback/feedback-attachment.j
|
|
|
27
27
|
import { ConfirmDialogLabels } from '../components/confirm-dialog.js';
|
|
28
28
|
import { FloatingPanelLabels } from '../components/floating-panel.js';
|
|
29
29
|
import { CopyButtonLabels } from '../components/copy-button.js';
|
|
30
|
+
import { BulkActionBarLabels } from '../components/bulk-action-bar.js';
|
|
31
|
+
import { ListLabels } from '../components/list.js';
|
|
32
|
+
import { BreadcrumbsLabels } from '../components/breadcrumbs.js';
|
|
33
|
+
import { ToastLabels } from '../components/toast.js';
|
|
30
34
|
import 'lucide-react';
|
|
31
35
|
import '../components/tooltip.js';
|
|
32
36
|
import '../hooks/use-anchored-rect.js';
|
|
@@ -222,6 +226,10 @@ interface UiKitLabels {
|
|
|
222
226
|
confirmDialog: ConfirmDialogLabels;
|
|
223
227
|
floatingPanel: FloatingPanelLabels;
|
|
224
228
|
copyButton: CopyButtonLabels;
|
|
229
|
+
bulkActionBar: BulkActionBarLabels;
|
|
230
|
+
list: ListLabels;
|
|
231
|
+
breadcrumbs: BreadcrumbsLabels;
|
|
232
|
+
toast: ToastLabels;
|
|
225
233
|
}
|
|
226
234
|
/** Any subset of the tree, one level deep — each namespace may be partial, and a
|
|
227
235
|
* namespace that holds a record (`dataTable.presets`) is merged key by key. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/i18n/kit-labels.tsx"],"sourcesContent":["import { createContext, useContext, useMemo } from \"react\";\nimport type { ReactNode } from \"react\";\nimport type { DataTableLabels } from \"../components/data-table-labels\";\nimport type { MiniCalendarLabels, WeekDay } from \"../components/mini-calendar\";\nimport type { PopoverLabels } from \"../components/popover\";\nimport type { ChipInputLabels } from \"../components/chip\";\nimport type { FieldSyncLabels } from \"../components/field-sync\";\nimport type { PasswordRevealLabels, TabsLabels } from \"../components/ui\";\nimport type { WizardLabels } from \"../wizard/types\";\nimport type { TourLabels } from \"../tour/tour\";\nimport type { CommandPaletteLabels } from \"../search/command-palette\";\nimport type { GlobalSearchLabels } from \"../search/global-search\";\nimport type { MonthPickerLabels } from \"../components/month-picker\";\nimport type { PageContentsLabels } from \"../components/page-contents\";\nimport type { SeriesChartLabels } from \"../components/series-chart-labels\";\nimport type { SparklineLabels } from \"../components/sparkline\";\nimport type { StatTileLabels } from \"../components/stat-tile\";\nimport type { SignaturePadLabels } from \"../components/signature-pad\";\nimport type { PasswordStrengthLabels } from \"../components/password-strength\";\nimport type { DangerConfirmLabels } from \"../components/danger-confirm\";\nimport type { SwatchPickerLabels } from \"../components/swatch-picker\";\nimport type { IconPickerLabels } from \"../components/icon-picker\";\nimport type { DialogFrameLabels } from \"../components/dialog-frame\";\nimport type { FilePickerLabels } from \"../components/file-button\";\nimport type { MeasuredGridLabels } from \"../components/measured-grid\";\nimport type { FeedbackAttachmentFieldLabels } from \"../feedback/feedback-attachment\";\nimport type { ConfirmDialogLabels } from \"../components/confirm-dialog\";\nimport type { FloatingPanelLabels } from \"../components/floating-panel\";\nimport type { CopyButtonLabels } from \"../components/copy-button\";\n\n/**\n * EVERY string the kit renders, as one typed tree — and an optional provider that\n * hands it to every component at once.\n *\n * WHY THIS EXISTS. The kit ships no catalogue and resolves no strings, and that stays\n * true: the app supplies every word. What was wrong was HOW it had to supply them —\n * one `labels` prop per component instance, under a different prop name per\n * component (`labels`, `calendarLabels`, `passwordLabels`, `clearLabel`,\n * `searchPlaceholder`, `ariaLabel` …). A translated app therefore rendered English\n * wherever one call site forgot one prop, and nothing told it so: a German showcase\n * still said \"Rows per page\", \"Collapse sidebar\" and \"Popover\" in seven languages.\n *\n * Now there is one key per string, addressed by a dot path (`dataTable.pageSize`,\n * `datePicker.today`), and three sources in a fixed order of precedence:\n *\n * the component's own prop > <UiKitProvider labels> > English default\n *\n * A consumer writes its translation ONCE, as a `UiKitLabels` (or a partial of it),\n * mounts `<UiKitProvider labels={…} locale={…}>` at the root, and every kit component\n * below speaks that language — including the ones nested inside other kit components\n * (the calendar inside the data table's date filter, the popover inside the date\n * picker), which no prop at the outer call site could reach before.\n *\n * Messages that carry a value are FUNCTIONS of that value, never a template to fill:\n * a number glued into an English sentence is untranslatable, because the grammar\n * around it moves with it in most languages.\n */\n\n/* ── Namespaces that had no labels type of their own ─────────────────────── */\n\n/** The words several components share. A component's own namespace wins over these\n * where both exist; these are what a new component reaches for first. */\nexport interface CommonLabels {\n close: string;\n clear: string;\n search: string;\n done: string;\n cancel: string;\n save: string;\n back: string;\n next: string;\n remove: string;\n loading: string;\n noResults: string;\n /** \"Name: value\" — how a field's accessible name is composed with its value.\n * A colon-and-space is not universal punctuation (French puts a space before\n * the colon, Chinese uses a full-width one). */\n fieldValue: (field: string, value: string) => string;\n /** The × that puts away a banner or a notice (`AlertBanner onDismiss`). Not `close`:\n * nothing opened, and \"Close\" on a banner reads as closing the page it sits on. */\n dismiss: string;\n}\n\n/** `DatePicker` / `DateRangePicker` chrome. The calendar inside has its own\n * namespace, `miniCalendar`. */\nexport interface DatePickerLabels {\n /** Accessible name of the popover panel the calendar opens in. */\n panel: string;\n /** The same, for `DateRangePicker`'s panel. */\n rangePanel: string;\n clear: string;\n previousDay: string;\n nextDay: string;\n today: string;\n /** `DateRangePicker commit=\"apply\"`: the button that commits the drafted range. */\n apply: string;\n /** …and the one that discards it. */\n cancel: string;\n /** Accessible name of `DateRangePicker`'s preset column. */\n presets: string;\n}\n\n/** The whole combobox family: `Combobox`, `EntityCombobox`,\n * `MultiEntityCombobox`, `InlineEntityCombobox`, `Autocomplete`. */\nexport interface ComboboxLabels {\n search: string;\n noResults: string;\n clear: string;\n loading: string;\n /** The \"add this\" row when free entry is allowed. */\n create: (query: string) => string;\n /** Trigger summary once more than one value is picked. */\n selectedCount: (count: number) => string;\n /** An async lookup (`loadOptions`) failed. */\n loadError: string;\n /** Announced (live region) when the list settles on `count` > 0 rows. */\n resultCount: (count: number) => string;\n /** The query is shorter than the `minChars` a lookup needs. */\n minChars: (count: number) => string;\n}\n\nexport interface MultiSelectLabels {\n search: string;\n selectAll: string;\n clear: string;\n /** Trigger text when nothing is picked, which a multi-select reads as \"all\". */\n all: string;\n /** Trigger summary once some (but not all) values are picked. The English\n * default is the bare count, which is what the trigger has always shown. */\n selectedCount: (count: number) => string;\n}\n\n/** `CalculatorButton` (desktop popover keypad) and `NumberPadSheet` (phone sheet). */\nexport interface CalculatorLabels {\n /** The button that opens the calculator. */\n open: string;\n /** The popover / sheet itself. */\n panel: string;\n calculation: string;\n backspace: string;\n clear: string;\n equals: string;\n /** The primary key of the phone pad — visible text, not an aria-label. */\n done: string;\n /** Names of the operator keys and the decimal key. Their glyphs are not names a\n * screen reader agrees on — \"÷\" is read as \"division sign\", \"divided by\" or\n * nothing at all depending on the reader — so each says what it does. */\n plus: string;\n minus: string;\n times: string;\n divide: string;\n decimal: string;\n}\n\n/** `CurrencySelect` and the currency half of `AmountInput`. */\nexport interface CurrencyLabels {\n currency: string;\n search: string;\n}\n\nexport interface AppShellLabels {\n collapse: string;\n expand: string;\n /** Accessible name of an inline group's disclosure button (`subNav=\"inline\"`). */\n toggleGroup: (groupLabel: string) => string;\n}\n\nexport interface TopBarLabels {\n theme: string;\n palette: string;\n language: string;\n switchRole: string;\n /** The role switcher's tooltip, given the active role's name. */\n role: (value: string) => string;\n}\n\nexport interface PickerSheetLabels {\n close: string;\n}\n\nexport interface SwipeableRowLabels {\n actions: string;\n}\n\nexport interface FileLabels {\n /** A file size for display, given its size in BYTES. The default uses\n * `Intl.NumberFormat`'s unit formatting in the provider's locale. */\n size: (bytes: number) => string;\n}\n\n/** The complete tree. `UiKitProvider` takes any partial of it. */\nexport interface UiKitLabels {\n common: CommonLabels;\n dataTable: DataTableLabels;\n miniCalendar: MiniCalendarLabels;\n datePicker: DatePickerLabels;\n monthPicker: MonthPickerLabels;\n popover: PopoverLabels;\n combobox: ComboboxLabels;\n multiSelect: MultiSelectLabels;\n calculator: CalculatorLabels;\n currency: CurrencyLabels;\n chipInput: ChipInputLabels;\n fieldSync: FieldSyncLabels;\n passwordReveal: PasswordRevealLabels;\n tabs: TabsLabels;\n appShell: AppShellLabels;\n pageContents: PageContentsLabels;\n topBar: TopBarLabels;\n pickerSheet: PickerSheetLabels;\n swipeableRow: SwipeableRowLabels;\n file: FileLabels;\n wizard: WizardLabels;\n tour: TourLabels;\n commandPalette: CommandPaletteLabels;\n globalSearch: GlobalSearchLabels;\n seriesChart: SeriesChartLabels;\n sparkline: SparklineLabels;\n statTile: StatTileLabels;\n signaturePad: SignaturePadLabels;\n passwordStrength: PasswordStrengthLabels;\n dangerConfirm: DangerConfirmLabels;\n swatchPicker: SwatchPickerLabels;\n iconPicker: IconPickerLabels;\n dialogFrame: DialogFrameLabels;\n filePicker: FilePickerLabels;\n measuredGrid: MeasuredGridLabels;\n feedbackAttachment: FeedbackAttachmentFieldLabels;\n confirmDialog: ConfirmDialogLabels;\n floatingPanel: FloatingPanelLabels;\n copyButton: CopyButtonLabels;\n}\n\n/** Any subset of the tree, one level deep — each namespace may be partial, and a\n * namespace that holds a record (`dataTable.presets`) is merged key by key. */\nexport type UiKitLabelOverrides = { [K in keyof UiKitLabels]?: Partial<UiKitLabels[K]> };\n\n/* ── English defaults for the namespaces defined here ────────────────────── */\n\nexport const DEFAULT_COMMON_LABELS: CommonLabels = {\n close: \"Close\",\n clear: \"Clear\",\n search: \"Search\",\n done: \"Done\",\n cancel: \"Cancel\",\n save: \"Save\",\n back: \"Back\",\n next: \"Next\",\n remove: \"Remove\",\n loading: \"Loading…\",\n noResults: \"No results\",\n fieldValue: (field, value) => `${field}: ${value}`,\n dismiss: \"Dismiss\",\n};\n\nexport const DEFAULT_DATE_PICKER_LABELS: DatePickerLabels = {\n panel: \"Choose a date\",\n rangePanel: \"Choose a date range\",\n clear: \"Clear\",\n previousDay: \"Previous day\",\n nextDay: \"Next day\",\n today: \"Today\",\n apply: \"Apply\",\n cancel: \"Cancel\",\n presets: \"Quick ranges\",\n};\n\nexport const DEFAULT_COMBOBOX_LABELS: ComboboxLabels = {\n search: \"Search\",\n noResults: \"No results\",\n clear: \"Clear\",\n loading: \"Loading…\",\n create: (query) => `Create “${query}”`,\n selectedCount: (count) => `${count} selected`,\n loadError: \"Couldn’t load results\",\n resultCount: (count) => (count === 1 ? \"1 result\" : `${count} results`),\n minChars: (count) =>\n count === 1 ? \"Type at least 1 character\" : `Type at least ${count} characters`,\n};\n\nexport const DEFAULT_MULTI_SELECT_LABELS: MultiSelectLabels = {\n search: \"Search\",\n selectAll: \"Select all\",\n clear: \"Clear\",\n all: \"All\",\n selectedCount: (count) => String(count),\n};\n\nexport const DEFAULT_CALCULATOR_LABELS: CalculatorLabels = {\n open: \"Open calculator\",\n panel: \"Calculator\",\n calculation: \"Calculation\",\n backspace: \"Backspace\",\n clear: \"Clear\",\n equals: \"Equals\",\n done: \"Done\",\n plus: \"Plus\",\n minus: \"Minus\",\n times: \"Times\",\n divide: \"Divide\",\n decimal: \"Decimal point\",\n};\n\nexport const DEFAULT_CURRENCY_LABELS: CurrencyLabels = {\n currency: \"Currency\",\n search: \"Search currency\",\n};\n\nexport const DEFAULT_APP_SHELL_LABELS: AppShellLabels = {\n collapse: \"Collapse sidebar\",\n expand: \"Expand sidebar\",\n toggleGroup: (groupLabel) => `${groupLabel}: pages`,\n};\n\nexport const DEFAULT_TOP_BAR_LABELS: TopBarLabels = {\n theme: \"Toggle theme\",\n palette: \"Appearance preset\",\n language: \"Language\",\n switchRole: \"Switch role\",\n role: (value) => `Role: ${value}`,\n};\n\nexport const DEFAULT_PICKER_SHEET_LABELS: PickerSheetLabels = { close: \"Close\" };\n\nexport const DEFAULT_SWIPEABLE_ROW_LABELS: SwipeableRowLabels = { actions: \"Row actions\" };\n\n/** Formats with the locale the provider was given (see {@link useKitFileLabels}).\n * This static default has no locale to hand and falls back to the runtime's. */\nexport const DEFAULT_FILE_LABELS: FileLabels = {\n size: (bytes) => formatFileSize(bytes),\n};\n\n/** \"12 kB\", \"3.4 MB\" — `Intl`'s unit formatting, so the digits, the decimal mark and\n * the unit's spelling all follow `locale`. */\nexport function formatFileSize(bytes: number, locale?: string): string {\n const units = [\"byte\", \"kilobyte\", \"megabyte\", \"gigabyte\"] as const;\n let value = bytes;\n let i = 0;\n while (value >= 1000 && i < units.length - 1) {\n value /= 1000;\n i += 1;\n }\n return new Intl.NumberFormat(locale, {\n style: \"unit\",\n unit: units[i],\n unitDisplay: i === 0 ? \"long\" : \"short\",\n maximumFractionDigits: value < 10 && i > 0 ? 1 : 0,\n }).format(value);\n}\n\n/* ── The provider ────────────────────────────────────────────────────────── */\n\ninterface KitI18n {\n labels?: UiKitLabelOverrides;\n locale?: string;\n weekStartsOn?: WeekDay;\n}\n\nconst KitI18nContext = createContext<KitI18n>({});\n\nexport interface UiKitProviderProps {\n /** Any part of {@link UiKitLabels}. Missing keys fall back to English. */\n labels?: UiKitLabelOverrides;\n /**\n * BCP 47 tag used by every kit component that formats something — dates, numbers,\n * month and weekday names, file sizes — when it is not handed a `locale` prop of\n * its own. Without a provider, and without a prop, those use the runtime default.\n */\n locale?: string;\n /**\n * The first day of the week (0 = Sunday, 1 = Monday …) for every calendar below —\n * `MiniCalendar` and the pickers built on it — that is not handed a `weekStartsOn`\n * of its own. Without it the week start follows `locale`'s week info.\n *\n * Separate from `locale` because the two are separate decisions: a German-built\n * app running in English (`locale=\"en\"`) would otherwise start its weeks on Sunday,\n * and switching it to `en-GB` to get Monday changes every date and number format.\n */\n weekStartsOn?: WeekDay;\n children: ReactNode;\n}\n\n/**\n * Hand every kit component below this point its strings and its locale.\n *\n * Optional: a component outside any provider behaves exactly as it did before the\n * provider existed. Nesting works as a merge — an inner provider overrides only what\n * it names, so a page can re-label one table's `dataTable.table` without restating\n * the language.\n */\nexport function UiKitProvider({ labels, locale, weekStartsOn, children }: UiKitProviderProps) {\n const outer = useContext(KitI18nContext);\n const value = useMemo<KitI18n>(\n () => ({\n locale: locale ?? outer.locale,\n weekStartsOn: weekStartsOn ?? outer.weekStartsOn,\n labels: mergeOverrides(outer.labels, labels),\n }),\n [outer, labels, locale, weekStartsOn],\n );\n return <KitI18nContext.Provider value={value}>{children}</KitI18nContext.Provider>;\n}\n\nfunction isRecord(v: unknown): v is Record<string, unknown> {\n return typeof v === \"object\" && v !== null && !Array.isArray(v);\n}\n\n/** Two levels: namespaces, and inside a namespace a record-valued key (presets). */\nfunction mergeNamespace<T extends object>(base: T, over: Partial<T> | undefined): T {\n if (!over) return base;\n const out = { ...base } as Record<string, unknown>;\n for (const [k, v] of Object.entries(over)) {\n if (v === undefined) continue;\n const prev = out[k];\n out[k] = isRecord(prev) && isRecord(v) ? { ...prev, ...v } : v;\n }\n return out as T;\n}\n\nfunction mergeOverrides(\n a: UiKitLabelOverrides | undefined,\n b: UiKitLabelOverrides | undefined,\n): UiKitLabelOverrides | undefined {\n if (!a) return b;\n if (!b) return a;\n const out: Record<string, unknown> = { ...a };\n for (const [ns, v] of Object.entries(b)) {\n out[ns] = mergeNamespace((out[ns] as object | undefined) ?? {}, v as object);\n }\n return out as UiKitLabelOverrides;\n}\n\n/** What the nearest provider says about one namespace — `undefined` outside one.\n * For a component whose own resolver does more than a merge (the data table\n * derives `columnsCount` from `columns`): feed `{ ...overrides, ...props }` to it. */\nexport function useKitLabelOverrides<K extends keyof UiKitLabels>(\n ns: K,\n): Partial<UiKitLabels[K]> | undefined {\n return useContext(KitI18nContext).labels?.[ns] as Partial<UiKitLabels[K]> | undefined;\n}\n\n/**\n * One namespace, resolved: `defaults`, then the provider, then the component's own\n * `prop`. Record-valued keys are merged key by key at each step.\n */\nexport function useKitLabels<K extends keyof UiKitLabels>(\n ns: K,\n defaults: UiKitLabels[K],\n prop?: Partial<UiKitLabels[K]>,\n): UiKitLabels[K] {\n const fromProvider = useKitLabelOverrides(ns);\n return useMemo(\n () => mergeNamespace(mergeNamespace(defaults, fromProvider), prop),\n [defaults, fromProvider, prop],\n );\n}\n\n/** The component's own `locale` prop, else the provider's, else `undefined` (which\n * every `Intl` API reads as \"the runtime's default\"). */\nexport function useKitLocale(prop?: string): string | undefined {\n const fromProvider = useContext(KitI18nContext).locale;\n return prop ?? fromProvider;\n}\n\n/** The week start the nearest `<UiKitProvider weekStartsOn>` pins, else `undefined`\n * (the caller then asks the locale). A component's own prop goes first:\n * `prop ?? useKitWeekStart()`. */\nexport function useKitWeekStart(): WeekDay | undefined {\n return useContext(KitI18nContext).weekStartsOn;\n}\n\n/** {@link DEFAULT_FILE_LABELS}, but formatting in the provider's locale. */\nexport function useKitFileLabels(prop?: Partial<FileLabels>): FileLabels {\n const locale = useKitLocale();\n const defaults = useMemo<FileLabels>(\n () => ({ size: (bytes) => formatFileSize(bytes, locale) }),\n [locale],\n );\n return useKitLabels(\"file\", defaults, prop);\n}\n\n/**\n * The dot paths of every key `labels` does NOT supply — the ones a translated app is\n * still showing in English. Assert on it in the app's own test:\n *\n * expect(missingKitLabels(de)).toEqual([]);\n *\n * `reference` is the complete tree to check against — pass\n * {@link DEFAULT_UI_KIT_LABELS} (src/i18n/defaults.ts). It is a parameter rather than an import\n * because the defaults live beside their components, and this module is imported BY\n * those components.\n */\nexport function missingKitLabels(\n labels: UiKitLabelOverrides | undefined,\n reference: UiKitLabels,\n): string[] {\n const missing: string[] = [];\n for (const [ns, keys] of Object.entries(reference)) {\n const given = (labels as Record<string, Record<string, unknown> | undefined> | undefined)?.[ns];\n for (const [key, value] of Object.entries(keys as Record<string, unknown>)) {\n const got = given?.[key];\n if (got === undefined) {\n missing.push(`${ns}.${key}`);\n } else if (isRecord(value) && isRecord(got)) {\n for (const sub of Object.keys(value)) {\n if (got[sub] === undefined) missing.push(`${ns}.${key}.${sub}`);\n }\n }\n }\n }\n return missing;\n}\n"],"mappings":";AAgZS;AAhZT,SAAS,eAAe,YAAY,eAAe;AA+O5C,MAAM,wBAAsC;AAAA,EACjD,OAAO;AAAA,EACP,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,MAAM;AAAA,EACN,QAAQ;AAAA,EACR,MAAM;AAAA,EACN,MAAM;AAAA,EACN,MAAM;AAAA,EACN,QAAQ;AAAA,EACR,SAAS;AAAA,EACT,WAAW;AAAA,EACX,YAAY,CAAC,OAAO,UAAU,GAAG,KAAK,KAAK,KAAK;AAAA,EAChD,SAAS;AACX;AAEO,MAAM,6BAA+C;AAAA,EAC1D,OAAO;AAAA,EACP,YAAY;AAAA,EACZ,OAAO;AAAA,EACP,aAAa;AAAA,EACb,SAAS;AAAA,EACT,OAAO;AAAA,EACP,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,SAAS;AACX;AAEO,MAAM,0BAA0C;AAAA,EACrD,QAAQ;AAAA,EACR,WAAW;AAAA,EACX,OAAO;AAAA,EACP,SAAS;AAAA,EACT,QAAQ,CAAC,UAAU,gBAAW,KAAK;AAAA,EACnC,eAAe,CAAC,UAAU,GAAG,KAAK;AAAA,EAClC,WAAW;AAAA,EACX,aAAa,CAAC,UAAW,UAAU,IAAI,aAAa,GAAG,KAAK;AAAA,EAC5D,UAAU,CAAC,UACT,UAAU,IAAI,8BAA8B,iBAAiB,KAAK;AACtE;AAEO,MAAM,8BAAiD;AAAA,EAC5D,QAAQ;AAAA,EACR,WAAW;AAAA,EACX,OAAO;AAAA,EACP,KAAK;A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G,IAAI;AAAA,IACjE,CAAC,UAAU,cAAc,IAAI;AAAA,EAC/B;AACF;AAIO,SAAS,aAAa,MAAmC;AAC9D,QAAM,eAAe,WAAW,cAAc,EAAE;AAChD,SAAO,QAAQ;AACjB;AAKO,SAAS,kBAAuC;AACrD,SAAO,WAAW,cAAc,EAAE;AACpC;AAGO,SAAS,iBAAiB,MAAwC;AACvE,QAAM,SAAS,aAAa;AAC5B,QAAM,WAAW;AAAA,IACf,OAAO,EAAE,MAAM,CAAC,UAAU,eAAe,OAAO,MAAM,EAAE;AAAA,IACxD,CAAC,MAAM;AAAA,EACT;AACA,SAAO,aAAa,QAAQ,UAAU,IAAI;AAC5C;AAaO,SAAS,iBACd,QACA,WACU;AACV,QAAM,UAAoB,CAAC;AAC3B,aAAW,CAAC,IAAI,IAAI,KAAK,OAAO,QAAQ,SAAS,GAAG;AAClD,UAAM,QAAS,SAA6E,EAAE;AAC9F,eAAW,CAAC,KAAK,KAAK,KAAK,OAAO,QAAQ,IAA+B,GAAG;AAC1E,YAAM,MAAM,QAAQ,GAAG;AACvB,UAAI,QAAQ,QAAW;AACrB,gBAAQ,KAAK,GAAG,EAAE,IAAI,GAAG,EAAE;AAAA,MAC7B,WAAW,SAAS,KAAK,KAAK,SAAS,GAAG,GAAG;AAC3C,mBAAW,OAAO,OAAO,KAAK,KAAK,GAAG;AACpC,cAAI,IAAI,GAAG,MAAM,OAAW,SAAQ,KAAK,GAAG,EAAE,IAAI,GAAG,IAAI,GAAG,EAAE;AAAA,QAChE;AAAA,MACF;AAAA,IACF;AAAA,EACF;AACA,SAAO;AACT;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../../src/i18n/kit-labels.tsx"],"sourcesContent":["import { createContext, useContext, useMemo } from \"react\";\nimport type { ReactNode } from \"react\";\nimport type { DataTableLabels } from \"../components/data-table-labels\";\nimport type { MiniCalendarLabels, WeekDay } from \"../components/mini-calendar\";\nimport type { PopoverLabels } from \"../components/popover\";\nimport type { ChipInputLabels } from \"../components/chip\";\nimport type { FieldSyncLabels } from \"../components/field-sync\";\nimport type { PasswordRevealLabels, TabsLabels } from \"../components/ui\";\nimport type { WizardLabels } from \"../wizard/types\";\nimport type { TourLabels } from \"../tour/tour\";\nimport type { CommandPaletteLabels } from \"../search/command-palette\";\nimport type { GlobalSearchLabels } from \"../search/global-search\";\nimport type { MonthPickerLabels } from \"../components/month-picker\";\nimport type { PageContentsLabels } from \"../components/page-contents\";\nimport type { SeriesChartLabels } from \"../components/series-chart-labels\";\nimport type { SparklineLabels } from \"../components/sparkline\";\nimport type { StatTileLabels } from \"../components/stat-tile\";\nimport type { SignaturePadLabels } from \"../components/signature-pad\";\nimport type { PasswordStrengthLabels } from \"../components/password-strength\";\nimport type { DangerConfirmLabels } from \"../components/danger-confirm\";\nimport type { SwatchPickerLabels } from \"../components/swatch-picker\";\nimport type { IconPickerLabels } from \"../components/icon-picker\";\nimport type { DialogFrameLabels } from \"../components/dialog-frame\";\nimport type { FilePickerLabels } from \"../components/file-button\";\nimport type { MeasuredGridLabels } from \"../components/measured-grid\";\nimport type { FeedbackAttachmentFieldLabels } from \"../feedback/feedback-attachment\";\nimport type { ConfirmDialogLabels } from \"../components/confirm-dialog\";\nimport type { FloatingPanelLabels } from \"../components/floating-panel\";\nimport type { CopyButtonLabels } from \"../components/copy-button\";\nimport type { BulkActionBarLabels } from \"../components/bulk-action-bar\";\nimport type { ListLabels } from \"../components/list\";\nimport type { BreadcrumbsLabels } from \"../components/breadcrumbs\";\nimport type { ToastLabels } from \"../components/toast\";\n\n/**\n * EVERY string the kit renders, as one typed tree — and an optional provider that\n * hands it to every component at once.\n *\n * WHY THIS EXISTS. The kit ships no catalogue and resolves no strings, and that stays\n * true: the app supplies every word. What was wrong was HOW it had to supply them —\n * one `labels` prop per component instance, under a different prop name per\n * component (`labels`, `calendarLabels`, `passwordLabels`, `clearLabel`,\n * `searchPlaceholder`, `ariaLabel` …). A translated app therefore rendered English\n * wherever one call site forgot one prop, and nothing told it so: a German showcase\n * still said \"Rows per page\", \"Collapse sidebar\" and \"Popover\" in seven languages.\n *\n * Now there is one key per string, addressed by a dot path (`dataTable.pageSize`,\n * `datePicker.today`), and three sources in a fixed order of precedence:\n *\n * the component's own prop > <UiKitProvider labels> > English default\n *\n * A consumer writes its translation ONCE, as a `UiKitLabels` (or a partial of it),\n * mounts `<UiKitProvider labels={…} locale={…}>` at the root, and every kit component\n * below speaks that language — including the ones nested inside other kit components\n * (the calendar inside the data table's date filter, the popover inside the date\n * picker), which no prop at the outer call site could reach before.\n *\n * Messages that carry a value are FUNCTIONS of that value, never a template to fill:\n * a number glued into an English sentence is untranslatable, because the grammar\n * around it moves with it in most languages.\n */\n\n/* ── Namespaces that had no labels type of their own ─────────────────────── */\n\n/** The words several components share. A component's own namespace wins over these\n * where both exist; these are what a new component reaches for first. */\nexport interface CommonLabels {\n close: string;\n clear: string;\n search: string;\n done: string;\n cancel: string;\n save: string;\n back: string;\n next: string;\n remove: string;\n loading: string;\n noResults: string;\n /** \"Name: value\" — how a field's accessible name is composed with its value.\n * A colon-and-space is not universal punctuation (French puts a space before\n * the colon, Chinese uses a full-width one). */\n fieldValue: (field: string, value: string) => string;\n /** The × that puts away a banner or a notice (`AlertBanner onDismiss`). Not `close`:\n * nothing opened, and \"Close\" on a banner reads as closing the page it sits on. */\n dismiss: string;\n}\n\n/** `DatePicker` / `DateRangePicker` chrome. The calendar inside has its own\n * namespace, `miniCalendar`. */\nexport interface DatePickerLabels {\n /** Accessible name of the popover panel the calendar opens in. */\n panel: string;\n /** The same, for `DateRangePicker`'s panel. */\n rangePanel: string;\n clear: string;\n previousDay: string;\n nextDay: string;\n today: string;\n /** `DateRangePicker commit=\"apply\"`: the button that commits the drafted range. */\n apply: string;\n /** …and the one that discards it. */\n cancel: string;\n /** Accessible name of `DateRangePicker`'s preset column. */\n presets: string;\n}\n\n/** The whole combobox family: `Combobox`, `EntityCombobox`,\n * `MultiEntityCombobox`, `InlineEntityCombobox`, `Autocomplete`. */\nexport interface ComboboxLabels {\n search: string;\n noResults: string;\n clear: string;\n loading: string;\n /** The \"add this\" row when free entry is allowed. */\n create: (query: string) => string;\n /** Trigger summary once more than one value is picked. */\n selectedCount: (count: number) => string;\n /** An async lookup (`loadOptions`) failed. */\n loadError: string;\n /** Announced (live region) when the list settles on `count` > 0 rows. */\n resultCount: (count: number) => string;\n /** The query is shorter than the `minChars` a lookup needs. */\n minChars: (count: number) => string;\n}\n\nexport interface MultiSelectLabels {\n search: string;\n selectAll: string;\n clear: string;\n /** Trigger text when nothing is picked, which a multi-select reads as \"all\". */\n all: string;\n /** Trigger summary once some (but not all) values are picked. The English\n * default is the bare count, which is what the trigger has always shown. */\n selectedCount: (count: number) => string;\n}\n\n/** `CalculatorButton` (desktop popover keypad) and `NumberPadSheet` (phone sheet). */\nexport interface CalculatorLabels {\n /** The button that opens the calculator. */\n open: string;\n /** The popover / sheet itself. */\n panel: string;\n calculation: string;\n backspace: string;\n clear: string;\n equals: string;\n /** The primary key of the phone pad — visible text, not an aria-label. */\n done: string;\n /** Names of the operator keys and the decimal key. Their glyphs are not names a\n * screen reader agrees on — \"÷\" is read as \"division sign\", \"divided by\" or\n * nothing at all depending on the reader — so each says what it does. */\n plus: string;\n minus: string;\n times: string;\n divide: string;\n decimal: string;\n}\n\n/** `CurrencySelect` and the currency half of `AmountInput`. */\nexport interface CurrencyLabels {\n currency: string;\n search: string;\n}\n\nexport interface AppShellLabels {\n collapse: string;\n expand: string;\n /** Accessible name of an inline group's disclosure button (`subNav=\"inline\"`). */\n toggleGroup: (groupLabel: string) => string;\n}\n\nexport interface TopBarLabels {\n theme: string;\n palette: string;\n language: string;\n switchRole: string;\n /** The role switcher's tooltip, given the active role's name. */\n role: (value: string) => string;\n}\n\nexport interface PickerSheetLabels {\n close: string;\n}\n\nexport interface SwipeableRowLabels {\n actions: string;\n}\n\nexport interface FileLabels {\n /** A file size for display, given its size in BYTES. The default uses\n * `Intl.NumberFormat`'s unit formatting in the provider's locale. */\n size: (bytes: number) => string;\n}\n\n/** The complete tree. `UiKitProvider` takes any partial of it. */\nexport interface UiKitLabels {\n common: CommonLabels;\n dataTable: DataTableLabels;\n miniCalendar: MiniCalendarLabels;\n datePicker: DatePickerLabels;\n monthPicker: MonthPickerLabels;\n popover: PopoverLabels;\n combobox: ComboboxLabels;\n multiSelect: MultiSelectLabels;\n calculator: CalculatorLabels;\n currency: CurrencyLabels;\n chipInput: ChipInputLabels;\n fieldSync: FieldSyncLabels;\n passwordReveal: PasswordRevealLabels;\n tabs: TabsLabels;\n appShell: AppShellLabels;\n pageContents: PageContentsLabels;\n topBar: TopBarLabels;\n pickerSheet: PickerSheetLabels;\n swipeableRow: SwipeableRowLabels;\n file: FileLabels;\n wizard: WizardLabels;\n tour: TourLabels;\n commandPalette: CommandPaletteLabels;\n globalSearch: GlobalSearchLabels;\n seriesChart: SeriesChartLabels;\n sparkline: SparklineLabels;\n statTile: StatTileLabels;\n signaturePad: SignaturePadLabels;\n passwordStrength: PasswordStrengthLabels;\n dangerConfirm: DangerConfirmLabels;\n swatchPicker: SwatchPickerLabels;\n iconPicker: IconPickerLabels;\n dialogFrame: DialogFrameLabels;\n filePicker: FilePickerLabels;\n measuredGrid: MeasuredGridLabels;\n feedbackAttachment: FeedbackAttachmentFieldLabels;\n confirmDialog: ConfirmDialogLabels;\n floatingPanel: FloatingPanelLabels;\n copyButton: CopyButtonLabels;\n bulkActionBar: BulkActionBarLabels;\n list: ListLabels;\n breadcrumbs: BreadcrumbsLabels;\n toast: ToastLabels;\n}\n\n/** Any subset of the tree, one level deep — each namespace may be partial, and a\n * namespace that holds a record (`dataTable.presets`) is merged key by key. */\nexport type UiKitLabelOverrides = { [K in keyof UiKitLabels]?: Partial<UiKitLabels[K]> };\n\n/* ── English defaults for the namespaces defined here ────────────────────── */\n\nexport const DEFAULT_COMMON_LABELS: CommonLabels = {\n close: \"Close\",\n clear: \"Clear\",\n search: \"Search\",\n done: \"Done\",\n cancel: \"Cancel\",\n save: \"Save\",\n back: \"Back\",\n next: \"Next\",\n remove: \"Remove\",\n loading: \"Loading…\",\n noResults: \"No results\",\n fieldValue: (field, value) => `${field}: ${value}`,\n dismiss: \"Dismiss\",\n};\n\nexport const DEFAULT_DATE_PICKER_LABELS: DatePickerLabels = {\n panel: \"Choose a date\",\n rangePanel: \"Choose a date range\",\n clear: \"Clear\",\n previousDay: \"Previous day\",\n nextDay: \"Next day\",\n today: \"Today\",\n apply: \"Apply\",\n cancel: \"Cancel\",\n presets: \"Quick ranges\",\n};\n\nexport const DEFAULT_COMBOBOX_LABELS: ComboboxLabels = {\n search: \"Search\",\n noResults: \"No results\",\n clear: \"Clear\",\n loading: \"Loading…\",\n create: (query) => `Create “${query}”`,\n selectedCount: (count) => `${count} selected`,\n loadError: \"Couldn’t load results\",\n resultCount: (count) => (count === 1 ? \"1 result\" : `${count} results`),\n minChars: (count) =>\n count === 1 ? \"Type at least 1 character\" : `Type at least ${count} characters`,\n};\n\nexport const DEFAULT_MULTI_SELECT_LABELS: MultiSelectLabels = {\n search: \"Search\",\n selectAll: \"Select all\",\n clear: \"Clear\",\n all: \"All\",\n selectedCount: (count) => String(count),\n};\n\nexport const DEFAULT_CALCULATOR_LABELS: CalculatorLabels = {\n open: \"Open calculator\",\n panel: \"Calculator\",\n calculation: \"Calculation\",\n backspace: \"Backspace\",\n clear: \"Clear\",\n equals: \"Equals\",\n done: \"Done\",\n plus: \"Plus\",\n minus: \"Minus\",\n times: \"Times\",\n divide: \"Divide\",\n decimal: \"Decimal point\",\n};\n\nexport const DEFAULT_CURRENCY_LABELS: CurrencyLabels = {\n currency: \"Currency\",\n search: \"Search currency\",\n};\n\nexport const DEFAULT_APP_SHELL_LABELS: AppShellLabels = {\n collapse: \"Collapse sidebar\",\n expand: \"Expand sidebar\",\n toggleGroup: (groupLabel) => `${groupLabel}: pages`,\n};\n\nexport const DEFAULT_TOP_BAR_LABELS: TopBarLabels = {\n theme: \"Toggle theme\",\n palette: \"Appearance preset\",\n language: \"Language\",\n switchRole: \"Switch role\",\n role: (value) => `Role: ${value}`,\n};\n\nexport const DEFAULT_PICKER_SHEET_LABELS: PickerSheetLabels = { close: \"Close\" };\n\nexport const DEFAULT_SWIPEABLE_ROW_LABELS: SwipeableRowLabels = { actions: \"Row actions\" };\n\n/** Formats with the locale the provider was given (see {@link useKitFileLabels}).\n * This static default has no locale to hand and falls back to the runtime's. */\nexport const DEFAULT_FILE_LABELS: FileLabels = {\n size: (bytes) => formatFileSize(bytes),\n};\n\n/** \"12 kB\", \"3.4 MB\" — `Intl`'s unit formatting, so the digits, the decimal mark and\n * the unit's spelling all follow `locale`. */\nexport function formatFileSize(bytes: number, locale?: string): string {\n const units = [\"byte\", \"kilobyte\", \"megabyte\", \"gigabyte\"] as const;\n let value = bytes;\n let i = 0;\n while (value >= 1000 && i < units.length - 1) {\n value /= 1000;\n i += 1;\n }\n return new Intl.NumberFormat(locale, {\n style: \"unit\",\n unit: units[i],\n unitDisplay: i === 0 ? \"long\" : \"short\",\n maximumFractionDigits: value < 10 && i > 0 ? 1 : 0,\n }).format(value);\n}\n\n/* ── The provider ────────────────────────────────────────────────────────── */\n\ninterface KitI18n {\n labels?: UiKitLabelOverrides;\n locale?: string;\n weekStartsOn?: WeekDay;\n}\n\nconst KitI18nContext = createContext<KitI18n>({});\n\nexport interface UiKitProviderProps {\n /** Any part of {@link UiKitLabels}. Missing keys fall back to English. */\n labels?: UiKitLabelOverrides;\n /**\n * BCP 47 tag used by every kit component that formats something — dates, numbers,\n * month and weekday names, file sizes — when it is not handed a `locale` prop of\n * its own. Without a provider, and without a prop, those use the runtime default.\n */\n locale?: string;\n /**\n * The first day of the week (0 = Sunday, 1 = Monday …) for every calendar below —\n * `MiniCalendar` and the pickers built on it — that is not handed a `weekStartsOn`\n * of its own. Without it the week start follows `locale`'s week info.\n *\n * Separate from `locale` because the two are separate decisions: a German-built\n * app running in English (`locale=\"en\"`) would otherwise start its weeks on Sunday,\n * and switching it to `en-GB` to get Monday changes every date and number format.\n */\n weekStartsOn?: WeekDay;\n children: ReactNode;\n}\n\n/**\n * Hand every kit component below this point its strings and its locale.\n *\n * Optional: a component outside any provider behaves exactly as it did before the\n * provider existed. Nesting works as a merge — an inner provider overrides only what\n * it names, so a page can re-label one table's `dataTable.table` without restating\n * the language.\n */\nexport function UiKitProvider({ labels, locale, weekStartsOn, children }: UiKitProviderProps) {\n const outer = useContext(KitI18nContext);\n const value = useMemo<KitI18n>(\n () => ({\n locale: locale ?? outer.locale,\n weekStartsOn: weekStartsOn ?? outer.weekStartsOn,\n labels: mergeOverrides(outer.labels, labels),\n }),\n [outer, labels, locale, weekStartsOn],\n );\n return <KitI18nContext.Provider value={value}>{children}</KitI18nContext.Provider>;\n}\n\nfunction isRecord(v: unknown): v is Record<string, unknown> {\n return typeof v === \"object\" && v !== null && !Array.isArray(v);\n}\n\n/** Two levels: namespaces, and inside a namespace a record-valued key (presets). */\nfunction mergeNamespace<T extends object>(base: T, over: Partial<T> | undefined): T {\n if (!over) return base;\n const out = { ...base } as Record<string, unknown>;\n for (const [k, v] of Object.entries(over)) {\n if (v === undefined) continue;\n const prev = out[k];\n out[k] = isRecord(prev) && isRecord(v) ? { ...prev, ...v } : v;\n }\n return out as T;\n}\n\nfunction mergeOverrides(\n a: UiKitLabelOverrides | undefined,\n b: UiKitLabelOverrides | undefined,\n): UiKitLabelOverrides | undefined {\n if (!a) return b;\n if (!b) return a;\n const out: Record<string, unknown> = { ...a };\n for (const [ns, v] of Object.entries(b)) {\n out[ns] = mergeNamespace((out[ns] as object | undefined) ?? {}, v as object);\n }\n return out as UiKitLabelOverrides;\n}\n\n/** What the nearest provider says about one namespace — `undefined` outside one.\n * For a component whose own resolver does more than a merge (the data table\n * derives `columnsCount` from `columns`): feed `{ ...overrides, ...props }` to it. */\nexport function useKitLabelOverrides<K extends keyof UiKitLabels>(\n ns: K,\n): Partial<UiKitLabels[K]> | undefined {\n return useContext(KitI18nContext).labels?.[ns] as Partial<UiKitLabels[K]> | undefined;\n}\n\n/**\n * One namespace, resolved: `defaults`, then the provider, then the component's own\n * `prop`. Record-valued keys are merged key by key at each step.\n */\nexport function useKitLabels<K extends keyof UiKitLabels>(\n ns: K,\n defaults: UiKitLabels[K],\n prop?: Partial<UiKitLabels[K]>,\n): UiKitLabels[K] {\n const fromProvider = useKitLabelOverrides(ns);\n return useMemo(\n () => mergeNamespace(mergeNamespace(defaults, fromProvider), prop),\n [defaults, fromProvider, prop],\n );\n}\n\n/** The component's own `locale` prop, else the provider's, else `undefined` (which\n * every `Intl` API reads as \"the runtime's default\"). */\nexport function useKitLocale(prop?: string): string | undefined {\n const fromProvider = useContext(KitI18nContext).locale;\n return prop ?? fromProvider;\n}\n\n/** The week start the nearest `<UiKitProvider weekStartsOn>` pins, else `undefined`\n * (the caller then asks the locale). A component's own prop goes first:\n * `prop ?? useKitWeekStart()`. */\nexport function useKitWeekStart(): WeekDay | undefined {\n return useContext(KitI18nContext).weekStartsOn;\n}\n\n/** {@link DEFAULT_FILE_LABELS}, but formatting in the provider's locale. */\nexport function useKitFileLabels(prop?: Partial<FileLabels>): FileLabels {\n const locale = useKitLocale();\n const defaults = useMemo<FileLabels>(\n () => ({ size: (bytes) => formatFileSize(bytes, locale) }),\n [locale],\n );\n return useKitLabels(\"file\", defaults, prop);\n}\n\n/**\n * The dot paths of every key `labels` does NOT supply — the ones a translated app is\n * still showing in English. Assert on it in the app's own test:\n *\n * expect(missingKitLabels(de)).toEqual([]);\n *\n * `reference` is the complete tree to check against — pass\n * {@link DEFAULT_UI_KIT_LABELS} (src/i18n/defaults.ts). It is a parameter rather than an import\n * because the defaults live beside their components, and this module is imported BY\n * those components.\n */\nexport function missingKitLabels(\n labels: UiKitLabelOverrides | undefined,\n reference: UiKitLabels,\n): string[] {\n const missing: string[] = [];\n for (const [ns, keys] of Object.entries(reference)) {\n const given = (labels as Record<string, Record<string, unknown> | undefined> | undefined)?.[ns];\n for (const [key, value] of Object.entries(keys as Record<string, unknown>)) {\n const got = given?.[key];\n if (got === undefined) {\n missing.push(`${ns}.${key}`);\n } else if (isRecord(value) && isRecord(got)) {\n for (const sub of Object.keys(value)) {\n if (got[sub] === undefined) missing.push(`${ns}.${key}.${sub}`);\n }\n }\n }\n }\n return missing;\n}\n"],"mappings":";AAwZS;AAxZT,SAAS,eAAe,YAAY,eAAe;AAuP5C,MAAM,wBAAsC;AAAA,EACjD,OAAO;AAAA,EACP,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,MAAM;AAAA,EACN,QAAQ;AAAA,EACR,MAAM;AAAA,EACN,MAAM;AAAA,EACN,MAAM;AAAA,EACN,QAAQ;AAAA,EACR,SAAS;AAAA,EACT,WAAW;AAAA,EACX,YAAY,CAAC,OAAO,UAAU,GAAG,KAAK,KAAK,KAAK;AAAA,EAChD,SAAS;AACX;AAEO,MAAM,6BAA+C;AAAA,EAC1D,OAAO;AAAA,EACP,YAAY;AAAA,EACZ,OAAO;AAAA,EACP,aAAa;AAAA,EACb,SAAS;AAAA,EACT,OAAO;AAAA,EACP,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,SAAS;AACX;AAEO,MAAM,0BAA0C;AAAA,EACrD,QAAQ;AAAA,EACR,WAAW;AAAA,EACX,OAAO;AAAA,EACP,SAAS;AAAA,EACT,QAAQ,CAAC,UAAU,gBAAW,KAAK;AAAA,EACnC,eAAe,CAAC,UAAU,GAAG,KAAK;AAAA,EAClC,WAAW;AAAA,EACX,aAAa,CAAC,UAAW,UAAU,IAAI,aAAa,GAAG,KAAK;AAAA,EAC5D,UAAU,CAAC,UACT,UAAU,IAAI,8BAA8B,iBAAiB,KAAK;AACtE;AAEO,MAAM,8BAAiD;AAAA,EAC5D,QAAQ;AAAA,EACR,WAAW;AAAA,EACX,OAAO;AAAA,EACP,KAAK;AAAA,EACL,eAAe,CAAC,UAAU,OAAO,KAAK;AACxC;AAEO,MAAM,4BAA8C;AAAA,EACzD,MAAM;AAAA,EACN,OAAO;AAAA,EACP,aAAa;AAAA,EACb,WAAW;AAAA,EAC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;AACjB;AAKO,SAAS,kBAAuC;AACrD,SAAO,WAAW,cAAc,EAAE;AACpC;AAGO,SAAS,iBAAiB,MAAwC;AACvE,QAAM,SAAS,aAAa;AAC5B,QAAM,WAAW;AAAA,IACf,OAAO,EAAE,MAAM,CAAC,UAAU,eAAe,OAAO,MAAM,EAAE;AAAA,IACxD,CAAC,MAAM;AAAA,EACT;AACA,SAAO,aAAa,QAAQ,UAAU,IAAI;AAC5C;AAaO,SAAS,iBACd,QACA,WACU;AACV,QAAM,UAAoB,CAAC;AAC3B,aAAW,CAAC,IAAI,IAAI,KAAK,OAAO,QAAQ,SAAS,GAAG;AAClD,UAAM,QAAS,SAA6E,EAAE;AAC9F,eAAW,CAAC,KAAK,KAAK,KAAK,OAAO,QAAQ,IAA+B,GAAG;AAC1E,YAAM,MAAM,QAAQ,GAAG;AACvB,UAAI,QAAQ,QAAW;AACrB,gBAAQ,KAAK,GAAG,EAAE,IAAI,GAAG,EAAE;AAAA,MAC7B,WAAW,SAAS,KAAK,KAAK,SAAS,GAAG,GAAG;AAC3C,mBAAW,OAAO,OAAO,KAAK,KAAK,GAAG;AACpC,cAAI,IAAI,GAAG,MAAM,OAAW,SAAQ,KAAK,GAAG,EAAE,IAAI,GAAG,IAAI,GAAG,EAAE;AAAA,QAChE;AAAA,MACF;AAAA,IACF;AAAA,EACF;AACA,SAAO;AACT;","names":[]}
|
|
@@ -34,6 +34,10 @@ import '../../feedback/feedback-dialog.js';
|
|
|
34
34
|
import '../../components/confirm-dialog.js';
|
|
35
35
|
import '../../components/floating-panel.js';
|
|
36
36
|
import '../../components/copy-button.js';
|
|
37
|
+
import '../../components/bulk-action-bar.js';
|
|
38
|
+
import '../../components/list.js';
|
|
39
|
+
import '../../components/breadcrumbs.js';
|
|
40
|
+
import '../../components/toast.js';
|
|
37
41
|
|
|
38
42
|
/**
|
|
39
43
|
* Swiss Standard German, informal ("du"): the informal German labels with Swiss
|
|
@@ -34,6 +34,10 @@ import '../../feedback/feedback-dialog.js';
|
|
|
34
34
|
import '../../components/confirm-dialog.js';
|
|
35
35
|
import '../../components/floating-panel.js';
|
|
36
36
|
import '../../components/copy-button.js';
|
|
37
|
+
import '../../components/bulk-action-bar.js';
|
|
38
|
+
import '../../components/list.js';
|
|
39
|
+
import '../../components/breadcrumbs.js';
|
|
40
|
+
import '../../components/toast.js';
|
|
37
41
|
|
|
38
42
|
/**
|
|
39
43
|
* Swiss Standard German: the German labels with Swiss spelling — "ss" for every "ß"
|
|
@@ -34,6 +34,10 @@ import '../../feedback/feedback-dialog.js';
|
|
|
34
34
|
import '../../components/confirm-dialog.js';
|
|
35
35
|
import '../../components/floating-panel.js';
|
|
36
36
|
import '../../components/copy-button.js';
|
|
37
|
+
import '../../components/bulk-action-bar.js';
|
|
38
|
+
import '../../components/list.js';
|
|
39
|
+
import '../../components/breadcrumbs.js';
|
|
40
|
+
import '../../components/toast.js';
|
|
37
41
|
|
|
38
42
|
/**
|
|
39
43
|
* The kit's words in informal German ("du"), for apps that address their users that way
|
|
@@ -34,6 +34,10 @@ import '../../feedback/feedback-dialog.js';
|
|
|
34
34
|
import '../../components/confirm-dialog.js';
|
|
35
35
|
import '../../components/floating-panel.js';
|
|
36
36
|
import '../../components/copy-button.js';
|
|
37
|
+
import '../../components/bulk-action-bar.js';
|
|
38
|
+
import '../../components/list.js';
|
|
39
|
+
import '../../components/breadcrumbs.js';
|
|
40
|
+
import '../../components/toast.js';
|
|
37
41
|
|
|
38
42
|
/**
|
|
39
43
|
* The kit's words in German: every namespace of {@link UiKitLabels}, for
|
package/dist/i18n/locales/de.js
CHANGED
|
@@ -224,6 +224,11 @@ function uiKitLabelsDe(numberLocale = "de-DE") {
|
|
|
224
224
|
dialogFrame: {
|
|
225
225
|
close: "Schlie\xDFen"
|
|
226
226
|
},
|
|
227
|
+
bulkActionBar: {
|
|
228
|
+
selected: (count) => `${n(count)} ausgew\xE4hlt`,
|
|
229
|
+
clear: "Auswahl aufheben",
|
|
230
|
+
cleared: "Auswahl aufgehoben"
|
|
231
|
+
},
|
|
227
232
|
swipeableRow: {
|
|
228
233
|
actions: "Zeilenaktionen"
|
|
229
234
|
},
|
|
@@ -353,7 +358,8 @@ function uiKitLabelsDe(numberLocale = "de-DE") {
|
|
|
353
358
|
resetZoom: "Zoom zur\xFCcksetzen",
|
|
354
359
|
zoomHint: "Zum Zoomen ziehen: Eine ann\xE4hernd quadratische Auswahl zoomt beide Achsen, eine lange, schmale nur ihre eigene. Doppelklick setzt zur\xFCck.",
|
|
355
360
|
empty: "Keine Daten",
|
|
356
|
-
legend: "Datenreihen"
|
|
361
|
+
legend: "Datenreihen",
|
|
362
|
+
points: "Diagrammwerte"
|
|
357
363
|
},
|
|
358
364
|
confirmDialog: {
|
|
359
365
|
confirm: "Best\xE4tigen",
|
|
@@ -368,6 +374,20 @@ function uiKitLabelsDe(numberLocale = "de-DE") {
|
|
|
368
374
|
failed: "Kopieren fehlgeschlagen",
|
|
369
375
|
copiedAnnouncement: "In die Zwischenablage kopiert",
|
|
370
376
|
failedAnnouncement: "Kopieren in die Zwischenablage fehlgeschlagen"
|
|
377
|
+
},
|
|
378
|
+
list: {
|
|
379
|
+
unread: "Ungelesen",
|
|
380
|
+
opensInNewTab: "\xF6ffnet in einem neuen Tab"
|
|
381
|
+
},
|
|
382
|
+
breadcrumbs: {
|
|
383
|
+
label: "Brotkr\xFCmelnavigation",
|
|
384
|
+
showAll: "Vollst\xE4ndigen Pfad anzeigen"
|
|
385
|
+
},
|
|
386
|
+
toast: {
|
|
387
|
+
close: "Benachrichtigung schlie\xDFen",
|
|
388
|
+
notifications: "Benachrichtigungen",
|
|
389
|
+
undo: "R\xFCckg\xE4ngig",
|
|
390
|
+
redo: "Wiederholen"
|
|
371
391
|
}
|
|
372
392
|
};
|
|
373
393
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/i18n/locales/de.ts"],"sourcesContent":["import { formatFileSize } from \"../kit-labels\";\nimport type { UiKitLabels } from \"../kit-labels\";\n\n/**\n * The kit's words in German: every namespace of {@link UiKitLabels}, for\n * `<UiKitProvider labels={UI_KIT_LABELS_DE}>`.\n *\n * Self-contained on purpose — nothing but the kit's own `formatFileSize` — so it works\n * as a starting point to copy and adjust. Counts and sizes are formatted with\n * `de-DE` digits; {@link uiKitLabelsDe} takes another number locale\n * (e.g. `\"de-CH\"` for 1’234) without touching the words.\n */\nexport function uiKitLabelsDe(numberLocale = \"de-DE\"): UiKitLabels {\n const num = new Intl.NumberFormat(numberLocale);\n const n = (value: number) => num.format(value);\n\n return {\n feedbackAttachment: {\n attachmentAdd: \"Bild anhängen\",\n attachmentCapture: \"Screenshot aufnehmen\",\n attachmentPaste: \"…oder einen Screenshot aus der Zwischenablage einfügen.\",\n attachmentRemove: \"Anhang entfernen\",\n },\n measuredGrid: {\n view: \"Tabellenansicht\",\n cellsView: \"Zellen\",\n textView: \"Text\",\n addRow: \"Zeile hinzufügen\",\n removeRow: (row) => `Zeile ${row} entfernen`,\n clear: \"Tabelle leeren\",\n pasteHint: \"Einen Block aus einer Tabellenkalkulation in eine beliebige Zelle einfügen\",\n cell: (column, row) => `${column}, Zeile ${row}`,\n rowNumber: \"Zeile\",\n rowActions: \"Zeilenaktionen\",\n keyboardHint:\n \"Pfeiltasten wechseln zwischen Zellen. Tippen ersetzt eine Zelle, F2 bearbeitet sie, Escape macht die Bearbeitung rückgängig. Enter geht nach unten und fügt am Ende eine Zeile hinzu.\",\n lineError: (line) => `Zeile ${line} konnte nicht gelesen werden`,\n points: (count) => (count === 1 ? \"1 Punkt\" : `${count} Punkte`),\n problems: (count) =>\n count === 1 ? \"1 Zelle ist keine Zahl\" : `${count} Zellen sind keine Zahlen`,\n },\n pageContents: { title: \"Auf dieser Seite\" },\n common: {\n dismiss: \"Schließen\",\n close: \"Schließen\",\n clear: \"Leeren\",\n search: \"Suchen\",\n done: \"Fertig\",\n cancel: \"Abbrechen\",\n save: \"Speichern\",\n back: \"Zurück\",\n next: \"Weiter\",\n remove: \"Entfernen\",\n loading: \"Wird geladen…\",\n noResults: \"Keine Ergebnisse\",\n fieldValue: (field, value) => `${field}: ${value}`,\n },\n dataTable: {\n columns: \"Spalten\",\n selectAllRows: \"Alle Zeilen auswählen\",\n sortHint: \"Klicken zum Sortieren · Umschalt-Klick für weitere Sortierung\",\n filter: \"Filter\",\n close: \"Schließen\",\n selectRow: \"Zeile auswählen\",\n autoSize: \"Spaltenbreiten anpassen\",\n loading: \"Wird geladen…\",\n filters: \"Filter\",\n // Resets every active filter; \"Alle löschen\" would read as deleting the filters.\n clearAll: \"Alle zurücksetzen\",\n done: \"Fertig\",\n pageSize: \"Zeilen pro Seite\",\n // Sits among 10 / 25 / 50 counting \"Zeilen\", so the plural \"Alle\", not \"Alles\".\n pageSizeAll: \"Alle\",\n prevPage: \"Vorherige Seite\",\n nextPage: \"Nächste Seite\",\n clearFilter: \"Filter zurücksetzen\",\n filterPlaceholder: \"Filtern…\",\n selectFilter: \"Auswählen\",\n selectAll: \"Alle\",\n selectNone: \"Keine\",\n dateFrom: \"Von\",\n dateTo: \"Bis\",\n numberMin: \"Min.\",\n numberMax: \"Max.\",\n numberAbs: \"Betrag\",\n presets: {\n today: \"Heute\",\n yesterday: \"Gestern\",\n this_week: \"Diese Woche\",\n last_week: \"Letzte Woche\",\n last_7_days: \"Letzte 7 Tage\",\n last_30_days: \"Letzte 30 Tage\",\n this_month: \"Dieser Monat\",\n last_month: \"Letzter Monat\",\n last_3_months: \"Letzte 3 Monate\",\n ytd: \"Seit Jahresbeginn\",\n last_year: \"Letztes Jahr\",\n },\n table: \"Datentabelle\",\n filterResults: (shown, total) =>\n `${n(shown)} von ${n(total)} ${total === 1 ? \"Zeile\" : \"Zeilen\"}`,\n sortedAscending: (column) => `Sortiert nach ${column}, aufsteigend`,\n sortedDescending: (column) => `Sortiert nach ${column}, absteigend`,\n sortCleared: (column) => `Sortierung nach ${column} aufgehoben`,\n pageChanged: (page, totalPages) => `Seite ${n(page)} von ${n(totalPages)}`,\n pageRange: (from, to, total) => `${n(from)}–${n(to)} / ${n(total)}`,\n rowCount: (total) => n(total),\n columnsCount: (visible, total) => `Spalten (${n(visible)}/${n(total)})`,\n },\n miniCalendar: {\n previousMonth: \"Vorheriger Monat\",\n nextMonth: \"Nächster Monat\",\n // Already formatted in the provider's locale (\"Montag, 14. September 2026\").\n day: (date) => date,\n chooseStart: \"Startdatum wählen\",\n chooseEnd: \"Enddatum wählen\",\n startSelected: (date) => `${date} als Startdatum gewählt. Wählen Sie jetzt ein Enddatum.`,\n rangeSelected: (from, to) =>\n `Zeitraum ${from} bis ${to} gewählt. Wählen Sie ein Startdatum, um neu zu beginnen.`,\n },\n datePicker: {\n apply: \"Übernehmen\",\n cancel: \"Abbrechen\",\n presets: \"Schnellauswahl\",\n panel: \"Datum wählen\",\n rangePanel: \"Zeitraum wählen\",\n clear: \"Leeren\",\n previousDay: \"Vorheriger Tag\",\n nextDay: \"Nächster Tag\",\n today: \"Heute\",\n },\n monthPicker: {\n previousYear: \"Vorheriges Jahr\",\n nextYear: \"Nächstes Jahr\",\n panel: \"Monat wählen\",\n month: (monthYear) => monthYear,\n },\n popover: {\n panel: \"Aufklappfenster\",\n },\n combobox: {\n search: \"Suchen\",\n noResults: \"Keine Ergebnisse\",\n clear: \"Leeren\",\n loading: \"Wird geladen…\",\n create: (query) => `„${query}“ anlegen`,\n selectedCount: (count) => `${n(count)} ausgewählt`,\n loadError: \"Ergebnisse konnten nicht geladen werden\",\n resultCount: (count) => `${n(count)} ${count === 1 ? \"Ergebnis\" : \"Ergebnisse\"}`,\n // \"Zeichen\" is the same in singular and plural.\n minChars: (count) => `Mindestens ${n(count)} Zeichen eingeben`,\n },\n multiSelect: {\n search: \"Suchen\",\n selectAll: \"Alle auswählen\",\n clear: \"Leeren\",\n all: \"Alle\",\n // The bare count, as in English: the trigger has always shown just the number.\n selectedCount: (count) => n(count),\n },\n calculator: {\n open: \"Taschenrechner öffnen\",\n panel: \"Taschenrechner\",\n calculation: \"Rechnung\",\n backspace: \"Rücktaste\",\n clear: \"Löschen\",\n equals: \"Ist gleich\",\n done: \"Fertig\",\n plus: \"Plus\",\n minus: \"Minus\",\n times: \"Mal\",\n divide: \"Geteilt durch\",\n decimal: \"Dezimaltrennzeichen\",\n },\n currency: {\n currency: \"Währung\",\n search: \"Währung suchen\",\n },\n chipInput: {\n // The value is arbitrary user text, quoted as a citation, so the participle agrees\n // with the implied \"Eintrag\" whatever the chip says.\n added: (value) => `„${value}“ hinzugefügt`,\n removed: (value) => `„${value}“ entfernt`,\n remove: \"Entfernen\",\n // `von` governs the dative, visible only in the plural: \"von 1 Eintrag\", \"von 2 Einträgen\".\n atLimit: (max) => `Grenze von ${n(max)} ${max === 1 ? \"Eintrag\" : \"Einträgen\"} erreicht`,\n duplicate: (value) => `„${value}“ steht bereits in der Liste`,\n },\n swatchPicker: {\n none: \"Keine Farbe\",\n mixed: \"Gemischt: Die ausgewählten Elemente haben unterschiedliche Farben\",\n },\n iconPicker: {\n none: \"Kein Symbol\",\n mixed: \"Gemischt: Die ausgewählten Elemente haben unterschiedliche Symbole\",\n search: \"Symbole suchen\",\n noResults: \"Keine passenden Symbole\",\n resultCount: (count) => `${n(count)} ${count === 1 ? \"Symbol\" : \"Symbole\"}`,\n },\n fieldSync: {\n synced: \"Gespeichert\",\n edited: \"Nicht gespeicherte Änderungen\",\n pending: \"Wird gespeichert…\",\n error: \"Speichern fehlgeschlagen\",\n retry: \"Erneut versuchen\",\n },\n passwordReveal: {\n show: \"Passwort anzeigen\",\n hide: \"Passwort verbergen\",\n },\n dangerConfirm: {\n arm: \"Löschen…\",\n confirm: \"Löschen\",\n cancel: \"Abbrechen\",\n prompt: \"Dies kann nicht rückgängig gemacht werden.\",\n password: \"Passwort\",\n phrase: (phrase) => `Geben Sie zur Bestätigung „${phrase}“ ein`,\n },\n tabs: {\n // \"Tab\" is what German UIs say; \"Registerkarte\" reads like a 1990s manual.\n add: \"Tab hinzufügen\",\n remove: (tab) => `${tab} entfernen`,\n },\n appShell: {\n collapse: \"Seitenleiste einklappen\",\n expand: \"Seitenleiste ausklappen\",\n toggleGroup: (groupLabel) => `${groupLabel}: Seiten`,\n },\n topBar: {\n theme: \"Theme wechseln\",\n palette: \"Darstellungsvorlage\",\n language: \"Sprache\",\n switchRole: \"Rolle wechseln\",\n role: (value) => `Rolle: ${value}`,\n },\n pickerSheet: {\n close: \"Schließen\",\n },\n dialogFrame: {\n close: \"Schließen\",\n },\n swipeableRow: {\n actions: \"Zeilenaktionen\",\n },\n file: {\n // The kit's own `Intl` unit formatting, pinned to this locale (\"3,4 MB\").\n size: (bytes) => formatFileSize(bytes, numberLocale),\n },\n filePicker: {\n dropzone: \"Datei-Upload\",\n browse: \"Durchsuchen\",\n empty: \"Datei hier ablegen\",\n emptyMultiple: \"Dateien hier ablegen\",\n hint: (accept) => (accept ? `Erlaubt: ${accept}` : \"Beliebiger Dateityp\"),\n busy: \"Wird hochgeladen…\",\n rejectedPick: (count) =>\n count === 1\n ? \"Die Datei wurde nicht hinzugefügt\"\n : `Keine der ${count} Dateien wurde hinzugefügt`,\n rejectedType: (name) => `„${name}“ hat einen nicht unterstützten Dateityp`,\n rejectedTypeOnly: (accept) => `Nur ${accept}-Dateien`,\n rejectedSize: (name, maxSize) => `„${name}“ ist größer als ${maxSize}`,\n rejectedCount: (name, maxFiles) =>\n `„${name}“ wurde nicht hinzugefügt: höchstens ${n(maxFiles)} ${maxFiles === 1 ? \"Datei\" : \"Dateien\"}`,\n rejectedInvalid: (name) => `„${name}“ kann hier nicht verwendet werden`,\n rejectedMany: (count) =>\n count === 1\n ? \"1 Datei wurde nicht hinzugefügt\"\n : `${n(count)} Dateien wurden nicht hinzugefügt`,\n selected: (count, firstName) =>\n count === 1 ? `„${firstName}“ ausgewählt` : `${n(count)} Dateien ausgewählt`,\n remove: (name) => `„${name}“ entfernen`,\n clearAll: \"Alle Dateien entfernen\",\n removed: (name) => `„${name}“ entfernt`,\n cleared: \"Alle Dateien entfernt\",\n },\n wizard: {\n done: \"Fertig\",\n cancel: \"Abbrechen\",\n back: \"Zurück\",\n next: \"Weiter\",\n skip: \"Überspringen\",\n finish: \"Abschließen\",\n submitting: \"Wird erstellt…\",\n steps: \"Schritte\",\n step: (current, total) => `Schritt ${n(current)} von ${n(total)}`,\n cancelTitle: \"Formular verwerfen?\",\n confirmCancel: \"Ihre Eingaben gehen verloren.\",\n cancelConfirmLabel: \"Verwerfen\",\n cancelDismissLabel: \"Weiter bearbeiten\",\n reviewTitle: \"Überprüfen\",\n edit: \"Bearbeiten\",\n missingRequired: \"Bitte füllen Sie alle Pflichtfelder aus.\",\n genericError: \"Ein Fehler ist aufgetreten\",\n },\n tour: {\n next: \"Weiter\",\n back: \"Zurück\",\n skip: \"Überspringen\",\n done: \"Fertig\",\n awaitClickHint: \"Klicken Sie auf das hervorgehobene Element, um fortzufahren\",\n step: (current, total) => `${n(current)} / ${n(total)}`,\n },\n commandPalette: {\n clear: \"Suche löschen\",\n submit: \"Suchen\",\n close: \"Schließen\",\n placeholder: \"Suchen…\",\n empty: \"Keine Ergebnisse\",\n loading: \"Wird gesucht…\",\n dialog: \"Suche\",\n error: \"Die Suche ist fehlgeschlagen. Bitte erneut versuchen.\",\n },\n globalSearch: {\n trigger: \"Suche\",\n placeholder: \"Suchen oder springen zu…\",\n shortcut: (keys) => `Suche (${keys})`,\n suggestions: \"Vorschläge\",\n results: \"Ergebnisse\",\n },\n sparkline: {\n rising: (first, last) => `Steigend von ${first} auf ${last}`,\n falling: (first, last) => `Fallend von ${first} auf ${last}`,\n flat: (value) => `Unverändert bei ${value}`,\n single: (value) => `Ein Wert: ${value}`,\n noData: \"Keine Daten\",\n named: (name, summary) => `${name}: ${summary}`,\n },\n statTile: {\n // `amount` arrives formatted and unsigned (\"5 %\", \"1.200 €\").\n increase: (amount) => `Um ${amount} gestiegen`,\n decrease: (amount) => `Um ${amount} gesunken`,\n unchanged: \"Keine Veränderung\",\n better: (change) => `${change} (besser)`,\n worse: (change) => `${change} (schlechter)`,\n noValue: \"Keine Daten\",\n loading: \"Wird geladen…\",\n },\n signaturePad: {\n label: \"Unterschrift\",\n instructions: \"Unterschreiben Sie im Feld mit der Maus, dem Finger oder einem Stift.\",\n typedFallbackHint: \"Wenn Sie nicht zeichnen können, geben Sie stattdessen Ihren Namen ein.\",\n empty: \"Noch nichts gezeichnet\",\n signed: \"Unterschrift gezeichnet\",\n undo: \"Letzten Strich rückgängig machen\",\n clear: \"Leeren\",\n save: \"Unterschrift speichern\",\n useTyped: \"Stattdessen Namen eingeben\",\n useDrawn: \"Stattdessen zeichnen\",\n typedName: \"Vollständiger Name\",\n cleared: \"Unterschrift gelöscht\",\n undone: \"Letzter Strich entfernt\",\n viewEmpty: \"Nicht unterschrieben\",\n viewDrawn: \"Handschriftliche Unterschrift\",\n viewTyped: (name) => `Unterschrieben mit dem eingegebenen Namen ${name}`,\n },\n passwordStrength: {\n tooShort: \"Zu kurz\",\n weak: \"Schwach\",\n fair: \"Mittel\",\n good: \"Gut\",\n strong: \"Stark\",\n announcement: (level) => `Passwortstärke: ${level}`,\n // \"Zeichen\" is the same in singular and plural. The English default does not\n // format these counts, so neither does this file.\n ruleLength: (minLength) => `Mindestens ${minLength} Zeichen`,\n ruleCase: \"Groß- und Kleinbuchstaben\",\n ruleDigit: \"Eine Ziffer\",\n ruleSymbol: \"Ein Sonderzeichen\",\n optional: (rule) => `${rule} (optional)`,\n met: \"Erfüllt:\",\n notMet: \"Nicht erfüllt:\",\n tooLong: (maxBytes) =>\n `Höchstens ${maxBytes} Zeichen (Buchstaben mit Akzent und Emojis zählen mehrfach).`,\n },\n seriesChart: {\n resetZoom: \"Zoom zurücksetzen\",\n zoomHint:\n \"Zum Zoomen ziehen: Eine annähernd quadratische Auswahl zoomt beide Achsen, eine lange, schmale nur ihre eigene. Doppelklick setzt zurück.\",\n empty: \"Keine Daten\",\n legend: \"Datenreihen\",\n },\n confirmDialog: {\n confirm: \"Bestätigen\",\n cancel: \"Abbrechen\",\n },\n floatingPanel: {\n close: \"Schließen\",\n },\n copyButton: {\n copy: \"Kopieren\",\n copied: \"Kopiert\",\n failed: \"Kopieren fehlgeschlagen\",\n copiedAnnouncement: \"In die Zwischenablage kopiert\",\n failedAnnouncement: \"Kopieren in die Zwischenablage fehlgeschlagen\",\n },\n };\n}\n\nexport const UI_KIT_LABELS_DE: UiKitLabels = uiKitLabelsDe();\n"],"mappings":";AAAA,SAAS,sBAAsB;AAYxB,SAAS,cAAc,eAAe,SAAsB;AACjE,QAAM,MAAM,IAAI,KAAK,aAAa,YAAY;AAC9C,QAAM,IAAI,CAAC,UAAkB,IAAI,OAAO,KAAK;AAE7C,SAAO;AAAA,IACL,oBAAoB;AAAA,MAClB,eAAe;AAAA,MACf,mBAAmB;AAAA,MACnB,iBAAiB;AAAA,MACjB,kBAAkB;AAAA,IACpB;AAAA,IACA,cAAc;AAAA,MACZ,MAAM;AAAA,MACN,WAAW;AAAA,MACX,UAAU;AAAA,MACV,QAAQ;AAAA,MACR,WAAW,CAAC,QAAQ,SAAS,GAAG;AAAA,MAChC,OAAO;AAAA,MACP,WAAW;AAAA,MACX,MAAM,CAAC,QAAQ,QAAQ,GAAG,MAAM,WAAW,GAAG;AAAA,MAC9C,WAAW;AAAA,MACX,YAAY;AAAA,MACZ,cACE;AAAA,MACF,WAAW,CAAC,SAAS,SAAS,IAAI;AAAA,MAClC,QAAQ,CAAC,UAAW,UAAU,IAAI,YAAY,GAAG,KAAK;AAAA,MACtD,UAAU,CAAC,UACT,UAAU,IAAI,2BAA2B,GAAG,KAAK;AAAA,IACrD;AAAA,IACA,cAAc,EAAE,OAAO,mBAAmB;AAAA,IAC1C,QAAQ;AAAA,MACN,SAAS;AAAA,MACT,OAAO;AAAA,MACP,OAAO;AAAA,MACP,QAAQ;AAAA,MACR,MAAM;AAAA,MACN,QAAQ;AAAA,MACR,MAAM;AAAA,MACN,MAAM;AAAA,MACN,MAAM;AAAA,MACN,QAAQ;AAAA,MACR,SAAS;AAAA,MACT,WA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;AAAA,MACV,MAAM;AAAA,MACN,QAAQ;AAAA,MACR,QAAQ;AAAA,MACR,oBAAoB;AAAA,MACpB,oBAAoB;AAAA,IACtB;AAAA,EACF;AACF;AAEO,MAAM,mBAAgC,cAAc;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../../../src/i18n/locales/de.ts"],"sourcesContent":["import { formatFileSize } from \"../kit-labels\";\nimport type { UiKitLabels } from \"../kit-labels\";\n\n/**\n * The kit's words in German: every namespace of {@link UiKitLabels}, for\n * `<UiKitProvider labels={UI_KIT_LABELS_DE}>`.\n *\n * Self-contained on purpose — nothing but the kit's own `formatFileSize` — so it works\n * as a starting point to copy and adjust. Counts and sizes are formatted with\n * `de-DE` digits; {@link uiKitLabelsDe} takes another number locale\n * (e.g. `\"de-CH\"` for 1’234) without touching the words.\n */\nexport function uiKitLabelsDe(numberLocale = \"de-DE\"): UiKitLabels {\n const num = new Intl.NumberFormat(numberLocale);\n const n = (value: number) => num.format(value);\n\n return {\n feedbackAttachment: {\n attachmentAdd: \"Bild anhängen\",\n attachmentCapture: \"Screenshot aufnehmen\",\n attachmentPaste: \"…oder einen Screenshot aus der Zwischenablage einfügen.\",\n attachmentRemove: \"Anhang entfernen\",\n },\n measuredGrid: {\n view: \"Tabellenansicht\",\n cellsView: \"Zellen\",\n textView: \"Text\",\n addRow: \"Zeile hinzufügen\",\n removeRow: (row) => `Zeile ${row} entfernen`,\n clear: \"Tabelle leeren\",\n pasteHint: \"Einen Block aus einer Tabellenkalkulation in eine beliebige Zelle einfügen\",\n cell: (column, row) => `${column}, Zeile ${row}`,\n rowNumber: \"Zeile\",\n rowActions: \"Zeilenaktionen\",\n keyboardHint:\n \"Pfeiltasten wechseln zwischen Zellen. Tippen ersetzt eine Zelle, F2 bearbeitet sie, Escape macht die Bearbeitung rückgängig. Enter geht nach unten und fügt am Ende eine Zeile hinzu.\",\n lineError: (line) => `Zeile ${line} konnte nicht gelesen werden`,\n points: (count) => (count === 1 ? \"1 Punkt\" : `${count} Punkte`),\n problems: (count) =>\n count === 1 ? \"1 Zelle ist keine Zahl\" : `${count} Zellen sind keine Zahlen`,\n },\n pageContents: { title: \"Auf dieser Seite\" },\n common: {\n dismiss: \"Schließen\",\n close: \"Schließen\",\n clear: \"Leeren\",\n search: \"Suchen\",\n done: \"Fertig\",\n cancel: \"Abbrechen\",\n save: \"Speichern\",\n back: \"Zurück\",\n next: \"Weiter\",\n remove: \"Entfernen\",\n loading: \"Wird geladen…\",\n noResults: \"Keine Ergebnisse\",\n fieldValue: (field, value) => `${field}: ${value}`,\n },\n dataTable: {\n columns: \"Spalten\",\n selectAllRows: \"Alle Zeilen auswählen\",\n sortHint: \"Klicken zum Sortieren · Umschalt-Klick für weitere Sortierung\",\n filter: \"Filter\",\n close: \"Schließen\",\n selectRow: \"Zeile auswählen\",\n autoSize: \"Spaltenbreiten anpassen\",\n loading: \"Wird geladen…\",\n filters: \"Filter\",\n // Resets every active filter; \"Alle löschen\" would read as deleting the filters.\n clearAll: \"Alle zurücksetzen\",\n done: \"Fertig\",\n pageSize: \"Zeilen pro Seite\",\n // Sits among 10 / 25 / 50 counting \"Zeilen\", so the plural \"Alle\", not \"Alles\".\n pageSizeAll: \"Alle\",\n prevPage: \"Vorherige Seite\",\n nextPage: \"Nächste Seite\",\n clearFilter: \"Filter zurücksetzen\",\n filterPlaceholder: \"Filtern…\",\n selectFilter: \"Auswählen\",\n selectAll: \"Alle\",\n selectNone: \"Keine\",\n dateFrom: \"Von\",\n dateTo: \"Bis\",\n numberMin: \"Min.\",\n numberMax: \"Max.\",\n numberAbs: \"Betrag\",\n presets: {\n today: \"Heute\",\n yesterday: \"Gestern\",\n this_week: \"Diese Woche\",\n last_week: \"Letzte Woche\",\n last_7_days: \"Letzte 7 Tage\",\n last_30_days: \"Letzte 30 Tage\",\n this_month: \"Dieser Monat\",\n last_month: \"Letzter Monat\",\n last_3_months: \"Letzte 3 Monate\",\n ytd: \"Seit Jahresbeginn\",\n last_year: \"Letztes Jahr\",\n },\n table: \"Datentabelle\",\n filterResults: (shown, total) =>\n `${n(shown)} von ${n(total)} ${total === 1 ? \"Zeile\" : \"Zeilen\"}`,\n sortedAscending: (column) => `Sortiert nach ${column}, aufsteigend`,\n sortedDescending: (column) => `Sortiert nach ${column}, absteigend`,\n sortCleared: (column) => `Sortierung nach ${column} aufgehoben`,\n pageChanged: (page, totalPages) => `Seite ${n(page)} von ${n(totalPages)}`,\n pageRange: (from, to, total) => `${n(from)}–${n(to)} / ${n(total)}`,\n rowCount: (total) => n(total),\n columnsCount: (visible, total) => `Spalten (${n(visible)}/${n(total)})`,\n },\n miniCalendar: {\n previousMonth: \"Vorheriger Monat\",\n nextMonth: \"Nächster Monat\",\n // Already formatted in the provider's locale (\"Montag, 14. September 2026\").\n day: (date) => date,\n chooseStart: \"Startdatum wählen\",\n chooseEnd: \"Enddatum wählen\",\n startSelected: (date) => `${date} als Startdatum gewählt. Wählen Sie jetzt ein Enddatum.`,\n rangeSelected: (from, to) =>\n `Zeitraum ${from} bis ${to} gewählt. Wählen Sie ein Startdatum, um neu zu beginnen.`,\n },\n datePicker: {\n apply: \"Übernehmen\",\n cancel: \"Abbrechen\",\n presets: \"Schnellauswahl\",\n panel: \"Datum wählen\",\n rangePanel: \"Zeitraum wählen\",\n clear: \"Leeren\",\n previousDay: \"Vorheriger Tag\",\n nextDay: \"Nächster Tag\",\n today: \"Heute\",\n },\n monthPicker: {\n previousYear: \"Vorheriges Jahr\",\n nextYear: \"Nächstes Jahr\",\n panel: \"Monat wählen\",\n month: (monthYear) => monthYear,\n },\n popover: {\n panel: \"Aufklappfenster\",\n },\n combobox: {\n search: \"Suchen\",\n noResults: \"Keine Ergebnisse\",\n clear: \"Leeren\",\n loading: \"Wird geladen…\",\n create: (query) => `„${query}“ anlegen`,\n selectedCount: (count) => `${n(count)} ausgewählt`,\n loadError: \"Ergebnisse konnten nicht geladen werden\",\n resultCount: (count) => `${n(count)} ${count === 1 ? \"Ergebnis\" : \"Ergebnisse\"}`,\n // \"Zeichen\" is the same in singular and plural.\n minChars: (count) => `Mindestens ${n(count)} Zeichen eingeben`,\n },\n multiSelect: {\n search: \"Suchen\",\n selectAll: \"Alle auswählen\",\n clear: \"Leeren\",\n all: \"Alle\",\n // The bare count, as in English: the trigger has always shown just the number.\n selectedCount: (count) => n(count),\n },\n calculator: {\n open: \"Taschenrechner öffnen\",\n panel: \"Taschenrechner\",\n calculation: \"Rechnung\",\n backspace: \"Rücktaste\",\n clear: \"Löschen\",\n equals: \"Ist gleich\",\n done: \"Fertig\",\n plus: \"Plus\",\n minus: \"Minus\",\n times: \"Mal\",\n divide: \"Geteilt durch\",\n decimal: \"Dezimaltrennzeichen\",\n },\n currency: {\n currency: \"Währung\",\n search: \"Währung suchen\",\n },\n chipInput: {\n // The value is arbitrary user text, quoted as a citation, so the participle agrees\n // with the implied \"Eintrag\" whatever the chip says.\n added: (value) => `„${value}“ hinzugefügt`,\n removed: (value) => `„${value}“ entfernt`,\n remove: \"Entfernen\",\n // `von` governs the dative, visible only in the plural: \"von 1 Eintrag\", \"von 2 Einträgen\".\n atLimit: (max) => `Grenze von ${n(max)} ${max === 1 ? \"Eintrag\" : \"Einträgen\"} erreicht`,\n duplicate: (value) => `„${value}“ steht bereits in der Liste`,\n },\n swatchPicker: {\n none: \"Keine Farbe\",\n mixed: \"Gemischt: Die ausgewählten Elemente haben unterschiedliche Farben\",\n },\n iconPicker: {\n none: \"Kein Symbol\",\n mixed: \"Gemischt: Die ausgewählten Elemente haben unterschiedliche Symbole\",\n search: \"Symbole suchen\",\n noResults: \"Keine passenden Symbole\",\n resultCount: (count) => `${n(count)} ${count === 1 ? \"Symbol\" : \"Symbole\"}`,\n },\n fieldSync: {\n synced: \"Gespeichert\",\n edited: \"Nicht gespeicherte Änderungen\",\n pending: \"Wird gespeichert…\",\n error: \"Speichern fehlgeschlagen\",\n retry: \"Erneut versuchen\",\n },\n passwordReveal: {\n show: \"Passwort anzeigen\",\n hide: \"Passwort verbergen\",\n },\n dangerConfirm: {\n arm: \"Löschen…\",\n confirm: \"Löschen\",\n cancel: \"Abbrechen\",\n prompt: \"Dies kann nicht rückgängig gemacht werden.\",\n password: \"Passwort\",\n phrase: (phrase) => `Geben Sie zur Bestätigung „${phrase}“ ein`,\n },\n tabs: {\n // \"Tab\" is what German UIs say; \"Registerkarte\" reads like a 1990s manual.\n add: \"Tab hinzufügen\",\n remove: (tab) => `${tab} entfernen`,\n },\n appShell: {\n collapse: \"Seitenleiste einklappen\",\n expand: \"Seitenleiste ausklappen\",\n toggleGroup: (groupLabel) => `${groupLabel}: Seiten`,\n },\n topBar: {\n theme: \"Theme wechseln\",\n palette: \"Darstellungsvorlage\",\n language: \"Sprache\",\n switchRole: \"Rolle wechseln\",\n role: (value) => `Rolle: ${value}`,\n },\n pickerSheet: {\n close: \"Schließen\",\n },\n dialogFrame: {\n close: \"Schließen\",\n },\n bulkActionBar: {\n selected: (count) => `${n(count)} ausgewählt`,\n clear: \"Auswahl aufheben\",\n cleared: \"Auswahl aufgehoben\",\n },\n swipeableRow: {\n actions: \"Zeilenaktionen\",\n },\n file: {\n // The kit's own `Intl` unit formatting, pinned to this locale (\"3,4 MB\").\n size: (bytes) => formatFileSize(bytes, numberLocale),\n },\n filePicker: {\n dropzone: \"Datei-Upload\",\n browse: \"Durchsuchen\",\n empty: \"Datei hier ablegen\",\n emptyMultiple: \"Dateien hier ablegen\",\n hint: (accept) => (accept ? `Erlaubt: ${accept}` : \"Beliebiger Dateityp\"),\n busy: \"Wird hochgeladen…\",\n rejectedPick: (count) =>\n count === 1\n ? \"Die Datei wurde nicht hinzugefügt\"\n : `Keine der ${count} Dateien wurde hinzugefügt`,\n rejectedType: (name) => `„${name}“ hat einen nicht unterstützten Dateityp`,\n rejectedTypeOnly: (accept) => `Nur ${accept}-Dateien`,\n rejectedSize: (name, maxSize) => `„${name}“ ist größer als ${maxSize}`,\n rejectedCount: (name, maxFiles) =>\n `„${name}“ wurde nicht hinzugefügt: höchstens ${n(maxFiles)} ${maxFiles === 1 ? \"Datei\" : \"Dateien\"}`,\n rejectedInvalid: (name) => `„${name}“ kann hier nicht verwendet werden`,\n rejectedMany: (count) =>\n count === 1\n ? \"1 Datei wurde nicht hinzugefügt\"\n : `${n(count)} Dateien wurden nicht hinzugefügt`,\n selected: (count, firstName) =>\n count === 1 ? `„${firstName}“ ausgewählt` : `${n(count)} Dateien ausgewählt`,\n remove: (name) => `„${name}“ entfernen`,\n clearAll: \"Alle Dateien entfernen\",\n removed: (name) => `„${name}“ entfernt`,\n cleared: \"Alle Dateien entfernt\",\n },\n wizard: {\n done: \"Fertig\",\n cancel: \"Abbrechen\",\n back: \"Zurück\",\n next: \"Weiter\",\n skip: \"Überspringen\",\n finish: \"Abschließen\",\n submitting: \"Wird erstellt…\",\n steps: \"Schritte\",\n step: (current, total) => `Schritt ${n(current)} von ${n(total)}`,\n cancelTitle: \"Formular verwerfen?\",\n confirmCancel: \"Ihre Eingaben gehen verloren.\",\n cancelConfirmLabel: \"Verwerfen\",\n cancelDismissLabel: \"Weiter bearbeiten\",\n reviewTitle: \"Überprüfen\",\n edit: \"Bearbeiten\",\n missingRequired: \"Bitte füllen Sie alle Pflichtfelder aus.\",\n genericError: \"Ein Fehler ist aufgetreten\",\n },\n tour: {\n next: \"Weiter\",\n back: \"Zurück\",\n skip: \"Überspringen\",\n done: \"Fertig\",\n awaitClickHint: \"Klicken Sie auf das hervorgehobene Element, um fortzufahren\",\n step: (current, total) => `${n(current)} / ${n(total)}`,\n },\n commandPalette: {\n clear: \"Suche löschen\",\n submit: \"Suchen\",\n close: \"Schließen\",\n placeholder: \"Suchen…\",\n empty: \"Keine Ergebnisse\",\n loading: \"Wird gesucht…\",\n dialog: \"Suche\",\n error: \"Die Suche ist fehlgeschlagen. Bitte erneut versuchen.\",\n },\n globalSearch: {\n trigger: \"Suche\",\n placeholder: \"Suchen oder springen zu…\",\n shortcut: (keys) => `Suche (${keys})`,\n suggestions: \"Vorschläge\",\n results: \"Ergebnisse\",\n },\n sparkline: {\n rising: (first, last) => `Steigend von ${first} auf ${last}`,\n falling: (first, last) => `Fallend von ${first} auf ${last}`,\n flat: (value) => `Unverändert bei ${value}`,\n single: (value) => `Ein Wert: ${value}`,\n noData: \"Keine Daten\",\n named: (name, summary) => `${name}: ${summary}`,\n },\n statTile: {\n // `amount` arrives formatted and unsigned (\"5 %\", \"1.200 €\").\n increase: (amount) => `Um ${amount} gestiegen`,\n decrease: (amount) => `Um ${amount} gesunken`,\n unchanged: \"Keine Veränderung\",\n better: (change) => `${change} (besser)`,\n worse: (change) => `${change} (schlechter)`,\n noValue: \"Keine Daten\",\n loading: \"Wird geladen…\",\n },\n signaturePad: {\n label: \"Unterschrift\",\n instructions: \"Unterschreiben Sie im Feld mit der Maus, dem Finger oder einem Stift.\",\n typedFallbackHint: \"Wenn Sie nicht zeichnen können, geben Sie stattdessen Ihren Namen ein.\",\n empty: \"Noch nichts gezeichnet\",\n signed: \"Unterschrift gezeichnet\",\n undo: \"Letzten Strich rückgängig machen\",\n clear: \"Leeren\",\n save: \"Unterschrift speichern\",\n useTyped: \"Stattdessen Namen eingeben\",\n useDrawn: \"Stattdessen zeichnen\",\n typedName: \"Vollständiger Name\",\n cleared: \"Unterschrift gelöscht\",\n undone: \"Letzter Strich entfernt\",\n viewEmpty: \"Nicht unterschrieben\",\n viewDrawn: \"Handschriftliche Unterschrift\",\n viewTyped: (name) => `Unterschrieben mit dem eingegebenen Namen ${name}`,\n },\n passwordStrength: {\n tooShort: \"Zu kurz\",\n weak: \"Schwach\",\n fair: \"Mittel\",\n good: \"Gut\",\n strong: \"Stark\",\n announcement: (level) => `Passwortstärke: ${level}`,\n // \"Zeichen\" is the same in singular and plural. The English default does not\n // format these counts, so neither does this file.\n ruleLength: (minLength) => `Mindestens ${minLength} Zeichen`,\n ruleCase: \"Groß- und Kleinbuchstaben\",\n ruleDigit: \"Eine Ziffer\",\n ruleSymbol: \"Ein Sonderzeichen\",\n optional: (rule) => `${rule} (optional)`,\n met: \"Erfüllt:\",\n notMet: \"Nicht erfüllt:\",\n tooLong: (maxBytes) =>\n `Höchstens ${maxBytes} Zeichen (Buchstaben mit Akzent und Emojis zählen mehrfach).`,\n },\n seriesChart: {\n resetZoom: \"Zoom zurücksetzen\",\n zoomHint:\n \"Zum Zoomen ziehen: Eine annähernd quadratische Auswahl zoomt beide Achsen, eine lange, schmale nur ihre eigene. Doppelklick setzt zurück.\",\n empty: \"Keine Daten\",\n legend: \"Datenreihen\",\n points: \"Diagrammwerte\",\n },\n confirmDialog: {\n confirm: \"Bestätigen\",\n cancel: \"Abbrechen\",\n },\n floatingPanel: {\n close: \"Schließen\",\n },\n copyButton: {\n copy: \"Kopieren\",\n copied: \"Kopiert\",\n failed: \"Kopieren fehlgeschlagen\",\n copiedAnnouncement: \"In die Zwischenablage kopiert\",\n failedAnnouncement: \"Kopieren in die Zwischenablage fehlgeschlagen\",\n },\n list: {\n unread: \"Ungelesen\",\n opensInNewTab: \"öffnet in einem neuen Tab\",\n },\n breadcrumbs: {\n label: \"Brotkrümelnavigation\",\n showAll: \"Vollständigen Pfad anzeigen\",\n },\n toast: {\n close: \"Benachrichtigung schließen\",\n notifications: \"Benachrichtigungen\",\n undo: \"Rückgängig\",\n redo: \"Wiederholen\",\n },\n };\n}\n\nexport const UI_KIT_LABELS_DE: UiKitLabels = uiKitLabelsDe();\n"],"mappings":";AAAA,SAAS,sBAAsB;AAYxB,SAAS,cAAc,eAAe,SAAsB;AACjE,QAAM,MAAM,IAAI,KAAK,aAAa,YAAY;AAC9C,QAAM,IAAI,CAAC,UAAkB,IAAI,OAAO,KAAK;AAE7C,SAAO;AAAA,IACL,oBAAoB;AAAA,MAClB,eAAe;AAAA,MACf,mBAAmB;AAAA,MACnB,iBAAiB;AAAA,MACjB,kBAAkB;AAAA,IACpB;AAAA,IACA,cAAc;AAAA,MACZ,MAAM;AAAA,MACN,WAAW;AAAA,MACX,UAAU;AAAA,MACV,QAAQ;AAAA,MACR,WAAW,CAAC,QAAQ,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AA,MACT,QAAQ;AAAA,MACR,WAAW;AAAA,MACX,WAAW;AAAA,MACX,WAAW,CAAC,SAAS,6CAA6C,IAAI;AAAA,IACxE;AAAA,IACA,kBAAkB;AAAA,MAChB,UAAU;AAAA,MACV,MAAM;AAAA,MACN,MAAM;AAAA,MACN,MAAM;AAAA,MACN,QAAQ;AAAA,MACR,cAAc,CAAC,UAAU,sBAAmB,KAAK;AAAA;AAAA;AAAA,MAGjD,YAAY,CAAC,cAAc,cAAc,SAAS;AAAA,MAClD,UAAU;AAAA,MACV,WAAW;AAAA,MACX,YAAY;AAAA,MACZ,UAAU,CAAC,SAAS,GAAG,IAAI;AAAA,MAC3B,KAAK;AAAA,MACL,QAAQ;AAAA,MACR,SAAS,CAAC,aACR,gBAAa,QAAQ;AAAA,IACzB;AAAA,IACA,aAAa;AAAA,MACX,WAAW;AAAA,MACX,UACE;AAAA,MACF,OAAO;AAAA,MACP,QAAQ;AAAA,MACR,QAAQ;AAAA,IACV;AAAA,IACA,eAAe;AAAA,MACb,SAAS;AAAA,MACT,QAAQ;AAAA,IACV;AAAA,IACA,eAAe;AAAA,MACb,OAAO;AAAA,IACT;AAAA,IACA,YAAY;AAAA,MACV,MAAM;AAAA,MACN,QAAQ;AAAA,MACR,QAAQ;AAAA,MACR,oBAAoB;AAAA,MACpB,oBAAoB;AAAA,IACtB;AAAA,IACA,MAAM;AAAA,MACJ,QAAQ;AAAA,MACR,eAAe;AAAA,IACjB;AAAA,IACA,aAAa;AAAA,MACX,OAAO;AAAA,MACP,SAAS;AAAA,IACX;AAAA,IACA,OAAO;AAAA,MACL,OAAO;AAAA,MACP,eAAe;AAAA,MACf,MAAM;AAAA,MACN,MAAM;AAAA,IACR;AAAA,EACF;AACF;AAEO,MAAM,mBAAgC,cAAc;","names":[]}
|
|
@@ -34,6 +34,10 @@ import '../../feedback/feedback-dialog.js';
|
|
|
34
34
|
import '../../components/confirm-dialog.js';
|
|
35
35
|
import '../../components/floating-panel.js';
|
|
36
36
|
import '../../components/copy-button.js';
|
|
37
|
+
import '../../components/bulk-action-bar.js';
|
|
38
|
+
import '../../components/list.js';
|
|
39
|
+
import '../../components/breadcrumbs.js';
|
|
40
|
+
import '../../components/toast.js';
|
|
37
41
|
|
|
38
42
|
/**
|
|
39
43
|
* The kit's words in Spanish: every namespace of {@link UiKitLabels}, for
|
package/dist/i18n/locales/es.js
CHANGED
|
@@ -220,6 +220,11 @@ function uiKitLabelsEs(numberLocale = "es-ES") {
|
|
|
220
220
|
dialogFrame: {
|
|
221
221
|
close: "Cerrar"
|
|
222
222
|
},
|
|
223
|
+
bulkActionBar: {
|
|
224
|
+
selected: (count) => `${n(count)} ${count === 1 ? "seleccionado" : "seleccionados"}`,
|
|
225
|
+
clear: "Borrar selecci\xF3n",
|
|
226
|
+
cleared: "Selecci\xF3n borrada"
|
|
227
|
+
},
|
|
223
228
|
swipeableRow: {
|
|
224
229
|
actions: "Acciones de la fila"
|
|
225
230
|
},
|
|
@@ -348,7 +353,8 @@ function uiKitLabelsEs(numberLocale = "es-ES") {
|
|
|
348
353
|
resetZoom: "Restablecer zoom",
|
|
349
354
|
zoomHint: "Arrastra para ampliar: una selecci\xF3n m\xE1s o menos cuadrada ampl\xEDa ambos ejes; una larga y estrecha, solo el suyo. Haz doble clic para restablecer.",
|
|
350
355
|
empty: "Sin datos",
|
|
351
|
-
legend: "Series"
|
|
356
|
+
legend: "Series",
|
|
357
|
+
points: "Valores del gr\xE1fico"
|
|
352
358
|
},
|
|
353
359
|
confirmDialog: {
|
|
354
360
|
confirm: "Confirmar",
|
|
@@ -363,6 +369,20 @@ function uiKitLabelsEs(numberLocale = "es-ES") {
|
|
|
363
369
|
failed: "No se pudo copiar",
|
|
364
370
|
copiedAnnouncement: "Copiado al portapapeles",
|
|
365
371
|
failedAnnouncement: "No se pudo copiar al portapapeles"
|
|
372
|
+
},
|
|
373
|
+
list: {
|
|
374
|
+
unread: "No le\xEDdo",
|
|
375
|
+
opensInNewTab: "se abre en una pesta\xF1a nueva"
|
|
376
|
+
},
|
|
377
|
+
breadcrumbs: {
|
|
378
|
+
label: "Ruta de navegaci\xF3n",
|
|
379
|
+
showAll: "Mostrar la ruta completa"
|
|
380
|
+
},
|
|
381
|
+
toast: {
|
|
382
|
+
close: "Cerrar notificaci\xF3n",
|
|
383
|
+
notifications: "Notificaciones",
|
|
384
|
+
undo: "Deshacer",
|
|
385
|
+
redo: "Rehacer"
|
|
366
386
|
}
|
|
367
387
|
};
|
|
368
388
|
}
|