smoothly 1.0.0-alpha.2 → 1.0.0-alpha.200
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{Listenable-c8d2f8ef.js → Data-ae713814.js} +526 -7
- package/dist/cjs/Data-ae713814.js.map +1 -0
- package/dist/cjs/GoogleFont-6c4f0da1.js +2 -0
- package/dist/cjs/GoogleFont-6c4f0da1.js.map +1 -0
- package/dist/cjs/Observers-6450f075.js +25 -0
- package/dist/cjs/Observers-6450f075.js.map +1 -0
- package/dist/cjs/TimeZone-016ac7b0.js +6181 -0
- package/dist/cjs/TimeZone-016ac7b0.js.map +1 -0
- package/dist/cjs/Tuple-18c7ae92.js +2892 -0
- package/dist/cjs/Tuple-18c7ae92.js.map +1 -0
- package/dist/cjs/{getLanguage-430ecf04.js → getLanguage-49a534df.js} +71 -5963
- package/dist/cjs/getLanguage-49a534df.js.map +1 -0
- package/dist/cjs/{index-de46f836.js → index-43af753b.js} +114 -43
- package/dist/cjs/index-43af753b.js.map +1 -0
- package/dist/cjs/index.cjs.js +396 -20
- package/dist/cjs/index.cjs.js.map +1 -0
- package/dist/cjs/loader.cjs.js +7 -3
- package/dist/cjs/loader.cjs.js.map +1 -0
- package/dist/cjs/redirect-2e5d4524.js +104 -0
- package/dist/cjs/redirect-2e5d4524.js.map +1 -0
- package/dist/cjs/smoothly-accordion-item.cjs.entry.js +61 -0
- package/dist/cjs/smoothly-accordion-item.cjs.entry.js.map +1 -0
- package/dist/cjs/smoothly-accordion.cjs.entry.js +58 -0
- package/dist/cjs/smoothly-accordion.cjs.entry.js.map +1 -0
- package/dist/cjs/smoothly-address-display.cjs.entry.js +32 -0
- package/dist/cjs/smoothly-address-display.cjs.entry.js.map +1 -0
- package/dist/cjs/smoothly-address.cjs.entry.js +23 -0
- package/dist/cjs/smoothly-address.cjs.entry.js.map +1 -0
- package/dist/cjs/smoothly-addresses.cjs.entry.js +23 -0
- package/dist/cjs/smoothly-addresses.cjs.entry.js.map +1 -0
- package/dist/cjs/smoothly-app_79.cjs.entry.js +7891 -0
- package/dist/cjs/smoothly-app_79.cjs.entry.js.map +1 -0
- package/dist/cjs/smoothly-checkbox.cjs.entry.js +102 -0
- package/dist/cjs/smoothly-checkbox.cjs.entry.js.map +1 -0
- package/dist/cjs/smoothly-color.cjs.entry.js +22 -0
- package/dist/cjs/smoothly-color.cjs.entry.js.map +1 -0
- package/dist/cjs/smoothly-country.cjs.entry.js +58 -55
- package/dist/cjs/smoothly-country.cjs.entry.js.map +1 -0
- package/dist/cjs/smoothly-display-date-time.cjs.entry.js +26 -0
- package/dist/cjs/smoothly-display-date-time.cjs.entry.js.map +1 -0
- package/dist/cjs/smoothly-filter-input.cjs.entry.js +61 -0
- package/dist/cjs/smoothly-filter-input.cjs.entry.js.map +1 -0
- package/dist/cjs/smoothly-google-font.cjs.entry.js +3 -1
- package/dist/cjs/smoothly-google-font.cjs.entry.js.map +1 -0
- package/dist/cjs/smoothly-reorder.cjs.entry.js +3 -1
- package/dist/cjs/smoothly-reorder.cjs.entry.js.map +1 -0
- package/dist/cjs/smoothly-trigger-sink.cjs.entry.js +6 -4
- package/dist/cjs/smoothly-trigger-sink.cjs.entry.js.map +1 -0
- package/dist/cjs/smoothly-trigger-source.cjs.entry.js +8 -6
- package/dist/cjs/smoothly-trigger-source.cjs.entry.js.map +1 -0
- package/dist/cjs/smoothly.cjs.js +10 -3
- package/dist/cjs/smoothly.cjs.js.map +1 -0
- package/dist/collection/collection-manifest.json +47 -16
- package/dist/collection/components/Button.js +19 -0
- package/dist/collection/components/Button.js.map +1 -0
- package/dist/collection/components/accordion/index.js +33 -12
- package/dist/collection/components/accordion/index.js.map +1 -0
- package/dist/collection/components/accordion-item/index.js +19 -25
- package/dist/collection/components/accordion-item/index.js.map +1 -0
- package/dist/collection/components/address/index.js +65 -0
- package/dist/collection/components/address/index.js.map +1 -0
- package/dist/collection/components/address/style.css +4 -0
- package/dist/collection/components/address-display/index.js +72 -0
- package/dist/collection/components/address-display/index.js.map +1 -0
- package/dist/collection/components/address-display/style.css +4 -0
- package/dist/collection/components/addresses/index.js +62 -0
- package/dist/collection/components/addresses/index.js.map +1 -0
- package/dist/collection/components/addresses/style.css +4 -0
- package/dist/collection/components/app/index.js +152 -1
- package/dist/collection/components/app/index.js.map +1 -0
- package/dist/collection/components/app/room/index.js +265 -0
- package/dist/collection/components/app/room/index.js.map +1 -0
- package/dist/collection/components/app/room/style.css +59 -0
- package/dist/collection/components/app/style.css +120 -107
- package/dist/collection/components/app-demo/index.js +6 -19
- package/dist/collection/components/app-demo/index.js.map +1 -0
- package/dist/collection/components/backtotop/index.js +4 -3
- package/dist/collection/components/backtotop/index.js.map +1 -0
- package/dist/collection/components/burger/index.js +174 -0
- package/dist/collection/components/burger/index.js.map +1 -0
- package/dist/collection/components/burger/style.css +22 -0
- package/dist/collection/components/button/index.js +50 -39
- package/dist/collection/components/button/index.js.map +1 -0
- package/dist/collection/components/button/style.css +200 -32
- package/dist/collection/components/button-demo/index.js +24 -0
- package/dist/collection/components/button-demo/index.js.map +1 -0
- package/dist/collection/components/button-demo/style.css +9 -0
- package/dist/collection/components/calendar/generate.js +2 -1
- package/dist/collection/components/calendar/generate.js.map +1 -0
- package/dist/collection/components/calendar/index.js +17 -16
- package/dist/collection/components/calendar/index.js.map +1 -0
- package/dist/collection/components/checkbox/index.js +143 -41
- package/dist/collection/components/checkbox/index.js.map +1 -0
- package/dist/collection/components/checkbox/style.css +52 -8
- package/dist/collection/components/checkbox/translation/index.js +1 -0
- package/dist/collection/components/checkbox/translation/index.js.map +1 -0
- package/dist/collection/components/checkbox/translation/sv.js +1 -0
- package/dist/collection/components/checkbox/translation/sv.js.map +1 -0
- package/dist/collection/components/color/index.js +48 -0
- package/dist/collection/components/color/index.js.map +1 -0
- package/dist/collection/components/color/style.css +69 -0
- package/dist/collection/components/confirm/index.js +261 -0
- package/dist/collection/components/confirm/index.js.map +1 -0
- package/dist/collection/components/confirm/style.css +15 -0
- package/dist/collection/components/country/index.js +2 -1
- package/dist/collection/components/country/index.js.map +1 -0
- package/dist/collection/components/dialog/index.js +1 -0
- package/dist/collection/components/dialog/index.js.map +1 -0
- package/dist/collection/components/dialog-demo/index.js +1 -0
- package/dist/collection/components/dialog-demo/index.js.map +1 -0
- package/dist/collection/components/display/index.js +7 -3
- package/dist/collection/components/display/index.js.map +1 -0
- package/dist/collection/components/display-amount/index.js +2 -1
- package/dist/collection/components/display-amount/index.js.map +1 -0
- package/dist/collection/components/display-date-time/index.js +1 -0
- package/dist/collection/components/display-date-time/index.js.map +1 -0
- package/dist/collection/components/display-demo/index.js +17 -1
- package/dist/collection/components/display-demo/index.js.map +1 -0
- package/dist/collection/components/filter/Filter.js +17 -0
- package/dist/collection/components/filter/Filter.js.map +1 -0
- package/dist/collection/components/filter/field/index.js +100 -0
- package/dist/collection/components/filter/field/index.js.map +1 -0
- package/dist/collection/components/filter/field/style.css +4 -0
- package/dist/collection/components/filter/index.js +61 -40
- package/dist/collection/components/filter/index.js.map +1 -0
- package/dist/collection/components/filter/input/index.js +67 -272
- package/dist/collection/components/filter/input/index.js.map +1 -0
- package/dist/collection/components/filter/input/style.css +2 -0
- package/dist/collection/components/filter/picker/index.js +174 -0
- package/dist/collection/components/filter/picker/index.js.map +1 -0
- package/dist/collection/components/filter/picker/style.css +7 -0
- package/dist/collection/components/filter/style.css +86 -1
- package/dist/collection/components/filter/toggle/index.js +237 -0
- package/dist/collection/components/filter/toggle/index.js.map +1 -0
- package/dist/collection/components/filter/toggle/style.css +8 -0
- package/dist/collection/components/form/index.js +518 -0
- package/dist/collection/components/form/index.js.map +1 -0
- package/dist/collection/components/form/style.css +44 -0
- package/dist/collection/components/frame/index.js +14 -11
- package/dist/collection/components/frame/index.js.map +1 -0
- package/dist/collection/components/google-font/index.js +1 -0
- package/dist/collection/components/google-font/index.js.map +1 -0
- package/dist/collection/components/icon/index.js +30 -33
- package/dist/collection/components/icon/index.js.map +1 -0
- package/dist/collection/components/icon-demo/index.js +2 -1
- package/dist/collection/components/icon-demo/index.js.map +1 -0
- package/dist/collection/components/icon-demo/style.css +5 -5
- package/dist/collection/components/input/Clearable.js +8 -0
- package/dist/collection/components/input/Clearable.js.map +1 -0
- package/dist/collection/components/input/Editable.js +18 -0
- package/dist/collection/components/input/Editable.js.map +1 -0
- package/dist/collection/components/input/Input.js +23 -0
- package/dist/collection/components/input/Input.js.map +1 -0
- package/dist/collection/components/input/Looks.js +8 -0
- package/dist/collection/components/input/Looks.js.map +1 -0
- package/dist/collection/components/input/Submittable.js +8 -0
- package/dist/collection/components/input/Submittable.js.map +1 -0
- package/dist/collection/components/input/checkbox/index.js +235 -0
- package/dist/collection/components/input/checkbox/index.js.map +1 -0
- package/dist/collection/components/input/checkbox/style.css +31 -0
- package/dist/collection/components/input/clear/index.js +242 -0
- package/dist/collection/components/input/clear/index.js.map +1 -0
- package/dist/collection/components/input/clear/style.css +256 -0
- package/dist/collection/components/input/color/index.js +226 -0
- package/dist/collection/components/input/color/index.js.map +1 -0
- package/dist/collection/components/input/color/style.css +15 -0
- package/dist/collection/components/{input-date-range → input/date}/index.js +154 -99
- package/dist/collection/components/input/date/index.js.map +1 -0
- package/dist/collection/components/input/date/range/index.js +443 -0
- package/dist/collection/components/input/date/range/index.js.map +1 -0
- package/dist/collection/components/input/date/range/style.css +94 -0
- package/dist/collection/components/input/date/style.css +83 -0
- package/dist/collection/components/input/demo/index.js +47 -0
- package/dist/collection/components/input/demo/index.js.map +1 -0
- package/dist/collection/components/input/demo/style.css +15 -0
- package/dist/collection/components/input/edit/index.js +228 -0
- package/dist/collection/components/input/edit/index.js.map +1 -0
- package/dist/collection/components/input/edit/style.css +235 -0
- package/dist/collection/components/input/file/index.js +305 -0
- package/dist/collection/components/input/file/index.js.map +1 -0
- package/dist/collection/components/input/file/style.css +107 -0
- package/dist/collection/components/input/index.js +365 -112
- package/dist/collection/components/input/index.js.map +1 -0
- package/dist/collection/components/{input-month → input/month}/index.js +9 -8
- package/dist/collection/components/input/month/index.js.map +1 -0
- package/dist/collection/components/input/radio/Selected.js +11 -0
- package/dist/collection/components/input/radio/Selected.js.map +1 -0
- package/dist/collection/components/input/radio/index.js +261 -0
- package/dist/collection/components/input/radio/index.js.map +1 -0
- package/dist/collection/components/input/radio/item/index.js +150 -0
- package/dist/collection/components/input/radio/item/index.js.map +1 -0
- package/dist/collection/components/input/radio/item/style.css +28 -0
- package/dist/collection/components/input/radio/style.css +66 -0
- package/dist/collection/components/input/range/index.js +305 -0
- package/dist/collection/components/input/range/index.js.map +1 -0
- package/dist/collection/components/input/range/style.css +154 -0
- package/dist/collection/components/input/reset/index.js +239 -0
- package/dist/collection/components/input/reset/index.js.map +1 -0
- package/dist/collection/components/input/reset/style.css +259 -0
- package/dist/collection/components/input/select/index.js +452 -0
- package/dist/collection/components/input/select/index.js.map +1 -0
- package/dist/collection/components/input/select/style.css +104 -0
- package/dist/collection/components/input/style.css +57 -15
- package/dist/collection/components/input/submit/index.js +232 -0
- package/dist/collection/components/input/submit/index.js.map +1 -0
- package/dist/collection/components/input/submit/style.css +236 -0
- package/dist/collection/components/item/index.js +6 -5
- package/dist/collection/components/item/index.js.map +1 -0
- package/dist/collection/components/label/index.js +81 -0
- package/dist/collection/components/label/index.js.map +1 -0
- package/dist/collection/components/label/style.css +15 -0
- package/dist/collection/components/lazy/index.js +73 -0
- package/dist/collection/components/lazy/index.js.map +1 -0
- package/dist/collection/components/load-more/index.js +94 -0
- package/dist/collection/components/load-more/index.js.map +1 -0
- package/dist/collection/components/load-more/style.css +5 -0
- package/dist/collection/components/notification/index.js +46 -8
- package/dist/collection/components/notification/index.js.map +1 -0
- package/dist/collection/components/notification/style.css +25 -1
- package/dist/collection/components/notifier/index.js +1 -0
- package/dist/collection/components/notifier/index.js.map +1 -0
- package/dist/collection/components/notifier/style.css +1 -3
- package/dist/collection/components/picker/demo/index.js +91 -0
- package/dist/collection/components/picker/demo/index.js.map +1 -0
- package/dist/collection/components/picker/demo/style.css +30 -0
- package/dist/collection/components/picker/index.js +198 -396
- package/dist/collection/components/picker/index.js.map +1 -0
- package/dist/collection/components/picker/menu/index.js +429 -0
- package/dist/collection/components/picker/menu/index.js.map +1 -0
- package/dist/collection/components/picker/menu/style.css +44 -0
- package/dist/collection/components/picker/option/index.js +298 -0
- package/dist/collection/components/picker/option/index.js.map +1 -0
- package/dist/collection/components/picker/option/style.css +30 -0
- package/dist/collection/components/picker/slot-elements/index.js +109 -0
- package/dist/collection/components/picker/slot-elements/index.js.map +1 -0
- package/dist/collection/components/picker/slot-elements/style.css +3 -0
- package/dist/collection/components/picker/slotted-elements/index.js +84 -0
- package/dist/collection/components/picker/slotted-elements/index.js.map +1 -0
- package/dist/collection/components/picker/slotted-elements/style.css +3 -0
- package/dist/collection/components/picker/style.css +76 -136
- package/dist/collection/components/popup/index.js +6 -5
- package/dist/collection/components/popup/index.js.map +1 -0
- package/dist/collection/components/popup/style.css +4 -4
- package/dist/collection/components/quiet/index.js +1 -0
- package/dist/collection/components/quiet/index.js.map +1 -0
- package/dist/collection/components/reorder/Draggable.js +1 -0
- package/dist/collection/components/reorder/Draggable.js.map +1 -0
- package/dist/collection/components/reorder/Dragged.js +1 -0
- package/dist/collection/components/reorder/Dragged.js.map +1 -0
- package/dist/collection/components/reorder/index.js +1 -0
- package/dist/collection/components/reorder/index.js.map +1 -0
- package/dist/collection/components/select-demo/index.js +1 -88
- package/dist/collection/components/select-demo/index.js.map +1 -0
- package/dist/collection/components/skeleton/index.js +1 -0
- package/dist/collection/components/skeleton/index.js.map +1 -0
- package/dist/collection/components/spinner/index.js +1 -0
- package/dist/collection/components/spinner/index.js.map +1 -0
- package/dist/collection/components/spinner/style.css +1 -0
- package/dist/collection/components/submit/index.js +99 -97
- package/dist/collection/components/submit/index.js.map +1 -0
- package/dist/collection/components/submit/style.css +211 -22
- package/dist/collection/components/summary/index.js +134 -0
- package/dist/collection/components/summary/index.js.map +1 -0
- package/dist/collection/components/summary/style.css +40 -0
- package/dist/collection/components/svg/index.js +1 -0
- package/dist/collection/components/svg/index.js.map +1 -0
- package/dist/collection/components/svg/style.css +2 -2
- package/dist/collection/components/tab/index.js +1 -0
- package/dist/collection/components/tab/index.js.map +1 -0
- package/dist/collection/components/tab-switch/index.js +1 -0
- package/dist/collection/components/tab-switch/index.js.map +1 -0
- package/dist/collection/components/table/Selector.js +44 -0
- package/dist/collection/components/table/Selector.js.map +1 -0
- package/dist/collection/components/table/cell/index.js +2 -1
- package/dist/collection/components/table/cell/index.js.map +1 -0
- package/dist/collection/components/table/cell/style.css +26 -9
- package/dist/collection/components/table/demo/filtered/Root.js +1 -0
- package/dist/collection/components/table/demo/filtered/Root.js.map +1 -0
- package/dist/collection/components/table/demo/filtered/index.js +41 -14
- package/dist/collection/components/table/demo/filtered/index.js.map +1 -0
- package/dist/collection/components/table/demo/filtered/style.css +9 -0
- package/dist/collection/components/table/demo/index.js +3 -8
- package/dist/collection/components/table/demo/index.js.map +1 -0
- package/dist/collection/components/table/demo/style.css +7 -0
- package/dist/collection/components/table/demo/testing/data.js +28 -0
- package/dist/collection/components/table/demo/testing/data.js.map +1 -0
- package/dist/collection/components/table/demo/testing/index.js +28 -0
- package/dist/collection/components/table/demo/testing/index.js.map +1 -0
- package/dist/collection/components/table/demo/testing/style.css +32 -0
- package/dist/collection/components/table/expandable/cell/index.js +15 -33
- package/dist/collection/components/table/expandable/cell/index.js.map +1 -0
- package/dist/collection/components/table/expandable/cell/style.css +41 -24
- package/dist/collection/components/table/expandable/row/index.js +10 -51
- package/dist/collection/components/table/expandable/row/index.js.map +1 -0
- package/dist/collection/components/table/expandable/row/style.css +32 -29
- package/dist/collection/components/{filter/advanced-filter → table/footer}/index.js +3 -2
- package/dist/collection/components/table/footer/index.js.map +1 -0
- package/dist/collection/components/table/footer/style.css +10 -0
- package/dist/collection/components/table/header/index.js +1 -0
- package/dist/collection/components/table/header/index.js.map +1 -0
- package/dist/collection/components/table/header/style.css +12 -2
- package/dist/collection/components/table/index.js +75 -12
- package/dist/collection/components/table/index.js.map +1 -0
- package/dist/collection/components/table/row/index.js +38 -5
- package/dist/collection/components/table/row/index.js.map +1 -0
- package/dist/collection/components/table/row/style.css +4 -1
- package/dist/collection/components/table/style.css +0 -2
- package/dist/collection/components/theme/color/index.js +48 -0
- package/dist/collection/components/theme/color/index.js.map +1 -0
- package/dist/collection/components/theme/color/style.css +8 -0
- package/dist/collection/components/theme/color/variant/index.js +66 -0
- package/dist/collection/components/theme/color/variant/index.js.map +1 -0
- package/dist/collection/components/theme/color/variant/style.css +18 -0
- package/dist/collection/components/theme/colors/index.js +30 -0
- package/dist/collection/components/theme/colors/index.js.map +1 -0
- package/dist/collection/components/theme/colors/style.css +7 -0
- package/dist/collection/components/theme/picker/index.js +48 -0
- package/dist/collection/components/theme/picker/index.js.map +1 -0
- package/dist/collection/components/theme/picker/style.css +0 -0
- package/dist/collection/components/toggle/style.css +36 -0
- package/dist/collection/components/{radio/index.js → toggle/toggle.js} +55 -48
- package/dist/collection/components/toggle/toggle.js.map +1 -0
- package/dist/collection/components/toggle-switch/index.js +170 -0
- package/dist/collection/components/toggle-switch/index.js.map +1 -0
- package/dist/collection/components/toggle-switch/style.css +63 -0
- package/dist/collection/components/trigger/index.js +1 -23
- package/dist/collection/components/trigger/index.js.map +1 -0
- package/dist/collection/components/trigger/style.css +2 -2
- package/dist/collection/components/trigger-sink/index.js +1 -0
- package/dist/collection/components/trigger-sink/index.js.map +1 -0
- package/dist/collection/components/trigger-source/index.js +4 -3
- package/dist/collection/components/trigger-source/index.js.map +1 -0
- package/dist/collection/components/tuple/index.js +1 -0
- package/dist/collection/components/tuple/index.js.map +1 -0
- package/dist/collection/components/urlencoded/index.js +1 -0
- package/dist/collection/components/urlencoded/index.js.map +1 -0
- package/dist/collection/global/Observers.js +22 -0
- package/dist/collection/global/Observers.js.map +1 -0
- package/dist/collection/global/index.js +5 -0
- package/dist/collection/global/index.js.map +1 -0
- package/dist/collection/index.js +3 -3
- package/dist/collection/index.js.map +1 -0
- package/dist/collection/model/Autocomplete.js +1 -0
- package/dist/collection/model/Autocomplete.js.map +1 -0
- package/dist/collection/model/ClientIdentifier.js +1 -0
- package/dist/collection/model/ClientIdentifier.js.map +1 -0
- package/dist/collection/model/Color.js +19 -1
- package/dist/collection/model/Color.js.map +1 -0
- package/dist/collection/model/Data.js +22 -0
- package/dist/collection/model/Data.js.map +1 -0
- package/dist/collection/model/Fill.js +1 -0
- package/dist/collection/model/Fill.js.map +1 -0
- package/dist/collection/model/GoogleFont.js +1 -0
- package/dist/collection/model/GoogleFont.js.map +1 -0
- package/dist/collection/model/Icon.js +23 -0
- package/dist/collection/model/Icon.js.map +1 -0
- package/dist/collection/model/Listenable.js +20 -6
- package/dist/collection/model/Listenable.js.map +1 -0
- package/dist/collection/model/Message.js +1 -0
- package/dist/collection/model/Message.js.map +1 -0
- package/dist/collection/model/Notice.js +2 -1
- package/dist/collection/model/Notice.js.map +1 -0
- package/dist/collection/model/Option.js +1 -0
- package/dist/collection/model/Option.js.map +1 -0
- package/dist/collection/model/StateBase.js +8 -0
- package/dist/collection/model/StateBase.js.map +1 -0
- package/dist/collection/model/Trigger.js +1 -0
- package/dist/collection/model/Trigger.js.map +1 -0
- package/dist/collection/model/index.js +6 -0
- package/dist/collection/model/index.js.map +1 -0
- package/dist/collection/model/redirect.js +8 -0
- package/dist/collection/model/redirect.js.map +1 -0
- package/dist/collection/smoothly.js +3 -0
- package/dist/collection/smoothly.js.map +1 -0
- package/dist/collection/utilities/Cosmetic/Color/CommaRgb.js +1 -0
- package/dist/collection/utilities/Cosmetic/Color/CommaRgb.js.map +1 -0
- package/dist/collection/utilities/Cosmetic/Color/Hex.js +1 -0
- package/dist/collection/utilities/Cosmetic/Color/Hex.js.map +1 -0
- package/dist/collection/utilities/Cosmetic/Color/Hsl.js +1 -0
- package/dist/collection/utilities/Cosmetic/Color/Hsl.js.map +1 -0
- package/dist/collection/utilities/Cosmetic/Color/Name.js +1 -0
- package/dist/collection/utilities/Cosmetic/Color/Name.js.map +1 -0
- package/dist/collection/utilities/Cosmetic/Color/Rgb.js +1 -0
- package/dist/collection/utilities/Cosmetic/Color/Rgb.js.map +1 -0
- package/dist/collection/utilities/Cosmetic/Color/index.js +1 -0
- package/dist/collection/utilities/Cosmetic/Color/index.js.map +1 -0
- package/dist/collection/utilities/Cosmetic/index.js +1 -0
- package/dist/collection/utilities/Cosmetic/index.js.map +1 -0
- package/dist/collection/utilities/index.js +1 -0
- package/dist/collection/utilities/index.js.map +1 -0
- package/dist/custom-elements/index.d.ts +240 -60
- package/dist/custom-elements/index.js +15319 -31465
- package/dist/custom-elements/index.js.map +1 -0
- package/dist/esm/{Listenable-55a1f6af.js → Data-0390d600.js} +521 -8
- package/dist/esm/Data-0390d600.js.map +1 -0
- package/dist/esm/GoogleFont-8474516b.js +2 -0
- package/dist/esm/GoogleFont-8474516b.js.map +1 -0
- package/dist/esm/Observers-5f08e828.js +25 -0
- package/dist/esm/Observers-5f08e828.js.map +1 -0
- package/dist/esm/TimeZone-c8df4905.js +6181 -0
- package/dist/esm/TimeZone-c8df4905.js.map +1 -0
- package/dist/esm/Tuple-7ed75ff3.js +2878 -0
- package/dist/esm/Tuple-7ed75ff3.js.map +1 -0
- package/dist/esm/{getLanguage-cccb8418.js → getLanguage-1e9ec036.js} +72 -5964
- package/dist/esm/getLanguage-1e9ec036.js.map +1 -0
- package/dist/esm/{index-d3421c35.js → index-258984d3.js} +114 -42
- package/dist/esm/index-258984d3.js.map +1 -0
- package/dist/esm/index.js +399 -6
- package/dist/esm/index.js.map +1 -0
- package/dist/esm/loader.js +7 -3
- package/dist/esm/loader.js.map +1 -0
- package/dist/esm/redirect-b0f87e88.js +101 -0
- package/dist/esm/redirect-b0f87e88.js.map +1 -0
- package/dist/esm/smoothly-accordion-item.entry.js +57 -0
- package/dist/esm/smoothly-accordion-item.entry.js.map +1 -0
- package/dist/esm/smoothly-accordion.entry.js +54 -0
- package/dist/esm/smoothly-accordion.entry.js.map +1 -0
- package/dist/esm/smoothly-address-display.entry.js +28 -0
- package/dist/esm/smoothly-address-display.entry.js.map +1 -0
- package/dist/esm/smoothly-address.entry.js +19 -0
- package/dist/esm/smoothly-address.entry.js.map +1 -0
- package/dist/esm/smoothly-addresses.entry.js +19 -0
- package/dist/esm/smoothly-addresses.entry.js.map +1 -0
- package/dist/esm/smoothly-app_79.entry.js +7809 -0
- package/dist/esm/smoothly-app_79.entry.js.map +1 -0
- package/dist/esm/smoothly-checkbox.entry.js +98 -0
- package/dist/esm/smoothly-checkbox.entry.js.map +1 -0
- package/dist/esm/smoothly-color.entry.js +18 -0
- package/dist/esm/smoothly-color.entry.js.map +1 -0
- package/dist/esm/smoothly-country.entry.js +12 -9
- package/dist/esm/smoothly-country.entry.js.map +1 -0
- package/dist/esm/smoothly-display-date-time.entry.js +22 -0
- package/dist/esm/smoothly-display-date-time.entry.js.map +1 -0
- package/dist/esm/smoothly-filter-input.entry.js +57 -0
- package/dist/esm/smoothly-filter-input.entry.js.map +1 -0
- package/dist/esm/smoothly-google-font.entry.js +3 -1
- package/dist/esm/smoothly-google-font.entry.js.map +1 -0
- package/dist/esm/smoothly-reorder.entry.js +3 -1
- package/dist/esm/smoothly-reorder.entry.js.map +1 -0
- package/dist/esm/smoothly-trigger-sink.entry.js +4 -2
- package/dist/esm/smoothly-trigger-sink.entry.js.map +1 -0
- package/dist/esm/smoothly-trigger-source.entry.js +6 -4
- package/dist/esm/smoothly-trigger-source.entry.js.map +1 -0
- package/dist/esm/smoothly.js +7 -3
- package/dist/esm/smoothly.js.map +1 -0
- package/dist/smoothly/index.esm.js +2 -1
- package/dist/smoothly/index.esm.js.map +1 -0
- package/dist/smoothly/p-12182a73.entry.js +2 -0
- package/dist/smoothly/p-12182a73.entry.js.map +1 -0
- package/dist/smoothly/p-127dcc56.entry.js +2 -0
- package/dist/smoothly/p-127dcc56.entry.js.map +1 -0
- package/dist/smoothly/p-21905b32.entry.js +2 -0
- package/dist/smoothly/p-21905b32.entry.js.map +1 -0
- package/dist/smoothly/p-312ef066.js +2 -0
- package/dist/smoothly/p-312ef066.js.map +1 -0
- package/dist/smoothly/p-47151a53.entry.js +2 -0
- package/dist/smoothly/p-47151a53.entry.js.map +1 -0
- package/dist/smoothly/p-5e387578.js +3 -0
- package/dist/smoothly/p-5e387578.js.map +1 -0
- package/dist/smoothly/p-6aebb818.entry.js +2 -0
- package/dist/smoothly/p-6aebb818.entry.js.map +1 -0
- package/dist/smoothly/p-6e9aca2e.entry.js +2 -0
- package/dist/smoothly/p-6e9aca2e.entry.js.map +1 -0
- package/dist/smoothly/p-7bf147bf.entry.js +2 -0
- package/dist/smoothly/p-7bf147bf.entry.js.map +1 -0
- package/dist/smoothly/p-823e02b0.entry.js +2 -0
- package/dist/smoothly/p-823e02b0.entry.js.map +1 -0
- package/dist/smoothly/p-9b828bde.js +2 -0
- package/dist/smoothly/p-9b828bde.js.map +1 -0
- package/dist/smoothly/p-a0ebd646.entry.js +2 -0
- package/dist/smoothly/p-a0ebd646.entry.js.map +1 -0
- package/dist/smoothly/p-b3eac6af.entry.js +2 -0
- package/dist/smoothly/p-b3eac6af.entry.js.map +1 -0
- package/dist/smoothly/p-bd478a53.js +2 -1
- package/dist/smoothly/p-bd478a53.js.map +1 -0
- package/dist/smoothly/p-c25cbaf3.entry.js +2 -0
- package/dist/smoothly/p-c25cbaf3.entry.js.map +1 -0
- package/dist/smoothly/p-c833c402.js +2 -0
- package/dist/smoothly/p-c833c402.js.map +1 -0
- package/dist/smoothly/p-cb493516.entry.js +2 -0
- package/dist/smoothly/p-cb493516.entry.js.map +1 -0
- package/dist/smoothly/p-e1525851.entry.js +2 -0
- package/dist/smoothly/p-e1525851.entry.js.map +1 -0
- package/dist/smoothly/p-ede93d69.js +2 -0
- package/dist/smoothly/p-ede93d69.js.map +1 -0
- package/dist/smoothly/p-eef1c80b.entry.js +2 -0
- package/dist/smoothly/p-eef1c80b.entry.js.map +1 -0
- package/dist/smoothly/p-f125610c.entry.js +2 -0
- package/dist/smoothly/p-f125610c.entry.js.map +1 -0
- package/dist/smoothly/p-fa553f1a.js +2 -0
- package/dist/smoothly/p-fa553f1a.js.map +1 -0
- package/dist/smoothly/p-fa664317.js +2 -0
- package/dist/smoothly/p-fa664317.js.map +1 -0
- package/dist/smoothly/smoothly.esm.js +2 -1
- package/dist/smoothly/smoothly.esm.js.map +1 -0
- package/dist/types/components/Button.d.ts +9 -0
- package/dist/types/components/accordion/index.d.ts +1 -1
- package/dist/types/components/accordion-item/index.d.ts +5 -4
- package/dist/types/components/address/index.d.ts +6 -0
- package/dist/types/components/address-display/index.d.ts +13 -0
- package/dist/types/components/addresses/index.d.ts +6 -0
- package/dist/types/components/app/index.d.ts +25 -0
- package/dist/types/components/app/room/index.d.ts +26 -0
- package/dist/types/components/app-demo/index.d.ts +2 -0
- package/dist/types/components/backtotop/index.d.ts +1 -1
- package/dist/types/components/burger/index.d.ts +15 -0
- package/dist/types/components/button/index.d.ts +9 -7
- package/dist/types/components/button-demo/index.d.ts +3 -0
- package/dist/types/components/calendar/index.d.ts +5 -5
- package/dist/types/components/checkbox/index.d.ts +11 -8
- package/dist/types/components/color/index.d.ts +5 -0
- package/dist/types/components/confirm/index.d.ts +19 -0
- package/dist/types/components/filter/Filter.d.ts +21 -0
- package/dist/types/components/filter/field/index.d.ts +9 -0
- package/dist/types/components/filter/index.d.ts +14 -5
- package/dist/types/components/filter/input/index.d.ts +15 -21
- package/dist/types/components/filter/picker/index.d.ts +22 -0
- package/dist/types/components/filter/toggle/index.d.ts +20 -0
- package/dist/types/components/form/index.d.ts +36 -0
- package/dist/types/components/frame/index.d.ts +3 -3
- package/dist/types/components/icon/index.d.ts +3 -9
- package/dist/types/components/input/Clearable.d.ts +6 -0
- package/dist/types/components/input/Editable.d.ts +20 -0
- package/dist/types/components/input/Input.d.ts +22 -0
- package/dist/types/components/input/Looks.d.ts +7 -0
- package/dist/types/components/input/Submittable.d.ts +6 -0
- package/dist/types/components/input/checkbox/index.d.ts +20 -0
- package/dist/types/components/input/clear/index.d.ts +17 -0
- package/dist/types/components/input/color/index.d.ts +24 -0
- package/dist/types/components/input/date/index.d.ts +28 -0
- package/dist/types/components/input/date/range/index.d.ts +33 -0
- package/dist/types/components/input/demo/index.d.ts +6 -0
- package/dist/types/components/input/edit/index.d.ts +17 -0
- package/dist/types/components/input/file/index.d.ts +24 -0
- package/dist/types/components/input/index.d.ts +33 -19
- package/dist/types/components/{input-month → input/month}/index.d.ts +2 -2
- package/dist/types/components/input/radio/Selected.d.ts +10 -0
- package/dist/types/components/input/radio/index.d.ts +25 -0
- package/dist/types/components/input/radio/item/index.d.ts +15 -0
- package/dist/types/components/input/range/index.d.ts +24 -0
- package/dist/types/components/input/reset/index.d.ts +17 -0
- package/dist/types/components/input/select/index.d.ts +36 -0
- package/dist/types/components/input/submit/index.d.ts +17 -0
- package/dist/types/components/item/index.d.ts +1 -1
- package/dist/types/components/label/index.d.ts +6 -0
- package/dist/types/components/lazy/index.d.ts +7 -0
- package/dist/types/components/load-more/index.d.ts +10 -0
- package/dist/types/components/notification/index.d.ts +3 -1
- package/dist/types/components/picker/demo/index.d.ts +22 -0
- package/dist/types/components/picker/index.d.ts +33 -45
- package/dist/types/components/picker/menu/index.d.ts +54 -0
- package/dist/types/components/picker/option/index.d.ts +23 -0
- package/dist/types/components/picker/slot-elements/index.d.ts +15 -0
- package/dist/types/components/picker/slotted-elements/index.d.ts +8 -0
- package/dist/types/components/popup/index.d.ts +1 -1
- package/dist/types/components/select-demo/index.d.ts +0 -9
- package/dist/types/components/submit/index.d.ts +12 -11
- package/dist/types/components/summary/index.d.ts +11 -0
- package/dist/types/components/table/Selector.d.ts +10 -0
- package/dist/types/components/table/demo/filtered/Root.d.ts +25 -15
- package/dist/types/components/table/demo/filtered/index.d.ts +9 -5
- package/dist/types/components/table/demo/index.d.ts +1 -1
- package/dist/types/components/table/demo/testing/data.d.ts +5 -0
- package/dist/types/components/table/demo/testing/index.d.ts +4 -0
- package/dist/types/components/table/expandable/cell/index.d.ts +4 -5
- package/dist/types/components/table/expandable/row/index.d.ts +3 -8
- package/dist/types/components/table/footer/index.d.ts +3 -0
- package/dist/types/components/table/index.d.ts +7 -3
- package/dist/types/components/table/row/index.d.ts +3 -1
- package/dist/types/components/theme/color/index.d.ts +5 -0
- package/dist/types/components/theme/color/variant/index.d.ts +6 -0
- package/dist/types/components/theme/colors/index.d.ts +3 -0
- package/dist/types/components/theme/picker/index.d.ts +4 -0
- package/dist/types/components/toggle/toggle.d.ts +9 -0
- package/dist/types/components/toggle-switch/index.d.ts +13 -0
- package/dist/types/components/trigger/index.d.ts +1 -2
- package/dist/types/components/trigger-source/index.d.ts +1 -1
- package/dist/types/components.d.ts +1146 -379
- package/dist/types/global/Observers.d.ts +8 -0
- package/dist/types/global/index.d.ts +4 -0
- package/dist/types/index.d.ts +1 -4
- package/dist/types/model/Color.d.ts +7 -1
- package/dist/types/model/Data.d.ts +13 -0
- package/dist/types/model/Icon.d.ts +8 -0
- package/dist/types/model/Listenable.d.ts +17 -3
- package/dist/types/model/Notice.d.ts +1 -1
- package/dist/types/model/Option.d.ts +24 -6
- package/dist/types/model/StateBase.d.ts +6 -0
- package/dist/types/model/index.d.ts +5 -2
- package/dist/types/model/redirect.d.ts +1 -0
- package/dist/types/smoothly.d.ts +3 -0
- package/dist/types/stencil-public-runtime.d.ts +20 -0
- package/loader/index.d.ts +9 -0
- package/package.json +19 -17
- package/dist/cjs/index-879bbabb.js +0 -863
- package/dist/cjs/smoothly-accordion_57.cjs.entry.js +0 -27735
- package/dist/cjs/smoothly-radio-group.cjs.entry.js +0 -20
- package/dist/collection/components/App.js +0 -70
- package/dist/collection/components/filter/advanced-filter/style.css +0 -3
- package/dist/collection/components/input-date/index.js +0 -205
- package/dist/collection/components/input-date/style.css +0 -39
- package/dist/collection/components/input-date-range/style.css +0 -51
- package/dist/collection/components/input-demo/index.js +0 -10
- package/dist/collection/components/menu-options/index.js +0 -412
- package/dist/collection/components/menu-options/style.css +0 -18
- package/dist/collection/components/option/index.js +0 -269
- package/dist/collection/components/option/style.css +0 -42
- package/dist/collection/components/radio/style.css +0 -31
- package/dist/collection/components/radio-button/Selected.js +0 -1
- package/dist/collection/components/radio-button/index.js +0 -136
- package/dist/collection/components/radio-button/item/index.js +0 -116
- package/dist/collection/components/radio-button/item/style.css +0 -95
- package/dist/collection/components/radio-group/index.js +0 -42
- package/dist/collection/components/radio-group/style.css +0 -36
- package/dist/collection/components/room/index.js +0 -89
- package/dist/collection/components/select/index.js +0 -107
- package/dist/collection/components/select/style.css +0 -20
- package/dist/collection/components/selector/index.js +0 -233
- package/dist/collection/components/selector/style.css +0 -46
- package/dist/collection/components/submit/Data.js +0 -12
- package/dist/collection/components/table/demo/filtered/File.js +0 -1
- package/dist/collection/components/table/demo/filtered/Metadata.js +0 -1
- package/dist/collection/components/table/demo/filtered/Review.js +0 -1
- package/dist/collection/model/Expand.js +0 -1
- package/dist/esm/index-d7a4e405.js +0 -859
- package/dist/esm/smoothly-accordion_57.entry.js +0 -27675
- package/dist/esm/smoothly-radio-group.entry.js +0 -16
- package/dist/smoothly/p-156763cd.js +0 -1
- package/dist/smoothly/p-4a0b35b7.js +0 -2
- package/dist/smoothly/p-4fecfc5d.entry.js +0 -1
- package/dist/smoothly/p-5b6351f6.js +0 -1
- package/dist/smoothly/p-5d41e3ca.entry.js +0 -1
- package/dist/smoothly/p-6630d923.entry.js +0 -1
- package/dist/smoothly/p-6e3d559e.entry.js +0 -1
- package/dist/smoothly/p-7db49a38.entry.js +0 -1
- package/dist/smoothly/p-94e08cee.js +0 -1
- package/dist/smoothly/p-96e8781a.entry.js +0 -1
- package/dist/smoothly/p-e0f4957d.entry.js +0 -1
- package/dist/types/components/App.d.ts +0 -5
- package/dist/types/components/filter/advanced-filter/index.d.ts +0 -3
- package/dist/types/components/input-date/index.d.ts +0 -14
- package/dist/types/components/input-date-range/index.d.ts +0 -23
- package/dist/types/components/input-demo/index.d.ts +0 -3
- package/dist/types/components/menu-options/index.d.ts +0 -35
- package/dist/types/components/option/index.d.ts +0 -32
- package/dist/types/components/radio/index.d.ts +0 -13
- package/dist/types/components/radio-button/Selected.d.ts +0 -5
- package/dist/types/components/radio-button/index.d.ts +0 -15
- package/dist/types/components/radio-button/item/index.d.ts +0 -12
- package/dist/types/components/radio-group/index.d.ts +0 -4
- package/dist/types/components/room/index.d.ts +0 -7
- package/dist/types/components/select/index.d.ts +0 -14
- package/dist/types/components/selector/index.d.ts +0 -23
- package/dist/types/components/submit/Data.d.ts +0 -7
- package/dist/types/components/table/demo/filtered/File.d.ts +0 -14
- package/dist/types/components/table/demo/filtered/Metadata.d.ts +0 -23
- package/dist/types/components/table/demo/filtered/Review.d.ts +0 -9
- package/dist/types/model/Expand.d.ts +0 -1
- /package/dist/collection/components/{input-month → input/month}/style.css +0 -0
- /package/dist/collection/components/{radio-button → lazy}/style.css +0 -0
|
@@ -47,6 +47,15 @@ function decode(value, standard = "standard") {
|
|
|
47
47
|
}
|
|
48
48
|
return result;
|
|
49
49
|
}
|
|
50
|
+
function next(value, increment = 1, standard = "standard") {
|
|
51
|
+
const table = tables[standard];
|
|
52
|
+
const rest = value.length > 1 ? value.substring(0, value.length - 1) : increment > 0 ? "" : table[63];
|
|
53
|
+
const number = (value.length == 0 ? 0 : table.indexOf(value[value.length - 1])) + increment;
|
|
54
|
+
return ((number > 63 || number < 0 ? next(rest, Math.floor(number / 63), standard) : rest) + table[remainder(number, 64)]);
|
|
55
|
+
}
|
|
56
|
+
function remainder(left, right) {
|
|
57
|
+
return left >= 0 ? left % right : remainder(left + right, right);
|
|
58
|
+
}
|
|
50
59
|
|
|
51
60
|
const crypto = typeof window != "undefined"
|
|
52
61
|
? window.crypto || window.msCrypto
|
|
@@ -153,6 +162,23 @@ exports.Identifier = void 0;
|
|
|
153
162
|
return result.join("");
|
|
154
163
|
}
|
|
155
164
|
Identifier.toHexadecimal = toHexadecimal;
|
|
165
|
+
function min(length) {
|
|
166
|
+
return "".padStart(length, "A");
|
|
167
|
+
}
|
|
168
|
+
Identifier.min = min;
|
|
169
|
+
function max(length) {
|
|
170
|
+
return "".padStart(length, "_");
|
|
171
|
+
}
|
|
172
|
+
Identifier.max = max;
|
|
173
|
+
function next$1(identifier, increment = 1) {
|
|
174
|
+
const result = next(identifier, increment, "url");
|
|
175
|
+
return result.length == identifier.length ? result : result.substring(result.length - identifier.length);
|
|
176
|
+
}
|
|
177
|
+
Identifier.next = next$1;
|
|
178
|
+
function previous(identifier, decrement = 1) {
|
|
179
|
+
return next$1(identifier, -decrement);
|
|
180
|
+
}
|
|
181
|
+
Identifier.previous = previous;
|
|
156
182
|
Identifier.length = [
|
|
157
183
|
4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 48, 52, 56, 60, 64, 68, 72, 76, 80, 84, 88, 92, 96, 100, 104, 108, 112,
|
|
158
184
|
116, 120, 124, 128,
|
|
@@ -438,7 +464,13 @@ if (!Uint8Array.__proto__.from) {
|
|
|
438
464
|
var Converter;
|
|
439
465
|
(function (Converter) {
|
|
440
466
|
function is(value) {
|
|
441
|
-
return typeof value == "object" &&
|
|
467
|
+
return (typeof value == "object" &&
|
|
468
|
+
Object.values(value).every(v => v &&
|
|
469
|
+
typeof v == "object" &&
|
|
470
|
+
"forward" in v &&
|
|
471
|
+
typeof v.forward == "function" &&
|
|
472
|
+
"backward" in v &&
|
|
473
|
+
typeof v.backward == "function"));
|
|
442
474
|
}
|
|
443
475
|
Converter.is = is;
|
|
444
476
|
})(Converter || (Converter = {}));
|
|
@@ -656,6 +688,451 @@ var Token;
|
|
|
656
688
|
Token.is = is;
|
|
657
689
|
})(Token || (Token = {}));
|
|
658
690
|
|
|
691
|
+
class Type {
|
|
692
|
+
get name() {
|
|
693
|
+
return typeof this._name == "function" ? this._name() : this._name;
|
|
694
|
+
}
|
|
695
|
+
get condition() {
|
|
696
|
+
return typeof this._condition == "function" ? this._condition() : this._condition;
|
|
697
|
+
}
|
|
698
|
+
optional() {
|
|
699
|
+
return new IslyOptional(this);
|
|
700
|
+
}
|
|
701
|
+
readonly() {
|
|
702
|
+
return new IslyReadonly(this);
|
|
703
|
+
}
|
|
704
|
+
array(...options) {
|
|
705
|
+
return array(this, ...options);
|
|
706
|
+
}
|
|
707
|
+
constructor(_name, _condition) {
|
|
708
|
+
this._name = _name;
|
|
709
|
+
this._condition = _condition;
|
|
710
|
+
/**
|
|
711
|
+
* Return the value if the value is valid for the type, otherwise undefined.
|
|
712
|
+
* For objects, unknown properties are filtered.
|
|
713
|
+
*
|
|
714
|
+
* Eg: isly.number().value(NaN) returns undefined
|
|
715
|
+
*/
|
|
716
|
+
this.get = value => (this.is(value) ? this.getValue(value) : undefined);
|
|
717
|
+
/**
|
|
718
|
+
* Return a flaw object, describing the flaws of the value compared to expected type.
|
|
719
|
+
*
|
|
720
|
+
* If it is a correct value, according to the type, it returns a Flaw with the message `{message:"This type is correct.", isFlaw: false, ... }`
|
|
721
|
+
*
|
|
722
|
+
* Implemented as a closure.
|
|
723
|
+
*/
|
|
724
|
+
this.flaw = value => {
|
|
725
|
+
return this.is(value)
|
|
726
|
+
? {
|
|
727
|
+
type: this.name,
|
|
728
|
+
...(this.condition ? { condition: this.condition } : undefined),
|
|
729
|
+
isFlaw: false,
|
|
730
|
+
message: "This type is correct.",
|
|
731
|
+
}
|
|
732
|
+
: {
|
|
733
|
+
...(this.condition ? { condition: this.condition } : undefined),
|
|
734
|
+
...this.createFlaw(value),
|
|
735
|
+
type: this.name,
|
|
736
|
+
};
|
|
737
|
+
};
|
|
738
|
+
}
|
|
739
|
+
getValue(value) {
|
|
740
|
+
return value;
|
|
741
|
+
}
|
|
742
|
+
/**
|
|
743
|
+
* Override this to create custom Flaws.
|
|
744
|
+
* Not necessary for simple types.
|
|
745
|
+
*/
|
|
746
|
+
createFlaw(value) {
|
|
747
|
+
return {};
|
|
748
|
+
}
|
|
749
|
+
/**
|
|
750
|
+
* Used by types that use a backend type.
|
|
751
|
+
*/
|
|
752
|
+
createFlawFromType(backend, value) {
|
|
753
|
+
return "createFlaw" in backend && typeof backend.createFlaw == "function"
|
|
754
|
+
? backend.createFlaw(value)
|
|
755
|
+
: backend.flaw(value);
|
|
756
|
+
}
|
|
757
|
+
}
|
|
758
|
+
class IslyOptional extends Type {
|
|
759
|
+
constructor(backend) {
|
|
760
|
+
super(() => backend.name + " | undefined", backend.condition);
|
|
761
|
+
this.backend = backend;
|
|
762
|
+
this.is = (value => value == undefined || this.backend.is(value));
|
|
763
|
+
}
|
|
764
|
+
createFlaw(value) {
|
|
765
|
+
return this.createFlawFromType(this.backend, value);
|
|
766
|
+
}
|
|
767
|
+
}
|
|
768
|
+
class IslyReadonly extends Type {
|
|
769
|
+
constructor(backend) {
|
|
770
|
+
super(() => `Readonly<${backend.name}>`, backend.condition);
|
|
771
|
+
this.backend = backend;
|
|
772
|
+
this.is = (value => value == undefined || this.backend.is(value));
|
|
773
|
+
}
|
|
774
|
+
createFlaw(value) {
|
|
775
|
+
return this.createFlawFromType(this.backend, value);
|
|
776
|
+
}
|
|
777
|
+
}
|
|
778
|
+
function array(itemType, ...options) {
|
|
779
|
+
return new IslyArray(itemType, options);
|
|
780
|
+
}
|
|
781
|
+
const criteriaFunctions$1 = {
|
|
782
|
+
length: {
|
|
783
|
+
is: (value, optionValue) => value.length == optionValue,
|
|
784
|
+
condition: optionValue => `length == ${optionValue}`,
|
|
785
|
+
},
|
|
786
|
+
minLength: {
|
|
787
|
+
is: (value, optionValue) => value.length >= optionValue,
|
|
788
|
+
condition: optionValue => `minLength == ${optionValue}`,
|
|
789
|
+
},
|
|
790
|
+
maxLength: {
|
|
791
|
+
is: (value, optionValue) => value.length <= optionValue,
|
|
792
|
+
condition: optionValue => `maxLength == ${optionValue}`,
|
|
793
|
+
},
|
|
794
|
+
};
|
|
795
|
+
class IslyArray extends Type {
|
|
796
|
+
constructor(itemType, options) {
|
|
797
|
+
super(() => this.baseName() + "[]", options.length > 0 ? options.map(c => criteriaFunctions$1[c.criteria].condition(c.value)).join(" & ") : undefined);
|
|
798
|
+
this.itemType = itemType;
|
|
799
|
+
this.options = options;
|
|
800
|
+
this.is = (value => globalThis.Array.isArray(value) &&
|
|
801
|
+
this.options.every(option => criteriaFunctions$1[option.criteria].is(value, option.value)) &&
|
|
802
|
+
value.every(item => this.itemType.is(item)));
|
|
803
|
+
}
|
|
804
|
+
baseName() {
|
|
805
|
+
return this.itemType.name.includes(" ") ? `(${this.itemType.name})` : this.itemType.name;
|
|
806
|
+
}
|
|
807
|
+
itemName(index) {
|
|
808
|
+
return `${this.baseName()}[${index}]`;
|
|
809
|
+
}
|
|
810
|
+
createFlaw(value) {
|
|
811
|
+
const flaws = (globalThis.Array.isArray(value) &&
|
|
812
|
+
value.flatMap((item, index) => {
|
|
813
|
+
const subFlaw = this.itemType.flaw(item);
|
|
814
|
+
return subFlaw.isFlaw ?? true ? [{ ...subFlaw, type: this.itemName(index) }] : [];
|
|
815
|
+
})) ||
|
|
816
|
+
[];
|
|
817
|
+
return {
|
|
818
|
+
...(flaws.length > 0 ? { flaws } : undefined),
|
|
819
|
+
};
|
|
820
|
+
}
|
|
821
|
+
getValue(value) {
|
|
822
|
+
return value.map(item => this.itemType.get(item));
|
|
823
|
+
}
|
|
824
|
+
}
|
|
825
|
+
|
|
826
|
+
class IslyBoolean extends Type {
|
|
827
|
+
constructor(booleanValue) {
|
|
828
|
+
super(booleanValue == undefined ? "boolean" : booleanValue ? "true" : "false");
|
|
829
|
+
this.booleanValue = booleanValue;
|
|
830
|
+
this.is = (value => typeof value == "boolean" && (this.booleanValue == undefined || value == this.booleanValue));
|
|
831
|
+
}
|
|
832
|
+
}
|
|
833
|
+
function boolean(booleanValue) {
|
|
834
|
+
return new IslyBoolean(booleanValue);
|
|
835
|
+
}
|
|
836
|
+
|
|
837
|
+
class IslyLazy extends Type {
|
|
838
|
+
constructor(factory, name) {
|
|
839
|
+
super(name ?? (() => (this.backend ??= factory()).name), () => (this.backend ??= factory()).condition);
|
|
840
|
+
this.factory = factory;
|
|
841
|
+
this.is = (value => (this.backend ??= this.factory()).is(value));
|
|
842
|
+
this.get = value => this.backend.get(value);
|
|
843
|
+
}
|
|
844
|
+
createFlaw(value) {
|
|
845
|
+
return this.createFlawFromType((this.backend ??= this.factory()), value);
|
|
846
|
+
}
|
|
847
|
+
}
|
|
848
|
+
/**
|
|
849
|
+
* Late evaluation of a type
|
|
850
|
+
* Can be used for for recursive types.
|
|
851
|
+
*
|
|
852
|
+
* @param factory
|
|
853
|
+
* @param name Provide a name, to avoid infinite loop if the type i recursive
|
|
854
|
+
* @returns
|
|
855
|
+
*/
|
|
856
|
+
function lazy(factory, name) {
|
|
857
|
+
return new IslyLazy(factory, name);
|
|
858
|
+
}
|
|
859
|
+
|
|
860
|
+
class IslyObject extends Type {
|
|
861
|
+
constructor(baseType, properties, name) {
|
|
862
|
+
super(() => name ??
|
|
863
|
+
(this.baseType ? `${this.baseType.name} & ` : "") +
|
|
864
|
+
`{${globalThis.Object.entries(this.properties)
|
|
865
|
+
.map(([property, type]) => `${property}: ${type.name}`)
|
|
866
|
+
.join(", ")}}`);
|
|
867
|
+
this.baseType = baseType;
|
|
868
|
+
this.properties = properties;
|
|
869
|
+
this.is = (value => !!(value &&
|
|
870
|
+
(this.baseType == undefined || this.baseType.is(value)) &&
|
|
871
|
+
typeof value == "object" &&
|
|
872
|
+
!globalThis.Array.isArray(value) &&
|
|
873
|
+
globalThis.Object.entries(this.properties).every(([property, type]) => type.is(value[property]))));
|
|
874
|
+
}
|
|
875
|
+
extend(properties, name) {
|
|
876
|
+
return new IslyObject(this, properties, name);
|
|
877
|
+
}
|
|
878
|
+
omit(omits, name) {
|
|
879
|
+
return new IslyObject(this.baseType?.omit(omits), globalThis.Object.fromEntries(globalThis.Object.entries(this.properties).filter(([key]) => !omits.includes(key))), name ?? `Omit<${this.name}, ${omits.map(key => `"${String(key)}"`).join(" | ")}>`);
|
|
880
|
+
}
|
|
881
|
+
pick(picks, name) {
|
|
882
|
+
return new IslyObject(this.baseType?.pick(picks), globalThis.Object.fromEntries(globalThis.Object.entries(this.properties).filter(([key]) => picks.includes(key))), name ?? `Pick<${this.name}, ${picks.map(key => `"${String(key)}"`).join(" | ")}>`);
|
|
883
|
+
}
|
|
884
|
+
createFlaw(value) {
|
|
885
|
+
return {
|
|
886
|
+
flaws: [
|
|
887
|
+
this.baseType ? this.baseType.flaw(value)?.flaws ?? [] : [],
|
|
888
|
+
globalThis.Object.entries(this.properties)
|
|
889
|
+
.map(([property, type]) => [property, type.flaw(value?.[property])])
|
|
890
|
+
.map(([property, flaw]) => (flaw?.isFlaw ?? true) && { property, ...flaw })
|
|
891
|
+
.filter(flaw => flaw),
|
|
892
|
+
]
|
|
893
|
+
.flat()
|
|
894
|
+
.filter(flaw => flaw?.isFlaw ?? true),
|
|
895
|
+
};
|
|
896
|
+
}
|
|
897
|
+
/**
|
|
898
|
+
* get-function on a object returns a object with only specified properties
|
|
899
|
+
*/
|
|
900
|
+
getValue(value) {
|
|
901
|
+
const result = this.baseType ? this.baseType.getValue(value) : {};
|
|
902
|
+
if (result)
|
|
903
|
+
for (const [key, type] of globalThis.Object.entries(this.properties))
|
|
904
|
+
if (key in value)
|
|
905
|
+
result[key] = type.get(value[key]);
|
|
906
|
+
return result;
|
|
907
|
+
}
|
|
908
|
+
}
|
|
909
|
+
function object(properties, name) {
|
|
910
|
+
return new IslyObject(undefined, properties ?? {}, name);
|
|
911
|
+
}
|
|
912
|
+
|
|
913
|
+
class IslyString extends Type {
|
|
914
|
+
constructor(stringCondition) {
|
|
915
|
+
super(typeof stringCondition == "string" ? `"${stringCondition}"` : "string", () => {
|
|
916
|
+
const conditionObject = this.getConditionObject();
|
|
917
|
+
return conditionObject instanceof RegExp
|
|
918
|
+
? `/${conditionObject.source}/${conditionObject.flags}`
|
|
919
|
+
: globalThis.Object.keys(conditionObject)
|
|
920
|
+
.map(key => `"${key}"`)
|
|
921
|
+
.join(" | ");
|
|
922
|
+
});
|
|
923
|
+
this.stringCondition = stringCondition;
|
|
924
|
+
this.is = (value => {
|
|
925
|
+
const conditionObject = this.getConditionObject();
|
|
926
|
+
return (typeof value == "string" &&
|
|
927
|
+
(conditionObject instanceof RegExp
|
|
928
|
+
? conditionObject.test(value)
|
|
929
|
+
: typeof conditionObject == "object"
|
|
930
|
+
? value in conditionObject //TODO, avoid "hasOwnProperty toString etc."
|
|
931
|
+
: conditionObject));
|
|
932
|
+
});
|
|
933
|
+
}
|
|
934
|
+
getConditionObject() {
|
|
935
|
+
return (this.conditionObject ??= Array.isArray(this.stringCondition)
|
|
936
|
+
? this.stringCondition.reduce((result, current) => {
|
|
937
|
+
result[current] = true;
|
|
938
|
+
return result;
|
|
939
|
+
}, globalThis.Object.create(null))
|
|
940
|
+
: typeof this.stringCondition == "string"
|
|
941
|
+
? { [this.stringCondition]: true }
|
|
942
|
+
: typeof this.stringCondition == "object" // Record or RegExp!
|
|
943
|
+
? this.stringCondition
|
|
944
|
+
: true);
|
|
945
|
+
}
|
|
946
|
+
}
|
|
947
|
+
function string(condition) {
|
|
948
|
+
return new IslyString(condition);
|
|
949
|
+
}
|
|
950
|
+
|
|
951
|
+
var Flaw;
|
|
952
|
+
(function (Flaw) {
|
|
953
|
+
Flaw.type = object({
|
|
954
|
+
message: string().optional(),
|
|
955
|
+
isFlaw: boolean().optional(),
|
|
956
|
+
property: string().optional(),
|
|
957
|
+
type: string(),
|
|
958
|
+
flaws: array(lazy(() => Flaw.type)).optional(),
|
|
959
|
+
condition: string().optional(),
|
|
960
|
+
}, "Flaw");
|
|
961
|
+
Flaw.is = Flaw.type.is;
|
|
962
|
+
Flaw.flaw = Flaw.type.flaw;
|
|
963
|
+
})(Flaw || (Flaw = {}));
|
|
964
|
+
|
|
965
|
+
class IslyFromIs extends Type {
|
|
966
|
+
constructor(name, isFunction) {
|
|
967
|
+
super(name);
|
|
968
|
+
this.isFunction = isFunction;
|
|
969
|
+
this.is = (value => this.isFunction(value));
|
|
970
|
+
}
|
|
971
|
+
}
|
|
972
|
+
function fromIs(name, is) {
|
|
973
|
+
return new IslyFromIs(name, is);
|
|
974
|
+
}
|
|
975
|
+
|
|
976
|
+
const criteriaFunctions = {
|
|
977
|
+
positive: {
|
|
978
|
+
is: (value) => value > 0,
|
|
979
|
+
condition: "> 0",
|
|
980
|
+
},
|
|
981
|
+
negative: {
|
|
982
|
+
is: (value) => value < 0,
|
|
983
|
+
condition: "< 0",
|
|
984
|
+
},
|
|
985
|
+
integer: {
|
|
986
|
+
is: (value) => Number.isInteger(value),
|
|
987
|
+
condition: "Number.isInteger",
|
|
988
|
+
},
|
|
989
|
+
};
|
|
990
|
+
function fromCriteria(criteria) {
|
|
991
|
+
return /* Eg: criteria == 42 */ typeof criteria == "number"
|
|
992
|
+
? [value => value == criteria, " == " + criteria.toString()]
|
|
993
|
+
: // Eg: criteria == [0,1,2]
|
|
994
|
+
((c) => Array.isArray(c) && c.every(c => typeof c == "number"))(criteria)
|
|
995
|
+
? [value => criteria.map(fromCriteria).some(c => c[0](value)), criteria.join(" | ")]
|
|
996
|
+
: // Eg: criteria == ["positive", "negative"]
|
|
997
|
+
((c) => Array.isArray(c) && c.every(c => typeof c == "string" && c in criteriaFunctions))(criteria)
|
|
998
|
+
? [
|
|
999
|
+
value => criteria.map(fromCriteria).every(c => c[0](value)),
|
|
1000
|
+
criteria
|
|
1001
|
+
.map(fromCriteria)
|
|
1002
|
+
.map(c => c[1])
|
|
1003
|
+
.join(" & "),
|
|
1004
|
+
]
|
|
1005
|
+
: // Eg: criteria == () => true
|
|
1006
|
+
typeof criteria === "function"
|
|
1007
|
+
? [criteria, "custom"]
|
|
1008
|
+
: // Eg: criteria == "positive"
|
|
1009
|
+
criteria in criteriaFunctions
|
|
1010
|
+
? [criteriaFunctions[criteria].is, criteriaFunctions[criteria].condition]
|
|
1011
|
+
: // Eg: criteria is unknown
|
|
1012
|
+
[() => false, "Unknown criteria"];
|
|
1013
|
+
}
|
|
1014
|
+
class IslyNumber extends Type {
|
|
1015
|
+
constructor(isFunction, condition) {
|
|
1016
|
+
super("number", condition);
|
|
1017
|
+
this.isFunction = isFunction;
|
|
1018
|
+
this.is = (value => typeof value == "number" &&
|
|
1019
|
+
!Number.isNaN(value - value) && // NaN-NaN==NaN && Infinity-Infinity==NaN && (-Infinity)-(-Infinity)==NaN
|
|
1020
|
+
(!this.isFunction || this.isFunction(value)));
|
|
1021
|
+
}
|
|
1022
|
+
}
|
|
1023
|
+
/**
|
|
1024
|
+
* NaN, Infinite and -Infinite is not considered to be numbers by this type,
|
|
1025
|
+
* since that it is hardly ever desirable when validating input data.
|
|
1026
|
+
*
|
|
1027
|
+
* @param criteria
|
|
1028
|
+
* @returns
|
|
1029
|
+
*/
|
|
1030
|
+
function number(criteria) {
|
|
1031
|
+
const [isFunction, condition] = criteria == undefined ? [undefined, undefined] : fromCriteria(criteria);
|
|
1032
|
+
return new IslyNumber(isFunction, condition);
|
|
1033
|
+
}
|
|
1034
|
+
|
|
1035
|
+
class IslyRecord extends Type {
|
|
1036
|
+
constructor(keyType, valueType) {
|
|
1037
|
+
super(() => `Record<${keyType.name}, ${valueType.name}>`);
|
|
1038
|
+
this.keyType = keyType;
|
|
1039
|
+
this.valueType = valueType;
|
|
1040
|
+
this.is = (value => !!(value &&
|
|
1041
|
+
typeof value == "object" &&
|
|
1042
|
+
!globalThis.Array.isArray(value) &&
|
|
1043
|
+
globalThis.Object.entries(value).every(([key, value]) => this.keyType.is(this.keyType.name == "number" && `${+key}` == key ? +key : key) && this.valueType.is(value))));
|
|
1044
|
+
}
|
|
1045
|
+
createFlaw(value) {
|
|
1046
|
+
return {
|
|
1047
|
+
flaws: value &&
|
|
1048
|
+
typeof value == "object" &&
|
|
1049
|
+
!globalThis.Array.isArray(value) &&
|
|
1050
|
+
globalThis.Object.entries(value).flatMap(([key, propertyValue]) => [
|
|
1051
|
+
this.keyType.flaw(this.keyType.name == "number" && `${+key}` == key ? +key : key),
|
|
1052
|
+
this.valueType.flaw(propertyValue),
|
|
1053
|
+
]
|
|
1054
|
+
.map((flaw, index) => (flaw.isFlaw ?? true) && { property: key + ` (${["key", "value"][index]})`, ...flaw })
|
|
1055
|
+
.filter(Boolean)),
|
|
1056
|
+
};
|
|
1057
|
+
}
|
|
1058
|
+
getValue(value) {
|
|
1059
|
+
return globalThis.Object.fromEntries(globalThis.Object.entries(value).map(([key, value]) => [key, this.valueType.get(value)]));
|
|
1060
|
+
}
|
|
1061
|
+
}
|
|
1062
|
+
function record(keyType, valueType) {
|
|
1063
|
+
return new IslyRecord(keyType, valueType);
|
|
1064
|
+
}
|
|
1065
|
+
|
|
1066
|
+
class IslyUnion extends Type {
|
|
1067
|
+
constructor(...types) {
|
|
1068
|
+
super(() => types.map(type => type.name).join(" | "));
|
|
1069
|
+
this.is = (value => this.types.some(type => type.is(value)));
|
|
1070
|
+
this.types = types;
|
|
1071
|
+
}
|
|
1072
|
+
createFlaw(value) {
|
|
1073
|
+
return {
|
|
1074
|
+
flaws: this.types.map(type => type.flaw(value)).filter(flaw => flaw),
|
|
1075
|
+
};
|
|
1076
|
+
}
|
|
1077
|
+
getValue(value) {
|
|
1078
|
+
return this.types.find(type => type.is(value))?.get(value);
|
|
1079
|
+
}
|
|
1080
|
+
}
|
|
1081
|
+
function union(...types) {
|
|
1082
|
+
return new IslyUnion(...types);
|
|
1083
|
+
}
|
|
1084
|
+
|
|
1085
|
+
class IslyUndefined extends Type {
|
|
1086
|
+
constructor() {
|
|
1087
|
+
super(...arguments);
|
|
1088
|
+
this.is = (value => value === undefined);
|
|
1089
|
+
}
|
|
1090
|
+
}
|
|
1091
|
+
function islyUndefined(name) {
|
|
1092
|
+
return new IslyUndefined(name ?? "undefined");
|
|
1093
|
+
}
|
|
1094
|
+
|
|
1095
|
+
exports.Color = void 0;
|
|
1096
|
+
(function (Color) {
|
|
1097
|
+
Color.types = [
|
|
1098
|
+
"default",
|
|
1099
|
+
"primary",
|
|
1100
|
+
"secondary",
|
|
1101
|
+
"tertiary",
|
|
1102
|
+
"success",
|
|
1103
|
+
"warning",
|
|
1104
|
+
"danger",
|
|
1105
|
+
"light",
|
|
1106
|
+
"medium",
|
|
1107
|
+
"dark",
|
|
1108
|
+
];
|
|
1109
|
+
Color.type = string(Color.types);
|
|
1110
|
+
Color.is = Color.type.is;
|
|
1111
|
+
})(exports.Color || (exports.Color = {}));
|
|
1112
|
+
|
|
1113
|
+
exports.Icon = void 0;
|
|
1114
|
+
(function (Icon) {
|
|
1115
|
+
const names = {
|
|
1116
|
+
"*": "https://ionicons.pages.dev/svg/${name}.svg",
|
|
1117
|
+
};
|
|
1118
|
+
const cache = {};
|
|
1119
|
+
async function fetch(url) {
|
|
1120
|
+
const response = await globalThis.fetch(url);
|
|
1121
|
+
return response.ok ? response.text() : undefined;
|
|
1122
|
+
}
|
|
1123
|
+
async function load(name) {
|
|
1124
|
+
var _a, _b;
|
|
1125
|
+
const url = ((_a = names[name]) !== null && _a !== void 0 ? _a : names["*"]).replace("${name}", name);
|
|
1126
|
+
return (_b = cache[url]) !== null && _b !== void 0 ? _b : (cache[url] = fetch(url));
|
|
1127
|
+
}
|
|
1128
|
+
Icon.load = load;
|
|
1129
|
+
function add(url, ...name) {
|
|
1130
|
+
for (const n of name)
|
|
1131
|
+
names[n] = url;
|
|
1132
|
+
}
|
|
1133
|
+
Icon.add = add;
|
|
1134
|
+
})(exports.Icon || (exports.Icon = {}));
|
|
1135
|
+
|
|
659
1136
|
class Message {
|
|
660
1137
|
static is(value) {
|
|
661
1138
|
return typeof value == "object" && typeof value.destination == "string" && value.content != undefined;
|
|
@@ -709,18 +1186,31 @@ class Listenable {
|
|
|
709
1186
|
constructor() {
|
|
710
1187
|
_Listenable_listeners.set(this, {});
|
|
711
1188
|
}
|
|
712
|
-
listen(property, listener) {
|
|
1189
|
+
listen(property, listener, options) {
|
|
713
1190
|
var _a, _b;
|
|
714
1191
|
(_b = (_a = __classPrivateFieldGet(this, _Listenable_listeners, "f")[property]) === null || _a === void 0 ? void 0 : _a.push(listener)) !== null && _b !== void 0 ? _b : (__classPrivateFieldGet(this, _Listenable_listeners, "f")[property] = [listener]);
|
|
715
|
-
|
|
1192
|
+
if (!(options === null || options === void 0 ? void 0 : options.lazy))
|
|
1193
|
+
listener(this[property]);
|
|
716
1194
|
}
|
|
717
1195
|
unlisten(property, listener) {
|
|
718
1196
|
var _a, _b;
|
|
719
1197
|
const index = (_a = __classPrivateFieldGet(this, _Listenable_listeners, "f")[property]) === null || _a === void 0 ? void 0 : _a.indexOf(listener);
|
|
720
1198
|
index != undefined && index >= 0 && ((_b = __classPrivateFieldGet(this, _Listenable_listeners, "f")[property]) === null || _b === void 0 ? void 0 : _b.splice(index, 1));
|
|
721
1199
|
}
|
|
722
|
-
|
|
723
|
-
const
|
|
1200
|
+
batchListen(listeners, options) {
|
|
1201
|
+
for (const key in listeners) {
|
|
1202
|
+
const listener = listeners[key];
|
|
1203
|
+
listener && this.listen(key, listener, options);
|
|
1204
|
+
}
|
|
1205
|
+
}
|
|
1206
|
+
batchUnlisten(listeners) {
|
|
1207
|
+
for (const key in listeners) {
|
|
1208
|
+
const listener = listeners[key];
|
|
1209
|
+
listener && this.unlisten(key, listener);
|
|
1210
|
+
}
|
|
1211
|
+
}
|
|
1212
|
+
static load(backend) {
|
|
1213
|
+
const result = backend.listenable;
|
|
724
1214
|
return Object.defineProperties(result, getProperties(backend));
|
|
725
1215
|
function getProperties(backend) {
|
|
726
1216
|
return Object.fromEntries(Object.entries(Object.assign(Object.assign({}, Object.getOwnPropertyDescriptors(backend)), Object.getOwnPropertyDescriptors(Object.getPrototypeOf(backend)))).map(([name, descriptor]) => [
|
|
@@ -739,12 +1229,12 @@ class Listenable {
|
|
|
739
1229
|
set(value) {
|
|
740
1230
|
var _a;
|
|
741
1231
|
backend[name] = value;
|
|
742
|
-
(_a = __classPrivateFieldGet(result, _Listenable_listeners, "f")[name]) === null || _a === void 0 ? void 0 : _a.forEach(listener => listener(
|
|
1232
|
+
(_a = __classPrivateFieldGet(result, _Listenable_listeners, "f")[name]) === null || _a === void 0 ? void 0 : _a.forEach(listener => listener(backend[name]));
|
|
743
1233
|
},
|
|
744
1234
|
}
|
|
745
1235
|
: {
|
|
746
1236
|
get() {
|
|
747
|
-
return backend[name]
|
|
1237
|
+
return backend[name];
|
|
748
1238
|
},
|
|
749
1239
|
},
|
|
750
1240
|
]));
|
|
@@ -753,6 +1243,35 @@ class Listenable {
|
|
|
753
1243
|
}
|
|
754
1244
|
_Listenable_listeners = new WeakMap();
|
|
755
1245
|
|
|
1246
|
+
exports.Data = void 0;
|
|
1247
|
+
(function (Data) {
|
|
1248
|
+
Data.valueType = union(string(), number(), boolean(), fromIs("Blob", value => value instanceof Blob), islyUndefined());
|
|
1249
|
+
Data.type = record(string(), union(lazy(() => Data.type, "Data"), Data.valueType));
|
|
1250
|
+
function set(data, [head, ...tail], value) {
|
|
1251
|
+
const current = data[head !== null && head !== void 0 ? head : ""];
|
|
1252
|
+
return Object.assign(Object.assign({}, data), { [head !== null && head !== void 0 ? head : ""]: !tail.length
|
|
1253
|
+
? value
|
|
1254
|
+
: set(typeof current == "object" && !(current instanceof Blob) ? current : {}, tail, value) });
|
|
1255
|
+
}
|
|
1256
|
+
Data.set = set;
|
|
1257
|
+
function deepen(data) {
|
|
1258
|
+
return merge({}, data);
|
|
1259
|
+
}
|
|
1260
|
+
Data.deepen = deepen;
|
|
1261
|
+
function merge(data, changes) {
|
|
1262
|
+
return Object.entries(changes).reduce((r, [name, value]) => set(r, name.split("."), value), data);
|
|
1263
|
+
}
|
|
1264
|
+
Data.merge = merge;
|
|
1265
|
+
})(exports.Data || (exports.Data = {}));
|
|
1266
|
+
|
|
756
1267
|
exports.Listenable = Listenable;
|
|
757
1268
|
exports.Message = Message;
|
|
758
1269
|
exports.Trigger = Trigger;
|
|
1270
|
+
exports.Type = Type;
|
|
1271
|
+
exports.boolean = boolean;
|
|
1272
|
+
exports.object = object;
|
|
1273
|
+
exports.record = record;
|
|
1274
|
+
exports.string = string;
|
|
1275
|
+
exports.union = union;
|
|
1276
|
+
|
|
1277
|
+
//# sourceMappingURL=Data-ae713814.js.map
|