@esri/calcite-components 1.0.0-next.424 → 1.0.0-next.427

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 (44) hide show
  1. package/dist/calcite/calcite.esm.js +1 -1
  2. package/dist/calcite/{p-8e0dd0af.system.entry.js → p-0217c41b.system.entry.js} +1 -1
  3. package/dist/calcite/p-62afcb36.system.js +1 -1
  4. package/dist/calcite/p-7b238036.entry.js +5 -0
  5. package/dist/calcite/{p-895d22f3.entry.js → p-851b6fa4.entry.js} +1 -1
  6. package/dist/calcite/p-b96b7c58.entry.js +5 -0
  7. package/dist/calcite/p-cedd48fe.system.entry.js +5 -0
  8. package/dist/calcite/p-f51353e8.system.entry.js +5 -0
  9. package/dist/cjs/calcite-combobox_3.cjs.entry.js +19 -14
  10. package/dist/cjs/calcite-modal.cjs.entry.js +1 -1
  11. package/dist/cjs/calcite-tab_4.cjs.entry.js +31 -32
  12. package/dist/collection/components/combobox/combobox.js +18 -13
  13. package/dist/collection/components/combobox-item/combobox-item.css +1 -1
  14. package/dist/collection/components/modal/modal.js +1 -1
  15. package/dist/collection/components/tab/tab.js +10 -12
  16. package/dist/collection/components/tab-nav/tab-nav.js +8 -5
  17. package/dist/collection/components/tab-title/tab-title.js +13 -12
  18. package/dist/collection/components/tabs/tabs.js +0 -3
  19. package/dist/components/calcite-combobox-item.js +1 -1
  20. package/dist/components/calcite-combobox.js +18 -13
  21. package/dist/components/calcite-modal.js +1 -1
  22. package/dist/components/tab-nav.js +8 -5
  23. package/dist/components/tab-title.js +13 -12
  24. package/dist/components/tab.js +10 -12
  25. package/dist/components/tabs.js +0 -3
  26. package/dist/custom-elements/index.js +51 -47
  27. package/dist/esm/calcite-combobox_3.entry.js +19 -14
  28. package/dist/esm/calcite-modal.entry.js +1 -1
  29. package/dist/esm/calcite-tab_4.entry.js +31 -32
  30. package/dist/esm-es5/calcite-combobox_3.entry.js +1 -1
  31. package/dist/esm-es5/calcite-modal.entry.js +1 -1
  32. package/dist/esm-es5/calcite-tab_4.entry.js +1 -1
  33. package/dist/extras/docs-json.json +1 -1
  34. package/dist/types/components/combobox/combobox.d.ts +1 -1
  35. package/dist/types/components/tab/tab.d.ts +4 -5
  36. package/dist/types/components/tab-nav/tab-nav.d.ts +15 -19
  37. package/dist/types/components/tab-title/tab-title.d.ts +9 -18
  38. package/dist/types/components/tabs/tabs.d.ts +1 -4
  39. package/hydrate/index.js +51 -47
  40. package/package.json +1 -1
  41. package/dist/calcite/p-1aeca42a.system.entry.js +0 -5
  42. package/dist/calcite/p-3915705c.entry.js +0 -5
  43. package/dist/calcite/p-867f7b7a.system.entry.js +0 -5
  44. package/dist/calcite/p-9e61d89d.entry.js +0 -5
@@ -20,14 +20,6 @@ const Tab = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
20
20
  this.active = false;
21
21
  /** @internal Parent tabs component scale value */
22
22
  this.scale = "m";
23
- //--------------------------------------------------------------------------
24
- //
25
- // Private State/Props
26
- //
27
- //--------------------------------------------------------------------------
28
- /**
29
- * @internal
30
- */
31
23
  this.guid = `calcite-tab-title-${guid()}`;
32
24
  }
33
25
  //--------------------------------------------------------------------------
@@ -39,12 +31,15 @@ const Tab = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
39
31
  const id = this.el.id || this.guid;
40
32
  return (h(Host, { "aria-expanded": this.active.toString(), "aria-labelledby": this.labeledBy, id: id, role: "tabpanel" }, h("section", null, h("slot", null))));
41
33
  }
34
+ connectedCallback() {
35
+ this.parentTabsEl = this.el.closest("calcite-tabs");
36
+ }
42
37
  componentDidLoad() {
43
38
  this.calciteTabRegister.emit();
44
39
  }
45
40
  componentWillRender() {
46
41
  var _a;
47
- this.scale = (_a = this.el.closest("calcite-tabs")) === null || _a === void 0 ? void 0 : _a.scale;
42
+ this.scale = (_a = this.parentTabsEl) === null || _a === void 0 ? void 0 : _a.scale;
48
43
  }
49
44
  disconnectedCallback() {
50
45
  var _a;
@@ -59,10 +54,13 @@ const Tab = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
59
54
  //
60
55
  //--------------------------------------------------------------------------
61
56
  tabChangeHandler(event) {
57
+ const targetTabsEl = event
58
+ .composedPath()
59
+ .find((el) => el.tagName === "CALCITE-TABS");
62
60
  // to allow `<calcite-tabs>` to be nested we need to make sure this
63
- // `calciteTabChange` event was actually fired from a title that is a
64
- // child of the `<calcite-tabs>` that is the a parent of this tab.
65
- if (!event.composedPath().includes(this.el.closest("calcite-tabs"))) {
61
+ // `calciteTabChange` event was actually fired from a within the same
62
+ // `<calcite-tabs>` that is the a parent of this tab.
63
+ if (targetTabsEl !== this.parentTabsEl) {
66
64
  return;
67
65
  }
68
66
  if (this.tab) {
@@ -47,14 +47,12 @@ const Tabs = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
47
47
  //
48
48
  //--------------------------------------------------------------------------
49
49
  /**
50
- * @internal
51
50
  *
52
51
  * Stores an array of ids of `<calcite-tab-titles>`s to match up ARIA
53
52
  * attributes.
54
53
  */
55
54
  this.titles = [];
56
55
  /**
57
- * @internal
58
56
  *
59
57
  * Stores an array of ids of `<calcite-tab>`s to match up ARIA attributes.
60
58
  */
@@ -116,7 +114,6 @@ const Tabs = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
116
114
  //
117
115
  //--------------------------------------------------------------------------
118
116
  /**
119
- * @internal
120
117
  *
121
118
  * Matches up elements from the internal `tabs` and `titles` to automatically
122
119
  * update the ARIA attributes and link `<calcite-tab>` and
@@ -9479,8 +9479,9 @@ const Combobox = class extends HTMLElement$1 {
9479
9479
  this.addCustomChip(this.text, true);
9480
9480
  event.preventDefault();
9481
9481
  }
9482
- else {
9482
+ else if (this.active) {
9483
9483
  this.active = false;
9484
+ event.preventDefault();
9484
9485
  }
9485
9486
  break;
9486
9487
  case "ArrowLeft":
@@ -9499,11 +9500,20 @@ const Combobox = class extends HTMLElement$1 {
9499
9500
  this.active = true;
9500
9501
  this.shiftActiveItemIndex(1);
9501
9502
  break;
9503
+ case " ":
9504
+ if (!this.textInput.value) {
9505
+ event.preventDefault();
9506
+ this.active = true;
9507
+ this.shiftActiveItemIndex(1);
9508
+ }
9509
+ break;
9502
9510
  case "Home":
9511
+ event.preventDefault();
9503
9512
  this.active = true;
9504
9513
  this.updateActiveItemIndex(0);
9505
9514
  break;
9506
9515
  case "End":
9516
+ event.preventDefault();
9507
9517
  this.active = true;
9508
9518
  this.updateActiveItemIndex(this.visibleItems.length - 1);
9509
9519
  break;
@@ -9530,11 +9540,6 @@ const Combobox = class extends HTMLElement$1 {
9530
9540
  this.removeLastChip();
9531
9541
  }
9532
9542
  break;
9533
- default:
9534
- if (!this.active) {
9535
- this.setFocus();
9536
- }
9537
- break;
9538
9543
  }
9539
9544
  };
9540
9545
  this.toggleCloseEnd = () => {
@@ -9568,10 +9573,11 @@ const Combobox = class extends HTMLElement$1 {
9568
9573
  }
9569
9574
  this.calciteComboboxChipDismiss.emit(event.detail);
9570
9575
  };
9571
- this.setFocusClick = (event) => {
9576
+ this.clickHandler = (event) => {
9572
9577
  if (event.composedPath().some((node) => node.tagName === "CALCITE-CHIP")) {
9573
9578
  return;
9574
9579
  }
9580
+ this.active = !this.active;
9575
9581
  this.setFocus();
9576
9582
  };
9577
9583
  this.setInactiveIfNotContained = (event) => {
@@ -9579,7 +9585,7 @@ const Combobox = class extends HTMLElement$1 {
9579
9585
  if (!this.active || composedPath.includes(this.el) || composedPath.includes(this.referenceEl)) {
9580
9586
  return;
9581
9587
  }
9582
- if (this.allowCustomValues && this.text) {
9588
+ if (this.allowCustomValues && this.text.trim().length) {
9583
9589
  this.addCustomChip(this.text);
9584
9590
  }
9585
9591
  if (this.selectionMode === "single") {
@@ -9661,7 +9667,6 @@ const Combobox = class extends HTMLElement$1 {
9661
9667
  };
9662
9668
  this.comboboxFocusHandler = () => {
9663
9669
  var _a;
9664
- this.active = true;
9665
9670
  (_a = this.textInput) === null || _a === void 0 ? void 0 : _a.focus();
9666
9671
  };
9667
9672
  this.comboboxBlurHandler = (event) => {
@@ -9734,7 +9739,6 @@ const Combobox = class extends HTMLElement$1 {
9734
9739
  /** Sets focus on the component. */
9735
9740
  async setFocus() {
9736
9741
  var _a;
9737
- this.active = true;
9738
9742
  (_a = this.textInput) === null || _a === void 0 ? void 0 : _a.focus();
9739
9743
  this.activeChipIndex = -1;
9740
9744
  this.activeItemIndex = -1;
@@ -10073,7 +10077,7 @@ const Combobox = class extends HTMLElement$1 {
10073
10077
  } }, showLabel && (h("span", { class: {
10074
10078
  label: true,
10075
10079
  "label--spaced": needsIcon
10076
- }, key: "label", onFocus: this.comboboxFocusHandler, tabindex: "0" }, selectedItem.textLabel)), h("input", { "aria-activedescendant": this.activeDescendant, "aria-autocomplete": "list", "aria-controls": `${listboxUidPrefix}${guid}`, "aria-label": getLabelText(this), class: {
10080
+ }, key: "label" }, selectedItem.textLabel)), h("input", { "aria-activedescendant": this.activeDescendant, "aria-autocomplete": "list", "aria-controls": `${listboxUidPrefix}${guid}`, "aria-label": getLabelText(this), class: {
10077
10081
  input: true,
10078
10082
  "input--single": true,
10079
10083
  "input--transparent": this.activeChipIndex > -1,
@@ -10100,7 +10104,8 @@ const Combobox = class extends HTMLElement$1 {
10100
10104
  needsIcon && (h("span", { class: "icon-start" }, (selectedItem === null || selectedItem === void 0 ? void 0 : selectedItem.icon) && (h("calcite-icon", { class: "selected-icon", icon: selectedItem.icon, scale: "s" })))));
10101
10105
  }
10102
10106
  renderIconEnd() {
10103
- return (h("span", { class: "icon-end" }, h("calcite-icon", { icon: "chevron-down", scale: "s" })));
10107
+ const { active } = this;
10108
+ return (h("span", { class: "icon-end" }, h("calcite-icon", { icon: active ? "chevron-up" : "chevron-down", scale: "s" })));
10104
10109
  }
10105
10110
  render() {
10106
10111
  const { active, guid, label } = this;
@@ -10109,7 +10114,7 @@ const Combobox = class extends HTMLElement$1 {
10109
10114
  wrapper: true,
10110
10115
  "wrapper--single": single || !this.selectedItems.length,
10111
10116
  "wrapper--active": active
10112
- }, onClick: this.setFocusClick, ref: this.setReferenceEl, role: "combobox" }, h("div", { class: "grid-input" }, this.renderIconStart(), !single && this.renderChips(), h("label", { class: "screen-readers-only", htmlFor: `${inputUidPrefix}${guid}`, id: `${labelUidPrefix}${guid}` }, label), this.renderInput()), this.renderIconEnd()), h("ul", { "aria-labelledby": `${labelUidPrefix}${guid}`, "aria-multiselectable": "true", class: "screen-readers-only", id: `${listboxUidPrefix}${guid}`, role: "listbox", tabIndex: -1 }, this.renderListBoxOptions()), this.renderPopperContainer(), h(HiddenFormInputSlot, { component: this })));
10117
+ }, onClick: this.clickHandler, ref: this.setReferenceEl, role: "combobox" }, h("div", { class: "grid-input" }, this.renderIconStart(), !single && this.renderChips(), h("label", { class: "screen-readers-only", htmlFor: `${inputUidPrefix}${guid}`, id: `${labelUidPrefix}${guid}` }, label), this.renderInput()), this.renderIconEnd()), h("ul", { "aria-labelledby": `${labelUidPrefix}${guid}`, "aria-multiselectable": "true", class: "screen-readers-only", id: `${listboxUidPrefix}${guid}`, role: "listbox", tabIndex: -1 }, this.renderListBoxOptions()), this.renderPopperContainer(), h(HiddenFormInputSlot, { component: this })));
10113
10118
  }
10114
10119
  get el() { return this; }
10115
10120
  static get watchers() { return {
@@ -10136,7 +10141,7 @@ const CSS$C = {
10136
10141
  textContainer: "text-container"
10137
10142
  };
10138
10143
 
10139
- const comboboxItemCss = "@charset \"UTF-8\";@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:var(--calcite-animation-timing)}:host([hidden]){display:none}.scale--s{font-size:var(--calcite-font-size--2);line-height:1rem;--calcite-combobox-item-spacing-unit-l:0.5rem;--calcite-combobox-item-spacing-unit-s:0.25rem;--calcite-combobox-item-spacing-indent:0.5rem}.scale--m{font-size:var(--calcite-font-size--1);line-height:1rem;--calcite-combobox-item-spacing-unit-l:0.75rem;--calcite-combobox-item-spacing-unit-s:0.5rem;--calcite-combobox-item-spacing-indent:0.75rem}.scale--l{font-size:var(--calcite-font-size-0);line-height:1.25rem;--calcite-combobox-item-spacing-unit-l:1rem;--calcite-combobox-item-spacing-unit-s:0.75rem;--calcite-combobox-item-spacing-indent:1rem}.container{--calcite-combobox-item-indent-value:calc(\n var(--calcite-combobox-item-spacing-indent) * var(--calcite-combobox-item-spacing-indent-multiplier)\n )}:host(:focus){--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;-webkit-box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host([disabled]){pointer-events:none;cursor:default;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;opacity:var(--calcite-ui-opacity-disabled)}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}:host,ul{margin:0px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;padding:0px;outline:2px solid transparent;outline-offset:2px}.label{position:relative;-webkit-box-sizing:border-box;box-sizing:border-box;display:-ms-flexbox;display:flex;width:100%;min-width:100%;cursor:pointer;-ms-flex-align:center;align-items:center;color:var(--calcite-ui-text-3);-webkit-text-decoration-line:none;text-decoration-line:none;-webkit-transition-duration:150ms;transition-duration:150ms;-webkit-transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;padding:var(--calcite-combobox-item-spacing-unit-s) var(--calcite-combobox-item-spacing-unit-l)}:host([disabled]) .label{cursor:default}.label--selected{font-weight:var(--calcite-font-weight-medium);color:var(--calcite-ui-text-1)}.label--active{outline:2px solid var(--calcite-ui-brand);outline-offset:-2px}.label:hover,.label:active{background-color:var(--calcite-ui-foreground-2);color:var(--calcite-ui-text-1);-webkit-text-decoration-line:none;text-decoration-line:none;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;-webkit-box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}.title{padding:0 var(--calcite-combobox-item-spacing-unit-l)}.icon{display:-ms-inline-flexbox;display:inline-flex;opacity:0;-webkit-transition-duration:150ms;transition-duration:150ms;-webkit-transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);color:var(--calcite-ui-border-1)}.icon--indent{-webkit-padding-start:var(--calcite-combobox-item-indent-value);padding-inline-start:var(--calcite-combobox-item-indent-value)}.icon--custom{margin-top:-1px;color:var(--calcite-ui-text-3)}.icon--active{color:var(--calcite-ui-text-1)}.icon--dot{display:-ms-flexbox;display:flex;-ms-flex-pack:end;justify-content:flex-end;width:var(--calcite-combobox-item-spacing-unit-l)}.icon--dot:before{text-align:start;content:\"•\"}.label--active .icon{opacity:1}.label--selected .icon{opacity:1;color:var(--calcite-ui-brand)}:host(:hover[disabled]) .icon{opacity:1}";
10144
+ const comboboxItemCss = "@charset \"UTF-8\";@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:var(--calcite-animation-timing)}:host([hidden]){display:none}.scale--s{font-size:var(--calcite-font-size--2);line-height:1rem;--calcite-combobox-item-spacing-unit-l:0.5rem;--calcite-combobox-item-spacing-unit-s:0.25rem;--calcite-combobox-item-spacing-indent:0.5rem}.scale--m{font-size:var(--calcite-font-size--1);line-height:1rem;--calcite-combobox-item-spacing-unit-l:0.75rem;--calcite-combobox-item-spacing-unit-s:0.5rem;--calcite-combobox-item-spacing-indent:0.75rem}.scale--l{font-size:var(--calcite-font-size-0);line-height:1.25rem;--calcite-combobox-item-spacing-unit-l:1rem;--calcite-combobox-item-spacing-unit-s:0.75rem;--calcite-combobox-item-spacing-indent:1rem}.container{--calcite-combobox-item-indent-value:calc(\n var(--calcite-combobox-item-spacing-indent) * var(--calcite-combobox-item-spacing-indent-multiplier)\n )}:host(:focus){--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;-webkit-box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host([disabled]){pointer-events:none;cursor:default;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;opacity:var(--calcite-ui-opacity-disabled)}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}:host,ul{margin:0px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;padding:0px;outline:2px solid transparent;outline-offset:2px}.label{position:relative;-webkit-box-sizing:border-box;box-sizing:border-box;display:-ms-flexbox;display:flex;width:100%;min-width:100%;cursor:pointer;-ms-flex-align:center;align-items:center;color:var(--calcite-ui-text-3);-webkit-text-decoration-line:none;text-decoration-line:none;-webkit-transition-duration:150ms;transition-duration:150ms;-webkit-transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;padding:var(--calcite-combobox-item-spacing-unit-s) var(--calcite-combobox-item-spacing-unit-l)}:host([disabled]) .label{cursor:default}.label--selected{font-weight:var(--calcite-font-weight-medium);color:var(--calcite-ui-text-1)}.label--active{outline:2px solid var(--calcite-ui-brand);outline-offset:-2px}.label:hover,.label:active{background-color:var(--calcite-ui-foreground-2);color:var(--calcite-ui-text-1);-webkit-text-decoration-line:none;text-decoration-line:none;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;-webkit-box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}.title{padding:0 var(--calcite-combobox-item-spacing-unit-l)}.icon{display:-ms-inline-flexbox;display:inline-flex;opacity:0;-webkit-transition-duration:150ms;transition-duration:150ms;-webkit-transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);color:var(--calcite-ui-border-1)}.icon--indent{-webkit-padding-start:var(--calcite-combobox-item-indent-value);padding-inline-start:var(--calcite-combobox-item-indent-value)}.icon--custom{margin-top:-1px;color:var(--calcite-ui-text-3)}.icon--active{color:var(--calcite-ui-text-1)}.icon--dot{display:-ms-flexbox;display:flex;-ms-flex-pack:end;justify-content:flex-end;min-width:var(--calcite-combobox-item-spacing-unit-l)}.icon--dot:before{text-align:start;content:\"•\"}.label--active .icon{opacity:1}.label--selected .icon{opacity:1;color:var(--calcite-ui-brand)}:host(:hover[disabled]) .icon{opacity:1}";
10140
10145
 
10141
10146
  const ComboboxItem = class extends HTMLElement$1 {
10142
10147
  constructor() {
@@ -15245,7 +15250,7 @@ const Modal = class extends HTMLElement$1 {
15245
15250
  });
15246
15251
  };
15247
15252
  this.focusFirstElement = () => {
15248
- focusElement(this.closeButtonEl);
15253
+ focusElement(this.disableCloseButton ? getFocusableElements(this.el)[0] : this.closeButtonEl);
15249
15254
  };
15250
15255
  this.focusLastElement = () => {
15251
15256
  const focusableElements = getFocusableElements(this.el).filter((el) => !el.getAttribute("data-focus-fence"));
@@ -22974,14 +22979,6 @@ const Tab = class extends HTMLElement$1 {
22974
22979
  this.active = false;
22975
22980
  /** @internal Parent tabs component scale value */
22976
22981
  this.scale = "m";
22977
- //--------------------------------------------------------------------------
22978
- //
22979
- // Private State/Props
22980
- //
22981
- //--------------------------------------------------------------------------
22982
- /**
22983
- * @internal
22984
- */
22985
22982
  this.guid = `calcite-tab-title-${guid()}`;
22986
22983
  }
22987
22984
  //--------------------------------------------------------------------------
@@ -22993,12 +22990,15 @@ const Tab = class extends HTMLElement$1 {
22993
22990
  const id = this.el.id || this.guid;
22994
22991
  return (h(Host, { "aria-expanded": this.active.toString(), "aria-labelledby": this.labeledBy, id: id, role: "tabpanel" }, h("section", null, h("slot", null))));
22995
22992
  }
22993
+ connectedCallback() {
22994
+ this.parentTabsEl = this.el.closest("calcite-tabs");
22995
+ }
22996
22996
  componentDidLoad() {
22997
22997
  this.calciteTabRegister.emit();
22998
22998
  }
22999
22999
  componentWillRender() {
23000
23000
  var _a;
23001
- this.scale = (_a = this.el.closest("calcite-tabs")) === null || _a === void 0 ? void 0 : _a.scale;
23001
+ this.scale = (_a = this.parentTabsEl) === null || _a === void 0 ? void 0 : _a.scale;
23002
23002
  }
23003
23003
  disconnectedCallback() {
23004
23004
  var _a;
@@ -23013,10 +23013,13 @@ const Tab = class extends HTMLElement$1 {
23013
23013
  //
23014
23014
  //--------------------------------------------------------------------------
23015
23015
  tabChangeHandler(event) {
23016
+ const targetTabsEl = event
23017
+ .composedPath()
23018
+ .find((el) => el.tagName === "CALCITE-TABS");
23016
23019
  // to allow `<calcite-tabs>` to be nested we need to make sure this
23017
- // `calciteTabChange` event was actually fired from a title that is a
23018
- // child of the `<calcite-tabs>` that is the a parent of this tab.
23019
- if (!event.composedPath().includes(this.el.closest("calcite-tabs"))) {
23020
+ // `calciteTabChange` event was actually fired from a within the same
23021
+ // `<calcite-tabs>` that is the a parent of this tab.
23022
+ if (targetTabsEl !== this.parentTabsEl) {
23020
23023
  return;
23021
23024
  }
23022
23025
  if (this.tab) {
@@ -23105,6 +23108,9 @@ const TabNav = class extends HTMLElement$1 {
23105
23108
  // Lifecycle
23106
23109
  //
23107
23110
  //--------------------------------------------------------------------------
23111
+ connectedCallback() {
23112
+ this.parentTabsEl = this.el.closest("calcite-tabs");
23113
+ }
23108
23114
  componentWillLoad() {
23109
23115
  const storageKey = `calcite-tab-nav-${this.storageId}`;
23110
23116
  if (localStorage && this.storageId && localStorage.getItem(storageKey)) {
@@ -23116,11 +23122,11 @@ const TabNav = class extends HTMLElement$1 {
23116
23122
  }
23117
23123
  }
23118
23124
  componentWillRender() {
23119
- var _a, _b, _c, _d;
23120
- this.layout = (_a = this.el.closest("calcite-tabs")) === null || _a === void 0 ? void 0 : _a.layout;
23121
- this.position = (_b = this.el.closest("calcite-tabs")) === null || _b === void 0 ? void 0 : _b.position;
23122
- this.scale = (_c = this.el.closest("calcite-tabs")) === null || _c === void 0 ? void 0 : _c.scale;
23123
- this.bordered = (_d = this.el.closest("calcite-tabs")) === null || _d === void 0 ? void 0 : _d.bordered;
23125
+ const { parentTabsEl } = this;
23126
+ this.layout = parentTabsEl === null || parentTabsEl === void 0 ? void 0 : parentTabsEl.layout;
23127
+ this.position = parentTabsEl === null || parentTabsEl === void 0 ? void 0 : parentTabsEl.position;
23128
+ this.scale = parentTabsEl === null || parentTabsEl === void 0 ? void 0 : parentTabsEl.scale;
23129
+ this.bordered = parentTabsEl === null || parentTabsEl === void 0 ? void 0 : parentTabsEl.bordered;
23124
23130
  // fix issue with active tab-title not lining up with blue indicator
23125
23131
  if (this.selectedTabEl) {
23126
23132
  this.updateOffsetPosition();
@@ -23263,9 +23269,6 @@ const TabTitle = class extends HTMLElement$1 {
23263
23269
  this.mutationObserver = createObserver("mutation", () => this.updateHasText());
23264
23270
  /** determine if there is slotted text for styling purposes */
23265
23271
  this.hasText = false;
23266
- /**
23267
- * @internal
23268
- */
23269
23272
  this.guid = `calcite-tab-title-${guid()}`;
23270
23273
  }
23271
23274
  activeTabChanged() {
@@ -23334,15 +23337,19 @@ const TabTitle = class extends HTMLElement$1 {
23334
23337
  //
23335
23338
  //--------------------------------------------------------------------------
23336
23339
  tabChangeHandler(event) {
23337
- if (event.composedPath().includes(this.parentTabNavEl)) {
23338
- if (this.tab) {
23339
- this.active = this.tab === event.detail.tab;
23340
- }
23341
- else {
23342
- this.getTabIndex().then((index) => {
23343
- this.active = index === event.detail.tab;
23344
- });
23345
- }
23340
+ const targetTabsEl = event
23341
+ .composedPath()
23342
+ .find((el) => el.tagName === "CALCITE-TABS");
23343
+ if (targetTabsEl !== this.parentTabsEl) {
23344
+ return;
23345
+ }
23346
+ if (this.tab) {
23347
+ this.active = this.tab === event.detail.tab;
23348
+ }
23349
+ else {
23350
+ this.getTabIndex().then((index) => {
23351
+ this.active = index === event.detail.tab;
23352
+ });
23346
23353
  }
23347
23354
  }
23348
23355
  onClick() {
@@ -23460,14 +23467,12 @@ const Tabs = class extends HTMLElement$1 {
23460
23467
  //
23461
23468
  //--------------------------------------------------------------------------
23462
23469
  /**
23463
- * @internal
23464
23470
  *
23465
23471
  * Stores an array of ids of `<calcite-tab-titles>`s to match up ARIA
23466
23472
  * attributes.
23467
23473
  */
23468
23474
  this.titles = [];
23469
23475
  /**
23470
- * @internal
23471
23476
  *
23472
23477
  * Stores an array of ids of `<calcite-tab>`s to match up ARIA attributes.
23473
23478
  */
@@ -23529,7 +23534,6 @@ const Tabs = class extends HTMLElement$1 {
23529
23534
  //
23530
23535
  //--------------------------------------------------------------------------
23531
23536
  /**
23532
- * @internal
23533
23537
  *
23534
23538
  * Matches up elements from the internal `tabs` and `titles` to automatically
23535
23539
  * update the ARIA attributes and link `<calcite-tab>` and
@@ -275,8 +275,9 @@ const Combobox = class {
275
275
  this.addCustomChip(this.text, true);
276
276
  event.preventDefault();
277
277
  }
278
- else {
278
+ else if (this.active) {
279
279
  this.active = false;
280
+ event.preventDefault();
280
281
  }
281
282
  break;
282
283
  case "ArrowLeft":
@@ -295,11 +296,20 @@ const Combobox = class {
295
296
  this.active = true;
296
297
  this.shiftActiveItemIndex(1);
297
298
  break;
299
+ case " ":
300
+ if (!this.textInput.value) {
301
+ event.preventDefault();
302
+ this.active = true;
303
+ this.shiftActiveItemIndex(1);
304
+ }
305
+ break;
298
306
  case "Home":
307
+ event.preventDefault();
299
308
  this.active = true;
300
309
  this.updateActiveItemIndex(0);
301
310
  break;
302
311
  case "End":
312
+ event.preventDefault();
303
313
  this.active = true;
304
314
  this.updateActiveItemIndex(this.visibleItems.length - 1);
305
315
  break;
@@ -326,11 +336,6 @@ const Combobox = class {
326
336
  this.removeLastChip();
327
337
  }
328
338
  break;
329
- default:
330
- if (!this.active) {
331
- this.setFocus();
332
- }
333
- break;
334
339
  }
335
340
  };
336
341
  this.toggleCloseEnd = () => {
@@ -364,10 +369,11 @@ const Combobox = class {
364
369
  }
365
370
  this.calciteComboboxChipDismiss.emit(event.detail);
366
371
  };
367
- this.setFocusClick = (event) => {
372
+ this.clickHandler = (event) => {
368
373
  if (event.composedPath().some((node) => node.tagName === "CALCITE-CHIP")) {
369
374
  return;
370
375
  }
376
+ this.active = !this.active;
371
377
  this.setFocus();
372
378
  };
373
379
  this.setInactiveIfNotContained = (event) => {
@@ -375,7 +381,7 @@ const Combobox = class {
375
381
  if (!this.active || composedPath.includes(this.el) || composedPath.includes(this.referenceEl)) {
376
382
  return;
377
383
  }
378
- if (this.allowCustomValues && this.text) {
384
+ if (this.allowCustomValues && this.text.trim().length) {
379
385
  this.addCustomChip(this.text);
380
386
  }
381
387
  if (this.selectionMode === "single") {
@@ -457,7 +463,6 @@ const Combobox = class {
457
463
  };
458
464
  this.comboboxFocusHandler = () => {
459
465
  var _a;
460
- this.active = true;
461
466
  (_a = this.textInput) === null || _a === void 0 ? void 0 : _a.focus();
462
467
  };
463
468
  this.comboboxBlurHandler = (event) => {
@@ -530,7 +535,6 @@ const Combobox = class {
530
535
  /** Sets focus on the component. */
531
536
  async setFocus() {
532
537
  var _a;
533
- this.active = true;
534
538
  (_a = this.textInput) === null || _a === void 0 ? void 0 : _a.focus();
535
539
  this.activeChipIndex = -1;
536
540
  this.activeItemIndex = -1;
@@ -869,7 +873,7 @@ const Combobox = class {
869
873
  } }, showLabel && (h("span", { class: {
870
874
  label: true,
871
875
  "label--spaced": needsIcon
872
- }, key: "label", onFocus: this.comboboxFocusHandler, tabindex: "0" }, selectedItem.textLabel)), h("input", { "aria-activedescendant": this.activeDescendant, "aria-autocomplete": "list", "aria-controls": `${listboxUidPrefix}${guid}`, "aria-label": getLabelText(this), class: {
876
+ }, key: "label" }, selectedItem.textLabel)), h("input", { "aria-activedescendant": this.activeDescendant, "aria-autocomplete": "list", "aria-controls": `${listboxUidPrefix}${guid}`, "aria-label": getLabelText(this), class: {
873
877
  input: true,
874
878
  "input--single": true,
875
879
  "input--transparent": this.activeChipIndex > -1,
@@ -896,7 +900,8 @@ const Combobox = class {
896
900
  needsIcon && (h("span", { class: "icon-start" }, (selectedItem === null || selectedItem === void 0 ? void 0 : selectedItem.icon) && (h("calcite-icon", { class: "selected-icon", icon: selectedItem.icon, scale: "s" })))));
897
901
  }
898
902
  renderIconEnd() {
899
- return (h("span", { class: "icon-end" }, h("calcite-icon", { icon: "chevron-down", scale: "s" })));
903
+ const { active } = this;
904
+ return (h("span", { class: "icon-end" }, h("calcite-icon", { icon: active ? "chevron-up" : "chevron-down", scale: "s" })));
900
905
  }
901
906
  render() {
902
907
  const { active, guid, label } = this;
@@ -905,7 +910,7 @@ const Combobox = class {
905
910
  wrapper: true,
906
911
  "wrapper--single": single || !this.selectedItems.length,
907
912
  "wrapper--active": active
908
- }, onClick: this.setFocusClick, ref: this.setReferenceEl, role: "combobox" }, h("div", { class: "grid-input" }, this.renderIconStart(), !single && this.renderChips(), h("label", { class: "screen-readers-only", htmlFor: `${inputUidPrefix}${guid}`, id: `${labelUidPrefix}${guid}` }, label), this.renderInput()), this.renderIconEnd()), h("ul", { "aria-labelledby": `${labelUidPrefix}${guid}`, "aria-multiselectable": "true", class: "screen-readers-only", id: `${listboxUidPrefix}${guid}`, role: "listbox", tabIndex: -1 }, this.renderListBoxOptions()), this.renderPopperContainer(), h(HiddenFormInputSlot, { component: this })));
913
+ }, onClick: this.clickHandler, ref: this.setReferenceEl, role: "combobox" }, h("div", { class: "grid-input" }, this.renderIconStart(), !single && this.renderChips(), h("label", { class: "screen-readers-only", htmlFor: `${inputUidPrefix}${guid}`, id: `${labelUidPrefix}${guid}` }, label), this.renderInput()), this.renderIconEnd()), h("ul", { "aria-labelledby": `${labelUidPrefix}${guid}`, "aria-multiselectable": "true", class: "screen-readers-only", id: `${listboxUidPrefix}${guid}`, role: "listbox", tabIndex: -1 }, this.renderListBoxOptions()), this.renderPopperContainer(), h(HiddenFormInputSlot, { component: this })));
909
914
  }
910
915
  get el() { return getElement(this); }
911
916
  static get watchers() { return {
@@ -932,7 +937,7 @@ const CSS$1 = {
932
937
  textContainer: "text-container"
933
938
  };
934
939
 
935
- const comboboxItemCss = "@charset \"UTF-8\";@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:var(--calcite-animation-timing)}:host([hidden]){display:none}.scale--s{font-size:var(--calcite-font-size--2);line-height:1rem;--calcite-combobox-item-spacing-unit-l:0.5rem;--calcite-combobox-item-spacing-unit-s:0.25rem;--calcite-combobox-item-spacing-indent:0.5rem}.scale--m{font-size:var(--calcite-font-size--1);line-height:1rem;--calcite-combobox-item-spacing-unit-l:0.75rem;--calcite-combobox-item-spacing-unit-s:0.5rem;--calcite-combobox-item-spacing-indent:0.75rem}.scale--l{font-size:var(--calcite-font-size-0);line-height:1.25rem;--calcite-combobox-item-spacing-unit-l:1rem;--calcite-combobox-item-spacing-unit-s:0.75rem;--calcite-combobox-item-spacing-indent:1rem}.container{--calcite-combobox-item-indent-value:calc(\n var(--calcite-combobox-item-spacing-indent) * var(--calcite-combobox-item-spacing-indent-multiplier)\n )}:host(:focus){--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;-webkit-box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host([disabled]){pointer-events:none;cursor:default;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;opacity:var(--calcite-ui-opacity-disabled)}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}:host,ul{margin:0px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;padding:0px;outline:2px solid transparent;outline-offset:2px}.label{position:relative;-webkit-box-sizing:border-box;box-sizing:border-box;display:-ms-flexbox;display:flex;width:100%;min-width:100%;cursor:pointer;-ms-flex-align:center;align-items:center;color:var(--calcite-ui-text-3);-webkit-text-decoration-line:none;text-decoration-line:none;-webkit-transition-duration:150ms;transition-duration:150ms;-webkit-transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;padding:var(--calcite-combobox-item-spacing-unit-s) var(--calcite-combobox-item-spacing-unit-l)}:host([disabled]) .label{cursor:default}.label--selected{font-weight:var(--calcite-font-weight-medium);color:var(--calcite-ui-text-1)}.label--active{outline:2px solid var(--calcite-ui-brand);outline-offset:-2px}.label:hover,.label:active{background-color:var(--calcite-ui-foreground-2);color:var(--calcite-ui-text-1);-webkit-text-decoration-line:none;text-decoration-line:none;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;-webkit-box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}.title{padding:0 var(--calcite-combobox-item-spacing-unit-l)}.icon{display:-ms-inline-flexbox;display:inline-flex;opacity:0;-webkit-transition-duration:150ms;transition-duration:150ms;-webkit-transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);color:var(--calcite-ui-border-1)}.icon--indent{-webkit-padding-start:var(--calcite-combobox-item-indent-value);padding-inline-start:var(--calcite-combobox-item-indent-value)}.icon--custom{margin-top:-1px;color:var(--calcite-ui-text-3)}.icon--active{color:var(--calcite-ui-text-1)}.icon--dot{display:-ms-flexbox;display:flex;-ms-flex-pack:end;justify-content:flex-end;width:var(--calcite-combobox-item-spacing-unit-l)}.icon--dot:before{text-align:start;content:\"•\"}.label--active .icon{opacity:1}.label--selected .icon{opacity:1;color:var(--calcite-ui-brand)}:host(:hover[disabled]) .icon{opacity:1}";
940
+ const comboboxItemCss = "@charset \"UTF-8\";@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:var(--calcite-animation-timing)}:host([hidden]){display:none}.scale--s{font-size:var(--calcite-font-size--2);line-height:1rem;--calcite-combobox-item-spacing-unit-l:0.5rem;--calcite-combobox-item-spacing-unit-s:0.25rem;--calcite-combobox-item-spacing-indent:0.5rem}.scale--m{font-size:var(--calcite-font-size--1);line-height:1rem;--calcite-combobox-item-spacing-unit-l:0.75rem;--calcite-combobox-item-spacing-unit-s:0.5rem;--calcite-combobox-item-spacing-indent:0.75rem}.scale--l{font-size:var(--calcite-font-size-0);line-height:1.25rem;--calcite-combobox-item-spacing-unit-l:1rem;--calcite-combobox-item-spacing-unit-s:0.75rem;--calcite-combobox-item-spacing-indent:1rem}.container{--calcite-combobox-item-indent-value:calc(\n var(--calcite-combobox-item-spacing-indent) * var(--calcite-combobox-item-spacing-indent-multiplier)\n )}:host(:focus){--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;-webkit-box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host([disabled]){pointer-events:none;cursor:default;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;opacity:var(--calcite-ui-opacity-disabled)}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}:host,ul{margin:0px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;padding:0px;outline:2px solid transparent;outline-offset:2px}.label{position:relative;-webkit-box-sizing:border-box;box-sizing:border-box;display:-ms-flexbox;display:flex;width:100%;min-width:100%;cursor:pointer;-ms-flex-align:center;align-items:center;color:var(--calcite-ui-text-3);-webkit-text-decoration-line:none;text-decoration-line:none;-webkit-transition-duration:150ms;transition-duration:150ms;-webkit-transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;padding:var(--calcite-combobox-item-spacing-unit-s) var(--calcite-combobox-item-spacing-unit-l)}:host([disabled]) .label{cursor:default}.label--selected{font-weight:var(--calcite-font-weight-medium);color:var(--calcite-ui-text-1)}.label--active{outline:2px solid var(--calcite-ui-brand);outline-offset:-2px}.label:hover,.label:active{background-color:var(--calcite-ui-foreground-2);color:var(--calcite-ui-text-1);-webkit-text-decoration-line:none;text-decoration-line:none;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;-webkit-box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}.title{padding:0 var(--calcite-combobox-item-spacing-unit-l)}.icon{display:-ms-inline-flexbox;display:inline-flex;opacity:0;-webkit-transition-duration:150ms;transition-duration:150ms;-webkit-transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);color:var(--calcite-ui-border-1)}.icon--indent{-webkit-padding-start:var(--calcite-combobox-item-indent-value);padding-inline-start:var(--calcite-combobox-item-indent-value)}.icon--custom{margin-top:-1px;color:var(--calcite-ui-text-3)}.icon--active{color:var(--calcite-ui-text-1)}.icon--dot{display:-ms-flexbox;display:flex;-ms-flex-pack:end;justify-content:flex-end;min-width:var(--calcite-combobox-item-spacing-unit-l)}.icon--dot:before{text-align:start;content:\"•\"}.label--active .icon{opacity:1}.label--selected .icon{opacity:1;color:var(--calcite-ui-brand)}:host(:hover[disabled]) .icon{opacity:1}";
936
941
 
937
942
  const ComboboxItem = class {
938
943
  constructor(hostRef) {
@@ -211,7 +211,7 @@ const Modal = class {
211
211
  });
212
212
  };
213
213
  this.focusFirstElement = () => {
214
- focusElement(this.closeButtonEl);
214
+ focusElement(this.disableCloseButton ? getFocusableElements(this.el)[0] : this.closeButtonEl);
215
215
  };
216
216
  this.focusLastElement = () => {
217
217
  const focusableElements = getFocusableElements(this.el).filter((el) => !el.getAttribute("data-focus-fence"));
@@ -20,14 +20,6 @@ const Tab = class {
20
20
  this.active = false;
21
21
  /** @internal Parent tabs component scale value */
22
22
  this.scale = "m";
23
- //--------------------------------------------------------------------------
24
- //
25
- // Private State/Props
26
- //
27
- //--------------------------------------------------------------------------
28
- /**
29
- * @internal
30
- */
31
23
  this.guid = `calcite-tab-title-${guid()}`;
32
24
  }
33
25
  //--------------------------------------------------------------------------
@@ -39,12 +31,15 @@ const Tab = class {
39
31
  const id = this.el.id || this.guid;
40
32
  return (h(Host, { "aria-expanded": this.active.toString(), "aria-labelledby": this.labeledBy, id: id, role: "tabpanel" }, h("section", null, h("slot", null))));
41
33
  }
34
+ connectedCallback() {
35
+ this.parentTabsEl = this.el.closest("calcite-tabs");
36
+ }
42
37
  componentDidLoad() {
43
38
  this.calciteTabRegister.emit();
44
39
  }
45
40
  componentWillRender() {
46
41
  var _a;
47
- this.scale = (_a = this.el.closest("calcite-tabs")) === null || _a === void 0 ? void 0 : _a.scale;
42
+ this.scale = (_a = this.parentTabsEl) === null || _a === void 0 ? void 0 : _a.scale;
48
43
  }
49
44
  disconnectedCallback() {
50
45
  var _a;
@@ -59,10 +54,13 @@ const Tab = class {
59
54
  //
60
55
  //--------------------------------------------------------------------------
61
56
  tabChangeHandler(event) {
57
+ const targetTabsEl = event
58
+ .composedPath()
59
+ .find((el) => el.tagName === "CALCITE-TABS");
62
60
  // to allow `<calcite-tabs>` to be nested we need to make sure this
63
- // `calciteTabChange` event was actually fired from a title that is a
64
- // child of the `<calcite-tabs>` that is the a parent of this tab.
65
- if (!event.composedPath().includes(this.el.closest("calcite-tabs"))) {
61
+ // `calciteTabChange` event was actually fired from a within the same
62
+ // `<calcite-tabs>` that is the a parent of this tab.
63
+ if (targetTabsEl !== this.parentTabsEl) {
66
64
  return;
67
65
  }
68
66
  if (this.tab) {
@@ -149,6 +147,9 @@ const TabNav = class {
149
147
  // Lifecycle
150
148
  //
151
149
  //--------------------------------------------------------------------------
150
+ connectedCallback() {
151
+ this.parentTabsEl = this.el.closest("calcite-tabs");
152
+ }
152
153
  componentWillLoad() {
153
154
  const storageKey = `calcite-tab-nav-${this.storageId}`;
154
155
  if (localStorage && this.storageId && localStorage.getItem(storageKey)) {
@@ -160,11 +161,11 @@ const TabNav = class {
160
161
  }
161
162
  }
162
163
  componentWillRender() {
163
- var _a, _b, _c, _d;
164
- this.layout = (_a = this.el.closest("calcite-tabs")) === null || _a === void 0 ? void 0 : _a.layout;
165
- this.position = (_b = this.el.closest("calcite-tabs")) === null || _b === void 0 ? void 0 : _b.position;
166
- this.scale = (_c = this.el.closest("calcite-tabs")) === null || _c === void 0 ? void 0 : _c.scale;
167
- this.bordered = (_d = this.el.closest("calcite-tabs")) === null || _d === void 0 ? void 0 : _d.bordered;
164
+ const { parentTabsEl } = this;
165
+ this.layout = parentTabsEl === null || parentTabsEl === void 0 ? void 0 : parentTabsEl.layout;
166
+ this.position = parentTabsEl === null || parentTabsEl === void 0 ? void 0 : parentTabsEl.position;
167
+ this.scale = parentTabsEl === null || parentTabsEl === void 0 ? void 0 : parentTabsEl.scale;
168
+ this.bordered = parentTabsEl === null || parentTabsEl === void 0 ? void 0 : parentTabsEl.bordered;
168
169
  // fix issue with active tab-title not lining up with blue indicator
169
170
  if (this.selectedTabEl) {
170
171
  this.updateOffsetPosition();
@@ -305,9 +306,6 @@ const TabTitle = class {
305
306
  this.mutationObserver = createObserver("mutation", () => this.updateHasText());
306
307
  /** determine if there is slotted text for styling purposes */
307
308
  this.hasText = false;
308
- /**
309
- * @internal
310
- */
311
309
  this.guid = `calcite-tab-title-${guid()}`;
312
310
  }
313
311
  activeTabChanged() {
@@ -376,15 +374,19 @@ const TabTitle = class {
376
374
  //
377
375
  //--------------------------------------------------------------------------
378
376
  tabChangeHandler(event) {
379
- if (event.composedPath().includes(this.parentTabNavEl)) {
380
- if (this.tab) {
381
- this.active = this.tab === event.detail.tab;
382
- }
383
- else {
384
- this.getTabIndex().then((index) => {
385
- this.active = index === event.detail.tab;
386
- });
387
- }
377
+ const targetTabsEl = event
378
+ .composedPath()
379
+ .find((el) => el.tagName === "CALCITE-TABS");
380
+ if (targetTabsEl !== this.parentTabsEl) {
381
+ return;
382
+ }
383
+ if (this.tab) {
384
+ this.active = this.tab === event.detail.tab;
385
+ }
386
+ else {
387
+ this.getTabIndex().then((index) => {
388
+ this.active = index === event.detail.tab;
389
+ });
388
390
  }
389
391
  }
390
392
  onClick() {
@@ -500,14 +502,12 @@ const Tabs = class {
500
502
  //
501
503
  //--------------------------------------------------------------------------
502
504
  /**
503
- * @internal
504
505
  *
505
506
  * Stores an array of ids of `<calcite-tab-titles>`s to match up ARIA
506
507
  * attributes.
507
508
  */
508
509
  this.titles = [];
509
510
  /**
510
- * @internal
511
511
  *
512
512
  * Stores an array of ids of `<calcite-tab>`s to match up ARIA attributes.
513
513
  */
@@ -569,7 +569,6 @@ const Tabs = class {
569
569
  //
570
570
  //--------------------------------------------------------------------------
571
571
  /**
572
- * @internal
573
572
  *
574
573
  * Matches up elements from the internal `tabs` and `titles` to automatically
575
574
  * update the ARIA attributes and link `<calcite-tab>` and