@ukic/web-components 3.9.0 → 3.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (53) hide show
  1. package/dist/cjs/ic-button_3.cjs.entry.js.map +1 -1
  2. package/dist/cjs/ic-horizontal-scroll.cjs.entry.js +1 -1
  3. package/dist/cjs/ic-horizontal-scroll.cjs.entry.js.map +1 -1
  4. package/dist/cjs/ic-input-component-container_3.cjs.entry.js.map +1 -1
  5. package/dist/cjs/ic-select.cjs.entry.js +3 -2
  6. package/dist/cjs/ic-select.cjs.entry.js.map +1 -1
  7. package/dist/cjs/ic-text-field.cjs.entry.js +3 -3
  8. package/dist/cjs/ic-text-field.cjs.entry.js.map +1 -1
  9. package/dist/collection/components/ic-back-to-top/ic-back-to-top.stories.js +179 -0
  10. package/dist/collection/components/ic-footer/ic-footer.stories.js +72 -0
  11. package/dist/collection/components/ic-hero/ic-hero.stories.js +72 -0
  12. package/dist/collection/components/ic-horizontal-scroll/ic-horizontal-scroll.css +8 -0
  13. package/dist/collection/components/ic-section-container/ic-section-container.stories.js +39 -0
  14. package/dist/collection/components/ic-select/ic-select.js +3 -2
  15. package/dist/collection/components/ic-select/ic-select.js.map +1 -1
  16. package/dist/collection/components/ic-text-field/ic-text-field.js +3 -3
  17. package/dist/collection/components/ic-text-field/ic-text-field.js.map +1 -1
  18. package/dist/collection/components/ic-toggle-button/ic-toggle-button.stories.js +236 -0
  19. package/dist/components/ic-back-to-top.js.map +1 -1
  20. package/dist/components/ic-horizontal-scroll2.js +1 -1
  21. package/dist/components/ic-horizontal-scroll2.js.map +1 -1
  22. package/dist/components/ic-pagination.js.map +1 -1
  23. package/dist/components/ic-radio-group.js.map +1 -1
  24. package/dist/components/ic-search-bar.js.map +1 -1
  25. package/dist/components/ic-select.js +3 -2
  26. package/dist/components/ic-select.js.map +1 -1
  27. package/dist/components/ic-status-tag.js.map +1 -1
  28. package/dist/components/ic-step.js.map +1 -1
  29. package/dist/components/ic-tab-panel.js.map +1 -1
  30. package/dist/components/ic-text-field.js +3 -3
  31. package/dist/components/ic-text-field.js.map +1 -1
  32. package/dist/core/core.esm.js +1 -1
  33. package/dist/core/p-0c0c6a9e.entry.js +2 -0
  34. package/dist/core/p-0c0c6a9e.entry.js.map +1 -0
  35. package/dist/core/p-28efe829.entry.js.map +1 -1
  36. package/dist/core/{p-b25d33d8.entry.js → p-47f6dac2.entry.js} +2 -2
  37. package/dist/core/{p-b25d33d8.entry.js.map → p-47f6dac2.entry.js.map} +1 -1
  38. package/dist/core/p-97b93ddf.entry.js.map +1 -1
  39. package/dist/core/{p-5daa7915.entry.js → p-bb4ce810.entry.js} +2 -2
  40. package/dist/core/{p-5daa7915.entry.js.map → p-bb4ce810.entry.js.map} +1 -1
  41. package/dist/esm/ic-button_3.entry.js.map +1 -1
  42. package/dist/esm/ic-horizontal-scroll.entry.js +1 -1
  43. package/dist/esm/ic-horizontal-scroll.entry.js.map +1 -1
  44. package/dist/esm/ic-input-component-container_3.entry.js.map +1 -1
  45. package/dist/esm/ic-select.entry.js +3 -2
  46. package/dist/esm/ic-select.entry.js.map +1 -1
  47. package/dist/esm/ic-text-field.entry.js +3 -3
  48. package/dist/esm/ic-text-field.entry.js.map +1 -1
  49. package/hydrate/index.js +7 -6
  50. package/hydrate/index.mjs +7 -6
  51. package/package.json +2 -2
  52. package/dist/core/p-948f89a0.entry.js +0 -2
  53. package/dist/core/p-948f89a0.entry.js.map +0 -1
@@ -1,2 +1,2 @@
1
- import{r as i,c as t,f as e,h as s,H as l,g as a}from"./p-8e4e97b4.js";import{H as o,E as n,C as r,J as h,r as c,l as d,x as u,k as p,o as b,m as f,q as v,s as m,i as g,K as x,z as w,L as y}from"./p-25007ec9.js";const k=`<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">\n<path d="M7 9.5L12 14.5L17 9.5H7Z" fill="currentColor" />\n</svg>\n`;const L=`<svg width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">\n<path d="M12.6666 4.27334L11.7266 3.33334L7.99998 7.06001L4.27331 3.33334L3.33331 4.27334L7.05998 8.00001L3.33331 11.7267L4.27331 12.6667L7.99998 8.94001L11.7266 12.6667L12.6666 11.7267L8.93998 8.00001L12.6666 4.27334Z" fill="currentColor" />\n</svg>\n`;const z='/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-webkit-text-size-adjust:100%;}body{margin:0}main{display:block}h1{font-size:2em;margin:0.67em 0}hr{box-sizing:content-box;height:0;overflow:visible;}pre{font-family:monospace, monospace;font-size:1em;}a{background-color:transparent}abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted;}b,strong{font-weight:bolder}code,kbd,samp{font-family:monospace, monospace;font-size:1em;}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-0.25em}sup{top:-0.5em}img{border-style:none}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0;}button,input{overflow:visible}button,select{text-transform:none}button,[type="button"],[type="reset"],[type="submit"]{-webkit-appearance:button}button::-moz-focus-inner,[type="button"]::-moz-focus-inner,[type="reset"]::-moz-focus-inner,[type="submit"]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type="button"]:-moz-focusring,[type="reset"]:-moz-focusring,[type="submit"]:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:0.35em 0.75em 0.625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal;}progress{vertical-align:baseline}textarea{overflow:auto}[type="checkbox"],[type="radio"]{box-sizing:border-box;padding:0;}[type="number"]::-webkit-inner-spin-button,[type="number"]::-webkit-outer-spin-button{height:auto}[type="search"]{-webkit-appearance:textfield;outline-offset:-2px;}[type="search"]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit;}details{display:block}summary{display:list-item}template{display:none}[hidden]{display:none}html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}:host{display:block;position:relative;--ic-input-label-helpertext-padding:var(--ic-space-xs);--menu-max-height:100px;--border-color:var(--ic-select-field-border);--border-color-hover:var(--ic-select-field-border-hover);--border-color-pressed:var(--ic-select-field-border-pressed);--border-color-disabled:var(--ic-select-field-border-disabled);--border-color-error:var(--ic-select-field-border-error);--border-color-error-hover:var(--ic-select-field-border-error-hover);--border-color-error-pressed:var(--ic-select-field-border-error-pressed);--border-color-success:var(--ic-select-field-border-success);--border-color-success-hover:var(--ic-select-field-border-success-hover);--border-color-success-pressed:var(--ic-select-field-border-success-pressed);--border-color-warning:var(--ic-select-field-border-warning);--border-color-warning-hover:var(--ic-select-field-border-warning-hover);--border-color-warning-pressed:var(--ic-select-field-border-warning-pressed);--ic-input-label-text-color:var(--ic-select-field-labe);--ic-input-label-helper-text-color:var(\n --ic-select-input-field-label-subtitle\n );--ic-input-validation-status-text-color:var(--ic-select-state-text);--ic-input-validation-error:var(--ic-select-state-icon-error);--ic-input-validation-warning-icon-color:var(--ic-select-state-icon-warning);--ic-input-validation-success-icon-color:var(--ic-select-state-icon-success);--menu-item-text-color:var(--ic-select-list-option-text);--menu-bg-color:var(--ic-select-list-option-background);--menu-border-color:var(--ic-select-dropdown-list-border)}:host(.ic-select-disabled){--ic-input-label-text-color:var(--ic-select-field-label-disabled);--ic-input-label-helper-text-color:var(\n --ic-select-input-field-label-subtitle-disabled\n )}:host(.ic-select-full-width){width:100%}ic-input-component-container.menu-open{--border-color:var(--ic-select-field-border-pressed)}ic-input-validation .status-icon,ic-input-validation .statustext{visibility:visible}ic-input-validation.menu-open .status-icon,ic-input-validation.menu-open .statustext{visibility:hidden;transition:visibility 0s}ic-input-label{margin-bottom:var(--ic-space-xs)}select{border:0;border-radius:var(--ic-border-radius);background-color:var(--ic-select-field-background);color:var(--ic-select-content-text);line-height:1.5rem;letter-spacing:0.005rem;width:100%;height:100%;padding-left:0.375rem;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-repeat:no-repeat;background-position:right 0.375rem center;background-image:var(--ic-select-mobile-dropdown-icon);caret-color:var(--ic-select-input-field-text-cursor)}select option,.select-option-selected{color:var(--ic-select-list-option-text)}select:disabled{color:var(--ic-select-content-text-disabled);background-image:var(--ic-select-mobile-dropdown-icon-disabled)}select:focus{border:0;outline:0}select:not([disabled]){cursor:pointer}.select-container{width:100%;display:flex;align-items:center;position:relative}.select-input{width:100%;height:100%;padding:0 0.375rem;display:flex;cursor:pointer;align-items:center;justify-content:space-between;background:none;border:none;background-color:var(--ic-select-field-background);color:var(--ic-select-content-text)}.select-input:focus{outline:none}.select-input[disabled]{pointer-events:none}:host(.ic-select-searchable) .select-input{cursor:auto}.select-input.with-clear-button{padding-right:0}.value-text{max-width:calc(100% - (var(--ic-space-lg) + var(--ic-space-xxs)));box-sizing:border-box;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;margin-bottom:0 !important}.value-text.with-clear-button{padding-right:calc(var(--ic-space-xl) + var(--ic-space-xs))}.searchable-select-container{align-items:center;display:flex;width:100%;position:relative}.expand-icon{height:var(--ic-space-lg);padding-left:var(--ic-space-xxs);color:var(--ic-select-expand-icon-color)}.expand-icon>svg{display:inline-block;width:var(--ic-space-lg);height:var(--ic-space-lg)}:host(.ic-select-disabled) .expand-icon,:host(.ic-select-disabled) .expand-icon>svg>path{color:var(--ic-select-disabled-expand-icon-color)}:host(.ic-select-searchable) .expand-icon{padding-left:0;height:2.25rem}:host(.ic-select-searchable) .expand-icon>svg{height:2.25rem;padding:0 calc(var(--ic-space-xxxs) + var(--ic-space-xxs)) 0\n var(--ic-space-xxs)}:host(.ic-select-searchable:not(.ic-select-disabled)) .expand-icon>svg{cursor:pointer}.expand-icon-open{color:var(--ic-select-expand-icon-color)}.expand-icon-open,:host(.ic-select-searchable) .expand-icon-open{transform:rotateX(180deg)}.placeholder{color:var(--ic-select-content-placeholder-text)}:host(.ic-select-disabled.ic-select-searchable) .select-input::-moz-placeholder{color:var(--ic-select-content-text-disabled)}:host(.ic-select-disabled) .value-text,:host(.ic-select-disabled) .select-input,:host(.ic-select-disabled) .placeholder,:host(.ic-select-disabled.ic-select-searchable) .select-input::placeholder{color:var(--ic-select-content-text-disabled)}.select-input-end{display:flex;align-items:center}.clear-button-container{display:flex;align-items:center}.divider{width:var(--ic-space-1px);background-color:var(--ic-select-content-divider);margin:var(--ic-space-xxs) 0;border-radius:var(--ic-space-1px);height:var(--ic-space-lg)}:host(.ic-select-small) .divider{height:var(--ic-space-md)}:host(.ic-select-large) .divider{height:var(--ic-space-xl)}.clear-button{color:var(--ic-select-clear-button);position:absolute;right:calc(var(--ic-space-xl) + var(--ic-space-xxs) - var(--ic-space-1px));border-radius:var(--ic-border-radius);transition:box-shadow var(--ic-easing-transition),\n border-radius var(--ic-easing-transition)}.clear-button:focus,.clear-button:active{background-color:var(--ic-color-focus-inner);box-shadow:inset 0 0 0 0.125rem var(--ic-color-focus-outer);border-radius:0.25rem}.clear-button:focus,.clear-button:active *{fill:var(--ic-atoms-input-clear-button-focus)}.clear-button.searchable{position:static}.searchable-select-results-status,.multi-select-selected-count{border:0;clip:rect(0, 0, 0, 0, 0);height:var(--ic-space-1px);overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:var(--ic-space-1px)}::slotted([slot="icon"]){fill:var(--ic-select-content-placeholder-text)}.has-value ::slotted([slot="icon"]){fill:var(--ic-select-content-text)}.readonly ::slotted([slot="icon"]){padding:0.375rem;margin-bottom:0.75rem}@media (forced-colors: active){.has-value ::slotted([slot="icon"]){fill:currentcolor}}';const C=z;let O=0;const T=[...w,"tabindex","title"];const $=class{constructor(l){i(this,l);this.icBlur=t(this,"icBlur",7);this.icChange=t(this,"icChange",7);this.icClear=t(this,"icClear",7);this.icClose=t(this,"icClose",7);this.icFocus=t(this,"icFocus",7);this.icInput=t(this,"icInput",7);this.icOpen=t(this,"icOpen",7);this.icOptionSelect=t(this,"icOptionSelect",7);this.icOptionDeselect=t(this,"icOptionDeselect",7);this.icRetryLoad=t(this,"icRetryLoad",7);this.blurredBecauseButtonPressed=false;this.hasSetDefaultValue=false;this.hasTimedOut=false;this.inheritedAttributes={};this.initialOptionsEmpty=false;this.inputId=`ic-select-input-${O++}`;this.menuId=`${this.inputId}-menu`;this.retryButtonClick=false;this.searchableMenuItemSelected=false;this.ungroupedOptions=[];this.hostMutationObserver=null;this.clearButtonFocused=false;this.noOptions=null;this.open=false;this.pressedCharacters="";this.searchableSelectInputValue=null;this.disabled=false;this.disableAutoFiltering=false;this.emptyOptionListText="No results found";this.fullWidth=false;this.helperText="";this.hideLabel=false;this.includeDescriptionsInSearch=false;this.includeGroupTitlesInSearch=false;this.loadingErrorLabel="Loading Error";this.loadingLabel="Loading...";this.multiple=false;this.name=this.inputId;this.placeholder="Select an option";this.readonly=false;this.required=false;this.searchable=false;this.searchMatchPosition="anywhere";this.selectOnEnter=false;this.showClearButton=false;this.size="medium";this.theme="inherit";this.validationStatus="";this.validationText="";this.loading=false;this.options=[];this.filteredOptions=this.options;this.uniqueOptions=this.options;this.debounce=0;this.currDebounce=this.debounce;this.value=null;this.initialValue=this.value;this.inputValueToFilter=this.value;this.hostMutationCallback=i=>{let t=false;i.forEach((({attributeName:i,type:e,addedNodes:s,removedNodes:l})=>{if(i){const e=this.el.getAttribute(i);if(e&&T.includes(i)){this.inheritedAttributes[i]=e;t=true}}else if(e==="childList"){t=o(s,l,"icon")}}));if(t){e(this)}};this.handleRetry=i=>{var t;if(i.detail.keyPressed)(t=this.searchableSelectElement)===null||t===void 0?void 0:t.focus();this.blurredBecauseButtonPressed=true;this.retryButtonClick=true;this.hasSetDefaultValue=true;this.icRetryLoad.emit({value:this.searchable?this.searchableSelectInputValue:this.hiddenInputValue})};this.emitIcChange=i=>{if(this.multiple&&!Array.isArray(i)&&i!==null){if(this.value){let t=this.value.slice();if(this.value.includes(i)){t.splice(t.indexOf(i),1)}else{t.push(i);t=this.getValueSortedByOptions(t)}this.value=t.length===0?null:t}else{this.value=[i]}}else{this.value=i}this.icChange.emit({value:this.multiple?this.value:i})};this.emitIcInput=i=>{clearTimeout(this.debounceIcInput);this.debounceIcInput=window.setTimeout((()=>this.icInput.emit({value:i})),this.currDebounce)};this.setOptions=()=>{if(!this.hasTimedOut&&this.options!==this.noOptions){this.loading=false;clearTimeout(this.timeoutTimer);if(this.options.length>0){this.setOptionsValuesFromLabels();this.uniqueOptions=this.deduplicateOptions(this.options)}else{this.noOptions=[{label:this.emptyOptionListText,value:""}];this.uniqueOptions=this.noOptions}this.filteredOptions=this.uniqueOptions;if(this.isExternalFiltering()){this.noOptions=null;this.updateSearchableSelectResultAriaLive();this.setDefaultValue()}else if(this.initialOptionsEmpty){this.setDefaultValue();this.initialOptionsEmpty=false}}else if(!this.searchable){this.options=this.noOptions||[]}};this.deduplicateOptions=i=>{const t=[];const e=[];i.forEach((i=>{if(i.children){const s=[];i.children.forEach((i=>{if(t.includes(i.value)){console.warn(`ic-select with label ${this.label} was populated with duplicate option (value: ${i.value}) which has been removed.`)}else{t.push(i.value);s.push(i)}}));e.push(Object.assign(Object.assign({},i),{children:s}))}else{if(t.includes(i.value)){console.warn(`ic-select with label ${this.label} was populated with duplicate option (value: ${i.value}) which has been removed.`)}else{t.push(i.value);e.push(i)}}}));return e};this.setOptionsValuesFromLabels=()=>{if(this.options.length>0){this.options.map((i=>{if(!i.value){i.value=i.label}}))}};this.setUngroupedOptions=i=>{this.ungroupedOptions=i.detail.options};this.setTextColor=()=>{if(this.nativeSelectElement){this.nativeSelectElement.className=this.nativeSelectElement.selectedIndex===0?"placeholder":"select-option-selected"}};this.setMenuChange=i=>{if(this.open!==i){this.open=i}};this.getLabelFromValue=i=>n(i,this.uniqueOptions);this.getMultipleOptionsString=i=>i===null||i===void 0?void 0:i.map((i=>this.getLabelFromValue(i))).filter((i=>!!i)).join(", ");this.getFilteredChildMenuOptions=i=>Object.assign(Object.assign({},i),{children:i.children&&r(i.children,this.searchable&&!!this.includeDescriptionsInSearch,this.searchable?this.searchableSelectInputValue||"":this.pressedCharacters,this.searchable?this.searchMatchPosition:"start")});this.getValueSortedByOptions=i=>{const t=i;const e=this.ungroupedOptions.map((i=>i.value));t.sort(((i,t)=>e.indexOf(i)-e.indexOf(t)));return t};this.handleNativeSelectChange=()=>{if(this.nativeSelectElement){this.icOptionSelect.emit({value:this.nativeSelectElement.value});this.emitIcChange(this.nativeSelectElement.value)}this.setTextColor()};this.handleCustomSelectChange=i=>{var t,e;const{value:s,label:l,optionId:a}=i.detail;if(l===this.emptyOptionListText){(t=this.searchableSelectElement)===null||t===void 0?void 0:t.focus();return}if(this.searchable){this.value=s||null;this.searchableMenuItemSelected=true;if(this.value===this.currValue){this.searchableSelectInputValue=this.getLabelFromValue(this.value)||null}this.inputValueToFilter=null;this.hiddenInputValue=this.getValueFromLabel(this.searchableSelectInputValue)||null}if(s){if(this.multiple&&((e=this.value)===null||e===void 0?void 0:e.includes(s))){this.icOptionDeselect.emit({value:s})}else{this.icOptionSelect.emit({value:s})}}this.ariaActiveDescendant=a;this.emitIcChange(s||null)};this.handleSelectAllChange=({detail:i})=>{const t=this.ungroupedOptions.filter((i=>!i.disabled)).map((i=>i.value));if(i.select){const i=this.value?t.filter((i=>this.value&&!this.value.includes(i))):t;i.forEach((i=>this.icOptionSelect.emit({value:i})))}else{this.value.forEach((i=>this.icOptionDeselect.emit({value:i})))}this.emitIcChange(i.select?t:null)};this.handleMenuChange=i=>{this.open=i.detail.open;this.pressedCharacters="";if(this.searchable)this.handleFocusIndicatorDisplay()};this.handleMenuKeyPress=i=>{i.cancelBubble=true;if(!this.multiple){this.handleCharacterKeyDown(i.detail.key)}};this.handleFocusIndicatorDisplay=()=>{var i;const t=(i=this.el.shadowRoot)===null||i===void 0?void 0:i.querySelector(".focus-indicator");if(t){if(this.open){t.classList.add("focus-indicator-enabled")}else{t.classList.remove("focus-indicator-enabled")}}};this.handleMouseDown=i=>{if(!this.open){i.preventDefault()}};this.isExternalFiltering=()=>this.searchable&&!!this.disableAutoFiltering;this.handleClick=i=>{var t,e;if(!this.open&&this.menu){if(this.isExternalFiltering()){this.menu.options=this.filteredOptions}else if(!this.hasTimedOut&&!this.loading&&!((t=this.noOptions)===null||t===void 0?void 0:t.length)&&(!this.searchable||this.searchableMenuItemSelected)){this.noOptions=null;this.menu.options=this.uniqueOptions}}if(i.detail!==0){(e=this.menu)===null||e===void 0?void 0:e.handleClickOpen()}};this.handleExpandIconMouseDown=i=>{var t;if(!this.disabled){i.preventDefault();(t=this.searchableSelectElement)===null||t===void 0?void 0:t.focus();this.handleClick(i)}};this.handleClear=i=>{var t,e;i.stopPropagation();this.hasTimedOut=false;clearTimeout(this.timeoutTimer);this.clearInput();this.emitIcChange(null);this.icClear.emit();if(this.searchable){this.hiddenInputValue=null;(t=this.searchableSelectElement)===null||t===void 0?void 0:t.focus()}else{(e=this.customSelectElement)===null||e===void 0?void 0:e.focus()}};this.handleCharacterKeyDown=i=>{if(this.open&&i===" "&&this.pressedCharacters.length===0){this.setMenuChange(false)}if(i.length!==1||this.searchable){this.pressedCharacters="";return}window.clearTimeout(this.characterKeyPressTimer);this.characterKeyPressTimer=window.setTimeout((()=>this.pressedCharacters=""),1e3);if(i!==" "||!!this.pressedCharacters){this.pressedCharacters+=i;this.handleFilter();if(!this.noOptions){this.emitIcChange(this.filteredOptions[0].value)}}};this.handleNativeSelectKeyDown=i=>{if(i.key!=="Escape"&&i.key!=="Tab"||this.open){i.cancelBubble=true}this.handleCharacterKeyDown(i.key)};this.handleKeyDown=i=>{var t;if(i.key!=="Escape"&&i.key!=="Tab"||this.open){i.cancelBubble=true}const e=i.key==="ArrowDown"||i.key==="ArrowUp";if(this.menu&&!this.open){if(this.isExternalFiltering()&&(i.key==="Enter"||e)){this.menu.options=this.filteredOptions}else if(!this.hasTimedOut){this.noOptions=null;this.menu.options=this.uniqueOptions}}if(this.open&&i.key==="Enter"){this.setMenuChange(false)}else{if(!e||this.noOptions===null){if(i.key!==" "||this.pressedCharacters.length<=0){(t=this.menu)===null||t===void 0?void 0:t.handleKeyboardOpen(i)}if(!this.multiple){this.handleCharacterKeyDown(i.key)}}}};this.handleClearButtonFocus=()=>{this.clearButtonFocused=true};this.handleClearButtonBlur=i=>{var t;const e=(t=this.menu)===null||t===void 0?void 0:t.querySelector("#retry-button");if((!this.searchableSelectElement||i.relatedTarget!==this.searchableSelectElement)&&(!e||i.relatedTarget!==e)){this.setMenuChange(false);this.handleFocusIndicatorDisplay()}this.clearButtonFocused=false};this.handleFilter=()=>{var i;const t=this.deduplicateOptions(this.searchable?[...this.uniqueOptions]:this.ungroupedOptions);const e=t.some((i=>!!i.children));let s=[];let l;if(this.searchable){l=r(t,!!this.includeDescriptionsInSearch,this.inputValueToFilter||"",this.searchMatchPosition);this.searchableMenuItemSelected=false}else{l=r(t,false,this.pressedCharacters,"start")}if(!e&&((i=l[0])===null||i===void 0?void 0:i.label)!==this.emptyOptionListText){s=l}else if(e){s=t.map((i=>this.includeGroupTitlesInSearch&&l.indexOf(i)!==-1?i:this.getFilteredChildMenuOptions(i)))}if(s.length>0&&(!e||s.some((({children:i})=>i&&i.length>0)))){this.noOptions=null;this.filteredOptions=s}else{this.noOptions=[{label:this.emptyOptionListText,value:""}];this.filteredOptions=this.noOptions}};this.triggerLoading=()=>{this.hasTimedOut=false;this.noOptions=[{label:this.loadingLabel,value:"",loading:true}];if(this.filteredOptions!==this.noOptions&&this.searchable){this.filteredOptions=this.noOptions}else if(this.uniqueOptions!==this.noOptions&&!this.searchable){this.uniqueOptions=this.noOptions}if(this.timeout){this.timeoutTimer=window.setTimeout((()=>{this.loading=false;this.hasTimedOut=true;this.noOptions=[{label:this.loadingErrorLabel,value:"",timedOut:true}];this.filteredOptions=this.noOptions;if(!this.searchable)this.uniqueOptions=this.noOptions}),this.timeout)}};this.getValueFromLabel=i=>{var t;return i&&((t=this.uniqueOptions.find((t=>t.label===i)))===null||t===void 0?void 0:t.value)};this.handleSearchableSelectInput=i=>{this.searchableSelectInputValue=i.target.value;this.emitIcInput(this.searchableSelectInputValue);if(this.value!=null){this.emitIcChange(null)}this.hiddenInputValue=null;this.inputValueToFilter=this.searchableSelectInputValue;this.setMenuChange(true);if(!this.disableAutoFiltering){this.handleFilter();clearTimeout(this.debounceAria);window.setTimeout((()=>{this.updateSearchableSelectResultAriaLive()}),800)}};this.updateSearchableSelectResultAriaLive=()=>{var i;const t=(i=this.el.shadowRoot)===null||i===void 0?void 0:i.querySelector(".searchable-select-results-status");if(t){t.innerText=this.noOptions!==null?this.emptyOptionListText:""}};this.updateMultiSelectedCountAriaLive=()=>{var i,t;const e=(i=this.el.shadowRoot)===null||i===void 0?void 0:i.querySelector(".multi-select-selected-count");const s=`${(t=this.currValue)===null||t===void 0?void 0:t.length} of ${h(this.options)} selected`;if(e&&e.innerText!==s){e.innerText=s}};this.getDefaultValue=i=>this.getLabelFromValue(i)||null;this.setDefaultValue=()=>{if(!this.hasSetDefaultValue&&this.currValue){this.searchableSelectInputValue=this.searchable?this.getDefaultValue(this.currValue):null;this.initialValue=this.currValue;this.hasSetDefaultValue=true}};this.onFocus=()=>{this.icFocus.emit()};this.onBlur=({relatedTarget:i})=>{var t;const e=i;if(e!==null&&(e.tagName==="UL"&&e.className.includes("menu")||e.tagName==="LI"&&e.className.includes("option"))){return}const s=(t=this.menu)===null||t===void 0?void 0:t.querySelector("#retry-button");if(this.searchable&&!!this.menu&&e!==this.menu&&!Array.from(this.menu.querySelectorAll("[role='option']")).includes(e)&&(!this.clearButton||e!==this.clearButton)&&(!s||e!==s)){if(!this.retryButtonClick){this.setMenuChange(false);if(!this.value){this.clearInput()}}this.handleFocusIndicatorDisplay()}this.retryButtonClick=false;this.icBlur.emit()};this.onTimeoutBlur=i=>{if(i.detail.ev.relatedTarget!==this.searchableSelectElement&&!this.blurredBecauseButtonPressed){this.setMenuChange(false);this.handleFocusIndicatorDisplay();this.icBlur.emit()}this.blurredBecauseButtonPressed=false};this.handleFormReset=()=>{this.value=this.initialValue;if(this.searchable){this.searchableSelectInputValue=this.getDefaultValue(this.value);this.hiddenInputValue=this.value}};this.clearInput=()=>{var i;this.noOptions=null;if(this.searchable){(i=this.searchableSelectElement)===null||i===void 0?void 0:i.setAttribute("value","");this.searchableSelectInputValue=null;this.filteredOptions=this.uniqueOptions}};this.renderNativeOption=i=>s("option",{value:i.value,disabled:i.disabled,selected:i.value===this.currValue},i.label)}watchDisabledHandler(){c(this.disabled,this.el)}loadingHandler(i){i?this.triggerLoading():this.setOptions()}watchOptionsHandler(){this.setOptions()}debounceChangedHandler(i){if(this.currDebounce!==i){this.currDebounce=i}}valueChangedHandler(){if(this.value!==this.currValue){if(this.value&&this.multiple){this.currValue=this.getMultipleOptionsString(this.value)?this.getValueSortedByOptions(this.value):null;this.updateMultiSelectedCountAriaLive()}else{this.currValue=this.getLabelFromValue(this.value)?this.value:null}}if(this.searchable&&this.value){this.searchableSelectInputValue=this.getLabelFromValue(String(this.currValue))||null}}openChangedHandler(){this.open?this.icOpen.emit():this.icClose.emit()}disconnectedCallback(){var i;d(this.el,this.handleFormReset);(i=this.hostMutationObserver)===null||i===void 0?void 0:i.disconnect()}componentWillLoad(){const i=this.multiple?this.getMultipleOptionsString(this.value):this.getLabelFromValue(this.value);this.currValue=i?this.value:null;this.inheritedAttributes=u(this.el,T);c(this.disabled,this.el);this.setOptionsValuesFromLabels();p(this.el,this.handleFormReset);if(!this.options.length){this.initialOptionsEmpty=true;this.noOptions=[{label:this.emptyOptionListText,value:""}];this.uniqueOptions=this.noOptions;this.filteredOptions=this.noOptions}else{this.setDefaultValue();this.uniqueOptions=this.deduplicateOptions(this.options)}}componentDidLoad(){b([{prop:this.label,propName:"label"}],"Select");if(this.loading){this.triggerLoading()}if(this.searchable){this.hiddenInputValue=this.currValue}this.hostMutationObserver=new MutationObserver(this.hostMutationCallback);this.hostMutationObserver.observe(this.el,{attributes:true,childList:true})}componentDidRender(){if(this.nativeSelectElement&&!this.disabled){this.setTextColor()}}async setFocus(){if(this.nativeSelectElement){this.nativeSelectElement.focus()}else if(this.customSelectElement){this.customSelectElement.focus()}else if(this.searchableSelectElement){this.searchableSelectElement.focus()}}render(){var i;const{size:t,disabled:e,fullWidth:a,helperText:o,hideLabel:n,label:r,menuId:c,multiple:d,name:u,options:p,placeholder:b,readonly:w,required:z,searchable:C,showClearButton:O,validationStatus:T,validationText:$,currValue:H,theme:M,hiddenInputValue:B,open:S,inputId:D,searchableSelectInputValue:E,loading:j,value:I,emptyOptionListText:q,uniqueOptions:F,selectOnEnter:A,form:K,inheritedAttributes:N,ariaActiveDescendant:W,hasTimedOut:R,noOptions:U,filteredOptions:V,clearButtonFocused:Z}=this;f(this.el,C?B:H,u||D,e);const J=`${T===y.Error}`;const P=v(this.el,D,o!=="",m(T,!!e)).trim();const X=d?this.getMultipleOptionsString(H):this.getLabelFromValue(H);const _=!e&&(C?!!E:!!H&&!j&&O);return s(l,{key:"7b99a667632c04cccbe465f90c4f5a9436ed04e2",class:{"ic-select-disabled":e,"ic-select-searchable":C,[`ic-select-${t}`]:t!=="medium","ic-select-full-width":a,[`ic-theme-${M}`]:M!=="inherit"},onBlur:this.onBlur},s("ic-input-container",{key:"be3746b8ac59d37562999157b5b70fbc5fb6cc18",readonly:w},!n&&s("ic-input-label",{key:"ccb2417565197ba5d71ce4ed25c2951a042bdcab",for:D,label:r,helperText:o,required:z,disabled:e,readonly:w},s("slot",{key:"eec64f5e410f4bbdfbea7afd23f8fd3bc4592429",name:"helper-text",slot:"helper-text"})),s("ic-input-component-container",{key:"1b059596836c96987edadd6b0ec5a46c057e5fb6",ref:i=>this.anchorEl=i,class:{"menu-open":S},size:t,fullWidth:a,disabled:e,readonly:w,validationStatus:T},g(this.el,"icon")&&!e&&(!w||!!I)&&s("span",{key:"594527db6666a07c89038b173b1abd7e4191efc5",slot:"left-icon",class:{readonly:w,"has-value":!!I}},s("slot",{key:"5b982f545b7a35f2a2b16ca15278de2c6decfd00",name:"icon"})),w?s("ic-typography",null,s("p",null,X)):x()&&!d?s("select",Object.assign({ref:i=>this.nativeSelectElement=i,disabled:e,onChange:this.handleNativeSelectChange,required:z,id:D,"aria-label":r,"aria-describedby":P,"aria-invalid":J,onBlur:this.onBlur,onFocus:this.onFocus,onKeyDown:this.handleNativeSelectKeyDown,form:K},N),s("option",{value:"",selected:true,disabled:!O},b),p.map((i=>i.children?s("optgroup",{label:i.label},i.children.map((i=>this.renderNativeOption(i)))):this.renderNativeOption(i)))):C?s("div",{class:"searchable-select-container"},s("input",{class:{"select-input":true,"with-clear-button":!!E},role:"combobox",autocomplete:"off","aria-label":r,"aria-describedby":P,"aria-activedescendant":W,"aria-autocomplete":"list","aria-expanded":`${S}`,"aria-invalid":J,"aria-required":`${z}`,"aria-controls":c,ref:i=>this.searchableSelectElement=i,id:D,value:E||undefined,placeholder:b,disabled:e,onInput:this.handleSearchableSelectInput,onClick:this.handleClick,onKeyDown:this.handleKeyDown,onFocus:this.onFocus,onBlur:this.onBlur,form:K}),_&&s("div",{class:"clear-button-container"},s("ic-button",{id:"clear-button",ref:i=>this.clearButton=i,"aria-label":E&&(H===null||j)?"Clear input":"Clear selection",class:"clear-button",innerHTML:L,onClick:this.handleClear,onFocus:this.handleClearButtonFocus,onBlur:this.handleClearButtonBlur,size:t,variant:"icon",theme:Z?"light":"dark"}),s("div",{class:"divider"})),s("span",{onMouseDown:this.handleExpandIconMouseDown,class:{"expand-icon":true,"expand-icon-open":S},innerHTML:k,"aria-hidden":"true"}),s("div",{"aria-live":"polite",role:"status",class:"searchable-select-results-status"})):s("div",{class:"select-container"},s("button",{class:"select-input",ref:i=>this.customSelectElement=i,id:D,"aria-label":`${r}, ${(d&&H?`${H.length} of ${h(p)} selected, ${X}`:X)||b}${z?", required":""}`,"aria-describedby":P,"aria-invalid":J,"aria-haspopup":"listbox","aria-expanded":`${S}`,"aria-owns":c,"aria-controls":c,disabled:e,onBlur:this.onBlur,onFocus:this.onFocus,onClick:this.handleClick,onMouseDown:this.handleMouseDown,onKeyDown:this.handleKeyDown},s("ic-typography",{variant:"body",class:{"value-text":true,"with-clear-button":_,placeholder:!j&&d?!I||I.length<1:!this.getLabelFromValue(H)}},X||b),s("div",{class:"select-input-end"},_&&s("div",{class:"divider"}),s("span",{class:{"expand-icon":true,"expand-icon-open":S},innerHTML:k,"aria-hidden":"true"}))),_&&s("ic-button",{id:"clear-button","aria-label":"Clear selection",class:"clear-button",innerHTML:L,onClick:this.handleClear,onFocus:this.handleClearButtonFocus,onBlur:this.handleClearButtonBlur,size:t,variant:"icon",theme:Z?"light":"dark"}))),(!x()||d)&&s("ic-menu",{key:"841eb3f04181992c0b00b033d19fe3650544c0ad",class:{"no-results":j||R||((i=U===null||U===void 0?void 0:U[0])===null||i===void 0?void 0:i.label)===q},ref:i=>this.menu=i,inputEl:C?this.searchableSelectElement:this.customSelectElement,inputLabel:r,anchorEl:this.anchorEl,size:t,menuId:c,open:S,options:C?V:F,value:d?H:H,fullWidth:a,selectOnEnter:A,onMenuStateChange:this.handleMenuChange,onMenuOptionSelect:this.handleCustomSelectChange,onMenuOptionSelectAll:this.handleSelectAllChange,onMenuKeyPress:this.handleMenuKeyPress,onUngroupedOptionsSet:this.setUngroupedOptions,onRetryButtonClicked:this.handleRetry,parentEl:this.el,onTimeoutBlur:this.onTimeoutBlur,activationType:C||d||A?"manual":"automatic",closeOnSelect:!d,multiSelect:d?true:false,searchableSelect:C?true:false}),d&&s("div",{key:"fecc09136ac127471d4f70ba69d3a26ba0a0a602","aria-live":"polite",role:"status",class:"multi-select-selected-count"}),m(T,e)&&s("ic-input-validation",{key:"b03f8b488a2b31686e1fa7150c0a407c3533accf",class:{"menu-open":S},ariaLiveMode:"polite",status:T,message:$,for:D})))}static get delegatesFocus(){return true}get el(){return a(this)}static get watchers(){return{disabled:["watchDisabledHandler"],loading:["loadingHandler"],options:["watchOptionsHandler"],debounce:["debounceChangedHandler"],value:["valueChangedHandler"],open:["openChangedHandler"]}}};$.style=C;export{$ as ic_select};
2
- //# sourceMappingURL=p-5daa7915.entry.js.map
1
+ import{r as t,c as i,f as e,h as s,H as l,g as a}from"./p-8e4e97b4.js";import{H as o,E as n,C as r,J as h,r as c,l as d,x as u,k as p,o as b,m as f,q as v,s as m,i as g,K as x,z as w,L as y}from"./p-25007ec9.js";const k=`<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">\n<path d="M7 9.5L12 14.5L17 9.5H7Z" fill="currentColor" />\n</svg>\n`;const L=`<svg width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">\n<path d="M12.6666 4.27334L11.7266 3.33334L7.99998 7.06001L4.27331 3.33334L3.33331 4.27334L7.05998 8.00001L3.33331 11.7267L4.27331 12.6667L7.99998 8.94001L11.7266 12.6667L12.6666 11.7267L8.93998 8.00001L12.6666 4.27334Z" fill="currentColor" />\n</svg>\n`;const z='/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-webkit-text-size-adjust:100%;}body{margin:0}main{display:block}h1{font-size:2em;margin:0.67em 0}hr{box-sizing:content-box;height:0;overflow:visible;}pre{font-family:monospace, monospace;font-size:1em;}a{background-color:transparent}abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted;}b,strong{font-weight:bolder}code,kbd,samp{font-family:monospace, monospace;font-size:1em;}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-0.25em}sup{top:-0.5em}img{border-style:none}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0;}button,input{overflow:visible}button,select{text-transform:none}button,[type="button"],[type="reset"],[type="submit"]{-webkit-appearance:button}button::-moz-focus-inner,[type="button"]::-moz-focus-inner,[type="reset"]::-moz-focus-inner,[type="submit"]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type="button"]:-moz-focusring,[type="reset"]:-moz-focusring,[type="submit"]:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:0.35em 0.75em 0.625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal;}progress{vertical-align:baseline}textarea{overflow:auto}[type="checkbox"],[type="radio"]{box-sizing:border-box;padding:0;}[type="number"]::-webkit-inner-spin-button,[type="number"]::-webkit-outer-spin-button{height:auto}[type="search"]{-webkit-appearance:textfield;outline-offset:-2px;}[type="search"]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit;}details{display:block}summary{display:list-item}template{display:none}[hidden]{display:none}html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}:host{display:block;position:relative;--ic-input-label-helpertext-padding:var(--ic-space-xs);--menu-max-height:100px;--border-color:var(--ic-select-field-border);--border-color-hover:var(--ic-select-field-border-hover);--border-color-pressed:var(--ic-select-field-border-pressed);--border-color-disabled:var(--ic-select-field-border-disabled);--border-color-error:var(--ic-select-field-border-error);--border-color-error-hover:var(--ic-select-field-border-error-hover);--border-color-error-pressed:var(--ic-select-field-border-error-pressed);--border-color-success:var(--ic-select-field-border-success);--border-color-success-hover:var(--ic-select-field-border-success-hover);--border-color-success-pressed:var(--ic-select-field-border-success-pressed);--border-color-warning:var(--ic-select-field-border-warning);--border-color-warning-hover:var(--ic-select-field-border-warning-hover);--border-color-warning-pressed:var(--ic-select-field-border-warning-pressed);--ic-input-label-text-color:var(--ic-select-field-labe);--ic-input-label-helper-text-color:var(\n --ic-select-input-field-label-subtitle\n );--ic-input-validation-status-text-color:var(--ic-select-state-text);--ic-input-validation-error:var(--ic-select-state-icon-error);--ic-input-validation-warning-icon-color:var(--ic-select-state-icon-warning);--ic-input-validation-success-icon-color:var(--ic-select-state-icon-success);--menu-item-text-color:var(--ic-select-list-option-text);--menu-bg-color:var(--ic-select-list-option-background);--menu-border-color:var(--ic-select-dropdown-list-border)}:host(.ic-select-disabled){--ic-input-label-text-color:var(--ic-select-field-label-disabled);--ic-input-label-helper-text-color:var(\n --ic-select-input-field-label-subtitle-disabled\n )}:host(.ic-select-full-width){width:100%}ic-input-component-container.menu-open{--border-color:var(--ic-select-field-border-pressed)}ic-input-validation .status-icon,ic-input-validation .statustext{visibility:visible}ic-input-validation.menu-open .status-icon,ic-input-validation.menu-open .statustext{visibility:hidden;transition:visibility 0s}ic-input-label{margin-bottom:var(--ic-space-xs)}select{border:0;border-radius:var(--ic-border-radius);background-color:var(--ic-select-field-background);color:var(--ic-select-content-text);line-height:1.5rem;letter-spacing:0.005rem;width:100%;height:100%;padding-left:0.375rem;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-repeat:no-repeat;background-position:right 0.375rem center;background-image:var(--ic-select-mobile-dropdown-icon);caret-color:var(--ic-select-input-field-text-cursor)}select option,.select-option-selected{color:var(--ic-select-list-option-text)}select:disabled{color:var(--ic-select-content-text-disabled);background-image:var(--ic-select-mobile-dropdown-icon-disabled)}select:focus{border:0;outline:0}select:not([disabled]){cursor:pointer}.select-container{width:100%;display:flex;align-items:center;position:relative}.select-input{width:100%;height:100%;padding:0 0.375rem;display:flex;cursor:pointer;align-items:center;justify-content:space-between;background:none;border:none;background-color:var(--ic-select-field-background);color:var(--ic-select-content-text)}.select-input:focus{outline:none}.select-input[disabled]{pointer-events:none}:host(.ic-select-searchable) .select-input{cursor:auto}.select-input.with-clear-button{padding-right:0}.value-text{max-width:calc(100% - (var(--ic-space-lg) + var(--ic-space-xxs)));box-sizing:border-box;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;margin-bottom:0 !important}.value-text.with-clear-button{padding-right:calc(var(--ic-space-xl) + var(--ic-space-xs))}.searchable-select-container{align-items:center;display:flex;width:100%;position:relative}.expand-icon{height:var(--ic-space-lg);padding-left:var(--ic-space-xxs);color:var(--ic-select-expand-icon-color)}.expand-icon>svg{display:inline-block;width:var(--ic-space-lg);height:var(--ic-space-lg)}:host(.ic-select-disabled) .expand-icon,:host(.ic-select-disabled) .expand-icon>svg>path{color:var(--ic-select-disabled-expand-icon-color)}:host(.ic-select-searchable) .expand-icon{padding-left:0;height:2.25rem}:host(.ic-select-searchable) .expand-icon>svg{height:2.25rem;padding:0 calc(var(--ic-space-xxxs) + var(--ic-space-xxs)) 0\n var(--ic-space-xxs)}:host(.ic-select-searchable:not(.ic-select-disabled)) .expand-icon>svg{cursor:pointer}.expand-icon-open{color:var(--ic-select-expand-icon-color)}.expand-icon-open,:host(.ic-select-searchable) .expand-icon-open{transform:rotateX(180deg)}.placeholder{color:var(--ic-select-content-placeholder-text)}:host(.ic-select-disabled.ic-select-searchable) .select-input::-moz-placeholder{color:var(--ic-select-content-text-disabled)}:host(.ic-select-disabled) .value-text,:host(.ic-select-disabled) .select-input,:host(.ic-select-disabled) .placeholder,:host(.ic-select-disabled.ic-select-searchable) .select-input::placeholder{color:var(--ic-select-content-text-disabled)}.select-input-end{display:flex;align-items:center}.clear-button-container{display:flex;align-items:center}.divider{width:var(--ic-space-1px);background-color:var(--ic-select-content-divider);margin:var(--ic-space-xxs) 0;border-radius:var(--ic-space-1px);height:var(--ic-space-lg)}:host(.ic-select-small) .divider{height:var(--ic-space-md)}:host(.ic-select-large) .divider{height:var(--ic-space-xl)}.clear-button{color:var(--ic-select-clear-button);position:absolute;right:calc(var(--ic-space-xl) + var(--ic-space-xxs) - var(--ic-space-1px));border-radius:var(--ic-border-radius);transition:box-shadow var(--ic-easing-transition),\n border-radius var(--ic-easing-transition)}.clear-button:focus,.clear-button:active{background-color:var(--ic-color-focus-inner);box-shadow:inset 0 0 0 0.125rem var(--ic-color-focus-outer);border-radius:0.25rem}.clear-button:focus,.clear-button:active *{fill:var(--ic-atoms-input-clear-button-focus)}.clear-button.searchable{position:static}.searchable-select-results-status,.multi-select-selected-count{border:0;clip:rect(0, 0, 0, 0, 0);height:var(--ic-space-1px);overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:var(--ic-space-1px)}::slotted([slot="icon"]){fill:var(--ic-select-content-placeholder-text)}.has-value ::slotted([slot="icon"]){fill:var(--ic-select-content-text)}.readonly ::slotted([slot="icon"]){padding:0.375rem;margin-bottom:0.75rem}@media (forced-colors: active){.has-value ::slotted([slot="icon"]){fill:currentcolor}}';const C=z;let O=0;const T=[...w,"tabindex","title"];const $=class{constructor(l){t(this,l);this.icBlur=i(this,"icBlur",7);this.icChange=i(this,"icChange",7);this.icClear=i(this,"icClear",7);this.icClose=i(this,"icClose",7);this.icFocus=i(this,"icFocus",7);this.icInput=i(this,"icInput",7);this.icOpen=i(this,"icOpen",7);this.icOptionSelect=i(this,"icOptionSelect",7);this.icOptionDeselect=i(this,"icOptionDeselect",7);this.icRetryLoad=i(this,"icRetryLoad",7);this.blurredBecauseButtonPressed=false;this.hasSetDefaultValue=false;this.hasTimedOut=false;this.inheritedAttributes={};this.initialOptionsEmpty=false;this.inputId=`ic-select-input-${O++}`;this.menuId=`${this.inputId}-menu`;this.retryButtonClick=false;this.searchableMenuItemSelected=false;this.ungroupedOptions=[];this.hostMutationObserver=null;this.clearButtonFocused=false;this.noOptions=null;this.open=false;this.pressedCharacters="";this.searchableSelectInputValue=null;this.disabled=false;this.disableAutoFiltering=false;this.emptyOptionListText="No results found";this.fullWidth=false;this.helperText="";this.hideLabel=false;this.includeDescriptionsInSearch=false;this.includeGroupTitlesInSearch=false;this.loadingErrorLabel="Loading Error";this.loadingLabel="Loading...";this.multiple=false;this.name=this.inputId;this.placeholder="Select an option";this.readonly=false;this.required=false;this.searchable=false;this.searchMatchPosition="anywhere";this.selectOnEnter=false;this.showClearButton=false;this.size="medium";this.theme="inherit";this.validationStatus="";this.validationText="";this.loading=false;this.options=[];this.filteredOptions=this.options;this.uniqueOptions=this.options;this.debounce=0;this.currDebounce=this.debounce;this.value=null;this.initialValue=this.value;this.inputValueToFilter=this.value;this.hostMutationCallback=t=>{let i=false;t.forEach((({attributeName:t,type:e,addedNodes:s,removedNodes:l})=>{if(t){const e=this.el.getAttribute(t);if(e&&T.includes(t)){this.inheritedAttributes[t]=e;i=true}}else if(e==="childList"){i=o(s,l,"icon")}}));if(i){e(this)}};this.handleRetry=t=>{var i;if(t.detail.keyPressed)(i=this.searchableSelectElement)===null||i===void 0?void 0:i.focus();this.blurredBecauseButtonPressed=true;this.retryButtonClick=true;this.hasSetDefaultValue=true;this.icRetryLoad.emit({value:this.searchable?this.searchableSelectInputValue:this.hiddenInputValue})};this.emitIcChange=t=>{if(this.multiple&&!Array.isArray(t)&&t!==null){if(this.value){let i=this.value.slice();if(this.value.includes(t)){i.splice(i.indexOf(t),1)}else{i.push(t);i=this.getValueSortedByOptions(i)}this.value=i.length===0?null:i}else{this.value=[t]}}else{this.value=t}this.icChange.emit({value:this.multiple?this.value:t})};this.emitIcInput=t=>{clearTimeout(this.debounceIcInput);this.debounceIcInput=window.setTimeout((()=>this.icInput.emit({value:t})),this.currDebounce)};this.setOptions=()=>{if(!this.hasTimedOut&&this.options!==this.noOptions){this.loading=false;clearTimeout(this.timeoutTimer);if(this.options.length>0){this.setOptionsValuesFromLabels();this.uniqueOptions=this.deduplicateOptions(this.options)}else{this.noOptions=[{label:this.emptyOptionListText,value:""}];this.uniqueOptions=this.noOptions}this.filteredOptions=this.uniqueOptions;if(this.isExternalFiltering()){this.noOptions=null;this.updateSearchableSelectResultAriaLive();this.setDefaultValue()}else if(this.initialOptionsEmpty){this.setDefaultValue();this.initialOptionsEmpty=false}}else if(!this.searchable){this.options=this.noOptions||[]}};this.deduplicateOptions=t=>{const i=[];const e=[];t.forEach((t=>{if(t.children){const s=[];t.children.forEach((t=>{if(i.includes(t.value)){console.warn(`ic-select with label ${this.label} was populated with duplicate option (value: ${t.value}) which has been removed.`)}else{i.push(t.value);s.push(t)}}));e.push(Object.assign(Object.assign({},t),{children:s}))}else{if(i.includes(t.value)){console.warn(`ic-select with label ${this.label} was populated with duplicate option (value: ${t.value}) which has been removed.`)}else{i.push(t.value);e.push(t)}}}));return e};this.setOptionsValuesFromLabels=()=>{if(this.options.length>0){this.options.map((t=>{if(!t.value){t.value=t.label}}))}};this.setUngroupedOptions=t=>{this.ungroupedOptions=t.detail.options};this.setTextColor=()=>{if(this.nativeSelectElement){this.nativeSelectElement.className=this.nativeSelectElement.selectedIndex===0?"placeholder":"select-option-selected"}};this.setMenuChange=t=>{if(this.open!==t){this.open=t}};this.getLabelFromValue=t=>n(t,this.uniqueOptions);this.getMultipleOptionsString=t=>t===null||t===void 0?void 0:t.map((t=>this.getLabelFromValue(t))).filter((t=>!!t)).join(", ");this.getFilteredChildMenuOptions=t=>Object.assign(Object.assign({},t),{children:t.children&&r(t.children,this.searchable&&!!this.includeDescriptionsInSearch,this.searchable?this.searchableSelectInputValue||"":this.pressedCharacters,this.searchable?this.searchMatchPosition:"start")});this.getValueSortedByOptions=t=>{const i=t;const e=this.ungroupedOptions.map((t=>t.value));i.sort(((t,i)=>e.indexOf(t)-e.indexOf(i)));return i};this.handleNativeSelectChange=()=>{if(this.nativeSelectElement){this.icOptionSelect.emit({value:this.nativeSelectElement.value});this.emitIcChange(this.nativeSelectElement.value)}this.setTextColor()};this.handleCustomSelectChange=t=>{var i,e;const{value:s,label:l,optionId:a}=t.detail;if(l===this.emptyOptionListText){(i=this.searchableSelectElement)===null||i===void 0?void 0:i.focus();return}if(this.searchable){this.value=s||null;this.searchableMenuItemSelected=true;if(this.value===this.currValue){this.searchableSelectInputValue=this.getLabelFromValue(this.value)||null}this.inputValueToFilter=null;this.hiddenInputValue=this.getValueFromLabel(this.searchableSelectInputValue)||null}if(s){if(this.multiple&&((e=this.value)===null||e===void 0?void 0:e.includes(s))){this.icOptionDeselect.emit({value:s})}else{this.icOptionSelect.emit({value:s})}}this.ariaActiveDescendant=a;this.emitIcChange(s||null)};this.handleSelectAllChange=({detail:t})=>{const i=this.ungroupedOptions.filter((t=>!t.disabled)).map((t=>t.value));if(t.select){const t=this.value?i.filter((t=>this.value&&!this.value.includes(t))):i;t.forEach((t=>this.icOptionSelect.emit({value:t})))}else{this.value.forEach((t=>this.icOptionDeselect.emit({value:t})))}this.emitIcChange(t.select?i:null)};this.handleMenuChange=t=>{this.open=t.detail.open;this.pressedCharacters="";if(this.searchable)this.handleFocusIndicatorDisplay()};this.handleMenuKeyPress=t=>{t.cancelBubble=true;if(!this.multiple){this.handleCharacterKeyDown(t.detail.key)}};this.handleFocusIndicatorDisplay=()=>{var t;const i=(t=this.el.shadowRoot)===null||t===void 0?void 0:t.querySelector(".focus-indicator");if(i){if(this.open){i.classList.add("focus-indicator-enabled")}else{i.classList.remove("focus-indicator-enabled")}}};this.handleMouseDown=t=>{if(!this.open){t.preventDefault()}};this.isExternalFiltering=()=>this.searchable&&!!this.disableAutoFiltering;this.handleClick=t=>{var i,e;if(!this.open&&this.menu){if(this.isExternalFiltering()){this.menu.options=this.filteredOptions}else if(!this.hasTimedOut&&!this.loading&&!((i=this.noOptions)===null||i===void 0?void 0:i.length)&&(!this.searchable||this.searchableMenuItemSelected)){this.noOptions=null;this.menu.options=this.uniqueOptions}}if(t.detail!==0){(e=this.menu)===null||e===void 0?void 0:e.handleClickOpen()}};this.handleExpandIconMouseDown=t=>{var i;if(!this.disabled){t.preventDefault();(i=this.searchableSelectElement)===null||i===void 0?void 0:i.focus();this.handleClick(t)}};this.handleClear=t=>{var i,e;t.stopPropagation();this.hasTimedOut=false;clearTimeout(this.timeoutTimer);this.clearInput();this.emitIcChange(null);this.icClear.emit();if(this.searchable){this.hiddenInputValue=null;(i=this.searchableSelectElement)===null||i===void 0?void 0:i.focus()}else{(e=this.customSelectElement)===null||e===void 0?void 0:e.focus()}};this.handleCharacterKeyDown=t=>{if(this.open&&t===" "&&this.pressedCharacters.length===0){this.setMenuChange(false)}if(t.length!==1||this.searchable){this.pressedCharacters="";return}window.clearTimeout(this.characterKeyPressTimer);this.characterKeyPressTimer=window.setTimeout((()=>this.pressedCharacters=""),1e3);if(t!==" "||!!this.pressedCharacters){this.pressedCharacters+=t;this.handleFilter();if(!this.noOptions){this.emitIcChange(this.filteredOptions[0].value)}}};this.handleNativeSelectKeyDown=t=>{if(t.key!=="Escape"&&t.key!=="Tab"||this.open){t.cancelBubble=true}this.handleCharacterKeyDown(t.key)};this.handleKeyDown=t=>{var i;if(t.key!=="Escape"&&t.key!=="Tab"||this.open){t.cancelBubble=true}const e=t.key==="ArrowDown"||t.key==="ArrowUp";if(this.menu&&!this.open){if(this.isExternalFiltering()&&(t.key==="Enter"||e)){this.menu.options=this.filteredOptions}else if(!this.hasTimedOut){this.noOptions=null;this.menu.options=this.uniqueOptions}}if(this.open&&t.key==="Enter"){this.setMenuChange(false)}else{if(!e||this.noOptions===null){if(t.key!==" "||this.pressedCharacters.length<=0){(i=this.menu)===null||i===void 0?void 0:i.handleKeyboardOpen(t)}if(!this.multiple){this.handleCharacterKeyDown(t.key)}}}};this.handleClearButtonFocus=()=>{this.clearButtonFocused=true};this.handleClearButtonBlur=t=>{var i;const e=(i=this.menu)===null||i===void 0?void 0:i.querySelector("#retry-button");if((!this.searchableSelectElement||t.relatedTarget!==this.searchableSelectElement)&&(!e||t.relatedTarget!==e)){this.setMenuChange(false);this.handleFocusIndicatorDisplay()}this.clearButtonFocused=false};this.handleFilter=()=>{var t;const i=this.deduplicateOptions(this.searchable?[...this.uniqueOptions]:this.ungroupedOptions);const e=i.some((t=>!!t.children));let s=[];let l;if(this.searchable){l=r(i,!!this.includeDescriptionsInSearch,this.inputValueToFilter||"",this.searchMatchPosition);this.searchableMenuItemSelected=false}else{l=r(i,false,this.pressedCharacters,"start")}if(!e&&((t=l[0])===null||t===void 0?void 0:t.label)!==this.emptyOptionListText){s=l}else if(e){s=i.map((t=>this.includeGroupTitlesInSearch&&l.indexOf(t)!==-1?t:this.getFilteredChildMenuOptions(t)))}if(s.length>0&&(!e||s.some((({children:t})=>t&&t.length>0)))){this.noOptions=null;this.filteredOptions=s}else{this.noOptions=[{label:this.emptyOptionListText,value:""}];this.filteredOptions=this.noOptions}};this.triggerLoading=()=>{this.hasTimedOut=false;this.noOptions=[{label:this.loadingLabel,value:"",loading:true}];if(this.filteredOptions!==this.noOptions&&this.searchable){this.filteredOptions=this.noOptions}else if(this.uniqueOptions!==this.noOptions&&!this.searchable){this.uniqueOptions=this.noOptions}if(this.timeout){this.timeoutTimer=window.setTimeout((()=>{this.loading=false;this.hasTimedOut=true;this.noOptions=[{label:this.loadingErrorLabel,value:"",timedOut:true}];this.filteredOptions=this.noOptions;if(!this.searchable)this.uniqueOptions=this.noOptions}),this.timeout)}};this.getValueFromLabel=t=>{var i;return t&&((i=this.uniqueOptions.find((i=>i.label===t)))===null||i===void 0?void 0:i.value)};this.handleSearchableSelectInput=t=>{this.searchableSelectInputValue=t.target.value;this.emitIcInput(this.searchableSelectInputValue);if(this.value!=null){this.emitIcChange(null)}this.hiddenInputValue=null;this.inputValueToFilter=this.searchableSelectInputValue;this.setMenuChange(true);if(!this.disableAutoFiltering){this.handleFilter();clearTimeout(this.debounceAria);window.setTimeout((()=>{this.updateSearchableSelectResultAriaLive()}),800)}};this.updateSearchableSelectResultAriaLive=()=>{var t;const i=(t=this.el.shadowRoot)===null||t===void 0?void 0:t.querySelector(".searchable-select-results-status");if(i){i.innerText=this.noOptions!==null?this.emptyOptionListText:""}};this.updateMultiSelectedCountAriaLive=()=>{var t,i;const e=(t=this.el.shadowRoot)===null||t===void 0?void 0:t.querySelector(".multi-select-selected-count");const s=`${(i=this.currValue)===null||i===void 0?void 0:i.length} of ${h(this.options)} selected`;if(e&&e.innerText!==s){e.innerText=s}};this.getDefaultValue=t=>this.getLabelFromValue(t)||null;this.setDefaultValue=()=>{if(!this.hasSetDefaultValue&&this.currValue){this.searchableSelectInputValue=this.searchable?this.getDefaultValue(this.currValue):null;this.initialValue=this.currValue;this.hasSetDefaultValue=true}};this.onFocus=()=>{this.icFocus.emit()};this.onBlur=({relatedTarget:t})=>{var i;const e=t;if(e!==null&&(e.tagName==="UL"&&e.className.includes("menu")||e.tagName==="LI"&&e.className.includes("option"))){return}const s=(i=this.menu)===null||i===void 0?void 0:i.querySelector("#retry-button");if(this.searchable&&!!this.menu&&e!==this.menu&&!Array.from(this.menu.querySelectorAll("[role='option']")).includes(e)&&(!this.clearButton||e!==this.clearButton)&&(!s||e!==s)){if(!this.retryButtonClick){this.setMenuChange(false);if(!this.value){this.clearInput()}}this.handleFocusIndicatorDisplay()}this.retryButtonClick=false;this.icBlur.emit()};this.onTimeoutBlur=t=>{if(t.detail.ev.relatedTarget!==this.searchableSelectElement&&!this.blurredBecauseButtonPressed){this.setMenuChange(false);this.handleFocusIndicatorDisplay();this.icBlur.emit()}this.blurredBecauseButtonPressed=false};this.handleFormReset=()=>{this.value=this.initialValue;if(this.searchable){this.searchableSelectInputValue=this.getDefaultValue(this.value);this.hiddenInputValue=this.value}};this.clearInput=()=>{var t;this.noOptions=null;if(this.searchable){(t=this.searchableSelectElement)===null||t===void 0?void 0:t.setAttribute("value","");this.searchableSelectInputValue=null;this.filteredOptions=this.uniqueOptions}};this.renderNativeOption=t=>s("option",{value:t.value,disabled:t.disabled,selected:t.value===this.currValue},t.label)}watchDisabledHandler(){c(this.disabled,this.el)}loadingHandler(t){t?this.triggerLoading():this.setOptions()}watchOptionsHandler(){this.setOptions()}debounceChangedHandler(t){if(this.currDebounce!==t){this.currDebounce=t}}valueChangedHandler(){if(this.value!==this.currValue){if(this.value&&this.multiple){this.currValue=this.getMultipleOptionsString(this.value)?this.getValueSortedByOptions(this.value):null;this.updateMultiSelectedCountAriaLive()}else{this.currValue=this.getLabelFromValue(this.value)?this.value:null}}if(this.searchable&&this.value){this.searchableSelectInputValue=this.getLabelFromValue(String(this.currValue))||null}}openChangedHandler(){this.open?this.icOpen.emit():this.icClose.emit()}disconnectedCallback(){var t;d(this.el,this.handleFormReset);(t=this.hostMutationObserver)===null||t===void 0?void 0:t.disconnect()}componentWillLoad(){const t=this.multiple?this.getMultipleOptionsString(this.value):this.getLabelFromValue(this.value);this.currValue=t?this.value:null;this.inheritedAttributes=u(this.el,T);c(this.disabled,this.el);this.setOptionsValuesFromLabels();p(this.el,this.handleFormReset);if(!this.options.length){this.initialOptionsEmpty=true;this.noOptions=[{label:this.emptyOptionListText,value:""}];this.uniqueOptions=this.noOptions;this.filteredOptions=this.noOptions}else{this.setDefaultValue();this.uniqueOptions=this.deduplicateOptions(this.options)}}componentDidLoad(){b([{prop:this.label,propName:"label"}],"Select");if(this.loading){this.triggerLoading()}if(this.searchable){this.hiddenInputValue=this.currValue}this.hostMutationObserver=new MutationObserver(this.hostMutationCallback);this.hostMutationObserver.observe(this.el,{attributes:true,childList:true})}componentDidRender(){if(this.nativeSelectElement&&!this.disabled){this.setTextColor()}}async setFocus(){if(this.nativeSelectElement){this.nativeSelectElement.focus()}else if(this.customSelectElement){this.customSelectElement.focus()}else if(this.searchableSelectElement){this.searchableSelectElement.focus()}}render(){var t;const{size:i,disabled:e,fullWidth:a,helperText:o,hideLabel:n,label:r,menuId:c,multiple:d,name:u,options:p,placeholder:b,readonly:w,required:z,searchable:C,showClearButton:O,validationStatus:T,validationText:$,currValue:H,theme:M,hiddenInputValue:B,open:S,inputId:D,searchableSelectInputValue:E,loading:j,value:I,emptyOptionListText:q,uniqueOptions:F,selectOnEnter:A,form:K,inheritedAttributes:N,ariaActiveDescendant:W,hasTimedOut:R,noOptions:U,filteredOptions:V,clearButtonFocused:Z}=this;f(this.el,C?B:H,u||D,e);const J=`${T===y.Error}`;const P=v(this.el,D,o!=="",m(T,!!e)).trim();const X=d?this.getMultipleOptionsString(H):this.getLabelFromValue(H);const _=!e&&(C?!!E:!!H&&!j&&O);return s(l,{key:"7b99a667632c04cccbe465f90c4f5a9436ed04e2",class:{"ic-select-disabled":e,"ic-select-searchable":C,[`ic-select-${i}`]:i!=="medium","ic-select-full-width":a,[`ic-theme-${M}`]:M!=="inherit"},onBlur:this.onBlur},s("ic-input-container",{key:"be3746b8ac59d37562999157b5b70fbc5fb6cc18",readonly:w},!n&&s("ic-input-label",{key:"ccb2417565197ba5d71ce4ed25c2951a042bdcab",for:D,label:r,helperText:o,required:z,disabled:e,readonly:w},s("slot",{key:"eec64f5e410f4bbdfbea7afd23f8fd3bc4592429",name:"helper-text",slot:"helper-text"})),s("ic-input-component-container",{key:"1b059596836c96987edadd6b0ec5a46c057e5fb6",ref:t=>this.anchorEl=t,class:{"menu-open":S},size:i,fullWidth:a,disabled:e,readonly:w,validationStatus:T},g(this.el,"icon")&&!e&&(!w||!!I)&&s("span",{key:"594527db6666a07c89038b173b1abd7e4191efc5",slot:"left-icon",class:{readonly:w,"has-value":!!I}},s("slot",{key:"5b982f545b7a35f2a2b16ca15278de2c6decfd00",name:"icon"})),w?s("ic-typography",null,s("p",null,X)):x()&&!d?s("select",Object.assign({ref:t=>this.nativeSelectElement=t,disabled:e,onChange:this.handleNativeSelectChange,required:z,id:D,"aria-label":r,"aria-describedby":P,"aria-invalid":J,onBlur:this.onBlur,onFocus:this.onFocus,onKeyDown:this.handleNativeSelectKeyDown,form:K},N),s("option",{value:"",selected:true,disabled:!O},b),p.map((t=>t.children?s("optgroup",{label:t.label},t.children.map((t=>this.renderNativeOption(t)))):this.renderNativeOption(t)))):C?s("div",{class:"searchable-select-container"},s("input",{class:{"value-text":true,"select-input":true,"with-clear-button":!!E},role:"combobox",autocomplete:"off","aria-label":r,"aria-describedby":P,"aria-activedescendant":W,"aria-autocomplete":"list","aria-expanded":`${S}`,"aria-invalid":J,"aria-required":`${z}`,"aria-controls":c,ref:t=>this.searchableSelectElement=t,id:D,value:E||undefined,placeholder:b,disabled:e,onInput:this.handleSearchableSelectInput,onClick:this.handleClick,onKeyDown:this.handleKeyDown,onFocus:this.onFocus,onBlur:this.onBlur,form:K}),_&&s("div",{class:"clear-button-container"},s("ic-button",{id:"clear-button",ref:t=>this.clearButton=t,"aria-label":E&&(H===null||j)?"Clear input":"Clear selection",class:"clear-button",innerHTML:L,onClick:this.handleClear,onFocus:this.handleClearButtonFocus,onBlur:this.handleClearButtonBlur,size:i,variant:"icon",theme:Z?"light":"dark"}),s("div",{class:"divider"})),s("span",{onMouseDown:this.handleExpandIconMouseDown,class:{"expand-icon":true,"expand-icon-open":S},innerHTML:k,"aria-hidden":"true"}),s("div",{"aria-live":"polite",role:"status",class:"searchable-select-results-status"})):s("div",{class:"select-container"},s("button",{class:"select-input",ref:t=>this.customSelectElement=t,id:D,"aria-label":`${r}, ${(d&&H?`${H.length} of ${h(p)} selected, ${X}`:X)||b}${z?", required":""}`,"aria-describedby":P,"aria-invalid":J,"aria-haspopup":"listbox","aria-expanded":`${S}`,"aria-owns":c,"aria-controls":c,disabled:e,onBlur:this.onBlur,onFocus:this.onFocus,onClick:this.handleClick,onMouseDown:this.handleMouseDown,onKeyDown:this.handleKeyDown},s("ic-typography",{variant:"body",class:{"value-text":true,"with-clear-button":_,placeholder:!j&&d?!I||I.length<1:!this.getLabelFromValue(H)}},X||b),s("div",{class:"select-input-end"},_&&s("div",{class:"divider"}),s("span",{class:{"expand-icon":true,"expand-icon-open":S},innerHTML:k,"aria-hidden":"true"}))),_&&s("ic-button",{id:"clear-button","aria-label":"Clear selection",class:"clear-button",innerHTML:L,onClick:this.handleClear,onFocus:this.handleClearButtonFocus,onBlur:this.handleClearButtonBlur,size:i,variant:"icon",theme:Z?"light":"dark"}))),(!x()||d)&&s("ic-menu",{key:"1fc149003752e654e7509577e4e501bb53185c5f",class:{"no-results":j||R||((t=U===null||U===void 0?void 0:U[0])===null||t===void 0?void 0:t.label)===q},ref:t=>this.menu=t,inputEl:C?this.searchableSelectElement:this.customSelectElement,inputLabel:r,anchorEl:this.anchorEl,size:i,menuId:c,open:S,options:C?V:F,value:d?H:H,fullWidth:a,selectOnEnter:A,onMenuStateChange:this.handleMenuChange,onMenuOptionSelect:this.handleCustomSelectChange,onMenuOptionSelectAll:this.handleSelectAllChange,onMenuKeyPress:this.handleMenuKeyPress,onUngroupedOptionsSet:this.setUngroupedOptions,onRetryButtonClicked:this.handleRetry,parentEl:this.el,onTimeoutBlur:this.onTimeoutBlur,activationType:C||d||A?"manual":"automatic",closeOnSelect:!d,multiSelect:d?true:false,searchableSelect:C?true:false}),d&&s("div",{key:"a48405db489c3ef668ed0d8df77220d212577a6a","aria-live":"polite",role:"status",class:"multi-select-selected-count"}),m(T,e)&&s("ic-input-validation",{key:"fbdc0a3dcecda44c020ed309d87472b67020292f",class:{"menu-open":S},ariaLiveMode:"polite",status:T,message:$,for:D})))}static get delegatesFocus(){return true}get el(){return a(this)}static get watchers(){return{disabled:["watchDisabledHandler"],loading:["loadingHandler"],options:["watchOptionsHandler"],debounce:["debounceChangedHandler"],value:["valueChangedHandler"],open:["openChangedHandler"]}}};$.style=C;export{$ as ic_select};
2
+ //# sourceMappingURL=p-bb4ce810.entry.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["icSelectCss","IcSelectStyle0","inputIds","MUTABLE_ATTRIBUTES","IC_INHERITED_ARIA","Select","constructor","hostRef","this","blurredBecauseButtonPressed","hasSetDefaultValue","hasTimedOut","inheritedAttributes","initialOptionsEmpty","inputId","menuId","retryButtonClick","searchableMenuItemSelected","ungroupedOptions","hostMutationObserver","clearButtonFocused","noOptions","open","pressedCharacters","searchableSelectInputValue","disabled","disableAutoFiltering","emptyOptionListText","fullWidth","helperText","hideLabel","includeDescriptionsInSearch","includeGroupTitlesInSearch","loadingErrorLabel","loadingLabel","multiple","name","placeholder","readonly","required","searchable","searchMatchPosition","selectOnEnter","showClearButton","size","theme","validationStatus","validationText","loading","options","filteredOptions","uniqueOptions","debounce","currDebounce","value","initialValue","inputValueToFilter","hostMutationCallback","mutationList","forceComponentUpdate","forEach","attributeName","type","addedNodes","removedNodes","attribute","el","getAttribute","includes","checkSlotInChildMutations","forceUpdate","handleRetry","ev","detail","keyPressed","_a","searchableSelectElement","focus","icRetryLoad","emit","hiddenInputValue","emitIcChange","Array","isArray","valueArray","slice","splice","indexOf","push","getValueSortedByOptions","length","icChange","emitIcInput","clearTimeout","debounceIcInput","window","setTimeout","icInput","setOptions","timeoutTimer","setOptionsValuesFromLabels","deduplicateOptions","label","isExternalFiltering","updateSearchableSelectResultAriaLive","setDefaultValue","uniqueValues","dedupedOptions","option","children","dedupedChildren","child","console","warn","Object","assign","map","setUngroupedOptions","event","setTextColor","nativeSelectElement","className","selectedIndex","setMenuChange","getLabelFromValue","getMultipleOptionsString","selectedValues","filter","join","getFilteredChildMenuOptions","getFilteredMenuOptions","valuesFromAllOptions","sort","a","b","handleNativeSelectChange","icOptionSelect","handleCustomSelectChange","optionId","currValue","getValueFromLabel","_b","icOptionDeselect","ariaActiveDescendant","handleSelectAllChange","allValues","select","unselectedValues","handleMenuChange","handleFocusIndicatorDisplay","handleMenuKeyPress","cancelBubble","handleCharacterKeyDown","key","focusIndicator","shadowRoot","querySelector","classList","add","remove","handleMouseDown","preventDefault","handleClick","menu","handleClickOpen","handleExpandIconMouseDown","handleClear","stopPropagation","clearInput","icClear","customSelectElement","characterKeyPressTimer","handleFilter","handleNativeSelectKeyDown","handleKeyDown","isArrowKey","handleKeyboardOpen","handleClearButtonFocus","handleClearButtonBlur","retryButton","relatedTarget","isGrouped","some","newFilteredOptions","menuOptionsFiltered","triggerLoading","timeout","timedOut","find","handleSearchableSelectInput","target","debounceAria","searchableSelectResultsStatusEl","innerText","updateMultiSelectedCountAriaLive","multiSelectSelectedCountEl","selectedCount","getOptionsWithoutGroupTitlesCount","getDefaultValue","onFocus","icFocus","onBlur","tagName","from","querySelectorAll","clearButton","icBlur","onTimeoutBlur","handleFormReset","setAttribute","renderNativeOption","h","selected","watchDisabledHandler","removeDisabledFalse","loadingHandler","newValue","watchOptionsHandler","debounceChangedHandler","valueChangedHandler","String","openChangedHandler","icOpen","icClose","disconnectedCallback","removeFormResetListener","disconnect","componentWillLoad","valueInOptions","inheritAttributes","addFormResetListener","componentDidLoad","onComponentRequiredPropUndefined","prop","propName","MutationObserver","observe","attributes","childList","componentDidRender","setFocus","render","form","renderHiddenInput","invalid","IcInformationStatus","Error","describedBy","getInputDescribedByText","hasValidationStatus","trim","valueLabelString","isClearable","Host","class","for","slot","ref","anchorEl","isSlotUsed","isMobileOrTablet","onChange","id","onKeyDown","role","autocomplete","undefined","onInput","onClick","innerHTML","Clear","variant","onMouseDown","Expand","inputEl","inputLabel","onMenuStateChange","onMenuOptionSelect","onMenuOptionSelectAll","onMenuKeyPress","onUngroupedOptionsSet","onRetryButtonClicked","parentEl","activationType","closeOnSelect","multiSelect","searchableSelect","ariaLiveMode","status","message"],"sources":["src/components/ic-select/ic-select.css?tag=ic-select&encapsulation=shadow","src/components/ic-select/ic-select.tsx"],"sourcesContent":["@import \"../../global/normalize.css\";\n\n/**\n * @prop --input-width: Width of the input field\n * @prop --menu-width: Width of the dropdown menu\n * @prop --ic-z-index-menu: z-index of select menu\n */\n\n:host {\n display: block;\n position: relative;\n\n --ic-input-label-helpertext-padding: var(--ic-space-xs);\n --menu-max-height: 100px;\n --border-color: var(--ic-select-field-border);\n --border-color-hover: var(--ic-select-field-border-hover);\n --border-color-pressed: var(--ic-select-field-border-pressed);\n --border-color-disabled: var(--ic-select-field-border-disabled);\n --border-color-error: var(--ic-select-field-border-error);\n --border-color-error-hover: var(--ic-select-field-border-error-hover);\n --border-color-error-pressed: var(--ic-select-field-border-error-pressed);\n --border-color-success: var(--ic-select-field-border-success);\n --border-color-success-hover: var(--ic-select-field-border-success-hover);\n --border-color-success-pressed: var(--ic-select-field-border-success-pressed);\n --border-color-warning: var(--ic-select-field-border-warning);\n --border-color-warning-hover: var(--ic-select-field-border-warning-hover);\n --border-color-warning-pressed: var(--ic-select-field-border-warning-pressed);\n --ic-input-label-text-color: var(--ic-select-field-labe);\n --ic-input-label-helper-text-color: var(\n --ic-select-input-field-label-subtitle\n );\n --ic-input-validation-status-text-color: var(--ic-select-state-text);\n --ic-input-validation-error: var(--ic-select-state-icon-error);\n --ic-input-validation-warning-icon-color: var(--ic-select-state-icon-warning);\n --ic-input-validation-success-icon-color: var(--ic-select-state-icon-success);\n --menu-item-text-color: var(--ic-select-list-option-text);\n --menu-bg-color: var(--ic-select-list-option-background);\n --menu-border-color: var(--ic-select-dropdown-list-border);\n}\n\n:host(.ic-select-disabled) {\n --ic-input-label-text-color: var(--ic-select-field-label-disabled);\n --ic-input-label-helper-text-color: var(\n --ic-select-input-field-label-subtitle-disabled\n );\n}\n\n:host(.ic-select-full-width) {\n width: 100%;\n}\n\nic-input-component-container.menu-open {\n --border-color: var(--ic-select-field-border-pressed);\n}\n\nic-input-validation .status-icon,\nic-input-validation .statustext {\n visibility: visible;\n}\n\nic-input-validation.menu-open .status-icon,\nic-input-validation.menu-open .statustext {\n visibility: hidden;\n transition: visibility 0s;\n}\n\nic-input-label {\n margin-bottom: var(--ic-space-xs);\n}\n\nselect {\n border: 0;\n border-radius: var(--ic-border-radius);\n background-color: var(--ic-select-field-background);\n color: var(--ic-select-content-text);\n line-height: 1.5rem;\n letter-spacing: 0.005rem;\n width: 100%;\n height: 100%;\n padding-left: 0.375rem;\n appearance: none;\n background-repeat: no-repeat;\n background-position: right 0.375rem center;\n background-image: var(--ic-select-mobile-dropdown-icon);\n caret-color: var(--ic-select-input-field-text-cursor);\n}\n\nselect option,\n.select-option-selected {\n color: var(--ic-select-list-option-text);\n}\n\nselect:disabled {\n color: var(--ic-select-content-text-disabled);\n background-image: var(--ic-select-mobile-dropdown-icon-disabled);\n}\n\nselect:focus {\n border: 0;\n outline: 0;\n}\n\nselect:not([disabled]) {\n cursor: pointer;\n}\n\n.select-container {\n width: 100%;\n display: flex;\n align-items: center;\n position: relative;\n}\n\n.select-input {\n width: 100%;\n height: 100%;\n padding: 0 0.375rem;\n display: flex;\n cursor: pointer;\n align-items: center;\n justify-content: space-between;\n background: none;\n border: none;\n background-color: var(--ic-select-field-background);\n color: var(--ic-select-content-text);\n}\n\n.select-input:focus {\n outline: none;\n}\n\n.select-input[disabled] {\n pointer-events: none;\n}\n\n:host(.ic-select-searchable) .select-input {\n cursor: auto;\n}\n\n.select-input.with-clear-button {\n padding-right: 0;\n}\n\n.value-text {\n max-width: calc(100% - (var(--ic-space-lg) + var(--ic-space-xxs)));\n box-sizing: border-box;\n white-space: nowrap;\n text-overflow: ellipsis;\n overflow: hidden;\n margin-bottom: 0 !important;\n}\n\n.value-text.with-clear-button {\n padding-right: calc(var(--ic-space-xl) + var(--ic-space-xs));\n}\n\n.searchable-select-container {\n align-items: center;\n display: flex;\n width: 100%;\n position: relative;\n}\n\n.expand-icon {\n height: var(--ic-space-lg);\n padding-left: var(--ic-space-xxs);\n color: var(--ic-select-expand-icon-color);\n}\n\n.expand-icon > svg {\n display: inline-block;\n width: var(--ic-space-lg);\n height: var(--ic-space-lg);\n}\n\n:host(.ic-select-disabled) .expand-icon,\n:host(.ic-select-disabled) .expand-icon > svg > path {\n color: var(--ic-select-disabled-expand-icon-color);\n}\n\n:host(.ic-select-searchable) .expand-icon {\n padding-left: 0;\n height: 2.25rem;\n}\n\n:host(.ic-select-searchable) .expand-icon > svg {\n height: 2.25rem;\n padding: 0 calc(var(--ic-space-xxxs) + var(--ic-space-xxs)) 0\n var(--ic-space-xxs);\n}\n\n:host(.ic-select-searchable:not(.ic-select-disabled)) .expand-icon > svg {\n cursor: pointer;\n}\n\n.expand-icon-open {\n color: var(--ic-select-expand-icon-color);\n}\n\n.expand-icon-open,\n:host(.ic-select-searchable) .expand-icon-open {\n transform: rotateX(180deg);\n}\n\n.placeholder {\n color: var(--ic-select-content-placeholder-text);\n}\n\n:host(.ic-select-disabled) .value-text,\n:host(.ic-select-disabled) .select-input,\n:host(.ic-select-disabled) .placeholder,\n:host(.ic-select-disabled.ic-select-searchable) .select-input::placeholder {\n color: var(--ic-select-content-text-disabled);\n}\n\n.select-input-end {\n display: flex;\n align-items: center;\n}\n\n.clear-button-container {\n display: flex;\n align-items: center;\n}\n\n.divider {\n width: var(--ic-space-1px);\n background-color: var(--ic-select-content-divider);\n margin: var(--ic-space-xxs) 0;\n border-radius: var(--ic-space-1px);\n height: var(--ic-space-lg);\n}\n\n:host(.ic-select-small) .divider {\n height: var(--ic-space-md);\n}\n\n:host(.ic-select-large) .divider {\n height: var(--ic-space-xl);\n}\n\n.clear-button {\n color: var(--ic-select-clear-button);\n position: absolute;\n right: calc(var(--ic-space-xl) + var(--ic-space-xxs) - var(--ic-space-1px));\n border-radius: var(--ic-border-radius);\n transition: box-shadow var(--ic-easing-transition),\n border-radius var(--ic-easing-transition);\n}\n\n.clear-button:focus,\n.clear-button:active {\n background-color: var(--ic-color-focus-inner);\n box-shadow: inset 0 0 0 0.125rem var(--ic-color-focus-outer);\n border-radius: 0.25rem;\n}\n\n.clear-button:focus,\n.clear-button:active * {\n fill: var(--ic-atoms-input-clear-button-focus);\n}\n\n.clear-button.searchable {\n position: static;\n}\n\n.searchable-select-results-status,\n.multi-select-selected-count {\n border: 0;\n clip: rect(0, 0, 0, 0, 0);\n height: var(--ic-space-1px);\n overflow: hidden;\n padding: 0;\n position: absolute;\n white-space: nowrap;\n width: var(--ic-space-1px);\n}\n\n::slotted([slot=\"icon\"]) {\n fill: var(--ic-select-content-placeholder-text);\n}\n\n.has-value ::slotted([slot=\"icon\"]) {\n fill: var(--ic-select-content-text);\n}\n\n.readonly ::slotted([slot=\"icon\"]) {\n padding: 0.375rem;\n margin-bottom: 0.75rem;\n}\n\n@media (forced-colors: active) {\n .has-value ::slotted([slot=\"icon\"]) {\n fill: currentcolor;\n }\n}\n","import {\n Component,\n Element,\n Event,\n EventEmitter,\n Host,\n Method,\n Prop,\n h,\n State,\n Watch,\n forceUpdate,\n} from \"@stencil/core\";\n\nimport {\n getInputDescribedByText,\n getLabelFromValue,\n hasValidationStatus,\n inheritAttributes,\n onComponentRequiredPropUndefined,\n renderHiddenInput,\n isMobileOrTablet,\n getFilteredMenuOptions,\n getOptionsWithoutGroupTitlesCount,\n addFormResetListener,\n removeFormResetListener,\n removeDisabledFalse,\n checkSlotInChildMutations,\n isSlotUsed,\n} from \"../../utils/helpers\";\nimport { IC_INHERITED_ARIA } from \"../../utils/constants\";\nimport {\n IcInformationStatus,\n IcInformationStatusOrEmpty,\n IcMenuOption,\n IcSearchMatchPositions,\n IcMultiValueEventDetail,\n IcSizes,\n IcThemeMode,\n} from \"../../utils/types\";\nimport Expand from \"./assets/Expand.svg\";\nimport Clear from \"./assets/Clear.svg\";\nimport {\n IcMenuChangeEventDetail,\n IcOptionSelectEventDetail,\n} from \"../ic-menu/ic-menu.types\";\n\nlet inputIds = 0;\nconst MUTABLE_ATTRIBUTES = [...IC_INHERITED_ARIA, \"tabindex\", \"title\"];\n\n/**\n * @slot helper-text - Content is set as the helper text for the select.\n * @slot icon - Content will be placed to the left of the select text input.\n */\n@Component({\n tag: \"ic-select\",\n styleUrl: \"ic-select.css\",\n shadow: {\n delegatesFocus: true,\n },\n})\nexport class Select {\n private anchorEl?: HTMLElement;\n private blurredBecauseButtonPressed = false;\n private characterKeyPressTimer?: number;\n private clearButton?: HTMLIcButtonElement;\n private customSelectElement?: HTMLButtonElement;\n private debounceAria?: number;\n private hasSetDefaultValue = false;\n private hasTimedOut = false;\n private inheritedAttributes: { [k: string]: string } = {};\n private initialOptionsEmpty = false;\n private inputId = `ic-select-input-${inputIds++}`;\n private menu?: HTMLIcMenuElement;\n private menuId = `${this.inputId}-menu`;\n private nativeSelectElement?: HTMLSelectElement;\n private retryButtonClick = false;\n private searchableMenuItemSelected = false;\n private searchableSelectElement?: HTMLInputElement;\n private timeoutTimer?: number;\n private ungroupedOptions: IcMenuOption[] = [];\n private hostMutationObserver: MutationObserver | null = null;\n\n @Element() el!: HTMLIcSelectElement;\n\n @State() ariaActiveDescendant?: string;\n @State() clearButtonFocused = false;\n @State() debounceIcInput?: number;\n @State() hiddenInputValue: string | null;\n @State() noOptions: IcMenuOption[] | null = null;\n @State() open = false;\n @State() pressedCharacters = \"\";\n @State() searchableSelectInputValue: string | null = null;\n\n /**\n * If `true`, the disabled state will be set.\n */\n @Prop({ reflect: true }) disabled = false;\n @Watch(\"disabled\")\n watchDisabledHandler(): void {\n removeDisabledFalse(this.disabled, this.el);\n }\n\n /**\n * If `true`, the built in filtering will be disabled for a searchable variant. For example, if options will already be filtered from external source.\n */\n @Prop() disableAutoFiltering = false;\n\n /**\n * The text displayed when there are no options in the option list.\n */\n @Prop() emptyOptionListText = \"No results found\";\n\n /**\n * The <form> element to associate the select with.\n */\n @Prop() form?: string;\n\n /**\n * If `true`, the select will fill the width of the container.\n */\n @Prop() fullWidth = false;\n\n /**\n * The helper text that will be displayed for additional field guidance.\n */\n @Prop() helperText = \"\";\n\n /**\n * If `true`, the label will be hidden and the required label value will be applied as an aria-label.\n */\n @Prop() hideLabel = false;\n\n /**\n * If `true`, descriptions of options will be included when filtering options in a searchable select. Only applies to built in filtering.\n */\n @Prop() includeDescriptionsInSearch = false;\n\n /**\n * If `true`, group titles of grouped options will be included when filtering options in a searchable select. Only applies to built in filtering.\n */\n @Prop() includeGroupTitlesInSearch = false;\n\n /**\n * The label for the select.\n */\n @Prop() label!: string;\n\n /**\n * The message displayed when external loading times out.\n */\n @Prop() loadingErrorLabel = \"Loading Error\";\n\n /**\n * The message displayed whilst the options are being loaded externally.\n */\n @Prop() loadingLabel = \"Loading...\";\n\n /**\n * If `true`, multiple options can be selected.\n */\n @Prop() multiple = false;\n\n /**\n * The name of the control, which is submitted with the form data.\n */\n @Prop() name = this.inputId;\n\n /**\n * The placeholder value to be displayed.\n */\n @Prop() placeholder = \"Select an option\";\n\n /**\n * If `true`, the readonly state will be set.\n */\n @Prop() readonly = false;\n\n /**\n * If `true`, the select will require a value.\n */\n @Prop() required = false;\n\n /**\n * If `true`, a searchable variant of the select will be displayed which can be typed in to filter options. This functionality is only available on the single-select variant of the select component.\n */\n @Prop() searchable = false;\n\n /**\n * Whether the search string of the searchable select should match the start of or anywhere in the options. Only applies to built in filtering.\n */\n @Prop() searchMatchPosition: IcSearchMatchPositions = \"anywhere\";\n\n /**\n * If `true`, the icOptionSelect event will be fired on enter instead of ArrowUp and ArrowDown on the single select.\n */\n @Prop() selectOnEnter = false;\n\n /**\n * If `true`, a button which clears the select input when clicked will be displayed. The button will always appear on the searchable select.\n */\n @Prop() showClearButton = false;\n\n /**\n * The size of the select.\n */\n @Prop() size: IcSizes = \"medium\";\n\n /**\n * If using external filtering, set a timeout for when loading takes too long.\n */\n @Prop() timeout?: number;\n\n /**\n * Sets the theme color to the dark or light theme color. \"inherit\" will set the color based on the system settings or ic-theme component.\n */\n @Prop() theme: IcThemeMode = \"inherit\";\n\n /**\n * The validation status - e.g. 'error' | 'warning' | 'success'.\n */\n @Prop() validationStatus: IcInformationStatusOrEmpty = \"\";\n\n /**\n * The text to display as the validation message.\n */\n @Prop() validationText = \"\";\n\n /**\n * If `true`, the loading state will be triggered when fetching options asynchronously.\n */\n @Prop({ mutable: true }) loading = false;\n @Watch(\"loading\")\n loadingHandler(newValue: boolean): void {\n newValue ? this.triggerLoading() : this.setOptions();\n }\n\n /**\n * The possible selection options.\n */\n @Prop() options: IcMenuOption[] = [];\n @State() filteredOptions: IcMenuOption[] = this.options;\n @State() uniqueOptions: IcMenuOption[] = this.options;\n @Watch(\"options\")\n watchOptionsHandler(): void {\n this.setOptions();\n }\n\n /**\n * The amount of time, in milliseconds, to wait to trigger the `icInput` event after each keystroke.\n */\n @Prop() debounce = 0;\n @State() currDebounce = this.debounce;\n @Watch(\"debounce\")\n debounceChangedHandler(newValue: number): void {\n if (this.currDebounce !== newValue) {\n this.currDebounce = newValue;\n }\n }\n\n /**\n * The value of the select, reflected by the value of the currently selected option.\n * For the searchable variant, the value is also reflected by the user input.\n * For the multi-select variant, the value must be an array of option values.\n */\n @Prop({ mutable: true }) value: string | string[] | null = null;\n @State() initialValue = this.value;\n @State() inputValueToFilter: string | null = this.value as string;\n @State() currValue: string | string[] | null;\n @Watch(\"value\")\n valueChangedHandler(): void {\n if (this.value !== this.currValue) {\n if (this.value && this.multiple) {\n this.currValue = this.getMultipleOptionsString(this.value as string[])\n ? this.getValueSortedByOptions(this.value as string[])\n : null;\n this.updateMultiSelectedCountAriaLive();\n } else {\n this.currValue = this.getLabelFromValue(this.value as string)\n ? this.value\n : null;\n }\n }\n\n if (this.searchable && this.value) {\n // Only set if value not null - prevents whole input value being cleared when edited\n this.searchableSelectInputValue =\n this.getLabelFromValue(String(this.currValue)) || null;\n }\n }\n\n @Watch(\"open\")\n openChangedHandler(): void {\n this.open ? this.icOpen.emit() : this.icClose.emit();\n }\n\n /**\n * Emitted when the select loses focus.\n */\n @Event() icBlur: EventEmitter<void>;\n\n /**\n * Emitted when the value changes.\n */\n @Event() icChange: EventEmitter<IcMultiValueEventDetail>;\n\n /**\n * Emitted when the clear or clear all button is clicked.\n */\n @Event() icClear: EventEmitter<void>;\n\n /**\n * Emitted when the select options menu is closed.\n */\n @Event() icClose: EventEmitter<void>;\n\n /**\n * Emitted when the select gains focus.\n */\n @Event() icFocus: EventEmitter<void>;\n\n /**\n * Emitted when a keyboard input occurred.\n */\n @Event() icInput: EventEmitter<IcMultiValueEventDetail>;\n\n /**\n * Emitted when the select options menu is opened.\n */\n @Event() icOpen: EventEmitter<void>;\n\n /**\n * Emitted when an option is selected.\n * Selecting an option will also trigger an `icChange/onIcChange` due to the value being updated.\n */\n @Event() icOptionSelect: EventEmitter<IcOptionSelectEventDetail>;\n\n /**\n * Emitted when `multiple` is `true` and an option is deselected.\n */\n @Event() icOptionDeselect: EventEmitter<IcOptionSelectEventDetail>;\n\n /**\n * Emitted when the 'retry loading' button is clicked for a searchable variant.\n */\n @Event() icRetryLoad: EventEmitter<IcMultiValueEventDetail>;\n\n disconnectedCallback(): void {\n removeFormResetListener(this.el, this.handleFormReset);\n this.hostMutationObserver?.disconnect();\n }\n\n componentWillLoad(): void {\n const valueInOptions = this.multiple\n ? this.getMultipleOptionsString(this.value as string[])\n : this.getLabelFromValue(this.value as string);\n this.currValue = valueInOptions ? this.value : null;\n this.inheritedAttributes = inheritAttributes(this.el, MUTABLE_ATTRIBUTES);\n\n removeDisabledFalse(this.disabled, this.el);\n\n this.setOptionsValuesFromLabels();\n\n addFormResetListener(this.el, this.handleFormReset);\n\n if (!this.options.length) {\n this.initialOptionsEmpty = true;\n this.noOptions = [{ label: this.emptyOptionListText, value: \"\" }];\n this.uniqueOptions = this.noOptions;\n this.filteredOptions = this.noOptions;\n } else {\n this.setDefaultValue();\n this.uniqueOptions = this.deduplicateOptions(this.options);\n }\n }\n\n componentDidLoad(): void {\n onComponentRequiredPropUndefined(\n [{ prop: this.label, propName: \"label\" }],\n \"Select\"\n );\n\n if (this.loading) {\n this.triggerLoading();\n }\n\n if (this.searchable) {\n this.hiddenInputValue = this.currValue as string;\n }\n\n this.hostMutationObserver = new MutationObserver(this.hostMutationCallback);\n this.hostMutationObserver.observe(this.el, {\n attributes: true,\n childList: true,\n });\n }\n\n componentDidRender(): void {\n if (this.nativeSelectElement && !this.disabled) {\n this.setTextColor();\n }\n }\n\n /**\n * Sets focus on the input box.\n */\n @Method()\n async setFocus(): Promise<void> {\n if (this.nativeSelectElement) {\n this.nativeSelectElement.focus();\n } else if (this.customSelectElement) {\n this.customSelectElement.focus();\n } else if (this.searchableSelectElement) {\n this.searchableSelectElement.focus();\n }\n }\n\n // triggered when attributes of host element change\n private hostMutationCallback = (mutationList: MutationRecord[]) => {\n let forceComponentUpdate = false;\n mutationList.forEach(\n ({ attributeName, type, addedNodes, removedNodes }) => {\n if (attributeName) {\n const attribute = this.el.getAttribute(attributeName);\n if (attribute && MUTABLE_ATTRIBUTES.includes(attributeName)) {\n this.inheritedAttributes[attributeName] = attribute;\n forceComponentUpdate = true;\n }\n } else if (type === \"childList\") {\n forceComponentUpdate = checkSlotInChildMutations(\n addedNodes,\n removedNodes,\n \"icon\"\n );\n }\n }\n );\n if (forceComponentUpdate) {\n forceUpdate(this);\n }\n };\n\n private handleRetry = (ev: CustomEvent<IcMultiValueEventDetail>) => {\n if (ev.detail.keyPressed) this.searchableSelectElement?.focus();\n this.blurredBecauseButtonPressed = true;\n this.retryButtonClick = true;\n this.hasSetDefaultValue = true;\n this.icRetryLoad.emit({\n value: this.searchable\n ? this.searchableSelectInputValue\n : this.hiddenInputValue,\n });\n };\n\n private emitIcChange = (value: string | string[] | null) => {\n // If \"Select all\" button clicked, replace value with new value (array of all option values)\n if (this.multiple && !Array.isArray(value) && value !== null) {\n // Update selected options - adds / removes them, in order of option list\n // Create new array if value prop is undefined\n if (this.value) {\n let valueArray = (this.value as string[]).slice();\n\n if (this.value.includes(value)) {\n valueArray.splice(valueArray.indexOf(value), 1);\n } else {\n valueArray.push(value);\n valueArray = this.getValueSortedByOptions(valueArray);\n }\n\n this.value = valueArray.length === 0 ? null : valueArray;\n } else {\n this.value = [value];\n }\n } else {\n this.value = value;\n }\n\n this.icChange.emit({ value: this.multiple ? this.value : value });\n };\n\n private emitIcInput = (value: string) => {\n clearTimeout(this.debounceIcInput);\n this.debounceIcInput = window.setTimeout(\n () => this.icInput.emit({ value }),\n this.currDebounce\n );\n };\n\n private setOptions = () => {\n if (!this.hasTimedOut && this.options !== this.noOptions) {\n this.loading = false;\n clearTimeout(this.timeoutTimer);\n\n if (this.options.length > 0) {\n this.setOptionsValuesFromLabels();\n this.uniqueOptions = this.deduplicateOptions(this.options);\n } else {\n this.noOptions = [{ label: this.emptyOptionListText, value: \"\" }];\n this.uniqueOptions = this.noOptions;\n }\n\n this.filteredOptions = this.uniqueOptions;\n\n if (this.isExternalFiltering()) {\n // When searchable select\n this.noOptions = null;\n this.updateSearchableSelectResultAriaLive();\n this.setDefaultValue();\n } else if (this.initialOptionsEmpty) {\n this.setDefaultValue();\n this.initialOptionsEmpty = false;\n }\n } else if (!this.searchable) {\n this.options = this.noOptions || [];\n }\n };\n\n /**\n * Processes the provided array of IcMenuOptions, removing duplicates and reporting them with a console.warn\n * @param options array of IcMenuOptions\n * @returns a new options object, with all entries possessing a duplicate 'value' field removed\n */\n private deduplicateOptions = (options: IcMenuOption[]) => {\n const uniqueValues: string[] = [];\n const dedupedOptions: IcMenuOption[] = [];\n\n options.forEach((option) => {\n if (option.children) {\n //If an option has children, we will loop through them\n const dedupedChildren: IcMenuOption[] = [];\n option.children.forEach((child) => {\n if (uniqueValues.includes(child.value)) {\n console.warn(\n `ic-select with label ${this.label} was populated with duplicate option (value: ${child.value}) which has been removed.`\n );\n } else {\n uniqueValues.push(child.value);\n dedupedChildren.push(child);\n }\n });\n // construct a modified option, inserting the deduplicated children alongside the original information\n dedupedOptions.push({\n ...option,\n children: dedupedChildren,\n });\n } else {\n // If an option does not have children, assess to see if it's value has been included already\n if (uniqueValues.includes(option.value)) {\n console.warn(\n `ic-select with label ${this.label} was populated with duplicate option (value: ${option.value}) which has been removed.`\n );\n } else {\n uniqueValues.push(option.value);\n dedupedOptions.push(option);\n }\n }\n });\n return dedupedOptions;\n };\n\n /**\n * Loop through options array and for all options with no value, infer it from the label\n */\n private setOptionsValuesFromLabels = () => {\n if (this.options.length > 0) {\n this.options.map((option) => {\n if (!option.value) {\n option.value = option.label;\n }\n });\n }\n };\n\n private setUngroupedOptions = (event: CustomEvent) => {\n this.ungroupedOptions = event.detail.options;\n };\n\n private setTextColor = () => {\n if (this.nativeSelectElement) {\n this.nativeSelectElement.className =\n this.nativeSelectElement.selectedIndex === 0\n ? \"placeholder\"\n : \"select-option-selected\";\n }\n };\n\n private setMenuChange = (open: boolean) => {\n if (this.open !== open) {\n this.open = open;\n }\n };\n\n private getLabelFromValue = (value: string) =>\n getLabelFromValue(value, this.uniqueOptions);\n\n private getMultipleOptionsString = (selectedValues: string[]) =>\n selectedValues\n ?.map((value) => this.getLabelFromValue(value))\n .filter((label) => !!label)\n .join(\", \");\n\n private getFilteredChildMenuOptions = (\n option: IcMenuOption\n ): IcMenuOption => ({\n ...option,\n children:\n option.children &&\n getFilteredMenuOptions(\n option.children,\n this.searchable && !!this.includeDescriptionsInSearch,\n this.searchable\n ? this.searchableSelectInputValue || \"\"\n : this.pressedCharacters,\n this.searchable ? this.searchMatchPosition : \"start\"\n ),\n });\n\n // (For multi-select) get value array, i.e. selected option values, in order they appear in option list\n private getValueSortedByOptions = (value: string[]) => {\n const valueArray = value;\n const valuesFromAllOptions = this.ungroupedOptions.map(\n (option) => option.value\n );\n\n valueArray.sort(\n (a, b) =>\n valuesFromAllOptions.indexOf(a) - valuesFromAllOptions.indexOf(b)\n );\n\n return valueArray;\n };\n\n private handleNativeSelectChange = () => {\n if (this.nativeSelectElement) {\n this.icOptionSelect.emit({ value: this.nativeSelectElement.value });\n this.emitIcChange(this.nativeSelectElement.value);\n }\n this.setTextColor();\n };\n\n // Handle option select for when a custom input box and menu is rendered\n // (rather than native <select> - rendered when viewed on a mobile / tablet screen)\n private handleCustomSelectChange = (\n event: CustomEvent<IcOptionSelectEventDetail>\n ) => {\n const { value, label, optionId } = event.detail;\n\n if (label === this.emptyOptionListText) {\n this.searchableSelectElement?.focus();\n return;\n }\n\n if (this.searchable) {\n this.value = value || null;\n this.searchableMenuItemSelected = true;\n\n // After editing the input, if selecting the same option as before, set the input value to label again\n if (this.value === this.currValue) {\n this.searchableSelectInputValue =\n this.getLabelFromValue(this.value as string) || null;\n }\n\n this.inputValueToFilter = null;\n this.hiddenInputValue =\n this.getValueFromLabel(this.searchableSelectInputValue) || null;\n }\n\n if (value) {\n if (this.multiple && this.value?.includes(value)) {\n this.icOptionDeselect.emit({ value });\n } else {\n this.icOptionSelect.emit({ value });\n }\n }\n\n this.ariaActiveDescendant = optionId;\n this.emitIcChange(value || null);\n };\n\n private handleSelectAllChange = ({\n detail,\n }: CustomEvent<{ select: boolean }>) => {\n const allValues = this.ungroupedOptions\n .filter((option) => !option.disabled)\n .map((option) => option.value);\n\n if (detail.select) {\n // Only emit icOptionSelect for all values that are newly selected\n const unselectedValues = this.value\n ? allValues.filter(\n (value) => this.value && !(this.value as string[]).includes(value)\n )\n : allValues;\n\n unselectedValues.forEach((value) => this.icOptionSelect.emit({ value }));\n } else {\n // Only emit icOptionDeselect for values that were selected\n (this.value as string[]).forEach((value) =>\n this.icOptionDeselect.emit({ value })\n );\n }\n\n this.emitIcChange(detail.select ? allValues : null);\n };\n\n private handleMenuChange = (event: CustomEvent<IcMenuChangeEventDetail>) => {\n this.open = event.detail.open;\n this.pressedCharacters = \"\";\n\n if (this.searchable) this.handleFocusIndicatorDisplay();\n };\n\n // clears the debounce delay when navigating the menu with arrow keys etc\n // to prevent delay in change event, which should only occur when typing in input\n private handleMenuKeyPress = (ev: CustomEvent): void => {\n ev.cancelBubble = true;\n if (!this.multiple) {\n this.handleCharacterKeyDown(ev.detail.key);\n }\n };\n\n private handleFocusIndicatorDisplay = () => {\n const focusIndicator =\n this.el.shadowRoot?.querySelector(\".focus-indicator\");\n\n if (focusIndicator) {\n if (this.open) {\n focusIndicator.classList.add(\"focus-indicator-enabled\");\n } else {\n focusIndicator.classList.remove(\"focus-indicator-enabled\");\n }\n }\n };\n\n private handleMouseDown = (event: Event) => {\n if (!this.open) {\n event.preventDefault();\n }\n };\n\n private isExternalFiltering = () =>\n this.searchable && !!this.disableAutoFiltering;\n\n private handleClick = (event: MouseEvent) => {\n if (!this.open && this.menu) {\n if (this.isExternalFiltering()) {\n this.menu.options = this.filteredOptions;\n } else if (\n !this.hasTimedOut &&\n !this.loading &&\n !this.noOptions?.length &&\n (!this.searchable || this.searchableMenuItemSelected)\n ) {\n this.noOptions = null;\n this.menu.options = this.uniqueOptions;\n }\n }\n\n if (event.detail !== 0) {\n this.menu?.handleClickOpen();\n }\n };\n\n private handleExpandIconMouseDown = (event: MouseEvent) => {\n if (!this.disabled) {\n event.preventDefault();\n this.searchableSelectElement?.focus();\n this.handleClick(event);\n }\n };\n\n private handleClear = (event: Event) => {\n event.stopPropagation();\n this.hasTimedOut = false;\n clearTimeout(this.timeoutTimer);\n this.clearInput();\n this.emitIcChange(null);\n this.icClear.emit();\n\n if (this.searchable) {\n this.hiddenInputValue = null;\n this.searchableSelectElement?.focus();\n } else {\n this.customSelectElement?.focus();\n }\n };\n\n private handleCharacterKeyDown = (key: string) => {\n // Only close menu when space is pressed if not being used alongside character keys to quickly select options\n if (this.open && key === \" \" && this.pressedCharacters.length === 0) {\n this.setMenuChange(false);\n }\n\n if (key.length !== 1 || this.searchable) {\n this.pressedCharacters = \"\";\n return;\n }\n\n window.clearTimeout(this.characterKeyPressTimer);\n this.characterKeyPressTimer = window.setTimeout(\n () => (this.pressedCharacters = \"\"),\n 1000\n );\n\n if (key !== \" \" || !!this.pressedCharacters) {\n this.pressedCharacters += key;\n this.handleFilter();\n\n if (!this.noOptions) {\n this.emitIcChange(this.filteredOptions[0].value);\n }\n }\n };\n\n private handleNativeSelectKeyDown = (event: KeyboardEvent) => {\n if ((event.key !== \"Escape\" && event.key !== \"Tab\") || this.open) {\n event.cancelBubble = true;\n }\n this.handleCharacterKeyDown(event.key);\n };\n\n private handleKeyDown = (event: KeyboardEvent) => {\n if ((event.key !== \"Escape\" && event.key !== \"Tab\") || this.open) {\n event.cancelBubble = true;\n }\n const isArrowKey = event.key === \"ArrowDown\" || event.key === \"ArrowUp\";\n\n if (this.menu && !this.open) {\n if (this.isExternalFiltering() && (event.key === \"Enter\" || isArrowKey)) {\n this.menu.options = this.filteredOptions;\n } else if (!this.hasTimedOut) {\n this.noOptions = null;\n this.menu.options = this.uniqueOptions;\n }\n }\n\n if (this.open && event.key === \"Enter\") {\n this.setMenuChange(false);\n } else {\n if (!isArrowKey || this.noOptions === null) {\n if (event.key !== \" \" || this.pressedCharacters.length <= 0) {\n // Keyboard events get passed onto ic-menu\n this.menu?.handleKeyboardOpen(event);\n }\n if (!this.multiple) {\n this.handleCharacterKeyDown(event.key);\n }\n }\n }\n };\n\n private handleClearButtonFocus = () => {\n this.clearButtonFocused = true;\n };\n\n private handleClearButtonBlur = (ev: FocusEvent) => {\n const retryButton = this.menu?.querySelector(\"#retry-button\");\n if (\n (!this.searchableSelectElement ||\n ev.relatedTarget !== this.searchableSelectElement) &&\n (!retryButton || ev.relatedTarget !== retryButton)\n ) {\n this.setMenuChange(false);\n this.handleFocusIndicatorDisplay();\n }\n this.clearButtonFocused = false;\n };\n\n private handleFilter = () => {\n const options = this.deduplicateOptions(\n this.searchable ? [...this.uniqueOptions] : this.ungroupedOptions\n );\n\n const isGrouped = options.some((option) => !!option.children);\n let newFilteredOptions: IcMenuOption[] = [];\n\n let menuOptionsFiltered: IcMenuOption[];\n\n if (this.searchable) {\n menuOptionsFiltered = getFilteredMenuOptions(\n options,\n !!this.includeDescriptionsInSearch,\n this.inputValueToFilter || \"\",\n this.searchMatchPosition\n );\n this.searchableMenuItemSelected = false;\n } else {\n menuOptionsFiltered = getFilteredMenuOptions(\n options,\n false,\n this.pressedCharacters,\n \"start\"\n );\n }\n\n if (\n !isGrouped &&\n menuOptionsFiltered[0]?.label !== this.emptyOptionListText\n ) {\n newFilteredOptions = menuOptionsFiltered;\n } else if (isGrouped) {\n newFilteredOptions = options.map((option) =>\n this.includeGroupTitlesInSearch &&\n menuOptionsFiltered.indexOf(option) !== -1\n ? option\n : this.getFilteredChildMenuOptions(option)\n );\n }\n\n if (\n newFilteredOptions.length > 0 &&\n (!isGrouped ||\n newFilteredOptions.some(\n ({ children }) => children && children.length > 0\n ))\n ) {\n this.noOptions = null;\n this.filteredOptions = newFilteredOptions;\n } else {\n this.noOptions = [{ label: this.emptyOptionListText, value: \"\" }];\n this.filteredOptions = this.noOptions;\n }\n };\n\n /**\n * Put the select component into loading state.\n * Replace options with the loading message. If timeout is enabled, set the timeout and once passed, replace options with the loading error message\n */\n private triggerLoading = () => {\n this.hasTimedOut = false;\n this.noOptions = [{ label: this.loadingLabel, value: \"\", loading: true }];\n if (this.filteredOptions !== this.noOptions && this.searchable) {\n this.filteredOptions = this.noOptions;\n } else if (this.uniqueOptions !== this.noOptions && !this.searchable) {\n this.uniqueOptions = this.noOptions;\n }\n if (this.timeout) {\n this.timeoutTimer = window.setTimeout(() => {\n this.loading = false;\n this.hasTimedOut = true;\n this.noOptions = [\n { label: this.loadingErrorLabel, value: \"\", timedOut: true },\n ];\n this.filteredOptions = this.noOptions;\n if (!this.searchable) this.uniqueOptions = this.noOptions;\n }, this.timeout);\n }\n };\n\n private getValueFromLabel = (label: string | null): string | undefined =>\n label && this.uniqueOptions.find((option) => option.label === label)?.value;\n\n private handleSearchableSelectInput = (event: Event) => {\n this.searchableSelectInputValue = (event.target as HTMLInputElement).value;\n this.emitIcInput(this.searchableSelectInputValue);\n\n // De-select previous selection when input is edited\n // Only emit icChange once when editing input\n if (this.value != null) {\n this.emitIcChange(null);\n }\n\n this.hiddenInputValue = null;\n this.inputValueToFilter = this.searchableSelectInputValue;\n this.setMenuChange(true);\n\n if (!this.disableAutoFiltering) {\n this.handleFilter();\n clearTimeout(this.debounceAria);\n\n window.setTimeout(() => {\n this.updateSearchableSelectResultAriaLive();\n }, 800);\n }\n };\n\n private updateSearchableSelectResultAriaLive = () => {\n const searchableSelectResultsStatusEl =\n this.el.shadowRoot?.querySelector<HTMLDivElement>(\n \".searchable-select-results-status\"\n );\n\n if (searchableSelectResultsStatusEl) {\n searchableSelectResultsStatusEl.innerText =\n this.noOptions !== null ? this.emptyOptionListText : \"\";\n }\n };\n\n private updateMultiSelectedCountAriaLive = () => {\n const multiSelectSelectedCountEl =\n this.el.shadowRoot?.querySelector<HTMLDivElement>(\n \".multi-select-selected-count\"\n );\n\n const selectedCount = `${\n this.currValue?.length\n } of ${getOptionsWithoutGroupTitlesCount(this.options)} selected`;\n\n if (\n multiSelectSelectedCountEl &&\n multiSelectSelectedCountEl.innerText !== selectedCount\n ) {\n multiSelectSelectedCountEl.innerText = selectedCount;\n }\n };\n\n private getDefaultValue = (value: string) =>\n this.getLabelFromValue(value) || null;\n\n private setDefaultValue = () => {\n if (!this.hasSetDefaultValue && this.currValue) {\n this.searchableSelectInputValue = this.searchable\n ? this.getDefaultValue(this.currValue as string)\n : null;\n\n this.initialValue = this.currValue;\n this.hasSetDefaultValue = true;\n }\n };\n\n private onFocus = () => {\n this.icFocus.emit();\n };\n\n private onBlur = ({ relatedTarget }: FocusEvent) => {\n const target = relatedTarget as HTMLElement;\n if (\n target !== null &&\n ((target.tagName === \"UL\" && target.className.includes(\"menu\")) ||\n (target.tagName === \"LI\" && target.className.includes(\"option\")))\n ) {\n return;\n }\n\n const retryButton = this.menu?.querySelector(\"#retry-button\");\n\n if (\n this.searchable &&\n !!this.menu &&\n target !== this.menu &&\n !Array.from(this.menu.querySelectorAll(\"[role='option']\")).includes(\n target\n ) &&\n (!this.clearButton || target !== this.clearButton) &&\n (!retryButton || target !== retryButton)\n ) {\n if (!this.retryButtonClick) {\n this.setMenuChange(false);\n // Clear input field on blur when searchable if no option is selected\n if (!this.value) {\n this.clearInput();\n }\n }\n this.handleFocusIndicatorDisplay();\n }\n\n this.retryButtonClick = false;\n this.icBlur.emit();\n };\n\n private onTimeoutBlur = (ev: CustomEvent) => {\n if (\n (ev.detail.ev as FocusEvent).relatedTarget !==\n this.searchableSelectElement &&\n !this.blurredBecauseButtonPressed\n ) {\n this.setMenuChange(false);\n this.handleFocusIndicatorDisplay();\n this.icBlur.emit();\n }\n this.blurredBecauseButtonPressed = false;\n };\n\n private handleFormReset = () => {\n this.value = this.initialValue;\n if (this.searchable) {\n this.searchableSelectInputValue = this.getDefaultValue(\n this.value as string\n );\n this.hiddenInputValue = this.value as string;\n }\n };\n\n private clearInput = () => {\n this.noOptions = null;\n\n if (this.searchable) {\n this.searchableSelectElement?.setAttribute(\"value\", \"\");\n this.searchableSelectInputValue = null;\n this.filteredOptions = this.uniqueOptions;\n }\n };\n\n private renderNativeOption = (option: IcMenuOption) => (\n <option\n value={option.value}\n disabled={option.disabled}\n selected={option.value === this.currValue}\n >\n {option.label}\n </option>\n );\n\n render() {\n const {\n size,\n disabled,\n fullWidth,\n helperText,\n hideLabel,\n label,\n menuId,\n multiple,\n name,\n options,\n placeholder,\n readonly,\n required,\n searchable,\n showClearButton,\n validationStatus,\n validationText,\n currValue,\n theme,\n hiddenInputValue,\n open,\n inputId,\n searchableSelectInputValue,\n loading,\n value,\n emptyOptionListText,\n uniqueOptions,\n selectOnEnter,\n form,\n inheritedAttributes,\n ariaActiveDescendant,\n hasTimedOut,\n noOptions,\n filteredOptions,\n clearButtonFocused,\n } = this;\n\n // HTML inputs only accept 'string' for their value\n // Does not cause errors when it is a multi-select - sets value correctly, to a comma-separated string\n renderHiddenInput(\n this.el,\n searchable ? hiddenInputValue : (currValue as string),\n name || inputId,\n disabled\n );\n\n const invalid = `${validationStatus === IcInformationStatus.Error}`;\n\n const describedBy = getInputDescribedByText(\n this.el,\n inputId,\n helperText !== \"\",\n hasValidationStatus(validationStatus, !!disabled)\n ).trim();\n\n const valueLabelString = multiple\n ? this.getMultipleOptionsString(currValue as string[])\n : this.getLabelFromValue(currValue as string);\n\n const isClearable =\n !disabled &&\n (searchable\n ? !!searchableSelectInputValue\n : !!currValue && !loading && showClearButton);\n\n return (\n <Host\n class={{\n \"ic-select-disabled\": disabled,\n \"ic-select-searchable\": searchable,\n [`ic-select-${size}`]: size !== \"medium\",\n \"ic-select-full-width\": fullWidth,\n [`ic-theme-${theme}`]: theme !== \"inherit\",\n }}\n onBlur={this.onBlur}\n >\n <ic-input-container readonly={readonly}>\n {!hideLabel && (\n <ic-input-label\n for={inputId}\n label={label}\n helperText={helperText}\n required={required}\n disabled={disabled}\n readonly={readonly}\n >\n <slot name=\"helper-text\" slot=\"helper-text\"></slot>\n </ic-input-label>\n )}\n <ic-input-component-container\n ref={(el) => (this.anchorEl = el)}\n class={{ \"menu-open\": open }}\n size={size}\n fullWidth={fullWidth}\n disabled={disabled}\n readonly={readonly}\n validationStatus={validationStatus}\n >\n {isSlotUsed(this.el, \"icon\") &&\n !disabled &&\n (!readonly || !!value) && (\n <span\n slot=\"left-icon\"\n class={{\n readonly,\n \"has-value\": !!value,\n }}\n >\n <slot name=\"icon\" />\n </span>\n )}\n {readonly ? (\n <ic-typography>\n <p>{valueLabelString}</p>\n </ic-typography>\n ) : isMobileOrTablet() && !multiple ? (\n <select\n ref={(el) => (this.nativeSelectElement = el)}\n disabled={disabled}\n onChange={this.handleNativeSelectChange}\n required={required}\n id={inputId}\n aria-label={label}\n aria-describedby={describedBy}\n aria-invalid={invalid}\n onBlur={this.onBlur}\n onFocus={this.onFocus}\n onKeyDown={this.handleNativeSelectKeyDown}\n form={form}\n {...inheritedAttributes}\n >\n <option value=\"\" selected disabled={!showClearButton}>\n {placeholder}\n </option>\n {options.map((option) =>\n option.children ? (\n <optgroup label={option.label}>\n {option.children.map((child) =>\n this.renderNativeOption(child)\n )}\n </optgroup>\n ) : (\n this.renderNativeOption(option)\n )\n )}\n </select>\n ) : searchable ? (\n <div class=\"searchable-select-container\">\n <input\n class={{\n \"select-input\": true,\n \"with-clear-button\": !!searchableSelectInputValue,\n }}\n role=\"combobox\"\n autocomplete=\"off\"\n aria-label={label}\n aria-describedby={describedBy}\n aria-activedescendant={ariaActiveDescendant}\n aria-autocomplete=\"list\"\n aria-expanded={`${open}`}\n aria-invalid={invalid}\n aria-required={`${required}`}\n aria-controls={menuId}\n ref={(el) => (this.searchableSelectElement = el)}\n id={inputId}\n value={searchableSelectInputValue || undefined}\n placeholder={placeholder}\n disabled={disabled}\n onInput={this.handleSearchableSelectInput}\n onClick={this.handleClick}\n onKeyDown={this.handleKeyDown}\n onFocus={this.onFocus}\n onBlur={this.onBlur}\n form={form}\n ></input>\n {isClearable && (\n <div class=\"clear-button-container\">\n <ic-button\n id=\"clear-button\"\n ref={(el) => (this.clearButton = el)}\n aria-label={\n searchableSelectInputValue &&\n (currValue === null || loading)\n ? \"Clear input\"\n : \"Clear selection\"\n }\n class=\"clear-button\"\n innerHTML={Clear}\n onClick={this.handleClear}\n onFocus={this.handleClearButtonFocus}\n onBlur={this.handleClearButtonBlur}\n size={size}\n variant=\"icon\"\n theme={clearButtonFocused ? \"light\" : \"dark\"}\n ></ic-button>\n <div class=\"divider\"></div>\n </div>\n )}\n <span\n onMouseDown={this.handleExpandIconMouseDown}\n class={{\n \"expand-icon\": true,\n \"expand-icon-open\": open,\n }}\n innerHTML={Expand}\n aria-hidden=\"true\"\n />\n <div\n aria-live=\"polite\"\n role=\"status\"\n class=\"searchable-select-results-status\"\n ></div>\n </div>\n ) : (\n <div class=\"select-container\">\n <button\n class=\"select-input\"\n ref={(el) => (this.customSelectElement = el)}\n id={inputId}\n aria-label={`${label}, ${\n (multiple && currValue\n ? `${\n currValue.length\n } of ${getOptionsWithoutGroupTitlesCount(\n options\n )} selected, ${valueLabelString}`\n : valueLabelString) || placeholder\n }${required ? \", required\" : \"\"}`}\n aria-describedby={describedBy}\n aria-invalid={invalid}\n aria-haspopup=\"listbox\"\n aria-expanded={`${open}`}\n aria-owns={menuId}\n aria-controls={menuId}\n disabled={disabled}\n onBlur={this.onBlur}\n onFocus={this.onFocus}\n onClick={this.handleClick}\n onMouseDown={this.handleMouseDown}\n onKeyDown={this.handleKeyDown}\n >\n <ic-typography\n variant=\"body\"\n class={{\n \"value-text\": true,\n \"with-clear-button\": isClearable,\n placeholder:\n !loading && multiple\n ? !value || value.length < 1\n : !this.getLabelFromValue(currValue as string),\n }}\n >\n {valueLabelString || placeholder}\n </ic-typography>\n <div class=\"select-input-end\">\n {isClearable && <div class=\"divider\"></div>}\n <span\n class={{\n \"expand-icon\": true,\n \"expand-icon-open\": open,\n }}\n innerHTML={Expand}\n aria-hidden=\"true\"\n />\n </div>\n </button>\n {isClearable && (\n <ic-button\n id=\"clear-button\"\n aria-label=\"Clear selection\"\n class=\"clear-button\"\n innerHTML={Clear}\n onClick={this.handleClear}\n onFocus={this.handleClearButtonFocus}\n onBlur={this.handleClearButtonBlur}\n size={size}\n variant=\"icon\"\n theme={clearButtonFocused ? \"light\" : \"dark\"}\n ></ic-button>\n )}\n </div>\n )}\n </ic-input-component-container>\n {(!isMobileOrTablet() || multiple) && (\n <ic-menu\n class={{\n \"no-results\":\n loading ||\n hasTimedOut ||\n noOptions?.[0]?.label === emptyOptionListText,\n }}\n ref={(el) => (this.menu = el)}\n inputEl={\n searchable\n ? this.searchableSelectElement\n : this.customSelectElement\n }\n inputLabel={label}\n anchorEl={this.anchorEl}\n size={size}\n menuId={menuId}\n open={open}\n options={searchable ? filteredOptions : uniqueOptions}\n value={multiple ? (currValue as string[]) : (currValue as string)}\n fullWidth={fullWidth}\n selectOnEnter={selectOnEnter}\n onMenuStateChange={this.handleMenuChange}\n onMenuOptionSelect={this.handleCustomSelectChange}\n onMenuOptionSelectAll={this.handleSelectAllChange}\n onMenuKeyPress={this.handleMenuKeyPress}\n onUngroupedOptionsSet={this.setUngroupedOptions}\n onRetryButtonClicked={this.handleRetry}\n parentEl={this.el}\n onTimeoutBlur={this.onTimeoutBlur}\n activationType={\n searchable || multiple || selectOnEnter ? \"manual\" : \"automatic\"\n }\n closeOnSelect={!multiple}\n multiSelect={multiple ? true : false}\n searchableSelect={searchable ? true : false}\n ></ic-menu>\n )}\n {multiple && (\n <div\n aria-live=\"polite\"\n role=\"status\"\n class=\"multi-select-selected-count\"\n ></div>\n )}\n {hasValidationStatus(validationStatus, disabled) && (\n <ic-input-validation\n class={{ \"menu-open\": open }}\n ariaLiveMode=\"polite\"\n status={validationStatus}\n message={validationText}\n for={inputId}\n ></ic-input-validation>\n )}\n </ic-input-container>\n </Host>\n );\n }\n}\n"],"mappings":"4rBAAA,MAAMA,EAAc,6qRACpB,MAAAC,EAAeD,EC8Cf,IAAIE,EAAW,EACf,MAAMC,EAAqB,IAAIC,EAAmB,WAAY,S,MAajDC,EAAM,MAPnB,WAAAC,CAAAC,G,0XASUC,KAAAC,4BAA8B,MAK9BD,KAAAE,mBAAqB,MACr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uBhR,KAAK6G,oBAC5BoK,qBAAsBjR,KAAK+D,YAC3BmN,SAAUlR,KAAK0D,GACf6I,cAAevM,KAAKuM,cACpB4E,eACEnP,GAAcL,GAAYO,EAAgB,SAAW,YAEvDkP,eAAgBzP,EAChB0P,YAAa1P,EAAW,KAAO,MAC/B2P,iBAAkBtP,EAAa,KAAO,QAGzCL,GACCgL,EAAA,OAAA1D,IAAA,uDACY,SACV+G,KAAK,SACLV,MAAM,gCAGTL,EAAoB3M,EAAkBrB,IACrC0L,EAAA,uBAAA1D,IAAA,2CACEqG,MAAO,CAAE,YAAaxO,GACtByQ,aAAa,SACbC,OAAQlP,EACRmP,QAASlP,EACTgN,IAAKjP,K","ignoreList":[]}
1
+ {"version":3,"names":["icSelectCss","IcSelectStyle0","inputIds","MUTABLE_ATTRIBUTES","IC_INHERITED_ARIA","Select","constructor","hostRef","this","blurredBecauseButtonPressed","hasSetDefaultValue","hasTimedOut","inheritedAttributes","initialOptionsEmpty","inputId","menuId","retryButtonClick","searchableMenuItemSelected","ungroupedOptions","hostMutationObserver","clearButtonFocused","noOptions","open","pressedCharacters","searchableSelectInputValue","disabled","disableAutoFiltering","emptyOptionListText","fullWidth","helperText","hideLabel","includeDescriptionsInSearch","includeGroupTitlesInSearch","loadingErrorLabel","loadingLabel","multiple","name","placeholder","readonly","required","searchable","searchMatchPosition","selectOnEnter","showClearButton","size","theme","validationStatus","validationText","loading","options","filteredOptions","uniqueOptions","debounce","currDebounce","value","initialValue","inputValueToFilter","hostMutationCallback","mutationList","forceComponentUpdate","forEach","attributeName","type","addedNodes","removedNodes","attribute","el","getAttribute","includes","checkSlotInChildMutations","forceUpdate","handleRetry","ev","detail","keyPressed","_a","searchableSelectElement","focus","icRetryLoad","emit","hiddenInputValue","emitIcChange","Array","isArray","valueArray","slice","splice","indexOf","push","getValueSortedByOptions","length","icChange","emitIcInput","clearTimeout","debounceIcInput","window","setTimeout","icInput","setOptions","timeoutTimer","setOptionsValuesFromLabels","deduplicateOptions","label","isExternalFiltering","updateSearchableSelectResultAriaLive","setDefaultValue","uniqueValues","dedupedOptions","option","children","dedupedChildren","child","console","warn","Object","assign","map","setUngroupedOptions","event","setTextColor","nativeSelectElement","className","selectedIndex","setMenuChange","getLabelFromValue","getMultipleOptionsString","selectedValues","filter","join","getFilteredChildMenuOptions","getFilteredMenuOptions","valuesFromAllOptions","sort","a","b","handleNativeSelectChange","icOptionSelect","handleCustomSelectChange","optionId","currValue","getValueFromLabel","_b","icOptionDeselect","ariaActiveDescendant","handleSelectAllChange","allValues","select","unselectedValues","handleMenuChange","handleFocusIndicatorDisplay","handleMenuKeyPress","cancelBubble","handleCharacterKeyDown","key","focusIndicator","shadowRoot","querySelector","classList","add","remove","handleMouseDown","preventDefault","handleClick","menu","handleClickOpen","handleExpandIconMouseDown","handleClear","stopPropagation","clearInput","icClear","customSelectElement","characterKeyPressTimer","handleFilter","handleNativeSelectKeyDown","handleKeyDown","isArrowKey","handleKeyboardOpen","handleClearButtonFocus","handleClearButtonBlur","retryButton","relatedTarget","isGrouped","some","newFilteredOptions","menuOptionsFiltered","triggerLoading","timeout","timedOut","find","handleSearchableSelectInput","target","debounceAria","searchableSelectResultsStatusEl","innerText","updateMultiSelectedCountAriaLive","multiSelectSelectedCountEl","selectedCount","getOptionsWithoutGroupTitlesCount","getDefaultValue","onFocus","icFocus","onBlur","tagName","from","querySelectorAll","clearButton","icBlur","onTimeoutBlur","handleFormReset","setAttribute","renderNativeOption","h","selected","watchDisabledHandler","removeDisabledFalse","loadingHandler","newValue","watchOptionsHandler","debounceChangedHandler","valueChangedHandler","String","openChangedHandler","icOpen","icClose","disconnectedCallback","removeFormResetListener","disconnect","componentWillLoad","valueInOptions","inheritAttributes","addFormResetListener","componentDidLoad","onComponentRequiredPropUndefined","prop","propName","MutationObserver","observe","attributes","childList","componentDidRender","setFocus","render","form","renderHiddenInput","invalid","IcInformationStatus","Error","describedBy","getInputDescribedByText","hasValidationStatus","trim","valueLabelString","isClearable","Host","class","for","slot","ref","anchorEl","isSlotUsed","isMobileOrTablet","onChange","id","onKeyDown","role","autocomplete","undefined","onInput","onClick","innerHTML","Clear","variant","onMouseDown","Expand","inputEl","inputLabel","onMenuStateChange","onMenuOptionSelect","onMenuOptionSelectAll","onMenuKeyPress","onUngroupedOptionsSet","onRetryButtonClicked","parentEl","activationType","closeOnSelect","multiSelect","searchableSelect","ariaLiveMode","status","message"],"sources":["src/components/ic-select/ic-select.css?tag=ic-select&encapsulation=shadow","src/components/ic-select/ic-select.tsx"],"sourcesContent":["@import \"../../global/normalize.css\";\n\n/**\n * @prop --input-width: Width of the input field\n * @prop --menu-width: Width of the dropdown menu\n * @prop --ic-z-index-menu: z-index of select menu\n */\n\n:host {\n display: block;\n position: relative;\n\n --ic-input-label-helpertext-padding: var(--ic-space-xs);\n --menu-max-height: 100px;\n --border-color: var(--ic-select-field-border);\n --border-color-hover: var(--ic-select-field-border-hover);\n --border-color-pressed: var(--ic-select-field-border-pressed);\n --border-color-disabled: var(--ic-select-field-border-disabled);\n --border-color-error: var(--ic-select-field-border-error);\n --border-color-error-hover: var(--ic-select-field-border-error-hover);\n --border-color-error-pressed: var(--ic-select-field-border-error-pressed);\n --border-color-success: var(--ic-select-field-border-success);\n --border-color-success-hover: var(--ic-select-field-border-success-hover);\n --border-color-success-pressed: var(--ic-select-field-border-success-pressed);\n --border-color-warning: var(--ic-select-field-border-warning);\n --border-color-warning-hover: var(--ic-select-field-border-warning-hover);\n --border-color-warning-pressed: var(--ic-select-field-border-warning-pressed);\n --ic-input-label-text-color: var(--ic-select-field-labe);\n --ic-input-label-helper-text-color: var(\n --ic-select-input-field-label-subtitle\n );\n --ic-input-validation-status-text-color: var(--ic-select-state-text);\n --ic-input-validation-error: var(--ic-select-state-icon-error);\n --ic-input-validation-warning-icon-color: var(--ic-select-state-icon-warning);\n --ic-input-validation-success-icon-color: var(--ic-select-state-icon-success);\n --menu-item-text-color: var(--ic-select-list-option-text);\n --menu-bg-color: var(--ic-select-list-option-background);\n --menu-border-color: var(--ic-select-dropdown-list-border);\n}\n\n:host(.ic-select-disabled) {\n --ic-input-label-text-color: var(--ic-select-field-label-disabled);\n --ic-input-label-helper-text-color: var(\n --ic-select-input-field-label-subtitle-disabled\n );\n}\n\n:host(.ic-select-full-width) {\n width: 100%;\n}\n\nic-input-component-container.menu-open {\n --border-color: var(--ic-select-field-border-pressed);\n}\n\nic-input-validation .status-icon,\nic-input-validation .statustext {\n visibility: visible;\n}\n\nic-input-validation.menu-open .status-icon,\nic-input-validation.menu-open .statustext {\n visibility: hidden;\n transition: visibility 0s;\n}\n\nic-input-label {\n margin-bottom: var(--ic-space-xs);\n}\n\nselect {\n border: 0;\n border-radius: var(--ic-border-radius);\n background-color: var(--ic-select-field-background);\n color: var(--ic-select-content-text);\n line-height: 1.5rem;\n letter-spacing: 0.005rem;\n width: 100%;\n height: 100%;\n padding-left: 0.375rem;\n appearance: none;\n background-repeat: no-repeat;\n background-position: right 0.375rem center;\n background-image: var(--ic-select-mobile-dropdown-icon);\n caret-color: var(--ic-select-input-field-text-cursor);\n}\n\nselect option,\n.select-option-selected {\n color: var(--ic-select-list-option-text);\n}\n\nselect:disabled {\n color: var(--ic-select-content-text-disabled);\n background-image: var(--ic-select-mobile-dropdown-icon-disabled);\n}\n\nselect:focus {\n border: 0;\n outline: 0;\n}\n\nselect:not([disabled]) {\n cursor: pointer;\n}\n\n.select-container {\n width: 100%;\n display: flex;\n align-items: center;\n position: relative;\n}\n\n.select-input {\n width: 100%;\n height: 100%;\n padding: 0 0.375rem;\n display: flex;\n cursor: pointer;\n align-items: center;\n justify-content: space-between;\n background: none;\n border: none;\n background-color: var(--ic-select-field-background);\n color: var(--ic-select-content-text);\n}\n\n.select-input:focus {\n outline: none;\n}\n\n.select-input[disabled] {\n pointer-events: none;\n}\n\n:host(.ic-select-searchable) .select-input {\n cursor: auto;\n}\n\n.select-input.with-clear-button {\n padding-right: 0;\n}\n\n.value-text {\n max-width: calc(100% - (var(--ic-space-lg) + var(--ic-space-xxs)));\n box-sizing: border-box;\n white-space: nowrap;\n text-overflow: ellipsis;\n overflow: hidden;\n margin-bottom: 0 !important;\n}\n\n.value-text.with-clear-button {\n padding-right: calc(var(--ic-space-xl) + var(--ic-space-xs));\n}\n\n.searchable-select-container {\n align-items: center;\n display: flex;\n width: 100%;\n position: relative;\n}\n\n.expand-icon {\n height: var(--ic-space-lg);\n padding-left: var(--ic-space-xxs);\n color: var(--ic-select-expand-icon-color);\n}\n\n.expand-icon > svg {\n display: inline-block;\n width: var(--ic-space-lg);\n height: var(--ic-space-lg);\n}\n\n:host(.ic-select-disabled) .expand-icon,\n:host(.ic-select-disabled) .expand-icon > svg > path {\n color: var(--ic-select-disabled-expand-icon-color);\n}\n\n:host(.ic-select-searchable) .expand-icon {\n padding-left: 0;\n height: 2.25rem;\n}\n\n:host(.ic-select-searchable) .expand-icon > svg {\n height: 2.25rem;\n padding: 0 calc(var(--ic-space-xxxs) + var(--ic-space-xxs)) 0\n var(--ic-space-xxs);\n}\n\n:host(.ic-select-searchable:not(.ic-select-disabled)) .expand-icon > svg {\n cursor: pointer;\n}\n\n.expand-icon-open {\n color: var(--ic-select-expand-icon-color);\n}\n\n.expand-icon-open,\n:host(.ic-select-searchable) .expand-icon-open {\n transform: rotateX(180deg);\n}\n\n.placeholder {\n color: var(--ic-select-content-placeholder-text);\n}\n\n:host(.ic-select-disabled) .value-text,\n:host(.ic-select-disabled) .select-input,\n:host(.ic-select-disabled) .placeholder,\n:host(.ic-select-disabled.ic-select-searchable) .select-input::placeholder {\n color: var(--ic-select-content-text-disabled);\n}\n\n.select-input-end {\n display: flex;\n align-items: center;\n}\n\n.clear-button-container {\n display: flex;\n align-items: center;\n}\n\n.divider {\n width: var(--ic-space-1px);\n background-color: var(--ic-select-content-divider);\n margin: var(--ic-space-xxs) 0;\n border-radius: var(--ic-space-1px);\n height: var(--ic-space-lg);\n}\n\n:host(.ic-select-small) .divider {\n height: var(--ic-space-md);\n}\n\n:host(.ic-select-large) .divider {\n height: var(--ic-space-xl);\n}\n\n.clear-button {\n color: var(--ic-select-clear-button);\n position: absolute;\n right: calc(var(--ic-space-xl) + var(--ic-space-xxs) - var(--ic-space-1px));\n border-radius: var(--ic-border-radius);\n transition: box-shadow var(--ic-easing-transition),\n border-radius var(--ic-easing-transition);\n}\n\n.clear-button:focus,\n.clear-button:active {\n background-color: var(--ic-color-focus-inner);\n box-shadow: inset 0 0 0 0.125rem var(--ic-color-focus-outer);\n border-radius: 0.25rem;\n}\n\n.clear-button:focus,\n.clear-button:active * {\n fill: var(--ic-atoms-input-clear-button-focus);\n}\n\n.clear-button.searchable {\n position: static;\n}\n\n.searchable-select-results-status,\n.multi-select-selected-count {\n border: 0;\n clip: rect(0, 0, 0, 0, 0);\n height: var(--ic-space-1px);\n overflow: hidden;\n padding: 0;\n position: absolute;\n white-space: nowrap;\n width: var(--ic-space-1px);\n}\n\n::slotted([slot=\"icon\"]) {\n fill: var(--ic-select-content-placeholder-text);\n}\n\n.has-value ::slotted([slot=\"icon\"]) {\n fill: var(--ic-select-content-text);\n}\n\n.readonly ::slotted([slot=\"icon\"]) {\n padding: 0.375rem;\n margin-bottom: 0.75rem;\n}\n\n@media (forced-colors: active) {\n .has-value ::slotted([slot=\"icon\"]) {\n fill: currentcolor;\n }\n}\n","import {\n Component,\n Element,\n Event,\n EventEmitter,\n Host,\n Method,\n Prop,\n h,\n State,\n Watch,\n forceUpdate,\n} from \"@stencil/core\";\n\nimport {\n getInputDescribedByText,\n getLabelFromValue,\n hasValidationStatus,\n inheritAttributes,\n onComponentRequiredPropUndefined,\n renderHiddenInput,\n isMobileOrTablet,\n getFilteredMenuOptions,\n getOptionsWithoutGroupTitlesCount,\n addFormResetListener,\n removeFormResetListener,\n removeDisabledFalse,\n checkSlotInChildMutations,\n isSlotUsed,\n} from \"../../utils/helpers\";\nimport { IC_INHERITED_ARIA } from \"../../utils/constants\";\nimport {\n IcInformationStatus,\n IcInformationStatusOrEmpty,\n IcMenuOption,\n IcSearchMatchPositions,\n IcMultiValueEventDetail,\n IcSizes,\n IcThemeMode,\n} from \"../../utils/types\";\nimport Expand from \"./assets/Expand.svg\";\nimport Clear from \"./assets/Clear.svg\";\nimport {\n IcMenuChangeEventDetail,\n IcOptionSelectEventDetail,\n} from \"../ic-menu/ic-menu.types\";\n\nlet inputIds = 0;\nconst MUTABLE_ATTRIBUTES = [...IC_INHERITED_ARIA, \"tabindex\", \"title\"];\n\n/**\n * @slot helper-text - Content is set as the helper text for the select.\n * @slot icon - Content will be placed to the left of the select text input.\n */\n@Component({\n tag: \"ic-select\",\n styleUrl: \"ic-select.css\",\n shadow: {\n delegatesFocus: true,\n },\n})\nexport class Select {\n private anchorEl?: HTMLElement;\n private blurredBecauseButtonPressed = false;\n private characterKeyPressTimer?: number;\n private clearButton?: HTMLIcButtonElement;\n private customSelectElement?: HTMLButtonElement;\n private debounceAria?: number;\n private hasSetDefaultValue = false;\n private hasTimedOut = false;\n private inheritedAttributes: { [k: string]: string } = {};\n private initialOptionsEmpty = false;\n private inputId = `ic-select-input-${inputIds++}`;\n private menu?: HTMLIcMenuElement;\n private menuId = `${this.inputId}-menu`;\n private nativeSelectElement?: HTMLSelectElement;\n private retryButtonClick = false;\n private searchableMenuItemSelected = false;\n private searchableSelectElement?: HTMLInputElement;\n private timeoutTimer?: number;\n private ungroupedOptions: IcMenuOption[] = [];\n private hostMutationObserver: MutationObserver | null = null;\n\n @Element() el!: HTMLIcSelectElement;\n\n @State() ariaActiveDescendant?: string;\n @State() clearButtonFocused = false;\n @State() debounceIcInput?: number;\n @State() hiddenInputValue: string | null;\n @State() noOptions: IcMenuOption[] | null = null;\n @State() open = false;\n @State() pressedCharacters = \"\";\n @State() searchableSelectInputValue: string | null = null;\n\n /**\n * If `true`, the disabled state will be set.\n */\n @Prop({ reflect: true }) disabled = false;\n @Watch(\"disabled\")\n watchDisabledHandler(): void {\n removeDisabledFalse(this.disabled, this.el);\n }\n\n /**\n * If `true`, the built in filtering will be disabled for a searchable variant. For example, if options will already be filtered from external source.\n */\n @Prop() disableAutoFiltering = false;\n\n /**\n * The text displayed when there are no options in the option list.\n */\n @Prop() emptyOptionListText = \"No results found\";\n\n /**\n * The <form> element to associate the select with.\n */\n @Prop() form?: string;\n\n /**\n * If `true`, the select will fill the width of the container.\n */\n @Prop() fullWidth = false;\n\n /**\n * The helper text that will be displayed for additional field guidance.\n */\n @Prop() helperText = \"\";\n\n /**\n * If `true`, the label will be hidden and the required label value will be applied as an aria-label.\n */\n @Prop() hideLabel = false;\n\n /**\n * If `true`, descriptions of options will be included when filtering options in a searchable select. Only applies to built in filtering.\n */\n @Prop() includeDescriptionsInSearch = false;\n\n /**\n * If `true`, group titles of grouped options will be included when filtering options in a searchable select. Only applies to built in filtering.\n */\n @Prop() includeGroupTitlesInSearch = false;\n\n /**\n * The label for the select.\n */\n @Prop() label!: string;\n\n /**\n * The message displayed when external loading times out.\n */\n @Prop() loadingErrorLabel = \"Loading Error\";\n\n /**\n * The message displayed whilst the options are being loaded externally.\n */\n @Prop() loadingLabel = \"Loading...\";\n\n /**\n * If `true`, multiple options can be selected.\n */\n @Prop() multiple = false;\n\n /**\n * The name of the control, which is submitted with the form data.\n */\n @Prop() name = this.inputId;\n\n /**\n * The placeholder value to be displayed.\n */\n @Prop() placeholder = \"Select an option\";\n\n /**\n * If `true`, the readonly state will be set.\n */\n @Prop() readonly = false;\n\n /**\n * If `true`, the select will require a value.\n */\n @Prop() required = false;\n\n /**\n * If `true`, a searchable variant of the select will be displayed which can be typed in to filter options. This functionality is only available on the single-select variant of the select component.\n */\n @Prop() searchable = false;\n\n /**\n * Whether the search string of the searchable select should match the start of or anywhere in the options. Only applies to built in filtering.\n */\n @Prop() searchMatchPosition: IcSearchMatchPositions = \"anywhere\";\n\n /**\n * If `true`, the icOptionSelect event will be fired on enter instead of ArrowUp and ArrowDown on the single select.\n */\n @Prop() selectOnEnter = false;\n\n /**\n * If `true`, a button which clears the select input when clicked will be displayed. The button will always appear on the searchable select.\n */\n @Prop() showClearButton = false;\n\n /**\n * The size of the select.\n */\n @Prop() size: IcSizes = \"medium\";\n\n /**\n * If using external filtering, set a timeout for when loading takes too long.\n */\n @Prop() timeout?: number;\n\n /**\n * Sets the theme color to the dark or light theme color. \"inherit\" will set the color based on the system settings or ic-theme component.\n */\n @Prop() theme: IcThemeMode = \"inherit\";\n\n /**\n * The validation status - e.g. 'error' | 'warning' | 'success'.\n */\n @Prop() validationStatus: IcInformationStatusOrEmpty = \"\";\n\n /**\n * The text to display as the validation message.\n */\n @Prop() validationText = \"\";\n\n /**\n * If `true`, the loading state will be triggered when fetching options asynchronously.\n */\n @Prop({ mutable: true }) loading = false;\n @Watch(\"loading\")\n loadingHandler(newValue: boolean): void {\n newValue ? this.triggerLoading() : this.setOptions();\n }\n\n /**\n * The possible selection options.\n */\n @Prop() options: IcMenuOption[] = [];\n @State() filteredOptions: IcMenuOption[] = this.options;\n @State() uniqueOptions: IcMenuOption[] = this.options;\n @Watch(\"options\")\n watchOptionsHandler(): void {\n this.setOptions();\n }\n\n /**\n * The amount of time, in milliseconds, to wait to trigger the `icInput` event after each keystroke.\n */\n @Prop() debounce = 0;\n @State() currDebounce = this.debounce;\n @Watch(\"debounce\")\n debounceChangedHandler(newValue: number): void {\n if (this.currDebounce !== newValue) {\n this.currDebounce = newValue;\n }\n }\n\n /**\n * The value of the select, reflected by the value of the currently selected option.\n * For the searchable variant, the value is also reflected by the user input.\n * For the multi-select variant, the value must be an array of option values.\n */\n @Prop({ mutable: true }) value: string | string[] | null = null;\n @State() initialValue = this.value;\n @State() inputValueToFilter: string | null = this.value as string;\n @State() currValue: string | string[] | null;\n @Watch(\"value\")\n valueChangedHandler(): void {\n if (this.value !== this.currValue) {\n if (this.value && this.multiple) {\n this.currValue = this.getMultipleOptionsString(this.value as string[])\n ? this.getValueSortedByOptions(this.value as string[])\n : null;\n this.updateMultiSelectedCountAriaLive();\n } else {\n this.currValue = this.getLabelFromValue(this.value as string)\n ? this.value\n : null;\n }\n }\n\n if (this.searchable && this.value) {\n // Only set if value not null - prevents whole input value being cleared when edited\n this.searchableSelectInputValue =\n this.getLabelFromValue(String(this.currValue)) || null;\n }\n }\n\n @Watch(\"open\")\n openChangedHandler(): void {\n this.open ? this.icOpen.emit() : this.icClose.emit();\n }\n\n /**\n * Emitted when the select loses focus.\n */\n @Event() icBlur: EventEmitter<void>;\n\n /**\n * Emitted when the value changes.\n */\n @Event() icChange: EventEmitter<IcMultiValueEventDetail>;\n\n /**\n * Emitted when the clear or clear all button is clicked.\n */\n @Event() icClear: EventEmitter<void>;\n\n /**\n * Emitted when the select options menu is closed.\n */\n @Event() icClose: EventEmitter<void>;\n\n /**\n * Emitted when the select gains focus.\n */\n @Event() icFocus: EventEmitter<void>;\n\n /**\n * Emitted when a keyboard input occurred.\n */\n @Event() icInput: EventEmitter<IcMultiValueEventDetail>;\n\n /**\n * Emitted when the select options menu is opened.\n */\n @Event() icOpen: EventEmitter<void>;\n\n /**\n * Emitted when an option is selected.\n * Selecting an option will also trigger an `icChange/onIcChange` due to the value being updated.\n */\n @Event() icOptionSelect: EventEmitter<IcOptionSelectEventDetail>;\n\n /**\n * Emitted when `multiple` is `true` and an option is deselected.\n */\n @Event() icOptionDeselect: EventEmitter<IcOptionSelectEventDetail>;\n\n /**\n * Emitted when the 'retry loading' button is clicked for a searchable variant.\n */\n @Event() icRetryLoad: EventEmitter<IcMultiValueEventDetail>;\n\n disconnectedCallback(): void {\n removeFormResetListener(this.el, this.handleFormReset);\n this.hostMutationObserver?.disconnect();\n }\n\n componentWillLoad(): void {\n const valueInOptions = this.multiple\n ? this.getMultipleOptionsString(this.value as string[])\n : this.getLabelFromValue(this.value as string);\n this.currValue = valueInOptions ? this.value : null;\n this.inheritedAttributes = inheritAttributes(this.el, MUTABLE_ATTRIBUTES);\n\n removeDisabledFalse(this.disabled, this.el);\n\n this.setOptionsValuesFromLabels();\n\n addFormResetListener(this.el, this.handleFormReset);\n\n if (!this.options.length) {\n this.initialOptionsEmpty = true;\n this.noOptions = [{ label: this.emptyOptionListText, value: \"\" }];\n this.uniqueOptions = this.noOptions;\n this.filteredOptions = this.noOptions;\n } else {\n this.setDefaultValue();\n this.uniqueOptions = this.deduplicateOptions(this.options);\n }\n }\n\n componentDidLoad(): void {\n onComponentRequiredPropUndefined(\n [{ prop: this.label, propName: \"label\" }],\n \"Select\"\n );\n\n if (this.loading) {\n this.triggerLoading();\n }\n\n if (this.searchable) {\n this.hiddenInputValue = this.currValue as string;\n }\n\n this.hostMutationObserver = new MutationObserver(this.hostMutationCallback);\n this.hostMutationObserver.observe(this.el, {\n attributes: true,\n childList: true,\n });\n }\n\n componentDidRender(): void {\n if (this.nativeSelectElement && !this.disabled) {\n this.setTextColor();\n }\n }\n\n /**\n * Sets focus on the input box.\n */\n @Method()\n async setFocus(): Promise<void> {\n if (this.nativeSelectElement) {\n this.nativeSelectElement.focus();\n } else if (this.customSelectElement) {\n this.customSelectElement.focus();\n } else if (this.searchableSelectElement) {\n this.searchableSelectElement.focus();\n }\n }\n\n // triggered when attributes of host element change\n private hostMutationCallback = (mutationList: MutationRecord[]) => {\n let forceComponentUpdate = false;\n mutationList.forEach(\n ({ attributeName, type, addedNodes, removedNodes }) => {\n if (attributeName) {\n const attribute = this.el.getAttribute(attributeName);\n if (attribute && MUTABLE_ATTRIBUTES.includes(attributeName)) {\n this.inheritedAttributes[attributeName] = attribute;\n forceComponentUpdate = true;\n }\n } else if (type === \"childList\") {\n forceComponentUpdate = checkSlotInChildMutations(\n addedNodes,\n removedNodes,\n \"icon\"\n );\n }\n }\n );\n if (forceComponentUpdate) {\n forceUpdate(this);\n }\n };\n\n private handleRetry = (ev: CustomEvent<IcMultiValueEventDetail>) => {\n if (ev.detail.keyPressed) this.searchableSelectElement?.focus();\n this.blurredBecauseButtonPressed = true;\n this.retryButtonClick = true;\n this.hasSetDefaultValue = true;\n this.icRetryLoad.emit({\n value: this.searchable\n ? this.searchableSelectInputValue\n : this.hiddenInputValue,\n });\n };\n\n private emitIcChange = (value: string | string[] | null) => {\n // If \"Select all\" button clicked, replace value with new value (array of all option values)\n if (this.multiple && !Array.isArray(value) && value !== null) {\n // Update selected options - adds / removes them, in order of option list\n // Create new array if value prop is undefined\n if (this.value) {\n let valueArray = (this.value as string[]).slice();\n\n if (this.value.includes(value)) {\n valueArray.splice(valueArray.indexOf(value), 1);\n } else {\n valueArray.push(value);\n valueArray = this.getValueSortedByOptions(valueArray);\n }\n\n this.value = valueArray.length === 0 ? null : valueArray;\n } else {\n this.value = [value];\n }\n } else {\n this.value = value;\n }\n\n this.icChange.emit({ value: this.multiple ? this.value : value });\n };\n\n private emitIcInput = (value: string) => {\n clearTimeout(this.debounceIcInput);\n this.debounceIcInput = window.setTimeout(\n () => this.icInput.emit({ value }),\n this.currDebounce\n );\n };\n\n private setOptions = () => {\n if (!this.hasTimedOut && this.options !== this.noOptions) {\n this.loading = false;\n clearTimeout(this.timeoutTimer);\n\n if (this.options.length > 0) {\n this.setOptionsValuesFromLabels();\n this.uniqueOptions = this.deduplicateOptions(this.options);\n } else {\n this.noOptions = [{ label: this.emptyOptionListText, value: \"\" }];\n this.uniqueOptions = this.noOptions;\n }\n\n this.filteredOptions = this.uniqueOptions;\n\n if (this.isExternalFiltering()) {\n // When searchable select\n this.noOptions = null;\n this.updateSearchableSelectResultAriaLive();\n this.setDefaultValue();\n } else if (this.initialOptionsEmpty) {\n this.setDefaultValue();\n this.initialOptionsEmpty = false;\n }\n } else if (!this.searchable) {\n this.options = this.noOptions || [];\n }\n };\n\n /**\n * Processes the provided array of IcMenuOptions, removing duplicates and reporting them with a console.warn\n * @param options array of IcMenuOptions\n * @returns a new options object, with all entries possessing a duplicate 'value' field removed\n */\n private deduplicateOptions = (options: IcMenuOption[]) => {\n const uniqueValues: string[] = [];\n const dedupedOptions: IcMenuOption[] = [];\n\n options.forEach((option) => {\n if (option.children) {\n //If an option has children, we will loop through them\n const dedupedChildren: IcMenuOption[] = [];\n option.children.forEach((child) => {\n if (uniqueValues.includes(child.value)) {\n console.warn(\n `ic-select with label ${this.label} was populated with duplicate option (value: ${child.value}) which has been removed.`\n );\n } else {\n uniqueValues.push(child.value);\n dedupedChildren.push(child);\n }\n });\n // construct a modified option, inserting the deduplicated children alongside the original information\n dedupedOptions.push({\n ...option,\n children: dedupedChildren,\n });\n } else {\n // If an option does not have children, assess to see if it's value has been included already\n if (uniqueValues.includes(option.value)) {\n console.warn(\n `ic-select with label ${this.label} was populated with duplicate option (value: ${option.value}) which has been removed.`\n );\n } else {\n uniqueValues.push(option.value);\n dedupedOptions.push(option);\n }\n }\n });\n return dedupedOptions;\n };\n\n /**\n * Loop through options array and for all options with no value, infer it from the label\n */\n private setOptionsValuesFromLabels = () => {\n if (this.options.length > 0) {\n this.options.map((option) => {\n if (!option.value) {\n option.value = option.label;\n }\n });\n }\n };\n\n private setUngroupedOptions = (event: CustomEvent) => {\n this.ungroupedOptions = event.detail.options;\n };\n\n private setTextColor = () => {\n if (this.nativeSelectElement) {\n this.nativeSelectElement.className =\n this.nativeSelectElement.selectedIndex === 0\n ? \"placeholder\"\n : \"select-option-selected\";\n }\n };\n\n private setMenuChange = (open: boolean) => {\n if (this.open !== open) {\n this.open = open;\n }\n };\n\n private getLabelFromValue = (value: string) =>\n getLabelFromValue(value, this.uniqueOptions);\n\n private getMultipleOptionsString = (selectedValues: string[]) =>\n selectedValues\n ?.map((value) => this.getLabelFromValue(value))\n .filter((label) => !!label)\n .join(\", \");\n\n private getFilteredChildMenuOptions = (\n option: IcMenuOption\n ): IcMenuOption => ({\n ...option,\n children:\n option.children &&\n getFilteredMenuOptions(\n option.children,\n this.searchable && !!this.includeDescriptionsInSearch,\n this.searchable\n ? this.searchableSelectInputValue || \"\"\n : this.pressedCharacters,\n this.searchable ? this.searchMatchPosition : \"start\"\n ),\n });\n\n // (For multi-select) get value array, i.e. selected option values, in order they appear in option list\n private getValueSortedByOptions = (value: string[]) => {\n const valueArray = value;\n const valuesFromAllOptions = this.ungroupedOptions.map(\n (option) => option.value\n );\n\n valueArray.sort(\n (a, b) =>\n valuesFromAllOptions.indexOf(a) - valuesFromAllOptions.indexOf(b)\n );\n\n return valueArray;\n };\n\n private handleNativeSelectChange = () => {\n if (this.nativeSelectElement) {\n this.icOptionSelect.emit({ value: this.nativeSelectElement.value });\n this.emitIcChange(this.nativeSelectElement.value);\n }\n this.setTextColor();\n };\n\n // Handle option select for when a custom input box and menu is rendered\n // (rather than native <select> - rendered when viewed on a mobile / tablet screen)\n private handleCustomSelectChange = (\n event: CustomEvent<IcOptionSelectEventDetail>\n ) => {\n const { value, label, optionId } = event.detail;\n\n if (label === this.emptyOptionListText) {\n this.searchableSelectElement?.focus();\n return;\n }\n\n if (this.searchable) {\n this.value = value || null;\n this.searchableMenuItemSelected = true;\n\n // After editing the input, if selecting the same option as before, set the input value to label again\n if (this.value === this.currValue) {\n this.searchableSelectInputValue =\n this.getLabelFromValue(this.value as string) || null;\n }\n\n this.inputValueToFilter = null;\n this.hiddenInputValue =\n this.getValueFromLabel(this.searchableSelectInputValue) || null;\n }\n\n if (value) {\n if (this.multiple && this.value?.includes(value)) {\n this.icOptionDeselect.emit({ value });\n } else {\n this.icOptionSelect.emit({ value });\n }\n }\n\n this.ariaActiveDescendant = optionId;\n this.emitIcChange(value || null);\n };\n\n private handleSelectAllChange = ({\n detail,\n }: CustomEvent<{ select: boolean }>) => {\n const allValues = this.ungroupedOptions\n .filter((option) => !option.disabled)\n .map((option) => option.value);\n\n if (detail.select) {\n // Only emit icOptionSelect for all values that are newly selected\n const unselectedValues = this.value\n ? allValues.filter(\n (value) => this.value && !(this.value as string[]).includes(value)\n )\n : allValues;\n\n unselectedValues.forEach((value) => this.icOptionSelect.emit({ value }));\n } else {\n // Only emit icOptionDeselect for values that were selected\n (this.value as string[]).forEach((value) =>\n this.icOptionDeselect.emit({ value })\n );\n }\n\n this.emitIcChange(detail.select ? allValues : null);\n };\n\n private handleMenuChange = (event: CustomEvent<IcMenuChangeEventDetail>) => {\n this.open = event.detail.open;\n this.pressedCharacters = \"\";\n\n if (this.searchable) this.handleFocusIndicatorDisplay();\n };\n\n // clears the debounce delay when navigating the menu with arrow keys etc\n // to prevent delay in change event, which should only occur when typing in input\n private handleMenuKeyPress = (ev: CustomEvent): void => {\n ev.cancelBubble = true;\n if (!this.multiple) {\n this.handleCharacterKeyDown(ev.detail.key);\n }\n };\n\n private handleFocusIndicatorDisplay = () => {\n const focusIndicator =\n this.el.shadowRoot?.querySelector(\".focus-indicator\");\n\n if (focusIndicator) {\n if (this.open) {\n focusIndicator.classList.add(\"focus-indicator-enabled\");\n } else {\n focusIndicator.classList.remove(\"focus-indicator-enabled\");\n }\n }\n };\n\n private handleMouseDown = (event: Event) => {\n if (!this.open) {\n event.preventDefault();\n }\n };\n\n private isExternalFiltering = () =>\n this.searchable && !!this.disableAutoFiltering;\n\n private handleClick = (event: MouseEvent) => {\n if (!this.open && this.menu) {\n if (this.isExternalFiltering()) {\n this.menu.options = this.filteredOptions;\n } else if (\n !this.hasTimedOut &&\n !this.loading &&\n !this.noOptions?.length &&\n (!this.searchable || this.searchableMenuItemSelected)\n ) {\n this.noOptions = null;\n this.menu.options = this.uniqueOptions;\n }\n }\n\n if (event.detail !== 0) {\n this.menu?.handleClickOpen();\n }\n };\n\n private handleExpandIconMouseDown = (event: MouseEvent) => {\n if (!this.disabled) {\n event.preventDefault();\n this.searchableSelectElement?.focus();\n this.handleClick(event);\n }\n };\n\n private handleClear = (event: Event) => {\n event.stopPropagation();\n this.hasTimedOut = false;\n clearTimeout(this.timeoutTimer);\n this.clearInput();\n this.emitIcChange(null);\n this.icClear.emit();\n\n if (this.searchable) {\n this.hiddenInputValue = null;\n this.searchableSelectElement?.focus();\n } else {\n this.customSelectElement?.focus();\n }\n };\n\n private handleCharacterKeyDown = (key: string) => {\n // Only close menu when space is pressed if not being used alongside character keys to quickly select options\n if (this.open && key === \" \" && this.pressedCharacters.length === 0) {\n this.setMenuChange(false);\n }\n\n if (key.length !== 1 || this.searchable) {\n this.pressedCharacters = \"\";\n return;\n }\n\n window.clearTimeout(this.characterKeyPressTimer);\n this.characterKeyPressTimer = window.setTimeout(\n () => (this.pressedCharacters = \"\"),\n 1000\n );\n\n if (key !== \" \" || !!this.pressedCharacters) {\n this.pressedCharacters += key;\n this.handleFilter();\n\n if (!this.noOptions) {\n this.emitIcChange(this.filteredOptions[0].value);\n }\n }\n };\n\n private handleNativeSelectKeyDown = (event: KeyboardEvent) => {\n if ((event.key !== \"Escape\" && event.key !== \"Tab\") || this.open) {\n event.cancelBubble = true;\n }\n this.handleCharacterKeyDown(event.key);\n };\n\n private handleKeyDown = (event: KeyboardEvent) => {\n if ((event.key !== \"Escape\" && event.key !== \"Tab\") || this.open) {\n event.cancelBubble = true;\n }\n const isArrowKey = event.key === \"ArrowDown\" || event.key === \"ArrowUp\";\n\n if (this.menu && !this.open) {\n if (this.isExternalFiltering() && (event.key === \"Enter\" || isArrowKey)) {\n this.menu.options = this.filteredOptions;\n } else if (!this.hasTimedOut) {\n this.noOptions = null;\n this.menu.options = this.uniqueOptions;\n }\n }\n\n if (this.open && event.key === \"Enter\") {\n this.setMenuChange(false);\n } else {\n if (!isArrowKey || this.noOptions === null) {\n if (event.key !== \" \" || this.pressedCharacters.length <= 0) {\n // Keyboard events get passed onto ic-menu\n this.menu?.handleKeyboardOpen(event);\n }\n if (!this.multiple) {\n this.handleCharacterKeyDown(event.key);\n }\n }\n }\n };\n\n private handleClearButtonFocus = () => {\n this.clearButtonFocused = true;\n };\n\n private handleClearButtonBlur = (ev: FocusEvent) => {\n const retryButton = this.menu?.querySelector(\"#retry-button\");\n if (\n (!this.searchableSelectElement ||\n ev.relatedTarget !== this.searchableSelectElement) &&\n (!retryButton || ev.relatedTarget !== retryButton)\n ) {\n this.setMenuChange(false);\n this.handleFocusIndicatorDisplay();\n }\n this.clearButtonFocused = false;\n };\n\n private handleFilter = () => {\n const options = this.deduplicateOptions(\n this.searchable ? [...this.uniqueOptions] : this.ungroupedOptions\n );\n\n const isGrouped = options.some((option) => !!option.children);\n let newFilteredOptions: IcMenuOption[] = [];\n\n let menuOptionsFiltered: IcMenuOption[];\n\n if (this.searchable) {\n menuOptionsFiltered = getFilteredMenuOptions(\n options,\n !!this.includeDescriptionsInSearch,\n this.inputValueToFilter || \"\",\n this.searchMatchPosition\n );\n this.searchableMenuItemSelected = false;\n } else {\n menuOptionsFiltered = getFilteredMenuOptions(\n options,\n false,\n this.pressedCharacters,\n \"start\"\n );\n }\n\n if (\n !isGrouped &&\n menuOptionsFiltered[0]?.label !== this.emptyOptionListText\n ) {\n newFilteredOptions = menuOptionsFiltered;\n } else if (isGrouped) {\n newFilteredOptions = options.map((option) =>\n this.includeGroupTitlesInSearch &&\n menuOptionsFiltered.indexOf(option) !== -1\n ? option\n : this.getFilteredChildMenuOptions(option)\n );\n }\n\n if (\n newFilteredOptions.length > 0 &&\n (!isGrouped ||\n newFilteredOptions.some(\n ({ children }) => children && children.length > 0\n ))\n ) {\n this.noOptions = null;\n this.filteredOptions = newFilteredOptions;\n } else {\n this.noOptions = [{ label: this.emptyOptionListText, value: \"\" }];\n this.filteredOptions = this.noOptions;\n }\n };\n\n /**\n * Put the select component into loading state.\n * Replace options with the loading message. If timeout is enabled, set the timeout and once passed, replace options with the loading error message\n */\n private triggerLoading = () => {\n this.hasTimedOut = false;\n this.noOptions = [{ label: this.loadingLabel, value: \"\", loading: true }];\n if (this.filteredOptions !== this.noOptions && this.searchable) {\n this.filteredOptions = this.noOptions;\n } else if (this.uniqueOptions !== this.noOptions && !this.searchable) {\n this.uniqueOptions = this.noOptions;\n }\n if (this.timeout) {\n this.timeoutTimer = window.setTimeout(() => {\n this.loading = false;\n this.hasTimedOut = true;\n this.noOptions = [\n { label: this.loadingErrorLabel, value: \"\", timedOut: true },\n ];\n this.filteredOptions = this.noOptions;\n if (!this.searchable) this.uniqueOptions = this.noOptions;\n }, this.timeout);\n }\n };\n\n private getValueFromLabel = (label: string | null): string | undefined =>\n label && this.uniqueOptions.find((option) => option.label === label)?.value;\n\n private handleSearchableSelectInput = (event: Event) => {\n this.searchableSelectInputValue = (event.target as HTMLInputElement).value;\n this.emitIcInput(this.searchableSelectInputValue);\n\n // De-select previous selection when input is edited\n // Only emit icChange once when editing input\n if (this.value != null) {\n this.emitIcChange(null);\n }\n\n this.hiddenInputValue = null;\n this.inputValueToFilter = this.searchableSelectInputValue;\n this.setMenuChange(true);\n\n if (!this.disableAutoFiltering) {\n this.handleFilter();\n clearTimeout(this.debounceAria);\n\n window.setTimeout(() => {\n this.updateSearchableSelectResultAriaLive();\n }, 800);\n }\n };\n\n private updateSearchableSelectResultAriaLive = () => {\n const searchableSelectResultsStatusEl =\n this.el.shadowRoot?.querySelector<HTMLDivElement>(\n \".searchable-select-results-status\"\n );\n\n if (searchableSelectResultsStatusEl) {\n searchableSelectResultsStatusEl.innerText =\n this.noOptions !== null ? this.emptyOptionListText : \"\";\n }\n };\n\n private updateMultiSelectedCountAriaLive = () => {\n const multiSelectSelectedCountEl =\n this.el.shadowRoot?.querySelector<HTMLDivElement>(\n \".multi-select-selected-count\"\n );\n\n const selectedCount = `${\n this.currValue?.length\n } of ${getOptionsWithoutGroupTitlesCount(this.options)} selected`;\n\n if (\n multiSelectSelectedCountEl &&\n multiSelectSelectedCountEl.innerText !== selectedCount\n ) {\n multiSelectSelectedCountEl.innerText = selectedCount;\n }\n };\n\n private getDefaultValue = (value: string) =>\n this.getLabelFromValue(value) || null;\n\n private setDefaultValue = () => {\n if (!this.hasSetDefaultValue && this.currValue) {\n this.searchableSelectInputValue = this.searchable\n ? this.getDefaultValue(this.currValue as string)\n : null;\n\n this.initialValue = this.currValue;\n this.hasSetDefaultValue = true;\n }\n };\n\n private onFocus = () => {\n this.icFocus.emit();\n };\n\n private onBlur = ({ relatedTarget }: FocusEvent) => {\n const target = relatedTarget as HTMLElement;\n if (\n target !== null &&\n ((target.tagName === \"UL\" && target.className.includes(\"menu\")) ||\n (target.tagName === \"LI\" && target.className.includes(\"option\")))\n ) {\n return;\n }\n\n const retryButton = this.menu?.querySelector(\"#retry-button\");\n\n if (\n this.searchable &&\n !!this.menu &&\n target !== this.menu &&\n !Array.from(this.menu.querySelectorAll(\"[role='option']\")).includes(\n target\n ) &&\n (!this.clearButton || target !== this.clearButton) &&\n (!retryButton || target !== retryButton)\n ) {\n if (!this.retryButtonClick) {\n this.setMenuChange(false);\n // Clear input field on blur when searchable if no option is selected\n if (!this.value) {\n this.clearInput();\n }\n }\n this.handleFocusIndicatorDisplay();\n }\n\n this.retryButtonClick = false;\n this.icBlur.emit();\n };\n\n private onTimeoutBlur = (ev: CustomEvent) => {\n if (\n (ev.detail.ev as FocusEvent).relatedTarget !==\n this.searchableSelectElement &&\n !this.blurredBecauseButtonPressed\n ) {\n this.setMenuChange(false);\n this.handleFocusIndicatorDisplay();\n this.icBlur.emit();\n }\n this.blurredBecauseButtonPressed = false;\n };\n\n private handleFormReset = () => {\n this.value = this.initialValue;\n if (this.searchable) {\n this.searchableSelectInputValue = this.getDefaultValue(\n this.value as string\n );\n this.hiddenInputValue = this.value as string;\n }\n };\n\n private clearInput = () => {\n this.noOptions = null;\n\n if (this.searchable) {\n this.searchableSelectElement?.setAttribute(\"value\", \"\");\n this.searchableSelectInputValue = null;\n this.filteredOptions = this.uniqueOptions;\n }\n };\n\n private renderNativeOption = (option: IcMenuOption) => (\n <option\n value={option.value}\n disabled={option.disabled}\n selected={option.value === this.currValue}\n >\n {option.label}\n </option>\n );\n\n render() {\n const {\n size,\n disabled,\n fullWidth,\n helperText,\n hideLabel,\n label,\n menuId,\n multiple,\n name,\n options,\n placeholder,\n readonly,\n required,\n searchable,\n showClearButton,\n validationStatus,\n validationText,\n currValue,\n theme,\n hiddenInputValue,\n open,\n inputId,\n searchableSelectInputValue,\n loading,\n value,\n emptyOptionListText,\n uniqueOptions,\n selectOnEnter,\n form,\n inheritedAttributes,\n ariaActiveDescendant,\n hasTimedOut,\n noOptions,\n filteredOptions,\n clearButtonFocused,\n } = this;\n\n // HTML inputs only accept 'string' for their value\n // Does not cause errors when it is a multi-select - sets value correctly, to a comma-separated string\n renderHiddenInput(\n this.el,\n searchable ? hiddenInputValue : (currValue as string),\n name || inputId,\n disabled\n );\n\n const invalid = `${validationStatus === IcInformationStatus.Error}`;\n\n const describedBy = getInputDescribedByText(\n this.el,\n inputId,\n helperText !== \"\",\n hasValidationStatus(validationStatus, !!disabled)\n ).trim();\n\n const valueLabelString = multiple\n ? this.getMultipleOptionsString(currValue as string[])\n : this.getLabelFromValue(currValue as string);\n\n const isClearable =\n !disabled &&\n (searchable\n ? !!searchableSelectInputValue\n : !!currValue && !loading && showClearButton);\n\n return (\n <Host\n class={{\n \"ic-select-disabled\": disabled,\n \"ic-select-searchable\": searchable,\n [`ic-select-${size}`]: size !== \"medium\",\n \"ic-select-full-width\": fullWidth,\n [`ic-theme-${theme}`]: theme !== \"inherit\",\n }}\n onBlur={this.onBlur}\n >\n <ic-input-container readonly={readonly}>\n {!hideLabel && (\n <ic-input-label\n for={inputId}\n label={label}\n helperText={helperText}\n required={required}\n disabled={disabled}\n readonly={readonly}\n >\n <slot name=\"helper-text\" slot=\"helper-text\"></slot>\n </ic-input-label>\n )}\n <ic-input-component-container\n ref={(el) => (this.anchorEl = el)}\n class={{ \"menu-open\": open }}\n size={size}\n fullWidth={fullWidth}\n disabled={disabled}\n readonly={readonly}\n validationStatus={validationStatus}\n >\n {isSlotUsed(this.el, \"icon\") &&\n !disabled &&\n (!readonly || !!value) && (\n <span\n slot=\"left-icon\"\n class={{\n readonly,\n \"has-value\": !!value,\n }}\n >\n <slot name=\"icon\" />\n </span>\n )}\n {readonly ? (\n <ic-typography>\n <p>{valueLabelString}</p>\n </ic-typography>\n ) : isMobileOrTablet() && !multiple ? (\n <select\n ref={(el) => (this.nativeSelectElement = el)}\n disabled={disabled}\n onChange={this.handleNativeSelectChange}\n required={required}\n id={inputId}\n aria-label={label}\n aria-describedby={describedBy}\n aria-invalid={invalid}\n onBlur={this.onBlur}\n onFocus={this.onFocus}\n onKeyDown={this.handleNativeSelectKeyDown}\n form={form}\n {...inheritedAttributes}\n >\n <option value=\"\" selected disabled={!showClearButton}>\n {placeholder}\n </option>\n {options.map((option) =>\n option.children ? (\n <optgroup label={option.label}>\n {option.children.map((child) =>\n this.renderNativeOption(child)\n )}\n </optgroup>\n ) : (\n this.renderNativeOption(option)\n )\n )}\n </select>\n ) : searchable ? (\n <div class=\"searchable-select-container\">\n <input\n class={{\n \"value-text\": true,\n \"select-input\": true,\n \"with-clear-button\": !!searchableSelectInputValue,\n }}\n role=\"combobox\"\n autocomplete=\"off\"\n aria-label={label}\n aria-describedby={describedBy}\n aria-activedescendant={ariaActiveDescendant}\n aria-autocomplete=\"list\"\n aria-expanded={`${open}`}\n aria-invalid={invalid}\n aria-required={`${required}`}\n aria-controls={menuId}\n ref={(el) => (this.searchableSelectElement = el)}\n id={inputId}\n value={searchableSelectInputValue || undefined}\n placeholder={placeholder}\n disabled={disabled}\n onInput={this.handleSearchableSelectInput}\n onClick={this.handleClick}\n onKeyDown={this.handleKeyDown}\n onFocus={this.onFocus}\n onBlur={this.onBlur}\n form={form}\n ></input>\n {isClearable && (\n <div class=\"clear-button-container\">\n <ic-button\n id=\"clear-button\"\n ref={(el) => (this.clearButton = el)}\n aria-label={\n searchableSelectInputValue &&\n (currValue === null || loading)\n ? \"Clear input\"\n : \"Clear selection\"\n }\n class=\"clear-button\"\n innerHTML={Clear}\n onClick={this.handleClear}\n onFocus={this.handleClearButtonFocus}\n onBlur={this.handleClearButtonBlur}\n size={size}\n variant=\"icon\"\n theme={clearButtonFocused ? \"light\" : \"dark\"}\n ></ic-button>\n <div class=\"divider\"></div>\n </div>\n )}\n <span\n onMouseDown={this.handleExpandIconMouseDown}\n class={{\n \"expand-icon\": true,\n \"expand-icon-open\": open,\n }}\n innerHTML={Expand}\n aria-hidden=\"true\"\n />\n <div\n aria-live=\"polite\"\n role=\"status\"\n class=\"searchable-select-results-status\"\n ></div>\n </div>\n ) : (\n <div class=\"select-container\">\n <button\n class=\"select-input\"\n ref={(el) => (this.customSelectElement = el)}\n id={inputId}\n aria-label={`${label}, ${\n (multiple && currValue\n ? `${\n currValue.length\n } of ${getOptionsWithoutGroupTitlesCount(\n options\n )} selected, ${valueLabelString}`\n : valueLabelString) || placeholder\n }${required ? \", required\" : \"\"}`}\n aria-describedby={describedBy}\n aria-invalid={invalid}\n aria-haspopup=\"listbox\"\n aria-expanded={`${open}`}\n aria-owns={menuId}\n aria-controls={menuId}\n disabled={disabled}\n onBlur={this.onBlur}\n onFocus={this.onFocus}\n onClick={this.handleClick}\n onMouseDown={this.handleMouseDown}\n onKeyDown={this.handleKeyDown}\n >\n <ic-typography\n variant=\"body\"\n class={{\n \"value-text\": true,\n \"with-clear-button\": isClearable,\n placeholder:\n !loading && multiple\n ? !value || value.length < 1\n : !this.getLabelFromValue(currValue as string),\n }}\n >\n {valueLabelString || placeholder}\n </ic-typography>\n <div class=\"select-input-end\">\n {isClearable && <div class=\"divider\"></div>}\n <span\n class={{\n \"expand-icon\": true,\n \"expand-icon-open\": open,\n }}\n innerHTML={Expand}\n aria-hidden=\"true\"\n />\n </div>\n </button>\n {isClearable && (\n <ic-button\n id=\"clear-button\"\n aria-label=\"Clear selection\"\n class=\"clear-button\"\n innerHTML={Clear}\n onClick={this.handleClear}\n onFocus={this.handleClearButtonFocus}\n onBlur={this.handleClearButtonBlur}\n size={size}\n variant=\"icon\"\n theme={clearButtonFocused ? \"light\" : \"dark\"}\n ></ic-button>\n )}\n </div>\n )}\n </ic-input-component-container>\n {(!isMobileOrTablet() || multiple) && (\n <ic-menu\n class={{\n \"no-results\":\n loading ||\n hasTimedOut ||\n noOptions?.[0]?.label === emptyOptionListText,\n }}\n ref={(el) => (this.menu = el)}\n inputEl={\n searchable\n ? this.searchableSelectElement\n : this.customSelectElement\n }\n inputLabel={label}\n anchorEl={this.anchorEl}\n size={size}\n menuId={menuId}\n open={open}\n options={searchable ? filteredOptions : uniqueOptions}\n value={multiple ? (currValue as string[]) : (currValue as string)}\n fullWidth={fullWidth}\n selectOnEnter={selectOnEnter}\n onMenuStateChange={this.handleMenuChange}\n onMenuOptionSelect={this.handleCustomSelectChange}\n onMenuOptionSelectAll={this.handleSelectAllChange}\n onMenuKeyPress={this.handleMenuKeyPress}\n onUngroupedOptionsSet={this.setUngroupedOptions}\n onRetryButtonClicked={this.handleRetry}\n parentEl={this.el}\n onTimeoutBlur={this.onTimeoutBlur}\n activationType={\n searchable || multiple || selectOnEnter ? \"manual\" : \"automatic\"\n }\n closeOnSelect={!multiple}\n multiSelect={multiple ? true : false}\n searchableSelect={searchable ? true : false}\n ></ic-menu>\n )}\n {multiple && (\n <div\n aria-live=\"polite\"\n role=\"status\"\n class=\"multi-select-selected-count\"\n ></div>\n )}\n {hasValidationStatus(validationStatus, disabled) && (\n <ic-input-validation\n class={{ \"menu-open\": open }}\n ariaLiveMode=\"polite\"\n status={validationStatus}\n message={validationText}\n for={inputId}\n ></ic-input-validation>\n )}\n </ic-input-container>\n </Host>\n );\n }\n}\n"],"mappings":"4rBAAA,MAAMA,EAAc,6qRACpB,MAAAC,EAAeD,EC8Cf,IAAIE,EAAW,EACf,MAAMC,EAAqB,IAAIC,EAAmB,WAAY,S,MAajDC,EAAM,MAPnB,WAAAC,CAAAC,G,0XASUC,KAAAC,4BAA8B,MAK9BD,KAAAE,mBAAqB,MACrBF,KAAAG,YAAc,MACdH,KAAAI,oBAA+C,GAC/CJ,KAAAK,oBAAsB,MACtBL,KAAAM,QAAU,mBAAmBZ,MAE7BM,KAAAO,OAAS,GAAGP,KAAKM,eAEjBN,KAAAQ,iBAAmB,MACnBR,KAAAS,2BAA6B,MAG7BT,KAAAU,iBAAmC,GACnCV,KAAAW,qBAAgD,KAK/CX,KAAAY,mBAAqB,MAGrBZ,KAAAa,UAAmC,KACnCb,KAAAc,KAAO,MACPd,KAAAe,kBAAoB,GACpBf,KAAAgB,2BAA4C,KAK5BhB,KAAAiB,SAAW,MAS5BjB,KAAAkB,qBAAuB,MAKv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