@sigx/zero-daisyui 0.14.0 → 0.15.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/css/components/container.css +1 -0
- package/dist/css/components/input.css +9 -0
- package/dist/css/components/nav-list.css +7 -0
- package/dist/css/index.css +17 -0
- package/dist/lynx/components/alert.css +7 -1
- package/dist/lynx/components/badge.css +2 -4
- package/dist/lynx/components/breadcrumbs.css +30 -21
- package/dist/lynx/components/button.css +2 -7
- package/dist/lynx/components/card.css +1 -2
- package/dist/lynx/components/carousel.css +4 -4
- package/dist/lynx/components/chat-log.css +5 -5
- package/dist/lynx/components/chat.css +1 -1
- package/dist/lynx/components/container.css +3 -2
- package/dist/lynx/components/diff.css +1 -1
- package/dist/lynx/components/divider.css +10 -10
- package/dist/lynx/components/drawer.css +8 -8
- package/dist/lynx/components/empty-state.css +1 -1
- package/dist/lynx/components/fieldset.css +1 -1
- package/dist/lynx/components/grid.css +2 -2
- package/dist/lynx/components/kbd.css +2 -3
- package/dist/lynx/components/menu.css +20 -1
- package/dist/lynx/components/nav-list.css +15 -2
- package/dist/lynx/components/navbar.css +9 -5
- package/dist/lynx/components/pagination.css +97 -65
- package/dist/lynx/components/radial-progress.css +10 -10
- package/dist/lynx/components/select.css +1 -2
- package/dist/lynx/components/spinner.css +2 -12
- package/dist/lynx/components/stack.css +2 -2
- package/dist/lynx/components/status.css +10 -20
- package/dist/lynx/components/steps.css +114 -22
- package/dist/lynx/components/table.css +1 -1
- package/dist/lynx/components/tabs.css +1 -1
- package/dist/lynx/components/timeline.css +12 -25
- package/dist/lynx/components/toast.css +2 -4
- package/dist/lynx/components/tree-view.css +31 -4
- package/dist/lynx/index.css +407 -249
- package/dist/lynx/manifest.json +2 -2
- package/dist/manifest.json +1 -1
- package/dist/recipes.d.ts.map +1 -1
- package/dist/recipes.js +282 -17
- package/dist/recipes.js.map +1 -1
- package/dist/report.json +548 -31
- package/package.json +4 -4
- package/src/recipes.ts +287 -17
package/dist/lynx/manifest.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://signalxjs.github.io/zero/schemas/lynx-manifest.schema.json",
|
|
3
3
|
"manifestVersion": 1,
|
|
4
|
-
"zeroVersion": "0.
|
|
4
|
+
"zeroVersion": "0.15.0",
|
|
5
5
|
"name": "daisyui",
|
|
6
6
|
"themes": [
|
|
7
7
|
{
|
|
@@ -2289,7 +2289,7 @@
|
|
|
2289
2289
|
"target": "lynx",
|
|
2290
2290
|
"classGrammarVersion": 2,
|
|
2291
2291
|
"capabilities": {
|
|
2292
|
-
"translated":
|
|
2292
|
+
"translated": 176,
|
|
2293
2293
|
"dropped": 471
|
|
2294
2294
|
}
|
|
2295
2295
|
}
|
package/dist/manifest.json
CHANGED
package/dist/recipes.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"recipes.d.ts","sourceRoot":"","sources":["../src/recipes.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,KAAK,EAAwB,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAmQxE;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,eAAO,MAAM,IAAI,EAAE,WAqVlB,CAAC;AA4BF,eAAO,MAAM,WAAW,EAAE,WA+EzB,CAAC;AAGF,eAAO,MAAM,YAAY,EAAE,WA0R1B,CAAC;AAmJF,eAAO,MAAM,MAAM,EAAE,WA0GpB,CAAC;AA4CF,eAAO,MAAM,OAAO,EAAE,WAoDrB,CAAC;AAEF,eAAO,MAAM,OAAO,EAAE,WA0CrB,CAAC;AAEF;;;;;;;GAOG;AACH,eAAO,MAAM,SAAS,EAAE,WAyCvB,CAAC;AAGF,eAAO,MAAM,IAAI,EAAE,
|
|
1
|
+
{"version":3,"file":"recipes.d.ts","sourceRoot":"","sources":["../src/recipes.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,KAAK,EAAwB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I,EAAE,WAmElB,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,MAAM,EAAE,WA4EpB,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,OAAO,EAAE,WAgIrB,CAAC;AAEF;;;;;GAKG;AACH,eAAO,MAAM,WAAW,EAAE,WAoIzB,CAAC;AAmDF;;;;;GAKG;AACH,eAAO,MAAM,UAAU,EAAE,WA0HxB,CAAC;AAsCF;;;;;GAKG;AACH,eAAO,MAAM,KAAK,EAAE,WAqQnB,CAAC;AA0CF;;;;;;GAMG;AACH,eAAO,MAAM,MAAM,EAAE,WA2IpB,CAAC;AAEF;;;;;GAKG;AACH,eAAO,MAAM,KAAK,EAAE,WA2LnB,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,UAAU,EAAE,WA+JxB,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,QAAQ,EAAE,WA8JtB,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,IAAI,EAAE,WA8ElB,CAAC;AAEF;;;;;GAKG;AACH,eAAO,MAAM,SAAS,EAAE,WAqDvB,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,IAAI,EAAE,WAwHlB,CAAC;AAEF,eAAO,MAAM,OAAO,EAAE,WAAW,EAahC,CAAC"}
|
package/dist/recipes.js
CHANGED
|
@@ -1558,12 +1558,34 @@ export const menu = {
|
|
|
1558
1558
|
// Trigger-carried axes — same wiring as dialog, same reason. The dropdown
|
|
1559
1559
|
// and its items are top-layer siblings the donut cannot reach.
|
|
1560
1560
|
variants: { color: btnColors(), size: btnSizes },
|
|
1561
|
-
// The btn paddings, restated physically — see `lynxBtnPad` (#1084)
|
|
1561
|
+
// The btn paddings, restated physically — see `lynxBtnPad` (#1084) —
|
|
1562
|
+
// and the trigger's press rendering, as popover's (`lynxBtnPressed`).
|
|
1562
1563
|
targets: {
|
|
1563
1564
|
web: floatingArrow('menu', panelArrowPaint),
|
|
1564
1565
|
lynx: {
|
|
1565
1566
|
parts: {
|
|
1566
|
-
|
|
1567
|
+
// Content-sized like daisy's btn (signalxjs/lynx#1165), an
|
|
1568
|
+
// explicit row (lynx does not default the direction the way a
|
|
1569
|
+
// browser does), the held state in place of the dropped
|
|
1570
|
+
// `:hover`, and the box-shadow ring (signalxjs/lynx#1163).
|
|
1571
|
+
trigger: {
|
|
1572
|
+
base: { ...lynxBtnPad(4), ...lynxBtnFit, flexDirection: 'row' },
|
|
1573
|
+
states: { pressed: lynxBtnPressed, ...lynxFocus() },
|
|
1574
|
+
},
|
|
1575
|
+
// The popups' rows stack and span the panel: a flex column
|
|
1576
|
+
// (a lynx view's default is a shrink-wrapping linear box).
|
|
1577
|
+
popup: { base: { display: 'flex', flexDirection: 'column' } },
|
|
1578
|
+
'sub-popup': { base: { display: 'flex', flexDirection: 'column' } },
|
|
1579
|
+
// Every row kind is a mark / label / shortcut / chevron row.
|
|
1580
|
+
// A touch list has no hover: lynx-zero stamps `highlighted` on
|
|
1581
|
+
// the row under the finger, so the web's highlight wash is the
|
|
1582
|
+
// press rendering as it stands. The ✓ (item-indicator) and ›
|
|
1583
|
+
// (sub-trigger) the web draws with `::after` render as
|
|
1584
|
+
// `<text>` glyphs in lynx-zero — there is no pseudo-element.
|
|
1585
|
+
item: { base: { flexDirection: 'row' } },
|
|
1586
|
+
'checkbox-item': { base: { flexDirection: 'row' } },
|
|
1587
|
+
'radio-item': { base: { flexDirection: 'row' } },
|
|
1588
|
+
'sub-trigger': { base: { flexDirection: 'row' } },
|
|
1567
1589
|
// The shortcut's reading-end push, restated physically (#1084).
|
|
1568
1590
|
shortcut: { base: { marginLeft: 'auto', paddingLeft: 'var(--space-lg)' } },
|
|
1569
1591
|
},
|
|
@@ -5253,6 +5275,28 @@ const treeRowSelectors = {
|
|
|
5253
5275
|
background: 'var(--color-base-300)',
|
|
5254
5276
|
},
|
|
5255
5277
|
};
|
|
5278
|
+
/**
|
|
5279
|
+
* The tree rows' lynx states (signalxjs/lynx#1256). The web's press wash is
|
|
5280
|
+
* `[data-pressed]:not([data-disabled]):not([data-selected])`; lynx has no
|
|
5281
|
+
* absence classes, so the wash is the plain `pressed` state and a selected
|
|
5282
|
+
* row restores its accent fill below. The web's descendant rule that swaps
|
|
5283
|
+
* the check box's pair on a selected row (`[data-selected] &` on the box)
|
|
5284
|
+
* becomes the ROW's own custom properties: they inherit to the box inside
|
|
5285
|
+
* it. The focus ring is inset (rows sit flush) and drawn as a box-shadow,
|
|
5286
|
+
* which follows the row's radius where lynx's `outline` does not.
|
|
5287
|
+
*/
|
|
5288
|
+
const lynxTreeRowStates = {
|
|
5289
|
+
pressed: { background: 'var(--color-base-300)' },
|
|
5290
|
+
selected: {
|
|
5291
|
+
'--tree-check': 'var(--tree-on-accent)',
|
|
5292
|
+
'--tree-on-check': 'var(--tree-accent)',
|
|
5293
|
+
},
|
|
5294
|
+
...lynxFocus({ inset: true }),
|
|
5295
|
+
};
|
|
5296
|
+
/** A held selected row keeps its accent fill (the web's `:not([data-selected])`). */
|
|
5297
|
+
const lynxTreeRowSelectors = {
|
|
5298
|
+
'&[data-selected][data-pressed]': { background: 'var(--tree-accent)' },
|
|
5299
|
+
};
|
|
5256
5300
|
/**
|
|
5257
5301
|
* `tickGlyphFallback` for the node check box, whose tick is its `::after`:
|
|
5258
5302
|
* the geometry drops and the same pseudo carries the glyph, in the medium's
|
|
@@ -5402,12 +5446,37 @@ export const treeView = {
|
|
|
5402
5446
|
xl: { root: { base: { '--tree-text': 'var(--text-lg)' } } },
|
|
5403
5447
|
},
|
|
5404
5448
|
},
|
|
5405
|
-
//
|
|
5406
|
-
// not
|
|
5407
|
-
//
|
|
5449
|
+
// lynx (signalxjs/lynx#1256, zero#478). No hover on a touch platform, no
|
|
5450
|
+
// `:not()`, no pseudo-elements, no descendant selectors: each web rule
|
|
5451
|
+
// those carry is restated on the part the runtime stamps. The skin's
|
|
5452
|
+
// `:dir(rtl)` mirror and the `@media` stops have no lynx form (no RTL
|
|
5453
|
+
// flow, no conditions) and stay dropped.
|
|
5408
5454
|
targets: {
|
|
5409
5455
|
lynx: {
|
|
5410
5456
|
parts: {
|
|
5457
|
+
item: { states: lynxTreeRowStates, selectors: lynxTreeRowSelectors },
|
|
5458
|
+
'branch-trigger': { states: lynxTreeRowStates, selectors: lynxTreeRowSelectors },
|
|
5459
|
+
// `inline-block` is not a lynx display value. The glyph is a
|
|
5460
|
+
// `<text>` part: a 1em box centred on it, so the quarter turn
|
|
5461
|
+
// pivots on the chevron instead of swinging it sideways.
|
|
5462
|
+
'branch-indicator': { base: { display: 'flex', width: '1em', textAlign: 'center' } },
|
|
5463
|
+
// The mark is a `<text>` child lynx-zero renders (`✓` checked,
|
|
5464
|
+
// `−` indeterminate) in place of the web's clip-path `::after`
|
|
5465
|
+
// tick — clip-path and pseudo-elements are both dropped on
|
|
5466
|
+
// lynx. The glyph is the forced-colors fallback's shape
|
|
5467
|
+
// (`nodeTickFallback`), inked with the box's `-on` pair and
|
|
5468
|
+
// sized by inheritance from the row.
|
|
5469
|
+
'node-checkbox': {
|
|
5470
|
+
base: {
|
|
5471
|
+
display: 'flex',
|
|
5472
|
+
alignItems: 'center',
|
|
5473
|
+
justifyContent: 'center',
|
|
5474
|
+
color: 'var(--tree-on-check)',
|
|
5475
|
+
},
|
|
5476
|
+
},
|
|
5477
|
+
// The indent, restated physically: logical spellings resolve
|
|
5478
|
+
// on iOS but not on Android (measured, signalxjs/lynx#1084),
|
|
5479
|
+
// so the emitter refuses them.
|
|
5411
5480
|
'branch-content': { base: { paddingLeft: 'var(--space-lg)' } },
|
|
5412
5481
|
},
|
|
5413
5482
|
},
|
|
@@ -5508,6 +5577,10 @@ export const input = {
|
|
|
5508
5577
|
selectors: {
|
|
5509
5578
|
// Same muting, same reason as `number-input/input` (#264).
|
|
5510
5579
|
'&::placeholder': { color: 'color-mix(in oklab, var(--color-base-content) 60%, transparent)' },
|
|
5580
|
+
// zero draws its own ClearTrigger and clears on Escape, and Firefox
|
|
5581
|
+
// draws no native clear: hide the engine's cancel button everywhere (#446).
|
|
5582
|
+
'&::-webkit-search-cancel-button': { appearance: 'none', display: 'none' },
|
|
5583
|
+
'&::-webkit-search-decoration': { appearance: 'none' },
|
|
5511
5584
|
},
|
|
5512
5585
|
},
|
|
5513
5586
|
// daisy's `label` inside `.input`: a quiet prefix/suffix at one edge,
|
|
@@ -6024,7 +6097,13 @@ export const alert = {
|
|
|
6024
6097
|
},
|
|
6025
6098
|
},
|
|
6026
6099
|
// Pinned top-right, its glyph on the padding edge. `inherit`
|
|
6027
|
-
// is spelled as the root's own ink.
|
|
6100
|
+
// is spelled as the root's own ink. A square chip, the
|
|
6101
|
+
// glyph centred in it: the web's `line-height: 1` + 2xs
|
|
6102
|
+
// padding make an almost-square box, but lynx does not carry
|
|
6103
|
+
// the line-height into the glyph's `<text>`, so the padded
|
|
6104
|
+
// box was a narrow × in a tall line — a 14 × 20pt pill whose
|
|
6105
|
+
// press wash and focus ring drew as vertical ovals
|
|
6106
|
+
// (signalxjs/lynx#1253). The box is sized outright instead.
|
|
6028
6107
|
close: {
|
|
6029
6108
|
base: {
|
|
6030
6109
|
position: 'absolute',
|
|
@@ -6032,6 +6111,13 @@ export const alert = {
|
|
|
6032
6111
|
right: 'calc(var(--alert-pad-x) - var(--space-2xs))',
|
|
6033
6112
|
color: 'var(--color-base-content)',
|
|
6034
6113
|
fontSize: 'var(--text-md)',
|
|
6114
|
+
display: 'flex',
|
|
6115
|
+
alignItems: 'center',
|
|
6116
|
+
justifyContent: 'center',
|
|
6117
|
+
boxSizing: 'border-box',
|
|
6118
|
+
padding: '0',
|
|
6119
|
+
width: 'calc(var(--text-md) + var(--space-2xs) * 2)',
|
|
6120
|
+
height: 'calc(var(--text-md) + var(--space-2xs) * 2)',
|
|
6035
6121
|
},
|
|
6036
6122
|
states: lynxFocus({ gap: 'var(--alert-tint)' }),
|
|
6037
6123
|
},
|
|
@@ -6670,6 +6756,15 @@ export const kbd = {
|
|
|
6670
6756
|
...lynxSides('border{}Width', 'var(--border)', ['Top', 'Right', 'Left']),
|
|
6671
6757
|
borderBottomWidth: 'calc(var(--border) * 2)',
|
|
6672
6758
|
...lynxSides('border{}Color', 'var(--color-base-300)'),
|
|
6759
|
+
// The web's monospace cap comes from the browser's
|
|
6760
|
+
// UA style for `<kbd>`, not the recipe; lynx has no
|
|
6761
|
+
// UA sheet, so the face is spelled here
|
|
6762
|
+
// (signalxjs/lynx#1254). Concrete names, not a
|
|
6763
|
+
// token: iOS Lynx walks the list with
|
|
6764
|
+
// `UIFont fontWithName:` (Menlo ships on iOS, the
|
|
6765
|
+
// CSS generics do not resolve there), and
|
|
6766
|
+
// `monospace` serves the lynx web target.
|
|
6767
|
+
fontFamily: 'Menlo, monospace',
|
|
6673
6768
|
},
|
|
6674
6769
|
},
|
|
6675
6770
|
},
|
|
@@ -7729,6 +7824,28 @@ export const navbar = {
|
|
|
7729
7824
|
xl: { root: { base: { minBlockSize: '6rem', fontSize: 'var(--text-lg)' } } },
|
|
7730
7825
|
},
|
|
7731
7826
|
},
|
|
7827
|
+
// Lynx (signalxjs/lynx#1257): `min-block-size` is not a lynx property,
|
|
7828
|
+
// so the bar's height ramp is restated as `min-height`; and a lynx flex
|
|
7829
|
+
// container is only a row when it says so, so the bar and its three
|
|
7830
|
+
// sections spell `flex-direction: row`.
|
|
7831
|
+
targets: {
|
|
7832
|
+
lynx: {
|
|
7833
|
+
parts: {
|
|
7834
|
+
root: { base: { flexDirection: 'row', minHeight: '4rem' } },
|
|
7835
|
+
start: { base: { flexDirection: 'row' } },
|
|
7836
|
+
center: { base: { flexDirection: 'row' } },
|
|
7837
|
+
end: { base: { flexDirection: 'row' } },
|
|
7838
|
+
},
|
|
7839
|
+
variants: {
|
|
7840
|
+
size: {
|
|
7841
|
+
xs: { root: { base: { minHeight: '2.5rem' } } },
|
|
7842
|
+
sm: { root: { base: { minHeight: '3rem' } } },
|
|
7843
|
+
lg: { root: { base: { minHeight: '5rem' } } },
|
|
7844
|
+
xl: { root: { base: { minHeight: '6rem' } } },
|
|
7845
|
+
},
|
|
7846
|
+
},
|
|
7847
|
+
},
|
|
7848
|
+
},
|
|
7732
7849
|
};
|
|
7733
7850
|
/**
|
|
7734
7851
|
* NavList (zero#132) — daisy's `menu` idiom for a sidebar: rounded rows, a
|
|
@@ -7787,6 +7904,14 @@ export const navList = {
|
|
|
7787
7904
|
alignItems: 'center',
|
|
7788
7905
|
gap: 'var(--space-sm)',
|
|
7789
7906
|
textDecoration: 'none',
|
|
7907
|
+
// Without an href the link is a <button> (#451): drop its chrome.
|
|
7908
|
+
appearance: 'none',
|
|
7909
|
+
background: 'none',
|
|
7910
|
+
border: '0',
|
|
7911
|
+
font: 'inherit',
|
|
7912
|
+
textAlign: 'start',
|
|
7913
|
+
inlineSize: '100%',
|
|
7914
|
+
cursor: 'pointer',
|
|
7790
7915
|
color: 'var(--nav-ink)',
|
|
7791
7916
|
padding: 'var(--space-sm) var(--space-lg)',
|
|
7792
7917
|
borderRadius: 'var(--radius-field)',
|
|
@@ -7834,6 +7959,27 @@ export const navList = {
|
|
|
7834
7959
|
xl: { root: { base: { fontSize: 'var(--text-lg)' } }, link: { base: { padding: 'var(--space-lg) var(--space-xl)' } } },
|
|
7835
7960
|
},
|
|
7836
7961
|
},
|
|
7962
|
+
// The web's block and inline boxes, restated for lynx (signalxjs/lynx#1259).
|
|
7963
|
+
// No `:hover` on a touch platform, and the link's anatomy declares no
|
|
7964
|
+
// `pressed` flag: a held link has lynx-zero's main-thread press scale.
|
|
7965
|
+
targets: {
|
|
7966
|
+
lynx: {
|
|
7967
|
+
parts: {
|
|
7968
|
+
// `display: block` has no lynx projection: a column, so the
|
|
7969
|
+
// link spans the list as a block `<li>` makes it.
|
|
7970
|
+
item: { base: { display: 'flex', flexDirection: 'column' } },
|
|
7971
|
+
// The icon / label / meta row, explicit (lynx does not
|
|
7972
|
+
// default the direction the way a browser does).
|
|
7973
|
+
link: { base: { flexDirection: 'row' } },
|
|
7974
|
+
// `inline-size` restated physically; the glyph centred in
|
|
7975
|
+
// its column on both axes.
|
|
7976
|
+
icon: { base: { width: '1.25em', flexDirection: 'row', alignItems: 'center' } },
|
|
7977
|
+
// The count's push to the far edge, restated physically —
|
|
7978
|
+
// `margin-inline-start` does not resolve on Android (#1084).
|
|
7979
|
+
meta: { base: { marginLeft: 'auto', flexDirection: 'row' } },
|
|
7980
|
+
},
|
|
7981
|
+
},
|
|
7982
|
+
},
|
|
7837
7983
|
};
|
|
7838
7984
|
/**
|
|
7839
7985
|
* Breadcrumbs — daisy's breadcrumbs: a compact text-sm trail, links
|
|
@@ -7942,6 +8088,37 @@ export const breadcrumbs = {
|
|
|
7942
8088
|
xl: { root: { base: { fontSize: 'var(--text-lg)' } } },
|
|
7943
8089
|
},
|
|
7944
8090
|
},
|
|
8091
|
+
// Lynx (signalxjs/lynx#1257):
|
|
8092
|
+
// - The list, the items and the ellipsis are explicit rows (a lynx flex
|
|
8093
|
+
// container is only a row when it says so).
|
|
8094
|
+
// - The trigger's `hover` ink is dropped on a touch platform; the
|
|
8095
|
+
// `pressed` flag carries it instead. Its resting ink moves onto a
|
|
8096
|
+
// lynx-only token so the base rule stays a plain var() read: the
|
|
8097
|
+
// emitter bakes a `color-mix` declaration per theme under the host
|
|
8098
|
+
// class, and that baked rule would outrank the pressed one.
|
|
8099
|
+
// - The focus ring is the lynx box-shadow ring (outline has no offset
|
|
8100
|
+
// and ignores the radius there).
|
|
8101
|
+
// - The link's `hover` stays dropped: the link anatomy declares no
|
|
8102
|
+
// pressed flag, so there is nothing on lynx to carry it.
|
|
8103
|
+
// - The separator is a real part on both targets (lynx-zero renders it
|
|
8104
|
+
// as a text glyph), so daisy's `::before` chevron needs no lynx form.
|
|
8105
|
+
targets: {
|
|
8106
|
+
lynx: {
|
|
8107
|
+
tokens: { '--bc-trigger-ink': 'color-mix(in oklch, var(--color-base-content) 75%, transparent)' },
|
|
8108
|
+
parts: {
|
|
8109
|
+
list: { base: { flexDirection: 'row' } },
|
|
8110
|
+
item: { base: { flexDirection: 'row' } },
|
|
8111
|
+
ellipsis: { base: { flexDirection: 'row' } },
|
|
8112
|
+
'ellipsis-trigger': {
|
|
8113
|
+
base: { color: 'var(--bc-trigger-ink)' },
|
|
8114
|
+
states: {
|
|
8115
|
+
pressed: { color: 'var(--color-base-content)' },
|
|
8116
|
+
'focus-visible': lynxFocusRing('var(--color-primary)'),
|
|
8117
|
+
},
|
|
8118
|
+
},
|
|
8119
|
+
},
|
|
8120
|
+
},
|
|
8121
|
+
},
|
|
7945
8122
|
};
|
|
7946
8123
|
/**
|
|
7947
8124
|
* The four pagination triggers — prev/next and, with `withEdges`, the
|
|
@@ -7978,6 +8155,17 @@ const pageTrigger = {
|
|
|
7978
8155
|
[`&${rtl}`]: { scale: '-1 1' },
|
|
7979
8156
|
},
|
|
7980
8157
|
};
|
|
8158
|
+
/** A pagination cell's box on lynx — see the recipe's lynx section. */
|
|
8159
|
+
const pageCellLynx = {
|
|
8160
|
+
minWidth: 'var(--pg-size)',
|
|
8161
|
+
height: 'var(--pg-size)',
|
|
8162
|
+
flexShrink: '0',
|
|
8163
|
+
};
|
|
8164
|
+
/** The four triggers on lynx: the cell box, the held wash + sink, the ring. */
|
|
8165
|
+
const pageTriggerLynx = {
|
|
8166
|
+
base: pageCellLynx,
|
|
8167
|
+
states: { pressed: { background: 'var(--color-base-300)' }, ...lynxFocus() },
|
|
8168
|
+
};
|
|
7981
8169
|
/**
|
|
7982
8170
|
* Pagination — daisy's join-of-buttons made of standalone btn cells: the
|
|
7983
8171
|
* quiet base-200 fill, base-300 hover, the current page inverted into the
|
|
@@ -8074,13 +8262,35 @@ export const pagination = {
|
|
|
8074
8262
|
xl: { root: { base: { '--pg-size': 'calc(var(--size-field) * 14)', '--pg-font': 'var(--text-lg)' } } },
|
|
8075
8263
|
},
|
|
8076
8264
|
},
|
|
8077
|
-
//
|
|
8078
|
-
//
|
|
8079
|
-
//
|
|
8265
|
+
// Lynx (signalxjs/lynx#1258):
|
|
8266
|
+
// - the cells' size, restated physically: `min-inline-size` and
|
|
8267
|
+
// `block-size` do not resolve on lynx (lynx#1145), so every cell
|
|
8268
|
+
// collapsed to its glyph. Read through `--pg-size`, so the compile
|
|
8269
|
+
// inlines the size steps per part, as it does the web's;
|
|
8270
|
+
// - the item's inline padding, physical: logical spellings resolve on
|
|
8271
|
+
// iOS but not on Android (measured, lynx#1084);
|
|
8272
|
+
// - the press: the web answers a pointer with `:hover`, which a touch
|
|
8273
|
+
// platform drops, so the held cell paints daisy's hover wash with the
|
|
8274
|
+
// 1px sink (`lynxBtnPressed`'s pair) — the current page keeps its
|
|
8275
|
+
// accent fill and only sinks;
|
|
8276
|
+
// - the focus ring as `lynxFocus`: lynx's outline has no offset and
|
|
8277
|
+
// ignores the radius (lynx#1163);
|
|
8278
|
+
// - no row shrink: a cell never squeezes below its size in a narrow row.
|
|
8279
|
+
// The glyphs' rtl flip has no replacement: lynx has no RTL flow.
|
|
8080
8280
|
targets: {
|
|
8081
8281
|
lynx: {
|
|
8082
8282
|
parts: {
|
|
8083
|
-
|
|
8283
|
+
root: { base: { flexDirection: 'row' } },
|
|
8284
|
+
item: {
|
|
8285
|
+
base: { ...pageCellLynx, paddingLeft: 'var(--space-2xs)', paddingRight: 'var(--space-2xs)' },
|
|
8286
|
+
states: lynxFocus(),
|
|
8287
|
+
selectors: { '&[data-pressed][data-state="inactive"]': { background: 'var(--color-base-300)' } },
|
|
8288
|
+
},
|
|
8289
|
+
ellipsis: { base: pageCellLynx },
|
|
8290
|
+
'first-trigger': pageTriggerLynx,
|
|
8291
|
+
'prev-trigger': pageTriggerLynx,
|
|
8292
|
+
'next-trigger': pageTriggerLynx,
|
|
8293
|
+
'last-trigger': pageTriggerLynx,
|
|
8084
8294
|
},
|
|
8085
8295
|
},
|
|
8086
8296
|
},
|
|
@@ -8097,6 +8307,11 @@ export const pagination = {
|
|
|
8097
8307
|
*/
|
|
8098
8308
|
const stepInk = (accent, role) => `color-mix(in oklab, ${accent} `
|
|
8099
8309
|
+ `${Math.min(ROLE_INK_KEEP[role] ?? 55, 70)}%, var(--color-base-content))`;
|
|
8310
|
+
/**
|
|
8311
|
+
* The complete disc's fill: 20% of the accent over base-100, in OKLAB (see
|
|
8312
|
+
* the indicator's `complete` state for why not OKLCH).
|
|
8313
|
+
*/
|
|
8314
|
+
const stepTint = (accent) => `color-mix(in oklab, ${accent} 20%, var(--color-base-100))`;
|
|
8100
8315
|
/** A Steps root holding wizard parts (#296) — the panel or the triggers. */
|
|
8101
8316
|
const STEPS_WIZARD = '&:has(> [data-scope="steps"]:is([data-part="content"], [data-part="prev-trigger"], [data-part="next-trigger"]))';
|
|
8102
8317
|
/** Steps' Back/Next (#296): the neutral daisy btn, with its 1px sink. */
|
|
@@ -8212,7 +8427,7 @@ export const steps = {
|
|
|
8212
8427
|
// (warning's yellow came out pink) — which the browser parity
|
|
8213
8428
|
// check caught once per-step colour put all eight roles on
|
|
8214
8429
|
// the disc (#112).
|
|
8215
|
-
complete: { background: '
|
|
8430
|
+
complete: { background: stepTint('var(--steps-accent)'), color: 'var(--steps-complete-ink)' },
|
|
8216
8431
|
inactive: { background: 'var(--color-base-200)', color: 'var(--color-base-content)' },
|
|
8217
8432
|
invalid: { background: 'var(--color-error)', color: 'var(--color-error-content)' },
|
|
8218
8433
|
},
|
|
@@ -8300,32 +8515,82 @@ export const steps = {
|
|
|
8300
8515
|
xl: { root: { base: { '--steps-ind': 'calc(var(--size-selector) * 9)', '--steps-font': 'var(--text-md)' } } },
|
|
8301
8516
|
},
|
|
8302
8517
|
},
|
|
8303
|
-
//
|
|
8304
|
-
//
|
|
8305
|
-
//
|
|
8306
|
-
//
|
|
8518
|
+
// Lynx. Physical spellings throughout: logical insets, margins and
|
|
8519
|
+
// paddings resolve on iOS but not on Android (measured,
|
|
8520
|
+
// signalxjs/lynx#1084), and `inline-size` / `block-size` do not resolve
|
|
8521
|
+
// at all (lynx#1145) — without the restatement the discs and lines did
|
|
8522
|
+
// not paint. Also (signalxjs/lynx#1258):
|
|
8523
|
+
// - the complete disc's tint and ink read `--steps-accent` through a
|
|
8524
|
+
// colour function, which cannot bake; the base pair is restated over
|
|
8525
|
+
// primary, and each colour already restates the ink on its item, so
|
|
8526
|
+
// the tint joins it there;
|
|
8527
|
+
// - the bridge runs from this disc's edge to the next disc's edge —
|
|
8528
|
+
// `50% + ind/2` for `100% - ind` — instead of centre to centre under
|
|
8529
|
+
// the disc, so it needs no z-index across sibling items; the item
|
|
8530
|
+
// stops clipping (a lynx view's `overflow` defaults to hidden) so the
|
|
8531
|
+
// bridge can reach past its box;
|
|
8532
|
+
// - the `:has()` wizard wrap becomes the `wizard` stamp lynx-zero puts on
|
|
8533
|
+
// the root while a panel or trigger is mounted (raw css below);
|
|
8534
|
+
// - the focus ring as `lynxFocus` (lynx#1163), and Back/Next's press as
|
|
8535
|
+
// daisy's hover wash + sink (`lynxBtnPressed`), `:hover` being dropped.
|
|
8307
8536
|
targets: {
|
|
8308
8537
|
lynx: {
|
|
8538
|
+
tokens: {
|
|
8539
|
+
'--steps-complete-ink': stepInk('var(--color-primary)', 'primary'),
|
|
8540
|
+
'--steps-complete-tint': stepTint('var(--color-primary)'),
|
|
8541
|
+
},
|
|
8309
8542
|
parts: {
|
|
8543
|
+
root: { base: { flexDirection: 'row', overflow: 'visible' } },
|
|
8310
8544
|
item: {
|
|
8545
|
+
base: { overflow: 'visible' },
|
|
8546
|
+
states: lynxFocus(),
|
|
8311
8547
|
selectors: {
|
|
8312
8548
|
'&[data-orientation="vertical"]': { paddingBottom: 'var(--space-lg)' },
|
|
8313
8549
|
},
|
|
8314
8550
|
},
|
|
8551
|
+
indicator: {
|
|
8552
|
+
base: { width: 'var(--steps-ind)', height: 'var(--steps-ind)' },
|
|
8553
|
+
states: { complete: { background: 'var(--steps-complete-tint)' } },
|
|
8554
|
+
},
|
|
8315
8555
|
separator: {
|
|
8316
8556
|
selectors: {
|
|
8317
8557
|
'&[data-orientation="horizontal"]': {
|
|
8318
|
-
top: 'calc(var(--space-xs) + var(--steps-ind) / 2)',
|
|
8319
|
-
left: '50%',
|
|
8558
|
+
top: 'calc(var(--space-xs) + (var(--steps-ind) - var(--border)) / 2)',
|
|
8559
|
+
left: 'calc(50% + var(--steps-ind) / 2)',
|
|
8560
|
+
width: 'calc(100% - var(--steps-ind))',
|
|
8561
|
+
height: 'var(--border)',
|
|
8320
8562
|
},
|
|
8321
8563
|
'&[data-orientation="vertical"]': {
|
|
8322
8564
|
left: 'calc(var(--space-xs) + (var(--steps-ind) - var(--border)) / 2)',
|
|
8323
8565
|
top: 'calc(var(--space-xs) + var(--steps-ind))',
|
|
8324
8566
|
bottom: 'calc(var(--space-xs) * -1)',
|
|
8567
|
+
width: 'var(--border)',
|
|
8325
8568
|
},
|
|
8326
8569
|
},
|
|
8327
8570
|
},
|
|
8571
|
+
'prev-trigger': {
|
|
8572
|
+
base: { ...lynxBtnPad(4), ...lynxBtnFit },
|
|
8573
|
+
states: { pressed: lynxBtnPressed, ...lynxFocus() },
|
|
8574
|
+
},
|
|
8575
|
+
'next-trigger': {
|
|
8576
|
+
base: { ...lynxBtnPad(4), ...lynxBtnFit, marginLeft: 'auto' },
|
|
8577
|
+
states: { pressed: lynxBtnPressed, ...lynxFocus() },
|
|
8578
|
+
},
|
|
8328
8579
|
},
|
|
8580
|
+
variants: {
|
|
8581
|
+
color: Object.fromEntries(ROLES.map((c) => [c, { item: { base: {
|
|
8582
|
+
'--steps-complete-tint': stepTint(`var(--color-${c})`),
|
|
8583
|
+
} } }])),
|
|
8584
|
+
},
|
|
8585
|
+
// lynx-zero stamps `wizard` on the root while a Content,
|
|
8586
|
+
// PrevTrigger or NextTrigger is mounted — the web's `:has()`.
|
|
8587
|
+
// A lynx-zero rendering detail, not a modifier an author sets.
|
|
8588
|
+
css: `
|
|
8589
|
+
.zx-steps__root.zx-m-wizard {
|
|
8590
|
+
flex-wrap: wrap;
|
|
8591
|
+
row-gap: var(--space-md);
|
|
8592
|
+
}
|
|
8593
|
+
`,
|
|
8329
8594
|
},
|
|
8330
8595
|
},
|
|
8331
8596
|
};
|