@prolibu-suite/cobalt-core 0.4.0 → 0.5.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/custom-elements.json +317 -153
- package/dist/cjs/co-accordion.cjs.entry.js +4 -4
- package/dist/cjs/co-app-shell.cjs.entry.js +3 -3
- package/dist/cjs/co-autocomplete.cjs.entry.js +38 -73
- package/dist/cjs/co-avatar-group.cjs.entry.js +3 -3
- package/dist/cjs/co-avatar.cjs.entry.js +2 -2
- package/dist/cjs/co-badge.cjs.entry.js +2 -2
- package/dist/cjs/co-bottom-sheet.cjs.entry.js +4 -4
- package/dist/cjs/co-breadcrumb-item.cjs.entry.js +3 -3
- package/dist/cjs/co-breadcrumb.cjs.entry.js +2 -2
- package/dist/cjs/co-button-group.cjs.entry.js +3 -3
- package/dist/cjs/co-button.cjs.entry.js +3 -3
- package/dist/cjs/co-calendar-month.cjs.entry.js +2 -2
- package/dist/cjs/co-calendar_3.cjs.entry.js +19 -14
- package/dist/cjs/co-card.cjs.entry.js +3 -3
- package/dist/cjs/co-checkbox-group.cjs.entry.js +4 -4
- package/dist/cjs/co-checkbox.cjs.entry.js +4 -4
- package/dist/cjs/co-chip_2.cjs.entry.js +485 -0
- package/dist/cjs/co-color-picker.cjs.entry.js +4 -4
- package/dist/cjs/co-column-picker.cjs.entry.js +3 -3
- package/dist/cjs/co-combobox.cjs.entry.js +51 -82
- package/dist/cjs/co-command-search.cjs.entry.js +20 -59
- package/dist/cjs/co-data-table-pagination.cjs.entry.js +5 -5
- package/dist/cjs/co-data-table.cjs.entry.js +54 -5
- package/dist/cjs/co-date-picker.cjs.entry.js +2 -2
- package/dist/cjs/co-date-range-picker.cjs.entry.js +3 -3
- package/dist/cjs/co-date-range.cjs.entry.js +2 -2
- package/dist/cjs/co-drive-card.cjs.entry.js +2 -2
- package/dist/cjs/co-drop-zone.cjs.entry.js +2 -2
- package/dist/cjs/co-empty-state.cjs.entry.js +4 -4
- package/dist/cjs/co-event-calendar.cjs.entry.js +3 -3
- package/dist/cjs/co-fab.cjs.entry.js +5 -5
- package/dist/cjs/co-file-field.cjs.entry.js +7 -7
- package/dist/cjs/co-file-type-tile.cjs.entry.js +3 -3
- package/dist/cjs/co-helper-text.cjs.entry.js +3 -3
- package/dist/cjs/co-icon-button.cjs.entry.js +2 -2
- package/dist/cjs/co-icon.cjs.entry.js +3 -3
- package/dist/cjs/co-input.cjs.entry.js +3 -3
- package/dist/cjs/co-json-field.cjs.entry.js +5 -5
- package/dist/cjs/co-lightbox.cjs.entry.js +6 -6
- package/dist/cjs/co-list-footer.cjs.entry.js +2 -2
- package/dist/cjs/co-list-item.cjs.entry.js +5 -5
- package/dist/cjs/co-loader.cjs.entry.js +1 -1
- package/dist/cjs/co-media-thumb.cjs.entry.js +3 -3
- package/dist/cjs/co-menu-divider.cjs.entry.js +2 -2
- package/dist/cjs/co-menu-item.cjs.entry.js +2 -2
- package/dist/cjs/co-menu.cjs.entry.js +2 -2
- package/dist/cjs/co-modal.cjs.entry.js +3 -3
- package/dist/cjs/co-navbar.cjs.entry.js +3 -3
- package/dist/cjs/co-number-field.cjs.entry.js +5 -5
- package/dist/cjs/co-overlay.cjs.entry.js +2 -2
- package/dist/cjs/co-page-header.cjs.entry.js +2 -2
- package/dist/cjs/co-phone-field.cjs.entry.js +4 -4
- package/dist/cjs/co-popover.cjs.entry.js +12 -3
- package/dist/cjs/co-progress-bar.cjs.entry.js +4 -4
- package/dist/cjs/co-progress-circle.cjs.entry.js +3 -3
- package/dist/cjs/co-radio-group.cjs.entry.js +4 -4
- package/dist/cjs/co-radio.cjs.entry.js +4 -4
- package/dist/cjs/co-rating.cjs.entry.js +4 -4
- package/dist/cjs/co-ref-field.cjs.entry.js +31 -135
- package/dist/cjs/co-rich-text-editor.cjs.entry.js +4 -4
- package/dist/cjs/co-rich-text-toolbar.cjs.entry.js +1 -1
- package/dist/cjs/co-rich-text-viewer.cjs.entry.js +1 -1
- package/dist/cjs/co-row.cjs.entry.js +3 -3
- package/dist/cjs/co-segmented-bar.cjs.entry.js +3 -3
- package/dist/cjs/co-select.cjs.entry.js +7 -7
- package/dist/cjs/co-separator.cjs.entry.js +2 -2
- package/dist/cjs/co-sidebar-nav.cjs.entry.js +10 -8
- package/dist/cjs/co-sidebar.cjs.entry.js +3 -3
- package/dist/cjs/co-skeleton.cjs.entry.js +2 -2
- package/dist/cjs/co-slider.cjs.entry.js +3 -3
- package/dist/cjs/co-switch.cjs.entry.js +6 -6
- package/dist/cjs/co-tab-group.cjs.entry.js +10 -4
- package/dist/cjs/co-tab.cjs.entry.js +5 -5
- package/dist/cjs/co-tags-field.cjs.entry.js +8 -8
- package/dist/cjs/co-textarea.cjs.entry.js +6 -6
- package/dist/cjs/co-toast.cjs.entry.js +3 -3
- package/dist/cjs/co-toggle-button-group.cjs.entry.js +3 -3
- package/dist/cjs/co-toggle-button.cjs.entry.js +3 -3
- package/dist/cjs/co-tooltip.cjs.entry.js +3 -3
- package/dist/cjs/co-transfer-list.cjs.entry.js +3 -3
- package/dist/cjs/co-video.cjs.entry.js +4 -4
- package/dist/cjs/cobalt.cjs.js +2 -2
- package/dist/cjs/{fieldChip-DtYUP0VZ.js → fieldChip-D8YJCyQF.js} +1 -1
- package/dist/cjs/{index-NNvye1ul.js → index-DxEFsH_t.js} +9 -13
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/{requiredMark-DyjZzUCd.js → requiredMark-B3pKyqYI.js} +1 -1
- package/dist/cobalt/cobalt.css +1 -1
- package/dist/cobalt/cobalt.esm.js +1 -1
- package/dist/cobalt/{p-69289e82.entry.js → p-002e5beb.entry.js} +1 -1
- package/dist/cobalt/{p-c23a2ff6.entry.js → p-02c5a9a9.entry.js} +1 -1
- package/dist/cobalt/{p-9310739f.entry.js → p-075eed3d.entry.js} +1 -1
- package/dist/cobalt/p-0c0621a7.entry.js +1 -0
- package/dist/cobalt/{p-20c68308.entry.js → p-0d6a562d.entry.js} +1 -1
- package/dist/cobalt/p-0d7536a8.entry.js +1 -0
- package/dist/cobalt/{p-f72f0e38.entry.js → p-13fc9c8a.entry.js} +1 -1
- package/dist/cobalt/{p-39a29bbb.entry.js → p-14d4c5c7.entry.js} +1 -1
- package/dist/cobalt/{p-96baec0e.entry.js → p-1681ce1d.entry.js} +1 -1
- package/dist/cobalt/{p-593fd213.entry.js → p-1726ce07.entry.js} +1 -1
- package/dist/cobalt/{p-7d9f2021.entry.js → p-20ba59a2.entry.js} +1 -1
- package/dist/cobalt/{p-35c63fdc.entry.js → p-2d1cbd7f.entry.js} +1 -1
- package/dist/cobalt/{p-7040e4c5.entry.js → p-373cd08e.entry.js} +1 -1
- package/dist/cobalt/{p-4aeefe3f.entry.js → p-3f06d373.entry.js} +1 -1
- package/dist/cobalt/{p-8fdf2163.entry.js → p-3f68fd2e.entry.js} +1 -1
- package/dist/cobalt/{p-ca108c6d.entry.js → p-47a2dd67.entry.js} +1 -1
- package/dist/cobalt/{p-328f0470.entry.js → p-495c9b99.entry.js} +1 -1
- package/dist/cobalt/p-4a075257.entry.js +1 -0
- package/dist/cobalt/{p-aa1ad9fa.entry.js → p-5647ca9d.entry.js} +1 -1
- package/dist/cobalt/{p-3d07e4a9.entry.js → p-5b31d45b.entry.js} +1 -1
- package/dist/cobalt/p-5c3101b5.entry.js +1 -0
- package/dist/cobalt/{p-0e1afdea.entry.js → p-5c43d30e.entry.js} +1 -1
- package/dist/cobalt/{p-c85a6a9e.entry.js → p-5e9a9caf.entry.js} +1 -1
- package/dist/cobalt/{p-b4dcc260.entry.js → p-5edd0d3f.entry.js} +1 -1
- package/dist/cobalt/{p-d7c9cf93.entry.js → p-627d2d1a.entry.js} +1 -1
- package/dist/cobalt/{p-e8e752f9.entry.js → p-6911a034.entry.js} +1 -1
- package/dist/cobalt/{p-1388eac6.entry.js → p-6ad1625a.entry.js} +1 -1
- package/dist/cobalt/{p-c682453a.entry.js → p-70f70e02.entry.js} +1 -1
- package/dist/cobalt/p-73b30ebb.entry.js +1 -0
- package/dist/cobalt/p-771bc8fe.entry.js +1 -0
- package/dist/cobalt/p-7780ddb5.entry.js +1 -0
- package/dist/cobalt/{p-e55fb916.entry.js → p-77d01b39.entry.js} +1 -1
- package/dist/cobalt/p-7FZXeBK4.js +1 -0
- package/dist/cobalt/{p-6a3ed174.entry.js → p-7a3fb93b.entry.js} +1 -1
- package/dist/cobalt/{p-860a685f.entry.js → p-809015dd.entry.js} +1 -1
- package/dist/cobalt/{p-d403d9c4.entry.js → p-8128e84a.entry.js} +1 -1
- package/dist/cobalt/p-81cfd951.entry.js +1 -0
- package/dist/cobalt/p-82ce1178.entry.js +1 -0
- package/dist/cobalt/{p-dd03c00b.entry.js → p-85eed52c.entry.js} +1 -1
- package/dist/cobalt/p-86d4e016.entry.js +1 -0
- package/dist/cobalt/{p-3dd6b57b.entry.js → p-86e60cfa.entry.js} +1 -1
- package/dist/cobalt/p-8a9ed2da.entry.js +1 -0
- package/dist/cobalt/{p-fb86cdb9.entry.js → p-8dfb6886.entry.js} +1 -1
- package/dist/cobalt/{p-d4086c34.entry.js → p-8e823c15.entry.js} +1 -1
- package/dist/cobalt/{p-08519a7c.entry.js → p-9a587867.entry.js} +1 -1
- package/dist/cobalt/{p-376c43b8.entry.js → p-9c6ca902.entry.js} +1 -1
- package/dist/cobalt/{p-bae82095.entry.js → p-9c873a6a.entry.js} +1 -1
- package/dist/cobalt/{p-BxzuCRMr.js → p-BAA4ln31.js} +1 -1
- package/dist/cobalt/{p-b8200f7f.entry.js → p-a6900010.entry.js} +1 -1
- package/dist/cobalt/p-a9afbaa6.entry.js +1 -0
- package/dist/cobalt/{p-2d4e1ca8.entry.js → p-aa20ffca.entry.js} +1 -1
- package/dist/cobalt/{p-e93644cb.entry.js → p-ac5df270.entry.js} +1 -1
- package/dist/cobalt/{p-8ae5da0c.entry.js → p-af4cb263.entry.js} +1 -1
- package/dist/cobalt/p-b1197c08.entry.js +1 -0
- package/dist/cobalt/p-b4bed98b.entry.js +1 -0
- package/dist/cobalt/{p-1cecb9e1.entry.js → p-b8ec0cc1.entry.js} +1 -1
- package/dist/cobalt/p-ba66584f.entry.js +1 -0
- package/dist/cobalt/{p-ff6be242.entry.js → p-bb534985.entry.js} +1 -1
- package/dist/cobalt/{p-6f12e721.entry.js → p-c0f39ddd.entry.js} +1 -1
- package/dist/cobalt/{p-804d025f.entry.js → p-c1e53e4c.entry.js} +1 -1
- package/dist/cobalt/p-c2e2eee9.entry.js +1 -0
- package/dist/cobalt/{p-af0495d8.entry.js → p-c3462def.entry.js} +1 -1
- package/dist/cobalt/p-c6fedc59.entry.js +1 -0
- package/dist/cobalt/{p-f6b93f17.entry.js → p-c750b2d2.entry.js} +1 -1
- package/dist/cobalt/{p-363a5262.entry.js → p-cc0a4617.entry.js} +1 -1
- package/dist/cobalt/{p-1af6ef83.entry.js → p-cc8e2f16.entry.js} +1 -1
- package/dist/cobalt/{p-c857b9ff.entry.js → p-d9608046.entry.js} +1 -1
- package/dist/cobalt/{p-be3e61f4.entry.js → p-e1957078.entry.js} +1 -1
- package/dist/cobalt/{p-a0749d7b.entry.js → p-e2762263.entry.js} +1 -1
- package/dist/cobalt/{p-21916f82.entry.js → p-e33853fa.entry.js} +1 -1
- package/dist/cobalt/p-e420d5c9.entry.js +1 -0
- package/dist/cobalt/{p-304c3be1.entry.js → p-e4a539da.entry.js} +1 -1
- package/dist/cobalt/{p-0be124d5.entry.js → p-e7085f08.entry.js} +1 -1
- package/dist/cobalt/p-e710b9ea.entry.js +1 -0
- package/dist/cobalt/p-e9aaeaf7.entry.js +1 -0
- package/dist/cobalt/{p-79e49749.entry.js → p-f073b467.entry.js} +1 -1
- package/dist/cobalt/p-f0de4415.entry.js +1 -0
- package/dist/cobalt/p-f36e461f.entry.js +1 -0
- package/dist/cobalt/p-f6ac5301.entry.js +1 -0
- package/dist/cobalt/{p-58aed8d6.entry.js → p-f6b0c4a0.entry.js} +1 -1
- package/dist/cobalt/p-f86ccb38.entry.js +1 -0
- package/dist/cobalt/{p-d7cbb4c7.entry.js → p-fb251497.entry.js} +1 -1
- package/dist/cobalt/p-fd27c2bd.entry.js +1 -0
- package/dist/cobalt/p-tT-aZV0-.js +2 -0
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/co-accordion/co-accordion.css +20 -8
- package/dist/collection/components/co-accordion/co-accordion.js +5 -2
- package/dist/collection/components/co-app-shell/co-app-shell.js +2 -2
- package/dist/collection/components/co-autocomplete/co-autocomplete.css +4 -751
- package/dist/collection/components/co-autocomplete/co-autocomplete.js +41 -76
- package/dist/collection/components/co-avatar/co-avatar.js +1 -1
- package/dist/collection/components/co-avatar-group/co-avatar-group.js +2 -2
- package/dist/collection/components/co-badge/co-badge.js +1 -1
- package/dist/collection/components/co-bottom-sheet/co-bottom-sheet.js +3 -3
- package/dist/collection/components/co-breadcrumb/co-breadcrumb.js +1 -1
- package/dist/collection/components/co-breadcrumb-item/co-breadcrumb-item.js +2 -2
- package/dist/collection/components/co-button/co-button.js +2 -2
- package/dist/collection/components/co-button-group/co-button-group.js +2 -2
- package/dist/collection/components/co-calendar/co-calendar.css +12 -12
- package/dist/collection/components/co-calendar/co-calendar.js +1 -1
- package/dist/collection/components/co-calendar-month/co-calendar-month.js +1 -1
- package/dist/collection/components/co-card/co-card.js +2 -2
- package/dist/collection/components/co-checkbox/co-checkbox.js +3 -3
- package/dist/collection/components/co-checkbox-group/co-checkbox-group.js +3 -3
- package/dist/collection/components/co-chip/co-chip.js +2 -2
- package/dist/collection/components/co-color-picker/co-color-picker.js +2 -2
- package/dist/collection/components/co-column-picker/co-column-picker.js +2 -2
- package/dist/collection/components/co-combobox/co-combobox.css +6 -830
- package/dist/collection/components/co-combobox/co-combobox.js +73 -84
- package/dist/collection/components/co-command-search/co-command-search.css +2 -60
- package/dist/collection/components/co-command-search/co-command-search.js +23 -48
- package/dist/collection/components/co-data-table/co-data-table.css +42 -7
- package/dist/collection/components/co-data-table/co-data-table.js +108 -3
- package/dist/collection/components/co-data-table-pagination/co-data-table-pagination.js +4 -4
- package/dist/collection/components/co-date-field/co-date-field.css +4 -7
- package/dist/collection/components/co-date-field/co-date-field.js +4 -4
- package/dist/collection/components/co-date-range/co-date-range.js +1 -1
- package/dist/collection/components/co-date-range-picker/co-date-range-picker.css +9 -9
- package/dist/collection/components/co-drawer/co-drawer.css +49 -13
- package/dist/collection/components/co-drawer/co-drawer.js +9 -4
- package/dist/collection/components/co-drive-card/co-drive-card.js +1 -1
- package/dist/collection/components/co-drop-zone/co-drop-zone.js +1 -1
- package/dist/collection/components/co-empty-state/co-empty-state.css +1 -1
- package/dist/collection/components/co-empty-state/co-empty-state.js +2 -2
- package/dist/collection/components/co-event-calendar/co-event-calendar.js +2 -2
- package/dist/collection/components/co-fab/co-fab.css +8 -1
- package/dist/collection/components/co-fab/co-fab.js +24 -5
- package/dist/collection/components/co-file-field/co-file-field.js +5 -5
- package/dist/collection/components/co-file-type-tile/co-file-type-tile.js +2 -2
- package/dist/collection/components/co-helper-text/co-helper-text.js +2 -2
- package/dist/collection/components/co-icon/co-icon.js +2 -2
- package/dist/collection/components/co-icon-button/co-icon-button.js +1 -1
- package/dist/collection/components/co-input/co-input.css +9 -6
- package/dist/collection/components/co-json-field/co-json-field.js +3 -3
- package/dist/collection/components/co-lightbox/co-lightbox.css +2 -2
- package/dist/collection/components/co-lightbox/co-lightbox.js +4 -4
- package/dist/collection/components/co-list-footer/co-list-footer.js +1 -1
- package/dist/collection/components/co-list-item/co-list-item.js +4 -4
- package/dist/collection/components/co-media-thumb/co-media-thumb.js +2 -2
- package/dist/collection/components/co-menu/co-menu.js +1 -1
- package/dist/collection/components/co-menu-divider/co-menu-divider.js +1 -1
- package/dist/collection/components/co-menu-item/co-menu-item.css +1 -1
- package/dist/collection/components/co-modal/co-modal.js +2 -2
- package/dist/collection/components/co-navbar/co-navbar.js +2 -2
- package/dist/collection/components/co-number-field/co-number-field.css +10 -11
- package/dist/collection/components/co-number-field/co-number-field.js +2 -2
- package/dist/collection/components/co-option-list/co-option-list.css +796 -58
- package/dist/collection/components/co-option-list/co-option-list.js +45 -6
- package/dist/collection/components/co-overlay/co-overlay.js +1 -1
- package/dist/collection/components/co-page-header/co-page-header.js +1 -1
- package/dist/collection/components/co-phone-field/co-phone-field.css +4 -7
- package/dist/collection/components/co-phone-field/co-phone-field.js +1 -1
- package/dist/collection/components/co-popover/co-popover.js +11 -2
- package/dist/collection/components/co-progress-bar/co-progress-bar.css +1 -1
- package/dist/collection/components/co-progress-bar/co-progress-bar.js +2 -2
- package/dist/collection/components/co-progress-circle/co-progress-circle.js +2 -2
- package/dist/collection/components/co-radio/co-radio.js +3 -3
- package/dist/collection/components/co-radio-group/co-radio-group.js +3 -3
- package/dist/collection/components/co-rating/co-rating.js +3 -3
- package/dist/collection/components/co-ref-field/co-ref-field.css +6 -897
- package/dist/collection/components/co-ref-field/co-ref-field.js +0 -0
- package/dist/collection/components/co-rich-text-editor/co-rich-text-editor.css +1 -1
- package/dist/collection/components/co-rich-text-editor/co-rich-text-editor.js +2 -2
- package/dist/collection/components/co-row/co-row.js +2 -2
- package/dist/collection/components/co-segmented-bar/co-segmented-bar.js +2 -2
- package/dist/collection/components/co-select/co-select.css +4 -7
- package/dist/collection/components/co-select/co-select.js +4 -4
- package/dist/collection/components/co-separator/co-separator.js +1 -1
- package/dist/collection/components/co-sidebar/co-sidebar.js +2 -2
- package/dist/collection/components/co-sidebar-nav/co-sidebar-nav.css +8 -6
- package/dist/collection/components/co-sidebar-nav/co-sidebar-nav.js +8 -6
- package/dist/collection/components/co-skeleton/co-skeleton.js +1 -1
- package/dist/collection/components/co-slider/co-slider.js +2 -2
- package/dist/collection/components/co-switch/co-switch.css +3 -1
- package/dist/collection/components/co-switch/co-switch.js +3 -3
- package/dist/collection/components/co-tab/co-tab.css +39 -4
- package/dist/collection/components/co-tab/co-tab.js +6 -6
- package/dist/collection/components/co-tab-group/co-tab-group.css +11 -0
- package/dist/collection/components/co-tab-group/co-tab-group.js +10 -4
- package/dist/collection/components/co-tags-field/co-tags-field.js +5 -5
- package/dist/collection/components/co-textarea/co-textarea.js +4 -4
- package/dist/collection/components/co-toast/co-toast.js +2 -2
- package/dist/collection/components/co-toggle-button/co-toggle-button.js +2 -2
- package/dist/collection/components/co-toggle-button-group/co-toggle-button-group.js +2 -2
- package/dist/collection/components/co-tooltip/co-tooltip.js +2 -2
- package/dist/collection/components/co-transfer-list/co-transfer-list.js +2 -2
- package/dist/collection/components/co-video/co-video.css +2 -2
- package/dist/collection/components/co-video/co-video.js +2 -2
- package/dist/components/co-accordion.js +1 -1
- package/dist/components/co-app-shell.js +1 -1
- package/dist/components/co-autocomplete.js +1 -1
- package/dist/components/co-avatar-group.js +1 -1
- package/dist/components/co-avatar.js +1 -1
- package/dist/components/co-badge.js +1 -1
- package/dist/components/co-bottom-sheet.js +1 -1
- package/dist/components/co-breadcrumb-item.js +1 -1
- package/dist/components/co-breadcrumb.js +1 -1
- package/dist/components/co-button-group.js +1 -1
- package/dist/components/co-button.js +1 -1
- package/dist/components/co-calendar-month.js +1 -1
- package/dist/components/co-calendar.js +1 -1
- package/dist/components/co-card.js +1 -1
- package/dist/components/co-checkbox-group.js +1 -1
- package/dist/components/co-checkbox.js +1 -1
- package/dist/components/co-chip.js +1 -1
- package/dist/components/co-color-picker.js +1 -1
- package/dist/components/co-column-picker.js +1 -1
- package/dist/components/co-combobox.js +1 -1
- package/dist/components/co-command-search.js +1 -1
- package/dist/components/co-data-table-pagination.js +1 -1
- package/dist/components/co-data-table.js +1 -1
- package/dist/components/co-date-field.js +1 -1
- package/dist/components/co-date-picker.js +1 -1
- package/dist/components/co-date-range-picker.js +1 -1
- package/dist/components/co-date-range.js +1 -1
- package/dist/components/co-drawer.js +1 -1
- package/dist/components/co-drive-card.js +1 -1
- package/dist/components/co-drop-zone.js +1 -1
- package/dist/components/co-empty-state.js +1 -1
- package/dist/components/co-event-calendar.js +1 -1
- package/dist/components/co-fab.js +1 -1
- package/dist/components/co-file-field.js +1 -1
- package/dist/components/co-file-type-tile.js +1 -1
- package/dist/components/co-helper-text.js +1 -1
- package/dist/components/co-icon-button.js +1 -1
- package/dist/components/co-icon.js +1 -1
- package/dist/components/co-input.js +1 -1
- package/dist/components/co-json-field.js +1 -1
- package/dist/components/co-lightbox.js +1 -1
- package/dist/components/co-list-footer.js +1 -1
- package/dist/components/co-list-item.js +1 -1
- package/dist/components/co-media-thumb.js +1 -1
- package/dist/components/co-menu-divider.js +1 -1
- package/dist/components/co-menu-item.js +1 -1
- package/dist/components/co-menu.js +1 -1
- package/dist/components/co-modal.js +1 -1
- package/dist/components/co-navbar.js +1 -1
- package/dist/components/co-number-field.js +1 -1
- package/dist/components/co-option-list.js +1 -1
- package/dist/components/co-overlay.js +1 -1
- package/dist/components/co-page-header.js +1 -1
- package/dist/components/co-phone-field.js +1 -1
- package/dist/components/co-popover.js +1 -1
- package/dist/components/co-progress-bar.js +1 -1
- package/dist/components/co-progress-circle.js +1 -1
- package/dist/components/co-radio-group.js +1 -1
- package/dist/components/co-radio.js +1 -1
- package/dist/components/co-rating.js +1 -1
- package/dist/components/co-ref-field.js +1 -1
- package/dist/components/co-rich-text-editor.js +1 -1
- package/dist/components/co-rich-text-toolbar.js +1 -1
- package/dist/components/co-row.js +1 -1
- package/dist/components/co-segmented-bar.js +1 -1
- package/dist/components/co-select.js +1 -1
- package/dist/components/co-separator.js +1 -1
- package/dist/components/co-sidebar-nav.js +1 -1
- package/dist/components/co-sidebar.js +1 -1
- package/dist/components/co-skeleton.js +1 -1
- package/dist/components/co-slider.js +1 -1
- package/dist/components/co-switch.js +1 -1
- package/dist/components/co-tab-group.js +1 -1
- package/dist/components/co-tab.js +1 -1
- package/dist/components/co-tags-field.js +1 -1
- package/dist/components/co-textarea.js +1 -1
- package/dist/components/co-toast.js +1 -1
- package/dist/components/co-toggle-button-group.js +1 -1
- package/dist/components/co-toggle-button.js +1 -1
- package/dist/components/co-tooltip.js +1 -1
- package/dist/components/co-transfer-list.js +1 -1
- package/dist/components/co-video.js +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/p-BHqdcGDh.js +1 -0
- package/dist/components/{p-B0buzt_E.js → p-BJTMFYax.js} +1 -1
- package/dist/components/{p-vLFwJ77w.js → p-Ba5lW0pA.js} +1 -1
- package/dist/components/{p-CybHxq25.js → p-CNIs9j-h.js} +1 -1
- package/dist/components/{p-Bx1OwdIV.js → p-COb8X_fE.js} +1 -1
- package/dist/components/{p-CzkeIavk.js → p-Cam92sWP.js} +1 -1
- package/dist/components/p-CmCsm4L-.js +1 -0
- package/dist/components/p-D3ts7oo9.js +1 -0
- package/dist/components/{p-CUvAZhuM.js → p-D4SOCy8I.js} +1 -1
- package/dist/components/{p-BnTTeIFH.js → p-Dh-h40mY.js} +1 -1
- package/dist/components/p-DrQh1Cb8.js +1 -0
- package/dist/components/{p-D7dk2gM7.js → p-DvL2TcDG.js} +1 -1
- package/dist/components/{p-BxiKVtk4.js → p-OKwHt2i9.js} +1 -1
- package/dist/components/{p-CBzpUqwG.js → p-QWi9AmnD.js} +1 -1
- package/dist/components/{p-B3igDRut.js → p-Xwo2HQmt.js} +1 -1
- package/dist/components/{p-DTS-dgEe.js → p-_k-j03K-.js} +1 -1
- package/dist/components/{p-HXlAaApx.js → p-eSq2ze8W.js} +1 -1
- package/dist/components/{p-LAxCvyJl.js → p-ivjj-BP8.js} +1 -1
- package/dist/components/{p-C7tPadNy.js → p-lus32JrB.js} +1 -1
- package/dist/esm/co-accordion.entry.js +4 -4
- package/dist/esm/co-app-shell.entry.js +3 -3
- package/dist/esm/co-autocomplete.entry.js +38 -73
- package/dist/esm/co-avatar-group.entry.js +3 -3
- package/dist/esm/co-avatar.entry.js +2 -2
- package/dist/esm/co-badge.entry.js +2 -2
- package/dist/esm/co-bottom-sheet.entry.js +4 -4
- package/dist/esm/co-breadcrumb-item.entry.js +3 -3
- package/dist/esm/co-breadcrumb.entry.js +2 -2
- package/dist/esm/co-button-group.entry.js +3 -3
- package/dist/esm/co-button.entry.js +3 -3
- package/dist/esm/co-calendar-month.entry.js +2 -2
- package/dist/esm/co-calendar_3.entry.js +19 -14
- package/dist/esm/co-card.entry.js +3 -3
- package/dist/esm/co-checkbox-group.entry.js +4 -4
- package/dist/esm/co-checkbox.entry.js +4 -4
- package/dist/esm/co-chip_2.entry.js +482 -0
- package/dist/esm/co-color-picker.entry.js +4 -4
- package/dist/esm/co-column-picker.entry.js +3 -3
- package/dist/esm/co-combobox.entry.js +52 -83
- package/dist/esm/co-command-search.entry.js +21 -60
- package/dist/esm/co-data-table-pagination.entry.js +5 -5
- package/dist/esm/co-data-table.entry.js +54 -5
- package/dist/esm/co-date-picker.entry.js +2 -2
- package/dist/esm/co-date-range-picker.entry.js +3 -3
- package/dist/esm/co-date-range.entry.js +2 -2
- package/dist/esm/co-drive-card.entry.js +2 -2
- package/dist/esm/co-drop-zone.entry.js +2 -2
- package/dist/esm/co-empty-state.entry.js +4 -4
- package/dist/esm/co-event-calendar.entry.js +3 -3
- package/dist/esm/co-fab.entry.js +5 -5
- package/dist/esm/co-file-field.entry.js +7 -7
- package/dist/esm/co-file-type-tile.entry.js +3 -3
- package/dist/esm/co-helper-text.entry.js +3 -3
- package/dist/esm/co-icon-button.entry.js +2 -2
- package/dist/esm/co-icon.entry.js +3 -3
- package/dist/esm/co-input.entry.js +3 -3
- package/dist/esm/co-json-field.entry.js +5 -5
- package/dist/esm/co-lightbox.entry.js +6 -6
- package/dist/esm/co-list-footer.entry.js +2 -2
- package/dist/esm/co-list-item.entry.js +5 -5
- package/dist/esm/co-loader.entry.js +1 -1
- package/dist/esm/co-media-thumb.entry.js +3 -3
- package/dist/esm/co-menu-divider.entry.js +2 -2
- package/dist/esm/co-menu-item.entry.js +2 -2
- package/dist/esm/co-menu.entry.js +2 -2
- package/dist/esm/co-modal.entry.js +3 -3
- package/dist/esm/co-navbar.entry.js +3 -3
- package/dist/esm/co-number-field.entry.js +5 -5
- package/dist/esm/co-overlay.entry.js +2 -2
- package/dist/esm/co-page-header.entry.js +2 -2
- package/dist/esm/co-phone-field.entry.js +4 -4
- package/dist/esm/co-popover.entry.js +12 -3
- package/dist/esm/co-progress-bar.entry.js +4 -4
- package/dist/esm/co-progress-circle.entry.js +3 -3
- package/dist/esm/co-radio-group.entry.js +4 -4
- package/dist/esm/co-radio.entry.js +4 -4
- package/dist/esm/co-rating.entry.js +4 -4
- package/dist/esm/co-ref-field.entry.js +31 -135
- package/dist/esm/co-rich-text-editor.entry.js +4 -4
- package/dist/esm/co-rich-text-toolbar.entry.js +1 -1
- package/dist/esm/co-rich-text-viewer.entry.js +1 -1
- package/dist/esm/co-row.entry.js +3 -3
- package/dist/esm/co-segmented-bar.entry.js +3 -3
- package/dist/esm/co-select.entry.js +7 -7
- package/dist/esm/co-separator.entry.js +2 -2
- package/dist/esm/co-sidebar-nav.entry.js +10 -8
- package/dist/esm/co-sidebar.entry.js +3 -3
- package/dist/esm/co-skeleton.entry.js +2 -2
- package/dist/esm/co-slider.entry.js +3 -3
- package/dist/esm/co-switch.entry.js +6 -6
- package/dist/esm/co-tab-group.entry.js +10 -4
- package/dist/esm/co-tab.entry.js +5 -5
- package/dist/esm/co-tags-field.entry.js +8 -8
- package/dist/esm/co-textarea.entry.js +6 -6
- package/dist/esm/co-toast.entry.js +3 -3
- package/dist/esm/co-toggle-button-group.entry.js +3 -3
- package/dist/esm/co-toggle-button.entry.js +3 -3
- package/dist/esm/co-tooltip.entry.js +3 -3
- package/dist/esm/co-transfer-list.entry.js +3 -3
- package/dist/esm/co-video.entry.js +4 -4
- package/dist/esm/cobalt.js +3 -3
- package/dist/esm/{fieldChip-BBu4ukje.js → fieldChip-ChXW__C5.js} +1 -1
- package/dist/esm/{index-Es9IUmmt.js → index-tT-aZV0-.js} +9 -13
- package/dist/esm/loader.js +3 -3
- package/dist/esm/{requiredMark-Bg25QWFn.js → requiredMark-C7-_2UhB.js} +1 -1
- package/dist/types/components/co-accordion/co-accordion.d.ts +3 -0
- package/dist/types/components/co-autocomplete/co-autocomplete.d.ts +12 -14
- package/dist/types/components/co-combobox/co-combobox.d.ts +29 -15
- package/dist/types/components/co-command-search/co-command-search.d.ts +13 -5
- package/dist/types/components/co-command-search/commandSearchLogic.d.ts +1 -1
- package/dist/types/components/co-data-table/co-data-table.d.ts +22 -0
- package/dist/types/components/co-fab/co-fab.d.ts +3 -1
- package/dist/types/components/co-option-list/co-option-list.d.ts +4 -0
- package/dist/types/components/co-popover/co-popover.d.ts +1 -0
- package/dist/types/components/co-ref-field/co-ref-field.d.ts +8 -30
- package/dist/types/components/co-sidebar-nav/co-sidebar-nav.d.ts +2 -0
- package/dist/types/components/co-tab/co-tab.d.ts +2 -2
- package/dist/types/components/co-tab-group/co-tab-group.d.ts +5 -1
- package/dist/types/components.d.ts +108 -45
- package/package.json +3 -3
- package/dist/cjs/co-chip.cjs.entry.js +0 -91
- package/dist/cjs/co-option-list.cjs.entry.js +0 -379
- package/dist/cobalt/p-06c27cc5.entry.js +0 -1
- package/dist/cobalt/p-075f6ca4.entry.js +0 -1
- package/dist/cobalt/p-0810ee1e.entry.js +0 -1
- package/dist/cobalt/p-0b41e76e.entry.js +0 -1
- package/dist/cobalt/p-19f7ee64.entry.js +0 -1
- package/dist/cobalt/p-23c9208a.entry.js +0 -1
- package/dist/cobalt/p-311118cb.entry.js +0 -1
- package/dist/cobalt/p-48c5f311.entry.js +0 -1
- package/dist/cobalt/p-523cfd98.entry.js +0 -1
- package/dist/cobalt/p-5eecea26.entry.js +0 -1
- package/dist/cobalt/p-64a0b656.entry.js +0 -1
- package/dist/cobalt/p-755ecee1.entry.js +0 -1
- package/dist/cobalt/p-76b46336.entry.js +0 -1
- package/dist/cobalt/p-7b5dec05.entry.js +0 -1
- package/dist/cobalt/p-87289d32.entry.js +0 -1
- package/dist/cobalt/p-BUgUTjOB.js +0 -1
- package/dist/cobalt/p-Es9IUmmt.js +0 -2
- package/dist/cobalt/p-a71fd4f1.entry.js +0 -1
- package/dist/cobalt/p-b045d680.entry.js +0 -1
- package/dist/cobalt/p-b3c8fc9a.entry.js +0 -1
- package/dist/cobalt/p-b8f36f12.entry.js +0 -1
- package/dist/cobalt/p-ba6f0f90.entry.js +0 -1
- package/dist/cobalt/p-c1abc74b.entry.js +0 -1
- package/dist/cobalt/p-cf239452.entry.js +0 -1
- package/dist/cobalt/p-d2507f04.entry.js +0 -1
- package/dist/cobalt/p-d55652f2.entry.js +0 -1
- package/dist/cobalt/p-da211abf.entry.js +0 -1
- package/dist/cobalt/p-dcc7fc95.entry.js +0 -1
- package/dist/collection/components/co-command-search/commandSearchGroup.js +0 -17
- package/dist/components/p-BhSJcOUS.js +0 -1
- package/dist/components/p-CZKHHCdL.js +0 -1
- package/dist/components/p-K6LC1Hz4.js +0 -1
- package/dist/esm/co-chip.entry.js +0 -89
- package/dist/esm/co-option-list.entry.js +0 -377
- package/dist/types/components/co-command-search/commandSearchGroup.d.ts +0 -20
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { h } from "@stencil/core";
|
|
2
2
|
import { RequiredMark } from "../../utils/requiredMark";
|
|
3
|
-
import {
|
|
4
|
-
import { highlightMatch, rankByMatch } from "../../utils/normalizeText";
|
|
3
|
+
import { rankByMatch } from "../../utils/normalizeText";
|
|
5
4
|
export class CoCombobox {
|
|
6
5
|
constructor() {
|
|
7
6
|
/** Whether the field is required (renders a required marker on the label). */
|
|
@@ -25,6 +24,8 @@ export class CoCombobox {
|
|
|
25
24
|
this.footerSecondaryLabel = 'New Tags';
|
|
26
25
|
/** Options to display in the dropdown (array of objects or strings) */
|
|
27
26
|
this.options = '[]';
|
|
27
|
+
/** Message shown when the filtered list is empty. */
|
|
28
|
+
this.emptyMessage = 'No results found';
|
|
28
29
|
/** Currently selected values (multi-select) */
|
|
29
30
|
this.value = '[]';
|
|
30
31
|
/** Whether multiple values can be selected */
|
|
@@ -38,7 +39,9 @@ export class CoCombobox {
|
|
|
38
39
|
this.isOpen = false;
|
|
39
40
|
this.searchQuery = '';
|
|
40
41
|
this.overflowCount = 0;
|
|
41
|
-
|
|
42
|
+
/** Foco diferido del search: @Watch corre antes del commit del render que
|
|
43
|
+
* monta la lista (patrón co-ref-field). */
|
|
44
|
+
this.pendingFocus = false;
|
|
42
45
|
this.handleTriggerClick = (e) => {
|
|
43
46
|
if (this.disabled)
|
|
44
47
|
e.stopPropagation();
|
|
@@ -55,38 +58,35 @@ export class CoCombobox {
|
|
|
55
58
|
e.stopPropagation();
|
|
56
59
|
this.value = '[]';
|
|
57
60
|
this.coClear.emit();
|
|
58
|
-
this.coChange.emit([]);
|
|
61
|
+
this.coChange.emit({ value: this.multiple ? [] : '', item: null });
|
|
59
62
|
};
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
63
|
+
/**
|
|
64
|
+
* Handler de coChange de <co-option-list>. Misma semántica que el click
|
|
65
|
+
* de opción anterior (single: set + cierra; multiple: la primitiva ya
|
|
66
|
+
* hace el toggle y entrega el array completo) pero almacenando `value`
|
|
67
|
+
* en el MISMO formato que antes (JSON-array-string siempre — lo que
|
|
68
|
+
* espera `selectedValues`, sin tocar ese getter) y emitiendo el detail
|
|
69
|
+
* normalizado `{ value, item }`.
|
|
70
|
+
*/
|
|
71
|
+
this.handleListChange = (detail) => {
|
|
72
|
+
if (this.multiple) {
|
|
73
|
+
const next = detail.value;
|
|
74
|
+
this.value = JSON.stringify(next);
|
|
75
|
+
this.coChange.emit({ value: next, item: detail.item });
|
|
65
76
|
}
|
|
66
77
|
else {
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
selected.length = 0;
|
|
72
|
-
selected.push(optionValue);
|
|
73
|
-
this.isOpen = false;
|
|
74
|
-
}
|
|
78
|
+
const next = detail.value;
|
|
79
|
+
this.value = JSON.stringify([next]);
|
|
80
|
+
this.isOpen = false;
|
|
81
|
+
this.coChange.emit({ value: next, item: detail.item });
|
|
75
82
|
}
|
|
76
|
-
this.value = JSON.stringify(selected);
|
|
77
|
-
this.coChange.emit(selected);
|
|
78
|
-
};
|
|
79
|
-
this.handleRemoveOption = (e, optionValue) => {
|
|
80
|
-
e.stopPropagation();
|
|
81
|
-
const selected = this.selectedValues.filter(v => v !== optionValue);
|
|
82
|
-
this.value = JSON.stringify(selected);
|
|
83
|
-
this.coChange.emit(selected);
|
|
84
83
|
};
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
84
|
+
/** Handler de coRemoveItem de <co-option-list> — también reusado por el
|
|
85
|
+
* botón "x" de los chips del trigger (mismo efecto: quitar un valor). */
|
|
86
|
+
this.handleListRemove = (id) => {
|
|
87
|
+
const next = this.selectedValues.filter((v) => v !== id);
|
|
88
|
+
this.value = JSON.stringify(next);
|
|
89
|
+
this.coChange.emit({ value: next, item: { _id: id, label: id } });
|
|
90
90
|
};
|
|
91
91
|
this.handleFooterPrimary = () => {
|
|
92
92
|
this.coFooterPrimary.emit();
|
|
@@ -95,9 +95,6 @@ export class CoCombobox {
|
|
|
95
95
|
this.handleFooterSecondary = () => {
|
|
96
96
|
this.coFooterSecondary.emit();
|
|
97
97
|
};
|
|
98
|
-
this.handleOptionsScroll = (e) => {
|
|
99
|
-
this.scrollTop = e.target.scrollTop;
|
|
100
|
-
};
|
|
101
98
|
}
|
|
102
99
|
normalizeOptions(raw) {
|
|
103
100
|
return raw.map(item => {
|
|
@@ -133,12 +130,9 @@ export class CoCombobox {
|
|
|
133
130
|
return this.parsedOptions;
|
|
134
131
|
return rankByMatch(this.parsedOptions, this.searchQuery, o => o.label);
|
|
135
132
|
}
|
|
136
|
-
/**
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
if (!seg)
|
|
140
|
-
return label;
|
|
141
|
-
return [seg.pre, h("span", { class: "co-combobox__match" }, seg.match), seg.post];
|
|
133
|
+
/** Opciones filtradas client-side, mapeadas al item de co-option-list. */
|
|
134
|
+
get listItemsJson() {
|
|
135
|
+
return JSON.stringify(this.filteredOptions.map((o) => ({ _id: o.value, label: o.label, icon: o.icon })));
|
|
142
136
|
}
|
|
143
137
|
get displayText() {
|
|
144
138
|
const selected = this.selectedValues;
|
|
@@ -164,8 +158,11 @@ export class CoCombobox {
|
|
|
164
158
|
}
|
|
165
159
|
onOpenChange(open) {
|
|
166
160
|
if (open) {
|
|
161
|
+
// La lista se monta on-demand ({this.isOpen && ...}), así que la
|
|
162
|
+
// primitiva arranca fresca en cada apertura (term/scroll en cero);
|
|
163
|
+
// aquí solo se resetea el filtro client-side del host.
|
|
167
164
|
this.searchQuery = '';
|
|
168
|
-
this.
|
|
165
|
+
this.pendingFocus = true;
|
|
169
166
|
this.coOpen.emit();
|
|
170
167
|
}
|
|
171
168
|
else {
|
|
@@ -181,26 +178,23 @@ export class CoCombobox {
|
|
|
181
178
|
});
|
|
182
179
|
}
|
|
183
180
|
disconnectedCallback() {
|
|
184
|
-
var _a
|
|
181
|
+
var _a;
|
|
185
182
|
(_a = this.resizeObserver) === null || _a === void 0 ? void 0 : _a.disconnect();
|
|
186
|
-
(_b = this.osInstance) === null || _b === void 0 ? void 0 : _b.destroy();
|
|
187
|
-
this.osInstance = undefined;
|
|
188
183
|
}
|
|
189
184
|
componentDidRender() {
|
|
190
|
-
var _a, _b;
|
|
185
|
+
var _a, _b, _c;
|
|
191
186
|
if (this.chipContainerEl) {
|
|
192
187
|
(_a = this.resizeObserver) === null || _a === void 0 ? void 0 : _a.disconnect();
|
|
193
188
|
(_b = this.resizeObserver) === null || _b === void 0 ? void 0 : _b.observe(this.chipContainerEl);
|
|
194
189
|
}
|
|
195
190
|
this.calcOverflow();
|
|
196
|
-
//
|
|
197
|
-
//
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
this.
|
|
203
|
-
this.osInstance = undefined;
|
|
191
|
+
// Corre después del commit: optionListEl ya apunta a la lista recién
|
|
192
|
+
// montada; isConnected descarta refs stale de aperturas anteriores.
|
|
193
|
+
// focusSearch() reintenta hasta que el popover sea visible (no-op si
|
|
194
|
+
// la lista no es searchable).
|
|
195
|
+
if (this.pendingFocus && ((_c = this.optionListEl) === null || _c === void 0 ? void 0 : _c.isConnected)) {
|
|
196
|
+
this.pendingFocus = false;
|
|
197
|
+
this.optionListEl.focusSearch();
|
|
204
198
|
}
|
|
205
199
|
}
|
|
206
200
|
calcOverflow() {
|
|
@@ -229,37 +223,16 @@ export class CoCombobox {
|
|
|
229
223
|
this.overflowCount = hiddenCount;
|
|
230
224
|
}
|
|
231
225
|
}
|
|
232
|
-
getVirtualSlice(items) {
|
|
233
|
-
const { ITEM_HEIGHT, VIEWPORT_ITEMS, OVERSCAN } = CoCombobox;
|
|
234
|
-
const total = items.length;
|
|
235
|
-
const totalHeight = total * ITEM_HEIGHT;
|
|
236
|
-
const startIdx = Math.max(0, Math.floor(this.scrollTop / ITEM_HEIGHT) - OVERSCAN);
|
|
237
|
-
const endIdx = Math.min(total, startIdx + VIEWPORT_ITEMS + OVERSCAN * 2);
|
|
238
|
-
const offsetY = startIdx * ITEM_HEIGHT;
|
|
239
|
-
return { totalHeight, startIdx, endIdx, offsetY };
|
|
240
|
-
}
|
|
241
226
|
render() {
|
|
242
|
-
|
|
243
|
-
const options = this.filteredOptions;
|
|
244
|
-
return (h("div", { key: '335a823bd69e0d57af567bd92befdc31b2449612', class: {
|
|
227
|
+
return (h("div", { key: '49723329c7a66fc87bac2280c36993aa7488e723', class: {
|
|
245
228
|
'co-combobox': true,
|
|
246
229
|
'co-combobox--open': this.isOpen,
|
|
247
230
|
'co-combobox--disabled': this.disabled,
|
|
248
|
-
'co-combobox--filled': this.hasValue,
|
|
249
231
|
[`co-combobox--${this.size}`]: true,
|
|
250
|
-
}, part: "wrapper" }, (this.label || this.secondaryLabel) && (h("div", { key: '
|
|
232
|
+
}, part: "wrapper" }, (this.label || this.secondaryLabel) && (h("div", { key: 'a32ea355689787cf5e4175964284512bd10041f7', class: "co-combobox__labels" }, this.label && h("label", { key: '2ec23463de4b263fbbf3669fe7c6930719b97572', class: "co-combobox__label", part: "label" }, this.label, h(RequiredMark, { key: '0fab4c10366d9f773eeef6912904a43e376685b5', required: this.required })), this.secondaryLabel && (h("span", { key: '3117d08e3d61799b840b6e12fd9bce7ed0eb74e8', class: "co-combobox__secondary-label", part: "secondary-label" }, this.secondaryLabel)))), h("co-popover", { key: '28d93c37ef62f757ae27f25621036aac8bb3e752', open: this.isOpen, placement: "bottom-start", matchWidth: true, offset: 4, onCoOpen: this.handlePopoverOpen, onCoClose: this.handlePopoverClose }, h("div", { key: '6e390e5d89d6e26abf75d3d8619bacb3e479388f', slot: "trigger", class: "co-combobox__trigger", part: "trigger", onClick: this.handleTriggerClick }, this.iconLeft && (h("co-icon", { key: 'f0df056dcd2a6b6990e920efb88daadde3e1fee1', name: this.iconLeft, size: 16, class: "co-combobox__icon" })), h("div", { key: 'b25c9da054983f6d572f7d63ac063a9735871753', class: "co-combobox__input-wrapper", ref: (el) => (this.chipContainerEl = el) }, this.multiple && this.hasValue ? (this.selectedOptions.map(opt => (h("co-chip", { size: "small", "icon-mode": "both", label: opt.label }, h("co-icon", { slot: "icon-left", name: opt.icon || 'circle', size: 10 }), h("co-icon", { slot: "icon-right", name: "x-circle", size: 10, weight: "fill", onClick: (e) => { e.stopPropagation(); this.handleListRemove(opt.value); } }))))) : (h("span", { class: {
|
|
251
233
|
'co-combobox__text': true,
|
|
252
234
|
'co-combobox__text--placeholder': !this.hasValue,
|
|
253
|
-
} }, this.hasValue ? this.displayText : this.placeholder))), this.multiple && this.overflowCount > 0 && (h("span", { key: '
|
|
254
|
-
const { totalHeight, startIdx, endIdx, offsetY } = this.getVirtualSlice(options);
|
|
255
|
-
return (h("div", { class: "co-combobox__virtual-spacer", style: { height: `${totalHeight}px`, position: 'relative' } }, h("div", { style: { position: 'absolute', top: `${offsetY}px`, left: '0', right: '0' } }, options.slice(startIdx, endIdx).map(option => {
|
|
256
|
-
const isSelected = selected.includes(option.value);
|
|
257
|
-
return (h("div", { class: {
|
|
258
|
-
'co-combobox__option': true,
|
|
259
|
-
'co-combobox__option--selected': isSelected,
|
|
260
|
-
}, onClick: () => this.handleOptionClick(option.value), part: "option" }, h("div", { class: "co-combobox__option-content" }, option.icon && (h("div", { class: "co-combobox__option-icon-wrapper" }, h("co-icon", { name: option.icon, size: 20, class: "co-combobox__option-icon" }))), h("span", { class: "co-combobox__option-label" }, this.renderLabel(option.label))), isSelected && this.multiple && (h("button", { class: "co-combobox__option-remove", type: "button", tabIndex: -1, onClick: (e) => this.handleRemoveOption(e, option.value), "aria-label": `Remove ${option.label}` }, h("co-icon", { name: "x-circle", size: 16, weight: "fill" }))), isSelected && !this.multiple && (h("co-icon", { name: "check", size: 16, class: "co-combobox__option-check" }))));
|
|
261
|
-
}))));
|
|
262
|
-
})()), this.showFooter && (h("co-list-footer", { key: '6ae233e2944648a21c09c3ef252cb89b05be86e3', secondaryLabel: this.footerSecondaryLabel, primaryLabel: this.footerPrimaryLabel, onCoSecondary: this.handleFooterSecondary, onCoPrimary: this.handleFooterPrimary })))), this.helperText && (h("div", { key: '6896e1e0ae6f7a29f9b3916759f57adc65c4ba4b', class: `co-combobox__helper co-combobox__helper--${this.status}`, part: "helper" }, this.statusIcon && h("co-icon", { key: 'a4e65d03cf076985fd72c835143718fb5e3b39ba', name: this.statusIcon, size: 14, weight: "fill", class: "co-combobox__helper-icon" }), h("span", { key: '83ed79b8f7cd06824619e5a337d3dd373c098f37', class: "co-combobox__helper-text" }, this.helperText)))));
|
|
235
|
+
} }, this.hasValue ? this.displayText : this.placeholder))), this.multiple && this.overflowCount > 0 && (h("span", { key: 'ac7ff27f3d4149260f441b3b81fba8b92d49bedf', class: "co-combobox__overflow-badge" }, this.overflowCount)), this.clearable && this.hasValue && !this.disabled && (h("button", { key: 'ad11ddb7806a2b1cfe044f6d1773ac9e19c5afb9', class: "co-combobox__clear", type: "button", tabIndex: -1, onClick: this.handleClear, "aria-label": "Clear selection", part: "clear" }, h("co-icon", { key: '634a149b26996d648cb88095e80531314d0c13dd', name: "x-circle", size: 16, weight: "fill" }))), h("co-icon", { key: '8ac8d146143869b39c6f3908a3580220dab41642', name: this.isOpen ? 'caret-up' : 'caret-down', size: 16, class: "co-combobox__caret" })), h("div", { key: '82f61579e15806878fa2b0e3797e20b77a8d5465', class: "co-combobox__dropdown", part: "dropdown" }, this.isOpen && (h("co-option-list", { key: 'b697324b29132b95d7c9d593f36452052933f22e', ref: (el) => (this.optionListEl = el), items: this.listItemsJson, value: this.multiple ? JSON.stringify(this.selectedValues) : (this.selectedValues[0] || ''), multiple: this.multiple, selectedAffordance: "check", removableItems: this.multiple, virtual: true, searchable: this.searchable, searchPlaceholder: this.searchPlaceholder, searchDebounce: 0, highlightMatches: true, emptyMessage: this.emptyMessage, onCoSearch: (e) => { this.searchQuery = e.detail; }, onCoChange: (e) => this.handleListChange(e.detail), onCoRemoveItem: (e) => this.handleListRemove(e.detail) }, this.showFooter && (h("co-list-footer", { key: '151517f62b1188dd7ea3a3c53f69be9260e2cbd8', slot: "footer", secondaryLabel: this.footerSecondaryLabel, primaryLabel: this.footerPrimaryLabel, onCoSecondary: this.handleFooterSecondary, onCoPrimary: this.handleFooterPrimary })))))), this.helperText && (h("div", { key: 'd6b65a3aa77340142038818d43cce73c39914897', class: `co-combobox__helper co-combobox__helper--${this.status}`, part: "helper" }, this.statusIcon && h("co-icon", { key: 'e77f399023eab01cb6de4dd356a9dc897da58755', name: this.statusIcon, size: 14, weight: "fill", class: "co-combobox__helper-icon" }), h("span", { key: 'cad08054732494180772c881622362e9d592df26', class: "co-combobox__helper-text" }, this.helperText)))));
|
|
263
236
|
}
|
|
264
237
|
static get is() { return "co-combobox"; }
|
|
265
238
|
static get encapsulation() { return "shadow"; }
|
|
@@ -538,6 +511,26 @@ export class CoCombobox {
|
|
|
538
511
|
"attribute": "options",
|
|
539
512
|
"defaultValue": "'[]'"
|
|
540
513
|
},
|
|
514
|
+
"emptyMessage": {
|
|
515
|
+
"type": "string",
|
|
516
|
+
"mutable": false,
|
|
517
|
+
"complexType": {
|
|
518
|
+
"original": "string",
|
|
519
|
+
"resolved": "string",
|
|
520
|
+
"references": {}
|
|
521
|
+
},
|
|
522
|
+
"required": false,
|
|
523
|
+
"optional": false,
|
|
524
|
+
"docs": {
|
|
525
|
+
"tags": [],
|
|
526
|
+
"text": "Message shown when the filtered list is empty."
|
|
527
|
+
},
|
|
528
|
+
"getter": false,
|
|
529
|
+
"setter": false,
|
|
530
|
+
"reflect": false,
|
|
531
|
+
"attribute": "empty-message",
|
|
532
|
+
"defaultValue": "'No results found'"
|
|
533
|
+
},
|
|
541
534
|
"value": {
|
|
542
535
|
"type": "string",
|
|
543
536
|
"mutable": true,
|
|
@@ -663,8 +656,7 @@ export class CoCombobox {
|
|
|
663
656
|
return {
|
|
664
657
|
"isOpen": {},
|
|
665
658
|
"searchQuery": {},
|
|
666
|
-
"overflowCount": {}
|
|
667
|
-
"scrollTop": {}
|
|
659
|
+
"overflowCount": {}
|
|
668
660
|
};
|
|
669
661
|
}
|
|
670
662
|
static get events() {
|
|
@@ -676,11 +668,11 @@ export class CoCombobox {
|
|
|
676
668
|
"composed": true,
|
|
677
669
|
"docs": {
|
|
678
670
|
"tags": [],
|
|
679
|
-
"text": "Emitted when the selection changes"
|
|
671
|
+
"text": "Emitted when the selection changes. `item` is the picked option (the\noption-list's native `{ _id, label }` shape); `null` on clear."
|
|
680
672
|
},
|
|
681
673
|
"complexType": {
|
|
682
|
-
"original": "string[]",
|
|
683
|
-
"resolved": "string[]",
|
|
674
|
+
"original": "{ value: string[] | string; item: { _id: string; label: string } | null }",
|
|
675
|
+
"resolved": "{ value: string | string[]; item: { _id: string; label: string; } | null; }",
|
|
684
676
|
"references": {}
|
|
685
677
|
}
|
|
686
678
|
}, {
|
|
@@ -771,6 +763,3 @@ export class CoCombobox {
|
|
|
771
763
|
}];
|
|
772
764
|
}
|
|
773
765
|
}
|
|
774
|
-
CoCombobox.ITEM_HEIGHT = 34; // 32px height + 2px gap
|
|
775
|
-
CoCombobox.VIEWPORT_ITEMS = 8; // visible items
|
|
776
|
-
CoCombobox.OVERSCAN = 3; // extra items above/below
|
|
@@ -74,66 +74,8 @@ co-overlay { --co-overlay-bg: rgba(0, 0, 0, 0.16); }
|
|
|
74
74
|
padding: var(--co-spacing-xs) 0;
|
|
75
75
|
}
|
|
76
76
|
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
align-items: center;
|
|
80
|
-
gap: var(--co-spacing-sm);
|
|
81
|
-
padding: var(--co-spacing-sm) var(--co-spacing-lg);
|
|
82
|
-
cursor: pointer;
|
|
83
|
-
font-size: var(--co-font-size-14);
|
|
84
|
-
color: var(--co-semantic-text-default);
|
|
85
|
-
transition: background 0.08s ease;
|
|
86
|
-
}
|
|
87
|
-
|
|
88
|
-
.co-command-search__item:hover,
|
|
89
|
-
.co-command-search__item--active {
|
|
90
|
-
background: var(--co-semantic-surface-hover);
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
.co-command-search__item-label {
|
|
94
|
-
flex: 1;
|
|
95
|
-
white-space: nowrap;
|
|
96
|
-
overflow: hidden;
|
|
97
|
-
text-overflow: ellipsis;
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
.co-command-search__match {
|
|
101
|
-
font-weight: 700;
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
/* Empty */
|
|
105
|
-
.co-command-search__empty {
|
|
106
|
-
padding: var(--co-spacing-2xl) var(--co-spacing-lg);
|
|
107
|
-
text-align: center;
|
|
108
|
-
font-size: var(--co-font-size-14);
|
|
109
|
-
color: var(--co-semantic-text-muted);
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
/* Section header */
|
|
113
|
-
.co-command-search__section {
|
|
114
|
-
padding: var(--co-spacing-sm) var(--co-spacing-lg) var(--co-spacing-xs);
|
|
115
|
-
font-size: var(--co-font-size-12);
|
|
116
|
-
font-weight: 600;
|
|
117
|
-
text-transform: uppercase;
|
|
118
|
-
letter-spacing: 0.04em;
|
|
119
|
-
color: var(--co-semantic-text-muted);
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
/* Item text column (label + subtitle stacked) */
|
|
123
|
-
.co-command-search__item-text {
|
|
124
|
-
flex: 1;
|
|
125
|
-
min-width: 0;
|
|
126
|
-
display: flex;
|
|
127
|
-
flex-direction: column;
|
|
128
|
-
}
|
|
129
|
-
|
|
130
|
-
.co-command-search__item-subtitle {
|
|
131
|
-
font-size: var(--co-font-size-12);
|
|
132
|
-
color: var(--co-semantic-text-secondary);
|
|
133
|
-
white-space: nowrap;
|
|
134
|
-
overflow: hidden;
|
|
135
|
-
text-overflow: ellipsis;
|
|
136
|
-
}
|
|
77
|
+
/* The results list itself (grouping, rows, highlight, empty/loading) is
|
|
78
|
+
co-option-list's own look & feel now — see co-option-list.css. */
|
|
137
79
|
|
|
138
80
|
/* Loading */
|
|
139
81
|
/* Inline loader next to the ESC chip (Cobalt co-loader, replaces the old "…"
|
|
@@ -1,6 +1,4 @@
|
|
|
1
1
|
import { h } from "@stencil/core";
|
|
2
|
-
import { highlightMatch } from "../../utils/normalizeText";
|
|
3
|
-
import { groupItems } from "./commandSearchGroup";
|
|
4
2
|
import { shouldKeepOpen, isEmptyBackspace, applyClientFilter } from "./commandSearchLogic";
|
|
5
3
|
/**
|
|
6
4
|
* A command palette / search component (⌘K style).
|
|
@@ -37,34 +35,24 @@ export class CoCommandSearch {
|
|
|
37
35
|
* Shown as a grid at the top of the results, only while the query is empty. */
|
|
38
36
|
this.favorites = '[]';
|
|
39
37
|
this.query = '';
|
|
40
|
-
this.activeIndex = 0;
|
|
41
38
|
this.handleInput = (e) => {
|
|
42
39
|
this.query = e.target.value;
|
|
43
|
-
this.
|
|
44
|
-
this.coQueryChange.emit(this.query);
|
|
40
|
+
this.coSearch.emit(this.query);
|
|
45
41
|
};
|
|
46
42
|
this.handleKeyDown = (e) => {
|
|
43
|
+
var _a, _b;
|
|
47
44
|
// Backspace with empty query → notify host to pop scope or last facet-chip
|
|
48
45
|
if (isEmptyBackspace(e.key, this.query)) {
|
|
49
46
|
e.preventDefault();
|
|
50
47
|
this.coBackspaceEmpty.emit(this.query);
|
|
51
48
|
return;
|
|
52
49
|
}
|
|
53
|
-
const items = this.filteredItems;
|
|
54
50
|
switch (e.key) {
|
|
55
51
|
case 'ArrowDown':
|
|
56
|
-
e.preventDefault();
|
|
57
|
-
this.activeIndex = (this.activeIndex + 1) % items.length;
|
|
58
|
-
break;
|
|
59
52
|
case 'ArrowUp':
|
|
60
|
-
e.preventDefault();
|
|
61
|
-
this.activeIndex = (this.activeIndex - 1 + items.length) % items.length;
|
|
62
|
-
break;
|
|
63
53
|
case 'Enter':
|
|
64
54
|
e.preventDefault();
|
|
65
|
-
|
|
66
|
-
this.selectItem(items[this.activeIndex]);
|
|
67
|
-
}
|
|
55
|
+
(_a = this.optionListEl) === null || _a === void 0 ? void 0 : _a.handleKey(e);
|
|
68
56
|
break;
|
|
69
57
|
case 'Escape':
|
|
70
58
|
e.preventDefault();
|
|
@@ -72,14 +60,16 @@ export class CoCommandSearch {
|
|
|
72
60
|
break;
|
|
73
61
|
case 'Tab':
|
|
74
62
|
e.preventDefault();
|
|
75
|
-
|
|
76
|
-
this.activeIndex = e.shiftKey
|
|
77
|
-
? (this.activeIndex - 1 + items.length) % items.length
|
|
78
|
-
: (this.activeIndex + 1) % items.length;
|
|
79
|
-
}
|
|
63
|
+
(_b = this.optionListEl) === null || _b === void 0 ? void 0 : _b.handleKey(new KeyboardEvent('keydown', { key: e.shiftKey ? 'ArrowUp' : 'ArrowDown' }));
|
|
80
64
|
break;
|
|
81
65
|
}
|
|
82
66
|
};
|
|
67
|
+
/** Two-stage commit intacto: keepOpen → coScopeChange; resto → coSelect + close. */
|
|
68
|
+
this.handleListPick = (id) => {
|
|
69
|
+
const item = this.filteredItems.find((it) => it.value === id);
|
|
70
|
+
if (item)
|
|
71
|
+
this.selectItem(item);
|
|
72
|
+
};
|
|
83
73
|
this.handleOverlayClick = () => {
|
|
84
74
|
this.close();
|
|
85
75
|
};
|
|
@@ -131,17 +121,9 @@ export class CoCommandSearch {
|
|
|
131
121
|
return [];
|
|
132
122
|
}
|
|
133
123
|
}
|
|
134
|
-
/** Item label with the matched substring wrapped for highlighting. */
|
|
135
|
-
renderLabel(label) {
|
|
136
|
-
const seg = this.query ? highlightMatch(label, this.query) : null;
|
|
137
|
-
if (!seg)
|
|
138
|
-
return label;
|
|
139
|
-
return [seg.pre, h("span", { class: "co-command-search__match" }, seg.match), seg.post];
|
|
140
|
-
}
|
|
141
124
|
onActiveTabChange(newVal) {
|
|
142
125
|
if (newVal) {
|
|
143
126
|
this.query = '';
|
|
144
|
-
this.activeIndex = 0;
|
|
145
127
|
}
|
|
146
128
|
// The active tab may be appended past the visible width (e.g. a model picked
|
|
147
129
|
// from "Más"). Scroll it into view; scroll-padding-right keeps it clear of the
|
|
@@ -155,7 +137,6 @@ export class CoCommandSearch {
|
|
|
155
137
|
onOpenChange(newVal) {
|
|
156
138
|
if (newVal) {
|
|
157
139
|
this.query = '';
|
|
158
|
-
this.activeIndex = 0;
|
|
159
140
|
requestAnimationFrame(() => { var _a; return (_a = this.inputEl) === null || _a === void 0 ? void 0 : _a.focus(); });
|
|
160
141
|
}
|
|
161
142
|
}
|
|
@@ -175,21 +156,17 @@ export class CoCommandSearch {
|
|
|
175
156
|
render() {
|
|
176
157
|
const items = this.filteredItems;
|
|
177
158
|
return [
|
|
178
|
-
h("div", { key: '
|
|
179
|
-
h("co-overlay", { key: '
|
|
159
|
+
h("div", { key: '6e45f5a53f39f516cc8a3eb43180b4c6f6c413fd', class: "co-command-search__trigger", onClick: this.handleTriggerClick }, h("slot", { key: '0dbbb33bf84b9a0fcf94d71802b87a2d0d240522', name: "trigger" })),
|
|
160
|
+
h("co-overlay", { key: 'b7f46dde81f6f3462b550c3ccde29388604f9404', open: this.open, onCoClose: this.handleOverlayClick }, h("div", { key: '745f5b7e2a31897b88303deb6b49ba3787b7c7b8', class: { 'co-command-search': true, 'co-command-search--open': this.open }, part: "panel", role: "dialog", "aria-modal": "true", "aria-label": "Command palette", onClick: this.handlePanelClick }, h("div", { key: '90f367e679c3e971cbe7823e766152cb02b2a018', class: "co-command-search__input-row", part: "input-row" }, h("co-icon", { key: 'f084dde02745550de0ebe92840f4a3f62e7eb543', name: "magnifying-glass", size: 20 }), this.parsedChips.map((chip, idx) => (h("span", { class: "co-command-search__facet-chip" }, chip.icon && h("co-icon", { name: chip.icon, size: 12 }), h("span", { class: "co-command-search__facet-chip-label" }, chip.label), h("button", { class: "co-command-search__facet-chip-remove", type: "button", "aria-label": `Remove filter ${chip.label}`, onClick: (e) => {
|
|
180
161
|
e.stopPropagation();
|
|
181
162
|
this.coChipRemove.emit(idx);
|
|
182
|
-
} }, h("co-icon", { name: "x", size: 10, weight: "bold" }))))), h("input", { key: '
|
|
163
|
+
} }, h("co-icon", { name: "x", size: 10, weight: "bold" }))))), h("input", { key: 'd00091dd6ba08d3924a00965b769eec12bade9da', class: "co-command-search__input", type: "text", placeholder: this.placeholder, value: this.query, onInput: this.handleInput, onKeyDown: this.handleKeyDown, ref: el => (this.inputEl = el), part: "input", role: "combobox", "aria-expanded": this.open ? 'true' : 'false', "aria-autocomplete": "list" }), this.loading && (h("co-loader", { key: 'b7c60019d203f7575535a0d12525c55441ba9f69', class: "co-command-search__loading", part: "loading", size: "sm" })), h("span", { key: '6bb4a4c2745b060f5fc118ce42eeb233709e6cde', class: "co-command-search__shortcut" }, "ESC")), (this.parsedTabs.length > 0 || this.hasMore) && (h("div", { key: 'bc77af8a7d44a3156af87c1e0fb16392acca7aa8', class: "co-command-search__tabs", part: "tabs", role: "tablist" }, this.parsedTabs.map(tab => {
|
|
183
164
|
const active = tab.value === this.activeTab;
|
|
184
165
|
return (h("co-chip", { class: "co-command-search__tab", role: "tab", "aria-selected": active ? 'true' : 'false', clickable: true, selected: active, variant: active ? 'filled' : 'outlined', color: active ? 'primary' : 'default', iconLeft: tab.icon, label: tab.label, onCoClick: () => this.coTabSelect.emit(active ? '' : tab.value) }));
|
|
185
|
-
}), this.hasMore && (h("co-chip", { key: '
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
'co-command-search__item': true,
|
|
190
|
-
'co-command-search__item--active': row.index === this.activeIndex,
|
|
191
|
-
}, part: "item", role: "option", id: 'co-cmd-opt-' + row.index, "aria-selected": row.index === this.activeIndex ? 'true' : 'false', onClick: () => this.selectItem(row.item), onMouseEnter: () => { this.activeIndex = row.index; } }, row.item.icon && h("co-icon", { name: row.item.icon, size: 18 }), h("span", { class: "co-command-search__item-text" }, h("span", { class: "co-command-search__item-label" }, this.renderLabel(row.item.label)), row.item.subtitle && (h("span", { class: "co-command-search__item-subtitle" }, row.item.subtitle))))))
|
|
192
|
-
: !this.loading && (h("div", { class: "co-command-search__empty", part: "empty" }, this.emptyMessage))))),
|
|
166
|
+
}), this.hasMore && (h("co-chip", { key: 'ac6931618eacc84c32006f53c8e0c5bbfec3d929', class: "co-command-search__tab co-command-search__tab--more", clickable: true, variant: "outlined", label: this.moreLabel, iconRight: "caret-down", onCoClick: () => this.coMoreTabs.emit() })))), h("div", { key: 'cd70456639c4e41268ddfff11f921c7a1dbede7e', class: "co-command-search__results", part: "results" }, this.parsedFavorites.length > 0 && !this.query && (h("div", { key: '024125d66406fb564e972f207f10972e7bbd944f', class: "co-command-search__fav", part: "favorites" }, h("div", { key: '9b165c53215a7818efe9ca3ee7d601df25f03e7e', class: "co-command-search__fav-grid" }, this.parsedFavorites.map(fav => (h("button", { class: "co-command-search__fav-card", type: "button", onClick: () => this.coSelect.emit(fav.value) }, h("span", { class: "co-command-search__fav-icon", style: { background: fav.color || 'var(--co-semantic-surface-muted)' } }, h("co-icon", { name: fav.icon || 'circle', size: 26, weight: "fill" })), h("span", { class: "co-command-search__fav-label" }, fav.label))))))), h("co-option-list", { key: 'f1f97b1606aaafab94cc8f9d2ab66ce4948cae0b', ref: (el) => (this.optionListEl = el), items: JSON.stringify(items.map((it) => ({
|
|
167
|
+
_id: it.value, label: it.label, icon: it.icon, description: it.subtitle, group: it.section,
|
|
168
|
+
disabled: it.disabled,
|
|
169
|
+
}))), autoHighlight: true, highlightMatches: true, highlightTerm: this.query, loading: this.loading, emptyMessage: this.emptyMessage, onCoChange: (e) => this.handleListPick(e.detail.item._id) })))),
|
|
193
170
|
];
|
|
194
171
|
}
|
|
195
172
|
static get is() { return "co-command-search"; }
|
|
@@ -254,10 +231,9 @@ export class CoCommandSearch {
|
|
|
254
231
|
"resolved": "CommandItem[] | string",
|
|
255
232
|
"references": {
|
|
256
233
|
"CommandItem": {
|
|
257
|
-
"location": "
|
|
258
|
-
"path": "
|
|
259
|
-
"id": "src/components/co-command-search/
|
|
260
|
-
"referenceLocation": "CommandItem"
|
|
234
|
+
"location": "local",
|
|
235
|
+
"path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-command-search/co-command-search.tsx",
|
|
236
|
+
"id": "src/components/co-command-search/co-command-search.tsx::CommandItem"
|
|
261
237
|
}
|
|
262
238
|
}
|
|
263
239
|
},
|
|
@@ -457,8 +433,7 @@ export class CoCommandSearch {
|
|
|
457
433
|
}
|
|
458
434
|
static get states() {
|
|
459
435
|
return {
|
|
460
|
-
"query": {}
|
|
461
|
-
"activeIndex": {}
|
|
436
|
+
"query": {}
|
|
462
437
|
};
|
|
463
438
|
}
|
|
464
439
|
static get events() {
|
|
@@ -493,8 +468,8 @@ export class CoCommandSearch {
|
|
|
493
468
|
"references": {}
|
|
494
469
|
}
|
|
495
470
|
}, {
|
|
496
|
-
"method": "
|
|
497
|
-
"name": "
|
|
471
|
+
"method": "coSearch",
|
|
472
|
+
"name": "coSearch",
|
|
498
473
|
"bubbles": true,
|
|
499
474
|
"cancelable": true,
|
|
500
475
|
"composed": true,
|
|
@@ -59,7 +59,8 @@ co-data-table {
|
|
|
59
59
|
|
|
60
60
|
.co-data-table__th {
|
|
61
61
|
position: relative;
|
|
62
|
-
|
|
62
|
+
height: 40px; /* Figma header 40 — altura dura, centrado por flex/vertical-align */
|
|
63
|
+
padding: 0 var(--co-spacing-md);
|
|
63
64
|
background: var(--co-color-base-blanco);
|
|
64
65
|
border-bottom: 1px solid var(--co-color-opacity-negro-8);
|
|
65
66
|
border-right: 1px solid var(--co-color-opacity-negro-8);
|
|
@@ -69,6 +70,7 @@ co-data-table {
|
|
|
69
70
|
font-weight: 500;
|
|
70
71
|
color: var(--co-semantic-text-default);
|
|
71
72
|
letter-spacing: var(--co-font-letter-spacing-body);
|
|
73
|
+
line-height: 1; /* Figma Btn3/Medium lh 1 — cierra el header en 40px */
|
|
72
74
|
white-space: nowrap;
|
|
73
75
|
overflow: hidden;
|
|
74
76
|
box-sizing: border-box;
|
|
@@ -122,6 +124,35 @@ co-data-table {
|
|
|
122
124
|
color: var(--co-semantic-text-default);
|
|
123
125
|
}
|
|
124
126
|
|
|
127
|
+
/* ─── COLUMN FILTER ICON (hover-reveal como el pin; --active/--indirect persistentes) ── */
|
|
128
|
+
.co-data-table__filter-icon {
|
|
129
|
+
display: flex;
|
|
130
|
+
align-items: center;
|
|
131
|
+
flex-shrink: 0;
|
|
132
|
+
color: var(--co-color-gray-300);
|
|
133
|
+
cursor: pointer;
|
|
134
|
+
opacity: 0;
|
|
135
|
+
transition: opacity 0.15s ease, color 0.15s ease;
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
.co-data-table__th:hover .co-data-table__filter-icon {
|
|
139
|
+
opacity: 1;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
.co-data-table__filter-icon:hover {
|
|
143
|
+
color: var(--co-semantic-text-default);
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
.co-data-table__filter-icon--active {
|
|
147
|
+
opacity: 1;
|
|
148
|
+
color: var(--co-color-primary-azul);
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
.co-data-table__filter-icon--indirect {
|
|
152
|
+
opacity: 0.45;
|
|
153
|
+
color: var(--co-semantic-text-muted);
|
|
154
|
+
}
|
|
155
|
+
|
|
125
156
|
.co-data-table__th-label {
|
|
126
157
|
flex: 1;
|
|
127
158
|
overflow: hidden;
|
|
@@ -171,8 +202,10 @@ co-data-table {
|
|
|
171
202
|
width: 48px;
|
|
172
203
|
min-width: 48px;
|
|
173
204
|
max-width: 48px;
|
|
174
|
-
padding:
|
|
205
|
+
/* Solo padding horizontal: el alto lo fijan header (40) y fila (48). */
|
|
206
|
+
padding: 0 var(--co-spacing-md);
|
|
175
207
|
text-align: center;
|
|
208
|
+
line-height: 0; /* el co-checkbox inline mete baseline-gap y estira el header a 43 */
|
|
176
209
|
}
|
|
177
210
|
|
|
178
211
|
/* ─── STICKY COLUMNS ───────────────────────────────────────── */
|
|
@@ -258,6 +291,7 @@ co-data-table {
|
|
|
258
291
|
border-right: 1px solid var(--co-color-opacity-negro-8);
|
|
259
292
|
vertical-align: middle;
|
|
260
293
|
font-size: var(--co-font-size-12);
|
|
294
|
+
font-weight: var(--co-font-weight-medium); /* Figma Btn4/Medium para contenido de celda */
|
|
261
295
|
color: var(--co-semantic-text-default);
|
|
262
296
|
letter-spacing: var(--co-font-letter-spacing-body);
|
|
263
297
|
white-space: nowrap;
|
|
@@ -308,7 +342,7 @@ co-data-table {
|
|
|
308
342
|
flex: 1;
|
|
309
343
|
min-height: 280px;
|
|
310
344
|
padding: var(--co-spacing-3xl) var(--co-spacing-lg);
|
|
311
|
-
gap: var(--co-spacing-
|
|
345
|
+
gap: var(--co-spacing-lg) /* Figma: 16 entre título y subtítulo */;
|
|
312
346
|
}
|
|
313
347
|
|
|
314
348
|
.co-data-table__empty-icon {
|
|
@@ -324,11 +358,11 @@ co-data-table {
|
|
|
324
358
|
}
|
|
325
359
|
|
|
326
360
|
.co-data-table__empty-title {
|
|
327
|
-
font-size: var(--co-font-size-
|
|
328
|
-
font-weight:
|
|
361
|
+
font-size: var(--co-font-size-24); /* Figma H5/Medium */
|
|
362
|
+
font-weight: var(--co-font-weight-medium, 500);
|
|
363
|
+
line-height: 1.25;
|
|
329
364
|
color: var(--co-semantic-text-default);
|
|
330
365
|
letter-spacing: -0.03em;
|
|
331
|
-
margin: 0;
|
|
332
366
|
}
|
|
333
367
|
|
|
334
368
|
.co-data-table__empty-message {
|
|
@@ -336,7 +370,8 @@ co-data-table {
|
|
|
336
370
|
font-weight: 400;
|
|
337
371
|
color: var(--co-semantic-text-secondary);
|
|
338
372
|
margin: 0;
|
|
339
|
-
max-width:
|
|
373
|
+
max-width: 538px /* Figma */;
|
|
374
|
+
line-height: 1.25;
|
|
340
375
|
}
|
|
341
376
|
|
|
342
377
|
.co-data-table__empty-action {
|