@arvea/components 0.0.2 → 0.0.3
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/dist/arvea-sidebar-DWEHmLOH.d.cts +2956 -0
- package/dist/arvea-sidebar-DWEHmLOH.d.ts +2956 -0
- package/dist/chunk-4XSNFOEW.cjs +21 -0
- package/dist/chunk-4XSNFOEW.cjs.map +1 -0
- package/dist/chunk-7AZWKBZW.js +18 -0
- package/dist/chunk-7AZWKBZW.js.map +1 -0
- package/dist/chunk-PRGVQSDD.cjs +17173 -0
- package/dist/chunk-PRGVQSDD.cjs.map +1 -0
- package/dist/chunk-ZFNUBDJZ.js +17034 -0
- package/dist/chunk-ZFNUBDJZ.js.map +1 -0
- package/dist/index.cjs +773 -17249
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +24 -2972
- package/dist/index.d.ts +24 -2972
- package/dist/index.js +3 -17113
- package/dist/index.js.map +1 -1
- package/dist/react/index.cjs +730 -0
- package/dist/react/index.cjs.map +1 -0
- package/dist/react/index.d.cts +175 -0
- package/dist/react/index.d.ts +175 -0
- package/dist/react/index.js +435 -0
- package/dist/react/index.js.map +1 -0
- package/dist/tokens/tailwind-preset.cjs +2 -0
- package/dist/tokens/tailwind-preset.cjs.map +1 -1
- package/dist/tokens/tailwind-preset.js +2 -0
- package/dist/tokens/tailwind-preset.js.map +1 -1
- package/package.json +35 -19
|
@@ -0,0 +1,2956 @@
|
|
|
1
|
+
import * as lit_html from 'lit-html';
|
|
2
|
+
import * as lit from 'lit';
|
|
3
|
+
import { LitElement, PropertyValues, TemplateResult, nothing } from 'lit';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* @file icon.types.ts
|
|
7
|
+
* @description All available icon names, sizes and variants.
|
|
8
|
+
*/
|
|
9
|
+
type IconName = 'user' | 'layout-bottom' | 'wifi-02' | 'setting-02' | 'lock' | 'globe' | 'chevron-down' | 'fingerprint' | 'flag' | 'map-pin' | 'mail' | 'id-card' | 'check' | 'eye' | 'eye-slash' | 'plus' | 'shopping-bag' | 'gift' | 'ticket' | 'shopping-cart' | 'map' | 'file-text' | 'truck' | 'refresh-cw' | 'archive' | 'tag' | 'package' | 'layers' | 'grid' | 'zap' | 'file' | 'shield' | 'chevron-right' | 'bell' | 'settings' | 'arrow-right' | 'google' | 'log-out' | 'home' | 'clipboard';
|
|
10
|
+
type IconSize = 'sm' | 'md' | 'lg' | 'xl';
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* @element arvea-icon
|
|
14
|
+
*
|
|
15
|
+
* @prop {IconName} name - Icon name e.g. 'user', 'view'
|
|
16
|
+
* @prop {IconSize} size - 'sm' | 'md' | 'lg' | 'xl'
|
|
17
|
+
* @prop {boolean} outline - true = outline, false = filled
|
|
18
|
+
* @prop {string} color - any CSS color value
|
|
19
|
+
*
|
|
20
|
+
* @example
|
|
21
|
+
* <arvea-icon name="user" size="md" outline></arvea-icon>
|
|
22
|
+
* <arvea-icon name="user" size="lg"></arvea-icon>
|
|
23
|
+
*/
|
|
24
|
+
declare class ArveaIcon extends LitElement {
|
|
25
|
+
static styles: lit.CSSResult;
|
|
26
|
+
name: IconName;
|
|
27
|
+
size: IconSize;
|
|
28
|
+
outline: boolean;
|
|
29
|
+
color?: string;
|
|
30
|
+
render(): lit_html.TemplateResult<1>;
|
|
31
|
+
}
|
|
32
|
+
declare global {
|
|
33
|
+
interface HTMLElementTagNameMap {
|
|
34
|
+
'arvea-icon': ArveaIcon;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
type ButtonVariant = 'default' | 'outline' | 'secondary' | 'danger' | 'link';
|
|
39
|
+
type ArveaButtonSize = 'sm' | 'default' | 'lg' | 'icon';
|
|
40
|
+
type ArveaButtonShape = 'default' | 'pill';
|
|
41
|
+
interface ArveaButtonProps {
|
|
42
|
+
variant?: ButtonVariant;
|
|
43
|
+
size?: ArveaButtonSize;
|
|
44
|
+
shape?: ArveaButtonShape;
|
|
45
|
+
disabled?: boolean;
|
|
46
|
+
loading?: boolean;
|
|
47
|
+
type?: 'button' | 'submit' | 'reset';
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
/**
|
|
51
|
+
* @element arvea-button
|
|
52
|
+
*
|
|
53
|
+
* @prop {ButtonVariant} variant - 'default' | 'outline' | 'secondary' | 'danger' | 'link'
|
|
54
|
+
* @prop {ArveaButtonSize} size - 'sm' | 'default' | 'lg' | 'icon'
|
|
55
|
+
* @prop {boolean} disabled - disables the button
|
|
56
|
+
* @prop {boolean} loading - shows a spinner (ignored for link variant)
|
|
57
|
+
* @prop {string} type - 'button' | 'submit' | 'reset'
|
|
58
|
+
*
|
|
59
|
+
* @slot - Default slot for button content (text or icon)
|
|
60
|
+
*
|
|
61
|
+
* @example
|
|
62
|
+
* <arvea-button variant="default" size="default">Button</arvea-button>
|
|
63
|
+
* <arvea-button variant="danger" size="sm">Delete</arvea-button>
|
|
64
|
+
* <arvea-button variant="outline" disabled>Disabled</arvea-button>
|
|
65
|
+
* <arvea-button variant="default" loading>Loading...</arvea-button>
|
|
66
|
+
* <arvea-button variant="default" size="icon"><arvea-icon name="user"></arvea-icon></arvea-button>
|
|
67
|
+
*/
|
|
68
|
+
declare class ArveaButton extends LitElement {
|
|
69
|
+
static styles: lit.CSSResult[];
|
|
70
|
+
variant: ButtonVariant;
|
|
71
|
+
size: ArveaButtonSize;
|
|
72
|
+
shape: ArveaButtonShape;
|
|
73
|
+
disabled: boolean;
|
|
74
|
+
type: 'button' | 'submit' | 'reset';
|
|
75
|
+
loading: boolean;
|
|
76
|
+
fullWidth: boolean;
|
|
77
|
+
private get _isLoading();
|
|
78
|
+
private _handleClick;
|
|
79
|
+
render(): lit_html.TemplateResult<1>;
|
|
80
|
+
}
|
|
81
|
+
declare global {
|
|
82
|
+
interface HTMLElementTagNameMap {
|
|
83
|
+
'arvea-button': ArveaButton;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
type BadgeVariant = 'success' | 'error' | 'warning' | 'info' | 'pending' | 'active' | 'inactive' | 'default' | 'destructive' | 'secondary' | 'outline';
|
|
88
|
+
interface ArveaBadgeProps {
|
|
89
|
+
variant?: BadgeVariant;
|
|
90
|
+
label?: string;
|
|
91
|
+
color?: string;
|
|
92
|
+
textColor?: string;
|
|
93
|
+
icon?: string;
|
|
94
|
+
noBg?: boolean;
|
|
95
|
+
selected?: boolean;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
/**
|
|
99
|
+
* @element arvea-badge
|
|
100
|
+
*
|
|
101
|
+
* @prop {BadgeVariant} variant - 'success' | 'error' | 'warning' | 'info' | 'pending' | 'active' | 'inactive'
|
|
102
|
+
* @prop {string} label - Text label displayed in the badge
|
|
103
|
+
* @prop {string} color - Custom background color (overrides variant color)
|
|
104
|
+
* @prop {string} textColor - Custom text/icon color (overrides variant color)
|
|
105
|
+
* @prop {string} icon - Icon name from arvea-icon (overrides the variant icon)
|
|
106
|
+
* @prop {boolean} noBg - Removes background and padding for a transparent look
|
|
107
|
+
*
|
|
108
|
+
* @example
|
|
109
|
+
* <arvea-badge variant="success" label="Vérifié"></arvea-badge>
|
|
110
|
+
* <arvea-badge icon="check-circle" label="Vérifié" no-bg text-color="#10b981"></arvea-badge>
|
|
111
|
+
* <arvea-badge label="Custom" color="#e0f2fe" text-color="#0369a1"></arvea-badge>
|
|
112
|
+
*/
|
|
113
|
+
declare class ArveaBadge extends LitElement {
|
|
114
|
+
static styles: lit.CSSResult[];
|
|
115
|
+
variant: BadgeVariant;
|
|
116
|
+
label: string;
|
|
117
|
+
color: string;
|
|
118
|
+
textColor: string;
|
|
119
|
+
icon: string;
|
|
120
|
+
noBg: boolean;
|
|
121
|
+
hideIcon: boolean;
|
|
122
|
+
selected: boolean;
|
|
123
|
+
private static STATUS_VARIANTS;
|
|
124
|
+
render(): lit_html.TemplateResult<1>;
|
|
125
|
+
}
|
|
126
|
+
declare global {
|
|
127
|
+
interface HTMLElementTagNameMap {
|
|
128
|
+
'arvea-badge': ArveaBadge;
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
/**
|
|
133
|
+
* @element arvea-toggle
|
|
134
|
+
*
|
|
135
|
+
* @prop {boolean} checked - Whether the toggle is checked
|
|
136
|
+
* @prop {boolean} disabled - Whether the toggle is disabled
|
|
137
|
+
* @prop {string} label - Optional label next to the toggle
|
|
138
|
+
*
|
|
139
|
+
* @fires arvea-change - Fired when the toggle is clicked with detail: { checked: boolean }
|
|
140
|
+
*
|
|
141
|
+
* @example
|
|
142
|
+
* <arvea-toggle></arvea-toggle>
|
|
143
|
+
* <arvea-toggle checked></arvea-toggle>
|
|
144
|
+
* <arvea-toggle disabled></arvea-toggle>
|
|
145
|
+
* <arvea-toggle label="Dark mode"></arvea-toggle>
|
|
146
|
+
*/
|
|
147
|
+
declare class ArveaToggle extends LitElement {
|
|
148
|
+
static styles: lit.CSSResult[];
|
|
149
|
+
checked: boolean;
|
|
150
|
+
disabled: boolean;
|
|
151
|
+
label: string;
|
|
152
|
+
private _handleClick;
|
|
153
|
+
render(): lit_html.TemplateResult<1>;
|
|
154
|
+
}
|
|
155
|
+
declare global {
|
|
156
|
+
interface HTMLElementTagNameMap {
|
|
157
|
+
'arvea-toggle': ArveaToggle;
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
/**
|
|
162
|
+
* @element arvea-checkbox
|
|
163
|
+
*
|
|
164
|
+
* @prop {boolean} checked - Whether the checkbox is checked
|
|
165
|
+
* @prop {boolean} indeterminate - Tri-state mixed state (overrides check visual)
|
|
166
|
+
* @prop {boolean} disabled - Whether the checkbox is disabled
|
|
167
|
+
* @prop {string} label - Optional label next to the checkbox
|
|
168
|
+
*
|
|
169
|
+
* @fires arvea-change - { detail: { checked, indeterminate } }
|
|
170
|
+
*
|
|
171
|
+
* @example
|
|
172
|
+
* <arvea-checkbox></arvea-checkbox>
|
|
173
|
+
* <arvea-checkbox checked></arvea-checkbox>
|
|
174
|
+
* <arvea-checkbox indeterminate></arvea-checkbox>
|
|
175
|
+
*/
|
|
176
|
+
declare class ArveaCheckbox extends LitElement {
|
|
177
|
+
static styles: lit.CSSResult[];
|
|
178
|
+
checked: boolean;
|
|
179
|
+
indeterminate: boolean;
|
|
180
|
+
disabled: boolean;
|
|
181
|
+
label: string;
|
|
182
|
+
private _ariaChecked;
|
|
183
|
+
private _toggle;
|
|
184
|
+
private _handleClick;
|
|
185
|
+
private _handleKey;
|
|
186
|
+
render(): lit_html.TemplateResult<1>;
|
|
187
|
+
}
|
|
188
|
+
declare global {
|
|
189
|
+
interface HTMLElementTagNameMap {
|
|
190
|
+
'arvea-checkbox': ArveaCheckbox;
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
/**
|
|
195
|
+
* @element arvea-radio
|
|
196
|
+
*
|
|
197
|
+
* @prop {boolean} checked - Whether the radio is checked
|
|
198
|
+
* @prop {boolean} disabled - Whether the radio is disabled
|
|
199
|
+
* @prop {string} label - Optional label next to the radio
|
|
200
|
+
* @prop {string} value - Value of the radio button
|
|
201
|
+
* @prop {string} name - Name of the radio group
|
|
202
|
+
*
|
|
203
|
+
* @example
|
|
204
|
+
* <arvea-radio label="Option 1" name="group" value="1"></arvea-radio>
|
|
205
|
+
* <arvea-radio label="Option 2" name="group" value="2" checked></arvea-radio>
|
|
206
|
+
* <arvea-radio label="Option 3" name="group" value="3" disabled></arvea-radio>
|
|
207
|
+
*/
|
|
208
|
+
declare class ArveaRadio extends LitElement {
|
|
209
|
+
static styles: lit.CSSResult[];
|
|
210
|
+
checked: boolean;
|
|
211
|
+
disabled: boolean;
|
|
212
|
+
label: string;
|
|
213
|
+
private _handleClick;
|
|
214
|
+
render(): lit_html.TemplateResult<1>;
|
|
215
|
+
}
|
|
216
|
+
declare global {
|
|
217
|
+
interface HTMLElementTagNameMap {
|
|
218
|
+
'arvea-radio': ArveaRadio;
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
/**
|
|
223
|
+
* @element arvea-slider
|
|
224
|
+
*
|
|
225
|
+
* @prop {number} value - Current value of the slider
|
|
226
|
+
* @prop {number} min - Minimum value (default: 0)
|
|
227
|
+
* @prop {number} max - Maximum value (default: 100)
|
|
228
|
+
* @prop {number} step - Step increment (default: 1)
|
|
229
|
+
* @prop {boolean} disabled - Disables the slider
|
|
230
|
+
* @prop {string} label - Visible label above the track
|
|
231
|
+
* @prop {boolean} showValue - Shows the current value in the head row
|
|
232
|
+
* @prop {string} valuePrefix - Prepended to the displayed value (e.g. '$')
|
|
233
|
+
* @prop {string} valueSuffix - Appended to the displayed value (e.g. '%')
|
|
234
|
+
* @prop {number} tickStep - When >0, draws tick marks at every N units
|
|
235
|
+
* @prop {string} name - Form name
|
|
236
|
+
*
|
|
237
|
+
* @fires arvea-input - Live updates while dragging (detail: { value })
|
|
238
|
+
* @fires arvea-change - When the value is committed (detail: { value })
|
|
239
|
+
* @fires change - Back-compat: dispatched alongside arvea-input
|
|
240
|
+
*
|
|
241
|
+
* @example
|
|
242
|
+
* <arvea-slider label="Volume" show-value value-suffix="%"></arvea-slider>
|
|
243
|
+
* <arvea-slider min="-50" max="50" step="5" tick-step="10"></arvea-slider>
|
|
244
|
+
*/
|
|
245
|
+
declare class ArveaSlider extends LitElement {
|
|
246
|
+
static styles: lit.CSSResult[];
|
|
247
|
+
value: number;
|
|
248
|
+
min: number;
|
|
249
|
+
max: number;
|
|
250
|
+
step: number;
|
|
251
|
+
disabled: boolean;
|
|
252
|
+
label: string;
|
|
253
|
+
showValue: boolean;
|
|
254
|
+
valuePrefix: string;
|
|
255
|
+
valueSuffix: string;
|
|
256
|
+
tickStep: number;
|
|
257
|
+
name: string;
|
|
258
|
+
private _focused;
|
|
259
|
+
private get _percentage();
|
|
260
|
+
private _ticks;
|
|
261
|
+
private _tickPercent;
|
|
262
|
+
private _formatValue;
|
|
263
|
+
private _handleInput;
|
|
264
|
+
private _handleChange;
|
|
265
|
+
private _handleFocus;
|
|
266
|
+
private _handleBlur;
|
|
267
|
+
render(): lit_html.TemplateResult<1>;
|
|
268
|
+
}
|
|
269
|
+
declare global {
|
|
270
|
+
interface HTMLElementTagNameMap {
|
|
271
|
+
'arvea-slider': ArveaSlider;
|
|
272
|
+
}
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
type ArveaInputType = 'text' | 'email' | 'password' | 'number' | 'tel' | 'url' | 'search';
|
|
276
|
+
type ArveaInputTextAlign = 'left' | 'right';
|
|
277
|
+
type ArveaInputVariant = 'default' | 'underline';
|
|
278
|
+
interface CountryOption {
|
|
279
|
+
name: string;
|
|
280
|
+
flag: string;
|
|
281
|
+
dialCode: string;
|
|
282
|
+
}
|
|
283
|
+
interface ArveaInputProps {
|
|
284
|
+
label?: string;
|
|
285
|
+
hideLabel?: boolean;
|
|
286
|
+
type?: ArveaInputType;
|
|
287
|
+
variant?: ArveaInputVariant;
|
|
288
|
+
name?: string;
|
|
289
|
+
value?: string;
|
|
290
|
+
placeholder?: string;
|
|
291
|
+
disabled?: boolean;
|
|
292
|
+
readonly?: boolean;
|
|
293
|
+
required?: boolean;
|
|
294
|
+
invalid?: boolean;
|
|
295
|
+
hasWarning?: boolean;
|
|
296
|
+
showValid?: boolean;
|
|
297
|
+
validationHint?: string;
|
|
298
|
+
optionalLabel?: string;
|
|
299
|
+
textAlign?: ArveaInputTextAlign;
|
|
300
|
+
flagSrc?: string;
|
|
301
|
+
dialCode?: string;
|
|
302
|
+
hintEnd?: string;
|
|
303
|
+
}
|
|
304
|
+
|
|
305
|
+
/**
|
|
306
|
+
* @element arvea-input
|
|
307
|
+
*
|
|
308
|
+
* @prop {string} label - Visible label for the input
|
|
309
|
+
* @prop {boolean} hideLabel - Visually hides the label (still accessible)
|
|
310
|
+
* @prop {string} type - text | email | password | number | tel | url | search
|
|
311
|
+
* @prop {string} name - Form name
|
|
312
|
+
* @prop {string} value - Current value
|
|
313
|
+
* @prop {string} placeholder - Placeholder text
|
|
314
|
+
* @prop {boolean} disabled
|
|
315
|
+
* @prop {boolean} readonly
|
|
316
|
+
* @prop {boolean} required
|
|
317
|
+
* @prop {boolean} invalid - Triggers error styles
|
|
318
|
+
* @prop {boolean} hasWarning - Triggers warning styles
|
|
319
|
+
* @prop {boolean} showValid - Triggers valid styles
|
|
320
|
+
* @prop {string} validationHint - Helper / error message below the input
|
|
321
|
+
* @prop {string} optionalLabel - Text shown next to label when not required
|
|
322
|
+
* @prop {'left'|'right'} textAlign
|
|
323
|
+
* @prop {CountryOption[]} countries - List of country options for phone prefix dropdown
|
|
324
|
+
*
|
|
325
|
+
* @slot prefix - Left-aligned content (icon)
|
|
326
|
+
* @slot suffix - Right-aligned content (icon)
|
|
327
|
+
*
|
|
328
|
+
* @fires arvea-input - When value changes (detail: { value })
|
|
329
|
+
* @fires arvea-change - When the input is committed (detail: { value })
|
|
330
|
+
* @fires arvea-country-change - When a country is selected (detail: CountryOption)
|
|
331
|
+
*/
|
|
332
|
+
declare class ArveaInput extends LitElement {
|
|
333
|
+
static styles: lit.CSSResult[];
|
|
334
|
+
label: string;
|
|
335
|
+
hideLabel: boolean;
|
|
336
|
+
type: ArveaInputType;
|
|
337
|
+
variant: ArveaInputVariant;
|
|
338
|
+
name: string;
|
|
339
|
+
value: string;
|
|
340
|
+
placeholder: string;
|
|
341
|
+
disabled: boolean;
|
|
342
|
+
readonly: boolean;
|
|
343
|
+
required: boolean;
|
|
344
|
+
invalid: boolean;
|
|
345
|
+
hasWarning: boolean;
|
|
346
|
+
showValid: boolean;
|
|
347
|
+
validationHint: string;
|
|
348
|
+
optionalLabel: string;
|
|
349
|
+
textAlign: ArveaInputTextAlign;
|
|
350
|
+
flagSrc: string;
|
|
351
|
+
dialCode: string;
|
|
352
|
+
hintEnd: string;
|
|
353
|
+
digitsOnly: boolean;
|
|
354
|
+
countries: CountryOption[];
|
|
355
|
+
private _open;
|
|
356
|
+
private _input;
|
|
357
|
+
private _hasPrefix;
|
|
358
|
+
private _hasSuffix;
|
|
359
|
+
private _closeHandler;
|
|
360
|
+
private _onInput;
|
|
361
|
+
private _onChange;
|
|
362
|
+
private _onSlotChange;
|
|
363
|
+
/** Focuses the inner input. */
|
|
364
|
+
focus(): void;
|
|
365
|
+
private _clear;
|
|
366
|
+
private _toggleDropdown;
|
|
367
|
+
private _removeCloseHandler;
|
|
368
|
+
private _selectCountry;
|
|
369
|
+
disconnectedCallback(): void;
|
|
370
|
+
private _renderAutoIcon;
|
|
371
|
+
private _renderCountryDropdown;
|
|
372
|
+
render(): lit_html.TemplateResult<1>;
|
|
373
|
+
}
|
|
374
|
+
declare global {
|
|
375
|
+
interface HTMLElementTagNameMap {
|
|
376
|
+
'arvea-input': ArveaInput;
|
|
377
|
+
}
|
|
378
|
+
}
|
|
379
|
+
|
|
380
|
+
/**
|
|
381
|
+
* @file countries.ts
|
|
382
|
+
* @description Full country dataset for arvea-phone-number.
|
|
383
|
+
*
|
|
384
|
+
* - `iso2` : lowercase ISO 3166-1 alpha-2 code (used for the flag image).
|
|
385
|
+
* - `name` : English country name.
|
|
386
|
+
* - `dialCode` : international calling code (without the leading "+").
|
|
387
|
+
* - `maxLength`: maximum national significant number length (digits, excluding
|
|
388
|
+
* the dial code) — based on intl-tel-input / libphonenumber
|
|
389
|
+
* metadata. e.g. Tunisia = 8, Algeria = 9.
|
|
390
|
+
*
|
|
391
|
+
* Flags are served from https://flagcdn.com/w20/<iso2>.png (same source the
|
|
392
|
+
* rest of the kit already uses).
|
|
393
|
+
*/
|
|
394
|
+
interface PhoneCountry {
|
|
395
|
+
iso2: string;
|
|
396
|
+
name: string;
|
|
397
|
+
dialCode: string;
|
|
398
|
+
/** Maximum national number length (digits). Used as input cap and, when minLength is absent, as the exact valid length. */
|
|
399
|
+
maxLength: number;
|
|
400
|
+
/** Minimum national number length (digits). Only set for countries where valid numbers are shorter than maxLength. */
|
|
401
|
+
minLength?: number;
|
|
402
|
+
}
|
|
403
|
+
/** Supported display languages for country names. */
|
|
404
|
+
type PhoneLanguage = 'en' | 'fr' | 'ar';
|
|
405
|
+
declare const flagUrl: (iso2: string) => string;
|
|
406
|
+
declare const COUNTRIES: PhoneCountry[];
|
|
407
|
+
/** Look up a country by its ISO2 code (case-insensitive). */
|
|
408
|
+
declare const findCountry: (iso2: string) => PhoneCountry | undefined;
|
|
409
|
+
/**
|
|
410
|
+
* Resolve a country from a full name (e.g. "Tunisia", "tunisia") or, as a
|
|
411
|
+
* fallback, an ISO2 code (e.g. "tn"). Case-insensitive.
|
|
412
|
+
*/
|
|
413
|
+
declare const resolveCountry: (value: string) => PhoneCountry | undefined;
|
|
414
|
+
|
|
415
|
+
/**
|
|
416
|
+
* @element arvea-phone-number
|
|
417
|
+
*
|
|
418
|
+
* International phone number input: selectable country flag + dial code with a
|
|
419
|
+
* searchable dropdown of all countries, and a number field whose length is
|
|
420
|
+
* capped to the selected country's national number length.
|
|
421
|
+
*
|
|
422
|
+
* @prop {string} country - Selected country: ISO2 code or full name (stored/reflected as ISO2; default 'tn')
|
|
423
|
+
* @prop {string} language - Country-name display language: 'en' | 'fr' | 'ar' (default 'en')
|
|
424
|
+
* @prop {string} value - National number digits (no dial code)
|
|
425
|
+
* @prop {string} label - Field label
|
|
426
|
+
* @prop {string} placeholder - Number input placeholder
|
|
427
|
+
* @prop {string} search-placeholder - Dropdown search placeholder
|
|
428
|
+
* @prop {boolean} disabled
|
|
429
|
+
* @prop {boolean} required
|
|
430
|
+
* @prop {boolean} invalid - Reflected; forces the error style
|
|
431
|
+
* @prop {string} validation-hint - Hint text shown under the field
|
|
432
|
+
*
|
|
433
|
+
* @fires arvea-input { value } - on every keystroke
|
|
434
|
+
* @fires arvea-change { iso2, dialCode, nationalNumber, e164, valid, country }
|
|
435
|
+
* @fires arvea-country-change { country } - when the country changes
|
|
436
|
+
*/
|
|
437
|
+
declare class ArveaPhoneNumber extends LitElement {
|
|
438
|
+
static styles: lit.CSSResult[];
|
|
439
|
+
country: string;
|
|
440
|
+
language: PhoneLanguage;
|
|
441
|
+
value: string;
|
|
442
|
+
label: string;
|
|
443
|
+
placeholder: string;
|
|
444
|
+
searchPlaceholder: string;
|
|
445
|
+
noResultsText: string;
|
|
446
|
+
disabled: boolean;
|
|
447
|
+
required: boolean;
|
|
448
|
+
invalid: boolean;
|
|
449
|
+
validationHint: string;
|
|
450
|
+
name: string;
|
|
451
|
+
/**
|
|
452
|
+
* Countries pinned to the top of the dropdown (by name or ISO2). Accepts a
|
|
453
|
+
* comma-separated attribute (`preferred-countries="tn,dz,..."`) or an array
|
|
454
|
+
* property. Defaults to a North/West-Africa suggestion set.
|
|
455
|
+
*/
|
|
456
|
+
preferredCountries: string[];
|
|
457
|
+
private _open;
|
|
458
|
+
private _query;
|
|
459
|
+
private _activeIndex;
|
|
460
|
+
private _searchInput?;
|
|
461
|
+
private _prefixBtn?;
|
|
462
|
+
private _onDocPointer;
|
|
463
|
+
connectedCallback(): void;
|
|
464
|
+
disconnectedCallback(): void;
|
|
465
|
+
private get _country();
|
|
466
|
+
/** Country name in the active language (English fallback). */
|
|
467
|
+
private _label;
|
|
468
|
+
/** Is the active language right-to-left? */
|
|
469
|
+
private get _rtl();
|
|
470
|
+
private static readonly _i18n;
|
|
471
|
+
private get _searchPlaceholder();
|
|
472
|
+
private get _noResultsText();
|
|
473
|
+
/**
|
|
474
|
+
* Full list localized and re-sorted for the active language, cached so the
|
|
475
|
+
* (relatively expensive) localize + `Intl.Collator` sort runs once per
|
|
476
|
+
* language rather than on every render.
|
|
477
|
+
*/
|
|
478
|
+
private _localizedCache?;
|
|
479
|
+
private get _localizedCountries();
|
|
480
|
+
private get _filtered();
|
|
481
|
+
/** Resolved, de-duplicated preferred countries. */
|
|
482
|
+
private get _preferred();
|
|
483
|
+
/** Flat list as rendered/navigated: preferred-first when not searching. */
|
|
484
|
+
private get _visibleList();
|
|
485
|
+
/** Digits-only view of `value` — guards against programmatic assignment of formatted strings. */
|
|
486
|
+
private get _digits();
|
|
487
|
+
/** True when the number length is within the country's valid range. */
|
|
488
|
+
get valid(): boolean;
|
|
489
|
+
get e164(): string;
|
|
490
|
+
/** Insert spaces into the national number per the country's group pattern. */
|
|
491
|
+
private _formatNational;
|
|
492
|
+
private _onNumberInput;
|
|
493
|
+
private _emitChange;
|
|
494
|
+
private _toggle;
|
|
495
|
+
private _openDropdown;
|
|
496
|
+
private _close;
|
|
497
|
+
private _onSearch;
|
|
498
|
+
private _selectCountry;
|
|
499
|
+
private _onSearchKey;
|
|
500
|
+
render(): lit_html.TemplateResult<1>;
|
|
501
|
+
private _renderPopup;
|
|
502
|
+
}
|
|
503
|
+
declare global {
|
|
504
|
+
interface HTMLElementTagNameMap {
|
|
505
|
+
'arvea-phone-number': ArveaPhoneNumber;
|
|
506
|
+
}
|
|
507
|
+
}
|
|
508
|
+
|
|
509
|
+
/**
|
|
510
|
+
* @element arvea-textarea
|
|
511
|
+
*
|
|
512
|
+
* Multi-line text input with label, validation, and optional auto-resize.
|
|
513
|
+
*
|
|
514
|
+
* @fires arvea-input - On every keystroke (detail: { value })
|
|
515
|
+
* @fires arvea-change - On commit (detail: { value })
|
|
516
|
+
*/
|
|
517
|
+
declare class ArveaTextarea extends LitElement {
|
|
518
|
+
static styles: lit.CSSResult[];
|
|
519
|
+
label: string;
|
|
520
|
+
hideLabel: boolean;
|
|
521
|
+
name: string;
|
|
522
|
+
value: string;
|
|
523
|
+
placeholder: string;
|
|
524
|
+
disabled: boolean;
|
|
525
|
+
readonly: boolean;
|
|
526
|
+
required: boolean;
|
|
527
|
+
invalid: boolean;
|
|
528
|
+
hasWarning: boolean;
|
|
529
|
+
showValid: boolean;
|
|
530
|
+
validationHint: string;
|
|
531
|
+
optionalLabel: string;
|
|
532
|
+
rows: number;
|
|
533
|
+
maxLength?: number;
|
|
534
|
+
autoResize: boolean;
|
|
535
|
+
private _ta;
|
|
536
|
+
focus(): void;
|
|
537
|
+
private _resize;
|
|
538
|
+
private _onInput;
|
|
539
|
+
private _onChange;
|
|
540
|
+
updated(changed: PropertyValues): void;
|
|
541
|
+
render(): lit_html.TemplateResult<1>;
|
|
542
|
+
}
|
|
543
|
+
declare global {
|
|
544
|
+
interface HTMLElementTagNameMap {
|
|
545
|
+
'arvea-textarea': ArveaTextarea;
|
|
546
|
+
}
|
|
547
|
+
}
|
|
548
|
+
|
|
549
|
+
interface ArveaSelectOption {
|
|
550
|
+
value: string;
|
|
551
|
+
label: string;
|
|
552
|
+
disabled?: boolean;
|
|
553
|
+
group?: string;
|
|
554
|
+
description?: string;
|
|
555
|
+
/** Optional flag/leading image URL shown before the label in the trigger and options. */
|
|
556
|
+
flagSrc?: string;
|
|
557
|
+
meta?: unknown;
|
|
558
|
+
}
|
|
559
|
+
type ArveaSelectFetchFn = (query: string) => Promise<ArveaSelectOption[]>;
|
|
560
|
+
type ArveaSelectFilterFn = (query: string, option: ArveaSelectOption) => boolean;
|
|
561
|
+
type ArveaSelectGroupBy = string | ((option: ArveaSelectOption) => string);
|
|
562
|
+
interface ArveaSelectProps {
|
|
563
|
+
label?: string;
|
|
564
|
+
hideLabel?: boolean;
|
|
565
|
+
name?: string;
|
|
566
|
+
value?: string | string[];
|
|
567
|
+
placeholder?: string;
|
|
568
|
+
options?: ArveaSelectOption[];
|
|
569
|
+
disabled?: boolean;
|
|
570
|
+
required?: boolean;
|
|
571
|
+
invalid?: boolean;
|
|
572
|
+
validationHint?: string;
|
|
573
|
+
optionalLabel?: string;
|
|
574
|
+
searchable?: boolean;
|
|
575
|
+
multiple?: boolean;
|
|
576
|
+
clearable?: boolean;
|
|
577
|
+
loading?: boolean;
|
|
578
|
+
fetchOptions?: ArveaSelectFetchFn;
|
|
579
|
+
debounceMs?: number;
|
|
580
|
+
noResultsText?: string;
|
|
581
|
+
loadingText?: string;
|
|
582
|
+
maxTagCount?: number;
|
|
583
|
+
groupBy?: ArveaSelectGroupBy;
|
|
584
|
+
createable?: boolean;
|
|
585
|
+
filterFn?: ArveaSelectFilterFn;
|
|
586
|
+
open?: boolean;
|
|
587
|
+
}
|
|
588
|
+
|
|
589
|
+
interface OptionState {
|
|
590
|
+
selected: boolean;
|
|
591
|
+
active: boolean;
|
|
592
|
+
}
|
|
593
|
+
/**
|
|
594
|
+
* @element arvea-select
|
|
595
|
+
*
|
|
596
|
+
* Select2-style combobox: searchable, multi-select, async, grouped, createable,
|
|
597
|
+
* keyboard navigable, with custom item rendering.
|
|
598
|
+
*
|
|
599
|
+
* @fires arvea-change { value, selectedOptions }
|
|
600
|
+
* @fires arvea-select-open
|
|
601
|
+
* @fires arvea-select-close
|
|
602
|
+
* @fires arvea-search { query }
|
|
603
|
+
* @fires arvea-fetch-error { error, query }
|
|
604
|
+
* @fires arvea-create { label, value }
|
|
605
|
+
* @fires arvea-clear
|
|
606
|
+
*/
|
|
607
|
+
declare class ArveaSelect extends LitElement {
|
|
608
|
+
static styles: lit.CSSResult[];
|
|
609
|
+
static formAssociated: boolean;
|
|
610
|
+
label: string;
|
|
611
|
+
hideLabel: boolean;
|
|
612
|
+
name: string;
|
|
613
|
+
value: string | string[];
|
|
614
|
+
placeholder: string;
|
|
615
|
+
options: ArveaSelectOption[];
|
|
616
|
+
disabled: boolean;
|
|
617
|
+
required: boolean;
|
|
618
|
+
invalid: boolean;
|
|
619
|
+
validationHint: string;
|
|
620
|
+
optionalLabel: string;
|
|
621
|
+
/** Leading flag/image shown in the trigger (e.g. default country flag for the placeholder state). */
|
|
622
|
+
flagSrc: string;
|
|
623
|
+
searchable: boolean;
|
|
624
|
+
multiple: boolean;
|
|
625
|
+
clearable: boolean;
|
|
626
|
+
loading: boolean;
|
|
627
|
+
fetchOptions?: ArveaSelectFetchFn;
|
|
628
|
+
debounceMs: number;
|
|
629
|
+
noResultsText: string;
|
|
630
|
+
loadingText: string;
|
|
631
|
+
maxTagCount: number;
|
|
632
|
+
groupBy?: ArveaSelectGroupBy;
|
|
633
|
+
createable: boolean;
|
|
634
|
+
filterFn?: ArveaSelectFilterFn;
|
|
635
|
+
open: boolean;
|
|
636
|
+
size: 'sm' | 'md' | 'lg';
|
|
637
|
+
renderOption?: (option: ArveaSelectOption, state: OptionState) => TemplateResult;
|
|
638
|
+
private _query;
|
|
639
|
+
private _activeIndex;
|
|
640
|
+
private _asyncResults;
|
|
641
|
+
private _fetchError;
|
|
642
|
+
private _popupEl?;
|
|
643
|
+
private _popupSearchInput?;
|
|
644
|
+
private _searchInput?;
|
|
645
|
+
private _internals?;
|
|
646
|
+
private _debounceTimer?;
|
|
647
|
+
private _abort?;
|
|
648
|
+
private _onDocPointer;
|
|
649
|
+
private _onWinReflow;
|
|
650
|
+
constructor();
|
|
651
|
+
connectedCallback(): void;
|
|
652
|
+
disconnectedCallback(): void;
|
|
653
|
+
updated(changed: Map<string, unknown>): void;
|
|
654
|
+
get form(): HTMLFormElement | null;
|
|
655
|
+
get validity(): ValidityState | undefined;
|
|
656
|
+
get validationMessage(): string;
|
|
657
|
+
checkValidity(): boolean;
|
|
658
|
+
reportValidity(): boolean;
|
|
659
|
+
private get _valueArray();
|
|
660
|
+
private get _allOptions();
|
|
661
|
+
private get _filtered();
|
|
662
|
+
private get _groups();
|
|
663
|
+
private get _flatVisible();
|
|
664
|
+
private readonly _knownOptions;
|
|
665
|
+
private get _selectedOptions();
|
|
666
|
+
private _onTriggerPointer;
|
|
667
|
+
private _focusSearchSoon;
|
|
668
|
+
private _onKeydown;
|
|
669
|
+
private _onSearchInput;
|
|
670
|
+
private _scheduleFetch;
|
|
671
|
+
private _runFetch;
|
|
672
|
+
private _firstSelectable;
|
|
673
|
+
private _lastSelectable;
|
|
674
|
+
private _moveActive;
|
|
675
|
+
private _toggleOption;
|
|
676
|
+
private _createTag;
|
|
677
|
+
private _setValue;
|
|
678
|
+
private _syncFormState;
|
|
679
|
+
private _clear;
|
|
680
|
+
private _open;
|
|
681
|
+
private _close;
|
|
682
|
+
private _afterOpen;
|
|
683
|
+
private _flatParent;
|
|
684
|
+
private _findScrollBounds;
|
|
685
|
+
private _positionPopup;
|
|
686
|
+
render(): TemplateResult<1>;
|
|
687
|
+
private _renderTrigger;
|
|
688
|
+
private _renderFlag;
|
|
689
|
+
private _renderPopup;
|
|
690
|
+
private _renderGroup;
|
|
691
|
+
private _iconChevron;
|
|
692
|
+
private _iconX;
|
|
693
|
+
}
|
|
694
|
+
declare global {
|
|
695
|
+
interface HTMLElementTagNameMap {
|
|
696
|
+
'arvea-select': ArveaSelect;
|
|
697
|
+
}
|
|
698
|
+
}
|
|
699
|
+
|
|
700
|
+
/**
|
|
701
|
+
* @element arvea-tag
|
|
702
|
+
*
|
|
703
|
+
* @prop {boolean} selected - Renders selected styles
|
|
704
|
+
* @prop {boolean} clickable - Renders as a <button> and dispatches click
|
|
705
|
+
* @prop {boolean} removable - Renders a close button on the right
|
|
706
|
+
* @prop {boolean} disabled
|
|
707
|
+
*
|
|
708
|
+
* @slot prefix - Leading icon
|
|
709
|
+
* @slot - Default slot for tag text
|
|
710
|
+
* @slot suffix - Trailing icon
|
|
711
|
+
*
|
|
712
|
+
* @fires arvea-remove - When the remove button is clicked
|
|
713
|
+
*/
|
|
714
|
+
declare class ArveaTag extends LitElement {
|
|
715
|
+
static styles: lit.CSSResult[];
|
|
716
|
+
selected: boolean;
|
|
717
|
+
clickable: boolean;
|
|
718
|
+
removable: boolean;
|
|
719
|
+
disabled: boolean;
|
|
720
|
+
private _onRemove;
|
|
721
|
+
private _renderInner;
|
|
722
|
+
render(): lit_html.TemplateResult<1>;
|
|
723
|
+
}
|
|
724
|
+
declare global {
|
|
725
|
+
interface HTMLElementTagNameMap {
|
|
726
|
+
'arvea-tag': ArveaTag;
|
|
727
|
+
}
|
|
728
|
+
}
|
|
729
|
+
|
|
730
|
+
type ArveaSpinnerSize = 'sm' | 'md' | 'lg';
|
|
731
|
+
interface ArveaSpinnerProps {
|
|
732
|
+
size?: ArveaSpinnerSize;
|
|
733
|
+
label?: string;
|
|
734
|
+
}
|
|
735
|
+
|
|
736
|
+
/**
|
|
737
|
+
* @element arvea-spinner
|
|
738
|
+
*
|
|
739
|
+
* @prop {'sm'|'md'|'lg'} size - Spinner size (default: 'md')
|
|
740
|
+
* @prop {string} label - Accessible loading label (default: 'Loading')
|
|
741
|
+
*/
|
|
742
|
+
declare class ArveaSpinner extends LitElement {
|
|
743
|
+
static styles: lit.CSSResult[];
|
|
744
|
+
size: ArveaSpinnerSize;
|
|
745
|
+
label: string;
|
|
746
|
+
render(): lit_html.TemplateResult<1>;
|
|
747
|
+
}
|
|
748
|
+
declare global {
|
|
749
|
+
interface HTMLElementTagNameMap {
|
|
750
|
+
'arvea-spinner': ArveaSpinner;
|
|
751
|
+
}
|
|
752
|
+
}
|
|
753
|
+
|
|
754
|
+
type ArveaTooltipPlacement = 'top' | 'right' | 'bottom' | 'left';
|
|
755
|
+
interface ArveaTooltipProps {
|
|
756
|
+
content?: string;
|
|
757
|
+
placement?: ArveaTooltipPlacement;
|
|
758
|
+
open?: boolean;
|
|
759
|
+
disabled?: boolean;
|
|
760
|
+
delay?: number;
|
|
761
|
+
}
|
|
762
|
+
|
|
763
|
+
/**
|
|
764
|
+
* @element arvea-tooltip
|
|
765
|
+
*
|
|
766
|
+
* Wrap a trigger element with this component to display a tooltip on
|
|
767
|
+
* hover / focus.
|
|
768
|
+
*
|
|
769
|
+
* @prop {string} content - Tooltip text
|
|
770
|
+
* @prop {'top'|'right'|'bottom'|'left'} placement - Default 'top'
|
|
771
|
+
* @prop {boolean} open - Force open
|
|
772
|
+
* @prop {boolean} disabled - Disables tooltip
|
|
773
|
+
* @prop {number} delay - Show delay in ms (default 100)
|
|
774
|
+
*
|
|
775
|
+
* @slot - The trigger element
|
|
776
|
+
* @slot content - Rich content alternative to the `content` attribute
|
|
777
|
+
*/
|
|
778
|
+
declare class ArveaTooltip extends LitElement {
|
|
779
|
+
static styles: lit.CSSResult[];
|
|
780
|
+
content: string;
|
|
781
|
+
placement: ArveaTooltipPlacement;
|
|
782
|
+
open: boolean;
|
|
783
|
+
disabled: boolean;
|
|
784
|
+
delay: number;
|
|
785
|
+
private _showTimer?;
|
|
786
|
+
private _hideTimer?;
|
|
787
|
+
private _id;
|
|
788
|
+
connectedCallback(): void;
|
|
789
|
+
disconnectedCallback(): void;
|
|
790
|
+
private _show;
|
|
791
|
+
private _hide;
|
|
792
|
+
render(): lit_html.TemplateResult<1>;
|
|
793
|
+
}
|
|
794
|
+
declare global {
|
|
795
|
+
interface HTMLElementTagNameMap {
|
|
796
|
+
'arvea-tooltip': ArveaTooltip;
|
|
797
|
+
}
|
|
798
|
+
}
|
|
799
|
+
|
|
800
|
+
type ArveaCardVariant = 'default' | 'elevated' | 'outline';
|
|
801
|
+
interface ArveaCardProps {
|
|
802
|
+
variant?: ArveaCardVariant;
|
|
803
|
+
padding?: 'none' | 'sm' | 'md' | 'lg';
|
|
804
|
+
interactive?: boolean;
|
|
805
|
+
}
|
|
806
|
+
|
|
807
|
+
/**
|
|
808
|
+
* @element arvea-card
|
|
809
|
+
*
|
|
810
|
+
* Generic container with three variants and four padding options.
|
|
811
|
+
*
|
|
812
|
+
* @prop {'default'|'elevated'|'outline'} variant
|
|
813
|
+
* @prop {'none'|'sm'|'md'|'lg'} padding
|
|
814
|
+
* @prop {boolean} interactive - hover/focus styles
|
|
815
|
+
*
|
|
816
|
+
* @slot header
|
|
817
|
+
* @slot - main content
|
|
818
|
+
* @slot footer
|
|
819
|
+
*/
|
|
820
|
+
declare class ArveaCard extends LitElement {
|
|
821
|
+
static styles: lit.CSSResult[];
|
|
822
|
+
variant: ArveaCardVariant;
|
|
823
|
+
padding: 'none' | 'sm' | 'md' | 'lg';
|
|
824
|
+
interactive: boolean;
|
|
825
|
+
render(): lit_html.TemplateResult<1>;
|
|
826
|
+
}
|
|
827
|
+
declare global {
|
|
828
|
+
interface HTMLElementTagNameMap {
|
|
829
|
+
'arvea-card': ArveaCard;
|
|
830
|
+
}
|
|
831
|
+
}
|
|
832
|
+
|
|
833
|
+
/**
|
|
834
|
+
* @element arvea-media-card
|
|
835
|
+
*
|
|
836
|
+
* Full-bleed image card with an uppercase label and a clickable arrow button.
|
|
837
|
+
*
|
|
838
|
+
* @prop {'sm'|'md'|'lg'|'xl'} size - Card height (default: md)
|
|
839
|
+
* @prop {'sm'|'md'|'lg'|'full'} radius - Border-radius (default: md)
|
|
840
|
+
* @prop {'none'|'light'|'medium'|'dark'} overlay - Gradient darkness (default: medium)
|
|
841
|
+
* @prop {'bottom'|'top'} label-position - Where the label & arrow sit (default: bottom)
|
|
842
|
+
* @prop {string} src - Background image URL
|
|
843
|
+
* @prop {string} label - Category / title text (displayed uppercase)
|
|
844
|
+
* @prop {string} href - URL the arrow button navigates to
|
|
845
|
+
* @prop {string} target - Link target (default: _blank)
|
|
846
|
+
*
|
|
847
|
+
* @fires arvea-media-card-click - { href } fired when the arrow button is clicked
|
|
848
|
+
*/
|
|
849
|
+
declare class ArveaMediaCard extends LitElement {
|
|
850
|
+
static styles: lit.CSSResult[];
|
|
851
|
+
src: string;
|
|
852
|
+
label: string;
|
|
853
|
+
href: string;
|
|
854
|
+
target: string;
|
|
855
|
+
size: 'sm' | 'md' | 'lg' | 'xl';
|
|
856
|
+
radius: 'sm' | 'md' | 'lg' | 'full';
|
|
857
|
+
overlay: 'none' | 'light' | 'medium' | 'dark';
|
|
858
|
+
labelPosition: 'bottom' | 'top';
|
|
859
|
+
private _navigate;
|
|
860
|
+
render(): lit_html.TemplateResult<1>;
|
|
861
|
+
}
|
|
862
|
+
declare global {
|
|
863
|
+
interface HTMLElementTagNameMap {
|
|
864
|
+
'arvea-media-card': ArveaMediaCard;
|
|
865
|
+
}
|
|
866
|
+
}
|
|
867
|
+
|
|
868
|
+
/**
|
|
869
|
+
* @element arvea-product-card
|
|
870
|
+
*
|
|
871
|
+
* E-commerce product card with image, add-to-cart button, name and price.
|
|
872
|
+
*
|
|
873
|
+
* @prop {string} src - Product image URL
|
|
874
|
+
* @prop {string} name - Product name (displayed uppercase)
|
|
875
|
+
* @prop {string} price - Formatted price (e.g. "16,900")
|
|
876
|
+
* @prop {string} currency - Currency label shown after the price (e.g. "TND")
|
|
877
|
+
* @prop {string} alt - Alt text for the product image (defaults to name)
|
|
878
|
+
* @prop {string} badge - Optional badge text (e.g. "BIENTÔT DISPONIBLE")
|
|
879
|
+
* @prop {string} badge-color - Badge background color (default: #e53935)
|
|
880
|
+
*
|
|
881
|
+
* @fires arvea-product-card-add - Fired when the cart button is clicked
|
|
882
|
+
*
|
|
883
|
+
* @csspart card - The outer wrapper
|
|
884
|
+
* @csspart image-wrapper - The image container
|
|
885
|
+
* @csspart image - The <img> element
|
|
886
|
+
* @csspart badge - The badge label
|
|
887
|
+
* @csspart cart-btn - The circular add-to-cart button
|
|
888
|
+
* @csspart info - The text section below the image
|
|
889
|
+
* @csspart name - The product name element
|
|
890
|
+
* @csspart price - The price element
|
|
891
|
+
*/
|
|
892
|
+
declare class ArveaProductCard extends LitElement {
|
|
893
|
+
static styles: lit.CSSResult[];
|
|
894
|
+
src: string;
|
|
895
|
+
name: string;
|
|
896
|
+
price: string;
|
|
897
|
+
currency: string;
|
|
898
|
+
alt: string;
|
|
899
|
+
badge: string;
|
|
900
|
+
badgeColor: string;
|
|
901
|
+
private _onAdd;
|
|
902
|
+
render(): lit_html.TemplateResult<1>;
|
|
903
|
+
}
|
|
904
|
+
declare global {
|
|
905
|
+
interface HTMLElementTagNameMap {
|
|
906
|
+
'arvea-product-card': ArveaProductCard;
|
|
907
|
+
}
|
|
908
|
+
}
|
|
909
|
+
|
|
910
|
+
type ArveaActionButtonSize = 'default' | 'sm' | 'md' | 'lg';
|
|
911
|
+
type ArveaActionButtonVariant = 'validate' | 'edit' | 'payment' | 'order' | 'price' | 'delete' | 'view' | 'pdf' | 'pause' | 'download' | 'upload' | 'copy' | 'print' | 'settings' | 'archive' | 'restore';
|
|
912
|
+
|
|
913
|
+
/**
|
|
914
|
+
* @element arvea-action-button
|
|
915
|
+
*
|
|
916
|
+
* Icon action button with a configurable background color, icon color,
|
|
917
|
+
* and a tooltip label that appears on hover.
|
|
918
|
+
*
|
|
919
|
+
* @prop {ArveaActionButtonVariant} variant - Preset that sets icon + colors automatically
|
|
920
|
+
* @prop {string} icon - SVG markup (overrides variant icon)
|
|
921
|
+
* @prop {string} label - Tooltip text shown on hover (also used as aria-label)
|
|
922
|
+
* @prop {string} bg-color - Background color (overrides variant color)
|
|
923
|
+
* @prop {string} color - Icon/foreground color (overrides variant color)
|
|
924
|
+
* @prop {'sm'|'md'|'lg'} size - Button size (default: md)
|
|
925
|
+
* @prop {boolean} disabled - Disables the button
|
|
926
|
+
*
|
|
927
|
+
* @fires arvea-action-click - Fired on click — detail: { label }
|
|
928
|
+
*
|
|
929
|
+
* @csspart button - The <button> element
|
|
930
|
+
* @csspart icon - The icon wrapper
|
|
931
|
+
* @csspart tooltip - The tooltip label
|
|
932
|
+
*/
|
|
933
|
+
declare class ArveaActionButton extends LitElement {
|
|
934
|
+
static styles: lit.CSSResult[];
|
|
935
|
+
variant: ArveaActionButtonVariant | '';
|
|
936
|
+
icon: string;
|
|
937
|
+
label: string;
|
|
938
|
+
bgColor: string;
|
|
939
|
+
color: string;
|
|
940
|
+
size: ArveaActionButtonSize;
|
|
941
|
+
disabled: boolean;
|
|
942
|
+
private get _resolved();
|
|
943
|
+
private _onClick;
|
|
944
|
+
private get _buttonStyle();
|
|
945
|
+
render(): lit_html.TemplateResult<1>;
|
|
946
|
+
}
|
|
947
|
+
declare global {
|
|
948
|
+
interface HTMLElementTagNameMap {
|
|
949
|
+
'arvea-action-button': ArveaActionButton;
|
|
950
|
+
}
|
|
951
|
+
}
|
|
952
|
+
|
|
953
|
+
type ArveaAvatarSize = 'sm' | 'md' | 'lg';
|
|
954
|
+
type ArveaAvatarVariant = 'identity' | 'object';
|
|
955
|
+
interface ArveaAvatarProps {
|
|
956
|
+
src?: string;
|
|
957
|
+
alt?: string;
|
|
958
|
+
initials?: string;
|
|
959
|
+
size?: ArveaAvatarSize;
|
|
960
|
+
variant?: ArveaAvatarVariant;
|
|
961
|
+
}
|
|
962
|
+
|
|
963
|
+
/**
|
|
964
|
+
* @element arvea-avatar
|
|
965
|
+
*
|
|
966
|
+
* @prop {string} src - Image URL
|
|
967
|
+
* @prop {string} alt - Image alt text
|
|
968
|
+
* @prop {string} initials - Fallback initials (1-2 chars)
|
|
969
|
+
* @prop {'sm'|'md'|'lg'} size - default 'md'
|
|
970
|
+
* @prop {'identity'|'object'} variant - 'identity' = round, 'object' = square
|
|
971
|
+
*/
|
|
972
|
+
declare class ArveaAvatar extends LitElement {
|
|
973
|
+
static styles: lit.CSSResult[];
|
|
974
|
+
src: string;
|
|
975
|
+
alt: string;
|
|
976
|
+
initials: string;
|
|
977
|
+
size: ArveaAvatarSize;
|
|
978
|
+
variant: ArveaAvatarVariant;
|
|
979
|
+
private _imageFailed;
|
|
980
|
+
private _onError;
|
|
981
|
+
private _formatInitials;
|
|
982
|
+
render(): lit_html.TemplateResult<1>;
|
|
983
|
+
}
|
|
984
|
+
declare global {
|
|
985
|
+
interface HTMLElementTagNameMap {
|
|
986
|
+
'arvea-avatar': ArveaAvatar;
|
|
987
|
+
}
|
|
988
|
+
}
|
|
989
|
+
|
|
990
|
+
type ArveaProgressSize = 'sm' | 'md' | 'lg';
|
|
991
|
+
interface ArveaProgressBarProps {
|
|
992
|
+
value?: number;
|
|
993
|
+
max?: number;
|
|
994
|
+
size?: ArveaProgressSize;
|
|
995
|
+
label?: string;
|
|
996
|
+
showValue?: boolean;
|
|
997
|
+
indeterminate?: boolean;
|
|
998
|
+
}
|
|
999
|
+
|
|
1000
|
+
/**
|
|
1001
|
+
* @element arvea-progress-bar
|
|
1002
|
+
*
|
|
1003
|
+
* @prop {number} value - current value (0..max)
|
|
1004
|
+
* @prop {number} max - max value (default 100)
|
|
1005
|
+
* @prop {'sm'|'md'|'lg'} size - default 'md'
|
|
1006
|
+
* @prop {string} label - label shown above the bar
|
|
1007
|
+
* @prop {boolean} showValue - show percentage on the right
|
|
1008
|
+
* @prop {boolean} indeterminate - looping animation, ignores value
|
|
1009
|
+
*/
|
|
1010
|
+
declare class ArveaProgressBar extends LitElement {
|
|
1011
|
+
static styles: lit.CSSResult[];
|
|
1012
|
+
value: number;
|
|
1013
|
+
max: number;
|
|
1014
|
+
size: ArveaProgressSize;
|
|
1015
|
+
label: string;
|
|
1016
|
+
showValue: boolean;
|
|
1017
|
+
indeterminate: boolean;
|
|
1018
|
+
private get _percent();
|
|
1019
|
+
render(): lit_html.TemplateResult<1>;
|
|
1020
|
+
}
|
|
1021
|
+
declare global {
|
|
1022
|
+
interface HTMLElementTagNameMap {
|
|
1023
|
+
'arvea-progress-bar': ArveaProgressBar;
|
|
1024
|
+
}
|
|
1025
|
+
}
|
|
1026
|
+
|
|
1027
|
+
type ArveaSkeletonShape = 'rect' | 'circle' | 'text' | 'pill';
|
|
1028
|
+
interface ArveaSkeletonProps {
|
|
1029
|
+
shape?: ArveaSkeletonShape;
|
|
1030
|
+
width?: string;
|
|
1031
|
+
height?: string;
|
|
1032
|
+
radius?: string;
|
|
1033
|
+
lines?: number;
|
|
1034
|
+
loading?: boolean;
|
|
1035
|
+
}
|
|
1036
|
+
|
|
1037
|
+
/**
|
|
1038
|
+
* @element arvea-skeleton
|
|
1039
|
+
*
|
|
1040
|
+
* A shimmer placeholder used while content is loading.
|
|
1041
|
+
*
|
|
1042
|
+
* @prop {'rect'|'circle'|'text'|'pill'} shape - default 'rect'
|
|
1043
|
+
* @prop {string} width - CSS width (e.g. '120px', '60%')
|
|
1044
|
+
* @prop {string} height - CSS height
|
|
1045
|
+
* @prop {string} radius - Custom border-radius
|
|
1046
|
+
* @prop {number} lines - When >0, renders a stack of text lines
|
|
1047
|
+
* @prop {boolean} loading - When false, renders the default slot instead
|
|
1048
|
+
*
|
|
1049
|
+
* @slot - Real content rendered when loading=false
|
|
1050
|
+
*
|
|
1051
|
+
* @example
|
|
1052
|
+
* <arvea-skeleton width="200px" height="16px"></arvea-skeleton>
|
|
1053
|
+
* <arvea-skeleton shape="circle" width="40px" height="40px"></arvea-skeleton>
|
|
1054
|
+
* <arvea-skeleton lines="3"></arvea-skeleton>
|
|
1055
|
+
*/
|
|
1056
|
+
declare class ArveaSkeleton extends LitElement {
|
|
1057
|
+
static styles: lit.CSSResult[];
|
|
1058
|
+
shape: ArveaSkeletonShape;
|
|
1059
|
+
width: string;
|
|
1060
|
+
height: string;
|
|
1061
|
+
radius: string;
|
|
1062
|
+
lines: number;
|
|
1063
|
+
loading: boolean;
|
|
1064
|
+
private _hostStyle;
|
|
1065
|
+
render(): lit_html.TemplateResult<1>;
|
|
1066
|
+
}
|
|
1067
|
+
declare global {
|
|
1068
|
+
interface HTMLElementTagNameMap {
|
|
1069
|
+
'arvea-skeleton': ArveaSkeleton;
|
|
1070
|
+
}
|
|
1071
|
+
}
|
|
1072
|
+
|
|
1073
|
+
type ArveaSkeletonCardPreset = 'article' | 'media' | 'profile' | 'product' | 'list';
|
|
1074
|
+
type ArveaSkeletonCardVariant = 'default' | 'elevated' | 'outline';
|
|
1075
|
+
interface ArveaSkeletonCardProps {
|
|
1076
|
+
preset?: ArveaSkeletonCardPreset;
|
|
1077
|
+
variant?: ArveaSkeletonCardVariant;
|
|
1078
|
+
lines?: number;
|
|
1079
|
+
loading?: boolean;
|
|
1080
|
+
padding?: 'none' | 'sm' | 'md' | 'lg';
|
|
1081
|
+
}
|
|
1082
|
+
|
|
1083
|
+
/**
|
|
1084
|
+
* @element arvea-skeleton-card
|
|
1085
|
+
*
|
|
1086
|
+
* A shimmering card placeholder with several common layout presets.
|
|
1087
|
+
* Renders slotted real content once `loading` is false.
|
|
1088
|
+
*
|
|
1089
|
+
* @prop {'article'|'media'|'profile'|'product'|'list'} preset - default 'article'
|
|
1090
|
+
* @prop {'default'|'elevated'|'outline'} variant - default 'default'
|
|
1091
|
+
* @prop {'none'|'sm'|'md'|'lg'} padding - default 'md'
|
|
1092
|
+
* @prop {number} lines - number of text lines (article preset)
|
|
1093
|
+
* @prop {boolean} loading - when false, renders slotted content
|
|
1094
|
+
*
|
|
1095
|
+
* @slot - Real content rendered when loading=false
|
|
1096
|
+
*
|
|
1097
|
+
* @example
|
|
1098
|
+
* <arvea-skeleton-card preset="media" ?loading=${isLoading}>
|
|
1099
|
+
* <h3>Loaded!</h3><p>Real content here.</p>
|
|
1100
|
+
* </arvea-skeleton-card>
|
|
1101
|
+
*/
|
|
1102
|
+
declare class ArveaSkeletonCard extends LitElement {
|
|
1103
|
+
static styles: lit.CSSResult[];
|
|
1104
|
+
preset: ArveaSkeletonCardPreset;
|
|
1105
|
+
variant: ArveaSkeletonCardVariant;
|
|
1106
|
+
padding: 'none' | 'sm' | 'md' | 'lg';
|
|
1107
|
+
lines: number;
|
|
1108
|
+
loading: boolean;
|
|
1109
|
+
private _article;
|
|
1110
|
+
private _media;
|
|
1111
|
+
private _profile;
|
|
1112
|
+
private _product;
|
|
1113
|
+
private _list;
|
|
1114
|
+
private _renderPreset;
|
|
1115
|
+
render(): lit_html.TemplateResult<1>;
|
|
1116
|
+
}
|
|
1117
|
+
declare global {
|
|
1118
|
+
interface HTMLElementTagNameMap {
|
|
1119
|
+
'arvea-skeleton-card': ArveaSkeletonCard;
|
|
1120
|
+
}
|
|
1121
|
+
}
|
|
1122
|
+
|
|
1123
|
+
type ArveaCarouselArrowPosition = 'inside' | 'outside';
|
|
1124
|
+
interface ArveaCarouselProps {
|
|
1125
|
+
index?: number;
|
|
1126
|
+
slidesPerView?: number;
|
|
1127
|
+
gap?: string;
|
|
1128
|
+
loop?: boolean;
|
|
1129
|
+
autoplay?: boolean;
|
|
1130
|
+
interval?: number;
|
|
1131
|
+
showArrows?: boolean;
|
|
1132
|
+
showDots?: boolean;
|
|
1133
|
+
arrowPosition?: ArveaCarouselArrowPosition;
|
|
1134
|
+
ariaLabel?: string;
|
|
1135
|
+
}
|
|
1136
|
+
|
|
1137
|
+
/**
|
|
1138
|
+
* @element arvea-carousel
|
|
1139
|
+
*
|
|
1140
|
+
* Slot any number of child elements as slides. The carousel handles
|
|
1141
|
+
* navigation (arrows, dots, keyboard), autoplay, looping, and pointer
|
|
1142
|
+
* swipe gestures.
|
|
1143
|
+
*
|
|
1144
|
+
* @prop {number} index - Active slide index (default: 0)
|
|
1145
|
+
* @prop {number} slidesPerView - Slides visible at once (default: 1)
|
|
1146
|
+
* @prop {string} gap - CSS gap between slides (default: '12px')
|
|
1147
|
+
* @prop {boolean} loop - Loop from last to first and vice-versa
|
|
1148
|
+
* @prop {boolean} autoplay - Auto-advance slides
|
|
1149
|
+
* @prop {number} interval - Autoplay interval in ms (default: 4000)
|
|
1150
|
+
* @prop {boolean} showArrows - Show prev/next arrows (default: true)
|
|
1151
|
+
* @prop {boolean} showDots - Show pagination dots (default: true)
|
|
1152
|
+
* @prop {'inside'|'outside'} arrowPosition - Arrow placement (default: 'inside')
|
|
1153
|
+
* @prop {string} ariaLabel - Accessible label for the carousel region
|
|
1154
|
+
*
|
|
1155
|
+
* @slot - Slides (any number of HTMLElement children)
|
|
1156
|
+
*
|
|
1157
|
+
* @fires arvea-change - When the active index changes (detail: { index })
|
|
1158
|
+
*/
|
|
1159
|
+
declare class ArveaCarousel extends LitElement {
|
|
1160
|
+
static styles: lit.CSSResult[];
|
|
1161
|
+
index: number;
|
|
1162
|
+
slidesPerView: number;
|
|
1163
|
+
gap: string;
|
|
1164
|
+
loop: boolean;
|
|
1165
|
+
autoplay: boolean;
|
|
1166
|
+
interval: number;
|
|
1167
|
+
showArrows: boolean;
|
|
1168
|
+
showDots: boolean;
|
|
1169
|
+
arrowPosition: ArveaCarouselArrowPosition;
|
|
1170
|
+
ariaLabel: string;
|
|
1171
|
+
private _slideCount;
|
|
1172
|
+
private _dragOffsetPx;
|
|
1173
|
+
private _viewport;
|
|
1174
|
+
private _timer?;
|
|
1175
|
+
private _pointerId?;
|
|
1176
|
+
private _dragStartX;
|
|
1177
|
+
private _dragStartY;
|
|
1178
|
+
private _isDragging;
|
|
1179
|
+
private _dragAxis;
|
|
1180
|
+
connectedCallback(): void;
|
|
1181
|
+
disconnectedCallback(): void;
|
|
1182
|
+
firstUpdated(): void;
|
|
1183
|
+
updated(changed: PropertyValues): void;
|
|
1184
|
+
private get _maxIndex();
|
|
1185
|
+
private _onSlotChange;
|
|
1186
|
+
/** Navigate to a specific index, clamping or looping as configured. */
|
|
1187
|
+
goTo(i: number): void;
|
|
1188
|
+
next(): void;
|
|
1189
|
+
prev(): void;
|
|
1190
|
+
private _stopTimer;
|
|
1191
|
+
private _maybeStartTimer;
|
|
1192
|
+
private _onKeyDown;
|
|
1193
|
+
private _onPointerDown;
|
|
1194
|
+
private _onPointerMove;
|
|
1195
|
+
private _endDrag;
|
|
1196
|
+
private _trackTransform;
|
|
1197
|
+
render(): lit_html.TemplateResult<1>;
|
|
1198
|
+
}
|
|
1199
|
+
declare global {
|
|
1200
|
+
interface HTMLElementTagNameMap {
|
|
1201
|
+
'arvea-carousel': ArveaCarousel;
|
|
1202
|
+
}
|
|
1203
|
+
}
|
|
1204
|
+
|
|
1205
|
+
type ArveaDialogSize = 'sm' | 'md' | 'lg' | 'fullscreen';
|
|
1206
|
+
interface ArveaDialogProps {
|
|
1207
|
+
open?: boolean;
|
|
1208
|
+
title?: string;
|
|
1209
|
+
description?: string;
|
|
1210
|
+
size?: ArveaDialogSize;
|
|
1211
|
+
closeOnOverlayClick?: boolean;
|
|
1212
|
+
closeOnEsc?: boolean;
|
|
1213
|
+
hideClose?: boolean;
|
|
1214
|
+
preventScroll?: boolean;
|
|
1215
|
+
}
|
|
1216
|
+
|
|
1217
|
+
/**
|
|
1218
|
+
* @element arvea-dialog
|
|
1219
|
+
*
|
|
1220
|
+
* Accessible modal dialog with overlay, focus trap, and Esc-to-close.
|
|
1221
|
+
*
|
|
1222
|
+
* @prop {boolean} open
|
|
1223
|
+
* @prop {string} title
|
|
1224
|
+
* @prop {string} description
|
|
1225
|
+
* @prop {'sm'|'md'|'lg'|'fullscreen'} size
|
|
1226
|
+
* @prop {boolean} closeOnOverlayClick - default true
|
|
1227
|
+
* @prop {boolean} closeOnEsc - default true
|
|
1228
|
+
* @prop {boolean} hideClose - hide the X button
|
|
1229
|
+
* @prop {boolean} preventScroll - lock body scroll while open (default true)
|
|
1230
|
+
*
|
|
1231
|
+
* @slot header - Overrides the default header (title + close)
|
|
1232
|
+
* @slot - Main body content
|
|
1233
|
+
* @slot footer - Footer with action buttons
|
|
1234
|
+
*
|
|
1235
|
+
* @fires arvea-open
|
|
1236
|
+
* @fires arvea-close
|
|
1237
|
+
*/
|
|
1238
|
+
declare class ArveaDialog extends LitElement {
|
|
1239
|
+
static styles: lit.CSSResult[];
|
|
1240
|
+
open: boolean;
|
|
1241
|
+
title: string;
|
|
1242
|
+
description: string;
|
|
1243
|
+
size: ArveaDialogSize;
|
|
1244
|
+
closeOnOverlayClick: boolean;
|
|
1245
|
+
closeOnEsc: boolean;
|
|
1246
|
+
hideClose: boolean;
|
|
1247
|
+
preventScroll: boolean;
|
|
1248
|
+
private _dialog;
|
|
1249
|
+
private _previouslyFocused;
|
|
1250
|
+
connectedCallback(): void;
|
|
1251
|
+
disconnectedCallback(): void;
|
|
1252
|
+
updated(changed: PropertyValues): void;
|
|
1253
|
+
/** Public API: show the dialog. */
|
|
1254
|
+
show(): void;
|
|
1255
|
+
/** Public API: hide the dialog. */
|
|
1256
|
+
hide(): void;
|
|
1257
|
+
private _handleOpen;
|
|
1258
|
+
private _handleClose;
|
|
1259
|
+
private _restoreScroll;
|
|
1260
|
+
private _onDocKeyDown;
|
|
1261
|
+
private _trapFocus;
|
|
1262
|
+
private _onOverlayClick;
|
|
1263
|
+
render(): lit_html.TemplateResult<1>;
|
|
1264
|
+
}
|
|
1265
|
+
declare global {
|
|
1266
|
+
interface HTMLElementTagNameMap {
|
|
1267
|
+
'arvea-dialog': ArveaDialog;
|
|
1268
|
+
}
|
|
1269
|
+
}
|
|
1270
|
+
|
|
1271
|
+
type ArveaToastVariant = 'default' | 'success' | 'error' | 'warning' | 'info';
|
|
1272
|
+
type ArveaToastPosition = 'top-right' | 'top-left' | 'top-center' | 'bottom-right' | 'bottom-left' | 'bottom-center';
|
|
1273
|
+
interface ArveaToastProps {
|
|
1274
|
+
open?: boolean;
|
|
1275
|
+
variant?: ArveaToastVariant;
|
|
1276
|
+
message?: string;
|
|
1277
|
+
duration?: number;
|
|
1278
|
+
closable?: boolean;
|
|
1279
|
+
}
|
|
1280
|
+
interface ArveaToastOptions {
|
|
1281
|
+
message: string;
|
|
1282
|
+
variant?: ArveaToastVariant;
|
|
1283
|
+
duration?: number;
|
|
1284
|
+
closable?: boolean;
|
|
1285
|
+
}
|
|
1286
|
+
|
|
1287
|
+
/**
|
|
1288
|
+
* @element arvea-toast
|
|
1289
|
+
*
|
|
1290
|
+
* Single toast notification. For multi-toast UX, use `arvea-toast-container`.
|
|
1291
|
+
*
|
|
1292
|
+
* @prop {boolean} open
|
|
1293
|
+
* @prop {'default'|'success'|'error'|'warning'|'info'} variant
|
|
1294
|
+
* @prop {string} message
|
|
1295
|
+
* @prop {number} duration - auto-dismiss in ms (0 = no auto-dismiss)
|
|
1296
|
+
* @prop {boolean} closable - shows the close button (default true)
|
|
1297
|
+
*
|
|
1298
|
+
* @slot - rich content alternative to `message`
|
|
1299
|
+
*
|
|
1300
|
+
* @fires arvea-open
|
|
1301
|
+
* @fires arvea-close
|
|
1302
|
+
*/
|
|
1303
|
+
declare class ArveaToast extends LitElement {
|
|
1304
|
+
static styles: lit.CSSResult[];
|
|
1305
|
+
open: boolean;
|
|
1306
|
+
variant: ArveaToastVariant;
|
|
1307
|
+
message: string;
|
|
1308
|
+
duration: number;
|
|
1309
|
+
closable: boolean;
|
|
1310
|
+
private _timer?;
|
|
1311
|
+
show(): void;
|
|
1312
|
+
hide(): void;
|
|
1313
|
+
updated(changed: PropertyValues): void;
|
|
1314
|
+
disconnectedCallback(): void;
|
|
1315
|
+
render(): lit_html.TemplateResult<1>;
|
|
1316
|
+
}
|
|
1317
|
+
declare global {
|
|
1318
|
+
interface HTMLElementTagNameMap {
|
|
1319
|
+
'arvea-toast': ArveaToast;
|
|
1320
|
+
}
|
|
1321
|
+
}
|
|
1322
|
+
|
|
1323
|
+
/**
|
|
1324
|
+
* @element arvea-toast-container
|
|
1325
|
+
*
|
|
1326
|
+
* Container that stacks toasts in a fixed corner of the viewport.
|
|
1327
|
+
* Use the imperative `toast()` method (or static `ArveaToastContainer.notify()`)
|
|
1328
|
+
* to push new toasts.
|
|
1329
|
+
*
|
|
1330
|
+
* @prop {ArveaToastPosition} position - default 'top-right'
|
|
1331
|
+
* @prop {number} max - max simultaneous toasts (default 5)
|
|
1332
|
+
*
|
|
1333
|
+
* @example
|
|
1334
|
+
* <arvea-toast-container id="toasts"></arvea-toast-container>
|
|
1335
|
+
* document.getElementById('toasts').toast({ message: 'Saved!', variant: 'success' });
|
|
1336
|
+
*/
|
|
1337
|
+
declare class ArveaToastContainer extends LitElement {
|
|
1338
|
+
static styles: lit.CSSResult[];
|
|
1339
|
+
position: ArveaToastPosition;
|
|
1340
|
+
max: number;
|
|
1341
|
+
private _toasts;
|
|
1342
|
+
/** Push a new toast. Returns the toast id. */
|
|
1343
|
+
toast(opts: ArveaToastOptions): number;
|
|
1344
|
+
/** Convenience helpers. */
|
|
1345
|
+
success(message: string, duration?: number): number;
|
|
1346
|
+
error(message: string, duration?: number): number;
|
|
1347
|
+
warning(message: string, duration?: number): number;
|
|
1348
|
+
info(message: string, duration?: number): number;
|
|
1349
|
+
/** Remove a specific toast by id. */
|
|
1350
|
+
dismiss(id: number): void;
|
|
1351
|
+
/** Clear all toasts. */
|
|
1352
|
+
clear(): void;
|
|
1353
|
+
private _onClose;
|
|
1354
|
+
render(): lit_html.TemplateResult<1>;
|
|
1355
|
+
}
|
|
1356
|
+
declare global {
|
|
1357
|
+
interface HTMLElementTagNameMap {
|
|
1358
|
+
'arvea-toast-container': ArveaToastContainer;
|
|
1359
|
+
}
|
|
1360
|
+
}
|
|
1361
|
+
|
|
1362
|
+
type ArveaTabsVariant = 'underline' | 'pill';
|
|
1363
|
+
interface ArveaTabItem {
|
|
1364
|
+
value: string;
|
|
1365
|
+
label: string;
|
|
1366
|
+
disabled?: boolean;
|
|
1367
|
+
}
|
|
1368
|
+
interface ArveaTabsProps {
|
|
1369
|
+
value?: string;
|
|
1370
|
+
items?: ArveaTabItem[];
|
|
1371
|
+
variant?: ArveaTabsVariant;
|
|
1372
|
+
fullWidth?: boolean;
|
|
1373
|
+
ariaLabel?: string;
|
|
1374
|
+
}
|
|
1375
|
+
|
|
1376
|
+
/**
|
|
1377
|
+
* @element arvea-tabs
|
|
1378
|
+
*
|
|
1379
|
+
* Tabs with two display variants:
|
|
1380
|
+
* - 'underline' (default) — bottom border + animated indicator
|
|
1381
|
+
* - 'pill' — segmented control style
|
|
1382
|
+
*
|
|
1383
|
+
* Tabs can be provided via the `items` array OR via slotted panels
|
|
1384
|
+
* (`<div slot="panel" data-value="x" data-label="Label">…</div>`).
|
|
1385
|
+
*
|
|
1386
|
+
* @prop {string} value - Active tab value (controlled)
|
|
1387
|
+
* @prop {ArveaTabItem[]} items - Tab definitions (optional)
|
|
1388
|
+
* @prop {'underline'|'pill'} variant
|
|
1389
|
+
* @prop {boolean} fullWidth
|
|
1390
|
+
* @prop {string} ariaLabel
|
|
1391
|
+
*
|
|
1392
|
+
* @slot panel - One panel per tab; first matching data-value is shown
|
|
1393
|
+
*
|
|
1394
|
+
* @fires arvea-change - { value }
|
|
1395
|
+
*/
|
|
1396
|
+
declare class ArveaTabs extends LitElement {
|
|
1397
|
+
static styles: lit.CSSResult[];
|
|
1398
|
+
value: string;
|
|
1399
|
+
items: ArveaTabItem[];
|
|
1400
|
+
variant: ArveaTabsVariant;
|
|
1401
|
+
fullWidth: boolean;
|
|
1402
|
+
ariaLabel: string;
|
|
1403
|
+
private _slotItems;
|
|
1404
|
+
private _indicatorStyle;
|
|
1405
|
+
private _tablist;
|
|
1406
|
+
private get _items();
|
|
1407
|
+
connectedCallback(): void;
|
|
1408
|
+
firstUpdated(): void;
|
|
1409
|
+
updated(changed: PropertyValues): void;
|
|
1410
|
+
private _onPanelsSlotChange;
|
|
1411
|
+
private _syncPanels;
|
|
1412
|
+
private _onTabClick;
|
|
1413
|
+
private _onKeyDown;
|
|
1414
|
+
private _updateIndicator;
|
|
1415
|
+
render(): lit_html.TemplateResult<1>;
|
|
1416
|
+
}
|
|
1417
|
+
declare global {
|
|
1418
|
+
interface HTMLElementTagNameMap {
|
|
1419
|
+
'arvea-tabs': ArveaTabs;
|
|
1420
|
+
}
|
|
1421
|
+
}
|
|
1422
|
+
|
|
1423
|
+
/**
|
|
1424
|
+
* @element arvea-accordion-item
|
|
1425
|
+
*
|
|
1426
|
+
* Single collapsible row. Place inside `<arvea-accordion>` (optional).
|
|
1427
|
+
*
|
|
1428
|
+
* @prop {boolean} open
|
|
1429
|
+
* @prop {string} title
|
|
1430
|
+
* @prop {boolean} disabled
|
|
1431
|
+
*
|
|
1432
|
+
* @slot title - Custom title (overrides `title` attr)
|
|
1433
|
+
* @slot - Body content
|
|
1434
|
+
*
|
|
1435
|
+
* @fires arvea-toggle - { open }
|
|
1436
|
+
*/
|
|
1437
|
+
declare class ArveaAccordionItem extends LitElement {
|
|
1438
|
+
static styles: lit.CSSResult[];
|
|
1439
|
+
open: boolean;
|
|
1440
|
+
title: string;
|
|
1441
|
+
disabled: boolean;
|
|
1442
|
+
toggle(): void;
|
|
1443
|
+
render(): lit_html.TemplateResult<1>;
|
|
1444
|
+
}
|
|
1445
|
+
declare global {
|
|
1446
|
+
interface HTMLElementTagNameMap {
|
|
1447
|
+
'arvea-accordion-item': ArveaAccordionItem;
|
|
1448
|
+
}
|
|
1449
|
+
}
|
|
1450
|
+
|
|
1451
|
+
/**
|
|
1452
|
+
* @element arvea-accordion
|
|
1453
|
+
*
|
|
1454
|
+
* Container for `<arvea-accordion-item>` elements. By default, opening
|
|
1455
|
+
* one item closes the others. Set `multiple` to allow multiple open items.
|
|
1456
|
+
*
|
|
1457
|
+
* @prop {boolean} multiple - Allow multiple open items
|
|
1458
|
+
* @prop {boolean} bordered - Render with a single rounded border
|
|
1459
|
+
*
|
|
1460
|
+
* @slot - One or more `<arvea-accordion-item>` elements
|
|
1461
|
+
*/
|
|
1462
|
+
declare class ArveaAccordion extends LitElement {
|
|
1463
|
+
static styles: lit.CSSResult[];
|
|
1464
|
+
multiple: boolean;
|
|
1465
|
+
bordered: boolean;
|
|
1466
|
+
connectedCallback(): void;
|
|
1467
|
+
disconnectedCallback(): void;
|
|
1468
|
+
private _onItemToggle;
|
|
1469
|
+
render(): lit_html.TemplateResult<1>;
|
|
1470
|
+
}
|
|
1471
|
+
declare global {
|
|
1472
|
+
interface HTMLElementTagNameMap {
|
|
1473
|
+
'arvea-accordion': ArveaAccordion;
|
|
1474
|
+
}
|
|
1475
|
+
}
|
|
1476
|
+
|
|
1477
|
+
type ArveaAlertVariant = 'info' | 'success' | 'warning' | 'danger';
|
|
1478
|
+
interface ArveaAlertProps {
|
|
1479
|
+
variant?: ArveaAlertVariant;
|
|
1480
|
+
title?: string;
|
|
1481
|
+
closable?: boolean;
|
|
1482
|
+
hideIcon?: boolean;
|
|
1483
|
+
}
|
|
1484
|
+
|
|
1485
|
+
/**
|
|
1486
|
+
* @element arvea-alert
|
|
1487
|
+
*
|
|
1488
|
+
* Inline notification with four variants. Use the default slot for body
|
|
1489
|
+
* content; `title` for the bold heading.
|
|
1490
|
+
*
|
|
1491
|
+
* @prop {'info'|'success'|'warning'|'danger'} variant - default 'info'
|
|
1492
|
+
* @prop {string} title
|
|
1493
|
+
* @prop {boolean} closable - shows a close button (dismisses the alert)
|
|
1494
|
+
* @prop {boolean} hideIcon
|
|
1495
|
+
*
|
|
1496
|
+
* @slot - body content
|
|
1497
|
+
* @slot icon - override the default icon
|
|
1498
|
+
* @slot action - trailing action (button/link) placed before the close button
|
|
1499
|
+
*
|
|
1500
|
+
* @fires arvea-close
|
|
1501
|
+
*/
|
|
1502
|
+
declare class ArveaAlert extends LitElement {
|
|
1503
|
+
static styles: lit.CSSResult[];
|
|
1504
|
+
variant: ArveaAlertVariant;
|
|
1505
|
+
title: string;
|
|
1506
|
+
closable: boolean;
|
|
1507
|
+
hideIcon: boolean;
|
|
1508
|
+
private _dismissed;
|
|
1509
|
+
private _close;
|
|
1510
|
+
render(): lit_html.TemplateResult<1> | typeof nothing;
|
|
1511
|
+
}
|
|
1512
|
+
declare global {
|
|
1513
|
+
interface HTMLElementTagNameMap {
|
|
1514
|
+
'arvea-alert': ArveaAlert;
|
|
1515
|
+
}
|
|
1516
|
+
}
|
|
1517
|
+
|
|
1518
|
+
type ArveaDividerOrientation = 'horizontal' | 'vertical';
|
|
1519
|
+
type ArveaDividerVariant = 'solid' | 'dashed' | 'dotted';
|
|
1520
|
+
type ArveaDividerEmphasis = 'subtle' | 'strong';
|
|
1521
|
+
type ArveaDividerAlign = 'start' | 'center' | 'end';
|
|
1522
|
+
interface ArveaDividerProps {
|
|
1523
|
+
orientation?: ArveaDividerOrientation;
|
|
1524
|
+
variant?: ArveaDividerVariant;
|
|
1525
|
+
emphasis?: ArveaDividerEmphasis;
|
|
1526
|
+
align?: ArveaDividerAlign;
|
|
1527
|
+
text?: string;
|
|
1528
|
+
spacing?: string;
|
|
1529
|
+
}
|
|
1530
|
+
|
|
1531
|
+
/**
|
|
1532
|
+
* @element arvea-divider
|
|
1533
|
+
*
|
|
1534
|
+
* Visual separator. Use orientation="vertical" inside flex containers, or
|
|
1535
|
+
* pass `text` (or slot content) for a labeled horizontal divider.
|
|
1536
|
+
*
|
|
1537
|
+
* @prop {'horizontal'|'vertical'} orientation - default 'horizontal'
|
|
1538
|
+
* @prop {'solid'|'dashed'|'dotted'} variant
|
|
1539
|
+
* @prop {'subtle'|'strong'} emphasis
|
|
1540
|
+
* @prop {'start'|'center'|'end'} align - text alignment
|
|
1541
|
+
* @prop {string} text - optional label
|
|
1542
|
+
* @prop {string} spacing - CSS margin override
|
|
1543
|
+
*
|
|
1544
|
+
* @slot - Alternative to the `text` attribute
|
|
1545
|
+
*/
|
|
1546
|
+
declare class ArveaDivider extends LitElement {
|
|
1547
|
+
static styles: lit.CSSResult[];
|
|
1548
|
+
orientation: ArveaDividerOrientation;
|
|
1549
|
+
variant: ArveaDividerVariant;
|
|
1550
|
+
emphasis: ArveaDividerEmphasis;
|
|
1551
|
+
align: ArveaDividerAlign;
|
|
1552
|
+
text: string;
|
|
1553
|
+
spacing: string;
|
|
1554
|
+
connectedCallback(): void;
|
|
1555
|
+
render(): lit_html.TemplateResult<1> | typeof nothing;
|
|
1556
|
+
}
|
|
1557
|
+
declare global {
|
|
1558
|
+
interface HTMLElementTagNameMap {
|
|
1559
|
+
'arvea-divider': ArveaDivider;
|
|
1560
|
+
}
|
|
1561
|
+
}
|
|
1562
|
+
|
|
1563
|
+
type ArveaFormFieldStatus = 'default' | 'invalid' | 'warning' | 'valid';
|
|
1564
|
+
interface ArveaFormFieldProps {
|
|
1565
|
+
label?: string;
|
|
1566
|
+
hint?: string;
|
|
1567
|
+
error?: string;
|
|
1568
|
+
required?: boolean;
|
|
1569
|
+
optional?: boolean;
|
|
1570
|
+
status?: ArveaFormFieldStatus;
|
|
1571
|
+
htmlFor?: string;
|
|
1572
|
+
}
|
|
1573
|
+
|
|
1574
|
+
/**
|
|
1575
|
+
* @element arvea-form-field
|
|
1576
|
+
*
|
|
1577
|
+
* Wraps a form control (input, textarea, select, etc.) with a label and hint/error message.
|
|
1578
|
+
*
|
|
1579
|
+
* @prop {string} label - Label text shown above the control
|
|
1580
|
+
* @prop {string} hint - Helper text shown below the control
|
|
1581
|
+
* @prop {string} error - Error message (forces status='invalid' when present)
|
|
1582
|
+
* @prop {boolean} required - Mark the field as required (renders an asterisk)
|
|
1583
|
+
* @prop {boolean} optional - Render an "(optional)" suffix on the label
|
|
1584
|
+
* @prop {ArveaFormFieldStatus} status - 'default' | 'invalid' | 'warning' | 'valid'
|
|
1585
|
+
* @prop {string} htmlFor - Associates the label with a control via id
|
|
1586
|
+
*
|
|
1587
|
+
* @slot default - Place a form control here (input, select, textarea, ...)
|
|
1588
|
+
*/
|
|
1589
|
+
declare class ArveaFormField extends LitElement {
|
|
1590
|
+
static styles: lit.CSSResult[];
|
|
1591
|
+
label: string;
|
|
1592
|
+
hint: string;
|
|
1593
|
+
error: string;
|
|
1594
|
+
required: boolean;
|
|
1595
|
+
optional: boolean;
|
|
1596
|
+
status: ArveaFormFieldStatus;
|
|
1597
|
+
htmlFor: string;
|
|
1598
|
+
private get _resolvedStatus();
|
|
1599
|
+
private get _message();
|
|
1600
|
+
willUpdate(): void;
|
|
1601
|
+
private _syncInputState;
|
|
1602
|
+
render(): lit_html.TemplateResult<1>;
|
|
1603
|
+
}
|
|
1604
|
+
declare global {
|
|
1605
|
+
interface HTMLElementTagNameMap {
|
|
1606
|
+
'arvea-form-field': ArveaFormField;
|
|
1607
|
+
}
|
|
1608
|
+
}
|
|
1609
|
+
|
|
1610
|
+
interface ArveaBreadcrumbItem {
|
|
1611
|
+
label: string;
|
|
1612
|
+
href?: string;
|
|
1613
|
+
current?: boolean;
|
|
1614
|
+
}
|
|
1615
|
+
type ArveaBreadcrumbSeparator = 'chevron' | 'slash' | 'dot';
|
|
1616
|
+
interface ArveaBreadcrumbProps {
|
|
1617
|
+
items?: ArveaBreadcrumbItem[];
|
|
1618
|
+
separator?: ArveaBreadcrumbSeparator;
|
|
1619
|
+
maxItems?: number;
|
|
1620
|
+
}
|
|
1621
|
+
|
|
1622
|
+
/**
|
|
1623
|
+
* @element arvea-breadcrumb
|
|
1624
|
+
*
|
|
1625
|
+
* @prop {ArveaBreadcrumbItem[]} items - Crumbs to display
|
|
1626
|
+
* @prop {'chevron'|'slash'|'dot'} separator - Visual separator (default 'chevron')
|
|
1627
|
+
* @prop {number} maxItems - Collapse to ellipsis if items exceed this number (0 = never)
|
|
1628
|
+
*
|
|
1629
|
+
* @fires arvea-breadcrumb-navigate - { detail: { item, index } } when a non-current crumb is clicked
|
|
1630
|
+
*/
|
|
1631
|
+
declare class ArveaBreadcrumb extends LitElement {
|
|
1632
|
+
static styles: lit.CSSResult[];
|
|
1633
|
+
items: ArveaBreadcrumbItem[];
|
|
1634
|
+
separator: ArveaBreadcrumbSeparator;
|
|
1635
|
+
maxItems: number;
|
|
1636
|
+
private _renderSeparator;
|
|
1637
|
+
private _onClick;
|
|
1638
|
+
private _renderCrumb;
|
|
1639
|
+
private _visibleItems;
|
|
1640
|
+
render(): TemplateResult<1>;
|
|
1641
|
+
}
|
|
1642
|
+
declare global {
|
|
1643
|
+
interface HTMLElementTagNameMap {
|
|
1644
|
+
'arvea-breadcrumb': ArveaBreadcrumb;
|
|
1645
|
+
}
|
|
1646
|
+
}
|
|
1647
|
+
|
|
1648
|
+
type ArveaPaginationSize = 'sm' | 'md' | 'lg';
|
|
1649
|
+
interface ArveaPaginationProps {
|
|
1650
|
+
page?: number;
|
|
1651
|
+
total?: number;
|
|
1652
|
+
siblings?: number;
|
|
1653
|
+
boundaries?: number;
|
|
1654
|
+
size?: ArveaPaginationSize;
|
|
1655
|
+
disabled?: boolean;
|
|
1656
|
+
showFirstLast?: boolean;
|
|
1657
|
+
pageSize?: number;
|
|
1658
|
+
pageSizeOptions?: number[];
|
|
1659
|
+
showJumpTo?: boolean;
|
|
1660
|
+
}
|
|
1661
|
+
|
|
1662
|
+
/**
|
|
1663
|
+
* @element arvea-pagination
|
|
1664
|
+
*
|
|
1665
|
+
* @prop {number} page - current page (1-based)
|
|
1666
|
+
* @prop {number} total - total number of pages
|
|
1667
|
+
* @prop {number} siblings - pages shown around current (default 1)
|
|
1668
|
+
* @prop {number} boundaries - pages always shown at start/end (default 1)
|
|
1669
|
+
* @prop {ArveaPaginationSize} size - 'sm' | 'md' | 'lg'
|
|
1670
|
+
* @prop {boolean} disabled
|
|
1671
|
+
* @prop {boolean} showFirstLast - render first/last buttons
|
|
1672
|
+
* @prop {number} pageSize - optional rows-per-page (renders a selector when pageSizeOptions provided)
|
|
1673
|
+
* @prop {number[]} pageSizeOptions - choices for the page-size selector
|
|
1674
|
+
* @prop {boolean} showJumpTo - render a "Go to" input for direct page entry
|
|
1675
|
+
*
|
|
1676
|
+
* @fires arvea-page-change - { detail: { page } }
|
|
1677
|
+
* @fires arvea-page-size-change - { detail: { pageSize } }
|
|
1678
|
+
*/
|
|
1679
|
+
declare class ArveaPagination extends LitElement {
|
|
1680
|
+
static styles: lit.CSSResult[];
|
|
1681
|
+
page: number;
|
|
1682
|
+
total: number;
|
|
1683
|
+
siblings: number;
|
|
1684
|
+
boundaries: number;
|
|
1685
|
+
size: ArveaPaginationSize;
|
|
1686
|
+
disabled: boolean;
|
|
1687
|
+
showFirstLast: boolean;
|
|
1688
|
+
pageSize?: number;
|
|
1689
|
+
pageSizeOptions: number[];
|
|
1690
|
+
showJumpTo: boolean;
|
|
1691
|
+
private _go;
|
|
1692
|
+
private _range;
|
|
1693
|
+
private _onPageSizeChange;
|
|
1694
|
+
private _onJumpKey;
|
|
1695
|
+
private _arrow;
|
|
1696
|
+
render(): lit_html.TemplateResult<1>;
|
|
1697
|
+
}
|
|
1698
|
+
declare global {
|
|
1699
|
+
interface HTMLElementTagNameMap {
|
|
1700
|
+
'arvea-pagination': ArveaPagination;
|
|
1701
|
+
}
|
|
1702
|
+
}
|
|
1703
|
+
|
|
1704
|
+
type ArveaDropdownPlacement = 'bottom-start' | 'bottom-end' | 'top-start' | 'top-end';
|
|
1705
|
+
interface ArveaDropdownItem {
|
|
1706
|
+
id: string;
|
|
1707
|
+
label: string;
|
|
1708
|
+
value?: string;
|
|
1709
|
+
flagSrc?: string;
|
|
1710
|
+
icon?: string;
|
|
1711
|
+
disabled?: boolean;
|
|
1712
|
+
destructive?: boolean;
|
|
1713
|
+
divider?: boolean;
|
|
1714
|
+
}
|
|
1715
|
+
interface ArveaDropdownMenuProps {
|
|
1716
|
+
items?: ArveaDropdownItem[];
|
|
1717
|
+
open?: boolean;
|
|
1718
|
+
placement?: ArveaDropdownPlacement;
|
|
1719
|
+
triggerLabel?: string;
|
|
1720
|
+
}
|
|
1721
|
+
|
|
1722
|
+
/**
|
|
1723
|
+
* @element arvea-dropdown-menu
|
|
1724
|
+
*
|
|
1725
|
+
* @prop {ArveaDropdownItem[]} items - Menu items (support flagSrc, value, divider, icon)
|
|
1726
|
+
* @prop {boolean} open - Controlled open state (reflected)
|
|
1727
|
+
* @prop {string} value - Currently selected item value (shows checkmark)
|
|
1728
|
+
* @prop {ArveaDropdownPlacement} placement - 'bottom-start' (default), 'bottom-end', 'top-start', 'top-end'
|
|
1729
|
+
* @prop {string} triggerLabel - Text for default trigger; ignored when slot[name=trigger] is used
|
|
1730
|
+
* @prop {'click'|'hover'} triggerMode - How the dropdown opens (default 'click')
|
|
1731
|
+
*
|
|
1732
|
+
* @slot trigger - Custom trigger element (replaces default button)
|
|
1733
|
+
* @slot - Custom items (alternative to .items property)
|
|
1734
|
+
*
|
|
1735
|
+
* @fires arvea-dropdown-select - { detail: { item } } on item click
|
|
1736
|
+
* @fires arvea-dropdown-open
|
|
1737
|
+
* @fires arvea-dropdown-close
|
|
1738
|
+
*/
|
|
1739
|
+
declare class ArveaDropdownMenu extends LitElement {
|
|
1740
|
+
static styles: lit.CSSResult[];
|
|
1741
|
+
items: ArveaDropdownItem[];
|
|
1742
|
+
open: boolean;
|
|
1743
|
+
value: string;
|
|
1744
|
+
placement: ArveaDropdownPlacement;
|
|
1745
|
+
triggerLabel: string;
|
|
1746
|
+
triggerMode: 'click' | 'hover';
|
|
1747
|
+
searchable: boolean;
|
|
1748
|
+
searchPlaceholder: string;
|
|
1749
|
+
noResultsText: string;
|
|
1750
|
+
private _hasTriggerSlot;
|
|
1751
|
+
private _hasContentSlot;
|
|
1752
|
+
private _query;
|
|
1753
|
+
private _activeIndex;
|
|
1754
|
+
private _searchInput?;
|
|
1755
|
+
private _mouseLeaveTimer?;
|
|
1756
|
+
private get _visibleItems();
|
|
1757
|
+
private _focusableItems;
|
|
1758
|
+
private _outsideHandler;
|
|
1759
|
+
private _keyHandler;
|
|
1760
|
+
private _onHostMouseEnter;
|
|
1761
|
+
private _onHostMouseLeave;
|
|
1762
|
+
connectedCallback(): void;
|
|
1763
|
+
disconnectedCallback(): void;
|
|
1764
|
+
private _toggle;
|
|
1765
|
+
private _openMenu;
|
|
1766
|
+
private _close;
|
|
1767
|
+
private _onSearchInput;
|
|
1768
|
+
private _pick;
|
|
1769
|
+
private _onTriggerSlotChange;
|
|
1770
|
+
private _onContentSlotChange;
|
|
1771
|
+
private _renderItems;
|
|
1772
|
+
render(): lit_html.TemplateResult<1>;
|
|
1773
|
+
}
|
|
1774
|
+
declare global {
|
|
1775
|
+
interface HTMLElementTagNameMap {
|
|
1776
|
+
'arvea-dropdown-menu': ArveaDropdownMenu;
|
|
1777
|
+
}
|
|
1778
|
+
}
|
|
1779
|
+
|
|
1780
|
+
type ArveaSearchSize = 'sm' | 'md' | 'lg';
|
|
1781
|
+
interface ArveaSearchSuggestion {
|
|
1782
|
+
id: string;
|
|
1783
|
+
label: string;
|
|
1784
|
+
hint?: string;
|
|
1785
|
+
}
|
|
1786
|
+
interface ArveaSearchBarProps {
|
|
1787
|
+
value?: string;
|
|
1788
|
+
placeholder?: string;
|
|
1789
|
+
size?: ArveaSearchSize;
|
|
1790
|
+
disabled?: boolean;
|
|
1791
|
+
loading?: boolean;
|
|
1792
|
+
clearable?: boolean;
|
|
1793
|
+
suggestions?: ArveaSearchSuggestion[];
|
|
1794
|
+
debounce?: number;
|
|
1795
|
+
}
|
|
1796
|
+
|
|
1797
|
+
/**
|
|
1798
|
+
* @element arvea-search-bar
|
|
1799
|
+
*
|
|
1800
|
+
* @prop {string} value - input value
|
|
1801
|
+
* @prop {string} placeholder
|
|
1802
|
+
* @prop {ArveaSearchSize} size - 'sm' | 'md' | 'lg'
|
|
1803
|
+
* @prop {boolean} disabled
|
|
1804
|
+
* @prop {boolean} loading - show spinner instead of search icon
|
|
1805
|
+
* @prop {boolean} clearable - show a clear (×) button when value is non-empty
|
|
1806
|
+
* @prop {ArveaSearchSuggestion[]} suggestions - autocomplete suggestions
|
|
1807
|
+
* @prop {number} debounce - ms before firing arvea-search-input (default 200)
|
|
1808
|
+
*
|
|
1809
|
+
* @fires arvea-search-input - debounced input event, { detail: { value } }
|
|
1810
|
+
* @fires arvea-search-submit - Enter pressed, { detail: { value } }
|
|
1811
|
+
* @fires arvea-search-select - suggestion selected, { detail: { suggestion } }
|
|
1812
|
+
* @fires arvea-search-clear
|
|
1813
|
+
*/
|
|
1814
|
+
declare class ArveaSearchBar extends LitElement {
|
|
1815
|
+
static styles: lit.CSSResult[];
|
|
1816
|
+
value: string;
|
|
1817
|
+
placeholder: string;
|
|
1818
|
+
size: ArveaSearchSize;
|
|
1819
|
+
disabled: boolean;
|
|
1820
|
+
loading: boolean;
|
|
1821
|
+
clearable: boolean;
|
|
1822
|
+
suggestions: ArveaSearchSuggestion[];
|
|
1823
|
+
debounce: number;
|
|
1824
|
+
private _activeIndex;
|
|
1825
|
+
private _showSuggestions;
|
|
1826
|
+
private _debounceTimer;
|
|
1827
|
+
private _emitInput;
|
|
1828
|
+
private _onInput;
|
|
1829
|
+
private _onKey;
|
|
1830
|
+
private _clear;
|
|
1831
|
+
private _pick;
|
|
1832
|
+
private _onBlur;
|
|
1833
|
+
render(): lit_html.TemplateResult<1>;
|
|
1834
|
+
}
|
|
1835
|
+
declare global {
|
|
1836
|
+
interface HTMLElementTagNameMap {
|
|
1837
|
+
'arvea-search-bar': ArveaSearchBar;
|
|
1838
|
+
}
|
|
1839
|
+
}
|
|
1840
|
+
|
|
1841
|
+
type ArveaRatingSize = 'sm' | 'md' | 'lg';
|
|
1842
|
+
interface ArveaRatingProps {
|
|
1843
|
+
value?: number;
|
|
1844
|
+
max?: number;
|
|
1845
|
+
size?: ArveaRatingSize;
|
|
1846
|
+
readonly?: boolean;
|
|
1847
|
+
allowHalf?: boolean;
|
|
1848
|
+
label?: string;
|
|
1849
|
+
}
|
|
1850
|
+
|
|
1851
|
+
/**
|
|
1852
|
+
* @element arvea-rating
|
|
1853
|
+
*
|
|
1854
|
+
* @prop {number} value - current value (0..max)
|
|
1855
|
+
* @prop {number} max - max stars (default 5)
|
|
1856
|
+
* @prop {ArveaRatingSize} size - 'sm' | 'md' | 'lg'
|
|
1857
|
+
* @prop {boolean} readonly - display-only mode
|
|
1858
|
+
* @prop {boolean} allowHalf - allow half-star values in display
|
|
1859
|
+
* @prop {string} label - text shown next to the stars (e.g. "4.2/5")
|
|
1860
|
+
*
|
|
1861
|
+
* @fires arvea-rating-change - { detail: { value } }
|
|
1862
|
+
*/
|
|
1863
|
+
declare class ArveaRating extends LitElement {
|
|
1864
|
+
static styles: lit.CSSResult[];
|
|
1865
|
+
value: number;
|
|
1866
|
+
max: number;
|
|
1867
|
+
size: ArveaRatingSize;
|
|
1868
|
+
readonly: boolean;
|
|
1869
|
+
allowHalf: boolean;
|
|
1870
|
+
label: string;
|
|
1871
|
+
score: string;
|
|
1872
|
+
private _set;
|
|
1873
|
+
private _onKey;
|
|
1874
|
+
render(): lit_html.TemplateResult<1>;
|
|
1875
|
+
}
|
|
1876
|
+
declare global {
|
|
1877
|
+
interface HTMLElementTagNameMap {
|
|
1878
|
+
'arvea-rating': ArveaRating;
|
|
1879
|
+
}
|
|
1880
|
+
}
|
|
1881
|
+
|
|
1882
|
+
type ArveaQuantitySize = 'sm' | 'md' | 'lg';
|
|
1883
|
+
interface ArveaQuantitySelectorProps {
|
|
1884
|
+
value?: number;
|
|
1885
|
+
min?: number;
|
|
1886
|
+
max?: number;
|
|
1887
|
+
step?: number;
|
|
1888
|
+
size?: ArveaQuantitySize;
|
|
1889
|
+
disabled?: boolean;
|
|
1890
|
+
}
|
|
1891
|
+
|
|
1892
|
+
/**
|
|
1893
|
+
* @element arvea-quantity-selector
|
|
1894
|
+
*
|
|
1895
|
+
* @prop {number} value - current value
|
|
1896
|
+
* @prop {number} min - default 1
|
|
1897
|
+
* @prop {number} max - default Infinity
|
|
1898
|
+
* @prop {number} step - default 1
|
|
1899
|
+
* @prop {ArveaQuantitySize} size - 'sm' | 'md' | 'lg'
|
|
1900
|
+
* @prop {boolean} disabled
|
|
1901
|
+
*
|
|
1902
|
+
* @fires arvea-quantity-change - { detail: { value } }
|
|
1903
|
+
*/
|
|
1904
|
+
declare class ArveaQuantitySelector extends LitElement {
|
|
1905
|
+
static styles: lit.CSSResult[];
|
|
1906
|
+
value: number;
|
|
1907
|
+
min: number;
|
|
1908
|
+
max: number;
|
|
1909
|
+
step: number;
|
|
1910
|
+
size: ArveaQuantitySize;
|
|
1911
|
+
disabled: boolean;
|
|
1912
|
+
private _set;
|
|
1913
|
+
private _onInput;
|
|
1914
|
+
render(): lit_html.TemplateResult<1>;
|
|
1915
|
+
}
|
|
1916
|
+
declare global {
|
|
1917
|
+
interface HTMLElementTagNameMap {
|
|
1918
|
+
'arvea-quantity-selector': ArveaQuantitySelector;
|
|
1919
|
+
}
|
|
1920
|
+
}
|
|
1921
|
+
|
|
1922
|
+
type ArveaStepperOrientation = 'horizontal' | 'vertical';
|
|
1923
|
+
interface ArveaStepperStep {
|
|
1924
|
+
id: string;
|
|
1925
|
+
label: string;
|
|
1926
|
+
description?: string;
|
|
1927
|
+
}
|
|
1928
|
+
interface ArveaStepperProps {
|
|
1929
|
+
steps?: ArveaStepperStep[];
|
|
1930
|
+
active?: number;
|
|
1931
|
+
orientation?: ArveaStepperOrientation;
|
|
1932
|
+
clickable?: boolean;
|
|
1933
|
+
}
|
|
1934
|
+
|
|
1935
|
+
/**
|
|
1936
|
+
* @element arvea-stepper
|
|
1937
|
+
*
|
|
1938
|
+
* @prop {ArveaStepperStep[]} steps - Step definitions
|
|
1939
|
+
* @prop {number} active - 0-based index of the active step
|
|
1940
|
+
* @prop {ArveaStepperOrientation} orientation - 'horizontal' (default) | 'vertical'
|
|
1941
|
+
* @prop {boolean} clickable - allow clicking complete/active steps to navigate
|
|
1942
|
+
*
|
|
1943
|
+
* @fires arvea-stepper-change - { detail: { active, step } }
|
|
1944
|
+
*/
|
|
1945
|
+
declare class ArveaStepper extends LitElement {
|
|
1946
|
+
static styles: lit.CSSResult[];
|
|
1947
|
+
steps: ArveaStepperStep[];
|
|
1948
|
+
active: number;
|
|
1949
|
+
orientation: ArveaStepperOrientation;
|
|
1950
|
+
clickable: boolean;
|
|
1951
|
+
private _stateOf;
|
|
1952
|
+
private _onStepClick;
|
|
1953
|
+
private _renderCircle;
|
|
1954
|
+
render(): lit_html.TemplateResult<1>;
|
|
1955
|
+
}
|
|
1956
|
+
declare global {
|
|
1957
|
+
interface HTMLElementTagNameMap {
|
|
1958
|
+
'arvea-stepper': ArveaStepper;
|
|
1959
|
+
}
|
|
1960
|
+
}
|
|
1961
|
+
|
|
1962
|
+
type ArveaEmptyStateSize = 'sm' | 'md' | 'lg';
|
|
1963
|
+
interface ArveaEmptyStateProps {
|
|
1964
|
+
icon?: string;
|
|
1965
|
+
title?: string;
|
|
1966
|
+
description?: string;
|
|
1967
|
+
size?: ArveaEmptyStateSize;
|
|
1968
|
+
}
|
|
1969
|
+
|
|
1970
|
+
/**
|
|
1971
|
+
* @element arvea-empty-state
|
|
1972
|
+
*
|
|
1973
|
+
* Placeholder block for empty lists, no-results, error pages, and the empty
|
|
1974
|
+
* state inside data tables.
|
|
1975
|
+
*
|
|
1976
|
+
* @prop {string} icon - SVG string. Falls back to a generic illustration.
|
|
1977
|
+
* @prop {string} title - Headline text
|
|
1978
|
+
* @prop {string} description - Helper sentence under the title
|
|
1979
|
+
* @prop {'sm'|'md'|'lg'} size
|
|
1980
|
+
*
|
|
1981
|
+
* @slot icon - Custom icon element (overrides the `icon` prop)
|
|
1982
|
+
* @slot - Default slot for replacing title/description with rich content
|
|
1983
|
+
* @slot actions - Buttons or links shown below the description
|
|
1984
|
+
*/
|
|
1985
|
+
declare class ArveaEmptyState extends LitElement {
|
|
1986
|
+
static styles: lit.CSSResult[];
|
|
1987
|
+
icon?: string;
|
|
1988
|
+
title: string;
|
|
1989
|
+
description: string;
|
|
1990
|
+
size: ArveaEmptyStateSize;
|
|
1991
|
+
render(): lit_html.TemplateResult<1>;
|
|
1992
|
+
}
|
|
1993
|
+
declare global {
|
|
1994
|
+
interface HTMLElementTagNameMap {
|
|
1995
|
+
'arvea-empty-state': ArveaEmptyState;
|
|
1996
|
+
}
|
|
1997
|
+
}
|
|
1998
|
+
|
|
1999
|
+
type ArveaDataTableAlign = 'left' | 'center' | 'right';
|
|
2000
|
+
type ArveaDataTableSortDirection = 'asc' | 'desc' | null;
|
|
2001
|
+
type ArveaDataTableRowSelection = 'none' | 'single' | 'multiple';
|
|
2002
|
+
type ArveaDataTableFilterType = 'text' | 'select' | 'date';
|
|
2003
|
+
interface ArveaDataTableColumnFilter {
|
|
2004
|
+
type: ArveaDataTableFilterType;
|
|
2005
|
+
options?: ArveaSelectOption[];
|
|
2006
|
+
placeholder?: string;
|
|
2007
|
+
}
|
|
2008
|
+
interface ArveaDataTableBadge {
|
|
2009
|
+
label: string;
|
|
2010
|
+
variant?: BadgeVariant;
|
|
2011
|
+
/** Custom background color (overrides variant color). */
|
|
2012
|
+
color?: string;
|
|
2013
|
+
/** Custom text/icon color (overrides variant color). */
|
|
2014
|
+
textColor?: string;
|
|
2015
|
+
/** Icon name from arvea-icon (overrides the variant icon). */
|
|
2016
|
+
icon?: string;
|
|
2017
|
+
/** Removes background and padding for a transparent look. */
|
|
2018
|
+
noBg?: boolean;
|
|
2019
|
+
/** Hides the leading icon (status variants show one by default). */
|
|
2020
|
+
hideIcon?: boolean;
|
|
2021
|
+
}
|
|
2022
|
+
interface ArveaDataTableAction {
|
|
2023
|
+
id: string;
|
|
2024
|
+
label?: string;
|
|
2025
|
+
variant?: ArveaActionButtonVariant;
|
|
2026
|
+
icon?: string;
|
|
2027
|
+
/** Overrides the variant's background color (mirrors arvea-action-button's bg-color prop). */
|
|
2028
|
+
bgColor?: string;
|
|
2029
|
+
/** Overrides the variant's icon/text color (mirrors arvea-action-button's color prop). */
|
|
2030
|
+
color?: string;
|
|
2031
|
+
disabled?: boolean;
|
|
2032
|
+
}
|
|
2033
|
+
interface ArveaDataTableColumn<T = Record<string, unknown>> {
|
|
2034
|
+
key: string;
|
|
2035
|
+
label: string;
|
|
2036
|
+
sortable?: boolean;
|
|
2037
|
+
align?: ArveaDataTableAlign;
|
|
2038
|
+
width?: string;
|
|
2039
|
+
minWidth?: number;
|
|
2040
|
+
resizable?: boolean;
|
|
2041
|
+
hideMobile?: boolean;
|
|
2042
|
+
hideTablet?: boolean;
|
|
2043
|
+
filter?: ArveaDataTableColumnFilter;
|
|
2044
|
+
/** Renders `row[key]` as an image thumbnail, with a placeholder icon when empty. */
|
|
2045
|
+
image?: boolean;
|
|
2046
|
+
/** Renders the cell as an `arvea-badge`; return `null` to leave the cell empty. */
|
|
2047
|
+
badge?: (row: T, index: number) => ArveaDataTableBadge | null;
|
|
2048
|
+
/** Renders a row of `arvea-action-button`s; clicks fire `arvea-table-action`. */
|
|
2049
|
+
actions?: (row: T, index: number) => ArveaDataTableAction[];
|
|
2050
|
+
render?: (row: T, index: number) => string | number | null | TemplateResult;
|
|
2051
|
+
}
|
|
2052
|
+
interface ArveaDataTableSort {
|
|
2053
|
+
key: string;
|
|
2054
|
+
direction: ArveaDataTableSortDirection;
|
|
2055
|
+
}
|
|
2056
|
+
interface ArveaDataTablePagination {
|
|
2057
|
+
page: number;
|
|
2058
|
+
pageSize: number;
|
|
2059
|
+
total?: number;
|
|
2060
|
+
}
|
|
2061
|
+
type ArveaDataTableSize = 'sm' | 'md' | 'lg';
|
|
2062
|
+
type ArveaDataTableResponsive = 'scroll' | 'hide' | 'cards';
|
|
2063
|
+
interface ArveaDataTableProps<T = Record<string, unknown>> {
|
|
2064
|
+
columns?: ArveaDataTableColumn<T>[];
|
|
2065
|
+
rows?: T[];
|
|
2066
|
+
loading?: boolean;
|
|
2067
|
+
emptyText?: string;
|
|
2068
|
+
rowKey?: string;
|
|
2069
|
+
sort?: ArveaDataTableSort;
|
|
2070
|
+
density?: 'compact' | 'normal';
|
|
2071
|
+
size?: ArveaDataTableSize;
|
|
2072
|
+
rowSelection?: ArveaDataTableRowSelection;
|
|
2073
|
+
selectedKeys?: string[];
|
|
2074
|
+
filterValues?: Record<string, unknown>;
|
|
2075
|
+
resizableColumns?: boolean;
|
|
2076
|
+
virtualized?: boolean;
|
|
2077
|
+
estimatedRowHeight?: number;
|
|
2078
|
+
pagination?: ArveaDataTablePagination | null;
|
|
2079
|
+
stickyHeader?: boolean;
|
|
2080
|
+
manualSort?: boolean;
|
|
2081
|
+
manualPagination?: boolean;
|
|
2082
|
+
striped?: boolean;
|
|
2083
|
+
bordered?: boolean;
|
|
2084
|
+
hoverable?: boolean;
|
|
2085
|
+
noWrap?: boolean;
|
|
2086
|
+
responsive?: ArveaDataTableResponsive;
|
|
2087
|
+
globalFilter?: string;
|
|
2088
|
+
caption?: string;
|
|
2089
|
+
expandable?: boolean;
|
|
2090
|
+
expandedKeys?: string[];
|
|
2091
|
+
renderExpanded?: (row: T, index: number) => unknown;
|
|
2092
|
+
}
|
|
2093
|
+
|
|
2094
|
+
type Row = Record<string, unknown>;
|
|
2095
|
+
/**
|
|
2096
|
+
* @element arvea-data-table
|
|
2097
|
+
*
|
|
2098
|
+
* @fires arvea-table-sort - { key, direction }
|
|
2099
|
+
* @fires arvea-table-row-click - { row, index }
|
|
2100
|
+
* @fires arvea-table-selection-change - { selectedKeys, selectedRows }
|
|
2101
|
+
* @fires arvea-table-filter-change - { filterValues }
|
|
2102
|
+
* @fires arvea-table-column-resize - { key, width }
|
|
2103
|
+
* @fires arvea-table-page-change - { page, pageSize }
|
|
2104
|
+
* @fires arvea-table-action - { id, row, index }
|
|
2105
|
+
*/
|
|
2106
|
+
declare class ArveaDataTable extends LitElement {
|
|
2107
|
+
static styles: lit.CSSResult[];
|
|
2108
|
+
columns: ArveaDataTableColumn<any>[];
|
|
2109
|
+
rows: Row[];
|
|
2110
|
+
loading: boolean;
|
|
2111
|
+
emptyText: string;
|
|
2112
|
+
rowKey: string;
|
|
2113
|
+
sort: ArveaDataTableSort | null;
|
|
2114
|
+
density: 'compact' | 'normal';
|
|
2115
|
+
rowSelection: ArveaDataTableRowSelection;
|
|
2116
|
+
selectedKeys: string[];
|
|
2117
|
+
filterValues: Record<string, unknown>;
|
|
2118
|
+
resizableColumns: boolean;
|
|
2119
|
+
virtualized: boolean;
|
|
2120
|
+
estimatedRowHeight: number;
|
|
2121
|
+
pagination: ArveaDataTablePagination | null;
|
|
2122
|
+
pageSizeOptions: number[];
|
|
2123
|
+
hideToolbar: boolean;
|
|
2124
|
+
stickyHeader: boolean;
|
|
2125
|
+
manualSort: boolean;
|
|
2126
|
+
manualPagination: boolean;
|
|
2127
|
+
size: ArveaDataTableSize;
|
|
2128
|
+
striped: boolean;
|
|
2129
|
+
bordered: boolean;
|
|
2130
|
+
hoverable: boolean;
|
|
2131
|
+
noWrap: boolean;
|
|
2132
|
+
responsive: ArveaDataTableResponsive;
|
|
2133
|
+
globalFilter: string;
|
|
2134
|
+
caption: string;
|
|
2135
|
+
expandable: boolean;
|
|
2136
|
+
expandedKeys: string[];
|
|
2137
|
+
renderExpanded?: (row: Row, index: number) => unknown;
|
|
2138
|
+
private _columnWidths;
|
|
2139
|
+
private _scrollTop;
|
|
2140
|
+
private _viewportHeight;
|
|
2141
|
+
private _scrollEl?;
|
|
2142
|
+
private _resizeKey;
|
|
2143
|
+
private _resizeStartX;
|
|
2144
|
+
private _resizeStartW;
|
|
2145
|
+
private get _activeFilters();
|
|
2146
|
+
private _matchesFilters;
|
|
2147
|
+
private _matchesGlobalFilter;
|
|
2148
|
+
private get _filteredRows();
|
|
2149
|
+
private _compare;
|
|
2150
|
+
private get _sortedRows();
|
|
2151
|
+
private get _paginatedRows();
|
|
2152
|
+
private get _rowKeyValue();
|
|
2153
|
+
private get _selectedSet();
|
|
2154
|
+
private get _visibleKeys();
|
|
2155
|
+
private get _headerSelectState();
|
|
2156
|
+
private get _virtualizationActive();
|
|
2157
|
+
connectedCallback(): void;
|
|
2158
|
+
private _toggleSort;
|
|
2159
|
+
private _onRowClick;
|
|
2160
|
+
private _onAction;
|
|
2161
|
+
private _toggleRow;
|
|
2162
|
+
private _toggleAllVisible;
|
|
2163
|
+
private _onFilterChange;
|
|
2164
|
+
private _onPageChange;
|
|
2165
|
+
private _onPageSizeChange;
|
|
2166
|
+
private _onPageSizeSelectChange;
|
|
2167
|
+
private _onResizeStart;
|
|
2168
|
+
private _onResizeMove;
|
|
2169
|
+
private _onResizeEnd;
|
|
2170
|
+
private _alignClass;
|
|
2171
|
+
private _colClass;
|
|
2172
|
+
private _renderCell;
|
|
2173
|
+
private _renderBadgeCell;
|
|
2174
|
+
private _renderImageCell;
|
|
2175
|
+
private _renderActionsCell;
|
|
2176
|
+
private _sortIcon;
|
|
2177
|
+
private _onScroll;
|
|
2178
|
+
private _columnStyle;
|
|
2179
|
+
render(): TemplateResult<1>;
|
|
2180
|
+
private _renderHeaderCell;
|
|
2181
|
+
private _renderFilterCell;
|
|
2182
|
+
private _renderBody;
|
|
2183
|
+
private _renderVirtualizedBody;
|
|
2184
|
+
private _toggleExpand;
|
|
2185
|
+
private _renderRow;
|
|
2186
|
+
}
|
|
2187
|
+
declare global {
|
|
2188
|
+
interface HTMLElementTagNameMap {
|
|
2189
|
+
'arvea-data-table': ArveaDataTable;
|
|
2190
|
+
}
|
|
2191
|
+
}
|
|
2192
|
+
|
|
2193
|
+
interface ArveaLightboxItem {
|
|
2194
|
+
src: string;
|
|
2195
|
+
alt?: string;
|
|
2196
|
+
caption?: string;
|
|
2197
|
+
}
|
|
2198
|
+
interface ArveaLightboxProps {
|
|
2199
|
+
items?: ArveaLightboxItem[];
|
|
2200
|
+
index?: number;
|
|
2201
|
+
open?: boolean;
|
|
2202
|
+
showThumbnails?: boolean;
|
|
2203
|
+
showCounter?: boolean;
|
|
2204
|
+
}
|
|
2205
|
+
|
|
2206
|
+
/**
|
|
2207
|
+
* @element arvea-lightbox
|
|
2208
|
+
*
|
|
2209
|
+
* @prop {ArveaLightboxItem[]} items - Media items
|
|
2210
|
+
* @prop {number} index - currently displayed item (0-based)
|
|
2211
|
+
* @prop {boolean} open - controls visibility
|
|
2212
|
+
* @prop {boolean} showThumbnails - show thumbnail strip
|
|
2213
|
+
* @prop {boolean} showCounter - show "1 / N" counter
|
|
2214
|
+
*
|
|
2215
|
+
* @fires arvea-lightbox-change - { detail: { index, item } }
|
|
2216
|
+
* @fires arvea-lightbox-close
|
|
2217
|
+
*/
|
|
2218
|
+
declare class ArveaLightbox extends LitElement {
|
|
2219
|
+
static styles: lit.CSSResult[];
|
|
2220
|
+
items: ArveaLightboxItem[];
|
|
2221
|
+
index: number;
|
|
2222
|
+
open: boolean;
|
|
2223
|
+
showThumbnails: boolean;
|
|
2224
|
+
showCounter: boolean;
|
|
2225
|
+
private _keyHandler;
|
|
2226
|
+
connectedCallback(): void;
|
|
2227
|
+
disconnectedCallback(): void;
|
|
2228
|
+
private _go;
|
|
2229
|
+
private _close;
|
|
2230
|
+
private _onOverlayClick;
|
|
2231
|
+
render(): lit_html.TemplateResult<1> | typeof nothing;
|
|
2232
|
+
}
|
|
2233
|
+
declare global {
|
|
2234
|
+
interface HTMLElementTagNameMap {
|
|
2235
|
+
'arvea-lightbox': ArveaLightbox;
|
|
2236
|
+
}
|
|
2237
|
+
}
|
|
2238
|
+
|
|
2239
|
+
type TableResponsive = 'scroll' | 'hide' | 'cards';
|
|
2240
|
+
interface TableColumn {
|
|
2241
|
+
key: string;
|
|
2242
|
+
label: string;
|
|
2243
|
+
visible?: boolean;
|
|
2244
|
+
hideMobile?: boolean;
|
|
2245
|
+
hideTablet?: boolean;
|
|
2246
|
+
}
|
|
2247
|
+
interface ArveaTableRow {
|
|
2248
|
+
[key: string]: string;
|
|
2249
|
+
}
|
|
2250
|
+
interface ArveaTableProps {
|
|
2251
|
+
columns?: TableColumn[];
|
|
2252
|
+
rows?: ArveaTableRow[];
|
|
2253
|
+
pageSize?: number;
|
|
2254
|
+
responsive?: TableResponsive;
|
|
2255
|
+
}
|
|
2256
|
+
|
|
2257
|
+
declare class ArveaTable extends LitElement {
|
|
2258
|
+
static styles: lit.CSSResult[];
|
|
2259
|
+
columns: TableColumn[];
|
|
2260
|
+
rows: ArveaTableRow[];
|
|
2261
|
+
pageSize: number;
|
|
2262
|
+
responsive: TableResponsive;
|
|
2263
|
+
emptyText: string;
|
|
2264
|
+
private _page;
|
|
2265
|
+
private get _pagedRows();
|
|
2266
|
+
private _getColClass;
|
|
2267
|
+
render(): lit_html.TemplateResult<1>;
|
|
2268
|
+
}
|
|
2269
|
+
declare global {
|
|
2270
|
+
interface HTMLElementTagNameMap {
|
|
2271
|
+
'arvea-table': ArveaTable;
|
|
2272
|
+
}
|
|
2273
|
+
}
|
|
2274
|
+
|
|
2275
|
+
type ArveaPopoverPlacement = 'top' | 'bottom' | 'left' | 'right' | 'top-start' | 'top-end' | 'bottom-start' | 'bottom-end' | 'left-start' | 'left-end' | 'right-start' | 'right-end';
|
|
2276
|
+
type ArveaPopoverTrigger = 'click' | 'hover' | 'focus' | 'manual';
|
|
2277
|
+
interface ArveaPopoverProps {
|
|
2278
|
+
open?: boolean;
|
|
2279
|
+
placement?: ArveaPopoverPlacement;
|
|
2280
|
+
offset?: number;
|
|
2281
|
+
trigger?: ArveaPopoverTrigger;
|
|
2282
|
+
disabled?: boolean;
|
|
2283
|
+
matchTriggerWidth?: boolean;
|
|
2284
|
+
}
|
|
2285
|
+
|
|
2286
|
+
/**
|
|
2287
|
+
* @element arvea-popover
|
|
2288
|
+
*
|
|
2289
|
+
* Anchored popover primitive. Renders an absolutely-positioned popup next to
|
|
2290
|
+
* a trigger element, with viewport-aware flipping and click-outside handling.
|
|
2291
|
+
* Used as the positioning foundation for tooltips, dropdowns, popconfirms,
|
|
2292
|
+
* date-pickers and selects.
|
|
2293
|
+
*
|
|
2294
|
+
* @prop {boolean} open
|
|
2295
|
+
* @prop {ArveaPopoverPlacement} placement
|
|
2296
|
+
* @prop {number} offset
|
|
2297
|
+
* @prop {ArveaPopoverTrigger} trigger
|
|
2298
|
+
* @prop {boolean} disabled
|
|
2299
|
+
* @prop {boolean} matchTriggerWidth
|
|
2300
|
+
*
|
|
2301
|
+
* @slot trigger - The element that triggers the popover
|
|
2302
|
+
* @slot - Popover body content
|
|
2303
|
+
*
|
|
2304
|
+
* @fires arvea-popover-open
|
|
2305
|
+
* @fires arvea-popover-close
|
|
2306
|
+
*/
|
|
2307
|
+
declare class ArveaPopover extends LitElement {
|
|
2308
|
+
static styles: lit.CSSResult[];
|
|
2309
|
+
open: boolean;
|
|
2310
|
+
placement: ArveaPopoverPlacement;
|
|
2311
|
+
offset: number;
|
|
2312
|
+
trigger: ArveaPopoverTrigger;
|
|
2313
|
+
disabled: boolean;
|
|
2314
|
+
matchTriggerWidth: boolean;
|
|
2315
|
+
private _triggerEl;
|
|
2316
|
+
private _popupEl;
|
|
2317
|
+
private _resolvedPlacement;
|
|
2318
|
+
private _onScroll;
|
|
2319
|
+
private _onResize;
|
|
2320
|
+
private _onDocPointer;
|
|
2321
|
+
private _onKey;
|
|
2322
|
+
connectedCallback(): void;
|
|
2323
|
+
disconnectedCallback(): void;
|
|
2324
|
+
updated(changed: Map<string, unknown>): void;
|
|
2325
|
+
show(): void;
|
|
2326
|
+
hide(): void;
|
|
2327
|
+
toggle(): void;
|
|
2328
|
+
private _show;
|
|
2329
|
+
private _hide;
|
|
2330
|
+
private _position;
|
|
2331
|
+
private _flipIfNeeded;
|
|
2332
|
+
private _onTriggerClick;
|
|
2333
|
+
private _onTriggerEnter;
|
|
2334
|
+
private _onTriggerLeave;
|
|
2335
|
+
private _onTriggerFocusIn;
|
|
2336
|
+
private _onTriggerFocusOut;
|
|
2337
|
+
render(): lit_html.TemplateResult<1>;
|
|
2338
|
+
}
|
|
2339
|
+
declare global {
|
|
2340
|
+
interface HTMLElementTagNameMap {
|
|
2341
|
+
'arvea-popover': ArveaPopover;
|
|
2342
|
+
}
|
|
2343
|
+
}
|
|
2344
|
+
|
|
2345
|
+
type ArveaPopconfirmVariant = 'default' | 'destructive';
|
|
2346
|
+
interface ArveaPopconfirmProps {
|
|
2347
|
+
title?: string;
|
|
2348
|
+
description?: string;
|
|
2349
|
+
confirmText?: string;
|
|
2350
|
+
cancelText?: string;
|
|
2351
|
+
variant?: ArveaPopconfirmVariant;
|
|
2352
|
+
disabled?: boolean;
|
|
2353
|
+
open?: boolean;
|
|
2354
|
+
}
|
|
2355
|
+
|
|
2356
|
+
/**
|
|
2357
|
+
* @element arvea-popconfirm
|
|
2358
|
+
*
|
|
2359
|
+
* Inline "Are you sure?" popover for destructive or impactful actions. Uses
|
|
2360
|
+
* <arvea-popover> for positioning.
|
|
2361
|
+
*
|
|
2362
|
+
* @slot trigger - The element that triggers the confirmation (button, icon, etc.)
|
|
2363
|
+
*
|
|
2364
|
+
* @fires arvea-confirm
|
|
2365
|
+
* @fires arvea-cancel
|
|
2366
|
+
*/
|
|
2367
|
+
declare class ArveaPopconfirm extends LitElement {
|
|
2368
|
+
static styles: lit.CSSResult[];
|
|
2369
|
+
title: string;
|
|
2370
|
+
description: string;
|
|
2371
|
+
confirmText: string;
|
|
2372
|
+
cancelText: string;
|
|
2373
|
+
variant: ArveaPopconfirmVariant;
|
|
2374
|
+
disabled: boolean;
|
|
2375
|
+
open: boolean;
|
|
2376
|
+
private _popover?;
|
|
2377
|
+
private _onConfirm;
|
|
2378
|
+
private _onCancel;
|
|
2379
|
+
private _onPopoverChange;
|
|
2380
|
+
render(): lit_html.TemplateResult<1>;
|
|
2381
|
+
}
|
|
2382
|
+
declare global {
|
|
2383
|
+
interface HTMLElementTagNameMap {
|
|
2384
|
+
'arvea-popconfirm': ArveaPopconfirm;
|
|
2385
|
+
}
|
|
2386
|
+
}
|
|
2387
|
+
|
|
2388
|
+
type ArveaDrawerPlacement = 'left' | 'right' | 'top' | 'bottom';
|
|
2389
|
+
type ArveaDrawerSize = 'sm' | 'md' | 'lg' | 'full' | string;
|
|
2390
|
+
interface ArveaDrawerProps {
|
|
2391
|
+
open?: boolean;
|
|
2392
|
+
placement?: ArveaDrawerPlacement;
|
|
2393
|
+
size?: ArveaDrawerSize;
|
|
2394
|
+
title?: string;
|
|
2395
|
+
closeOnOverlayClick?: boolean;
|
|
2396
|
+
closeOnEsc?: boolean;
|
|
2397
|
+
preventScroll?: boolean;
|
|
2398
|
+
hideOverlay?: boolean;
|
|
2399
|
+
}
|
|
2400
|
+
|
|
2401
|
+
/**
|
|
2402
|
+
* @element arvea-drawer
|
|
2403
|
+
*
|
|
2404
|
+
* Side-sliding panel for cart drawers, filter sidebars, settings, etc.
|
|
2405
|
+
* Companion to <arvea-dialog> for non-centered overlays.
|
|
2406
|
+
*
|
|
2407
|
+
* @slot header
|
|
2408
|
+
* @slot - default body
|
|
2409
|
+
* @slot footer
|
|
2410
|
+
*
|
|
2411
|
+
* @fires arvea-drawer-open
|
|
2412
|
+
* @fires arvea-drawer-close
|
|
2413
|
+
*/
|
|
2414
|
+
declare class ArveaDrawer extends LitElement {
|
|
2415
|
+
static styles: lit.CSSResult[];
|
|
2416
|
+
open: boolean;
|
|
2417
|
+
placement: ArveaDrawerPlacement;
|
|
2418
|
+
size: ArveaDrawerSize;
|
|
2419
|
+
title: string;
|
|
2420
|
+
closeOnOverlayClick: boolean;
|
|
2421
|
+
closeOnEsc: boolean;
|
|
2422
|
+
preventScroll: boolean;
|
|
2423
|
+
hideOverlay: boolean;
|
|
2424
|
+
private _previouslyFocused;
|
|
2425
|
+
private _onKey;
|
|
2426
|
+
connectedCallback(): void;
|
|
2427
|
+
disconnectedCallback(): void;
|
|
2428
|
+
updated(changed: Map<string, unknown>): void;
|
|
2429
|
+
show(): void;
|
|
2430
|
+
close(): void;
|
|
2431
|
+
toggle(): void;
|
|
2432
|
+
private _focusableElements;
|
|
2433
|
+
private _focusFirst;
|
|
2434
|
+
private _trapFocus;
|
|
2435
|
+
private _onOverlayClick;
|
|
2436
|
+
render(): lit_html.TemplateResult<1>;
|
|
2437
|
+
}
|
|
2438
|
+
declare global {
|
|
2439
|
+
interface HTMLElementTagNameMap {
|
|
2440
|
+
'arvea-drawer': ArveaDrawer;
|
|
2441
|
+
}
|
|
2442
|
+
}
|
|
2443
|
+
|
|
2444
|
+
type ArveaSegmentedControlSize = 'sm' | 'md' | 'lg';
|
|
2445
|
+
interface ArveaSegmentedControlItem {
|
|
2446
|
+
value: string;
|
|
2447
|
+
label: string;
|
|
2448
|
+
icon?: string;
|
|
2449
|
+
disabled?: boolean;
|
|
2450
|
+
}
|
|
2451
|
+
interface ArveaSegmentedControlProps {
|
|
2452
|
+
items?: ArveaSegmentedControlItem[];
|
|
2453
|
+
value?: string;
|
|
2454
|
+
size?: ArveaSegmentedControlSize;
|
|
2455
|
+
disabled?: boolean;
|
|
2456
|
+
fullWidth?: boolean;
|
|
2457
|
+
}
|
|
2458
|
+
|
|
2459
|
+
/**
|
|
2460
|
+
* @element arvea-segmented-control
|
|
2461
|
+
*
|
|
2462
|
+
* Pill-style segmented selector. Useful as a single-choice alternative to
|
|
2463
|
+
* radio groups (view-mode toggles, sort selectors).
|
|
2464
|
+
*
|
|
2465
|
+
* @fires arvea-segmented-change - { value }
|
|
2466
|
+
*/
|
|
2467
|
+
declare class ArveaSegmentedControl extends LitElement {
|
|
2468
|
+
static styles: lit.CSSResult[];
|
|
2469
|
+
items: ArveaSegmentedControlItem[];
|
|
2470
|
+
value: string;
|
|
2471
|
+
size: ArveaSegmentedControlSize;
|
|
2472
|
+
disabled: boolean;
|
|
2473
|
+
fullWidth: boolean;
|
|
2474
|
+
private _select;
|
|
2475
|
+
private _onKey;
|
|
2476
|
+
render(): lit_html.TemplateResult<1>;
|
|
2477
|
+
}
|
|
2478
|
+
declare global {
|
|
2479
|
+
interface HTMLElementTagNameMap {
|
|
2480
|
+
'arvea-segmented-control': ArveaSegmentedControl;
|
|
2481
|
+
}
|
|
2482
|
+
}
|
|
2483
|
+
|
|
2484
|
+
type ArveaTagValidator = (tag: string) => boolean | string;
|
|
2485
|
+
interface ArveaTagsInputProps {
|
|
2486
|
+
value?: string[];
|
|
2487
|
+
placeholder?: string;
|
|
2488
|
+
maxTags?: number;
|
|
2489
|
+
allowDuplicates?: boolean;
|
|
2490
|
+
separator?: string | RegExp;
|
|
2491
|
+
validateTag?: ArveaTagValidator;
|
|
2492
|
+
disabled?: boolean;
|
|
2493
|
+
label?: string;
|
|
2494
|
+
suggestions?: string[];
|
|
2495
|
+
invalid?: boolean;
|
|
2496
|
+
validationHint?: string;
|
|
2497
|
+
}
|
|
2498
|
+
|
|
2499
|
+
/**
|
|
2500
|
+
* @element arvea-tags-input
|
|
2501
|
+
*
|
|
2502
|
+
* Multi-tag entry input. Typed values are committed as chips on Enter or on
|
|
2503
|
+
* any of the configured separator characters. Supports optional autocomplete
|
|
2504
|
+
* suggestions, max-tags limit, duplicate prevention and per-tag validation.
|
|
2505
|
+
*
|
|
2506
|
+
* @fires arvea-tags-change { value: string[] }
|
|
2507
|
+
* @fires arvea-tag-add { tag: string }
|
|
2508
|
+
* @fires arvea-tag-remove { tag: string }
|
|
2509
|
+
*/
|
|
2510
|
+
declare class ArveaTagsInput extends LitElement {
|
|
2511
|
+
static styles: lit.CSSResult[];
|
|
2512
|
+
value: string[];
|
|
2513
|
+
placeholder: string;
|
|
2514
|
+
maxTags?: number;
|
|
2515
|
+
allowDuplicates: boolean;
|
|
2516
|
+
separator: string | RegExp;
|
|
2517
|
+
validateTag?: ArveaTagValidator;
|
|
2518
|
+
disabled: boolean;
|
|
2519
|
+
label: string;
|
|
2520
|
+
suggestions: string[];
|
|
2521
|
+
invalid: boolean;
|
|
2522
|
+
validationHint: string;
|
|
2523
|
+
private _query;
|
|
2524
|
+
private _activeSuggestion;
|
|
2525
|
+
private _errorMessage;
|
|
2526
|
+
private _input?;
|
|
2527
|
+
private get _suggestions();
|
|
2528
|
+
private _commit;
|
|
2529
|
+
private _remove;
|
|
2530
|
+
private _emitChange;
|
|
2531
|
+
private _onInput;
|
|
2532
|
+
private _onKeydown;
|
|
2533
|
+
render(): lit_html.TemplateResult<1>;
|
|
2534
|
+
}
|
|
2535
|
+
declare global {
|
|
2536
|
+
interface HTMLElementTagNameMap {
|
|
2537
|
+
'arvea-tags-input': ArveaTagsInput;
|
|
2538
|
+
}
|
|
2539
|
+
}
|
|
2540
|
+
|
|
2541
|
+
type ArveaOtpType = 'numeric' | 'alphanumeric';
|
|
2542
|
+
interface ArveaOtpInputProps {
|
|
2543
|
+
length?: number;
|
|
2544
|
+
value?: string;
|
|
2545
|
+
type?: ArveaOtpType;
|
|
2546
|
+
mask?: boolean;
|
|
2547
|
+
autoFocus?: boolean;
|
|
2548
|
+
disabled?: boolean;
|
|
2549
|
+
invalid?: boolean;
|
|
2550
|
+
label?: string;
|
|
2551
|
+
}
|
|
2552
|
+
|
|
2553
|
+
/**
|
|
2554
|
+
* @element arvea-otp-input
|
|
2555
|
+
*
|
|
2556
|
+
* Segmented one-time-code / PIN input. Auto-advances cells, supports paste,
|
|
2557
|
+
* backspace navigation, arrow keys, masking, and a configurable character
|
|
2558
|
+
* class (numeric / alphanumeric).
|
|
2559
|
+
*
|
|
2560
|
+
* @fires arvea-otp-input { value }
|
|
2561
|
+
* @fires arvea-otp-complete { value } (only when all cells filled)
|
|
2562
|
+
*/
|
|
2563
|
+
declare class ArveaOtpInput extends LitElement {
|
|
2564
|
+
static styles: lit.CSSResult[];
|
|
2565
|
+
length: number;
|
|
2566
|
+
value: string;
|
|
2567
|
+
type: ArveaOtpType;
|
|
2568
|
+
mask: boolean;
|
|
2569
|
+
autoFocus: boolean;
|
|
2570
|
+
disabled: boolean;
|
|
2571
|
+
invalid: boolean;
|
|
2572
|
+
label: string;
|
|
2573
|
+
private _cells;
|
|
2574
|
+
private get _allowedRegex();
|
|
2575
|
+
private get _digits();
|
|
2576
|
+
firstUpdated(): void;
|
|
2577
|
+
private _setChar;
|
|
2578
|
+
private _onInput;
|
|
2579
|
+
private _onKey;
|
|
2580
|
+
private _onPaste;
|
|
2581
|
+
private _cellChar;
|
|
2582
|
+
render(): lit_html.TemplateResult<1>;
|
|
2583
|
+
}
|
|
2584
|
+
declare global {
|
|
2585
|
+
interface HTMLElementTagNameMap {
|
|
2586
|
+
'arvea-otp-input': ArveaOtpInput;
|
|
2587
|
+
}
|
|
2588
|
+
}
|
|
2589
|
+
|
|
2590
|
+
/**
|
|
2591
|
+
* @element arvea-file-upload
|
|
2592
|
+
*
|
|
2593
|
+
* Drop-zone + click-to-browse file input. Supports type filtering, size and
|
|
2594
|
+
* count limits, image previews, and externally-fed progress.
|
|
2595
|
+
*
|
|
2596
|
+
* @fires arvea-files-change { files: File[] }
|
|
2597
|
+
* @fires arvea-file-rejected { file, reason }
|
|
2598
|
+
* @fires arvea-existing-remove fired when the existingImageUrl preview is removed
|
|
2599
|
+
*/
|
|
2600
|
+
declare class ArveaFileUpload extends LitElement {
|
|
2601
|
+
static styles: lit.CSSResult[];
|
|
2602
|
+
accept?: string;
|
|
2603
|
+
multiple: boolean;
|
|
2604
|
+
maxSize?: number;
|
|
2605
|
+
maxFiles?: number;
|
|
2606
|
+
disabled: boolean;
|
|
2607
|
+
label: string;
|
|
2608
|
+
description: string;
|
|
2609
|
+
files: File[];
|
|
2610
|
+
showPreview: boolean;
|
|
2611
|
+
progress: Record<string, number>;
|
|
2612
|
+
existingImageUrl?: string;
|
|
2613
|
+
private _dragActive;
|
|
2614
|
+
private _previews;
|
|
2615
|
+
private _input?;
|
|
2616
|
+
disconnectedCallback(): void;
|
|
2617
|
+
private _accepts;
|
|
2618
|
+
private _reject;
|
|
2619
|
+
private _processFiles;
|
|
2620
|
+
private _refreshPreviews;
|
|
2621
|
+
private _onSelect;
|
|
2622
|
+
private _onDrop;
|
|
2623
|
+
private _onDragOver;
|
|
2624
|
+
private _onDragLeave;
|
|
2625
|
+
private _remove;
|
|
2626
|
+
private _open;
|
|
2627
|
+
private _zoomEl;
|
|
2628
|
+
private _openZoom;
|
|
2629
|
+
private _replaceFile;
|
|
2630
|
+
private _closeZoom;
|
|
2631
|
+
private _onZoomKey;
|
|
2632
|
+
private _singleImagePreview;
|
|
2633
|
+
private _removeExisting;
|
|
2634
|
+
private _boxPreview;
|
|
2635
|
+
render(): lit_html.TemplateResult<1>;
|
|
2636
|
+
private _renderBoxImage;
|
|
2637
|
+
private _renderFile;
|
|
2638
|
+
}
|
|
2639
|
+
declare global {
|
|
2640
|
+
interface HTMLElementTagNameMap {
|
|
2641
|
+
'arvea-file-upload': ArveaFileUpload;
|
|
2642
|
+
}
|
|
2643
|
+
}
|
|
2644
|
+
|
|
2645
|
+
type ArveaImageFit = 'cover' | 'contain' | 'fill' | 'none';
|
|
2646
|
+
|
|
2647
|
+
/**
|
|
2648
|
+
* @element arvea-image
|
|
2649
|
+
*
|
|
2650
|
+
* Displays an image with an optional click-to-zoom lightbox.
|
|
2651
|
+
*
|
|
2652
|
+
* @prop {string} src - Image URL
|
|
2653
|
+
* @prop {string} alt - Alt text
|
|
2654
|
+
* @prop {string} width - CSS width of the image (e.g. "320px", "100%")
|
|
2655
|
+
* @prop {string} height - CSS height of the image (e.g. "200px")
|
|
2656
|
+
* @prop {ArveaImageFit} fit - object-fit value (cover | contain | fill | none)
|
|
2657
|
+
* @prop {string} radius - Border radius (e.g. "8px", "50%")
|
|
2658
|
+
* @prop {boolean} zoomable - Enable click-to-zoom lightbox (default true)
|
|
2659
|
+
* @prop {string} caption - Optional caption shown below the image
|
|
2660
|
+
*/
|
|
2661
|
+
declare class ArveaImage extends LitElement {
|
|
2662
|
+
static styles: lit.CSSResult[];
|
|
2663
|
+
src: string;
|
|
2664
|
+
alt: string;
|
|
2665
|
+
width: string;
|
|
2666
|
+
height: string;
|
|
2667
|
+
fit: ArveaImageFit;
|
|
2668
|
+
radius: string;
|
|
2669
|
+
zoomable: boolean;
|
|
2670
|
+
caption: string;
|
|
2671
|
+
private _lightboxEl;
|
|
2672
|
+
disconnectedCallback(): void;
|
|
2673
|
+
private _openLightbox;
|
|
2674
|
+
private _closeLightbox;
|
|
2675
|
+
private _onKey;
|
|
2676
|
+
render(): lit_html.TemplateResult<1>;
|
|
2677
|
+
}
|
|
2678
|
+
declare global {
|
|
2679
|
+
interface HTMLElementTagNameMap {
|
|
2680
|
+
'arvea-image': ArveaImage;
|
|
2681
|
+
}
|
|
2682
|
+
}
|
|
2683
|
+
|
|
2684
|
+
type ArveaDatePickerMode = 'single' | 'range';
|
|
2685
|
+
interface ArveaDateRange {
|
|
2686
|
+
from?: string;
|
|
2687
|
+
to?: string;
|
|
2688
|
+
}
|
|
2689
|
+
type ArveaDatePickerValue = string | ArveaDateRange;
|
|
2690
|
+
interface ArveaDatePickerProps {
|
|
2691
|
+
value?: ArveaDatePickerValue;
|
|
2692
|
+
mode?: ArveaDatePickerMode;
|
|
2693
|
+
min?: string;
|
|
2694
|
+
max?: string;
|
|
2695
|
+
disabled?: boolean;
|
|
2696
|
+
required?: boolean;
|
|
2697
|
+
invalid?: boolean;
|
|
2698
|
+
locale?: string;
|
|
2699
|
+
firstDayOfWeek?: number;
|
|
2700
|
+
format?: string;
|
|
2701
|
+
placeholder?: string;
|
|
2702
|
+
label?: string;
|
|
2703
|
+
hideLabel?: boolean;
|
|
2704
|
+
validationHint?: string;
|
|
2705
|
+
disabledDates?: (date: Date) => boolean;
|
|
2706
|
+
}
|
|
2707
|
+
|
|
2708
|
+
/**
|
|
2709
|
+
* @element arvea-date-picker
|
|
2710
|
+
*
|
|
2711
|
+
* Single-date or range date picker. ISO-8601 (YYYY-MM-DD) strings on the wire,
|
|
2712
|
+
* localized labels in the calendar via Intl.
|
|
2713
|
+
*
|
|
2714
|
+
* @fires arvea-date-change { value }
|
|
2715
|
+
*/
|
|
2716
|
+
declare class ArveaDatePicker extends LitElement {
|
|
2717
|
+
static styles: lit.CSSResult[];
|
|
2718
|
+
label: string;
|
|
2719
|
+
hideLabel: boolean;
|
|
2720
|
+
value?: ArveaDatePickerValue;
|
|
2721
|
+
mode: ArveaDatePickerMode;
|
|
2722
|
+
min?: string;
|
|
2723
|
+
max?: string;
|
|
2724
|
+
disabled: boolean;
|
|
2725
|
+
required: boolean;
|
|
2726
|
+
invalid: boolean;
|
|
2727
|
+
locale?: string;
|
|
2728
|
+
firstDayOfWeek: number;
|
|
2729
|
+
format?: string;
|
|
2730
|
+
placeholder: string;
|
|
2731
|
+
validationHint: string;
|
|
2732
|
+
disabledDates?: (d: Date) => boolean;
|
|
2733
|
+
open: boolean;
|
|
2734
|
+
closeOnSelect: boolean;
|
|
2735
|
+
private _viewMonth;
|
|
2736
|
+
private _viewLevel;
|
|
2737
|
+
private _rangeAnchor;
|
|
2738
|
+
private _hoverDate;
|
|
2739
|
+
private _popup?;
|
|
2740
|
+
private _onDocPointer;
|
|
2741
|
+
private _onWinResize;
|
|
2742
|
+
connectedCallback(): void;
|
|
2743
|
+
disconnectedCallback(): void;
|
|
2744
|
+
updated(changed: Map<string, unknown>): void;
|
|
2745
|
+
private _refDate;
|
|
2746
|
+
private _open;
|
|
2747
|
+
private _close;
|
|
2748
|
+
private _positionPopup;
|
|
2749
|
+
private get _localeFormatter();
|
|
2750
|
+
private _formatValue;
|
|
2751
|
+
private _isDisabled;
|
|
2752
|
+
private _isMonthDisabled;
|
|
2753
|
+
private _isYearDisabled;
|
|
2754
|
+
private _selected;
|
|
2755
|
+
private _pick;
|
|
2756
|
+
private _emit;
|
|
2757
|
+
private _headerLabel;
|
|
2758
|
+
private _yearGridStart;
|
|
2759
|
+
private _navPrev;
|
|
2760
|
+
private _navNext;
|
|
2761
|
+
private _headerLabelClick;
|
|
2762
|
+
private _renderHeader;
|
|
2763
|
+
private _renderDays;
|
|
2764
|
+
private _renderMonths;
|
|
2765
|
+
private _renderYears;
|
|
2766
|
+
private _renderCalendar;
|
|
2767
|
+
render(): lit_html.TemplateResult<1>;
|
|
2768
|
+
}
|
|
2769
|
+
declare global {
|
|
2770
|
+
interface HTMLElementTagNameMap {
|
|
2771
|
+
'arvea-date-picker': ArveaDatePicker;
|
|
2772
|
+
}
|
|
2773
|
+
}
|
|
2774
|
+
|
|
2775
|
+
/**
|
|
2776
|
+
* @element arvea-time-select
|
|
2777
|
+
*
|
|
2778
|
+
* Time-of-day picker made of independent hour/minute/second selects — each
|
|
2779
|
+
* segment opens and closes its own dropdown, rather than one shared popup or
|
|
2780
|
+
* free typing. "HH:mm" (or "HH:mm:ss" with `show-seconds`) 24h strings on the wire.
|
|
2781
|
+
*
|
|
2782
|
+
* @fires arvea-time-change { value }
|
|
2783
|
+
*/
|
|
2784
|
+
declare class ArveaTimeSelect extends LitElement {
|
|
2785
|
+
static styles: lit.CSSResult[];
|
|
2786
|
+
label: string;
|
|
2787
|
+
hideLabel: boolean;
|
|
2788
|
+
value: string;
|
|
2789
|
+
showSeconds: boolean;
|
|
2790
|
+
hourStep: number;
|
|
2791
|
+
minuteStep: number;
|
|
2792
|
+
secondStep: number;
|
|
2793
|
+
min?: string;
|
|
2794
|
+
max?: string;
|
|
2795
|
+
disabled: boolean;
|
|
2796
|
+
required: boolean;
|
|
2797
|
+
invalid: boolean;
|
|
2798
|
+
validationHint: string;
|
|
2799
|
+
private _openSegment;
|
|
2800
|
+
private _flipUp;
|
|
2801
|
+
private _onDocPointer;
|
|
2802
|
+
connectedCallback(): void;
|
|
2803
|
+
disconnectedCallback(): void;
|
|
2804
|
+
private _toggle;
|
|
2805
|
+
private _positionAndScroll;
|
|
2806
|
+
private _current;
|
|
2807
|
+
private _bestCase;
|
|
2808
|
+
private _isDisabled;
|
|
2809
|
+
private _pick;
|
|
2810
|
+
private _emit;
|
|
2811
|
+
private _renderSegment;
|
|
2812
|
+
render(): lit_html.TemplateResult<1>;
|
|
2813
|
+
}
|
|
2814
|
+
declare global {
|
|
2815
|
+
interface HTMLElementTagNameMap {
|
|
2816
|
+
'arvea-time-select': ArveaTimeSelect;
|
|
2817
|
+
}
|
|
2818
|
+
}
|
|
2819
|
+
|
|
2820
|
+
interface ArveaTreeNode {
|
|
2821
|
+
key: string;
|
|
2822
|
+
label: string;
|
|
2823
|
+
children?: ArveaTreeNode[];
|
|
2824
|
+
isLeaf?: boolean;
|
|
2825
|
+
disabled?: boolean;
|
|
2826
|
+
icon?: string;
|
|
2827
|
+
}
|
|
2828
|
+
type ArveaTreeSelection = 'none' | 'single' | 'multiple';
|
|
2829
|
+
interface ArveaTreeProps {
|
|
2830
|
+
nodes?: ArveaTreeNode[];
|
|
2831
|
+
expandedKeys?: string[];
|
|
2832
|
+
selectedKeys?: string[];
|
|
2833
|
+
selectable?: ArveaTreeSelection;
|
|
2834
|
+
checkable?: boolean;
|
|
2835
|
+
loadChildren?: (node: ArveaTreeNode) => Promise<ArveaTreeNode[]>;
|
|
2836
|
+
disabled?: boolean;
|
|
2837
|
+
showLine?: boolean;
|
|
2838
|
+
checkedKeys?: string[];
|
|
2839
|
+
}
|
|
2840
|
+
|
|
2841
|
+
/**
|
|
2842
|
+
* @element arvea-tree
|
|
2843
|
+
*
|
|
2844
|
+
* Collapsible tree with optional checkboxes and async children loading.
|
|
2845
|
+
*
|
|
2846
|
+
* @fires arvea-tree-expand { key, expanded }
|
|
2847
|
+
* @fires arvea-tree-select { selectedKeys, node }
|
|
2848
|
+
* @fires arvea-tree-check { checkedKeys, node }
|
|
2849
|
+
*/
|
|
2850
|
+
declare class ArveaTree extends LitElement {
|
|
2851
|
+
static styles: lit.CSSResult[];
|
|
2852
|
+
nodes: ArveaTreeNode[];
|
|
2853
|
+
expandedKeys: string[];
|
|
2854
|
+
selectedKeys: string[];
|
|
2855
|
+
checkedKeys: string[];
|
|
2856
|
+
selectable: ArveaTreeSelection;
|
|
2857
|
+
checkable: boolean;
|
|
2858
|
+
loadChildren?: (node: ArveaTreeNode) => Promise<ArveaTreeNode[]>;
|
|
2859
|
+
disabled: boolean;
|
|
2860
|
+
showLine: boolean;
|
|
2861
|
+
private _loadingKeys;
|
|
2862
|
+
private _loadedChildren;
|
|
2863
|
+
private _expandedSet;
|
|
2864
|
+
private _selectedSet;
|
|
2865
|
+
private _checkedSet;
|
|
2866
|
+
willUpdate(): void;
|
|
2867
|
+
private _hasChildren;
|
|
2868
|
+
private _childrenOf;
|
|
2869
|
+
private _toggleExpand;
|
|
2870
|
+
private _select;
|
|
2871
|
+
private _flattenChildKeys;
|
|
2872
|
+
private _checkState;
|
|
2873
|
+
private _toggleCheck;
|
|
2874
|
+
private _renderNode;
|
|
2875
|
+
render(): TemplateResult<1>;
|
|
2876
|
+
}
|
|
2877
|
+
declare global {
|
|
2878
|
+
interface HTMLElementTagNameMap {
|
|
2879
|
+
'arvea-tree': ArveaTree;
|
|
2880
|
+
}
|
|
2881
|
+
}
|
|
2882
|
+
|
|
2883
|
+
interface ArveaSidebarItem {
|
|
2884
|
+
id: string;
|
|
2885
|
+
label: string;
|
|
2886
|
+
icon?: string;
|
|
2887
|
+
iconVariant?: 'outline' | 'filled';
|
|
2888
|
+
badge?: string;
|
|
2889
|
+
badgeVariant?: 'new' | 'warning' | 'default';
|
|
2890
|
+
children?: ArveaSidebarItem[];
|
|
2891
|
+
disabled?: boolean;
|
|
2892
|
+
}
|
|
2893
|
+
interface ArveaSidebarSection {
|
|
2894
|
+
title?: string;
|
|
2895
|
+
items: ArveaSidebarItem[];
|
|
2896
|
+
}
|
|
2897
|
+
interface ArveaSidebarProps {
|
|
2898
|
+
logoSrc?: string;
|
|
2899
|
+
title?: string;
|
|
2900
|
+
items?: ArveaSidebarItem[];
|
|
2901
|
+
sections?: ArveaSidebarSection[];
|
|
2902
|
+
}
|
|
2903
|
+
|
|
2904
|
+
/**
|
|
2905
|
+
* @element arvea-sidebar
|
|
2906
|
+
*
|
|
2907
|
+
* @prop {string} logo-src - URL of the logo image shown in the teal header
|
|
2908
|
+
* @prop {string} title - Section title shown above nav items (e.g. "ADMIN")
|
|
2909
|
+
* @prop {ArveaSidebarItem[]} items - Flat array of nav items (each may have children)
|
|
2910
|
+
*
|
|
2911
|
+
* @slot logo - Custom logo content (overrides logo-src)
|
|
2912
|
+
* @slot actions - Right side of the header (e.g. settings icon)
|
|
2913
|
+
* @slot user - User profile card shown below the header, above the nav items (hidden while collapsed)
|
|
2914
|
+
*
|
|
2915
|
+
* @prop {string} active-id - Externally-controlled active item id (syncs highlight + auto-expands its group)
|
|
2916
|
+
*
|
|
2917
|
+
* @fires arvea-sidebar-select - { detail: { item: ArveaSidebarItem } }
|
|
2918
|
+
* @fires arvea-sidebar-toggle - { detail: { collapsed: boolean } }
|
|
2919
|
+
*
|
|
2920
|
+
* @cssprop --sidebar-width - Sidebar width when open (default 300px)
|
|
2921
|
+
* @cssprop --sidebar-width-collapsed - Sidebar width when closed, icons only (default 72px)
|
|
2922
|
+
* @cssprop --sidebar-logo-height - Logo image height (default 28px)
|
|
2923
|
+
* @cssprop --sidebar-logo-max-width - Logo image max-width (default 120px)
|
|
2924
|
+
*/
|
|
2925
|
+
declare class ArveaSidebar extends LitElement {
|
|
2926
|
+
static styles: lit.CSSResult[];
|
|
2927
|
+
logoSrc: string;
|
|
2928
|
+
title: string;
|
|
2929
|
+
items: ArveaSidebarItem[];
|
|
2930
|
+
sections: ArveaSidebarSection[];
|
|
2931
|
+
collapsed: boolean;
|
|
2932
|
+
activeId: string;
|
|
2933
|
+
private _activeId;
|
|
2934
|
+
private _expanded;
|
|
2935
|
+
private _hasLogoSlot;
|
|
2936
|
+
private _hasUserSlot;
|
|
2937
|
+
willUpdate(changed: Map<string, unknown>): void;
|
|
2938
|
+
private _expandGroupContaining;
|
|
2939
|
+
private _toggle;
|
|
2940
|
+
private _toggleCollapsed;
|
|
2941
|
+
private _onNavItemClick;
|
|
2942
|
+
private _select;
|
|
2943
|
+
private _onLogoSlotChange;
|
|
2944
|
+
private _onUserSlotChange;
|
|
2945
|
+
private _renderBadge;
|
|
2946
|
+
private _renderSubItem;
|
|
2947
|
+
private _renderItem;
|
|
2948
|
+
render(): lit_html.TemplateResult<1>;
|
|
2949
|
+
}
|
|
2950
|
+
declare global {
|
|
2951
|
+
interface HTMLElementTagNameMap {
|
|
2952
|
+
'arvea-sidebar': ArveaSidebar;
|
|
2953
|
+
}
|
|
2954
|
+
}
|
|
2955
|
+
|
|
2956
|
+
export { type ArveaDrawerPlacement as $, ArveaAccordion as A, type ArveaCarouselProps as B, ArveaCheckbox as C, ArveaDataTable as D, type ArveaDataTableAlign as E, type ArveaDataTableBadge as F, type ArveaDataTableColumn as G, type ArveaDataTableProps as H, type IconName as I, type ArveaDataTableSort as J, type ArveaDataTableSortDirection as K, ArveaDatePicker as L, type ArveaDatePickerMode as M, type ArveaDatePickerProps as N, type ArveaDatePickerValue as O, type PhoneCountry as P, type ArveaDateRange as Q, ArveaDialog as R, type ArveaDialogProps as S, type ArveaDialogSize as T, ArveaDivider as U, type ArveaDividerAlign as V, type ArveaDividerEmphasis as W, type ArveaDividerOrientation as X, type ArveaDividerProps as Y, type ArveaDividerVariant as Z, ArveaDrawer as _, type IconSize as a, type ArveaSidebarSection as a$, type ArveaDrawerProps as a0, type ArveaDrawerSize as a1, type ArveaDropdownItem as a2, ArveaDropdownMenu as a3, type ArveaDropdownMenuProps as a4, type ArveaDropdownPlacement as a5, ArveaEmptyState as a6, type ArveaEmptyStateProps as a7, type ArveaEmptyStateSize as a8, ArveaFileUpload as a9, type ArveaPopoverProps as aA, type ArveaPopoverTrigger as aB, ArveaProductCard as aC, ArveaProgressBar as aD, type ArveaProgressBarProps as aE, type ArveaProgressSize as aF, ArveaQuantitySelector as aG, type ArveaQuantitySelectorProps as aH, type ArveaQuantitySize as aI, ArveaRadio as aJ, ArveaRating as aK, type ArveaRatingProps as aL, type ArveaRatingSize as aM, ArveaSearchBar as aN, type ArveaSearchBarProps as aO, type ArveaSearchSize as aP, type ArveaSearchSuggestion as aQ, ArveaSegmentedControl as aR, type ArveaSegmentedControlItem as aS, type ArveaSegmentedControlProps as aT, type ArveaSegmentedControlSize as aU, ArveaSelect as aV, type ArveaSelectOption as aW, type ArveaSelectProps as aX, ArveaSidebar as aY, type ArveaSidebarItem as aZ, type ArveaSidebarProps as a_, ArveaFormField as aa, type ArveaFormFieldProps as ab, type ArveaFormFieldStatus as ac, ArveaIcon as ad, ArveaImage as ae, type ArveaImageFit as af, ArveaInput as ag, type ArveaInputProps as ah, type ArveaInputTextAlign as ai, type ArveaInputType as aj, ArveaLightbox as ak, type ArveaLightboxItem as al, type ArveaLightboxProps as am, ArveaMediaCard as an, ArveaOtpInput as ao, type ArveaOtpInputProps as ap, type ArveaOtpType as aq, ArveaPagination as ar, type ArveaPaginationProps as as, type ArveaPaginationSize as at, ArveaPhoneNumber as au, ArveaPopconfirm as av, type ArveaPopconfirmProps as aw, type ArveaPopconfirmVariant as ax, ArveaPopover as ay, type ArveaPopoverPlacement as az, type PhoneLanguage as b, ArveaSkeleton as b0, ArveaSkeletonCard as b1, type ArveaSkeletonCardPreset as b2, type ArveaSkeletonCardProps as b3, type ArveaSkeletonCardVariant as b4, type ArveaSkeletonProps as b5, type ArveaSkeletonShape as b6, ArveaSlider as b7, ArveaSpinner as b8, type ArveaSpinnerProps as b9, type ArveaTooltipPlacement as bA, type ArveaTooltipProps as bB, ArveaTree as bC, type ArveaTreeNode as bD, type ArveaTreeProps as bE, type ArveaTreeSelection as bF, type BadgeVariant as bG, type ButtonVariant as bH, COUNTRIES as bI, type TableColumn as bJ, findCountry as bK, flagUrl as bL, resolveCountry as bM, type ArveaSpinnerSize as ba, ArveaStepper as bb, type ArveaStepperOrientation as bc, type ArveaStepperProps as bd, type ArveaStepperStep as be, type ArveaTabItem as bf, ArveaTable as bg, type ArveaTableProps as bh, type ArveaTableRow as bi, ArveaTabs as bj, type ArveaTabsProps as bk, type ArveaTabsVariant as bl, ArveaTag as bm, type ArveaTagValidator as bn, ArveaTagsInput as bo, type ArveaTagsInputProps as bp, ArveaTextarea as bq, ArveaTimeSelect as br, ArveaToast as bs, ArveaToastContainer as bt, type ArveaToastOptions as bu, type ArveaToastPosition as bv, type ArveaToastProps as bw, type ArveaToastVariant as bx, ArveaToggle as by, ArveaTooltip as bz, ArveaAccordionItem as c, ArveaActionButton as d, type ArveaActionButtonSize as e, ArveaAlert as f, type ArveaAlertProps as g, type ArveaAlertVariant as h, ArveaAvatar as i, type ArveaAvatarProps as j, type ArveaAvatarSize as k, type ArveaAvatarVariant as l, ArveaBadge as m, type ArveaBadgeProps as n, ArveaBreadcrumb as o, type ArveaBreadcrumbItem as p, type ArveaBreadcrumbProps as q, type ArveaBreadcrumbSeparator as r, ArveaButton as s, type ArveaButtonProps as t, type ArveaButtonSize as u, ArveaCard as v, type ArveaCardProps as w, type ArveaCardVariant as x, ArveaCarousel as y, type ArveaCarouselArrowPosition as z };
|