@lmvz-ds/components 0.18.2 → 0.19.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.
Files changed (104) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/README.md +45 -100
  3. package/cjs/ds.constants-DSnxZ3ia.js +16 -0
  4. package/cjs/{icons-swqMn6s2.js → icons-Tg7ySOh-.js} +54 -38
  5. package/cjs/index.cjs.js +9 -10
  6. package/cjs/lmvz-button.cjs.entry.js +2 -2
  7. package/cjs/lmvz-chip.cjs.entry.js +68 -4
  8. package/cjs/lmvz-components.cjs.js +1 -1
  9. package/cjs/lmvz-header_2.cjs.entry.js +2 -2
  10. package/cjs/lmvz-icon.cjs.entry.js +6 -6
  11. package/cjs/lmvz-input.cjs.entry.js +3 -3
  12. package/cjs/lmvz-menuitem.cjs.entry.js +2 -2
  13. package/cjs/lmvz-select.cjs.entry.js +2 -2
  14. package/cjs/loader.cjs.js +1 -1
  15. package/cjs/{reactive-controller-host-CtaVAiYJ.js → reactive-controller-host-Bi9eu2bV.js} +9 -9
  16. package/collection/api/ds.constants.js +2 -0
  17. package/collection/components/lmvz-button/lmvz-button.js +6 -3
  18. package/collection/components/lmvz-chip/lmvz-chip.css +84 -1
  19. package/collection/components/lmvz-chip/lmvz-chip.js +110 -13
  20. package/collection/components/lmvz-header/lmvz-header.js +2 -2
  21. package/collection/components/lmvz-icon/lmvz-icon.css +11 -10
  22. package/collection/components/lmvz-icon/lmvz-icon.js +7 -6
  23. package/collection/components/lmvz-input/lmvz-input.js +4 -4
  24. package/collection/components/lmvz-menuitem/lmvz-menuitem.js +11 -5
  25. package/collection/components/lmvz-select/lmvz-select.js +1 -1
  26. package/collection/index.js +1 -1
  27. package/collection/integration/header-integration/header-integration.js +1 -1
  28. package/collection/utils/aria/aria-validation-controller.js +1 -0
  29. package/collection/utils/reactive-controller-host.js +9 -9
  30. package/components/index.js +1 -1
  31. package/components/lmvz-button.js +1 -1
  32. package/components/lmvz-chip.js +1 -1
  33. package/components/lmvz-header.js +1 -1
  34. package/components/lmvz-icon.js +1 -1
  35. package/components/lmvz-input.js +1 -1
  36. package/components/lmvz-menuitem.js +1 -1
  37. package/components/lmvz-select.js +1 -1
  38. package/components/{p-DQEkWkMh.js → p-DIrAQ4IB.js} +1 -1
  39. package/esm/{aria-loader-BF_AYtbb.js → aria-loader-CES8Ae1e.js} +1 -1
  40. package/esm/ds.constants-Bmi89ll1.js +9 -0
  41. package/esm/{icons-Ca8oMiRa.js → icons-Bj4dF1-I.js} +55 -40
  42. package/esm/{index-7Ru1khgk.js → index-BvxaUA12.js} +1 -1
  43. package/esm/index.js +4 -11
  44. package/esm/lmvz-button.entry.js +3 -3
  45. package/esm/lmvz-chip.entry.js +69 -5
  46. package/esm/lmvz-components.js +1 -1
  47. package/esm/lmvz-header_2.entry.js +3 -3
  48. package/esm/lmvz-icon.entry.js +7 -7
  49. package/esm/lmvz-input.entry.js +4 -4
  50. package/esm/lmvz-menuitem.entry.js +3 -3
  51. package/esm/lmvz-select.entry.js +3 -3
  52. package/esm/loader.js +1 -1
  53. package/esm/{logger-fiRXhuXK.js → logger-0bL3pydp.js} +1 -1
  54. package/esm/{reactive-controller-host-sR2jJxNG.js → reactive-controller-host-J2thAxVH.js} +10 -10
  55. package/hydrate/index.js +92 -27
  56. package/hydrate/index.mjs +92 -27
  57. package/lmvz-components/index.esm.js +1 -1
  58. package/lmvz-components/lmvz-components.esm.js +1 -1
  59. package/lmvz-components/{p-fiRXhuXK.js → p-0bL3pydp.js} +1 -1
  60. package/lmvz-components/p-40569208.entry.js +1 -0
  61. package/lmvz-components/p-49ab22bd.entry.js +1 -0
  62. package/lmvz-components/{p-6dbb3f13.entry.js → p-6e8acbd9.entry.js} +1 -1
  63. package/lmvz-components/{p-59383f3a.entry.js → p-9212bd23.entry.js} +1 -1
  64. package/lmvz-components/p-9626e951.entry.js +1 -0
  65. package/lmvz-components/p-Bmi89ll1.js +1 -0
  66. package/lmvz-components/p-Bu4Z_PMf.js +1 -0
  67. package/lmvz-components/{p-Bkfdgg0T.js → p-BxHnZA0M.js} +1 -1
  68. package/lmvz-components/{p-DXOTa5VF.js → p-DHZwxmLb.js} +1 -1
  69. package/lmvz-components/{p-B3dnXEPG.js → p-DYaffOLo.js} +1 -1
  70. package/lmvz-components/{p-84267405.entry.js → p-e1b847d2.entry.js} +1 -1
  71. package/lmvz-components/{p-5aa17cd2.entry.js → p-ec96c6b6.entry.js} +1 -1
  72. package/manifest.json +139 -32
  73. package/package.json +1 -1
  74. package/types/api/ds.constants.d.ts +6 -1
  75. package/types/components/lmvz-action/lmvz-action.d.ts +0 -1
  76. package/types/components/lmvz-button/lmvz-button.d.ts +0 -1
  77. package/types/components/lmvz-card/lmvz-card.d.ts +0 -1
  78. package/types/components/lmvz-chip/lmvz-chip.d.ts +18 -3
  79. package/types/components/lmvz-header/lmvz-header.d.ts +0 -1
  80. package/types/components/lmvz-icon/lmvz-icon.d.ts +0 -1
  81. package/types/components/lmvz-input/lmvz-input.d.ts +0 -1
  82. package/types/components/lmvz-menuitem/lmvz-menuitem.d.ts +0 -1
  83. package/types/components/lmvz-select/lmvz-select.d.ts +0 -1
  84. package/types/components.d.ts +70 -12
  85. package/types/index.d.ts +1 -2
  86. package/types/utils/aria/aria-validation-controller.d.ts +1 -2
  87. package/types/utils/aria/element-activation-controller.d.ts +0 -1
  88. package/types/utils/aria/list-keyboard-controller.d.ts +0 -1
  89. package/types/utils/assets.d.ts +0 -1
  90. package/types/utils/component.d.ts +0 -1
  91. package/types/utils/environment.d.ts +0 -1
  92. package/types/utils/http.d.ts +0 -1
  93. package/types/utils/http.unit.d.ts +0 -1
  94. package/types/utils/icons/icons-registry.d.ts +0 -1
  95. package/types/utils/icons/icons.d.ts +0 -1
  96. package/types/utils/icons/icons.unit.d.ts +0 -1
  97. package/types/utils/icons/public.d.ts +0 -1
  98. package/types/utils/public.d.ts +0 -1
  99. package/types/utils/reactive-controller-host.d.ts +0 -1
  100. package/lmvz-components/p-0a41cc24.entry.js +0 -1
  101. package/lmvz-components/p-30b99f11.entry.js +0 -1
  102. package/lmvz-components/p-5f150890.entry.js +0 -1
  103. package/lmvz-components/p-Bh2Epkwf.js +0 -1
  104. /package/components/{p-CBLAeife.js → p-DbeHBSOe.js} +0 -0
@@ -5,6 +5,15 @@ export declare namespace Button {
5
5
  export type Variant = LmvzDS.Variant;
6
6
  }
7
7
 
8
+ export declare namespace Chip {
9
+ export type Type = (typeof chipTypes)[number];
10
+ export type Size = (typeof chipSizes)[number];
11
+ }
12
+
13
+ declare const chipSizes: readonly ["default", "small"];
14
+
15
+ declare const chipTypes: readonly ["active", "warning", "success", "error", "neutral"];
16
+
8
17
  export declare namespace Components {
9
18
  export interface LmvzAction {
10
19
  }
@@ -29,6 +38,7 @@ export declare namespace Components {
29
38
  */
30
39
  "ti": number;
31
40
  /**
41
+ * Native button type forwarded to the internal `<button>` element. Use `submit` to trigger form submission.
32
42
  * @default 'button'
33
43
  */
34
44
  "type": 'submit' | 'button';
@@ -57,13 +67,28 @@ export declare namespace Components {
57
67
  */
58
68
  "primaryActionLabel": string;
59
69
  }
70
+ /**
71
+ * The chip displays a compact semantic status as a non-interactive UI element.
72
+ */
60
73
  export interface LmvzChip {
61
- "text": string;
74
+ /**
75
+ * Size variant of the chip. Invalid values are normalized to `default` at runtime.
76
+ * @default 'default'
77
+ */
78
+ "size": Chip.Size;
79
+ /**
80
+ * Semantic variant of the chip. Invalid values are normalized to `active` at runtime.
81
+ * @default 'active'
82
+ */
83
+ "type": Chip.Type;
62
84
  }
63
85
  /**
64
86
  * An accessible, application-style navigation header component, that renders two connected levels of navigation.
65
87
  */
66
88
  export interface LmvzHeader {
89
+ /**
90
+ * Id of the currently active primary navigation item. Also determines which `connect-nav-*` secondary slot is shown.
91
+ */
67
92
  "lmvzActiveNav"?: string;
68
93
  /**
69
94
  * @readonly
@@ -77,13 +102,16 @@ export declare namespace Components {
77
102
  * Loading is deferred, using an IntersectionObserver, until the instance becomes visible in the viewport.
78
103
  */
79
104
  export interface LmvzIcon {
105
+ /**
106
+ * Accessible name for assistive technology. Leave unset for decorative icons so the icon stays hidden from the accessibility tree.
107
+ */
80
108
  "ariaLabel"?: string;
81
109
  /**
82
- * Required Either a valid name from a registered iconset, or the icon's SVG content (inline). Will be checked against the (default) iconset.
110
+ * Required Either a valid name from a registered iconset, or the icon's SVG content (inline). Will be checked against the chosen {@link iconset}.
83
111
  */
84
112
  "icon": SVGString | string;
85
113
  /**
86
- * Optional custom icon iconset id. Must reference a registered custom iconset by its exported name.
114
+ * Optional custom icon iconset id. Must reference a registered custom iconset by its exported name. Will try to resolve from the default iconset if not provided.
87
115
  */
88
116
  "iconset"?: string;
89
117
  /**
@@ -226,6 +254,9 @@ export declare namespace Components {
226
254
  * Selects the text in the input
227
255
  */
228
256
  "select": () => Promise<void>;
257
+ /**
258
+ * Updates the value programmatically and emits `lmvzInput` with the new value.
259
+ */
229
260
  "setValue": (newValue: string | undefined) => Promise<void>;
230
261
  /**
231
262
  * Spellcheck attribute
@@ -251,13 +282,15 @@ export declare namespace Components {
251
282
  */
252
283
  export interface LmvzMenuitem {
253
284
  /**
254
- * @readonly
285
+ * Accessibility role exposed by the host element.
255
286
  * @default 'menuitem'
287
+ * @readonly
256
288
  */
257
289
  "role": string;
258
290
  /**
259
- * @readonly
291
+ * Keeps the host focusable for keyboard navigation inside `lmvz-header`.
260
292
  * @default 0
293
+ * @readonly
261
294
  */
262
295
  "ti": number;
263
296
  }
@@ -357,6 +390,7 @@ export declare namespace JSX {
357
390
  */
358
391
  "ti"?: number;
359
392
  /**
393
+ * Native button type forwarded to the internal `<button>` element. Use `submit` to trigger form submission.
360
394
  * @default 'button'
361
395
  */
362
396
  "type"?: 'submit' | 'button';
@@ -389,13 +423,28 @@ export declare namespace JSX {
389
423
  */
390
424
  "primaryActionLabel"?: string;
391
425
  }
426
+ /**
427
+ * The chip displays a compact semantic status as a non-interactive UI element.
428
+ */
392
429
  export interface LmvzChip {
393
- "text": string;
430
+ /**
431
+ * Size variant of the chip. Invalid values are normalized to `default` at runtime.
432
+ * @default 'default'
433
+ */
434
+ "size"?: Chip.Size;
435
+ /**
436
+ * Semantic variant of the chip. Invalid values are normalized to `active` at runtime.
437
+ * @default 'active'
438
+ */
439
+ "type"?: Chip.Type;
394
440
  }
395
441
  /**
396
442
  * An accessible, application-style navigation header component, that renders two connected levels of navigation.
397
443
  */
398
444
  export interface LmvzHeader {
445
+ /**
446
+ * Id of the currently active primary navigation item. Also determines which `connect-nav-*` secondary slot is shown.
447
+ */
399
448
  "lmvzActiveNav"?: string;
400
449
  /**
401
450
  * @readonly
@@ -409,13 +458,16 @@ export declare namespace JSX {
409
458
  * Loading is deferred, using an IntersectionObserver, until the instance becomes visible in the viewport.
410
459
  */
411
460
  export interface LmvzIcon {
461
+ /**
462
+ * Accessible name for assistive technology. Leave unset for decorative icons so the icon stays hidden from the accessibility tree.
463
+ */
412
464
  "ariaLabel"?: string;
413
465
  /**
414
- * Required Either a valid name from a registered iconset, or the icon's SVG content (inline). Will be checked against the (default) iconset.
466
+ * Required Either a valid name from a registered iconset, or the icon's SVG content (inline). Will be checked against the chosen {@link iconset}.
415
467
  */
416
468
  "icon": SVGString | string;
417
469
  /**
418
- * Optional custom icon iconset id. Must reference a registered custom iconset by its exported name.
470
+ * Optional custom icon iconset id. Must reference a registered custom iconset by its exported name. Will try to resolve from the default iconset if not provided.
419
471
  */
420
472
  "iconset"?: string;
421
473
  /**
@@ -516,6 +568,9 @@ export declare namespace JSX {
516
568
  * Name attribute for the input
517
569
  */
518
570
  "name"?: string;
571
+ /**
572
+ * Emitted whenever the input value changes. Event detail contains the current value.
573
+ */
519
574
  "onLmvzInput"?: (event: LmvzInputCustomEvent<string>) => void;
520
575
  /**
521
576
  * Validation pattern (regex)
@@ -563,13 +618,15 @@ export declare namespace JSX {
563
618
  */
564
619
  "onLmvzActivation"?: (event: LmvzMenuitemCustomEvent<void>) => void;
565
620
  /**
566
- * @readonly
621
+ * Accessibility role exposed by the host element.
567
622
  * @default 'menuitem'
623
+ * @readonly
568
624
  */
569
625
  "role"?: string;
570
626
  /**
571
- * @readonly
627
+ * Keeps the host focusable for keyboard navigation inside `lmvz-header`.
572
628
  * @default 0
629
+ * @readonly
573
630
  */
574
631
  "ti"?: number;
575
632
  }
@@ -636,7 +693,8 @@ export declare namespace JSX {
636
693
  "primaryActionLabel": string;
637
694
  }
638
695
  export interface LmvzChipAttributes {
639
- "text": string;
696
+ "type": Chip.Type;
697
+ "size": Chip.Size;
640
698
  }
641
699
  export interface LmvzHeaderAttributes {
642
700
  "role": string;
@@ -692,7 +750,7 @@ export declare namespace JSX {
692
750
  "lmvz-action": LmvzAction;
693
751
  "lmvz-button": Omit<LmvzButton, keyof LmvzButtonAttributes> & { [K in keyof LmvzButton & keyof LmvzButtonAttributes]?: LmvzButton[K] } & { [K in keyof LmvzButton & keyof LmvzButtonAttributes as `attr:${K}`]?: LmvzButtonAttributes[K] } & { [K in keyof LmvzButton & keyof LmvzButtonAttributes as `prop:${K}`]?: LmvzButton[K] };
694
752
  "lmvz-card": Omit<LmvzCard, keyof LmvzCardAttributes> & { [K in keyof LmvzCard & keyof LmvzCardAttributes]?: LmvzCard[K] } & { [K in keyof LmvzCard & keyof LmvzCardAttributes as `attr:${K}`]?: LmvzCardAttributes[K] } & { [K in keyof LmvzCard & keyof LmvzCardAttributes as `prop:${K}`]?: LmvzCard[K] } & OneOf<"cardTitle", LmvzCard["cardTitle"], LmvzCardAttributes["cardTitle"]>;
695
- "lmvz-chip": Omit<LmvzChip, keyof LmvzChipAttributes> & { [K in keyof LmvzChip & keyof LmvzChipAttributes]?: LmvzChip[K] } & { [K in keyof LmvzChip & keyof LmvzChipAttributes as `attr:${K}`]?: LmvzChipAttributes[K] } & { [K in keyof LmvzChip & keyof LmvzChipAttributes as `prop:${K}`]?: LmvzChip[K] } & OneOf<"text", LmvzChip["text"], LmvzChipAttributes["text"]>;
753
+ "lmvz-chip": Omit<LmvzChip, keyof LmvzChipAttributes> & { [K in keyof LmvzChip & keyof LmvzChipAttributes]?: LmvzChip[K] } & { [K in keyof LmvzChip & keyof LmvzChipAttributes as `attr:${K}`]?: LmvzChipAttributes[K] } & { [K in keyof LmvzChip & keyof LmvzChipAttributes as `prop:${K}`]?: LmvzChip[K] };
696
754
  "lmvz-header": Omit<LmvzHeader, keyof LmvzHeaderAttributes> & { [K in keyof LmvzHeader & keyof LmvzHeaderAttributes]?: LmvzHeader[K] } & { [K in keyof LmvzHeader & keyof LmvzHeaderAttributes as `attr:${K}`]?: LmvzHeaderAttributes[K] } & { [K in keyof LmvzHeader & keyof LmvzHeaderAttributes as `prop:${K}`]?: LmvzHeader[K] };
697
755
  "lmvz-icon": Omit<LmvzIcon, keyof LmvzIconAttributes> & { [K in keyof LmvzIcon & keyof LmvzIconAttributes]?: LmvzIcon[K] } & { [K in keyof LmvzIcon & keyof LmvzIconAttributes as `attr:${K}`]?: LmvzIconAttributes[K] } & { [K in keyof LmvzIcon & keyof LmvzIconAttributes as `prop:${K}`]?: LmvzIcon[K] } & OneOf<"icon", LmvzIcon["icon"], LmvzIconAttributes["icon"]>;
698
756
  "lmvz-input": Omit<LmvzInput, keyof LmvzInputAttributes> & { [K in keyof LmvzInput & keyof LmvzInputAttributes]?: LmvzInput[K] } & { [K in keyof LmvzInput & keyof LmvzInputAttributes as `attr:${K}`]?: LmvzInputAttributes[K] } & { [K in keyof LmvzInput & keyof LmvzInputAttributes as `prop:${K}`]?: LmvzInput[K] } & OneOf<"label", LmvzInput["label"], LmvzInputAttributes["label"]>;
package/types/index.d.ts CHANGED
@@ -1,6 +1,5 @@
1
1
  export * from '@lmvz-ds/aria-validation';
2
2
  export type * from './components.d.ts';
3
- export { iconSizes, iconWeights, inputTypes, textSizes } from './api/ds.constants';
3
+ export { chipSizes, chipTypes, iconSizes, iconWeights, inputTypes, textSizes } from './api/ds.constants';
4
4
  export type { LmvzDS, Typography } from './api';
5
5
  export * from './utils/public';
6
- //# sourceMappingURL=index.d.ts.map
@@ -1,4 +1,5 @@
1
1
  import type { ReactiveController } from '../reactive-controller-host';
2
+ export { isAriaValidationEnabled } from '@lmvz-ds/aria-validation';
2
3
  export type AriaValidationHost<T extends HTMLElement = HTMLElement> = {
3
4
  validationEl: T | undefined;
4
5
  validationSlot?: HTMLSlotElement;
@@ -30,5 +31,3 @@ export declare class AriaValidationController implements ReactiveController {
30
31
  private enqueueValidation;
31
32
  private discardVisibilityObserver;
32
33
  }
33
- export {};
34
- //# sourceMappingURL=aria-validation-controller.d.ts.map
@@ -17,4 +17,3 @@ export declare class ElementActivationController implements ReactiveController {
17
17
  private handleActivation;
18
18
  }
19
19
  export {};
20
- //# sourceMappingURL=element-activation-controller.d.ts.map
@@ -11,4 +11,3 @@ export declare class ListKeyboardNavigationController implements ReactiveControl
11
11
  private handleKeydown;
12
12
  private getNextFocusableElement;
13
13
  }
14
- //# sourceMappingURL=list-keyboard-controller.d.ts.map
@@ -1,2 +1 @@
1
1
  export declare const createAssetUrlSafely: (file: string, pathFromAssetRoot?: string | undefined) => string | URL;
2
- //# sourceMappingURL=assets.d.ts.map
@@ -31,4 +31,3 @@ export declare const isSafeNumber: (input: unknown) => input is number;
31
31
  export declare function getDeepActiveElement(root?: Document): Element | null;
32
32
  export declare function canReceiveFocus(el: Element | undefined): boolean;
33
33
  export declare function findFormByRef(form: FormRef, el: HTMLElement): HTMLFormElement | null;
34
- //# sourceMappingURL=component.d.ts.map
@@ -1,2 +1 @@
1
1
  export declare function getLocationBase(): string;
2
- //# sourceMappingURL=environment.d.ts.map
@@ -24,4 +24,3 @@ export declare class ResponseTextError extends ResponseTextError_base<{
24
24
  }
25
25
  export declare const responseAsText: (res: Response) => Micro.Micro<string, ResponseTextError, never>;
26
26
  export {};
27
- //# sourceMappingURL=http.d.ts.map
@@ -1,2 +1 @@
1
1
  export {};
2
- //# sourceMappingURL=http.unit.d.ts.map
@@ -10,4 +10,3 @@ export declare function registerIconProvider<I extends KnownIconSetId>(id: I, pr
10
10
  export declare function getRegisteredIconProvider<I extends KnownIconSetId>(id: I): IconProvider<KnownIconName<I>> | undefined;
11
11
  export declare function getRegisteredIconProvider(id?: string | undefined): IconProvider<string> | undefined;
12
12
  export {};
13
- //# sourceMappingURL=icons-registry.d.ts.map
@@ -5,4 +5,3 @@ export declare const emptyDefaultSvg: () => import("@lmvz-ds/lib-ts/validation/S
5
5
  export declare function resolveIconSvg<I extends KnownIconSetId>(options: IconPropsForSet<I>): Promise<IconData>;
6
6
  export declare function resolveIconSvg(options: IconPropsFallback): Promise<IconData>;
7
7
  export declare function typedIconFromSet<S extends string>(iconset: S, icon: IconPropsForSetWithoutFallback<S>['icon']): IconPropsForSetWithoutFallback<S>;
8
- //# sourceMappingURL=icons.d.ts.map
@@ -5,4 +5,3 @@ declare module '@lmvz-ds/lib-icon-api' {
5
5
  }
6
6
  }
7
7
  export {};
8
- //# sourceMappingURL=icons.unit.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export type { IconSetNameMap } from '@lmvz-ds/lib-icon-api';
2
2
  export { getRegisteredIconProvider, registerIconProvider } from './icons-registry.js';
3
3
  export { typedIconFromSet } from './icons.js';
4
- //# sourceMappingURL=public.d.ts.map
@@ -1,2 +1 @@
1
1
  export * from './icons/public';
2
- //# sourceMappingURL=public.d.ts.map
@@ -24,4 +24,3 @@ export declare class ReactiveControllerHost implements ComponentInterface {
24
24
  componentWillUpdate(): void;
25
25
  componentDidUpdate(): void;
26
26
  }
27
- //# sourceMappingURL=reactive-controller-host.d.ts.map
@@ -1 +0,0 @@
1
- import{g as i,r as e,h as t,H as s}from"./p-saW7O-EW.js";import{i as o,a as n}from"./p-Bh2Epkwf.js";import{R as r,A as c}from"./p-Bkfdgg0T.js";import"./p-fiRXhuXK.js";import"./p-B3dnXEPG.js";const m=class extends r{intersectionObserver;ariaValidationController=new c(this);get el(){return i(this)}validationEl;icon;weight="medium";size="md";iconset;iconData;visible=!1;ariaLabel;get ariaHidden(){return!this.ariaLabel}constructor(i){super(),e(this,i),this.addController(this.ariaValidationController)}connectedCallback(){this.waitUntilVisible((()=>{this.visible=!0,this.loadIconPathData()})),super.connectedCallback()}disconnectedCallback(){this.intersectionObserver&&"function"==typeof this.intersectionObserver.disconnect&&this.intersectionObserver.disconnect(),this.intersectionObserver=void 0,super.disconnectedCallback()}async loadIconPathData(){const{icon:i,iconset:e,visible:t}=this;i&&t&&(this.iconData=o(i)?i:await n({icon:i,iconset:e}))}componentDidRender(){this.validationEl=this.el.querySelector("svg"),this.ariaValidationController.revalidateAria(),super.componentDidRender()}render(){return t(s,{key:"6022ed0e30bcdd13455ccaae65784ac70abcb349",role:"img","aria-hidden":`${this.ariaHidden}`,innerHTML:this.iconData})}waitUntilVisible(i,e=50){"undefined"!=typeof window&&window.IntersectionObserver?(this.intersectionObserver=new IntersectionObserver((e=>{e.some((e=>!!e.isIntersecting&&(this.intersectionObserver&&"function"==typeof this.intersectionObserver.disconnect&&this.intersectionObserver.disconnect(),this.intersectionObserver=void 0,i(),!0)))}),{rootMargin:`${e}px`}),this.intersectionObserver.observe(this.el)):i()}static get watchers(){return{icon:[{loadIconPathData:0}],iconset:[{loadIconPathData:0}]}}};m.style=".sc-lmvz-icon-h{--lmvz-icon-color:var(--lmvz-component-color, var(--lmvz-semantic-color-on-surface-input-primary, #000000));display:inline-block;line-height:0;svg{display:block}svg path{stroke:var(--lmvz-icon-color);fill:none}}[size='xs'].sc-lmvz-icon-h{svg{width:var(--lmvz-component-icon-size-xs, clamp(0.75rem, 0.72rem + 0.13vw, 0.88rem));height:var(--lmvz-component-icon-size-xs, clamp(0.75rem, 0.72rem + 0.13vw, 0.88rem))}}[size='sm'].sc-lmvz-icon-h{svg{width:var(--lmvz-component-icon-size-sm, clamp(0.88rem, 0.84rem + 0.13vw, 1rem));height:var(--lmvz-component-icon-size-sm, clamp(0.88rem, 0.84rem + 0.13vw, 1rem))}}[size='md'].sc-lmvz-icon-h{svg{width:var(--lmvz-component-icon-size-md, clamp(1rem, 0.94rem + 0.26vw, 1.25rem));height:var(--lmvz-component-icon-size-md, clamp(1rem, 0.94rem + 0.26vw, 1.25rem))}}[size='lg'].sc-lmvz-icon-h{svg{width:var(--lmvz-component-icon-size-lg, clamp(1.5rem, 1.44rem + 0.26vw, 1.75rem));height:var(--lmvz-component-icon-size-lg, clamp(1.5rem, 1.44rem + 0.26vw, 1.75rem))}}[size='inherit'].sc-lmvz-icon-h{svg{width:inherit;height:inherit}}[weight='light'].sc-lmvz-icon-h{svg path{stroke-width:1}}[weight='medium'].sc-lmvz-icon-h{svg path{stroke-width:1.5}}[weight='bold'].sc-lmvz-icon-h{svg path{stroke-width:2}}[weight='filled'].sc-lmvz-icon-h{svg path{stroke-width:2;fill:var(--lmvz-icon-color)}}";export{m as lmvz_icon}
@@ -1 +0,0 @@
1
- import{g as M,r as N,h as e,H as I}from"./p-saW7O-EW.js";import{R as j,A as D}from"./p-Bkfdgg0T.js";import{g,a as u}from"./p-DIrAQ4IB.js";export{lmvz_menuitem}from"./p-59383f3a.entry.js";import"./p-B3dnXEPG.js";import"./p-CN0JX9-m.js";class i{host;elements=[];constructor(M){this.host=M}hostDidRender(){this.host.el.addEventListener("keydown",this.handleKeydown)}updateElements(M){this.elements=M}handleKeydown=M=>{const{key:N}=M;if(!["ArrowDown","ArrowRight","ArrowUp","ArrowLeft"].includes(N))return;const e=g(document),I=this.getNextFocusableElement(e,["ArrowDown","ArrowRight"].includes(N)?"down":"up");I&&(M.preventDefault(),I.focus?.())};getNextFocusableElement(M,N){if(!M)return;const{elements:e}=this,I=e.indexOf(M);if(-1===I)return;let j;if("down"===N?j=(I+1)%e.length:"up"===N&&(j=(I-1+e.length)%e.length),null==j)return;const D=e[j];return u(D)?D:this.getNextFocusableElement(D,N)}}const a=class extends j{get el(){return M(this)}get validationEl(){return this.el}primarySlot;secondarySlot;secondaryNav;keyboardNavigationController=new i(this);get primaryMenuitems(){return this.primarySlot?.assignedElements({flatten:!1})||[]}get secondaryMenuitems(){return this.secondarySlot?.assignedElements({flatten:!0})||[]}get role(){return"banner"}lmvzActiveNav;get secondarySlotName(){return`connect-nav-${this.lmvzActiveNav}`}constructor(M){super(),N(this,M),this.addController(new D(this,{reValidateOnPropChanges:!0})),this.addController(this.keyboardNavigationController)}handleActiveNavChange(){this.updateElementsActive()}componentDidLoad(){this.primarySlot?.addEventListener("slotchange",this.handlePrimaryNavItemsChange.bind(this)),this.handlePrimaryNavItemsChange(),this.secondarySlot?.addEventListener("slotchange",this.handleSecondaryNavItemsChange.bind(this)),super.componentDidLoad()}handlePrimaryNavItemsChange(){const M=this.primaryMenuitems;M.length?(M.forEach((M=>{M.setAttribute("aria-haspopup","true"),M.setAttribute("aria-controls","nav-secondary")})),this.updateElementsActive(),this.updateKeyboardNavSubjects()):console.warn("Primary slot has no assigned elements. Please add navigation items to the primary slot.")}handleSecondaryNavItemsChange(){this.secondaryMenuitems.length&&this.updateKeyboardNavSubjects()}updateKeyboardNavSubjects(){this.keyboardNavigationController.updateElements([...this.primaryMenuitems,...this.secondaryMenuitems])}updateElementsActive(){const M=this.primaryMenuitems;if(!M.length)return;let N="";M.forEach((M=>{const e=M.id===this.lmvzActiveNav;e&&(N=M.textContent||M.id),M.setAttribute("aria-expanded",e?"true":"false")})),N&&this.secondaryNav?.setAttribute("aria-label",`Untermenü für ${N}`)}delegateFocus(){const M=this.primaryMenuitems[0];M&&M.focus()}render(){return e(I,{key:"96626b8d29cdefc8ed97a7bb68a689ff6155d2c7",onFocus:this.delegateFocus.bind(this)},e("div",{key:"41ac004bdc6c2c6a1f8e3d293f6b0c3727c27aff",class:"brand"},e("slot",{key:"8e33150a54c8b8070b22db51c8584e06dd06dd5c",name:"brand"},e("img",{key:"889955c7335d64f2c8d0b2e032db3dd64a27cbd2",id:"fallback-logo-lmvz",src:"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNDYiIGhlaWdodD0iNzIiIHZpZXdCb3g9IjAgMCA0NiA3MiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0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zMi44NSAyMS45IDM0LjE1IDIxLjkgMzUuNjVaTTI5LjcgNzEuNDVDMjguMiA3MS40NSAyNy4yIDcwLjQ1IDI3LjIgNjkuMTVDMjcuMiA2OC43NSAyNy4yIDY4LjI1IDI3LjggNjcuNDVMMzcuNCA1My40NUMzNy45IDUyLjc1IDM4LjUgNTIuMDUgMzkuMSA1MS4zNUgzMi4yQzMxLjUgNTEuMzUgMzAuNyA1MS42NSAzMC4xIDUxLjY1QzI4LjcgNTEuNjUgMjcuNiA1MC43NSAyNy42IDQ5LjM1QzI3LjYgNDcuOTUgMjguNyA0Ni45NSAzMC4xIDQ2Ljk1SDQyLjdDNDQuMiA0Ni45NSA0NS4yIDQ3Ljg1IDQ1LjIgNDkuMjVDNDUuMiA0OS42NSA0NSA1MC4zNSA0NC41IDUxLjA1TDM1LjIgNjQuODVDMzQuNyA2NS42NSAzNC4xIDY2LjQ1IDMzLjUgNjcuMDVINDEuMUM0MS45IDY3LjA1IDQyLjcgNjYuNzUgNDMuMyA2Ni43NUM0NC43IDY2Ljc1IDQ1LjcgNjcuNzUgNDUuNyA2OS4wNUM0NS43IDcwLjU1IDQ0LjUgNzEuNTUgNDMuMiA3MS41NUgyOS43VjcxLjQ1WiIgZmlsbD0iYmxhY2siLz4KPC9nPgo8ZGVmcz4KPGNsaXBQYXRoIGlkPSJjbGlwMF8yNzJfNDA1Ij4KPHJlY3Qgd2lkdGg9IjQ2IiBoZWlnaHQ9IjcyIiBmaWxsPSJ3aGl0ZSIvPgo8L2NsaXBQYXRoPgo8L2RlZnM+Cjwvc3ZnPgo=",alt:"Lehrmittelverlag Zürich"}))),e("nav",{key:"37b6ef465d320c325e0c830bcc91ea3a575d2690","aria-label":"Hauptnavigation"},e("div",{key:"7a0ec1a78d6eee3b3e37f55f872806b0791c2156",role:"menubar",class:"primary-menubar"},e("slot",{key:"e0403633c6acd137c94b1552cc7f08e3549550d3",name:"nav-primary",ref:M=>this.primarySlot=M}),e("div",{key:"4e377f38a0b94a766f9001174729e5763fa0a194",role:"menu",id:"nav-secondary",class:"secondary-menubar",hidden:!this.lmvzActiveNav,ref:M=>this.secondaryNav=M},e("slot",{key:"368e461f239498c706a3c9bb27a7b05de2b79cac",name:this.secondarySlotName,ref:M=>this.secondarySlot=M})))),e("div",{key:"8ffaf8d6f1254644b48dc0a40b9f552339ecc690",class:"actions"},e("slot",{key:"5b679885e4fa111d66e993458ab7f5092d8179d4",name:"actions"})))}static get watchers(){return{lmvzActiveNav:[{handleActiveNavChange:0}]}}};a.style=":host{display:flex;width:100vw;flex-direction:row;align-items:center;box-sizing:border-box;background-color:var(--lmvz-semantic-color-surface-primary, #ffffff);--lmvz-header-x-spacing-level-1:var(--lmvz-dimension-8-28, clamp(0.5rem, 0.2rem + 1.29vw, 1.75rem));--lmvz-header-x-spacing-level-2:var(--lmvz-component-buttongroup-wrapper-gap-x, clamp(0.25rem, 0.16rem + 0.39vw, 0.63rem));padding:var(--lmvz-dimension-8-16, clamp(0.5rem, 0.38rem + 0.52vw, 1rem)) var(--lmvz-header-x-spacing-level-1);gap:var(--lmvz-header-x-spacing-level-1);.brand{display:inline-flex;justify-content:center;align-items:center}#fallback-logo-lmvz{height:34px;width:auto}nav{flex-grow:1}.primary-menubar{display:flex;flex-direction:row;align-items:center}.secondary-menubar{display:flex;flex-direction:row;align-items:center;margin-left:var(--lmvz-header-x-spacing-level-2);padding-left:var(--lmvz-header-x-spacing-level-2);border-left:1px solid var(--lmvz-semantic-color-border-default, #e0e0e0)}}";export{a as lmvz_header}
@@ -1 +0,0 @@
1
- import{r as s,h as t,H as e}from"./p-saW7O-EW.js";const r=class{constructor(t){s(this,t)}text;render(){return t(e,{key:"d128e24bb90891ebd13d13a8e27c06782363cace"},this.text)}};r.style=":host{display:block}";export{r as lmvz_chip}
@@ -1 +0,0 @@
1
- import{g as n,r as o,l as e,i as t,a as r,b as i,m as s,t as c,T as a,c as d}from"./p-fiRXhuXK.js";const f=Symbol.for("effect/Brand/Refined"),u=function(...c){const a=2===c.length?n=>c[0](n)?o(n):e(c[1](n)):n=>s(c[0](n),{onNone:()=>o(n),onSome:e});return Object.assign((o=>n(a(o),t)),{[f]:f,option:n=>i(a(n)),either:a,is:n=>r(a(n))})}(g,(()=>[{message:"SVG data is malformed",meta:undefined}]));class l extends(a("BrandValidationError")){constructor(n,o){super(new Error(`Brand validation failed for type ${o}.`,{cause:n}))}}function g(n){if("string"!=typeof n)return!1;try{return"svg"===(new DOMParser).parseFromString(n,"image/svg+xml").documentElement.nodeName}catch{return!1}}const v=Symbol.for("LMVZ__iconProviderRegistry"),w={};function m(){return"undefined"==typeof window?w:window[v]??(window[v]={})}function p(n,o){const e=m(),t=n;Object.prototype.hasOwnProperty.call(e,t)&&console.warn(`Icon provider with name "${t}" is already registered. Overwriting existing provider.`),e[t]=o}function y(n){const o=m();if(n)return o[n];const e=Object.keys(o);if(0===e.length)return;e.length>1&&console.warn(`Multiple icon providers registered (${e.join(", ")}). Using the first one: "${e[0]}".`);const t=e[0];return t?o[t]:void 0}const $=()=>u('<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"></svg>');async function h(n){const{icon:o,iconset:e}=n;return await(async()=>{const n=y(e);if(n)try{const t=await Promise.resolve(n.resolve(o));if(!t?.svg)return void console.warn(`Icon "${o}"${e?` from set "${e}"`:""} not found in provider. Using default icon.`);const r=await async function(n){try{return await d((o=n,c({try:()=>u(o),catch:n=>new l(n,"SVGString")})))}catch{return console.error("Invalid SVG string:",n),$()}var o}(t.svg);if(r)return r}catch(n){return void console.error(`Error resolving icon "${o}" with provider:`,n)}else console.warn(`No icon provider registered. Unable to resolve icon "${o}"${e?` from set "${e}"`:""}. Using default icon.`)})()||(console.error(`Icon "${o}" not found${e?` in set "${e}"`:""}. Using default icon.`),$())}function b(n,o){return{iconset:n,icon:o}}export{h as a,y as g,g as i,p as r,b as t}
File without changes