@mono-lit/helper 0.0.1 → 0.0.3
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/LICENSE.md +55 -55
- package/README.md +35 -35
- package/dist/{breakpoints-CAbhDUht.js → breakpoints-DllybT82.js} +7 -5
- package/dist/checkbox.css_raw-AYtSbUtY.js +5 -0
- package/dist/{chip-limits-BMoO31JM.js → chip-limits-CFABydIL.js} +5 -3
- package/dist/{chip-strip-Cw3gyz0q.js → chip-strip-bNfLn52Z.js} +5 -3
- package/dist/chip.css_raw-ChfRSHLO.js +5 -0
- package/dist/{color-DHYrfXsX.js → color-CEYYtRX-.js} +8 -7
- package/dist/{css-class-BRKRzHx-.js → css-class-B6Tc_MAx.js} +2 -1
- package/dist/{css-size-DhHSVZJK.js → css-size-DWAPgQdT.js} +2 -1
- package/dist/{data-source-controller-C50Qyfzh.js → data-source-controller-Cf_sMxEh.js} +72 -7
- package/dist/data-source-controller-Dx6IQ2CN.js +243 -0
- package/dist/{data-source-options-BTpfrOZ_.js → data-source-options-Bk-UoaZV.js} +15 -10
- package/dist/{data-source-options-CQSTZHPE.js → data-source-options-QjuI73g8.js} +17 -12
- package/dist/{data-source-read-CUX-lgrQ.js → data-source-read-Cuqw3LcP.js} +7 -4
- package/dist/{data-source-read-DL88aH8t.js → data-source-read-FxqzQkk2.js} +8 -5
- package/dist/{decorate-DEXtNagw.js → decorate-DbYFpi8R.js} +7 -5
- package/dist/{element-props-CLB6yvbm.js → element-props-xvw0EB7H.js} +4 -3
- package/dist/{esm-Ptok4SQZ.js → esm-D0We7ndD.js} +48 -44
- package/dist/{excel-DopRbEMK.js → excel-BXzr3uI1.js} +192 -16
- package/dist/{excel-CY6zGkcx.js → excel-DtRpxmxs.js} +27 -16
- package/dist/{export-BvlBx_GZ.js → export-B91P6J1y.js} +104 -18
- package/dist/export.js +103 -18
- package/dist/{field-icons-BoOG6KrL.js → field-icons-FmyBWa0g.js} +38 -1
- package/dist/{field-path-C92eGLg3.js → field-path-BabiMrrA.js} +3 -2
- package/dist/{filter-builder-Bke3qOgJ.js → filter-builder-B6Y2mmbM.js} +7 -4
- package/dist/{filter-builder-CE4zE0V5.js → filter-builder-C0T3pMx2.js} +7 -4
- package/dist/{filter-eval-DIfU2EAn.js → filter-eval-ChDSaAUH.js} +7 -5
- package/dist/{filter-odata-C1vSGZaY.js → filter-odata-Bi27XUpQ.js} +9 -6
- package/dist/{form-control-core-B8d7k6vk.js → form-control-core-CIdMLXMo.js} +9 -6
- package/dist/{form-control-core-eeRr0zLU.js → form-control-core-CRZPZ1ru.js} +9 -6
- package/dist/hydration-flush-DHrl4_KK.js +1014 -0
- package/dist/{icon-CJkTlmTb.js → icon-BM9N-jOt.js} +5 -2
- package/dist/{icon-dVhYJUIH.js → icon-ClxnYhBG.js} +4 -2
- package/dist/{import-BgJdkwBI.js → import-Dc4eXC02.js} +22 -16
- package/dist/import.js +22 -16
- package/dist/index.js +17 -16
- package/dist/{index.node-DjvYOL-J.js → index.node-dvrNviMx.js} +26 -19
- package/dist/index.node.js +17 -16
- package/dist/input.css_raw-CGESifay.js +5 -0
- package/dist/{layout-var-CZnzMC0s.js → layout-var-BSBKY49k.js} +3 -2
- package/dist/{light-slots-BVJwyg_2.js → light-slots-4ZCjOcBg.js} +6 -4
- package/dist/{light-slots-DW1WgfgT.js → light-slots-DdDdZ6zs.js} +6 -4
- package/dist/{markdown-DfqrfOJN.js → markdown-uGlE_OfJ.js} +414 -369
- package/dist/mono-button-CeDB9khW.js +878 -0
- package/dist/mono-button.shadow-D9NdMsmH.js +790 -0
- package/dist/{mono-data-chart-ChU4Ii3p.js → mono-data-chart-ChkelNT7.js} +66 -22
- package/dist/{mono-data-dropdown-BAUl58kW.js → mono-data-dropdown-DxpUUk2y.js} +5 -3
- package/dist/{mono-data-grid-Db80FzdZ.js → mono-data-grid-8jmeIXUU.js} +56 -265
- package/dist/{mono-data-grid-CLBK8clE.js → mono-data-grid-BHlo1IgR.js} +56 -265
- package/dist/{mono-element-B0kP_96P.js → mono-element-C7vCschg.js} +7 -4
- package/dist/{mono-event-Bi1qP9uN.js → mono-event-BPku9HpS.js} +4 -3
- package/dist/{mono-form-controller-5PfsU4qa.js → mono-form-controller-IYn0MuUQ.js} +7 -4
- package/dist/{mono-modal-controller-BMO3n3rP.js → mono-modal-controller-ClObbHUs.js} +9 -7
- package/dist/{mono-ui-CPV7rrdo.js → mono-ui-BwUc0L6B.js} +22 -20
- package/dist/{data-search-Bwo5bg8K.js → normalize-error-D93O4q8g.js} +314 -10
- package/dist/{notifier-CE4yxMUQ.js → notifier-BIrqUzRh.js} +11 -1
- package/dist/nuxt.js +20 -15
- package/dist/{popup-portal-BziRX1yG.js → popup-portal-HWhkd7oy.js} +6 -4
- package/dist/{popup-stack-CEEMib__.js → popup-stack-De05Y-mJ.js} +13 -10
- package/dist/{rate-limit-BBa2PO79.js → rate-limit-e9Jlpl5l.js} +12 -9
- package/dist/{reactive-BHsqVjRh.js → reactive-DFCdZbH9.js} +318 -12
- package/dist/{reactive-D3EERqgO.js → reactive-Dtd-esHO.js} +2 -1
- package/dist/search.js +5 -4
- package/dist/src/components/accordion/accordion-core.d.ts +42 -40
- package/dist/src/components/accordion/accordion-types.d.ts +50 -48
- package/dist/src/components/accordion/index.d.ts +3 -2
- package/dist/src/components/accordion/index.shadow.d.ts +4 -4
- package/dist/src/components/accordion/mono-accordion.d.ts +44 -40
- package/dist/src/components/accordion/mono-accordion.shadow.d.ts +42 -38
- package/dist/src/components/alert/alert-core.d.ts +30 -28
- package/dist/src/components/alert/alert-types.d.ts +36 -34
- package/dist/src/components/alert/index.d.ts +3 -2
- package/dist/src/components/alert/index.shadow.d.ts +4 -4
- package/dist/src/components/alert/mono-alert.d.ts +30 -26
- package/dist/src/components/alert/mono-alert.shadow.d.ts +24 -20
- package/dist/src/components/breadcrumb/breadcrumb-core.d.ts +42 -40
- package/dist/src/components/breadcrumb/breadcrumb-list-core.d.ts +31 -29
- package/dist/src/components/breadcrumb/breadcrumb-render.d.ts +18 -16
- package/dist/src/components/breadcrumb/breadcrumb-types.d.ts +89 -87
- package/dist/src/components/breadcrumb/breadcrumb-utils.d.ts +18 -15
- package/dist/src/components/breadcrumb/index.d.ts +6 -5
- package/dist/src/components/breadcrumb/index.shadow.d.ts +7 -7
- package/dist/src/components/breadcrumb/mono-breadcrumb-list.d.ts +18 -14
- package/dist/src/components/breadcrumb/mono-breadcrumb-list.shadow.d.ts +33 -29
- package/dist/src/components/breadcrumb/mono-breadcrumb.d.ts +24 -20
- package/dist/src/components/breadcrumb/mono-breadcrumb.shadow.d.ts +55 -51
- package/dist/src/components/button/button-core.d.ts +73 -71
- package/dist/src/components/button/button-dropdown-core.d.ts +55 -53
- package/dist/src/components/button/button-dropdown-types.d.ts +98 -96
- package/dist/src/components/button/button-types.d.ts +157 -155
- package/dist/src/components/button/button-utils.d.ts +7 -5
- package/dist/src/components/button/index.button-dropdown.d.ts +5 -3
- package/dist/src/components/button/index.button-dropdown.shadow.d.ts +5 -3
- package/dist/src/components/button/index.d.ts +4 -7
- package/dist/src/components/button/index.shadow.d.ts +5 -4
- package/dist/src/components/button/mono-button-dropdown.d.ts +24 -19
- package/dist/src/components/button/mono-button-dropdown.shadow.d.ts +34 -29
- package/dist/src/components/button/mono-button.d.ts +105 -101
- package/dist/src/components/button/mono-button.shadow.d.ts +42 -38
- package/dist/src/components/card/card-core.d.ts +59 -56
- package/dist/src/components/card/card-types.d.ts +91 -89
- package/dist/src/components/card/card-utils.d.ts +11 -9
- package/dist/src/components/card/index.d.ts +4 -3
- package/dist/src/components/card/index.shadow.d.ts +5 -5
- package/dist/src/components/card/mono-card.d.ts +36 -32
- package/dist/src/components/card/mono-card.shadow.d.ts +32 -28
- package/dist/src/components/chart/chart-core.d.ts +30 -28
- package/dist/src/components/chart/chart-odata.d.ts +17 -16
- package/dist/src/components/chart/chart-types.d.ts +269 -248
- package/dist/src/components/chart/index.d.ts +7 -7
- package/dist/src/components/chart/index.shadow.d.ts +7 -6
- package/dist/src/components/chart/mono-chart-presets.d.ts +33 -29
- package/dist/src/components/chart/mono-chart-presets.shadow.d.ts +33 -29
- package/dist/src/components/chart/mono-chart.d.ts +13 -9
- package/dist/src/components/chart/mono-chart.shadow.d.ts +13 -9
- package/dist/src/components/chart/mono-data-chart.d.ts +4 -26
- package/dist/src/components/checkbox/checkbox-core.d.ts +39 -37
- package/dist/src/components/checkbox/checkbox-types.d.ts +59 -57
- package/dist/src/components/checkbox/checkbox-utils.d.ts +13 -11
- package/dist/src/components/checkbox/index.d.ts +4 -3
- package/dist/src/components/checkbox/index.shadow.d.ts +5 -4
- package/dist/src/components/checkbox/mono-checkbox.d.ts +21 -17
- package/dist/src/components/checkbox/mono-checkbox.shadow.d.ts +31 -27
- package/dist/src/components/chip/chip-core.d.ts +42 -40
- package/dist/src/components/chip/chip-types.d.ts +104 -102
- package/dist/src/components/chip/chip-utils.d.ts +20 -18
- package/dist/src/components/chip/index.d.ts +5 -7
- package/dist/src/components/chip/index.shadow.d.ts +6 -5
- package/dist/src/components/chip/mono-chip.d.ts +31 -27
- package/dist/src/components/chip/mono-chip.shadow.d.ts +19 -15
- package/dist/src/components/chip/mono-status-dot.d.ts +19 -17
- package/dist/src/components/date/date-core.d.ts +64 -62
- package/dist/src/components/date/date-types.d.ts +143 -141
- package/dist/src/components/date/index.d.ts +3 -2
- package/dist/src/components/date/index.shadow.d.ts +4 -3
- package/dist/src/components/date/mono-date.d.ts +12 -8
- package/dist/src/components/date/mono-date.shadow.d.ts +21 -17
- package/dist/src/components/drawer/drawer-core.d.ts +75 -73
- package/dist/src/components/drawer/drawer-types.d.ts +109 -107
- package/dist/src/components/drawer/index.d.ts +3 -2
- package/dist/src/components/drawer/index.shadow.d.ts +4 -3
- package/dist/src/components/drawer/mono-drawer.d.ts +32 -28
- package/dist/src/components/drawer/mono-drawer.shadow.d.ts +34 -31
- package/dist/src/components/dropdown/dropdown-core.d.ts +31 -29
- package/dist/src/components/dropdown/dropdown-types.d.ts +62 -60
- package/dist/src/components/dropdown/index.d.ts +3 -2
- package/dist/src/components/dropdown/index.shadow.d.ts +4 -3
- package/dist/src/components/dropdown/mono-dropdown.d.ts +23 -19
- package/dist/src/components/dropdown/mono-dropdown.shadow.d.ts +19 -15
- package/dist/src/components/dropdown-table/dropdown-table-core.d.ts +53 -51
- package/dist/src/components/dropdown-table/dropdown-table-types.d.ts +218 -216
- package/dist/src/components/dropdown-table/index.d.ts +5 -4
- package/dist/src/components/dropdown-table/index.shadow.d.ts +6 -5
- package/dist/src/components/dropdown-table/mono-data-dropdown.d.ts +119 -129
- package/dist/src/components/dropdown-table/mono-dropdown-table.d.ts +20 -16
- package/dist/src/components/dropdown-table/mono-dropdown-table.shadow.d.ts +15 -11
- package/dist/src/components/file-upload/file-upload-core.d.ts +44 -42
- package/dist/src/components/file-upload/file-upload-types.d.ts +123 -121
- package/dist/src/components/file-upload/file-upload-utils.d.ts +7 -4
- package/dist/src/components/file-upload/index.d.ts +4 -3
- package/dist/src/components/file-upload/index.shadow.d.ts +5 -4
- package/dist/src/components/file-upload/mono-file-upload.d.ts +20 -16
- package/dist/src/components/file-upload/mono-file-upload.shadow.d.ts +34 -30
- package/dist/src/components/filter/filter-builder-core.d.ts +17 -15
- package/dist/src/components/filter/filter-builder.d.ts +4 -22
- package/dist/src/components/filter/filter-odata.d.ts +3 -1
- package/dist/src/components/filter/filter-operators.d.ts +3 -1
- package/dist/src/components/filter/filter-types.d.ts +172 -170
- package/dist/src/components/filter/index.d.ts +6 -5
- package/dist/src/components/filter/index.shadow.d.ts +7 -6
- package/dist/src/components/filter/mono-filter-builder.d.ts +13 -10
- package/dist/src/components/filter/mono-filter-builder.shadow.d.ts +10 -7
- package/dist/src/components/form/form-control-core.d.ts +14 -12
- package/dist/src/components/form/form-rules.d.ts +7 -5
- package/dist/src/components/form/form-types.d.ts +214 -214
- package/dist/src/components/form/index.d.ts +5 -5
- package/dist/src/components/form/mono-form-controller.d.ts +4 -15
- package/dist/src/components/input/index.d.ts +5 -5
- package/dist/src/components/input/index.shadow.d.ts +6 -7
- package/dist/src/components/input/input-core.d.ts +73 -71
- package/dist/src/components/input/input-format.d.ts +22 -20
- package/dist/src/components/input/input-types.d.ts +167 -165
- package/dist/src/components/input/input-utils.d.ts +7 -5
- package/dist/src/components/input/mono-input.d.ts +35 -31
- package/dist/src/components/input/mono-input.shadow.d.ts +17 -13
- package/dist/src/components/menu/index.d.ts +7 -5
- package/dist/src/components/menu/index.shadow.d.ts +7 -6
- package/dist/src/components/menu/menu-core.d.ts +47 -45
- package/dist/src/components/menu/menu-render.d.ts +42 -40
- package/dist/src/components/menu/menu-types.d.ts +132 -130
- package/dist/src/components/menu/menu-utils.d.ts +16 -13
- package/dist/src/components/menu/mono-menu-list.d.ts +116 -114
- package/dist/src/components/menu/mono-menu.d.ts +30 -26
- package/dist/src/components/menu/mono-menu.shadow.d.ts +22 -18
- package/dist/src/components/modal/index.d.ts +5 -3
- package/dist/src/components/modal/index.shadow.d.ts +6 -4
- package/dist/src/components/modal/modal-core.d.ts +81 -79
- package/dist/src/components/modal/modal-types.d.ts +223 -221
- package/dist/src/components/modal/mono-modal-controller.d.ts +4 -3
- package/dist/src/components/modal/mono-modal.d.ts +32 -28
- package/dist/src/components/modal/mono-modal.shadow.d.ts +38 -35
- package/dist/src/components/nav/index.d.ts +4 -3
- package/dist/src/components/nav/index.shadow.d.ts +5 -5
- package/dist/src/components/nav/mono-nav.d.ts +28 -24
- package/dist/src/components/nav/mono-nav.shadow.d.ts +10 -7
- package/dist/src/components/nav/nav-core.d.ts +16 -14
- package/dist/src/components/nav/nav-types.d.ts +23 -22
- package/dist/src/components/nav/nav-utils.d.ts +10 -8
- package/dist/src/components/radio/index.d.ts +4 -3
- package/dist/src/components/radio/index.shadow.d.ts +5 -4
- package/dist/src/components/radio/mono-radio.d.ts +19 -15
- package/dist/src/components/radio/mono-radio.shadow.d.ts +22 -18
- package/dist/src/components/radio/radio-core.d.ts +31 -29
- package/dist/src/components/radio/radio-types.d.ts +48 -46
- package/dist/src/components/radio/radio-utils.d.ts +5 -3
- package/dist/src/components/rich-text-editor/index.d.ts +5 -4
- package/dist/src/components/rich-text-editor/index.shadow.d.ts +6 -5
- package/dist/src/components/rich-text-editor/mono-rich-text-editor.d.ts +19 -15
- package/dist/src/components/rich-text-editor/mono-rich-text-editor.shadow.d.ts +22 -19
- package/dist/src/components/rich-text-editor/rich-text-editor-core.d.ts +61 -59
- package/dist/src/components/rich-text-editor/rich-text-editor-loader.d.ts +2 -0
- package/dist/src/components/rich-text-editor/rich-text-editor-toolbar.d.ts +5 -3
- package/dist/src/components/rich-text-editor/rich-text-editor-types.d.ts +179 -177
- package/dist/src/components/select/index.d.ts +4 -3
- package/dist/src/components/select/index.shadow.d.ts +5 -4
- package/dist/src/components/select/mono-select.d.ts +58 -54
- package/dist/src/components/select/mono-select.shadow.d.ts +30 -27
- package/dist/src/components/select/select-core.d.ts +82 -80
- package/dist/src/components/select/select-types.d.ts +235 -208
- package/dist/src/components/select/select-utils.d.ts +7 -5
- package/dist/src/components/sidebar/index.d.ts +4 -3
- package/dist/src/components/sidebar/index.shadow.d.ts +5 -5
- package/dist/src/components/sidebar/mono-sidebar.d.ts +22 -18
- package/dist/src/components/sidebar/mono-sidebar.shadow.d.ts +11 -8
- package/dist/src/components/sidebar/sidebar-core.d.ts +33 -31
- package/dist/src/components/sidebar/sidebar-types.d.ts +77 -75
- package/dist/src/components/sidebar/sidebar-utils.d.ts +28 -26
- package/dist/src/components/switch/index.d.ts +4 -3
- package/dist/src/components/switch/index.shadow.d.ts +5 -4
- package/dist/src/components/switch/mono-switch.d.ts +19 -15
- package/dist/src/components/switch/mono-switch.shadow.d.ts +23 -19
- package/dist/src/components/switch/switch-core.d.ts +35 -33
- package/dist/src/components/switch/switch-types.d.ts +55 -53
- package/dist/src/components/switch/switch-utils.d.ts +5 -3
- package/dist/src/components/table/array-source.d.ts +31 -29
- package/dist/src/components/table/date-filter-tree.d.ts +25 -23
- package/dist/src/components/table/grouping.d.ts +22 -20
- package/dist/src/components/table/index.d.ts +28 -32
- package/dist/src/components/table/index.shadow.d.ts +34 -46
- package/dist/src/components/table/mono-data-grid.d.ts +1447 -1456
- package/dist/src/components/table/mono-table-checkbox-core.d.ts +34 -32
- package/dist/src/components/table/mono-table-checkbox.d.ts +12 -8
- package/dist/src/components/table/mono-table-checkbox.shadow.d.ts +16 -12
- package/dist/src/components/table/mono-table-detail-core.d.ts +29 -27
- package/dist/src/components/table/mono-table-detail.d.ts +12 -8
- package/dist/src/components/table/mono-table-detail.shadow.d.ts +13 -9
- package/dist/src/components/table/mono-table-empty-core.d.ts +24 -22
- package/dist/src/components/table/mono-table-empty.d.ts +17 -13
- package/dist/src/components/table/mono-table-empty.shadow.d.ts +22 -18
- package/dist/src/components/table/mono-table-error-core.d.ts +24 -22
- package/dist/src/components/table/mono-table-error.d.ts +12 -8
- package/dist/src/components/table/mono-table-error.shadow.d.ts +15 -11
- package/dist/src/components/table/mono-table-info-core.d.ts +6 -4
- package/dist/src/components/table/mono-table-info.d.ts +12 -8
- package/dist/src/components/table/mono-table-info.shadow.d.ts +9 -5
- package/dist/src/components/table/mono-table-loading-core.d.ts +7 -5
- package/dist/src/components/table/mono-table-loading.d.ts +12 -8
- package/dist/src/components/table/mono-table-loading.shadow.d.ts +9 -5
- package/dist/src/components/table/mono-table-page-size-core.d.ts +7 -5
- package/dist/src/components/table/mono-table-page-size.d.ts +12 -8
- package/dist/src/components/table/mono-table-page-size.shadow.d.ts +9 -5
- package/dist/src/components/table/mono-table-paging-core.d.ts +16 -14
- package/dist/src/components/table/mono-table-paging-group-core.d.ts +10 -8
- package/dist/src/components/table/mono-table-paging-group.d.ts +12 -8
- package/dist/src/components/table/mono-table-paging-group.shadow.d.ts +9 -5
- package/dist/src/components/table/mono-table-paging.d.ts +12 -8
- package/dist/src/components/table/mono-table-paging.shadow.d.ts +9 -5
- package/dist/src/components/table/mono-table-search-core.d.ts +51 -49
- package/dist/src/components/table/mono-table-search.d.ts +25 -22
- package/dist/src/components/table/mono-table-search.shadow.d.ts +12 -9
- package/dist/src/components/table/mono-table-sort-core.d.ts +16 -14
- package/dist/src/components/table/mono-table-sort.d.ts +21 -18
- package/dist/src/components/table/mono-table-sort.shadow.d.ts +11 -8
- package/dist/src/components/table/mono-table-summary-core.d.ts +9 -7
- package/dist/src/components/table/mono-table-summary.d.ts +12 -8
- package/dist/src/components/table/mono-table-summary.shadow.d.ts +9 -5
- package/dist/src/components/table/mono-table-th-core.d.ts +23 -21
- package/dist/src/components/table/mono-table-th.d.ts +21 -18
- package/dist/src/components/table/mono-table-th.shadow.d.ts +11 -8
- package/dist/src/components/table/store-group-source.d.ts +14 -12
- package/dist/src/components/table/table-controller-core.d.ts +17 -15
- package/dist/src/components/table/table-filter-icons.d.ts +3 -1
- package/dist/src/components/table/table-menu-core.d.ts +40 -38
- package/dist/src/components/table/table-overlay.d.ts +43 -41
- package/dist/src/components/table/table-sort-icons.d.ts +4 -2
- package/dist/src/components/table/table-sort-utils.d.ts +3 -1
- package/dist/src/components/table/table-types.d.ts +391 -400
- package/dist/src/components/tabs/index.d.ts +3 -2
- package/dist/src/components/tabs/index.shadow.d.ts +4 -3
- package/dist/src/components/tabs/mono-tabs.d.ts +21 -17
- package/dist/src/components/tabs/mono-tabs.shadow.d.ts +21 -17
- package/dist/src/components/tabs/tabs-core.d.ts +36 -34
- package/dist/src/components/tabs/tabs-types.d.ts +48 -46
- package/dist/src/components/tag-input/index.d.ts +5 -3
- package/dist/src/components/tag-input/index.shadow.d.ts +6 -4
- package/dist/src/components/tag-input/mono-tag-input.d.ts +56 -52
- package/dist/src/components/tag-input/mono-tag-input.shadow.d.ts +41 -38
- package/dist/src/components/tag-input/tag-input-core.d.ts +95 -93
- package/dist/src/components/tag-input/tag-input-types.d.ts +350 -327
- package/dist/src/components/tag-input/tag-input-utils.d.ts +7 -5
- package/dist/src/components/textarea/index.d.ts +4 -3
- package/dist/src/components/textarea/index.shadow.d.ts +5 -4
- package/dist/src/components/textarea/mono-textarea.d.ts +19 -15
- package/dist/src/components/textarea/mono-textarea.shadow.d.ts +19 -16
- package/dist/src/components/textarea/textarea-core.d.ts +48 -46
- package/dist/src/components/textarea/textarea-types.d.ts +120 -118
- package/dist/src/components/textarea/textarea-utils.d.ts +7 -5
- package/dist/src/components/tooltip/control-tooltip.d.ts +3 -1
- package/dist/src/components/tooltip/index.d.ts +6 -5
- package/dist/src/components/tooltip/tooltip-config.d.ts +17 -15
- package/dist/src/components/tooltip/tooltip-declarative.d.ts +3 -1
- package/dist/src/components/tooltip/tooltip-loader.d.ts +2 -0
- package/dist/src/components/tooltip/tooltip-types.d.ts +74 -72
- package/dist/src/composables/breakpoints.d.ts +9 -7
- package/dist/src/composables/chip-limits.d.ts +12 -10
- package/dist/src/composables/chip-strip.d.ts +91 -89
- package/dist/src/composables/color.d.ts +6 -4
- package/dist/src/composables/css-class.d.ts +4 -2
- package/dist/src/composables/css-size.d.ts +9 -7
- package/dist/src/composables/data-source-controller.d.ts +90 -59
- package/dist/src/composables/element-props.d.ts +3 -3
- package/dist/src/composables/field-icons.d.ts +11 -1
- package/dist/src/composables/hybird-prop.d.ts +10 -8
- package/dist/src/composables/hydration-flush.d.ts +16 -14
- package/dist/src/composables/icon.d.ts +3 -1
- package/dist/src/composables/layout-var.d.ts +2 -0
- package/dist/src/composables/light-slots.d.ts +34 -32
- package/dist/src/composables/mdi-glyphs.d.ts +2 -0
- package/dist/src/composables/mono-element.d.ts +3 -1
- package/dist/src/composables/mono-event.d.ts +15 -13
- package/dist/src/composables/mono-pending.d.ts +4 -2
- package/dist/src/composables/mono-skeleton.d.ts +100 -98
- package/dist/src/composables/mono-ui.d.ts +17 -18
- package/dist/src/composables/notifier.d.ts +20 -18
- package/dist/src/composables/popup-portal.d.ts +177 -175
- package/dist/src/composables/popup-stack.d.ts +36 -34
- package/dist/src/composables/rate-limit.d.ts +33 -31
- package/dist/src/composables/reactive.d.ts +3 -1
- package/dist/src/composables/shadow-css.d.ts +17 -15
- package/dist/src/composables/visibility.d.ts +6 -4
- package/dist/src/data/theme/index.d.ts +9 -7
- package/dist/src/data/theme/presets.d.ts +64 -62
- package/dist/src/entries/index.d.ts +36 -1
- package/dist/src/entries/index.node.d.ts +34 -41
- package/dist/src/entries/search.d.ts +2 -2
- package/dist/src/export/detail.d.ts +14 -12
- package/dist/src/export/download.d.ts +2 -0
- package/dist/src/export/excel/index.d.ts +13 -11
- package/dist/src/export/excel/nodes.d.ts +95 -93
- package/dist/src/export/expression.d.ts +3 -1
- package/dist/src/export/helpers.d.ts +3 -1
- package/dist/src/export/index.d.ts +6 -4
- package/dist/src/export/markdown.d.ts +19 -17
- package/dist/src/export/resolve-data.d.ts +3 -1
- package/dist/src/export/sentinel.d.ts +32 -30
- package/dist/src/export/sheet-name.d.ts +7 -5
- package/dist/src/export/styles.d.ts +13 -11
- package/dist/src/export/template.d.ts +3 -1
- package/dist/src/export/types.d.ts +224 -222
- package/dist/src/import/coerce.d.ts +5 -3
- package/dist/src/import/index.d.ts +12 -10
- package/dist/src/import/match.d.ts +20 -18
- package/dist/src/import/parse.d.ts +5 -3
- package/dist/src/import/types.d.ts +125 -123
- package/dist/src/nuxt/index.d.ts +92 -90
- package/dist/src/search/data-search.d.ts +92 -90
- package/dist/src/search/field-path.d.ts +10 -8
- package/dist/src/search/filter-eval.d.ts +2 -0
- package/dist/src/search/index.d.ts +6 -22
- package/dist/src/search/odata-search.d.ts +9 -7
- package/dist/src/search/search-expr.d.ts +16 -14
- package/dist/src/utils/data-source-apply.d.ts +11 -9
- package/dist/src/utils/data-source-options.d.ts +37 -35
- package/dist/src/utils/data-source-read.d.ts +40 -54
- package/dist/src/utils/data-source-summary.d.ts +8 -7
- package/dist/src/utils/normalize-error.d.ts +41 -9
- package/dist/src/vite/index.d.ts +34 -34
- package/dist/src/vite/mono-client-only.d.ts +34 -32
- package/dist/src/vite/mono-ssr-stub.d.ts +8 -6
- package/dist/src/vite/shadow-manifest.d.ts +2 -0
- package/dist/{styles-BIJ31TM4.js → styles-D-ergrfR.js} +417 -207
- package/dist/{tooltip-CysgRgBi.js → tooltip-FCMRUSLi.js} +94 -52
- package/dist/tooltip.js +3 -2
- package/dist/ui/accordion.js +16 -12
- package/dist/ui/alert.js +21 -14
- package/dist/ui/breadcrumb.js +28 -18
- package/dist/ui/button-dropdown.js +18 -14
- package/dist/ui/button.js +4 -2
- package/dist/ui/card.js +31 -13
- package/dist/ui/chart.js +107 -25
- package/dist/ui/checkbox.js +17 -12
- package/dist/ui/chip.js +19 -12
- package/dist/ui/date.js +19 -15
- package/dist/ui/drawer.js +26 -20
- package/dist/ui/dropdown-table.js +39 -30
- package/dist/ui/dropdown.js +19 -15
- package/dist/ui/file-upload.js +22 -17
- package/dist/ui/filter.js +18 -14
- package/dist/ui/form.js +4 -3
- package/dist/ui/index.css +1233 -2194
- package/dist/ui/input.js +24 -17
- package/dist/ui/menu.js +32 -20
- package/dist/ui/modal.js +34 -26
- package/dist/ui/nav.js +21 -15
- package/dist/ui/radio.js +17 -12
- package/dist/ui/rich-text-editor.js +34 -28
- package/dist/ui/select.js +181 -41
- package/dist/ui/shadow/accordion.js +13 -9
- package/dist/ui/shadow/alert.js +13 -9
- package/dist/ui/shadow/breadcrumb.js +23 -14
- package/dist/ui/shadow/button-dropdown.js +17 -13
- package/dist/ui/shadow/button.js +4 -2
- package/dist/ui/shadow/card.js +30 -11
- package/dist/ui/shadow/chart.js +163 -40
- package/dist/ui/shadow/checkbox.js +13 -9
- package/dist/ui/shadow/chip.js +16 -10
- package/dist/ui/shadow/date.js +19 -12
- package/dist/ui/shadow/drawer.js +22 -16
- package/dist/ui/shadow/dropdown-table.js +39 -28
- package/dist/ui/shadow/dropdown.js +15 -11
- package/dist/ui/shadow/file-upload.js +26 -19
- package/dist/ui/shadow/filter.js +17 -13
- package/dist/ui/shadow/input.js +20 -14
- package/dist/ui/shadow/menu.js +24 -14
- package/dist/ui/shadow/modal.js +36 -27
- package/dist/ui/shadow/nav.js +18 -12
- package/dist/ui/shadow/radio.js +15 -10
- package/dist/ui/shadow/rich-text-editor.js +32 -26
- package/dist/ui/shadow/select.js +179 -39
- package/dist/ui/shadow/sidebar.js +23 -16
- package/dist/ui/shadow/switch.js +15 -10
- package/dist/ui/shadow/table.js +123 -84
- package/dist/ui/shadow/tabs.js +12 -8
- package/dist/ui/shadow/tag-input.js +186 -52
- package/dist/ui/shadow/textarea.js +17 -12
- package/dist/ui/sidebar.js +27 -20
- package/dist/ui/switch.js +17 -12
- package/dist/ui/table.js +129 -87
- package/dist/ui/tabs.js +15 -11
- package/dist/ui/tag-input.js +182 -48
- package/dist/ui/textarea.js +19 -14
- package/dist/{vite-C5iUK7so.js → vite-DcyRlTTf.js} +17 -9
- package/dist/vite.js +3 -2
- package/package.json +15 -14
- package/dist/checkbox-Cqpie9Ap.js +0 -4
- package/dist/chip-DBUUa2eB.js +0 -4
- package/dist/data/theme/presets.json.d.ts +0 -140
- package/dist/export.d.ts +0 -1
- package/dist/hydration-flush-RB5Tz5nl.js +0 -1001
- package/dist/import.d.ts +0 -1
- package/dist/index.d.ts +0 -1
- package/dist/index.node.d.ts +0 -1
- package/dist/input-zGOULADt.js +0 -4
- package/dist/mono-button-CoVnBLav.js +0 -873
- package/dist/mono-button.shadow-FfP_hMH4.js +0 -784
- package/dist/nuxt.d.ts +0 -1
- package/dist/search.d.ts +0 -1
- package/dist/tooltip.d.ts +0 -1
- package/dist/ui/accordion.d.ts +0 -1
- package/dist/ui/alert.d.ts +0 -1
- package/dist/ui/breadcrumb.d.ts +0 -1
- package/dist/ui/button-dropdown.d.ts +0 -1
- package/dist/ui/button.d.ts +0 -1
- package/dist/ui/card.d.ts +0 -1
- package/dist/ui/chart.d.ts +0 -1
- package/dist/ui/checkbox.d.ts +0 -1
- package/dist/ui/chip.d.ts +0 -1
- package/dist/ui/date.d.ts +0 -1
- package/dist/ui/drawer.d.ts +0 -1
- package/dist/ui/dropdown-table.d.ts +0 -1
- package/dist/ui/dropdown.d.ts +0 -1
- package/dist/ui/file-upload.d.ts +0 -1
- package/dist/ui/filter.d.ts +0 -1
- package/dist/ui/form.d.ts +0 -1
- package/dist/ui/input.d.ts +0 -1
- package/dist/ui/menu.d.ts +0 -1
- package/dist/ui/modal.d.ts +0 -1
- package/dist/ui/nav.d.ts +0 -1
- package/dist/ui/radio.d.ts +0 -1
- package/dist/ui/rich-text-editor.d.ts +0 -1
- package/dist/ui/select.d.ts +0 -1
- package/dist/ui/sidebar.d.ts +0 -1
- package/dist/ui/switch.d.ts +0 -1
- package/dist/ui/table.d.ts +0 -1
- package/dist/ui/tabs.d.ts +0 -1
- package/dist/ui/tag-input.d.ts +0 -1
- package/dist/ui/textarea.d.ts +0 -1
- package/dist/vite.d.ts +0 -1
|
@@ -1,15 +1,16 @@
|
|
|
1
|
-
import { MonoEventProps } from
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import { RadioEvents, RadioProps } from
|
|
12
|
-
import { SwitchEvents, SwitchProps } from
|
|
1
|
+
import { MonoEventProps } from "../../composables/element-props.js";
|
|
2
|
+
import { CheckboxEvents, CheckboxProps } from "../checkbox/checkbox-types.js";
|
|
3
|
+
import { DateEvents, DateProps } from "../date/date-types.js";
|
|
4
|
+
import { DropdownTableEvents, DropdownTableProps } from "../dropdown-table/dropdown-table-types.js";
|
|
5
|
+
import { FileUploadEvents, FileUploadProps } from "../file-upload/file-upload-types.js";
|
|
6
|
+
import { InputEvents, InputProps } from "../input/input-types.js";
|
|
7
|
+
import { SelectEvents, SelectProps } from "../select/select-types.js";
|
|
8
|
+
import { TextareaEvents, TextareaProps } from "../textarea/textarea-types.js";
|
|
9
|
+
import { RichTextEditorEvents, RichTextEditorProps } from "../rich-text-editor/rich-text-editor-types.js";
|
|
10
|
+
import { TagInputEvents, TagInputProps } from "../tag-input/tag-input-types.js";
|
|
11
|
+
import { RadioEvents, RadioProps } from "../radio/radio-types.js";
|
|
12
|
+
import { SwitchEvents, SwitchProps } from "../switch/switch-types.js";
|
|
13
|
+
//#region src/components/form/form-types.d.ts
|
|
13
14
|
/**
|
|
14
15
|
* Tag name → its props, so `inputs[key].props` and `setProp()` autocomplete against the
|
|
15
16
|
* component actually being driven. Keyed by the LIGHT tag; the shadow twins
|
|
@@ -20,17 +21,17 @@ import { SwitchEvents, SwitchProps } from '../switch/switch-types.js';
|
|
|
20
21
|
* as listeners rather than writing them as props.
|
|
21
22
|
*/
|
|
22
23
|
export interface MonoFormComponentProps {
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
24
|
+
'mono-input': Partial<InputProps> & MonoEventProps<InputEvents>;
|
|
25
|
+
'mono-select': Partial<SelectProps> & MonoEventProps<SelectEvents>;
|
|
26
|
+
'mono-textarea': Partial<TextareaProps> & MonoEventProps<TextareaEvents>;
|
|
27
|
+
'mono-rich-text-editor': Partial<RichTextEditorProps> & MonoEventProps<RichTextEditorEvents>;
|
|
28
|
+
'mono-date': Partial<DateProps> & MonoEventProps<DateEvents>;
|
|
29
|
+
'mono-tag-input': Partial<TagInputProps> & MonoEventProps<TagInputEvents>;
|
|
30
|
+
'mono-file-upload': Partial<FileUploadProps> & MonoEventProps<FileUploadEvents>;
|
|
31
|
+
'mono-dropdown-table': Partial<DropdownTableProps> & MonoEventProps<DropdownTableEvents>;
|
|
32
|
+
'mono-checkbox': Partial<CheckboxProps> & MonoEventProps<CheckboxEvents>;
|
|
33
|
+
'mono-radio': Partial<RadioProps> & MonoEventProps<RadioEvents>;
|
|
34
|
+
'mono-switch': Partial<SwitchProps> & MonoEventProps<SwitchEvents>;
|
|
34
35
|
}
|
|
35
36
|
/** Every component `monoForm` can drive. */
|
|
36
37
|
export type MonoFormComponent = keyof MonoFormComponentProps;
|
|
@@ -46,9 +47,9 @@ export type MonoFormProps<C extends MonoFormComponent = MonoFormComponent> = Mon
|
|
|
46
47
|
export type MonoFormTiming = 'live' | 'change';
|
|
47
48
|
/** Context handed to a `type: 'custom'` rule. */
|
|
48
49
|
export interface MonoFormRuleCtx<V = unknown> {
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
50
|
+
value: V;
|
|
51
|
+
values: Record<string, unknown>;
|
|
52
|
+
key: string;
|
|
52
53
|
}
|
|
53
54
|
/**
|
|
54
55
|
* Anything schema-shaped — yup and friends. Duck-typed on purpose: @mono-lit/helper
|
|
@@ -56,48 +57,48 @@ export interface MonoFormRuleCtx<V = unknown> {
|
|
|
56
57
|
* async `validate`) works, and the thrown error's `message` becomes the message.
|
|
57
58
|
*/
|
|
58
59
|
export interface MonoFormSchemaLike {
|
|
59
|
-
|
|
60
|
-
|
|
60
|
+
validateSync?: (value: unknown, options?: unknown) => unknown;
|
|
61
|
+
validate?: (value: unknown, options?: unknown) => unknown;
|
|
61
62
|
}
|
|
62
63
|
interface MonoFormRuleBase {
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
64
|
+
/** Overrides the form-level `validation.type` for this rule only. */
|
|
65
|
+
timing?: MonoFormTiming;
|
|
66
|
+
message?: string;
|
|
67
|
+
/**
|
|
68
|
+
* A schema for this rule. When present it WINS over `type`/`validate`, and its
|
|
69
|
+
* own error message wins over `message`.
|
|
70
|
+
*/
|
|
71
|
+
schema?: MonoFormSchemaLike;
|
|
71
72
|
}
|
|
72
73
|
export type MonoFormRule<V = unknown> = (MonoFormRuleBase & {
|
|
73
|
-
|
|
74
|
+
type: 'required';
|
|
74
75
|
}) | (MonoFormRuleBase & {
|
|
75
|
-
|
|
76
|
-
|
|
76
|
+
type: 'min';
|
|
77
|
+
value: number;
|
|
77
78
|
}) | (MonoFormRuleBase & {
|
|
78
|
-
|
|
79
|
-
|
|
79
|
+
type: 'max';
|
|
80
|
+
value: number;
|
|
80
81
|
}) | (MonoFormRuleBase & {
|
|
81
|
-
|
|
82
|
-
|
|
82
|
+
type: 'pattern';
|
|
83
|
+
value: RegExp | string;
|
|
83
84
|
}) | (MonoFormRuleBase & {
|
|
84
|
-
|
|
85
|
+
type: 'email';
|
|
85
86
|
}) | (MonoFormRuleBase & {
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
})
|
|
87
|
+
type: 'custom';
|
|
88
|
+
/** Return `true` to pass, or a string / `false` to fail. */
|
|
89
|
+
validate: (ctx: MonoFormRuleCtx<V>) => boolean | string;
|
|
90
|
+
}) |
|
|
90
91
|
/** Schema-only rule — no `type` needed. */
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
92
|
+
(MonoFormRuleBase & {
|
|
93
|
+
type?: undefined;
|
|
94
|
+
schema: MonoFormSchemaLike;
|
|
94
95
|
});
|
|
95
96
|
/** The validation record exposed per field. */
|
|
96
97
|
export interface MonoFormValidation {
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
98
|
+
/** `true` when the field passes. */
|
|
99
|
+
success: boolean;
|
|
100
|
+
/** The failure message, or `''` when it passes. */
|
|
101
|
+
message: string;
|
|
101
102
|
}
|
|
102
103
|
/**
|
|
103
104
|
* One row of a list control's RESOLVED options, as reported onto {@link MonoFormItem.list}.
|
|
@@ -110,131 +111,131 @@ export interface MonoFormValidation {
|
|
|
110
111
|
* `kind`. The two are deliberately not unified — do not "tidy" either to match the other.
|
|
111
112
|
*/
|
|
112
113
|
export interface MonoFormListEntry<T = Record<string, unknown>> {
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
114
|
+
/** `'row'` for a selectable option, `'group'` for the header above a run of them. */
|
|
115
|
+
type: 'row' | 'group';
|
|
116
|
+
/**
|
|
117
|
+
* A row's key is `item[keyValue]` — the same value `key-value` already resolves for selection, so
|
|
118
|
+
* there is only ever one notion of a key here. A group's key is its own group path.
|
|
119
|
+
*/
|
|
120
|
+
key: string;
|
|
121
|
+
/** The source row. Present on `'row'` entries only. */
|
|
122
|
+
item?: T;
|
|
123
|
+
/** The group's resolved caption. Present on `'group'` entries only. */
|
|
124
|
+
label?: string;
|
|
125
|
+
/** Nesting depth. On a ROW this is the depth of the group it sits IN, so indent by it directly. */
|
|
126
|
+
level: number;
|
|
127
|
+
/** A group's leaves — enough for a count without walking the rest of the list. */
|
|
128
|
+
items?: T[];
|
|
129
|
+
/** Whether this row is currently picked. `'row'` only. */
|
|
130
|
+
selected?: boolean;
|
|
131
|
+
/** Whether the keyboard cursor is on this row. `'row'` only. */
|
|
132
|
+
active?: boolean;
|
|
132
133
|
}
|
|
133
134
|
/** One field's live state, as read through `form.items()`. */
|
|
134
135
|
export interface MonoFormItem<V = unknown> {
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
136
|
+
/** The field name — the same string used as `key-form` on the control. */
|
|
137
|
+
key: string;
|
|
138
|
+
/** The value right now. */
|
|
139
|
+
currentValue: V;
|
|
140
|
+
/** The value before the most recent change. */
|
|
141
|
+
oldValue: V;
|
|
142
|
+
/** Current verdict — from the field's rules, or from `setValidation`. */
|
|
143
|
+
validate: MonoFormValidation;
|
|
144
|
+
/** Whether the field has been committed at least once (drives nothing yet; useful to consumers). */
|
|
145
|
+
touched: boolean;
|
|
146
|
+
/** The merged props currently pushed onto the element. */
|
|
147
|
+
props: Record<string, unknown>;
|
|
148
|
+
/**
|
|
149
|
+
* The control's RESOLVED options — after the search box, after the DataSource loaded, after
|
|
150
|
+
* grouping was flattened. Empty for a control that has no list.
|
|
151
|
+
*
|
|
152
|
+
* This is what `slot="list"` is looped over: the raw `items` / `dataSource` you passed in would
|
|
153
|
+
* ignore the search box and desync from what is on screen, which is the whole reason the control
|
|
154
|
+
* reports this back up rather than the consumer reusing its own array.
|
|
155
|
+
*/
|
|
156
|
+
list: MonoFormListEntry[];
|
|
156
157
|
}
|
|
157
158
|
/** A ref-like external input (a Vue `ref` satisfies this). */
|
|
158
159
|
export interface MonoFormRefLike<T = unknown> {
|
|
159
|
-
|
|
160
|
+
value: T;
|
|
160
161
|
}
|
|
161
162
|
/** Argument to `setProp` — `component` narrows `props`. */
|
|
162
163
|
export type MonoFormSetProp<C extends MonoFormComponent = MonoFormComponent> = {
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
164
|
+
component?: C;
|
|
165
|
+
key: string;
|
|
166
|
+
props: MonoFormProps<C>;
|
|
166
167
|
};
|
|
167
168
|
/** Argument to `setValidation`. */
|
|
168
169
|
export interface MonoFormSetValidation {
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
170
|
+
component?: MonoFormComponent;
|
|
171
|
+
key: string;
|
|
172
|
+
validation: Partial<MonoFormValidation>;
|
|
172
173
|
}
|
|
173
174
|
/** Context handed to a field watcher. */
|
|
174
175
|
export interface MonoFormWatcherCtx {
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
176
|
+
/** The field this watcher belongs to. */
|
|
177
|
+
selfKey: string;
|
|
178
|
+
/** The field that actually changed (equals `selfKey` for a self change). */
|
|
179
|
+
peerKey: string;
|
|
180
|
+
/** Value of `selfKey`. */
|
|
181
|
+
currentValue: unknown;
|
|
182
|
+
oldValue: unknown;
|
|
183
|
+
/** Value of `peerKey` — the field that changed. */
|
|
184
|
+
peerCurrentValue: unknown;
|
|
185
|
+
peerOldValue: unknown;
|
|
186
|
+
/**
|
|
187
|
+
* The DOM `CustomEvent` (`mno-input` / `mno-change` — same payload as the plain
|
|
188
|
+
* `input` / `change`) that last touched
|
|
189
|
+
* `selfKey`. `undefined` when this field hasn't been edited by hand yet, or
|
|
190
|
+
* when its value was written programmatically via `setValue` / `setValues`.
|
|
191
|
+
*/
|
|
192
|
+
event?: Event;
|
|
193
|
+
/**
|
|
194
|
+
* The DOM `CustomEvent` that caused THIS run — the one that changed `peerKey`.
|
|
195
|
+
* Same object as `event` on a self change. `undefined` for a programmatic write.
|
|
196
|
+
*/
|
|
197
|
+
peerEvent?: Event;
|
|
198
|
+
/** Every field's current value. */
|
|
199
|
+
values: Record<string, unknown>;
|
|
200
|
+
/** Unwrapped `external` refs. */
|
|
201
|
+
external: Record<string, unknown>;
|
|
202
|
+
/**
|
|
203
|
+
* Push props onto any field's control. NOTE: a static `inputs[key].props`
|
|
204
|
+
* declares the same thing and ALWAYS wins over this one.
|
|
205
|
+
*/
|
|
206
|
+
setProp: <C extends MonoFormComponent = MonoFormComponent>(arg: MonoFormSetProp<C>) => void;
|
|
207
|
+
/** Mark any field valid/invalid — the message renders on that control. */
|
|
208
|
+
setValidation: (arg: MonoFormSetValidation) => void;
|
|
209
|
+
/** Set another field's value (runs its rules + fans out again). */
|
|
210
|
+
setValue: (key: string, value: unknown) => void;
|
|
210
211
|
}
|
|
211
212
|
/**
|
|
212
213
|
* One field's declaration, for ONE component. Consumers use {@link MonoFormInput},
|
|
213
214
|
* which distributes this over the components it is given.
|
|
214
215
|
*/
|
|
215
216
|
export interface MonoFormInputOf<C extends MonoFormComponent = MonoFormComponent, V = unknown> {
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
217
|
+
/** Narrows the TS type of `props`. Optional — omit for a loose record. */
|
|
218
|
+
component?: C;
|
|
219
|
+
/**
|
|
220
|
+
* Static props for this field's control that ALWAYS win — over the
|
|
221
|
+
* `setProp()` method and over template bindings. Same name and role as
|
|
222
|
+
* `monoDataGrid({ props })`.
|
|
223
|
+
*/
|
|
224
|
+
props?: MonoFormProps<C>;
|
|
225
|
+
/** Initial value for the field. */
|
|
226
|
+
value?: V;
|
|
227
|
+
/**
|
|
228
|
+
* Rules for this field, checked in order — the FIRST failure is reported,
|
|
229
|
+
* since a control renders one message. Each entry is a built-in `type`, a
|
|
230
|
+
* `type: 'custom'` function, or a `schema` (which wins over both).
|
|
231
|
+
*/
|
|
232
|
+
validates?: MonoFormRule<V>[];
|
|
233
|
+
/**
|
|
234
|
+
* Runs when THIS field changes (`peerKey === selfKey`) and whenever any OTHER
|
|
235
|
+
* field changes (`peerKey` = that field) — which is what lets one field react
|
|
236
|
+
* to another without a separate peer-watcher registry.
|
|
237
|
+
*/
|
|
238
|
+
watcher?: (ctx: MonoFormWatcherCtx) => void;
|
|
238
239
|
}
|
|
239
240
|
/**
|
|
240
241
|
* One field's declaration — {@link MonoFormInputOf} DISTRIBUTED over `C`, so
|
|
@@ -245,63 +246,62 @@ export interface MonoFormInputOf<C extends MonoFormComponent = MonoFormComponent
|
|
|
245
246
|
* `event` fell back to `any`. A declaration without `component` still matches
|
|
246
247
|
* (every member's `component` is optional) and keeps the loose union.
|
|
247
248
|
*/
|
|
248
|
-
export type MonoFormInput<C extends MonoFormComponent = MonoFormComponent, V = unknown> = {
|
|
249
|
-
[K in C]: MonoFormInputOf<K, V>;
|
|
250
|
-
}[C];
|
|
249
|
+
export type MonoFormInput<C extends MonoFormComponent = MonoFormComponent, V = unknown> = { [K in C]: MonoFormInputOf<K, V>; }[C];
|
|
251
250
|
export interface MonoFormOptions {
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
251
|
+
/** Default rule timing for the whole form. Defaults to `'change'`. */
|
|
252
|
+
validation?: {
|
|
253
|
+
type?: MonoFormTiming;
|
|
254
|
+
};
|
|
255
|
+
inputs: Record<string, MonoFormInput>;
|
|
256
|
+
/** Ref-like values readable from watchers as `external.<name>`. */
|
|
257
|
+
external?: Record<string, MonoFormRefLike | unknown>;
|
|
258
|
+
/**
|
|
259
|
+
* A ref the form writes a fresh snapshot into on every change, so a Vue
|
|
260
|
+
* template can read `state.Name.validate.message` and re-render without any
|
|
261
|
+
* manual subscription.
|
|
262
|
+
*/
|
|
263
|
+
state?: MonoFormRefLike<Record<string, MonoFormItem> | undefined>;
|
|
265
264
|
}
|
|
266
265
|
/** The controller returned by {@link monoForm}. */
|
|
267
266
|
export interface MonoFormController {
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
267
|
+
/** Live state for every field (stable object, mutated in place). */
|
|
268
|
+
items(): Record<string, MonoFormItem>;
|
|
269
|
+
/** Just the values, `{ Name: 'Denis', Age: 18 }`. */
|
|
270
|
+
values(): Record<string, unknown>;
|
|
271
|
+
setValue(key: string, value: unknown): void;
|
|
272
|
+
/** Bulk-set values, e.g. seeding an edit form from a fetched record. */
|
|
273
|
+
setValues(values: Record<string, unknown>): void;
|
|
274
|
+
/** Run EVERY rule on every field regardless of timing. Resolves to overall validity. */
|
|
275
|
+
validate(): Promise<boolean>;
|
|
276
|
+
/** Whether every field currently passes. */
|
|
277
|
+
isValid(): boolean;
|
|
278
|
+
/** Clear values + validation back to the declared defaults. */
|
|
279
|
+
reset(): void;
|
|
280
|
+
/** Push props onto a field's control. `inputs[key].props` still wins over this. */
|
|
281
|
+
setProp<C extends MonoFormComponent = MonoFormComponent>(arg: MonoFormSetProp<C>): void;
|
|
282
|
+
/** Mark any field valid/invalid, e.g. from a server response. */
|
|
283
|
+
setValidation(arg: MonoFormSetValidation): void;
|
|
284
|
+
/** Re-read `external` refs and re-run watchers. */
|
|
285
|
+
refresh(): void;
|
|
286
|
+
/** Write snapshots into `ref` on every change (same as the `state` option). */
|
|
287
|
+
bindRef(ref: MonoFormRefLike<Record<string, MonoFormItem> | undefined>): () => void;
|
|
288
|
+
subscribe(cb: () => void): () => void;
|
|
289
|
+
dispose(): void;
|
|
290
|
+
/** @internal Register an element under `key`; returns an unregister handle. */
|
|
291
|
+
_register(key: string, el: unknown): () => void;
|
|
292
|
+
/**
|
|
293
|
+
* @internal Element reported a value change. `timing` picks which rules run;
|
|
294
|
+
* `event` is the originating `mno-input`/`mno-change` CustomEvent, surfaced to
|
|
295
|
+
* watchers as `event` / `peerEvent`.
|
|
296
|
+
*/
|
|
297
|
+
_report(key: string, value: unknown, timing: MonoFormTiming, event?: Event): void;
|
|
298
|
+
/**
|
|
299
|
+
* @internal A list control publishing its resolved options, so `form.items()[key].list` can be
|
|
300
|
+
* looped from a `slot="list"`. Reference-compared, so a control may call it on every render.
|
|
301
|
+
*/
|
|
302
|
+
_reportList(key: string, entries: MonoFormListEntry[]): void;
|
|
303
|
+
/** @internal The props an element should currently apply (`inputs[key].props` wins). */
|
|
304
|
+
_propsFor(key: string): Record<string, unknown>;
|
|
306
305
|
}
|
|
307
|
-
|
|
306
|
+
//#endregion
|
|
307
|
+
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference path="../../../vue.d.ts" />
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
export type
|
|
2
|
+
import { MonoFormComponent, MonoFormComponentProps, MonoFormController, MonoFormInput, MonoFormInputOf, MonoFormItem, MonoFormOptions, MonoFormProps, MonoFormRefLike, MonoFormRule, MonoFormRuleCtx, MonoFormSchemaLike, MonoFormSetProp, MonoFormSetValidation, MonoFormTiming, MonoFormValidation, MonoFormWatcherCtx } from "./form-types.js";
|
|
3
|
+
import { MonoFormControlCore, MonoFormControlCoreInterface } from "./form-control-core.js";
|
|
4
|
+
import { isBlank, runRule, runRules } from "./form-rules.js";
|
|
5
|
+
import { controlMonoForm as monoForm } from "./mono-form-controller.js";
|
|
6
|
+
export { type MonoFormComponent, type MonoFormComponentProps, MonoFormControlCore, type MonoFormControlCoreInterface, type MonoFormController, type MonoFormInput, type MonoFormInputOf, type MonoFormItem, type MonoFormOptions, type MonoFormProps, type MonoFormRefLike, type MonoFormRule, type MonoFormRuleCtx, type MonoFormSchemaLike, type MonoFormSetProp, type MonoFormSetValidation, type MonoFormTiming, type MonoFormValidation, type MonoFormWatcherCtx, monoForm as controlMonoForm, isBlank, monoForm, runRule, runRules };
|
|
@@ -1,16 +1,5 @@
|
|
|
1
|
-
import { MonoFormController, MonoFormOptions } from
|
|
2
|
-
|
|
3
|
-
* `monoForm()` — a headless form controller.
|
|
4
|
-
*
|
|
5
|
-
* The consumer authors the markup by hand and opts each control in with
|
|
6
|
-
* `:data-form="form"` + `key-form="Name"`. The controller owns the value,
|
|
7
|
-
* validation, cross-field reactions and the props pushed onto each element;
|
|
8
|
-
* nothing here touches the DOM, so it is SSR-safe and testable on its own.
|
|
9
|
-
*
|
|
10
|
-
* Mirrors `monoDataGrid`'s controller shape: a plain object with coalesced
|
|
11
|
-
* `subscribe`/`notify`, state mutated in place, and elements re-rendering off
|
|
12
|
-
* the subscription.
|
|
13
|
-
*/
|
|
14
|
-
/** Renamed "control" alias of {@link monoForm} (no breaking change — both work). */
|
|
15
|
-
export { monoForm as controlMonoForm };
|
|
1
|
+
import { MonoFormController, MonoFormOptions } from "./form-types.js";
|
|
2
|
+
//#region src/components/form/mono-form-controller.d.ts
|
|
16
3
|
export declare function monoForm(options: MonoFormOptions): MonoFormController;
|
|
4
|
+
//#endregion
|
|
5
|
+
export { monoForm as controlMonoForm };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference path="../../../vue.d.ts" />
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
export {
|
|
2
|
+
import { InputFormat, InputFormatCtx, InputFormatDescriptor, InputFormatOn, applyFormat, caretAfterFormat, localeSeparators, normaliseValue, parseFormat, resolveFormat, significantFor, stripFormat } from "./input-format.js";
|
|
3
|
+
import { InputColor, InputEvents, InputProps, InputSize, InputType, InputVariant } from "./input-types.js";
|
|
4
|
+
import { MonoInput } from "./mono-input.js";
|
|
5
|
+
import { generateInputAriaAttributes, generateInputAttributes, getInputIcon, validateInputProps } from "./input-utils.js";
|
|
6
|
+
export { type InputColor, type InputEvents, type InputFormat, type InputFormatCtx, type InputFormatDescriptor, type InputFormatOn, type InputProps, type InputSize, type InputType, type InputVariant, MonoInput, applyFormat, caretAfterFormat, generateInputAriaAttributes, generateInputAttributes, getInputIcon, localeSeparators, normaliseValue, parseFormat, resolveFormat, significantFor, stripFormat, validateInputProps };
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
/// <reference path="../../../vue.d.ts" />
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
export type
|
|
8
|
-
export { validateInputProps, generateInputAttributes, generateInputAriaAttributes, getInputIcon, } from './input-utils.js';
|
|
2
|
+
import { InputFormat, InputFormatCtx, InputFormatDescriptor, InputFormatOn, applyFormat, caretAfterFormat, localeSeparators, normaliseValue, parseFormat, resolveFormat, significantFor, stripFormat } from "./input-format.js";
|
|
3
|
+
import { InputColor, InputEvents, InputProps, InputSize, InputType, InputVariant } from "./input-types.js";
|
|
4
|
+
import { InputSlotName, MonoInputCore } from "./input-core.js";
|
|
5
|
+
import { generateInputAriaAttributes, generateInputAttributes, getInputIcon, validateInputProps } from "./input-utils.js";
|
|
6
|
+
import { MonoInputShadow } from "./mono-input.shadow.js";
|
|
7
|
+
export { type InputColor, type InputEvents, type InputFormat, type InputFormatCtx, type InputFormatDescriptor, type InputFormatOn, type InputProps, type InputSize, type InputSlotName, type InputType, type InputVariant, MonoInputCore, MonoInputShadow, applyFormat, caretAfterFormat, generateInputAriaAttributes, generateInputAttributes, getInputIcon, localeSeparators, normaliseValue, parseFormat, resolveFormat, significantFor, stripFormat, validateInputProps };
|