@f-ewald/components 1.0.0 → 1.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -0
- package/custom-elements.json +891 -22
- package/dist/address-autocomplete.d.ts +8 -0
- package/dist/address-autocomplete.d.ts.map +1 -1
- package/dist/address-autocomplete.js +165 -15
- package/dist/address-autocomplete.js.map +1 -1
- package/dist/animate-confetti.d.ts +8 -5
- package/dist/animate-confetti.d.ts.map +1 -1
- package/dist/animate-confetti.js +46 -19
- package/dist/animate-confetti.js.map +1 -1
- package/dist/autocomplete-input.d.ts +8 -0
- package/dist/autocomplete-input.d.ts.map +1 -1
- package/dist/autocomplete-input.js +165 -15
- package/dist/autocomplete-input.js.map +1 -1
- package/dist/calendar-month.d.ts.map +1 -1
- package/dist/calendar-month.js +27 -13
- package/dist/calendar-month.js.map +1 -1
- package/dist/calendar-year.d.ts.map +1 -1
- package/dist/calendar-year.js +11 -2
- package/dist/calendar-year.js.map +1 -1
- package/dist/chat-message.d.ts.map +1 -1
- package/dist/chat-message.js +77 -24
- package/dist/chat-message.js.map +1 -1
- package/dist/confirm-dialog.d.ts +8 -1
- package/dist/confirm-dialog.d.ts.map +1 -1
- package/dist/confirm-dialog.js +130 -18
- package/dist/confirm-dialog.js.map +1 -1
- package/dist/copy-link-button.d.ts +2 -0
- package/dist/copy-link-button.d.ts.map +1 -1
- package/dist/copy-link-button.js +35 -3
- package/dist/copy-link-button.js.map +1 -1
- package/dist/data-table.d.ts +2 -0
- package/dist/data-table.d.ts.map +1 -1
- package/dist/data-table.js +83 -11
- package/dist/data-table.js.map +1 -1
- package/dist/distance-value.d.ts +0 -1
- package/dist/distance-value.d.ts.map +1 -1
- package/dist/distance-value.js +3 -8
- package/dist/distance-value.js.map +1 -1
- package/dist/distribution-chart.d.ts.map +1 -1
- package/dist/distribution-chart.js +54 -17
- package/dist/distribution-chart.js.map +1 -1
- package/dist/dropdown-button.d.ts.map +1 -1
- package/dist/dropdown-button.js +60 -11
- package/dist/dropdown-button.js.map +1 -1
- package/dist/editable-text.d.ts.map +1 -1
- package/dist/editable-text.js +46 -13
- package/dist/editable-text.js.map +1 -1
- package/dist/form-select.d.ts.map +1 -1
- package/dist/form-select.js +70 -22
- package/dist/form-select.js.map +1 -1
- package/dist/frame-box.d.ts.map +1 -1
- package/dist/frame-box.js +20 -12
- package/dist/frame-box.js.map +1 -1
- package/dist/icon-button.d.ts.map +1 -1
- package/dist/icon-button.js +11 -0
- package/dist/icon-button.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/kbd-hint.d.ts +30 -0
- package/dist/kbd-hint.d.ts.map +1 -0
- package/dist/kbd-hint.js +184 -0
- package/dist/kbd-hint.js.map +1 -0
- package/dist/live-timer.d.ts +0 -1
- package/dist/live-timer.d.ts.map +1 -1
- package/dist/live-timer.js +1 -6
- package/dist/live-timer.js.map +1 -1
- package/dist/map-circle.d.ts.map +1 -1
- package/dist/map-circle.js +16 -1
- package/dist/map-circle.js.map +1 -1
- package/dist/map-pin.d.ts.map +1 -1
- package/dist/map-pin.js +16 -1
- package/dist/map-pin.js.map +1 -1
- package/dist/percent-bar-chart.d.ts +3 -0
- package/dist/percent-bar-chart.d.ts.map +1 -1
- package/dist/percent-bar-chart.js +60 -4
- package/dist/percent-bar-chart.js.map +1 -1
- package/dist/photo-gallery.d.ts.map +1 -1
- package/dist/photo-gallery.js +12 -3
- package/dist/photo-gallery.js.map +1 -1
- package/dist/popover-panel.d.ts.map +1 -1
- package/dist/popover-panel.js +132 -23
- package/dist/popover-panel.js.map +1 -1
- package/dist/price-history-chart.d.ts.map +1 -1
- package/dist/price-history-chart.js +52 -18
- package/dist/price-history-chart.js.map +1 -1
- package/dist/radio-cards.d.ts +2 -0
- package/dist/radio-cards.d.ts.map +1 -1
- package/dist/radio-cards.js +51 -5
- package/dist/radio-cards.js.map +1 -1
- package/dist/radio-pills.d.ts +2 -0
- package/dist/radio-pills.d.ts.map +1 -1
- package/dist/radio-pills.js +46 -4
- package/dist/radio-pills.js.map +1 -1
- package/dist/relative-time.d.ts +0 -1
- package/dist/relative-time.d.ts.map +1 -1
- package/dist/relative-time.js +1 -6
- package/dist/relative-time.js.map +1 -1
- package/dist/reveal-button.d.ts +2 -0
- package/dist/reveal-button.d.ts.map +1 -1
- package/dist/reveal-button.js +42 -5
- package/dist/reveal-button.js.map +1 -1
- package/dist/roman-numeral.js +1 -1
- package/dist/roman-numeral.js.map +1 -1
- package/dist/slide-panel.d.ts +7 -3
- package/dist/slide-panel.d.ts.map +1 -1
- package/dist/slide-panel.js +95 -23
- package/dist/slide-panel.js.map +1 -1
- package/dist/stat-meter.d.ts.map +1 -1
- package/dist/stat-meter.js +17 -7
- package/dist/stat-meter.js.map +1 -1
- package/dist/status-pill.d.ts.map +1 -1
- package/dist/status-pill.js +26 -12
- package/dist/status-pill.js.map +1 -1
- package/dist/tile-grid.d.ts +8 -0
- package/dist/tile-grid.d.ts.map +1 -1
- package/dist/tile-grid.js +88 -12
- package/dist/tile-grid.js.map +1 -1
- package/dist/toast-notification.d.ts.map +1 -1
- package/dist/toast-notification.js +40 -11
- package/dist/toast-notification.js.map +1 -1
- package/dist/tokens.css +19 -0
- package/dist/tokens.d.ts.map +1 -1
- package/dist/tokens.js +13 -0
- package/dist/tokens.js.map +1 -1
- package/dist/ui-button.d.ts +2 -0
- package/dist/ui-button.d.ts.map +1 -1
- package/dist/ui-button.js +58 -9
- package/dist/ui-button.js.map +1 -1
- package/dist/user-avatar.d.ts.map +1 -1
- package/dist/user-avatar.js +18 -3
- package/dist/user-avatar.js.map +1 -1
- package/dist/utils/form.d.ts +3 -0
- package/dist/utils/form.d.ts.map +1 -0
- package/dist/utils/form.js +14 -0
- package/dist/utils/form.js.map +1 -0
- package/dist/utils/layer-stack.d.ts +9 -0
- package/dist/utils/layer-stack.d.ts.map +1 -0
- package/dist/utils/layer-stack.js +35 -0
- package/dist/utils/layer-stack.js.map +1 -0
- package/dist/weight-bar-chart.d.ts.map +1 -1
- package/dist/weight-bar-chart.js +27 -8
- package/dist/weight-bar-chart.js.map +1 -1
- package/docs/address-autocomplete.md +5 -0
- package/docs/autocomplete-input.md +5 -0
- package/docs/calendar-month.md +2 -0
- package/docs/chat-message.md +4 -0
- package/docs/confirm-dialog.md +2 -0
- package/docs/copy-link-button.md +2 -0
- package/docs/data-table.md +2 -0
- package/docs/design-language.md +149 -0
- package/docs/distribution-chart.md +4 -0
- package/docs/dropdown-button.md +1 -0
- package/docs/frame-box.md +2 -0
- package/docs/kbd-hint.md +42 -0
- package/docs/percent-bar-chart.md +4 -1
- package/docs/photo-gallery.md +1 -0
- package/docs/popover-panel.md +2 -0
- package/docs/price-history-chart.md +8 -1
- package/docs/radio-cards.md +2 -0
- package/docs/radio-pills.md +2 -0
- package/docs/reveal-button.md +3 -0
- package/docs/slide-panel.md +4 -2
- package/docs/status-pill.md +3 -0
- package/docs/tile-grid.md +10 -1
- package/docs/toast-notification.md +4 -1
- package/docs/ui-button.md +2 -0
- package/docs/user-avatar.md +1 -0
- package/llms.txt +59 -34
- package/package.json +5 -1
package/llms.txt
CHANGED
|
@@ -33,9 +33,9 @@ Supports two suggestion sources:
|
|
|
33
33
|
|
|
34
34
|
Import: `import "@f-ewald/components/address-autocomplete.js";`
|
|
35
35
|
|
|
36
|
-
Properties: `value` (attribute `value`) : string, default ""; `placeholder` (attribute `placeholder`) : string, default ""; `required` (attribute `required`) : boolean, default false; `types` (attribute `types`) : string, default "address"; `endpoint` (attribute `endpoint`) : string, default "https://api.mapbox.com/search/geocode/v6/forward"; `accessToken` (attribute `access-token`) : string, default ""; `bbox` (attribute `bbox`) : string, default ""; `proximity` (attribute `proximity`) : string, default ""; `debounce` (attribute `debounce`) : number, default 300; `minLength` (attribute `min-length`) : number, default 3; `suggestions` (JS property only) : AddressSuggestion[] | null, default null; `selectedSuggestion` (JS property only) : AddressSuggestion | null, default —
|
|
36
|
+
Properties: `value` (attribute `value`) : string, default ""; `placeholder` (attribute `placeholder`) : string, default ""; `required` (attribute `required`) : boolean, default false; `disabled` (attribute `disabled`) : boolean, default false; `types` (attribute `types`) : string, default "address"; `endpoint` (attribute `endpoint`) : string, default "https://api.mapbox.com/search/geocode/v6/forward"; `accessToken` (attribute `access-token`) : string, default ""; `bbox` (attribute `bbox`) : string, default ""; `proximity` (attribute `proximity`) : string, default ""; `debounce` (attribute `debounce`) : number, default 300; `minLength` (attribute `min-length`) : number, default 3; `suggestions` (JS property only) : AddressSuggestion[] | null, default null; `selectedSuggestion` (JS property only) : AddressSuggestion | null, default —
|
|
37
37
|
Events: `address-select`
|
|
38
|
-
CSS custom properties: `--ui-border`, `--ui-font`, `--ui-font-size-sm`, `--ui-radius-sm`, `--ui-shadow`, `--ui-surface`, `--ui-surface-muted`
|
|
38
|
+
CSS custom properties: `--ui-border`, `--ui-focus-ring`, `--ui-font`, `--ui-font-size-sm`, `--ui-primary`, `--ui-radius-sm`, `--ui-shadow`, `--ui-surface`, `--ui-surface-muted`, `--ui-text`, `--ui-text-muted`
|
|
39
39
|
|
|
40
40
|
Example:
|
|
41
41
|
```html
|
|
@@ -83,9 +83,9 @@ Supports two suggestion sources:
|
|
|
83
83
|
|
|
84
84
|
Import: `import "@f-ewald/components/autocomplete-input.js";`
|
|
85
85
|
|
|
86
|
-
Properties: `value` (attribute `value`) : string, default ""; `placeholder` (attribute `placeholder`) : string, default ""; `required` (attribute `required`) : boolean, default false; `endpoint` (attribute `endpoint`) : string, default ""; `queryParam` (attribute `query-param`) : string, default "q"; `debounce` (attribute `debounce`) : number, default 300; `minLength` (attribute `min-length`) : number, default 3; `options` (JS property only) : AutocompleteOption[] | null, default null; `selectedOption` (JS property only) : AutocompleteOption | null, default —
|
|
86
|
+
Properties: `value` (attribute `value`) : string, default ""; `placeholder` (attribute `placeholder`) : string, default ""; `required` (attribute `required`) : boolean, default false; `disabled` (attribute `disabled`) : boolean, default false; `endpoint` (attribute `endpoint`) : string, default ""; `queryParam` (attribute `query-param`) : string, default "q"; `debounce` (attribute `debounce`) : number, default 300; `minLength` (attribute `min-length`) : number, default 3; `options` (JS property only) : AutocompleteOption[] | null, default null; `selectedOption` (JS property only) : AutocompleteOption | null, default —
|
|
87
87
|
Events: `option-select`
|
|
88
|
-
CSS custom properties: `--ui-border`, `--ui-font`, `--ui-font-size-sm`, `--ui-radius-sm`, `--ui-shadow`, `--ui-surface`, `--ui-surface-muted`
|
|
88
|
+
CSS custom properties: `--ui-border`, `--ui-focus-ring`, `--ui-font`, `--ui-font-size-sm`, `--ui-primary`, `--ui-radius-sm`, `--ui-shadow`, `--ui-surface`, `--ui-surface-muted`, `--ui-text`, `--ui-text-muted`
|
|
89
89
|
|
|
90
90
|
Example:
|
|
91
91
|
```html
|
|
@@ -153,7 +153,7 @@ Import: `import "@f-ewald/components/calendar-month.js";`
|
|
|
153
153
|
|
|
154
154
|
Properties: `year` (attribute `year`) : number, default —; `month` (attribute `month`) : number, default 1
|
|
155
155
|
Events: none
|
|
156
|
-
CSS custom properties: `--ui-border`, `--ui-danger`, `--ui-focus-ring`, `--ui-font`, `--ui-font-size`, `--ui-font-size-sm`, `--ui-font-size-xs`, `--ui-hover-overlay`, `--ui-primary`, `--ui-radius-sm`, `--ui-success`, `--ui-surface`, `--ui-surface-muted`, `--ui-text`, `--ui-text-muted`
|
|
156
|
+
CSS custom properties: `--ui-border`, `--ui-danger`, `--ui-focus-ring`, `--ui-font`, `--ui-font-size`, `--ui-font-size-sm`, `--ui-font-size-xs`, `--ui-hover-overlay`, `--ui-info`, `--ui-primary`, `--ui-radius-sm`, `--ui-success`, `--ui-surface`, `--ui-surface-muted`, `--ui-text`, `--ui-text-muted`, `--ui-warning`
|
|
157
157
|
|
|
158
158
|
Example:
|
|
159
159
|
```html
|
|
@@ -213,7 +213,7 @@ Import: `import "@f-ewald/components/chat-message.js";`
|
|
|
213
213
|
|
|
214
214
|
Properties: `role` (attribute `role`) : ChatMessageRole, default "agent"; `variant` (attribute `variant`) : ChatMessageVariant, default "normal"; `author` (attribute `author`) : string, default ""; `timestamp` (attribute `timestamp`) : string | null, default null; `summary` (attribute `summary`) : string, default ""; `collapsible` (attribute `collapsible`) : boolean, default false; `collapsed` (attribute `collapsed`) : boolean, default false
|
|
215
215
|
Events: `toggle`
|
|
216
|
-
CSS custom properties: `--ui-border`, `--ui-font`, `--ui-font-size`, `--ui-primary`, `--ui-radius`, `--ui-surface`, `--ui-text`, `--ui-text-muted`
|
|
216
|
+
CSS custom properties: `--ui-border`, `--ui-focus-ring`, `--ui-font`, `--ui-font-mono`, `--ui-font-size`, `--ui-font-size-sm`, `--ui-primary`, `--ui-radius`, `--ui-radius-sm`, `--ui-surface`, `--ui-text`, `--ui-text-muted`
|
|
217
217
|
|
|
218
218
|
Example:
|
|
219
219
|
```html
|
|
@@ -238,7 +238,7 @@ Import: `import "@f-ewald/components/confirm-dialog.js";`
|
|
|
238
238
|
|
|
239
239
|
Properties: `open` (attribute `open`) : boolean, default false; `confirmLabel` (attribute `confirm-label`) : string, default "Delete"; `cancelLabel` (attribute `cancel-label`) : string, default "Cancel"; `danger` (attribute `danger`) : boolean, default true; `busy` (attribute `busy`) : boolean, default false; `error` (attribute `error`) : string | null, default null
|
|
240
240
|
Events: `confirm`, `cancel`
|
|
241
|
-
CSS custom properties: `--ui-border`, `--ui-danger`, `--ui-danger-hover`, `--ui-font`, `--ui-font-size`, `--ui-font-size-sm`, `--ui-overlay`, `--ui-primary`, `--ui-primary-hover`, `--ui-radius`, `--ui-radius-sm`, `--ui-shadow-lg`, `--ui-surface`, `--ui-text`, `--ui-text-muted`
|
|
241
|
+
CSS custom properties: `--ui-border`, `--ui-danger`, `--ui-danger-hover`, `--ui-focus-ring`, `--ui-font`, `--ui-font-size`, `--ui-font-size-sm`, `--ui-on-accent`, `--ui-overlay`, `--ui-primary`, `--ui-primary-hover`, `--ui-radius`, `--ui-radius-sm`, `--ui-shadow-lg`, `--ui-surface`, `--ui-text`, `--ui-text-muted`
|
|
242
242
|
|
|
243
243
|
Example:
|
|
244
244
|
```html
|
|
@@ -257,9 +257,9 @@ without a toast element can react. Defaults to the current page URL if
|
|
|
257
257
|
|
|
258
258
|
Import: `import "@f-ewald/components/copy-link-button.js";`
|
|
259
259
|
|
|
260
|
-
Properties: `value` (attribute `value`) : string, default ""; `label` (attribute `label`) : string, default "Copy link"
|
|
260
|
+
Properties: `value` (attribute `value`) : string, default ""; `label` (attribute `label`) : string, default "Copy link"; `disabled` (attribute `disabled`) : boolean, default false
|
|
261
261
|
Events: `copy-success`, `copy-error`
|
|
262
|
-
CSS custom properties: `--ui-radius-sm`, `--ui-surface-muted`, `--ui-text`, `--ui-text-muted`
|
|
262
|
+
CSS custom properties: `--ui-focus-ring`, `--ui-radius-sm`, `--ui-surface-muted`, `--ui-text`, `--ui-text-muted`
|
|
263
263
|
|
|
264
264
|
Example:
|
|
265
265
|
```html
|
|
@@ -279,9 +279,9 @@ cell's rendered content might contain.
|
|
|
279
279
|
|
|
280
280
|
Import: `import "@f-ewald/components/data-table.js";`
|
|
281
281
|
|
|
282
|
-
Properties: `columns` (JS property only) : DataTableColumn[], default []; `rows` (JS property only) : unknown[], default []; `rowKey` (JS property only) : (row: unknown, index: number) => string | number, default —; `renderCell` (JS property only) : (row: unknown, key: string) => unknown, default —; `rowHref` (JS property only) : ((row: unknown) => string | null) | null, default null
|
|
282
|
+
Properties: `columns` (JS property only) : DataTableColumn[], default []; `rows` (JS property only) : unknown[], default []; `rowKey` (JS property only) : (row: unknown, index: number) => string | number, default —; `renderCell` (JS property only) : (row: unknown, key: string) => unknown, default —; `rowHref` (JS property only) : ((row: unknown) => string | null) | null, default null; `rowLabel` (JS property only) : ((row: unknown) => string) | null, default null
|
|
283
283
|
Events: none
|
|
284
|
-
CSS custom properties: `--ui-border`, `--ui-font`, `--ui-font-size-sm`, `--ui-surface-muted`, `--ui-text`, `--ui-text-muted`
|
|
284
|
+
CSS custom properties: `--ui-border`, `--ui-focus-ring`, `--ui-font`, `--ui-font-size-sm`, `--ui-surface-muted`, `--ui-text`, `--ui-text-muted`
|
|
285
285
|
|
|
286
286
|
Example:
|
|
287
287
|
```html
|
|
@@ -334,7 +334,7 @@ Import: `import "@f-ewald/components/distribution-chart.js";`
|
|
|
334
334
|
|
|
335
335
|
Properties: `metric` (attribute `metric`) : string, default ""; `values` (JS property only) : DistributionValue[], default []; `markerColors` (JS property only) : string[], default ["#4f46e5", "#d97706", "#0d9488", "#e11d48"]; `fontSize` (attribute `font-size`) : number, default 11
|
|
336
336
|
Events: none
|
|
337
|
-
CSS custom properties: `--ui-danger`, `--ui-font-size-sm`, `--ui-radius-sm`, `--ui-text-muted`
|
|
337
|
+
CSS custom properties: `--ui-border`, `--ui-danger`, `--ui-font`, `--ui-font-size-sm`, `--ui-primary`, `--ui-radius-sm`, `--ui-surface-muted`, `--ui-text-muted`
|
|
338
338
|
|
|
339
339
|
Example:
|
|
340
340
|
```html
|
|
@@ -355,7 +355,7 @@ Import: `import "@f-ewald/components/dropdown-button.js";`
|
|
|
355
355
|
|
|
356
356
|
Properties: `label` (attribute `label`) : string, default ""; `options` (JS property only) : DropdownOption[], default []; `disabled` (attribute `disabled`) : boolean, default false
|
|
357
357
|
Events: `select`
|
|
358
|
-
CSS custom properties: `--ui-border`, `--ui-focus-ring`, `--ui-font`, `--ui-font-size-sm`, `--ui-primary`, `--ui-primary-hover`, `--ui-radius-sm`, `--ui-shadow`, `--ui-surface`, `--ui-surface-muted`, `--ui-text`
|
|
358
|
+
CSS custom properties: `--ui-border`, `--ui-focus-ring`, `--ui-font`, `--ui-font-size-sm`, `--ui-on-accent`, `--ui-primary`, `--ui-primary-hover`, `--ui-radius-sm`, `--ui-shadow`, `--ui-surface`, `--ui-surface-muted`, `--ui-text`
|
|
359
359
|
|
|
360
360
|
Example:
|
|
361
361
|
```html
|
|
@@ -447,7 +447,7 @@ Import: `import "@f-ewald/components/frame-box.js";`
|
|
|
447
447
|
|
|
448
448
|
Properties: `label` (attribute `label`) : string, default ""
|
|
449
449
|
Events: none
|
|
450
|
-
CSS custom properties: `--ui-border`, `--ui-radius-sm`, `--ui-surface`, `--ui-text-muted`
|
|
450
|
+
CSS custom properties: `--ui-border`, `--ui-font`, `--ui-font-size-xs`, `--ui-radius-sm`, `--ui-surface`, `--ui-text-muted`
|
|
451
451
|
|
|
452
452
|
Example:
|
|
453
453
|
```html
|
|
@@ -522,6 +522,25 @@ Example:
|
|
|
522
522
|
</script>
|
|
523
523
|
```
|
|
524
524
|
|
|
525
|
+
## <kbd-hint>
|
|
526
|
+
|
|
527
|
+
Renders a keyboard shortcut as one boxed keycap per `+`-separated token.
|
|
528
|
+
Modifier keys are platform-aware: `Mod` becomes Command on macOS and
|
|
529
|
+
Control elsewhere. Keycaps derive their presentation from `currentColor`,
|
|
530
|
+
so the hint works inside neutral and accent-colored controls.
|
|
531
|
+
|
|
532
|
+
Import: `import "@f-ewald/components/kbd-hint.js";`
|
|
533
|
+
|
|
534
|
+
Properties: `keys` (attribute `keys`) : string, default ""; `platform` (attribute `platform`) : KbdPlatform, default "auto"
|
|
535
|
+
Events: none
|
|
536
|
+
CSS custom properties: `--ui-font-mono`, `--ui-font-size-xs`, `--ui-radius-sm`
|
|
537
|
+
|
|
538
|
+
Example:
|
|
539
|
+
```html
|
|
540
|
+
<kbd-hint keys="Mod+K"></kbd-hint>
|
|
541
|
+
<kbd-hint keys="Mod+Shift+Enter" platform="mac"></kbd-hint>
|
|
542
|
+
```
|
|
543
|
+
|
|
525
544
|
## <live-timer>
|
|
526
545
|
|
|
527
546
|
Per-second ticking count-up timer, e.g. a live "running for 12s" or
|
|
@@ -592,7 +611,7 @@ Import: `import "@f-ewald/components/percent-bar-chart.js";`
|
|
|
592
611
|
|
|
593
612
|
Properties: `groups` (JS property only) : PercentBarGroup[], default []
|
|
594
613
|
Events: none
|
|
595
|
-
CSS custom properties:
|
|
614
|
+
CSS custom properties: `--ui-font`, `--ui-text-muted`
|
|
596
615
|
|
|
597
616
|
Example:
|
|
598
617
|
```html
|
|
@@ -614,7 +633,7 @@ Import: `import "@f-ewald/components/photo-gallery.js";`
|
|
|
614
633
|
|
|
615
634
|
Properties: `currentIndex` (attribute `current-index`) : number, default 0; `delay` (attribute `delay`) : number, default 0; `showControls` (attribute `show-controls`) : boolean, default true; `showCounter` (attribute `show-counter`) : boolean, default false; `showIndicators` (attribute `show-indicators`) : boolean, default false; `showAutoplayControl` (attribute `show-autoplay-control`) : boolean, default true; `paused` (attribute `paused`) : boolean, default false; `aspectRatio` (attribute `aspect-ratio`) : string, default "16 / 9"; `objectFit` (attribute `object-fit`) : PhotoGalleryObjectFit, default "cover"
|
|
616
635
|
Events: `slide-change`
|
|
617
|
-
CSS custom properties: `--ui-border`, `--ui-focus-ring`, `--ui-font`, `--ui-font-size`, `--ui-font-size-sm`, `--ui-overlay`, `--ui-primary`, `--ui-radius`, `--ui-radius-sm`, `--ui-surface`, `--ui-surface-muted`, `--ui-text`, `--ui-text-muted`
|
|
636
|
+
CSS custom properties: `--ui-border`, `--ui-focus-ring`, `--ui-font`, `--ui-font-size`, `--ui-font-size-sm`, `--ui-on-accent`, `--ui-overlay`, `--ui-primary`, `--ui-radius`, `--ui-radius-sm`, `--ui-surface`, `--ui-surface-muted`, `--ui-text`, `--ui-text-muted`
|
|
618
637
|
|
|
619
638
|
Example:
|
|
620
639
|
```html
|
|
@@ -654,7 +673,7 @@ Import: `import "@f-ewald/components/popover-panel.js";`
|
|
|
654
673
|
|
|
655
674
|
Properties: `open` (attribute `open`) : boolean, default false; `heading` (attribute `heading`) : string, default ""; `centered` (attribute `centered`) : boolean, default false
|
|
656
675
|
Events: `panel-close`
|
|
657
|
-
CSS custom properties: `--ui-border`, `--ui-font`, `--ui-font-size`, `--ui-radius`, `--ui-radius-sm`, `--ui-shadow-lg`, `--ui-surface`, `--ui-surface-muted`, `--ui-text`, `--ui-text-muted`
|
|
676
|
+
CSS custom properties: `--ui-border`, `--ui-focus-ring`, `--ui-font`, `--ui-font-size`, `--ui-overlay`, `--ui-radius`, `--ui-radius-sm`, `--ui-shadow-lg`, `--ui-surface`, `--ui-surface-muted`, `--ui-text`, `--ui-text-muted`
|
|
658
677
|
|
|
659
678
|
Example:
|
|
660
679
|
```html
|
|
@@ -682,7 +701,7 @@ Import: `import "@f-ewald/components/price-history-chart.js";`
|
|
|
682
701
|
|
|
683
702
|
Properties: `history` (attribute `history`) : PricePoint[], default []; `yLabels` (attribute `y-labels`) : "auto" | "always" | "never", default "auto"; `maxXLabels` (attribute `max-x-labels`) : number, default 3
|
|
684
703
|
Events: none
|
|
685
|
-
CSS custom properties:
|
|
704
|
+
CSS custom properties: `--ui-border`, `--ui-font`, `--ui-on-accent`, `--ui-primary`, `--ui-text-muted`, `--ui-tooltip`
|
|
686
705
|
|
|
687
706
|
Example:
|
|
688
707
|
```html
|
|
@@ -705,9 +724,9 @@ keyboard/a11y and fires `change` rather than relying on form submission.
|
|
|
705
724
|
|
|
706
725
|
Import: `import "@f-ewald/components/radio-cards.js";`
|
|
707
726
|
|
|
708
|
-
Properties: `options` (JS property only) : RadioCardOption[], default []; `value` (attribute `value`) : string, default ""
|
|
727
|
+
Properties: `options` (JS property only) : RadioCardOption[], default []; `value` (attribute `value`) : string, default ""; `disabled` (attribute `disabled`) : boolean, default false
|
|
709
728
|
Events: `change`
|
|
710
|
-
CSS custom properties: `--ui-border`, `--ui-font`, `--ui-font-size-sm`, `--ui-primary`, `--ui-radius-sm`, `--ui-surface-muted`, `--ui-text`, `--ui-text-muted`
|
|
729
|
+
CSS custom properties: `--ui-border`, `--ui-focus-ring`, `--ui-font`, `--ui-font-size-sm`, `--ui-primary`, `--ui-radius-sm`, `--ui-surface-muted`, `--ui-text`, `--ui-text-muted`
|
|
711
730
|
|
|
712
731
|
Example:
|
|
713
732
|
```html
|
|
@@ -733,9 +752,9 @@ relying on form submission.
|
|
|
733
752
|
|
|
734
753
|
Import: `import "@f-ewald/components/radio-pills.js";`
|
|
735
754
|
|
|
736
|
-
Properties: `options` (JS property only) : RadioPillOption[], default []; `value` (attribute `value`) : string, default ""
|
|
755
|
+
Properties: `options` (JS property only) : RadioPillOption[], default []; `value` (attribute `value`) : string, default ""; `disabled` (attribute `disabled`) : boolean, default false
|
|
737
756
|
Events: `change`
|
|
738
|
-
CSS custom properties: `--ui-border`, `--ui-font`, `--ui-font-size-sm`, `--ui-primary`, `--ui-surface-muted`, `--ui-text`
|
|
757
|
+
CSS custom properties: `--ui-border`, `--ui-focus-ring`, `--ui-font`, `--ui-font-size-sm`, `--ui-primary`, `--ui-surface-muted`, `--ui-text`
|
|
739
758
|
|
|
740
759
|
Example:
|
|
741
760
|
```html
|
|
@@ -776,9 +795,9 @@ Button that reveals hidden slotted content when clicked.
|
|
|
776
795
|
|
|
777
796
|
Import: `import "@f-ewald/components/reveal-button.js";`
|
|
778
797
|
|
|
779
|
-
Properties: `label` (attribute `label`) : string, default "Reveal hidden content"
|
|
798
|
+
Properties: `label` (attribute `label`) : string, default "Reveal hidden content"; `disabled` (attribute `disabled`) : boolean, default false
|
|
780
799
|
Events: none
|
|
781
|
-
CSS custom properties: `--ui-font`, `--ui-font-size`, `--ui-primary`, `--ui-primary-hover`, `--ui-radius-sm`
|
|
800
|
+
CSS custom properties: `--ui-focus-ring`, `--ui-font`, `--ui-font-size`, `--ui-on-accent`, `--ui-primary`, `--ui-primary-hover`, `--ui-radius-sm`
|
|
782
801
|
|
|
783
802
|
Example:
|
|
784
803
|
```html
|
|
@@ -808,14 +827,14 @@ Generic sliding panel shell. Handles positioning, open/close animation,
|
|
|
808
827
|
header chrome, and a close button. Body content is provided via the
|
|
809
828
|
default slot; the consumer controls its own padding and overflow.
|
|
810
829
|
|
|
811
|
-
Desktop:
|
|
812
|
-
Mobile (≤
|
|
830
|
+
Desktop: fixed right-side panel that slides from the right.
|
|
831
|
+
Mobile (≤48rem): bottom-sheet drawer (60vh) — reserved for future use.
|
|
813
832
|
|
|
814
833
|
Import: `import "@f-ewald/components/slide-panel.js";`
|
|
815
834
|
|
|
816
835
|
Properties: `open` (attribute `open`) : boolean, default false; `heading` (attribute `heading`) : string, default ""
|
|
817
836
|
Events: `panel-close`
|
|
818
|
-
CSS custom properties: `--ui-border`, `--ui-font`, `--ui-font-size`, `--ui-radius-sm`, `--ui-shadow-lg`, `--ui-surface`, `--ui-surface-muted`, `--ui-text`, `--ui-text-muted`
|
|
837
|
+
CSS custom properties: `--ui-border`, `--ui-focus-ring`, `--ui-font`, `--ui-font-size`, `--ui-radius`, `--ui-radius-sm`, `--ui-shadow-lg`, `--ui-surface`, `--ui-surface-muted`, `--ui-text`, `--ui-text-muted`
|
|
819
838
|
|
|
820
839
|
Example:
|
|
821
840
|
```html
|
|
@@ -854,7 +873,7 @@ Import: `import "@f-ewald/components/status-pill.js";`
|
|
|
854
873
|
|
|
855
874
|
Properties: `label` (attribute `label`) : string, default ""; `color` (attribute `color`) : StatusPillColor, default "neutral"; `spinner` (attribute `spinner`) : boolean, default false
|
|
856
875
|
Events: none
|
|
857
|
-
CSS custom properties: `--ui-danger`, `--ui-font`, `--ui-primary`, `--ui-success`, `--ui-text-muted`
|
|
876
|
+
CSS custom properties: `--ui-danger`, `--ui-font`, `--ui-font-size-sm`, `--ui-info`, `--ui-primary`, `--ui-success`, `--ui-text-muted`, `--ui-warning`
|
|
858
877
|
|
|
859
878
|
Example:
|
|
860
879
|
```html
|
|
@@ -873,15 +892,21 @@ Optional `itemHref` makes whole tiles clickable (navigating via
|
|
|
873
892
|
`location.hash`), without hijacking clicks on nested interactive elements
|
|
874
893
|
(links/buttons) a tile's rendered content might contain.
|
|
875
894
|
|
|
895
|
+
Optional `fileIcon` prefixes each tile with a decorative Heroicons
|
|
896
|
+
"document" glyph, for grids whose items represent files — the icon never
|
|
897
|
+
carries its own accessible name since the rendered tile content (e.g. a
|
|
898
|
+
filename) already identifies the item. Off by default, so it consumes no
|
|
899
|
+
layout space or markup for grids of non-file items.
|
|
900
|
+
|
|
876
901
|
Import: `import "@f-ewald/components/tile-grid.js";`
|
|
877
902
|
|
|
878
|
-
Properties: `items` (JS property only) : unknown[], default []; `itemKey` (JS property only) : (item: unknown, index: number) => string | number, default —; `renderTile` (JS property only) : (item: unknown) => unknown, default —; `itemHref` (JS property only) : ((item: unknown) => string | null) | null, default null
|
|
903
|
+
Properties: `items` (JS property only) : unknown[], default []; `itemKey` (JS property only) : (item: unknown, index: number) => string | number, default —; `renderTile` (JS property only) : (item: unknown) => unknown, default —; `itemHref` (JS property only) : ((item: unknown) => string | null) | null, default null; `fileIcon` (attribute `file-icon`) : boolean, default false
|
|
879
904
|
Events: none
|
|
880
|
-
CSS custom properties: `--ui-border`, `--ui-font`, `--ui-font-size-sm`, `--ui-radius`, `--ui-surface-muted`, `--ui-text`
|
|
905
|
+
CSS custom properties: `--ui-border`, `--ui-focus-ring`, `--ui-font`, `--ui-font-size-sm`, `--ui-radius`, `--ui-surface-muted`, `--ui-text`, `--ui-text-muted`
|
|
881
906
|
|
|
882
907
|
Example:
|
|
883
908
|
```html
|
|
884
|
-
<tile-grid></tile-grid>
|
|
909
|
+
<tile-grid file-icon></tile-grid>
|
|
885
910
|
<script type="module">
|
|
886
911
|
const grid = document.querySelector("tile-grid");
|
|
887
912
|
grid.items = [
|
|
@@ -907,7 +932,7 @@ Import: `import "@f-ewald/components/toast-notification.js";`
|
|
|
907
932
|
|
|
908
933
|
Properties: none
|
|
909
934
|
Events: none
|
|
910
|
-
CSS custom properties: `--ui-danger`, `--ui-font`, `--ui-font-size`, `--ui-
|
|
935
|
+
CSS custom properties: `--ui-danger`, `--ui-focus-ring`, `--ui-font`, `--ui-font-size`, `--ui-hover-overlay`, `--ui-info`, `--ui-on-accent`, `--ui-radius`, `--ui-radius-sm`, `--ui-shadow-lg`, `--ui-success`, `--ui-text`
|
|
911
936
|
|
|
912
937
|
Example:
|
|
913
938
|
```html
|
|
@@ -937,7 +962,7 @@ Import: `import "@f-ewald/components/ui-button.js";`
|
|
|
937
962
|
|
|
938
963
|
Properties: `variant` (attribute `variant`) : ButtonVariant, default "primary"; `href` (attribute `href`) : string | null, default null; `type` (attribute `type`) : "button" | "submit" | "reset", default "button"; `disabled` (attribute `disabled`) : boolean, default false; `busy` (attribute `busy`) : boolean, default false
|
|
939
964
|
Events: none
|
|
940
|
-
CSS custom properties: `--ui-border`, `--ui-danger`, `--ui-danger-hover`, `--ui-font`, `--ui-font-size-sm`, `--ui-primary`, `--ui-primary-hover`, `--ui-radius-sm`, `--ui-text`, `--ui-text-muted`
|
|
965
|
+
CSS custom properties: `--ui-border`, `--ui-danger`, `--ui-danger-hover`, `--ui-focus-ring`, `--ui-font`, `--ui-font-size-sm`, `--ui-on-accent`, `--ui-primary`, `--ui-primary-hover`, `--ui-radius-sm`, `--ui-text`, `--ui-text-muted`
|
|
941
966
|
|
|
942
967
|
Example:
|
|
943
968
|
```html
|
|
@@ -961,7 +986,7 @@ Import: `import "@f-ewald/components/user-avatar.js";`
|
|
|
961
986
|
|
|
962
987
|
Properties: `src` (attribute `src`) : string | null, default null; `name` (attribute `name`) : string | null, default null; `size` (attribute `size`) : string | number, default 32
|
|
963
988
|
Events: none
|
|
964
|
-
CSS custom properties: `--ui-font`, `--ui-primary`
|
|
989
|
+
CSS custom properties: `--ui-font`, `--ui-on-accent`, `--ui-primary`
|
|
965
990
|
|
|
966
991
|
Example:
|
|
967
992
|
```html
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@f-ewald/components",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "1.0.
|
|
4
|
+
"version": "1.0.2",
|
|
5
5
|
"description": "A collection of universally usable web components for various tasks.",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"main": "dist/index.js",
|
|
@@ -35,6 +35,7 @@
|
|
|
35
35
|
],
|
|
36
36
|
"scripts": {
|
|
37
37
|
"dev": "vite",
|
|
38
|
+
"typecheck": "tsc --noEmit",
|
|
38
39
|
"build": "rm -rf dist && tsc && node scripts/generate-tokens-css.mjs && chmod +x dist/mcp-server.js",
|
|
39
40
|
"build:demo": "vite build",
|
|
40
41
|
"build:site": "node scripts/generate-docs.mjs --site && vite build --base=./ --outDir=pages-dist/playground",
|
|
@@ -44,6 +45,9 @@
|
|
|
44
45
|
"icons": "node scripts/generate-icons.mjs",
|
|
45
46
|
"mcp": "node dist/mcp-server.js",
|
|
46
47
|
"test": "playwright test",
|
|
48
|
+
"test:design": "playwright test --config playwright.design.config.ts",
|
|
49
|
+
"test:visual": "playwright test --config playwright.visual.config.ts",
|
|
50
|
+
"test:visual:update": "playwright test --config playwright.visual.config.ts --update-snapshots",
|
|
47
51
|
"test:site": "playwright test --config playwright.site.config.ts",
|
|
48
52
|
"prepublishOnly": "npm run build && npm run docs && npm run test"
|
|
49
53
|
},
|