@orangelogic/design-system 4.59.0 → 4.60.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/library/chunks/{asset-link-format.zO0t0oA3.js → asset-link-format.dG974FMS.js} +1 -1
- package/library/chunks/{bicolor-picker.DZY5PP24.js → bicolor-picker.ePTFxpv-.js} +1 -1
- package/library/chunks/{block-width.Dbc3rT3Y.js → block-width.DN6TdcDq.js} +19 -19
- package/library/chunks/{border-input-group.BymzNWba.js → border-input-group.B-GD9YGF.js} +1 -1
- package/library/chunks/{color-picker.Ch5-Ylm8.js → color-picker.DzBT5QXr.js} +3 -3
- package/library/chunks/{color-swatch-group.Bcw5aIqG.js → color-swatch-group.CCMYA-co.js} +6 -6
- package/library/chunks/{config-manager.BfkCA0F3.js → config-manager.ijFjACzv.js} +16 -16
- package/library/chunks/{configs-controller.uTcM4iX4.js → configs-controller.US9PZfsX.js} +4 -4
- package/library/chunks/{confirm-popover.DUrgLQjC.js → confirm-popover.C2X0sUMv.js} +2 -2
- package/library/chunks/{corner-position-input-group.mrOiz-0k.js → corner-position-input-group.B1SMOWGF.js} +1 -1
- package/library/chunks/{dialog.BcCTa8Bd.js → dialog.CPvHVWDJ.js} +421 -416
- package/library/chunks/{document-viewer.Ch5h5Wte.js → document-viewer.DmXykwuU.js} +3 -3
- package/library/chunks/{dropdown.DDQXJMth.js → dropdown.B4vsoK98.js} +1 -1
- package/library/chunks/{dynamic-select.Dwcz7UjN.js → dynamic-select.BHCgqRwF.js} +1 -1
- package/library/chunks/{file-on-demand.BmRBmyyq.js → file-on-demand.C2qiTIH9.js} +4 -4
- package/library/chunks/{folder-select.Buoz3ioX.js → folder-select.Cf2KaF54.js} +1 -1
- package/library/chunks/{menu-item.CtFgeM0H.js → menu-item.SGtyl6pY.js} +24 -5
- package/library/chunks/{menu.BEVPnl3Y.js → menu.69SdPYy6.js} +2 -2
- package/library/chunks/{pagination.DULLxssA.js → pagination.B6alBgDy.js} +1 -1
- package/library/chunks/{select.S9rnkI_b.js → select.D_899gsk.js} +50 -38
- package/library/chunks/{shadow-input-group.B_W5gJ4u.js → shadow-input-group.DG3s_mso.js} +1 -1
- package/library/chunks/{size-input-group.DUyTc5na.js → size-input-group.Df-P7xql.js} +1 -1
- package/library/chunks/{src.D0Zj6Eo1.js → src.CBMYFQxL.js} +9 -9
- package/library/chunks/{tab-group.kyiPblS9.js → tab-group.FZnVZRnT.js} +3 -3
- package/library/components/asset-link-format.js +1 -1
- package/library/components/atoms.js +10 -10
- package/library/components/bicolor-picker.js +1 -1
- package/library/components/border-input-group.js +1 -1
- package/library/components/color-picker.js +1 -1
- package/library/components/color-swatch-group.js +1 -1
- package/library/components/confirm-popover.js +1 -1
- package/library/components/corner-position-input-group.js +1 -1
- package/library/components/dialog.js +1 -1
- package/library/components/document-viewer.js +1 -1
- package/library/components/dropdown.js +1 -1
- package/library/components/dynamic-select.js +1 -1
- package/library/components/file-on-demand.js +1 -1
- package/library/components/folder-select.js +1 -1
- package/library/components/menu-item.js +1 -1
- package/library/components/menu.js +1 -1
- package/library/components/molecules.js +8 -8
- package/library/components/organisms.js +3 -3
- package/library/components/pagination.js +1 -1
- package/library/components/select.js +1 -1
- package/library/components/shadow-input-group.js +1 -1
- package/library/components/size-input-group.js +1 -1
- package/library/components/tab-group.js +1 -1
- package/library/components/types.js +24 -24
- package/library/package.json +1 -1
- package/library/packages/atoms/src/components/dialog/dialog.d.ts +15 -4
- package/library/packages/atoms/src/components/menu/menu.d.ts +1 -0
- package/library/packages/atoms/src/components/menu-item/menu-item.d.ts +4 -1
- package/library/packages/atoms/src/components/menu-item/submenu-controller.d.ts +9 -0
- package/library/packages/atoms/src/components/select/select.d.ts +12 -1
- package/library/packages/types/src/dialog.d.ts +9 -0
- package/library/react-web-component.d.ts +5 -1
- package/package.json +1 -1
|
@@ -17,11 +17,11 @@ import { t as resize_observer_default } from "./resize-observer.D9EHlnZI.js";
|
|
|
17
17
|
import { t as tooltip_default } from "./tooltip.Cc02vm6M.js";
|
|
18
18
|
import { a as ObjectFit } from "./src.BJhIYoMP.js";
|
|
19
19
|
import { t as typography_default } from "./typography.B0mkhqTB.js";
|
|
20
|
-
import { t as dropdown_default } from "./dropdown.
|
|
20
|
+
import { t as dropdown_default } from "./dropdown.B4vsoK98.js";
|
|
21
21
|
import { t as focusWhenVisible } from "./focus-when-visible.DKscgyKo.js";
|
|
22
22
|
import { t as input_default } from "./input.kTjqEyC8.js";
|
|
23
|
-
import { t as menu_default } from "./menu.
|
|
24
|
-
import { t as menu_item_default } from "./menu-item.
|
|
23
|
+
import { t as menu_default } from "./menu.69SdPYy6.js";
|
|
24
|
+
import { t as menu_item_default } from "./menu-item.SGtyl6pY.js";
|
|
25
25
|
import { X as fetchCortexApi } from "./src.Dia365C9.js";
|
|
26
26
|
import { t as drawer_default } from "./drawer.CLSdjLR9.js";
|
|
27
27
|
import { t as progress_bar_default } from "./progress-bar.CynVLLnY.js";
|
|
@@ -15,7 +15,7 @@ import { t as b } from "./active-elements.Tk45XSNQ.js";
|
|
|
15
15
|
import { t as x } from "./focus-when-visible.DKscgyKo.js";
|
|
16
16
|
import { t as S } from "./tabbable.BSwpOHdm.js";
|
|
17
17
|
import { t as C } from "./input.kTjqEyC8.js";
|
|
18
|
-
import { t as w } from "./menu.
|
|
18
|
+
import { t as w } from "./menu.69SdPYy6.js";
|
|
19
19
|
import { t as T } from "./textarea.CHSZI8vt.js";
|
|
20
20
|
//#region ../../packages/utils/src/custom-element/escapable-overlays.ts
|
|
21
21
|
var E = [], D = class {
|
|
@@ -13,7 +13,7 @@ import { t as h } from "./debounce.Ci-xdsHE.js";
|
|
|
13
13
|
import { t as g } from "./button.BjijpxeK.js";
|
|
14
14
|
import { t as _ } from "./repeat.CKv9FPlC.js";
|
|
15
15
|
import { n as v, t as y } from "./option.DWE0tark.js";
|
|
16
|
-
import { t as b } from "./select.
|
|
16
|
+
import { t as b } from "./select.D_899gsk.js";
|
|
17
17
|
import { t as x } from "./map.ByDuLduF.js";
|
|
18
18
|
import { t as S } from "./keyed.zYwdaCfO.js";
|
|
19
19
|
import { t as C } from "./_baseIteratee.DWc2-Bvm.js";
|
|
@@ -23,18 +23,18 @@ import { t as w } from "./repeat.CKv9FPlC.js";
|
|
|
23
23
|
import { t as ae } from "./input.kTjqEyC8.js";
|
|
24
24
|
import { t as oe } from "./option.DWE0tark.js";
|
|
25
25
|
import { t as se } from "./space.Dd8jezXK.js";
|
|
26
|
-
import { t as ce } from "./select.
|
|
26
|
+
import { t as ce } from "./select.D_899gsk.js";
|
|
27
27
|
import { t as le } from "./tab.Cv-UuYM5.js";
|
|
28
|
-
import { t as T } from "./tab-group.
|
|
28
|
+
import { t as T } from "./tab-group.FZnVZRnT.js";
|
|
29
29
|
import { t as ue } from "./tab-panel.BxeoKuSv.js";
|
|
30
|
-
import { t as E } from "./dialog.
|
|
30
|
+
import { t as E } from "./dialog.CPvHVWDJ.js";
|
|
31
31
|
import { t as de } from "./divider.CqSNZCU8.js";
|
|
32
32
|
import { t as fe } from "./progress-bar.CynVLLnY.js";
|
|
33
33
|
import { o as D, u as O } from "./url.BCc06dE7.js";
|
|
34
34
|
import k from "../components/format-bytes.js";
|
|
35
35
|
import { t as pe } from "./relative-time.BfE3UOhF.js";
|
|
36
36
|
import { a as A, i as me, n as he, t as j } from "./tree.XYIP-Ujw.js";
|
|
37
|
-
import { t as ge } from "./confirm-popover.
|
|
37
|
+
import { t as ge } from "./confirm-popover.C2X0sUMv.js";
|
|
38
38
|
import { t as _e } from "./_baseIteratee.DWc2-Bvm.js";
|
|
39
39
|
import { t as ve } from "./choose.C2vpqhLc.js";
|
|
40
40
|
import { t as ye } from "./_baseXor.Ca5K0ORC.js";
|
|
@@ -18,7 +18,7 @@ import { t as C } from "./tag.Cq8m5pRP.js";
|
|
|
18
18
|
import { t as w } from "./repeat.CKv9FPlC.js";
|
|
19
19
|
import { t as T } from "./input.kTjqEyC8.js";
|
|
20
20
|
import { t as E } from "./space.Dd8jezXK.js";
|
|
21
|
-
import { t as D } from "./select.
|
|
21
|
+
import { t as D } from "./select.D_899gsk.js";
|
|
22
22
|
import { t as O } from "./template.Cyvih0XQ.js";
|
|
23
23
|
import { s as k } from "./asset-link-format.COPyGdND.js";
|
|
24
24
|
import { a as A, i as j } from "./tree.XYIP-Ujw.js";
|
|
@@ -21,8 +21,9 @@ var C = /* @__PURE__ */ function(e) {
|
|
|
21
21
|
}({}), T = /* @__PURE__ */ function(e) {
|
|
22
22
|
return e.Checkbox = "checkbox", e.Normal = "normal", e.Selectable = "selectable", e;
|
|
23
23
|
}({}), E = /* @__PURE__ */ new Set(["checkbox", "selectable"]), D = t`:host{--submenu-offset:0px;--prefix-font-size:var(--cx-font-size-small);--prefix-color:var(--cx-color-neutral-500);--label-color:var(--cx-color-neutral);--suffix-color:var(--cx-color-neutral);--font-weight:var(--cx-font-weight-medium);display:block}:host([inert]){display:none}.menu-item{font:var(--cx-font-label-small);font-weight:var(--font-weight,var(--cx-font-weight-medium));letter-spacing:var(--cx-letter-spacing-normal);color:var(--cx-color-neutral);padding:var(--cx-spacing-x-small) var(--cx-spacing-small);transition:var(--cx-transition-fast) fill;background-color:var(--cx-menu-item-background-color,unset);-webkit-user-select:none;user-select:none;white-space:nowrap;cursor:pointer;align-items:stretch;text-decoration:none;display:flex;position:relative}.menu-item.menu-item--disabled{cursor:default;outline:none}.menu-item.menu-item--disabled .menu-item__label,.menu-item.menu-item--disabled .menu-item__prefix,.menu-item.menu-item--disabled .menu-item__chevron,.menu-item.menu-item--disabled .menu-item__check{opacity:.5}.menu-item.menu-item--disabled .menu-item__suffix:not(:slotted(cx-tooltip)){opacity:.5}.menu-item.menu-item--loading{cursor:wait;outline:none}.menu-item.menu-item--loading :not(cx-spinner){opacity:.5}.menu-item--loading cx-spinner{--indicator-color:currentColor;--track-width:1px;opacity:1;font-size:.75em;position:absolute;top:calc(50% - .5em);left:.65rem}.menu-item .menu-item__label{color:var(--label-color,var(--cx-color-neutral));text-overflow:ellipsis;flex:auto;margin:auto;display:inline-block;overflow:hidden}.menu-item--checked .menu-item__label{color:var(--checked-label-color,var(--cx-color-primary))}.menu-item .menu-item__prefix{color:var(--prefix-color,var(--cx-color-neutral-500));font-size:var(--prefix-font-size,var(--cx-font-size-small));flex:none;align-items:center;display:flex}.menu-item--checked{--prefix-color:var(--cx-color-primary);--suffix-color:var(--cx-color-primary)}.menu-item--checked .menu-item__check{color:var(--checked-icon-color,var(--cx-color-primary))}.menu-item .menu-item__prefix::slotted(*){margin-inline-end:var(--cx-spacing-x-small)}.menu-item .menu-item__suffix{color:var(--suffix-color);flex:none;align-items:center;display:flex}.menu-item .menu-item__suffix::slotted(*){margin-inline-start:var(--cx-spacing-medium)}.menu-item--submenu-expanded:after{content:"";z-index:calc(var(--cx-z-index-dropdown) - 1);clip-path:polygon(var(--safe-triangle-cursor-x,0) var(--safe-triangle-cursor-y,0), var(--safe-triangle-submenu-start-x,0) var(--safe-triangle-submenu-start-y,0), var(--safe-triangle-submenu-end-x,0) var(--safe-triangle-submenu-end-y,0));position:fixed;inset:0}@media (pointer:none),(pointer:coarse){.menu-item--submenu-expanded:after{display:none}}:host(:focus-visible){outline:none}:host(:hover:not([aria-disabled=true],:focus-visible,.disable-hover)) .menu-item,.menu-item--submenu-expanded{background-color:var(--cx-menu-item-background-color-hover);color:var(--cx-color-neutral-1000)}:host(:not([aria-disabled=true])) .menu-item--active{background-color:var(--cx-menu-item-background-color-active,var(--cx-menu-item-background-color-hover));color:var(--cx-color-neutral-1000)}:host(:hover:not([aria-disabled=true],:focus-visible,.disable-hover)) .menu-item--active{background-color:var(--cx-menu-item-background-color-active-hover,var(--cx-menu-item-background-color-active,var(--cx-menu-item-background-color-hover)))}:host(:focus-visible) .menu-item{outline:var(--cx-focus-ring);outline-offset:calc(-1 * var(--cx-focus-ring-width));background-color:var(--cx-menu-item-background-color-hover);opacity:1}.menu-item .menu-item__check,.menu-item .menu-item__chevron{width:var(--checked-icon-size,1.5em);visibility:hidden;flex:none;justify-content:center;align-items:center}.menu-item .menu-item__check{display:var(--checked-icon-display,flex);margin-inline-end:var(--cx-spacing-2x-small)}.menu-item .menu-item__check--suffix{margin-inline:auto 0;padding-inline-start:var(--cx-spacing-2x-small)}.menu-item .menu-item__check--always-show{visibility:visible}.menu-item .menu-item__chevron{display:var(--submenu-icon-display,flex)}.menu-item--checked .menu-item__check,.menu-item--has-submenu .menu-item__chevron{visibility:visible}cx-popup::part(popup){border:var(--cx-panel-border-width) solid var(--cx-popup-border-color);border-radius:var(--cx-border-radius-large);box-shadow:var(--cx-shadow-large);z-index:var(--cx-z-index-dropdown);margin-left:var(--submenu-offset,0px);overflow:hidden}.menu-item--rtl cx-popup::part(popup){margin-left:calc(-1 * var(--submenu-offset))}@media (forced-colors:active){:host(:hover:not([aria-disabled=true])) .menu-item,:host(:focus-visible) .menu-item{outline-offset:-1px;outline:1px dashed selecteditem}}::slotted(cx-menu){max-width:var(--auto-size-available-width)!important;max-height:var(--auto-size-available-height)!important}`, O = class {
|
|
24
|
+
#e;
|
|
24
25
|
constructor(e, t) {
|
|
25
|
-
this.popupRef = S(), this.parent = null, this.enableSubmenuTimer = -1, this.isHorizontalMenu = !1, this.isConnected = !1, this.isPopupConnected = !1, this.skidding = 0, this.submenuOpenDelay = 100, this.focusVisibilityTimeoutMs = 1e4, this.lazyLoadObserver = null, this.pendingFocusCancel = null, (this.host = e).addController(this), this.hasSlotController = t, this.handleMouseMove = this.handleMouseMove.bind(this), this.handleMouseOver = this.handleMouseOver.bind(this), this.handleKeyDown = this.handleKeyDown.bind(this), this.handleClick = this.handleClick.bind(this), this.handleSubmenuIconClick = this.handleSubmenuIconClick.bind(this), this.handleDocumentMouseDown = this.handleDocumentMouseDown.bind(this), this.handleMouseLeave = this.handleMouseLeave.bind(this), this.handlePopupMouseover = this.handlePopupMouseover.bind(this), this.handlePopupReposition = this.handlePopupReposition.bind(this);
|
|
26
|
+
this.popupRef = S(), this.parent = null, this.enableSubmenuTimer = -1, this.#e = "", this.isHorizontalMenu = !1, this.isConnected = !1, this.isPopupConnected = !1, this.skidding = 0, this.submenuOpenDelay = 100, this.focusVisibilityTimeoutMs = 1e4, this.lazyLoadObserver = null, this.pendingFocusCancel = null, (this.host = e).addController(this), this.hasSlotController = t, this.handleMouseMove = this.handleMouseMove.bind(this), this.handleMouseOver = this.handleMouseOver.bind(this), this.handleKeyDown = this.handleKeyDown.bind(this), this.handlePointerDown = this.handlePointerDown.bind(this), this.handlePointerCancel = this.handlePointerCancel.bind(this), this.handleDocumentPointerUp = this.handleDocumentPointerUp.bind(this), this.handleClick = this.handleClick.bind(this), this.handleSubmenuIconClick = this.handleSubmenuIconClick.bind(this), this.handleDocumentMouseDown = this.handleDocumentMouseDown.bind(this), this.handleMouseLeave = this.handleMouseLeave.bind(this), this.handlePopupMouseover = this.handlePopupMouseover.bind(this), this.handlePopupReposition = this.handlePopupReposition.bind(this);
|
|
26
27
|
}
|
|
27
28
|
get popup() {
|
|
28
29
|
return this.popupRef.value;
|
|
@@ -42,10 +43,10 @@ var C = /* @__PURE__ */ function(e) {
|
|
|
42
43
|
this.host.setAttribute("aria-expanded", this.isExpanded() ? "true" : "false");
|
|
43
44
|
}
|
|
44
45
|
addListeners() {
|
|
45
|
-
this.isConnected ||= (this.host.addEventListener("mousemove", this.handleMouseMove), (this.host.submenuTrigger === "both" || this.host.submenuTrigger === "hover") && (this.host.addEventListener("mouseover", this.handleMouseOver), this.host.addEventListener("mouseleave", this.handleMouseLeave)), (this.host.submenuTrigger === "both" || this.host.submenuTrigger === "click") && (this.host.addEventListener("click", this.handleClick), this.host.submenuIcon?.addEventListener("click", this.handleSubmenuIconClick), document.addEventListener("mousedown", this.handleDocumentMouseDown)), this.host.addEventListener("keydown", this.handleKeyDown), !0), this.isPopupConnected || this.popupRef.value && (this.popupRef.value.addEventListener("mouseover", this.handlePopupMouseover), this.popupRef.value.addEventListener("cx-reposition", this.handlePopupReposition), this.isPopupConnected = !0);
|
|
46
|
+
this.isConnected ||= (this.host.addEventListener("mousemove", this.handleMouseMove), (this.host.submenuTrigger === "both" || this.host.submenuTrigger === "hover") && (this.host.addEventListener("mouseover", this.handleMouseOver), this.host.addEventListener("mouseleave", this.handleMouseLeave)), (this.host.submenuTrigger === "both" || this.host.submenuTrigger === "click") && (this.host.addEventListener("pointerdown", this.handlePointerDown), this.host.addEventListener("pointercancel", this.handlePointerCancel), document.addEventListener("pointerup", this.handleDocumentPointerUp), this.host.addEventListener("click", this.handleClick), this.host.submenuIcon?.addEventListener("click", this.handleSubmenuIconClick), document.addEventListener("mousedown", this.handleDocumentMouseDown)), this.host.addEventListener("keydown", this.handleKeyDown), !0), this.isPopupConnected || this.popupRef.value && (this.popupRef.value.addEventListener("mouseover", this.handlePopupMouseover), this.popupRef.value.addEventListener("cx-reposition", this.handlePopupReposition), this.isPopupConnected = !0);
|
|
46
47
|
}
|
|
47
48
|
removeListeners() {
|
|
48
|
-
this.isConnected &&= (this.host.removeEventListener("mousemove", this.handleMouseMove), this.host.removeEventListener("mouseover", this.handleMouseOver), this.host.removeEventListener("mouseleave", this.handleMouseLeave), this.host.removeEventListener("click", this.handleClick), this.host.submenuIcon?.removeEventListener("click", this.handleSubmenuIconClick), document.removeEventListener("mousedown", this.handleDocumentMouseDown), this.host.removeEventListener("keydown", this.handleKeyDown), !1), this.isPopupConnected && this.popupRef.value && (this.popupRef.value.removeEventListener("mouseover", this.handlePopupMouseover), this.popupRef.value.removeEventListener("cx-reposition", this.handlePopupReposition), this.isPopupConnected = !1);
|
|
49
|
+
this.isConnected &&= (this.host.removeEventListener("mousemove", this.handleMouseMove), this.host.removeEventListener("mouseover", this.handleMouseOver), this.host.removeEventListener("mouseleave", this.handleMouseLeave), this.host.removeEventListener("pointerdown", this.handlePointerDown), this.host.removeEventListener("pointercancel", this.handlePointerCancel), document.removeEventListener("pointerup", this.handleDocumentPointerUp), this.host.removeEventListener("click", this.handleClick), this.host.submenuIcon?.removeEventListener("click", this.handleSubmenuIconClick), document.removeEventListener("mousedown", this.handleDocumentMouseDown), this.host.removeEventListener("keydown", this.handleKeyDown), !1), this.isPopupConnected && this.popupRef.value && (this.popupRef.value.removeEventListener("mouseover", this.handlePopupMouseover), this.popupRef.value.removeEventListener("cx-reposition", this.handlePopupReposition), this.isPopupConnected = !1);
|
|
49
50
|
}
|
|
50
51
|
syncIsHorizontalMenu() {
|
|
51
52
|
this.parent && (this.isHorizontalMenu = this.parent.hasAttribute("horizontal"));
|
|
@@ -120,11 +121,29 @@ var C = /* @__PURE__ */ function(e) {
|
|
|
120
121
|
case " ": this.host.href || this.handleSubmenuEntry(e);
|
|
121
122
|
}
|
|
122
123
|
}
|
|
124
|
+
handlePointerDown(e) {
|
|
125
|
+
this.#e = e.pointerType;
|
|
126
|
+
}
|
|
127
|
+
handlePointerCancel() {
|
|
128
|
+
this.#e = "";
|
|
129
|
+
}
|
|
130
|
+
handleDocumentPointerUp(e) {
|
|
131
|
+
e.composedPath().includes(this.host) || (this.#e = "");
|
|
132
|
+
}
|
|
123
133
|
handleClick(e) {
|
|
124
|
-
|
|
134
|
+
let t = this.#t();
|
|
135
|
+
e.target !== this.host && e.target instanceof Element && (e.target.localName === "cx-menu-item" || e.target.role?.startsWith("menuitem")) || (e.preventDefault(), e.stopPropagation(), this.isExpanded() ? this.#n(t) || this.disableSubmenu() : e.isTrusted && this.enableSubmenu());
|
|
125
136
|
}
|
|
126
137
|
handleSubmenuIconClick(e) {
|
|
127
|
-
|
|
138
|
+
let t = this.#t();
|
|
139
|
+
e.preventDefault(), e.stopPropagation(), this.isExpanded() ? this.#n(t) || this.disableSubmenu() : this.enableSubmenu();
|
|
140
|
+
}
|
|
141
|
+
#t() {
|
|
142
|
+
let e = this.#e;
|
|
143
|
+
return this.#e = "", e;
|
|
144
|
+
}
|
|
145
|
+
#n(e) {
|
|
146
|
+
return this.host.submenuTrigger === "both" && e === "mouse";
|
|
128
147
|
}
|
|
129
148
|
handleDocumentMouseDown(e) {
|
|
130
149
|
let t = e.composedPath();
|
|
@@ -5,11 +5,11 @@ import { t as c } from "./component.styles.0xM1ZmBs.js";
|
|
|
5
5
|
import { t as l } from "./custom-element.BEMYNDK1.js";
|
|
6
6
|
import { t as u } from "./i18n.Bjg2ubA4.js";
|
|
7
7
|
import { t as d } from "./when.BUskJLtZ.js";
|
|
8
|
-
import { r as f, t as p } from "./menu-item.
|
|
8
|
+
import { r as f, t as p } from "./menu-item.SGtyl6pY.js";
|
|
9
9
|
//#region ../../packages/types/src/menu.ts
|
|
10
10
|
var m = /* @__PURE__ */ function(e) {
|
|
11
11
|
return e.Default = "default", e.Multiple = "multiple", e;
|
|
12
|
-
}({}), h = t`:host{background:var(--cx-panel-background-color);border:solid var(--cx-panel-border-width) var(--cx-panel-border-color);border-radius:var(--cx-panel-border-radius,var(--cx-border-radius-large));padding:var(--cx-panel-padding,var(--cx-spacing-x-small) 0);--divider-color:var(--cx-panel-border-color);--divider-width:var(--cx-panel-border-width);--divider-spacing:var(--cx-spacing-x-small);display:block;position:relative;overflow:auto}:host([horizontal]){padding:0 var(--cx-spacing-x-small);flex-wrap:wrap;justify-content:space-between;display:flex}::slotted(cx-divider){--color:var(--divider-color);--width:var(--divider-width);--spacing:var(--divider-spacing)}::slotted([data-alternating-grouping]):before{content:" ";background-color:var(--divider-color);margin:var(--divider-spacing) 0;height:var(--divider-width);display:block}::slotted([data-alternating-grouping=horizontal]):before{height:100%;margin:0 var(--divider-spacing);width:var(--divider-width);display:inline-block}:host([horizontal]) ::slotted(cx-menu-section){flex-wrap:wrap;justify-content:space-between;display:flex}:host([horizontal]) ::slotted(cx-menu-item){display:flex}:host([variant=multiple]){position:relative;overflow:hidden}:host([variant=multiple]) ::slotted(cx-menu[name]){opacity:0;pointer-events:none;transition:opacity var(--cx-transition-fast) ease-in-out, transform var(--cx-transition-medium) ease-in-out;border:none;top:0;left:0;transform:translate(-50%);position:absolute!important}:host([variant=multiple]) ::slotted(cx-menu[active]){opacity:1;pointer-events:auto;transform:translate(0)}.back__button::part(checked-icon),.back__button::part(submenu-icon){display:none}.back__divider{--spacing:var(--
|
|
12
|
+
}({}), h = t`:host{background:var(--cx-panel-background-color);border:solid var(--cx-panel-border-width) var(--cx-panel-border-color);border-radius:var(--cx-panel-border-radius,var(--cx-border-radius-large));padding:var(--cx-panel-padding,var(--cx-spacing-x-small) 0);--divider-color:var(--cx-panel-border-color);--divider-width:var(--cx-panel-border-width);--divider-spacing:var(--cx-menu-divider-spacing,var(--cx-spacing-x-small));display:block;position:relative;overflow:auto}:host([horizontal]){padding:0 var(--cx-spacing-x-small);flex-wrap:wrap;justify-content:space-between;display:flex}::slotted(cx-divider){--color:var(--divider-color);--width:var(--divider-width);--spacing:var(--divider-spacing)}::slotted([data-alternating-grouping]):before{content:" ";background-color:var(--divider-color);margin:var(--divider-spacing) 0;height:var(--divider-width);display:block}::slotted([data-alternating-grouping=horizontal]):before{height:100%;margin:0 var(--divider-spacing);width:var(--divider-width);display:inline-block}:host([horizontal]) ::slotted(cx-menu-section){flex-wrap:wrap;justify-content:space-between;display:flex}:host([horizontal]) ::slotted(cx-menu-item){display:flex}:host([variant=multiple]){position:relative;overflow:hidden}:host([variant=multiple]) ::slotted(cx-menu[name]){opacity:0;pointer-events:none;transition:opacity var(--cx-transition-fast) ease-in-out, transform var(--cx-transition-medium) ease-in-out;border:none;top:0;left:0;transform:translate(-50%);position:absolute!important}:host([variant=multiple]) ::slotted(cx-menu[active]){opacity:1;pointer-events:auto;transform:translate(0)}.back__button::part(checked-icon),.back__button::part(submenu-icon){display:none}.back__divider{--spacing:var(--divider-spacing)}`, g;
|
|
13
13
|
function _(e) {
|
|
14
14
|
return e.tagName.toLowerCase() === "cx-menu" && e instanceof y && e.getAttribute("role") === "menu" && !e.inert;
|
|
15
15
|
}
|
|
@@ -15,7 +15,7 @@ import { t as y } from "./repeat.CKv9FPlC.js";
|
|
|
15
15
|
import { t as b } from "./input.kTjqEyC8.js";
|
|
16
16
|
import { t as x } from "./option.DWE0tark.js";
|
|
17
17
|
import { t as S } from "./space.Dd8jezXK.js";
|
|
18
|
-
import { t as C } from "./select.
|
|
18
|
+
import { t as C } from "./select.D_899gsk.js";
|
|
19
19
|
//#region ../../packages/types/src/pagination.ts
|
|
20
20
|
var w = /* @__PURE__ */ function(e) {
|
|
21
21
|
return e.Both = "both", e.Pages = "pages", e.Rows = "rows", e;
|
|
@@ -26,9 +26,9 @@ import { n as P } from "./scroll.CEH_a4pm.js";
|
|
|
26
26
|
import { t as F } from "./user-agent.D2bRhUeS.js";
|
|
27
27
|
import { t as I } from "./unsafe-html.Cb838aX7.js";
|
|
28
28
|
//#region ../../packages/atoms/src/utilities/type-check.ts
|
|
29
|
-
var L = (e) => !(document.createElement(e.tagName).constructor === HTMLElement || customElements.get(e.tagName.toLowerCase())), R = t`:host{display:block}:host([data-user-invalid])::part(combobox){border-color:var(--cx-input-invalid-border-color)}:host([data-user-invalid]:focus-within)::part(combobox){border-color:var(--cx-input-invalid-border-color);box-shadow:var(--cx-input-invalid-shadow)}.select{vertical-align:middle;flex:auto;width:100%;display:inline-flex;position:relative}.select::part(popup){z-index:var(--cx-z-index-dropdown)}.select[data-current-placement^=top]::part(popup){transform-origin:bottom}.select[data-current-placement^=bottom]::part(popup){transform-origin:top}.select__combobox{font-family:var(--cx-input-font-family);font-weight:var(--cx-input-font-weight);letter-spacing:var(--cx-input-letter-spacing);vertical-align:middle;cursor:pointer;transition:var(--cx-transition-fast) color, var(--cx-transition-fast) border, var(--cx-transition-fast) box-shadow, var(--cx-transition-fast) background-color;flex:1;justify-content:start;align-items:center;width:20ch;min-width:0;display:flex;position:relative;overflow:hidden}.select__display-input{width:100%;font:inherit;color:var(--cx-input-color);cursor:inherit;-webkit-appearance:none;text-overflow:ellipsis;background:0 0;border:none;margin:0;padding:0;transition:padding-top .2s ease-in-out;position:relative;overflow:hidden}:host([allow-freetext]) .input-container,:host([allow-freetext]) .select__display-input{cursor:text}:host([allow-freetext]) .select--disabled .input-container,:host([allow-freetext]) .select--disabled .select__display-input{cursor:default}.select__tags+.select__display-input{padding-top:var(--cx-spacing-2x-small)}.select__display-input--small{line-height:var(--cx-line-height-small)}.select__display-input--medium{line-height:var(--cx-line-height-medium)}.select__display-input--large{line-height:var(--cx-line-height-large)}.select__display-input--hidden{visibility:hidden;height:0;padding-top:0!important}.form-control--has-label .select__display-input{padding-top:var(--cx-spacing-x-small);padding-bottom:var(--cx-spacing-2x-small)}.select__display-input::placeholder{color:var(--cx-input-placeholder-color)}.select:not(.select--disabled):hover .select__display-input{color:var(--cx-input-color-hover)}.select:not(.select--disabled):hover .select__combobox{border-color:var(--cx-input-border-color-hover)}.select__display-input:focus{outline:none}.select__value-input{opacity:0;z-index:-1;width:100%;height:100%;margin:0;padding:0;position:absolute;top:0;left:0}.select__tags{flex-wrap:wrap;align-items:center;max-width:100%;display:flex}.form-control--has-label .select__tags{margin-top:var(--cx-spacing-x-small)}.select--small:not(.select--placeholder-visible) .select__tags,.select--medium:not(.select--placeholder-visible) .select__tags,.select--large:not(.select--placeholder-visible) .select__tags{min-height:var(--cx-line-height-medium)}.select__tags::slotted(cx-tag){cursor:pointer!important}.select--disabled .select__tags,.select--disabled .select__tags::slotted(cx-tag){cursor:default!important}.select__tag-wrapper{line-height:1}.select--standard .select__combobox{background-color:var(--cx-input-background-color);border:solid var(--cx-input-border-width) var(--cx-input-border-color)}.select--standard.select--disabled .select__combobox{background-color:var(--cx-input-background-color-disabled);border-color:var(--cx-input-border-color-disabled);color:var(--cx-input-color-disabled);opacity:.5;cursor:default;outline:none}.select--standard:not(.select--disabled).select--open .select__combobox,.select--standard:not(.select--disabled).select--focused .select__combobox{background-color:var(--cx-input-background-color-focus);border-color:var(--cx-input-border-color-focus)}.select--filled .select__combobox{background-color:var(--cx-input-filled-background-color);color:var(--cx-input-color);border:none}.select--filled:hover:not(.select--disabled) .select__combobox{background-color:var(--cx-input-filled-background-color-hover)}.select--filled.select--disabled .select__combobox{background-color:var(--cx-input-filled-background-color-disabled);opacity:.5;cursor:default}.select--filled:not(.select--disabled).select--open .select__combobox,.select--filled:not(.select--disabled).select--focused .select__combobox{background-color:var(--cx-input-filled-background-color-focus);outline:var(--cx-focus-ring)}.select--small .select__combobox{border-radius:var(--cx-input-border-radius-small);font-size:var(--cx-input-font-size-small);min-height:var(--cx-input-height-small);padding-block:0;padding-inline:var(--cx-input-spacing-small)}.form-control:not(.form-control--has-label) .select--small.select--multiple .select__combobox{padding-block:2px}.form-control:not(.form-control--has-label) .select--multiple .select__display-input{margin-top:0}.form-control:not(.form-control--has-label) .input-container{justify-content:center}.form-control:not(.form-control--has-label) .input-container .select__display-input{margin-top:0}.select--small .select__clear{margin-inline-start:var(--cx-input-spacing-small)}.select--small .select__prefix::slotted(*){margin-inline-end:var(--cx-input-spacing-small)}.select--small .select__tags{gap:2px}.select--medium .select__combobox{border-radius:var(--cx-input-border-radius-medium);font-size:var(--cx-input-font-size-small);min-height:var(--cx-input-height-medium);padding-block:0;padding-inline:var(--cx-input-spacing-medium)}.form-control:not(.form-control--has-label) .select--medium.select--multiple .select__combobox{padding-block:3px}.select--medium .select__clear{margin-inline-start:var(--cx-input-spacing-medium)}.select--medium .select__prefix::slotted(*){margin-inline-end:var(--cx-input-spacing-medium)}.select--medium .select__tags{gap:3px}.select--large .select__combobox{border-radius:var(--cx-input-border-radius-large);font-size:var(--cx-input-font-size-small);min-height:var(--cx-input-height-large);padding-block:0;padding-inline:var(--cx-input-spacing-large)}.form-control:not(.form-control--has-label) .select--large.select--multiple .select__combobox{padding-block:4px}.select--large .select__clear{margin-inline-start:var(--cx-input-spacing-large)}.select--large .select__prefix::slotted(*){margin-inline-end:var(--cx-input-spacing-large)}.select--large .select__tags{gap:4px}.select--pill.select--small .select__combobox{border-radius:var(--cx-input-height-small)}.select--pill.select--medium .select__combobox{border-radius:var(--cx-input-height-medium)}.select--pill.select--large .select__combobox{border-radius:var(--cx-input-height-large)}.select__prefix,.select__suffix{color:var(--cx-input-placeholder-color);flex:0;align-items:center;display:inline-flex}.select__clear{font-size:inherit;color:var(--cx-input-icon-color);transition:var(--cx-transition-fast) color;cursor:pointer;z-index:1;background:0 0;border:none;justify-content:center;align-items:center;padding:0;display:inline-flex}.select__clear:hover{color:var(--cx-input-icon-color-hover)}.select__clear:focus{outline:none}.select__expand-icon{transition:var(--cx-transition-medium) rotate ease;rotate:0;font-size:var(--cx-font-size-large);flex:none;align-items:center;margin-inline-start:var(--cx-spacing-small);display:flex}.select--open .select__expand-icon{rotate:var(--cx-select-expand-icon-rotate-open,-180deg)}.select__listbox{font-family:var(--cx-font-sans);font-size:var(--cx-font-size-medium);font-weight:var(--cx-font-weight-regular);box-shadow:var(--cx-shadow-large);background:var(--cx-panel-background-color);border:solid var(--cx-panel-border-width) var(--cx-panel-border-color);border-radius:var(--cx-border-radius-large);padding-block:var(--cx-spacing-x-small);overscroll-behavior:none;max-width:var(--auto-size-available-width);max-height:var(--select-max-height,var(--auto-size-available-height));padding-inline:0;display:block;position:relative;overflow:auto}.select__listbox ::slotted(cx-divider){--spacing:var(--cx-spacing-x-small);width:calc(100% - (var(--cx-spacing-x-small) * 2));margin-inline:auto}.select__listbox ::slotted(small){font-size:var(--cx-font-size-x-small);font-weight:var(--cx-font-weight-medium);line-height:var(--cx-line-height-x-small);color:var(--cx-color-neutral-600);padding-block:var(--cx-spacing-2x-small);padding-inline:var(--cx-spacing-small);display:block}.select__no-options{font-size:var(--cx-font-size-small);color:var(--cx-color-neutral-500);padding-block:var(--cx-spacing-2x-small);padding-inline:var(--cx-spacing-small);text-align:left;cursor:default;user-select:none;display:block}.input-container{flex-direction:column;flex:1;align-self:stretch;width:0;display:inline-flex;position:relative}.input-container__display-value{column-gap:var(--cx-spacing-small);row-gap:var(--cx-spacing-3x-small);flex-flow:wrap;width:100%;height:100%;display:flex}.form-control__label{pointer-events:none;width:fit-content;line-height:1;-webkit-transition:transform .2s ease-in-out;-moz-transition:transform .2s ease-in-out;transition:transform .2s ease-in-out;position:relative}.select--small .form-control__label{transform:translateY(calc(( var(--cx-input-height-small) + 1.25rem - var(--cx-input-font-size-small) ) / 2));margin:0}.select--medium .form-control__label{transform:translateY(calc(( var(--cx-input-height-medium) / 2 + 1rem - var(--cx-input-font-size-medium) )));margin:0}.select--large .form-control__label{transform:translateY(calc(( var(--cx-input-height-large) + 1rem - var(--cx-input-font-size-large) ) / 2));margin:0}.form-control--has-label .select--small{min-height:calc(var(--cx-input-height-small) + 1rem)}.form-control--has-label .select--medium{min-height:calc(var(--cx-input-height-medium) + 1rem)}.form-control--has-label .select--large{min-height:calc(var(--cx-input-height-large) + 1rem)}.form-control--has-label .select--focused .form-control__label,.form-control--has-label .select--placeholder-visible .form-control__label,.form-control--has-label .select:not(.select--empty) .form-control__label{transform:translateY(calc(var(--cx-spacing-2x-small) + var(--cx-spacing-3x-small)))}.select__listbox slot{flex-direction:column;display:flex}:host([data-cx-input-group__input--first]:not([data-cx-input-group__input--last])) .select__combobox{border-start-end-radius:0;border-end-end-radius:0}:host([data-cx-input-group__input--inner]) .select__combobox{border-radius:0}:host([data-cx-input-group__input--last]:not([data-cx-input-group__input--first])) .select__combobox{border-start-start-radius:0;border-end-start-radius:0}:host([data-cx-input-group__input]:not([data-cx-input-group__input--first])){margin-inline-start:calc(-1 * var(--cx-input-border-width))}:host([data-cx-input-group__input--hover]){z-index:1}:host([data-cx-input-group__input--focus]),:host([data-cx-input-group__input][checked]){z-index:2}`, z = class extends s {
|
|
29
|
+
var L = (e) => !(document.createElement(e.tagName).constructor === HTMLElement || customElements.get(e.tagName.toLowerCase())), R = t`:host{display:block}:host([data-user-invalid])::part(combobox){border-color:var(--cx-input-invalid-border-color)}:host([data-user-invalid]:focus-within)::part(combobox){border-color:var(--cx-input-invalid-border-color);box-shadow:var(--cx-input-invalid-shadow)}.select{vertical-align:middle;flex:auto;width:100%;display:inline-flex;position:relative}.select::part(popup){z-index:var(--cx-z-index-dropdown)}.select[data-current-placement^=top]::part(popup){transform-origin:bottom}.select[data-current-placement^=bottom]::part(popup){transform-origin:top}.select__combobox{font-family:var(--cx-input-font-family);font-weight:var(--cx-input-font-weight);letter-spacing:var(--cx-input-letter-spacing);vertical-align:middle;cursor:pointer;transition:var(--cx-transition-fast) color, var(--cx-transition-fast) border, var(--cx-transition-fast) box-shadow, var(--cx-transition-fast) background-color;flex:1;justify-content:start;align-items:center;width:20ch;min-width:0;display:flex;position:relative;overflow:hidden}.select__display-input{width:100%;font:inherit;color:var(--cx-input-color);cursor:inherit;-webkit-appearance:none;text-overflow:ellipsis;background:0 0;border:none;margin:0;padding:0;transition:padding-top .2s ease-in-out;position:relative;overflow:hidden}:host([allow-freetext]) .input-container,:host([allow-freetext]) .select__display-input{cursor:text}:host([allow-freetext]) .select--disabled .input-container,:host([allow-freetext]) .select--disabled .select__display-input{cursor:default}.select__tags+.select__display-input{padding-top:var(--cx-spacing-2x-small)}.select__display-input--small{line-height:var(--cx-line-height-small)}.select__display-input--medium{line-height:var(--cx-line-height-medium)}.select__display-input--large{line-height:var(--cx-line-height-large)}.select__display-input--hidden{visibility:hidden;height:0;padding-top:0!important}.form-control--has-label .select__display-input{padding-top:var(--cx-spacing-x-small);padding-bottom:var(--cx-spacing-2x-small)}.select__display-input::placeholder{color:var(--cx-input-placeholder-color)}.select:not(.select--disabled):hover .select__display-input{color:var(--cx-input-color-hover)}.select:not(.select--disabled):hover .select__combobox{border-color:var(--cx-input-border-color-hover)}.select__display-input:focus{outline:none}.select__value-input{opacity:0;z-index:-1;width:100%;height:100%;margin:0;padding:0;position:absolute;top:0;left:0}.select__tags{flex-wrap:wrap;align-items:center;max-width:100%;display:flex}.form-control--has-label .select__tags{margin-top:var(--cx-spacing-x-small)}.select--small:not(.select--placeholder-visible) .select__tags,.select--medium:not(.select--placeholder-visible) .select__tags,.select--large:not(.select--placeholder-visible) .select__tags{min-height:var(--cx-line-height-medium)}.select__tags::slotted(cx-tag){cursor:pointer!important}.select--disabled .select__tags,.select--disabled .select__tags::slotted(cx-tag){cursor:default!important}.select__tag-wrapper{line-height:1}.select--standard .select__combobox{background-color:var(--cx-input-background-color);border:solid var(--cx-input-border-width) var(--cx-input-border-color)}.select--standard.select--disabled .select__combobox{background-color:var(--cx-input-background-color-disabled);border-color:var(--cx-input-border-color-disabled);color:var(--cx-input-color-disabled);opacity:.5;cursor:default;outline:none}.select--standard:not(.select--disabled).select--open .select__combobox,.select--standard:not(.select--disabled).select--focused .select__combobox{background-color:var(--cx-input-background-color-focus);border-color:var(--cx-input-border-color-focus)}.select--filled .select__combobox{background-color:var(--cx-input-filled-background-color);color:var(--cx-input-color);border:none}.select--filled:hover:not(.select--disabled) .select__combobox{background-color:var(--cx-input-filled-background-color-hover)}.select--filled.select--disabled .select__combobox{background-color:var(--cx-input-filled-background-color-disabled);opacity:.5;cursor:default}.select--filled:not(.select--disabled).select--open .select__combobox,.select--filled:not(.select--disabled).select--focused .select__combobox{background-color:var(--cx-input-filled-background-color-focus);outline:var(--cx-focus-ring)}.select--small .select__combobox{border-radius:var(--cx-input-border-radius-small);font-size:var(--cx-input-font-size-small);min-height:var(--cx-input-height-small);padding-block:0;padding-inline:var(--cx-input-spacing-small)}.form-control:not(.form-control--has-label) .select--small.select--multiple .select__combobox{padding-block:2px}.form-control:not(.form-control--has-label) .select--multiple .select__display-input{margin-top:0}.form-control:not(.form-control--has-label) .input-container{justify-content:center}.form-control:not(.form-control--has-label) .input-container .select__display-input{margin-top:0}.select--small .select__clear{margin-inline-start:var(--cx-input-spacing-small)}.select--small .select__prefix::slotted(*){margin-inline-end:var(--cx-input-spacing-small)}.select--small .select__tags{gap:2px}.select--medium .select__combobox{border-radius:var(--cx-input-border-radius-medium);font-size:var(--cx-input-font-size-small);min-height:var(--cx-input-height-medium);padding-block:0;padding-inline:var(--cx-input-spacing-medium)}.form-control:not(.form-control--has-label) .select--medium.select--multiple .select__combobox{padding-block:3px}.select--medium .select__clear{margin-inline-start:var(--cx-input-spacing-medium)}.select--medium .select__prefix::slotted(*){margin-inline-end:var(--cx-input-spacing-medium)}.select--medium .select__tags{gap:3px}.select--large .select__combobox{border-radius:var(--cx-input-border-radius-large);font-size:var(--cx-input-font-size-small);min-height:var(--cx-input-height-large);padding-block:0;padding-inline:var(--cx-input-spacing-large)}.form-control:not(.form-control--has-label) .select--large.select--multiple .select__combobox{padding-block:4px}.select--large .select__clear{margin-inline-start:var(--cx-input-spacing-large)}.select--large .select__prefix::slotted(*){margin-inline-end:var(--cx-input-spacing-large)}.select--large .select__tags{gap:4px}.select--pill.select--small .select__combobox{border-radius:var(--cx-input-height-small)}.select--pill.select--medium .select__combobox{border-radius:var(--cx-input-height-medium)}.select--pill.select--large .select__combobox{border-radius:var(--cx-input-height-large)}.select__prefix,.select__suffix{color:var(--cx-input-placeholder-color);flex:0;align-items:center;display:inline-flex}.select__clear{font-size:inherit;color:var(--cx-input-icon-color);transition:var(--cx-transition-fast) color;cursor:pointer;z-index:1;background:0 0;border:none;justify-content:center;align-items:center;padding:0;display:inline-flex}.select__clear:hover{color:var(--cx-input-icon-color-hover)}.select__clear:focus{outline:none}.select__expand-icon{transition:var(--cx-transition-medium) rotate ease;rotate:0;font-size:var(--cx-font-size-large);flex:none;align-items:center;margin-inline-start:var(--cx-spacing-small);display:flex}.select--open .select__expand-icon{rotate:var(--cx-select-expand-icon-rotate-open,-180deg)}.select__listbox{font-family:var(--cx-font-sans);font-size:var(--cx-font-size-medium);font-weight:var(--cx-font-weight-regular);box-shadow:var(--cx-shadow-large);background:var(--cx-panel-background-color);border:solid var(--cx-panel-border-width) var(--cx-panel-border-color);border-radius:var(--cx-border-radius-large);padding-block:var(--cx-spacing-x-small);overscroll-behavior:none;max-width:var(--auto-size-available-width);max-height:var(--select-max-height,var(--auto-size-available-height));padding-inline:0;display:block;position:relative;overflow:auto}.select__listbox ::slotted(cx-divider){--spacing:var(--cx-spacing-x-small);width:calc(100% - (var(--cx-spacing-x-small) * 2));margin-inline:auto}.select__listbox ::slotted(small){font-size:var(--cx-font-size-x-small);font-weight:var(--cx-font-weight-medium);line-height:var(--cx-line-height-x-small);color:var(--cx-color-neutral-600);padding-block:var(--cx-spacing-2x-small);padding-inline:var(--cx-spacing-small);display:block}.select__no-options{font-size:var(--cx-font-size-small);color:var(--cx-color-neutral-500);padding-block:var(--cx-spacing-2x-small);padding-inline:var(--cx-spacing-small);text-align:left;cursor:default;user-select:none;display:block}.select__options{display:contents}.select__footer{display:none}.select__listbox--has-footer{flex-direction:column;display:flex}.select__listbox--has-footer .select__options{overscroll-behavior:none;flex:0 auto;min-height:0;display:block;overflow:auto}.select__listbox--has-footer .select__footer{flex:none;display:block}.select__listbox--has-footer .select__footer:before{content:"";margin:0 var(--cx-spacing-x-small);border-top:solid var(--cx-panel-border-width) var(--cx-panel-border-color);display:block}.input-container{flex-direction:column;flex:1;align-self:stretch;width:0;display:inline-flex;position:relative}.input-container__display-value{column-gap:var(--cx-spacing-small);row-gap:var(--cx-spacing-3x-small);flex-flow:wrap;width:100%;height:100%;display:flex}.form-control__label{pointer-events:none;width:fit-content;line-height:1;-webkit-transition:transform .2s ease-in-out;-moz-transition:transform .2s ease-in-out;transition:transform .2s ease-in-out;position:relative}.select--small .form-control__label{transform:translateY(calc(( var(--cx-input-height-small) + 1.25rem - var(--cx-input-font-size-small) ) / 2));margin:0}.select--medium .form-control__label{transform:translateY(calc(( var(--cx-input-height-medium) / 2 + 1rem - var(--cx-input-font-size-medium) )));margin:0}.select--large .form-control__label{transform:translateY(calc(( var(--cx-input-height-large) + 1rem - var(--cx-input-font-size-large) ) / 2));margin:0}.form-control--has-label .select--small{min-height:calc(var(--cx-input-height-small) + 1rem)}.form-control--has-label .select--medium{min-height:calc(var(--cx-input-height-medium) + 1rem)}.form-control--has-label .select--large{min-height:calc(var(--cx-input-height-large) + 1rem)}.form-control--has-label .select--focused .form-control__label,.form-control--has-label .select--placeholder-visible .form-control__label,.form-control--has-label .select:not(.select--empty) .form-control__label{transform:translateY(calc(var(--cx-spacing-2x-small) + var(--cx-spacing-3x-small)))}.select__listbox slot{flex-direction:column;display:flex}:host([data-cx-input-group__input--first]:not([data-cx-input-group__input--last])) .select__combobox{border-start-end-radius:0;border-end-end-radius:0}:host([data-cx-input-group__input--inner]) .select__combobox{border-radius:0}:host([data-cx-input-group__input--last]:not([data-cx-input-group__input--first])) .select__combobox{border-start-start-radius:0;border-end-start-radius:0}:host([data-cx-input-group__input]:not([data-cx-input-group__input--first])){margin-inline-start:calc(-1 * var(--cx-input-border-width))}:host([data-cx-input-group__input--hover]){z-index:1}:host([data-cx-input-group__input--focus]),:host([data-cx-input-group__input][checked]){z-index:2}`, z = class extends s {
|
|
30
30
|
constructor(...t) {
|
|
31
|
-
super(...t), this.formControlController = new E(this, { assumeInteractionOn: ["cx-input"] }), this.hasSlotController = new g(this, "help-text", "label"), this.localize = new h(this), this.typeToSelectString = "", this.openListenersRoot = null, this.hasFocus = !1, this.displayLabel = "", this.selectedOptions = [], this.name = "", this.value = "", this.fallbackOptionValue = "", this.matchEmptyValue = !1, this.defaultValue = "", this.size = "medium", this.placeholder = "", this.allowFreetext = !1, this.multiple = !1, this.maxOptionsVisible = 3, this.disabled = !1, this.clearable = !1, this.open = !1, this.hoist = !1, this.noFlip = !1, this.freeWidth = !1, this.autosizePadding = 10, this.filled = !1, this.pill = !1, this.label = "", this.placement = "bottom", this.helpText = "", this.form = void 0, this.required = !1, this.useTag = !1, this.noSelectOnEnter = !1, this.noResetCurrent = !1, this.noDropdown = !1, this.noExpandIcon = !1, this.loading = !1, this.getTag = (t) => {
|
|
31
|
+
super(...t), this.formControlController = new E(this, { assumeInteractionOn: ["cx-input"] }), this.hasSlotController = new g(this, "footer", "help-text", "label"), this.localize = new h(this), this.typeToSelectString = "", this.openListenersRoot = null, this.hasFocus = !1, this.displayLabel = "", this.selectedOptions = [], this.name = "", this.value = "", this.fallbackOptionValue = "", this.matchEmptyValue = !1, this.defaultValue = "", this.size = "medium", this.placeholder = "", this.allowFreetext = !1, this.multiple = !1, this.maxOptionsVisible = 3, this.disabled = !1, this.clearable = !1, this.open = !1, this.hoist = !1, this.noFlip = !1, this.freeWidth = !1, this.autosizePadding = 10, this.filled = !1, this.pill = !1, this.label = "", this.placement = "bottom", this.helpText = "", this.form = void 0, this.required = !1, this.useTag = !1, this.noSelectOnEnter = !1, this.noResetCurrent = !1, this.noDropdown = !1, this.noExpandIcon = !1, this.loading = !1, this.getTag = (t) => {
|
|
32
32
|
let n = this.hasSlotController.test("label"), r = this.label || n ? this.size === "large" ? "medium" : "small" : this.size;
|
|
33
33
|
return e`<cx-tag part="tag" exportparts="
|
|
34
34
|
base:tag__base,
|
|
@@ -59,7 +59,7 @@ var L = (e) => !(document.createElement(e.tagName).constructor === HTMLElement |
|
|
|
59
59
|
this.show();
|
|
60
60
|
return;
|
|
61
61
|
}
|
|
62
|
-
this.currentOption && !this.currentOption.hidden && this.currentOption.isConnected && !this.getOptionDisabled(this.currentOption) && (this.noSelectOnEnter || (this.multiple ? (this.toggleOptionSelection(this.currentOption), this.#
|
|
62
|
+
this.currentOption && !this.currentOption.hidden && this.currentOption.isConnected && !this.getOptionDisabled(this.currentOption) && (this.noSelectOnEnter || (this.multiple ? (this.toggleOptionSelection(this.currentOption), this.#d(), this.inputBehavior === "select" && this.selectOptionByInput()) : this.setSelectedOptions(this.currentOption), this.updateComplete.then(() => {
|
|
63
63
|
this.emit("cx-input"), this.emit("cx-change");
|
|
64
64
|
})), (!this.multiple || this.closeOnSelect) && !this.stayOpenOnSelect && (this.hide(), this.displayInput.focus({ preventScroll: !0 })));
|
|
65
65
|
return;
|
|
@@ -71,14 +71,14 @@ var L = (e) => !(document.createElement(e.tagName).constructor === HTMLElement |
|
|
|
71
71
|
"End"
|
|
72
72
|
].includes(e.key)) {
|
|
73
73
|
let t = this.getAllOptions().filter((e) => this.inputBehavior !== "filter" || !e.hidden), n = this.currentOption ? t.indexOf(this.currentOption) : -1, r = Math.max(0, n);
|
|
74
|
-
if (e.preventDefault(), !this.open && (!this.#
|
|
74
|
+
if (e.preventDefault(), !this.open && (!this.#o() || (this.show(), this.currentOption))) return;
|
|
75
75
|
e.key === "ArrowDown" ? (r = n + 1, r > t.length - 1 && (r = 0)) : e.key === "ArrowUp" ? (r = n - 1, r < 0 && (r = t.length - 1)) : e.key === "Home" ? r = 0 : e.key === "End" && (r = t.length - 1), this.setCurrentOption(t[r]);
|
|
76
76
|
}
|
|
77
77
|
}
|
|
78
78
|
}, this.handleDocumentMouseDown = (e) => {
|
|
79
79
|
let t = e.composedPath();
|
|
80
80
|
this && !t.includes(this) && !this.stayOpenOnSelect && this.hide();
|
|
81
|
-
}, this.#
|
|
81
|
+
}, this.#s = {
|
|
82
82
|
folded: "",
|
|
83
83
|
raw: ""
|
|
84
84
|
};
|
|
@@ -136,7 +136,7 @@ var L = (e) => !(document.createElement(e.tagName).constructor === HTMLElement |
|
|
|
136
136
|
}
|
|
137
137
|
}
|
|
138
138
|
filterCallback(e, t) {
|
|
139
|
-
return this.filterIgnoreAccents ? T(this.getOptionLabel(e), { ignoreAccents: !0 }).includes(this.#
|
|
139
|
+
return this.filterIgnoreAccents ? T(this.getOptionLabel(e), { ignoreAccents: !0 }).includes(this.#c(t)) : this.getOptionLabel(e).toLowerCase().includes(t);
|
|
140
140
|
}
|
|
141
141
|
connectedCallback() {
|
|
142
142
|
super.connectedCallback(), this.stayOpenOnSelect || (this.open = !1);
|
|
@@ -191,7 +191,7 @@ var L = (e) => !(document.createElement(e.tagName).constructor === HTMLElement |
|
|
|
191
191
|
break;
|
|
192
192
|
case "select": this.selectOptionByInput();
|
|
193
193
|
}
|
|
194
|
-
this.#
|
|
194
|
+
this.#l();
|
|
195
195
|
}
|
|
196
196
|
handleComboboxMouseDown(e) {
|
|
197
197
|
let t = e.composedPath(), n = !1, r = !1;
|
|
@@ -203,13 +203,13 @@ var L = (e) => !(document.createElement(e.tagName).constructor === HTMLElement |
|
|
|
203
203
|
e instanceof HTMLElement && e.tagName.toLowerCase() === "cx-icon-button" && (n = !0);
|
|
204
204
|
}), !(this.disabled || n) && (r || this.inputBehavior !== "filter" || !this.open || !this.multiple && !this.useTag ? (this.allowDefaultMouseDown || this.allowFreetext ? requestAnimationFrame(() => {
|
|
205
205
|
this.displayInput.focus({ preventScroll: !0 });
|
|
206
|
-
}) : (e.preventDefault(), this.displayInput.focus({ preventScroll: !0 })), this.open = !this.open && (this.getAllOptions().length > 0 || !!this.noOptionText) && this.#
|
|
206
|
+
}) : (e.preventDefault(), this.displayInput.focus({ preventScroll: !0 })), this.open = !this.open && (this.getAllOptions().length > 0 || !!this.noOptionText) && this.#o()) : (this.allowFreetext || e.preventDefault(), this.displayInput.focus({ preventScroll: !0 })));
|
|
207
207
|
}
|
|
208
208
|
handleComboboxKeyDown(e) {
|
|
209
209
|
e.key !== "Tab" && ((e.key !== "Escape" || this.open && (this.shouldShowNoOptionsMessage || this.getVisibleOptions().length > 0)) && e.stopPropagation(), this.handleDocumentKeyDown(e));
|
|
210
210
|
}
|
|
211
211
|
handleClearClick(e) {
|
|
212
|
-
e.stopPropagation(), (this.value !== "" || this.displayLabel !== "") && (this.setSelectedOptions([]), this.displayInput.focus({ preventScroll: !0 }), this.#
|
|
212
|
+
e.stopPropagation(), (this.value !== "" || this.displayLabel !== "") && (this.setSelectedOptions([]), this.displayInput.focus({ preventScroll: !0 }), this.#d(), this.updateComplete.then(() => {
|
|
213
213
|
this.emit("cx-clear"), this.emit("cx-input"), this.emit("cx-change");
|
|
214
214
|
}));
|
|
215
215
|
}
|
|
@@ -218,7 +218,7 @@ var L = (e) => !(document.createElement(e.tagName).constructor === HTMLElement |
|
|
|
218
218
|
}
|
|
219
219
|
handleOptionClick(e) {
|
|
220
220
|
let t = e.target.closest("[role=\"option\"], cx-option"), n = this.value, r = e.composedPath().some((e) => e?.classList?.contains("tree-item__expand-button")), i = e.composedPath().some((e) => e?.classList?.contains("tree-item__actions"));
|
|
221
|
-
t && !this.getOptionDisabled(t) && !r && !i && (this.multiple ? (this.toggleOptionSelection(t), this.#
|
|
221
|
+
t && !this.getOptionDisabled(t) && !r && !i && (this.multiple ? (this.toggleOptionSelection(t), this.#d()) : this.setSelectedOptions(t), this.updateComplete.then(() => this.displayInput.focus({ preventScroll: !0 })), (this.value !== n || this.forceOnChange) && this.updateComplete.then(() => {
|
|
222
222
|
this.emit("cx-input"), this.emit("cx-change");
|
|
223
223
|
}), (!this.multiple || this.closeOnSelect) && !this.stayOpenOnSelect && (this.hide(), this.displayInput.focus({ preventScroll: !0 })));
|
|
224
224
|
}
|
|
@@ -239,18 +239,27 @@ var L = (e) => !(document.createElement(e.tagName).constructor === HTMLElement |
|
|
|
239
239
|
this.setSelectedOptions(r, i ? this.value : void 0), this.hasFocus && !this.open && !this.disabled && e.length > 0 && this.show();
|
|
240
240
|
}
|
|
241
241
|
handleTagRemove(e, t) {
|
|
242
|
-
e.stopPropagation(), this.disabled || (this.toggleOptionSelection(t, !1), this.#
|
|
242
|
+
e.stopPropagation(), this.disabled || (this.toggleOptionSelection(t, !1), this.#d(), this.updateComplete.then(() => {
|
|
243
243
|
this.emit("cx-input"), this.emit("cx-change");
|
|
244
244
|
}));
|
|
245
245
|
}
|
|
246
246
|
getAllOptions() {
|
|
247
|
-
return [...this.querySelectorAll("[role=\"option\"], cx-option")];
|
|
247
|
+
return this.#i([...this.querySelectorAll("[role=\"option\"], cx-option")]);
|
|
248
248
|
}
|
|
249
249
|
getFirstOption() {
|
|
250
250
|
return this.querySelector("cx-option");
|
|
251
251
|
}
|
|
252
252
|
#n() {
|
|
253
|
-
return [...this.querySelectorAll("cx-option")].find((e) => !e.hidden) ?? null;
|
|
253
|
+
return this.#i([...this.querySelectorAll("cx-option")]).find((e) => !e.hidden) ?? null;
|
|
254
|
+
}
|
|
255
|
+
#r(e) {
|
|
256
|
+
return e.slot === "footer" && e.parentElement === this;
|
|
257
|
+
}
|
|
258
|
+
#i(e) {
|
|
259
|
+
return e.some((e) => this.#r(e)) ? [...e.filter((e) => !this.#r(e)), ...e.filter((e) => this.#r(e))] : e;
|
|
260
|
+
}
|
|
261
|
+
#a() {
|
|
262
|
+
return this.hasSlotController.test("footer") ? this.optionsContainer : this.listbox;
|
|
254
263
|
}
|
|
255
264
|
getVisibleOptions() {
|
|
256
265
|
return this.getAllOptions().filter((e) => !e.hidden);
|
|
@@ -320,7 +329,7 @@ var L = (e) => !(document.createElement(e.tagName).constructor === HTMLElement |
|
|
|
320
329
|
this.currentOption && this.setCurrentOption(this.currentOption);
|
|
321
330
|
});
|
|
322
331
|
let { keyframes: e, options: t } = b(this, "select.show", { dir: this.localize.dir() });
|
|
323
|
-
await d(this.popup.popup, e, t), this.currentOption && P(this.currentOption, this
|
|
332
|
+
await d(this.popup.popup, e, t), this.currentOption && !this.#r(this.currentOption) && P(this.currentOption, this.#a(), "vertical", "auto"), this.emit("cx-after-show");
|
|
324
333
|
} else {
|
|
325
334
|
this.emit("cx-hide"), this.removeOpenListeners(), await f(this);
|
|
326
335
|
let { keyframes: e, options: t } = b(this, "select.hide", { dir: this.localize.dir() });
|
|
@@ -334,31 +343,31 @@ var L = (e) => !(document.createElement(e.tagName).constructor === HTMLElement |
|
|
|
334
343
|
break;
|
|
335
344
|
}
|
|
336
345
|
}
|
|
337
|
-
#
|
|
346
|
+
#o() {
|
|
338
347
|
return this.typeToSelectString.length >= Math.max(0, this.minQueryLength || 0);
|
|
339
348
|
}
|
|
340
|
-
#
|
|
341
|
-
#
|
|
342
|
-
return this.#
|
|
349
|
+
#s;
|
|
350
|
+
#c(e) {
|
|
351
|
+
return this.#s.raw !== e && (this.#s = {
|
|
343
352
|
folded: T(e, { ignoreAccents: !0 }),
|
|
344
353
|
raw: e
|
|
345
|
-
}), this.#
|
|
354
|
+
}), this.#s.folded;
|
|
346
355
|
}
|
|
347
|
-
#
|
|
348
|
-
this.open && !this.#
|
|
356
|
+
#l() {
|
|
357
|
+
this.open && !this.#o() && this.hide();
|
|
349
358
|
}
|
|
350
|
-
#
|
|
359
|
+
#u(e) {
|
|
351
360
|
return !this.highlightMatches || e.hidden ? [] : w(e.getTextLabel(), this.typeToSelectString, { ignoreAccents: this.filterIgnoreAccents });
|
|
352
361
|
}
|
|
353
362
|
filterOptionsByInput() {
|
|
354
363
|
let e = this.getAllOptions();
|
|
355
|
-
for (let t of e) this.filterCallback(t, this.typeToSelectString) ? (t.hidden = !1, t.style.removeProperty("display")) : (t.hidden = !0, t.style.setProperty("display", "none")), t instanceof N && (t.matchRanges = this.#
|
|
356
|
-
this.#
|
|
364
|
+
for (let t of e) this.filterCallback(t, this.typeToSelectString) ? (t.hidden = !1, t.style.removeProperty("display")) : (t.hidden = !0, t.style.setProperty("display", "none")), t instanceof N && (t.matchRanges = this.#u(t));
|
|
365
|
+
this.#f(), this.popup.style.removeProperty("--auto-size-available-width"), this.popup.style.removeProperty("--auto-size-available-height");
|
|
357
366
|
}
|
|
358
|
-
#
|
|
359
|
-
this.typeToSelectString = "", this.displayLabel = "", this.displayInput.value = "", this.inputBehavior === "filter" && this.filterOptionsByInput(), this.#
|
|
367
|
+
#d() {
|
|
368
|
+
this.typeToSelectString = "", this.displayLabel = "", this.displayInput.value = "", this.inputBehavior === "filter" && this.filterOptionsByInput(), this.#l();
|
|
360
369
|
}
|
|
361
|
-
#
|
|
370
|
+
#f() {
|
|
362
371
|
let { currentOption: e } = this;
|
|
363
372
|
if (!e || !e.hidden && e.isConnected) return;
|
|
364
373
|
let t = this.getVisibleOptions()[0];
|
|
@@ -369,7 +378,7 @@ var L = (e) => !(document.createElement(e.tagName).constructor === HTMLElement |
|
|
|
369
378
|
this.open = !1;
|
|
370
379
|
return;
|
|
371
380
|
}
|
|
372
|
-
if ((this.getAllOptions().length !== 0 || this.noOptionText) && this.#
|
|
381
|
+
if ((this.getAllOptions().length !== 0 || this.noOptionText) && this.#o()) return this.open = !0, p(this, "cx-after-show");
|
|
373
382
|
}
|
|
374
383
|
async hide() {
|
|
375
384
|
if (!this.open || this.disabled) {
|
|
@@ -385,11 +394,11 @@ var L = (e) => !(document.createElement(e.tagName).constructor === HTMLElement |
|
|
|
385
394
|
this.displayInput.blur();
|
|
386
395
|
}
|
|
387
396
|
render() {
|
|
388
|
-
let t = this.hasSlotController.test("label"), r = this.hasSlotController.test("help-text"), i = this.label ? !0 : !!t,
|
|
397
|
+
let t = this.hasSlotController.test("label"), r = this.hasSlotController.test("help-text"), i = this.hasSlotController.test("footer"), a = this.label ? !0 : !!t, o = this.helpText ? !0 : !!r, s = this.clearable && !this.disabled && (this.displayLabel.length > 0 || this.selectedOptions.length > 0), c = this.placeholder && this.value.length === 0 && this.displayLabel.length === 0, l = this.value.length === 0 && this.displayLabel.length === 0 || (this.multiple || this.useTag) && this.tags.length === 0, u = (this.multiple || this.useTag) && this.selectedOptions.length > 0;
|
|
389
398
|
return e`<div part="form-control" class=${v({
|
|
390
399
|
"form-control": !0,
|
|
391
|
-
"form-control--has-help-text":
|
|
392
|
-
"form-control--has-label":
|
|
400
|
+
"form-control--has-help-text": o,
|
|
401
|
+
"form-control--has-label": a,
|
|
393
402
|
"form-control--large": this.size === "large",
|
|
394
403
|
"form-control--medium": this.size === "medium",
|
|
395
404
|
"form-control--small": this.size === "small"
|
|
@@ -397,7 +406,7 @@ var L = (e) => !(document.createElement(e.tagName).constructor === HTMLElement |
|
|
|
397
406
|
select: !0,
|
|
398
407
|
"select--bottom": this.placement.startsWith("bottom"),
|
|
399
408
|
"select--disabled": this.disabled,
|
|
400
|
-
"select--empty":
|
|
409
|
+
"select--empty": l,
|
|
401
410
|
"select--filled": this.filled,
|
|
402
411
|
"select--focused": this.hasFocus || this.open,
|
|
403
412
|
"select--large": this.size === "large",
|
|
@@ -405,21 +414,24 @@ var L = (e) => !(document.createElement(e.tagName).constructor === HTMLElement |
|
|
|
405
414
|
"select--multiple": this.multiple || this.useTag,
|
|
406
415
|
"select--open": this.open,
|
|
407
416
|
"select--pill": this.pill,
|
|
408
|
-
"select--placeholder-visible":
|
|
417
|
+
"select--placeholder-visible": c,
|
|
409
418
|
"select--small": this.size === "small",
|
|
410
419
|
"select--standard": !0,
|
|
411
420
|
"select--top": this.placement.startsWith("top")
|
|
412
|
-
})} placement=${this.placement} strategy=${this.hoist ? "overlay" : "absolute"} ?flip=${!this.noFlip} shift sync=${this.freeWidth ? void 0 : "width"} auto-size="both" auto-size-padding=${this.autosizePadding} flip-padding="10"><div part="combobox" class="select__combobox" slot="anchor" @keydown=${this.handleComboboxKeyDown} @mousedown=${this.handleComboboxMouseDown}><slot part="prefix" name="prefix" class="select__prefix"></slot><span class="input-container" @click=${this.handleFocus}><label id="label" part="form-control-label" class="form-control__label" aria-hidden=${
|
|
421
|
+
})} placement=${this.placement} strategy=${this.hoist ? "overlay" : "absolute"} ?flip=${!this.noFlip} shift sync=${this.freeWidth ? void 0 : "width"} auto-size="both" auto-size-padding=${this.autosizePadding} flip-padding="10"><div part="combobox" class="select__combobox" slot="anchor" @keydown=${this.handleComboboxKeyDown} @mousedown=${this.handleComboboxMouseDown}><slot part="prefix" name="prefix" class="select__prefix"></slot><span class="input-container" @click=${this.handleFocus}><label id="label" part="form-control-label" class="form-control__label" aria-hidden=${a ? "false" : "true"}><slot name="label">${this.label}</slot></label>${x(u, () => e`<div part="tags" class="select__tags" @cx-remove=${this.handleTagRemove}>${this.tags}</div>`)}<input part="display-input" class=${v({
|
|
413
422
|
"select__display-input": !0,
|
|
414
|
-
"select__display-input--hidden": (this.multiple || this.useTag) && !this.hasFocus && !
|
|
423
|
+
"select__display-input--hidden": (this.multiple || this.useTag) && !this.hasFocus && !l && !(this.open && this.inputBehavior === "filter"),
|
|
415
424
|
"select__display-input--large": this.size === "large",
|
|
416
425
|
"select__display-input--medium": this.size === "medium",
|
|
417
426
|
"select__display-input--small": this.size === "small"
|
|
418
|
-
})} type="text" placeholder=${this.placeholder} .disabled=${this.disabled} ?readonly=${this.inputBehavior === "none" && !this.allowFreetext} .value=${this.displayLabel} autocomplete="off" spellcheck="false" autocapitalize="off" aria-controls="listbox" aria-expanded=${this.open ? "true" : "false"} aria-haspopup="listbox" aria-label=${
|
|
419
|
-
${x(
|
|
427
|
+
})} type="text" placeholder=${this.placeholder} .disabled=${this.disabled} ?readonly=${this.inputBehavior === "none" && !this.allowFreetext} .value=${this.displayLabel} autocomplete="off" spellcheck="false" autocapitalize="off" aria-controls="listbox" aria-expanded=${this.open ? "true" : "false"} aria-haspopup="listbox" aria-label=${a ? void 0 : this.dataset.label} aria-labelledby="label" aria-disabled=${this.disabled ? "true" : "false"} aria-describedby="help-text" role="combobox" tabindex="0" @focus=${this.handleFocus} @input=${this.handleInput} @blur=${this.handleBlur}></span><input class="select__value-input" type="text" ?disabled=${this.disabled} ?required=${this.required} .value=${Array.isArray(this.value) ? this.value.join(", ") : this.value} tabindex="-1" aria-hidden="true" @focus=${this.focus} @invalid=${this.handleInvalid}>${x(this.loading, () => e`<cx-spinner part="spinner" role="status" aria-live="polite"></cx-spinner>`)}
|
|
428
|
+
${x(s, () => e`<button part="clear-button" class="select__clear" type="button" aria-label=${this.localize.term("clearEntry")} @mousedown=${this.handleClearMouseDown} @click=${this.handleClearClick} tabindex="-1"><slot name="clear-icon"><cx-icon name="cancel"></cx-icon></slot></button>`)}<slot name="suffix" part="suffix" class="select__suffix"></slot>${this.noExpandIcon ? n : e`<slot name="expand-icon" part="expand-icon" class="select__expand-icon"><cx-icon name="arrow_drop_down"></cx-icon></slot>`}</div><div id="listbox" role="listbox" aria-expanded=${this.open ? "true" : "false"} ?hidden=${!this.open || this.disabled} aria-multiselectable=${this.multiple ? "true" : "false"} aria-labelledby="label" part="listbox" class=${v({
|
|
429
|
+
select__listbox: !0,
|
|
430
|
+
"select__listbox--has-footer": i
|
|
431
|
+
})} tabindex="-1" @mouseup=${this.handleOptionClick} @slotchange=${this.handleDefaultSlotChange}><div class="select__options"><slot></slot>${x(this.shouldShowNoOptionsMessage, () => e`<cx-typography variant="body3" class="select__no-options" role="option">${this.noOptionText}</cx-typography>`)}</div><div part="listbox-footer" class="select__footer"><slot name="footer"></slot></div></div></cx-popup></div><div part="form-control-help-text" id="help-text" class="form-control__help-text" aria-hidden=${o ? "false" : "true"}><slot name="help-text">${this.helpText}</slot></div></div>`;
|
|
420
432
|
}
|
|
421
433
|
};
|
|
422
|
-
a([c(".select"), o("design:type", l === void 0 ? Object : l)], z.prototype, "popup", void 0), a([c(".select__combobox"), o("design:type", typeof HTMLSlotElement > "u" ? Object : HTMLSlotElement)], z.prototype, "combobox", void 0), a([c(".select__display-input"), o("design:type", typeof HTMLInputElement > "u" ? Object : HTMLInputElement)], z.prototype, "displayInput", void 0), a([c(".select__value-input"), o("design:type", Object)], z.prototype, "valueInput", void 0), a([c(".select__listbox"), o("design:type", typeof HTMLSlotElement > "u" ? Object : HTMLSlotElement)], z.prototype, "listbox", void 0), a([i(), o("design:type", Object)], z.prototype, "hasFocus", void 0), a([i(), o("design:type", Object)], z.prototype, "displayLabel", void 0), a([i(), o("design:type", Object)], z.prototype, "currentOption", void 0), a([i(), o("design:type", Array)], z.prototype, "selectedOptions", void 0), a([r(), o("design:type", Object)], z.prototype, "name", void 0), a([r({ converter: {
|
|
434
|
+
a([c(".select"), o("design:type", l === void 0 ? Object : l)], z.prototype, "popup", void 0), a([c(".select__combobox"), o("design:type", typeof HTMLSlotElement > "u" ? Object : HTMLSlotElement)], z.prototype, "combobox", void 0), a([c(".select__display-input"), o("design:type", typeof HTMLInputElement > "u" ? Object : HTMLInputElement)], z.prototype, "displayInput", void 0), a([c(".select__value-input"), o("design:type", Object)], z.prototype, "valueInput", void 0), a([c(".select__listbox"), o("design:type", typeof HTMLSlotElement > "u" ? Object : HTMLSlotElement)], z.prototype, "listbox", void 0), a([c(".select__options"), o("design:type", typeof HTMLElement > "u" ? Object : HTMLElement)], z.prototype, "optionsContainer", void 0), a([i(), o("design:type", Object)], z.prototype, "hasFocus", void 0), a([i(), o("design:type", Object)], z.prototype, "displayLabel", void 0), a([i(), o("design:type", Object)], z.prototype, "currentOption", void 0), a([i(), o("design:type", Array)], z.prototype, "selectedOptions", void 0), a([r(), o("design:type", Object)], z.prototype, "name", void 0), a([r({ converter: {
|
|
423
435
|
fromAttribute: (e) => e.split(" "),
|
|
424
436
|
toAttribute: (e) => Array.isArray(e) ? e.join(" ") : e
|
|
425
437
|
} }), o("design:type", Object)], z.prototype, "value", void 0), a([r({
|
|
@@ -6,7 +6,7 @@ import { t as c } from "./repeat.CKv9FPlC.js";
|
|
|
6
6
|
import { t as l } from "./input.kTjqEyC8.js";
|
|
7
7
|
import { t as u } from "./space.Dd8jezXK.js";
|
|
8
8
|
import { t as d } from "./input-group.Dmd8XcxL.js";
|
|
9
|
-
import { t as f } from "./bicolor-picker.
|
|
9
|
+
import { t as f } from "./bicolor-picker.ePTFxpv-.js";
|
|
10
10
|
//#region ../../packages/molecules/src/shadow-input-group/shadow-input-group.styles.ts
|
|
11
11
|
var p = t``, m = class extends a {
|
|
12
12
|
constructor(...e) {
|
|
@@ -11,7 +11,7 @@ import { t as m } from "./tooltip.Cc02vm6M.js";
|
|
|
11
11
|
import { t as h } from "./default-value.opqQgoRT.js";
|
|
12
12
|
import { t as g } from "./input.kTjqEyC8.js";
|
|
13
13
|
import { t as _ } from "./space.Dd8jezXK.js";
|
|
14
|
-
import { t as v } from "./select.
|
|
14
|
+
import { t as v } from "./select.D_899gsk.js";
|
|
15
15
|
//#region ../../packages/types/src/size-input-group.ts
|
|
16
16
|
var y = /* @__PURE__ */ function(e) {
|
|
17
17
|
return e.Percentage = "percentage", e.Pixel = "pixel", e;
|
|
@@ -23,28 +23,28 @@ import "./breadcrumb-item.nHAFmgtO.js";
|
|
|
23
23
|
import "./button-group.CPfXrqyq.js";
|
|
24
24
|
import "./card.3c-X4hqR.js";
|
|
25
25
|
import "./checkbox.BdSpQlwf.js";
|
|
26
|
-
import "./dropdown.
|
|
26
|
+
import "./dropdown.B4vsoK98.js";
|
|
27
27
|
import "./input.kTjqEyC8.js";
|
|
28
|
-
import "./menu.
|
|
29
|
-
import "./menu-item.
|
|
28
|
+
import "./menu.69SdPYy6.js";
|
|
29
|
+
import "./menu-item.SGtyl6pY.js";
|
|
30
30
|
import "./textarea.CHSZI8vt.js";
|
|
31
31
|
import "./option.DWE0tark.js";
|
|
32
32
|
import "./space.Dd8jezXK.js";
|
|
33
|
-
import "./select.
|
|
33
|
+
import "./select.D_899gsk.js";
|
|
34
34
|
import "./tab.Cv-UuYM5.js";
|
|
35
|
-
import "./tab-group.
|
|
35
|
+
import "./tab-group.FZnVZRnT.js";
|
|
36
36
|
import "./tab-panel.BxeoKuSv.js";
|
|
37
37
|
import "./visually-hidden.Bv3SInZp.js";
|
|
38
|
-
import "./color-picker.
|
|
38
|
+
import "./color-picker.DzBT5QXr.js";
|
|
39
39
|
import "./copy-button.CqqKJEh3.js";
|
|
40
40
|
import "./date-calendar.B7e6WBzh.js";
|
|
41
41
|
import "./details.DSgp6VAD.js";
|
|
42
|
-
import "./dialog.
|
|
42
|
+
import "./dialog.CPvHVWDJ.js";
|
|
43
43
|
import "./divider.CqSNZCU8.js";
|
|
44
44
|
import "./diff.Bmdpmpvo.js";
|
|
45
45
|
import "./drawer.CLSdjLR9.js";
|
|
46
46
|
import "./progress-bar.CynVLLnY.js";
|
|
47
|
-
import "./document-viewer.
|
|
47
|
+
import "./document-viewer.DmXykwuU.js";
|
|
48
48
|
import "./image.-lgb634-.js";
|
|
49
49
|
import "./skeleton.BtwugOTG.js";
|
|
50
50
|
import "./dot-pagination.C1C6NG8d.js";
|
|
@@ -67,7 +67,7 @@ import "./markdown.BzDRvv-f.js";
|
|
|
67
67
|
import "./menu-label.B-FOyfAX.js";
|
|
68
68
|
import "./menu-section.BzzA6L5E.js";
|
|
69
69
|
import "./mutation-observer.CD5prBIP.js";
|
|
70
|
-
import "./pagination.
|
|
70
|
+
import "./pagination.B6alBgDy.js";
|
|
71
71
|
import "./progress-ring.Bfdj3-uB.js";
|
|
72
72
|
import "./qr-code.SwjFPrvB.js";
|
|
73
73
|
import "./radio.DhPbmKbQ.js";
|
|
@@ -14,9 +14,9 @@ import { t as _ } from "./style-map.DPGQIxip.js";
|
|
|
14
14
|
import { t as v } from "./button.BjijpxeK.js";
|
|
15
15
|
import { d as y } from "./dom.BLHsooDR.js";
|
|
16
16
|
import { t as b } from "./resize-observer.D9EHlnZI.js";
|
|
17
|
-
import { t as x } from "./dropdown.
|
|
18
|
-
import { t as S } from "./menu.
|
|
19
|
-
import { t as C } from "./menu-item.
|
|
17
|
+
import { t as x } from "./dropdown.B4vsoK98.js";
|
|
18
|
+
import { t as S } from "./menu.69SdPYy6.js";
|
|
19
|
+
import { t as C } from "./menu-item.SGtyl6pY.js";
|
|
20
20
|
import { n as w } from "./scroll.CEH_a4pm.js";
|
|
21
21
|
import { t as T } from "./tab.Cv-UuYM5.js";
|
|
22
22
|
import { t as E } from "./parse.CDrJ-NY7.js";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as e } from "../chunks/asset-link-format.
|
|
1
|
+
import { t as e } from "../chunks/asset-link-format.dG974FMS.js";
|
|
2
2
|
export { e as default };
|