@prolibu-suite/cobalt-core 0.10.3 → 0.11.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/custom-elements.json +4385 -389
- package/dist/cjs/co-accordion.cjs.entry.js +3 -3
- package/dist/cjs/co-action-bar.cjs.entry.js +3 -3
- package/dist/cjs/co-app-shell.cjs.entry.js +3 -3
- package/dist/cjs/co-audio-player.cjs.entry.js +4 -4
- package/dist/cjs/co-autocomplete.cjs.entry.js +2 -2
- package/dist/cjs/co-avatar-group.cjs.entry.js +1 -1
- package/dist/cjs/co-avatar.cjs.entry.js +7 -4
- package/dist/cjs/co-badge.cjs.entry.js +2 -2
- package/dist/cjs/co-bottom-sheet.cjs.entry.js +5 -5
- 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 +9 -7
- package/dist/cjs/co-calendar-month_2.cjs.entry.js +4 -4
- package/dist/cjs/co-calendar_3.cjs.entry.js +72 -27
- package/dist/cjs/co-card.cjs.entry.js +3 -3
- package/dist/cjs/co-carousel-item.cjs.entry.js +2 -2
- package/dist/cjs/co-carousel.cjs.entry.js +3 -3
- package/dist/cjs/co-checkbox-group.cjs.entry.js +1 -1
- package/dist/cjs/co-checkbox.cjs.entry.js +13 -5
- package/dist/cjs/co-chip_2.cjs.entry.js +28 -6
- package/dist/cjs/co-color-area.cjs.entry.js +169 -0
- package/dist/cjs/co-color-picker.cjs.entry.js +5 -5
- package/dist/cjs/co-color-slider.cjs.entry.js +189 -0
- package/dist/cjs/co-column-picker.cjs.entry.js +3 -3
- package/dist/cjs/co-combobox.cjs.entry.js +5 -5
- package/dist/cjs/co-command-search.cjs.entry.js +5 -5
- package/dist/cjs/co-data-table-pagination.cjs.entry.js +5 -5
- package/dist/cjs/co-data-table.cjs.entry.js +3 -3
- package/dist/cjs/co-date-picker.cjs.entry.js +2 -2
- package/dist/cjs/co-date-range-picker.cjs.entry.js +2 -2
- package/dist/cjs/co-date-range.cjs.entry.js +2 -2
- package/dist/cjs/co-date-time-picker.cjs.entry.js +4 -4
- package/dist/cjs/co-document-editor.cjs.entry.js +1161 -0
- 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-emoji-picker.cjs.entry.js +3 -3
- package/dist/cjs/co-empty-state.cjs.entry.js +3 -3
- package/dist/cjs/co-event-calendar.cjs.entry.js +3 -3
- package/dist/cjs/co-event-popover.cjs.entry.js +3 -3
- package/dist/cjs/co-fab.cjs.entry.js +3 -3
- package/dist/cjs/co-file-field.cjs.entry.js +8 -8
- package/dist/cjs/co-file-type-tile.cjs.entry.js +3 -3
- package/dist/cjs/co-gradient-bar.cjs.entry.js +220 -0
- package/dist/cjs/co-helper-text.cjs.entry.js +3 -3
- package/dist/cjs/co-icon-button.cjs.entry.js +49 -9
- package/dist/cjs/co-icon.cjs.entry.js +3 -3
- package/dist/cjs/co-input.cjs.entry.js +14 -8
- package/dist/cjs/co-json-field.cjs.entry.js +5 -5
- package/dist/cjs/{co-tooltip.cjs.entry.js → co-kbd_2.cjs.entry.js} +194 -6
- package/dist/cjs/co-lightbox.cjs.entry.js +5 -5
- 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 +3 -3
- package/dist/cjs/co-menu-item.cjs.entry.js +41 -43
- package/dist/cjs/co-menu.cjs.entry.js +81 -5
- package/dist/cjs/co-modal.cjs.entry.js +350 -7
- 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 +8 -4
- package/dist/cjs/co-page-header.cjs.entry.js +2 -2
- package/dist/cjs/co-phone-field.cjs.entry.js +3 -3
- package/dist/cjs/co-popover.cjs.entry.js +81 -6
- package/dist/cjs/co-progress-bar.cjs.entry.js +3 -3
- package/dist/cjs/co-progress-circle.cjs.entry.js +3 -3
- package/dist/cjs/co-provider-logo_2.cjs.entry.js +2 -2
- 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 +5 -5
- package/dist/cjs/co-rich-text-editor.cjs.entry.js +26 -92
- package/dist/cjs/co-rich-text-toolbar.cjs.entry.js +79 -20
- package/dist/cjs/co-rich-text-viewer.cjs.entry.js +9 -2
- 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 +158 -29
- package/dist/cjs/co-separator.cjs.entry.js +2 -2
- package/dist/cjs/co-sidebar-nav.cjs.entry.js +20 -5
- package/dist/cjs/co-sidebar.cjs.entry.js +3 -3
- package/dist/cjs/co-slider.cjs.entry.js +203 -23
- package/dist/cjs/co-swatch-grid.cjs.entry.js +121 -0
- package/dist/cjs/co-switch.cjs.entry.js +5 -5
- package/dist/cjs/co-tab-group.cjs.entry.js +113 -4
- package/dist/cjs/co-tab.cjs.entry.js +15 -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-tile.cjs.entry.js +61 -0
- package/dist/cjs/co-time-field.cjs.entry.js +2 -2
- package/dist/cjs/co-toast.cjs.entry.js +3 -3
- package/dist/cjs/co-toggle-button-group.cjs.entry.js +26 -5
- package/dist/cjs/co-toggle-button.cjs.entry.js +67 -6
- package/dist/cjs/co-transfer-list.cjs.entry.js +3 -3
- package/dist/cjs/co-tree-item.cjs.entry.js +110 -0
- package/dist/cjs/co-video.cjs.entry.js +3 -3
- package/dist/cjs/cobalt.cjs.js +2 -2
- package/dist/cjs/{color-CML2Cfdh.js → color-DQVrQGi0.js} +10 -5
- package/dist/cjs/{fieldChip-B6YIGU1V.js → fieldChip-C7MxxBVO.js} +1 -1
- package/dist/cjs/gradientStops-CMpH4fB_.js +153 -0
- package/dist/cjs/hsv-DpfSF3M2.js +95 -0
- package/dist/cjs/{index-MDAnKsze.js → index-bHoidDwv.js} +67 -27
- package/dist/cjs/index-oMHzCXm6.js +144 -0
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/{index-2kMmd5-a.js → pagination-DV43TRj9.js} +1780 -297
- package/dist/cjs/{positioning-CyatXeT_.js → positioning-CILo5esi.js} +45 -18
- package/dist/cjs/{requiredMark-D-t-IPN0.js → requiredMark-21yHvvZS.js} +1 -1
- package/dist/cjs/rich-text-host-ueFSfW-6.js +119 -0
- package/dist/cjs/{richTextI18n-B28uAhh4.js → richTextI18n-DXGIv5w1.js} +45 -0
- package/dist/cjs/submenu-RlaX6irw.js +65 -0
- package/dist/cjs/{toolbar-config-CYACt9hh.js → toolbar-config-DczL6C4W.js} +32 -0
- package/dist/cobalt/cobalt.css +1 -1
- package/dist/cobalt/cobalt.esm.js +1 -1
- package/dist/cobalt/{p-ee149fd2.entry.js → p-05000ef3.entry.js} +1 -1
- package/dist/cobalt/p-06689166.entry.js +1 -0
- package/dist/cobalt/{p-1dc55e43.entry.js → p-0a5cfed0.entry.js} +1 -1
- package/dist/cobalt/p-1289131f.entry.js +1 -0
- package/dist/cobalt/{p-c7d7d7f7.entry.js → p-136beb2c.entry.js} +1 -1
- package/dist/cobalt/{p-b437eff6.entry.js → p-1693b614.entry.js} +1 -1
- package/dist/cobalt/p-1bfb69ae.entry.js +1 -0
- package/dist/cobalt/{p-2c9dba2f.entry.js → p-1f3d5313.entry.js} +1 -1
- package/dist/cobalt/{p-b821d9de.entry.js → p-22233b31.entry.js} +1 -1
- package/dist/cobalt/{p-c30b4cb5.entry.js → p-26fa36f8.entry.js} +1 -1
- package/dist/cobalt/p-2794c500.entry.js +1 -0
- package/dist/cobalt/p-297b55cd.entry.js +1 -0
- package/dist/cobalt/{p-17244412.entry.js → p-2a2b0c7a.entry.js} +1 -1
- package/dist/cobalt/{p-2636b7eb.entry.js → p-2e5702a0.entry.js} +1 -1
- package/dist/cobalt/p-3011c84f.entry.js +1 -0
- package/dist/cobalt/{p-4d65e713.entry.js → p-30760f77.entry.js} +1 -1
- package/dist/cobalt/{p-6dd220e0.entry.js → p-3b9a8e86.entry.js} +1 -1
- package/dist/cobalt/p-4111fefa.entry.js +1 -0
- package/dist/cobalt/{p-a32b20eb.entry.js → p-44edde81.entry.js} +1 -1
- package/dist/cobalt/{p-292b0389.entry.js → p-45007758.entry.js} +1 -1
- package/dist/cobalt/p-48c23310.entry.js +1 -0
- package/dist/cobalt/p-4b327483.entry.js +1 -0
- package/dist/cobalt/p-4c6caa41.entry.js +1 -0
- package/dist/cobalt/{p-000a15b8.entry.js → p-5534a64f.entry.js} +1 -1
- package/dist/cobalt/p-5573985a.entry.js +1 -0
- package/dist/cobalt/p-57d250ad.entry.js +1 -0
- package/dist/cobalt/{p-826ee074.entry.js → p-59d3e8fc.entry.js} +1 -1
- package/dist/cobalt/{p-4592ca00.entry.js → p-5a32b9a2.entry.js} +1 -1
- package/dist/cobalt/p-5b2aa70e.entry.js +1 -0
- package/dist/cobalt/{p-d29bb0fa.entry.js → p-5d6e02dd.entry.js} +1 -1
- package/dist/cobalt/{p-623cc195.entry.js → p-608d251d.entry.js} +1 -1
- package/dist/cobalt/{p-011dc80b.entry.js → p-66fc1528.entry.js} +1 -1
- package/dist/cobalt/{p-11c5ce78.entry.js → p-67ad9544.entry.js} +1 -1
- package/dist/cobalt/{p-290066ef.entry.js → p-6c157ea2.entry.js} +1 -1
- package/dist/cobalt/{p-a2462d7a.entry.js → p-6d541199.entry.js} +1 -1
- package/dist/cobalt/{p-58d9b650.entry.js → p-7376f4ed.entry.js} +1 -1
- package/dist/cobalt/{p-39a50e7f.entry.js → p-7569375a.entry.js} +1 -1
- package/dist/cobalt/{p-7b5c555c.entry.js → p-763698b3.entry.js} +1 -1
- package/dist/cobalt/{p-f57dffca.entry.js → p-7675cebe.entry.js} +1 -1
- package/dist/cobalt/p-78a20284.entry.js +1 -0
- package/dist/cobalt/{p-aa9400bf.entry.js → p-7f3523ce.entry.js} +1 -1
- package/dist/cobalt/{p-24196410.entry.js → p-86b6fd81.entry.js} +1 -1
- package/dist/cobalt/{p-996f4e38.entry.js → p-889563d5.entry.js} +1 -1
- package/dist/cobalt/{p-eadfd661.entry.js → p-8ab5b396.entry.js} +1 -1
- package/dist/cobalt/{p-c91d4fc6.entry.js → p-8b2e4579.entry.js} +1 -1
- package/dist/cobalt/p-8cd3acaa.entry.js +1 -0
- package/dist/cobalt/{p-23ab0cc5.entry.js → p-8f701eac.entry.js} +1 -1
- package/dist/cobalt/p-90fad0f9.entry.js +1 -0
- package/dist/cobalt/{p-76249983.entry.js → p-97a4fbba.entry.js} +1 -1
- package/dist/cobalt/p-9b46a8fe.entry.js +1 -0
- package/dist/cobalt/{p-ee2023da.entry.js → p-9bee9dc8.entry.js} +1 -1
- package/dist/cobalt/{p-2f9cbbd5.entry.js → p-9cf10331.entry.js} +1 -1
- package/dist/cobalt/p-9dc01092.entry.js +1 -0
- package/dist/cobalt/p-9e406172.entry.js +1 -0
- package/dist/cobalt/p-B1JT7us1.js +1 -0
- package/dist/cobalt/{p-BRbgGqLw.js → p-BVGGRfNG.js} +1 -1
- package/dist/cobalt/p-BmdKHBZP.js +1 -0
- package/dist/cobalt/p-BtliEQAT.js +1 -0
- package/dist/cobalt/p-COJdaKBU.js +1 -0
- package/dist/cobalt/{p-BAYo-RBt.js → p-CRxTFT_z.js} +1 -1
- package/dist/cobalt/p-CYN5B3IQ.js +1 -0
- package/dist/cobalt/p-DJkaRtbb.js +2 -0
- package/dist/cobalt/p-DU-KOQ8L.js +1 -0
- package/dist/cobalt/p-DXLeDZvr.js +1 -0
- package/dist/cobalt/{p-D_zA1Pv4.js → p-DgJovDdy.js} +1 -1
- package/dist/cobalt/p-RVQJEYxa.js +1 -0
- package/dist/cobalt/{p-1861fe41.entry.js → p-a07dedd1.entry.js} +1 -1
- package/dist/cobalt/{p-08e42e00.entry.js → p-a336178b.entry.js} +1 -1
- package/dist/cobalt/{p-f9a7b7c6.entry.js → p-a52ed6ff.entry.js} +1 -1
- package/dist/cobalt/{p-aaca6dab.entry.js → p-a930cdd7.entry.js} +1 -1
- package/dist/cobalt/{p-eb82358d.entry.js → p-b1994bb4.entry.js} +1 -1
- package/dist/cobalt/p-b2b13da8.entry.js +1 -0
- package/dist/cobalt/{p-c2ebf0ec.entry.js → p-b5ec4286.entry.js} +1 -1
- package/dist/cobalt/p-b9401dd7.entry.js +1 -0
- package/dist/cobalt/p-b9dfb333.entry.js +1 -0
- package/dist/cobalt/p-bc3ba0cd.entry.js +1 -0
- package/dist/cobalt/{p-d375014b.entry.js → p-bc4fbfa6.entry.js} +1 -1
- package/dist/cobalt/{p-d0b2c418.entry.js → p-c109a1e1.entry.js} +1 -1
- package/dist/cobalt/{p-ee9a623d.entry.js → p-c1caa112.entry.js} +1 -1
- package/dist/cobalt/p-c9990662.entry.js +1 -0
- package/dist/cobalt/p-cc4b51fa.entry.js +1 -0
- package/dist/cobalt/p-cc5989e9.entry.js +1 -0
- package/dist/cobalt/{p-e4264532.entry.js → p-ce2b2048.entry.js} +1 -1
- package/dist/cobalt/p-d1c378ff.entry.js +1 -0
- package/dist/cobalt/p-d1e83525.entry.js +1 -0
- package/dist/cobalt/{p-59963937.entry.js → p-d1f47915.entry.js} +1 -1
- package/dist/cobalt/{p-28764b8e.entry.js → p-d4979025.entry.js} +1 -1
- package/dist/cobalt/p-d6e7c258.entry.js +1 -0
- package/dist/cobalt/p-d75d2f3d.entry.js +1 -0
- package/dist/cobalt/p-db42c4ab.entry.js +1 -0
- package/dist/cobalt/{p-44c4e4a3.entry.js → p-e4ff2fcb.entry.js} +1 -1
- package/dist/cobalt/p-e6116149.entry.js +1 -0
- package/dist/cobalt/{p-0c004735.entry.js → p-e99ddf9c.entry.js} +1 -1
- package/dist/cobalt/{p-1cc818ca.entry.js → p-ea24eea8.entry.js} +1 -1
- package/dist/cobalt/{p-07416e31.entry.js → p-ea564148.entry.js} +1 -1
- package/dist/cobalt/{p-8471abe2.entry.js → p-ec7a6bf2.entry.js} +1 -1
- package/dist/cobalt/{p-fb2d1144.entry.js → p-ee42dca6.entry.js} +1 -1
- package/dist/cobalt/{p-49834b8e.entry.js → p-ee88ec40.entry.js} +1 -1
- package/dist/cobalt/p-eeb114da.entry.js +1 -0
- package/dist/cobalt/{p-f6691108.entry.js → p-f0898e21.entry.js} +1 -1
- package/dist/cobalt/p-f246946a.entry.js +1 -0
- package/dist/cobalt/{p-b90d41e4.entry.js → p-f5934cd9.entry.js} +1 -1
- package/dist/cobalt/p-f5e1873d.entry.js +1 -0
- package/dist/cobalt/p-f60bd4d6.entry.js +1 -0
- package/dist/cobalt/p-f813569c.entry.js +1 -0
- package/dist/cobalt/{p-f7eb1a40.entry.js → p-f8c7941f.entry.js} +1 -1
- package/dist/cobalt/{p-44ea675f.entry.js → p-f8d3c71e.entry.js} +1 -1
- package/dist/cobalt/{p-91e73a92.entry.js → p-ffbe955a.entry.js} +1 -1
- package/dist/cobalt/p-xnrKkNWQ.js +1 -0
- package/dist/collection/collection-manifest.json +8 -0
- package/dist/collection/components/co-accordion/co-accordion.js +2 -2
- package/dist/collection/components/co-action-bar/co-action-bar.js +2 -2
- package/dist/collection/components/co-app-shell/co-app-shell.js +2 -2
- package/dist/collection/components/co-audio-player/co-audio-player.js +3 -3
- package/dist/collection/components/co-autocomplete/co-autocomplete.js +1 -1
- package/dist/collection/components/co-avatar/co-avatar.css +11 -2
- package/dist/collection/components/co-avatar/co-avatar.js +7 -4
- package/dist/collection/components/co-avatar-group/co-avatar-group.js +1 -1
- package/dist/collection/components/co-badge/co-badge.js +1 -1
- package/dist/collection/components/co-bottom-sheet/co-bottom-sheet.js +4 -4
- 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.css +73 -6
- package/dist/collection/components/co-button/co-button.js +33 -11
- package/dist/collection/components/co-button-group/co-button-group.js +2 -2
- package/dist/collection/components/co-calendar/calendarMarks.js +40 -0
- package/dist/collection/components/co-calendar/co-calendar.css +11 -1
- package/dist/collection/components/co-calendar/co-calendar.js +82 -20
- package/dist/collection/components/co-calendar-month/co-calendar-month.js +1 -1
- package/dist/collection/components/co-calendar-timegrid/co-calendar-timegrid.js +2 -2
- package/dist/collection/components/co-card/co-card.js +2 -2
- package/dist/collection/components/co-carousel/co-carousel.js +2 -2
- package/dist/collection/components/co-carousel-item/co-carousel-item.js +1 -1
- package/dist/collection/components/co-checkbox/co-checkbox.css +43 -1
- package/dist/collection/components/co-checkbox/co-checkbox.js +31 -3
- package/dist/collection/components/co-checkbox-group/co-checkbox-group.js +1 -1
- package/dist/collection/components/co-chip/co-chip.js +2 -2
- package/dist/collection/components/co-color-area/co-color-area.css +83 -0
- package/dist/collection/components/co-color-area/co-color-area.js +341 -0
- package/dist/collection/components/co-color-picker/co-color-picker.js +2 -2
- package/dist/collection/components/co-color-slider/co-color-slider.css +115 -0
- package/dist/collection/components/co-color-slider/co-color-slider.js +353 -0
- package/dist/collection/components/co-column-picker/co-column-picker.js +2 -2
- package/dist/collection/components/co-combobox/co-combobox.js +4 -4
- package/dist/collection/components/co-command-search/co-command-search.js +5 -5
- package/dist/collection/components/co-data-table/co-data-table.js +3 -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.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.js +2 -2
- package/dist/collection/components/co-date-time-picker/co-date-time-picker.js +3 -3
- package/dist/collection/components/co-document-editor/change-throttle.js +30 -0
- package/dist/collection/components/co-document-editor/co-document-editor.css +438 -0
- package/dist/collection/components/co-document-editor/co-document-editor.js +1542 -0
- package/dist/collection/components/co-document-editor/document-props.js +40 -0
- package/dist/collection/components/co-document-editor/header-tools.js +11 -0
- package/dist/collection/components/co-document-editor/image-bar.js +66 -0
- package/dist/collection/components/co-document-editor/page-styles.js +90 -0
- package/dist/collection/components/co-document-editor/zoom.js +45 -0
- 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-emoji-picker/co-emoji-picker.js +2 -2
- 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-event-popover/co-event-popover.js +1 -1
- package/dist/collection/components/co-fab/co-fab.js +2 -2
- package/dist/collection/components/co-file-field/co-file-field.js +6 -6
- package/dist/collection/components/co-file-type-tile/co-file-type-tile.js +2 -2
- package/dist/collection/components/co-gradient-bar/co-gradient-bar.css +138 -0
- package/dist/collection/components/co-gradient-bar/co-gradient-bar.js +407 -0
- 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.css +95 -19
- package/dist/collection/components/co-icon-button/co-icon-button.js +120 -10
- package/dist/collection/components/co-input/co-input.css +122 -0
- package/dist/collection/components/co-input/co-input.js +37 -11
- package/dist/collection/components/co-json-field/co-json-field.js +3 -3
- package/dist/collection/components/co-kbd/co-kbd.css +99 -0
- package/dist/collection/components/co-kbd/co-kbd.js +291 -0
- 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.css +60 -0
- package/dist/collection/components/co-menu/co-menu.js +143 -3
- package/dist/collection/components/co-menu-divider/co-menu-divider.css +17 -0
- package/dist/collection/components/co-menu-divider/co-menu-divider.js +1 -1
- package/dist/collection/components/co-menu-item/co-menu-item.css +42 -6
- package/dist/collection/components/co-menu-item/co-menu-item.js +58 -4
- package/dist/collection/components/co-modal/co-modal.css +212 -1
- package/dist/collection/components/co-modal/co-modal.js +339 -9
- package/dist/collection/components/co-navbar/co-navbar.js +2 -2
- package/dist/collection/components/co-number-field/co-number-field.js +3 -3
- package/dist/collection/components/co-option-list/co-option-list.css +64 -21
- package/dist/collection/components/co-option-list/co-option-list.js +43 -3
- package/dist/collection/components/co-overlay/co-overlay.js +7 -3
- package/dist/collection/components/co-page-header/co-page-header.js +1 -1
- package/dist/collection/components/co-phone-field/co-phone-field.js +1 -1
- package/dist/collection/components/co-popover/co-popover.css +15 -2
- package/dist/collection/components/co-popover/co-popover.js +144 -5
- 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 +4 -4
- package/dist/collection/components/co-rating/co-rating.js +3 -3
- package/dist/collection/components/co-ref-field/co-ref-field.js +5 -5
- package/dist/collection/components/co-rich-text-editor/co-rich-text-editor.js +23 -90
- package/dist/collection/components/co-rich-text-toolbar/co-rich-text-toolbar.css +12 -0
- package/dist/collection/components/co-rich-text-toolbar/co-rich-text-toolbar.js +123 -18
- package/dist/collection/components/co-rich-text-viewer/co-rich-text-viewer.js +8 -1
- package/dist/collection/components/co-row/co-row.js +2 -2
- package/dist/collection/components/co-segmented-bar/co-segmented-bar.js +3 -3
- package/dist/collection/components/co-select/co-select.css +194 -10
- package/dist/collection/components/co-select/co-select.js +163 -32
- package/dist/collection/components/co-select/virtualRows.js +57 -0
- 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 +10 -0
- package/dist/collection/components/co-sidebar-nav/co-sidebar-nav.js +19 -4
- package/dist/collection/components/co-skeleton/co-skeleton.js +1 -1
- package/dist/collection/components/co-slider/co-slider.css +148 -5
- package/dist/collection/components/co-slider/co-slider.js +240 -21
- package/dist/collection/components/co-swatch-grid/co-swatch-grid.css +56 -0
- package/dist/collection/components/co-swatch-grid/co-swatch-grid.js +292 -0
- package/dist/collection/components/co-switch/co-switch.js +3 -3
- package/dist/collection/components/co-tab/co-tab.css +60 -0
- package/dist/collection/components/co-tab/co-tab.js +36 -6
- package/dist/collection/components/co-tab-group/co-tab-group.css +24 -0
- package/dist/collection/components/co-tab-group/co-tab-group.js +124 -2
- package/dist/collection/components/co-tab-group/revealTab.js +26 -0
- 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-tile/co-tile.css +63 -0
- package/dist/collection/components/co-tile/co-tile.js +162 -0
- package/dist/collection/components/co-time-field/co-time-field.js +1 -1
- package/dist/collection/components/co-toast/co-toast.js +4 -4
- package/dist/collection/components/co-toggle-button/co-toggle-button.css +101 -0
- package/dist/collection/components/co-toggle-button/co-toggle-button.js +80 -8
- package/dist/collection/components/co-toggle-button-group/co-toggle-button-group.css +21 -0
- package/dist/collection/components/co-toggle-button-group/co-toggle-button-group.js +28 -7
- package/dist/collection/components/co-tooltip/co-tooltip.css +36 -0
- package/dist/collection/components/co-tooltip/co-tooltip.js +51 -3
- package/dist/collection/components/co-transfer-list/co-transfer-list.js +3 -3
- package/dist/collection/components/co-tree-item/co-tree-item.css +226 -0
- package/dist/collection/components/co-tree-item/co-tree-item.js +353 -0
- package/dist/collection/components/co-tree-item/treeItemI18n.js +16 -0
- package/dist/collection/components/co-video/co-video.js +2 -2
- package/dist/collection/utils/color.js +9 -5
- package/dist/collection/utils/dragMove.js +95 -0
- package/dist/collection/utils/gradientBarI18n.js +24 -0
- package/dist/collection/utils/gradientStops.js +142 -0
- package/dist/collection/utils/hsv.js +114 -0
- package/dist/collection/utils/kbdI18n.js +29 -0
- package/dist/collection/utils/positioning.js +44 -18
- package/dist/collection/utils/rich-text-host.js +109 -0
- package/dist/collection/utils/richTextI18n.js +45 -0
- package/dist/collection/utils/submenu.js +23 -3
- package/dist/collection/utils/swatchGridI18n.js +14 -0
- package/dist/collection/utils/test/fake-block-layout.js +41 -0
- package/dist/collection/utils/test/prosemirror-dom-shim.js +17 -0
- package/dist/collection/utils/test/shared-contract-css.js +9 -0
- package/dist/components/co-accordion.js +1 -1
- package/dist/components/co-action-bar.js +1 -1
- package/dist/components/co-app-shell.js +1 -1
- package/dist/components/co-audio-player.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-timegrid.js +1 -1
- package/dist/components/co-calendar.js +1 -1
- package/dist/components/co-card.js +1 -1
- package/dist/components/co-carousel-item.js +1 -1
- package/dist/components/co-carousel.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-area.d.ts +11 -0
- package/dist/components/co-color-area.js +1 -0
- package/dist/components/co-color-picker.js +1 -1
- package/dist/components/co-color-slider.d.ts +11 -0
- package/dist/components/co-color-slider.js +1 -0
- 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-date-time-picker.js +1 -1
- package/dist/components/co-document-editor.d.ts +11 -0
- package/dist/components/co-document-editor.js +1 -0
- 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-emoji-picker.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-event-popover.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-gradient-bar.d.ts +11 -0
- package/dist/components/co-gradient-bar.js +1 -0
- 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-kbd.d.ts +11 -0
- package/dist/components/co-kbd.js +1 -0
- 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-rich-text-viewer.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-swatch-grid.d.ts +11 -0
- package/dist/components/co-swatch-grid.js +1 -0
- 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-tile.d.ts +11 -0
- package/dist/components/co-tile.js +1 -0
- package/dist/components/co-time-field.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-tree-item.d.ts +11 -0
- package/dist/components/co-tree-item.js +1 -0
- package/dist/components/co-video.js +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/p-B1JT7us1.js +1 -0
- package/dist/components/{p-Nt4JJxbL.js → p-B20o5exO.js} +1 -1
- package/dist/components/{p-DNJAIVfI.js → p-B3kKOgsA.js} +1 -1
- package/dist/components/{p-P4HlMBlL.js → p-BIDSDP05.js} +1 -1
- package/dist/components/p-BOqtnWTJ.js +1 -0
- package/dist/components/p-BQltjDw5.js +1 -0
- package/dist/components/p-BR0LYW9v.js +1 -0
- package/dist/components/{p-BRbgGqLw.js → p-BVGGRfNG.js} +1 -1
- package/dist/components/p-BZDl9aFl.js +1 -0
- package/dist/components/p-BcXdId8y.js +1 -0
- package/dist/components/p-BmdKHBZP.js +1 -0
- package/dist/components/{p-NNxjElcX.js → p-BraiMwgs.js} +1 -1
- package/dist/components/p-BtliEQAT.js +1 -0
- package/dist/components/p-Bymi-A7C.js +1 -0
- package/dist/components/p-C-f8wTqe.js +1 -0
- package/dist/components/{p-BhCVadcA.js → p-C1jZYtUS.js} +1 -1
- package/dist/components/{p-CT2enQ6h.js → p-C3G8oPgU.js} +1 -1
- package/dist/components/{p-cndRd_-U.js → p-CGH3E8uK.js} +1 -1
- package/dist/components/p-COJdaKBU.js +1 -0
- package/dist/components/{p-BAYo-RBt.js → p-CRxTFT_z.js} +1 -1
- package/dist/components/{p-Du_CgT5E.js → p-CfJgypOl.js} +1 -1
- package/dist/components/{p-uxdXViMV.js → p-ChwSnCFf.js} +1 -1
- package/dist/components/{p-Dc_Kbari.js → p-CpGEV0iM.js} +1 -1
- package/dist/components/{p-DvR45CLa.js → p-D9or2g4j.js} +1 -1
- package/dist/components/{p-e5KibEs8.js → p-DJ468fPu.js} +1 -1
- package/dist/components/{p-DFlJMEJ-.js → p-DKXCr-hE.js} +1 -1
- package/dist/components/p-DU-KOQ8L.js +1 -0
- package/dist/components/p-DXLeDZvr.js +1 -0
- package/dist/components/{p-BGDqldEg.js → p-DfcPGitr.js} +1 -1
- package/dist/components/p-Dg-Ti_Bf.js +1 -0
- package/dist/components/p-Dh_eRYKu.js +1 -0
- package/dist/components/p-Dp650Gpp.js +1 -0
- package/dist/components/p-FA1kBmZ-.js +1 -0
- package/dist/components/p-RVQJEYxa.js +1 -0
- package/dist/components/p-d4rf3H8p.js +1 -0
- package/dist/components/{p-Dxa7c4Ap.js → p-dnaee7fS.js} +1 -1
- package/dist/components/p-f2xwcrXa.js +1 -0
- package/dist/esm/co-accordion.entry.js +3 -3
- package/dist/esm/co-action-bar.entry.js +3 -3
- package/dist/esm/co-app-shell.entry.js +3 -3
- package/dist/esm/co-audio-player.entry.js +4 -4
- package/dist/esm/co-autocomplete.entry.js +2 -2
- package/dist/esm/co-avatar-group.entry.js +1 -1
- package/dist/esm/co-avatar.entry.js +7 -4
- package/dist/esm/co-badge.entry.js +2 -2
- package/dist/esm/co-bottom-sheet.entry.js +5 -5
- 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 +9 -7
- package/dist/esm/co-calendar-month_2.entry.js +4 -4
- package/dist/esm/co-calendar_3.entry.js +72 -27
- package/dist/esm/co-card.entry.js +3 -3
- package/dist/esm/co-carousel-item.entry.js +2 -2
- package/dist/esm/co-carousel.entry.js +3 -3
- package/dist/esm/co-checkbox-group.entry.js +1 -1
- package/dist/esm/co-checkbox.entry.js +13 -5
- package/dist/esm/co-chip_2.entry.js +28 -6
- package/dist/esm/co-color-area.entry.js +167 -0
- package/dist/esm/co-color-picker.entry.js +5 -5
- package/dist/esm/co-color-slider.entry.js +187 -0
- package/dist/esm/co-column-picker.entry.js +3 -3
- package/dist/esm/co-combobox.entry.js +5 -5
- package/dist/esm/co-command-search.entry.js +5 -5
- package/dist/esm/co-data-table-pagination.entry.js +5 -5
- package/dist/esm/co-data-table.entry.js +3 -3
- package/dist/esm/co-date-picker.entry.js +2 -2
- package/dist/esm/co-date-range-picker.entry.js +2 -2
- package/dist/esm/co-date-range.entry.js +2 -2
- package/dist/esm/co-date-time-picker.entry.js +4 -4
- package/dist/esm/co-document-editor.entry.js +1159 -0
- package/dist/esm/co-drive-card.entry.js +2 -2
- package/dist/esm/co-drop-zone.entry.js +2 -2
- package/dist/esm/co-emoji-picker.entry.js +3 -3
- package/dist/esm/co-empty-state.entry.js +3 -3
- package/dist/esm/co-event-calendar.entry.js +3 -3
- package/dist/esm/co-event-popover.entry.js +3 -3
- package/dist/esm/co-fab.entry.js +3 -3
- package/dist/esm/co-file-field.entry.js +8 -8
- package/dist/esm/co-file-type-tile.entry.js +3 -3
- package/dist/esm/co-gradient-bar.entry.js +218 -0
- package/dist/esm/co-helper-text.entry.js +3 -3
- package/dist/esm/co-icon-button.entry.js +49 -9
- package/dist/esm/co-icon.entry.js +3 -3
- package/dist/esm/co-input.entry.js +14 -8
- package/dist/esm/co-json-field.entry.js +5 -5
- package/dist/esm/{co-tooltip.entry.js → co-kbd_2.entry.js} +194 -7
- package/dist/esm/co-lightbox.entry.js +5 -5
- 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 +3 -3
- package/dist/esm/co-menu-item.entry.js +39 -41
- package/dist/esm/co-menu.entry.js +81 -5
- package/dist/esm/co-modal.entry.js +350 -7
- 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 +8 -4
- package/dist/esm/co-page-header.entry.js +2 -2
- package/dist/esm/co-phone-field.entry.js +3 -3
- package/dist/esm/co-popover.entry.js +81 -6
- package/dist/esm/co-progress-bar.entry.js +3 -3
- package/dist/esm/co-progress-circle.entry.js +3 -3
- package/dist/esm/co-provider-logo_2.entry.js +2 -2
- 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 +5 -5
- package/dist/esm/co-rich-text-editor.entry.js +26 -92
- package/dist/esm/co-rich-text-toolbar.entry.js +79 -20
- package/dist/esm/co-rich-text-viewer.entry.js +9 -2
- 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 +158 -29
- package/dist/esm/co-separator.entry.js +2 -2
- package/dist/esm/co-sidebar-nav.entry.js +20 -5
- package/dist/esm/co-sidebar.entry.js +3 -3
- package/dist/esm/co-slider.entry.js +203 -23
- package/dist/esm/co-swatch-grid.entry.js +119 -0
- package/dist/esm/co-switch.entry.js +5 -5
- package/dist/esm/co-tab-group.entry.js +113 -4
- package/dist/esm/co-tab.entry.js +15 -5
- package/dist/esm/co-tags-field.entry.js +8 -8
- package/dist/esm/co-textarea.entry.js +6 -6
- package/dist/esm/co-tile.entry.js +59 -0
- package/dist/esm/co-time-field.entry.js +2 -2
- package/dist/esm/co-toast.entry.js +3 -3
- package/dist/esm/co-toggle-button-group.entry.js +26 -5
- package/dist/esm/co-toggle-button.entry.js +67 -6
- package/dist/esm/co-transfer-list.entry.js +3 -3
- package/dist/esm/co-tree-item.entry.js +108 -0
- package/dist/esm/co-video.entry.js +3 -3
- package/dist/esm/cobalt.js +3 -3
- package/dist/esm/{color-BRbgGqLw.js → color-BVGGRfNG.js} +10 -6
- package/dist/esm/{fieldChip-uyggU8VV.js → fieldChip-B2ctp2m6.js} +1 -1
- package/dist/esm/gradientStops-DDK0y8ra.js +145 -0
- package/dist/esm/hsv-COJdaKBU.js +90 -0
- package/dist/esm/index-Cpo8HTwr.js +142 -0
- package/dist/esm/{index-DH5lfRNj.js → index-DJkaRtbb.js} +67 -28
- package/dist/esm/loader.js +3 -3
- package/dist/esm/{index-BBIYyvq-.js → pagination-D9OfZUnY.js} +1728 -297
- package/dist/esm/{positioning-DFHRS9cJ.js → positioning-BtliEQAT.js} +45 -19
- package/dist/esm/{requiredMark-BCJUuZvC.js → requiredMark-D5C5NzOE.js} +1 -1
- package/dist/esm/rich-text-host-BmdKHBZP.js +111 -0
- package/dist/esm/{richTextI18n-BYKAgwq3.js → richTextI18n-xnrKkNWQ.js} +45 -0
- package/dist/esm/submenu-DU-KOQ8L.js +57 -0
- package/dist/esm/{toolbar-config-BAYo-RBt.js → toolbar-config-CRxTFT_z.js} +32 -0
- package/dist/types/components/co-avatar/co-avatar.d.ts +4 -2
- package/dist/types/components/co-button/co-button.d.ts +6 -4
- package/dist/types/components/co-calendar/calendarMarks.d.ts +15 -0
- package/dist/types/components/co-calendar/co-calendar.d.ts +16 -0
- package/dist/types/components/co-checkbox/co-checkbox.d.ts +7 -0
- package/dist/types/components/co-color-area/co-color-area.d.ts +64 -0
- package/dist/types/components/co-color-slider/co-color-slider.d.ts +61 -0
- package/dist/types/components/co-date-time-picker/co-date-time-picker.d.ts +1 -1
- package/dist/types/components/co-document-editor/change-throttle.d.ts +9 -0
- package/dist/types/components/co-document-editor/co-document-editor.d.ts +276 -0
- package/dist/types/components/co-document-editor/document-props.d.ts +6 -0
- package/dist/types/components/co-document-editor/header-tools.d.ts +11 -0
- package/dist/types/components/co-document-editor/image-bar.d.ts +50 -0
- package/dist/types/components/co-document-editor/page-styles.d.ts +1 -0
- package/dist/types/components/co-document-editor/zoom.d.ts +26 -0
- package/dist/types/components/co-gradient-bar/co-gradient-bar.d.ts +72 -0
- package/dist/types/components/co-icon-button/co-icon-button.d.ts +34 -2
- package/dist/types/components/co-input/co-input.d.ts +14 -5
- package/dist/types/components/co-kbd/co-kbd.d.ts +43 -0
- package/dist/types/components/co-menu/co-menu.d.ts +40 -1
- package/dist/types/components/co-menu-item/co-menu-item.d.ts +17 -0
- package/dist/types/components/co-modal/co-modal.d.ts +111 -2
- package/dist/types/components/co-option-list/co-option-list.d.ts +8 -0
- package/dist/types/components/co-option-list/optionListLogic.d.ts +3 -0
- package/dist/types/components/co-popover/co-popover.d.ts +38 -0
- package/dist/types/components/co-rich-text-editor/co-rich-text-editor.d.ts +2 -5
- package/dist/types/components/co-rich-text-toolbar/co-rich-text-toolbar.d.ts +17 -2
- package/dist/types/components/co-select/co-select.d.ts +47 -5
- package/dist/types/components/co-select/virtualRows.d.ts +44 -0
- package/dist/types/components/co-slider/co-slider.d.ts +143 -1
- package/dist/types/components/co-swatch-grid/co-swatch-grid.d.ts +37 -0
- package/dist/types/components/co-tab/co-tab.d.ts +12 -2
- package/dist/types/components/co-tab-group/co-tab-group.d.ts +37 -0
- package/dist/types/components/co-tab-group/revealTab.d.ts +29 -0
- package/dist/types/components/co-tile/co-tile.d.ts +40 -0
- package/dist/types/components/co-toggle-button/co-toggle-button.d.ts +37 -2
- package/dist/types/components/co-toggle-button-group/co-toggle-button-group.d.ts +20 -2
- package/dist/types/components/co-tooltip/co-tooltip.d.ts +12 -0
- package/dist/types/components/co-tree-item/co-tree-item.d.ts +73 -0
- package/dist/types/components/co-tree-item/treeItemI18n.d.ts +6 -0
- package/dist/types/components.d.ts +1748 -91
- package/dist/types/utils/color.d.ts +9 -1
- package/dist/types/utils/dragMove.d.ts +63 -0
- package/dist/types/utils/gradientBarI18n.d.ts +8 -0
- package/dist/types/utils/gradientStops.d.ts +63 -0
- package/dist/types/utils/hsv.d.ts +44 -0
- package/dist/types/utils/kbdI18n.d.ts +25 -0
- package/dist/types/utils/positioning.d.ts +24 -0
- package/dist/types/utils/rich-text-host.d.ts +41 -0
- package/dist/types/utils/richTextI18n.d.ts +15 -0
- package/dist/types/utils/submenu.d.ts +16 -2
- package/dist/types/utils/swatchGridI18n.d.ts +6 -0
- package/dist/types/utils/test/fake-block-layout.d.ts +7 -0
- package/dist/types/utils/test/prosemirror-dom-shim.d.ts +1 -0
- package/dist/types/utils/test/shared-contract-css.d.ts +9 -0
- package/package.json +5 -5
- package/dist/cobalt/p-0678c797.entry.js +0 -1
- package/dist/cobalt/p-216a63ee.entry.js +0 -1
- package/dist/cobalt/p-39dc4ec8.entry.js +0 -1
- package/dist/cobalt/p-3d31c575.entry.js +0 -1
- package/dist/cobalt/p-410bee4d.entry.js +0 -1
- package/dist/cobalt/p-416795f5.entry.js +0 -1
- package/dist/cobalt/p-56551580.entry.js +0 -1
- package/dist/cobalt/p-58137c9e.entry.js +0 -1
- package/dist/cobalt/p-5a3e4c81.entry.js +0 -1
- package/dist/cobalt/p-5c756787.entry.js +0 -1
- package/dist/cobalt/p-67f3b9d6.entry.js +0 -1
- package/dist/cobalt/p-6a4f3179.entry.js +0 -1
- package/dist/cobalt/p-71cbc53c.entry.js +0 -1
- package/dist/cobalt/p-72e52af7.entry.js +0 -1
- package/dist/cobalt/p-8530ad16.entry.js +0 -1
- package/dist/cobalt/p-8a74bf7d.entry.js +0 -1
- package/dist/cobalt/p-8e05b979.entry.js +0 -1
- package/dist/cobalt/p-8ebc0c12.entry.js +0 -1
- package/dist/cobalt/p-8f2199ff.entry.js +0 -1
- package/dist/cobalt/p-9246e09c.entry.js +0 -1
- package/dist/cobalt/p-99a655f6.entry.js +0 -1
- package/dist/cobalt/p-BYKAgwq3.js +0 -1
- package/dist/cobalt/p-CJW9H3Gi.js +0 -1
- package/dist/cobalt/p-DFHRS9cJ.js +0 -1
- package/dist/cobalt/p-DH5lfRNj.js +0 -2
- package/dist/cobalt/p-a1b422ca.entry.js +0 -1
- package/dist/cobalt/p-ade07307.entry.js +0 -1
- package/dist/cobalt/p-b698188c.entry.js +0 -1
- package/dist/cobalt/p-bde32f8b.entry.js +0 -1
- package/dist/cobalt/p-db805569.entry.js +0 -1
- package/dist/cobalt/p-e3aae282.entry.js +0 -1
- package/dist/cobalt/p-e49a564c.entry.js +0 -1
- package/dist/cobalt/p-ef301976.entry.js +0 -1
- package/dist/cobalt/p-f4e1c3c3.entry.js +0 -1
- package/dist/cobalt/p-fMqVDypp.js +0 -1
- package/dist/components/p-2EOI1nrz.js +0 -1
- package/dist/components/p-7TncUlLN.js +0 -1
- package/dist/components/p-B4NCaKrR.js +0 -1
- package/dist/components/p-BJh68Jqe.js +0 -1
- package/dist/components/p-BrAFTkAn.js +0 -1
- package/dist/components/p-Bsh0JMGf.js +0 -1
- package/dist/components/p-CJW9H3Gi.js +0 -1
- package/dist/components/p-CWCYYQrF.js +0 -1
- package/dist/components/p-D7Lhxz7L.js +0 -1
- package/dist/components/p-DFHRS9cJ.js +0 -1
- package/dist/components/p-DRP8D9ro.js +0 -1
- package/dist/components/p-DTPYZwaZ.js +0 -1
- package/dist/components/p-Dcg4krSX.js +0 -1
|
@@ -1,13 +1,14 @@
|
|
|
1
|
-
import { r as registerInstance, h } from './index-
|
|
1
|
+
import { r as registerInstance, h } from './index-DJkaRtbb.js';
|
|
2
2
|
|
|
3
|
-
const coIconButtonCss = () => `:host{display:inline-flex}:host([disabled]){pointer-events:none}.co-icon-button{display:inline-flex;align-items:center;justify-content:center;cursor:pointer;border:1px solid transparent;outline:none;padding:0;flex-shrink:0;transition:opacity var(--co-motion-duration-fast) var(--co-motion-ease-out), background var(--co-motion-duration-fast) var(--co-motion-ease-out), transform var(--co-motion-duration-fast) var(--co-motion-ease-out);box-sizing:border-box;-webkit-font-smoothing:antialiased;-webkit-backdrop-filter:var(--co-icon-button-backdrop-filter, var(--co-glass-filter, blur(var(--co-glass-blur)) saturate(var(--co-glass-saturate))));backdrop-filter:var(--co-icon-button-backdrop-filter, var(--co-glass-filter, blur(var(--co-glass-blur)) saturate(var(--co-glass-saturate))))}.co-icon-button--filled{background:color-mix(in srgb, var(--co-semantic-surface-primary) 78%, transparent);color:var(--co-semantic-on-primary);border-color:color-mix(in srgb, var(--co-semantic-on-primary) 28%, transparent)}.co-icon-button--outlined{background:color-mix(in srgb, var(--co-icon-button-bg, var(--co-semantic-surface-secondary)) 55%, transparent);color:var(--co-icon-button-color, var(--co-semantic-on-secondary));border:1px solid var(--co-icon-button-border, var(--co-semantic-border-subtle))}.co-icon-button--ghost{background:transparent;color:var(--co-icon-button-color, var(--co-semantic-text-default));border:none;-webkit-backdrop-filter:none;backdrop-filter:none}.co-icon-button--ghost:hover:not(:disabled){background:var(--co-color-opacity-negro-8, rgba(31, 28, 27, 0.08))}.co-icon-button--dark{color:var(--co-icon-button-color, var(--co-color-base-blanco, #fff))}.co-icon-button--dark.co-icon-button--ghost:hover:not(:disabled){background:var(--co-color-opacity-blanco-16, rgba(255, 255, 255, 0.16))}.co-icon-button--rounded.co-icon-button--xl{width:80px;height:80px;border-radius:var(--co-border-radius-full)}.co-icon-button--rounded.co-icon-button--lg{width:64px;height:64px;border-radius:var(--co-border-radius-full)}.co-icon-button--rounded.co-icon-button--md{width:56px;height:56px;border-radius:var(--co-border-radius-full)}.co-icon-button--rounded.co-icon-button--sm{width:48px;height:48px;border-radius:var(--co-border-radius-full)}.co-icon-button--rounded.co-icon-button--xs{width:32px;height:32px;border-radius:var(--co-border-radius-full)}.co-icon-button--rounded.co-icon-button--xxs{width:24px;height:24px;border-radius:var(--co-border-radius-full)}.co-icon-button--square.co-icon-button--xl{width:80px;height:80px;border-radius:var(--co-border-radius-xl);}.co-icon-button--square.co-icon-button--lg{width:64px;height:64px;border-radius:var(--co-border-radius-lg);}.co-icon-button--square.co-icon-button--md{width:56px;height:56px;border-radius:var(--co-border-radius-lg);}.co-icon-button--square.co-icon-button--sm{width:48px;height:48px;border-radius:var(--co-border-radius-sm);}.co-icon-button--square.co-icon-button--xs{width:32px;height:32px;border-radius:var(--co-border-radius-xs);}.co-icon-button--square.co-icon-button--xxs{width:24px;height:24px;border-radius:var(--co-spacing-sm);}
|
|
3
|
+
const coIconButtonCss = () => `:host{display:inline-flex}:host([disabled]){pointer-events:none}:host([fluid]){flex:1 1 0;min-width:0}:host([fluid]) .co-icon-button{width:100%}.co-icon-button{display:inline-flex;align-items:center;justify-content:center;cursor:pointer;border:1px solid transparent;outline:none;padding:0;flex-shrink:0;transition:opacity var(--co-motion-duration-fast) var(--co-motion-ease-out), background var(--co-motion-duration-fast) var(--co-motion-ease-out), transform var(--co-motion-duration-fast) var(--co-motion-ease-out);box-sizing:border-box;-webkit-font-smoothing:antialiased;-webkit-backdrop-filter:var(--co-icon-button-backdrop-filter, var(--co-glass-filter, blur(var(--co-glass-blur)) saturate(var(--co-glass-saturate))));backdrop-filter:var(--co-icon-button-backdrop-filter, var(--co-glass-filter, blur(var(--co-glass-blur)) saturate(var(--co-glass-saturate))))}.co-icon-button--filled{background:color-mix(in srgb, var(--co-semantic-surface-primary) 78%, transparent);color:var(--co-semantic-on-primary);border-color:color-mix(in srgb, var(--co-semantic-on-primary) 28%, transparent)}.co-icon-button--outlined{background:color-mix(in srgb, var(--co-icon-button-bg, var(--co-semantic-surface-secondary)) 55%, transparent);color:var(--co-icon-button-color, var(--co-semantic-on-secondary));border:1px solid var(--co-icon-button-border, var(--co-semantic-border-subtle))}.co-icon-button--ghost{background:transparent;color:var(--co-icon-button-color, var(--co-semantic-text-default));border:none;-webkit-backdrop-filter:none;backdrop-filter:none}.co-icon-button--ghost:hover:not(:disabled){background:var(--co-color-opacity-negro-8, rgba(31, 28, 27, 0.08))}.co-icon-button--soft{background:var(--co-semantic-surface-control);color:var(--co-icon-button-color, var(--co-semantic-text-default));border-color:transparent;-webkit-backdrop-filter:none;backdrop-filter:none}.co-icon-button--soft:hover:not(:disabled){background:color-mix(in srgb, var(--co-semantic-surface-control), var(--co-semantic-surface-hover))}.co-icon-button--dark{color:var(--co-icon-button-color, var(--co-color-base-blanco, #fff))}.co-icon-button--dark.co-icon-button--ghost:hover:not(:disabled){background:var(--co-color-opacity-blanco-16, rgba(255, 255, 255, 0.16))}.co-icon-button--selected,.co-icon-button--selected:hover:not(:disabled),.co-icon-button--dark.co-icon-button--selected:hover:not(:disabled){background:var(--co-icon-button-selected-bg, var(--co-semantic-accent));color:var(--co-icon-button-selected-color, var(--co-semantic-on-accent))}.co-icon-button--rounded.co-icon-button--xl{width:80px;height:80px;border-radius:var(--co-icon-button-radius, var(--co-border-radius-full))}.co-icon-button--rounded.co-icon-button--lg{width:64px;height:64px;border-radius:var(--co-icon-button-radius, var(--co-border-radius-full))}.co-icon-button--rounded.co-icon-button--md{width:56px;height:56px;border-radius:var(--co-icon-button-radius, var(--co-border-radius-full))}.co-icon-button--rounded.co-icon-button--sm{width:48px;height:48px;border-radius:var(--co-icon-button-radius, var(--co-border-radius-full))}.co-icon-button--rounded.co-icon-button--xs{width:32px;height:32px;border-radius:var(--co-icon-button-radius, var(--co-border-radius-full))}.co-icon-button--rounded.co-icon-button--xxs{width:24px;height:24px;border-radius:var(--co-icon-button-radius, var(--co-border-radius-full))}.co-icon-button--square.co-icon-button--xl{width:80px;height:80px;border-radius:var(--co-icon-button-radius, var(--co-border-radius-xl));}.co-icon-button--square.co-icon-button--lg{width:64px;height:64px;border-radius:var(--co-icon-button-radius, var(--co-border-radius-lg));}.co-icon-button--square.co-icon-button--md{width:56px;height:56px;border-radius:var(--co-icon-button-radius, var(--co-border-radius-lg));}.co-icon-button--square.co-icon-button--sm{width:48px;height:48px;border-radius:var(--co-icon-button-radius, var(--co-border-radius-sm));}.co-icon-button--square.co-icon-button--xs{width:32px;height:32px;border-radius:var(--co-icon-button-radius, var(--co-border-radius-xs));}.co-icon-button--square.co-icon-button--xxs{width:24px;height:24px;border-radius:var(--co-icon-button-radius, var(--co-spacing-sm));}::slotted(*){width:var(--co-icon-button-glyph-size);height:var(--co-icon-button-glyph-size);flex-shrink:0}.co-icon-button--caret{gap:4px}.co-icon-button--caret.co-icon-button--xl{width:calc(80px + 8px)}.co-icon-button--caret.co-icon-button--lg{width:calc(64px + 8px)}.co-icon-button--caret.co-icon-button--md{width:calc(56px + 8px)}.co-icon-button--caret.co-icon-button--sm{width:calc(48px + 8px)}.co-icon-button--caret.co-icon-button--xs{width:calc(32px + 8px)}.co-icon-button--caret.co-icon-button--xxs{width:calc(24px + 8px)}.co-icon-button--disabled,.co-icon-button:disabled{opacity:0.4;cursor:not-allowed;pointer-events:none}.co-icon-button:hover:not(:disabled){opacity:0.88}.co-icon-button:focus-visible{outline:none;border-color:var(--co-semantic-border-focus);box-shadow:0 0 0 2px var(--co-semantic-border-focus)}.co-icon-button--dark:focus-visible{box-shadow:0 0 0 2px color-mix(in srgb, var(--co-color-base-blanco, #fff) 45%, transparent)}.co-icon-button:active:not(:disabled){transform:scale(0.97);transition-duration:var(--co-motion-duration-instant)}@supports not (background: color-mix(in srgb, red, transparent)){.co-icon-button--filled{background:var(--co-semantic-surface-primary)}.co-icon-button--outlined{background:var(--co-icon-button-bg, var(--co-semantic-surface-secondary))}}.co-icon-button__swap{display:inline-grid}.co-icon-button__swap>co-icon{grid-area:1 / 1;transition:opacity var(--co-motion-duration-base) var(--co-motion-ease-in-out), transform var(--co-motion-duration-base) var(--co-motion-ease-in-out), filter var(--co-motion-duration-base) var(--co-motion-ease-in-out)}.co-icon-button__swap>co-icon:last-child{opacity:0;transform:scale(0.25);filter:blur(var(--co-motion-blur-sm))}.co-icon-button__swap--toggled>co-icon:first-child{opacity:0;transform:scale(0.25);filter:blur(var(--co-motion-blur-sm))}.co-icon-button__swap--toggled>co-icon:last-child{opacity:1;transform:scale(1);filter:blur(0)}`;
|
|
4
4
|
|
|
5
5
|
const CoIconButton = class {
|
|
6
6
|
constructor(hostRef) {
|
|
7
7
|
registerInstance(this, hostRef);
|
|
8
8
|
/**
|
|
9
9
|
* filled = dark background (negro), outlined = light background (blanco + border),
|
|
10
|
-
* ghost = transparent background, no border, tinted hover (negro-8 on light / blanco-16 on dark)
|
|
10
|
+
* ghost = transparent background, no border, tinted hover (negro-8 on light / blanco-16 on dark),
|
|
11
|
+
* soft = fondo gris sólido (--co-color-gray-100), sin borde visible, sin frost.
|
|
11
12
|
* Matches Figma: Secundario → filled, Primario → outlined
|
|
12
13
|
*/
|
|
13
14
|
this.variant = 'filled';
|
|
@@ -34,6 +35,27 @@ const CoIconButton = class {
|
|
|
34
35
|
this.toggled = false;
|
|
35
36
|
/** Icon weight */
|
|
36
37
|
this.iconWeight = 'regular';
|
|
38
|
+
/**
|
|
39
|
+
* Estado de selección (transversal, gana sobre cualquier `variant`): fondo/color
|
|
40
|
+
* de acento. Reflejado para que `:host([selected])` sea estilable desde afuera y
|
|
41
|
+
* marca `aria-pressed="true"` en el `<button>` (ausente cuando no está selected,
|
|
42
|
+
* en vez de "false", para no alterar el árbol de accesibilidad por defecto).
|
|
43
|
+
*/
|
|
44
|
+
this.selected = false;
|
|
45
|
+
/**
|
|
46
|
+
* Ocupa el espacio disponible del contenedor flex (`flex: 1 1 0; min-width: 0`) en
|
|
47
|
+
* vez del ancho fijo por `size` — para filas de N botones repartidos en el 100%.
|
|
48
|
+
*/
|
|
49
|
+
this.fluid = false;
|
|
50
|
+
/**
|
|
51
|
+
* Agrega un `caret-down` de 8px a la derecha del icono principal (botones-disclosure).
|
|
52
|
+
* Ensancha la caja +8px (el alto no cambia) para que el caret no le robe espacio
|
|
53
|
+
* al icono — fix round 1: la primera versión usaba `padding-right`, que con
|
|
54
|
+
* `box-sizing: border-box` y ancho fijo por talla ENCOGE el área de contenido en
|
|
55
|
+
* vez de agrandar la caja (overflow real en xs/xxs). Sin `caret`, el DOM/CSS
|
|
56
|
+
* quedan idénticos al comportamiento anterior.
|
|
57
|
+
*/
|
|
58
|
+
this.caret = false;
|
|
37
59
|
}
|
|
38
60
|
render() {
|
|
39
61
|
var _a, _b;
|
|
@@ -41,23 +63,41 @@ const CoIconButton = class {
|
|
|
41
63
|
xl: 32, lg: 28, md: 24, sm: 20, xs: 16, xxs: 16,
|
|
42
64
|
};
|
|
43
65
|
const resolvedIconSize = (_a = this.iconSize) !== null && _a !== void 0 ? _a : ((_b = iconSizeMap[this.size]) !== null && _b !== void 0 ? _b : 24);
|
|
66
|
+
// --co-icon-button-radius unifica el radio: mismo fallback que ya tenía el
|
|
67
|
+
// boxStyle inline, pero ahora personalizable también en el path de `boxSize`.
|
|
68
|
+
const radiusFallback = this.shape === 'square' ? 'var(--co-border-radius-xs, 8px)' : 'var(--co-border-radius-full)';
|
|
69
|
+
// Con `caret`, el ancho crece +8px (el alto NO — el caret es más angosto que
|
|
70
|
+
// alto) para que el caret quepa sin robarle espacio al contenido existente
|
|
71
|
+
// (con box-sizing:border-box, un padding-right no agranda la caja, la
|
|
72
|
+
// encoge — de ahí el bug de overflow en xs/xxs que esto corrige). Espejo del
|
|
73
|
+
// fix por talla en el .css (`.co-icon-button--caret.co-icon-button--<size>`).
|
|
44
74
|
const boxStyle = this.boxSize != null
|
|
45
75
|
? {
|
|
46
|
-
width: `${this.boxSize}px`,
|
|
76
|
+
width: `${this.caret ? this.boxSize + 8 : this.boxSize}px`,
|
|
47
77
|
height: `${this.boxSize}px`,
|
|
48
|
-
borderRadius:
|
|
49
|
-
? 'var(--co-border-radius-xs, 8px)'
|
|
50
|
-
: 'var(--co-border-radius-full)',
|
|
78
|
+
borderRadius: `var(--co-icon-button-radius, ${radiusFallback})`,
|
|
51
79
|
}
|
|
52
80
|
: undefined;
|
|
53
|
-
|
|
81
|
+
// Modo slot (sin `icon`): el glifo proyectado debe medir lo mismo que
|
|
82
|
+
// mediría el co-icon de esta talla (o `iconSize`). Se publica como custom
|
|
83
|
+
// property inline SOLO en este modo, así el botón con `icon` no gana un
|
|
84
|
+
// atributo `style` que antes no tenía (DOM byte-idéntico). El CSS la
|
|
85
|
+
// consume en `::slotted(*)`.
|
|
86
|
+
const usesSlot = !this.icon;
|
|
87
|
+
const style = usesSlot
|
|
88
|
+
? Object.assign(Object.assign({}, (boxStyle !== null && boxStyle !== void 0 ? boxStyle : {})), { '--co-icon-button-glyph-size': `${resolvedIconSize}px` }) : boxStyle;
|
|
89
|
+
return (h("button", { key: '4ae94400d9f54425b1aa844a651fbe441f545645', class: {
|
|
54
90
|
'co-icon-button': true,
|
|
55
91
|
[`co-icon-button--${this.variant}`]: true,
|
|
56
92
|
[`co-icon-button--${this.shape}`]: true,
|
|
57
93
|
[`co-icon-button--${this.size}`]: true,
|
|
58
94
|
'co-icon-button--dark': this.surface === 'dark',
|
|
95
|
+
'co-icon-button--selected': this.selected,
|
|
96
|
+
'co-icon-button--caret': this.caret,
|
|
59
97
|
'co-icon-button--disabled': this.disabled,
|
|
60
|
-
}, style:
|
|
98
|
+
}, style: style, disabled: this.disabled, "aria-label": this.label || (this.toggled && this.toggleIcon ? this.toggleIcon : this.icon), "aria-pressed": this.selected ? 'true' : undefined, part: "button" }, this.icon && this.toggleIcon ? (h("span", { class: { 'co-icon-button__swap': true, 'co-icon-button__swap--toggled': this.toggled }, "aria-hidden": "true" }, h("co-icon", { name: this.icon, weight: this.iconWeight, size: resolvedIconSize }), h("co-icon", { name: this.toggleIcon, weight: this.iconWeight, size: resolvedIconSize }))) : this.icon ? (h("co-icon", { name: this.icon, weight: this.iconWeight, size: resolvedIconSize })) : (
|
|
99
|
+
// Sin `icon`: el consumidor proyecta su propio glifo (ver @slot).
|
|
100
|
+
h("slot", null)), this.caret && h("co-icon", { key: 'f8a026ec97d9d37f9f62c81a3ae484d2a8b09665', class: "co-icon-button__caret", name: "caret-down", size: 8 })));
|
|
61
101
|
}
|
|
62
102
|
};
|
|
63
103
|
CoIconButton.style = coIconButtonCss();
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as registerInstance, h, H as Host } from './index-
|
|
1
|
+
import { r as registerInstance, h, H as Host } from './index-DJkaRtbb.js';
|
|
2
2
|
|
|
3
3
|
const CDN_BASE = 'https://cdn.jsdelivr.net/npm/@phosphor-icons/core@2.1.1/assets';
|
|
4
4
|
/** Caché compartido a nivel de módulo: clave → PROMESA del SVG (en vuelo o resuelta). */
|
|
@@ -83,12 +83,12 @@ const CoIcon = class {
|
|
|
83
83
|
this.svgContent = await loadSvg(this.name, this.weight);
|
|
84
84
|
}
|
|
85
85
|
render() {
|
|
86
|
-
return (h(Host, { key: '
|
|
86
|
+
return (h(Host, { key: '66a4583c6d57b57eaee720026f40453653048d8d', "aria-hidden": "true", style: {
|
|
87
87
|
display: 'inline-flex',
|
|
88
88
|
width: `${this.size}px`,
|
|
89
89
|
height: `${this.size}px`,
|
|
90
90
|
flexShrink: '0',
|
|
91
|
-
} }, h("span", { key: '
|
|
91
|
+
} }, h("span", { key: '423686acaa97e3c78163f79f98a38234b319c050', part: "svg", innerHTML: this.svgContent })));
|
|
92
92
|
}
|
|
93
93
|
static get watchers() { return {
|
|
94
94
|
"name": [{
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { r as registerInstance, c as createEvent, h, a as getElement } from './index-
|
|
2
|
-
import { R as RequiredMark } from './requiredMark-
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, a as getElement } from './index-DJkaRtbb.js';
|
|
2
|
+
import { R as RequiredMark } from './requiredMark-D5C5NzOE.js';
|
|
3
3
|
|
|
4
|
-
const coInputCss = () => `:host{display:block;font-family:var(--co-font-family-primary);font-size:var(--co-font-size-14);letter-spacing:var(--co-font-letter-spacing-body);line-height:1}.co-input{display:flex;flex-direction:column;gap:var(--co-spacing-sm2)}:host([layout='horizontal']) .co-input{display:grid;grid-template-columns:var(--co-field-label-width, max-content) 1fr;align-items:start;column-gap:var(--co-spacing-md);row-gap:var(--co-spacing-sm2)}:host([layout='horizontal']) .co-input__labels{grid-column:1;grid-row:1;padding-top:var(--co-spacing-sm2);min-width:0}:host([layout='horizontal']) .co-input__label{white-space:normal}:host([layout='horizontal']) .co-input>:not(.co-input__labels){grid-column:2;min-width:0}.co-input__labels{display:flex;align-items:center;justify-content:space-between;padding:0 var(--co-spacing-xs);gap:var(--co-spacing-sm2)}.co-input__label{color:var(--co-semantic-text-secondary);font-size:var(--co-font-size-14);font-weight:400;letter-spacing:var(--co-font-letter-spacing-body);line-height:1;white-space:nowrap;cursor:default}.co-input__secondary-label{color:var(--co-semantic-text-secondary);font-size:var(--co-font-size-14);font-weight:400;letter-spacing:var(--co-font-letter-spacing-body);line-height:1;white-space:nowrap;text-align:right}.co-input__field-row{display:flex;align-items:stretch}.co-input__field{display:flex;align-items:center;gap:var(--co-spacing-sm2);padding:var(--co-spacing-sm2) var(--co-spacing-md);background:var(--co-semantic-surface-page);border:1px solid var(--co-semantic-border-field);border-radius:var(--co-border-radius-xs);transition:border-color var(--co-motion-duration-fast) var(--co-motion-ease-out), box-shadow var(--co-motion-duration-fast) var(--co-motion-ease-out);min-height:40px;box-sizing:border-box;overflow:hidden;flex:1;min-width:0}.co-input--flat .co-input__field{background:transparent;border-color:transparent}.co-input--s .co-input__field{min-height:28px;padding:var(--co-spacing-xxs) var(--co-spacing-sm);font-size:var(--co-font-size-12)}.co-input--sm .co-input__field{min-height:32px;padding:var(--co-spacing-xs) var(--co-spacing-sm);font-size:var(--co-font-size-14)}.co-input--lg .co-input__field{min-height:48px;padding:var(--co-spacing-sm) var(--co-spacing-lg);font-size:var(--co-font-size-16)}.co-input--has-action .co-input__field{border-radius:var(--co-border-radius-xs) 0 0 var(--co-border-radius-xs);border-right:none}.co-input__field ::slotted([slot="action"]){margin-left:auto;margin-right:calc(-1 * var(--co-spacing-md));margin-top:calc(-1 * var(--co-spacing-sm2));margin-bottom:calc(-1 * var(--co-spacing-sm2));border-radius:0 var(--co-border-radius-xs) var(--co-border-radius-xs) 0;flex-shrink:0}.co-input__field ::slotted([slot="chips"]){display:flex;gap:var(--co-spacing-xxs);align-items:center;flex-wrap:wrap;min-width:0}.co-input__input-wrapper{flex:1;display:flex;align-items:center;min-width:0;min-height:22px;padding:0}.co-input__native{width:100%;border:none;outline:none;background:transparent;font-family:inherit;font-size:inherit;font-weight:400;letter-spacing:inherit;line-height:1;color:var(--co-semantic-text-default);padding:0;margin:0}.co-input__native::placeholder{color:var(--co-semantic-text-muted)}.co-input__native[type='number']::-webkit-inner-spin-button,.co-input__native[type='number']::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}.co-input__native[type='number']{-moz-appearance:textfield;appearance:textfield}.co-input__icon{flex-shrink:0;color:var(--co-semantic-text-muted);display:flex;align-items:center}.co-input__clear{flex-shrink:0;display:flex;align-items:center;justify-content:center;width:16px;padding:0;margin:0;border:none;background:transparent;cursor:pointer;color:var(--co-semantic-text-muted);transition:color var(--co-motion-duration-fast) var(--co-motion-ease-out)}.co-input__clear--hidden{visibility:hidden;pointer-events:none}.co-input__clear:hover{color:var(--co-semantic-text-default)}.co-input__action{display:flex;align-items:center;gap:var(--co-spacing-sm);padding:var(--co-spacing-sm2) var(--co-spacing-md) var(--co-spacing-sm2) var(--co-spacing-sm2);background:var(--co-semantic-surface-primary);color:var(--co-semantic-on-primary);border:none;border-radius:0 var(--co-border-radius-xs) var(--co-border-radius-xs) 0;cursor:pointer;font-family:var(--co-font-family-primary);font-size:var(--co-font-size-14);font-weight:400;letter-spacing:var(--co-font-letter-spacing-body);line-height:1;white-space:nowrap;flex-shrink:0;transition:opacity var(--co-motion-duration-fast) var(--co-motion-ease-out);box-sizing:border-box}.co-input__action:hover{opacity:0.85}.co-input__action:disabled{opacity:0.4;cursor:not-allowed}.co-input__action-icon{display:flex;align-items:center;flex-shrink:0}.co-input__action-label{display:flex;align-items:center}.co-input__helper{display:flex;align-items:center;gap:var(--co-spacing-xs);padding:0 var(--co-spacing-xs)}.co-input__helper-icon{flex-shrink:0;color:var(--co-semantic-text-muted);display:flex;align-items:center}.co-input__helper-text{color:var(--co-semantic-text-muted);font-size:var(--co-font-size-14);font-weight:400;line-height:1;letter-spacing:var(--co-font-letter-spacing-body)}.co-input--focused .co-input__field{border-color:var(--co-semantic-border-focus);box-shadow:0 0 0 2px var(--co-semantic-border-focus-ring)}.co-input--disabled .co-input__labels .co-input__label,.co-input--disabled .co-input__labels .co-input__secondary-label{color:var(--co-semantic-text-disabled)}.co-input--disabled .co-input__field{background:var(--co-semantic-surface-disabled);border-color:transparent;cursor:not-allowed}.co-input--disabled .co-input__native{color:var(--co-semantic-text-disabled);cursor:not-allowed}.co-input--disabled .co-input__native::placeholder{color:var(--co-semantic-text-disabled)}.co-input--disabled .co-input__icon{color:var(--co-semantic-text-disabled)}.co-input__status-icon{flex-shrink:0;display:flex;align-items:center}.co-input--success .co-input__status-icon{color:var(--co-semantic-status-success)}.co-input--error .co-input__status-icon{color:var(--co-semantic-status-error)}.co-input--warning .co-input__status-icon{color:var(--co-color-status-review)}.co-input--info .co-input__status-icon{color:var(--co-semantic-status-info)}.co-input--error .co-input__field{border-color:var(--co-semantic-status-error)}.co-input--error.co-input--focused .co-input__field{border-color:var(--co-semantic-status-error);box-shadow:0 0 0 2px rgba(170, 46, 27, 0.12)}.co-input__helper--error .co-input__helper-icon,.co-input__helper--error .co-input__helper-text{color:var(--co-semantic-status-error)}.co-input--shake .co-input__field{animation:co-input-shake calc(var(--co-motion-duration-instant) * 3.5) var(--co-motion-ease-out) both}@keyframes co-input-shake{0%{transform:translateX(0);animation-timing-function:var(--co-motion-ease-out)}28.57%{transform:translateX(-6px);animation-timing-function:var(--co-motion-ease-out)}57.14%{transform:translateX(6px);animation-timing-function:var(--co-motion-ease-out)}78.57%{transform:translateX(-4px);animation-timing-function:var(--co-motion-ease-out)}100%{transform:translateX(0)}}.co-input--success .co-input__field{border-color:var(--co-semantic-status-success)}.co-input--success.co-input--focused .co-input__field{border-color:var(--co-semantic-status-success);box-shadow:0 0 0 2px rgba(10, 119, 36, 0.12)}.co-input__helper--success .co-input__helper-icon,.co-input__helper--success .co-input__helper-text{color:var(--co-semantic-status-success)}.co-input--warning .co-input__field{border-color:var(--co-color-status-review)}.co-input--warning.co-input--focused .co-input__field{border-color:var(--co-color-status-review);box-shadow:0 0 0 2px rgba(133, 87, 31, 0.12)}.co-input__helper--warning .co-input__helper-icon,.co-input__helper--warning .co-input__helper-text{color:var(--co-color-status-review)}.co-input--info .co-input__field{border-color:var(--co-semantic-status-info)}.co-input--info.co-input--focused .co-input__field{border-color:var(--co-semantic-status-info);box-shadow:0 0 0 2px rgba(45, 108, 197, 0.12)}.co-input__helper--info .co-input__helper-icon,.co-input__helper--info .co-input__helper-text{color:var(--co-semantic-status-info)}.co-field-required{margin-left:2px;color:var(--co-color-status-error)}.co-field-required__caption{margin-left:4px;color:var(--co-semantic-text-muted);font-size:var(--co-font-size-12);font-weight:400}.co-field-required__caption::before{content:var(--co-field-required-text, ' (required)')}@supports not (background: color-mix(in srgb, red, transparent)){.co-input__field{background:var(--co-semantic-surface-secondary)}}.co-input--fill .co-input__field{background:var(--co-color-gray-100, #f6f6f6);border:none;box-shadow:none;border-radius:10px;padding:0 12px;gap:var(--co-spacing-sm2);min-height:46px;font-size:13.5px;-webkit-backdrop-filter:none;backdrop-filter:none}.co-input--fill.co-input--s .co-input__field{min-height:38px}.co-input--fill.co-input--sm .co-input__field{min-height:42px}.co-input--fill.co-input--lg .co-input__field{min-height:52px}.co-input--fill .co-input__native{font-size:13.5px;font-family:var(--co-font-family-primary);letter-spacing:var(--co-font-letter-spacing-body)}.co-input--fill .co-input__native::placeholder{color:var(--co-color-gray-400, #a0a0a0)}.co-input--fill .co-input__icon{color:var(--co-color-gray-400, #a0a0a0)}.co-input--fill .co-input__clear{color:var(--co-color-gray-400, #a0a0a0)}.co-input--fill .co-input__clear:hover{color:var(--co-color-gray-600, #585858)}.co-input--fill.co-input--focused .co-input__field{border-color:transparent;box-shadow:none}`;
|
|
4
|
+
const coInputCss = () => `:host{display:block;font-family:var(--co-font-family-primary);font-size:var(--co-font-size-14);letter-spacing:var(--co-font-letter-spacing-body);line-height:1}.co-input{display:flex;flex-direction:column;gap:var(--co-spacing-sm2)}:host([layout='horizontal']) .co-input{display:grid;grid-template-columns:var(--co-field-label-width, max-content) 1fr;align-items:start;column-gap:var(--co-spacing-md);row-gap:var(--co-spacing-sm2)}:host([layout='horizontal']) .co-input__labels{grid-column:1;grid-row:1;padding-top:var(--co-spacing-sm2);min-width:0}:host([layout='horizontal']) .co-input__label{white-space:normal}:host([layout='horizontal']) .co-input>:not(.co-input__labels){grid-column:2;min-width:0}.co-input__labels{display:flex;align-items:center;justify-content:space-between;padding:0 var(--co-spacing-xs);gap:var(--co-spacing-sm2)}.co-input__label{color:var(--co-semantic-text-secondary);font-size:var(--co-font-size-14);font-weight:400;letter-spacing:var(--co-font-letter-spacing-body);line-height:1;white-space:nowrap;cursor:default}.co-input__secondary-label{color:var(--co-semantic-text-secondary);font-size:var(--co-font-size-14);font-weight:400;letter-spacing:var(--co-font-letter-spacing-body);line-height:1;white-space:nowrap;text-align:right}.co-input__field-row{display:flex;align-items:stretch}.co-input__field{display:flex;align-items:center;gap:var(--co-spacing-sm2);padding:var(--co-spacing-sm2) var(--co-spacing-md);background:var(--co-semantic-surface-page);border:1px solid var(--co-semantic-border-field);border-radius:var(--co-border-radius-xs);transition:border-color var(--co-motion-duration-fast) var(--co-motion-ease-out), box-shadow var(--co-motion-duration-fast) var(--co-motion-ease-out);min-height:40px;box-sizing:border-box;overflow:hidden;flex:1;min-width:0}.co-input--flat .co-input__field{background:transparent;border-color:transparent}.co-input--soft .co-input__field{background:var(--co-semantic-surface-control, #f6f6f6);border-color:transparent;box-shadow:none;-webkit-backdrop-filter:none;backdrop-filter:none;color:var(--co-semantic-text-default)}.co-input--s .co-input__field{min-height:28px;padding:var(--co-spacing-xxs) var(--co-spacing-sm);font-size:var(--co-font-size-12)}.co-input--sm .co-input__field{min-height:32px;padding:var(--co-spacing-xs) var(--co-spacing-sm);font-size:var(--co-font-size-14)}.co-input--lg .co-input__field{min-height:48px;padding:var(--co-spacing-sm) var(--co-spacing-lg);font-size:var(--co-font-size-16)}.co-input--has-action .co-input__field{border-radius:var(--co-border-radius-xs) 0 0 var(--co-border-radius-xs);border-right:none}.co-input__field ::slotted([slot="action"]){margin-left:auto;margin-right:calc(-1 * var(--co-spacing-md));margin-top:calc(-1 * var(--co-spacing-sm2));margin-bottom:calc(-1 * var(--co-spacing-sm2));border-radius:0 var(--co-border-radius-xs) var(--co-border-radius-xs) 0;flex-shrink:0}.co-input__field ::slotted([slot="chips"]){display:flex;gap:var(--co-spacing-xxs);align-items:center;flex-wrap:wrap;min-width:0}.co-input__input-wrapper{flex:1;display:flex;align-items:center;min-width:0;min-height:22px;padding:0}.co-input__native{width:100%;border:none;outline:none;background:transparent;font-family:inherit;font-size:inherit;font-weight:400;letter-spacing:inherit;line-height:1;color:var(--co-semantic-text-default);padding:0;margin:0}.co-input__native::placeholder{color:var(--co-semantic-text-muted)}.co-input__native[type='number']::-webkit-inner-spin-button,.co-input__native[type='number']::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}.co-input__native[type='number']{-moz-appearance:textfield;appearance:textfield}.co-input__icon{flex-shrink:0;color:var(--co-semantic-text-muted);display:flex;align-items:center}.co-input__clear{flex-shrink:0;display:flex;align-items:center;justify-content:center;width:16px;padding:0;margin:0;border:none;background:transparent;cursor:pointer;color:var(--co-semantic-text-muted);transition:color var(--co-motion-duration-fast) var(--co-motion-ease-out)}.co-input__clear--hidden{visibility:hidden;pointer-events:none}.co-input__clear:hover{color:var(--co-semantic-text-default)}.co-input__action{display:flex;align-items:center;gap:var(--co-spacing-sm);padding:var(--co-spacing-sm2) var(--co-spacing-md) var(--co-spacing-sm2) var(--co-spacing-sm2);background:var(--co-semantic-surface-primary);color:var(--co-semantic-on-primary);border:none;border-radius:0 var(--co-border-radius-xs) var(--co-border-radius-xs) 0;cursor:pointer;font-family:var(--co-font-family-primary);font-size:var(--co-font-size-14);font-weight:400;letter-spacing:var(--co-font-letter-spacing-body);line-height:1;white-space:nowrap;flex-shrink:0;transition:opacity var(--co-motion-duration-fast) var(--co-motion-ease-out);box-sizing:border-box}.co-input__action:hover{opacity:0.85}.co-input__action:disabled{opacity:0.4;cursor:not-allowed}.co-input__action-icon{display:flex;align-items:center;flex-shrink:0}.co-input__action-label{display:flex;align-items:center}.co-input__helper{display:flex;align-items:center;gap:var(--co-spacing-xs);padding:0 var(--co-spacing-xs)}.co-input__helper-icon{flex-shrink:0;color:var(--co-semantic-text-muted);display:flex;align-items:center}.co-input__helper-text{color:var(--co-semantic-text-muted);font-size:var(--co-font-size-14);font-weight:400;line-height:1;letter-spacing:var(--co-font-letter-spacing-body)}.co-input--focused .co-input__field{border-color:var(--co-semantic-border-focus);box-shadow:0 0 0 2px var(--co-semantic-border-focus-ring)}.co-input--disabled .co-input__labels .co-input__label,.co-input--disabled .co-input__labels .co-input__secondary-label{color:var(--co-semantic-text-disabled)}.co-input--disabled .co-input__field{background:var(--co-semantic-surface-disabled);border-color:transparent;cursor:not-allowed}.co-input--disabled .co-input__native{color:var(--co-semantic-text-disabled);cursor:not-allowed}.co-input--disabled .co-input__native::placeholder{color:var(--co-semantic-text-disabled)}.co-input--disabled .co-input__icon{color:var(--co-semantic-text-disabled)}.co-input__status-icon{flex-shrink:0;display:flex;align-items:center}.co-input--success .co-input__status-icon{color:var(--co-semantic-status-success)}.co-input--error .co-input__status-icon{color:var(--co-semantic-status-error)}.co-input--warning .co-input__status-icon{color:var(--co-color-status-review)}.co-input--info .co-input__status-icon{color:var(--co-semantic-status-info)}.co-input--error .co-input__field{border-color:var(--co-semantic-status-error)}.co-input--error.co-input--focused .co-input__field{border-color:var(--co-semantic-status-error);box-shadow:0 0 0 2px rgba(170, 46, 27, 0.12)}.co-input__helper--error .co-input__helper-icon,.co-input__helper--error .co-input__helper-text{color:var(--co-semantic-status-error)}.co-input--shake .co-input__field{animation:co-input-shake calc(var(--co-motion-duration-instant) * 3.5) var(--co-motion-ease-out) both}@keyframes co-input-shake{0%{transform:translateX(0);animation-timing-function:var(--co-motion-ease-out)}28.57%{transform:translateX(-6px);animation-timing-function:var(--co-motion-ease-out)}57.14%{transform:translateX(6px);animation-timing-function:var(--co-motion-ease-out)}78.57%{transform:translateX(-4px);animation-timing-function:var(--co-motion-ease-out)}100%{transform:translateX(0)}}.co-input--success .co-input__field{border-color:var(--co-semantic-status-success)}.co-input--success.co-input--focused .co-input__field{border-color:var(--co-semantic-status-success);box-shadow:0 0 0 2px rgba(10, 119, 36, 0.12)}.co-input__helper--success .co-input__helper-icon,.co-input__helper--success .co-input__helper-text{color:var(--co-semantic-status-success)}.co-input--warning .co-input__field{border-color:var(--co-color-status-review)}.co-input--warning.co-input--focused .co-input__field{border-color:var(--co-color-status-review);box-shadow:0 0 0 2px rgba(133, 87, 31, 0.12)}.co-input__helper--warning .co-input__helper-icon,.co-input__helper--warning .co-input__helper-text{color:var(--co-color-status-review)}.co-input--info .co-input__field{border-color:var(--co-semantic-status-info)}.co-input--info.co-input--focused .co-input__field{border-color:var(--co-semantic-status-info);box-shadow:0 0 0 2px rgba(45, 108, 197, 0.12)}.co-input__helper--info .co-input__helper-icon,.co-input__helper--info .co-input__helper-text{color:var(--co-semantic-status-info)}.co-field-required{margin-left:2px;color:var(--co-color-status-error)}.co-field-required__caption{margin-left:4px;color:var(--co-semantic-text-muted);font-size:var(--co-font-size-12);font-weight:400}.co-field-required__caption::before{content:var(--co-field-required-text, ' (required)')}@supports not (background: color-mix(in srgb, red, transparent)){.co-input__field{background:var(--co-semantic-surface-secondary)}}.co-input--fill .co-input__field{background:var(--co-color-gray-100, #f6f6f6);border:none;box-shadow:none;border-radius:10px;padding:0 12px;gap:var(--co-spacing-sm2);min-height:46px;font-size:13.5px;-webkit-backdrop-filter:none;backdrop-filter:none}.co-input--fill.co-input--s .co-input__field{min-height:38px}.co-input--fill.co-input--sm .co-input__field{min-height:42px}.co-input--fill.co-input--lg .co-input__field{min-height:52px}.co-input--fill .co-input__native{font-size:13.5px;font-family:var(--co-font-family-primary);letter-spacing:var(--co-font-letter-spacing-body)}.co-input--fill .co-input__native::placeholder{color:var(--co-color-gray-400, #a0a0a0)}.co-input--fill .co-input__icon{color:var(--co-color-gray-400, #a0a0a0)}.co-input--fill .co-input__clear{color:var(--co-color-gray-400, #a0a0a0)}.co-input--fill .co-input__clear:hover{color:var(--co-color-gray-600, #585858)}.co-input--fill.co-input--focused .co-input__field{border-color:transparent;box-shadow:none}.co-input--xs .co-input__field{min-height:24px;padding:0 var(--co-spacing-md);font-size:var(--co-font-size-12);border-radius:var(--co-border-radius-xxs);gap:var(--co-spacing-sm)}.co-input--soft.co-input--disabled .co-input__field{background:var(--co-semantic-surface-control, #f6f6f6);border-color:transparent}.co-input--soft.co-input--disabled .co-input__field>.co-input__icon,.co-input--soft.co-input--disabled .co-input__field>.co-input__input-wrapper,.co-input--soft.co-input--disabled .co-input__field>.co-input__clear,.co-input--soft.co-input--disabled .co-input__field>.co-input__status-icon,.co-input--soft.co-input--disabled .co-input__field ::slotted(:not([slot="prefix"])){opacity:0.35}.co-input__input-wrapper{gap:var(--co-spacing-xs)}.co-input__input-wrapper ::slotted([slot="prefix"]){display:flex;align-items:center;flex-shrink:0;color:var(--co-semantic-text-muted)}.co-input--xs .co-input__input-wrapper ::slotted([slot="prefix"]){font-size:var(--co-font-size-12);font-weight:400;color:var(--co-color-gray-600, #585858)}.co-input__field ::slotted([slot="suffix"]){color:var(--co-input-suffix-color, inherit)}.co-input--xs .co-input__field ::slotted([slot="suffix"]){font-size:var(--co-font-size-12)}`;
|
|
5
5
|
|
|
6
6
|
const CoInput = class {
|
|
7
7
|
constructor(hostRef) {
|
|
@@ -37,14 +37,18 @@ const CoInput = class {
|
|
|
37
37
|
this.autoFocus = false;
|
|
38
38
|
/** Validation status */
|
|
39
39
|
this.status = 'default';
|
|
40
|
-
/** Size variant: s (28px), sm (32px), md (40px, default), lg (48px).
|
|
40
|
+
/** Size variant: xs (24px), s (28px), sm (32px), md (40px, default), lg (48px).
|
|
41
41
|
* In the filled search-pill variant (`fill`) this drives the pill height
|
|
42
42
|
* instead (s ≈ 38px). */
|
|
43
43
|
this.size = 'md';
|
|
44
44
|
/** Visual style. `flat` strips the field's border and background so it
|
|
45
45
|
* reads as plain content instead of a boxed input — padding, label, focus
|
|
46
|
-
* ring, disabled and status states are unaffected. `
|
|
47
|
-
*
|
|
46
|
+
* ring, disabled and status states are unaffected. `soft` renders a solid
|
|
47
|
+
* gray-100 background with a transparent 1px border (same width as
|
|
48
|
+
* default, so nothing shifts) and no backdrop-filter — the disabled state
|
|
49
|
+
* keeps that gray-100 background and dims the field's content instead.
|
|
50
|
+
* `default` (the standard bordered box) renders identically to before
|
|
51
|
+
* this prop existed. */
|
|
48
52
|
this.variant = 'default';
|
|
49
53
|
/** Filled search-pill variant. When true the field renders as a minimal gray
|
|
50
54
|
* pill (background gray-100, no border/box-shadow, 10px radius) with a search
|
|
@@ -177,6 +181,7 @@ const CoInput = class {
|
|
|
177
181
|
}, type: "button", tabIndex: -1, onClick: this.handleClear, "aria-label": "Clear input", part: "clear" }, h("co-icon", { name: "x", size: 14 })))))));
|
|
178
182
|
}
|
|
179
183
|
render() {
|
|
184
|
+
var _a, _b;
|
|
180
185
|
if (this.fill) {
|
|
181
186
|
return this.renderFill();
|
|
182
187
|
}
|
|
@@ -191,11 +196,12 @@ const CoInput = class {
|
|
|
191
196
|
[`co-input--${this.status}`]: this.status !== 'default',
|
|
192
197
|
'co-input--has-action': this.hasAction,
|
|
193
198
|
'co-input--flat': this.variant === 'flat',
|
|
199
|
+
'co-input--soft': this.variant === 'soft',
|
|
194
200
|
'co-input--shake': this.shaking,
|
|
195
|
-
}, part: "wrapper" }, (this.label || this.secondaryLabel) && (h("div", { class: "co-input__labels" }, this.label && h("label", { class: "co-input__label", part: "label" }, this.label, h(RequiredMark, { required: this.required })), this.secondaryLabel && (h("span", { class: "co-input__secondary-label", part: "secondary-label" }, this.secondaryLabel)))), h("div", { class: "co-input__field-row" }, h("div", { class: "co-input__field", part: "field", onAnimationEnd: this.handleShakeEnd }, this.iconLeft && (h("co-icon", { name: this.iconLeft, size: 16, class: "co-input__icon co-input__icon--left" })), h("slot", { name: "chips" }), h("div", { class: "co-input__input-wrapper" }, h("input", { ref: (el) => (this.inputEl = el), class: "co-input__native", type: this.type, name: this.name, value: this.value, placeholder: this.placeholder, disabled: this.disabled, readOnly: this.readonly, required: this.required, autoComplete: this.autocomplete, onInput: this.handleInput, onChange: this.handleChange, onFocus: this.handleFocus, onBlur: this.handleBlur, onKeyDown: this.handleKeyDown, part: "input" })), this.clearable && (h("button", { class: {
|
|
201
|
+
}, part: "wrapper" }, (this.label || this.secondaryLabel) && (h("div", { class: "co-input__labels" }, this.label && h("label", { class: "co-input__label", part: "label" }, this.label, h(RequiredMark, { required: this.required })), this.secondaryLabel && (h("span", { class: "co-input__secondary-label", part: "secondary-label" }, this.secondaryLabel)))), h("div", { class: "co-input__field-row" }, h("div", { class: "co-input__field", part: "field", onAnimationEnd: this.handleShakeEnd }, this.iconLeft && (h("co-icon", { name: this.iconLeft, size: (_a = this.iconSize) !== null && _a !== void 0 ? _a : 16, class: "co-input__icon co-input__icon--left" })), h("slot", { name: "chips" }), h("div", { class: "co-input__input-wrapper" }, h("slot", { name: "prefix" }), h("input", { ref: (el) => (this.inputEl = el), class: "co-input__native", type: this.type, name: this.name, value: this.value, placeholder: this.placeholder, disabled: this.disabled, readOnly: this.readonly, required: this.required, autoComplete: this.autocomplete, onInput: this.handleInput, onChange: this.handleChange, onFocus: this.handleFocus, onBlur: this.handleBlur, onKeyDown: this.handleKeyDown, part: "input" })), this.clearable && (h("button", { class: {
|
|
196
202
|
'co-input__clear': true,
|
|
197
203
|
'co-input__clear--hidden': !showClear,
|
|
198
|
-
}, type: "button", tabIndex: -1, onClick: this.handleClear, "aria-label": "Clear input", part: "clear" }, h("co-icon", { name: "x-circle", size: 16, weight: "fill" }))), this.iconRight && (h("co-icon", { name: this.iconRight, size: 16, class: "co-input__icon co-input__icon--right" })), this.statusFieldIcon && (h("co-icon", { name: this.statusFieldIcon, size: 16, class: "co-input__status-icon" })), h("slot", { name: "suffix" }), h("slot", null), h("slot", { name: "action" })), this.hasAction && (h("button", { class: "co-input__action", type: "button", onClick: this.handleAction, disabled: this.disabled, part: "action" }, this.actionIcon && (h("co-icon", { name: this.actionIcon, size: 16, class: "co-input__action-icon" })), this.actionLabel && (h("span", { class: "co-input__action-label" }, this.actionLabel))))), this.helperText && (h("div", { class: `co-input__helper co-input__helper--${this.status}`, part: "helper" }, this.helperIcon && (h("co-icon", { name: this.helperIcon, size: 14, class: "co-input__helper-icon" })), h("span", { class: "co-input__helper-text" }, this.helperText)))));
|
|
204
|
+
}, type: "button", tabIndex: -1, onClick: this.handleClear, "aria-label": "Clear input", part: "clear" }, h("co-icon", { name: "x-circle", size: 16, weight: "fill" }))), this.iconRight && (h("co-icon", { name: this.iconRight, size: (_b = this.iconSize) !== null && _b !== void 0 ? _b : 16, class: "co-input__icon co-input__icon--right" })), this.statusFieldIcon && (h("co-icon", { name: this.statusFieldIcon, size: 16, class: "co-input__status-icon" })), h("slot", { name: "suffix" }), h("slot", null), h("slot", { name: "action" })), this.hasAction && (h("button", { class: "co-input__action", type: "button", onClick: this.handleAction, disabled: this.disabled, part: "action" }, this.actionIcon && (h("co-icon", { name: this.actionIcon, size: 16, class: "co-input__action-icon" })), this.actionLabel && (h("span", { class: "co-input__action-label" }, this.actionLabel))))), this.helperText && (h("div", { class: `co-input__helper co-input__helper--${this.status}`, part: "helper" }, this.helperIcon && (h("co-icon", { name: this.helperIcon, size: 14, class: "co-input__helper-icon" })), h("span", { class: "co-input__helper-text" }, this.helperText)))));
|
|
199
205
|
}
|
|
200
206
|
get el() { return getElement(this); }
|
|
201
207
|
static get watchers() { return {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { r as registerInstance, c as createEvent, h, a as getElement } from './index-
|
|
2
|
-
import { R as RequiredMark } from './requiredMark-
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, a as getElement } from './index-DJkaRtbb.js';
|
|
2
|
+
import { R as RequiredMark } from './requiredMark-D5C5NzOE.js';
|
|
3
3
|
|
|
4
4
|
const coJsonFieldCss = () => `:host{display:block;font-family:var(--co-font-family-primary);font-size:var(--co-font-size-14);letter-spacing:var(--co-font-letter-spacing-body);line-height:1}.co-json-field{display:flex;flex-direction:column;gap:var(--co-spacing-sm2)}.co-json-field__labels{display:flex;align-items:center;justify-content:space-between;padding:0 var(--co-spacing-xs);gap:var(--co-spacing-sm2)}.co-json-field__label{color:var(--co-semantic-text-secondary);font-size:var(--co-font-size-14);font-weight:400;letter-spacing:var(--co-font-letter-spacing-body);line-height:1;white-space:nowrap;cursor:default}.co-field-required{margin-left:2px;color:var(--co-color-status-error)}.co-field-required__caption{margin-left:4px;color:var(--co-semantic-text-muted);font-size:var(--co-font-size-12);font-weight:400}.co-field-required__caption::before{content:var(--co-field-required-text, ' (required)')}.co-json-field__field{display:flex;background:var(--co-semantic-surface-page);border:1px solid var(--co-semantic-border-field);border-radius:var(--co-border-radius-xs);transition:border-color var(--co-motion-duration-fast) var(--co-motion-ease-out), box-shadow var(--co-motion-duration-fast) var(--co-motion-ease-out);box-sizing:border-box;overflow:hidden}.co-json-field__native{width:100%;resize:vertical;border:none;outline:none;background:transparent;font-family:var(--co-font-family-mono, monospace);font-size:var(--co-font-size-13, 13px);font-weight:400;line-height:1.5;color:var(--co-semantic-text-default);padding:var(--co-spacing-sm2) var(--co-spacing-md);margin:0;box-sizing:border-box;tab-size:2}.co-json-field__native::placeholder{color:var(--co-semantic-text-muted)}.co-json-field--s .co-json-field__native{padding:var(--co-spacing-xxs) var(--co-spacing-sm);font-size:var(--co-font-size-12, 12px)}.co-json-field--sm .co-json-field__native{padding:var(--co-spacing-xs) var(--co-spacing-sm)}.co-json-field--lg .co-json-field__native{padding:var(--co-spacing-sm) var(--co-spacing-lg);font-size:var(--co-font-size-14)}.co-json-field__helper{display:flex;align-items:center;gap:var(--co-spacing-xs);padding:0 var(--co-spacing-xs)}.co-json-field__helper-icon{flex-shrink:0;color:var(--co-semantic-text-muted);display:flex;align-items:center}.co-json-field__helper-text{color:var(--co-semantic-text-muted);font-size:var(--co-font-size-14);font-weight:400;line-height:1;letter-spacing:var(--co-font-letter-spacing-body)}.co-json-field--focused .co-json-field__field{border-color:var(--co-semantic-border-focus);box-shadow:0 0 0 2px var(--co-semantic-border-focus-ring)}.co-json-field--disabled{opacity:0.6;pointer-events:none}.co-json-field--disabled .co-json-field__field{background:var(--co-semantic-surface-disabled);border-color:transparent}.co-json-field--invalid .co-json-field__field,.co-json-field--error .co-json-field__field{border-color:var(--co-semantic-status-error)}.co-json-field--invalid.co-json-field--focused .co-json-field__field,.co-json-field--error.co-json-field--focused .co-json-field__field{border-color:var(--co-semantic-status-error);box-shadow:0 0 0 2px rgba(170, 46, 27, 0.12)}.co-json-field__helper--error .co-json-field__helper-icon,.co-json-field__helper--error .co-json-field__helper-text{color:var(--co-semantic-status-error)}:host([layout='horizontal']) .co-json-field{display:grid;grid-template-columns:var(--co-field-label-width, max-content) 1fr;align-items:start;column-gap:var(--co-spacing-md);row-gap:var(--co-spacing-sm2)}:host([layout='horizontal']) .co-json-field__labels{grid-column:1;grid-row:1;padding-top:var(--co-spacing-sm2);min-width:0}:host([layout='horizontal']) .co-json-field__label{white-space:normal}:host([layout='horizontal']) .co-json-field>:not(.co-json-field__labels){grid-column:2;min-width:0}`;
|
|
5
5
|
|
|
@@ -87,17 +87,17 @@ const CoJsonField = class {
|
|
|
87
87
|
render() {
|
|
88
88
|
const helper = this.internalInvalid ? this.invalidMessage : this.helperText;
|
|
89
89
|
const statusClass = this.status !== 'default' ? `co-json-field--${this.status}` : '';
|
|
90
|
-
return (h("div", { key: '
|
|
90
|
+
return (h("div", { key: 'b7cc05a2cf7bcac484ef35923b873d487f9cf818', class: {
|
|
91
91
|
'co-json-field': true,
|
|
92
92
|
'co-json-field--disabled': this.disabled,
|
|
93
93
|
'co-json-field--focused': this.hasFocus,
|
|
94
94
|
'co-json-field--invalid': this.isInvalid,
|
|
95
95
|
[`co-json-field--${this.size}`]: true,
|
|
96
96
|
[statusClass]: !!statusClass,
|
|
97
|
-
}, part: "wrapper" }, this.label && (h("div", { key: '
|
|
97
|
+
}, part: "wrapper" }, this.label && (h("div", { key: '5e6829693907789665f54851df8ac012bbe9d9c9', class: "co-json-field__labels" }, h("label", { key: 'e19ba3d715acd5b505147ef6e0c173dbaf1dbae8', class: "co-json-field__label", part: "label" }, this.label, h(RequiredMark, { key: 'e45feaa1a58875adc64ab58e77d1cef498042574', required: this.required })))), h("div", { key: '7b5ed251a4c7f3456f1a5c36c7800aae60b8e602', class: "co-json-field__field", part: "field" }, h("textarea", { key: '03b4e34fabc26829c823f5dea01c987e5fc1a1f8', class: "co-json-field__native", rows: this.rows, spellcheck: false, autocomplete: "off", value: this.draft, placeholder: this.placeholder, disabled: this.disabled, readOnly: this.readonly, required: this.required, "aria-invalid": this.isInvalid ? 'true' : 'false', "aria-label": !this.label ? 'JSON' : undefined, onInput: this.handleInput, onFocus: this.handleFocus, onBlur: this.handleBlur, part: "input" })), this.name && h("input", { key: 'e7659c214e65fb97de486f442a170e11fb917587', type: "hidden", name: this.name, value: this.draft }), helper && (h("div", { key: '744697ecde8364833b3dfb4656602a5c8bb6192a', class: {
|
|
98
98
|
'co-json-field__helper': true,
|
|
99
99
|
'co-json-field__helper--error': this.isInvalid,
|
|
100
|
-
}, part: "helper" }, this.isInvalid && (h("co-icon", { key: '
|
|
100
|
+
}, part: "helper" }, this.isInvalid && (h("co-icon", { key: '8b80af75ce8f27fb68fa5760e584ce7aeedd67a7', name: "warning-circle", size: 14, class: "co-json-field__helper-icon" })), h("span", { key: 'f79da7c507e282694367d602dac6e99e534579f0', class: "co-json-field__helper-text" }, helper)))));
|
|
101
101
|
}
|
|
102
102
|
get el() { return getElement(this); }
|
|
103
103
|
static get watchers() { return {
|
|
@@ -1,7 +1,185 @@
|
|
|
1
|
-
import { r as registerInstance, h, a as getElement } from './index-
|
|
2
|
-
import { c as computePosition, g as getOffsetAncestor, f as findScrollParents } from './positioning-
|
|
1
|
+
import { r as registerInstance, h, a as getElement } from './index-DJkaRtbb.js';
|
|
2
|
+
import { c as computePosition, g as getOffsetAncestor, f as findScrollParents } from './positioning-BtliEQAT.js';
|
|
3
3
|
|
|
4
|
-
|
|
4
|
+
/**
|
|
5
|
+
* Diccionario embebido de `co-kbd` para las etiquetas de texto de los
|
|
6
|
+
* modificadores en plataformas sin teclas dedicadas (Windows/Linux): sin
|
|
7
|
+
* los glifos de Mac (⌘/⇧/⌥/⌃) el modificador se rotula con texto.
|
|
8
|
+
*
|
|
9
|
+
* Mismo patrón que `fileI18n.ts`: un mapa por locale + un getter. A
|
|
10
|
+
* diferencia de `fileI18n`, acá el locale no llega tipado por componente —
|
|
11
|
+
* `co-kbd` expone un `locale?: string` opcional (BCP-47, p.ej. "es-CO") y
|
|
12
|
+
* este util lo resuelve al lenguaje soportado más cercano, igual que
|
|
13
|
+
* `langFromLocale` en `fileI18n.ts`.
|
|
14
|
+
*/
|
|
15
|
+
const DICT = {
|
|
16
|
+
es: { ctrl: 'Ctrl', shift: 'Shift', alt: 'Alt', win: 'Win' },
|
|
17
|
+
en: { ctrl: 'Ctrl', shift: 'Shift', alt: 'Alt', win: 'Win' },
|
|
18
|
+
pt: { ctrl: 'Ctrl', shift: 'Shift', alt: 'Alt', win: 'Win' },
|
|
19
|
+
};
|
|
20
|
+
/** Map any BCP-47 locale (e.g. "es-CO") to a supported language; fallback 'en'. */
|
|
21
|
+
function langFromLocale(locale) {
|
|
22
|
+
const l = (locale || '').toLowerCase();
|
|
23
|
+
if (l.startsWith('es'))
|
|
24
|
+
return 'es';
|
|
25
|
+
if (l.startsWith('pt'))
|
|
26
|
+
return 'pt';
|
|
27
|
+
return 'en';
|
|
28
|
+
}
|
|
29
|
+
/** Resolve the built-in win-label strings for a locale. */
|
|
30
|
+
function getKbdStrings(locale) {
|
|
31
|
+
return DICT[langFromLocale(locale)];
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
const coKbdCss = () => `:host{display:inline-flex}.co-kbd{display:inline-flex;align-items:center;gap:var(--co-spacing-xxs, 2px)}.co-kbd__sep{font-family:var(--co-font-family-primary, 'Geist', sans-serif);font-size:var(--co-font-size-10, 10px);line-height:1;opacity:0.6}.co-kbd__key{display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;font-family:var(--co-font-family-primary, 'Geist', sans-serif);font-style:normal;font-weight:var(--co-font-weight-medium, 500);font-size:var(--co-font-size-10, 10px);line-height:1;text-transform:uppercase;border-radius:var(--co-border-radius-xxs, 4px)}.co-kbd--sm .co-kbd__key{min-width:30px;height:18px;padding:0 3px}.co-kbd--xs .co-kbd__key{width:16px;height:16px;padding:0}.co-kbd__cell{display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;min-width:12px;height:12px;flex-shrink:0;white-space:nowrap}.co-kbd__cell--icon{width:12px}.co-kbd__cell--text{width:auto;padding:0 1px}.co-kbd--xs .co-kbd__key--chord{width:auto;min-width:16px;height:16px;padding:0 2px}.co-kbd--light .co-kbd__key{background:var(--co-semantic-surface-control, #f6f6f6);color:var(--co-semantic-text-default, #1f1c1b)}.co-kbd--light .co-kbd__sep{color:var(--co-semantic-text-default, #1f1c1b)}.co-kbd--dark .co-kbd__key{background:var(--co-color-opacity-blanco-16, rgba(255, 255, 255, 0.16));color:var(--co-color-base-blanco, #fff)}.co-kbd--dark .co-kbd__sep{color:var(--co-color-base-blanco, #fff)}`;
|
|
35
|
+
|
|
36
|
+
/** Ícono Phosphor por modificador en mac. */
|
|
37
|
+
const MAC_ICON_BY_MODIFIER = {
|
|
38
|
+
mod: 'command',
|
|
39
|
+
cmd: 'command',
|
|
40
|
+
shift: 'arrow-fat-up',
|
|
41
|
+
alt: 'option',
|
|
42
|
+
ctrl: 'control',
|
|
43
|
+
};
|
|
44
|
+
/** Ícono del modo `chord` (diseño: ícono 12 en celda de 12, en ambas tallas). */
|
|
45
|
+
const CHORD_ICON_SIZE = 12;
|
|
46
|
+
function isModifierToken(token) {
|
|
47
|
+
return token === 'mod' || token === 'cmd' || token === 'shift' || token === 'alt' || token === 'ctrl';
|
|
48
|
+
}
|
|
49
|
+
/** Núcleo puro: separa "shift+1" en ["shift", "1"]. Sin tocar el DOM/store. */
|
|
50
|
+
function parseKeyTokens(keys) {
|
|
51
|
+
return keys
|
|
52
|
+
.split('+')
|
|
53
|
+
.map((token) => token.trim().toLowerCase())
|
|
54
|
+
.filter(Boolean);
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* Etiqueta textual de un modificador — se usa para el aria-label siempre, y
|
|
58
|
+
* como contenido visible en `win` (en `mac` el visible es el ícono, ver
|
|
59
|
+
* `MAC_ICON_BY_MODIFIER`). Difieren por plataforma:
|
|
60
|
+
* - `mod` = el modificador "de plataforma": "Cmd" en mac, `kbdI18n` "Ctrl"
|
|
61
|
+
* en win (el editor trata Ctrl como meta en Windows/Linux).
|
|
62
|
+
* - `cmd` = la tecla Cmd literal: "Cmd" en mac, `kbdI18n` "Win" en win (no
|
|
63
|
+
* hay tecla Cmd en Windows; la física análoga es Win).
|
|
64
|
+
*/
|
|
65
|
+
function modifierLabel(token, platform, strings) {
|
|
66
|
+
if (platform === 'mac') {
|
|
67
|
+
switch (token) {
|
|
68
|
+
case 'mod':
|
|
69
|
+
case 'cmd':
|
|
70
|
+
return 'Cmd';
|
|
71
|
+
case 'shift':
|
|
72
|
+
return 'Shift';
|
|
73
|
+
case 'alt':
|
|
74
|
+
return 'Option';
|
|
75
|
+
case 'ctrl':
|
|
76
|
+
return 'Control';
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
switch (token) {
|
|
80
|
+
case 'mod':
|
|
81
|
+
return strings.ctrl;
|
|
82
|
+
case 'cmd':
|
|
83
|
+
return strings.win;
|
|
84
|
+
case 'shift':
|
|
85
|
+
return strings.shift;
|
|
86
|
+
case 'alt':
|
|
87
|
+
return strings.alt;
|
|
88
|
+
case 'ctrl':
|
|
89
|
+
return strings.ctrl;
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
/** Detecta Mac por `navigator.platform`/`userAgent` — usado cuando `platform="auto"`.
|
|
93
|
+
* jsdom no completa `navigator.platform` en los tests: sin señal de Mac se
|
|
94
|
+
* cae a `win` (fallback explícito, no un bug). */
|
|
95
|
+
function detectsMacPlatform() {
|
|
96
|
+
if (typeof navigator === 'undefined')
|
|
97
|
+
return false;
|
|
98
|
+
const platform = navigator.platform || '';
|
|
99
|
+
const userAgent = navigator.userAgent || '';
|
|
100
|
+
return /Mac/i.test(platform) || /Mac/i.test(userAgent);
|
|
101
|
+
}
|
|
102
|
+
const CoKbd = class {
|
|
103
|
+
constructor(hostRef) {
|
|
104
|
+
registerInstance(this, hostRef);
|
|
105
|
+
/** Combinación de teclas separadas por "+", p.ej. "shift+1", "mod+0", "v". */
|
|
106
|
+
this.keys = '';
|
|
107
|
+
/**
|
|
108
|
+
* Plataforma para resolver el render de los modificadores:
|
|
109
|
+
* `mac` → íconos Phosphor (⌘⇧⌥⌃); `win` → etiquetas de texto (`kbdI18n`).
|
|
110
|
+
* `auto` detecta por `navigator.platform`/`userAgent`; sin señal de Mac
|
|
111
|
+
* (p.ej. jsdom en tests) cae a `win`.
|
|
112
|
+
*/
|
|
113
|
+
this.platform = 'auto';
|
|
114
|
+
/** Superficie donde se apoya: `light` → fondo gray-100 (texto oscuro);
|
|
115
|
+
* `dark` → blanco-16 (texto blanco) — pensado para pills oscuras, p.ej.
|
|
116
|
+
* `co-tooltip` variant="label". */
|
|
117
|
+
this.surface = 'light';
|
|
118
|
+
/** Tamaño de cada tecla: `sm` 30×18 (con ícono 12px) · `xs` 16×16 (solo texto/1 char). */
|
|
119
|
+
this.size = 'sm';
|
|
120
|
+
/**
|
|
121
|
+
* Modo acorde: toda la combinación en UN solo chip (`part="key"`; 30×18 en
|
|
122
|
+
* `sm`, 16 de alto en `xs`), sin separadores "+" — cada token va en una
|
|
123
|
+
* celda (`part="cell"`) de 12 de alto: ícono Phosphor de 12px en una celda
|
|
124
|
+
* de 12×12 fija (modificadores en mac); texto en una celda que crece con su
|
|
125
|
+
* contenido, mínimo 12 (modificadores en win, teclas sueltas). El chip
|
|
126
|
+
* ensancha con las celdas. `role="group"` y `aria-label` no cambian. Sin
|
|
127
|
+
* `chord`, el modo de siempre: un chip por tecla + separadores.
|
|
128
|
+
*/
|
|
129
|
+
this.chord = false;
|
|
130
|
+
}
|
|
131
|
+
resolvePlatform() {
|
|
132
|
+
if (this.platform === 'mac')
|
|
133
|
+
return 'mac';
|
|
134
|
+
if (this.platform === 'win')
|
|
135
|
+
return 'win';
|
|
136
|
+
return detectsMacPlatform() ? 'mac' : 'win';
|
|
137
|
+
}
|
|
138
|
+
render() {
|
|
139
|
+
const tokens = parseKeyTokens(this.keys);
|
|
140
|
+
const platform = this.resolvePlatform();
|
|
141
|
+
const strings = getKbdStrings(this.locale);
|
|
142
|
+
const iconSize = this.size === 'sm' ? 12 : 10;
|
|
143
|
+
const ariaLabel = tokens
|
|
144
|
+
.map((token) => (isModifierToken(token) ? modifierLabel(token, platform, strings) : token.toUpperCase()))
|
|
145
|
+
.join(' + ');
|
|
146
|
+
/** Un token se ve como ícono solo si es modificador Y la plataforma es
|
|
147
|
+
* mac; todo lo demás (modificadores en win, teclas sueltas) es texto. */
|
|
148
|
+
const rendersAsIcon = (token) => isModifierToken(token) && platform === 'mac';
|
|
149
|
+
/** Contenido visible de un token: ícono (mac) o texto (win) para los
|
|
150
|
+
* modificadores; la tecla suelta siempre en mayúscula. */
|
|
151
|
+
const renderToken = (token, size) => rendersAsIcon(token) ? (h("co-icon", { name: MAC_ICON_BY_MODIFIER[token], size: size })) : isModifierToken(token) ? (modifierLabel(token, platform, strings)) : (token.toUpperCase());
|
|
152
|
+
const keyNodes = [];
|
|
153
|
+
if (this.chord) {
|
|
154
|
+
// Un solo chip, sin "+". La celda con ÍCONO es 12×12 fija; la de TEXTO
|
|
155
|
+
// ("Ctrl"/"Shift" en win, "Esc"/"F1" en cualquier plataforma) crece con
|
|
156
|
+
// su contenido — con 12px fijos desbordaba y pisaba al token siguiente
|
|
157
|
+
// (fix round 1).
|
|
158
|
+
keyNodes.push(h("kbd", { class: "co-kbd__key co-kbd__key--chord", part: "key", key: "chord" }, tokens.map((token, index) => (h("span", { class: {
|
|
159
|
+
'co-kbd__cell': true,
|
|
160
|
+
'co-kbd__cell--icon': rendersAsIcon(token),
|
|
161
|
+
'co-kbd__cell--text': !rendersAsIcon(token),
|
|
162
|
+
}, part: "cell", key: `cell-${index}` }, renderToken(token, CHORD_ICON_SIZE))))));
|
|
163
|
+
}
|
|
164
|
+
else {
|
|
165
|
+
tokens.forEach((token, index) => {
|
|
166
|
+
if (index > 0) {
|
|
167
|
+
keyNodes.push(h("span", { class: "co-kbd__sep", part: "sep", key: `sep-${index}` }, "+"));
|
|
168
|
+
}
|
|
169
|
+
keyNodes.push(h("kbd", { class: "co-kbd__key", part: "key", key: `key-${index}` }, renderToken(token, iconSize)));
|
|
170
|
+
});
|
|
171
|
+
}
|
|
172
|
+
return (h("span", { key: '7a99812a76e02cf357694da3bbea990118c8fff5', class: {
|
|
173
|
+
'co-kbd': true,
|
|
174
|
+
[`co-kbd--${this.size}`]: true,
|
|
175
|
+
[`co-kbd--${this.surface}`]: true,
|
|
176
|
+
'co-kbd--chord': this.chord,
|
|
177
|
+
}, role: "group", "aria-label": ariaLabel, part: "group" }, keyNodes));
|
|
178
|
+
}
|
|
179
|
+
};
|
|
180
|
+
CoKbd.style = coKbdCss();
|
|
181
|
+
|
|
182
|
+
const coTooltipCss = () => `:host{display:inline-block;position:relative}.co-tooltip{display:inline-block}.co-tooltip__trigger{display:inline-block}:host([block]){display:block;width:100%;min-width:0}:host([block]) .co-tooltip,:host([block]) .co-tooltip__trigger{display:block;width:100%;min-width:0}.co-tooltip__panel{position:fixed;inset:auto;top:0;left:0;margin:0;border:0;max-height:none;overflow:visible;z-index:10000;visibility:hidden;opacity:0;pointer-events:none;background:var(--co-color-base-negro, #1f1c1b);color:var(--co-color-base-blanco, #fff);font-family:var(--co-font-family-primary, 'Geist', sans-serif);font-size:var(--co-font-size-12, 12px);line-height:1.4;font-weight:400;text-transform:none;letter-spacing:var(--co-font-letter-spacing-body, normal);padding:var(--co-spacing-xs, 4px) var(--co-spacing-sm, 8px);border-radius:var(--co-border-radius-xxs, 4px);box-shadow:0 4px 12px rgba(31, 28, 27, 0.12);white-space:normal;word-wrap:break-word;transition:opacity var(--co-motion-duration-fast) var(--co-motion-ease-out), transform var(--co-motion-duration-fast) var(--co-motion-ease-out)}.co-tooltip__panel--positioned{visibility:visible;opacity:1}.co-tooltip__panel--closing{visibility:visible;opacity:0;transition:opacity var(--co-motion-duration-instant) var(--co-motion-ease-in), transform var(--co-motion-duration-instant) var(--co-motion-ease-in)}.co-tooltip__panel--top{transform:translateY(4px)}.co-tooltip__panel--top.co-tooltip__panel--positioned{transform:translateY(0)}.co-tooltip__panel--bottom{transform:translateY(-4px)}.co-tooltip__panel--bottom.co-tooltip__panel--positioned{transform:translateY(0)}.co-tooltip__panel--left{transform:translateX(4px)}.co-tooltip__panel--left.co-tooltip__panel--positioned{transform:translateX(0)}.co-tooltip__panel--right{transform:translateX(-4px)}.co-tooltip__panel--right.co-tooltip__panel--positioned{transform:translateX(0)}.co-tooltip__arrow{position:absolute;width:0;height:0;border:5px solid transparent}.co-tooltip__arrow--top{bottom:-10px;left:50%;transform:translateX(-50%);border-top-color:var(--co-color-base-negro, #1f1c1b);border-bottom:none}.co-tooltip__arrow--bottom{top:-5px;left:50%;transform:translateX(-50%);border-bottom-color:var(--co-color-base-negro, #1f1c1b);border-top:none}.co-tooltip__arrow--left{right:-10px;top:50%;transform:translateY(-50%);border-left-color:var(--co-color-base-negro, #1f1c1b);border-right:none}.co-tooltip__arrow--right{left:-5px;top:50%;transform:translateY(-50%);border-right-color:var(--co-color-base-negro, #1f1c1b);border-left:none}.co-tooltip__content{display:block}.co-tooltip__panel--label{padding:4px 8px;border-radius:var(--co-border-radius-xs, 8px);font-weight:var(--co-font-weight-medium, 500);line-height:1;box-shadow:none}.co-tooltip__panel--label .co-tooltip__arrow{display:none}.co-tooltip__panel--with-shortcut{display:flex;align-items:center;gap:6px}.co-tooltip__panel--with-shortcut:not(.co-tooltip__panel--label){padding-right:10px;}.co-tooltip__panel--label.co-tooltip__panel--with-shortcut{padding-right:4px}`;
|
|
5
183
|
|
|
6
184
|
const CoTooltip = class {
|
|
7
185
|
constructor(hostRef) {
|
|
@@ -29,6 +207,13 @@ const CoTooltip = class {
|
|
|
29
207
|
* must fill its track — e.g. an ellipsised list/table cell — without the
|
|
30
208
|
* inline-block wrapper shrink-wrapping it. Drives the `:host([block])` CSS. */
|
|
31
209
|
this.block = false;
|
|
210
|
+
/**
|
|
211
|
+
* Visual variant. `label` = compact pill for a labeled trigger with an
|
|
212
|
+
* optional keyboard shortcut (radius `--co-border-radius-xs`, tighter
|
|
213
|
+
* padding, medium (500) text, `line-height: 1`, no shadow, arrow hidden). The
|
|
214
|
+
* arrow hide is CSS-only — `arrow`'s own default/behavior is unchanged.
|
|
215
|
+
*/
|
|
216
|
+
this.variant = 'default';
|
|
32
217
|
// ── State ──────────────────────────────────────────────────
|
|
33
218
|
this.visible = false;
|
|
34
219
|
this.actualPlacement = 'top';
|
|
@@ -260,17 +445,19 @@ const CoTooltip = class {
|
|
|
260
445
|
// ── Render ─────────────────────────────────────────────────
|
|
261
446
|
render() {
|
|
262
447
|
const side = this.actualPlacement.split('-')[0];
|
|
263
|
-
return (h("div", { key: '
|
|
448
|
+
return (h("div", { key: '42e40af183afae3fe39ea52e7ab834d2e2ef2a1f', class: "co-tooltip" }, h("div", { key: '021c63ead4abcfc8bd938657af0f4486a710e1d0', class: "co-tooltip__trigger", ref: (el) => (this.triggerEl = el), onMouseEnter: this.handleMouseEnter, onMouseLeave: this.handleMouseLeave, onPointerDown: this.handlePointerDown, onFocusin: this.handleFocusIn, onFocusout: this.handleFocusOut, onKeyDown: this.handleKeyDown, "aria-describedby": this.visible ? 'tooltip-panel' : undefined }, h("slot", { key: '93bfbae6583c49cd0e38accce52b2ee7029a3bc0' })), (this.visible || this.closing) && this.content && (h("div", { key: 'd5bf6003b83490d21869f41ae49c24dd347b7d82', id: "tooltip-panel", class: {
|
|
264
449
|
'co-tooltip__panel': true,
|
|
265
450
|
[`co-tooltip__panel--${side}`]: true,
|
|
266
451
|
'co-tooltip__panel--closing': this.closing,
|
|
267
|
-
|
|
452
|
+
'co-tooltip__panel--label': this.variant === 'label',
|
|
453
|
+
'co-tooltip__panel--with-shortcut': !!this.shortcut,
|
|
454
|
+
}, role: "tooltip", popover: "manual", part: "panel", onTransitionEnd: this.handlePanelTransitionEnd, ref: (el) => {
|
|
268
455
|
if (el && el !== this.panelEl) {
|
|
269
456
|
this.panelEl = el;
|
|
270
457
|
this.promotePanel();
|
|
271
458
|
this.scheduleUpdate();
|
|
272
459
|
}
|
|
273
|
-
}, style: { maxWidth: this.maxWidth } }, this.arrow && h("div", { key: '
|
|
460
|
+
}, style: { maxWidth: this.maxWidth } }, this.arrow && h("div", { key: '1f3ef81dd7d655e68958321a33a5d405ba671f83', class: `co-tooltip__arrow co-tooltip__arrow--${side}` }), h("span", { key: 'a33a95e77ee0bc6922a0c81a63f9862b2ccf9bf5', class: "co-tooltip__content" }, this.content), this.shortcut && h("co-kbd", { key: '608bba77bfc7d43a3ca4d4a2f0c87290b1a9de57', keys: this.shortcut, surface: "dark", size: "xs" })))));
|
|
274
461
|
}
|
|
275
462
|
get el() { return getElement(this); }
|
|
276
463
|
static get watchers() { return {
|
|
@@ -284,4 +471,4 @@ const CoTooltip = class {
|
|
|
284
471
|
};
|
|
285
472
|
CoTooltip.style = coTooltipCss();
|
|
286
473
|
|
|
287
|
-
export { CoTooltip as co_tooltip };
|
|
474
|
+
export { CoKbd as co_kbd, CoTooltip as co_tooltip };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as registerInstance, c as createEvent, h, a as getElement } from './index-
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, a as getElement } from './index-DJkaRtbb.js';
|
|
2
2
|
import { l as langFromLocale } from './dateI18n-jYd9gu_c.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
@@ -516,7 +516,7 @@ const CoLightbox = class {
|
|
|
516
516
|
const counter = s.counter
|
|
517
517
|
.replace('{i}', String(this.index + 1))
|
|
518
518
|
.replace('{n}', String(imgs.length));
|
|
519
|
-
return (h("div", { key: '
|
|
519
|
+
return (h("div", { key: 'e6c6c55d90c2a0b83d142cf88f158b87c4d2e02a', class: { 'co-lightbox': true, 'co-lightbox--open': this.open }, part: "overlay", role: "dialog", "aria-modal": "true", "aria-label": img === null || img === void 0 ? void 0 : img.alt, popover: "manual", ref: this.syncTopLayer, onClick: this.requestClose }, img && (h("div", { key: 'f488f9a4ceb012d3db6549d555988001782af07b', class: "co-lightbox__toolbar", part: "toolbar", onClick: this.stop }, h("span", { key: 'fb57cbc8fb5ff4be44c77cbad70eba9f5fc20ebb', class: "co-lightbox__caption", title: img.alt }, img.alt), !video && (h("div", { key: 'c7928efd810878d4f7ea261558691759fcd9854c', class: "co-lightbox__zoom" }, h("button", { key: '65f92f021c1ba3feca3aa6fe18cd3feee54a5ef3', class: "co-lightbox__btn", type: "button", "aria-label": s.zoomOut, title: s.zoomOut, onClick: () => this.zoomAt(this.scale / WHEEL_FACTOR, 0, 0) }, h("co-icon", { key: '2079736e31b26e8f5acef8613f91a3bf98ca02c2', name: "minus", size: 16 })), h("button", { key: '31e7e1257b07f7232788a1a399bcb681f2685807', class: "co-lightbox__btn co-lightbox__zoom-value", type: "button", "aria-label": s.zoomReset, title: s.zoomReset, onClick: () => this.resetView() }, Math.round(this.scale * 100), "%"), h("button", { key: '0b7093aa5e7065db71419eef348422732f644b1a', class: "co-lightbox__btn", type: "button", "aria-label": s.zoomIn, title: s.zoomIn, onClick: () => this.zoomAt(this.scale * WHEEL_FACTOR, 0, 0) }, h("co-icon", { key: 'f0e782492b2d902af14de1d3cfbc83d9b202e78c', name: "plus", size: 16 })))), h("button", { key: 'b0e78378c3ba4270d951f269fdf04fa60601efb5', class: "co-lightbox__btn", type: "button", "aria-label": s.openOriginal, title: s.openOriginal, onClick: this.openOriginal }, h("co-icon", { key: 'dad0c979349c6c6a6b20962609d09a7c3bde55dc', name: "arrow-square-out", size: 16 })), h("button", { key: '209e8ad1ab624b30f8917a3731c2562724ac7f88', class: "co-lightbox__btn", part: "close", type: "button", "aria-label": s.close, title: s.close, ref: (el) => (this.closeBtnEl = el), onClick: this.requestClose }, h("co-icon", { key: '72c135d4b3a88ea4c87b162bc5a5651b488049b2', name: "x", size: 16 })))), img && (h("div", { key: 'af781758e0da002fc011c5a93461d7c93752a093', class: "co-lightbox__stage", ref: (el) => (this.stageEl = el), onWheel: video ? undefined : this.handleWheel }, video ? (h("co-video", { class: "co-lightbox__video", part: "video",
|
|
520
520
|
/* Keyed per slide: a fresh player is the only way to be sure
|
|
521
521
|
poster, error state and playback all start clean. */
|
|
522
522
|
key: `video-${this.index}`, ref: this.mountPlayer, src: img.src, poster: img.poster || '', aspectRatio: "auto", rounded: "none",
|
|
@@ -526,13 +526,13 @@ const CoLightbox = class {
|
|
|
526
526
|
'co-lightbox__img': true,
|
|
527
527
|
'co-lightbox__img--zoomed': this.scale > MIN_SCALE,
|
|
528
528
|
'co-lightbox__img--dragging': this.dragging,
|
|
529
|
-
}, part: "image", ref: (el) => (this.imgEl = el), src: img.src, alt: img.alt || '', draggable: false, style: { transform: `translate(${this.tx}px, ${this.ty}px) scale(${this.scale})` }, onClick: this.stop, onDblClick: this.handleDblClick, onPointerDown: this.handlePointerDown, onPointerMove: this.handlePointerMove, onPointerUp: this.handlePointerUp, onPointerCancel: this.handlePointerUp })))), img && multi && (h("button", { key: '
|
|
529
|
+
}, part: "image", ref: (el) => (this.imgEl = el), src: img.src, alt: img.alt || '', draggable: false, style: { transform: `translate(${this.tx}px, ${this.ty}px) scale(${this.scale})` }, onClick: this.stop, onDblClick: this.handleDblClick, onPointerDown: this.handlePointerDown, onPointerMove: this.handlePointerMove, onPointerUp: this.handlePointerUp, onPointerCancel: this.handlePointerUp })))), img && multi && (h("button", { key: '014622508d9f057d3063dbafefb79d9db7d182d6', class: "co-lightbox__nav co-lightbox__nav--prev", part: "prev", type: "button", "aria-label": s.prevImage, title: s.prevImage, onClick: (e) => {
|
|
530
530
|
e.stopPropagation();
|
|
531
531
|
this.goTo(-1);
|
|
532
|
-
} }, h("co-icon", { key: '
|
|
532
|
+
} }, h("co-icon", { key: '8751f7fd41bc9ff145d1f41b18bc1fc719f4791e', name: "caret-left", size: 24 }))), img && multi && (h("button", { key: '1fae0772a594c9354db4d0aace04b6741cf7ae1b', class: "co-lightbox__nav co-lightbox__nav--next", part: "next", type: "button", "aria-label": s.nextImage, title: s.nextImage, onClick: (e) => {
|
|
533
533
|
e.stopPropagation();
|
|
534
534
|
this.goTo(1);
|
|
535
|
-
} }, h("co-icon", { key: '
|
|
535
|
+
} }, h("co-icon", { key: '7823ad091764d26ed79e460c0288b97dec1260bb', name: "caret-right", size: 24 }))), img && multi && (h("div", { key: '3aa1f701ddf4c433c48790550071bc0c4e87dbc9', class: "co-lightbox__counter", part: "counter", onClick: this.stop }, counter))));
|
|
536
536
|
}
|
|
537
537
|
get el() { return getElement(this); }
|
|
538
538
|
static get watchers() { return {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as registerInstance, c as createEvent, h } from './index-
|
|
1
|
+
import { r as registerInstance, c as createEvent, h } from './index-DJkaRtbb.js';
|
|
2
2
|
|
|
3
3
|
const coListFooterCss = () => `:host{display:block}.co-list-footer{display:flex;gap:var(--co-spacing-sm2);padding-top:var(--co-spacing-sm2)}.co-list-footer__btn{flex:1;display:flex;align-items:center;justify-content:center;gap:var(--co-spacing-sm);padding:var(--co-spacing-sm2) var(--co-spacing-md);border-radius:var(--co-border-radius-xs);font-family:var(--co-font-family-primary);font-size:var(--co-font-size-12, 12px);font-weight:500;line-height:1;letter-spacing:var(--co-font-letter-spacing-body);white-space:nowrap;cursor:pointer;transition:opacity var(--co-motion-duration-fast) var(--co-motion-ease-out);box-sizing:border-box;min-height:32px}.co-list-footer__btn:hover{opacity:0.85}.co-list-footer__btn:focus-visible{outline:2px solid var(--co-semantic-border-focus);outline-offset:2px}.co-list-footer__btn--secondary{background:transparent;color:var(--co-semantic-text-default);border:1px solid var(--co-semantic-border-default)}.co-list-footer__btn--primary{background:var(--co-semantic-surface-primary);color:var(--co-semantic-on-primary);border:none}`;
|
|
4
4
|
|
|
@@ -15,7 +15,7 @@ const CoListFooter = class {
|
|
|
15
15
|
this.handleSecondary = () => this.coSecondary.emit();
|
|
16
16
|
}
|
|
17
17
|
render() {
|
|
18
|
-
return (h("div", { key: '
|
|
18
|
+
return (h("div", { key: 'f0c91f1eb20fbbd57da3a9de3ee9596b1c726ccf', class: "co-list-footer", part: "footer" }, this.secondaryLabel && (h("button", { key: 'c43b6137c82ab5ecb8493dcabb93a0b6e1fb8527', class: "co-list-footer__btn co-list-footer__btn--secondary", type: "button", onClick: this.handleSecondary }, this.secondaryIcon && h("co-icon", { key: '4723de7f0236643d8ecee7041144c058478237b6', name: this.secondaryIcon, size: 16 }), h("span", { key: '798e8a622a2b0784849e8040501ae92f87a9fab9' }, this.secondaryLabel))), this.primaryLabel && (h("button", { key: '0ce5cdab965ede9ad2489354f31d0f0d55e3fba5', class: "co-list-footer__btn co-list-footer__btn--primary", type: "button", onClick: this.handlePrimary }, this.primaryIcon && h("co-icon", { key: '50e5fb43c0966cb939ba3daced28916e1fe766dd', name: this.primaryIcon, size: 16 }), h("span", { key: 'd2bf250cb31ae5e7ff3595ecbb4234a493744e67' }, this.primaryLabel))), h("slot", { key: 'dd002081999ed611aef5a411e7011b804e7036ff' })));
|
|
19
19
|
}
|
|
20
20
|
};
|
|
21
21
|
CoListFooter.style = coListFooterCss();
|