@nxgt/material 2.4.2 → 2.6.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/README.md +28 -21
- package/dist/{_Uint8Array-DEXn42kj.js → _Uint8Array-CDlDeQmw.js} +1 -1
- package/dist/_overRest-CWIWQwDJ.js +81 -0
- package/dist/{abnfDiagram-O67JEVCF-C7NxOWqd.js → abnfDiagram-O67JEVCF-Cl4ukf6a.js} +4 -4
- package/dist/{architectureDiagram-NJMV4G6O-BIvwyzEh.js → architectureDiagram-NJMV4G6O-WmFlBQF5.js} +7 -7
- package/dist/{client-only.utils-DhcBUmau.js → async-slice-Qoen0Mqm.js} +164 -93
- package/dist/{blockDiagram-BEXU5L5S-CzgMFdtn.js → blockDiagram-BEXU5L5S-_6EVgQ2-.js} +11 -11
- package/dist/{c4Diagram-YGBWAQC7-WgqlRIL5.js → c4Diagram-YGBWAQC7-D9xSt2QO.js} +8 -8
- package/dist/{channel-Ba8pEAWx.js → channel-Dg92Hoym.js} +1 -1
- package/dist/{chunk-3FUC2YCW-DnIzetwB.js → chunk-3FUC2YCW-CRQHl-Jx.js} +8 -8
- package/dist/{chunk-5DYCD2WN-Bqi3iL5i.js → chunk-5DYCD2WN-Cja1INgd.js} +3 -3
- package/dist/{chunk-6AEJRKK7-DDXoGWDs.js → chunk-6AEJRKK7-3YWRP4aV.js} +2 -2
- package/dist/{chunk-742MDFTN-nG_ROTnT.js → chunk-742MDFTN-Cs1qGiTK.js} +2 -2
- package/dist/{chunk-7INBJB4K-Dg64CbhT.js → chunk-7INBJB4K-BY5n77ka.js} +6 -6
- package/dist/{chunk-7M6MHVWA-CPdb6LVf.js → chunk-7M6MHVWA-DqXpf6CM.js} +9 -9
- package/dist/{chunk-7PRAP22T-DIiYRAce.js → chunk-7PRAP22T-_Av9vcXz.js} +1 -1
- package/dist/{chunk-GNY47TPC-CxWZwDbp.js → chunk-GNY47TPC-BgMsLbCS.js} +11 -11
- package/dist/{chunk-GTNCS2PH-CzDYTYNy.js → chunk-GTNCS2PH-BZ9WMD1v.js} +3 -3
- package/dist/{chunk-GWA4HPMP-CmsxMX3A.js → chunk-GWA4HPMP-Co-A6dtV.js} +3 -3
- package/dist/{chunk-MBY4JIJT-IA2XBafa.js → chunk-MBY4JIJT-C3RQP_Nk.js} +4 -4
- package/dist/{chunk-NETBCI7D-Cq92-0cA.js → chunk-NETBCI7D-CsyH43bj.js} +1 -1
- package/dist/{chunk-O7XYJQB3-C87zK8E5.js → chunk-O7XYJQB3-A66QSOPA.js} +1 -1
- package/dist/{chunk-UA2S7LBM-B0LGFGu3.js → chunk-UA2S7LBM-BNeHeMx9.js} +6 -6
- package/dist/{chunk-WEXAMYUT-C-QP0DFq.js → chunk-WEXAMYUT-CucJfehv.js} +2 -2
- package/dist/{chunk-XXDRQBXY-Bq4sFnO2.js → chunk-XXDRQBXY-FgXU14Bh.js} +1 -1
- package/dist/{chunk-Z7XXMR3K-vh8Pvgr_.js → chunk-Z7XXMR3K-CoCjTVVx.js} +8 -8
- package/dist/{chunk-ZIGJFQKS-HDJ6e6OJ.js → chunk-ZIGJFQKS-C3xUAXJq.js} +3 -3
- package/dist/{classDiagram-v2-NBCMYWYE-BSyQx7Df.js → classDiagram-v2-NBCMYWYE-j4vk04t-.js} +14 -14
- package/dist/{components-C3jpOwPw.js → components-C3wIUrWw.js} +26931 -25668
- package/dist/components.js +6 -6
- package/dist/{cose-bilkent-JH36ORCC-11-T1rfk.js → cose-bilkent-JH36ORCC-DRUT3qBb.js} +2 -2
- package/dist/{cynefinDiagram-VND7K2PF-1kHi2rGa.js → cynefinDiagram-VND7K2PF-B9HrdQW8.js} +4 -4
- package/dist/{dagre-6A5THRUB-BDk37t1_.js → dagre-6A5THRUB-DXq_YBNL.js} +572 -613
- package/dist/{diagram-22UHCM2B-BvH24G-C.js → diagram-22UHCM2B-He8NDldw.js} +15 -15
- package/dist/{diagram-3UASUU5V-DAKVPT0Q.js → diagram-3UASUU5V-CeILva4U.js} +7 -7
- package/dist/{diagram-ATOU4E4O-Clju_0RY.js → diagram-ATOU4E4O-CNY-8kl0.js} +3 -3
- package/dist/{diagram-CDSNMT55-w7kkJ6MU.js → diagram-CDSNMT55-C8Mk1smi.js} +5 -5
- package/dist/{diagram-MLGK6HIB-mUOtRVmm.js → diagram-MLGK6HIB-CpfeILwW.js} +4 -4
- package/dist/{diagram-MPIPVDR6-DEUw58dq.js → diagram-MPIPVDR6-Do7bUnTd.js} +4 -4
- package/dist/{dist-gYpAi-su.js → dist-C3YK_ean.js} +1 -1
- package/dist/{dist-CeHNxLJG.js → dist-CRbPtqwD.js} +1 -1
- package/dist/dnd.js +1 -1
- package/dist/{ebnfDiagram-ZINNZB2B-BYfatie5.js → ebnfDiagram-ZINNZB2B-1GewX9Zq.js} +4 -4
- package/dist/{elk-276RUBZZ-CtsHzWCy.js → elk-276RUBZZ-DFn4kTey.js} +13 -13
- package/dist/{erDiagram-OPXOYQCR-DTrqayuU.js → erDiagram-OPXOYQCR-BzVUcUwh.js} +14 -14
- package/dist/{field-blur-EUOqpHbF.js → field-blur-BlrE9fOD.js} +1109 -1083
- package/dist/flowDiagram-KWPJA3E3-B4pJCj2Q.js +17 -0
- package/dist/{ganttDiagram-FUAMR5RP-DxWSt8R4.js → ganttDiagram-FUAMR5RP-B4A4UFFi.js} +6 -6
- package/dist/{gitGraphDiagram-X574FWY7-DcGaPSwy.js → gitGraphDiagram-X574FWY7-80yOq8dE.js} +3 -3
- package/dist/{graphlib-BOTXrGOf.js → graphlib-CQ3hLS1N.js} +103 -139
- package/dist/hooks.js +2 -2
- package/dist/{i18n-provider-XTTU9ArK.js → i18n-provider-CbYD2KxP.js} +1 -1
- package/dist/i18n.js +6 -6
- package/dist/{icon-button-Dl9PDYCE.js → icon-button-BxySFfrr.js} +581 -581
- package/dist/{infoDiagram-VRGFBTTK-Cvj167dl.js → infoDiagram-VRGFBTTK-Cboh-B9n.js} +3 -3
- package/dist/isArrayLikeObject-5rnYwEK7.js +28 -0
- package/dist/isEmpty-DChvniYe.js +53 -0
- package/dist/{ishikawaDiagram-OU5B5YK6-ChBwjCfr.js → ishikawaDiagram-OU5B5YK6-DwTd1YxL.js} +4 -4
- package/dist/{journeyDiagram-ZHPQQLJL-BycdRLE6.js → journeyDiagram-ZHPQQLJL-C91SPPkY.js} +4 -4
- package/dist/{kanban-definition-PNTS6WVX-BRoa-Yp5.js → kanban-definition-PNTS6WVX-S8plI4wn.js} +10 -10
- package/dist/lib/components/ui/actions/button/button.compound-variants.d.ts +114 -0
- package/dist/lib/components/ui/actions/button/button.d.ts +4 -7
- package/dist/lib/components/ui/actions/button/button.variants.d.ts +7 -0
- package/dist/lib/components/ui/actions/button/has-text-content.d.ts +10 -0
- package/dist/lib/components/ui/actions/icon-button/icon-button.variants.d.ts +1 -1
- package/dist/lib/components/ui/collections/data-table/data-table-context.d.ts +4 -0
- package/dist/lib/components/ui/collections/data-table/data-table-pagination.d.ts +3 -1
- package/dist/lib/components/ui/collections/data-table/data-table.d.ts +12 -2
- package/dist/lib/components/ui/collections/data-table/hooks.d.ts +13 -13
- package/dist/lib/components/ui/collections/data-table/partials/data-table-body.d.ts +9 -5
- package/dist/lib/components/ui/collections/data-table/partials/data-table-empty-row.d.ts +14 -0
- package/dist/lib/components/ui/collections/data-table/partials/data-table-skeleton-rows.d.ts +7 -0
- package/dist/lib/components/ui/collections/filter/filter-field-number-range.d.ts +15 -0
- package/dist/lib/components/ui/collections/pagination/index.d.ts +1 -1
- package/dist/lib/components/ui/collections/pagination/pagination.d.ts +9 -1
- package/dist/lib/components/ui/collections/tree/use-tree.d.ts +2 -0
- package/dist/lib/components/ui/dates/date-range-field/date-range-field-trigger.d.ts +1 -1
- package/dist/lib/components/ui/dates/date-range-field/date-range-field.d.ts +10 -1
- package/dist/lib/components/ui/dates/date-range-field/date-range-field.utils.d.ts +13 -0
- package/dist/lib/components/ui/dates/date-range-field/index.d.ts +1 -0
- package/dist/lib/components/ui/dates/date-range-field/partials/date-range-field-content.d.ts +25 -0
- package/dist/lib/components/ui/dates/date-range-field/partials/date-range-presets.d.ts +11 -0
- package/dist/lib/components/ui/dates/date-range-field/partials/date-range-times.d.ts +11 -0
- package/dist/lib/components/ui/dates/date-range-field/use-date-range-presets.d.ts +22 -0
- package/dist/lib/components/ui/dates/time-picker/time-picker-utils.d.ts +7 -0
- package/dist/lib/components/ui/display/chip/chip.d.ts +1 -1
- package/dist/lib/components/ui/feedback/toast/toast.d.ts +9 -4
- package/dist/lib/components/ui/fields/number-field/number-field.d.ts +3 -1
- package/dist/lib/components/ui/fields/otp-field/index.d.ts +1 -0
- package/dist/lib/components/ui/fields/otp-field/input-otp.d.ts +1 -1
- package/dist/lib/components/ui/fields/slider/slider-header.d.ts +19 -0
- package/dist/lib/components/ui/fields/slider/slider-readout.d.ts +5 -1
- package/dist/lib/components/ui/fields/slider/slider.d.ts +7 -0
- package/dist/lib/components/ui/fields/switch/switch.d.ts +7 -0
- package/dist/lib/components/ui/layout/stepper/stepper-step.d.ts +17 -0
- package/dist/lib/components/ui/media/camera/camera-content.d.ts +1 -2
- package/dist/lib/components/ui/media/camera/camera-context.d.ts +4 -0
- package/dist/lib/components/ui/media/camera/camera-provider.d.ts +2 -0
- package/dist/lib/components/ui/media/camera/camera.d.ts +6 -3
- package/dist/lib/components/ui/media/camera/capture-photo.d.ts +13 -0
- package/dist/lib/components/ui/media/camera/index.d.ts +9 -1
- package/dist/lib/components/ui/media/camera/state/camera.reducers.d.ts +1 -1
- package/dist/lib/components/ui/media/camera/state/camera.slice.d.ts +4 -9
- package/dist/lib/components/ui/media/camera/state/camera.store.d.ts +11 -5
- package/dist/lib/components/ui/media/camera/state/camera.thunks.d.ts +4 -4
- package/dist/lib/components/ui/media/camera/types.d.ts +19 -9
- package/dist/lib/components/ui/media/camera/use-camera.d.ts +5 -11
- package/dist/lib/components/ui/media/camera/utils/camera.utils.d.ts +0 -1
- package/dist/lib/components/ui/media/file-preview/file-preview-pdf.lazy.d.ts +9 -0
- package/dist/lib/components/ui/media/file-preview/file-preview.d.ts +12 -0
- package/dist/lib/components/ui/media/file-preview/index.d.ts +3 -0
- package/dist/lib/components/ui/media/file-preview/partials/file-preview-body.d.ts +9 -0
- package/dist/lib/components/ui/media/file-preview/partials/file-preview-card.d.ts +20 -0
- package/dist/lib/components/ui/media/file-preview/partials/file-preview-media.d.ts +11 -0
- package/dist/lib/components/ui/media/file-preview/partials/file-preview-pdf.d.ts +10 -0
- package/dist/lib/components/ui/media/file-preview/partials/file-preview-status.d.ts +17 -0
- package/dist/lib/components/ui/media/file-preview/partials/file-preview-text.d.ts +13 -0
- package/dist/lib/components/ui/media/file-preview/types.d.ts +23 -0
- package/dist/lib/components/ui/media/file-preview/use-file-preview.d.ts +22 -0
- package/dist/lib/components/ui/media/file-preview/use-text-preview.d.ts +15 -0
- package/dist/lib/components/ui/media/index.d.ts +2 -0
- package/dist/lib/components/ui/media/upload/network-upload-field/use-image-preview.d.ts +6 -0
- package/dist/lib/components/ui/overlays/dialog/dialog-outside.d.ts +5 -0
- package/dist/lib/components/ui/overlays/dialog/dialog-scroll-content.d.ts +9 -0
- package/dist/lib/components/ui/overlays/dialog/index.d.ts +1 -0
- package/dist/lib/components/ui/primitives/icon/icon-context.d.ts +1 -1
- package/dist/lib/components/ui/primitives/table/table.d.ts +6 -1
- package/dist/lib/components/ui/selection/index.d.ts +2 -0
- package/dist/lib/components/ui/selection/native-select/index.d.ts +1 -0
- package/dist/lib/components/ui/selection/native-select/native-select.d.ts +11 -0
- package/dist/lib/components/ui/selection/radio-group/radio-group.d.ts +8 -1
- package/dist/lib/components/ui/selection/tree-select-field/index.d.ts +2 -0
- package/dist/lib/components/ui/selection/tree-select-field/partials/tree-select-content.d.ts +13 -0
- package/dist/lib/components/ui/selection/tree-select-field/partials/tree-select-panel.d.ts +19 -0
- package/dist/lib/components/ui/selection/tree-select-field/partials/tree-select-trigger.d.ts +24 -0
- package/dist/lib/components/ui/selection/tree-select-field/tree-select-field.d.ts +9 -0
- package/dist/lib/components/ui/selection/tree-select-field/tree-select-form-field.d.ts +8 -0
- package/dist/lib/components/ui/selection/tree-select-field/tree-select.utils.d.ts +35 -0
- package/dist/lib/components/ui/selection/tree-select-field/types.d.ts +37 -0
- package/dist/lib/components/ui/selection/tree-select-field/use-tree-select-field.d.ts +20 -0
- package/dist/lib/i18n/resources/en/en.d.ts +40 -0
- package/dist/lib/i18n/resources/en/material.json.d.ts +43 -3
- package/dist/lib/i18n/resources/fr/fr.d.ts +40 -0
- package/dist/lib/i18n/resources/fr/material.json.d.ts +43 -3
- package/dist/lib/i18n/resources/resources.d.ts +80 -0
- package/dist/lib/i18n/translator.d.ts +1 -1
- package/dist/lib/lib/redux/status-slice.d.ts +1 -1
- package/dist/lib.js +295 -4
- package/dist/main.js +16 -16
- package/dist/map.js +5 -5
- package/dist/material.css +1 -1
- package/dist/merge-_Awk4ywA.js +156 -0
- package/dist/{mermaid.core-BGAQ3ZAZ.js → mermaid.core-DciYB1MV.js} +49 -49
- package/dist/{mindmap-definition-NLK3R4M7-HIqs4Eil.js → mindmap-definition-NLK3R4M7-Brf_2jIE.js} +13 -13
- package/dist/{pegDiagram-GJSIUBJH-Dcm3LCQX.js → pegDiagram-GJSIUBJH-CAO6aYvj.js} +4 -4
- package/dist/{pieDiagram-5QR66LMP-DQ6djEkW.js → pieDiagram-5QR66LMP-MPh-EWf-.js} +5 -5
- package/dist/print.js +2 -2
- package/dist/{quadrantDiagram-O4NWA36T-yUWorB72.js → quadrantDiagram-O4NWA36T-CwDeE9KB.js} +3 -3
- package/dist/{railroadDiagram-XR7U4H2S-CzOJlTUA.js → railroadDiagram-XR7U4H2S-DmKDXg8V.js} +4 -4
- package/dist/{requirementDiagram-PLB6GJNP-Cs5-8Nro.js → requirementDiagram-PLB6GJNP-CCP3YtvB.js} +13 -13
- package/dist/{sankeyDiagram-IPEJSGJF-CCqxyVoj.js → sankeyDiagram-IPEJSGJF-vgVchd2a.js} +3 -3
- package/dist/{sequenceDiagram-PO4LG4MO-DMLeIQ03.js → sequenceDiagram-PO4LG4MO-B2qb55A5.js} +5 -5
- package/dist/{sortable-provider-DuRzFvwe.js → sortable-provider-CzSnl6It.js} +17 -17
- package/dist/{src-CJ8DNrI1.js → src-C9kQSo6K.js} +1 -1
- package/dist/{stateDiagram-v2-GCMORJYK-D-8sLHg8.js → stateDiagram-v2-GCMORJYK-T-oIXh-8.js} +14 -14
- package/dist/{stored-language-BP90Ydtg.js → stored-language-DmUUhRb5.js} +90 -6
- package/dist/{swimlanes-2SLR337P-DM_lDm6v.js → swimlanes-2SLR337P-tW3_wBWO.js} +12 -12
- package/dist/swimlanesDiagram-TC7HE7FX-B1lWzHp1.js +28 -0
- package/dist/{timeline-definition-EJHVYXUP-D3Tz-JnK.js → timeline-definition-EJHVYXUP-SdA6wt2-.js} +5 -5
- package/dist/{translate-material-Ctzt0Y2N.js → translate-material-DuY12xca.js} +2 -2
- package/dist/{translator-Cfug7hC5.js → translator-CaIYjyFP.js} +1 -1
- package/dist/{use-heading-spy-DtVo2HBk.js → use-heading-spy-Crdz4OH5.js} +2 -2
- package/dist/{use-material-translation-CJswHOmK.js → use-material-translation-Od0QsFPA.js} +2 -2
- package/dist/{usecaseDiagram-POWQR4AR-Cxx8PDrr.js → usecaseDiagram-POWQR4AR-B3rBcR4E.js} +13 -13
- package/dist/{vennDiagram-UO4OBE2U-Aql8mhcy.js → vennDiagram-UO4OBE2U-CO0yFCI8.js} +4 -4
- package/dist/{wardleyDiagram-VNRHLVJA-tknlhG_t.js → wardleyDiagram-VNRHLVJA-QkwghAYo.js} +4 -4
- package/dist/{xychartDiagram-PMCCYNJV-CM0QlWD5.js → xychartDiagram-PMCCYNJV-stQWLgCx.js} +7 -7
- package/docs/components/README.md +2 -1
- package/docs/components/buttons-and-actions.md +8 -3
- package/docs/components/data-display.md +4 -4
- package/docs/components/data-table-filter-and-lists.md +100 -6
- package/docs/components/date-and-time.md +106 -6
- package/docs/components/feedback-and-status.md +4 -3
- package/docs/components/form-fields.md +55 -5
- package/docs/components/media-and-files.md +117 -8
- package/docs/components/navigation-and-layout.md +6 -1
- package/docs/components/overlays-and-menus.md +27 -2
- package/docs/components/primitives.md +34 -3
- package/docs/components/rich-widgets.md +1 -1
- package/docs/components/selection-and-choice.md +111 -8
- package/docs/guides/forms.md +2 -1
- package/docs/guides/i18n.md +58 -9
- package/docs/guides/ssr.md +3 -1
- package/docs/previews/date-time-daterangefield.webp +0 -0
- package/docs/previews/media-files-camera.webp +0 -0
- package/docs/previews/media-files-filepreview.webp +0 -0
- package/docs/previews/navigation-layout-stepper.webp +0 -0
- package/docs/previews/selection-choice-treeselectfield.webp +0 -0
- package/docs/roadmap.md +42 -3
- package/docs/troubleshooting.md +167 -0
- package/package.json +2 -2
- package/dist/flowDiagram-KWPJA3E3-B8Isvcc5.js +0 -17
- package/dist/isArrayLikeObject-CCJDO2RL.js +0 -86
- package/dist/lib/components/ui/fields/slider/slider-ticks.d.ts +0 -1
- package/dist/lib/components/ui/media/camera/camera.provider.d.ts +0 -6
- package/dist/lib/components/ui/media/camera/state/index.d.ts +0 -2
- package/dist/lib/components/ui/media/camera/utils/index.d.ts +0 -1
- package/dist/lib-DIj5dvbb.js +0 -367
- package/dist/merge-Dm-kHFxo.js +0 -172
- package/dist/swimlanesDiagram-TC7HE7FX-CbV1TsML.js +0 -28
|
@@ -61,7 +61,32 @@ import {
|
|
|
61
61
|
|
|
62
62
|
Parts: `Dialog`, `DialogTrigger`, `DialogContent`, `DialogHeader`,
|
|
63
63
|
`DialogTitle`, `DialogDescription`, `DialogFooter`, `DialogClose`, plus
|
|
64
|
-
`DialogOverlay` and `DialogPortal
|
|
64
|
+
`DialogOverlay` and `DialogPortal`, and `DialogScrollContent`: a content for
|
|
65
|
+
a dialog taller than the screen, which sits in a scrolling overlay with a
|
|
66
|
+
margin instead of being clipped, and renders its own close button. It takes
|
|
67
|
+
`DialogContent`'s props and moves and returns focus the same way.
|
|
68
|
+
|
|
69
|
+
```tsx
|
|
70
|
+
import { Button, Dialog, DialogScrollContent, DialogTitle, DialogTrigger } from '@nxgt/material/components';
|
|
71
|
+
|
|
72
|
+
const clauses = Array.from({ length: 30 }, (_, i) => `Clause ${i + 1}. Either party may end the service with thirty days' notice.`);
|
|
73
|
+
|
|
74
|
+
export function Terms() {
|
|
75
|
+
return (
|
|
76
|
+
<Dialog>
|
|
77
|
+
<DialogTrigger>
|
|
78
|
+
<Button>Read the terms</Button>
|
|
79
|
+
</DialogTrigger>
|
|
80
|
+
<DialogScrollContent>
|
|
81
|
+
<DialogTitle>Terms of service</DialogTitle>
|
|
82
|
+
{clauses.map((clause) => (
|
|
83
|
+
<p key={clause}>{clause}</p>
|
|
84
|
+
))}
|
|
85
|
+
</DialogScrollContent>
|
|
86
|
+
</Dialog>
|
|
87
|
+
);
|
|
88
|
+
}
|
|
89
|
+
```
|
|
65
90
|
|
|
66
91
|
| Prop | Type | Default | Effect |
|
|
67
92
|
| --- | --- | --- | --- |
|
|
@@ -105,7 +130,7 @@ export function RenameButton() {
|
|
|
105
130
|
}
|
|
106
131
|
```
|
|
107
132
|
|
|
108
|
-
**Storybook:** `Overlays & menus/Dialog` · **Vue:** `Dialog` (same parts)
|
|
133
|
+
**Storybook:** `Overlays & menus/Dialog` · **Vue:** `Dialog` (same parts)
|
|
109
134
|
|
|
110
135
|
---
|
|
111
136
|
|
|
@@ -516,11 +516,42 @@ import {
|
|
|
516
516
|
```
|
|
517
517
|
|
|
518
518
|
Parts: `Table`, `TableHeader`, `TableBody`, `TableFooter`, `TableRow`,
|
|
519
|
-
`TableHead`, `TableCell`, `TableCaption` — each takes its HTML element's props
|
|
519
|
+
`TableHead`, `TableCell`, `TableCaption` — each takes its HTML element's props
|
|
520
|
+
— plus `TableEmpty`, a full-width row for "nothing here" (`colSpan`, default
|
|
521
|
+
`1`; the content is centred):
|
|
522
|
+
|
|
523
|
+
```tsx
|
|
524
|
+
import { Table, TableBody, TableCell, TableEmpty, TableHead, TableHeader, TableRow } from '@nxgt/material/components';
|
|
525
|
+
|
|
526
|
+
type Invoice = { id: string; amount: string };
|
|
527
|
+
|
|
528
|
+
export function Invoices({ invoices }: { invoices: Invoice[] }) {
|
|
529
|
+
return (
|
|
530
|
+
<Table>
|
|
531
|
+
<TableHeader>
|
|
532
|
+
<TableRow>
|
|
533
|
+
<TableHead>Invoice</TableHead>
|
|
534
|
+
<TableHead className="text-right">Amount</TableHead>
|
|
535
|
+
</TableRow>
|
|
536
|
+
</TableHeader>
|
|
537
|
+
<TableBody>
|
|
538
|
+
{invoices.length === 0 && <TableEmpty colSpan={2}>No invoices yet.</TableEmpty>}
|
|
539
|
+
{invoices.map((invoice) => (
|
|
540
|
+
<TableRow key={invoice.id}>
|
|
541
|
+
<TableCell>{invoice.id}</TableCell>
|
|
542
|
+
<TableCell className="text-right">{invoice.amount}</TableCell>
|
|
543
|
+
</TableRow>
|
|
544
|
+
))}
|
|
545
|
+
</TableBody>
|
|
546
|
+
</Table>
|
|
547
|
+
);
|
|
548
|
+
}
|
|
549
|
+
```
|
|
550
|
+
|
|
520
551
|
For sorting, paging and selection use `DataTable` on the
|
|
521
552
|
[Data table, filter & lists](data-table-filter-and-lists.md) page.
|
|
522
553
|
|
|
523
|
-
**Storybook:** `Primitives/Table` · **Vue:** `Table` (same parts)
|
|
554
|
+
**Storybook:** `Primitives/Table` · **Vue:** `Table` (same parts)
|
|
524
555
|
|
|
525
556
|
---
|
|
526
557
|
|
|
@@ -562,7 +593,7 @@ Parts: `Tabs`, `TabsList`, `TabsTrigger`, `TabsContent`.
|
|
|
562
593
|
| `onValueChange` (`Tabs`) | `(value: string) => void` | — | called when a trigger is selected |
|
|
563
594
|
| `icon` (`TabsTrigger`) | `ReactNode` | — | shown before the label (above it on the phone in `bar`) |
|
|
564
595
|
|
|
565
|
-
**Storybook:** `Primitives/Tabs` · **Vue:** `Tabs` (same parts)
|
|
596
|
+
**Storybook:** `Primitives/Tabs` · **Vue:** `Tabs` (same parts, `variant="line"`)
|
|
566
597
|
|
|
567
598
|
---
|
|
568
599
|
|
|
@@ -372,7 +372,7 @@ function Config() {
|
|
|
372
372
|
|
|
373
373
|
**Form wrapper:** `CodeEditorFormField` — `control` and `name`, see
|
|
374
374
|
[forms](../guides/forms.md).
|
|
375
|
-
**Storybook:** `Rich widgets/CodeEditor` · **Vue:** `CodeEditor`
|
|
375
|
+
**Storybook:** `Rich widgets/CodeEditor` · **Vue:** `CodeEditor` (`options`), `CodeEditorFormField`
|
|
376
376
|
|
|
377
377
|
---
|
|
378
378
|
|
|
@@ -10,7 +10,7 @@ value type each one writes. Everything is imported from
|
|
|
10
10
|
|
|
11
11
|
| | Component | What it does |
|
|
12
12
|
| --- | --- | --- |
|
|
13
|
-
| <img src="../previews/selection-choice-select.webp" width="96" alt=""> | [Select](#select) | Select primitives with groups and labels |
|
|
13
|
+
| <img src="../previews/selection-choice-select.webp" width="96" alt=""> | [Select](#select) | Select primitives with groups and labels, and a styled native `<select>` |
|
|
14
14
|
| <img src="../previews/selection-choice-selectfield.webp" width="96" alt=""> | [SelectField](#selectfield) | Labelled select built from `options` |
|
|
15
15
|
| <img src="../previews/selection-choice-combobox.webp" width="96" alt=""> | [Combobox](#combobox) | Base UI combobox primitives |
|
|
16
16
|
| <img src="../previews/selection-choice-comboboxfield.webp" width="96" alt=""> | [ComboboxField](#comboboxfield) | Labelled, searchable single select |
|
|
@@ -23,6 +23,7 @@ value type each one writes. Everything is imported from
|
|
|
23
23
|
| <img src="../previews/selection-choice-selectchipfield.webp" width="96" alt=""> | [SelectChipField](#selectchipfield) | Choice shown as chips |
|
|
24
24
|
| <img src="../previews/selection-choice-transferlist.webp" width="96" alt=""> | [TransferList](#transferlist) | Two-pane picker |
|
|
25
25
|
| <img src="../previews/selection-choice-sortablelist.webp" width="96" alt=""> | [SortableList](#sortablelist) | Reorderable list of strings |
|
|
26
|
+
| <img src="../previews/selection-choice-treeselectfield.webp" width="96" alt=""> | [TreeSelectField](#treeselectfield) | Pick from a tree, single or multiple |
|
|
26
27
|
| <img src="../previews/selection-choice-switcher.webp" width="96" alt=""> | [Switcher](#switcher) | Workspace or account switcher |
|
|
27
28
|
|
|
28
29
|
## Select
|
|
@@ -73,9 +74,32 @@ Parts: `Select`, `SelectTrigger`, `SelectValue`, `SelectContent`,
|
|
|
73
74
|
| `SelectContent` `position` | `'popper' \| 'item-aligned'` | `'popper'` | below the trigger, as wide as it; `item-aligned` overlays it macOS-style |
|
|
74
75
|
| `SelectTrigger` `size` | `'sm' \| 'default'` | `'default'` | trigger height |
|
|
75
76
|
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
77
|
+
`NativeSelect` is the browser's own `<select>` with the library's styling and
|
|
78
|
+
chevron, for when the platform picker is what you want (long lists on a
|
|
79
|
+
phone, no portal). Parts: `NativeSelect`, `NativeSelectOption`,
|
|
80
|
+
`NativeSelectOptGroup`; `value` / `defaultValue` / `onChange`, `className`
|
|
81
|
+
and every other attribute go to the `<select>`.
|
|
82
|
+
|
|
83
|
+
```tsx
|
|
84
|
+
import { NativeSelect, NativeSelectOptGroup, NativeSelectOption } from '@nxgt/material/components';
|
|
85
|
+
import { useState } from 'react';
|
|
86
|
+
|
|
87
|
+
export function Food() {
|
|
88
|
+
const [food, setFood] = useState('banana');
|
|
89
|
+
return (
|
|
90
|
+
<NativeSelect aria-label="Food" value={food} onChange={(event) => setFood(event.target.value)}>
|
|
91
|
+
<NativeSelectOptGroup label="Fruits">
|
|
92
|
+
<NativeSelectOption value="apple">Apple</NativeSelectOption>
|
|
93
|
+
<NativeSelectOption value="banana">Banana</NativeSelectOption>
|
|
94
|
+
</NativeSelectOptGroup>
|
|
95
|
+
</NativeSelect>
|
|
96
|
+
);
|
|
97
|
+
}
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
**Emits:** `string` through `onValueChange` (`Select`), a change event
|
|
101
|
+
(`NativeSelect`). For a form, use `SelectField` / `SelectFormField`.
|
|
102
|
+
**Storybook:** `Selection & choice/Select` · **Vue:** `Select` (same parts), `NativeSelect` (same parts)
|
|
79
103
|
|
|
80
104
|
---
|
|
81
105
|
|
|
@@ -114,7 +138,7 @@ export function Framework() {
|
|
|
114
138
|
**Emits:** `string`.
|
|
115
139
|
**Form wrapper:** `SelectFormField` — `control` and `name`, see
|
|
116
140
|
[forms](../guides/forms.md#the-pair) and [what each field emits](../guides/forms.md#what-each-field-emits).
|
|
117
|
-
**Storybook:** `Selection & choice/SelectField` · **Vue:** `SelectField`, `SelectFormField`
|
|
141
|
+
**Storybook:** `Selection & choice/SelectField` · **Vue:** `SelectField`, `SelectFormField` (`#option` slot for `renderOption`)
|
|
118
142
|
|
|
119
143
|
---
|
|
120
144
|
|
|
@@ -268,7 +292,7 @@ Parts: `Autocomplete`, `AutocompleteChips` (the chips row it uses in
|
|
|
268
292
|
**Emits:** `string | null` in `single` mode, `string[]` in `multiple`.
|
|
269
293
|
**Form wrapper:** `AutocompleteFormField` — `control` and `name`, see
|
|
270
294
|
[forms](../guides/forms.md#the-pair) and [what each field emits](../guides/forms.md#what-each-field-emits).
|
|
271
|
-
**Storybook:** `Selection & choice/Autocomplete` · **Vue:** `Autocomplete`, `AutocompleteFormField`
|
|
295
|
+
**Storybook:** `Selection & choice/Autocomplete` · **Vue:** `Autocomplete`, `AutocompleteFormField` (generic; `#option`, `#selected-leading`, `#actions` slots)
|
|
272
296
|
|
|
273
297
|
---
|
|
274
298
|
|
|
@@ -297,7 +321,7 @@ the field's `name`, which two forms on one page shared).
|
|
|
297
321
|
and `null` for indeterminate.
|
|
298
322
|
**Form wrapper:** `CheckboxFormField` — `control` and `name`, see
|
|
299
323
|
[forms](../guides/forms.md#the-pair) and [what each field emits](../guides/forms.md#what-each-field-emits).
|
|
300
|
-
**Storybook:** `Selection & choice/Checkbox` · **Vue:** `Checkbox`
|
|
324
|
+
**Storybook:** `Selection & choice/Checkbox` · **Vue:** `Checkbox`, `CheckboxFormField`
|
|
301
325
|
|
|
302
326
|
---
|
|
303
327
|
|
|
@@ -372,7 +396,10 @@ export function Plan() {
|
|
|
372
396
|
```
|
|
373
397
|
|
|
374
398
|
Parts: `RadioGroup` (labelled, from `options`) and `RadioGroupItem` (one
|
|
375
|
-
radio, for a hand-built layout).
|
|
399
|
+
radio, for a hand-built layout). `RadioGroupField` is the same component under
|
|
400
|
+
`@nxgt/material-vue`'s name (an alias, `RadioGroupFieldProps` for its props),
|
|
401
|
+
so code reads the same in both libraries; neither name is deprecated, and the
|
|
402
|
+
full naming alignment is planned for 3.0.
|
|
376
403
|
|
|
377
404
|
| Prop | Type | Default | Effect |
|
|
378
405
|
| --- | --- | --- | --- |
|
|
@@ -601,6 +628,82 @@ export function Ranking() {
|
|
|
601
628
|
|
|
602
629
|
---
|
|
603
630
|
|
|
631
|
+
## TreeSelectField
|
|
632
|
+
|
|
633
|
+

|
|
634
|
+
|
|
635
|
+
A field that opens a `Tree` in a popover: pick one node, or several as chips,
|
|
636
|
+
with an optional filter.
|
|
637
|
+
|
|
638
|
+
The field is controlled only: it holds no value of its own. Pass `value` and update it in `onValueChange`;
|
|
639
|
+
without it, a pick changes nothing on screen.
|
|
640
|
+
|
|
641
|
+
```tsx
|
|
642
|
+
import { TreeSelectField, type TreeNode } from '@nxgt/material/components';
|
|
643
|
+
import { useState } from 'react';
|
|
644
|
+
|
|
645
|
+
const regions: TreeNode[] = [
|
|
646
|
+
{
|
|
647
|
+
id: 'europe',
|
|
648
|
+
label: 'Europe',
|
|
649
|
+
children: [
|
|
650
|
+
{ id: 'france', label: 'France' },
|
|
651
|
+
{ id: 'spain', label: 'Spain' },
|
|
652
|
+
],
|
|
653
|
+
},
|
|
654
|
+
{ id: 'africa', label: 'Africa', children: [{ id: 'cameroon', label: 'Cameroon' }] },
|
|
655
|
+
];
|
|
656
|
+
|
|
657
|
+
export function Regions() {
|
|
658
|
+
const [value, setValue] = useState<string[]>(['france']);
|
|
659
|
+
return (
|
|
660
|
+
<TreeSelectField
|
|
661
|
+
label="Regions"
|
|
662
|
+
items={regions}
|
|
663
|
+
multiple
|
|
664
|
+
searchable
|
|
665
|
+
value={value}
|
|
666
|
+
onValueChange={setValue}
|
|
667
|
+
/>
|
|
668
|
+
);
|
|
669
|
+
}
|
|
670
|
+
```
|
|
671
|
+
|
|
672
|
+
Single mode (no `multiple`): a pick closes the popover and the trigger shows
|
|
673
|
+
the node's label. Multiple: the tree has checkboxes, and each pick is a
|
|
674
|
+
dismissible `Chip` beside the trigger, its remove button named "Remove
|
|
675
|
+
{label}" (`material.chip.dismiss-label`). The trigger is a `combobox`, named by
|
|
676
|
+
the label, with `aria-expanded` and, while open, `aria-controls`. Opening moves
|
|
677
|
+
focus into the filter, else into the tree on the pick (its branches unfolded);
|
|
678
|
+
the tree keeps its own keys (arrows, Home / End, Enter / Space), ↓ from the
|
|
679
|
+
filter enters it, and Escape closes the popover and hands focus back to the
|
|
680
|
+
trigger.
|
|
681
|
+
|
|
682
|
+
| Prop | Type | Default | Effect |
|
|
683
|
+
| --- | --- | --- | --- |
|
|
684
|
+
| `items` | `TreeNode[]` | — | required; `Tree`'s nodes: `{ id, label, icon?, trailing?, disabled?, children? }` |
|
|
685
|
+
| `multiple` | `boolean` | `false` | checkboxes and chips; decides the `value` type |
|
|
686
|
+
| `value` | `string \| null` / `string[]` | — | the picked id, or ids with `multiple` |
|
|
687
|
+
| `onValueChange` | `(value: string \| null) => void` / `(value: string[]) => void` | — | per `multiple` |
|
|
688
|
+
| `searchable` | `boolean` | `false` | a filter above the tree; each match stays under its ancestors, which open |
|
|
689
|
+
| `placeholder` | `string` | "Select…" | shown while nothing is picked (`material.tree-select-field.placeholder`) |
|
|
690
|
+
| `searchPlaceholder` | `string` | "Search" | the filter's placeholder and name (`material.tree-select-field.search`) |
|
|
691
|
+
| `required` | `boolean` | — | the asterisk, and `aria-required` on the `combobox` |
|
|
692
|
+
| `disabled` | `boolean` | — | disables the trigger and each chip's remove button |
|
|
693
|
+
| `error` | `boolean` | — | error border, error helper text, `aria-invalid` on the `combobox` |
|
|
694
|
+
| `id`, `aria-describedby`, `data-*` | | — | on the trigger: the label is `for` the `id`, the description follows the helper text's |
|
|
695
|
+
|
|
696
|
+
Its copy is `material.tree-select-field.*`: `placeholder`, `search`, `empty` ("No
|
|
697
|
+
match found.") and `selected` ("{count} selected", the trigger's text in
|
|
698
|
+
multiple mode).
|
|
699
|
+
|
|
700
|
+
**Emits:** `string | null` (single), `string[]` (multiple).
|
|
701
|
+
**Form wrapper:** `TreeSelectFormField` — `control`, `name` and `multiple`, see
|
|
702
|
+
[forms](../guides/forms.md#the-pair) and [what each field emits](../guides/forms.md#what-each-field-emits).
|
|
703
|
+
**Storybook:** `Selection & choice/TreeSelectField` · **Vue:** `TreeSelectField`, `TreeSelectFormField`
|
|
704
|
+
|
|
705
|
+
---
|
|
706
|
+
|
|
604
707
|
## Switcher
|
|
605
708
|
|
|
606
709
|

|
package/docs/guides/forms.md
CHANGED
|
@@ -116,7 +116,7 @@ export function PlanForm() {
|
|
|
116
116
|
| --- | --- |
|
|
117
117
|
| one input (`TextFormField`, `EmailFormField`, `TextareaFormField`, `SwitchFormField`, `CheckboxFormField`, …) | its input loses focus, as a native `blur` |
|
|
118
118
|
| several controls (`PasswordFormField` and its eye button, `NumberFormField` and its steppers, `PhoneFormField`, `OtpFormField`, `SliderFormField` with two thumbs, `DurationFormField`, `RatingFormField`, `RadioGroupFormField`, `CheckboxGroupFormField`, `SelectChipFormField`, `SelectCardFormField`, `SortableListFormField`, `TransferListFormField`, `InlineEditFormField`, `AttributeValuesFormFieldSet`, …) | focus leaves all of them; moving between them is not leaving |
|
|
119
|
-
| a picker (`SelectFormField`, `ComboboxFormField`, `AutocompleteFormField`, `CountryFormField`, `TimezoneFormField`, `ColorFormField`, `DateFormField`, `DateRangeFormField`, `TimeFormField`, …) | focus leaves the trigger **and** the popover it opened. Opening the popover, or picking in it, is not leaving; closing it hands focus back to the trigger, and the next Tab or click elsewhere is |
|
|
119
|
+
| a picker (`SelectFormField`, `ComboboxFormField`, `AutocompleteFormField`, `TreeSelectFormField`, `CountryFormField`, `TimezoneFormField`, `ColorFormField`, `DateFormField`, `DateRangeFormField`, `TimeFormField`, …) | focus leaves the trigger **and** the popover it opened. Opening the popover, or picking in it, is not leaving; closing it hands focus back to the trigger, and the next Tab or click elsewhere is |
|
|
120
120
|
| a dialog editor (`PostalAddressFormField`, `ContactsFormField`, `OpeningHoursFormField`, `AttributesFormField`, and `LocationFormField` from `@nxgt/material/map`) | focus leaves its buttons and the dialog they open. Closing the dialog hands focus back to the button that opened it |
|
|
121
121
|
| an upload (`UploadFormField`, `NetworkUploadFormField`, `S3UploadFormField`, `ImageFormField`, `ImageS3FormField`, `FileListFormField`, `FileListS3FormField`) | focus leaves the drop zone and its buttons. Choosing a file in the browser's own dialog is not leaving |
|
|
122
122
|
| `RichTextEditorFormField`, `CodeEditorFormField` | focus leaves the editor and its toolbar |
|
|
@@ -343,6 +343,7 @@ or fails validation.
|
|
|
343
343
|
| `SelectChipField` · `SelectChipFormField` | same as `SelectCardField` | `''` / `[]` |
|
|
344
344
|
| `TransferList` · `TransferListFormField` | `string[]`: the selected `value`s, in order | `[]` |
|
|
345
345
|
| `SortableList` · `SortableListFormField` | `string[]`: the `value`s, in the user's order | `[]` |
|
|
346
|
+
| `TreeSelectField` · `TreeSelectFormField` | `string \| null` (a node `id`). With `multiple`: `string[]`, in the order picked | `null` / `[]` |
|
|
346
347
|
|
|
347
348
|
### Media & files
|
|
348
349
|
|
package/docs/guides/i18n.md
CHANGED
|
@@ -195,16 +195,21 @@ The copy components render on their own comes from this namespace: empty
|
|
|
195
195
|
states, dialogs, pickers, the rich-text editor's toolbar, menus, node dialogs,
|
|
196
196
|
slash menu, font names and table-caption alignment
|
|
197
197
|
(`material['rich-text-editor'].*`), the carousel arrows' screen-reader text,
|
|
198
|
-
the camera
|
|
198
|
+
the camera's button, toggle and image (`material.camera.capture`, `captured`,
|
|
199
|
+
`start` and `stop`), the autocomplete's `Add "…"` and empty state, the QR code and
|
|
199
200
|
barcode accessible names, the calendar's navigation tooltips
|
|
200
201
|
(`material.calendar.*`), the data table's selection checkboxes, the filter's
|
|
201
202
|
presets and `Min`/`Max` fields, the `variant="4"` spinner's label,
|
|
202
203
|
`ScrollToTop`, the network upload field's `Retry`/`Remove`, the map's
|
|
203
204
|
`You are here` and zoom buttons, and the icon-only close button of
|
|
204
205
|
`DialogClose`, `DrawerClose`, `SheetClose` and `SheetContent`'s
|
|
205
|
-
`withCloseButton`.
|
|
206
|
+
`withCloseButton`. A range `Slider`'s readout inputs read
|
|
207
|
+
`material.slider.minimum` / `maximum` ("Minimum", "Maximum"), and a
|
|
208
|
+
single value's input, when nothing names the slider, `material.slider.value`
|
|
209
|
+
("Value", "Valeur"). The other icon-only buttons are named from it too: the
|
|
206
210
|
`Sidebar` toggle (`material.sidebar.toggle`), the data table's row expander
|
|
207
|
-
(`material.table.labels.toggle-row`),
|
|
211
|
+
(`material.table.labels.toggle-row`), its loading status, "Loading data…" /
|
|
212
|
+
"Chargement des données…" (`material.table.loading`), a chip's remove button — `Chip`,
|
|
208
213
|
`ComboboxChip` and the `Autocomplete` chips, "Remove {label}"
|
|
209
214
|
(`material.chip.dismiss-label`) — the `LocationPreview` trigger
|
|
210
215
|
(`material.map.preview` / `preview-named`), and the delete button of the
|
|
@@ -217,7 +222,10 @@ reads `material.print.table.total` ("Total", "Total") for its totals row and
|
|
|
217
222
|
unless you pass `totalLabel` or `emptyText`; a PDF does not see your
|
|
218
223
|
app's provider, so pass `PrintDocument` its `language` (see
|
|
219
224
|
[printing](printing.md#translating-built-in-strings-in-a-pdf)). The keys and the French
|
|
220
|
-
are the same in `@nxgt/material-vue`, so one set of overrides fits both.
|
|
225
|
+
are the same in `@nxgt/material-vue`, so one set of overrides fits both. Some
|
|
226
|
+
keys are read there only, such as `material.confirm-dialog.form-failed` ("The form could
|
|
227
|
+
not be loaded."), which `@nxgt/material-vue`'s `ConfirmationDialog` shows when
|
|
228
|
+
its on-demand form fails to load. Text
|
|
221
229
|
you pass yourself always wins over the translation: a `label`,
|
|
222
230
|
`Autocomplete`'s `freeSoloLabel` and `empty`, the editor's `options.labels`,
|
|
223
231
|
`QRCode`'s `title`, `Barecode`'s `aria-label`, `CarouselPrevious`/`CarouselNext`
|
|
@@ -246,11 +254,52 @@ sheet title on a phone (`material['pane-layout']['sheet-title']`);
|
|
|
246
254
|
`JsonViewer`'s "Empty JSON" (`material['json-viewer'].empty`);
|
|
247
255
|
`TimePicker`'s AM/PM (`material['time-picker'].am` / `pm`, "a.m." / "p.m." in
|
|
248
256
|
French); and the names of `DurationField`'s inputs, "Hours" and "Minutes"
|
|
249
|
-
(`material['duration-field']['hours-label']` / `minutes-label`)
|
|
250
|
-
`
|
|
251
|
-
`material.
|
|
252
|
-
|
|
253
|
-
|
|
257
|
+
(`material['duration-field']['hours-label']` / `minutes-label`); the status a
|
|
258
|
+
`Stepper` step announces after its title, "Completed" or "Error"
|
|
259
|
+
(`material.stepper.completed` / `error`, "Terminée" / "Erreur" in French); and
|
|
260
|
+
the pagination buttons' names and text: `PaginationPrevious` /
|
|
261
|
+
`PaginationNext`'s "Previous" / "Next" (`material.pagination.previous` /
|
|
262
|
+
`next`), `PaginationFirst` / `PaginationLast`'s "First" / "Last"
|
|
263
|
+
(`material.pagination.first` / `last`), `PaginationBar`'s "Page {page}" on
|
|
264
|
+
each page button (`material.pagination.page`) and `PaginationEllipsis`'s
|
|
265
|
+
"More pages" (`material.pagination.more`). `TreeSelectField`'s placeholder,
|
|
266
|
+
search box, empty message and "{count} selected" follow the language too
|
|
267
|
+
(`material['tree-select-field'].placeholder` / `search` / `empty` /
|
|
268
|
+
`selected`; in French `selected` is an ICU plural, `{count, plural, …}`); the
|
|
269
|
+
`placeholder` and `searchPlaceholder` props take precedence over them. The names of
|
|
270
|
+
`TimePicker`'s inputs read `material.time-picker.hours` and
|
|
271
|
+
`material.time-picker.minutes` ("Hours" / "Minutes", "Heures" / "Minutes").
|
|
272
|
+
`DateRangeField`'s preset list is a group named by
|
|
273
|
+
`material.date-range-field.presets` ("Presets", "Plages prédéfinies"); its
|
|
274
|
+
built-in presets read `material.date-range-field.preset.today`,
|
|
275
|
+
`material.date-range-field.preset.yesterday`,
|
|
276
|
+
`material.date-range-field.preset.last-7-days`,
|
|
277
|
+
`material.date-range-field.preset.last-30-days`,
|
|
278
|
+
`material.date-range-field.preset.this-month`,
|
|
279
|
+
`material.date-range-field.preset.last-month` and
|
|
280
|
+
`material.date-range-field.preset.this-year` ("Today", "Yesterday", "Last 7
|
|
281
|
+
days", "Last 30 days", "This month", "Last month", "This year"; "Aujourd’hui",
|
|
282
|
+
"Hier", "7 derniers jours", "30 derniers jours", "Ce mois-ci", "Le mois
|
|
283
|
+
dernier", "Cette année"), and with times its two groups
|
|
284
|
+
`material.date-range-field.start-time` and `material.date-range-field.end-time`
|
|
285
|
+
("Start time" / "End time", "Heure de début" / "Heure de fin"); its OK button
|
|
286
|
+
reads `material.buttons.ok`. The label of a preset of your own is yours.
|
|
287
|
+
`FilePreview`'s figure is named by `material.file-preview.label` ("Preview
|
|
288
|
+
of {name}", "Aperçu de {name}"), with `material.file-preview.untitled`
|
|
289
|
+
("Untitled file", "Fichier sans nom") as the name of a file that has none; it
|
|
290
|
+
reads `material.file-preview.loading` ("Loading preview…", "Chargement de
|
|
291
|
+
l’aperçu…") while it reads the file, `material.file-preview.error` ("This
|
|
292
|
+
file could not be previewed.", "Impossible d’afficher l’aperçu de ce
|
|
293
|
+
fichier.") when it cannot show it, `material.file-preview.download`
|
|
294
|
+
("Download", "Télécharger") on its download link, and
|
|
295
|
+
`material.file-preview.truncated` ("Showing the first {size} of this file.",
|
|
296
|
+
"Seuls les premiers {size} de ce fichier sont affichés.") under a text cut
|
|
297
|
+
by the size cap; the text or Markdown it shows scrolls in a region named by
|
|
298
|
+
`material.file-preview.content` ("Contents of {name}", "Contenu de {name}").
|
|
299
|
+
`material.carousel.roledescription` /
|
|
300
|
+
`slide` and `material.attributes.buttons.add-option` are there for
|
|
301
|
+
`@nxgt/material-vue`'s carousel and attribute options, so the bundles hold
|
|
302
|
+
the same keys. Your `placeholder`, `sheetTitle` and `aria-label` still
|
|
254
303
|
win.
|
|
255
304
|
|
|
256
305
|
To format filter values yourself in the provider's language, pass
|
package/docs/guides/ssr.md
CHANGED
|
@@ -34,7 +34,9 @@ at import time would crash the server before it answers anything.
|
|
|
34
34
|
- **Browser-only widgets render nothing on the server.** `PdfReader`,
|
|
35
35
|
`PdfSidebar`, `PdfPageList`, `PdfThumbnailSidebar` and the mermaid diagrams
|
|
36
36
|
inside `Markdown` load their dependency with `import()` and are wrapped in
|
|
37
|
-
`clientOnly`. They appear after hydration, with no mismatch.
|
|
37
|
+
`clientOnly`. They appear after hydration, with no mismatch. `Camera` is
|
|
38
|
+
`clientOnly` too: it has no lazy dependency, but `getUserMedia` has no
|
|
39
|
+
server side.
|
|
38
40
|
- **Two entries are the exceptions, on purpose.** They are not in any barrel,
|
|
39
41
|
and the build fails if another entry reaches their dependencies:
|
|
40
42
|
- `@nxgt/material/print` reaches `@react-pdf/renderer` and pdfkit, whose
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/docs/roadmap.md
CHANGED
|
@@ -6,7 +6,16 @@ the version something shipped in.
|
|
|
6
6
|
|
|
7
7
|
## Now
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
- **TreeSelectField** — pick one or several items from a tree inside a form
|
|
10
|
+
field, as chips when several, with an optional filter that keeps each match
|
|
11
|
+
under its ancestors (`TreeSelectField`, `TreeSelectFormField`).
|
|
12
|
+
- **DateRangeField presets and time** — one-click ranges such as Today, Last 7
|
|
13
|
+
days and This month, or your own, beside the calendar (`presets`), and a time
|
|
14
|
+
of day on each end of the range (`withTime`).
|
|
15
|
+
- **FilePreview** — preview a file picked by its type, in one component: an
|
|
16
|
+
image, a PDF in `PdfReader`, a video or audio file, the text of a text, JSON,
|
|
17
|
+
CSV or Markdown file, or a card with a download link for anything else
|
|
18
|
+
(`FilePreview`, `onError`). Safe on a server.
|
|
10
19
|
|
|
11
20
|
## Next
|
|
12
21
|
|
|
@@ -30,11 +39,14 @@ Nothing in progress right now; see Next.
|
|
|
30
39
|
The `Switch` row's misspelt `data-filed` attribute goes too: select
|
|
31
40
|
`[data-checked="true"]` instead. `DateField` / `DateRangeField` stop
|
|
32
41
|
accepting a day rule as `disabled`: pass it as `disabledDays`.
|
|
42
|
+
- **3.0: the same component names as `@nxgt/material-vue`** — the labelled
|
|
43
|
+
fields take the names both libraries share (`RadioGroupField`,
|
|
44
|
+
`SliderField`, `SwitchField`, today aliases of `RadioGroup`, `Slider` and
|
|
45
|
+
`Switch`), so code reads the same in React and Vue. Both names work until
|
|
46
|
+
then, and neither is deprecated yet.
|
|
33
47
|
- **Multi-month calendar with custom caption** — the month, caption and grid
|
|
34
48
|
slots together with `numberOfMonths` greater than one; today that combination
|
|
35
49
|
is not supported.
|
|
36
|
-
- **Range filters in generated filter forms** — slider ranges and number ranges
|
|
37
|
-
rendered by the schema-driven filter fields, not only by hand-written ones.
|
|
38
50
|
- **Ready-made documents** — invoice, quote, receipt, report, certificate and
|
|
39
51
|
label-sheet templates that take your data and return a document, their labels
|
|
40
52
|
translated.
|
|
@@ -82,6 +94,28 @@ Nothing in progress right now; see Next.
|
|
|
82
94
|
|
|
83
95
|
## Shipped
|
|
84
96
|
|
|
97
|
+
- **Spinner `light` colour renders** — a `Spinner` with `color="light"` shows
|
|
98
|
+
its light ring, for loading states on dark or coloured surfaces. 2.5.0.
|
|
99
|
+
- **Range filters announce their field name** — the slider thumbs and the
|
|
100
|
+
`Min`/`Max` inputs of a `slider-range` or `number-range` filter are named
|
|
101
|
+
after the field, so a screen reader says which range is changing. 2.5.0.
|
|
102
|
+
- **Alert keeps long content inside** — a long title, description or unbroken
|
|
103
|
+
string wraps inside the `Alert` instead of running past its edge. 2.5.0.
|
|
104
|
+
- **Stepper: unique ids, announced steps and truncated titles** — two steppers
|
|
105
|
+
on one page no longer share ids, a screen reader hears which step is current
|
|
106
|
+
and whether each is done or in error, and a long step title truncates. 2.5.0.
|
|
107
|
+
- **Layouts that hold long content** — `ListTile`, `StatCard` and `Banner`
|
|
108
|
+
keep long titles, values and actions inside their box instead of overflowing.
|
|
109
|
+
2.5.0.
|
|
110
|
+
- **The same exports as `@nxgt/material-vue`** — `Camera`, `NativeSelect`, the
|
|
111
|
+
`InputOTP` parts, `PaginationFirst` and `PaginationLast`, `TableEmpty`,
|
|
112
|
+
`DialogScrollContent` and `ToastAction`, `Button`'s sizes, and the
|
|
113
|
+
`RadioGroupField`, `SliderField` and `SwitchField` names, so code moves
|
|
114
|
+
between the two libraries without renaming. 2.5.0.
|
|
115
|
+
- **DataTable loading and empty states** — skeleton rows while the data loads
|
|
116
|
+
(the rows already shown stay in place, dimmed, during a refresh), the table
|
|
117
|
+
announced as busy, and your own content when there are no rows, told
|
|
118
|
+
whether a filter emptied it. 2.5.0.
|
|
85
119
|
- **PDFs from a Next.js route handler in one line of config** —
|
|
86
120
|
`withNxgtPrint(nextConfig)` from `@nxgt/material/next` adds what `/print`
|
|
87
121
|
needs to `next.config.ts` — the library in `serverExternalPackages`, and
|
|
@@ -219,5 +253,10 @@ Nothing in progress right now; see Next.
|
|
|
219
253
|
chat and markdown. 1.16.1.
|
|
220
254
|
- **`MentionList`** — mention suggestions with local search, for chat and the
|
|
221
255
|
rich text editor. 1.16.0.
|
|
256
|
+
- **Range filters in generated filter forms** — slider ranges and number ranges
|
|
257
|
+
rendered by the schema-driven filter fields: a `Filter` schema field with
|
|
258
|
+
`type: 'slider-range'` or `'number-range'` renders a two-thumb slider or a
|
|
259
|
+
`Min`/`Max` pair. 1.0.0.
|
|
260
|
+
([filters](components/data-table-filter-and-lists.md))
|
|
222
261
|
|
|
223
262
|
Older releases: the [version list on npm](https://www.npmjs.com/package/@nxgt/material?activeTab=versions).
|