@prolibu-suite/cobalt-core 0.11.7 → 0.11.9

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.
Files changed (99) hide show
  1. package/custom-elements.json +31 -31
  2. package/dist/cjs/co-calendar_3.cjs.entry.js +2 -1
  3. package/dist/cjs/co-kbd_2.cjs.entry.js +5 -4
  4. package/dist/cjs/co-lightbox.cjs.entry.js +7 -6
  5. package/dist/cjs/co-overlay.cjs.entry.js +4 -3
  6. package/dist/cjs/co-popover.cjs.entry.js +5 -4
  7. package/dist/cjs/co-sidebar-nav.cjs.entry.js +29 -8
  8. package/dist/cjs/index-bHoidDwv.js +4 -4
  9. package/dist/cjs/popoverApi-D1ChCCdO.js +27 -0
  10. package/dist/cobalt/cobalt.esm.js +1 -1
  11. package/dist/cobalt/p-2832ab99.entry.js +1 -0
  12. package/dist/cobalt/p-299c2425.entry.js +1 -0
  13. package/dist/cobalt/p-438cc876.entry.js +1 -0
  14. package/dist/cobalt/p-Dp1JT0dm.js +1 -0
  15. package/dist/cobalt/p-b723aa47.entry.js +1 -0
  16. package/dist/cobalt/p-eab59be5.entry.js +1 -0
  17. package/dist/cobalt/p-f562bd96.entry.js +1 -0
  18. package/dist/collection/components/co-autocomplete/co-autocomplete.js +1 -1
  19. package/dist/collection/components/co-avatar-group/co-avatar-group.js +1 -1
  20. package/dist/collection/components/co-checkbox-group/co-checkbox-group.js +1 -1
  21. package/dist/collection/components/co-color-area/co-color-area.js +2 -2
  22. package/dist/collection/components/co-color-slider/co-color-slider.js +1 -1
  23. package/dist/collection/components/co-combobox/co-combobox.js +1 -1
  24. package/dist/collection/components/co-command-search/co-command-search.js +1 -1
  25. package/dist/collection/components/co-data-table/co-data-table.js +1 -1
  26. package/dist/collection/components/co-date-range-picker/co-date-range-picker.js +2 -2
  27. package/dist/collection/components/co-document-editor/co-document-editor.js +5 -5
  28. package/dist/collection/components/co-drawer/co-drawer.js +2 -1
  29. package/dist/collection/components/co-lightbox/co-lightbox.js +7 -6
  30. package/dist/collection/components/co-overlay/co-overlay.js +4 -3
  31. package/dist/collection/components/co-popover/co-popover.js +6 -5
  32. package/dist/collection/components/co-radio-group/co-radio-group.js +1 -1
  33. package/dist/collection/components/co-ref-field/co-ref-field.js +4 -4
  34. package/dist/collection/components/co-segmented-bar/co-segmented-bar.js +1 -1
  35. package/dist/collection/components/co-select/co-select.js +1 -1
  36. package/dist/collection/components/co-sidebar-nav/co-sidebar-nav.js +6 -190
  37. package/dist/collection/components/co-sidebar-nav/sidebar-icon-map.js +205 -0
  38. package/dist/collection/components/co-toast/co-toast.js +2 -2
  39. package/dist/collection/components/co-tooltip/co-tooltip.js +5 -4
  40. package/dist/collection/components/co-transfer-list/co-transfer-list.js +1 -1
  41. package/dist/collection/components/co-tree-item/co-tree-item.js +2 -2
  42. package/dist/collection/utils/popoverApi.js +23 -0
  43. package/dist/components/co-autocomplete.js +1 -1
  44. package/dist/components/co-avatar-group.js +1 -1
  45. package/dist/components/co-avatar.js +1 -1
  46. package/dist/components/co-color-picker.js +1 -1
  47. package/dist/components/co-combobox.js +1 -1
  48. package/dist/components/co-command-search.js +1 -1
  49. package/dist/components/co-data-table.js +1 -1
  50. package/dist/components/co-date-picker.js +1 -1
  51. package/dist/components/co-date-range-picker.js +1 -1
  52. package/dist/components/co-date-range.js +1 -1
  53. package/dist/components/co-date-time-picker.js +1 -1
  54. package/dist/components/co-document-editor.js +1 -1
  55. package/dist/components/co-drawer.js +1 -1
  56. package/dist/components/co-file-field.js +1 -1
  57. package/dist/components/co-lightbox.js +1 -1
  58. package/dist/components/co-list-item.js +1 -1
  59. package/dist/components/co-menu-item.js +1 -1
  60. package/dist/components/co-menu.js +1 -1
  61. package/dist/components/co-modal.js +1 -1
  62. package/dist/components/co-option-list.js +1 -1
  63. package/dist/components/co-overlay.js +1 -1
  64. package/dist/components/co-popover.js +1 -1
  65. package/dist/components/co-ref-field.js +1 -1
  66. package/dist/components/co-select.js +1 -1
  67. package/dist/components/co-sidebar-nav.js +1 -1
  68. package/dist/components/co-tooltip.js +1 -1
  69. package/dist/components/{p-_S5htX1i.js → p-BGNXvnDr.js} +1 -1
  70. package/dist/components/p-BMyWdiVO.js +1 -0
  71. package/dist/components/{p-CaFwCFgg.js → p-BRIf9NGv.js} +1 -1
  72. package/dist/components/p-Bd6H9_5D.js +1 -0
  73. package/dist/components/{p-upZqhFKo.js → p-BkyYV32T.js} +1 -1
  74. package/dist/components/p-DHIa14ep.js +1 -0
  75. package/dist/components/p-DRL-a5hO.js +1 -0
  76. package/dist/components/p-Dp1JT0dm.js +1 -0
  77. package/dist/components/p-xA7AfoIW.js +1 -0
  78. package/dist/esm/co-calendar_3.entry.js +2 -1
  79. package/dist/esm/co-kbd_2.entry.js +5 -4
  80. package/dist/esm/co-lightbox.entry.js +7 -6
  81. package/dist/esm/co-overlay.entry.js +4 -3
  82. package/dist/esm/co-popover.entry.js +5 -4
  83. package/dist/esm/co-sidebar-nav.entry.js +29 -8
  84. package/dist/esm/index-DJkaRtbb.js +4 -4
  85. package/dist/esm/popoverApi-Dp1JT0dm.js +25 -0
  86. package/dist/types/components/co-sidebar-nav/sidebar-icon-map.d.ts +6 -0
  87. package/dist/types/utils/popoverApi.d.ts +12 -0
  88. package/package.json +2 -2
  89. package/dist/cobalt/p-60ea3d33.entry.js +0 -1
  90. package/dist/cobalt/p-84256bde.entry.js +0 -1
  91. package/dist/cobalt/p-8c22bf4b.entry.js +0 -1
  92. package/dist/cobalt/p-99781b0b.entry.js +0 -1
  93. package/dist/cobalt/p-b2c49664.entry.js +0 -1
  94. package/dist/cobalt/p-cf675968.entry.js +0 -1
  95. package/dist/components/p-B5F93Ujt.js +0 -1
  96. package/dist/components/p-CMMv2RcH.js +0 -1
  97. package/dist/components/p-CX0bNXK3.js +0 -1
  98. package/dist/components/p-Co0eKIiO.js +0 -1
  99. package/dist/components/p-xtGT3YeI.js +0 -1
@@ -0,0 +1 @@
1
+ import{r as t,c as i,h as n,a as o}from"./p-DJkaRtbb.js";import{a as e}from"./p-Ch1jfwZ2.js";import{i as r}from"./p-Dp1JT0dm.js";const s=["a[href]","area[href]","button:not([disabled])",'input:not([disabled]):not([type="hidden"])',"select:not([disabled])","textarea:not([disabled])","iframe","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])','[tabindex]:not([tabindex="-1"])'].join(",");function a(t){if(t.shadowRoot)return Array.from(t.shadowRoot.children);if("SLOT"===t.tagName){const i=t.assignedElements({flatten:!0});return i.length?i:Array.from(t.children)}return Array.from(t.children)}function c(t){var i,n;if(!(null===(i=t.matches)||void 0===i?void 0:i.call(t,s))||t.hasAttribute("disabled"))return!1;const o=t.getAttribute("tabindex");return!(null!==o&&Number(o)<0||null===t.offsetParent&&0===t.getClientRects().length||!1===(null===(n=t.checkVisibility)||void 0===n?void 0:n.call(t,{visibilityProperty:!0})))}function h(t,i){const n=t=>{return"true"!==(o=t).getAttribute("aria-hidden")&&!o.hasAttribute("inert")&&(!!i(t)||a(t).some(n));var o};a(t).some(n)}function l(t,i){let n=null;return h(t,(t=>!!i(t)&&(n=t,!0))),n}function u(t){const i=[];return h(t,(t=>(c(t)&&i.push(t),!1))),i}function d(t,i){return t.length>0&&t[t.length-1]===i}let f=0,p="";const v=[];let y=0;const b="co-overlay--refront";function m(t){"function"==typeof requestAnimationFrame?requestAnimationFrame(t):t()}const g=class{constructor(n){t(this,n),this.coClose=i(this,"coClose",7),this.coAfterClose=i(this,"coAfterClose",3),this.coAfterOpen=i(this,"coAfterOpen",3),this.open=!1,this.trapFocus=!1,this.closeOnEscape=!1,this.hasLock=!1,this.trapId="co-overlay-trap-"+ ++y,this.trapping=!1,this.pressDownTarget=null,this.pressUpTarget=null,this.handlePointerDown=t=>{var i;this.pressDownTarget=null!==(i=t.composedPath()[0])&&void 0!==i?i:null,this.pressUpTarget=null},this.handlePointerUp=t=>{var i;this.pressUpTarget=null!==(i=t.composedPath()[0])&&void 0!==i?i:null},this.handleClick=t=>{var i;const n=null!==(i=t.composedPath()[0])&&void 0!==i?i:null,o=n===this.overlayEl&&function(t,i,n){return null!==t&&t===i&&i===n}(this.pressDownTarget,this.pressUpTarget,n);this.pressDownTarget=null,this.pressUpTarget=null,o&&this.coClose.emit()},this.handleTransitionEnd=t=>{if(t.target!==this.overlayEl)return;const i=e(t.propertyName,this.open,"opacity");"after-open"===i?this.coAfterOpen.emit():"after-close"===i&&this.coAfterClose.emit()}}onOpenChange(t){t?this.acquireLock():this.releaseLock(),this.syncPopover(),this.syncTrap()}onTrapFocusChange(){this.syncTrap()}componentDidLoad(){this.open&&this.acquireLock(),this.syncPopover(),this.syncTrap()}disconnectedCallback(){this.releaseLock(),this.releaseTrap()}async bringToFront(){const t=this.overlayEl;if(!this.open||!t||"function"!=typeof t.showPopover)return;if(!r(t))return;const i=this.deepActiveElement();t.classList.add(b);try{t.hidePopover(),t.showPopover()}catch(t){}i&&i.isConnected&&this.deepActiveElement()!==i&&i.focus({preventScroll:!0}),m((()=>t.classList.remove(b)))}acquireLock(){this.hasLock||(this.hasLock=!0,"undefined"!=typeof document&&(0===f&&(p=document.body.style.overflow,document.body.style.overflow="hidden"),f++))}releaseLock(){this.hasLock&&(this.hasLock=!1,"undefined"!=typeof document&&0!==f&&(f--,0===f&&(document.body.style.overflow=p)))}syncPopover(){const t=this.overlayEl;if(t&&"function"==typeof t.showPopover)try{const i=r(t);this.open&&!i?t.showPopover():!this.open&&i&&t.hidePopover()}catch(t){}}syncTrap(){this.open&&this.trapFocus?this.engageTrap():this.releaseTrap()}engageTrap(){this.trapping||(this.trapping=!0,v.push(this.trapId),this.captureAndFocus())}releaseTrap(){if(!this.trapping)return;this.trapping=!1;const t=v.indexOf(this.trapId);t>=0&&v.splice(t,1),this.restoreFocus()}captureAndFocus(){this.returnFocusEl=this.deepActiveElement(),m((()=>{var t;if(!this.open||!this.trapping||!d(v,this.trapId))return;const i=function(t){const i=l(t,(t=>t.hasAttribute("autofocus")));if(i){if(c(i))return i;const t=i.shadowRoot?u(i)[0]:void 0;if(t)return t}return l(t,c)}(this.el);i?i.focus():null===(t=this.overlayEl)||void 0===t||t.focus()}))}restoreFocus(){const t=this.returnFocusEl;this.returnFocusEl=null,t&&t.isConnected&&"function"==typeof t.focus&&t.focus({preventScroll:!0})}deepActiveElement(){if("undefined"==typeof document)return null;let t=document.activeElement;for(;t&&t.shadowRoot&&t.shadowRoot.activeElement;)t=t.shadowRoot.activeElement;return t}handleKeydown(t){this.open&&(this.closeOnEscape&&"Escape"===t.key?this.coClose.emit():this.trapping&&"Tab"===t.key&&d(v,this.trapId)&&this.trapTab(t))}trapTab(t){var i;if(t.defaultPrevented)return;const n=u(this.el);if(0===n.length)return t.preventDefault(),void(null===(i=this.overlayEl)||void 0===i||i.focus());const o=n.indexOf(this.deepActiveElement()),e=function(t,i,n){return t<=0?-1:n?i<=0?t-1:i-1:-1===i||i>=t-1?0:i+1}(n.length,o,t.shiftKey);e<0||(t.preventDefault(),n[e].focus())}render(){return n("div",{key:"419d44027ef0e270aa9bddccc83bf3e93e1e78db",class:{"co-overlay":!0,"co-overlay--open":this.open},part:"overlay",popover:"manual",tabindex:this.trapFocus?-1:void 0,ref:t=>this.overlayEl=t,onPointerDown:this.handlePointerDown,onPointerUp:this.handlePointerUp,onClick:this.handleClick,onTransitionEnd:this.handleTransitionEnd},n("slot",{key:"34ffc7586b41bced7d7f56b6189f654c1c5e1a7f"}))}get el(){return o(this)}static get watchers(){return{open:[{onOpenChange:0}],trapFocus:[{onTrapFocusChange:0}]}}};g.style=":host{display:contents}.co-overlay{position:fixed;inset:0;z-index:1000;margin:0;border:0;padding:0;width:auto;height:auto;max-width:none;max-height:none;overflow:visible;color:inherit;display:flex;align-items:center;justify-content:center;background:var(--co-overlay-bg, rgba(0, 0, 0, 0.4));-webkit-backdrop-filter:blur(var(--co-overlay-blur, 2px));backdrop-filter:blur(var(--co-overlay-blur, 2px));opacity:0;pointer-events:none;transition:opacity var(--co-motion-duration-fast) var(--co-motion-ease-in)}.co-overlay--open{opacity:1;pointer-events:auto;transition:opacity var(--co-motion-duration-base) var(--co-motion-ease-out)}.co-overlay--refront{transition:none !important}";export{g as co_overlay}
@@ -0,0 +1 @@
1
+ import{r as t,h as o,a as i}from"./p-DJkaRtbb.js";import{c as s,g as e,f as a}from"./p-BtliEQAT.js";import{i as r}from"./p-Dp1JT0dm.js";const n={es:{ctrl:"Ctrl",shift:"Shift",alt:"Alt",win:"Win"},en:{ctrl:"Ctrl",shift:"Shift",alt:"Alt",win:"Win"},pt:{ctrl:"Ctrl",shift:"Shift",alt:"Alt",win:"Win"}},c={mod:"command",cmd:"command",shift:"arrow-fat-up",alt:"option",ctrl:"control"};function l(t){return"mod"===t||"cmd"===t||"shift"===t||"alt"===t||"ctrl"===t}function h(t,o,i){if("mac"===o)switch(t){case"mod":case"cmd":return"Cmd";case"shift":return"Shift";case"alt":return"Option";case"ctrl":return"Control"}switch(t){case"mod":case"ctrl":return i.ctrl;case"cmd":return i.win;case"shift":return i.shift;case"alt":return i.alt}}const p=class{constructor(o){t(this,o),this.keys="",this.platform="auto",this.surface="light",this.size="sm",this.chord=!1}resolvePlatform(){return"mac"===this.platform?"mac":"win"===this.platform?"win":function(){if("undefined"==typeof navigator)return!1;const t=navigator.platform||"",o=navigator.userAgent||"";return/Mac/i.test(t)||/Mac/i.test(o)}()?"mac":"win"}render(){const t=this.keys.split("+").map((t=>t.trim().toLowerCase())).filter(Boolean),i=this.resolvePlatform(),s=n[function(t){const o=(t||"").toLowerCase();return o.startsWith("es")?"es":o.startsWith("pt")?"pt":"en"}(this.locale)],e="sm"===this.size?12:10,a=t.map((t=>l(t)?h(t,i,s):t.toUpperCase())).join(" + "),r=t=>l(t)&&"mac"===i,p=(t,e)=>r(t)?o("co-icon",{name:c[t],size:e}):l(t)?h(t,i,s):t.toUpperCase(),d=[];return this.chord?d.push(o("kbd",{class:"co-kbd__key co-kbd__key--chord",part:"key",key:"chord"},t.map(((t,i)=>o("span",{class:{"co-kbd__cell":!0,"co-kbd__cell--icon":r(t),"co-kbd__cell--text":!r(t)},part:"cell",key:`cell-${i}`},p(t,12)))))):t.forEach(((t,i)=>{i>0&&d.push(o("span",{class:"co-kbd__sep",part:"sep",key:`sep-${i}`},"+")),d.push(o("kbd",{class:"co-kbd__key",part:"key",key:`key-${i}`},p(t,e)))})),o("span",{key:"539eee42201f514049f1a879f1cab901af375b79",class:{"co-kbd":!0,[`co-kbd--${this.size}`]:!0,[`co-kbd--${this.surface}`]:!0,"co-kbd--chord":this.chord},role:"group","aria-label":a,part:"group"},d)}};p.style=":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)}";const d=class{constructor(o){t(this,o),this.content="",this.placement="top",this.offset=8,this.showDelay=80,this.hideDelay=100,this.disabled=!1,this.arrow=!0,this.flip=!0,this.maxWidth="280px",this.block=!1,this.variant="default",this.tone="default",this.visible=!1,this.actualPlacement="top",this.closing=!1,this.suppressed=!1,this.scrollParents=[],this.cachedOffsetAncestor=null,this.offsetAncestorComputed=!1,this.scheduleShow=()=>{this.disabled||!this.content||this.suppressed||(this.clearHideTimeout(),this.visible||(this.showTimeout=setTimeout((()=>{this.visible=!0}),this.showDelay)))},this.scheduleHide=()=>{this.clearShowTimeout(),this.visible&&(this.hideTimeout=setTimeout((()=>{this.visible=!1}),this.hideDelay))},this.hideImmediate=()=>{this.clearTimers(),this.visible=!1},this.finishClose=()=>{clearTimeout(this.closeFallbackTimer),this.visible||(this.closing=!1,this.panelEl=void 0)},this.handlePanelTransitionEnd=t=>{!this.visible&&this.closing&&t.target===this.panelEl&&"opacity"===t.propertyName&&this.finishClose()},this.handleMouseEnter=()=>{this.scheduleShow()},this.handleMouseLeave=()=>{this.suppressed=!1,this.scheduleHide()},this.handlePointerDown=()=>{this.suppressed=!0,this.hideImmediate()},this.handleFocusIn=()=>{this.scheduleShow()},this.handleFocusOut=()=>{this.suppressed=!1,this.scheduleHide()},this.handleKeyDown=t=>{"Escape"===t.key&&this.visible&&this.hideImmediate()},this.updatePosition=()=>{if(!this.visible||!this.triggerEl||!this.panelEl)return;const t=this.triggerEl.getBoundingClientRect(),o=this.panelEl.getBoundingClientRect();if(0===o.width&&0===o.height)return;const{top:i,left:a,actualPlacement:n}=s(t,o,{placement:this.placement,offset:this.offset,flip:this.flip});this.actualPlacement=n;let c=i,l=a;if(!r(this.panelEl)&&(this.offsetAncestorComputed||(this.cachedOffsetAncestor=e(this.panelEl),(this.cachedOffsetAncestor||this.panelEl.isConnected)&&(this.offsetAncestorComputed=!0)),this.cachedOffsetAncestor)){const t=this.cachedOffsetAncestor.getBoundingClientRect();c-=t.top,l-=t.left}this.panelEl&&(this.panelEl.style.top=`${c}px`,this.panelEl.style.left=`${l}px`,this.panelEl.classList.add("co-tooltip__panel--positioned"))},this.scheduleUpdate=()=>{this.rafId&&cancelAnimationFrame(this.rafId),this.rafId=requestAnimationFrame(this.updatePosition)}}disconnectedCallback(){this.clearTimers(),this.cleanupListeners(),clearTimeout(this.closeFallbackTimer),this.closing=!1}onVisibleChange(t){t?(this.closing=!1,clearTimeout(this.closeFallbackTimer),this.scheduleUpdate(),requestAnimationFrame((()=>{requestAnimationFrame((()=>{this.updatePosition()}))})),this.addScrollListeners()):(this.cleanupListeners(),this.cachedOffsetAncestor=null,this.offsetAncestorComputed=!1,this.closing=!0,clearTimeout(this.closeFallbackTimer),this.closeFallbackTimer=setTimeout((()=>this.finishClose()),250))}onDisabledChange(t){t&&this.visible&&(this.visible=!1,this.clearTimers())}clearShowTimeout(){this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=void 0)}clearHideTimeout(){this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=void 0)}clearTimers(){this.clearShowTimeout(),this.clearHideTimeout()}promotePanel(){const t=this.panelEl;if(t&&"function"==typeof t.showPopover)try{r(t)||t.showPopover()}catch(t){}}addScrollListeners(){window.addEventListener("resize",this.scheduleUpdate,{passive:!0}),window.addEventListener("scroll",this.scheduleUpdate,{passive:!0,capture:!0}),this.scrollParents=a(this.el);for(const t of this.scrollParents)t.addEventListener("scroll",this.scheduleUpdate,{passive:!0})}cleanupListeners(){this.rafId&&(cancelAnimationFrame(this.rafId),this.rafId=void 0),window.removeEventListener("resize",this.scheduleUpdate),window.removeEventListener("scroll",this.scheduleUpdate,{capture:!0});for(const t of this.scrollParents)t.removeEventListener("scroll",this.scheduleUpdate);this.scrollParents=[]}render(){const t=this.actualPlacement.split("-")[0];return o("div",{key:"2254aedec8e6f6f5d2a5eb8421474d367bf88618",class:"co-tooltip"},o("div",{key:"8e165c1e70c2147924f125b48c893a92ec23e6c7",class:"co-tooltip__trigger",ref:t=>this.triggerEl=t,onMouseEnter:this.handleMouseEnter,onMouseLeave:this.handleMouseLeave,onPointerDown:this.handlePointerDown,onFocusin:this.handleFocusIn,onFocusout:this.handleFocusOut,onKeyDown:this.handleKeyDown,"aria-describedby":this.visible?"tooltip-panel":void 0},o("slot",{key:"c5cf8e75b1be170ed3cd7193677779e426b2eb90"})),(this.visible||this.closing)&&this.content&&o("div",{key:"181da8ed7444cbeefecf4282e267737593c8be0b",id:"tooltip-panel",class:{"co-tooltip__panel":!0,[`co-tooltip__panel--${t}`]:!0,"co-tooltip__panel--closing":this.closing,"co-tooltip__panel--label":"label"===this.variant,"co-tooltip__panel--tone-error":"error"===this.tone,"co-tooltip__panel--with-shortcut":!!this.shortcut},role:"tooltip",popover:"manual",part:"panel",onTransitionEnd:this.handlePanelTransitionEnd,ref:t=>{t&&t!==this.panelEl&&(this.panelEl=t,this.promotePanel(),this.scheduleUpdate())},style:{maxWidth:this.maxWidth}},this.arrow&&o("div",{key:"526fbe6d0317d185491a5e564739c5f2e793688a",class:`co-tooltip__arrow co-tooltip__arrow--${t}`}),o("span",{key:"0a09d46f957d3231ee1584565acc815501ab1fbc",class:"co-tooltip__content"},this.content),this.shortcut&&o("co-kbd",{key:"15a382aa3e6d5547f8450389faa5360e2ee5ecac",keys:this.shortcut,surface:"dark",size:"xs"})))}get el(){return i(this)}static get watchers(){return{visible:[{onVisibleChange:0}],disabled:[{onDisabledChange:0}]}}};d.style=":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;--co-tooltip-surface:var(--co-color-base-negro, #1f1c1b);background:var(--co-tooltip-surface);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-tooltip-surface);border-bottom:none}.co-tooltip__arrow--bottom{top:-5px;left:50%;transform:translateX(-50%);border-bottom-color:var(--co-tooltip-surface);border-top:none}.co-tooltip__arrow--left{right:-10px;top:50%;transform:translateY(-50%);border-left-color:var(--co-tooltip-surface);border-right:none}.co-tooltip__arrow--right{left:-5px;top:50%;transform:translateY(-50%);border-right-color:var(--co-tooltip-surface);border-left:none}.co-tooltip__panel--tone-error{--co-tooltip-surface:var(--co-semantic-status-error, #aa2e1b)}.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}";export{p as co_kbd,d as co_tooltip}
@@ -0,0 +1 @@
1
+ import{r as e,c as t,h as a,a as r}from"./p-DJkaRtbb.js";import{g as o}from"./p-jYd9gu_c.js";import{b as i,d as s,a as c,p as n,i as d,h as l,s as h,c as f,e as p,j as u,g as m,k as b,f as g,l as v}from"./p-BU7SQCje.js";import{R as _}from"./p-CYN5B3IQ.js";import{a as w}from"./p-Ch1jfwZ2.js";import{i as y,p as x,r as L}from"./p-hXbDUT3I.js";import{s as k}from"./p-CBX_oabB.js";import{i as q}from"./p-Dp1JT0dm.js";const z=/^\d{4}-\d{2}-\d{2}$/;function C(e){if(Array.isArray(e))return e;if("string"==typeof e&&e.trim()){const t=e.trim();try{const e=JSON.parse(t);if(Array.isArray(e))return e.map(String)}catch(e){}return t.split(",").map((e=>e.trim())).filter(Boolean)}return[]}function S(e,t,a){return t&&a?`${e}, ${a}`:e}const D=class{constructor(a){e(this,a),this.coSelect=t(this,"coSelect",7),this.coRangeSelect=t(this,"coRangeSelect",7),this.mode="single",this.locale="es-CO",this.firstDayOfWeek=1,this.hoverDay=null,this.view="days",this.shouldFocusGrid=!1,this.handleDayHover=e=>{"range"===this.mode&&(this.hoverDay=e)},this.handlePrev=()=>this.step(-1),this.handleNext=()=>this.step(1),this.toggleView=()=>{this.view="days"===this.view?"months":"months"===this.view?"years":"days"},this.handleGridKeyDown=e=>{const t=this.focused;let a=!0;switch(e.key){case"ArrowLeft":this.moveFocus(s(t,-1));break;case"ArrowRight":this.moveFocus(s(t,1));break;case"ArrowUp":this.moveFocus(s(t,-7));break;case"ArrowDown":this.moveFocus(s(t,7));break;case"Home":this.moveFocus(j(t,this.firstDayOfWeek));break;case"End":this.moveFocus(s(j(t,this.firstDayOfWeek),6));break;case"PageUp":this.moveFocus(i(t,e.shiftKey?-12:-1));break;case"PageDown":this.moveFocus(i(t,e.shiftKey?12:1));break;case"Enter":case" ":this.selectDay(t);break;default:a=!1}a&&(e.preventDefault(),e.stopPropagation())}}componentWillLoad(){var e;const t=null!==(e=this.anchorValue)&&void 0!==e?e:c(),a=n(t);this.viewYear=a.year,this.viewMonth=a.month,this.applyMonthProp(),this.focused=this.initialFocus()}onMonthChange(){this.applyMonthProp()}applyMonthProp(){const e=function(e){const t=/^(\d{4})-(\d{2})$/.exec(String(null!=e?e:"").trim());if(!t)return null;const a=Number(t[1]),r=Number(t[2]);return r>=1&&r<=12?{year:a,month:r}:null}(this.month);e&&(this.viewYear=e.year,this.viewMonth=e.month)}onValueChange(){if(!this.selectedValue)return;const e=n(this.selectedValue);this.viewYear=e.year,this.viewMonth=e.month,this.focused=this.selectedValue}async focusGrid(){this.shouldFocusGrid=!0,this.focusFocusedCell()}get selectedValue(){return d(this.value)?this.value:null}get rangeStartV(){return d(this.rangeStart)?this.rangeStart:null}get rangeEndV(){return d(this.rangeEnd)?this.rangeEnd:null}get anchorValue(){return"range"===this.mode?this.rangeStartV:this.selectedValue}get disabledOpts(){return{min:this.min,max:this.max,disabledDates:C(this.disabledDates),disabledDaysOfWeek:A(this.disabledDaysOfWeek)}}isDayDisabled(e){return l(e,this.disabledOpts)}initialFocus(){const e=this.anchorValue;if(e&&!this.isDayDisabled(e))return e;const t=c(),a=n(t);if(a.year===this.viewYear&&a.month===this.viewMonth&&!this.isDayDisabled(t))return t;const r=`${String(this.viewYear).padStart(4,"0")}-${String(this.viewMonth).padStart(2,"0")}-01`;let o=r;for(let e=0;e<31;e++){const e=n(o);if(!e||e.month!==this.viewMonth)break;if(!this.isDayDisabled(o))return o;o=s(o,1)}return r}selectDay(e){this.isDayDisabled(e)||(this.focused=e,"range"===this.mode?this.selectRangeDay(e):this.coSelect.emit(e))}selectRangeDay(e){const t=this.rangeStartV;let a;a=!t||t&&this.rangeEndV?{start:e,end:null}:f(e,t)<0?{start:e,end:t}:{start:t,end:e},this.coRangeSelect.emit(a)}moveFocus(e){this.focused=e;const t=n(e);t.year===this.viewYear&&t.month===this.viewMonth||(this.viewYear=t.year,this.viewMonth=t.month),this.shouldFocusGrid=!0}step(e){if("days"===this.view){const t=i(`${this.viewYear}-${String(this.viewMonth).padStart(2,"0")}-01`,e),a=n(t);this.viewYear=a.year,this.viewMonth=a.month}else this.viewYear+="months"===this.view?e:10*e}selectMonth(e){this.viewMonth=e,this.view="days"}selectYear(e){this.viewYear=e,this.view="months"}get decadeStart(){return 10*Math.floor(this.viewYear/10)}get selectedYM(){const e="range"===this.mode?this.rangeStartV:this.selectedValue;if(!e)return null;const t=n(e);return{year:t.year,month:t.month}}isMonthDisabled(e,t){const a=`${String(e).padStart(4,"0")}-${String(t).padStart(2,"0")}-01`,r=s(h(i(a,1)),-1);return!!(this.min&&f(r,this.min)<0)||!!(this.max&&f(a,this.max)>0)}isYearDisabled(e){const t=`${String(e).padStart(4,"0")}-01-01`,a=`${String(e).padStart(4,"0")}-12-31`;return!!(this.min&&f(a,this.min)<0)||!!(this.max&&f(t,this.max)>0)}componentDidRender(){this.shouldFocusGrid&&(this.shouldFocusGrid=!1,this.focusFocusedCell())}focusFocusedCell(){var e;const t=null===(e=this.el.shadowRoot)||void 0===e?void 0:e.querySelector(`[data-date="${this.focused}"]`);null==t||t.focus()}rangeFlags(e){const t=this.rangeStartV,a=this.rangeEndV;if(!t)return{isStart:!1,isEnd:!1,inRange:!1};const r=null!=a?a:this.hoverDay&&!a?this.hoverDay:null;if(!r)return{isStart:0===f(e,t),isEnd:!1,inRange:!1};const o=f(t,r)<=0?t:r,i=f(t,r)<=0?r:t;return{isStart:0===f(e,o),isEnd:0===f(e,i),inRange:f(e,o)>0&&f(e,i)<0}}get markedSet(){return new Set(C(this.markedDates).map((e=>e.trim())).filter((e=>z.test(e))))}dayClass(e,t,a,r=!1){const o=0===f(e,c());if("range"===this.mode){const{isStart:i,isEnd:s,inRange:c}=this.rangeFlags(e);return{"co-calendar__day":!0,"co-calendar__day--outside":!t,"co-calendar__day--today":o&&!(i||s)&&!c,"co-calendar__day--range-start":i,"co-calendar__day--range-end":s,"co-calendar__day--in-range":c,"co-calendar__day--disabled":a,"co-calendar__day--marked":r}}const i=this.selectedValue,s=!!i&&0===f(e,i);return{"co-calendar__day":!0,"co-calendar__day--outside":!t,"co-calendar__day--today":o&&!s,"co-calendar__day--selected":s,"co-calendar__day--disabled":a,"co-calendar__day--marked":r}}headerTitle(){return"months"===this.view?String(this.viewYear):"years"===this.view?`${this.decadeStart}–${this.decadeStart+9}`:p(this.viewYear,this.viewMonth,this.locale,"long")}renderDays(e){const t=p(this.viewYear,this.viewMonth,this.locale,"long"),r=u(this.locale,this.firstDayOfWeek,"short"),o=u(this.locale,this.firstDayOfWeek,"long"),i=m(this.viewYear,this.viewMonth,this.firstDayOfWeek).filter((e=>e.some((e=>e.inMonth)))),s=this.markedSet;return a("div",{class:"co-calendar__grid",part:"grid",role:"grid","aria-label":t,onKeyDown:this.handleGridKeyDown},a("div",{class:"co-calendar__row co-calendar__row--dow",role:"row"},r.map(((e,t)=>a("span",{class:"co-calendar__dow",role:"columnheader","aria-label":o[t]},e)))),i.map((e=>a("div",{class:"co-calendar__row",role:"row"},e.map((e=>{const t=this.isDayDisabled(e.value),r=s.has(e.value),o=0===f(e.value,this.focused),i=0===f(e.value,c());let d;if("range"===this.mode){const{isStart:t,isEnd:a}=this.rangeFlags(e.value);d=t||a}else{const t=this.selectedValue;d=!!t&&0===f(e.value,t)}const l=n(e.value).day;return a("button",{type:"button",role:"gridcell","data-date":e.value,class:this.dayClass(e.value,e.inMonth,t,r),tabIndex:o?0:-1,"aria-selected":d?"true":"false","aria-current":i?"date":void 0,"aria-disabled":t?"true":void 0,"aria-label":S(b(e.value,this.locale),r,this.markedLabel),onClick:()=>this.selectDay(e.value),onMouseEnter:()=>this.handleDayHover(e.value),onMouseLeave:()=>this.handleDayHover(null)},l)}))))))}renderMonths(){const e=this.selectedYM,t=new Date;return a("div",{class:"co-calendar__panel",part:"grid"},Array.from({length:12},((r,o)=>{const i=o+1,s=new Intl.DateTimeFormat(this.locale,{month:"short"}).format(new Date(this.viewYear,o,1)),c=this.isMonthDisabled(this.viewYear,i),n=!!e&&e.year===this.viewYear&&e.month===i,d=t.getFullYear()===this.viewYear&&t.getMonth()===o;return a("button",{type:"button",class:{"co-calendar__cell":!0,"co-calendar__cell--selected":n,"co-calendar__cell--today":d&&!n,"co-calendar__cell--disabled":c},disabled:c,"aria-current":d?"date":void 0,onClick:()=>this.selectMonth(i)},s)})))}renderYears(){const e=this.selectedYM,t=(new Date).getFullYear(),r=this.decadeStart-1;return a("div",{class:"co-calendar__panel",part:"grid"},Array.from({length:12},((o,i)=>{const s=r+i,c=this.isYearDisabled(s),n=!!e&&e.year===s,d=t===s;return a("button",{type:"button",class:{"co-calendar__cell":!0,"co-calendar__cell--muted":s<this.decadeStart||s>this.decadeStart+9,"co-calendar__cell--selected":n,"co-calendar__cell--today":d&&!n,"co-calendar__cell--disabled":c},disabled:c,"aria-current":d?"date":void 0,onClick:()=>this.selectYear(s)},s)})))}render(){var e,t;const r=o(this.locale);return a("div",{key:"5ecdc23692eb69b8dc86b225857f51a3acf54838",class:"co-calendar",part:"root"},a("div",{key:"b66924b6b59f91d284210c6a0ed24294f211a5b7",class:"co-calendar__header",part:"header"},a("button",{key:"a4d52f3c02081b03f872a95955986c6351f9ca44",type:"button",class:"co-calendar__nav",onClick:this.handlePrev,"aria-label":null!==(e=this.prevMonthLabel)&&void 0!==e?e:r.prevMonth},a("co-icon",{key:"6eaf089247fc85477a1bd9095af2c1c557d01bb3",name:"caret-left",size:16})),a("button",{key:"473815fa6114c82f601bea27e919b5c4546648f2",type:"button",class:"co-calendar__title","aria-live":"polite",onClick:this.toggleView},this.headerTitle(),a("co-icon",{key:"923647a98317c5e42ec7655ac21eed3e645224b6",name:"caret-down",size:12,class:"co-calendar__title-caret"})),a("button",{key:"1ccbdf76cc5574021894f8f1c6bd381b9b524cfa",type:"button",class:"co-calendar__nav",onClick:this.handleNext,"aria-label":null!==(t=this.nextMonthLabel)&&void 0!==t?t:r.nextMonth},a("co-icon",{key:"4b06c0827034a9f6924f1e80a51fdef924a0f8d1",name:"caret-right",size:16}))),"days"===this.view&&this.renderDays(r),"months"===this.view&&this.renderMonths(),"years"===this.view&&this.renderYears())}get el(){return r(this)}static get watchers(){return{month:[{onMonthChange:0}],value:[{onValueChange:0}]}}};function j(e,t){const a=n(e);if(!a)return e;const r=new Date(a.year,a.month-1,a.day).getDay();return s(e,-(r-t+7)%7)}function A(e){if(Array.isArray(e))return e;if("string"==typeof e&&e.trim()){const t=e.trim();try{const e=JSON.parse(t);if(Array.isArray(e))return e.map(Number).filter((e=>!Number.isNaN(e)))}catch(e){}return t.split(",").map((e=>Number(e.trim()))).filter((e=>!Number.isNaN(e)))}return[]}D.style=":host{display:inline-block;font-family:var(--co-font-family-primary);--co-calendar-day-size:36px}:host([data-touch]){--co-calendar-day-size:44px}.co-calendar{display:flex;flex-direction:column;gap:var(--co-spacing-sm);width:var(--co-calendar-width, max-content)}.co-calendar__header{display:flex;align-items:center;justify-content:space-between;padding:0 var(--co-spacing-xs)}.co-calendar__month{font-size:var(--co-font-size-14);font-weight:600;color:var(--co-semantic-text-default);text-transform:capitalize}.co-calendar__title{display:inline-flex;align-items:center;gap:var(--co-spacing-xxs);background:none;border:0;cursor:pointer;font-family:inherit;font-size:var(--co-font-size-14);font-weight:600;color:var(--co-semantic-text-default);text-transform:capitalize;padding:var(--co-spacing-xxs) var(--co-spacing-sm);border-radius:var(--co-border-radius-xs)}.co-calendar__title:hover{background:var(--co-semantic-surface-hover)}.co-calendar__title:focus-visible{outline:2px solid var(--co-semantic-border-focus);outline-offset:1px}.co-calendar__title-caret{color:var(--co-semantic-text-muted)}.co-calendar__panel{display:grid;grid-template-columns:repeat(3, 1fr);gap:var(--co-spacing-xs);width:var(--co-calendar-width, calc(var(--co-calendar-day-size) * 7 + 12px));padding-top:var(--co-spacing-xs)}.co-calendar__cell{height:calc(var(--co-calendar-day-size) + 8px);display:inline-flex;align-items:center;justify-content:center;background:none;border:1px solid transparent;border-radius:var(--co-border-radius-xs);font-family:inherit;font-size:var(--co-font-size-14);color:var(--co-semantic-text-default);cursor:pointer;text-transform:capitalize;transition:background var(--co-motion-duration-fast) var(--co-motion-ease-out), color var(--co-motion-duration-fast) var(--co-motion-ease-out), border-color var(--co-motion-duration-fast) var(--co-motion-ease-out)}.co-calendar__cell:hover:not(.co-calendar__cell--disabled):not(.co-calendar__cell--selected){background:var(--co-semantic-surface-hover)}.co-calendar__cell:focus-visible{outline:2px solid var(--co-semantic-border-focus);outline-offset:1px}.co-calendar__cell--muted{color:var(--co-semantic-text-muted)}.co-calendar__cell--today{border-color:var(--co-semantic-surface-primary);font-weight:600}.co-calendar__cell--selected{background:var(--co-semantic-surface-primary);border-color:var(--co-semantic-surface-primary);color:var(--co-semantic-on-primary);font-weight:600}.co-calendar__cell--disabled{color:var(--co-semantic-text-disabled);cursor:not-allowed}.co-calendar__nav{background:none;border:0;cursor:pointer;padding:var(--co-spacing-xs);border-radius:var(--co-border-radius-xxs);display:inline-flex;align-items:center;color:var(--co-semantic-text-default)}.co-calendar__nav:hover{background:var(--co-semantic-surface-hover)}.co-calendar__nav:focus-visible{outline:2px solid var(--co-semantic-border-focus);outline-offset:1px}.co-calendar__grid{display:flex;flex-direction:column;gap:2px}.co-calendar__row{display:grid;grid-template-columns:repeat(7, var(--co-calendar-col, var(--co-calendar-day-size)));gap:2px}.co-calendar__row--dow{margin-bottom:2px}.co-calendar__dow{height:24px;display:inline-flex;align-items:center;justify-content:center;font-size:var(--co-font-size-10, 10px);font-weight:600;color:var(--co-semantic-text-muted);text-transform:uppercase;letter-spacing:0.04em}.co-calendar__day{width:var(--co-calendar-day-width, var(--co-calendar-day-size));height:var(--co-calendar-day-size);display:inline-flex;align-items:center;justify-content:center;background:none;border:1px solid transparent;border-radius:var(--co-border-radius-xs);font-size:var(--co-font-size-14);font-family:inherit;color:var(--co-semantic-text-default);cursor:pointer;transition:background var(--co-motion-duration-fast) var(--co-motion-ease-out), color var(--co-motion-duration-fast) var(--co-motion-ease-out), border-color var(--co-motion-duration-fast) var(--co-motion-ease-out)}.co-calendar__day:hover:not(.co-calendar__day--disabled):not(.co-calendar__day--selected):not(.co-calendar__day--marked):not(.co-calendar__day--range-start):not(.co-calendar__day--range-end){background:var(--co-semantic-surface-hover)}.co-calendar__day:focus-visible{outline:2px solid var(--co-semantic-border-focus);outline-offset:1px}.co-calendar__day--outside{color:var(--co-semantic-text-muted)}.co-calendar__day--today{border-color:var(--co-semantic-surface-primary);font-weight:600}.co-calendar__day--marked{background:var(--co-calendar-marked-bg, var(--co-color-primary-rosado));border-color:var(--co-calendar-marked-bg, var(--co-color-primary-rosado));color:var(--co-calendar-marked-fg, var(--co-color-base-blanco));font-weight:600}.co-calendar__day--selected{background:var(--co-semantic-surface-primary);border-color:var(--co-semantic-surface-primary);color:var(--co-semantic-on-primary);font-weight:600}.co-calendar__day--disabled{color:var(--co-semantic-text-disabled);cursor:not-allowed;pointer-events:none}.co-calendar__day--in-range{background:color-mix(in srgb, var(--co-semantic-surface-primary) 8%, transparent);border-radius:0;color:var(--co-semantic-text-default)}.co-calendar__day--range-start,.co-calendar__day--range-end{background:var(--co-semantic-surface-primary);border-color:var(--co-semantic-surface-primary);color:var(--co-semantic-on-primary);font-weight:600}.co-calendar__day--range-start:not(.co-calendar__day--range-end){border-top-right-radius:0;border-bottom-right-radius:0}.co-calendar__day--range-end:not(.co-calendar__day--range-start){border-top-left-radius:0;border-bottom-left-radius:0}";const M=class{constructor(a){e(this,a),this.coInput=t(this,"coInput",7),this.coChange=t(this,"coChange",7),this.coInvalid=t(this,"coInvalid",7),this.coClear=t(this,"coClear",7),this.coFocus=t(this,"coFocus",7),this.coBlur=t(this,"coBlur",7),this.value=null,this.size="md",this.locale="es-CO",this.displayFormat="d MMM yyyy",this.disabled=!1,this.readonly=!1,this.required=!1,this.clearable=!0,this.invalid=!1,this.layout="vertical",this.draft="",this.internalInvalid=!1,this.hasFocus=!1,this.handleInput=e=>{this.draft=e.target.value,this.internalInvalid=!1,this.coInput.emit(this.draft)},this.handleFocus=()=>{this.hasFocus=!0,this.coFocus.emit()},this.handleBlur=()=>{this.hasFocus=!1,this.commit(),this.coBlur.emit()},this.handleKeyDown=e=>{"Enter"===e.key&&(this.commit()||(e.preventDefault(),e.stopPropagation()))},this.handleClear=()=>{var e;this.draft="",this.internalInvalid=!1,null!==this.value&&(this.value=null,this.coChange.emit(null)),this.coClear.emit(),null===(e=this.inputEl)||void 0===e||e.focus()}}componentWillLoad(){this.draft=g(this.value,this.displayFormat,this.locale)}onValueChange(){this.hasFocus||(this.draft=g(this.value,this.displayFormat,this.locale),this.internalInvalid=!1)}async focusInput(){var e;null===(e=this.inputEl)||void 0===e||e.focus()}get order(){const e=this.displayFormat.toLowerCase();return e.startsWith("y")?"ymd":e.startsWith("m")?"mdy":"dmy"}get isInvalid(){return this.invalid||this.internalInvalid}get hasValue(){return""!==this.draft.trim()}commit(){const e=v(this.draft,{order:this.order,locale:this.locale});if("empty"===e.status)return this.internalInvalid=!1,null!==this.value&&(this.value=null,this.coChange.emit(null)),!0;if("invalid"===e.status||null===e.value)return this.internalInvalid=!0,this.coInvalid.emit({raw:this.draft}),!1;const t=e.value;return l(t,{min:this.min,max:this.max,disabledDates:$(this.disabledDates),disabledDaysOfWeek:N(this.disabledDaysOfWeek)})?(this.internalInvalid=!0,this.coInvalid.emit({raw:this.draft}),!1):(this.internalInvalid=!1,this.draft=g(t,this.displayFormat,this.locale),this.value!==t&&(this.value=t,this.coChange.emit(t)),!0)}render(){var e,t;const r=o(this.locale),i=this.clearable&&this.hasValue&&!this.disabled&&!this.readonly,s=this.placeholder||r.setDate,c=this.isInvalid?this.errorMessage:this.helperText;return a("div",{key:"453e532a8aa115e750353877880555d00c768951",class:{"co-date-field":!0,"co-date-field--disabled":this.disabled,"co-date-field--focused":this.hasFocus,"co-date-field--filled":this.hasValue,"co-date-field--invalid":this.isInvalid,[`co-date-field--${this.size}`]:!0},part:"wrapper"},this.label&&a("div",{key:"e455cfb66bb65981ba685dcd3c2fbbf0bd98562f",class:"co-date-field__labels"},a("label",{key:"d3cd19357bded058f3922c5423f816bc094c5fb9",class:"co-date-field__label",part:"label"},this.label,a(_,{key:"e66ca94dabe83f2bcf77a85d6d4c72ad7eed6cdb",required:this.required}))),a("div",{key:"848c32b06cbe5fa847c9c769c1407f13237ba4d5",class:"co-date-field__field-row"},a("div",{key:"ca350ae929087a7e6268de42a4b2e14d3de9ef58",class:"co-date-field__field",part:"field"},a("co-icon",{key:"9054673efd46a0f367abffc938a3328af6d0408b",name:"calendar",size:16,class:"co-date-field__icon"}),a("div",{key:"06c441cd3829acfd26d1e2eba100f246fadf4f55",class:"co-date-field__input-wrapper"},a("input",{key:"0b1fccd57b629230b079ad41d3d02555ca54144d",ref:e=>this.inputEl=e,class:"co-date-field__native",type:"text",inputMode:"numeric",autocomplete:"off",value:this.draft,placeholder:s,disabled:this.disabled,readOnly:this.readonly,required:this.required,"aria-invalid":this.isInvalid?"true":"false","aria-label":this.label?void 0:r.dateLabel,onInput:this.handleInput,onFocus:this.handleFocus,onBlur:this.handleBlur,onKeyDown:this.handleKeyDown,part:"input"})),this.clearable&&a("button",{key:"afacd96145ddfb36f9c4823dace12472c1692839",class:{"co-date-field__clear":!0,"co-date-field__clear--hidden":!i},type:"button",tabIndex:-1,onMouseDown:e=>e.preventDefault(),onClick:this.handleClear,"aria-label":null!==(e=this.clearLabel)&&void 0!==e?e:r.clearDate,part:"clear"},a("co-icon",{key:"87d841da80b8d0ef82df03ec32345a0cd274f043",name:"x-circle",size:16,weight:"fill"})))),this.name&&a("input",{key:"60a65f36972af02f0bb3f747c287b0fb8174de4d",type:"hidden",name:this.name,value:null!==(t=this.value)&&void 0!==t?t:""}),c&&a("div",{key:"05cfeef9edc268c1ca3f6b112d9750532cbf6159",class:{"co-date-field__helper":!0,"co-date-field__helper--error":this.isInvalid},part:"helper"},this.isInvalid&&a("co-icon",{key:"8e97926b9bd11f007d850dbcced80b9fb51b37b6",name:"warning-circle",size:14,class:"co-date-field__helper-icon"}),a("span",{key:"8cd33b10c139f17a97bc88f457a96e23413e744a",class:"co-date-field__helper-text"},c)))}get el(){return r(this)}static get watchers(){return{value:[{onValueChange:0}]}}};function $(e){if(Array.isArray(e))return e;if("string"==typeof e&&e.trim()){try{const t=JSON.parse(e);if(Array.isArray(t))return t.map(String)}catch(e){}return e.split(",").map((e=>e.trim())).filter(Boolean)}return[]}function N(e){if(Array.isArray(e))return e;if("string"==typeof e&&e.trim()){try{const t=JSON.parse(e);if(Array.isArray(t))return t.map(Number).filter((e=>!Number.isNaN(e)))}catch(e){}return e.split(",").map((e=>Number(e.trim()))).filter((e=>!Number.isNaN(e)))}return[]}M.style=":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-date-field{display:flex;flex-direction:column;gap:var(--co-spacing-sm2)}.co-date-field__labels{display:flex;align-items:center;justify-content:space-between;padding:0 var(--co-spacing-xs);gap:var(--co-spacing-sm2)}.co-date-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-date-field__field-row{display:flex;align-items:stretch}.co-date-field--s .co-date-field__field{min-height:28px;padding:var(--co-spacing-xxs) var(--co-spacing-sm)}.co-date-field--sm .co-date-field__field{min-height:32px;padding:var(--co-spacing-xs) var(--co-spacing-sm)}.co-date-field--lg .co-date-field__field{min-height:48px;padding:var(--co-spacing-sm) var(--co-spacing-lg)}.co-date-field__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-date-field__icon{flex-shrink:0;color:var(--co-semantic-text-muted);display:flex;align-items:center}.co-date-field__input-wrapper{flex:1;display:flex;align-items:center;min-width:0;min-height:22px;padding:0}.co-date-field__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-date-field__native::placeholder{color:var(--co-semantic-text-muted)}.co-date-field__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-date-field__clear--hidden{visibility:hidden;pointer-events:none}.co-date-field__clear:hover{color:var(--co-semantic-text-default)}.co-date-field__helper{display:flex;align-items:center;gap:var(--co-spacing-xs);padding:0 var(--co-spacing-xs)}.co-date-field__helper-icon{flex-shrink:0;color:var(--co-semantic-text-muted);display:flex;align-items:center}.co-date-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-date-field--focused .co-date-field__field{border-color:var(--co-semantic-border-focus);box-shadow:0 0 0 2px var(--co-semantic-border-focus-ring)}.co-date-field--disabled .co-date-field__labels .co-date-field__label{color:var(--co-semantic-text-disabled)}.co-date-field--disabled .co-date-field__field{background:var(--co-semantic-surface-disabled);border-color:transparent;cursor:not-allowed}.co-date-field--disabled .co-date-field__native{color:var(--co-semantic-text-disabled);cursor:not-allowed}.co-date-field--disabled .co-date-field__native::placeholder{color:var(--co-semantic-text-disabled)}.co-date-field--disabled .co-date-field__icon{color:var(--co-semantic-text-disabled)}.co-date-field--invalid .co-date-field__field{border-color:var(--co-semantic-border-error, var(--co-semantic-status-error))}.co-date-field--invalid.co-date-field--focused .co-date-field__field{border-color:var(--co-semantic-border-error, var(--co-semantic-status-error));box-shadow:0 0 0 2px color-mix(in srgb, var(--co-semantic-border-error, var(--co-semantic-status-error)) 12%, transparent)}.co-date-field__helper--error .co-date-field__helper-icon,.co-date-field__helper--error .co-date-field__helper-text{color:var(--co-semantic-text-error, var(--co-semantic-status-error))}:host([layout='horizontal']) .co-date-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-date-field__labels{grid-column:1;grid-row:1;padding-top:var(--co-spacing-sm2);min-width:0}:host([layout='horizontal']) .co-date-field__label{white-space:normal}:host([layout='horizontal']) .co-date-field>:not(.co-date-field__labels){grid-column:2;min-width:0}.co-field-required{margin-left:2px;color:var(--co-semantic-text-error, 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)')}";const O=class{constructor(a){e(this,a),this.coClose=t(this,"coClose",7),this.coOpen=t(this,"coOpen",7),this.coAfterOpen=t(this,"coAfterOpen",7),this.coAfterClose=t(this,"coAfterClose",7),this.open=!1,this.position="right",this.size="md",this.heading="",this.description="",this.icon="",this.closable=!0,this.closeOnOverlay=!0,this.closeOnEscape=!0,this.modeless=!1,this.loading=!1,this.hasFooter=!1,this.hasTabs=!1,this.hasHeaderSlot=!1,this.handleFooterSlotChange=e=>{this.hasFooter=k(e)},this.handleTabsSlotChange=e=>{this.hasTabs=k(e)},this.handleHeaderSlotChange=e=>{this.hasHeaderSlot=k(e)},this.handleOverlayClose=()=>{this.closeOnOverlay&&this.coClose.emit()},this.handleCloseClick=()=>{this.coClose.emit()},this.stopPropagation=e=>{e.stopPropagation()},this.handleTransitionEnd=e=>{if(e.target!==this.asideEl)return;const t=w(e.propertyName,this.open,"transform");"after-open"===t?this.coAfterOpen.emit():"after-close"===t&&this.coAfterClose.emit()},this.promoteModeless=e=>{e&&(this.asideEl=e);const t=this.asideEl;if(this.modeless&&t&&"function"==typeof t.showPopover)try{q(t)||t.showPopover()}catch(e){}}}get labelledBy(){return this.hasHeaderSlot?"co-drawer-header-content":this.heading?"co-drawer-heading":void 0}onOpenChange(e,t){e?x(this):L(this),e&&!t&&this.coOpen.emit()}connectedCallback(){this.open&&x(this)}disconnectedCallback(){L(this)}handleKey(e){this.open&&this.closeOnEscape&&"Escape"===e.key&&(this.modeless&&document.querySelector("co-drawer[open]:not([modeless]), co-modal[open]")||y(this)&&this.coClose.emit())}componentDidLoad(){this.promoteModeless()}render(){const e=a("aside",{class:{"co-drawer":!0,"co-sq-elevation":!0,"co-sq-elevation-fallback":!0,"co-drawer--open":this.open,"co-drawer--modeless":this.modeless,[`co-drawer--${this.position}`]:!0,[`co-drawer--${this.size}`]:!0},popover:this.modeless?"manual":void 0,ref:this.promoteModeless,part:"drawer",role:"dialog","aria-modal":this.modeless?"false":"true","aria-labelledby":this.labelledBy,onClick:this.stopPropagation,onTransitionEnd:this.handleTransitionEnd},a("div",{class:"co-drawer__card co-sq-clip",part:"card"},a("header",{class:"co-drawer__header",part:"header"},a("div",{class:"co-drawer__header-content",id:"co-drawer-header-content"},a("slot",{name:"header",onSlotchange:this.handleHeaderSlotChange},a("div",{class:"co-drawer__heading-row"},this.icon&&a("co-icon",{name:this.icon,size:20,class:"co-drawer__icon"}),a("h2",{class:"co-drawer__heading",id:"co-drawer-heading"},this.heading)),this.description&&a("p",{class:"co-drawer__description"},this.description))),this.closable&&a("button",{class:"co-drawer__close",type:"button","aria-label":"Close",onClick:this.handleCloseClick},a("co-icon",{name:"x",size:20}))),a("div",{class:{"co-drawer__tabs":!0,"co-drawer__tabs--empty":!this.hasTabs},part:"tabs"},a("slot",{name:"tabs",onSlotchange:this.handleTabsSlotChange})),a("div",{class:"co-drawer__body",part:"body"},a("slot",null),a("co-loader",{overlay:!0,visible:this.loading,part:"loader"})),a("footer",{class:{"co-drawer__footer":!0,"co-drawer__footer--empty":!this.hasFooter},part:"footer"},a("slot",{name:"footer",onSlotchange:this.handleFooterSlotChange}))));return this.modeless?e:a("co-overlay",{open:this.open,onCoClose:this.handleOverlayClose},e)}get el(){return r(this)}static get watchers(){return{open:[{onOpenChange:0}]}}};O.style='.co-sq-elevation{border-radius:var(--co-sq-r);corner-shape:squircle;box-shadow:var(--co-sq-shadow)}.co-sq-clip{overflow:hidden;border-radius:var(--co-sq-r);corner-shape:squircle}@supports not (corner-shape: squircle){.co-sq-elevation{box-shadow:none}.co-sq-elevation-fallback{filter:var(--co-sq-drop-shadow)}.co-sq-clip{border-radius:0;--co-sq-tl:url("data:image/svg+xml,<svg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 100 100%27 preserveAspectRatio=%27none%27><path d=%27M100 0L97.5 0L95 0L92.5 0L90 0L87.5 0.01L85 0.01L82.5 0.02L80 0.04L77.5 0.06L75 0.1L72.5 0.14L70 0.2L67.5 0.28L65 0.38L62.5 0.5L60 0.65L57.5 0.83L55 1.04L52.5 1.3L50 1.6L47.5 1.96L45 2.37L42.5 2.85L40 3.41L37.5 4.05L35 4.8L32.5 5.65L30 6.63L27.5 7.77L25 9.07L22.5 10.58L20 12.34L17.5 14.41L15 16.85L12.5 19.79L10 23.42L7.5 28.06L5 34.37L2.5 44.29L0 100L100 100Z%27 fill=%27%23fff%27/></svg>");--co-sq-tr:url("data:image/svg+xml,<svg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 100 100%27 preserveAspectRatio=%27none%27><path d=%27M0 0L2.5 0L5 0L7.5 0L10 0L12.5 0.01L15 0.01L17.5 0.02L20 0.04L22.5 0.06L25 0.1L27.5 0.14L30 0.2L32.5 0.28L35 0.38L37.5 0.5L40 0.65L42.5 0.83L45 1.04L47.5 1.3L50 1.6L52.5 1.96L55 2.37L57.5 2.85L60 3.41L62.5 4.05L65 4.8L67.5 5.65L70 6.63L72.5 7.77L75 9.07L77.5 10.58L80 12.34L82.5 14.41L85 16.85L87.5 19.79L90 23.42L92.5 28.06L95 34.37L97.5 44.29L100 100L0 100Z%27 fill=%27%23fff%27/></svg>");--co-sq-bl:url("data:image/svg+xml,<svg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 100 100%27 preserveAspectRatio=%27none%27><path d=%27M0 0L2.5 55.71L5 65.63L7.5 71.94L10 76.58L12.5 80.21L15 83.15L17.5 85.59L20 87.66L22.5 89.42L25 90.93L27.5 92.23L30 93.37L32.5 94.35L35 95.2L37.5 95.95L40 96.59L42.5 97.15L45 97.63L47.5 98.04L50 98.4L52.5 98.7L55 98.96L57.5 99.17L60 99.35L62.5 99.5L65 99.62L67.5 99.72L70 99.8L72.5 99.86L75 99.9L77.5 99.94L80 99.96L82.5 99.98L85 99.99L87.5 99.99L90 100L92.5 100L95 100L97.5 100L100 100L100 0Z%27 fill=%27%23fff%27/></svg>");--co-sq-br:url("data:image/svg+xml,<svg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 100 100%27 preserveAspectRatio=%27none%27><path d=%27M100 0L97.5 55.71L95 65.63L92.5 71.94L90 76.58L87.5 80.21L85 83.15L82.5 85.59L80 87.66L77.5 89.42L75 90.93L72.5 92.23L70 93.37L67.5 94.35L65 95.2L62.5 95.95L60 96.59L57.5 97.15L55 97.63L52.5 98.04L50 98.4L47.5 98.7L45 98.96L42.5 99.17L40 99.35L37.5 99.5L35 99.62L32.5 99.72L30 99.8L27.5 99.86L25 99.9L22.5 99.94L20 99.96L17.5 99.98L15 99.99L12.5 99.99L10 100L7.5 100L5 100L2.5 100L0 100L0 0Z%27 fill=%27%23fff%27/></svg>");-webkit-mask:var(--co-sq-tl) top left / var(--co-sq-r) var(--co-sq-r) no-repeat, var(--co-sq-tr) top right / var(--co-sq-r) var(--co-sq-r) no-repeat, var(--co-sq-bl) bottom left / var(--co-sq-r) var(--co-sq-r) no-repeat, var(--co-sq-br) bottom right / var(--co-sq-r) var(--co-sq-r) no-repeat, linear-gradient(#fff 0 0) center / 100% calc(100% - 2 * var(--co-sq-r) + 2px) no-repeat, linear-gradient(#fff 0 0) center / calc(100% - 2 * var(--co-sq-r) + 2px) 100% no-repeat;mask:var(--co-sq-tl) top left / var(--co-sq-r) var(--co-sq-r) no-repeat, var(--co-sq-tr) top right / var(--co-sq-r) var(--co-sq-r) no-repeat, var(--co-sq-bl) bottom left / var(--co-sq-r) var(--co-sq-r) no-repeat, var(--co-sq-br) bottom right / var(--co-sq-r) var(--co-sq-r) no-repeat, linear-gradient(#fff 0 0) center / 100% calc(100% - 2 * var(--co-sq-r) + 2px) no-repeat, linear-gradient(#fff 0 0) center / calc(100% - 2 * var(--co-sq-r) + 2px) 100% no-repeat}}:host{display:contents}.co-drawer{position:fixed;display:flex;flex-direction:column;font-family:var(--co-font-family-primary);color:inherit;transition:transform var(--co-motion-duration-slow) var(--co-motion-ease-in-out);will-change:transform;z-index:1;contain:layout;--co-drawer-r:var(--co-shell-r, var(--co-border-radius-md));--co-sq-r:var(--co-drawer-r);--co-sq-shadow:0 1px 4px rgba(31, 28, 27, 0.06), 0 10px 56px rgba(31, 28, 27, 0.12);--co-sq-drop-shadow:drop-shadow(0 1px 2px rgba(31, 28, 27, 0.06)) drop-shadow(0 10px 28px rgba(31, 28, 27, 0.12))}.co-drawer--right{top:0;right:0;margin:6px;height:100vh;height:-webkit-fill-available;transform:translateX(calc(100% + 12px))}.co-drawer--right.co-drawer--open{transform:translateX(0)}.co-drawer--left{top:0;left:0;margin:6px;height:100vh;height:-webkit-fill-available;transform:translateX(calc(-100% - 12px))}.co-drawer--left.co-drawer--open{transform:translateX(0)}.co-drawer--bottom{bottom:0;left:0;right:0;margin:6px;width:auto;transform:translateY(calc(100% + 12px))}.co-drawer--bottom.co-drawer--open{transform:translateY(0)}.co-drawer--right.co-drawer--sm,.co-drawer--left.co-drawer--sm{width:400px;max-width:100vw}.co-drawer--right.co-drawer--md,.co-drawer--left.co-drawer--md{width:520px;max-width:100vw}.co-drawer--right.co-drawer--lg,.co-drawer--left.co-drawer--lg{width:672px;max-width:100vw}.co-drawer--right.co-drawer--xl,.co-drawer--left.co-drawer--xl{width:960px;max-width:100vw}.co-drawer--right.co-drawer--full,.co-drawer--left.co-drawer--full{width:100vw}.co-drawer--bottom.co-drawer--sm{height:40vh}.co-drawer--bottom.co-drawer--md{height:60vh}.co-drawer--bottom.co-drawer--lg{height:80vh}.co-drawer--bottom.co-drawer--xl{height:95vh}.co-drawer--bottom.co-drawer--full{height:100vh}.co-drawer__card{flex:1;min-height:0;display:flex;flex-direction:column;background:var(--co-semantic-surface-page);color:var(--co-semantic-text-default)}.co-drawer__header{display:flex;align-items:center;gap:var(--co-spacing-md);padding:var(--co-spacing-lg) var(--co-spacing-xl);border-bottom:1px solid var(--co-semantic-border-default);flex-shrink:0}.co-drawer__header-content{flex:1;min-width:0}.co-drawer__heading-row{display:flex;align-items:center;gap:var(--co-spacing-sm, 8px)}.co-drawer__icon{flex-shrink:0;color:var(--co-semantic-text-secondary)}.co-drawer__heading{margin:0;font-size:var(--co-font-size-18);font-weight:600;color:var(--co-semantic-text-default);line-height:1.3;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.co-drawer__description{margin:var(--co-spacing-xs) 0 0;font-size:var(--co-font-size-13, 13px);font-weight:400;color:var(--co-semantic-text-muted);line-height:1.4}.co-drawer__close{display:flex;align-items:center;justify-content:center;padding:var(--co-spacing-xs);margin:0;border:none;background:transparent;cursor:pointer;color:var(--co-semantic-text-muted);border-radius:var(--co-border-radius-sm);transition:background var(--co-motion-duration-fast) var(--co-motion-ease-out);flex-shrink:0}.co-drawer__close:hover{background:var(--co-semantic-surface-hover)}.co-drawer__close:focus-visible{outline:2px solid var(--co-color-primary-azul);outline-offset:2px}.co-drawer__tabs{flex-shrink:0;border-bottom:1px solid var(--co-semantic-border-default)}.co-drawer__tabs--empty{display:none}.co-drawer__body{flex:1;overflow-y:auto;overscroll-behavior:contain;padding:var(--co-spacing-xl);position:relative}.co-drawer__body{scrollbar-width:thin;scrollbar-color:transparent transparent}.co-drawer__body:hover{scrollbar-color:var(--co-semantic-border-default) transparent}.co-drawer__body::-webkit-scrollbar{width:6px}.co-drawer__body::-webkit-scrollbar-track{background:transparent}.co-drawer__body::-webkit-scrollbar-thumb{background:transparent;border-radius:9999px}.co-drawer__body:hover::-webkit-scrollbar-thumb{background:var(--co-semantic-border-default)}.co-drawer__body:hover::-webkit-scrollbar-thumb:hover{background:var(--co-semantic-border-field)}.co-drawer__body:hover::-webkit-scrollbar-thumb:active{background:var(--co-semantic-border-strong)}.co-drawer__footer{display:flex;justify-content:flex-end;align-items:center;gap:var(--co-spacing-md);padding:var(--co-spacing-lg) var(--co-spacing-xl);border-top:1px solid var(--co-semantic-border-default);flex-shrink:0}.co-drawer__footer--empty{display:none}@media (max-width: 600px){.co-drawer--right,.co-drawer--left{width:100vw !important}}.co-drawer--modeless{z-index:1000;border:0;padding:0;background:transparent}.co-drawer--modeless.co-drawer--right{left:auto;bottom:auto}.co-drawer--modeless.co-drawer--left{right:auto;bottom:auto}.co-drawer--modeless.co-drawer--bottom{top:auto}';export{D as co_calendar,M as co_date_field,O as co_drawer}
@@ -431,7 +431,7 @@ export class CoAutocomplete {
431
431
  "references": {
432
432
  "AutocompleteOption": {
433
433
  "location": "local",
434
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-autocomplete/co-autocomplete.tsx",
434
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-autocomplete/co-autocomplete.tsx",
435
435
  "id": "src/components/co-autocomplete/co-autocomplete.tsx::AutocompleteOption"
436
436
  }
437
437
  }
@@ -92,7 +92,7 @@ export class CoAvatarGroup {
92
92
  "references": {
93
93
  "CoAvatarGroupItem": {
94
94
  "location": "local",
95
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-avatar-group/co-avatar-group.tsx",
95
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-avatar-group/co-avatar-group.tsx",
96
96
  "id": "src/components/co-avatar-group/co-avatar-group.tsx::CoAvatarGroupItem"
97
97
  }
98
98
  }
@@ -236,7 +236,7 @@ export class CoCheckboxGroup {
236
236
  "references": {
237
237
  "CheckboxOption": {
238
238
  "location": "local",
239
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-checkbox-group/co-checkbox-group.tsx",
239
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-checkbox-group/co-checkbox-group.tsx",
240
240
  "id": "src/components/co-checkbox-group/co-checkbox-group.tsx::CheckboxOption"
241
241
  }
242
242
  }
@@ -310,7 +310,7 @@ export class CoColorArea {
310
310
  "references": {
311
311
  "ColorAreaDetail": {
312
312
  "location": "local",
313
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-color-area/co-color-area.tsx",
313
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-color-area/co-color-area.tsx",
314
314
  "id": "src/components/co-color-area/co-color-area.tsx::ColorAreaDetail"
315
315
  }
316
316
  }
@@ -331,7 +331,7 @@ export class CoColorArea {
331
331
  "references": {
332
332
  "ColorAreaDetail": {
333
333
  "location": "local",
334
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-color-area/co-color-area.tsx",
334
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-color-area/co-color-area.tsx",
335
335
  "id": "src/components/co-color-area/co-color-area.tsx::ColorAreaDetail"
336
336
  }
337
337
  }
@@ -215,7 +215,7 @@ export class CoColorSlider {
215
215
  "references": {
216
216
  "ColorSliderChannel": {
217
217
  "location": "local",
218
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-color-slider/co-color-slider.tsx",
218
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-color-slider/co-color-slider.tsx",
219
219
  "id": "src/components/co-color-slider/co-color-slider.tsx::ColorSliderChannel"
220
220
  }
221
221
  }
@@ -547,7 +547,7 @@ export class CoCombobox {
547
547
  "references": {
548
548
  "ComboboxOption": {
549
549
  "location": "local",
550
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-combobox/co-combobox.tsx",
550
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-combobox/co-combobox.tsx",
551
551
  "id": "src/components/co-combobox/co-combobox.tsx::ComboboxOption"
552
552
  }
553
553
  }
@@ -257,7 +257,7 @@ export class CoCommandSearch {
257
257
  "references": {
258
258
  "CommandItem": {
259
259
  "location": "local",
260
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-command-search/co-command-search.tsx",
260
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-command-search/co-command-search.tsx",
261
261
  "id": "src/components/co-command-search/co-command-search.tsx::CommandItem"
262
262
  }
263
263
  }
@@ -509,7 +509,7 @@ export class CoDataTable {
509
509
  "references": {
510
510
  "CoDataTableColumn": {
511
511
  "location": "local",
512
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-data-table/co-data-table.tsx",
512
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-data-table/co-data-table.tsx",
513
513
  "id": "src/components/co-data-table/co-data-table.tsx::CoDataTableColumn"
514
514
  }
515
515
  }
@@ -1055,7 +1055,7 @@ export class CoDateRangePicker {
1055
1055
  "references": {
1056
1056
  "DateRangeValue": {
1057
1057
  "location": "local",
1058
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-date-range-picker/co-date-range-picker.tsx",
1058
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-date-range-picker/co-date-range-picker.tsx",
1059
1059
  "id": "src/components/co-date-range-picker/co-date-range-picker.tsx::DateRangeValue"
1060
1060
  }
1061
1061
  }
@@ -1076,7 +1076,7 @@ export class CoDateRangePicker {
1076
1076
  "references": {
1077
1077
  "DateRangeValue": {
1078
1078
  "location": "local",
1079
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-date-range-picker/co-date-range-picker.tsx",
1079
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-date-range-picker/co-date-range-picker.tsx",
1080
1080
  "id": "src/components/co-date-range-picker/co-date-range-picker.tsx::DateRangeValue"
1081
1081
  }
1082
1082
  }
@@ -1016,7 +1016,7 @@ export class CoDocumentEditor {
1016
1016
  "references": {
1017
1017
  "DocumentPageSize": {
1018
1018
  "location": "local",
1019
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-document-editor/co-document-editor.tsx",
1019
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-document-editor/co-document-editor.tsx",
1020
1020
  "id": "src/components/co-document-editor/co-document-editor.tsx::DocumentPageSize"
1021
1021
  }
1022
1022
  }
@@ -1042,7 +1042,7 @@ export class CoDocumentEditor {
1042
1042
  "references": {
1043
1043
  "DocumentMargins": {
1044
1044
  "location": "local",
1045
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-document-editor/co-document-editor.tsx",
1045
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-document-editor/co-document-editor.tsx",
1046
1046
  "id": "src/components/co-document-editor/co-document-editor.tsx::DocumentMargins"
1047
1047
  }
1048
1048
  }
@@ -1107,7 +1107,7 @@ export class CoDocumentEditor {
1107
1107
  "references": {
1108
1108
  "DocumentFeatures": {
1109
1109
  "location": "local",
1110
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-document-editor/co-document-editor.tsx",
1110
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-document-editor/co-document-editor.tsx",
1111
1111
  "id": "src/components/co-document-editor/co-document-editor.tsx::DocumentFeatures"
1112
1112
  }
1113
1113
  }
@@ -1301,7 +1301,7 @@ export class CoDocumentEditor {
1301
1301
  "references": {
1302
1302
  "DocumentHeaderDetail": {
1303
1303
  "location": "local",
1304
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-document-editor/co-document-editor.tsx",
1304
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-document-editor/co-document-editor.tsx",
1305
1305
  "id": "src/components/co-document-editor/co-document-editor.tsx::DocumentHeaderDetail"
1306
1306
  }
1307
1307
  }
@@ -1337,7 +1337,7 @@ export class CoDocumentEditor {
1337
1337
  "references": {
1338
1338
  "DocumentActionDetail": {
1339
1339
  "location": "local",
1340
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-document-editor/co-document-editor.tsx",
1340
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-document-editor/co-document-editor.tsx",
1341
1341
  "id": "src/components/co-document-editor/co-document-editor.tsx::DocumentActionDetail"
1342
1342
  }
1343
1343
  }
@@ -2,6 +2,7 @@ import { h } from "@stencil/core";
2
2
  import { afterEventFor } from "../co-overlay/overlayAfterClose";
3
3
  import { isTopEscapeLayer, pushEscapeLayer, removeEscapeLayer } from "../co-overlay/escapeLayers";
4
4
  import { slotHasContent } from "../../utils/slotContent";
5
+ import { isPopoverOpen } from "../../utils/popoverApi";
5
6
  /**
6
7
  * Panel lateral (derecha, izquierda o abajo) sobre un scrim, con header, pestañas,
7
8
  * cuerpo scrolleable y footer. Es controlado: la ✕, el scrim y Escape emiten
@@ -99,7 +100,7 @@ export class CoDrawer {
99
100
  if (!this.modeless || !aside || typeof aside.showPopover !== 'function')
100
101
  return;
101
102
  try {
102
- if (!aside.matches(':popover-open'))
103
+ if (!isPopoverOpen(aside))
103
104
  aside.showPopover();
104
105
  }
105
106
  catch (_a) {
@@ -2,6 +2,7 @@ import { h } from "@stencil/core";
2
2
  import { langFromLocale } from "../../utils/dateI18n";
3
3
  import { getLightboxStrings } from "../../utils/lightboxI18n";
4
4
  import { openMediaInTab } from "./openInTab";
5
+ import { isPopoverOpen } from "../../utils/popoverApi";
5
6
  const MIN_SCALE = 1;
6
7
  const MAX_SCALE = 8;
7
8
  const WHEEL_FACTOR = 1.15;
@@ -60,12 +61,12 @@ export class CoLightbox {
60
61
  if (this.open) {
61
62
  clearTimeout(this.demoteTimer);
62
63
  try {
63
- if (!root.matches(':popover-open'))
64
+ if (!isPopoverOpen(root))
64
65
  root.showPopover();
65
66
  }
66
67
  catch ( /* not connected yet — the ref call retries */_a) { /* not connected yet — the ref call retries */ }
67
68
  }
68
- else if (root.matches(':popover-open')) {
69
+ else if (isPopoverOpen(root)) {
69
70
  // Let the opacity fade-out run before display:none kicks in.
70
71
  clearTimeout(this.demoteTimer);
71
72
  this.demoteTimer = setTimeout(() => {
@@ -497,7 +498,7 @@ export class CoLightbox {
497
498
  const counter = s.counter
498
499
  .replace('{i}', String(this.index + 1))
499
500
  .replace('{n}', String(imgs.length));
500
- return (h("div", { key: '189314e8e6be6a3b908d2c4387e0561162a1b96e', 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: 'ee52518418ac4e58cd9bcece7bc3391cb0e9742f', class: "co-lightbox__toolbar", part: "toolbar", onClick: this.stop }, h("span", { key: 'c9e214561c3d2b7b773f82888a9147aab7d120df', class: "co-lightbox__caption", title: img.alt }, img.alt), !video && (h("div", { key: '911216d5873a1462303f1ed5b59c14d72b7328c4', class: "co-lightbox__zoom" }, h("button", { key: '9344807bbac6aefc47824b866a4225206b859323', 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: '736c42fc97c09d76cf0aa8e0763ba56eb1ecd394', name: "minus", size: 16 })), h("button", { key: 'e115084b8e4941bd0f476b248c3cc88f096c55f2', 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: 'd5955ce9dcf15f0768a1f012a11acec012805811', 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: '64126b83b5ee1a510e4787c17a77b5bfb65db721', name: "plus", size: 16 })))), h("button", { key: '1798ea6aba9c8ce425317258b076874134de4724', class: "co-lightbox__btn", type: "button", "aria-label": s.openOriginal, title: s.openOriginal, onClick: this.openOriginal }, h("co-icon", { key: 'a4ef44fe626c33b1b0eb11d38afe034ca5a13a8f', name: "arrow-square-out", size: 16 })), h("button", { key: 'c68fbb1498dcfe177d8255647c39b5db83a66f7c', 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: 'b62c1dd5fa4fba5a57b4c804e31494e5da48f0af', name: "x", size: 16 })))), img && (h("div", { key: '80d34170f27f6a0177747e797e10646dcfca0bed', class: "co-lightbox__stage", ref: (el) => (this.stageEl = el), onWheel: video ? undefined : this.handleWheel }, video ? (h("co-video", { class: "co-lightbox__video", part: "video",
501
+ return (h("div", { key: '0e6491fbe0eb9515df66d167abb555ee00d68a07', 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: '799faaab6bb3504d723732d47618d2489ff9eae4', class: "co-lightbox__toolbar", part: "toolbar", onClick: this.stop }, h("span", { key: 'a9fe7f715cb0b76c4c411514ab872f45022be9ed', class: "co-lightbox__caption", title: img.alt }, img.alt), !video && (h("div", { key: '9e0df923dd41bfaa5ed3ba28538e170529a19823', class: "co-lightbox__zoom" }, h("button", { key: 'c56a015724fe92be890e6d2681e552c303c02b0a', 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: '6b84a1dac161507d4084fba067aa1d2b4bfea5ea', name: "minus", size: 16 })), h("button", { key: '0e4747500888c3bb7a35dbe490d936de053f1a0c', 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: '52d89aa312e2eacf96072dd1f4b14f04a5966e81', 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: 'a32b55340d8027b57595c097d992de88b5cd8799', name: "plus", size: 16 })))), h("button", { key: 'f138d46223ac0db43b3ce037f323bb5f226260a9', class: "co-lightbox__btn", type: "button", "aria-label": s.openOriginal, title: s.openOriginal, onClick: this.openOriginal }, h("co-icon", { key: 'e39089e43b1178eb20bce0647c7b3f19e0c58110', name: "arrow-square-out", size: 16 })), h("button", { key: 'c52ebe7347d11c0c1416978002cc2b67ffc94a25', 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: 'bb3e0aac0dfa10c8b5de5cb54bd7601a8ae66dec', name: "x", size: 16 })))), img && (h("div", { key: '3597bd31e1b65efbb2c02cb55dbacf0ec43d7639', class: "co-lightbox__stage", ref: (el) => (this.stageEl = el), onWheel: video ? undefined : this.handleWheel }, video ? (h("co-video", { class: "co-lightbox__video", part: "video",
501
502
  /* Keyed per slide: a fresh player is the only way to be sure
502
503
  poster, error state and playback all start clean. */
503
504
  key: `video-${this.index}`, ref: this.mountPlayer, src: img.src, poster: img.poster || '', aspectRatio: "auto", rounded: "none",
@@ -507,13 +508,13 @@ export class CoLightbox {
507
508
  'co-lightbox__img': true,
508
509
  'co-lightbox__img--zoomed': this.scale > MIN_SCALE,
509
510
  'co-lightbox__img--dragging': this.dragging,
510
- }, 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: '4ef78cd047f1e8b2efb669aefbee51b73e4c5c3b', class: "co-lightbox__nav co-lightbox__nav--prev", part: "prev", type: "button", "aria-label": s.prevImage, title: s.prevImage, onClick: (e) => {
511
+ }, 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: '5185685a016df10825bd2ddd4479c074ab88b9e4', class: "co-lightbox__nav co-lightbox__nav--prev", part: "prev", type: "button", "aria-label": s.prevImage, title: s.prevImage, onClick: (e) => {
511
512
  e.stopPropagation();
512
513
  this.goTo(-1);
513
- } }, h("co-icon", { key: '834bd12a0dead46df44e291197f5d3b79f619932', name: "caret-left", size: 24 }))), img && multi && (h("button", { key: '0252acb36e360dedd1fe8ac8cba74ab5895476c1', class: "co-lightbox__nav co-lightbox__nav--next", part: "next", type: "button", "aria-label": s.nextImage, title: s.nextImage, onClick: (e) => {
514
+ } }, h("co-icon", { key: 'ff3d9a5e57dc9e74ef29c9ee8696040f46a295f2', name: "caret-left", size: 24 }))), img && multi && (h("button", { key: '33eaec6709a4f22490ff56c93a32de332c6adc65', class: "co-lightbox__nav co-lightbox__nav--next", part: "next", type: "button", "aria-label": s.nextImage, title: s.nextImage, onClick: (e) => {
514
515
  e.stopPropagation();
515
516
  this.goTo(1);
516
- } }, h("co-icon", { key: '53521495d2bd6ac11004cedd96fd7351135115a7', name: "caret-right", size: 24 }))), img && multi && (h("div", { key: 'fae75527e79964a30745accf565b33be3b466ba6', class: "co-lightbox__counter", part: "counter", onClick: this.stop }, counter))));
517
+ } }, h("co-icon", { key: '1631e46b4d05c2f1495842adb2a6e524dc67b47d', name: "caret-right", size: 24 }))), img && multi && (h("div", { key: 'cf751691f9dffb1325c9a5183b1cca2c01bd28c4', class: "co-lightbox__counter", part: "counter", onClick: this.stop }, counter))));
517
518
  }
518
519
  static get is() { return "co-lightbox"; }
519
520
  static get encapsulation() { return "shadow"; }
@@ -2,6 +2,7 @@ import { h } from "@stencil/core";
2
2
  import { afterEventFor } from "./overlayAfterClose";
3
3
  import { isBackdropDismiss } from "./backdropDismiss";
4
4
  import { getComposedFocusables, isTopTrap, resolveInitialFocus, resolveTabIndex } from "./focusTrap";
5
+ import { isPopoverOpen } from "../../utils/popoverApi";
5
6
  /**
6
7
  * Module-level body-scroll lock shared by every overlay instance.
7
8
  * Ref-counted so stacked/nested overlays (e.g. a modal opened from a drawer)
@@ -157,7 +158,7 @@ export class CoOverlay {
157
158
  const el = this.overlayEl;
158
159
  if (!this.open || !el || typeof el.showPopover !== 'function')
159
160
  return;
160
- if (!el.matches(':popover-open'))
161
+ if (!isPopoverOpen(el))
161
162
  return;
162
163
  const active = this.deepActiveElement();
163
164
  el.classList.add(REFRONT_CLASS);
@@ -198,7 +199,7 @@ export class CoOverlay {
198
199
  if (!el || typeof el.showPopover !== 'function')
199
200
  return;
200
201
  try {
201
- const isShown = el.matches(':popover-open');
202
+ const isShown = isPopoverOpen(el);
202
203
  if (this.open && !isShown)
203
204
  el.showPopover();
204
205
  else if (!this.open && isShown)
@@ -298,7 +299,7 @@ export class CoOverlay {
298
299
  focusables[nextIndex].focus();
299
300
  }
300
301
  render() {
301
- return (h("div", { key: '9d6cec0764074a33489f79fb4a554e7aa7374785', class: { 'co-overlay': true, 'co-overlay--open': this.open }, part: "overlay", popover: "manual", tabindex: this.trapFocus ? -1 : undefined, ref: (el) => (this.overlayEl = el), onPointerDown: this.handlePointerDown, onPointerUp: this.handlePointerUp, onClick: this.handleClick, onTransitionEnd: this.handleTransitionEnd }, h("slot", { key: '2f8ad7b23e72ce2f5c74b3cb67ba9ab80e88cf26' })));
302
+ return (h("div", { key: '419d44027ef0e270aa9bddccc83bf3e93e1e78db', class: { 'co-overlay': true, 'co-overlay--open': this.open }, part: "overlay", popover: "manual", tabindex: this.trapFocus ? -1 : undefined, ref: (el) => (this.overlayEl = el), onPointerDown: this.handlePointerDown, onPointerUp: this.handlePointerUp, onClick: this.handleClick, onTransitionEnd: this.handleTransitionEnd }, h("slot", { key: '34ffc7586b41bced7d7f56b6189f654c1c5e1a7f' })));
302
303
  }
303
304
  static get is() { return "co-overlay"; }
304
305
  static get encapsulation() { return "shadow"; }
@@ -1,6 +1,7 @@
1
1
  import { h } from "@stencil/core";
2
2
  import { computePosition, findScrollParents, getOffsetAncestor, isAnchorVisible } from "../../utils/positioning";
3
3
  import { pushLayer, removeLayer, isTopLayer } from "../../utils/popover-stack";
4
+ import { isPopoverOpen } from "../../utils/popoverApi";
4
5
  /** Side classes driving the entrance `transform-origin` (see co-popover.css). */
5
6
  const SIDE_CLASSES = ['top', 'bottom', 'left', 'right'].map((s) => `co-popover__panel--${s}`);
6
7
  /**
@@ -190,7 +191,7 @@ export class CoPopover {
190
191
  // resolves against the viewport regardless of any transformed/filtered
191
192
  // ancestor — so skip the offset-ancestor compensation. It only applies in
192
193
  // the no-Popover-API fallback where the panel still renders in place.
193
- const promoted = this.panelEl.matches(':popover-open');
194
+ const promoted = isPopoverOpen(this.panelEl);
194
195
  if (!promoted) {
195
196
  if (!this.offsetAncestorComputed) {
196
197
  this.cachedOffsetAncestor = getOffsetAncestor(this.panelEl);
@@ -366,7 +367,7 @@ export class CoPopover {
366
367
  if (!el || typeof el.showPopover !== 'function')
367
368
  return;
368
369
  try {
369
- if (!el.matches(':popover-open'))
370
+ if (!isPopoverOpen(el))
370
371
  el.showPopover();
371
372
  }
372
373
  catch (_a) {
@@ -424,13 +425,13 @@ export class CoPopover {
424
425
  }
425
426
  // ── Render ─────────────────────────────────────────────────
426
427
  render() {
427
- return (h("div", { key: 'a85df32be71c08c86bd19a31224b51b899d1f468', class: "co-popover" }, h("div", { key: 'accafae8513bad7bfbf32b7e98f0dc6ec0968efa', class: "co-popover__trigger", ref: (el) => (this.triggerEl = el), onClick: this.handleTriggerClick }, h("slot", { key: 'f12247af31066f6d4cbdd45671146b3ea5c996bc', name: "trigger" })), (this.open || this.closing) && (h("div", { key: '64dbc77cae4a913bbe3ec4174f6b18c4982520ae', class: { 'co-popover__panel': true, 'co-popover__panel--closing': this.closing }, part: "panel", popover: "manual", onTransitionEnd: this.handlePanelTransitionEnd, ref: (el) => {
428
+ return (h("div", { key: '36563fc43d535139e1dcacf5c10f7d94ac7c3c56', class: "co-popover" }, h("div", { key: 'b89ff545f53702c42e95058449644af4336c7b8e', class: "co-popover__trigger", ref: (el) => (this.triggerEl = el), onClick: this.handleTriggerClick }, h("slot", { key: 'aacbf2fbf099af3402d2a09d2f003893ed01b6da', name: "trigger" })), (this.open || this.closing) && (h("div", { key: '571d316922717803b4645e66302068f8081e8d36', class: { 'co-popover__panel': true, 'co-popover__panel--closing': this.closing }, part: "panel", popover: "manual", onTransitionEnd: this.handlePanelTransitionEnd, ref: (el) => {
428
429
  if (el && el !== this.panelEl) {
429
430
  this.panelEl = el;
430
431
  this.promotePanel();
431
432
  this.scheduleUpdate();
432
433
  }
433
- } }, h("slot", { key: '858df49b45b1bd72f215f5e408e835227633d41f' })))));
434
+ } }, h("slot", { key: 'cd42d52c6bbdf2522ce692b75ba556da35c8a5b9' })))));
434
435
  }
435
436
  static get is() { return "co-popover"; }
436
437
  static get encapsulation() { return "shadow"; }
@@ -475,7 +476,7 @@ export class CoPopover {
475
476
  "references": {
476
477
  "PopoverPlacement": {
477
478
  "location": "local",
478
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-popover/co-popover.tsx",
479
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-popover/co-popover.tsx",
479
480
  "id": "src/components/co-popover/co-popover.tsx::PopoverPlacement"
480
481
  }
481
482
  }
@@ -224,7 +224,7 @@ export class CoRadioGroup {
224
224
  "references": {
225
225
  "RadioOption": {
226
226
  "location": "local",
227
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-radio-group/co-radio-group.tsx",
227
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-radio-group/co-radio-group.tsx",
228
228
  "id": "src/components/co-radio-group/co-radio-group.tsx::RadioOption"
229
229
  }
230
230
  }
@@ -1356,7 +1356,7 @@ export class CoRefField {
1356
1356
  "references": {
1357
1357
  "RefFieldOption": {
1358
1358
  "location": "local",
1359
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-ref-field/co-ref-field.tsx",
1359
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-ref-field/co-ref-field.tsx",
1360
1360
  "id": "src/components/co-ref-field/co-ref-field.tsx::RefFieldOption"
1361
1361
  }
1362
1362
  }
@@ -1497,7 +1497,7 @@ export class CoRefField {
1497
1497
  "references": {
1498
1498
  "RefFieldOption": {
1499
1499
  "location": "local",
1500
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-ref-field/co-ref-field.tsx",
1500
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-ref-field/co-ref-field.tsx",
1501
1501
  "id": "src/components/co-ref-field/co-ref-field.tsx::RefFieldOption"
1502
1502
  }
1503
1503
  }
@@ -1518,7 +1518,7 @@ export class CoRefField {
1518
1518
  "references": {
1519
1519
  "RefFieldOption": {
1520
1520
  "location": "local",
1521
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-ref-field/co-ref-field.tsx",
1521
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-ref-field/co-ref-field.tsx",
1522
1522
  "id": "src/components/co-ref-field/co-ref-field.tsx::RefFieldOption"
1523
1523
  }
1524
1524
  }
@@ -1557,7 +1557,7 @@ export class CoRefField {
1557
1557
  },
1558
1558
  "RefFieldOption": {
1559
1559
  "location": "local",
1560
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-ref-field/co-ref-field.tsx",
1560
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-ref-field/co-ref-field.tsx",
1561
1561
  "id": "src/components/co-ref-field/co-ref-field.tsx::RefFieldOption"
1562
1562
  }
1563
1563
  },
@@ -160,7 +160,7 @@ export class CoSegmentedBar {
160
160
  "references": {
161
161
  "CoSegment": {
162
162
  "location": "local",
163
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-segmented-bar/co-segmented-bar.tsx",
163
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-segmented-bar/co-segmented-bar.tsx",
164
164
  "id": "src/components/co-segmented-bar/co-segmented-bar.tsx::CoSegment"
165
165
  }
166
166
  }
@@ -848,7 +848,7 @@ export class CoSelect {
848
848
  "references": {
849
849
  "SelectOption": {
850
850
  "location": "local",
851
- "path": "/Users/agox/Documents/Prolibu/prolibu-cobalt/packages/core/src/components/co-select/co-select.tsx",
851
+ "path": "/Users/agox/worktrees/cobalt-sidebar-icons/packages/core/src/components/co-select/co-select.tsx",
852
852
  "id": "src/components/co-select/co-select.tsx::SelectOption"
853
853
  }
854
854
  }