@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
|
@@ -123,9 +123,8 @@ export class KupDrawer {
|
|
|
123
123
|
this.kupManager.debug.logRender(this, true);
|
|
124
124
|
}
|
|
125
125
|
render() {
|
|
126
|
-
const customStyle = this.kupManager.theme.setCustomStyle(this.rootElement);
|
|
127
126
|
return (h(Host, { "kup-opened": this.opened },
|
|
128
|
-
|
|
127
|
+
h("style", null, this.kupManager.theme.setKupStyle(this.rootElement)),
|
|
129
128
|
h("div", { class: "backdrop", onPointerDown: () => this.close() }),
|
|
130
129
|
h("div", { id: componentWrapperId },
|
|
131
130
|
h("div", { class: drawerClass }, this.content()))));
|
|
@@ -154,11 +153,11 @@ export class KupDrawer {
|
|
|
154
153
|
"optional": false,
|
|
155
154
|
"docs": {
|
|
156
155
|
"tags": [{
|
|
157
|
-
"
|
|
158
|
-
"
|
|
156
|
+
"name": "default",
|
|
157
|
+
"text": "\"\""
|
|
159
158
|
}, {
|
|
160
|
-
"
|
|
161
|
-
"
|
|
159
|
+
"name": "see",
|
|
160
|
+
"text": "https://ketchup.smeup.com/ketchup-showcase/#/customization"
|
|
162
161
|
}],
|
|
163
162
|
"text": "Custom style of the component."
|
|
164
163
|
},
|
|
@@ -253,8 +252,8 @@ export class KupDrawer {
|
|
|
253
252
|
"signature": "(descriptions?: boolean) => Promise<GenericObject>",
|
|
254
253
|
"parameters": [{
|
|
255
254
|
"tags": [{
|
|
256
|
-
"
|
|
257
|
-
"
|
|
255
|
+
"name": "param",
|
|
256
|
+
"text": "descriptions - When provided and true, the result will be the list of props with their description."
|
|
258
257
|
}],
|
|
259
258
|
"text": "- When provided and true, the result will be the list of props with their description."
|
|
260
259
|
}],
|
|
@@ -336,8 +335,8 @@ export class KupDrawer {
|
|
|
336
335
|
"signature": "(props: GenericObject) => Promise<void>",
|
|
337
336
|
"parameters": [{
|
|
338
337
|
"tags": [{
|
|
339
|
-
"
|
|
340
|
-
"
|
|
338
|
+
"name": "param",
|
|
339
|
+
"text": "props - Object containing props that will be set to the component."
|
|
341
340
|
}],
|
|
342
341
|
"text": "- Object containing props that will be set to the component."
|
|
343
342
|
}],
|
|
@@ -1,338 +1,10 @@
|
|
|
1
|
-
|
|
2
|
-
display: block;
|
|
3
|
-
margin: auto;
|
|
4
|
-
position: relative;
|
|
5
|
-
height: var(--kup_image_height, 100%);
|
|
6
|
-
width: var(--kup_image_width, 100%);
|
|
7
|
-
}
|
|
8
|
-
.f-image--wrapper.kup-fit img {
|
|
9
|
-
max-width: max-content;
|
|
10
|
-
object-fit: contain;
|
|
11
|
-
}
|
|
12
|
-
.f-image--wrapper img {
|
|
1
|
+
:host {
|
|
13
2
|
display: block;
|
|
14
|
-
|
|
15
|
-
height: var(--kup_image_height, 100%);
|
|
16
|
-
width: var(--kup_image_width, 100%);
|
|
17
|
-
}
|
|
18
|
-
.f-image--wrapper .f-image__css {
|
|
19
|
-
overflow: hidden;
|
|
20
|
-
height: var(--kup_image_height, 100%);
|
|
21
|
-
width: var(--kup_image_width, 100%);
|
|
22
|
-
}
|
|
23
|
-
.f-image--wrapper .f-image__icon {
|
|
24
|
-
margin: auto;
|
|
25
|
-
height: var(--kup_image_height, 100%);
|
|
26
|
-
width: var(--kup_image_width, 100%);
|
|
27
|
-
}
|
|
28
|
-
.f-image--wrapper .css-step.bottom-aligned {
|
|
29
|
-
bottom: 0;
|
|
30
|
-
position: absolute;
|
|
3
|
+
width: max-content;
|
|
31
4
|
}
|
|
32
5
|
|
|
33
|
-
|
|
34
|
-
--kup_button_border_radius: var(--kup-button-border-radius, 4px);
|
|
35
|
-
--kup_button_disabled_color: var(
|
|
36
|
-
--kup-button-disabled-color,
|
|
37
|
-
var(--kup-disabled-color)
|
|
38
|
-
);
|
|
39
|
-
--kup_button_font_family: var(
|
|
40
|
-
--kup-button-font-family,
|
|
41
|
-
var(--kup-font-family)
|
|
42
|
-
);
|
|
43
|
-
--kup_button_font_size: var(--kup-button-font-size, var(--kup-font-size));
|
|
44
|
-
--kup_button_font_weight: var(--kup-button-font-weight, 400);
|
|
45
|
-
--kup_button_height: var(--kup-button-height, 3em);
|
|
46
|
-
--kup_button_padding: var(--kup-button-padding, 0 1.25em);
|
|
47
|
-
--kup_button_primary_color: var(
|
|
48
|
-
--kup-button-primary-color,
|
|
49
|
-
var(--kup-primary-color)
|
|
50
|
-
);
|
|
51
|
-
--kup_button_primary_color_h: var(
|
|
52
|
-
--kup-button-primary-color-h,
|
|
53
|
-
var(--kup-primary-color-h)
|
|
54
|
-
);
|
|
55
|
-
--kup_button_primary_color_s: var(
|
|
56
|
-
--kup-button-primary-color-s,
|
|
57
|
-
var(--kup-primary-color-s)
|
|
58
|
-
);
|
|
59
|
-
--kup_button_primary_color_l: var(
|
|
60
|
-
--kup-button-primary-color-l,
|
|
61
|
-
var(--kup-primary-color-l)
|
|
62
|
-
);
|
|
63
|
-
--kup_button_primary_color_rgb: var(
|
|
64
|
-
--kup-button-primary-color-rgb,
|
|
65
|
-
var(--kup-primary-color-rgb)
|
|
66
|
-
);
|
|
67
|
-
--kup_button_text_on_primary_color: var(
|
|
68
|
-
--kup-button-text-on-primary-color,
|
|
69
|
-
var(--kup-text-on-primary-color)
|
|
70
|
-
);
|
|
71
|
-
--kup-spinner-color: var(--kup_button_primary_color);
|
|
72
|
-
font-family: var(--kup_button_font_family);
|
|
73
|
-
font-size: var(--kup_button_font_size);
|
|
74
|
-
}
|
|
75
|
-
.f-button--wrapper .button {
|
|
76
|
-
-moz-osx-font-smoothing: grayscale;
|
|
77
|
-
-webkit-appearance: none;
|
|
78
|
-
-webkit-font-smoothing: antialiased;
|
|
79
|
-
align-items: center;
|
|
80
|
-
background-color: transparent;
|
|
81
|
-
border: none;
|
|
82
|
-
border-radius: var(--kup_button_border_radius);
|
|
83
|
-
box-sizing: border-box;
|
|
84
|
-
color: var(--kup_button_primary_color);
|
|
85
|
-
cursor: pointer;
|
|
86
|
-
display: inline-flex;
|
|
87
|
-
font-size: 0.775em;
|
|
88
|
-
font-weight: var(--kup_button_font_weight);
|
|
89
|
-
height: var(--kup_button_height);
|
|
90
|
-
justify-content: center;
|
|
91
|
-
letter-spacing: 0.0892857143em;
|
|
92
|
-
line-height: inherit;
|
|
93
|
-
min-width: 64px;
|
|
94
|
-
outline: none;
|
|
95
|
-
overflow: visible;
|
|
96
|
-
padding: var(--kup_button_padding);
|
|
6
|
+
#kup-component {
|
|
97
7
|
position: relative;
|
|
98
|
-
text-decoration: none;
|
|
99
|
-
text-transform: uppercase;
|
|
100
|
-
transition: background-color 80ms linear, box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);
|
|
101
|
-
user-select: none;
|
|
102
|
-
vertical-align: middle;
|
|
103
|
-
}
|
|
104
|
-
.f-button--wrapper .button:hover {
|
|
105
|
-
background-color: rgba(var(--kup_button_primary_color_rgb), 0.125);
|
|
106
|
-
}
|
|
107
|
-
.f-button--wrapper .button:focus {
|
|
108
|
-
background-color: rgba(var(--kup_button_primary_color_rgb), 0.175);
|
|
109
|
-
}
|
|
110
|
-
.f-button--wrapper .button .button__icon {
|
|
111
|
-
margin-left: -0.25em;
|
|
112
|
-
margin-right: 0.75em;
|
|
113
|
-
}
|
|
114
|
-
.f-button--wrapper .button .button__label + .button__icon {
|
|
115
|
-
margin-left: 0.75em;
|
|
116
|
-
margin-right: -0.25em;
|
|
117
|
-
}
|
|
118
|
-
.f-button--wrapper .button.button--floating, .f-button--wrapper .button.button--raised {
|
|
119
|
-
--kup-spinner-color: var(--kup_button_text_on_primary_color);
|
|
120
|
-
}
|
|
121
|
-
.f-button--wrapper .button.button--floating:not(.button--disabled), .f-button--wrapper .button.button--raised:not(.button--disabled) {
|
|
122
|
-
--kup-spinner-border-color: hsl(
|
|
123
|
-
var(--kup_button_primary_color_h),
|
|
124
|
-
calc(var(--kup_button_primary_color_s) * 0.75),
|
|
125
|
-
calc(var(--kup_button_primary_color_l) * 0.85)
|
|
126
|
-
);
|
|
127
|
-
background-color: var(--kup_button_primary_color);
|
|
128
|
-
color: var(--kup_button_text_on_primary_color);
|
|
129
|
-
}
|
|
130
|
-
.f-button--wrapper .button.button--floating:hover, .f-button--wrapper .button.button--raised:hover {
|
|
131
|
-
background-color: hsl(var(--kup_button_primary_color_h), calc(var(--kup_button_primary_color_s) * 0.93), calc(var(--kup_button_primary_color_l) * 1.07));
|
|
132
|
-
}
|
|
133
|
-
.f-button--wrapper .button.button--floating:focus, .f-button--wrapper .button.button--raised:focus {
|
|
134
|
-
background-color: hsl(var(--kup_button_primary_color_h), calc(var(--kup_button_primary_color_s) * 0.88), calc(var(--kup_button_primary_color_l) * 1.12));
|
|
135
|
-
}
|
|
136
|
-
.f-button--wrapper .button.button--floating.button--disabled, .f-button--wrapper .button.button--raised.button--disabled {
|
|
137
|
-
background-color: var(--kup-disabled-background-color);
|
|
138
|
-
box-shadow: none;
|
|
139
|
-
}
|
|
140
|
-
.f-button--wrapper .button.button--floating {
|
|
141
|
-
border-radius: 24px;
|
|
142
|
-
box-shadow: 0 0.215em 0.35em -1px rgba(var(--kup-text-color-rgb), 0.2), 0 0.43em 0.71em 0 rgba(var(--kup-text-color-rgb), 0.14), 0 0.07em 1.285em 0 rgba(var(--kup-text-color-rgb), 0.12);
|
|
143
|
-
font-weight: 500;
|
|
144
|
-
font-size: 1em;
|
|
145
|
-
height: 3.4em;
|
|
146
|
-
width: auto;
|
|
147
|
-
padding: 0 1.5em;
|
|
148
|
-
}
|
|
149
|
-
.f-button--wrapper .button.button--floating.button--no-label {
|
|
150
|
-
border-radius: 50%;
|
|
151
|
-
height: 4em;
|
|
152
|
-
padding: 0;
|
|
153
|
-
width: 4em;
|
|
154
|
-
}
|
|
155
|
-
.f-button--wrapper .button.button--floating:hover, .f-button--wrapper .button.button--floating:focus {
|
|
156
|
-
box-shadow: 0 0.35em 0.35em -3px rgba(var(--kup-text-color-rgb), 0.2), 0 0.57em 0.71em 0.07em rgba(var(--kup-text-color-rgb), 0.14), 0 0.21em 1em 0.14em rgba(var(--kup-text-color-rgb), 0.12);
|
|
157
|
-
}
|
|
158
|
-
.f-button--wrapper .button.button--floating:active {
|
|
159
|
-
box-shadow: 0 0.5em 0.57em -4px rgba(var(--kup-text-color-rgb), 0.2), 0 0.85em 1.21em 0.14em rgba(var(--kup-text-color-rgb), 0.14), 0 0.35em 1.57em 0.28em rgba(var(--kup-text-color-rgb), 0.12);
|
|
160
|
-
}
|
|
161
|
-
.f-button--wrapper .button.button--raised {
|
|
162
|
-
box-shadow: 0px 0.1em 0.1em 0 rgba(var(--kup-text-color-rgb), 0.125), 0px 0.2em 1em 0.1em rgba(var(--kup-text-color-rgb), 0.1), 0px 0.25em 1.5em 0.2em rgba(var(--kup-text-color-rgb), 0.075);
|
|
163
|
-
}
|
|
164
|
-
.f-button--wrapper .button.button--raised:hover {
|
|
165
|
-
box-shadow: 0 0.25em 0.25em 0 rgba(var(--kup-text-color-rgb), 0.125), 0 0.75em 1em 0.1em rgba(var(--kup-text-color-rgb), 0.1), 0 0.25em 1.5em 0.2em rgba(var(--kup-text-color-rgb), 0.075);
|
|
166
|
-
}
|
|
167
|
-
.f-button--wrapper .button.button--outlined {
|
|
168
|
-
border-width: 1px;
|
|
169
|
-
border-style: solid;
|
|
170
|
-
}
|
|
171
|
-
.f-button--wrapper .button.button--outlined:not(.button--disabled) {
|
|
172
|
-
border-color: var(--kup_button_primary_color);
|
|
173
|
-
background-color: transparent;
|
|
174
|
-
color: var(--kup_button_primary_color);
|
|
175
|
-
}
|
|
176
|
-
.f-button--wrapper .button.button--outlined:hover {
|
|
177
|
-
background-color: rgba(var(--kup_button_primary_color_rgb), 0.125);
|
|
178
|
-
}
|
|
179
|
-
.f-button--wrapper .button.button--outlined:focus {
|
|
180
|
-
background-color: rgba(var(--kup_button_primary_color_rgb), 0.175);
|
|
181
|
-
}
|
|
182
|
-
.f-button--wrapper .button.button--outlined.button--disabled {
|
|
183
|
-
opacity: 0.75;
|
|
184
|
-
border-color: var(--kup_button_disabled_color);
|
|
185
|
-
}
|
|
186
|
-
.f-button--wrapper .button.button--no-label {
|
|
187
|
-
min-width: unset;
|
|
188
|
-
padding: 0 0.5em;
|
|
189
|
-
}
|
|
190
|
-
.f-button--wrapper .button.button--no-label .button__icon {
|
|
191
|
-
margin: 0;
|
|
192
|
-
}
|
|
193
|
-
.f-button--wrapper .button.button--disabled {
|
|
194
|
-
color: var(--kup_button_disabled_color);
|
|
195
|
-
cursor: auto;
|
|
196
|
-
opacity: 0.75;
|
|
197
|
-
pointer-events: none;
|
|
198
|
-
}
|
|
199
|
-
.f-button--wrapper .button .button__spinner-container {
|
|
200
|
-
width: 100%;
|
|
201
|
-
height: var(--kup_button_spinner_height);
|
|
202
|
-
left: 0;
|
|
203
|
-
position: absolute;
|
|
204
|
-
}
|
|
205
|
-
.f-button--wrapper .icon-button {
|
|
206
|
-
background-color: transparent;
|
|
207
|
-
display: inline-block;
|
|
208
|
-
position: relative;
|
|
209
|
-
box-sizing: border-box;
|
|
210
|
-
border: none;
|
|
211
|
-
outline: none;
|
|
212
|
-
font-size: var(--kup_button_font_size);
|
|
213
|
-
text-decoration: none;
|
|
214
|
-
cursor: pointer;
|
|
215
|
-
user-select: none;
|
|
216
|
-
padding: 0.75em;
|
|
217
|
-
border-radius: 50%;
|
|
218
|
-
}
|
|
219
|
-
.f-button--wrapper .icon-button:hover, .f-button--wrapper .icon-button:focus {
|
|
220
|
-
background-color: rgba(var(--kup_button_primary_color_rgb), 0.125);
|
|
221
|
-
}
|
|
222
|
-
.f-button--wrapper .icon-button .icon-button__icon {
|
|
223
|
-
display: flex;
|
|
224
|
-
margin: auto;
|
|
225
|
-
}
|
|
226
|
-
.f-button--wrapper .icon-button .icon-button__icon.icon-button__icon--on {
|
|
227
|
-
display: none;
|
|
228
|
-
}
|
|
229
|
-
.f-button--wrapper .icon-button.button--disabled {
|
|
230
|
-
opacity: 0.75;
|
|
231
|
-
pointer-events: none;
|
|
232
|
-
}
|
|
233
|
-
.f-button--wrapper .icon-button .icon-button__spinner-container {
|
|
234
|
-
width: var(--kup_button_spinner_width);
|
|
235
|
-
height: var(--kup_button_spinner_height);
|
|
236
|
-
}
|
|
237
|
-
.f-button--wrapper .button--with-spinner {
|
|
238
|
-
opacity: 0.8;
|
|
239
|
-
pointer-events: none;
|
|
240
|
-
}
|
|
241
|
-
.f-button--wrapper .content--hidden {
|
|
242
|
-
visibility: hidden;
|
|
243
|
-
}
|
|
244
|
-
.f-button--wrapper.kup-full-height {
|
|
245
|
-
height: 100%;
|
|
246
|
-
}
|
|
247
|
-
.f-button--wrapper.kup-full-height .button {
|
|
248
|
-
height: 100%;
|
|
249
|
-
}
|
|
250
|
-
.f-button--wrapper.kup-full-width {
|
|
251
|
-
width: 100%;
|
|
252
|
-
}
|
|
253
|
-
.f-button--wrapper.kup-full-width .button {
|
|
254
|
-
width: 100%;
|
|
255
|
-
}
|
|
256
|
-
.f-button--wrapper.kup-large button {
|
|
257
|
-
font-size: 1.25em;
|
|
258
|
-
}
|
|
259
|
-
.f-button--wrapper.kup-shaped .button {
|
|
260
|
-
border-radius: 18px;
|
|
261
|
-
}
|
|
262
|
-
.f-button--wrapper.kup-shaped .button.button--floating {
|
|
263
|
-
border-radius: 50% 0;
|
|
264
|
-
}
|
|
265
|
-
.f-button--wrapper.kup-slim button {
|
|
266
|
-
font-size: 0.675em;
|
|
267
|
-
}
|
|
268
|
-
.f-button--wrapper.kup-pulsating .icon-button--on:after {
|
|
269
|
-
content: "";
|
|
270
|
-
animation: pulsating 1250ms infinite;
|
|
271
|
-
position: absolute;
|
|
272
|
-
height: 2px;
|
|
273
|
-
width: 2px;
|
|
274
|
-
top: calc(50% - 1px);
|
|
275
|
-
left: calc(50% - 1px);
|
|
276
|
-
border-radius: 50%;
|
|
277
|
-
}
|
|
278
|
-
.f-button--wrapper.kup-danger {
|
|
279
|
-
--kup-button-primary-color: var(--kup-danger-color);
|
|
280
|
-
--kup-button-primary-color-h: var(--kup-danger-color-h);
|
|
281
|
-
--kup-button-primary-color-s: var(--kup-danger-color-s);
|
|
282
|
-
--kup-button-primary-color-l: var(--kup-danger-color-l);
|
|
283
|
-
--kup-button-primary-color-rgb: var(--kup-danger-color-rgb);
|
|
284
|
-
--kup-button-text-on-primary-color: white;
|
|
285
|
-
}
|
|
286
|
-
.f-button--wrapper.kup-info {
|
|
287
|
-
--kup-button-primary-color: var(--kup-info-color);
|
|
288
|
-
--kup-button-primary-color-h: var(--kup-info-color-h);
|
|
289
|
-
--kup-button-primary-color-s: var(--kup-info-color-s);
|
|
290
|
-
--kup-button-primary-color-l: var(--kup-info-color-l);
|
|
291
|
-
--kup-button-primary-color-rgb: var(--kup-info-color-rgb);
|
|
292
|
-
--kup-button-text-on-primary-color: white;
|
|
293
|
-
}
|
|
294
|
-
.f-button--wrapper.kup-secondary {
|
|
295
|
-
--kup-button-primary-color: var(--kup-secondary-color);
|
|
296
|
-
--kup-button-primary-color-h: var(--kup-secondary-color-h);
|
|
297
|
-
--kup-button-primary-color-s: var(--kup-secondary-color-s);
|
|
298
|
-
--kup-button-primary-color-l: var(--kup-secondary-color-l);
|
|
299
|
-
--kup-button-primary-color-rgb: var(--kup-secondary-color-rgb);
|
|
300
|
-
--kup-button-text-on-primary-color: var(--kup-text-on-secondary-color);
|
|
301
|
-
}
|
|
302
|
-
.f-button--wrapper.kup-success {
|
|
303
|
-
--kup-button-primary-color: var(--kup-success-color);
|
|
304
|
-
--kup-button-primary-color-h: var(--kup-success-color-h);
|
|
305
|
-
--kup-button-primary-color-s: var(--kup-success-color-s);
|
|
306
|
-
--kup-button-primary-color-l: var(--kup-success-color-l);
|
|
307
|
-
--kup-button-primary-color-rgb: var(--kup-success-color-rgb);
|
|
308
|
-
--kup-button-text-on-primary-color: white;
|
|
309
|
-
}
|
|
310
|
-
.f-button--wrapper.kup-warning {
|
|
311
|
-
--kup-button-primary-color: var(--kup-warning-color);
|
|
312
|
-
--kup-button-primary-color-h: var(--kup-warning-color-h);
|
|
313
|
-
--kup-button-primary-color-s: var(--kup-warning-color-s);
|
|
314
|
-
--kup-button-primary-color-l: var(--kup-warning-color-l);
|
|
315
|
-
--kup-button-primary-color-rgb: var(--kup-warning-color-rgb);
|
|
316
|
-
--kup-button-text-on-primary-color: white;
|
|
317
|
-
}
|
|
318
|
-
|
|
319
|
-
@keyframes pulsating {
|
|
320
|
-
0% {
|
|
321
|
-
transform: scale(2);
|
|
322
|
-
box-shadow: 0 0 0 0 rgba(var(--kup_button_primary_color_rgb), 0.7);
|
|
323
|
-
}
|
|
324
|
-
70% {
|
|
325
|
-
transform: scale(2.75);
|
|
326
|
-
box-shadow: 0 0 0 10px rgba(var(--kup_button_primary_color_rgb), 0);
|
|
327
|
-
}
|
|
328
|
-
100% {
|
|
329
|
-
transform: scale(2);
|
|
330
|
-
box-shadow: 0 0 0 0 rgba(var(--kup_button_primary_color_rgb), 0);
|
|
331
|
-
}
|
|
332
|
-
}
|
|
333
|
-
:host {
|
|
334
|
-
display: block;
|
|
335
|
-
width: max-content;
|
|
336
8
|
}
|
|
337
9
|
|
|
338
10
|
.dropdown-button--wrapper {
|
|
@@ -340,37 +12,37 @@
|
|
|
340
12
|
flex-direction: row;
|
|
341
13
|
}
|
|
342
14
|
|
|
343
|
-
.f-button
|
|
15
|
+
.f-button.dropdown-button__primary-action .button {
|
|
344
16
|
border-top-right-radius: 0;
|
|
345
17
|
border-bottom-right-radius: 0;
|
|
346
18
|
}
|
|
347
|
-
.f-button
|
|
19
|
+
.f-button.dropdown-button__primary-action .button.button--outlined {
|
|
348
20
|
border-right: none;
|
|
349
21
|
}
|
|
350
22
|
|
|
351
|
-
.f-button
|
|
23
|
+
.f-button.dropdown-button__dropdown-action.dropdown-only .button {
|
|
352
24
|
border-top-left-radius: 4px;
|
|
353
25
|
border-bottom-left-radius: 4px;
|
|
354
26
|
}
|
|
355
27
|
|
|
356
|
-
.f-button
|
|
28
|
+
.f-button.dropdown-button__dropdown-action .button {
|
|
357
29
|
border-top-left-radius: 0;
|
|
358
30
|
border-bottom-left-radius: 0;
|
|
359
31
|
box-shadow: var(--kup-primary-color) -2px 0px 2px -2px;
|
|
360
32
|
}
|
|
361
|
-
.f-button
|
|
33
|
+
.f-button.dropdown-button__dropdown-action .button .button__icon {
|
|
362
34
|
transition: transform 80ms linear;
|
|
363
35
|
}
|
|
364
|
-
.f-button
|
|
36
|
+
.f-button.dropdown-button__dropdown-action .button.button--raised {
|
|
365
37
|
box-shadow: 0px 3px 1px -2px rgba(var(--kup-text-color-rgb), 0.125), 0px 2px 2px 0px rgba(var(--kup-text-color-rgb), 0.1), 0px 1px 5px 0px rgba(var(--kup-text-color-rgb), 0.075), var(--kup-text-on-primary-color) -2px 0px 2px -2px;
|
|
366
38
|
}
|
|
367
|
-
.f-button
|
|
39
|
+
.f-button.dropdown-button__dropdown-action .button.button--disabled {
|
|
368
40
|
box-shadow: none;
|
|
369
41
|
}
|
|
370
|
-
.f-button
|
|
42
|
+
.f-button.dropdown-button__dropdown-action .button.button--outlined {
|
|
371
43
|
border-left: none;
|
|
372
44
|
}
|
|
373
|
-
.f-button
|
|
45
|
+
.f-button.dropdown-button__dropdown-action .button.toggled .button__icon {
|
|
374
46
|
transform: rotate(180deg);
|
|
375
47
|
}
|
|
376
48
|
|
|
@@ -2,12 +2,12 @@ import { Component, Element, Event, forceUpdate, h, Host, Listen, Method, Prop,
|
|
|
2
2
|
import { kupManagerInstance, } from '../../utils/kup-manager/kup-manager';
|
|
3
3
|
import { ItemsDisplayMode } from '../kup-list/kup-list-declarations';
|
|
4
4
|
import { consistencyCheck } from '../kup-list/kup-list-helper';
|
|
5
|
-
import { kupDynamicPositionAttribute, } from '../../utils/kup-dynamic-position/kup-dynamic-position-declarations';
|
|
6
5
|
import { KupDropdownButtonProps, } from './kup-dropdown-button-declarations';
|
|
7
6
|
import { FButtonStyling, } from '../../f-components/f-button/f-button-declarations';
|
|
8
7
|
import { FButton } from '../../f-components/f-button/f-button';
|
|
9
8
|
import { getProps, setProps } from '../../utils/utils';
|
|
10
9
|
import { componentWrapperId } from '../../variables/GenericVariables';
|
|
10
|
+
import { KupDynamicPositionPlacement } from '../../utils/kup-dynamic-position/kup-dynamic-position-declarations';
|
|
11
11
|
export class KupDropdownButton {
|
|
12
12
|
constructor() {
|
|
13
13
|
/*-------------------------------------------------*/
|
|
@@ -92,10 +92,7 @@ export class KupDropdownButton {
|
|
|
92
92
|
* List element (dropdown menu).
|
|
93
93
|
*/
|
|
94
94
|
this.listEl = null;
|
|
95
|
-
|
|
96
|
-
* List anchor point.
|
|
97
|
-
*/
|
|
98
|
-
this.wrapperEl = null;
|
|
95
|
+
this.clickCb = null;
|
|
99
96
|
}
|
|
100
97
|
/**
|
|
101
98
|
* Handles the navigation of the dropdown menu with the keyboard.
|
|
@@ -249,10 +246,25 @@ export class KupDropdownButton {
|
|
|
249
246
|
(_a = this.buttonEl) === null || _a === void 0 ? void 0 : _a.classList.add('toggled');
|
|
250
247
|
this.dropdownEl.classList.add('toggled');
|
|
251
248
|
this.listEl.menuVisible = true;
|
|
252
|
-
this.
|
|
253
|
-
let elStyle = this.listEl.style;
|
|
249
|
+
const elStyle = this.listEl.style;
|
|
254
250
|
elStyle.height = 'auto';
|
|
255
251
|
elStyle.minWidth = buttonWidth + 'px';
|
|
252
|
+
if (this.kupManager.dynamicPosition.isRegistered(this.listEl)) {
|
|
253
|
+
this.kupManager.dynamicPosition.changeAnchor(this.listEl, this.buttonEl ? this.buttonEl : this.dropdownEl);
|
|
254
|
+
}
|
|
255
|
+
else {
|
|
256
|
+
this.kupManager.dynamicPosition.register(this.listEl, this.buttonEl ? this.buttonEl : this.dropdownEl, 0, KupDynamicPositionPlacement.AUTO, true);
|
|
257
|
+
}
|
|
258
|
+
this.kupManager.dynamicPosition.start(this.listEl);
|
|
259
|
+
if (!this.clickCb) {
|
|
260
|
+
this.clickCb = {
|
|
261
|
+
cb: () => {
|
|
262
|
+
this.closeList();
|
|
263
|
+
},
|
|
264
|
+
el: this.listEl,
|
|
265
|
+
};
|
|
266
|
+
}
|
|
267
|
+
this.kupManager.addClickCallback(this.clickCb, true);
|
|
256
268
|
}
|
|
257
269
|
/**
|
|
258
270
|
* Closes the dropdown menu.
|
|
@@ -263,6 +275,7 @@ export class KupDropdownButton {
|
|
|
263
275
|
this.dropdownEl.classList.remove('toggled');
|
|
264
276
|
this.listEl.menuVisible = false;
|
|
265
277
|
this.kupManager.dynamicPosition.stop(this.listEl);
|
|
278
|
+
this.kupManager.removeClickCallback(this.clickCb);
|
|
266
279
|
}
|
|
267
280
|
/**
|
|
268
281
|
* Checks the consistency of the list.
|
|
@@ -297,7 +310,6 @@ export class KupDropdownButton {
|
|
|
297
310
|
this.buttonEl = root.querySelector('.dropdown-button__primary-action');
|
|
298
311
|
this.dropdownEl = root.querySelector('.dropdown-button__dropdown-action');
|
|
299
312
|
}
|
|
300
|
-
this.kupManager.dynamicPosition.register(this.listEl, this.wrapperEl);
|
|
301
313
|
this.kupManager.debug.logRender(this, true);
|
|
302
314
|
}
|
|
303
315
|
renderButtons() {
|
|
@@ -325,19 +337,18 @@ export class KupDropdownButton {
|
|
|
325
337
|
return buttons;
|
|
326
338
|
}
|
|
327
339
|
render() {
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
h("div", { id: componentWrapperId, ref: (el) => (this.wrapperEl = el) },
|
|
340
|
+
return (h(Host, null,
|
|
341
|
+
h("style", null, this.kupManager.theme.setKupStyle(this.rootElement)),
|
|
342
|
+
h("div", { id: componentWrapperId },
|
|
332
343
|
h("div", { class: "dropdown-button--wrapper" }, this.renderButtons()),
|
|
333
|
-
h("kup-list", Object.assign({}, this.data['kup-list'], { displayMode: this.displayMode, isMenu: true, "onkup-list-click": (e) => this.onKupItemClick(e), id: this.rootElement.id + '_list', ref: (el) => (this.listEl = el)
|
|
344
|
+
h("kup-list", Object.assign({}, this.data['kup-list'], { displayMode: this.displayMode, isMenu: true, "onkup-list-click": (e) => this.onKupItemClick(e), id: this.rootElement.id + '_list', ref: (el) => (this.listEl = el) })))));
|
|
334
345
|
}
|
|
335
346
|
disconnectedCallback() {
|
|
336
|
-
this.
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
this.kupManager.dynamicPosition.unregister(Array.prototype.slice.call(dynamicPositionElements));
|
|
347
|
+
if (this.listEl) {
|
|
348
|
+
this.kupManager.dynamicPosition.unregister([this.listEl]);
|
|
349
|
+
this.listEl.remove();
|
|
340
350
|
}
|
|
351
|
+
this.kupManager.theme.unregister(this);
|
|
341
352
|
}
|
|
342
353
|
static get is() { return "kup-dropdown-button"; }
|
|
343
354
|
static get encapsulation() { return "shadow"; }
|
|
@@ -360,11 +371,11 @@ export class KupDropdownButton {
|
|
|
360
371
|
"optional": false,
|
|
361
372
|
"docs": {
|
|
362
373
|
"tags": [{
|
|
363
|
-
"
|
|
364
|
-
"
|
|
374
|
+
"name": "default",
|
|
375
|
+
"text": "\"\""
|
|
365
376
|
}, {
|
|
366
|
-
"
|
|
367
|
-
"
|
|
377
|
+
"name": "see",
|
|
378
|
+
"text": "https://ketchup.smeup.com/ketchup-showcase/#/customization"
|
|
368
379
|
}],
|
|
369
380
|
"text": "Custom style of the component."
|
|
370
381
|
},
|
|
@@ -388,8 +399,8 @@ export class KupDropdownButton {
|
|
|
388
399
|
"optional": false,
|
|
389
400
|
"docs": {
|
|
390
401
|
"tags": [{
|
|
391
|
-
"
|
|
392
|
-
"
|
|
402
|
+
"name": "default",
|
|
403
|
+
"text": "null"
|
|
393
404
|
}],
|
|
394
405
|
"text": "Props of the sub-components."
|
|
395
406
|
},
|
|
@@ -407,8 +418,8 @@ export class KupDropdownButton {
|
|
|
407
418
|
"optional": false,
|
|
408
419
|
"docs": {
|
|
409
420
|
"tags": [{
|
|
410
|
-
"
|
|
411
|
-
"
|
|
421
|
+
"name": "default",
|
|
422
|
+
"text": "false"
|
|
412
423
|
}],
|
|
413
424
|
"text": "Defaults at false. When set to true, the component is disabled."
|
|
414
425
|
},
|
|
@@ -433,8 +444,8 @@ export class KupDropdownButton {
|
|
|
433
444
|
"optional": false,
|
|
434
445
|
"docs": {
|
|
435
446
|
"tags": [{
|
|
436
|
-
"
|
|
437
|
-
"
|
|
447
|
+
"name": "default",
|
|
448
|
+
"text": "ItemsDisplayMode.DESCRIPTION"
|
|
438
449
|
}],
|
|
439
450
|
"text": "Sets how to show the selected item value. Suported values: \"code\", \"description\", \"both\"."
|
|
440
451
|
},
|
|
@@ -454,8 +465,8 @@ export class KupDropdownButton {
|
|
|
454
465
|
"optional": false,
|
|
455
466
|
"docs": {
|
|
456
467
|
"tags": [{
|
|
457
|
-
"
|
|
458
|
-
"
|
|
468
|
+
"name": "default",
|
|
469
|
+
"text": "false"
|
|
459
470
|
}],
|
|
460
471
|
"text": "Default value is false. When set to true, the arrow dropdown button is the only button displayed."
|
|
461
472
|
},
|
|
@@ -475,8 +486,8 @@ export class KupDropdownButton {
|
|
|
475
486
|
"optional": false,
|
|
476
487
|
"docs": {
|
|
477
488
|
"tags": [{
|
|
478
|
-
"
|
|
479
|
-
"
|
|
489
|
+
"name": "default",
|
|
490
|
+
"text": "icon"
|
|
480
491
|
}],
|
|
481
492
|
"text": "Defaults at null. When set, the button will show this icon."
|
|
482
493
|
},
|
|
@@ -496,8 +507,8 @@ export class KupDropdownButton {
|
|
|
496
507
|
"optional": false,
|
|
497
508
|
"docs": {
|
|
498
509
|
"tags": [{
|
|
499
|
-
"
|
|
500
|
-
"
|
|
510
|
+
"name": "default",
|
|
511
|
+
"text": "\"\""
|
|
501
512
|
}],
|
|
502
513
|
"text": "Sets the initial value of the component."
|
|
503
514
|
},
|
|
@@ -517,8 +528,8 @@ export class KupDropdownButton {
|
|
|
517
528
|
"optional": false,
|
|
518
529
|
"docs": {
|
|
519
530
|
"tags": [{
|
|
520
|
-
"
|
|
521
|
-
"
|
|
531
|
+
"name": "default",
|
|
532
|
+
"text": "\"\""
|
|
522
533
|
}],
|
|
523
534
|
"text": "Defaults at null. When set, the button will show this text."
|
|
524
535
|
},
|
|
@@ -543,8 +554,8 @@ export class KupDropdownButton {
|
|
|
543
554
|
"optional": false,
|
|
544
555
|
"docs": {
|
|
545
556
|
"tags": [{
|
|
546
|
-
"
|
|
547
|
-
"
|
|
557
|
+
"name": "default",
|
|
558
|
+
"text": "ItemsDisplayMode.CODE"
|
|
548
559
|
}],
|
|
549
560
|
"text": "Sets how to return the selected item value. Suported values: \"code\", \"description\", \"both\"."
|
|
550
561
|
},
|
|
@@ -569,8 +580,8 @@ export class KupDropdownButton {
|
|
|
569
580
|
"optional": false,
|
|
570
581
|
"docs": {
|
|
571
582
|
"tags": [{
|
|
572
|
-
"
|
|
573
|
-
"
|
|
583
|
+
"name": "default",
|
|
584
|
+
"text": "FButtonStyling.RAISED"
|
|
574
585
|
}],
|
|
575
586
|
"text": "Defines the style of the button. Styles available: \"flat\", \"outlined\" and \"raised\" which is also the default."
|
|
576
587
|
},
|
|
@@ -590,8 +601,8 @@ export class KupDropdownButton {
|
|
|
590
601
|
"optional": false,
|
|
591
602
|
"docs": {
|
|
592
603
|
"tags": [{
|
|
593
|
-
"
|
|
594
|
-
"
|
|
604
|
+
"name": "default",
|
|
605
|
+
"text": "false"
|
|
595
606
|
}],
|
|
596
607
|
"text": "Defaults at null. When set, the icon will be shown after the text."
|
|
597
608
|
},
|
|
@@ -710,8 +721,8 @@ export class KupDropdownButton {
|
|
|
710
721
|
"signature": "(descriptions?: boolean) => Promise<GenericObject>",
|
|
711
722
|
"parameters": [{
|
|
712
723
|
"tags": [{
|
|
713
|
-
"
|
|
714
|
-
"
|
|
724
|
+
"name": "param",
|
|
725
|
+
"text": "descriptions - When provided and true, the result will be the list of props with their description."
|
|
715
726
|
}],
|
|
716
727
|
"text": "- When provided and true, the result will be the list of props with their description."
|
|
717
728
|
}],
|
|
@@ -774,8 +785,8 @@ export class KupDropdownButton {
|
|
|
774
785
|
"signature": "(props: GenericObject) => Promise<void>",
|
|
775
786
|
"parameters": [{
|
|
776
787
|
"tags": [{
|
|
777
|
-
"
|
|
778
|
-
"
|
|
788
|
+
"name": "param",
|
|
789
|
+
"text": "props - Object containing props that will be set to the component."
|
|
779
790
|
}],
|
|
780
791
|
"text": "- Object containing props that will be set to the component."
|
|
781
792
|
}],
|