@usecapsule/core-components 3.0.1-dev.1 → 3.0.1-dev.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (69) hide show
  1. package/css/capsule-core.css +4 -4
  2. package/dist/capsule/capsule.esm.js +1 -1
  3. package/dist/capsule/capsule.esm.js.map +1 -1
  4. package/dist/capsule/p-397edab5.entry.js +2 -0
  5. package/dist/capsule/{p-73398222.entry.js → p-52d6ebee.entry.js} +2 -2
  6. package/dist/capsule/{p-39584a7b.entry.js → p-5ed5e96c.entry.js} +2 -2
  7. package/dist/capsule/{p-97c33636.js → p-6e71539d.js} +1 -1
  8. package/dist/{esm/index-97ed6ec1.js.map → capsule/p-6e71539d.js.map} +1 -1
  9. package/dist/capsule/{p-127ac658.entry.js → p-70f95c93.entry.js} +2 -2
  10. package/dist/capsule/{p-69756614.entry.js → p-86e6cba5.entry.js} +2 -2
  11. package/dist/capsule/{p-8de15b15.entry.js → p-a7db40a8.entry.js} +3 -3
  12. package/dist/capsule/p-a7db40a8.entry.js.map +1 -0
  13. package/dist/capsule/{p-fd26ce6e.entry.js → p-f9351426.entry.js} +2 -2
  14. package/dist/cjs/capsule.cjs.js +2 -2
  15. package/dist/cjs/capsule.cjs.js.map +1 -1
  16. package/dist/cjs/cpsl-alert_33.cjs.entry.js +39 -20
  17. package/dist/cjs/cpsl-alert_33.cjs.entry.js.map +1 -1
  18. package/dist/cjs/cpsl-animation.cjs.entry.js +1 -1
  19. package/dist/cjs/cpsl-col.cjs.entry.js +1 -1
  20. package/dist/cjs/cpsl-grid.cjs.entry.js +1 -1
  21. package/dist/cjs/cpsl-info-box.cjs.entry.js +1 -1
  22. package/dist/cjs/cpsl-modal-v2.cjs.entry.js +1 -1
  23. package/dist/cjs/cpsl-row.cjs.entry.js +1 -1
  24. package/dist/cjs/{index-5293d431.js → index-85125285.js} +1 -1
  25. package/dist/cjs/index-85125285.js.map +1 -0
  26. package/dist/cjs/loader.cjs.js +2 -2
  27. package/dist/collection/components/cpsl-popover/cpsl-popover.js +47 -6
  28. package/dist/collection/components/cpsl-popover/cpsl-popover.js.map +1 -1
  29. package/dist/collection/components/cpsl-select/cpsl-select.css +2 -0
  30. package/dist/collection/components/cpsl-select/cpsl-select.js +17 -1
  31. package/dist/collection/components/cpsl-select/cpsl-select.js.map +1 -1
  32. package/dist/collection/components/cpsl-select-item/cpsl-select-item.css +22 -12
  33. package/dist/collection/components/cpsl-select-item/cpsl-select-item.js +1 -1
  34. package/dist/collection/components/cpsl-select-item/cpsl-select-item.js.map +1 -1
  35. package/dist/collection/components/cpsl-slide-button/cpsl-slide-button.js +1 -1
  36. package/dist/collection/components/cpsl-spinner/cpsl-spinner.js +2 -2
  37. package/dist/collection/components/cpsl-switch/cpsl-switch.js +1 -1
  38. package/dist/collection/components/cpsl-tab/cpsl-tab.js +1 -1
  39. package/dist/collection/components/cpsl-table/cpsl-table.js +1 -1
  40. package/dist/collection/components/cpsl-tabs/cpsl-tabs.js +1 -1
  41. package/dist/collection/components/cpsl-text/cpsl-text.js +1 -1
  42. package/dist/collection/components/cpsl-tile-button/cpsl-tile-button.js +1 -1
  43. package/dist/esm/capsule.js +3 -3
  44. package/dist/esm/capsule.js.map +1 -1
  45. package/dist/esm/cpsl-alert_33.entry.js +39 -20
  46. package/dist/esm/cpsl-alert_33.entry.js.map +1 -1
  47. package/dist/esm/cpsl-animation.entry.js +1 -1
  48. package/dist/esm/cpsl-col.entry.js +1 -1
  49. package/dist/esm/cpsl-grid.entry.js +1 -1
  50. package/dist/esm/cpsl-info-box.entry.js +1 -1
  51. package/dist/esm/cpsl-modal-v2.entry.js +1 -1
  52. package/dist/esm/cpsl-row.entry.js +1 -1
  53. package/dist/esm/{index-97ed6ec1.js → index-b9a060b3.js} +1 -1
  54. package/dist/esm/index-b9a060b3.js.map +1 -0
  55. package/dist/esm/loader.js +3 -3
  56. package/dist/types/components/cpsl-popover/cpsl-popover.d.ts +2 -0
  57. package/dist/types/components/cpsl-select/cpsl-select.d.ts +3 -0
  58. package/dist/types/components.d.ts +16 -0
  59. package/package.json +1 -1
  60. package/dist/capsule/p-8de15b15.entry.js.map +0 -1
  61. package/dist/capsule/p-97c33636.js.map +0 -1
  62. package/dist/capsule/p-f72482c3.entry.js +0 -2
  63. package/dist/cjs/index-5293d431.js.map +0 -1
  64. /package/dist/capsule/{p-f72482c3.entry.js.map → p-397edab5.entry.js.map} +0 -0
  65. /package/dist/capsule/{p-73398222.entry.js.map → p-52d6ebee.entry.js.map} +0 -0
  66. /package/dist/capsule/{p-39584a7b.entry.js.map → p-5ed5e96c.entry.js.map} +0 -0
  67. /package/dist/capsule/{p-127ac658.entry.js.map → p-70f95c93.entry.js.map} +0 -0
  68. /package/dist/capsule/{p-69756614.entry.js.map → p-86e6cba5.entry.js.map} +0 -0
  69. /package/dist/capsule/{p-fd26ce6e.entry.js.map → p-f9351426.entry.js.map} +0 -0
@@ -1,4 +1,4 @@
1
- import { r as registerInstance, h, H as Host, g as getElement, c as createEvent, F as Fragment } from './index-97ed6ec1.js';
1
+ import { r as registerInstance, h, H as Host, g as getElement, c as createEvent, F as Fragment } from './index-b9a060b3.js';
2
2
  import { a as DEFAULT_Z_INDICES, M as MOBILE_SIZE } from './constants-fce138fa.js';
3
3
  import { g as getDefaultExportFromCjs } from './_commonjsHelpers-1789f0cf.js';
4
4
 
@@ -15081,12 +15081,14 @@ const CpslPopover = class {
15081
15081
  };
15082
15082
  };
15083
15083
  this.setPosition = () => {
15084
- if (Boolean(this.triggerEl)) {
15084
+ var _a;
15085
+ const anchorEl = (_a = this.anchorEl) !== null && _a !== void 0 ? _a : this.triggerEl;
15086
+ if (Boolean(anchorEl)) {
15085
15087
  const windowWidth = window.innerWidth;
15086
15088
  const windowHeight = window.innerHeight;
15087
15089
  const elWidth = this.el.clientWidth;
15088
15090
  const elHeight = this.el.clientHeight;
15089
- const { top, left, height, width } = this.triggerEl.getBoundingClientRect();
15091
+ const { top, left, height, width } = anchorEl.getBoundingClientRect();
15090
15092
  switch (this.anchorOriginHorizontal) {
15091
15093
  case 'left': {
15092
15094
  this.positionX = left;
@@ -15140,7 +15142,7 @@ const CpslPopover = class {
15140
15142
  }
15141
15143
  };
15142
15144
  this.present = () => {
15143
- if (!this.open) {
15145
+ if (!this.open && !this.disabled) {
15144
15146
  this.open = true;
15145
15147
  this.cpslOpen.emit();
15146
15148
  this.setPosition();
@@ -15154,9 +15156,11 @@ const CpslPopover = class {
15154
15156
  this.open = false;
15155
15157
  this.positionX = undefined;
15156
15158
  this.positionY = undefined;
15159
+ this.anchorEl = undefined;
15157
15160
  this.anchorOriginHorizontal = 'left';
15158
15161
  this.anchorOriginVertical = 'bottom';
15159
15162
  this.autoWidth = true;
15163
+ this.disabled = undefined;
15160
15164
  this.preventBlur = undefined;
15161
15165
  this.transformOriginHorizontal = 'left';
15162
15166
  this.transformOriginVertical = 'top';
@@ -15178,7 +15182,7 @@ const CpslPopover = class {
15178
15182
  onOpenChange() {
15179
15183
  if (this.open) {
15180
15184
  window.addEventListener('click', this.handleClickOutside);
15181
- window.addEventListener('scroll', () => this.setPosition());
15185
+ window.addEventListener('scroll', () => this.setPosition(), true);
15182
15186
  }
15183
15187
  else {
15184
15188
  window.removeEventListener('click', this.handleClickOutside);
@@ -15194,7 +15198,7 @@ const CpslPopover = class {
15194
15198
  }
15195
15199
  render() {
15196
15200
  var _a;
15197
- return (h(Host, { key: '2c1f03932520d63cc98ddd3496125bf08104e1ba', class: {
15201
+ return (h(Host, { key: 'bb9a38fb37e6588041f6b09e064cbe85d0dd46b1', class: {
15198
15202
  'open': this.open,
15199
15203
  'transform-h-left': this.transformOriginHorizontal === 'left',
15200
15204
  'transform-h-center': this.transformOriginHorizontal === 'center',
@@ -15202,7 +15206,7 @@ const CpslPopover = class {
15202
15206
  'transform-v-top': this.transformOriginVertical === 'top',
15203
15207
  'transform-v-center': this.transformOriginVertical === 'center',
15204
15208
  'transform-v-bottom': this.transformOriginVertical === 'bottom',
15205
- }, style: { top: `${this.positionY}px`, left: `${this.positionX}px`, width: this.autoWidth ? 'auto' : `${(_a = this.triggerEl) === null || _a === void 0 ? void 0 : _a.clientWidth}px` } }, h("div", { key: '97a28f240533a7a1d4e1200769086e13666a94e4', id: "container", class: { container: true, open: this.open } }, h("slot", { key: 'efacb33d8dae9abef32fdc9a7b1047384cc0cd38' }))));
15209
+ }, style: { top: `${this.positionY}px`, left: `${this.positionX}px`, width: this.autoWidth ? 'auto' : `${(_a = this.triggerEl) === null || _a === void 0 ? void 0 : _a.clientWidth}px` } }, h("div", { key: '99478330639eed6be6f7e5a960ebb2f485692cff', id: "container", class: { container: true, open: this.open } }, h("slot", { key: '2d15adf8c986698ce02858dfdca49047777e2c33' }))));
15206
15210
  }
15207
15211
  get el() { return getElement(this); }
15208
15212
  static get watchers() { return {
@@ -15312,7 +15316,7 @@ const CpslRadio = class {
15312
15316
  };
15313
15317
  CpslRadio.style = CpslRadioStyle0;
15314
15318
 
15315
- const cpslSelectCss = ":host{--container-box-shadow:none;--container-box-shadow-color:var(--cpsl-color-select-border-placeholder);--container-border-color:var(--cpsl-color-select-border-active);--container-border-error-color:var(--cpsl-color-select-border-error);--container-background-color:var(--cpsl-color-select-surface-default);--container-background-color-disabled:var(--cpsl-color-select-surface-disabled);--container-border-width:1px;--container-border-radius:var(--cpsl-border-radius-select);--container-padding-top:0px;--container-padding-bottom:0px;--container-padding-end:12px;--container-padding-start:12px;--container-height:48px;--container-gap:8px;--dropdown-margin-top:4px;--dropdown-border-width:1px;--dropdown-border-radius:var(--cpsl-border-radius-select);--dropdown-border-color:var(--cpsl-color-select-dropdown-border);--optional-label-color:var(--cpsl-color-text-secondary);--label-color:var(--cpsl-color-text-primary);--label-font-size:var(--cpsl-font-size-body-s);--label-margin-bottom:0px;--helper-text-color:var(--cpsl-color-text-secondary);--helper-text-error-color:var(--cpsl-color-text-error);--helper-text-icon-color:var(--cpsl-color-text-secondary);--helper-text-icon-error-color:var(--cpsl-color-text-error);--helper-text-icon-size:16px;--helper-text-font-size:var(--cpsl-font-size-body-xs);--helper-text-margin-top:0px;display:flex;flex-direction:column;gap:4px;font-family:var(--cpsl-font-family, inherit)}input{box-sizing:border-box;position:absolute;width:100%;height:100%;margin:0px;opacity:0;top:0;left:0;cursor:pointer}input.disabled{cursor:default}:host(:not(.has-value)){--container-border-color:var(--cpsl-color-select-border-placeholder);--select-color:var(--cpsl-color-text-secondary)}:host(.disabled){--container-background-color:var(--container-background-color-disabled);--select-background-color:var(--select-background-color-disabled);--select-color:var(--cpsl-color-text-disabled)}:host(.focused){--container-box-shadow:0px 0px 0px 2px var(--container-box-shadow-color);--container-border-color:var(--cpsl-color-select-border-active);--container-background-color:var(--cpsl-color-select-surface-default)}.select-container{-webkit-padding-start:var(--container-padding-start);padding-inline-start:var(--container-padding-start);-webkit-padding-end:var(--container-padding-end);padding-inline-end:var(--container-padding-end);padding-top:var(--container-padding-top);padding-bottom:var(--container-padding-bottom);position:relative;display:flex;align-items:center;justify-content:space-between;gap:8px;box-sizing:border-box;height:var(--container-height);gap:var(--container-gap);border-style:solid;border-width:var(--container-border-width);border-color:var(--container-border-color);border-radius:var(--container-border-radius);background:var(--container-background-color);box-shadow:var(--container-box-shadow)}.error-container{border-color:var(--container-border-error-color)}.label{display:inline-block;color:var(--label-color);font-size:var(--label-font-size);font-weight:500;margin-bottom:var(--label-margin-bottom)}.optional-label{display:inline-block;color:var(--optional-label-color);font-size:var(--label-font-size);font-weight:500}.helper-text-container{display:flex;align-items:center;gap:4px;color:var(--helper-text-color);font-size:var(--helper-text-font-size);font-weight:500;margin-top:var(--helper-text-margin-top)}.helper-text-container cpsl-icon{--height:var(--helper-text-icon-size);--width:var(--helper-text-icon-size);--icon-color:var(--helper-text-icon-color)}.error-text{color:var(--helper-text-error-color)}.error-text cpsl-icon{--icon-color:var(--helper-text-icon-error-color)}.selected-container-content{flex:1}.chevron{transition:transform 0.3s ease;transform:rotate(180deg);--icon-color:var(--cpsl-color-text-disabled)}.chevron.open{transform:rotate(0deg);--icon-color:var(--cpsl-color-text-primary)}.chevron.has-value{--icon-color:var(--cpsl-color-text-primary)}.selected-text{color:var(--cpsl-color-text-primary)}.selected-text.placeholder{color:var(--cpsl-color-text-disabled)}.dropdown{margin-top:var(--dropdown-margin-top);border-style:solid;border-width:var(--dropdown-border-width);border-color:var(--dropdown-border-color);border-radius:var(--dropdown-border-radius);overflow:hidden}.dropdown ::slotted(*:last-child){--container-border-width:0px}.dropdown-inner{overflow:auto;scrollbar-width:thin}";
15319
+ const cpslSelectCss = ":host{--container-box-shadow:none;--container-box-shadow-color:var(--cpsl-color-select-border-placeholder);--container-border-color:var(--cpsl-color-select-border-active);--container-border-error-color:var(--cpsl-color-select-border-error);--container-background-color:var(--cpsl-color-select-surface-default);--container-background-color-disabled:var(--cpsl-color-select-surface-disabled);--container-border-width:1px;--container-border-radius:var(--cpsl-border-radius-select);--container-padding-top:0px;--container-padding-bottom:0px;--container-padding-end:12px;--container-padding-start:12px;--container-height:48px;--container-gap:8px;--dropdown-margin-top:4px;--dropdown-border-width:1px;--dropdown-border-radius:var(--cpsl-border-radius-select);--dropdown-border-color:var(--cpsl-color-select-dropdown-border);--optional-label-color:var(--cpsl-color-text-secondary);--label-color:var(--cpsl-color-text-primary);--label-font-size:var(--cpsl-font-size-body-s);--label-margin-bottom:0px;--helper-text-color:var(--cpsl-color-text-secondary);--helper-text-error-color:var(--cpsl-color-text-error);--helper-text-icon-color:var(--cpsl-color-text-secondary);--helper-text-icon-error-color:var(--cpsl-color-text-error);--helper-text-icon-size:16px;--helper-text-font-size:var(--cpsl-font-size-body-xs);--helper-text-margin-top:0px;display:flex;flex-direction:column;gap:4px;font-family:var(--cpsl-font-family, inherit)}input{box-sizing:border-box;position:absolute;width:100%;height:100%;margin:0px;opacity:0;top:0;left:0;z-index:-1;cursor:pointer}input.disabled{cursor:default}:host(:not(.has-value)){--container-border-color:var(--cpsl-color-select-border-placeholder);--select-color:var(--cpsl-color-text-secondary)}:host(.disabled){--container-background-color:var(--container-background-color-disabled);--select-background-color:var(--select-background-color-disabled);--select-color:var(--cpsl-color-text-disabled)}:host(.focused){--container-box-shadow:0px 0px 0px 2px var(--container-box-shadow-color);--container-border-color:var(--cpsl-color-select-border-active);--container-background-color:var(--cpsl-color-select-surface-default)}.select-container{-webkit-padding-start:var(--container-padding-start);padding-inline-start:var(--container-padding-start);-webkit-padding-end:var(--container-padding-end);padding-inline-end:var(--container-padding-end);padding-top:var(--container-padding-top);padding-bottom:var(--container-padding-bottom);position:relative;display:flex;align-items:center;justify-content:space-between;gap:8px;box-sizing:border-box;height:var(--container-height);gap:var(--container-gap);cursor:pointer;border-style:solid;border-width:var(--container-border-width);border-color:var(--container-border-color);border-radius:var(--container-border-radius);background:var(--container-background-color);box-shadow:var(--container-box-shadow)}.error-container{border-color:var(--container-border-error-color)}.label{display:inline-block;color:var(--label-color);font-size:var(--label-font-size);font-weight:500;margin-bottom:var(--label-margin-bottom)}.optional-label{display:inline-block;color:var(--optional-label-color);font-size:var(--label-font-size);font-weight:500}.helper-text-container{display:flex;align-items:center;gap:4px;color:var(--helper-text-color);font-size:var(--helper-text-font-size);font-weight:500;margin-top:var(--helper-text-margin-top)}.helper-text-container cpsl-icon{--height:var(--helper-text-icon-size);--width:var(--helper-text-icon-size);--icon-color:var(--helper-text-icon-color)}.error-text{color:var(--helper-text-error-color)}.error-text cpsl-icon{--icon-color:var(--helper-text-icon-error-color)}.selected-container-content{flex:1}.chevron{transition:transform 0.3s ease;transform:rotate(180deg);--icon-color:var(--cpsl-color-text-disabled)}.chevron.open{transform:rotate(0deg);--icon-color:var(--cpsl-color-text-primary)}.chevron.has-value{--icon-color:var(--cpsl-color-text-primary)}.selected-text{color:var(--cpsl-color-text-primary)}.selected-text.placeholder{color:var(--cpsl-color-text-disabled)}.dropdown{margin-top:var(--dropdown-margin-top);border-style:solid;border-width:var(--dropdown-border-width);border-color:var(--dropdown-border-color);border-radius:var(--dropdown-border-radius);overflow:hidden}.dropdown ::slotted(*:last-child){--container-border-width:0px}.dropdown-inner{overflow:auto;scrollbar-width:thin}";
15316
15320
  const CpslSelectStyle0 = cpslSelectCss;
15317
15321
 
15318
15322
  const CpslSelect = class {
@@ -15324,6 +15328,7 @@ const CpslSelect = class {
15324
15328
  this.inputId = `cpsl-select-${inputIds++}`;
15325
15329
  this.onBlur = (ev) => {
15326
15330
  this.hasFocus = false;
15331
+ this.popoverEl.closePopover();
15327
15332
  this.cpslBlur.emit(ev);
15328
15333
  };
15329
15334
  this.onFocus = (ev) => {
@@ -15351,6 +15356,19 @@ const CpslSelect = class {
15351
15356
  this.hasSelectedItem = false;
15352
15357
  }
15353
15358
  };
15359
+ this.handleClickOutside = (event) => {
15360
+ if (this.hasFocus && !this.el.contains(event.target)) {
15361
+ this.hasFocus = false;
15362
+ window.removeEventListener('click', this.handleClickOutside);
15363
+ }
15364
+ };
15365
+ this.handleClick = () => {
15366
+ if (!this.disabled) {
15367
+ this.hasFocus = true;
15368
+ window.addEventListener('click', this.handleClickOutside);
15369
+ }
15370
+ };
15371
+ this.anchorEl = undefined;
15354
15372
  this.hasFocus = false;
15355
15373
  this.popoverOpen = false;
15356
15374
  this.hasSelectedItem = false;
@@ -15384,11 +15402,12 @@ const CpslSelect = class {
15384
15402
  }
15385
15403
  componentDidLoad() {
15386
15404
  this.popoverEl = this.el.shadowRoot.querySelector(`cpsl-popover`);
15405
+ this.anchorEl = this.el.shadowRoot.getElementById('select-container');
15387
15406
  this.selectItem();
15388
15407
  }
15389
15408
  render() {
15390
15409
  var _a, _b, _c, _d;
15391
- return (h(Host, { key: '7ad387377c9e3a14fd9e9ed39627d65df33a255a', id: this.id, class: { 'disabled': this.disabled, 'focused': this.hasFocus, 'has-value': Boolean(this.selectedValue) } }, this.label && (h("label", { key: 'a04cdb05dac058b57301b4052ca8e49992319048', class: "label", htmlFor: this.inputId }, this.label, this.required ? '*' : ' ', !this.required && this.showOptionalLabel ? h("span", { class: "optional-label" }, "(optional)") : '')), h("div", { key: '04baa7155a989015a3a57318d653eaad6fb8e0e9', class: { 'select-container': true, 'error-container': Boolean(this.errorText) } }, this.hasSelectedItem && this.showFormattedSelectedItem && h("slot", { key: '447dcce739659ff4139197ffaf7d5d9f0775de89', name: "selected-item" }), h("div", { key: '46cbfcc9afee9132e7d254bdd064296970f28f47', class: "selected-container-content", id: "selected-container-content" }, (!this.hasSelectedItem || !this.showFormattedSelectedItem) && (h("cpsl-text", { key: 'fc77344729bcef824db7f32325293bf031c1fb74', class: { 'selected-text': true, 'placeholder': !Boolean(this.selectedValue) } }, !Boolean(this.selectedValue) ? (_a = this.placeholder) !== null && _a !== void 0 ? _a : 'Select' : (_c = (_b = this.formatValue) === null || _b === void 0 ? void 0 : _b.call(this, this.selectedValue)) !== null && _c !== void 0 ? _c : this.selectedValue))), h("cpsl-icon", { key: '44d40d1b80105809f446ed169467a8c583b8afd5', class: { 'chevron': true, 'open': this.popoverOpen, 'has-value': Boolean(this.selectedValue) }, icon: "chevronUp" }), h("input", { key: 'cbeb30eb519dd7db84da6f5e5366ea924ec6c715', id: this.inputId, disabled: this.disabled, class: { disabled: this.disabled }, value: this.selectedValue, onFocus: this.onFocus, onBlur: this.onBlur, onKeyPress: this.handleEnterPress })), (this.errorText || this.helperText) && (h("div", { key: '9f3475b40c6ab3872af65d8aecc4e653add2ba2d', class: { 'helper-text-container': true, 'error-text': Boolean(this.errorText) } }, h("span", { key: '04dcc76a6c5b93969b16ac2b400fe86c96189a9b' }, (_d = this.errorText) !== null && _d !== void 0 ? _d : this.helperText))), h("cpsl-popover", { key: '7909618009a8080bc570b761e6800779eb482a61', autoWidth: false, trigger: this.id, preventBlur: this.hasFocus }, h("div", { key: '1fe3de1d21302f76669dd8f6730373d47de0fb27', class: "dropdown" }, h("div", { key: 'c888c8bc3da0a85b31b37dc44bfc826c6ac635f8', class: "dropdown-inner", style: { maxHeight: `${this.dropdownMaxHeight}px` } }, h("slot", { key: '69cd9e6df64d26a5ec68912bf52042cb8eebda1f', name: "items" }))))));
15410
+ return (h(Host, { key: 'dfe6786c9be71ebd71fee236c9b569ef1ad30eac', id: this.id, class: { 'disabled': this.disabled, 'focused': this.hasFocus, 'has-value': Boolean(this.selectedValue) } }, this.label && (h("label", { key: 'fbe2cfb2d93558f647442e17b29713f37375be5a', class: "label", htmlFor: this.inputId }, this.label, this.required ? '*' : ' ', !this.required && this.showOptionalLabel ? h("span", { class: "optional-label" }, "(optional)") : '')), h("div", { key: '9e5fdf3c056a7a6c13fe9ce45caf78e27482e779', id: "select-container", class: { 'select-container': true, 'error-container': Boolean(this.errorText) }, onMouseDown: this.handleClick }, this.hasSelectedItem && this.showFormattedSelectedItem && h("slot", { key: 'c721fcd057a142bad5f8f473c7b4daf090e7722a', name: "selected-item" }), h("div", { key: '58c94ace573965e8151ef4a9c0648385d6b1c4dc', class: "selected-container-content", id: "selected-container-content" }, (!this.hasSelectedItem || !this.showFormattedSelectedItem) && (h("cpsl-text", { key: 'ceb4c60607b6c2cbc17a086fe702045196afbd44', class: { 'selected-text': true, 'placeholder': !Boolean(this.selectedValue) } }, !Boolean(this.selectedValue) ? (_a = this.placeholder) !== null && _a !== void 0 ? _a : 'Select' : (_c = (_b = this.formatValue) === null || _b === void 0 ? void 0 : _b.call(this, this.selectedValue)) !== null && _c !== void 0 ? _c : this.selectedValue))), h("cpsl-icon", { key: '05cf53f1ce3f8f34e47082c591f2d75d4aeea11b', class: { 'chevron': true, 'open': this.popoverOpen, 'has-value': Boolean(this.selectedValue) }, icon: "chevronUp" }), h("input", { key: 'a395add0f06b0d10f1e2e6d0ea81478f4a1c07d6', id: this.inputId, disabled: this.disabled, class: { disabled: this.disabled }, value: this.selectedValue, onFocus: this.onFocus, onBlur: this.onBlur, onKeyPress: this.handleEnterPress, inputmode: "none" })), (this.errorText || this.helperText) && (h("div", { key: 'e7f991ed99ed332f5f42e666bfd2d25eecff3113', class: { 'helper-text-container': true, 'error-text': Boolean(this.errorText) } }, h("span", { key: 'f734a586f0dd7e94ccb2d7806fc9a6a5bdb5f50b' }, (_d = this.errorText) !== null && _d !== void 0 ? _d : this.helperText))), h("cpsl-popover", { key: 'c45f42267e3b4945823e27f5901b58dc5545a51e', autoWidth: false, trigger: this.id, preventBlur: this.hasFocus, disabled: this.disabled, anchorEl: this.anchorEl }, h("div", { key: 'cd7bdc9a3e06a2c4aed9ebe12ec3cd070e323b12', class: "dropdown" }, h("div", { key: '0e1483542dd9d63ad548242a2bc2ecb2041f8ed5', class: "dropdown-inner", style: { maxHeight: `${this.dropdownMaxHeight}px` } }, h("slot", { key: 'e7697bc187fc433ccb2f5728f8944ff2162387d9', name: "items" }))))));
15392
15411
  }
15393
15412
  get el() { return getElement(this); }
15394
15413
  static get watchers() { return {
@@ -15398,7 +15417,7 @@ const CpslSelect = class {
15398
15417
  let inputIds = 0;
15399
15418
  CpslSelect.style = CpslSelectStyle0;
15400
15419
 
15401
- const cpslSelectItemCss = ":host{--container-background-color:var(--cpsl-color-select-surface-default);--container-hover-background-color:var(--cpsl-color-select-surface-hover);--container-border-color:var(--cpsl-color-select-dropdown-border);--container-border-width:1px;--container-padding-start:16px;--container-padding-end:16px;--container-padding-top:16px;--container-padding-bottom:16px;display:block;font-family:var(--cpsl-font-family, inherit);cursor:pointer}.container{-webkit-padding-start:var(--container-padding-start);padding-inline-start:var(--container-padding-start);-webkit-padding-end:var(--container-padding-end);padding-inline-end:var(--container-padding-end);padding-top:var(--container-padding-top);padding-bottom:var(--container-padding-bottom);background-color:var(--container-background-color);border-style:solid;border-width:0px;border-bottom-width:var(--container-border-width);border-color:var(--container-border-color);height:100%;display:flex;align-items:center}.container:hover{background-color:var(--container-hover-background-color)}.selected{background-color:var(--container-hover-background-color)}:host(.in-select-box){--container-background-color:transparent;--container-hover-background-color:transparent;--container-border-width:0px;--container-padding-start:0px;--container-padding-end:0px;--container-padding-top:0px;--container-padding-bottom:0px;flex:1;height:100%}";
15420
+ const cpslSelectItemCss = ":host{--outer-container-padding-start:8px;--outer-container-padding-end:8px;--outer-container-padding-top:8px;--outer-container-padding-bottom:8px;--container-background-color:var(--cpsl-color-select-surface-default);--container-hover-background-color:var(--cpsl-color-select-surface-hover);--container-border-radius:calc(var(--cpsl-border-radius-select) - 4px);--container-padding-start:8px;--container-padding-end:8px;--container-padding-top:8px;--container-padding-bottom:8px;display:block;font-family:var(--cpsl-font-family, inherit);cursor:pointer}.inner-container{-webkit-padding-start:var(--container-padding-start);padding-inline-start:var(--container-padding-start);-webkit-padding-end:var(--container-padding-end);padding-inline-end:var(--container-padding-end);padding-top:var(--container-padding-top);padding-bottom:var(--container-padding-bottom);background-color:var(--container-background-color);border-radius:var(--container-border-radius);height:100%;display:flex;align-items:center}.outer-container{-webkit-padding-start:var(--outer-container-padding-start);padding-inline-start:var(--outer-container-padding-start);-webkit-padding-end:var(--outer-container-padding-end);padding-inline-end:var(--outer-container-padding-end);padding-top:var(--outer-container-padding-top);padding-bottom:var(--outer-container-padding-bottom);background-color:var(--container-background-color)}.outer-container:hover>.inner-container{background-color:var(--container-hover-background-color)}.selected{background-color:var(--container-hover-background-color)}:host(.in-select-box){--container-background-color:transparent;--container-hover-background-color:transparent;--container-border-width:0px;--container-padding-start:0px;--container-padding-end:0px;--container-padding-top:0px;--container-padding-bottom:0px;flex:1;height:100%}";
15402
15421
  const CpslSelectItemStyle0 = cpslSelectItemCss;
15403
15422
 
15404
15423
  const CpslSelectItem = class {
@@ -15412,7 +15431,7 @@ const CpslSelectItem = class {
15412
15431
  this.value = undefined;
15413
15432
  }
15414
15433
  render() {
15415
- return (h(Host, { key: 'd85478b3b2eaa5c99ba1f3dbc0e3aae6d368540c' }, h("div", { key: '6066108863ef8440f79732e94a7849c06fe8cd5b', class: { container: true, selected: this.selected }, onClick: this.handleItemClick }, h("slot", { key: '857ce8891d6ae250e48e4af417e596b2a99fedb7' }))));
15434
+ return (h(Host, { key: 'd85478b3b2eaa5c99ba1f3dbc0e3aae6d368540c' }, h("div", { key: 'd13e45f3997cfbbc4042a2810c76eb9b71b15d22', class: "outer-container", onClick: this.handleItemClick }, h("div", { key: '5c9787fb9ad5b13740515386e269895d2c0ca91d', class: { 'inner-container': true, 'selected': this.selected } }, h("slot", { key: '0fc1ff893cb3e5f53a99978f683b1e4f1fb15410' })))));
15416
15435
  }
15417
15436
  };
15418
15437
  CpslSelectItem.style = CpslSelectItemStyle0;
@@ -15537,7 +15556,7 @@ const CpslSlideButton = class {
15537
15556
  return this.el.shadowRoot.getElementById('end-icon');
15538
15557
  }
15539
15558
  render() {
15540
- return (h(Host, { key: '3596eacfceeab7bff0c45c7993480367d3981d5d' }, h("div", { key: 'c1ea3019d349361d4c60e5754be9c8ff77ade08b', id: "slider-container", class: "slider-container" }, h("div", { key: '49b34608c2315629006d7fc2f56bd8f4658a70e7', id: "start-slider-container-background", class: { 'start-slider-container-background': true, 'slider-container-background': true } }), h("div", { key: '013654d1ab70af8220908d25d19ac16e31f81441', id: "end-slider-container-background", class: { 'end-slider-container-background': true, 'slider-container-background': true } }), h("div", { key: 'f09c57e5150fc41dfece17b8d0d869d8acd2326e', id: "slider", class: { slider: true, disabled: this.disabled } }, h("cpsl-icon", { key: '869f90456a9989e468d2b16d4995253615a40cef', id: "start-icon", class: { 'start-icon': true, 'icon': true }, icon: this.startIcon }), h("cpsl-icon", { key: 'fcc96741040125aa98357e7ab46e13da46a780d2', id: "end-icon", class: { 'end-icon': true, 'icon': true }, icon: this.endIcon })), h("span", { key: '56d9ebc90c1fcdfd0976574a60be0c4af0d8590d', id: "start-text", class: { 'start-text': true, 'disabled': this.disabled } }, this.startText), h("span", { key: '6f8e10b9ed8738b899279be1e599b3fcd38a894d', id: "end-text", class: "end-text" }, this.endText))));
15559
+ return (h(Host, { key: 'aecef591819520c5abd43529f797a11d564bbf40' }, h("div", { key: '8d08c211ff7393aaf86569d3cb442216e1f78efd', id: "slider-container", class: "slider-container" }, h("div", { key: '072a8c587c34bf792d289cfa4490cd8564121a16', id: "start-slider-container-background", class: { 'start-slider-container-background': true, 'slider-container-background': true } }), h("div", { key: '6f656942985f8c490bb96d99475373fe6978c0e0', id: "end-slider-container-background", class: { 'end-slider-container-background': true, 'slider-container-background': true } }), h("div", { key: '0fcdc94813b54c9c32fdf7d5fc963448e0cf492a', id: "slider", class: { slider: true, disabled: this.disabled } }, h("cpsl-icon", { key: 'f45c670469c80f5604c06c8182ef7c9fabc56200', id: "start-icon", class: { 'start-icon': true, 'icon': true }, icon: this.startIcon }), h("cpsl-icon", { key: 'bc987b8d1495bb731ead75497ae7c411534f7ff0', id: "end-icon", class: { 'end-icon': true, 'icon': true }, icon: this.endIcon })), h("span", { key: 'bd6ab1e1adaff366e5ebb2bf82415bab514c00e8', id: "start-text", class: { 'start-text': true, 'disabled': this.disabled } }, this.startText), h("span", { key: '0b94b997a625213645e737c77ad736663d41a844', id: "end-text", class: "end-text" }, this.endText))));
15541
15560
  }
15542
15561
  get el() { return getElement(this); }
15543
15562
  };
@@ -15553,13 +15572,13 @@ const CpslSpinner = class {
15553
15572
  this.speed = 1;
15554
15573
  }
15555
15574
  render() {
15556
- return (h(Host, { key: '79425e262154e53691240dec1033910e693c1eaf', style: {
15575
+ return (h(Host, { key: '10ec2d7dc8b62b0819e4ff3f683b5b7c7a6dbf19', style: {
15557
15576
  'height': `${this.size}px`,
15558
15577
  'width': `${this.size}px`,
15559
15578
  'animation': `spin ${this.speed}s linear infinite`,
15560
15579
  '-webkit-animation': `spin ${this.speed}s linear infinite`,
15561
15580
  '-moz-animation': `spin ${this.speed}s linear infinite`,
15562
- } }, h("svg", { key: 'b212d3552fcae69b2e5538bc93c3a016444e9326', height: this.size, width: this.size, xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 54 54", fill: "none" }, h("path", { key: '1801af097635352fb4ca20917a11bd66e5fe5543', d: "M43.1586 17C39.8082 11.5978 33.8243 8 27 8C16.5066 8 8 16.5066 8 27C8 37.4934 16.5066 46 27 46C33.8242 46 39.8082 42.4022 43.1586 37", "stroke-width": "6", "stroke-linecap": "round" }), h("circle", { key: '1f54bfa6fae3ee4ed705e6442c8eba29d857406f', cx: "45", cy: "27", r: "5" }))));
15581
+ } }, h("svg", { key: 'e88b02f99bbfe3677eafe55d75ee65f595e829c5', height: this.size, width: this.size, xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 54 54", fill: "none" }, h("path", { key: 'de3d33313d7509abeb7733c37d3ed99ca9894260', d: "M43.1586 17C39.8082 11.5978 33.8243 8 27 8C16.5066 8 8 16.5066 8 27C8 37.4934 16.5066 46 27 46C33.8242 46 39.8082 42.4022 43.1586 37", "stroke-width": "6", "stroke-linecap": "round" }), h("circle", { key: '7e0edc7e3222dc95a8c62d3228aceeddaf51593b', cx: "45", cy: "27", r: "5" }))));
15563
15582
  }
15564
15583
  };
15565
15584
  CpslSpinner.style = CpslSpinnerStyle0;
@@ -15577,7 +15596,7 @@ const CpslSwitch = class {
15577
15596
  this.checked = undefined;
15578
15597
  }
15579
15598
  render() {
15580
- return (h(Host, { key: '522bcdfa156531915323f64b620d9207f9006c5b' }, h("input", { key: '2062a1c2d6b412d92e7da8c509a7e26c48fe7cd9', type: "checkbox", checked: this.checked }), h("span", { key: '58d096cdfd809bdb52294ea70a263a58f99971c7', onClick: this.handleSwitchClick, class: { container: true, checked: this.checked } }, h("span", { key: '15b702eb45d8fe3d61d6f2313cc291cd62fbd3c7', class: { thumb: true, checked: this.checked } }))));
15599
+ return (h(Host, { key: '1b25c42d27a45e0af756eadba475d15a8034d483' }, h("input", { key: 'fbb246d9b9fd5d3842bef147922095a36277ff0f', type: "checkbox", checked: this.checked }), h("span", { key: 'fe9356dec1f9b41b94cd5597b36ae6e1d5fce7ac', onClick: this.handleSwitchClick, class: { container: true, checked: this.checked } }, h("span", { key: '11d0ce011571a147912b400398ed8b78743d356c', class: { thumb: true, checked: this.checked } }))));
15581
15600
  }
15582
15601
  };
15583
15602
  CpslSwitch.style = CpslSwitchStyle0;
@@ -15609,7 +15628,7 @@ const CpslTab = class {
15609
15628
  }
15610
15629
  }
15611
15630
  render() {
15612
- return (h(Host, { key: '7421ddd0b946411ae0d4415b02d878affbe0ac94', onClick: this.onTabClicked }, h("div", { key: '94a73eac12e6cb326879f4ff8d7bb9977745201f', class: { 'tab-container': true } }, h("slot", { key: '504138d77b041b165448ed5d8027546087852023' }))));
15631
+ return (h(Host, { key: 'cc8785697e46574b6fdb1839098473bb3ca17866', onClick: this.onTabClicked }, h("div", { key: '2c6451937db4c48fa11bd610bfd344154eced8e6', class: { 'tab-container': true } }, h("slot", { key: '1dc724e299adbc96024aa6636f94551b09853c2a' }))));
15613
15632
  }
15614
15633
  get el() { return getElement(this); }
15615
15634
  };
@@ -15629,7 +15648,7 @@ const CpslTable = class {
15629
15648
  return this.el.querySelector('[slot="footer"]');
15630
15649
  }
15631
15650
  render() {
15632
- return (h(Host, { key: '5d1ad9d5503e188e9feda4472604dfb7eb79837d' }, h("cpsl-card", { key: '6521eb6d0a8b991cbaba96785a3653ecbb55a65b', part: "table-container" }, h("div", { key: 'bbf78a4700a8f3a4be12bfc17ec7e9665e7c95e2', class: { 'container-header': true, 'shown': Boolean(this.containerHeaderEl) } }, h("slot", { key: '2c50bdad1e19f0fcd86864b4ed91fe6516e8c036', name: "header" })), h("div", { key: 'e8bd5010262c200e059c98176748cd90cfae800b', class: "content", part: "content" }, h("slot", { key: 'bad1c53fdcb148470e04867c73e0fa3e4e6dd4c3', name: "content" })), h("div", { key: '1ab4ad8e62964a8e474ba55f77777f64c22d82c6', class: { 'container-footer': true, 'shown': Boolean(this.containerFooterEl) } }, h("slot", { key: 'f9cc7262b33a015e2eb7b8cd29b1b2c4bdb4f7cf', name: "footer" })))));
15651
+ return (h(Host, { key: '69d28584233c9f7545be8068c6f6fe5c6698d36f' }, h("cpsl-card", { key: 'fe1cdd5e9b0332d6056a38d32239057a252909e1', part: "table-container" }, h("div", { key: 'fd8eba0d9ebb48efb45617da3884d4a330a42704', class: { 'container-header': true, 'shown': Boolean(this.containerHeaderEl) } }, h("slot", { key: '8aaf689f820bc2c6732058b9d60a16d34974f0f0', name: "header" })), h("div", { key: '54610dd3abedc4f1214308a8b1f57d5f41b4d530', class: "content", part: "content" }, h("slot", { key: '49b369b546a08d25c85573e9807a4dd730a3e5e6', name: "content" })), h("div", { key: 'dcfb4bcbe1ad526bf07f4717ac4089711a8e4e70', class: { 'container-footer': true, 'shown': Boolean(this.containerFooterEl) } }, h("slot", { key: '4c60a98ad1098c77b8c14f8943fabe6141428fe0', name: "footer" })))));
15633
15652
  }
15634
15653
  get el() { return getElement(this); }
15635
15654
  };
@@ -15688,7 +15707,7 @@ const CpslTabs = class {
15688
15707
  const tabsPosition = this.el.getBoundingClientRect();
15689
15708
  const tabsBorderWidth = +getComputedStyle(this.el).getPropertyValue('--tabs-border-width').slice(0, -2);
15690
15709
  const selectedTabRect = this.selectedTabRect;
15691
- return (h(Host, { key: '04d442550749a14429d03619bbd2978bca9a8411', class: { 'full-width': this.fullWidth }, onCpslTabButtonClick: this.onTabClicked }, h("div", { key: '304eb35a1e05c26d81a1102d324b3824d9d0437e', class: "tabs-container" }, h("slot", { key: '813aecefd7a916ee378a9d77efd4e9a2c9232a43' }), h("div", { key: '68b2fd7ea6889ae3c4baa5c87b67e27e21ec5ac1', class: { slider: true, loaded: this.loaded }, style: { width: `${selectedTabRect.width}px`, left: `${selectedTabRect.x - tabsPosition.x - tabsBorderWidth * 2}px` } }))));
15710
+ return (h(Host, { key: '8620de3b1cff8b60d0273f892ca7669cd53e479c', class: { 'full-width': this.fullWidth }, onCpslTabButtonClick: this.onTabClicked }, h("div", { key: '1441d0f383ae41c5293e2ced9a0c77b04e3cfd5f', class: "tabs-container" }, h("slot", { key: '78f40c6d6f4826bc83254349e35ef98faf3968ce' }), h("div", { key: '900ab917e38b71195cd498cc2ed05a90d48515ac', class: { slider: true, loaded: this.loaded }, style: { width: `${selectedTabRect.width}px`, left: `${selectedTabRect.x - tabsPosition.x - tabsBorderWidth * 2}px` } }))));
15692
15711
  }
15693
15712
  get el() { return getElement(this); }
15694
15713
  static get watchers() { return {
@@ -15738,7 +15757,7 @@ const CpslText = class {
15738
15757
  }
15739
15758
  }
15740
15759
  render() {
15741
- return (h(Host, { key: '2e9bd70bb3fad7f86b881fbc07eaf5af974e92de', class: {
15760
+ return (h(Host, { key: '0f21250f8e8b38eeb854ba3b465c4ac0917b058b', class: {
15742
15761
  'primary': this.color === 'primary',
15743
15762
  'secondary': this.color === 'secondary',
15744
15763
  'tertiary': this.color === 'tertiary',
@@ -15775,7 +15794,7 @@ const CpslTileButton = class {
15775
15794
  this.icon = undefined;
15776
15795
  }
15777
15796
  render() {
15778
- return (h(Host, { key: '54b66964a2d179530ed244d85a3da4edf78415aa' }, h("button", { key: 'a73f89f90361fac70c9365cdd6191a91d26ed70f', class: "button-native" }, h("cpsl-icon", { key: '574fc93949e8b0fb42b71c617dcf972730ae369d', exportparts: "icon", src: this.src, icon: this.icon }), h("slot", { key: 'db542e72141d187eeb2fe9f8d1524fa70e23276b' }))));
15797
+ return (h(Host, { key: 'f7d808cefadce272235872ba05cd60f9c0bffc3c' }, h("button", { key: '47e808a5ed0bdb6e0705d746844f74ce7ad07620', class: "button-native" }, h("cpsl-icon", { key: 'ba374a65bee6433b96d2f3c8abbe1da51f9172af', exportparts: "icon", src: this.src, icon: this.icon }), h("slot", { key: 'b5f55bdcec9566625f7c7a9567a933ff86815d6c' }))));
15779
15798
  }
15780
15799
  };
15781
15800
  CpslTileButton.style = CpslTileButtonStyle0;