@nxgt/material 3.73.0 → 3.75.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +72 -0
- package/README.md +10 -7
- package/dist/{alert-dialog-A8K8zai1.js → alert-dialog-BfO_ri-N.js} +1 -1
- package/dist/{async-slice-B8933IHY.js → async-slice-roMAJVzG.js} +1 -1
- package/dist/{background-D1gC4m2R.js → background-Q4Ek3rNy.js} +3 -1
- package/dist/backgrounds/css-react/celestial-day.css +85 -0
- package/dist/backgrounds/css-react/celestial.css +11 -11
- package/dist/backgrounds.js +1 -1
- package/dist/{button-C8moFnIT.js → button-DgenqmpS.js} +1 -1
- package/dist/charts.js +3 -3
- package/dist/{chip-B6AY1E91.js → chip-CiDczNxO.js} +2 -2
- package/dist/{code-editor-DQZIKL54.js → code-editor-CohlhFsA.js} +5 -5
- package/dist/code-editor.js +5 -5
- package/dist/{code-language-items-8VL0aMKG.js → code-language-items-Cs8GLYDp.js} +2 -2
- package/dist/components/ui/collections/data-table/data-table-items-actions.css +37 -0
- package/dist/components/ui/collections/data-table/data-table-items-chevron.css +28 -0
- package/dist/components/ui/collections/data-table/data-table-items-tiles.css +7 -0
- package/dist/components/ui/collections/data-table/index.css +5 -1
- package/dist/components/ui/display/seat-ring/seat-ring.css +26 -0
- package/dist/components/ui/display/secret-card/secret-card.css +5 -1
- package/dist/components/ui/feedback/celebration/celebration.css +49 -0
- package/dist/components/ui/feedback/feedback.css +4 -0
- package/dist/components/ui/feedback/moment/moment.css +22 -0
- package/dist/{components-Cvp2F9uk.js → components-zJdfH4im.js} +16930 -16524
- package/dist/components.js +28 -28
- package/dist/{dialog-WuLTwxkr.js → dialog-AGsB3bv4.js} +4 -4
- package/dist/dnd.js +1 -1
- package/dist/{dropdown-menu-tadySeGH.js → dropdown-menu-CzR6JP31.js} +1 -1
- package/dist/editor.js +10 -10
- package/dist/{empty-state-ZYiFSSBQ.js → empty-state-DjHGMp5F.js} +2 -2
- package/dist/{field-blur-BYR0yE5L.js → field-blur-CdASxjL7.js} +1 -1
- package/dist/{field-blur-context-bEhByoK-.js → field-blur-context-kZ4SD7xu.js} +1 -1
- package/dist/{hooks-GpwD8iDu.js → hooks-Dqq8O3Az.js} +2 -2
- package/dist/hooks.js +2 -2
- package/dist/{hover-card-BowaI_ra.js → hover-card-BPKqte4a.js} +1 -1
- package/dist/i18n.js +3 -3
- package/dist/{icon-badge-B1B0Lg02.js → icon-badge-B9uvDoyY.js} +3 -3
- package/dist/{icon-button-BbGU17cb.js → icon-button-Cr-DyDGg.js} +1 -1
- package/dist/lib/backgrounds/background/available.d.ts +4 -4
- package/dist/lib/backgrounds/background/background.d.ts +1 -1
- package/dist/lib/backgrounds/background/types.d.ts +1 -1
- package/dist/lib/components/ui/collections/data-table/layout-types.d.ts +13 -0
- package/dist/lib/components/ui/collections/data-table/partials/layouts/data-table-item-actions.d.ts +12 -0
- package/dist/lib/components/ui/collections/data-table/partials/layouts/data-table-item-title.d.ts +2 -1
- package/dist/lib/components/ui/collections/data-table/select-checkbox.d.ts +2 -1
- package/dist/lib/components/ui/collections/filter/bar/filter-bar-classes.d.ts +2 -2
- package/dist/lib/components/ui/collections/filter/bar/filter-bar-view.d.ts +1 -1
- package/dist/lib/components/ui/collections/filter/facets/filter-facets.d.ts +1 -1
- package/dist/lib/components/ui/collections/filter/query/types.d.ts +6 -0
- package/dist/lib/components/ui/collections/filter/query/view-types.d.ts +1 -0
- package/dist/lib/components/ui/collections/filter/sections/chips/filter-chip-body.d.ts +1 -1
- package/dist/lib/components/ui/collections/filter/sections/filter-search.d.ts +1 -0
- package/dist/lib/components/ui/collections/filter/sections/filter-sections-classes.d.ts +8 -0
- package/dist/lib/components/ui/collections/server-table/partials/server-table-band-classes.d.ts +3 -2
- package/dist/lib/components/ui/collections/server-table/partials/server-table-empty-page.d.ts +4 -0
- package/dist/lib/components/ui/collections/server-table/server-table-classes.d.ts +8 -2
- package/dist/lib/components/ui/collections/server-table/types.d.ts +11 -1
- package/dist/lib/components/ui/display/change-history/partials/changes-collapse.d.ts +2 -1
- package/dist/lib/components/ui/display/highlighted-text/highlight-ranges.d.ts +11 -0
- package/dist/lib/components/ui/display/highlighted-text/highlighted-text.d.ts +16 -0
- package/dist/lib/components/ui/display/highlighted-text/index.d.ts +2 -0
- package/dist/lib/components/ui/display/index.d.ts +1 -0
- package/dist/lib/components/ui/display/list-tile/list-tile.d.ts +10 -1
- package/dist/lib/components/ui/display/list-tile/partials/list-tile-box.d.ts +16 -0
- package/dist/lib/components/ui/display/list-tile/partials/list-tile-classes.d.ts +3 -1
- package/dist/lib/components/ui/display/list-tile/partials/list-tile-line.d.ts +1 -1
- package/dist/lib/components/ui/display/list-tile/partials/list-tile-row.d.ts +1 -1
- package/dist/lib/components/ui/display/seat-ring/types.d.ts +6 -0
- package/dist/lib/components/ui/display/secret-card/types.d.ts +6 -0
- package/dist/lib/components/ui/feedback/celebration/celebration.d.ts +24 -0
- package/dist/lib/components/ui/feedback/celebration/index.d.ts +1 -0
- package/dist/lib/components/ui/feedback/countdown-timer/countdown-ring.d.ts +1 -1
- package/dist/lib/components/ui/feedback/countdown-timer/countdown-timer.d.ts +2 -1
- package/dist/lib/components/ui/feedback/index.d.ts +2 -0
- package/dist/lib/components/ui/feedback/moment/index.d.ts +1 -0
- package/dist/lib/components/ui/feedback/moment/moment-body.d.ts +9 -0
- package/dist/lib/components/ui/feedback/moment/moment.d.ts +33 -0
- package/dist/lib/components/ui/fields/choice-list/choice-list-control.d.ts +17 -0
- package/dist/lib/components/ui/fields/choice-list/choice-list-focus.d.ts +7 -0
- package/dist/lib/components/ui/fields/contacts/placeholders.d.ts +1 -1
- package/dist/lib/components/ui/fields/number-field/number-stepper.d.ts +11 -0
- package/dist/lib/components/ui/fields/quantity-field/quantity-row.d.ts +8 -0
- package/dist/lib/components/ui/overlays/command/command-dialog.d.ts +8 -1
- package/dist/lib/components/ui/primitives/tabs/tabs-overflow-classes.d.ts +1 -1
- package/dist/lib/components/ui/selection/chip-group-field/chip-group-field.d.ts +2 -2
- package/dist/lib/components/ui/selection/chip-group-field/partials/chip-group-option.d.ts +5 -3
- package/dist/lib/components/ui/selection/choice-group/choice-group-root.d.ts +3 -1
- package/dist/lib/components/ui/widgets/chat/chat-thread-header-parts.d.ts +17 -0
- package/dist/lib/components/ui/widgets/chat/chat-thread-header.d.ts +9 -3
- package/dist/lib/components/ui/widgets/chat/proposal/chat-tool-activity.d.ts +3 -1
- package/dist/lib/i18n/resources/en/en.d.ts +4 -0
- package/dist/lib/i18n/resources/en/material.json.d.ts +5 -1
- package/dist/lib/i18n/resources/fr/fr.d.ts +4 -0
- package/dist/lib/i18n/resources/fr/material.json.d.ts +5 -1
- package/dist/lib/i18n/resources/resources.d.ts +8 -0
- package/dist/lib/i18n/translator.d.ts +1 -1
- package/dist/lib/illustrations-game/index.d.ts +6 -5
- package/dist/lib.js +1 -1
- package/dist/main.js +42 -42
- package/dist/map.js +8 -8
- package/dist/material.css +1 -1
- package/dist/pdf-reader.js +1 -1
- package/dist/print.js +1 -1
- package/dist/{public-CFj2qn7l.js → public-DC9VQw4Z.js} +9 -9
- package/dist/{rich-code-block-B7Teg7-e.js → rich-code-block-DBSL9zEN.js} +5 -5
- package/dist/{sortable-provider-DU2zp_jn.js → sortable-provider-C4tk5esY.js} +2 -2
- package/dist/{spinner-C5Kb6MWu.js → spinner-B2MubVWb.js} +1 -1
- package/dist/theme-picker.js +2 -2
- package/dist/{theme-toggle-B1JZg7mU.js → theme-toggle-BInlu21G.js} +1 -1
- package/dist/{toolbar-items-m_1FTFPQ.js → toolbar-items-CRJSx1MU.js} +3 -3
- package/dist/{translate-material-D1ndrd7a.js → translate-material-pVlPJ1v4.js} +1 -1
- package/dist/{translator-CtEC_AQa.js → translator-BoYCward.js} +10 -2
- package/dist/{typography-prQHb3gI.js → typography-B6YMbCge.js} +1 -1
- package/dist/{use-chat-composer-BAoUsyKN.js → use-chat-composer-BvWQogJe.js} +2046 -2037
- package/dist/{use-heading-spy-Bzj5mIUZ.js → use-heading-spy-B_Z4ArDh.js} +4 -4
- package/dist/{use-material-translation-C6H0B4kE.js → use-material-translation-CIS2n3RB.js} +1 -1
- package/dist/{use-return-focus-CkUX1HFl.js → use-return-focus-DNQtADAR.js} +1 -1
- package/docs/components/data-display.md +60 -6
- package/docs/components/data-table-filter-and-lists.md +22 -6
- package/docs/components/feedback-and-status.md +69 -1
- package/docs/components/form-fields.md +22 -3
- package/docs/components/navigation-and-layout.md +1 -1
- package/docs/components/overlays-and-menus.md +2 -1
- package/docs/components/primitives.md +2 -2
- package/docs/components/rich-widgets.md +3 -2
- package/docs/components/selection-and-choice.md +3 -3
- package/docs/getting-started.md +1 -1
- package/docs/guides/app-shell.md +1 -1
- package/docs/guides/backgrounds.md +23 -11
- package/docs/guides/cards-and-tiles.md +42 -3
- package/docs/guides/i18n.md +4 -1
- package/docs/guides/icon-motifs.md +7 -7
- package/docs/guides/illustrations.md +6 -5
- package/docs/guides/theming.md +5 -1
- package/docs/previews/backgrounds-day-and-dawn-sky.webp +0 -0
- package/docs/previews/data-display-highlightedtext.webp +0 -0
- package/docs/previews/feedback-status-illustration-game.webp +0 -0
- package/docs/roadmap.md +1 -0
- package/docs/troubleshooting.md +44 -4
- package/lib/backgrounds/css-react/celestial-day.css +85 -0
- package/lib/backgrounds/css-react/celestial.css +11 -11
- package/lib/components/ui/collections/data-table/data-table-items-actions.css +37 -0
- package/lib/components/ui/collections/data-table/data-table-items-chevron.css +28 -0
- package/lib/components/ui/collections/data-table/data-table-items-tiles.css +7 -0
- package/lib/components/ui/collections/data-table/index.css +5 -1
- package/lib/components/ui/display/seat-ring/seat-ring.css +26 -0
- package/lib/components/ui/display/secret-card/secret-card.css +5 -1
- package/lib/components/ui/feedback/celebration/celebration.css +49 -0
- package/lib/components/ui/feedback/feedback.css +4 -0
- package/lib/components/ui/feedback/moment/moment.css +22 -0
- package/lib/theme-picker/theme-picker.css +1 -0
- package/lib/theme-picker/theme-tile-textures-day.css +43 -0
- package/lib/themes/teal.css +20 -18
- package/package.json +7 -3
|
@@ -45,22 +45,22 @@ import '@nxgt/material/backgrounds.css';
|
|
|
45
45
|
|
|
46
46
|
| Prop | Values | Default |
|
|
47
47
|
| --- | --- | --- |
|
|
48
|
-
| `preset` | `gradient`, `grain`, `mesh`, `aurora`, `spotlight`, `bokeh`, `rays`, `halo`, `plasma`, `glass`, `ripples`, `blobs`, `paper`, `linen`, `concrete`, `marble`, `isometric`, `blueprint`, `dots`, `stripes`, `low-poly`, `topography`, `waves`, `hexagons`, `circuit`, `graph-paper`, `checker`, `diagonal-checker`, `chevrons`, `shapes`, `confetti-grid`, `constellation`, `halftone`, `truchet`, `floating`, `scatter-icons`, `school`, `night-sky`, `bubbles`, `leaves`, `science`, `music`, `travel`, `sport`, `moon`, `eclipse`, `meteor-shower`, `ringed-planet`, `northern-lights`, `icons` (`AVAILABLE_BACKGROUND_PRESETS`, the ids this library draws); any other id draws the gradient and warns outside production | `gradient` |
|
|
48
|
+
| `preset` | `gradient`, `grain`, `mesh`, `aurora`, `spotlight`, `bokeh`, `rays`, `halo`, `plasma`, `glass`, `ripples`, `blobs`, `paper`, `linen`, `concrete`, `marble`, `isometric`, `blueprint`, `dots`, `stripes`, `low-poly`, `topography`, `waves`, `hexagons`, `circuit`, `graph-paper`, `checker`, `diagonal-checker`, `chevrons`, `shapes`, `confetti-grid`, `constellation`, `halftone`, `truchet`, `floating`, `scatter-icons`, `school`, `night-sky`, `bubbles`, `leaves`, `science`, `music`, `travel`, `sport`, `moon`, `eclipse`, `meteor-shower`, `ringed-planet`, `northern-lights`, `day-sky`, `dawn-sky`, `icons` (`AVAILABLE_BACKGROUND_PRESETS`, the ids this library draws); any other id draws the gradient and warns outside production | `gradient` |
|
|
49
49
|
| `tone`, `intensity` | as above | `primary`, `default` |
|
|
50
50
|
| `animated` | `boolean`: drifts the layers, see Motion | `false` |
|
|
51
51
|
| `grain` | `boolean`: film noise over the preset; needs `grain.css` | `false` |
|
|
52
52
|
| `seed` | `number`: moves a seeded preset's geometry and the grain | `0` |
|
|
53
53
|
| `motif` | a `MotifOptions` object (`shapes`, `density`, `layout`, `size`, `rotate`, `shapeFill`, `opacitySpread`), see [Motif presets](#motif-presets) | all fields optional |
|
|
54
54
|
| `moon` | a `MoonOptions` object for `preset="moon"`, the celestial presets and a `sky`: `position` (`{ x, y }`, fractions of the container), `phase`, `halo`; see [Moon](#moon) | `{ position: { x: 0.8, y: 0.2 }, phase: 0.78, halo: 2.6 }` |
|
|
55
|
-
| `sky` | `'moon'`, `'eclipse'`, `'meteor-shower'`, `'ringed-planet'` or `'
|
|
55
|
+
| `sky` | `'moon'`, `'eclipse'`, `'meteor-shower'`, `'ringed-planet'`, `'northern-lights'`, `'day-sky'` or `'dawn-sky'`: a second scene drawn over any preset, before the grain; see [Celestial presets and the sky overlay](#celestial-presets-and-the-sky-overlay) | none |
|
|
56
56
|
| `icons` | for `preset="icons"`: a pack name (`school`, `health`, `finance`, `travel`, `nature`, `tech`) or up to 48 icon names and `{ name, family?, type? }` references; see [Icons](#icons) | the `school` pack |
|
|
57
57
|
| `iconStyle` | for `preset="icons"` (and `shapes` with `motif.icons`): one style (`{ family?, type? }` or a sprite name such as `'sharp-light'`), a list of at most 8, or a weighted list `[{ style, weight? }]`; one drawn per icon. A weighted list drops the styles whose sprite is not served | light 3, thin 3, sharp-regular 2, sharp-light 2, duotone-thin 1 |
|
|
58
58
|
| `iconMotif` | for `preset="icons"` (and `shapes` with `motif.icons`): `layout` (`even`: shapes and a few icons; `scatter`, `grid`, `constellation`, `drift`: icons only), `colors` (`one`, `palette`, `classic`), `sizeRange`, `rotation`, `duotone` (`opacity` or `tones`), `secondaryOpacity` (0.4 or, with `tones`, 0.85 unless set), `calm` (icons-only layouts), `quiet` (`start`, `end`, `center`: a band the icons fade out of) | `{ layout: 'even', colors: 'one', duotone: 'opacity' }` (`secondaryOpacity` unset: 0.4, or 0.85 with `tones`) |
|
|
59
59
|
| `fill` | `viewport` (the viewport's size) or `container` (its parent's size: the parent needs a definite height) | `viewport` |
|
|
60
60
|
|
|
61
61
|
|
|
62
|
-
`BACKGROUND_PRESETS` is the table of all
|
|
63
|
-
kind; `AVAILABLE_BACKGROUND_PRESETS` lists the ids this library draws (all
|
|
62
|
+
`BACKGROUND_PRESETS` is the table of all 52 presets with their family and
|
|
63
|
+
kind; `AVAILABLE_BACKGROUND_PRESETS` lists the ids this library draws (all 52;
|
|
64
64
|
`SHIPPED_BACKGROUND_PRESETS` is the common floor every library draws).
|
|
65
65
|
|
|
66
66
|
<img src="../previews/backgrounds-matrix.webp" width="640" alt="The presets, each in a card with its name">
|
|
@@ -287,8 +287,8 @@ follows `intensity` (`subtle` is a faint watermark, `vivid` the strongest; the s
|
|
|
287
287
|
|
|
288
288
|
## Celestial presets and the sky overlay
|
|
289
289
|
|
|
290
|
-
|
|
291
|
-
colours, a few stars and a clear middle for the content.
|
|
290
|
+
Six presets draw a sky of their own, each discreet like `moon`: thin outlines and soft halos in the tone's three
|
|
291
|
+
colours, a few stars (or, for the two daytime skies, clouds) and a clear middle for the content.
|
|
292
292
|
|
|
293
293
|
| Preset | Draws | `moon.phase` is | Default `moon.position` |
|
|
294
294
|
| --- | --- | --- | --- |
|
|
@@ -296,6 +296,8 @@ colours, a few stars and a clear middle for the content.
|
|
|
296
296
|
| `meteor-shower` | streaks falling down and to the left, among a few stars | the direction of the fall (0.2 steep, 0.9 shallow) | `0.7, 0.18` (the radiant) |
|
|
297
297
|
| `ringed-planet` | a planet with a ring that passes behind it, and a small moon | the ring's tilt | `0.78, 0.22` |
|
|
298
298
|
| `northern-lights` | three soft ribbons across the top | the ribbons' height | `0.5, 0.2` (only `y` applies) |
|
|
299
|
+
| `day-sky` | a thin-outlined sun with rays and a halo, and soft clouds in the top band; no stars | the cloud cover (0.2 clear, 0.9 overcast) | `0.8, 0.16` |
|
|
300
|
+
| `dawn-sky` | a low sun on the left over a horizon glow, and long thin clouds; no stars | the cloud cover | `0.22, 0.7` (`y` is where the glow hangs) |
|
|
299
301
|
|
|
300
302
|
```tsx
|
|
301
303
|
import '@nxgt/material/backgrounds/celestial.css'; // or backgrounds.css
|
|
@@ -308,7 +310,17 @@ They read `motif.size` (the body at 0.7, 1 or 1.4 times) and `motif.density` (5,
|
|
|
308
310
|
and `seed` places the stars. The body is halved (the planet scaled to two thirds) in a container under 640 px
|
|
309
311
|
wide so it stays whole in its corner. In light the scene is multiplied into the page, a faint watermark; in dark
|
|
310
312
|
it adds light and the body is silver. `intensity` fades it (`subtle` is the calmest, and the right pick for
|
|
311
|
-
`northern-lights`, whose ribbons are the strongest of the
|
|
313
|
+
`northern-lights`, whose ribbons are the strongest of the night skies).
|
|
314
|
+
|
|
315
|
+
`day-sky` and `dawn-sky` are the daytime pair, for an app that alternates night and day phases: the same
|
|
316
|
+
`preset` or `sky` option, so switching phase is a prop change (`preset={night ? 'night-sky' : 'day-sky'}`, or
|
|
317
|
+
`sky={night ? 'moon' : 'dawn-sky'}`). `moon.phase` is the cloud cover and `motif.density` adds clouds (2, 3 or 5,
|
|
318
|
+
plus up to two with the cover); `motif.size` scales the sun and the clouds. The clouds stay in the top band, out of
|
|
319
|
+
the clear middle, and every shape is drawn at half opacity or less, so body text over the backdrop keeps AA
|
|
320
|
+
contrast (checked in light and dark for every `intensity`). The tones follow the theme in light and dark, and
|
|
321
|
+
`animated` drifts the clouds sideways (18 s) unless the user asks for reduced motion.
|
|
322
|
+
|
|
323
|
+
<img src="../previews/backgrounds-day-and-dawn-sky.webp" width="640" alt="The day-sky and dawn-sky presets, each behind a card">
|
|
312
324
|
|
|
313
325
|
The builders live in `@nxgt/material-core/backgrounds/celestial`, a separate subpath, and `Background` loads it
|
|
314
326
|
on demand: the first paint (and the server's HTML) holds the layers, with the SVG filling in once the chunk has
|
|
@@ -316,7 +328,7 @@ loaded, so the scene never causes a hydration mismatch and an app that draws non
|
|
|
316
328
|
|
|
317
329
|
### The `sky` prop
|
|
318
330
|
|
|
319
|
-
`sky` draws the moon
|
|
331
|
+
`sky` draws the moon, a celestial preset or a daytime one over *any* preset, after its layers and before the grain, with its
|
|
320
332
|
own ids (`<id>-sky-…`), so the two never clash. It reads the base's `motif` but not its `moon` options (those stay with the
|
|
321
333
|
preset): the sky's body sits at its own default place, mirrored to the other side when the preset's moon or
|
|
322
334
|
celestial body would land within a fifth of the width, and its stars follow `seed + 1`.
|
|
@@ -327,8 +339,8 @@ celestial body would land within a fifth of the width, and its stars follow `see
|
|
|
327
339
|
|
|
328
340
|
A theme can name it too (`background: { preset: 'school', sky: 'meteor-shower' }`): a `sky` you pass wins over the
|
|
329
341
|
theme's. With `animated` the stars twinkle (8 s a leg), a meteor glides and fades (10 s) and a ribbon drifts
|
|
330
|
-
(14 s); nothing moves under `prefers-reduced-motion` or while the page is hidden. CSS: `backgrounds/celestial.css`
|
|
331
|
-
(it imports `scene.css`) styles all
|
|
342
|
+
(14 s) and a cloud slides (18 s); nothing moves under `prefers-reduced-motion` or while the page is hidden. CSS: `backgrounds/celestial.css`
|
|
343
|
+
(it imports `scene.css`) styles all six presets and the overlay; React only, `@nxgt/material-vue` does not draw
|
|
332
344
|
them. The theme picker draws a small tile for a theme with a celestial preset.
|
|
333
345
|
|
|
334
346
|
## Icons
|
|
@@ -700,7 +712,7 @@ else is opt-in, because CSS cannot be tree-shaken. `animated` on the
|
|
|
700
712
|
/* or just the one you use: */
|
|
701
713
|
@import "@nxgt/material/backgrounds/aurora.css"; /* a preset file, named after the preset (aurora.css, low-poly.css, hexagons.css, scatter-icons.css…) */
|
|
702
714
|
@import "@nxgt/material/backgrounds/grain.css"; /* the grain overlay, over any preset */
|
|
703
|
-
@import "@nxgt/material/backgrounds/celestial.css"; /* eclipse, meteor-shower, ringed-planet, northern-lights, and the `sky` overlay */
|
|
715
|
+
@import "@nxgt/material/backgrounds/celestial.css"; /* eclipse, meteor-shower, ringed-planet, northern-lights, day-sky, dawn-sky, and the `sky` overlay */
|
|
704
716
|
@import "@nxgt/material/backgrounds/halftone.css"; /* a motif preset (brings motifs.css) */
|
|
705
717
|
@import "@nxgt/material/backgrounds/floating.css"; /* brings motifs.css and drift.css */
|
|
706
718
|
```
|
|
@@ -123,12 +123,50 @@ A card is as tall as its content, and the cards of a grid row stretch to the tal
|
|
|
123
123
|
| the text only | neither |
|
|
124
124
|
|
|
125
125
|
The link's hit area covers the whole card, so a click anywhere on the card
|
|
126
|
-
follows it.
|
|
126
|
+
follows it. A linked or clickable `Title` also draws the same discreet,
|
|
127
|
+
decorative trailing chevron as `Row`, centred at the card's end (left out when
|
|
128
|
+
the card holds an `Actions` slot); `<Title chevron={false}>` removes it.
|
|
129
|
+
|
|
130
|
+
Never put a second link or a button inside the card's content:
|
|
127
131
|
only the title is interactive.
|
|
128
132
|
|
|
129
133
|
On a coarse pointer the title link also keeps a 44px box of its own, clear of
|
|
130
134
|
the row-select checkbox, however short the title.
|
|
131
135
|
|
|
136
|
+
### A trailing action beside the link
|
|
137
|
+
|
|
138
|
+
A card's primary action (a worklist's "Edit", "Approve") cannot live inside
|
|
139
|
+
the title link. Render it in `item.Actions`, after `Title`:
|
|
140
|
+
|
|
141
|
+
```tsx
|
|
142
|
+
import { Pencil } from 'lucide-react';
|
|
143
|
+
import { Button } from '@nxgt/material/components';
|
|
144
|
+
|
|
145
|
+
<DataTable
|
|
146
|
+
layout="cards"
|
|
147
|
+
getRowHref={(task) => `/tasks/${task.id}`}
|
|
148
|
+
renderCard={(task, { Title, Actions }) => (
|
|
149
|
+
<>
|
|
150
|
+
<Title as="h3">{task.name}</Title>
|
|
151
|
+
<p>{task.owner}</p>
|
|
152
|
+
<Actions>
|
|
153
|
+
<Button variant="ghost" size="icon" aria-label={`Edit ${task.name}`}
|
|
154
|
+
onClick={() => edit(task)}>
|
|
155
|
+
<Pencil aria-hidden />
|
|
156
|
+
</Button>
|
|
157
|
+
</Actions>
|
|
158
|
+
</>
|
|
159
|
+
)}
|
|
160
|
+
/>
|
|
161
|
+
```
|
|
162
|
+
|
|
163
|
+
`Actions` is a slot at the item's end (a tile centres it), outside the link,
|
|
164
|
+
at least 44px square, raised above the link's overlay: a click on the action
|
|
165
|
+
runs the action and does not follow the card. The item keeps room for it at its
|
|
166
|
+
end, room for one 44px control: a menu button for several actions, not a row
|
|
167
|
+
of buttons. `renderTile` takes it too, and so does a `ServerTable`. Render it once per
|
|
168
|
+
item. Put the action in `Actions`, not in `Row`'s `trailing` (decoration only).
|
|
169
|
+
|
|
132
170
|
`item` also carries `Row` (the compact record row above), `selected`,
|
|
133
171
|
`locked` and `reason` (a row `enableRowSelection` leaves out, and
|
|
134
172
|
`rowSelectionDisabledReason`'s answer).
|
|
@@ -237,7 +275,7 @@ own: do not put it in a shrink-to-fit parent (`w-fit`, `inline-flex`).
|
|
|
237
275
|
`cardDensity="compact"` instead fits as many cards of at least
|
|
238
276
|
`--nxgt-cards-min` (15rem) as the list holds, up to four, with a 0.5rem gap and a
|
|
239
277
|
tighter padding. By the list's own width (the table's box minus the 16px it
|
|
240
|
-
keeps on each side), four from about 62rem, three from about 46.5rem, two from
|
|
278
|
+
keeps on each side from 768px; on a phone it keeps 0, so the list is 32px wider than the thresholds below assume), four from about 62rem, three from about 46.5rem, two from
|
|
241
279
|
about 31rem, one below: a table 1280px wide shows four (so does a 1024px one), a 992px one
|
|
242
280
|
(a 1024px window with 16px page padding) three, a 328px one one. It suits a card that
|
|
243
281
|
holds a name and a fact or two. A compact card is about 15rem wide, so stack it
|
|
@@ -274,7 +312,7 @@ they are ignored and warn once in development. `tableRef` stays `null`: use
|
|
|
274
312
|
|
|
275
313
|
The list is a plain list, not a grid: Tab visits each card's checkbox (with a
|
|
276
314
|
`select` column) and then its link, in order, after the list bar's "Select all on
|
|
277
|
-
this page". Space toggles a checkbox, Enter follows a link. There is no arrow-key
|
|
315
|
+
this page". An `Actions` control comes after its link. Space toggles a checkbox, Enter follows a link. There is no arrow-key
|
|
278
316
|
navigation to learn.
|
|
279
317
|
|
|
280
318
|
## Custom links
|
|
@@ -352,6 +390,7 @@ then switches. Render the app on the client for a phone-only screen, or use
|
|
|
352
390
|
|
|
353
391
|
**My card has two links.** Only `Title` is a link. Content you render yourself
|
|
354
392
|
must not hold another `<a>` or button: it would sit under the card's hit area.
|
|
393
|
+
A button the card needs goes in `item.Actions`.
|
|
355
394
|
|
|
356
395
|
**The cards have one column on a wide screen.** (Tiles always do.) The columns follow the list's
|
|
357
396
|
width. Check that the list is not inside a shrink-to-fit parent.
|
package/docs/guides/i18n.md
CHANGED
|
@@ -312,7 +312,7 @@ title), `show` "Show results", `show-count` (an ICU plural over `count`:
|
|
|
312
312
|
filters" (the list atop it); its Close is `material.buttons.close`.
|
|
313
313
|
|
|
314
314
|
Smaller labels follow the language the same way: `CommandDialog`'s default
|
|
315
|
-
title and description (`material.command.title` / `description`) and
|
|
315
|
+
title and description (`material.command.title` / `description`), its close button (`material.buttons.close`) and
|
|
316
316
|
`CommandList`'s accessible name (`material.command.list`); the filter's empty state and
|
|
317
317
|
`+N more` chip (`material.filter.empty` / `more`) and the Yes/No, From, Until
|
|
318
318
|
and Up to of its chips (`material.filter.value.*`; `formatFilterValue` takes
|
|
@@ -578,6 +578,9 @@ places that use them read:
|
|
|
578
578
|
| `material.table.labels.select-page` / `select-item` | Select all on this page / Select | Tout sélectionner sur cette page / Sélectionner | The cards list bar's select-all (its accessible name), and a card's checkbox (named "Select <title>"). Inside a `ServerTable`'s two-row phone header the select-all also shows `material.table.labels.select-all` ("Select all") as its short visible label |
|
|
579
579
|
| `material.table.labels.clear-selection` | Clear selection | Effacer la sélection | The cards list bar's button, shown while rows are selected; on a narrow list it is an icon button, and this string is its accessible name and tooltip |
|
|
580
580
|
| `material.table.labels.scroll-list` | Scrollable list | Liste défilante | The region of a cards or tiles list with `maxHeight` (`scrollLabel` overrides it) |
|
|
581
|
+
| `material.seat-ring.empty` | Empty seat | Place libre | `SeatRing`'s default empty seat (`renderEmptySeat` replaces it) |
|
|
582
|
+
| `material.seat-ring.out` | Out | Éliminé | the word written in a `SeatRing` seat with `out: true`, part of its accessible name |
|
|
583
|
+
| `material.moment.hint` | Press Escape or tap to dismiss. | Appuyez sur Échap ou touchez l'écran pour fermer. | `Moment`'s description for assistive technology when it has no `description` |
|
|
581
584
|
| `material.command.empty` | No results | Aucun résultat | `CommandEmpty` with no children |
|
|
582
585
|
| `material.pdf-reader.retry` | Retry | Réessayer | the `PdfReader` button |
|
|
583
586
|
|
|
@@ -97,8 +97,8 @@ no icon background never downloads it.
|
|
|
97
97
|
|
|
98
98
|
## A sky
|
|
99
99
|
|
|
100
|
-
|
|
101
|
-
`northern-lights`), and `sky` lays the moon or one of them over **any** preset:
|
|
100
|
+
Six presets draw a discreet sky (`eclipse`, `meteor-shower`, `ringed-planet`,
|
|
101
|
+
`northern-lights`, `day-sky`, `dawn-sky`), and `sky` lays the moon or one of them over **any** preset:
|
|
102
102
|
|
|
103
103
|
```tsx
|
|
104
104
|
import '@nxgt/material/backgrounds/celestial.css'; // or backgrounds.css
|
|
@@ -107,12 +107,12 @@ import '@nxgt/material/backgrounds/celestial.css'; // or backgrounds.css
|
|
|
107
107
|
<Background preset="icons" icons="travel" sky="northern-lights" grain />
|
|
108
108
|
```
|
|
109
109
|
|
|
110
|
-
<img src="../previews/backgrounds-celestial.webp" width="480" alt="
|
|
110
|
+
<img src="../previews/backgrounds-celestial.webp" width="480" alt="Four of the celestial presets: an eclipse, a meteor shower, a ringed planet and northern lights">
|
|
111
111
|
|
|
112
112
|
The `sky` keeps clear of the base's own moon or planet (it moves to the other
|
|
113
113
|
side), and sits before the grain. The sky over the school icons:
|
|
114
114
|
|
|
115
|
-
<img src="../previews/backgrounds-sky-overlay.webp" width="480" alt="
|
|
115
|
+
<img src="../previews/backgrounds-sky-overlay.webp" width="480" alt="Four of the skies laid over the school icons">
|
|
116
116
|
|
|
117
117
|
The presets and `sky` are pure SVG: they need no sprite. Details in
|
|
118
118
|
[backgrounds](backgrounds.md#celestial-presets-and-the-sky-overlay).
|
|
@@ -138,8 +138,8 @@ An `Illustration` draws a hero icon on a Material 3 Expressive plate, with two
|
|
|
138
138
|
to four satellites. There are twelve base scenes (`empty`, `no-results`,
|
|
139
139
|
`not-found`, `error`, `offline`, `success`, `welcome`, `forbidden`,
|
|
140
140
|
`maintenance`, `invitation`, `sign-in`, `empty-inbox`) and two domain sets of
|
|
141
|
-
ten, **health** and **education**, plus **game** (
|
|
142
|
-
import one does not carry it:
|
|
141
|
+
ten, **health** and **education**, plus **game** (sixteen scenes for games and
|
|
142
|
+
events), each its own subpath so an app that does not import one does not carry it:
|
|
143
143
|
|
|
144
144
|
<img src="../previews/feedback-status-illustration.webp" width="480" alt="The twelve base illustration scenes">
|
|
145
145
|
|
|
@@ -147,7 +147,7 @@ import one does not carry it:
|
|
|
147
147
|
|
|
148
148
|
<img src="../previews/feedback-status-illustration-education.webp" width="480" alt="The ten education scenes">
|
|
149
149
|
|
|
150
|
-
<img src="../previews/feedback-status-illustration-game.webp" width="480" alt="The
|
|
150
|
+
<img src="../previews/feedback-status-illustration-game.webp" width="480" alt="The game scenes">
|
|
151
151
|
|
|
152
152
|
- `IllustrationDefaults` is opt-in: without it (and without a `hero`) an
|
|
153
153
|
`EmptyState` or `ErrorState` draws the same built-in art as before. An
|
|
@@ -5,7 +5,7 @@ on a Material 3 Expressive plate, two to four satellite icons around it, a
|
|
|
5
5
|
dashed ring and a few sparkles. There are twelve scenes: `empty`, `no-results`,
|
|
6
6
|
`not-found`, `error`, `offline`, `success`, `welcome`, `forbidden`,
|
|
7
7
|
`maintenance`, `invitation`, `sign-in` and `empty-inbox`, and two domain sets of
|
|
8
|
-
ten more each, health and education, in their own entries ([health](#scene-sets-the-health-scenes) and [education](#scene-sets-the-education-scenes)), and
|
|
8
|
+
ten more each, health and education, in their own entries ([health](#scene-sets-the-health-scenes) and [education](#scene-sets-the-education-scenes)), and sixteen for games ([game](#scene-sets-the-game-scenes)). The icons are
|
|
9
9
|
[Font Awesome](https://fontawesome.com) sprites **your app serves** (see
|
|
10
10
|
[Icons](../getting-started.md#icons)): the package ships no icon artwork, so it
|
|
11
11
|
works with the sprites your licence covers. The [icon motifs guide](icon-motifs.md) shows them next to the icon backgrounds, the sky and the themes, and lists the suggested names that are Pro only, with Free neighbours.
|
|
@@ -148,16 +148,17 @@ icons: serve a Pro sprite, or set `edition="free"` on `IconSpritesProvider`, whi
|
|
|
148
148
|
|
|
149
149
|
## Scene sets: the game scenes
|
|
150
150
|
|
|
151
|
-
`@nxgt/material/illustrations/game` holds
|
|
152
|
-
community or an event app: `night-sky`, `
|
|
153
|
-
|
|
151
|
+
`@nxgt/material/illustrations/game` holds sixteen scenes for a game, a quiz, a
|
|
152
|
+
community or an event app: `night-sky`, `dawn`, `village` (night),
|
|
153
|
+
`day-village`, `graveyard`, seven character pictograms (`seer`, `healer`,
|
|
154
|
+
`archer`, `cupid`, `wolf`, `villager`, `witch`), `victory`, `empty-table`,
|
|
154
155
|
`waiting-players` and `connection-lost`. It works exactly like the other sets,
|
|
155
156
|
and they register side by side. Use them where a screen is empty, waiting,
|
|
156
157
|
failed, celebrating or opening: a lobby with no players, a round that waits, a
|
|
157
158
|
dropped connection, a winner, a night-phase hero. Keep them away from behind
|
|
158
159
|
data.
|
|
159
160
|
|
|
160
|
-
<img src="../previews/feedback-status-illustration-game.webp" width="480" alt="The
|
|
161
|
+
<img src="../previews/feedback-status-illustration-game.webp" width="480" alt="The game scenes">
|
|
161
162
|
|
|
162
163
|
```tsx
|
|
163
164
|
import { Illustration, IllustrationDefaults } from '@nxgt/material/illustrations';
|
package/docs/guides/theming.md
CHANGED
|
@@ -146,7 +146,7 @@ A backdrop's colours come from the theme; set none on it.
|
|
|
146
146
|
## The neutral palette
|
|
147
147
|
|
|
148
148
|
The default theme's page is plain: pure white in light and the one dark night
|
|
149
|
-
every theme shares (`oklch(0.15 0.026 273)`), whatever the colours.
|
|
149
|
+
every theme shares (`oklch(0.15 0.026 273)`), whatever the colours (the `teal` theme is the exception: it sets `neutrals: 'tinted'`). The default's other
|
|
150
150
|
neutrals (cards in dark, muted, borders, text) are softly tinted toward violet
|
|
151
151
|
(hue 290, low chroma), to sit with the primary indigo instead of fighting it.
|
|
152
152
|
A theme can tint its page too with `neutrals: 'tinted'` in `defineTheme`
|
|
@@ -1171,6 +1171,10 @@ are, without growing what is painted (nothing changes for a mouse):
|
|
|
1171
1171
|
visible label (only an `aria-label`) is still its drawn size plus the
|
|
1172
1172
|
`.nxgt-touch-target` hit area: wrap it in a `<label>` of 44px, or give it a
|
|
1173
1173
|
label.
|
|
1174
|
+
- **A `FilterBar` chip is 44px tall and at least 44px wide**: the quick pills and toggles, the
|
|
1175
|
+
scope pill, an active condition's chip and the default hint (`height` and
|
|
1176
|
+
`min-width`, so a long label still grows it; a mouse keeps 24-28px), and
|
|
1177
|
+
"Add filter" and "Clear all" are 44px tall.
|
|
1174
1178
|
|
|
1175
1179
|
A toast covering a control is out of scope: it physically hides what is under
|
|
1176
1180
|
it.
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/docs/roadmap.md
CHANGED
|
@@ -371,6 +371,7 @@ version they shipped in, and planned entries may name the major they target.
|
|
|
371
371
|
|
|
372
372
|
## Shipped
|
|
373
373
|
|
|
374
|
+
- **Moment (next minor)** — a transient full-screen announcement for a one-off event (a player is eliminated, a role is revealed): a modal dialog named by its title, with an illustration, description, action and tone, dismissed by Escape, a tap, its action or a timer, and no motion under reduced motion ([#2220](https://github.com/softistx/nxgt-material/issues/2220)).
|
|
374
375
|
- **RecordActionsMenu (next minor)** — one menu for a record's lifecycle: archive with an Undo toast (or confirm first with `archivePolicy="confirm"`), restore, and delete that always confirms and shows the backend's refusal, with `ConfirmDialog` gaining `details` and `refusal` slots.
|
|
375
376
|
- **Assistant approval card (next minor)** — `ChatActionProposal` shows an action an assistant proposes, with its status, deadline and Confirm / Reject, and `ChatToolActivity` is a compact row for a tool step in a chat thread ([#2134](https://github.com/softistx/nxgt-material/issues/2134)).
|
|
376
377
|
|
package/docs/troubleshooting.md
CHANGED
|
@@ -386,6 +386,7 @@ words in your error.
|
|
|
386
386
|
- [`defineCodeTheme: "keyword" must be a hex colour`](#definecodetheme-keyword-must-be-a-hex-colour-rgb-or-rrggbb)
|
|
387
387
|
- [A `CodeEditor` shows its code in one colour after another Monaco editor mounts](#a-codeeditor-shows-its-code-in-one-colour-after-another-monaco-editor-mounts)
|
|
388
388
|
- [`primary={false}` has no effect on a `ContactsFormField` with `editing="dialog"`](#primaryfalse-has-no-effect-on-a-contactsformfield-with-editingdialog)
|
|
389
|
+
- [ChatConversationItem collapses to zero width (or its timestamp is clipped) inside a w-fit / max-content / inline-flex / popover parent](#chatconversationitem-collapses-to-zero-width-or-its-timestamp-is-clipped-inside-a-w-fit--max-content--inline-flex--popover-parent)
|
|
389
390
|
|
|
390
391
|
**PDF reader**
|
|
391
392
|
|
|
@@ -2325,6 +2326,17 @@ your own draws a second chevron since the tile adds one.
|
|
|
2325
2326
|
<ListTile title="Notifications" href="/settings/notifications" chevron={false} trailing={<MyArrow />} />
|
|
2326
2327
|
```
|
|
2327
2328
|
|
|
2329
|
+
### A linked DataTable card shows two chevrons
|
|
2330
|
+
|
|
2331
|
+
**When:** a `renderCard` or `renderTile` built on `item.Title`, with
|
|
2332
|
+
`getRowHref` or `onRowClick`, draws a chevron icon of its own.
|
|
2333
|
+
**Why:** a linked `Title` ends with a decorative chevron by default.
|
|
2334
|
+
**Fix:** drop your own, or keep it and pass `chevron={false}`:
|
|
2335
|
+
|
|
2336
|
+
```tsx
|
|
2337
|
+
<Title as="h3" chevron={false}>{row.name}</Title>
|
|
2338
|
+
```
|
|
2339
|
+
|
|
2328
2340
|
### A `ListTile` link reloads the whole page
|
|
2329
2341
|
|
|
2330
2342
|
**When:** a `ListTile` with an `href` is clicked inside a router app: the
|
|
@@ -4891,8 +4903,10 @@ before this fix.
|
|
|
4891
4903
|
control of the list, whichever row was refused.
|
|
4892
4904
|
**Fix:** upgrade to the release that lists this fix in its changelog:
|
|
4893
4905
|
`shouldFocusError` and `setFocus(name)` focus the first refused row's text
|
|
4894
|
-
input
|
|
4895
|
-
|
|
4906
|
+
input, and so do `setFocus('choices.1.text')` and
|
|
4907
|
+
`setError('choices.1.text', …, { shouldFocus: true })` on a row path, as a
|
|
4908
|
+
server's refusal sets. Remove a workaround that queries `[aria-invalid="true"]`
|
|
4909
|
+
after submit. For the other fields, see the next entry.
|
|
4896
4910
|
|
|
4897
4911
|
### `setError(…, { shouldFocus: true })` or a failed submit does not focus the field
|
|
4898
4912
|
|
|
@@ -7063,6 +7077,32 @@ in both modes.
|
|
|
7063
7077
|
**Fix:** use the default `editing="inline"` when the star must go, or drop the
|
|
7064
7078
|
`primary` flag from the value before saving.
|
|
7065
7079
|
|
|
7080
|
+
### `ChatConversationItem collapses to zero width (or its timestamp is clipped) inside a w-fit / max-content / inline-flex / popover parent`
|
|
7081
|
+
|
|
7082
|
+
**When:** a `ChatConversationItem` sits in a parent that sizes to its content
|
|
7083
|
+
(`w-fit`, `max-content`, an inline-flex wrapper, a popover sized to content),
|
|
7084
|
+
after upgrading `@nxgt/material` to the version that fixed the clipped timestamp.
|
|
7085
|
+
|
|
7086
|
+
**Why:** the item now has `contain: inline-size`, so it has no intrinsic width
|
|
7087
|
+
and a long title can no longer widen an auto-sized grid track and push the
|
|
7088
|
+
timestamp out of the list pane. It fills its container (`w-full`); a parent
|
|
7089
|
+
that takes its width from its content gives it zero.
|
|
7090
|
+
|
|
7091
|
+
**Fix:** give the item's parent a width, or, in a grid, use
|
|
7092
|
+
`grid-cols-[minmax(0,1fr)]` on the list that wraps it:
|
|
7093
|
+
|
|
7094
|
+
```tsx
|
|
7095
|
+
// A shrink-to-fit parent: give the item a width.
|
|
7096
|
+
<div className="w-72">
|
|
7097
|
+
<ChatConversationItem title="Support" timestamp="31 août" />
|
|
7098
|
+
</div>
|
|
7099
|
+
|
|
7100
|
+
// In a grid, let the track shrink below the title's width.
|
|
7101
|
+
<ul className="grid grid-cols-[minmax(0,1fr)]">
|
|
7102
|
+
<li><ChatConversationItem title="Support" timestamp="31 août" /></li>
|
|
7103
|
+
</ul>
|
|
7104
|
+
```
|
|
7105
|
+
|
|
7066
7106
|
## PDF reader
|
|
7067
7107
|
|
|
7068
7108
|
### PDF text is missing or in the wrong font in `PdfReader` (cMaps and standard fonts)
|
|
@@ -7651,13 +7691,13 @@ How the presets work is in the [Backgrounds guide](guides/backgrounds.md).
|
|
|
7651
7691
|
### `Background: preset "<id>" is not available in this library yet; drawing "gradient".`
|
|
7652
7692
|
|
|
7653
7693
|
**When:** in development (not when `NODE_ENV` is `production`), the first time a `Background` from `@nxgt/material/backgrounds` gets a `preset` that this library does not draw yet, or a typo from JavaScript. It is printed once per id.
|
|
7654
|
-
**Why:** `BACKGROUND_PRESETS` lists the
|
|
7694
|
+
**Why:** `BACKGROUND_PRESETS` lists the 52 presets; this library draws all of them, the ones in `AVAILABLE_BACKGROUND_PRESETS`. Any other id (a typo from JavaScript) draws the gradient.
|
|
7655
7695
|
**Fix:** use an available preset:
|
|
7656
7696
|
|
|
7657
7697
|
```ts
|
|
7658
7698
|
import { AVAILABLE_BACKGROUND_PRESETS } from '@nxgt/material/backgrounds';
|
|
7659
7699
|
|
|
7660
|
-
console.log(AVAILABLE_BACKGROUND_PRESETS); // the
|
|
7700
|
+
console.log(AVAILABLE_BACKGROUND_PRESETS); // the 52 ids it draws: 'gradient', 'grain', 'mesh', 'aurora', …, 'moon', 'eclipse', …, 'northern-lights', 'icons'
|
|
7661
7701
|
```
|
|
7662
7702
|
|
|
7663
7703
|
### A preset `Background` looks bare, with no error
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
/* The daytime skies, `day-sky` and `dawn-sky`: the dawn's wash, the sun's rays,
|
|
2
|
+
* the horizon glow and the clouds. Imported by celestial.css, which holds the
|
|
3
|
+
* rest of the celestial presets and the shared scene; see its header.
|
|
4
|
+
*
|
|
5
|
+
* Motion (opt-in, `animated`): rays turn, the glow swells, clouds drift;
|
|
6
|
+
* never under `prefers-reduced-motion`. React only. */
|
|
7
|
+
@layer components {
|
|
8
|
+
/* The dawn's wash: a pool low on the left where the sun rises, a lighter one above. */
|
|
9
|
+
[data-background="dawn-sky"] > [data-layer="wash"] {
|
|
10
|
+
position: absolute;
|
|
11
|
+
inset: 0;
|
|
12
|
+
background:
|
|
13
|
+
radial-gradient(
|
|
14
|
+
ellipse 80% 45% at 22% 74%,
|
|
15
|
+
color-mix(in oklab, var(--nxgt-bg-c2) var(--nxgt-bg-a2), transparent),
|
|
16
|
+
transparent 72%
|
|
17
|
+
),
|
|
18
|
+
radial-gradient(
|
|
19
|
+
ellipse 70% 40% at 80% 4%,
|
|
20
|
+
color-mix(in oklab, var(--nxgt-bg-c3) var(--nxgt-bg-a1), transparent),
|
|
21
|
+
transparent 70%
|
|
22
|
+
);
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
/* The sun's rays turn about the sun, the dawn's glow swells from the horizon. */
|
|
26
|
+
[data-background] > [data-scene][data-celestial] .sn > path,
|
|
27
|
+
[data-background] > [data-scene][data-celestial] .hz {
|
|
28
|
+
transform-box: fill-box;
|
|
29
|
+
transform-origin: 50% 100%;
|
|
30
|
+
}
|
|
31
|
+
[data-background] > [data-scene][data-celestial] .sn > path {
|
|
32
|
+
transform-origin: center;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/* The clouds drift sideways from their own box. */
|
|
36
|
+
[data-background]
|
|
37
|
+
> [data-scene][data-celestial]
|
|
38
|
+
:is(.cl-day-sky, .cl-dawn-sky)
|
|
39
|
+
.cd
|
|
40
|
+
> .mo {
|
|
41
|
+
transform-box: fill-box;
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
@media (prefers-reduced-motion: no-preference) {
|
|
46
|
+
@keyframes nxgt-bg-sky-turn {
|
|
47
|
+
to {
|
|
48
|
+
transform: rotate(30deg);
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
@keyframes nxgt-bg-sky-glow {
|
|
52
|
+
to {
|
|
53
|
+
transform: scaleY(1.12);
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
@keyframes nxgt-bg-sky-cloud {
|
|
57
|
+
to {
|
|
58
|
+
transform: translateX(14px);
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
@layer components {
|
|
63
|
+
[data-background][data-animated]
|
|
64
|
+
> [data-scene][data-celestial]
|
|
65
|
+
.cl-day-sky
|
|
66
|
+
.cd
|
|
67
|
+
> .mo,
|
|
68
|
+
[data-background][data-animated]
|
|
69
|
+
> [data-scene][data-celestial]
|
|
70
|
+
.cl-dawn-sky
|
|
71
|
+
.cd
|
|
72
|
+
> .mo {
|
|
73
|
+
animation: nxgt-bg-sky-cloud 18s ease-in-out var(--nxgt-sky-delay, 0s)
|
|
74
|
+
infinite alternate var(--nxgt-bg-play, running);
|
|
75
|
+
}
|
|
76
|
+
[data-background][data-animated] > [data-scene][data-celestial] .sn > path {
|
|
77
|
+
animation: nxgt-bg-sky-turn 60s linear infinite alternate
|
|
78
|
+
var(--nxgt-bg-play, running);
|
|
79
|
+
}
|
|
80
|
+
[data-background][data-animated] > [data-scene][data-celestial] .hz {
|
|
81
|
+
animation: nxgt-bg-sky-glow 14s ease-in-out infinite alternate
|
|
82
|
+
var(--nxgt-bg-play, running);
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
}
|
|
@@ -1,15 +1,14 @@
|
|
|
1
1
|
/* The celestial presets (`eclipse`, `meteor-shower`, `ringed-planet`,
|
|
2
|
-
* `northern-lights`
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
* a
|
|
7
|
-
*
|
|
8
|
-
* watermark in light
|
|
9
|
-
*
|
|
10
|
-
* Motion (opt-in, `animated`): stars twinkle, meteors glide, ribbons drift;
|
|
11
|
-
* never under `prefers-reduced-motion`. React only. */
|
|
2
|
+
* `northern-lights`; `day-sky` and `dawn-sky` are in celestial-day.css) and
|
|
3
|
+
* the `sky` overlay, which draws the moon or one of them over any preset.
|
|
4
|
+
* Core's `/backgrounds/celestial` builds the scenes: the root is
|
|
5
|
+
* `mn cl-<preset>`, the colours are the `k1..k3` and `s1..s3` classes of
|
|
6
|
+
* scene.css, and a scene holds no inline style. Both kinds sit in a
|
|
7
|
+
* `[data-scene][data-celestial]` div, which this file styles. Discreet like
|
|
8
|
+
* `moon.css`: a faint watermark in light, silver light in dark. Motion
|
|
9
|
+
* (opt-in, `animated`): never under `prefers-reduced-motion`. React only. */
|
|
12
10
|
@import "../css/scene.css";
|
|
11
|
+
@import "./celestial-day.css";
|
|
13
12
|
|
|
14
13
|
@layer components {
|
|
15
14
|
/* The wash behind a celestial preset, as the moon's: two faint pools of
|
|
@@ -17,7 +16,8 @@
|
|
|
17
16
|
:is(
|
|
18
17
|
[data-background="eclipse"],
|
|
19
18
|
[data-background="meteor-shower"],
|
|
20
|
-
[data-background="ringed-planet"]
|
|
19
|
+
[data-background="ringed-planet"],
|
|
20
|
+
[data-background="day-sky"]
|
|
21
21
|
) > [data-layer="wash"] {
|
|
22
22
|
position: absolute;
|
|
23
23
|
inset: 0;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
/* DataTable cards and tiles: the trailing action slot (`item.Actions`,
|
|
2
|
+
* partials/layouts/data-table-item-actions.tsx). A sibling of the title, never
|
|
3
|
+
* inside its link, raised above the link's stretched `::after` (z-index 1, as
|
|
4
|
+
* the corner checkbox is) so a click on it never follows the card. At least a
|
|
5
|
+
* 44px target, at the item's end; the item keeps room for it. */
|
|
6
|
+
@layer components {
|
|
7
|
+
[data-slot="data-table-item-actions"] {
|
|
8
|
+
position: absolute;
|
|
9
|
+
z-index: 1;
|
|
10
|
+
inset-inline-end: 0.25rem;
|
|
11
|
+
inset-block-start: 0.625rem;
|
|
12
|
+
display: flex;
|
|
13
|
+
align-items: center;
|
|
14
|
+
justify-content: center;
|
|
15
|
+
gap: 0.25rem;
|
|
16
|
+
min-width: 2.75rem;
|
|
17
|
+
min-height: 2.75rem;
|
|
18
|
+
}
|
|
19
|
+
/* A tile: the slot is centred on the tile, as its checkbox is. */
|
|
20
|
+
[data-slot="data-table-tiles"] [data-slot="data-table-item-actions"] {
|
|
21
|
+
inset-block-start: 50%;
|
|
22
|
+
translate: 0 -50%;
|
|
23
|
+
}
|
|
24
|
+
[data-slot="data-table-cards"][data-density="compact"]
|
|
25
|
+
> [data-slot="data-table-item"]
|
|
26
|
+
> [data-slot="data-table-item-actions"],
|
|
27
|
+
[data-slot="data-table-cards"][data-card-density="compact"]
|
|
28
|
+
> [data-slot="data-table-item"]
|
|
29
|
+
> [data-slot="data-table-item-actions"] {
|
|
30
|
+
inset-block-start: 0.375rem;
|
|
31
|
+
}
|
|
32
|
+
/* Specific enough to win over the density and tile paddings above it. */
|
|
33
|
+
[data-slot="data-table-items"]
|
|
34
|
+
[data-slot="data-table-item"]:has(> [data-slot="data-table-item-actions"]) {
|
|
35
|
+
padding-inline-end: 3.25rem;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/* DataTable cards and tiles: the trailing chevron of a linked `item.Title`
|
|
2
|
+
* (partials/layouts/data-table-item-title.tsx), the affordance `item.Row`
|
|
3
|
+
* draws in its own row. Decorative: centred on the item at its end, under the
|
|
4
|
+
* pointer (the link's `::after` takes the click), and the item keeps room for
|
|
5
|
+
* it. An item with an `item.Actions` slot leaves it out: that slot owns the
|
|
6
|
+
* item's end. */
|
|
7
|
+
@layer components {
|
|
8
|
+
[data-slot="item-chevron"][data-placement="item"] {
|
|
9
|
+
position: absolute;
|
|
10
|
+
inset-inline-end: 0.75rem;
|
|
11
|
+
inset-block-start: 50%;
|
|
12
|
+
translate: 0 -50%;
|
|
13
|
+
pointer-events: none;
|
|
14
|
+
}
|
|
15
|
+
[data-slot="data-table-items"]
|
|
16
|
+
[data-slot="data-table-item"]:has([data-placement="item"]) {
|
|
17
|
+
padding-inline-end: 2.25rem;
|
|
18
|
+
}
|
|
19
|
+
[data-slot="data-table-items"]
|
|
20
|
+
[data-slot="data-table-item"]:has(> [data-slot="data-table-item-actions"])
|
|
21
|
+
[data-placement="item"] {
|
|
22
|
+
display: none;
|
|
23
|
+
}
|
|
24
|
+
[data-slot="data-table-items"]
|
|
25
|
+
[data-slot="data-table-item"]:has(> [data-slot="data-table-item-actions"]) {
|
|
26
|
+
padding-inline-end: 3.25rem;
|
|
27
|
+
}
|
|
28
|
+
}
|
|
@@ -13,6 +13,13 @@
|
|
|
13
13
|
border: 1px solid var(--item-border);
|
|
14
14
|
border-radius: var(--item-radius);
|
|
15
15
|
}
|
|
16
|
+
/* A ServerTable on a phone has no panel of its own: the tile list sits at
|
|
17
|
+
* the page gutter, in line with the heading (#2292). */
|
|
18
|
+
@media (max-width: 767.98px) {
|
|
19
|
+
[data-slot="server-table"] [data-slot="data-table-tiles"] {
|
|
20
|
+
margin-inline: 0;
|
|
21
|
+
}
|
|
22
|
+
}
|
|
16
23
|
[data-slot="data-table-tiles"] > [data-slot="data-table-item"] {
|
|
17
24
|
padding: 0.75rem 1rem;
|
|
18
25
|
min-height: 4.5rem;
|
|
@@ -5,10 +5,14 @@
|
|
|
5
5
|
* data-table-items-bar.css the list bar
|
|
6
6
|
* data-table-items-forced.css forced colours
|
|
7
7
|
* data-table-items-tiles.css tiles: one column, one surface
|
|
8
|
-
* data-table-items-record.css the compact record row of a tile (item.Row)
|
|
8
|
+
* data-table-items-record.css the compact record row of a tile (item.Row)
|
|
9
|
+
* data-table-items-actions.css the trailing action slot (item.Actions)
|
|
10
|
+
* data-table-items-chevron.css the chevron of a linked item.Title */
|
|
9
11
|
@import "./data-table-items.css";
|
|
10
12
|
@import "./data-table-items-compact.css";
|
|
11
13
|
@import "./data-table-items-bar.css";
|
|
12
14
|
@import "./data-table-items-forced.css";
|
|
13
15
|
@import "./data-table-items-tiles.css";
|
|
14
16
|
@import "./data-table-items-record.css";
|
|
17
|
+
@import "./data-table-items-actions.css";
|
|
18
|
+
@import "./data-table-items-chevron.css";
|