@sme.up/ketchup 4.0.0 → 4.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -3
- package/dist/cjs/cell-utils-dc0884a3.js +168 -0
- package/dist/cjs/f-button-2ba74fb5.js +105 -0
- package/dist/cjs/f-cell-fe60a08d.js +731 -0
- package/dist/cjs/f-chip-90d95d22.js +141 -0
- package/dist/cjs/{f-image-5f4f29ca.js → f-image-d3bd4e08.js} +4 -5
- package/dist/cjs/{index-3c471303.js → index-0416afab.js} +73 -64
- package/dist/cjs/ketchup.cjs.js +3 -3
- package/dist/cjs/kup-accordion.cjs.entry.js +6 -8
- package/dist/cjs/{kup-autocomplete_29.cjs.entry.js → kup-autocomplete_28.cjs.entry.js} +2580 -3060
- package/dist/cjs/kup-calendar.cjs.entry.js +30 -30
- package/dist/cjs/kup-cell.cjs.entry.js +201 -0
- package/dist/cjs/kup-dash-list.cjs.entry.js +15 -7
- package/dist/cjs/kup-dash_2.cjs.entry.js +104 -62
- package/dist/cjs/kup-drawer.cjs.entry.js +4 -6
- package/dist/cjs/kup-field.cjs.entry.js +3 -5
- package/dist/cjs/kup-iframe.cjs.entry.js +3 -4
- package/dist/cjs/kup-lazy.cjs.entry.js +4 -6
- package/dist/cjs/kup-magic-box.cjs.entry.js +21 -31
- package/dist/cjs/kup-manager-1a2688ca.js +5813 -0
- package/dist/cjs/kup-nav-bar.cjs.entry.js +4 -6
- package/dist/cjs/kup-probe.cjs.entry.js +3 -4
- package/dist/cjs/kup-qlik.cjs.entry.js +2 -3
- package/dist/cjs/kup-snackbar.cjs.entry.js +152 -0
- package/dist/cjs/loader.cjs.js +3 -3
- package/dist/cjs/{utils-2af73538.js → utils-0cc466b9.js} +17 -83
- package/dist/collection/assets/cell.js +51 -0
- package/dist/collection/assets/data-table.js +518 -1
- package/dist/collection/assets/index.js +8 -0
- package/dist/collection/assets/snackbar.js +32 -0
- package/dist/collection/collection-manifest.json +6 -6
- package/dist/collection/components/kup-accordion/kup-accordion.css +0 -213
- package/dist/collection/components/kup-accordion/kup-accordion.js +15 -16
- package/dist/collection/components/kup-autocomplete/kup-autocomplete-declarations.js +2 -2
- package/dist/collection/components/kup-autocomplete/kup-autocomplete.css +5 -2381
- package/dist/collection/components/kup-autocomplete/kup-autocomplete.js +83 -111
- package/dist/collection/components/kup-badge/kup-badge.css +1 -35
- package/dist/collection/components/kup-badge/kup-badge.js +13 -14
- package/dist/collection/components/kup-box/kup-box.css +47 -780
- package/dist/collection/components/kup-box/kup-box.js +240 -366
- package/dist/collection/components/kup-button/kup-button.css +0 -333
- package/dist/collection/components/kup-button/kup-button.js +27 -28
- package/dist/collection/components/kup-button-list/kup-button-list.css +0 -332
- package/dist/collection/components/kup-button-list/kup-button-list.js +19 -20
- package/dist/collection/components/kup-calendar/kup-calendar.css +0 -517
- package/dist/collection/components/kup-calendar/kup-calendar.js +47 -45
- package/dist/collection/components/kup-card/builtin/kup-card-builtin.js +20 -0
- package/dist/collection/components/kup-card/builtin/kup-card-calendar.js +458 -0
- package/dist/collection/components/kup-card/builtin/kup-card-clock.js +321 -0
- package/dist/collection/components/kup-card/dialog/kup-card-dialog.js +18 -0
- package/dist/collection/components/kup-card/free/kup-card-free.js +13 -0
- package/dist/collection/components/kup-card/kup-card-declarations.js +19 -0
- package/dist/collection/components/kup-card/kup-card-helper.js +19 -1
- package/dist/collection/components/kup-card/kup-card.css +615 -185
- package/dist/collection/components/kup-card/kup-card.js +94 -34
- package/dist/collection/components/kup-card/standard/kup-card-standard.js +75 -0
- package/dist/collection/components/kup-cell/kup-cell-declarations.js +11 -0
- package/dist/collection/components/kup-cell/kup-cell.css +20 -0
- package/dist/collection/components/kup-cell/kup-cell.js +413 -0
- package/dist/collection/components/kup-chart/kup-chart.js +41 -42
- package/dist/collection/components/kup-checkbox/kup-checkbox.css +0 -214
- package/dist/collection/components/kup-checkbox/kup-checkbox.js +19 -20
- package/dist/collection/components/kup-chip/kup-chip.css +0 -217
- package/dist/collection/components/kup-chip/kup-chip.js +15 -16
- package/dist/collection/components/kup-color-picker/kup-color-picker.css +7 -2380
- package/dist/collection/components/kup-color-picker/kup-color-picker.js +41 -41
- package/dist/collection/components/kup-combobox/kup-combobox-declarations.js +1 -0
- package/dist/collection/components/kup-combobox/kup-combobox.css +5 -2381
- package/dist/collection/components/kup-combobox/kup-combobox.js +68 -28
- package/dist/collection/components/kup-dash-list/kup-dash-list.js +13 -4
- package/dist/collection/components/kup-data-table/kup-data-table-declarations.js +2 -0
- package/dist/collection/components/kup-data-table/kup-data-table-helper.js +61 -102
- package/dist/collection/components/kup-data-table/kup-data-table.css +118 -3232
- package/dist/collection/components/kup-data-table/kup-data-table.js +589 -1089
- package/dist/collection/components/kup-date-picker/kup-date-picker.css +1 -85
- package/dist/collection/components/kup-date-picker/kup-date-picker.js +92 -395
- package/dist/collection/components/kup-drawer/kup-drawer.js +9 -10
- package/dist/collection/components/kup-dropdown-button/kup-dropdown-button.css +12 -340
- package/dist/collection/components/kup-dropdown-button/kup-dropdown-button.js +56 -45
- package/dist/collection/components/kup-field/kup-field.js +21 -22
- package/dist/collection/components/kup-gauge/kup-gauge.js +17 -18
- package/dist/collection/components/kup-grid/kup-grid.css +2 -1
- package/dist/collection/components/kup-grid/kup-grid.js +13 -14
- package/dist/collection/components/kup-iframe/kup-iframe.js +4 -4
- package/dist/collection/components/kup-image/assets/svg/ketchup.svg +74 -0
- package/dist/collection/components/kup-image/assets/svg/smeup.svg +59 -0
- package/dist/collection/components/kup-image/kup-image.css +0 -32
- package/dist/collection/components/kup-image/kup-image.js +25 -26
- package/dist/collection/components/kup-lazy/kup-lazy.js +17 -18
- package/dist/collection/components/kup-list/kup-list-declarations.js +1 -1
- package/dist/collection/components/kup-list/kup-list.css +4 -260
- package/dist/collection/components/kup-list/kup-list.js +39 -49
- package/dist/collection/components/kup-magic-box/kup-magic-box.css +13 -39
- package/dist/collection/components/kup-magic-box/kup-magic-box.js +29 -38
- package/dist/collection/components/kup-nav-bar/kup-nav-bar.js +11 -12
- package/dist/collection/components/kup-paginator/kup-paginator.css +0 -332
- package/dist/collection/components/kup-paginator/kup-paginator.js +44 -12
- package/dist/collection/components/kup-probe/kup-probe.js +9 -9
- package/dist/collection/components/kup-progress-bar/kup-progress-bar.js +21 -22
- package/dist/collection/components/kup-radio/kup-radio.js +17 -18
- package/dist/collection/components/kup-rating/kup-rating.js +15 -16
- package/dist/collection/components/kup-snackbar/kup-snackbar-declarations.js +13 -0
- package/dist/collection/components/kup-snackbar/kup-snackbar.css +75 -0
- package/dist/collection/components/kup-snackbar/kup-snackbar.js +390 -0
- package/dist/collection/components/kup-spinner/kup-spinner.js +23 -24
- package/dist/collection/components/kup-switch/kup-switch.css +0 -156
- package/dist/collection/components/kup-switch/kup-switch.js +17 -18
- package/dist/collection/components/kup-tab-bar/kup-tab-bar.css +0 -199
- package/dist/collection/components/kup-tab-bar/kup-tab-bar.js +13 -14
- package/dist/collection/components/kup-text-field/kup-text-field-declarations.js +1 -0
- package/dist/collection/components/kup-text-field/kup-text-field.css +4 -2371
- package/dist/collection/components/kup-text-field/kup-text-field.js +77 -51
- package/dist/collection/components/kup-time-picker/kup-time-picker.css +7 -0
- package/dist/collection/components/kup-time-picker/kup-time-picker.js +97 -317
- package/dist/collection/components/kup-tooltip/kup-tooltip.js +24 -14
- package/dist/collection/components/kup-tree/kup-tree.css +27 -371
- package/dist/collection/components/kup-tree/kup-tree.js +163 -383
- package/dist/collection/f-components/f-button/f-button.js +4 -2
- package/dist/collection/f-components/f-cell/f-cell-declarations.js +143 -0
- package/dist/collection/f-components/f-cell/f-cell.js +471 -0
- package/dist/collection/f-components/f-checkbox/f-checkbox.js +1 -1
- package/dist/collection/f-components/f-chip/f-chip.js +2 -2
- package/dist/collection/f-components/f-image/f-image.js +2 -3
- package/dist/collection/f-components/f-switch/f-switch.js +1 -1
- package/dist/collection/f-components/f-text-field/f-text-field-mdc.js +1 -1
- package/dist/collection/f-components/f-text-field/f-text-field.js +25 -21
- package/dist/collection/utils/cell-utils.js +18 -222
- package/dist/collection/utils/filters/filters.js +31 -37
- package/dist/collection/utils/kup-column-menu/kup-column-menu.js +15 -3
- package/dist/collection/utils/kup-dates/kup-dates.js +14 -2
- package/dist/collection/utils/kup-debug/kup-debug-browser-utils.js +3 -3
- package/dist/collection/utils/kup-debug/kup-debug.js +57 -29
- package/dist/collection/utils/kup-dynamic-position/kup-dynamic-position.js +5 -7
- package/dist/collection/utils/kup-interact/kup-interact-declarations.js +48 -0
- package/dist/collection/utils/kup-interact/kup-interact.js +379 -0
- package/dist/collection/utils/kup-language/kup-language-declarations.js +2 -0
- package/dist/collection/utils/kup-language/kup-language.js +1 -1
- package/dist/collection/utils/kup-manager/kup-manager.js +47 -10
- package/dist/collection/utils/kup-objects/kup-objects.js +9 -33
- package/dist/collection/utils/kup-scroll-on-hover/kup-scroll-on-hover.js +60 -62
- package/dist/collection/utils/kup-search/kup-search-declarations.js +1 -0
- package/dist/collection/utils/kup-search/kup-search.js +75 -0
- package/dist/collection/utils/kup-theme/kup-theme-declarations.js +1 -0
- package/dist/collection/utils/kup-theme/kup-theme.js +4 -3
- package/dist/collection/utils/kup-toolbar/kup-toolbar.js +16 -18
- package/dist/collection/utils/utils.js +15 -23
- package/dist/esm/cell-utils-8f512ea9.js +160 -0
- package/dist/esm/f-button-30dbcaa9.js +103 -0
- package/dist/esm/f-cell-95c186c6.js +727 -0
- package/dist/esm/f-chip-c0e9c0ff.js +139 -0
- package/dist/esm/{f-image-68b34fab.js → f-image-3bc8b24f.js} +4 -5
- package/dist/esm/{index-bf2824a6.js → index-e0e67c23.js} +74 -65
- package/dist/esm/ketchup.js +3 -3
- package/dist/esm/kup-accordion.entry.js +6 -8
- package/dist/esm/{kup-autocomplete_29.entry.js → kup-autocomplete_28.entry.js} +2379 -2858
- package/dist/esm/kup-calendar.entry.js +10 -10
- package/dist/esm/kup-cell.entry.js +197 -0
- package/dist/esm/kup-dash-list.entry.js +15 -7
- package/dist/esm/kup-dash_2.entry.js +104 -62
- package/dist/esm/kup-drawer.entry.js +4 -6
- package/dist/esm/kup-field.entry.js +3 -5
- package/dist/esm/kup-iframe.entry.js +3 -4
- package/dist/esm/kup-lazy.entry.js +4 -6
- package/dist/esm/kup-magic-box.entry.js +21 -31
- package/dist/esm/kup-manager-7fc234da.js +5800 -0
- package/dist/esm/kup-nav-bar.entry.js +4 -6
- package/dist/esm/kup-probe.entry.js +3 -4
- package/dist/esm/kup-qlik.entry.js +2 -3
- package/dist/esm/kup-snackbar.entry.js +148 -0
- package/dist/esm/loader.js +3 -3
- package/dist/esm/{utils-13dd007a.js → utils-6c73709d.js} +15 -78
- package/dist/ketchup/assets/svg/ketchup.svg +74 -0
- package/dist/ketchup/assets/svg/smeup.svg +59 -0
- package/dist/ketchup/ketchup.esm.js +1 -1
- package/dist/ketchup/p-15321eae.js +1 -0
- package/dist/ketchup/p-1baf1205.entry.js +1 -0
- package/dist/ketchup/p-1c6178e4.entry.js +1 -0
- package/dist/ketchup/p-44375e49.js +1 -0
- package/dist/ketchup/p-4dcdbd31.entry.js +45 -0
- package/dist/ketchup/p-5a5f2a53.js +1 -0
- package/dist/ketchup/{p-c7ee1fbc.js → p-61faaa38.js} +2 -2
- package/dist/ketchup/p-62816d0b.entry.js +1 -0
- package/dist/ketchup/p-65adc15b.entry.js +1 -0
- package/dist/ketchup/p-7e23ea7c.entry.js +1 -0
- package/dist/ketchup/p-a378ba56.entry.js +1 -0
- package/dist/ketchup/p-a878016f.entry.js +1 -0
- package/dist/ketchup/p-a96e6e32.entry.js +1 -0
- package/dist/ketchup/p-ad32821e.entry.js +1 -0
- package/dist/ketchup/p-af4a6191.entry.js +1 -0
- package/dist/ketchup/p-c18c7bb0.entry.js +27 -0
- package/dist/ketchup/p-ca0ca27f.entry.js +1 -0
- package/dist/ketchup/p-cb5f4994.js +1 -0
- package/dist/ketchup/p-ccda584a.entry.js +1 -0
- package/dist/ketchup/p-d4aa4922.js +1 -0
- package/dist/ketchup/p-dbb6998b.entry.js +1 -0
- package/dist/ketchup/p-de83f2f6.js +1 -0
- package/dist/ketchup/p-ec3a3db9.js +1 -0
- package/dist/types/components/kup-autocomplete/kup-autocomplete-declarations.d.ts +2 -6
- package/dist/types/components/kup-autocomplete/kup-autocomplete.d.ts +7 -13
- package/dist/types/components/kup-box/kup-box-declarations.d.ts +13 -4
- package/dist/types/components/kup-box/kup-box.d.ts +13 -6
- package/dist/types/components/kup-card/builtin/kup-card-builtin.d.ts +14 -0
- package/dist/types/components/kup-card/builtin/kup-card-calendar.d.ts +2 -0
- package/dist/types/components/kup-card/builtin/kup-card-clock.d.ts +2 -0
- package/dist/types/components/kup-card/dialog/kup-card-dialog.d.ts +6 -0
- package/dist/types/components/kup-card/free/kup-card-free.d.ts +8 -0
- package/dist/types/components/kup-card/kup-card-declarations.d.ts +74 -0
- package/dist/types/components/kup-card/kup-card.d.ts +12 -3
- package/dist/types/components/kup-card/standard/kup-card-standard.d.ts +6 -0
- package/dist/types/components/kup-cell/kup-cell-declarations.d.ts +10 -0
- package/dist/types/components/kup-cell/kup-cell.d.ts +67 -0
- package/dist/types/components/kup-color-picker/kup-color-picker.d.ts +1 -1
- package/dist/types/components/kup-combobox/kup-combobox-declarations.d.ts +3 -2
- package/dist/types/components/kup-combobox/kup-combobox.d.ts +5 -0
- package/dist/types/components/kup-dash-list/kup-dash-list.d.ts +4 -0
- package/dist/types/components/kup-data-table/kup-data-table-declarations.d.ts +20 -36
- package/dist/types/components/kup-data-table/kup-data-table-helper.d.ts +1 -15
- package/dist/types/components/kup-data-table/kup-data-table.d.ts +33 -83
- package/dist/types/components/kup-date-picker/kup-date-picker.d.ts +11 -23
- package/dist/types/components/kup-dropdown-button/kup-dropdown-button.d.ts +1 -4
- package/dist/types/components/kup-list/kup-list-declarations.d.ts +1 -1
- package/dist/types/components/kup-list/kup-list.d.ts +2 -3
- package/dist/types/components/kup-magic-box/kup-magic-box.d.ts +1 -0
- package/dist/types/components/kup-paginator/kup-paginator.d.ts +6 -0
- package/dist/types/components/kup-snackbar/kup-snackbar-declarations.d.ts +12 -0
- package/dist/types/components/kup-snackbar/kup-snackbar.d.ts +79 -0
- package/dist/types/components/kup-text-field/kup-text-field-declarations.d.ts +2 -1
- package/dist/types/components/kup-text-field/kup-text-field.d.ts +5 -0
- package/dist/types/components/kup-time-picker/kup-time-picker.d.ts +10 -20
- package/dist/types/components/kup-tooltip/kup-tooltip.d.ts +1 -0
- package/dist/types/components/kup-tree/kup-tree-declarations.d.ts +4 -4
- package/dist/types/components/kup-tree/kup-tree.d.ts +12 -23
- package/dist/types/components.d.ts +348 -176
- package/dist/types/f-components/f-cell/f-cell-declarations.d.ts +153 -0
- package/dist/types/f-components/f-cell/f-cell.d.ts +3 -0
- package/dist/types/f-components/f-text-field/f-text-field-declarations.d.ts +1 -0
- package/dist/types/f-components/f-text-field/f-text-field-mdc.d.ts +1 -1
- package/dist/types/utils/cell-utils.d.ts +0 -19
- package/dist/types/utils/kup-column-menu/kup-column-menu.d.ts +2 -0
- package/dist/types/utils/kup-dates/kup-dates.d.ts +9 -4
- package/dist/types/utils/kup-debug/kup-debug.d.ts +1 -1
- package/dist/types/utils/kup-dynamic-position/kup-dynamic-position-declarations.d.ts +1 -1
- package/dist/types/utils/kup-dynamic-position/kup-dynamic-position.d.ts +2 -2
- package/dist/types/utils/kup-interact/kup-interact-declarations.d.ts +127 -0
- package/dist/types/utils/kup-interact/kup-interact.d.ts +93 -0
- package/dist/types/utils/kup-language/kup-language-declarations.d.ts +2 -0
- package/dist/types/utils/kup-language/kup-language.d.ts +1 -1
- package/dist/types/utils/kup-manager/kup-manager-declarations.d.ts +28 -8
- package/dist/types/utils/kup-manager/kup-manager.d.ts +18 -5
- package/dist/types/utils/kup-objects/kup-objects.d.ts +1 -7
- package/dist/types/utils/kup-search/kup-search-declarations.d.ts +7 -0
- package/dist/types/utils/kup-search/kup-search.d.ts +20 -0
- package/dist/types/utils/kup-theme/kup-theme-declarations.d.ts +2 -0
- package/dist/types/utils/kup-theme/kup-theme.d.ts +2 -2
- package/dist/types/utils/utils.d.ts +0 -1
- package/package.json +4 -6
- package/dist/cjs/cell-utils-1f89a299.js +0 -1527
- package/dist/cjs/drag-and-drop-4787ff6f.js +0 -281
- package/dist/cjs/f-chip-2d58c8f7.js +0 -239
- package/dist/cjs/kup-grid.cjs.entry.js +0 -130
- package/dist/cjs/kup-manager-59ad8bdc.js +0 -4845
- package/dist/cjs/kup-objects-59ea949c.js +0 -717
- package/dist/collection/assets/images/drag-multiple.js +0 -1
- package/dist/collection/components/kup-editor/kup-editor.css +0 -5
- package/dist/collection/components/kup-editor/kup-editor.js +0 -59
- package/dist/collection/components/kup-layout/kup-layout.css +0 -53
- package/dist/collection/components/kup-layout/kup-layout.js +0 -156
- package/dist/collection/utils/drag-and-drop.js +0 -109
- package/dist/collection/utils/kup-dialog/kup-dialog-declarations.js +0 -36
- package/dist/collection/utils/kup-dialog/kup-dialog.js +0 -310
- package/dist/esm/cell-utils-cb612463.js +0 -1510
- package/dist/esm/drag-and-drop-321cb4ca.js +0 -265
- package/dist/esm/f-chip-125d5dd6.js +0 -236
- package/dist/esm/kup-grid.entry.js +0 -126
- package/dist/esm/kup-manager-e7d7b353.js +0 -4842
- package/dist/esm/kup-objects-d38d2fa2.js +0 -711
- package/dist/ketchup/p-00fe1e3e.js +0 -1
- package/dist/ketchup/p-0320e24e.entry.js +0 -1
- package/dist/ketchup/p-08c7a092.js +0 -1
- package/dist/ketchup/p-1165f4ea.entry.js +0 -1
- package/dist/ketchup/p-170d3cba.js +0 -1
- package/dist/ketchup/p-18cb3ba3.js +0 -1
- package/dist/ketchup/p-23541a97.entry.js +0 -45
- package/dist/ketchup/p-64ea7e37.entry.js +0 -1
- package/dist/ketchup/p-7896031c.entry.js +0 -1
- package/dist/ketchup/p-876da4c2.entry.js +0 -1
- package/dist/ketchup/p-8fb9d9b2.entry.js +0 -1
- package/dist/ketchup/p-940ab57a.entry.js +0 -1
- package/dist/ketchup/p-9c858a38.entry.js +0 -1
- package/dist/ketchup/p-a12a5690.entry.js +0 -1
- package/dist/ketchup/p-a5424073.js +0 -1
- package/dist/ketchup/p-b0724035.entry.js +0 -1
- package/dist/ketchup/p-b14e77f0.js +0 -1
- package/dist/ketchup/p-d24cfdea.entry.js +0 -1
- package/dist/ketchup/p-ee89966f.entry.js +0 -27
- package/dist/ketchup/p-fcd2fd8f.js +0 -1
- package/dist/ketchup/p-fce3b9d8.entry.js +0 -1
- package/dist/types/assets/images/drag-multiple.d.ts +0 -1
- package/dist/types/components/kup-editor/kup-editor.d.ts +0 -16
- package/dist/types/components/kup-layout/kup-layout.d.ts +0 -25
- package/dist/types/utils/drag-and-drop.d.ts +0 -53
- package/dist/types/utils/kup-dialog/kup-dialog-declarations.d.ts +0 -43
- package/dist/types/utils/kup-dialog/kup-dialog.d.ts +0 -50
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
import numeral from 'numeral';
|
|
2
|
-
import { KupDates } from './kup-dates/kup-dates';
|
|
3
2
|
import { KupDatesFormats, KupDatesNormalize, } from './kup-dates/kup-dates-declarations';
|
|
4
3
|
const dom = document.documentElement;
|
|
5
|
-
const kupDates = dom.ketchup ? dom.ketchup.dates : new KupDates();
|
|
6
4
|
export var DateTimeFormatOptionsMonth;
|
|
7
5
|
(function (DateTimeFormatOptionsMonth) {
|
|
8
6
|
DateTimeFormatOptionsMonth["NUMERIC"] = "numeric";
|
|
@@ -38,12 +36,6 @@ export function eventFromElement(element, eventSource) {
|
|
|
38
36
|
}
|
|
39
37
|
return false;
|
|
40
38
|
}
|
|
41
|
-
export function getCurrentLocale() {
|
|
42
|
-
if (navigator == null || navigator.language == null) {
|
|
43
|
-
return 'en-US';
|
|
44
|
-
}
|
|
45
|
-
return navigator.language;
|
|
46
|
-
}
|
|
47
39
|
function getSeparator(locale, separatorType) {
|
|
48
40
|
const numberWithGroupAndDecimalSeparator = 1000.1;
|
|
49
41
|
return Intl.NumberFormat(locale)
|
|
@@ -51,7 +43,7 @@ function getSeparator(locale, separatorType) {
|
|
|
51
43
|
.find((part) => part.type === separatorType).value;
|
|
52
44
|
}
|
|
53
45
|
export function getCurrentDateFormatFromBrowserLocale() {
|
|
54
|
-
const formatObj = new Intl.DateTimeFormat(
|
|
46
|
+
const formatObj = new Intl.DateTimeFormat(dom.ketchup.dates.getLocale()).formatToParts(new Date());
|
|
55
47
|
let dateFormat = formatObj
|
|
56
48
|
.map((obj) => {
|
|
57
49
|
switch (obj.type) {
|
|
@@ -77,7 +69,7 @@ function getCurrentTimeFormatFromBrowserLocale(manageSeconds) {
|
|
|
77
69
|
if (manageSeconds == true) {
|
|
78
70
|
options.second = '2-digit';
|
|
79
71
|
}
|
|
80
|
-
const formatObj = new Intl.DateTimeFormat(
|
|
72
|
+
const formatObj = new Intl.DateTimeFormat(dom.ketchup.dates.getLocale() + '-u-hc-h23', options).formatToParts(new Date());
|
|
81
73
|
let timeFormat = formatObj
|
|
82
74
|
.map((obj) => {
|
|
83
75
|
switch (obj.type) {
|
|
@@ -160,7 +152,7 @@ export function numberToString(input, decimals) {
|
|
|
160
152
|
if (input == null) {
|
|
161
153
|
return '';
|
|
162
154
|
}
|
|
163
|
-
return _numberToString(input, decimals,
|
|
155
|
+
return _numberToString(input, decimals, dom.ketchup.dates.getLocale(), true);
|
|
164
156
|
}
|
|
165
157
|
/**
|
|
166
158
|
* @param type - type of number for calculate suffix
|
|
@@ -212,7 +204,7 @@ export function unformattedStringToFormattedStringNumber(input, decimals, type)
|
|
|
212
204
|
* @returns number as string, formatted by locale US, decimal separator . (like java decimal numbers), without group separator
|
|
213
205
|
**/
|
|
214
206
|
export function formattedStringToUnformattedStringNumber(input, type) {
|
|
215
|
-
return numberStringToNumberString(input, type, getDecimalSeparator(
|
|
207
|
+
return numberStringToNumberString(input, type, getDecimalSeparator(dom.ketchup.dates.getLocale()));
|
|
216
208
|
}
|
|
217
209
|
/**
|
|
218
210
|
* @param input number as string, formatted by locale US, decimal separator . (like java decimal numbers), with group separator
|
|
@@ -293,7 +285,7 @@ export function formatTime(time, manageSeconds) {
|
|
|
293
285
|
if (manageSeconds == true) {
|
|
294
286
|
options.second = '2-digit';
|
|
295
287
|
}
|
|
296
|
-
return time.toLocaleTimeString(
|
|
288
|
+
return time.toLocaleTimeString(dom.ketchup.dates.getLocale() + '-u-hc-h23', options);
|
|
297
289
|
}
|
|
298
290
|
/**
|
|
299
291
|
* @param value time string, formatted by actual browser locale
|
|
@@ -301,7 +293,7 @@ export function formatTime(time, manageSeconds) {
|
|
|
301
293
|
*/
|
|
302
294
|
export function isValidFormattedStringTime(value, manageSeconds) {
|
|
303
295
|
let format = getCurrentTimeFormatFromBrowserLocale(manageSeconds);
|
|
304
|
-
return
|
|
296
|
+
return dom.ketchup.dates.isValid(value, format, true);
|
|
305
297
|
}
|
|
306
298
|
/**
|
|
307
299
|
* @param value time as string, formatted by actual browser locale
|
|
@@ -325,8 +317,8 @@ export function formattedStringToDefaultUnformattedStringTimestamp(value) {
|
|
|
325
317
|
**/
|
|
326
318
|
export function formattedStringToCustomUnformattedStringTime(value, outputFormat, manageSeconds) {
|
|
327
319
|
let inputFormat = getCurrentTimeFormatFromBrowserLocale(manageSeconds);
|
|
328
|
-
if (
|
|
329
|
-
return
|
|
320
|
+
if (dom.ketchup.dates.isValid(value, inputFormat)) {
|
|
321
|
+
return dom.ketchup.dates.format(dom.ketchup.dates.normalize(value, KupDatesNormalize.TIME), outputFormat);
|
|
330
322
|
}
|
|
331
323
|
else {
|
|
332
324
|
return '';
|
|
@@ -348,12 +340,12 @@ export function unformattedStringToFormattedStringTime(value, manageSeconds, cus
|
|
|
348
340
|
if (manageSeconds == true) {
|
|
349
341
|
options.second = '2-digit';
|
|
350
342
|
}
|
|
351
|
-
let date =
|
|
343
|
+
let date = dom.ketchup.dates.toDate(dom.ketchup.dates.normalize(value, KupDatesNormalize.TIME));
|
|
352
344
|
return formatByCustomedOutputTimeFormat(value, date, options, customedFormat);
|
|
353
345
|
}
|
|
354
346
|
function formatByCustomedOutputTimeFormat(valueStr, date, options, customedFormat) {
|
|
355
347
|
if (customedFormat == null) {
|
|
356
|
-
return date.toLocaleTimeString(
|
|
348
|
+
return date.toLocaleTimeString(dom.ketchup.dates.getLocale() + '-u-hc-h23', options);
|
|
357
349
|
}
|
|
358
350
|
switch (customedFormat) {
|
|
359
351
|
case 'I13': {
|
|
@@ -422,7 +414,7 @@ function formatByCustomedOutputTimeFormat(valueStr, date, options, customedForma
|
|
|
422
414
|
return valueStr;
|
|
423
415
|
}
|
|
424
416
|
}
|
|
425
|
-
return date.toLocaleTimeString(
|
|
417
|
+
return date.toLocaleTimeString(dom.ketchup.dates.getLocale() + '-u-hc-h23', options);
|
|
426
418
|
}
|
|
427
419
|
/**
|
|
428
420
|
* @param value date/time as string, formatted ISO
|
|
@@ -439,8 +431,8 @@ export function unformattedStringToFormattedStringTimestamp(value) {
|
|
|
439
431
|
second: '2-digit',
|
|
440
432
|
hour12: false,
|
|
441
433
|
};
|
|
442
|
-
let date =
|
|
443
|
-
return date.toLocaleString(
|
|
434
|
+
let date = dom.ketchup.dates.toDate(dom.ketchup.dates.normalize(value, KupDatesNormalize.TIMESTAMP));
|
|
435
|
+
return date.toLocaleString(dom.ketchup.dates.getLocale() + '-u-hc-h23', options);
|
|
444
436
|
}
|
|
445
437
|
export function getMonthAsStringByLocale(month, format) {
|
|
446
438
|
if (month == null) {
|
|
@@ -452,7 +444,7 @@ export function getMonthAsStringByLocale(month, format) {
|
|
|
452
444
|
const options = {
|
|
453
445
|
month: format,
|
|
454
446
|
};
|
|
455
|
-
const dateTimeFormat = new Intl.DateTimeFormat(
|
|
447
|
+
const dateTimeFormat = new Intl.DateTimeFormat(dom.ketchup.dates.getLocale(), options);
|
|
456
448
|
return dateTimeFormat.format(dateTmp);
|
|
457
449
|
}
|
|
458
450
|
export function getMonthsAsStringByLocale(format) {
|
|
@@ -473,7 +465,7 @@ export function getDayAsStringByLocale(date) {
|
|
|
473
465
|
weekday: 'narrow',
|
|
474
466
|
/** weekday: 'narrow' 'short' 'long' */
|
|
475
467
|
};
|
|
476
|
-
const dateTimeFormat = new Intl.DateTimeFormat(
|
|
468
|
+
const dateTimeFormat = new Intl.DateTimeFormat(dom.ketchup.dates.getLocale(), options);
|
|
477
469
|
return dateTimeFormat.format(date);
|
|
478
470
|
}
|
|
479
471
|
function firstDayThisWeek(firstDayIndex) {
|
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
import { o as unformattedStringToFormattedStringNumber, q as unformattedStringToFormattedStringTime, r as unformattedStringToFormattedStringTimestamp, n as numeral, d as stringToNumber } from './utils-6c73709d.js';
|
|
2
|
+
import { c as KupDatesFormats } from './kup-manager-7fc234da.js';
|
|
3
|
+
|
|
4
|
+
const dom = document.documentElement;
|
|
5
|
+
// -------------
|
|
6
|
+
// COMMONS
|
|
7
|
+
// -------------
|
|
8
|
+
function getCellValueForDisplay(column, cell) {
|
|
9
|
+
if (cell != null) {
|
|
10
|
+
if (cell.displayedValue != null) {
|
|
11
|
+
return cell.displayedValue;
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
let formattedValue = _getCellValueForDisplay(cell.value, column, cell);
|
|
15
|
+
if (cell != null) {
|
|
16
|
+
cell.displayedValue = formattedValue;
|
|
17
|
+
}
|
|
18
|
+
return formattedValue;
|
|
19
|
+
}
|
|
20
|
+
function getValueForDisplay2(values, column) {
|
|
21
|
+
if (values == null) {
|
|
22
|
+
return '';
|
|
23
|
+
}
|
|
24
|
+
if (values.displayedValue == null || values.displayedValue.trim() == '') {
|
|
25
|
+
values.displayedValue = _getCellValueForDisplay(values.value, column, null);
|
|
26
|
+
}
|
|
27
|
+
return values.displayedValue;
|
|
28
|
+
}
|
|
29
|
+
function formatToNumber(cell) {
|
|
30
|
+
if (cell.obj) {
|
|
31
|
+
return numeral(cell.obj.k).value();
|
|
32
|
+
}
|
|
33
|
+
return numeral(cell.value).value();
|
|
34
|
+
}
|
|
35
|
+
function _getCellValueForDisplay(value, column, cell) {
|
|
36
|
+
let obj = column != null ? column.obj : null;
|
|
37
|
+
if (cell != null) {
|
|
38
|
+
obj = cell.obj ? cell.obj : obj;
|
|
39
|
+
}
|
|
40
|
+
return getValueForDisplay(value, obj, column != null ? column.decimals : null);
|
|
41
|
+
}
|
|
42
|
+
function getValueForDisplay(value, obj, decimals) {
|
|
43
|
+
if (value == null || value.trim() == '') {
|
|
44
|
+
return value;
|
|
45
|
+
}
|
|
46
|
+
if (dom.ketchup.objects.isNumber(obj)) {
|
|
47
|
+
return unformattedStringToFormattedStringNumber(value, decimals ? decimals : -1, obj ? obj.p : '');
|
|
48
|
+
}
|
|
49
|
+
if (dom.ketchup.objects.isDate(obj) &&
|
|
50
|
+
dom.ketchup.dates.isValid(value, KupDatesFormats.ISO_DATE)) {
|
|
51
|
+
return dom.ketchup.dates.format(value);
|
|
52
|
+
}
|
|
53
|
+
if (dom.ketchup.objects.isTime(obj)) {
|
|
54
|
+
return unformattedStringToFormattedStringTime(value, dom.ketchup.objects.isTimeWithSeconds(obj), obj.t + obj.p);
|
|
55
|
+
}
|
|
56
|
+
if (dom.ketchup.objects.isTimestamp(obj)) {
|
|
57
|
+
return unformattedStringToFormattedStringTimestamp(value);
|
|
58
|
+
}
|
|
59
|
+
return value;
|
|
60
|
+
}
|
|
61
|
+
function getColumnByName(columns, name) {
|
|
62
|
+
if (columns == null) {
|
|
63
|
+
return null;
|
|
64
|
+
}
|
|
65
|
+
for (let column of columns) {
|
|
66
|
+
if (column.name === name) {
|
|
67
|
+
return column;
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
return null;
|
|
71
|
+
}
|
|
72
|
+
function compareCell(cell1, cell2, sortMode) {
|
|
73
|
+
return compareValues(cell1.obj, cell1.value, cell2.obj, cell2.value, sortMode);
|
|
74
|
+
}
|
|
75
|
+
function compareValues(obj1, value1, obj2, value2, sortMode) {
|
|
76
|
+
const sm = sortMode === 'A' ? 1 : -1;
|
|
77
|
+
if (obj1 == null || obj2 == null) {
|
|
78
|
+
return sm * localCompareAsInJava(value1, value2);
|
|
79
|
+
}
|
|
80
|
+
// If either the type or the parameter of the current object are not equal.
|
|
81
|
+
if (!(obj1.t === obj2.t && obj1.p === obj2.p)) {
|
|
82
|
+
let compare = localCompareAsInJava(obj1.t, obj2.t);
|
|
83
|
+
if (compare === 0) {
|
|
84
|
+
compare = localCompareAsInJava(obj1.p, obj2.p);
|
|
85
|
+
}
|
|
86
|
+
return compare * sm;
|
|
87
|
+
}
|
|
88
|
+
let s1 = value1;
|
|
89
|
+
let s2 = value2;
|
|
90
|
+
if (s1 == s2) {
|
|
91
|
+
return 0;
|
|
92
|
+
}
|
|
93
|
+
if (s1 == '') {
|
|
94
|
+
return sm * -1;
|
|
95
|
+
}
|
|
96
|
+
if (s2 == '') {
|
|
97
|
+
return sm * 1;
|
|
98
|
+
}
|
|
99
|
+
let v1 = s1;
|
|
100
|
+
let v2 = s2;
|
|
101
|
+
if (dom.ketchup.objects.isNumber(obj1)) {
|
|
102
|
+
v1 = stringToNumber(s1);
|
|
103
|
+
v2 = stringToNumber(s2);
|
|
104
|
+
}
|
|
105
|
+
else if (dom.ketchup.objects.isDate(obj1)) {
|
|
106
|
+
v1 = dom.ketchup.dates.toDate(dom.ketchup.dates.format(s1, KupDatesFormats.ISO_DATE));
|
|
107
|
+
v2 = dom.ketchup.dates.toDate(dom.ketchup.dates.format(s2, KupDatesFormats.ISO_DATE));
|
|
108
|
+
}
|
|
109
|
+
else if (dom.ketchup.objects.isTime(obj1)) {
|
|
110
|
+
let manageSeconds = dom.ketchup.objects.isTimeWithSeconds(obj1);
|
|
111
|
+
v1 = dom.ketchup.dates.toDate(dom.ketchup.dates.format(s1, manageSeconds
|
|
112
|
+
? KupDatesFormats.ISO_TIME
|
|
113
|
+
: KupDatesFormats.ISO_TIME_WITHOUT_SECONDS));
|
|
114
|
+
v2 = dom.ketchup.dates.toDate(dom.ketchup.dates.format(s2, manageSeconds
|
|
115
|
+
? KupDatesFormats.ISO_TIME
|
|
116
|
+
: KupDatesFormats.ISO_TIME_WITHOUT_SECONDS));
|
|
117
|
+
}
|
|
118
|
+
else if (dom.ketchup.objects.isTimestamp(obj1)) {
|
|
119
|
+
v1 = dom.ketchup.dates.toDate(dom.ketchup.dates.format(s1, KupDatesFormats.ISO_DATE_TIME));
|
|
120
|
+
v2 = dom.ketchup.dates.toDate(dom.ketchup.dates.format(s2, KupDatesFormats.ISO_DATE_TIME));
|
|
121
|
+
}
|
|
122
|
+
if (v1 > v2) {
|
|
123
|
+
return sm * 1;
|
|
124
|
+
}
|
|
125
|
+
if (v1 < v2) {
|
|
126
|
+
return sm * -1;
|
|
127
|
+
}
|
|
128
|
+
return 0;
|
|
129
|
+
}
|
|
130
|
+
/**
|
|
131
|
+
* Given two strings to compare, the functions decides which string comes before the other or if they are equal.
|
|
132
|
+
* This is meant as a replacement for the JavaScript function localCompare() which produces a slightly different result from
|
|
133
|
+
* the Java version of compareTo().
|
|
134
|
+
*
|
|
135
|
+
* Re-implemented from java source method compareTo() of java.lang.String
|
|
136
|
+
* @param t1 firstString the first string to be compared
|
|
137
|
+
* @param t2 anotherString the another string to be compared to the first one
|
|
138
|
+
* @returns the value 0 if the anotherString is equal to
|
|
139
|
+
* firstString; a value less than 0 if firstString
|
|
140
|
+
* is lexicographically less than the anotherString; and a
|
|
141
|
+
* value greater than 0 if firstString is
|
|
142
|
+
* lexicographically greater than the anotherString.
|
|
143
|
+
*/
|
|
144
|
+
function localCompareAsInJava(t1, t2) {
|
|
145
|
+
let t1Length = t1 == null ? 0 : t1.length;
|
|
146
|
+
let t2Length = t2 == null ? 0 : t2.length;
|
|
147
|
+
const lim = Math.min(t1Length, t2Length);
|
|
148
|
+
let k = 0;
|
|
149
|
+
while (k < lim) {
|
|
150
|
+
const c1 = t1[k];
|
|
151
|
+
const c2 = t2[k];
|
|
152
|
+
if (c1 !== c2) {
|
|
153
|
+
return c1.charCodeAt(0) - c2.charCodeAt(0);
|
|
154
|
+
}
|
|
155
|
+
k++;
|
|
156
|
+
}
|
|
157
|
+
return t1Length - t2Length;
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
export { getValueForDisplay2 as a, getCellValueForDisplay as b, getColumnByName as c, compareValues as d, compareCell as e, formatToNumber as f, getValueForDisplay as g };
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
import { h } from './index-e0e67c23.js';
|
|
2
|
+
import { F as FButtonStyling } from './f-button-declarations-fd4965d1.js';
|
|
3
|
+
import { F as FImage } from './f-image-3bc8b24f.js';
|
|
4
|
+
|
|
5
|
+
/*-------------------------------------------------*/
|
|
6
|
+
/* C o m p o n e n t */
|
|
7
|
+
/*-------------------------------------------------*/
|
|
8
|
+
const FButton = (props, children) => {
|
|
9
|
+
if (!props.styling) {
|
|
10
|
+
props.styling = FButtonStyling.RAISED;
|
|
11
|
+
}
|
|
12
|
+
if (!props.label && !props.icon) {
|
|
13
|
+
return;
|
|
14
|
+
}
|
|
15
|
+
const isIconButton = !!(props.styling.toLowerCase() === FButtonStyling.ICON ||
|
|
16
|
+
(props.styling.toLowerCase() === FButtonStyling.RAISED &&
|
|
17
|
+
props.icon &&
|
|
18
|
+
(props.label === null || props.label === undefined)));
|
|
19
|
+
return (h("div", Object.assign({ class: `f-button ${props.danger ? 'kup-danger' : ''} ${props.fullHeight ? 'kup-full-height' : ''} ${props.fullWidth ? 'kup-full-width' : ''} ${props.info ? 'kup-info' : ''} ${props.large ? 'kup-large' : ''} ${props.pulsating ? 'kup-pulsating' : ''} ${props.shaped ? 'kup-shaped' : ''} ${props.secondary ? 'kup-secondary' : ''} ${props.slim ? 'kup-slim' : ''} ${props.success ? 'kup-success' : ''} ${props.warning ? 'kup-warning' : ''} ${props.wrapperClass ? props.wrapperClass : ''}` }, props.dataSet, { id: props.id, title: props.title }),
|
|
20
|
+
isIconButton ? renderIconButton(props) : renderButton(props),
|
|
21
|
+
children));
|
|
22
|
+
};
|
|
23
|
+
/*-------------------------------------------------*/
|
|
24
|
+
/* M e t h o d s */
|
|
25
|
+
/*-------------------------------------------------*/
|
|
26
|
+
function renderButton(props) {
|
|
27
|
+
const isFlat = props.styling.toLowerCase() === FButtonStyling.FLAT;
|
|
28
|
+
const isFloating = props.styling.toLowerCase() === FButtonStyling.FLOATING;
|
|
29
|
+
const isIcon = props.styling.toLowerCase() === FButtonStyling.ICON;
|
|
30
|
+
const isOutlined = props.styling.toLowerCase() === FButtonStyling.OUTLINED;
|
|
31
|
+
const isRaised = !isFlat && !isFloating && !isOutlined && !isIcon ? true : false;
|
|
32
|
+
const propsFImage = {
|
|
33
|
+
color: props.disabled
|
|
34
|
+
? `var(--kup_button_disabled_color)`
|
|
35
|
+
: isOutlined || isFlat
|
|
36
|
+
? `var(--kup_button_primary_color)`
|
|
37
|
+
: `var(--kup_button_text_on_primary_color)`,
|
|
38
|
+
resource: props.icon,
|
|
39
|
+
sizeX: isFloating ? '1.75em' : '1.475em',
|
|
40
|
+
sizeY: isFloating ? '1.75em' : '1.475em',
|
|
41
|
+
wrapperClass: 'button__icon kup-icon',
|
|
42
|
+
};
|
|
43
|
+
if (props.showSpinner)
|
|
44
|
+
propsFImage.wrapperClass += ' content--hidden';
|
|
45
|
+
const classObj = {
|
|
46
|
+
button: true,
|
|
47
|
+
'button--disabled': props.disabled ? true : false,
|
|
48
|
+
'button--floating': isFloating ? true : false,
|
|
49
|
+
'button--outlined': isOutlined ? true : false,
|
|
50
|
+
'button--raised': isRaised ? true : false,
|
|
51
|
+
'button--no-label': !props.label || props.label === ' ' ? true : false,
|
|
52
|
+
'button--with-spinner': props.showSpinner && !props.disabled ? true : false,
|
|
53
|
+
};
|
|
54
|
+
const classLabelObj = {
|
|
55
|
+
button__label: true,
|
|
56
|
+
'content--hidden': props.showSpinner && !props.disabled ? true : false,
|
|
57
|
+
};
|
|
58
|
+
const styleSpinnerContainer = {
|
|
59
|
+
'--kup_button_spinner_height': propsFImage.sizeY,
|
|
60
|
+
};
|
|
61
|
+
return (h("button", { class: classObj, disabled: props.disabled, onBlur: props.onBlur, onClick: props.onClick, onFocus: props.onFocus, style: styleSpinnerContainer, type: "button" },
|
|
62
|
+
props.trailingIcon
|
|
63
|
+
? [
|
|
64
|
+
h("span", { class: classLabelObj }, props.label),
|
|
65
|
+
props.icon ? h(FImage, Object.assign({}, propsFImage)) : undefined,
|
|
66
|
+
]
|
|
67
|
+
: [
|
|
68
|
+
props.icon ? h(FImage, Object.assign({}, propsFImage)) : undefined,
|
|
69
|
+
h("span", { class: classLabelObj }, props.label),
|
|
70
|
+
],
|
|
71
|
+
props.showSpinner && !props.disabled ? (h("div", { class: "button__spinner-container" },
|
|
72
|
+
h("slot", { name: "spinner" }))) : undefined));
|
|
73
|
+
}
|
|
74
|
+
function renderIconButton(props) {
|
|
75
|
+
const propsFImage = {
|
|
76
|
+
color: props.disabled
|
|
77
|
+
? `var(--kup_button_disabled_color)`
|
|
78
|
+
: `var(--kup_button_primary_color)`,
|
|
79
|
+
sizeX: props.large ? 'calc(1.75em * 1.5)' : '1.75em',
|
|
80
|
+
sizeY: props.large ? 'calc(1.75em * 1.5)' : '1.75em',
|
|
81
|
+
};
|
|
82
|
+
const classObj = {
|
|
83
|
+
'icon-button': true,
|
|
84
|
+
'button--disabled': props.disabled ? true : false,
|
|
85
|
+
'icon-button--on': props.toggable && props.checked ? true : false,
|
|
86
|
+
toggable: props.toggable ? true : false,
|
|
87
|
+
'button--with-spinner': props.showSpinner && !props.disabled ? true : false,
|
|
88
|
+
};
|
|
89
|
+
const styleSpinnerContainer = {
|
|
90
|
+
'--kup_button_spinner_height': propsFImage.sizeY,
|
|
91
|
+
'--kup_button_spinner_width': propsFImage.sizeX,
|
|
92
|
+
};
|
|
93
|
+
const iconOff = props.iconOff
|
|
94
|
+
? props.iconOff
|
|
95
|
+
: props.icon + '_border';
|
|
96
|
+
return (h("button", { class: classObj, disabled: props.disabled, onClick: props.onClick, style: styleSpinnerContainer, type: "button", value: props.checked ? 'on' : 'off' },
|
|
97
|
+
!props.showSpinner || props.disabled ? (h(FImage, Object.assign({}, propsFImage, { resource: props.toggable && !props.checked ? iconOff : props.icon, wrapperClass: `icon-button__icon kup-icon` }))) : null,
|
|
98
|
+
props.toggable && !props.showSpinner ? (h(FImage, Object.assign({}, propsFImage, { resource: props.icon, wrapperClass: `icon-button__icon icon-button__icon--on kup-icon` }))) : null,
|
|
99
|
+
props.showSpinner && !props.disabled ? (h("div", { class: "icon-button__spinner-container" },
|
|
100
|
+
h("slot", { name: "spinner" }))) : undefined));
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
export { FButton as F };
|