@lmvz-ds/components 0.18.2 → 0.20.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/CHANGELOG.md +16 -0
- package/README.md +45 -100
- package/assets/icons/checkmark.svg +4 -0
- package/cjs/{aria-loader-CfFuAbJn.js → aria-loader-Cec1zR2g.js} +1 -1
- package/cjs/ds.constants-DSnxZ3ia.js +16 -0
- package/cjs/icons-BQASWgk-.js +80 -0
- package/cjs/{index--7IqZZqn.js → index-3g9Z9sfF.js} +765 -2854
- package/cjs/index.cjs.js +12 -12
- package/cjs/lmvz-button.cjs.entry.js +4 -4
- package/cjs/lmvz-card.cjs.entry.js +1 -1
- package/cjs/lmvz-checkbox.cjs.entry.js +113 -0
- package/cjs/lmvz-chip.cjs.entry.js +68 -4
- package/cjs/lmvz-components.cjs.js +1 -1
- package/cjs/lmvz-header_2.cjs.entry.js +3 -3
- package/cjs/lmvz-icon.cjs.entry.js +10 -8
- package/cjs/lmvz-input.cjs.entry.js +4 -4
- package/cjs/lmvz-menuitem.cjs.entry.js +4 -4
- package/cjs/lmvz-select.cjs.entry.js +3 -3
- package/cjs/loader.cjs.js +1 -1
- package/cjs/{logger-Bn2yoZGP.js → logger-DsM6xg6V.js} +3063 -833
- package/cjs/{reactive-controller-host-CtaVAiYJ.js → reactive-controller-host-BA4ZhjKA.js} +10 -10
- package/cjs/svg-BMBduILB.js +125 -0
- package/collection/api/ds.constants.js +2 -0
- package/collection/assets/icons/checkmark.svg +4 -0
- package/collection/collection-manifest.json +1 -0
- package/collection/components/lmvz-button/lmvz-button.css +1 -2
- package/collection/components/lmvz-button/lmvz-button.js +6 -3
- package/collection/components/lmvz-card/lmvz-card.css +1 -2
- package/collection/components/lmvz-checkbox/lmvz-checkbox.css +207 -0
- package/collection/components/lmvz-checkbox/lmvz-checkbox.js +424 -0
- package/collection/components/lmvz-chip/lmvz-chip.css +84 -1
- package/collection/components/lmvz-chip/lmvz-chip.js +110 -13
- package/collection/components/lmvz-header/lmvz-header.js +2 -2
- package/collection/components/lmvz-icon/lmvz-icon.css +11 -10
- package/collection/components/lmvz-icon/lmvz-icon.js +8 -7
- package/collection/components/lmvz-input/lmvz-input.js +4 -4
- package/collection/components/lmvz-menuitem/lmvz-menuitem.css +1 -1
- package/collection/components/lmvz-menuitem/lmvz-menuitem.js +11 -5
- package/collection/components/lmvz-select/lmvz-select.js +1 -1
- package/collection/index.js +1 -1
- package/collection/integration/header-integration/header-integration.js +1 -1
- package/collection/utils/aria/aria-validation-controller.js +1 -0
- package/collection/utils/icons/icons.js +2 -13
- package/collection/utils/icons/icons.unit.js +3 -15
- package/collection/utils/reactive-controller-host.js +9 -9
- package/components/index.d.ts +2 -0
- package/components/index.d.ts.bak +2 -0
- package/components/index.js +1 -1
- package/components/lmvz-button.js +1 -1
- package/components/lmvz-card.js +1 -1
- package/components/lmvz-checkbox.d.ts +11 -0
- package/components/lmvz-checkbox.d.ts.bak +11 -0
- package/components/lmvz-checkbox.js +1 -0
- package/components/lmvz-chip.js +1 -1
- package/components/lmvz-header.js +1 -1
- package/components/lmvz-icon.js +1 -1
- package/components/lmvz-input.js +1 -1
- package/components/lmvz-menuitem.js +1 -1
- package/components/lmvz-select.js +1 -1
- package/components/p-0s99QfRy.js +12 -0
- package/components/{p-CBLAeife.js → p-BuFx0tTm.js} +1 -1
- package/components/p-CGmJG63p.js +1 -0
- package/components/p-CcxjkCOx.js +1 -0
- package/components/{p-DQEkWkMh.js → p-DIrAQ4IB.js} +1 -1
- package/esm/{aria-loader-BF_AYtbb.js → aria-loader-BVolm0lC.js} +1 -1
- package/esm/ds.constants-Bmi89ll1.js +9 -0
- package/esm/icons-CmuFKDRz.js +75 -0
- package/esm/{index-7Ru1khgk.js → index-Dh_9sN0q.js} +389 -2478
- package/esm/index.js +5 -11
- package/esm/lmvz-button.entry.js +4 -4
- package/esm/lmvz-card.entry.js +1 -1
- package/esm/lmvz-checkbox.entry.js +111 -0
- package/esm/lmvz-chip.entry.js +69 -5
- package/esm/lmvz-components.js +1 -1
- package/esm/lmvz-header_2.entry.js +3 -3
- package/esm/lmvz-icon.entry.js +10 -8
- package/esm/lmvz-input.entry.js +4 -4
- package/esm/lmvz-menuitem.entry.js +4 -4
- package/esm/lmvz-select.entry.js +3 -3
- package/esm/loader.js +1 -1
- package/esm/{logger-fiRXhuXK.js → logger-CGmJG63p.js} +2870 -765
- package/esm/{reactive-controller-host-sR2jJxNG.js → reactive-controller-host-DHcPpJW7.js} +10 -10
- package/esm/svg-B2YoIRuh.js +121 -0
- package/hydrate/index.js +2383 -42
- package/hydrate/index.mjs +2383 -42
- package/lmvz-components/index.esm.js +1 -1
- package/lmvz-components/lmvz-components.esm.js +1 -1
- package/lmvz-components/{p-5aa17cd2.entry.js → p-0f7a4236.entry.js} +1 -1
- package/lmvz-components/p-0s99QfRy.js +12 -0
- package/lmvz-components/{p-30b99f11.entry.js → p-2f83d7a2.entry.js} +1 -1
- package/lmvz-components/{p-6dbb3f13.entry.js → p-32171f4f.entry.js} +1 -1
- package/lmvz-components/{p-59383f3a.entry.js → p-400b2318.entry.js} +1 -1
- package/lmvz-components/p-851969bd.entry.js +1 -0
- package/lmvz-components/p-9f9d845d.entry.js +1 -0
- package/lmvz-components/p-Bmi89ll1.js +1 -0
- package/lmvz-components/p-CFsC37ww.js +1 -0
- package/lmvz-components/p-CGmJG63p.js +1 -0
- package/lmvz-components/p-CcxjkCOx.js +1 -0
- package/lmvz-components/{p-Bkfdgg0T.js → p-GdMr6Qlp.js} +1 -1
- package/lmvz-components/p-a12f95da.entry.js +1 -0
- package/lmvz-components/{p-84267405.entry.js → p-ab4437dc.entry.js} +1 -1
- package/lmvz-components/{p-7a6bec13.entry.js → p-d0a0e206.entry.js} +1 -1
- package/lmvz-components/{p-B3dnXEPG.js → p-dhVSUYqd.js} +1 -1
- package/manifest.json +544 -28
- package/package.json +5 -1
- package/types/api/ds.constants.d.ts +6 -1
- package/types/components/lmvz-action/lmvz-action.d.ts +0 -1
- package/types/components/lmvz-button/lmvz-button.d.ts +0 -1
- package/types/components/lmvz-card/lmvz-card.d.ts +0 -1
- package/types/components/lmvz-checkbox/lmvz-checkbox.d.ts +39 -0
- package/types/components/lmvz-chip/lmvz-chip.d.ts +18 -3
- package/types/components/lmvz-header/lmvz-header.d.ts +0 -1
- package/types/components/lmvz-icon/lmvz-icon.d.ts +0 -1
- package/types/components/lmvz-input/lmvz-input.d.ts +0 -1
- package/types/components/lmvz-menuitem/lmvz-menuitem.d.ts +0 -1
- package/types/components/lmvz-select/lmvz-select.d.ts +0 -1
- package/types/components.d.ts +221 -12
- package/types/index.d.ts +1 -2
- package/types/utils/aria/aria-validation-controller.d.ts +1 -2
- package/types/utils/aria/element-activation-controller.d.ts +0 -1
- package/types/utils/aria/list-keyboard-controller.d.ts +0 -1
- package/types/utils/assets.d.ts +0 -1
- package/types/utils/component.d.ts +0 -1
- package/types/utils/environment.d.ts +0 -1
- package/types/utils/http.d.ts +0 -1
- package/types/utils/http.unit.d.ts +0 -1
- package/types/utils/icons/icons-registry.d.ts +0 -1
- package/types/utils/icons/icons.d.ts +0 -2
- package/types/utils/icons/icons.unit.d.ts +0 -1
- package/types/utils/icons/public.d.ts +0 -1
- package/types/utils/public.d.ts +0 -1
- package/types/utils/reactive-controller-host.d.ts +0 -1
- package/cjs/icons-swqMn6s2.js +0 -163
- package/components/p-DXOTa5VF.js +0 -12
- package/components/p-fiRXhuXK.js +0 -1
- package/esm/icons-Ca8oMiRa.js +0 -157
- package/lmvz-components/p-0a41cc24.entry.js +0 -1
- package/lmvz-components/p-5f150890.entry.js +0 -1
- package/lmvz-components/p-Bh2Epkwf.js +0 -1
- package/lmvz-components/p-DXOTa5VF.js +0 -12
- package/lmvz-components/p-fiRXhuXK.js +0 -1
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lmvz-ds/components",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.20.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"description": "The components of the design system",
|
|
7
7
|
"author": "Patrick Nemenz <patrick.nemenz@adesso.at>",
|
|
@@ -67,6 +67,10 @@
|
|
|
67
67
|
"./lmvz-select": {
|
|
68
68
|
"types": "./components/lmvz-select.d.ts",
|
|
69
69
|
"import": "./components/lmvz-select.js"
|
|
70
|
+
},
|
|
71
|
+
"./lmvz-checkbox": {
|
|
72
|
+
"import": "./components/lmvz-checkbox.js",
|
|
73
|
+
"types": "./components/lmvz-checkbox.d.ts"
|
|
70
74
|
}
|
|
71
75
|
},
|
|
72
76
|
"main": "./index.cjs.js",
|
|
@@ -5,6 +5,8 @@ export declare const textSizes: readonly ["xs", "sm", "md", "lg", "xl"];
|
|
|
5
5
|
export declare const inputTypes: readonly ["text", "email", "password", "tel", "url", "search", "number"];
|
|
6
6
|
export declare const iconSizes: readonly ["xs", "sm", "md", "lg", "inherit"];
|
|
7
7
|
export declare const iconWeights: readonly ["thin", "medium", "bold", "filled"];
|
|
8
|
+
export declare const chipTypes: readonly ["active", "warning", "success", "error", "neutral"];
|
|
9
|
+
export declare const chipSizes: readonly ["default", "small"];
|
|
8
10
|
export declare namespace LmvzDS {
|
|
9
11
|
type Variant = (typeof variants)[number];
|
|
10
12
|
type Size = (typeof sizes)[number];
|
|
@@ -16,6 +18,10 @@ export declare namespace Button {
|
|
|
16
18
|
type Scale = (typeof scaleValues)[number];
|
|
17
19
|
type Variant = LmvzDS.Variant;
|
|
18
20
|
}
|
|
21
|
+
export declare namespace Chip {
|
|
22
|
+
type Type = (typeof chipTypes)[number];
|
|
23
|
+
type Size = (typeof chipSizes)[number];
|
|
24
|
+
}
|
|
19
25
|
export declare namespace Icon {
|
|
20
26
|
type Size = (typeof iconSizes)[number];
|
|
21
27
|
type IconWeight = (typeof iconWeights)[number];
|
|
@@ -26,4 +32,3 @@ export declare namespace Input {
|
|
|
26
32
|
type Inputmode = 'none' | 'text' | 'decimal' | 'numeric' | 'tel' | 'search' | 'email' | 'url';
|
|
27
33
|
type Autocapitalize = 'off' | 'none' | 'on' | 'sentences' | 'words' | 'characters';
|
|
28
34
|
}
|
|
29
|
-
//# sourceMappingURL=ds.constants.d.ts.map
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { type EventEmitter } from '../../stencil-public-runtime';
|
|
2
|
+
import { type AriaValidationHost } from '../../utils/aria/aria-validation-controller';
|
|
3
|
+
import { ReactiveControllerHost } from '../../utils/reactive-controller-host';
|
|
4
|
+
export declare class LmvzCheckbox extends ReactiveControllerHost implements AriaValidationHost {
|
|
5
|
+
readonly el: HTMLElement;
|
|
6
|
+
get validationEl(): HTMLElement;
|
|
7
|
+
internals: ElementInternals;
|
|
8
|
+
private nativeInput;
|
|
9
|
+
private checkboxId;
|
|
10
|
+
private initialChecked;
|
|
11
|
+
private get helperId();
|
|
12
|
+
private get errorId();
|
|
13
|
+
private get ariaDescribedBy();
|
|
14
|
+
label: string;
|
|
15
|
+
checked: boolean;
|
|
16
|
+
value: string;
|
|
17
|
+
name?: string;
|
|
18
|
+
disabled: boolean;
|
|
19
|
+
required: boolean;
|
|
20
|
+
error: boolean;
|
|
21
|
+
errorMessage?: string;
|
|
22
|
+
helperText?: string;
|
|
23
|
+
form?: string;
|
|
24
|
+
autofocus: boolean;
|
|
25
|
+
private checkedState;
|
|
26
|
+
protected handleCheckedChange(val: boolean): void;
|
|
27
|
+
lmvzChange: EventEmitter<boolean>;
|
|
28
|
+
focusInput(): Promise<void>;
|
|
29
|
+
checkValidity(): Promise<boolean>;
|
|
30
|
+
reportValidity(): Promise<boolean>;
|
|
31
|
+
constructor();
|
|
32
|
+
componentWillLoad(): void;
|
|
33
|
+
componentWillRender(): void;
|
|
34
|
+
formAssociatedCallback(): void;
|
|
35
|
+
formResetCallback(): void;
|
|
36
|
+
formStateRestoreCallback(state: string | File | FormData): void;
|
|
37
|
+
private handleChange;
|
|
38
|
+
render(): any;
|
|
39
|
+
}
|
|
@@ -1,5 +1,20 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
import { type Chip } from '../../api/ds.constants.js';
|
|
2
|
+
import { type AriaValidationHost } from '../../utils/aria/aria-validation-controller';
|
|
3
|
+
import { ReactiveControllerHost } from '../../utils/reactive-controller-host';
|
|
4
|
+
export declare class LmvzChip extends ReactiveControllerHost implements AriaValidationHost {
|
|
5
|
+
private readonly ariaValidationController;
|
|
6
|
+
private beforeSlot?;
|
|
7
|
+
private defaultSlot?;
|
|
8
|
+
private afterSlot?;
|
|
9
|
+
el: HTMLElement;
|
|
10
|
+
get validationEl(): HTMLElement;
|
|
11
|
+
type: Chip.Type;
|
|
12
|
+
size: Chip.Size;
|
|
13
|
+
constructor();
|
|
14
|
+
normalizeType(value: string): void;
|
|
15
|
+
normalizeSize(value: string): void;
|
|
16
|
+
componentWillLoad(): void;
|
|
17
|
+
connectedCallback(): void;
|
|
18
|
+
private readonly checkContent;
|
|
3
19
|
render(): any;
|
|
4
20
|
}
|
|
5
|
-
//# sourceMappingURL=lmvz-chip.d.ts.map
|
package/types/components.d.ts
CHANGED
|
@@ -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,98 @@ export declare namespace Components {
|
|
|
57
67
|
*/
|
|
58
68
|
"primaryActionLabel": string;
|
|
59
69
|
}
|
|
70
|
+
/**
|
|
71
|
+
* Checkbox component with form association, ARIA validation, and accessible label support.
|
|
72
|
+
* @example ```html
|
|
73
|
+
* <lmvz-checkbox label="Accept terms" name="terms" required></lmvz-checkbox>
|
|
74
|
+
* ```
|
|
75
|
+
*/
|
|
76
|
+
export interface LmvzCheckbox {
|
|
77
|
+
/**
|
|
78
|
+
* Whether the checkbox should autofocus.
|
|
79
|
+
* @default false
|
|
80
|
+
*/
|
|
81
|
+
"autofocus": boolean;
|
|
82
|
+
/**
|
|
83
|
+
* Returns whether the checkbox satisfies its validation constraints.
|
|
84
|
+
*/
|
|
85
|
+
"checkValidity": () => Promise<boolean>;
|
|
86
|
+
/**
|
|
87
|
+
* Whether the checkbox is checked.
|
|
88
|
+
* @default false
|
|
89
|
+
*/
|
|
90
|
+
"checked": boolean;
|
|
91
|
+
/**
|
|
92
|
+
* Whether the checkbox is disabled.
|
|
93
|
+
* @default false
|
|
94
|
+
*/
|
|
95
|
+
"disabled": boolean;
|
|
96
|
+
/**
|
|
97
|
+
* Whether the checkbox is in an error state.
|
|
98
|
+
* @default false
|
|
99
|
+
*/
|
|
100
|
+
"error": boolean;
|
|
101
|
+
/**
|
|
102
|
+
* Error message displayed when error is true. Required when error=true.
|
|
103
|
+
*/
|
|
104
|
+
"errorMessage"?: string;
|
|
105
|
+
/**
|
|
106
|
+
* Sets focus on the native checkbox input.
|
|
107
|
+
*/
|
|
108
|
+
"focusInput": () => Promise<void>;
|
|
109
|
+
/**
|
|
110
|
+
* Form id to associate with (for out-of-form usage).
|
|
111
|
+
*/
|
|
112
|
+
"form"?: string;
|
|
113
|
+
/**
|
|
114
|
+
* Helper / description text displayed below the label.
|
|
115
|
+
*/
|
|
116
|
+
"helperText"?: string;
|
|
117
|
+
/**
|
|
118
|
+
* Label text for the checkbox. Required for accessibility.
|
|
119
|
+
*/
|
|
120
|
+
"label": string;
|
|
121
|
+
/**
|
|
122
|
+
* Name attribute for form submission via ElementInternals.
|
|
123
|
+
*/
|
|
124
|
+
"name"?: string;
|
|
125
|
+
/**
|
|
126
|
+
* Reports validation errors to the user.
|
|
127
|
+
*/
|
|
128
|
+
"reportValidity": () => Promise<boolean>;
|
|
129
|
+
/**
|
|
130
|
+
* Whether the checkbox is required.
|
|
131
|
+
* @default false
|
|
132
|
+
*/
|
|
133
|
+
"required": boolean;
|
|
134
|
+
/**
|
|
135
|
+
* Form submission value when checked.
|
|
136
|
+
* @default 'on'
|
|
137
|
+
*/
|
|
138
|
+
"value": string;
|
|
139
|
+
}
|
|
140
|
+
/**
|
|
141
|
+
* The chip displays a compact semantic status as a non-interactive UI element.
|
|
142
|
+
*/
|
|
60
143
|
export interface LmvzChip {
|
|
61
|
-
|
|
144
|
+
/**
|
|
145
|
+
* Size variant of the chip. Invalid values are normalized to `default` at runtime.
|
|
146
|
+
* @default 'default'
|
|
147
|
+
*/
|
|
148
|
+
"size": Chip.Size;
|
|
149
|
+
/**
|
|
150
|
+
* Semantic variant of the chip. Invalid values are normalized to `active` at runtime.
|
|
151
|
+
* @default 'active'
|
|
152
|
+
*/
|
|
153
|
+
"type": Chip.Type;
|
|
62
154
|
}
|
|
63
155
|
/**
|
|
64
156
|
* An accessible, application-style navigation header component, that renders two connected levels of navigation.
|
|
65
157
|
*/
|
|
66
158
|
export interface LmvzHeader {
|
|
159
|
+
/**
|
|
160
|
+
* Id of the currently active primary navigation item. Also determines which `connect-nav-*` secondary slot is shown.
|
|
161
|
+
*/
|
|
67
162
|
"lmvzActiveNav"?: string;
|
|
68
163
|
/**
|
|
69
164
|
* @readonly
|
|
@@ -77,13 +172,16 @@ export declare namespace Components {
|
|
|
77
172
|
* Loading is deferred, using an IntersectionObserver, until the instance becomes visible in the viewport.
|
|
78
173
|
*/
|
|
79
174
|
export interface LmvzIcon {
|
|
175
|
+
/**
|
|
176
|
+
* Accessible name for assistive technology. Leave unset for decorative icons so the icon stays hidden from the accessibility tree.
|
|
177
|
+
*/
|
|
80
178
|
"ariaLabel"?: string;
|
|
81
179
|
/**
|
|
82
|
-
* Required Either a valid name from a registered iconset, or the icon's SVG content (inline). Will be checked against the
|
|
180
|
+
* 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
181
|
*/
|
|
84
182
|
"icon": SVGString | string;
|
|
85
183
|
/**
|
|
86
|
-
* Optional custom icon iconset id. Must reference a registered custom iconset by its exported name.
|
|
184
|
+
* 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
185
|
*/
|
|
88
186
|
"iconset"?: string;
|
|
89
187
|
/**
|
|
@@ -226,6 +324,9 @@ export declare namespace Components {
|
|
|
226
324
|
* Selects the text in the input
|
|
227
325
|
*/
|
|
228
326
|
"select": () => Promise<void>;
|
|
327
|
+
/**
|
|
328
|
+
* Updates the value programmatically and emits `lmvzInput` with the new value.
|
|
329
|
+
*/
|
|
229
330
|
"setValue": (newValue: string | undefined) => Promise<void>;
|
|
230
331
|
/**
|
|
231
332
|
* Spellcheck attribute
|
|
@@ -251,13 +352,15 @@ export declare namespace Components {
|
|
|
251
352
|
*/
|
|
252
353
|
export interface LmvzMenuitem {
|
|
253
354
|
/**
|
|
254
|
-
*
|
|
355
|
+
* Accessibility role exposed by the host element.
|
|
255
356
|
* @default 'menuitem'
|
|
357
|
+
* @readonly
|
|
256
358
|
*/
|
|
257
359
|
"role": string;
|
|
258
360
|
/**
|
|
259
|
-
*
|
|
361
|
+
* Keeps the host focusable for keyboard navigation inside `lmvz-header`.
|
|
260
362
|
* @default 0
|
|
363
|
+
* @readonly
|
|
261
364
|
*/
|
|
262
365
|
"ti": number;
|
|
263
366
|
}
|
|
@@ -357,6 +460,7 @@ export declare namespace JSX {
|
|
|
357
460
|
*/
|
|
358
461
|
"ti"?: number;
|
|
359
462
|
/**
|
|
463
|
+
* Native button type forwarded to the internal `<button>` element. Use `submit` to trigger form submission.
|
|
360
464
|
* @default 'button'
|
|
361
465
|
*/
|
|
362
466
|
"type"?: 'submit' | 'button';
|
|
@@ -389,13 +493,90 @@ export declare namespace JSX {
|
|
|
389
493
|
*/
|
|
390
494
|
"primaryActionLabel"?: string;
|
|
391
495
|
}
|
|
496
|
+
/**
|
|
497
|
+
* Checkbox component with form association, ARIA validation, and accessible label support.
|
|
498
|
+
* @example ```html
|
|
499
|
+
* <lmvz-checkbox label="Accept terms" name="terms" required></lmvz-checkbox>
|
|
500
|
+
* ```
|
|
501
|
+
*/
|
|
502
|
+
export interface LmvzCheckbox {
|
|
503
|
+
/**
|
|
504
|
+
* Whether the checkbox should autofocus.
|
|
505
|
+
* @default false
|
|
506
|
+
*/
|
|
507
|
+
"autofocus"?: boolean;
|
|
508
|
+
/**
|
|
509
|
+
* Whether the checkbox is checked.
|
|
510
|
+
* @default false
|
|
511
|
+
*/
|
|
512
|
+
"checked"?: boolean;
|
|
513
|
+
/**
|
|
514
|
+
* Whether the checkbox is disabled.
|
|
515
|
+
* @default false
|
|
516
|
+
*/
|
|
517
|
+
"disabled"?: boolean;
|
|
518
|
+
/**
|
|
519
|
+
* Whether the checkbox is in an error state.
|
|
520
|
+
* @default false
|
|
521
|
+
*/
|
|
522
|
+
"error"?: boolean;
|
|
523
|
+
/**
|
|
524
|
+
* Error message displayed when error is true. Required when error=true.
|
|
525
|
+
*/
|
|
526
|
+
"errorMessage"?: string;
|
|
527
|
+
/**
|
|
528
|
+
* Form id to associate with (for out-of-form usage).
|
|
529
|
+
*/
|
|
530
|
+
"form"?: string;
|
|
531
|
+
/**
|
|
532
|
+
* Helper / description text displayed below the label.
|
|
533
|
+
*/
|
|
534
|
+
"helperText"?: string;
|
|
535
|
+
/**
|
|
536
|
+
* Label text for the checkbox. Required for accessibility.
|
|
537
|
+
*/
|
|
538
|
+
"label": string;
|
|
539
|
+
/**
|
|
540
|
+
* Name attribute for form submission via ElementInternals.
|
|
541
|
+
*/
|
|
542
|
+
"name"?: string;
|
|
543
|
+
/**
|
|
544
|
+
* Emitted whenever the checkbox checked state changes. Event detail contains the new checked boolean value.
|
|
545
|
+
*/
|
|
546
|
+
"onLmvzChange"?: (event: LmvzCheckboxCustomEvent<boolean>) => void;
|
|
547
|
+
/**
|
|
548
|
+
* Whether the checkbox is required.
|
|
549
|
+
* @default false
|
|
550
|
+
*/
|
|
551
|
+
"required"?: boolean;
|
|
552
|
+
/**
|
|
553
|
+
* Form submission value when checked.
|
|
554
|
+
* @default 'on'
|
|
555
|
+
*/
|
|
556
|
+
"value"?: string;
|
|
557
|
+
}
|
|
558
|
+
/**
|
|
559
|
+
* The chip displays a compact semantic status as a non-interactive UI element.
|
|
560
|
+
*/
|
|
392
561
|
export interface LmvzChip {
|
|
393
|
-
|
|
562
|
+
/**
|
|
563
|
+
* Size variant of the chip. Invalid values are normalized to `default` at runtime.
|
|
564
|
+
* @default 'default'
|
|
565
|
+
*/
|
|
566
|
+
"size"?: Chip.Size;
|
|
567
|
+
/**
|
|
568
|
+
* Semantic variant of the chip. Invalid values are normalized to `active` at runtime.
|
|
569
|
+
* @default 'active'
|
|
570
|
+
*/
|
|
571
|
+
"type"?: Chip.Type;
|
|
394
572
|
}
|
|
395
573
|
/**
|
|
396
574
|
* An accessible, application-style navigation header component, that renders two connected levels of navigation.
|
|
397
575
|
*/
|
|
398
576
|
export interface LmvzHeader {
|
|
577
|
+
/**
|
|
578
|
+
* Id of the currently active primary navigation item. Also determines which `connect-nav-*` secondary slot is shown.
|
|
579
|
+
*/
|
|
399
580
|
"lmvzActiveNav"?: string;
|
|
400
581
|
/**
|
|
401
582
|
* @readonly
|
|
@@ -409,13 +590,16 @@ export declare namespace JSX {
|
|
|
409
590
|
* Loading is deferred, using an IntersectionObserver, until the instance becomes visible in the viewport.
|
|
410
591
|
*/
|
|
411
592
|
export interface LmvzIcon {
|
|
593
|
+
/**
|
|
594
|
+
* Accessible name for assistive technology. Leave unset for decorative icons so the icon stays hidden from the accessibility tree.
|
|
595
|
+
*/
|
|
412
596
|
"ariaLabel"?: string;
|
|
413
597
|
/**
|
|
414
|
-
* Required Either a valid name from a registered iconset, or the icon's SVG content (inline). Will be checked against the
|
|
598
|
+
* 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
599
|
*/
|
|
416
600
|
"icon": SVGString | string;
|
|
417
601
|
/**
|
|
418
|
-
* Optional custom icon iconset id. Must reference a registered custom iconset by its exported name.
|
|
602
|
+
* 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
603
|
*/
|
|
420
604
|
"iconset"?: string;
|
|
421
605
|
/**
|
|
@@ -516,6 +700,9 @@ export declare namespace JSX {
|
|
|
516
700
|
* Name attribute for the input
|
|
517
701
|
*/
|
|
518
702
|
"name"?: string;
|
|
703
|
+
/**
|
|
704
|
+
* Emitted whenever the input value changes. Event detail contains the current value.
|
|
705
|
+
*/
|
|
519
706
|
"onLmvzInput"?: (event: LmvzInputCustomEvent<string>) => void;
|
|
520
707
|
/**
|
|
521
708
|
* Validation pattern (regex)
|
|
@@ -563,13 +750,15 @@ export declare namespace JSX {
|
|
|
563
750
|
*/
|
|
564
751
|
"onLmvzActivation"?: (event: LmvzMenuitemCustomEvent<void>) => void;
|
|
565
752
|
/**
|
|
566
|
-
*
|
|
753
|
+
* Accessibility role exposed by the host element.
|
|
567
754
|
* @default 'menuitem'
|
|
755
|
+
* @readonly
|
|
568
756
|
*/
|
|
569
757
|
"role"?: string;
|
|
570
758
|
/**
|
|
571
|
-
*
|
|
759
|
+
* Keeps the host focusable for keyboard navigation inside `lmvz-header`.
|
|
572
760
|
* @default 0
|
|
761
|
+
* @readonly
|
|
573
762
|
*/
|
|
574
763
|
"ti"?: number;
|
|
575
764
|
}
|
|
@@ -635,8 +824,22 @@ export declare namespace JSX {
|
|
|
635
824
|
"description": string;
|
|
636
825
|
"primaryActionLabel": string;
|
|
637
826
|
}
|
|
827
|
+
export interface LmvzCheckboxAttributes {
|
|
828
|
+
"label": string;
|
|
829
|
+
"checked": boolean;
|
|
830
|
+
"value": string;
|
|
831
|
+
"name": string;
|
|
832
|
+
"disabled": boolean;
|
|
833
|
+
"required": boolean;
|
|
834
|
+
"error": boolean;
|
|
835
|
+
"errorMessage": string;
|
|
836
|
+
"helperText": string;
|
|
837
|
+
"form": string;
|
|
838
|
+
"autofocus": boolean;
|
|
839
|
+
}
|
|
638
840
|
export interface LmvzChipAttributes {
|
|
639
|
-
"
|
|
841
|
+
"type": Chip.Type;
|
|
842
|
+
"size": Chip.Size;
|
|
640
843
|
}
|
|
641
844
|
export interface LmvzHeaderAttributes {
|
|
642
845
|
"role": string;
|
|
@@ -692,7 +895,8 @@ export declare namespace JSX {
|
|
|
692
895
|
"lmvz-action": LmvzAction;
|
|
693
896
|
"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
897
|
"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-
|
|
898
|
+
"lmvz-checkbox": Omit<LmvzCheckbox, keyof LmvzCheckboxAttributes> & { [K in keyof LmvzCheckbox & keyof LmvzCheckboxAttributes]?: LmvzCheckbox[K] } & { [K in keyof LmvzCheckbox & keyof LmvzCheckboxAttributes as `attr:${K}`]?: LmvzCheckboxAttributes[K] } & { [K in keyof LmvzCheckbox & keyof LmvzCheckboxAttributes as `prop:${K}`]?: LmvzCheckbox[K] } & OneOf<"label", LmvzCheckbox["label"], LmvzCheckboxAttributes["label"]>;
|
|
899
|
+
"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
900
|
"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
901
|
"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
902
|
"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"]>;
|
|
@@ -716,6 +920,11 @@ export declare interface LmvzCardCustomEvent<T> extends CustomEvent<T> {
|
|
|
716
920
|
target: HTMLLmvzCardElement;
|
|
717
921
|
}
|
|
718
922
|
|
|
923
|
+
export declare interface LmvzCheckboxCustomEvent<T> extends CustomEvent<T> {
|
|
924
|
+
detail: T;
|
|
925
|
+
target: HTMLLmvzCheckboxElement;
|
|
926
|
+
}
|
|
927
|
+
|
|
719
928
|
declare namespace LmvzDS {
|
|
720
929
|
type Variant = (typeof variants)[number];
|
|
721
930
|
type Size = (typeof sizes)[number];
|
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
|
package/types/utils/assets.d.ts
CHANGED
|
@@ -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
|
package/types/utils/http.d.ts
CHANGED
|
@@ -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
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
import type { IconPropsFallback, IconPropsForSet, IconPropsForSetWithoutFallback, KnownIconSetId } from '@lmvz-ds/lib-icon-api';
|
|
2
2
|
import type { SVGString } from '@lmvz-ds/lib-ts/validation/SVGString.d.ts';
|
|
3
3
|
export type IconData = SVGString;
|
|
4
|
-
export declare const emptyDefaultSvg: () => import("@lmvz-ds/lib-ts/validation/SVGString.js").SVGString;
|
|
5
4
|
export declare function resolveIconSvg<I extends KnownIconSetId>(options: IconPropsForSet<I>): Promise<IconData>;
|
|
6
5
|
export declare function resolveIconSvg(options: IconPropsFallback): Promise<IconData>;
|
|
7
6
|
export declare function typedIconFromSet<S extends string>(iconset: S, icon: IconPropsForSetWithoutFallback<S>['icon']): IconPropsForSetWithoutFallback<S>;
|
|
8
|
-
//# sourceMappingURL=icons.d.ts.map
|
package/types/utils/public.d.ts
CHANGED