atomicuilibrary 0.1.0 → 0.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/category-section.cjs.entry.js +2 -2
- package/dist/cjs/dom-BvBb0kmW.js +267 -0
- package/dist/cjs/exploration-project-tailwind.cjs.js +2 -2
- package/dist/cjs/{index-ClkOYpT8.js → index-C32cWsm5.js} +1 -1
- package/dist/cjs/layout-manager.cjs.entry.js +3 -3
- package/dist/cjs/library-card.cjs.entry.js +2 -2
- package/dist/cjs/lm-container_2.cjs.entry.js +2 -2
- package/dist/cjs/lm-panel_3.cjs.entry.js +4 -4
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/my-component.cjs.entry.js +1 -1
- package/dist/cjs/my-step.cjs.entry.js +2 -2
- package/dist/cjs/nav-bar.cjs.entry.js +4 -4
- package/dist/cjs/smart-step.cjs.entry.js +3 -3
- package/dist/cjs/timeline-item.cjs.entry.js +2 -2
- package/dist/cjs/ui-accordion_11.cjs.entry.js +132 -50
- package/dist/cjs/ui-advanced-data-table.cjs.entry.js +2 -2
- package/dist/cjs/ui-anchor.cjs.entry.js +2 -2
- package/dist/cjs/ui-animate-on-scroll.cjs.entry.js +3 -3
- package/dist/cjs/ui-aside-panel.cjs.entry.js +10 -11
- package/dist/cjs/ui-avatar-group_5.cjs.entry.js +1694 -0
- package/dist/cjs/ui-breadcrumb-item.cjs.entry.js +3 -3
- package/dist/cjs/ui-breadcrumb.cjs.entry.js +1 -1
- package/dist/cjs/ui-callout-banner.cjs.entry.js +2 -2
- package/dist/cjs/ui-card.cjs.entry.js +4 -3
- package/dist/cjs/ui-carousel.cjs.entry.js +1 -1
- package/dist/cjs/ui-checkbox.cjs.entry.js +3 -3
- package/dist/cjs/ui-code-editor.cjs.entry.js +2 -2
- package/dist/cjs/ui-code-preview.cjs.entry.js +2 -2
- package/dist/cjs/ui-color-picker.cjs.entry.js +256 -22
- package/dist/cjs/ui-command-palette.cjs.entry.js +1 -1
- package/dist/cjs/ui-dialog-box.cjs.entry.js +85 -11
- package/dist/cjs/ui-dialog-content.cjs.entry.js +1 -1
- package/dist/cjs/ui-dialog-footer_2.cjs.entry.js +1 -1
- package/dist/cjs/ui-divider.cjs.entry.js +1 -1
- package/dist/cjs/ui-dock-host.cjs.entry.js +4 -4
- package/dist/cjs/ui-dock.cjs.entry.js +2 -2
- package/dist/cjs/ui-drag-drop.cjs.entry.js +2 -2
- package/dist/cjs/ui-dropdown_2.cjs.entry.js +104 -34
- package/dist/cjs/ui-empty-state.cjs.entry.js +2 -2
- package/dist/cjs/ui-fab-item.cjs.entry.js +2 -2
- package/dist/cjs/ui-fab.cjs.entry.js +4 -4
- package/dist/cjs/ui-file-upload.cjs.entry.js +143 -44
- package/dist/cjs/ui-horizontal-nav.cjs.entry.js +2 -2
- package/dist/cjs/ui-knob.cjs.entry.js +1 -1
- package/dist/cjs/ui-label.cjs.entry.js +473 -0
- package/dist/cjs/ui-library.cjs.entry.js +2 -2
- package/dist/cjs/ui-list-group_2.cjs.entry.js +349 -60
- package/dist/cjs/ui-list.cjs.entry.js +76 -42
- package/dist/cjs/ui-masonry.cjs.entry.js +1 -1
- package/dist/cjs/ui-meter-group.cjs.entry.js +5 -4
- package/dist/cjs/ui-navigation-item.cjs.entry.js +5 -5
- package/dist/cjs/ui-number-input.cjs.entry.js +7 -3
- package/dist/cjs/ui-otp-input.cjs.entry.js +5 -5
- package/dist/cjs/{ui-pagination_4.cjs.entry.js → ui-pagination_3.cjs.entry.js} +35 -506
- package/dist/cjs/ui-panel.cjs.entry.js +1 -1
- package/dist/cjs/ui-pattern-input.cjs.entry.js +46 -11
- package/dist/cjs/ui-progress.cjs.entry.js +66 -9
- package/dist/cjs/ui-range-slider.cjs.entry.js +2 -2
- package/dist/cjs/ui-resizable-panel.cjs.entry.js +2 -2
- package/dist/cjs/ui-scroll-top.cjs.entry.js +1 -1
- package/dist/cjs/ui-smart-context-menu.cjs.entry.js +1 -1
- package/dist/cjs/ui-smart-stepper.cjs.entry.js +2 -2
- package/dist/cjs/ui-snackbar.cjs.entry.js +1 -1
- package/dist/cjs/ui-speed-dial.cjs.entry.js +1 -1
- package/dist/cjs/ui-speedometer.cjs.entry.js +28 -17
- package/dist/cjs/ui-splitter.cjs.entry.js +1 -1
- package/dist/cjs/ui-step.cjs.entry.js +2 -2
- package/dist/cjs/ui-stepper.cjs.entry.js +1 -1
- package/dist/cjs/ui-switch.cjs.entry.js +14 -13
- package/dist/cjs/ui-tabs.cjs.entry.js +2 -2
- package/dist/cjs/ui-tag.cjs.entry.js +58 -13
- package/dist/cjs/ui-timeline.cjs.entry.js +10 -2
- package/dist/cjs/ui-timer.cjs.entry.js +2 -2
- package/dist/cjs/ui-toolbar.cjs.entry.js +2 -2
- package/dist/cjs/ui-tooltip.cjs.entry.js +4 -4
- package/dist/cjs/ui-top-bar.cjs.entry.js +1 -1
- package/dist/cjs/ui-transfer-list.cjs.entry.js +6 -6
- package/dist/cjs/ui-tree.cjs.entry.js +30 -15
- package/dist/cjs/ui-workspace-manager.cjs.entry.js +2 -2
- package/dist/collection/assets/js/component-config.js +1 -0
- package/dist/collection/assets/js/demo-loader.js +2 -0
- package/dist/collection/assets/js/demos/about-demo.js +13 -13
- package/dist/collection/assets/js/demos/accordion-demo.js +66 -66
- package/dist/collection/assets/js/demos/advanced-data-table-demo.js +102 -102
- package/dist/collection/assets/js/demos/anchor-demo.js +27 -28
- package/dist/collection/assets/js/demos/animate-on-scroll-demo.js +12 -12
- package/dist/collection/assets/js/demos/aside-panel-demo.js +51 -51
- package/dist/collection/assets/js/demos/avatar-demo.js +433 -95
- package/dist/collection/assets/js/demos/badge-demo.js +51 -52
- package/dist/collection/assets/js/demos/breadcrumb-demo.js +7 -7
- package/dist/collection/assets/js/demos/button-demo.js +117 -107
- package/dist/collection/assets/js/demos/button-toggle-demo.js +199 -96
- package/dist/collection/assets/js/demos/callout-banner-demo.js +23 -23
- package/dist/collection/assets/js/demos/card-demo.js +23 -22
- package/dist/collection/assets/js/demos/carousel-demo.js +632 -360
- package/dist/collection/assets/js/demos/checkbox-demo.js +124 -7
- package/dist/collection/assets/js/demos/color-picker-demo.js +394 -100
- package/dist/collection/assets/js/demos/command-palette-demo.js +182 -65
- package/dist/collection/assets/js/demos/complex-form-demo.js +5 -5
- package/dist/collection/assets/js/demos/context-menu-demo.js +43 -43
- package/dist/collection/assets/js/demos/dialog-demo-temp.js +3 -3
- package/dist/collection/assets/js/demos/dialog-demo.js +336 -230
- package/dist/collection/assets/js/demos/divider-demo.js +59 -62
- package/dist/collection/assets/js/demos/dock-demo.js +12 -12
- package/dist/collection/assets/js/demos/dock-host-init.js +31 -31
- package/dist/collection/assets/js/demos/documentation-demo.js +34 -34
- package/dist/collection/assets/js/demos/drag-drop-demo.js +2 -2
- package/dist/collection/assets/js/demos/dropdown-demo.js +140 -136
- package/dist/collection/assets/js/demos/dropdown-subtitle-demo.js +2 -2
- package/dist/collection/assets/js/demos/empty-state-demo.js +294 -78
- package/dist/collection/assets/js/demos/fab-demo.js +95 -11
- package/dist/collection/assets/js/demos/file-upload-demo.js +641 -171
- package/dist/collection/assets/js/demos/home-components.js +2 -2
- package/dist/collection/assets/js/demos/horizontal-nav-demo.js +6 -6
- package/dist/collection/assets/js/demos/icon-demo.js +17 -17
- package/dist/collection/assets/js/demos/input-demo.js +147 -143
- package/dist/collection/assets/js/demos/knob-demo.js +29 -30
- package/dist/collection/assets/js/demos/label-demo.js +697 -0
- package/dist/collection/assets/js/demos/layout-manager-demo.js +55 -55
- package/dist/collection/assets/js/demos/list-demo.js +185 -122
- package/dist/collection/assets/js/demos/loader-demo.js +48 -48
- package/dist/collection/assets/js/demos/masonry-demo.js +568 -140
- package/dist/collection/assets/js/demos/meter-group-demo.js +14 -16
- package/dist/collection/assets/js/demos/multi-level-context-menu-demo.js +25 -25
- package/dist/collection/assets/js/demos/my-profile-demo.js +27 -27
- package/dist/collection/assets/js/demos/nav-bar-demo.js +1 -1
- package/dist/collection/assets/js/demos/number-input-demo.js +262 -211
- package/dist/collection/assets/js/demos/pagination-demo.js +29 -29
- package/dist/collection/assets/js/demos/panel-demo.js +18 -25
- package/dist/collection/assets/js/demos/pattern-input-demo.js +278 -40
- package/dist/collection/assets/js/demos/popover-demo.js +240 -149
- package/dist/collection/assets/js/demos/progress-demo.js +170 -156
- package/dist/collection/assets/js/demos/radio-demo.js +73 -12
- package/dist/collection/assets/js/demos/range-slider-demo.js +33 -33
- package/dist/collection/assets/js/demos/rating-demo.js +19 -19
- package/dist/collection/assets/js/demos/scroll-top-demo.js +8 -9
- package/dist/collection/assets/js/demos/skeleton-demo.js +110 -52
- package/dist/collection/assets/js/demos/skeleton-performance-demo.js +2 -2
- package/dist/collection/assets/js/demos/smart-dialog-demo.js +12 -12
- package/dist/collection/assets/js/demos/smart-menu-demo.js +17 -17
- package/dist/collection/assets/js/demos/snackbar-demo.js +53 -53
- package/dist/collection/assets/js/demos/speed-dial-demo.js +14 -14
- package/dist/collection/assets/js/demos/speedometer-demo.js +40 -32
- package/dist/collection/assets/js/demos/split-button-demo.js +2 -2
- package/dist/collection/assets/js/demos/splitter-demo.js +14 -14
- package/dist/collection/assets/js/demos/stack-demo.js +27 -27
- package/dist/collection/assets/js/demos/stepper-demo.js +49 -49
- package/dist/collection/assets/js/demos/switch-demo.js +561 -125
- package/dist/collection/assets/js/demos/tabs-demo.js +22 -22
- package/dist/collection/assets/js/demos/tag-demo.js +62 -62
- package/dist/collection/assets/js/demos/theme-selector-demo.js +27 -27
- package/dist/collection/assets/js/demos/timeline-demo.js +10 -10
- package/dist/collection/assets/js/demos/timeline-playground.js +2 -2
- package/dist/collection/assets/js/demos/timer-demo.js +10 -10
- package/dist/collection/assets/js/demos/toolbar-demo.js +17 -17
- package/dist/collection/assets/js/demos/tooltip-demo.js +92 -90
- package/dist/collection/assets/js/demos/top-bar-demo.js +6 -6
- package/dist/collection/assets/js/demos/transfer-list-demo.js +20 -20
- package/dist/collection/assets/js/demos/tree-demo.js +50 -66
- package/dist/collection/assets/js/demos/workspace-manager-demo.js +20 -20
- package/dist/collection/collection-manifest.json +1 -2
- package/dist/collection/components/accordion/accordion.css +275 -9
- package/dist/collection/components/accordion/accordion.js +7 -6
- package/dist/collection/components/advanced-data-table/advanced-data-table.css +5 -5
- package/dist/collection/components/advanced-data-table/advanced-data-table.js +2 -2
- package/dist/collection/components/anchor/anchor.css +1 -0
- package/dist/collection/components/animate-on-scroll/animate-on-scroll.js +2 -2
- package/dist/collection/components/aside-panel/aside-panel.css +2 -2
- package/dist/collection/components/aside-panel/aside-panel.js +10 -11
- package/dist/collection/components/avatar/avatar.css +6 -6
- package/dist/collection/components/avatar/avatar.js +63 -11
- package/dist/collection/components/badge/badge.css +27 -17
- package/dist/collection/components/badge/badge.js +6 -3
- package/dist/collection/components/breadcrumb/breadcrumb-item.js +2 -2
- package/dist/collection/components/button/button.css +1 -0
- package/dist/collection/components/button/button.js +3 -3
- package/dist/collection/components/button-toggle/button-toggle.js +2 -2
- package/dist/collection/components/button-toggle-group/button-toggle-group.css +161 -14
- package/dist/collection/components/button-toggle-group/button-toggle-group.js +2 -2
- package/dist/collection/components/callout-banner/callout-banner.css +75 -0
- package/dist/collection/components/callout-banner/callout-banner.js +1 -1
- package/dist/collection/components/card/card.css +221 -9
- package/dist/collection/components/card/card.js +3 -2
- package/dist/collection/components/checkbox/checkbox.js +3 -3
- package/dist/collection/components/code-editor/code-editor.js +1 -1
- package/dist/collection/components/code-preview/ui-code-preview.js +1 -1
- package/dist/collection/components/color-picker/color-picker.css +110 -6
- package/dist/collection/components/color-picker/color-picker.js +302 -26
- package/dist/collection/components/context-menu/context-menu.css +9 -9
- package/dist/collection/components/dialog-box/dialog-box.js +116 -14
- package/dist/collection/components/dialog-header/dialog-header.js +1 -1
- package/dist/collection/components/dock/dock.css +116 -3
- package/dist/collection/components/dock-host/ui-dock-host.js +3 -3
- package/dist/collection/components/drag-drop/drag-drop.js +1 -1
- package/dist/collection/components/dropdown/dropdown.css +101 -8
- package/dist/collection/components/dropdown/dropdown.js +94 -28
- package/dist/collection/components/empty-state/empty-state.js +1 -1
- package/dist/collection/components/fab/fab.css +87 -15
- package/dist/collection/components/fab/fab.js +3 -3
- package/dist/collection/components/fab-item/fab-item.js +1 -1
- package/dist/collection/components/file-upload/file-upload.css +1362 -31
- package/dist/collection/components/file-upload/file-upload.js +171 -50
- package/dist/collection/components/horizontal-nav/horizontal-nav.css +9 -9
- package/dist/collection/components/horizontal-nav/horizontal-nav.js +2 -2
- package/dist/collection/components/icon/icon.js +1 -1
- package/dist/collection/components/input/input.css +9 -0
- package/dist/collection/components/input/input.js +20 -9
- package/dist/collection/components/label/label.css +583 -0
- package/dist/collection/components/label/label.js +1669 -0
- package/dist/collection/components/layout-manager/layout-manager.js +1 -1
- package/dist/collection/components/layout-manager/lm-floating-window/lm-floating-window.js +1 -1
- package/dist/collection/components/layout-manager/lm-panel/lm-panel.js +1 -1
- package/dist/collection/components/layout-manager/lm-splitter/lm-splitter.js +1 -1
- package/dist/collection/components/layout-manager/lm-tabs/lm-tabs.js +1 -1
- package/dist/collection/components/library/category-section.js +1 -1
- package/dist/collection/components/library/library-card.js +1 -1
- package/dist/collection/components/library/library.js +1 -1
- package/dist/collection/components/list/list.css +46 -5
- package/dist/collection/components/list/list.js +76 -42
- package/dist/collection/components/list-group/list-group.css +0 -2
- package/dist/collection/components/list-group/list-group.js +11 -5
- package/dist/collection/components/list-item/list-item.css +403 -131
- package/dist/collection/components/list-item/list-item.js +345 -61
- package/dist/collection/components/loader/loader.css +1 -1
- package/dist/collection/components/loader/loader.js +2 -2
- package/dist/collection/components/meter-group/meter-group.css +5 -0
- package/dist/collection/components/meter-group/meter-group.js +3 -2
- package/dist/collection/components/my-step/my-step.js +1 -1
- package/dist/collection/components/nav-bar/nav-bar.css +4 -4
- package/dist/collection/components/nav-bar/nav-bar.js +6 -6
- package/dist/collection/components/number-input/number-input.js +6 -2
- package/dist/collection/components/otp-input/otp-input.css +10 -0
- package/dist/collection/components/otp-input/otp-input.js +3 -3
- package/dist/collection/components/pagination/pagination.js +1 -1
- package/dist/collection/components/pattern-input/pattern-input.css +0 -1
- package/dist/collection/components/pattern-input/pattern-input.js +44 -9
- package/dist/collection/components/popover/popover.css +35 -7
- package/dist/collection/components/popover/popover.js +64 -9
- package/dist/collection/components/progress/progress.css +176 -32
- package/dist/collection/components/progress/progress.js +66 -8
- package/dist/collection/components/radio/radio.css +2 -0
- package/dist/collection/components/radio/radio.js +2 -2
- package/dist/collection/components/range-slider/range-slider.css +284 -31
- package/dist/collection/components/range-slider/range-slider.js +5 -5
- package/dist/collection/components/rating/rating.css +151 -65
- package/dist/collection/components/rating/rating.js +31 -13
- package/dist/collection/components/resizable-panel/resizable-panel.js +1 -1
- package/dist/collection/components/skeleton/skeleton-loader.css +144 -44
- package/dist/collection/components/skeleton/skeleton-loader.js +11 -7
- package/dist/collection/components/smart-stepper/smart-step.js +2 -2
- package/dist/collection/components/smart-stepper/smart-stepper.js +1 -1
- package/dist/collection/components/speedometer/speedometer.css +26 -6
- package/dist/collection/components/speedometer/speedometer.js +26 -15
- package/dist/collection/components/stack/stack.js +2 -2
- package/dist/collection/components/step/step.js +1 -1
- package/dist/collection/components/stepper/stepper.js +1 -1
- package/dist/collection/components/switch/switch.css +367 -8
- package/dist/collection/components/switch/switch.js +13 -12
- package/dist/collection/components/tag/tag.css +38 -12
- package/dist/collection/components/tag/tag.js +58 -13
- package/dist/collection/components/tag-group/tag-group.css +0 -1
- package/dist/collection/components/tag-group/tag-group.js +3 -3
- package/dist/collection/components/timeline/timeline.css +380 -317
- package/dist/collection/components/timeline/timeline.js +8 -0
- package/dist/collection/components/timeline-item/timeline-item.js +1 -1
- package/dist/collection/components/timer/timer.js +1 -1
- package/dist/collection/components/toggle-group/toggle-group.css +7 -3
- package/dist/collection/components/toggle-group/toggle-group.js +7 -3
- package/dist/collection/components/toolbar/toolbar.js +1 -1
- package/dist/collection/components/tooltip/tooltip.js +4 -4
- package/dist/collection/components/top-bar/top-bar.js +2 -2
- package/dist/collection/components/transfer-list/transfer-list.css +13 -13
- package/dist/collection/components/transfer-list/transfer-list.js +4 -4
- package/dist/collection/components/tree/tree.css +35 -21
- package/dist/collection/components/tree/tree.js +28 -13
- package/dist/collection/components/ui-navigation-bar/navigation-bar/navigation-bar.css +34 -16
- package/dist/collection/components/ui-navigation-bar/navigation-bar/navigation-bar.js +46 -11
- package/dist/collection/components/ui-navigation-bar/navigation-item.css +7 -7
- package/dist/collection/components/ui-navigation-bar/navigation-item.js +3 -3
- package/dist/collection/utils/dom.js +151 -151
- package/dist/components/avatar-group.js +1 -1
- package/dist/components/avatar.js +1 -1
- package/dist/components/badge.js +1 -1
- package/dist/components/button-toggle.js +1 -1
- package/dist/components/button.js +1 -0
- package/dist/components/category-section2.js +1 -1
- package/dist/components/checkbox.js +1 -1
- package/dist/components/context-menu.js +1 -1
- package/dist/components/dialog-header.js +1 -1
- package/dist/components/dom.js +1 -1
- package/dist/components/dropdown.js +1 -1
- package/dist/components/icon.js +2 -2
- package/dist/components/input.js +1 -1
- package/dist/components/layout-manager.js +1 -1
- package/dist/components/library-card2.js +1 -1
- package/dist/components/list-group.js +1 -1
- package/dist/components/list-item.js +1 -1
- package/dist/components/lm-container2.js +1 -1
- package/dist/components/lm-floating-window2.js +1 -1
- package/dist/components/lm-panel2.js +1 -1
- package/dist/components/lm-splitter2.js +1 -1
- package/dist/components/lm-tabs2.js +1 -1
- package/dist/components/loader.js +1 -1
- package/dist/components/my-step.js +1 -1
- package/dist/components/nav-bar.js +1 -1
- package/dist/components/pagination.js +1 -1
- package/dist/components/popover.js +1 -0
- package/dist/components/radio.js +1 -1
- package/dist/components/range-slider.js +1 -1
- package/dist/components/rating.js +1 -1
- package/dist/components/resizable-panel.js +1 -1
- package/dist/components/skeleton-loader.js +1 -1
- package/dist/components/smart-step.js +1 -1
- package/dist/components/stack.js +1 -1
- package/dist/components/switch.js +1 -1
- package/dist/components/tag-group.js +1 -1
- package/dist/components/tag.js +1 -1
- package/dist/components/timeline-item.js +1 -1
- package/dist/components/toggle-group.js +1 -1
- package/dist/components/tooltip.js +1 -1
- package/dist/components/ui-accordion.js +1 -1
- package/dist/components/ui-advanced-data-table.js +1 -1
- package/dist/components/ui-anchor.js +1 -1
- package/dist/components/ui-animate-on-scroll.js +1 -1
- package/dist/components/ui-aside-panel.js +1 -1
- package/dist/components/ui-badge.js +1 -1
- package/dist/components/ui-breadcrumb-item.js +1 -1
- package/dist/components/ui-breadcrumb.js +1 -1
- package/dist/components/ui-button-toggle-group.js +1 -1
- package/dist/components/ui-button.js +1 -1
- package/dist/components/ui-callout-banner.js +1 -1
- package/dist/components/ui-card.js +1 -1
- package/dist/components/ui-carousel.js +1 -1
- package/dist/components/ui-code-editor.js +1 -1
- package/dist/components/ui-code-preview.js +1 -1
- package/dist/components/ui-color-picker.js +1 -1
- package/dist/components/ui-command-palette.js +1 -1
- package/dist/components/ui-dialog-box.js +1 -1
- package/dist/components/ui-dock-host.js +1 -1
- package/dist/components/ui-dock.js +1 -1
- package/dist/components/ui-drag-drop.js +1 -1
- package/dist/components/ui-empty-state.js +1 -1
- package/dist/components/ui-fab-item.js +1 -1
- package/dist/components/ui-fab.js +1 -1
- package/dist/components/ui-file-upload.js +1 -1
- package/dist/components/ui-horizontal-nav.js +1 -1
- package/dist/components/ui-knob.js +1 -1
- package/dist/components/{ui-color-controller.d.ts → ui-label.d.ts} +4 -4
- package/dist/components/ui-label.js +1 -0
- package/dist/components/ui-library.js +1 -1
- package/dist/components/ui-list.js +1 -1
- package/dist/components/ui-masonry.js +1 -1
- package/dist/components/ui-meter-group.js +1 -1
- package/dist/components/ui-navigation-bar.js +1 -1
- package/dist/components/ui-navigation-item.js +1 -1
- package/dist/components/ui-number-input.js +1 -1
- package/dist/components/ui-otp-input.js +1 -1
- package/dist/components/ui-panel.js +1 -1
- package/dist/components/ui-pattern-input.js +1 -1
- package/dist/components/ui-popover.js +1 -1
- package/dist/components/ui-progress.js +1 -1
- package/dist/components/ui-scroll-top.js +1 -1
- package/dist/components/ui-smart-stepper.js +1 -1
- package/dist/components/ui-snackbar.js +1 -1
- package/dist/components/ui-speed-dial.js +1 -1
- package/dist/components/ui-speedometer.js +1 -1
- package/dist/components/ui-splitter.js +1 -1
- package/dist/components/ui-step.js +1 -1
- package/dist/components/ui-stepper.js +1 -1
- package/dist/components/ui-tabs.js +1 -1
- package/dist/components/ui-timeline.js +1 -1
- package/dist/components/ui-timer.js +1 -1
- package/dist/components/ui-toolbar.js +1 -1
- package/dist/components/ui-top-bar.js +1 -1
- package/dist/components/ui-transfer-list.js +1 -1
- package/dist/components/ui-tree.js +1 -1
- package/dist/components/ui-workspace-manager.js +1 -1
- package/dist/esm/category-section.entry.js +2 -2
- package/dist/esm/dom-DFBTWhGw.js +262 -0
- package/dist/esm/exploration-project-tailwind.js +3 -3
- package/dist/esm/{index-DUsoYu9r.js → index-Dqu2zaH1.js} +1 -1
- package/dist/esm/layout-manager.entry.js +3 -3
- package/dist/esm/library-card.entry.js +2 -2
- package/dist/esm/lm-container_2.entry.js +2 -2
- package/dist/esm/lm-panel_3.entry.js +4 -4
- package/dist/esm/loader.js +3 -3
- package/dist/esm/my-component.entry.js +1 -1
- package/dist/esm/my-step.entry.js +2 -2
- package/dist/esm/nav-bar.entry.js +4 -4
- package/dist/esm/smart-step.entry.js +3 -3
- package/dist/esm/timeline-item.entry.js +2 -2
- package/dist/esm/ui-accordion_11.entry.js +132 -50
- package/dist/esm/ui-advanced-data-table.entry.js +2 -2
- package/dist/esm/ui-anchor.entry.js +2 -2
- package/dist/esm/ui-animate-on-scroll.entry.js +3 -3
- package/dist/esm/ui-aside-panel.entry.js +10 -11
- package/dist/esm/ui-avatar-group_5.entry.js +1688 -0
- package/dist/esm/ui-breadcrumb-item.entry.js +3 -3
- package/dist/esm/ui-breadcrumb.entry.js +1 -1
- package/dist/esm/ui-callout-banner.entry.js +2 -2
- package/dist/esm/ui-card.entry.js +4 -3
- package/dist/esm/ui-carousel.entry.js +1 -1
- package/dist/esm/ui-checkbox.entry.js +3 -3
- package/dist/esm/ui-code-editor.entry.js +2 -2
- package/dist/esm/ui-code-preview.entry.js +2 -2
- package/dist/esm/ui-color-picker.entry.js +256 -22
- package/dist/esm/ui-command-palette.entry.js +1 -1
- package/dist/esm/ui-dialog-box.entry.js +85 -11
- package/dist/esm/ui-dialog-content.entry.js +1 -1
- package/dist/esm/ui-dialog-footer_2.entry.js +1 -1
- package/dist/esm/ui-divider.entry.js +1 -1
- package/dist/esm/ui-dock-host.entry.js +4 -4
- package/dist/esm/ui-dock.entry.js +2 -2
- package/dist/esm/ui-drag-drop.entry.js +2 -2
- package/dist/esm/ui-dropdown_2.entry.js +104 -34
- package/dist/esm/ui-empty-state.entry.js +2 -2
- package/dist/esm/ui-fab-item.entry.js +2 -2
- package/dist/esm/ui-fab.entry.js +4 -4
- package/dist/esm/ui-file-upload.entry.js +143 -44
- package/dist/esm/ui-horizontal-nav.entry.js +2 -2
- package/dist/esm/ui-knob.entry.js +1 -1
- package/dist/esm/ui-label.entry.js +471 -0
- package/dist/esm/ui-library.entry.js +2 -2
- package/dist/esm/ui-list-group_2.entry.js +349 -60
- package/dist/esm/ui-list.entry.js +76 -42
- package/dist/esm/ui-masonry.entry.js +1 -1
- package/dist/esm/ui-meter-group.entry.js +5 -4
- package/dist/esm/ui-navigation-item.entry.js +5 -5
- package/dist/esm/ui-number-input.entry.js +7 -3
- package/dist/esm/ui-otp-input.entry.js +5 -5
- package/dist/esm/{ui-pagination_4.entry.js → ui-pagination_3.entry.js} +36 -506
- package/dist/esm/ui-panel.entry.js +1 -1
- package/dist/esm/ui-pattern-input.entry.js +46 -11
- package/dist/esm/ui-progress.entry.js +66 -9
- package/dist/esm/ui-range-slider.entry.js +2 -2
- package/dist/esm/ui-resizable-panel.entry.js +2 -2
- package/dist/esm/ui-scroll-top.entry.js +1 -1
- package/dist/esm/ui-smart-context-menu.entry.js +1 -1
- package/dist/esm/ui-smart-stepper.entry.js +2 -2
- package/dist/esm/ui-snackbar.entry.js +1 -1
- package/dist/esm/ui-speed-dial.entry.js +1 -1
- package/dist/esm/ui-speedometer.entry.js +28 -17
- package/dist/esm/ui-splitter.entry.js +1 -1
- package/dist/esm/ui-step.entry.js +2 -2
- package/dist/esm/ui-stepper.entry.js +1 -1
- package/dist/esm/ui-switch.entry.js +14 -13
- package/dist/esm/ui-tabs.entry.js +2 -2
- package/dist/esm/ui-tag.entry.js +58 -13
- package/dist/esm/ui-timeline.entry.js +10 -2
- package/dist/esm/ui-timer.entry.js +2 -2
- package/dist/esm/ui-toolbar.entry.js +2 -2
- package/dist/esm/ui-tooltip.entry.js +4 -4
- package/dist/esm/ui-top-bar.entry.js +1 -1
- package/dist/esm/ui-transfer-list.entry.js +6 -6
- package/dist/esm/ui-tree.entry.js +30 -15
- package/dist/esm/ui-workspace-manager.entry.js +2 -2
- package/dist/exploration-project-tailwind/exploration-project-tailwind.css +1 -1
- package/dist/exploration-project-tailwind/exploration-project-tailwind.esm.js +1 -1
- package/dist/exploration-project-tailwind/{p-7ba2258a.entry.js → p-024a299a.entry.js} +1 -1
- package/dist/exploration-project-tailwind/p-0a71896a.entry.js +1 -0
- package/dist/exploration-project-tailwind/{p-35296877.entry.js → p-0cdeb8d8.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-a42fdc33.entry.js → p-139cefbc.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-036d2a44.entry.js → p-198c83e5.entry.js} +1 -1
- package/dist/exploration-project-tailwind/p-236f47b1.entry.js +1 -0
- package/dist/exploration-project-tailwind/{p-81ebba11.entry.js → p-25530d0d.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-41cd6bf0.entry.js → p-298f2057.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-85e36111.entry.js → p-2b5a8e3e.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-e8c6d395.entry.js → p-2b6aa7bc.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-70bacda8.entry.js → p-2cfba753.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-cbee2607.entry.js → p-2fe22958.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-20ecc116.entry.js → p-3012e780.entry.js} +1 -1
- package/dist/exploration-project-tailwind/p-321c3f46.entry.js +1 -0
- package/dist/exploration-project-tailwind/{p-8b57fe4e.entry.js → p-3ab43638.entry.js} +1 -1
- package/dist/exploration-project-tailwind/p-3ad7e47e.entry.js +1 -0
- package/dist/exploration-project-tailwind/p-3b1ca826.entry.js +1 -0
- package/dist/exploration-project-tailwind/p-3ee8ddae.entry.js +1 -0
- package/dist/exploration-project-tailwind/{p-e22317c1.entry.js → p-3efb44c8.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-36861546.entry.js → p-42e3bc28.entry.js} +1 -1
- package/dist/exploration-project-tailwind/p-4360331a.entry.js +1 -0
- package/dist/exploration-project-tailwind/{p-2f961934.entry.js → p-443de32b.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-898dd0fa.entry.js → p-44d15451.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-4288c158.entry.js → p-46071679.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-a3f465d9.entry.js → p-497d6182.entry.js} +1 -1
- package/dist/exploration-project-tailwind/p-4ad8c55c.entry.js +1 -0
- package/dist/exploration-project-tailwind/{p-4aaa8e40.entry.js → p-4c46ac0b.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-98e91da5.entry.js → p-5042ddaa.entry.js} +1 -1
- package/dist/exploration-project-tailwind/p-60190e0e.entry.js +1 -0
- package/dist/exploration-project-tailwind/p-60530874.entry.js +1 -0
- package/dist/exploration-project-tailwind/{p-200241f8.entry.js → p-6108565d.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-fb4aca69.entry.js → p-62889cfe.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-c02284ea.entry.js → p-66f71613.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-7889bfc4.entry.js → p-67c440b2.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-c1c8ac28.entry.js → p-6f09503f.entry.js} +1 -1
- package/dist/exploration-project-tailwind/p-721bdbc3.entry.js +1 -0
- package/dist/exploration-project-tailwind/p-747b02ea.entry.js +1 -0
- package/dist/exploration-project-tailwind/{p-c6fd72e1.entry.js → p-754cb046.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-97af03cc.entry.js → p-7ed3bba2.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-d59da767.entry.js → p-864cebb7.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-4d73c143.entry.js → p-96ee3196.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-54965530.entry.js → p-97086868.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-d114a347.entry.js → p-9c5ced88.entry.js} +1 -1
- package/dist/exploration-project-tailwind/p-9d3044d4.entry.js +1 -0
- package/dist/exploration-project-tailwind/p-9e079be6.entry.js +1 -0
- package/dist/exploration-project-tailwind/{p-790556f0.entry.js → p-9e4c45f5.entry.js} +1 -1
- package/dist/exploration-project-tailwind/p-9eee7394.entry.js +1 -0
- package/dist/exploration-project-tailwind/p-DFBTWhGw.js +1 -0
- package/dist/exploration-project-tailwind/p-Dqu2zaH1.js +2 -0
- package/dist/exploration-project-tailwind/p-a7bdedc2.entry.js +1 -0
- package/dist/exploration-project-tailwind/{p-c87aeab6.entry.js → p-a8ec29de.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-6ddbee42.entry.js → p-ae617f62.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-05a436d3.entry.js → p-aef76052.entry.js} +1 -1
- package/dist/exploration-project-tailwind/p-b5f043fa.entry.js +1 -0
- package/dist/exploration-project-tailwind/p-b637b91b.entry.js +1 -0
- package/dist/exploration-project-tailwind/{p-d2e45c5e.entry.js → p-bc49a088.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-6b838549.entry.js → p-bd9a631f.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-e8ba0c95.entry.js → p-bf4b6767.entry.js} +1 -1
- package/dist/exploration-project-tailwind/p-c0fa400e.entry.js +1 -0
- package/dist/exploration-project-tailwind/{p-8578b616.entry.js → p-c4f3d990.entry.js} +1 -1
- package/dist/exploration-project-tailwind/p-c68ddb2f.entry.js +1 -0
- package/dist/exploration-project-tailwind/p-c79574c4.entry.js +1 -0
- package/dist/exploration-project-tailwind/p-c840098d.entry.js +1 -0
- package/dist/exploration-project-tailwind/{p-a1ad32a2.entry.js → p-c8663cbe.entry.js} +1 -1
- package/dist/exploration-project-tailwind/p-cb6e38a6.entry.js +1 -0
- package/dist/exploration-project-tailwind/p-cb9f2df1.entry.js +1 -0
- package/dist/exploration-project-tailwind/p-cfe8b696.entry.js +1 -0
- package/dist/exploration-project-tailwind/p-d00e13ae.entry.js +1 -0
- package/dist/exploration-project-tailwind/{p-c4ba7e52.entry.js → p-d01ed934.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-aa85ff78.entry.js → p-d4e57d94.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-ccb5c737.entry.js → p-d5bd3a3f.entry.js} +1 -1
- package/dist/exploration-project-tailwind/{p-45482d86.entry.js → p-d987cebe.entry.js} +1 -1
- package/dist/exploration-project-tailwind/p-d9ae77c0.entry.js +1 -0
- package/dist/exploration-project-tailwind/p-e9bae5c7.entry.js +1 -0
- package/dist/exploration-project-tailwind/p-f516fabc.entry.js +1 -0
- package/dist/exploration-project-tailwind/p-f68e2794.entry.js +1 -0
- package/dist/exploration-project-tailwind/{p-d30e24bd.entry.js → p-fa034f69.entry.js} +1 -1
- package/dist/types/components/aside-panel/aside-panel.d.ts +0 -3
- package/dist/types/components/avatar/avatar.d.ts +3 -0
- package/dist/types/components/avatar/types.d.ts +2 -0
- package/dist/types/components/badge/badge.d.ts +1 -0
- package/dist/types/components/color-picker/color-picker.d.ts +35 -2
- package/dist/types/components/dialog-box/dialog-box.d.ts +10 -0
- package/dist/types/components/dropdown/dropdown.d.ts +5 -0
- package/dist/types/components/file-upload/file-upload.d.ts +23 -6
- package/dist/types/components/label/label.d.ts +290 -0
- package/dist/types/components/label/types.d.ts +39 -0
- package/dist/types/components/list/list.d.ts +2 -1
- package/dist/types/components/list-group/list-group.d.ts +1 -0
- package/dist/types/components/list-item/list-item.d.ts +45 -17
- package/dist/types/components/pattern-input/pattern-input.d.ts +6 -0
- package/dist/types/components/popover/popover.d.ts +3 -0
- package/dist/types/components/progress/progress.d.ts +7 -0
- package/dist/types/components/range-slider/range-slider.d.ts +2 -2
- package/dist/types/components/rating/rating.d.ts +1 -0
- package/dist/types/components/skeleton/skeleton-loader.d.ts +1 -1
- package/dist/types/components/speedometer/speedometer.d.ts +1 -0
- package/dist/types/components/tag/tag.d.ts +4 -0
- package/dist/types/components/tree/tree.d.ts +1 -0
- package/dist/types/components/ui-navigation-bar/navigation-bar/navigation-bar.d.ts +1 -1
- package/dist/types/components.d.ts +742 -425
- package/dist/types/types/common.d.ts +2 -2
- package/dist/types/types/common.type.d.ts +2 -0
- package/dist/types/utils/dom.d.ts +4 -4
- package/package.json +4 -5
- package/dist/cjs/dom-oP1E4Rd3.js +0 -267
- package/dist/cjs/ui-avatar-group_3.cjs.entry.js +0 -634
- package/dist/cjs/ui-color-controller.cjs.entry.js +0 -150
- package/dist/cjs/ui-popover.cjs.entry.js +0 -517
- package/dist/cjs/ui-smart-location-dropdown.cjs.entry.js +0 -565
- package/dist/collection/components/color-controller/color-controller.css +0 -108
- package/dist/collection/components/color-controller/color-controller.js +0 -224
- package/dist/collection/components/smart-location-dropdown/smart-location-dropdown.css +0 -357
- package/dist/collection/components/smart-location-dropdown/smart-location-dropdown.js +0 -1190
- package/dist/components/ui-color-controller.js +0 -1
- package/dist/components/ui-smart-location-dropdown.d.ts +0 -11
- package/dist/components/ui-smart-location-dropdown.js +0 -1
- package/dist/esm/dom-BMFah5q3.js +0 -262
- package/dist/esm/ui-avatar-group_3.entry.js +0 -630
- package/dist/esm/ui-color-controller.entry.js +0 -148
- package/dist/esm/ui-popover.entry.js +0 -515
- package/dist/esm/ui-smart-location-dropdown.entry.js +0 -563
- package/dist/exploration-project-tailwind/p-06f0c679.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-0d31c9e9.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-148e81df.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-16bdd162.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-2347d21b.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-3d381f75.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-4417a9d8.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-44742ddd.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-47e2a7ee.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-4bef8bed.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-4efd63ce.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-5c835d90.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-61717490.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-717dad1f.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-71d95bb1.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-9bd14f69.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-9fc06ff0.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-BMFah5q3.js +0 -1
- package/dist/exploration-project-tailwind/p-DUsoYu9r.js +0 -2
- package/dist/exploration-project-tailwind/p-a27f59d2.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-a7b07cf4.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-bd89d060.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-c63c522e.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-c69dd43e.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-d6ce9721.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-dc92a343.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-debede45.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-e76318c7.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-ea51c5d8.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-eab5ad36.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-f0bc5d7e.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-f1beee72.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-f543392f.entry.js +0 -1
- package/dist/exploration-project-tailwind/p-f61cfb7c.entry.js +0 -1
- package/dist/types/components/color-controller/color-controller.d.ts +0 -24
- package/dist/types/components/smart-location-dropdown/smart-location-dropdown.d.ts +0 -119
- package/dist/types/components/smart-location-dropdown/types.d.ts +0 -37
- /package/dist/collection/components/{smart-location-dropdown → label}/types.js +0 -0
|
@@ -7,14 +7,19 @@ export class ColorPicker {
|
|
|
7
7
|
/** Show hex input field */
|
|
8
8
|
showHex = true;
|
|
9
9
|
/** Show RGB input field */
|
|
10
|
-
showRgb =
|
|
10
|
+
showRgb = false;
|
|
11
11
|
/** Show RGBA input field */
|
|
12
|
-
showRgba =
|
|
12
|
+
showRgba = false;
|
|
13
13
|
/** Show HSL input field */
|
|
14
|
-
showHsl =
|
|
14
|
+
showHsl = false;
|
|
15
15
|
/** Show HSLA input field */
|
|
16
|
-
showHsla =
|
|
17
|
-
|
|
16
|
+
showHsla = false; /**
|
|
17
|
+
* Comma-separated string or array of formats to show.
|
|
18
|
+
* Accepted values: 'hex', 'rgb', 'rgba', 'hsl', 'hsla'.
|
|
19
|
+
* When set, overrides the individual showHex/showRgb/showRgba/showHsl/showHsla flags.
|
|
20
|
+
* Examples: formats="hex,rgb" | :formats="['hex','hsl','hsla']"
|
|
21
|
+
*/
|
|
22
|
+
formats = ''; /** Show alpha channel slider */
|
|
18
23
|
showAlpha = false;
|
|
19
24
|
/** Show preset swatches */
|
|
20
25
|
showSwatches = true;
|
|
@@ -42,6 +47,8 @@ export class ColorPicker {
|
|
|
42
47
|
showGradient = false;
|
|
43
48
|
/** Display variant: full picker, hue slider only, or direct inputs */
|
|
44
49
|
variant = 'default';
|
|
50
|
+
/** Compact trigger — shows only the color swatch, no hex label or arrow */
|
|
51
|
+
compact = false;
|
|
45
52
|
el;
|
|
46
53
|
internals;
|
|
47
54
|
isOpen = false;
|
|
@@ -56,6 +63,10 @@ export class ColorPicker {
|
|
|
56
63
|
isGradientMode = false;
|
|
57
64
|
gradientStops = ['#3bf673', '#10b981'];
|
|
58
65
|
activeStopIndex = 0;
|
|
66
|
+
enabledFormatsSet = null;
|
|
67
|
+
dropdownStyle = {};
|
|
68
|
+
/** Prevents refineDropdownPlacement from running more than once per open cycle */
|
|
69
|
+
_placementRefined = false;
|
|
59
70
|
colorChange;
|
|
60
71
|
handleDocumentPointerDown = (event) => {
|
|
61
72
|
if (!this.isOpen || this.inline) {
|
|
@@ -92,13 +103,138 @@ export class ColorPicker {
|
|
|
92
103
|
}
|
|
93
104
|
}
|
|
94
105
|
}
|
|
106
|
+
handleFormatsChange() {
|
|
107
|
+
this.parseFormats();
|
|
108
|
+
}
|
|
109
|
+
handleIsOpenChange(open) {
|
|
110
|
+
if (open) {
|
|
111
|
+
// Sync input fields to the current color every time the popover opens
|
|
112
|
+
this.hexInput = this.getHexInputValue();
|
|
113
|
+
this.isInvalid = false;
|
|
114
|
+
this.invalidField = null;
|
|
115
|
+
}
|
|
116
|
+
else {
|
|
117
|
+
this.dropdownStyle = {};
|
|
118
|
+
this._placementRefined = false;
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
componentDidUpdate() {
|
|
122
|
+
// Run placement refinement exactly once after the dropdown is in the DOM
|
|
123
|
+
if (this.isOpen && !this._placementRefined) {
|
|
124
|
+
this._placementRefined = true;
|
|
125
|
+
this.refineDropdownPlacement();
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
/**
|
|
129
|
+
* Fast pre-compute using estimated panel height — called synchronously on
|
|
130
|
+
* click so the dropdown renders in the right place from the very first frame.
|
|
131
|
+
*/
|
|
132
|
+
preComputePlacement() {
|
|
133
|
+
const panelHeight = this.isHueVariant() ? 340 : this.isInputVariant() ? 320 : 580;
|
|
134
|
+
const panelWidth = this.isHueVariant() ? 280 : this.isInputVariant() ? 480 : 460;
|
|
135
|
+
this.dropdownStyle = this.buildPositionStyle(panelWidth, panelHeight);
|
|
136
|
+
}
|
|
137
|
+
/**
|
|
138
|
+
* Accurate refinement using the actual rendered dropdown dimensions.
|
|
139
|
+
* Runs once after the first render with the dropdown in the DOM.
|
|
140
|
+
*/
|
|
141
|
+
refineDropdownPlacement() {
|
|
142
|
+
const dropdown = this.el.shadowRoot?.querySelector('.cp-dropdown');
|
|
143
|
+
if (!dropdown)
|
|
144
|
+
return;
|
|
145
|
+
const panelWidth = this.isHueVariant() ? 280 : this.isInputVariant() ? 480 : 460;
|
|
146
|
+
const panelHeight = dropdown.scrollHeight || dropdown.offsetHeight || 580;
|
|
147
|
+
const newStyle = this.buildPositionStyle(panelWidth, panelHeight);
|
|
148
|
+
// Only write state if something changed (prevents an extra re-render)
|
|
149
|
+
const changed = Object.keys(newStyle).some(k => newStyle[k] !== this.dropdownStyle[k]);
|
|
150
|
+
if (changed)
|
|
151
|
+
this.dropdownStyle = newStyle;
|
|
152
|
+
}
|
|
153
|
+
/**
|
|
154
|
+
* Computes position: fixed coordinates so the dropdown is always fully
|
|
155
|
+
* visible within the viewport, preferring below but flipping upward as needed.
|
|
156
|
+
* Always constrains dimensions so the panel never extends past any viewport edge.
|
|
157
|
+
*/
|
|
158
|
+
buildPositionStyle(panelWidth, panelHeight) {
|
|
159
|
+
const hostRect = this.el.getBoundingClientRect();
|
|
160
|
+
// clientWidth/Height excludes scrollbar width — more accurate for layout
|
|
161
|
+
const vw = document.documentElement.clientWidth || window.innerWidth;
|
|
162
|
+
const vh = document.documentElement.clientHeight || window.innerHeight;
|
|
163
|
+
const gap = 6; // gap between trigger and panel
|
|
164
|
+
const edge = 8; // minimum clearance from every viewport edge
|
|
165
|
+
// ── Width — never exceed viewport ───────────────────────────────────────
|
|
166
|
+
const actualWidth = Math.min(panelWidth, vw - 2 * edge);
|
|
167
|
+
// ── Vertical ────────────────────────────────────────────────────────────
|
|
168
|
+
const spaceBelow = vh - hostRect.bottom - gap - edge;
|
|
169
|
+
const spaceAbove = hostRect.top - gap - edge;
|
|
170
|
+
let top;
|
|
171
|
+
let maxHeight;
|
|
172
|
+
if (spaceBelow >= panelHeight || spaceBelow >= spaceAbove) {
|
|
173
|
+
// Open downward
|
|
174
|
+
top = hostRect.bottom + gap;
|
|
175
|
+
maxHeight = Math.max(80, spaceBelow);
|
|
176
|
+
}
|
|
177
|
+
else {
|
|
178
|
+
// Open upward
|
|
179
|
+
maxHeight = Math.max(80, spaceAbove);
|
|
180
|
+
top = hostRect.top - gap - Math.min(panelHeight, maxHeight);
|
|
181
|
+
}
|
|
182
|
+
// Hard-clamp: top edge and bottom edge must stay inside viewport
|
|
183
|
+
const clampedHeight = Math.min(panelHeight, maxHeight);
|
|
184
|
+
top = Math.max(edge, Math.min(top, vh - clampedHeight - edge));
|
|
185
|
+
// ── Horizontal ──────────────────────────────────────────────────────────
|
|
186
|
+
let left = hostRect.left;
|
|
187
|
+
if (left + actualWidth > vw - edge) {
|
|
188
|
+
// Would overflow right: align right edges
|
|
189
|
+
left = hostRect.right - actualWidth;
|
|
190
|
+
}
|
|
191
|
+
// Hard-clamp: left edge and right edge must stay inside viewport
|
|
192
|
+
left = Math.max(edge, Math.min(left, vw - actualWidth - edge));
|
|
193
|
+
// ── Apply constraints only when content won't fit — otherwise render naturally ─
|
|
194
|
+
const style = {
|
|
195
|
+
top: `${Math.round(top)}px`,
|
|
196
|
+
left: `${Math.round(left)}px`,
|
|
197
|
+
width: `${Math.round(actualWidth)}px`,
|
|
198
|
+
};
|
|
199
|
+
if (panelHeight > maxHeight) {
|
|
200
|
+
// Content taller than available space — constrain and scroll
|
|
201
|
+
style['max-height'] = `${Math.round(clampedHeight)}px`;
|
|
202
|
+
style['overflow-y'] = 'auto';
|
|
203
|
+
style['overflow-x'] = 'hidden';
|
|
204
|
+
}
|
|
205
|
+
return style;
|
|
206
|
+
}
|
|
95
207
|
componentWillLoad() {
|
|
96
208
|
this.initializeInternals();
|
|
209
|
+
this.parseFormats();
|
|
97
210
|
this.syncValueToState(this.value);
|
|
98
211
|
this.value = this.getFormattedValue();
|
|
99
212
|
this.updateFormValue();
|
|
100
213
|
this.loadHistory();
|
|
101
214
|
}
|
|
215
|
+
parseFormats() {
|
|
216
|
+
if (!this.formats || (Array.isArray(this.formats) ? this.formats.length === 0 : this.formats.trim() === '')) {
|
|
217
|
+
this.enabledFormatsSet = null;
|
|
218
|
+
return;
|
|
219
|
+
}
|
|
220
|
+
const arr = Array.isArray(this.formats)
|
|
221
|
+
? this.formats
|
|
222
|
+
: this.formats.split(',');
|
|
223
|
+
const cleaned = arr.map(f => f.trim().toLowerCase()).filter(Boolean);
|
|
224
|
+
this.enabledFormatsSet = cleaned.length > 0 ? new Set(cleaned) : null;
|
|
225
|
+
}
|
|
226
|
+
isFormatEnabled(fmt) {
|
|
227
|
+
if (this.enabledFormatsSet)
|
|
228
|
+
return this.enabledFormatsSet.has(fmt);
|
|
229
|
+
switch (fmt) {
|
|
230
|
+
case 'hex': return this.showHex;
|
|
231
|
+
case 'rgb': return this.showRgb;
|
|
232
|
+
case 'rgba': return this.showRgba;
|
|
233
|
+
case 'hsl': return this.showHsl;
|
|
234
|
+
case 'hsla': return this.showHsla;
|
|
235
|
+
default: return false;
|
|
236
|
+
}
|
|
237
|
+
}
|
|
102
238
|
connectedCallback() {
|
|
103
239
|
document.addEventListener('pointerdown', this.handleDocumentPointerDown, true);
|
|
104
240
|
}
|
|
@@ -405,7 +541,32 @@ export class ColorPicker {
|
|
|
405
541
|
return this.colorNames[h] || 'Custom';
|
|
406
542
|
}
|
|
407
543
|
handleHexInput = (e) => {
|
|
408
|
-
|
|
544
|
+
const raw = String(e.detail ?? '').replace(/^#/, '').trim();
|
|
545
|
+
this.hexInput = raw;
|
|
546
|
+
if (raw.length === 0) {
|
|
547
|
+
// Empty — clear error, wait for user to finish
|
|
548
|
+
this.isInvalid = false;
|
|
549
|
+
this.invalidField = null;
|
|
550
|
+
return;
|
|
551
|
+
}
|
|
552
|
+
// When alpha is disabled only 3 and 6 char hex are valid.
|
|
553
|
+
// When alpha is enabled, 4 (shorthand + alpha) and 8 (RRGGBBAA) are also accepted.
|
|
554
|
+
const validLengths = this.showAlpha ? [3, 4, 6, 8] : [3, 6];
|
|
555
|
+
const maxLen = this.showAlpha ? 8 : 6;
|
|
556
|
+
if (validLengths.includes(raw.length)) {
|
|
557
|
+
// Complete hex length — validate and apply color
|
|
558
|
+
this.updateColorFromInput(raw, 'hex');
|
|
559
|
+
}
|
|
560
|
+
else if (raw.length > maxLen) {
|
|
561
|
+
// Exceeds maximum — always invalid
|
|
562
|
+
this.isInvalid = true;
|
|
563
|
+
this.invalidField = 'hex';
|
|
564
|
+
}
|
|
565
|
+
else {
|
|
566
|
+
// Incomplete — user is still typing, stay silent
|
|
567
|
+
this.isInvalid = false;
|
|
568
|
+
this.invalidField = null;
|
|
569
|
+
}
|
|
409
570
|
};
|
|
410
571
|
handleSwatch = (color) => {
|
|
411
572
|
const parsedColor = this.parseHex(color);
|
|
@@ -462,8 +623,14 @@ export class ColorPicker {
|
|
|
462
623
|
// Removed redundant saveHistory call
|
|
463
624
|
}
|
|
464
625
|
handleRgbChannelChange = (channel, event) => {
|
|
465
|
-
const
|
|
626
|
+
const raw = event.detail === null || event.detail === undefined ? '' : String(event.detail).trim();
|
|
466
627
|
const fieldKey = `rgb-${channel}`;
|
|
628
|
+
if (raw === '') {
|
|
629
|
+
// User cleared the field — clear error, wait for a valid value
|
|
630
|
+
this.setChannelValidation(null);
|
|
631
|
+
return;
|
|
632
|
+
}
|
|
633
|
+
const channelValue = this.parseChannelValue(raw);
|
|
467
634
|
if (channelValue === null || channelValue < 0 || channelValue > 255) {
|
|
468
635
|
this.setChannelValidation(fieldKey);
|
|
469
636
|
return;
|
|
@@ -474,8 +641,13 @@ export class ColorPicker {
|
|
|
474
641
|
this.applyRgbColor(currentRgb.r, currentRgb.g, currentRgb.b);
|
|
475
642
|
};
|
|
476
643
|
handleRgbaChannelChange = (channel, event) => {
|
|
477
|
-
const
|
|
644
|
+
const raw = event.detail === null || event.detail === undefined ? '' : String(event.detail).trim();
|
|
478
645
|
const fieldKey = `rgba-${channel}`;
|
|
646
|
+
if (raw === '') {
|
|
647
|
+
this.setChannelValidation(null);
|
|
648
|
+
return;
|
|
649
|
+
}
|
|
650
|
+
const channelValue = this.parseChannelValue(raw);
|
|
479
651
|
if (channelValue === null) {
|
|
480
652
|
this.setChannelValidation(fieldKey);
|
|
481
653
|
return;
|
|
@@ -500,9 +672,14 @@ export class ColorPicker {
|
|
|
500
672
|
this.applyRgbColor(currentRgb.r, currentRgb.g, currentRgb.b, nextAlpha);
|
|
501
673
|
};
|
|
502
674
|
handleHslChannelChange = (channel, event) => {
|
|
503
|
-
const
|
|
675
|
+
const raw = event.detail === null || event.detail === undefined ? '' : String(event.detail).trim();
|
|
504
676
|
const fieldKey = `hsl-${channel}`;
|
|
505
677
|
const limits = { h: 360, s: 100, l: 100 };
|
|
678
|
+
if (raw === '') {
|
|
679
|
+
this.setChannelValidation(null);
|
|
680
|
+
return;
|
|
681
|
+
}
|
|
682
|
+
const channelValue = this.parseChannelValue(raw);
|
|
506
683
|
if (channelValue === null || channelValue < 0 || channelValue > limits[channel]) {
|
|
507
684
|
this.setChannelValidation(fieldKey);
|
|
508
685
|
return;
|
|
@@ -517,8 +694,13 @@ export class ColorPicker {
|
|
|
517
694
|
this.applyHslColor(nextHsl.h, nextHsl.s, nextHsl.l);
|
|
518
695
|
};
|
|
519
696
|
handleHslaChannelChange = (channel, event) => {
|
|
520
|
-
const
|
|
697
|
+
const raw = event.detail === null || event.detail === undefined ? '' : String(event.detail).trim();
|
|
521
698
|
const fieldKey = `hsla-${channel}`;
|
|
699
|
+
if (raw === '') {
|
|
700
|
+
this.setChannelValidation(null);
|
|
701
|
+
return;
|
|
702
|
+
}
|
|
703
|
+
const channelValue = this.parseChannelValue(raw);
|
|
522
704
|
if (channelValue === null) {
|
|
523
705
|
this.setChannelValidation(fieldKey);
|
|
524
706
|
return;
|
|
@@ -560,7 +742,9 @@ export class ColorPicker {
|
|
|
560
742
|
return !this.isInputVariant();
|
|
561
743
|
}
|
|
562
744
|
showInputSection() {
|
|
563
|
-
return this.
|
|
745
|
+
return this.isFormatEnabled('hex') || this.isFormatEnabled('rgb') ||
|
|
746
|
+
this.isFormatEnabled('rgba') || this.isFormatEnabled('hsl') ||
|
|
747
|
+
this.isFormatEnabled('hsla') || this.isInputVariant();
|
|
564
748
|
}
|
|
565
749
|
getPanelClasses() {
|
|
566
750
|
return {
|
|
@@ -571,18 +755,50 @@ export class ColorPicker {
|
|
|
571
755
|
};
|
|
572
756
|
}
|
|
573
757
|
renderFormatInput(label, value, onInputChange, formatKey) {
|
|
574
|
-
|
|
758
|
+
const hasError = this.isInvalid && this.invalidField === formatKey;
|
|
759
|
+
const errMsg = this.getFieldError(formatKey);
|
|
760
|
+
return (h("div", { class: "cp-input-wrap cp-full cp-inline-row" }, h("span", { class: "cp-sm-label" }, label), h("div", { class: "cp-input-field-wrap" }, h("ui-input", { class: { 'cp-text-input': true, 'cp-input-error': hasError }, type: "text", value: value, prefixText: formatKey === 'hex' ? '#' : undefined, onInputChange: onInputChange, size: "sm" }), errMsg && h("span", { class: "cp-field-error" }, errMsg))));
|
|
575
761
|
}
|
|
576
762
|
renderChannelInput(fieldKey, label, value, min, max, step, onInputChange) {
|
|
577
763
|
return (h("div", { class: "cp-channel-field" }, h("span", { class: "cp-channel-label" }, label), h("ui-input", { class: { 'cp-text-input': true, 'cp-channel-input': true, 'cp-input-error': this.isInvalid && this.invalidField === fieldKey }, type: "number", min: min, max: max, step: step, value: value, onInputChange: onInputChange, size: "sm" })));
|
|
578
764
|
}
|
|
579
765
|
renderChannelGroup(label, columns, fields) {
|
|
580
|
-
|
|
766
|
+
const groupPrefix = label.toLowerCase() + '-';
|
|
767
|
+
const errMsg = this.getFieldError(groupPrefix);
|
|
768
|
+
return (h("div", { class: "cp-input-wrap cp-full cp-channel-group cp-inline-row" }, h("span", { class: "cp-sm-label" }, label), h("div", { class: "cp-channel-col" }, h("div", { class: { 'cp-channel-grid': true, 'cp-channel-grid-3': columns === 3, 'cp-channel-grid-4': columns === 4 } }, fields), errMsg && h("span", { class: "cp-field-error" }, errMsg))));
|
|
769
|
+
}
|
|
770
|
+
getFieldError(prefix) {
|
|
771
|
+
if (!this.isInvalid || !this.invalidField)
|
|
772
|
+
return '';
|
|
773
|
+
if (prefix === 'hex') {
|
|
774
|
+
if (this.invalidField !== 'hex')
|
|
775
|
+
return '';
|
|
776
|
+
return this.showAlpha
|
|
777
|
+
? 'Enter 3, 6, or 8 hex characters (e.g. FF0000 or FF0000FF for alpha)'
|
|
778
|
+
: 'Enter 3 or 6 hex characters (e.g. FF0000)';
|
|
779
|
+
}
|
|
780
|
+
if (!this.invalidField.startsWith(prefix))
|
|
781
|
+
return '';
|
|
782
|
+
if (this.invalidField.endsWith('-r'))
|
|
783
|
+
return 'Red (R) must be 0–255';
|
|
784
|
+
if (this.invalidField.endsWith('-g'))
|
|
785
|
+
return 'Green (G) must be 0–255';
|
|
786
|
+
if (this.invalidField.endsWith('-b'))
|
|
787
|
+
return 'Blue (B) must be 0–255';
|
|
788
|
+
if (this.invalidField.endsWith('-h'))
|
|
789
|
+
return 'Hue (H) must be 0–360';
|
|
790
|
+
if (this.invalidField.endsWith('-s'))
|
|
791
|
+
return 'Saturation (S) must be 0–100';
|
|
792
|
+
if (this.invalidField.endsWith('-l'))
|
|
793
|
+
return 'Lightness (L) must be 0–100';
|
|
794
|
+
if (this.invalidField.endsWith('-a'))
|
|
795
|
+
return 'Alpha (A) must be 0–1 (e.g. 0.5 = 50%)';
|
|
796
|
+
return 'Invalid value';
|
|
581
797
|
}
|
|
582
798
|
render() {
|
|
583
799
|
const currentColor = this.hslToHex(this.hue, this.saturation, this.lightness);
|
|
584
800
|
const swatches = this.getSwatches();
|
|
585
|
-
const picker = (h("div", { key: '
|
|
801
|
+
const picker = (h("div", { key: '947077dfe39fcd935bc97692b063b91d0fd06a9d', class: this.getPanelClasses() }, this.showGradientSurface() && (h("div", { key: 'a6c4878e2a6bca5c6b70af63da25dcd3457a8ec1', class: "cp-gradient", role: "slider", "aria-label": "Saturation and Lightness", "aria-valuemin": 0, "aria-valuemax": 100, "aria-valuenow": this.saturation, "aria-valuetext": `Saturation ${this.saturation}%, Lightness ${this.lightness}%`, tabindex: "0", onKeyDown: (e) => {
|
|
586
802
|
const step = e.shiftKey ? 10 : 1;
|
|
587
803
|
if (e.key === 'ArrowLeft') {
|
|
588
804
|
this.saturation = Math.max(0, this.saturation - step);
|
|
@@ -616,26 +832,38 @@ export class ColorPicker {
|
|
|
616
832
|
window.addEventListener('mousemove', onMove);
|
|
617
833
|
window.addEventListener('mouseup', onUp);
|
|
618
834
|
onMove(e);
|
|
619
|
-
} }, h("div", { key: '
|
|
835
|
+
} }, h("div", { key: '393bdcc90e400571ed7a51aaa25ac73868cd1c55', class: "cp-gradient-thumb", style: { left: `${this.saturation}%`, top: `${100 - this.lightness}%`, background: currentColor } }))), this.showSliderSection() && (h("div", { key: 'ede35ae4eb38c8b655c7f74075fcfaf8ee9cb7c0', class: "cp-row" }, h("div", { key: 'fda077df5270580b81cacd22b252d4acb9a770ed', class: "cp-preview", style: { background: currentColor } }), h("div", { key: 'f9f013ad09b24b5d42ac0d46fc60d473dcc699a1', class: "cp-sliders" }, h("ui-range-slider", { key: '1a10770920b3d793635794a857fae6653f926757', class: "cp-hue-slider", min: 0, max: 360, value: this.hue, onSliderChange: (e) => { this.hue = Number(e.detail); this.emitChange(); }, "aria-label": "Hue", showTooltip: false, showValue: false, hideRange: true, trackColor: "linear-gradient(to right, #f00 0%, #ff0 17%, #0f0 33%, #0ff 50%, #00f 67%, #f0f 83%, #f00 100%)" }), this.showAlpha && (h("ui-range-slider", { key: '2ba506ea2e7ce927cee0d3da96ac894629832e8e', class: "cp-alpha-slider", min: 0, max: 100, value: Math.round(this.alpha * 100), onSliderChange: (e) => { this.alpha = Number(e.detail) / 100; this.emitChange(); }, "aria-label": "Alpha", showTooltip: false, showValue: false, hideRange: true, trackColor: `linear-gradient(to right, transparent, ${this.hslToHex(this.hue, this.saturation, this.lightness)}), url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10'%3E%3Crect width='5' height='5' fill='%23ccc'/%3E%3Crect x='5' y='5' width='5' height='5' fill='%23ccc'/%3E%3C/svg%3E")` }))), this.showEyeDropper && 'EyeDropper' in window && (h("ui-button", { key: '5bca61232947d6ab735fc58e2a327849b947adda', variant: "ghost", onClick: () => this.handleEyeDropper(), ariaLabel: "Sample color from screen", icon: "pipette", iconLibrary: "lucide", iconOnly: true, size: "sm", title: "Sample color from screen" })))), this.showInputSection() && (h("div", { key: 'a7373dc01faaad4b1a29e2e58181121001355efc', class: "cp-inputs-grid" }, this.isFormatEnabled('hex') && (this.renderFormatInput('HEX', this.hexInput || this.getHexInputValue(), this.handleHexInput, 'hex')), this.isFormatEnabled('rgb') && (this.renderChannelGroup('RGB', 3, [
|
|
620
836
|
this.renderChannelInput('rgb-r', 'R', this.getRgbValues().r, 0, 255, 1, (event) => this.handleRgbChannelChange('r', event)),
|
|
621
837
|
this.renderChannelInput('rgb-g', 'G', this.getRgbValues().g, 0, 255, 1, (event) => this.handleRgbChannelChange('g', event)),
|
|
622
838
|
this.renderChannelInput('rgb-b', 'B', this.getRgbValues().b, 0, 255, 1, (event) => this.handleRgbChannelChange('b', event)),
|
|
623
|
-
])), this.
|
|
839
|
+
])), this.isFormatEnabled('rgba') && (this.renderChannelGroup('RGBA', 4, [
|
|
624
840
|
this.renderChannelInput('rgba-r', 'R', this.getRgbValues().r, 0, 255, 1, (event) => this.handleRgbaChannelChange('r', event)),
|
|
625
841
|
this.renderChannelInput('rgba-g', 'G', this.getRgbValues().g, 0, 255, 1, (event) => this.handleRgbaChannelChange('g', event)),
|
|
626
842
|
this.renderChannelInput('rgba-b', 'B', this.getRgbValues().b, 0, 255, 1, (event) => this.handleRgbaChannelChange('b', event)),
|
|
627
843
|
this.renderChannelInput('rgba-a', 'A', this.alpha, 0, 1, 0.01, (event) => this.handleRgbaChannelChange('a', event)),
|
|
628
|
-
])), this.
|
|
844
|
+
])), this.isFormatEnabled('hsl') && (this.renderChannelGroup('HSL', 3, [
|
|
629
845
|
this.renderChannelInput('hsl-h', 'H', this.hue, 0, 360, 1, (event) => this.handleHslChannelChange('h', event)),
|
|
630
846
|
this.renderChannelInput('hsl-s', 'S', this.saturation, 0, 100, 1, (event) => this.handleHslChannelChange('s', event)),
|
|
631
847
|
this.renderChannelInput('hsl-l', 'L', this.lightness, 0, 100, 1, (event) => this.handleHslChannelChange('l', event)),
|
|
632
|
-
])), this.
|
|
848
|
+
])), this.isFormatEnabled('hsla') && (this.renderChannelGroup('HSLA', 4, [
|
|
633
849
|
this.renderChannelInput('hsla-h', 'H', this.hue, 0, 360, 1, (event) => this.handleHslaChannelChange('h', event)),
|
|
634
850
|
this.renderChannelInput('hsla-s', 'S', this.saturation, 0, 100, 1, (event) => this.handleHslaChannelChange('s', event)),
|
|
635
851
|
this.renderChannelInput('hsla-l', 'L', this.lightness, 0, 100, 1, (event) => this.handleHslaChannelChange('l', event)),
|
|
636
852
|
this.renderChannelInput('hsla-a', 'A', this.alpha, 0, 1, 0.01, (event) => this.handleHslaChannelChange('a', event)),
|
|
637
|
-
])), this.showColorName && (h("div", { key: '
|
|
638
|
-
return (h(Host, { key: '
|
|
853
|
+
])), this.showColorName && (h("div", { key: '59c6affab34a5d5e8ac1bcbbbd6b596129fc8c01', class: "cp-input-wrap cp-full" }, h("span", { key: '416b9dd86cd1b26d166f79799d988a0f31c94c0f', class: "cp-sm-label" }, "NAME"), h("div", { key: '0580d021a17ef4791bb693e62ab81328b859e1e3', class: "cp-name-display" }, this.getColorName(currentColor)))), this.showGradient && (h("div", { key: '36c26bcd60a6670b5db602cb64c28eb472831b34', class: "cp-gradient-toggle-wrap cp-full" }, h("ui-button", { key: 'd66bcf4f0079ebb0a674c4f72d29eddeab535748', variant: 'outline', class: { 'cp-gradient-toggle': true, 'cp-active': this.isGradientMode }, onClick: this.toggleGradientMode, fullWidth: true, label: this.isGradientMode ? 'Disable Gradient' : 'Enable Gradient', size: "sm" }), this.isGradientMode && (h("div", { key: 'b5c68733d93b41955a8c869ec413306c4c249fa6', class: "cp-stop-selectors" }, this.gradientStops.map((stop, i) => (h("button", { type: "button", class: { 'cp-swatch': true, 'cp-swatch-active': this.activeStopIndex === i }, style: { 'background-color': stop, '--swatch-color': stop, 'border-radius': '50%' }, onClick: () => this.activeStopIndex = i, "aria-label": `Gradient stop ${i + 1}` }))))))))), !this.isInputVariant() && (this.showSwatches || (this.showRecent && this.recentColors.length > 0)) && (h("div", { key: '5d0c7ae9c61d21bbc61c825c024cfd4a18969729', class: "cp-swatches-section" }, h("div", { key: '561f17394b3e185dba5e0cd0ee33607b72853992', class: "cp-swatches" }, swatches.map(s => (h("button", { type: "button", style: { 'background-color': s, '--swatch-color': s }, class: { 'cp-swatch': true, 'cp-swatch-active': s.toLowerCase() === currentColor.toLowerCase() }, onClick: () => this.handleSwatch(s), title: this.getColorName(s), "aria-label": `Color ${this.getColorName(s)}` })))), this.showRecent && this.recentColors.length > 0 && (h("div", { key: '961bdc3ff4959328d340dad0eae2ea3ec8f0c6fd', class: "cp-history", style: { marginTop: '16px' } }, h("div", { key: '2b0e31318c0be810b2ab1e0f2fa058e838488ce7', class: "cp-sm-label", style: { marginBottom: '8px' } }, "RECENT"), h("div", { key: '72ace7d3af678623f196ace590027a3c8e8e4332', class: "cp-swatches" }, this.recentColors.map(s => (h("button", { type: "button", style: { 'background-color': s, '--swatch-color': s, 'border-radius': '50%' }, class: { 'cp-swatch': true, 'cp-history-swatch': true, 'cp-swatch-active': s.toLowerCase() === currentColor.toLowerCase() }, onClick: () => this.handleSwatch(s), title: this.getColorName(s), "aria-label": `Recent color ${this.getColorName(s)}` }))))))))));
|
|
854
|
+
return (h(Host, { key: 'ea389dfa80644128e47af4416097548127585782', class: `cp-size-${this.size} cp-variant-${this.variant}` }, this.label && h("label", { key: '36154620d4bfad250103eec666f4c6f7934edd14', class: "cp-label" }, this.label), this.inline ? picker : (h("div", { class: `cp-trigger-wrapper${this.compact ? ' cp-trigger-wrapper--compact' : ''}` }, this.compact ? (h("button", { class: { 'cp-trigger-compact': true, 'cp-disabled': this.disabled, 'cp-open': this.isOpen }, disabled: this.disabled, "aria-label": `Color picker, current color ${this.getFormattedValue()}`, onClick: () => {
|
|
855
|
+
if (this.disabled)
|
|
856
|
+
return;
|
|
857
|
+
if (!this.isOpen)
|
|
858
|
+
this.preComputePlacement();
|
|
859
|
+
this.isOpen = !this.isOpen;
|
|
860
|
+
} }, h("span", { class: "cp-trigger-compact-swatch", style: { background: this.value } }))) : (h("ui-button", { variant: "outline", disabled: this.disabled, onClick: () => {
|
|
861
|
+
if (this.disabled)
|
|
862
|
+
return;
|
|
863
|
+
if (!this.isOpen)
|
|
864
|
+
this.preComputePlacement();
|
|
865
|
+
this.isOpen = !this.isOpen;
|
|
866
|
+
}, fullWidth: true }, h("span", { class: "cp-trigger-swatch", style: { background: this.value } }), h("span", { class: "cp-trigger-value", style: { marginLeft: '8px', flex: '1', textAlign: 'left' } }, this.isGradientMode ? this.value : this.getFormattedValue()), h("ui-icon", { name: this.isOpen ? 'chevron-up' : 'chevron-down', size: "18", library: "lucide" }))), this.isOpen && (h("div", { class: "cp-dropdown", style: this.dropdownStyle }, picker))))));
|
|
639
867
|
}
|
|
640
868
|
static get is() { return "ui-color-picker"; }
|
|
641
869
|
static get encapsulation() { return "shadow"; }
|
|
@@ -730,7 +958,7 @@ export class ColorPicker {
|
|
|
730
958
|
"setter": false,
|
|
731
959
|
"reflect": false,
|
|
732
960
|
"attribute": "show-rgb",
|
|
733
|
-
"defaultValue": "
|
|
961
|
+
"defaultValue": "false"
|
|
734
962
|
},
|
|
735
963
|
"showRgba": {
|
|
736
964
|
"type": "boolean",
|
|
@@ -750,7 +978,7 @@ export class ColorPicker {
|
|
|
750
978
|
"setter": false,
|
|
751
979
|
"reflect": false,
|
|
752
980
|
"attribute": "show-rgba",
|
|
753
|
-
"defaultValue": "
|
|
981
|
+
"defaultValue": "false"
|
|
754
982
|
},
|
|
755
983
|
"showHsl": {
|
|
756
984
|
"type": "boolean",
|
|
@@ -770,7 +998,7 @@ export class ColorPicker {
|
|
|
770
998
|
"setter": false,
|
|
771
999
|
"reflect": false,
|
|
772
1000
|
"attribute": "show-hsl",
|
|
773
|
-
"defaultValue": "
|
|
1001
|
+
"defaultValue": "false"
|
|
774
1002
|
},
|
|
775
1003
|
"showHsla": {
|
|
776
1004
|
"type": "boolean",
|
|
@@ -790,7 +1018,27 @@ export class ColorPicker {
|
|
|
790
1018
|
"setter": false,
|
|
791
1019
|
"reflect": false,
|
|
792
1020
|
"attribute": "show-hsla",
|
|
793
|
-
"defaultValue": "
|
|
1021
|
+
"defaultValue": "false"
|
|
1022
|
+
},
|
|
1023
|
+
"formats": {
|
|
1024
|
+
"type": "string",
|
|
1025
|
+
"mutable": false,
|
|
1026
|
+
"complexType": {
|
|
1027
|
+
"original": "string | string[]",
|
|
1028
|
+
"resolved": "string | string[]",
|
|
1029
|
+
"references": {}
|
|
1030
|
+
},
|
|
1031
|
+
"required": false,
|
|
1032
|
+
"optional": false,
|
|
1033
|
+
"docs": {
|
|
1034
|
+
"tags": [],
|
|
1035
|
+
"text": ""
|
|
1036
|
+
},
|
|
1037
|
+
"getter": false,
|
|
1038
|
+
"setter": false,
|
|
1039
|
+
"reflect": false,
|
|
1040
|
+
"attribute": "formats",
|
|
1041
|
+
"defaultValue": "''"
|
|
794
1042
|
},
|
|
795
1043
|
"showAlpha": {
|
|
796
1044
|
"type": "boolean",
|
|
@@ -804,7 +1052,7 @@ export class ColorPicker {
|
|
|
804
1052
|
"optional": false,
|
|
805
1053
|
"docs": {
|
|
806
1054
|
"tags": [],
|
|
807
|
-
"text": "
|
|
1055
|
+
"text": ""
|
|
808
1056
|
},
|
|
809
1057
|
"getter": false,
|
|
810
1058
|
"setter": false,
|
|
@@ -1092,6 +1340,26 @@ export class ColorPicker {
|
|
|
1092
1340
|
"reflect": false,
|
|
1093
1341
|
"attribute": "variant",
|
|
1094
1342
|
"defaultValue": "'default'"
|
|
1343
|
+
},
|
|
1344
|
+
"compact": {
|
|
1345
|
+
"type": "boolean",
|
|
1346
|
+
"mutable": false,
|
|
1347
|
+
"complexType": {
|
|
1348
|
+
"original": "boolean",
|
|
1349
|
+
"resolved": "boolean",
|
|
1350
|
+
"references": {}
|
|
1351
|
+
},
|
|
1352
|
+
"required": false,
|
|
1353
|
+
"optional": false,
|
|
1354
|
+
"docs": {
|
|
1355
|
+
"tags": [],
|
|
1356
|
+
"text": "Compact trigger \u2014 shows only the color swatch, no hex label or arrow"
|
|
1357
|
+
},
|
|
1358
|
+
"getter": false,
|
|
1359
|
+
"setter": false,
|
|
1360
|
+
"reflect": false,
|
|
1361
|
+
"attribute": "compact",
|
|
1362
|
+
"defaultValue": "false"
|
|
1095
1363
|
}
|
|
1096
1364
|
};
|
|
1097
1365
|
}
|
|
@@ -1108,7 +1376,9 @@ export class ColorPicker {
|
|
|
1108
1376
|
"recentColors": {},
|
|
1109
1377
|
"isGradientMode": {},
|
|
1110
1378
|
"gradientStops": {},
|
|
1111
|
-
"activeStopIndex": {}
|
|
1379
|
+
"activeStopIndex": {},
|
|
1380
|
+
"enabledFormatsSet": {},
|
|
1381
|
+
"dropdownStyle": {}
|
|
1112
1382
|
};
|
|
1113
1383
|
}
|
|
1114
1384
|
static get events() {
|
|
@@ -1132,6 +1402,12 @@ export class ColorPicker {
|
|
|
1132
1402
|
static get elementRef() { return "el"; }
|
|
1133
1403
|
static get watchers() {
|
|
1134
1404
|
return [{
|
|
1405
|
+
"propName": "formats",
|
|
1406
|
+
"methodName": "handleFormatsChange"
|
|
1407
|
+
}, {
|
|
1408
|
+
"propName": "isOpen",
|
|
1409
|
+
"methodName": "handleIsOpenChange"
|
|
1410
|
+
}, {
|
|
1135
1411
|
"propName": "value",
|
|
1136
1412
|
"methodName": "valueChanged"
|
|
1137
1413
|
}];
|
|
@@ -33,9 +33,9 @@
|
|
|
33
33
|
--ctx-fg: var(--text-primary, #000000);
|
|
34
34
|
--ctx-border: var(--border-default, #d9d9d9);
|
|
35
35
|
--ctx-hover: var(--bg-secondary, #e6e6e6);
|
|
36
|
-
--ctx-active: rgba(0, 138, 22, 0.08);
|
|
37
|
-
--ctx-active-fg: var(--color-
|
|
38
|
-
--ctx-active-icon: var(--color-
|
|
36
|
+
--ctx-active: var(--color-primary-subtle, rgba(0, 138, 22, 0.08));
|
|
37
|
+
--ctx-active-fg: var(--color-primary, #008a16);
|
|
38
|
+
--ctx-active-icon: var(--color-primary, #008a16);
|
|
39
39
|
/* Force Opaque Background for accessibility & occlusion */
|
|
40
40
|
background-color: var(--ctx-bg, #ffffff) !important;
|
|
41
41
|
background-image: none !important;
|
|
@@ -101,11 +101,11 @@ html[data-theme=dark] :host .ctx-menu {
|
|
|
101
101
|
/* Portal Consistent Dark Theme */
|
|
102
102
|
--ctx-bg: var(--bg-primary, #1e293b);
|
|
103
103
|
--ctx-fg: var(--text-primary, #e2e8f0);
|
|
104
|
-
--ctx-border: var(--
|
|
105
|
-
--ctx-hover: var(--
|
|
106
|
-
--ctx-active: rgba(0, 138, 22, 0.15);
|
|
107
|
-
--ctx-active-fg: var(--color-
|
|
108
|
-
--ctx-active-icon: var(--color-
|
|
104
|
+
--ctx-border: var(--color-primary, #334155);
|
|
105
|
+
--ctx-hover: var(--color-primary, #334155);
|
|
106
|
+
--ctx-active: var(--color-primary-subtle, rgba(0, 138, 22, 0.15));
|
|
107
|
+
--ctx-active-fg: var(--color-primary, #008a16);
|
|
108
|
+
--ctx-active-icon: var(--color-primary, #008a16);
|
|
109
109
|
box-shadow: 0 12px 28px rgba(0, 0, 0, 0.4), 0 8px 10px rgba(0, 0, 0, 0.2);
|
|
110
110
|
}
|
|
111
111
|
|
|
@@ -195,7 +195,7 @@ html[data-theme=dark] :host .ctx-list::-webkit-scrollbar-thumb:hover {
|
|
|
195
195
|
transform: translateY(-50%);
|
|
196
196
|
width: 4px;
|
|
197
197
|
height: 24px;
|
|
198
|
-
background-color: var(--color-
|
|
198
|
+
background-color: var(--color-primary, #008a16);
|
|
199
199
|
border-radius: 4px;
|
|
200
200
|
}
|
|
201
201
|
|