@prolibu-suite/cobalt-core 0.10.0 → 0.10.1
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 +395 -29
- package/dist/cjs/co-accordion.cjs.entry.js +4 -4
- package/dist/cjs/co-action-bar.cjs.entry.js +1 -1
- package/dist/cjs/co-audio-player.cjs.entry.js +82 -12
- package/dist/cjs/co-avatar.cjs.entry.js +72 -0
- package/dist/cjs/co-button.cjs.entry.js +1 -1
- package/dist/cjs/co-checkbox.cjs.entry.js +3 -3
- package/dist/cjs/co-chip_2.cjs.entry.js +62 -10
- package/dist/cjs/co-color-picker.cjs.entry.js +40 -10
- package/dist/cjs/co-data-table.cjs.entry.js +82 -4
- package/dist/cjs/co-input.cjs.entry.js +6 -2
- package/dist/cjs/co-menu-item.cjs.entry.js +1 -1
- package/dist/cjs/co-modal.cjs.entry.js +7 -3
- package/dist/cjs/co-navbar.cjs.entry.js +2 -2
- package/dist/cjs/co-number-field.cjs.entry.js +3 -3
- package/dist/cjs/co-overlay.cjs.entry.js +1 -1
- package/dist/cjs/co-page-header.cjs.entry.js +1 -1
- package/dist/cjs/co-phone-field.cjs.entry.js +1 -1
- package/dist/cjs/co-progress-bar.cjs.entry.js +2 -2
- package/dist/cjs/co-progress-circle.cjs.entry.js +2 -2
- package/dist/cjs/co-provider-logo_2.cjs.entry.js +1 -1
- package/dist/cjs/co-radio.cjs.entry.js +3 -3
- package/dist/cjs/co-rating.cjs.entry.js +3 -3
- package/dist/cjs/co-ref-field.cjs.entry.js +100 -9
- package/dist/cjs/co-rich-text-editor.cjs.entry.js +3 -3
- package/dist/cjs/co-row.cjs.entry.js +2 -2
- package/dist/cjs/co-select.cjs.entry.js +4 -4
- package/dist/cjs/co-separator.cjs.entry.js +1 -1
- package/dist/cjs/co-sidebar.cjs.entry.js +2 -2
- package/dist/cjs/co-slider.cjs.entry.js +2 -2
- package/dist/cjs/co-switch.cjs.entry.js +3 -3
- package/dist/cjs/co-tab-group.cjs.entry.js +2 -2
- package/dist/cjs/co-tab.cjs.entry.js +2 -2
- package/dist/cjs/co-tags-field.cjs.entry.js +5 -5
- package/dist/cjs/co-textarea.cjs.entry.js +4 -4
- package/dist/cjs/co-time-field.cjs.entry.js +1 -1
- package/dist/cjs/co-toggle-button-group.cjs.entry.js +3 -3
- package/dist/cjs/co-toggle-button.cjs.entry.js +3 -3
- package/dist/cjs/{co-avatar_2.cjs.entry.js → co-tooltip.cjs.entry.js} +2 -70
- package/dist/cjs/co-video.cjs.entry.js +2 -2
- package/dist/cjs/cobalt.cjs.js +1 -1
- package/dist/cjs/index-MDAnKsze.js +12 -8
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cobalt/cobalt.esm.js +1 -1
- package/dist/cobalt/{p-82266f11.entry.js → p-000a15b8.entry.js} +1 -1
- package/dist/cobalt/{p-fe7e8813.entry.js → p-148d4aa6.entry.js} +1 -1
- package/dist/cobalt/p-16f8cee6.entry.js +1 -0
- package/dist/cobalt/p-239c5c5f.entry.js +1 -0
- package/dist/cobalt/{p-4d897896.entry.js → p-28764b8e.entry.js} +1 -1
- package/dist/cobalt/{p-73c6d735.entry.js → p-2a30c143.entry.js} +1 -1
- package/dist/cobalt/{p-85501c6a.entry.js → p-2f0f3bb1.entry.js} +1 -1
- package/dist/cobalt/{p-e01f9b9a.entry.js → p-2fba312b.entry.js} +1 -1
- package/dist/cobalt/p-354d5089.entry.js +1 -0
- package/dist/cobalt/{p-5298c030.entry.js → p-383a998e.entry.js} +1 -1
- package/dist/cobalt/{p-325b91b6.entry.js → p-3c4f7026.entry.js} +1 -1
- package/dist/cobalt/p-416795f5.entry.js +1 -0
- package/dist/cobalt/{p-54c987d7.entry.js → p-5a3e4c81.entry.js} +1 -1
- package/dist/cobalt/p-5adf117c.entry.js +1 -0
- package/dist/cobalt/{p-83a9a05a.entry.js → p-5ca394b1.entry.js} +1 -1
- package/dist/cobalt/{p-1a589c8e.entry.js → p-5e4973a6.entry.js} +1 -1
- package/dist/cobalt/{p-b565104d.entry.js → p-6c82a892.entry.js} +1 -1
- package/dist/cobalt/{p-83ea631d.entry.js → p-789c4b3e.entry.js} +1 -1
- package/dist/cobalt/{p-ea20f048.entry.js → p-7e8e6907.entry.js} +1 -1
- package/dist/cobalt/{p-10b82207.entry.js → p-8471abe2.entry.js} +1 -1
- package/dist/cobalt/p-8f2199ff.entry.js +1 -0
- package/dist/cobalt/p-9246e09c.entry.js +1 -0
- package/dist/cobalt/{p-eb063cc0.entry.js → p-93fe45fd.entry.js} +1 -1
- package/dist/cobalt/{p-ad33c40e.entry.js → p-95cfcb34.entry.js} +1 -1
- package/dist/cobalt/{p-bd683db3.entry.js → p-9cf738ed.entry.js} +1 -1
- package/dist/cobalt/p-a2462d7a.entry.js +1 -0
- package/dist/cobalt/p-a325ea0c.entry.js +1 -0
- package/dist/cobalt/{p-e8a4e6b0.entry.js → p-b5bba7fe.entry.js} +1 -1
- package/dist/cobalt/{p-6bf6bc3e.entry.js → p-b821d9de.entry.js} +1 -1
- package/dist/cobalt/{p-92b092db.entry.js → p-be34e447.entry.js} +1 -1
- package/dist/cobalt/p-c7d7d7f7.entry.js +1 -0
- package/dist/cobalt/{p-aae86f96.entry.js → p-d0b2c418.entry.js} +1 -1
- package/dist/cobalt/{p-50bcc76f.entry.js → p-d3344187.entry.js} +1 -1
- package/dist/cobalt/p-d375014b.entry.js +1 -0
- package/dist/cobalt/p-d9d9e8ae.entry.js +1 -0
- package/dist/cobalt/p-e371ec7a.entry.js +1 -0
- package/dist/cobalt/p-eadfd661.entry.js +1 -0
- package/dist/cobalt/p-ef301976.entry.js +1 -0
- package/dist/cobalt/{p-f68dd124.entry.js → p-fb2d1144.entry.js} +1 -1
- package/dist/collection/components/co-accordion/co-accordion.css +2 -2
- package/dist/collection/components/co-accordion/co-accordion.js +4 -4
- package/dist/collection/components/co-action-bar/co-action-bar.css +9 -2
- package/dist/collection/components/co-audio-player/co-audio-player.js +138 -12
- package/dist/collection/components/co-autocomplete/co-autocomplete.js +1 -1
- package/dist/collection/components/co-avatar-group/co-avatar-group.js +1 -1
- package/dist/collection/components/co-button/co-button.css +6 -3
- package/dist/collection/components/co-checkbox/co-checkbox.js +22 -3
- package/dist/collection/components/co-checkbox-group/co-checkbox-group.js +1 -1
- package/dist/collection/components/co-color-picker/co-color-picker.js +40 -10
- package/dist/collection/components/co-combobox/co-combobox.js +1 -1
- package/dist/collection/components/co-command-search/co-command-search.js +1 -1
- package/dist/collection/components/co-data-table/co-data-table.css +63 -2
- package/dist/collection/components/co-data-table/co-data-table.js +59 -4
- package/dist/collection/components/co-data-table/headerTruncationLogic.js +34 -0
- package/dist/collection/components/co-date-range-picker/co-date-range-picker.js +2 -2
- package/dist/collection/components/co-input/co-input.js +17 -5
- package/dist/collection/components/co-menu-item/co-menu-item.css +9 -0
- package/dist/collection/components/co-modal/co-modal.css +6 -0
- package/dist/collection/components/co-modal/co-modal.js +33 -2
- 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.js +32 -3
- package/dist/collection/components/co-option-list/optionListLogic.js +31 -8
- package/dist/collection/components/co-overlay/co-overlay.js +1 -1
- package/dist/collection/components/co-page-header/co-page-header.js +1 -1
- package/dist/collection/components/co-phone-field/co-phone-field.js +1 -1
- package/dist/collection/components/co-popover/co-popover.js +1 -1
- package/dist/collection/components/co-progress-bar/co-progress-bar.js +2 -2
- package/dist/collection/components/co-progress-circle/co-progress-circle.js +2 -2
- package/dist/collection/components/co-radio/co-radio.js +3 -3
- package/dist/collection/components/co-radio-group/co-radio-group.js +1 -1
- package/dist/collection/components/co-rating/co-rating.js +3 -3
- package/dist/collection/components/co-ref-field/co-ref-field.css +40 -0
- package/dist/collection/components/co-ref-field/co-ref-field.js +207 -11
- package/dist/collection/components/co-rich-text-editor/co-rich-text-editor.js +3 -3
- package/dist/collection/components/co-row/co-row.js +2 -2
- package/dist/collection/components/co-segmented-bar/co-segmented-bar.js +1 -1
- package/dist/collection/components/co-select/co-select.js +24 -5
- 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.js +1 -1
- package/dist/collection/components/co-skeleton/co-skeleton.js +1 -1
- package/dist/collection/components/co-slider/co-slider.js +2 -2
- package/dist/collection/components/co-switch/co-switch.js +3 -3
- package/dist/collection/components/co-tab/co-tab.js +2 -2
- package/dist/collection/components/co-tab-group/co-tab-group.js +2 -2
- 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-time-field/co-time-field.js +1 -1
- package/dist/collection/components/co-toast/co-toast.js +2 -2
- package/dist/collection/components/co-toggle-button/co-toggle-button.css +6 -5
- package/dist/collection/components/co-toggle-button/co-toggle-button.js +2 -2
- package/dist/collection/components/co-toggle-button-group/co-toggle-button-group.css +9 -5
- package/dist/collection/components/co-toggle-button-group/co-toggle-button-group.js +2 -2
- package/dist/collection/components/co-tooltip/co-tooltip.js +2 -2
- package/dist/collection/components/co-transfer-list/co-transfer-list.js +1 -1
- package/dist/collection/components/co-video/co-video.js +2 -2
- package/dist/components/co-accordion.js +1 -1
- package/dist/components/co-action-bar.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-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-checkbox.js +1 -1
- package/dist/components/co-color-picker.js +1 -1
- package/dist/components/co-column-picker.js +1 -1
- package/dist/components/co-combobox.js +1 -1
- package/dist/components/co-command-search.js +1 -1
- package/dist/components/co-data-table.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-drawer.js +1 -1
- package/dist/components/co-event-calendar.js +1 -1
- package/dist/components/co-file-field.js +1 -1
- package/dist/components/co-input.js +1 -1
- package/dist/components/co-lightbox.js +1 -1
- package/dist/components/co-list-item.js +1 -1
- package/dist/components/co-menu-item.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-progress-bar.js +1 -1
- package/dist/components/co-progress-circle.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-row.js +1 -1
- package/dist/components/co-select.js +1 -1
- package/dist/components/co-separator.js +1 -1
- package/dist/components/co-sidebar-nav.js +1 -1
- package/dist/components/co-sidebar.js +1 -1
- package/dist/components/co-skeleton.js +1 -1
- package/dist/components/co-slider.js +1 -1
- package/dist/components/co-switch.js +1 -1
- package/dist/components/co-tab-group.js +1 -1
- package/dist/components/co-tab.js +1 -1
- package/dist/components/co-tags-field.js +1 -1
- package/dist/components/co-textarea.js +1 -1
- package/dist/components/co-time-field.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-video.js +1 -1
- package/dist/components/p-7TncUlLN.js +1 -0
- package/dist/components/{p-BxP8OBw6.js → p-B9xitpGU.js} +1 -1
- package/dist/components/{p-x4grh-eZ.js → p-CBTGN490.js} +1 -1
- package/dist/components/{p-CXPRaTuo.js → p-CLsAo0-A.js} +1 -1
- package/dist/components/{p-B1QFLcY9.js → p-D2ldYZo1.js} +1 -1
- package/dist/components/{p-Bv6U5y3d.js → p-D3mVYO-G.js} +1 -1
- package/dist/components/{p-DkDTmHCg.js → p-DDV_bRcU.js} +1 -1
- package/dist/components/{p-Be_kyNRE.js → p-DSnJWzQw.js} +1 -1
- package/dist/components/{p-BBP5__CY.js → p-DTi2O4O8.js} +1 -1
- package/dist/components/p-De7w9k6_.js +1 -0
- package/dist/components/{p-Cl3AdEQJ.js → p-DoHLTC0n.js} +1 -1
- package/dist/components/{p-CnX3L8aF.js → p-DxtNejr2.js} +1 -1
- package/dist/components/p-wjt4IAGZ.js +1 -0
- package/dist/components/{p-DIo66nBr.js → p-zuhal3IZ.js} +1 -1
- package/dist/esm/co-accordion.entry.js +4 -4
- package/dist/esm/co-action-bar.entry.js +1 -1
- package/dist/esm/co-audio-player.entry.js +82 -12
- package/dist/esm/co-avatar.entry.js +70 -0
- package/dist/esm/co-button.entry.js +1 -1
- package/dist/esm/co-checkbox.entry.js +3 -3
- package/dist/esm/co-chip_2.entry.js +62 -10
- package/dist/esm/co-color-picker.entry.js +40 -10
- package/dist/esm/co-data-table.entry.js +82 -4
- package/dist/esm/co-input.entry.js +6 -2
- package/dist/esm/co-menu-item.entry.js +1 -1
- package/dist/esm/co-modal.entry.js +7 -3
- package/dist/esm/co-navbar.entry.js +2 -2
- package/dist/esm/co-number-field.entry.js +3 -3
- package/dist/esm/co-overlay.entry.js +1 -1
- package/dist/esm/co-page-header.entry.js +1 -1
- package/dist/esm/co-phone-field.entry.js +1 -1
- package/dist/esm/co-progress-bar.entry.js +2 -2
- package/dist/esm/co-progress-circle.entry.js +2 -2
- package/dist/esm/co-provider-logo_2.entry.js +1 -1
- package/dist/esm/co-radio.entry.js +3 -3
- package/dist/esm/co-rating.entry.js +3 -3
- package/dist/esm/co-ref-field.entry.js +100 -9
- package/dist/esm/co-rich-text-editor.entry.js +3 -3
- package/dist/esm/co-row.entry.js +2 -2
- package/dist/esm/co-select.entry.js +4 -4
- package/dist/esm/co-separator.entry.js +1 -1
- package/dist/esm/co-sidebar.entry.js +2 -2
- package/dist/esm/co-slider.entry.js +2 -2
- package/dist/esm/co-switch.entry.js +3 -3
- package/dist/esm/co-tab-group.entry.js +2 -2
- package/dist/esm/co-tab.entry.js +2 -2
- package/dist/esm/co-tags-field.entry.js +5 -5
- package/dist/esm/co-textarea.entry.js +4 -4
- package/dist/esm/co-time-field.entry.js +1 -1
- package/dist/esm/co-toggle-button-group.entry.js +3 -3
- package/dist/esm/co-toggle-button.entry.js +3 -3
- package/dist/esm/{co-avatar_2.entry.js → co-tooltip.entry.js} +3 -70
- package/dist/esm/co-video.entry.js +2 -2
- package/dist/esm/cobalt.js +1 -1
- package/dist/esm/index-DH5lfRNj.js +12 -8
- package/dist/esm/loader.js +1 -1
- package/dist/types/components/co-accordion/co-accordion.d.ts +6 -0
- package/dist/types/components/co-audio-player/co-audio-player.d.ts +25 -0
- package/dist/types/components/co-checkbox/co-checkbox.d.ts +4 -0
- package/dist/types/components/co-color-picker/co-color-picker.d.ts +4 -2
- package/dist/types/components/co-data-table/co-data-table.d.ts +15 -0
- package/dist/types/components/co-data-table/headerTruncationLogic.d.ts +24 -0
- package/dist/types/components/co-input/co-input.d.ts +5 -1
- package/dist/types/components/co-modal/co-modal.d.ts +10 -0
- package/dist/types/components/co-option-list/co-option-list.d.ts +13 -0
- package/dist/types/components/co-option-list/optionListLogic.d.ts +23 -6
- package/dist/types/components/co-ref-field/co-ref-field.d.ts +38 -0
- package/dist/types/components/co-select/co-select.d.ts +6 -0
- package/dist/types/components.d.ts +79 -3
- package/package.json +2 -2
- package/dist/cobalt/p-15d59169.entry.js +0 -1
- package/dist/cobalt/p-1788aab5.entry.js +0 -1
- package/dist/cobalt/p-20a39218.entry.js +0 -1
- package/dist/cobalt/p-3cc3ff93.entry.js +0 -1
- package/dist/cobalt/p-4908f33f.entry.js +0 -1
- package/dist/cobalt/p-63825d7f.entry.js +0 -1
- package/dist/cobalt/p-6f700f0d.entry.js +0 -1
- package/dist/cobalt/p-88195a63.entry.js +0 -1
- package/dist/cobalt/p-8fa5dc4a.entry.js +0 -1
- package/dist/cobalt/p-b1e8d69e.entry.js +0 -1
- package/dist/cobalt/p-b48917c9.entry.js +0 -1
- package/dist/cobalt/p-c32c176a.entry.js +0 -1
- package/dist/cobalt/p-e48f4e45.entry.js +0 -1
- package/dist/cobalt/p-ef5ca521.entry.js +0 -1
- package/dist/components/p-9ceBPSd1.js +0 -1
- package/dist/components/p-B2IsXte7.js +0 -1
- package/dist/components/p-BsTO1uUA.js +0 -1
|
@@ -19,7 +19,7 @@ export class CoProgressCircle {
|
|
|
19
19
|
const clamped = Math.max(0, Math.min(100, this.value));
|
|
20
20
|
const angle = (clamped / 100) * 360;
|
|
21
21
|
const safeStroke = Math.min(this.strokeWidth, this.size / 2);
|
|
22
|
-
return (h("div", { key: '
|
|
22
|
+
return (h("div", { key: 'bc100ca3ef731aab3168a247098102b8e9ab9537', class: {
|
|
23
23
|
'co-progress-circle': true,
|
|
24
24
|
[`co-progress-circle--${this.status}`]: true,
|
|
25
25
|
}, role: "progressbar", "aria-valuenow": clamped, "aria-valuemin": 0, "aria-valuemax": 100, part: "circle", style: {
|
|
@@ -27,7 +27,7 @@ export class CoProgressCircle {
|
|
|
27
27
|
height: `${this.size}px`,
|
|
28
28
|
'--co-pc-angle': `${angle}deg`,
|
|
29
29
|
'--co-pc-stroke': `${safeStroke}px`,
|
|
30
|
-
} }, h("div", { key: '
|
|
30
|
+
} }, h("div", { key: '48862f1f57c0bb8cd6e03c2f0a84a1ae324d3ec1', class: "co-progress-circle__track" }), this.showLabel && (h("span", { key: '0ff2c6995740504e1df9b11dfa10e0a9f9d368c5', class: "co-progress-circle__label" }, clamped, "%"))));
|
|
31
31
|
}
|
|
32
32
|
static get is() { return "co-progress-circle"; }
|
|
33
33
|
static get encapsulation() { return "shadow"; }
|
|
@@ -17,15 +17,15 @@ export class CoRadio {
|
|
|
17
17
|
};
|
|
18
18
|
}
|
|
19
19
|
render() {
|
|
20
|
-
return (h("div", { key: '
|
|
20
|
+
return (h("div", { key: '59335ec237efb379852efc4fabcb7cbb37632a1e', class: {
|
|
21
21
|
'co-radio-row': true,
|
|
22
22
|
'co-radio-row--disabled': this.disabled,
|
|
23
|
-
}, onClick: this.handleClick }, h("button", { key: '
|
|
23
|
+
}, onClick: this.handleClick }, h("button", { key: 'dc726deac041e9df4cb34f60a473350426ed2cbc', role: "radio", "aria-checked": String(this.checked), "aria-label": this.label || '', class: {
|
|
24
24
|
'co-radio': true,
|
|
25
25
|
[`co-radio--${this.size}`]: true,
|
|
26
26
|
'co-radio--checked': this.checked,
|
|
27
27
|
'co-radio--disabled': this.disabled,
|
|
28
|
-
}, disabled: this.disabled, part: "circle" }), this.label && (h("span", { key: '
|
|
28
|
+
}, disabled: this.disabled, part: "circle" }), this.label && (h("span", { key: 'bf2602521d20f806283884ba3ebbab4ff4ef0c70', class: "co-radio__label", part: "label" }, this.label))));
|
|
29
29
|
}
|
|
30
30
|
static get is() { return "co-radio"; }
|
|
31
31
|
static get encapsulation() { return "shadow"; }
|
|
@@ -219,7 +219,7 @@ export class CoRadioGroup {
|
|
|
219
219
|
"references": {
|
|
220
220
|
"RadioOption": {
|
|
221
221
|
"location": "local",
|
|
222
|
-
"path": "/Users/agox/
|
|
222
|
+
"path": "/Users/agox/worktrees/cobalt-release/packages/core/src/components/co-radio-group/co-radio-group.tsx",
|
|
223
223
|
"id": "src/components/co-radio-group/co-radio-group.tsx::RadioOption"
|
|
224
224
|
}
|
|
225
225
|
}
|
|
@@ -36,16 +36,16 @@ export class CoRating {
|
|
|
36
36
|
const iconSize = this.size === 'large' ? 28 : 20;
|
|
37
37
|
const active = this.hoverValue || this.value;
|
|
38
38
|
const stars = Array.from({ length: this.max }, (_, i) => i + 1);
|
|
39
|
-
return (h("div", { key: '
|
|
39
|
+
return (h("div", { key: 'a825b7cf49067c0a12ccddb81554c172d90a888f', class: {
|
|
40
40
|
'co-rating': true,
|
|
41
41
|
'co-rating--disabled': this.disabled,
|
|
42
42
|
'co-rating--readonly': this.readOnly,
|
|
43
43
|
[`co-rating--${this.size}`]: true,
|
|
44
|
-
} }, this.label && h("label", { key: '
|
|
44
|
+
} }, this.label && h("label", { key: '354b3b676401d0265e5f64aed1b137b97a147468', class: "co-rating__label" }, this.label), h("div", { key: '29c8af2cde2482ac803e75025dc5533c7051c2ff', class: "co-rating__stars", onMouseLeave: this.handleMouseLeave }, stars.map(star => (h("button", { class: {
|
|
45
45
|
'co-rating__star': true,
|
|
46
46
|
'co-rating__star--active': star <= active,
|
|
47
47
|
'co-rating__star--hover': this.hoverValue > 0 && star <= this.hoverValue,
|
|
48
|
-
}, type: "button", tabIndex: this.disabled || this.readOnly ? -1 : 0, disabled: this.disabled, onClick: () => this.handleClick(star), onMouseEnter: () => this.handleMouseEnter(star), "aria-label": `${star} of ${this.max}` }, h("co-icon", { name: this.icon, size: iconSize, weight: star <= active ? 'fill' : 'regular' }))))), this.helperText && (h("div", { key: '
|
|
48
|
+
}, type: "button", tabIndex: this.disabled || this.readOnly ? -1 : 0, disabled: this.disabled, onClick: () => this.handleClick(star), onMouseEnter: () => this.handleMouseEnter(star), "aria-label": `${star} of ${this.max}` }, h("co-icon", { name: this.icon, size: iconSize, weight: star <= active ? 'fill' : 'regular' }))))), this.helperText && (h("div", { key: '0fcc95b7e125f1ef57c67ed9e46d4511da5d3eaa', class: `co-rating__helper co-rating__helper--${this.status}` }, this.statusIcon && h("co-icon", { key: 'c9cb1f60e902c0b52a45225bedacd92ba08ae0b4', name: this.statusIcon, size: 14, weight: "fill", class: "co-rating__helper-icon" }), h("span", { key: '8a5479175de97fccb5947f2f8f2c87888481b104', class: "co-rating__helper-text" }, this.helperText)))));
|
|
49
49
|
}
|
|
50
50
|
static get is() { return "co-rating"; }
|
|
51
51
|
static get encapsulation() { return "shadow"; }
|
|
@@ -163,6 +163,46 @@
|
|
|
163
163
|
text-overflow: ellipsis;
|
|
164
164
|
}
|
|
165
165
|
|
|
166
|
+
/* Valor heredado (inheritedLabel): lo que aplica por defecto con el campo
|
|
167
|
+
vacío. Se lee como contenido (text-secondary), no como hint (muted), y va
|
|
168
|
+
con un chip outlined opcional (inheritedBadgeLabel) que cabe en el trigger
|
|
169
|
+
md de 40px (22px = alto del contenido). */
|
|
170
|
+
/* El host block del co-tooltip es el ítem flex: min-width:0 acá y display:block
|
|
171
|
+
en el span son lo que deja truncar (un inline dentro del trigger no trunca). */
|
|
172
|
+
.co-ref-field__inherited-tip {
|
|
173
|
+
min-width: 0;
|
|
174
|
+
max-width: 100%;
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
.co-ref-field__inherited {
|
|
178
|
+
display: block;
|
|
179
|
+
color: var(--co-semantic-text-secondary);
|
|
180
|
+
font-size: inherit;
|
|
181
|
+
font-weight: 400;
|
|
182
|
+
line-height: 1;
|
|
183
|
+
white-space: nowrap;
|
|
184
|
+
overflow: hidden;
|
|
185
|
+
text-overflow: ellipsis;
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
.co-ref-field__inherited-badge {
|
|
189
|
+
flex-shrink: 0;
|
|
190
|
+
display: inline-flex;
|
|
191
|
+
align-items: center;
|
|
192
|
+
box-sizing: border-box;
|
|
193
|
+
height: 22px;
|
|
194
|
+
padding: 0 var(--co-spacing-sm2);
|
|
195
|
+
/* Escapes temáticos como el resto del trigger (--co-ref-field-trigger-*):
|
|
196
|
+
sobre una isla oscura en tema light, border-default (negro 16%) desaparece. */
|
|
197
|
+
border: 1px solid var(--co-ref-field-inherited-badge-border, var(--co-semantic-border-default));
|
|
198
|
+
border-radius: var(--co-border-radius-full);
|
|
199
|
+
color: var(--co-ref-field-inherited-badge-color, var(--co-semantic-text-secondary));
|
|
200
|
+
font-size: var(--co-font-size-12);
|
|
201
|
+
font-weight: 400;
|
|
202
|
+
line-height: 1;
|
|
203
|
+
white-space: nowrap;
|
|
204
|
+
}
|
|
205
|
+
|
|
166
206
|
.co-ref-field__caret {
|
|
167
207
|
flex-shrink: 0;
|
|
168
208
|
color: var(--co-semantic-text-muted);
|
|
@@ -79,6 +79,15 @@ export class CoRefField {
|
|
|
79
79
|
this.triggerBadgeIcon = '';
|
|
80
80
|
/** Accessible name / tooltip for the trigger badge. */
|
|
81
81
|
this.triggerBadgeLabel = '';
|
|
82
|
+
/**
|
|
83
|
+
* Valor HEREDADO: texto que se pinta cuando NO hay valor, en lugar del
|
|
84
|
+
* placeholder, para mostrar lo que aplica por defecto (p. ej. el layout
|
|
85
|
+
* predeterminado del workspace en Deal.proposal.template.layout). No es un
|
|
86
|
+
* valor: `value` sigue vacío y no hay ×. Vacío = placeholder de siempre.
|
|
87
|
+
*/
|
|
88
|
+
this.inheritedLabel = '';
|
|
89
|
+
/** Chip outlined junto al valor heredado (p. ej. 'Predeterminado'). Solo con inheritedLabel. */
|
|
90
|
+
this.inheritedBadgeLabel = '';
|
|
82
91
|
/**
|
|
83
92
|
* Shape of the leading avatar (selected value + option rows). Defaults to
|
|
84
93
|
* 'circle' (people refs); use 'square' for company/workspace refs — it renders
|
|
@@ -89,11 +98,21 @@ export class CoRefField {
|
|
|
89
98
|
this.pinnable = false;
|
|
90
99
|
/** Drag-reorder de la lista del panel (forward a co-option-list). */
|
|
91
100
|
this.listReorderable = false;
|
|
101
|
+
/** Tooltip del valor heredado: co-tooltip lee `disabled` en el mouseenter
|
|
102
|
+
* (scheduleShow), así que el truncado se mide ANTES del hover — al montar /
|
|
103
|
+
* redimensionar el span (RO propio: el de los chips hace disconnect() por
|
|
104
|
+
* render) y al cambiar el texto — nunca en el hover mismo. */
|
|
105
|
+
this.inheritedTruncated = false;
|
|
92
106
|
this.isOpen = false;
|
|
93
107
|
/** How many trailing chips don't fit the trigger width (responsive mode). */
|
|
94
108
|
this.overflowCount = 0;
|
|
95
109
|
this.lastChipsKey = '\x00';
|
|
96
110
|
this.pendingFocus = false;
|
|
111
|
+
/** El host proyecta su PROPIO panel (`<div slot="panel">`: galería, grid…)
|
|
112
|
+
* en lugar de la co-option-list. Se detecta al ABRIR — los hijos light-DOM
|
|
113
|
+
* ya existen y el panel se monta on-demand — y el host cierra/selecciona
|
|
114
|
+
* vía los métodos `selectOption`/`closePanel`. El footer se conserva. */
|
|
115
|
+
this.hasPanelSlot = false;
|
|
97
116
|
// ── Popover event handlers ─────────────────────────────────
|
|
98
117
|
this.handlePopoverOpen = () => {
|
|
99
118
|
this.isOpen = true;
|
|
@@ -101,6 +120,28 @@ export class CoRefField {
|
|
|
101
120
|
this.handlePopoverClose = () => {
|
|
102
121
|
this.isOpen = false;
|
|
103
122
|
};
|
|
123
|
+
this.measureInherited = () => {
|
|
124
|
+
const el = this.inheritedEl;
|
|
125
|
+
const truncated = el ? el.scrollWidth > el.clientWidth + 1 : false;
|
|
126
|
+
if (truncated !== this.inheritedTruncated)
|
|
127
|
+
this.inheritedTruncated = truncated;
|
|
128
|
+
};
|
|
129
|
+
// Stencil llama el ref con null al desmontar (nullifyVNodeRefs): observar /
|
|
130
|
+
// des-observar en el mismo lugar. observe() dispara una notificación inicial
|
|
131
|
+
// → primera medición sin hover previo.
|
|
132
|
+
this.setInheritedEl = (el) => {
|
|
133
|
+
var _a, _b;
|
|
134
|
+
const next = el || undefined;
|
|
135
|
+
if (next === this.inheritedEl)
|
|
136
|
+
return;
|
|
137
|
+
if (this.inheritedEl)
|
|
138
|
+
(_a = this.inheritedResizeObserver) === null || _a === void 0 ? void 0 : _a.unobserve(this.inheritedEl);
|
|
139
|
+
this.inheritedEl = next;
|
|
140
|
+
if (next)
|
|
141
|
+
(_b = this.inheritedResizeObserver) === null || _b === void 0 ? void 0 : _b.observe(next);
|
|
142
|
+
else if (this.inheritedTruncated)
|
|
143
|
+
this.inheritedTruncated = false;
|
|
144
|
+
};
|
|
104
145
|
this.handleTriggerClick = (e) => {
|
|
105
146
|
if (this.disabled)
|
|
106
147
|
e.stopPropagation();
|
|
@@ -259,6 +300,11 @@ export class CoRefField {
|
|
|
259
300
|
// Responsive chips: refit on any trigger width change (same pattern as
|
|
260
301
|
// co-combobox).
|
|
261
302
|
this.resizeObserver = new ResizeObserver(() => this.calcOverflow());
|
|
303
|
+
this.inheritedResizeObserver = new ResizeObserver(() => this.measureInherited());
|
|
304
|
+
// Reconexión del host: el observer es nuevo pero el span ya está montado y
|
|
305
|
+
// el ref no vuelve a llamarse (mismo elemento) → re-observar acá.
|
|
306
|
+
if (this.inheritedEl)
|
|
307
|
+
this.inheritedResizeObserver.observe(this.inheritedEl);
|
|
262
308
|
}
|
|
263
309
|
componentDidRender() {
|
|
264
310
|
var _a, _b, _c, _d;
|
|
@@ -287,8 +333,9 @@ export class CoRefField {
|
|
|
287
333
|
}
|
|
288
334
|
}
|
|
289
335
|
disconnectedCallback() {
|
|
290
|
-
var _a;
|
|
336
|
+
var _a, _b;
|
|
291
337
|
(_a = this.resizeObserver) === null || _a === void 0 ? void 0 : _a.disconnect();
|
|
338
|
+
(_b = this.inheritedResizeObserver) === null || _b === void 0 ? void 0 : _b.disconnect();
|
|
292
339
|
}
|
|
293
340
|
/**
|
|
294
341
|
* Counts how many trailing chips overflow the single-line chips wrapper
|
|
@@ -324,6 +371,7 @@ export class CoRefField {
|
|
|
324
371
|
// ── Watchers ───────────────────────────────────────────────
|
|
325
372
|
onOpenChange(isOpen) {
|
|
326
373
|
if (isOpen) {
|
|
374
|
+
this.hasPanelSlot = !!this.el.querySelector(':scope > [slot="panel"]');
|
|
327
375
|
this.coOpen.emit();
|
|
328
376
|
// The panel is mounted on-demand: co-option-list takes its selected-first
|
|
329
377
|
// snapshot in componentWillLoad on every open; we only need to focus the
|
|
@@ -338,6 +386,12 @@ export class CoRefField {
|
|
|
338
386
|
this.restoreTriggerFocus();
|
|
339
387
|
}
|
|
340
388
|
}
|
|
389
|
+
// ── Valor heredado: medición del truncado (drives co-tooltip `disabled`) ──
|
|
390
|
+
onInheritedLabelChange() {
|
|
391
|
+
// El span no cambia de caja al cambiar el texto (overflow:hidden) → el RO
|
|
392
|
+
// no dispara: medir tras el render.
|
|
393
|
+
requestAnimationFrame(this.measureInherited);
|
|
394
|
+
}
|
|
341
395
|
/** Devuelve el foco al trigger al cerrar el panel (Escape, selección),
|
|
342
396
|
* salvo que el cierre venga de un click-outside que ya movió el foco a
|
|
343
397
|
* otro elemento — en ese caso no robarlo. */
|
|
@@ -348,6 +402,25 @@ export class CoRefField {
|
|
|
348
402
|
(_a = this.triggerEl) === null || _a === void 0 ? void 0 : _a.focus();
|
|
349
403
|
}
|
|
350
404
|
}
|
|
405
|
+
/** Selección desde un panel proyectado (slot `panel`): mismo contrato que un
|
|
406
|
+
* click en la co-option-list — actualiza `value`, emite `coChange` con
|
|
407
|
+
* `{ value, item }` y cierra en single. */
|
|
408
|
+
async selectOption(option) {
|
|
409
|
+
this.handleOptionClick(option);
|
|
410
|
+
}
|
|
411
|
+
/** Cierra el panel (Escape/Enter manejados por un panel proyectado). */
|
|
412
|
+
async closePanel() {
|
|
413
|
+
this.isOpen = false;
|
|
414
|
+
}
|
|
415
|
+
/** Abre el panel. Espejo de `closePanel` para un panel proyectado que se
|
|
416
|
+
* cierra a sí mismo (p.ej. para mostrar un modal — un click dentro de un
|
|
417
|
+
* co-modal cuenta como click-outside del popover) y quiere volver a abrirse
|
|
418
|
+
* después. No-op si está disabled, igual que el trigger. */
|
|
419
|
+
async openPanel() {
|
|
420
|
+
if (this.disabled)
|
|
421
|
+
return;
|
|
422
|
+
this.isOpen = true;
|
|
423
|
+
}
|
|
351
424
|
// ── Render helpers ─────────────────────────────────────────
|
|
352
425
|
renderTrigger() {
|
|
353
426
|
const selected = this.effectiveDisplayItems;
|
|
@@ -359,7 +432,7 @@ export class CoRefField {
|
|
|
359
432
|
[`co-ref-field--${this.normalizedSize}`]: true,
|
|
360
433
|
[`co-ref-field--${this.status}`]: this.status !== 'default',
|
|
361
434
|
'co-ref-field--flat': this.variant === 'flat',
|
|
362
|
-
}, role: "combobox", "aria-expanded": this.isOpen ? 'true' : 'false', "aria-haspopup": "listbox", "aria-label": this.label || undefined, "aria-disabled": this.disabled ? 'true' : undefined, "aria-controls": this.isOpen ? CoRefField.LIST_ID : undefined, tabIndex: this.disabled ? -1 : 0, ref: (el) => (this.triggerEl = el), onClick: this.handleTriggerClick, onKeyDown: this.handleTriggerKeyDown }, this.iconLeft && (h("span", { class: "co-ref-field__icon" }, h("co-icon", { name: this.iconLeft, size: 16 }))), h("div", { class: "co-ref-field__value" }, !hasValue && h("span", { class: "co-ref-field__placeholder", part: "trigger-placeholder" }, this.placeholder), hasValue && !this.multiple && this.renderSingleValue(selected[0]), hasValue && this.multiple && this.renderMultipleValue(selected)), hasValue && this.triggerBadgeIcon && (h("span", { class: "co-ref-field__trigger-badge", part: "trigger-badge", role: "img", title: this.triggerBadgeLabel || undefined, "aria-label": this.triggerBadgeLabel || undefined }, h("co-icon", { name: this.triggerBadgeIcon, size: 11, weight: "fill" }))), hasValue && !this.multiple && this.editable && !this.disabled && (h("button", { class: "co-ref-field__edit", part: "trigger-edit", tabIndex: -1, onClick: this.handleEditClick, type: "button", title: this.editLabel || undefined, "aria-label": this.editLabel || undefined }, h("co-icon", { name: "pencil-simple", size: 14 }))), hasValue && this.clearable && !this.disabled && (h("button", { class: "co-ref-field__clear", part: "trigger-clear", tabIndex: -1, onClick: this.handleClear, type: "button" }, h("co-icon", { name: "x", size: 14 }))), h("span", { class: "co-ref-field__caret", part: "trigger-chevron" }, h("co-icon", { name: "caret-up-down", size: 16 }))));
|
|
435
|
+
}, role: "combobox", "aria-expanded": this.isOpen ? 'true' : 'false', "aria-haspopup": "listbox", "aria-label": this.label || undefined, "aria-disabled": this.disabled ? 'true' : undefined, "aria-controls": this.isOpen ? CoRefField.LIST_ID : undefined, tabIndex: this.disabled ? -1 : 0, ref: (el) => (this.triggerEl = el), onClick: this.handleTriggerClick, onKeyDown: this.handleTriggerKeyDown }, this.iconLeft && (h("span", { class: "co-ref-field__icon" }, h("co-icon", { name: this.iconLeft, size: 16 }))), h("div", { class: "co-ref-field__value" }, !hasValue && this.inheritedLabel && (h("co-tooltip", { block: true, class: "co-ref-field__inherited-tip", content: this.inheritedLabel, placement: "top", disabled: !this.inheritedTruncated }, h("span", { class: "co-ref-field__inherited", part: "trigger-inherited", ref: this.setInheritedEl }, this.inheritedLabel))), !hasValue && !this.inheritedLabel && (h("span", { class: "co-ref-field__placeholder", part: "trigger-placeholder" }, this.placeholder)), hasValue && !this.multiple && this.renderSingleValue(selected[0]), hasValue && this.multiple && this.renderMultipleValue(selected)), !hasValue && this.inheritedLabel && this.inheritedBadgeLabel && (h("span", { class: "co-ref-field__inherited-badge", part: "trigger-inherited-badge" }, this.inheritedBadgeLabel)), hasValue && this.triggerBadgeIcon && (h("span", { class: "co-ref-field__trigger-badge", part: "trigger-badge", role: "img", title: this.triggerBadgeLabel || undefined, "aria-label": this.triggerBadgeLabel || undefined }, h("co-icon", { name: this.triggerBadgeIcon, size: 11, weight: "fill" }))), hasValue && !this.multiple && this.editable && !this.disabled && (h("button", { class: "co-ref-field__edit", part: "trigger-edit", tabIndex: -1, onClick: this.handleEditClick, type: "button", title: this.editLabel || undefined, "aria-label": this.editLabel || undefined }, h("co-icon", { name: "pencil-simple", size: 14 }))), hasValue && this.clearable && !this.disabled && (h("button", { class: "co-ref-field__clear", part: "trigger-clear", tabIndex: -1, onClick: this.handleClear, type: "button" }, h("co-icon", { name: "x", size: 14 }))), h("span", { class: "co-ref-field__caret", part: "trigger-chevron" }, h("co-icon", { name: "caret-up-down", size: 16 }))));
|
|
363
436
|
}
|
|
364
437
|
/**
|
|
365
438
|
* Leading visual for a selected value / chip. Prefers a real avatar (image
|
|
@@ -408,16 +481,31 @@ export class CoRefField {
|
|
|
408
481
|
}, style: fill ? { backgroundColor: item.color } : undefined, onRemove: (e) => this.handleRemoveChip(item._id, e) }, item.image || item.avatar ? (this.renderItemAvatar(item)) : item.color && !fill ? (h("span", { class: "co-ref-field__chip-dot", style: { backgroundColor: item.color } })) : null));
|
|
409
482
|
})), overflow > 0 && h("span", { class: "co-ref-field__chip-overflow" }, "+", overflow)));
|
|
410
483
|
}
|
|
484
|
+
/** Botones del footer. `slotted`: dentro de la co-option-list van por su
|
|
485
|
+
* slot `footer`; en el panel proyectado se pintan directo bajo el slot. */
|
|
486
|
+
renderFooter(slotted) {
|
|
487
|
+
if (!this.showFooter)
|
|
488
|
+
return null;
|
|
489
|
+
return (h("div", { class: "co-ref-field__footer", slot: slotted ? 'footer' : undefined }, this.footerSecondaryLabel && (h("button", { class: "co-ref-field__footer-btn co-ref-field__footer-btn--secondary", type: "button", onClick: this.handleFooterSecondary }, h("co-icon", { name: "plus", size: 16 }), h("span", null, this.footerSecondaryLabel))), h("button", { class: "co-ref-field__footer-btn co-ref-field__footer-btn--primary", type: "button", onClick: this.handleFooterPrimary }, h("co-icon", { name: "check", size: 16 }), h("span", null, this.footerPrimaryLabel))));
|
|
490
|
+
}
|
|
411
491
|
renderPanel() {
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
492
|
+
const panelClass = {
|
|
493
|
+
'co-ref-field__panel': true,
|
|
494
|
+
'co-ref-field__panel--dark': this.panelTheme === 'dark',
|
|
495
|
+
'co-ref-field__panel--light': this.panelTheme === 'light',
|
|
496
|
+
};
|
|
497
|
+
const panelStyle = this.panelWidth ? { width: this.panelWidth } : undefined;
|
|
498
|
+
if (this.hasPanelSlot) {
|
|
499
|
+
// Panel del host: la búsqueda, las opciones y su a11y son suyas; acá
|
|
500
|
+
// quedan el chrome del panel (radius/tema/ancho), el id que el trigger
|
|
501
|
+
// referencia por aria-controls y el footer compartido.
|
|
502
|
+
return (h("div", { class: Object.assign(Object.assign({}, panelClass), { 'co-ref-field__panel--custom': true }), id: CoRefField.LIST_ID, style: panelStyle }, h("slot", { name: "panel" }), this.renderFooter(false)));
|
|
503
|
+
}
|
|
504
|
+
return (h("div", { class: panelClass, style: panelStyle }, h("co-option-list", { id: CoRefField.LIST_ID, ref: (el) => (this.optionListEl = el), items: typeof this.options === 'string' ? this.options : JSON.stringify(this.options), value: this.value, selectedItems: typeof this.selectedDisplay === 'string' ? this.selectedDisplay : JSON.stringify(this.selectedDisplay), multiple: this.multiple, selectedFirst: this.multiple, reorderable: this.multiple, pinnable: this.pinnable, listReorderable: this.listReorderable, selectedAffordance: "deselect", searchable: this.searchable, searchPlaceholder: this.searchPlaceholder, searchDebounce: this.searchDebounce, loading: this.loading, total: this.total, emptyMessage: this.emptyMessage, avatarShape: this.avatarShape, onCoSearch: (e) => this.coSearch.emit(e.detail), onCoChange: (e) => this.handleListChange(e.detail), onCoReorder: (e) => this.handleReorder(e.detail), onCoPinToggle: (e) => this.coPinToggle.emit(e.detail), onCoListReorder: (e) => this.coListReorder.emit(e.detail), onCoLoadMore: () => this.coLoadMore.emit() }, h("slot", { name: "panel-footer", slot: "footer" }), this.renderFooter(true))));
|
|
417
505
|
}
|
|
418
506
|
// ── Main render ────────────────────────────────────────────
|
|
419
507
|
render() {
|
|
420
|
-
return (h("div", { key: '
|
|
508
|
+
return (h("div", { key: 'fa7de667cc9002d1a4a042b0d200524cbcb89b78', class: "co-ref-field" }, (this.label || this.secondaryLabel) && (h("div", { key: 'a6ddd5b71364e4f5bdf63b04faa09bfc0a32f6bc', class: "co-ref-field__labels" }, this.label && (h("label", { key: '766f803c8be77f72e52e4d3cdd7b6d7a363a146a', class: "co-ref-field__label" }, this.labelIcon && (h("co-icon", { key: 'a8b6c7f189af4b9f37de8c3cc96cb489fd9183e4', class: "co-ref-field__label-icon", name: this.labelIcon, size: 16 })), this.label, h(RequiredMark, { key: '643edcb040ef9a91040e8d52f628bc0af06c36ba', required: this.required }))), this.secondaryLabel && (h("span", { key: '7a107c578e003760423acc6d450f2a42a0868375', class: "co-ref-field__secondary-label" }, this.secondaryLabel)))), h("co-popover", { key: '9938ca629c5927156ea137adfefd1d927104312b', open: this.isOpen, placement: "bottom-start", matchWidth: !this.panelWidth, offset: 4, onCoOpen: this.handlePopoverOpen, onCoClose: this.handlePopoverClose }, h("div", { key: '7618ea5fb13e4944596fd728cf934b5c28bd29ab', slot: "trigger" }, this.renderTrigger()), this.isOpen && this.renderPanel()), this.helperText && (h("div", { key: '1dd9fc7659e8f8791bb4b785407b0e89b32107c8', class: `co-ref-field__helper co-ref-field__helper--${this.status}` }, this.status !== 'default' && (h("co-icon", { key: '399674b95ebcc91581f1f1cea54451f8ee33d9da', name: this.status === 'error' ? 'warning-circle' : this.status === 'success' ? 'check-circle' : 'info', size: 14 })), h("span", { key: '640adc4e5cd4cd742a171cac1319b75489cb7ef8' }, this.helperText)))));
|
|
421
509
|
}
|
|
422
510
|
static get is() { return "co-ref-field"; }
|
|
423
511
|
static get encapsulation() { return "shadow"; }
|
|
@@ -1088,6 +1176,46 @@ export class CoRefField {
|
|
|
1088
1176
|
"attribute": "trigger-badge-label",
|
|
1089
1177
|
"defaultValue": "''"
|
|
1090
1178
|
},
|
|
1179
|
+
"inheritedLabel": {
|
|
1180
|
+
"type": "string",
|
|
1181
|
+
"mutable": false,
|
|
1182
|
+
"complexType": {
|
|
1183
|
+
"original": "string",
|
|
1184
|
+
"resolved": "string",
|
|
1185
|
+
"references": {}
|
|
1186
|
+
},
|
|
1187
|
+
"required": false,
|
|
1188
|
+
"optional": false,
|
|
1189
|
+
"docs": {
|
|
1190
|
+
"tags": [],
|
|
1191
|
+
"text": "Valor HEREDADO: texto que se pinta cuando NO hay valor, en lugar del\nplaceholder, para mostrar lo que aplica por defecto (p. ej. el layout\npredeterminado del workspace en Deal.proposal.template.layout). No es un\nvalor: `value` sigue vac\u00EDo y no hay \u00D7. Vac\u00EDo = placeholder de siempre."
|
|
1192
|
+
},
|
|
1193
|
+
"getter": false,
|
|
1194
|
+
"setter": false,
|
|
1195
|
+
"reflect": false,
|
|
1196
|
+
"attribute": "inherited-label",
|
|
1197
|
+
"defaultValue": "''"
|
|
1198
|
+
},
|
|
1199
|
+
"inheritedBadgeLabel": {
|
|
1200
|
+
"type": "string",
|
|
1201
|
+
"mutable": false,
|
|
1202
|
+
"complexType": {
|
|
1203
|
+
"original": "string",
|
|
1204
|
+
"resolved": "string",
|
|
1205
|
+
"references": {}
|
|
1206
|
+
},
|
|
1207
|
+
"required": false,
|
|
1208
|
+
"optional": false,
|
|
1209
|
+
"docs": {
|
|
1210
|
+
"tags": [],
|
|
1211
|
+
"text": "Chip outlined junto al valor heredado (p. ej. 'Predeterminado'). Solo con inheritedLabel."
|
|
1212
|
+
},
|
|
1213
|
+
"getter": false,
|
|
1214
|
+
"setter": false,
|
|
1215
|
+
"reflect": false,
|
|
1216
|
+
"attribute": "inherited-badge-label",
|
|
1217
|
+
"defaultValue": "''"
|
|
1218
|
+
},
|
|
1091
1219
|
"panelWidth": {
|
|
1092
1220
|
"type": "string",
|
|
1093
1221
|
"mutable": false,
|
|
@@ -1171,6 +1299,7 @@ export class CoRefField {
|
|
|
1171
1299
|
}
|
|
1172
1300
|
static get states() {
|
|
1173
1301
|
return {
|
|
1302
|
+
"inheritedTruncated": {},
|
|
1174
1303
|
"isOpen": {},
|
|
1175
1304
|
"overflowCount": {}
|
|
1176
1305
|
};
|
|
@@ -1192,7 +1321,7 @@ export class CoRefField {
|
|
|
1192
1321
|
"references": {
|
|
1193
1322
|
"RefFieldOption": {
|
|
1194
1323
|
"location": "local",
|
|
1195
|
-
"path": "/Users/agox/
|
|
1324
|
+
"path": "/Users/agox/worktrees/cobalt-release/packages/core/src/components/co-ref-field/co-ref-field.tsx",
|
|
1196
1325
|
"id": "src/components/co-ref-field/co-ref-field.tsx::RefFieldOption"
|
|
1197
1326
|
}
|
|
1198
1327
|
}
|
|
@@ -1333,7 +1462,7 @@ export class CoRefField {
|
|
|
1333
1462
|
"references": {
|
|
1334
1463
|
"RefFieldOption": {
|
|
1335
1464
|
"location": "local",
|
|
1336
|
-
"path": "/Users/agox/
|
|
1465
|
+
"path": "/Users/agox/worktrees/cobalt-release/packages/core/src/components/co-ref-field/co-ref-field.tsx",
|
|
1337
1466
|
"id": "src/components/co-ref-field/co-ref-field.tsx::RefFieldOption"
|
|
1338
1467
|
}
|
|
1339
1468
|
}
|
|
@@ -1354,7 +1483,7 @@ export class CoRefField {
|
|
|
1354
1483
|
"references": {
|
|
1355
1484
|
"RefFieldOption": {
|
|
1356
1485
|
"location": "local",
|
|
1357
|
-
"path": "/Users/agox/
|
|
1486
|
+
"path": "/Users/agox/worktrees/cobalt-release/packages/core/src/components/co-ref-field/co-ref-field.tsx",
|
|
1358
1487
|
"id": "src/components/co-ref-field/co-ref-field.tsx::RefFieldOption"
|
|
1359
1488
|
}
|
|
1360
1489
|
}
|
|
@@ -1376,11 +1505,78 @@ export class CoRefField {
|
|
|
1376
1505
|
}
|
|
1377
1506
|
}];
|
|
1378
1507
|
}
|
|
1508
|
+
static get methods() {
|
|
1509
|
+
return {
|
|
1510
|
+
"selectOption": {
|
|
1511
|
+
"complexType": {
|
|
1512
|
+
"signature": "(option: RefFieldOption) => Promise<void>",
|
|
1513
|
+
"parameters": [{
|
|
1514
|
+
"name": "option",
|
|
1515
|
+
"type": "RefFieldOption",
|
|
1516
|
+
"docs": ""
|
|
1517
|
+
}],
|
|
1518
|
+
"references": {
|
|
1519
|
+
"Promise": {
|
|
1520
|
+
"location": "global",
|
|
1521
|
+
"id": "global::Promise"
|
|
1522
|
+
},
|
|
1523
|
+
"RefFieldOption": {
|
|
1524
|
+
"location": "local",
|
|
1525
|
+
"path": "/Users/agox/worktrees/cobalt-release/packages/core/src/components/co-ref-field/co-ref-field.tsx",
|
|
1526
|
+
"id": "src/components/co-ref-field/co-ref-field.tsx::RefFieldOption"
|
|
1527
|
+
}
|
|
1528
|
+
},
|
|
1529
|
+
"return": "Promise<void>"
|
|
1530
|
+
},
|
|
1531
|
+
"docs": {
|
|
1532
|
+
"text": "Selecci\u00F3n desde un panel proyectado (slot `panel`): mismo contrato que un\nclick en la co-option-list \u2014 actualiza `value`, emite `coChange` con\n`{ value, item }` y cierra en single.",
|
|
1533
|
+
"tags": []
|
|
1534
|
+
}
|
|
1535
|
+
},
|
|
1536
|
+
"closePanel": {
|
|
1537
|
+
"complexType": {
|
|
1538
|
+
"signature": "() => Promise<void>",
|
|
1539
|
+
"parameters": [],
|
|
1540
|
+
"references": {
|
|
1541
|
+
"Promise": {
|
|
1542
|
+
"location": "global",
|
|
1543
|
+
"id": "global::Promise"
|
|
1544
|
+
}
|
|
1545
|
+
},
|
|
1546
|
+
"return": "Promise<void>"
|
|
1547
|
+
},
|
|
1548
|
+
"docs": {
|
|
1549
|
+
"text": "Cierra el panel (Escape/Enter manejados por un panel proyectado).",
|
|
1550
|
+
"tags": []
|
|
1551
|
+
}
|
|
1552
|
+
},
|
|
1553
|
+
"openPanel": {
|
|
1554
|
+
"complexType": {
|
|
1555
|
+
"signature": "() => Promise<void>",
|
|
1556
|
+
"parameters": [],
|
|
1557
|
+
"references": {
|
|
1558
|
+
"Promise": {
|
|
1559
|
+
"location": "global",
|
|
1560
|
+
"id": "global::Promise"
|
|
1561
|
+
}
|
|
1562
|
+
},
|
|
1563
|
+
"return": "Promise<void>"
|
|
1564
|
+
},
|
|
1565
|
+
"docs": {
|
|
1566
|
+
"text": "Abre el panel. Espejo de `closePanel` para un panel proyectado que se\ncierra a s\u00ED mismo (p.ej. para mostrar un modal \u2014 un click dentro de un\nco-modal cuenta como click-outside del popover) y quiere volver a abrirse\ndespu\u00E9s. No-op si est\u00E1 disabled, igual que el trigger.",
|
|
1567
|
+
"tags": []
|
|
1568
|
+
}
|
|
1569
|
+
}
|
|
1570
|
+
};
|
|
1571
|
+
}
|
|
1379
1572
|
static get elementRef() { return "el"; }
|
|
1380
1573
|
static get watchers() {
|
|
1381
1574
|
return [{
|
|
1382
1575
|
"propName": "isOpen",
|
|
1383
1576
|
"methodName": "onOpenChange"
|
|
1577
|
+
}, {
|
|
1578
|
+
"propName": "inheritedLabel",
|
|
1579
|
+
"methodName": "onInheritedLabelChange"
|
|
1384
1580
|
}];
|
|
1385
1581
|
}
|
|
1386
1582
|
}
|
|
@@ -2034,7 +2034,7 @@ export class CoRichTextEditor {
|
|
|
2034
2034
|
render() {
|
|
2035
2035
|
const showToolbar = this.resolvedToolbar !== 'none' && !this.readonly && !this.disabled;
|
|
2036
2036
|
const showCount = this.showCharacterCount || this.maxLength != null;
|
|
2037
|
-
return (h("div", { key: '
|
|
2037
|
+
return (h("div", { key: '3acc844eb53d8b3568d9f72e053363b674e9ba87', class: {
|
|
2038
2038
|
'co-rich-text-editor': true,
|
|
2039
2039
|
'co-rich-text-editor--focused': this.hasFocus,
|
|
2040
2040
|
'co-rich-text-editor--disabled': this.disabled,
|
|
@@ -2042,10 +2042,10 @@ export class CoRichTextEditor {
|
|
|
2042
2042
|
'co-rich-text-editor--loading': !this.ready,
|
|
2043
2043
|
[`co-rich-text-editor--${this.status}`]: this.status !== 'default',
|
|
2044
2044
|
'co-rich-text-editor--flat': this.variant === 'flat',
|
|
2045
|
-
}, part: "wrapper" }, (this.label || this.secondaryLabel) && (h("div", { key: '
|
|
2045
|
+
}, part: "wrapper" }, (this.label || this.secondaryLabel) && (h("div", { key: '53b6f47e19e422ab1c7b3e2d452f320495199c33', class: "co-rich-text-editor__labels" }, this.label && h("label", { key: 'c4c7eb0f49cbffc40cbd6cfd2a28848201623be9', class: "co-rich-text-editor__label", part: "label" }, this.label), this.secondaryLabel && (h("span", { key: '13663ac237f80b637ebf8df841ba52c4aa73a0f4', class: "co-rich-text-editor__secondary-label" }, this.secondaryLabel)))), h("div", { key: 'deb51dfabddb6ca08dc849f17f7850d635bee9e0', class: "co-rich-text-editor__frame" }, showToolbar && (h("co-rich-text-toolbar", { key: 'f62c2cf76ce791f0648bde14c30300c40417a22b', class: "co-rich-text-editor__toolbar", part: "toolbar", variant: this.resolvedToolbar, disabled: this.disabled || this.readonly, locale: this.locale, attachmentsEnabled: this.attachmentsEnabled, attachmentAccept: this.attachmentAccept, onCoAttachmentsSelected: (e) => {
|
|
2046
2046
|
e.stopPropagation();
|
|
2047
2047
|
this.coAttachmentsSelected.emit(e.detail);
|
|
2048
|
-
}, ref: (el) => (this.toolbarEl = el) })), h("div", { key: '
|
|
2048
|
+
}, ref: (el) => (this.toolbarEl = el) })), h("div", { key: 'af3c512a9ec4ed3dc62d83b8acbd13132c84f349', class: "co-rich-text-editor__box" }, h("div", { key: '3cacb60bf24487d631ec3e7153313b3ed940ea8e', class: "co-rte-content", part: "content", role: "textbox", "aria-multiline": "true", "aria-label": this.label, "aria-required": this.required ? 'true' : undefined, "aria-invalid": this.status === 'error' ? 'true' : undefined, ref: (el) => (this.contentEl = el) }))), h("div", { key: 'ac6511ee617587f29a55adeb5ef9840be559adcd', class: "co-rich-text-editor__footer" }, this.helperText && (h("div", { key: '8ae2c198a948e553d22111bad15d5119c7ee090f', class: `co-rich-text-editor__helper co-rich-text-editor__helper--${this.status}`, part: "helper" }, h("co-icon", { key: 'a764d0daeeaeee64fae43c2358cdad9ecfe89b13', name: this.helperIcon, size: 14 }), h("span", { key: 'c1efcf1a97de016fa78a408306696cc0f4b29f29' }, this.helperText))), showCount && (h("span", { key: 'c68f01b407e6b2aa17582b58244b147825729138', class: "co-rich-text-editor__count", ref: (el) => (this.charCountEl = el) }, this.charCount, this.maxLength != null ? ` / ${this.maxLength}` : '')))));
|
|
2049
2049
|
}
|
|
2050
2050
|
static get is() { return "co-rich-text-editor"; }
|
|
2051
2051
|
static get originalStyleUrls() {
|
|
@@ -13,11 +13,11 @@ export class CoRow {
|
|
|
13
13
|
this.size = 'sm';
|
|
14
14
|
}
|
|
15
15
|
render() {
|
|
16
|
-
return (h("div", { key: '
|
|
16
|
+
return (h("div", { key: 'df05ce9c0da83cd61ce3a42e4a578ea4d038e12c', class: {
|
|
17
17
|
'co-row': true,
|
|
18
18
|
[`co-row--${this.position}`]: true,
|
|
19
19
|
[`co-row--${this.size}`]: true,
|
|
20
|
-
}, part: "row" }, h("div", { key: '
|
|
20
|
+
}, part: "row" }, h("div", { key: 'fcd7514bd6071f16f8b92ace2651bf33b74a402e', class: "co-row__prefix" }, h("slot", { key: '47254fffd8803454f9d8f0cccfb6e80bb7058b38', name: "prefix" })), h("div", { key: '43aaab6683919b7e9e47c0a67203edffa3db81df', class: "co-row__content" }, h("slot", { key: '4fb7a8ea03f79313176ca8c5ae23f878eace9027' })), h("div", { key: '3c7bcd64ccf417e95620cec6ae87d7d9d1697bed', class: "co-row__suffix" }, h("slot", { key: 'af2e72debbcc68919ef3e28d03ff18cf747ccc43', name: "suffix" }))));
|
|
21
21
|
}
|
|
22
22
|
static get is() { return "co-row"; }
|
|
23
23
|
static get encapsulation() { return "shadow"; }
|
|
@@ -154,7 +154,7 @@ export class CoSegmentedBar {
|
|
|
154
154
|
"references": {
|
|
155
155
|
"CoSegment": {
|
|
156
156
|
"location": "local",
|
|
157
|
-
"path": "/Users/agox/
|
|
157
|
+
"path": "/Users/agox/worktrees/cobalt-release/packages/core/src/components/co-segmented-bar/co-segmented-bar.tsx",
|
|
158
158
|
"id": "src/components/co-segmented-bar/co-segmented-bar.tsx::CoSegment"
|
|
159
159
|
}
|
|
160
160
|
}
|