@aceshooting/lyra-ui 18.2.0 → 18.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -9,7 +9,7 @@
9
9
  - **Release history** [CHANGELOG.md](../../CHANGELOG.md); family-wide breaking-change summaries: [llms-full.txt](../../llms-full.txt)
10
10
  - **Deprecations** none
11
11
  - **Optional peers** none
12
- - **Themeable via** 6 parts, 5 custom properties — see this component's own `@csspart`/`@cssprop` list below
12
+ - **Themeable via** 6 parts, 14 custom properties — see this component's own `@csspart`/`@cssprop` list below
13
13
  - **Library-wide behavior** (events, form association, `locale`/`strings`, tokens, TS types): `llms/shared.md`
14
14
 
15
15
  ---
@@ -57,6 +57,11 @@ extension?: string }`. Descriptor labels/descriptions are consumer-supplied, alr
57
57
  copy. `formatId` must be nonempty and unique; malformed options and later duplicates are omitted
58
58
  first-wins before menu state, focus reconciliation, or export events. Custom format ids are
59
59
  event-only; no custom encoder is bundled
60
+ - `size?: LyraSize` — optional density on the shared `2xs` through `xl` ladder, including the
61
+ `small`/`medium`/`large` aliases. It changes trigger and menu-row typography and padding while
62
+ retaining the shared 40px minimum hit-area floor. Unset preserves the established geometry
63
+ - `appearance?: LyraExportButtonAppearance` — `outlined` or `quiet` trigger treatment. Unset
64
+ preserves the established surface, border, and text colors
60
65
  - `disabled: boolean = false` (reflected) — also disables every `[part="menu-item"]` button, not just
61
66
  the trigger
62
67
  - `loading: boolean = false` (reflected) — controlled busy state for an async or server-generated
@@ -93,8 +98,16 @@ closes caused by disablement, loading, or an unusable format list emit neither e
93
98
  attempt regardless of outcome — style with `::part(trigger-error)`), `menu`, `menu-item`,
94
99
  `format-label`, `format-description`
95
100
 
96
- **Themeable custom properties:** shared tokens only, including `--lr-popover-viewport-clamp`
97
- (default `92vw`) the shared narrow-viewport ceiling the `menu`'s max-inline-size is `min()`ed
101
+ **Themeable custom properties:** the trigger's paint is settable per state. At rest,
102
+ `--lr-export-button-background`, `--lr-export-button-color` and `--lr-export-button-border`; on
103
+ hover, `--lr-export-button-hover-background`, `--lr-export-button-hover-color` and
104
+ `--lr-export-button-hover-border`; while pressed, `--lr-export-button-active-background`,
105
+ `--lr-export-button-active-color` and `--lr-export-button-active-border`. Each layers over whatever
106
+ the current `appearance` resolves to and leaves the other paints alone, so they are also the way to
107
+ keep `appearance="outlined"` chrome while returning its label to neutral text — `outlined` paints
108
+ the label `--lr-color-brand` and, unlike `lr-button`, this component has no `variant` of its own to
109
+ opt out. Before 18.4.0 none of these existed and the only lever was `::part(trigger)`. Plus shared
110
+ tokens, including `--lr-popover-viewport-clamp` (default `92vw`) — the shared narrow-viewport ceiling the `menu`'s max-inline-size is `min()`ed
98
111
  against, alongside its own `20rem` cap and the positioner's available space. See `lr-tour` for the
99
112
  shared-clamp note.
100
113
 
@@ -348,9 +348,13 @@ color?: string; label?: string; partOfRamp?: boolean }`: a discrete legend key r
348
348
  "no data" color next to an N-step ramp) to exclude just that stop from the comparison; defaults to
349
349
  `true`. A caption-only stop (no `color`) is already excluded regardless of this flag.
350
350
 
351
- **Getters/methods:** `refreshTheme()` redraws canvas content after an upstream design-token or
352
- color-scheme change; called automatically on theme changes, exposed for a consumer that needs to
353
- force a redraw manually. `matrixGeometry: Readonly<LyraHeatmapMatrixGeometryChangeDetail> | undefined` — the gutter/cell geometry the last matrix-mode draw actually painted with,
351
+ **Getters/methods:** `exportData('png')` returns a PNG data URL for the most recently completed
352
+ canvas paint. It includes the painted axes, cells, focus/selection/annotation overlays, and frozen
353
+ label bands while `stickyLabels` is enabled; the DOM legend, tooltip, and accessible-cell buttons
354
+ are deliberately excluded. It returns `''` before a completed paint, while rendering is deferred or
355
+ zero-sized, after disconnect, or when the browser cannot encode the snapshot. `refreshTheme()` —
356
+ redraws canvas content after an upstream design-token or color-scheme change; called automatically
357
+ on theme changes, exposed for a consumer that needs to force a redraw manually. `matrixGeometry: Readonly<LyraHeatmapMatrixGeometryChangeDetail> | undefined` — the gutter/cell geometry the last matrix-mode draw actually painted with,
354
358
  in CSS pixels; `undefined` in calendar mode. Lets a light-DOM consumer line up with the canvas
355
359
  without hardcoding the same numbers `row-label-width`/`col-label-height`'s `"auto"` resolution would
356
360
  otherwise keep private. For the case that motivated it — a frozen header or gutter on a tall or wide
@@ -46,6 +46,13 @@ trap, Escape/backdrop dismissal, scroll lock, and focus return.
46
46
  - `minZoom: number = 0.5`, `maxZoom: number = 4`, `zoomStep: number = 0.25` (attributes `min-zoom`/
47
47
  `max-zoom`/`zoom-step`) — pure pass-throughs to the embedded `<lr-pan-zoom>`, which does the
48
48
  normalizing.
49
+ - `fit: LyraImageFit = 'actual'` (reflected) — opt-in base sizing policy for the current image,
50
+ reusing `<lr-image-viewer>`'s `contain`/`width`/`actual` vocabulary. The default preserves the
51
+ existing natural-size behavior. `contain` fits both landscape and tall images inside the stage;
52
+ `width` fills its inline size. CSS recalculates either policy when the stage is resized or a
53
+ delayed image source finishes loading, so navigation and opening do not require consumer timers.
54
+ Fit is the base zoom policy: an explicit user zoom remains until navigation or a reset, and
55
+ changing the theme does not mutate the lightbox's zoom property.
49
56
  - `accessibleLabel: string | null = null` (attribute `aria-label`) — the panel's accessible name,
50
57
  overriding the localized `lightboxLabel`.
51
58
 
@@ -102,6 +109,10 @@ photo content.
102
109
  - zoom/pan reset on navigation is imperative (`resetView()` from `updated()`), not a binding; the
103
110
  frame element is reused across navigations rather than recreated, so a keyboard user who tabbed
104
111
  into the viewport keeps focus.
112
+ - fit sizing is CSS-driven inside the stable frame. The rendered DOM image is not copied or
113
+ measured by the lightbox, so stale load events cannot apply a previous image's size. The fit
114
+ policy covers the painted image only; the lightbox's DOM caption, toolbar, legend-like actions,
115
+ and tooltip content remain outside that image surface.
105
116
  - scope for v1: no per-image slotted content (data-driven via `images` only), no dot indicators, no
106
117
  visual open/close animation, no click-image-to-navigate, no touch-swipe. Lifecycle phases are
107
118
  still observable through the before/after events and methods above.
@@ -27,6 +27,10 @@ import to `LyraPanZoom`); `lr-zoomable-frame` now means the mapped iframe compon
27
27
  `zoomStep: number = 0.25` — bounded, finite zoom configuration
28
28
  - `src: string = ''` and `alt: string = ''` — optional safe image source. A rejected URL is treated
29
29
  as absent and the default slot renders; no empty or unsafe `<img>` replaces that fallback.
30
+ - `fit: LyraImageFit = 'actual'` (reflected) — base sizing policy for an image supplied through
31
+ `src`, using the same `contain`/`width`/`actual` vocabulary as `<lr-image-viewer>`. `actual`
32
+ preserves the historical natural-size layout; the other modes resolve against the viewport and
33
+ update with its allocation, including when an image loads after the frame first renders.
30
34
  - `accessibleLabel: string | null` (attribute `aria-label`) — a declarative host label remains on
31
35
  the host while the focusable viewport receives the localized inspection-surface purpose name.
32
36
  A property-only value names the viewport and updates reactively without creating a host attribute. This avoids cloning one author label onto both the outer component and nested `role="group"`. An explicitly empty direct property remains empty; a present host attribute, including an empty one, leaves the viewport's localized purpose name intact.
package/llms-full.txt CHANGED
@@ -13702,9 +13702,13 @@ color?: string; label?: string; partOfRamp?: boolean }`: a discrete legend key r
13702
13702
  "no data" color next to an N-step ramp) to exclude just that stop from the comparison; defaults to
13703
13703
  `true`. A caption-only stop (no `color`) is already excluded regardless of this flag.
13704
13704
 
13705
- **Getters/methods:** `refreshTheme()` redraws canvas content after an upstream design-token or
13706
- color-scheme change; called automatically on theme changes, exposed for a consumer that needs to
13707
- force a redraw manually. `matrixGeometry: Readonly<LyraHeatmapMatrixGeometryChangeDetail> | undefined` — the gutter/cell geometry the last matrix-mode draw actually painted with,
13705
+ **Getters/methods:** `exportData('png')` returns a PNG data URL for the most recently completed
13706
+ canvas paint. It includes the painted axes, cells, focus/selection/annotation overlays, and frozen
13707
+ label bands while `stickyLabels` is enabled; the DOM legend, tooltip, and accessible-cell buttons
13708
+ are deliberately excluded. It returns `''` before a completed paint, while rendering is deferred or
13709
+ zero-sized, after disconnect, or when the browser cannot encode the snapshot. `refreshTheme()` —
13710
+ redraws canvas content after an upstream design-token or color-scheme change; called automatically
13711
+ on theme changes, exposed for a consumer that needs to force a redraw manually. `matrixGeometry: Readonly<LyraHeatmapMatrixGeometryChangeDetail> | undefined` — the gutter/cell geometry the last matrix-mode draw actually painted with,
13708
13712
  in CSS pixels; `undefined` in calendar mode. Lets a light-DOM consumer line up with the canvas
13709
13713
  without hardcoding the same numbers `row-label-width`/`col-label-height`'s `"auto"` resolution would
13710
13714
  otherwise keep private. For the case that motivated it — a frozen header or gutter on a tall or wide
@@ -24829,6 +24833,11 @@ extension?: string }`. Descriptor labels/descriptions are consumer-supplied, alr
24829
24833
  copy. `formatId` must be nonempty and unique; malformed options and later duplicates are omitted
24830
24834
  first-wins before menu state, focus reconciliation, or export events. Custom format ids are
24831
24835
  event-only; no custom encoder is bundled
24836
+ - `size?: LyraSize` — optional density on the shared `2xs` through `xl` ladder, including the
24837
+ `small`/`medium`/`large` aliases. It changes trigger and menu-row typography and padding while
24838
+ retaining the shared 40px minimum hit-area floor. Unset preserves the established geometry
24839
+ - `appearance?: LyraExportButtonAppearance` — `outlined` or `quiet` trigger treatment. Unset
24840
+ preserves the established surface, border, and text colors
24832
24841
  - `disabled: boolean = false` (reflected) — also disables every `[part="menu-item"]` button, not just
24833
24842
  the trigger
24834
24843
  - `loading: boolean = false` (reflected) — controlled busy state for an async or server-generated
@@ -24865,8 +24874,16 @@ closes caused by disablement, loading, or an unusable format list emit neither e
24865
24874
  attempt regardless of outcome — style with `::part(trigger-error)`), `menu`, `menu-item`,
24866
24875
  `format-label`, `format-description`
24867
24876
 
24868
- **Themeable custom properties:** shared tokens only, including `--lr-popover-viewport-clamp`
24869
- (default `92vw`) the shared narrow-viewport ceiling the `menu`'s max-inline-size is `min()`ed
24877
+ **Themeable custom properties:** the trigger's paint is settable per state. At rest,
24878
+ `--lr-export-button-background`, `--lr-export-button-color` and `--lr-export-button-border`; on
24879
+ hover, `--lr-export-button-hover-background`, `--lr-export-button-hover-color` and
24880
+ `--lr-export-button-hover-border`; while pressed, `--lr-export-button-active-background`,
24881
+ `--lr-export-button-active-color` and `--lr-export-button-active-border`. Each layers over whatever
24882
+ the current `appearance` resolves to and leaves the other paints alone, so they are also the way to
24883
+ keep `appearance="outlined"` chrome while returning its label to neutral text — `outlined` paints
24884
+ the label `--lr-color-brand` and, unlike `lr-button`, this component has no `variant` of its own to
24885
+ opt out. Before 18.4.0 none of these existed and the only lever was `::part(trigger)`. Plus shared
24886
+ tokens, including `--lr-popover-viewport-clamp` (default `92vw`) — the shared narrow-viewport ceiling the `menu`'s max-inline-size is `min()`ed
24870
24887
  against, alongside its own `20rem` cap and the positioner's available space. See `lr-tour` for the
24871
24888
  shared-clamp note.
24872
24889
 
@@ -28547,6 +28564,10 @@ import to `LyraPanZoom`); `lr-zoomable-frame` now means the mapped iframe compon
28547
28564
  `zoomStep: number = 0.25` — bounded, finite zoom configuration
28548
28565
  - `src: string = ''` and `alt: string = ''` — optional safe image source. A rejected URL is treated
28549
28566
  as absent and the default slot renders; no empty or unsafe `<img>` replaces that fallback.
28567
+ - `fit: LyraImageFit = 'actual'` (reflected) — base sizing policy for an image supplied through
28568
+ `src`, using the same `contain`/`width`/`actual` vocabulary as `<lr-image-viewer>`. `actual`
28569
+ preserves the historical natural-size layout; the other modes resolve against the viewport and
28570
+ update with its allocation, including when an image loads after the frame first renders.
28550
28571
  - `accessibleLabel: string | null` (attribute `aria-label`) — a declarative host label remains on
28551
28572
  the host while the focusable viewport receives the localized inspection-surface purpose name.
28552
28573
  A property-only value names the viewport and updates reactively without creating a host attribute. This avoids cloning one author label onto both the outer component and nested `role="group"`. An explicitly empty direct property remains empty; a present host attribute, including an empty one, leaves the viewport's localized purpose name intact.
@@ -29534,6 +29555,13 @@ trap, Escape/backdrop dismissal, scroll lock, and focus return.
29534
29555
  - `minZoom: number = 0.5`, `maxZoom: number = 4`, `zoomStep: number = 0.25` (attributes `min-zoom`/
29535
29556
  `max-zoom`/`zoom-step`) — pure pass-throughs to the embedded `<lr-pan-zoom>`, which does the
29536
29557
  normalizing.
29558
+ - `fit: LyraImageFit = 'actual'` (reflected) — opt-in base sizing policy for the current image,
29559
+ reusing `<lr-image-viewer>`'s `contain`/`width`/`actual` vocabulary. The default preserves the
29560
+ existing natural-size behavior. `contain` fits both landscape and tall images inside the stage;
29561
+ `width` fills its inline size. CSS recalculates either policy when the stage is resized or a
29562
+ delayed image source finishes loading, so navigation and opening do not require consumer timers.
29563
+ Fit is the base zoom policy: an explicit user zoom remains until navigation or a reset, and
29564
+ changing the theme does not mutate the lightbox's zoom property.
29537
29565
  - `accessibleLabel: string | null = null` (attribute `aria-label`) — the panel's accessible name,
29538
29566
  overriding the localized `lightboxLabel`.
29539
29567
 
@@ -29590,6 +29618,10 @@ photo content.
29590
29618
  - zoom/pan reset on navigation is imperative (`resetView()` from `updated()`), not a binding; the
29591
29619
  frame element is reused across navigations rather than recreated, so a keyboard user who tabbed
29592
29620
  into the viewport keeps focus.
29621
+ - fit sizing is CSS-driven inside the stable frame. The rendered DOM image is not copied or
29622
+ measured by the lightbox, so stale load events cannot apply a previous image's size. The fit
29623
+ policy covers the painted image only; the lightbox's DOM caption, toolbar, legend-like actions,
29624
+ and tooltip content remain outside that image surface.
29593
29625
  - scope for v1: no per-image slotted content (data-driven via `images` only), no dot indicators, no
29594
29626
  visual open/close animation, no click-image-to-navigate, no touch-swipe. Lifecycle phases are
29595
29627
  still observable through the before/after events and methods above.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aceshooting/lyra-ui",
3
- "version": "18.2.0",
3
+ "version": "18.4.0",
4
4
  "description": "Free, independent Lit web components: an open-source alternative to Shoelace and Web Awesome with accessible forms, dashboards, charts, and agent UI.",
5
5
  "keywords": [
6
6
  "web-components",