{"version":3,"names":["kdxDropdownListCss","DropdownList","constructor","hostRef","this","guid","Math","random","toString","slice","selectOptions","updateActiveIndex","bind","activeIndexUpdatedHandler","event","detail","elem","selectId","val","length","currVal","value","el","document","getElementById","selectedIndex","dispatchEvent","window","Event","bubbles","activeItemIndex","parseInt","target","getAttribute","root","querySelector","innerText","closeDropdown","activeIndexUpdated","emit","handleClick","preventDefault","targetElem","closest","classList","toggle","dropdownBoxHeight","clientHeight","menuElem","rect","getBoundingClientRect","innerHeight","top","height","style","marginTop","contains","remove","redirectOptionLink","optionIndex","startsWith","location","href","origin","getQueriesLink","newParams","newSearchParams","URLSearchParams","urlSearchParams","search","k","v","has","set","append","split","componentWillLoad","addEventListener","querySelectorAll","selectedOption","reverse","find","option","selected","indexOf","componentDidLoad","dropdownText","innerHTML","label","componentDidRender","containsLinks","Array","from","forEach","link","index","setAttribute","render","h","Host","labelText","class","htmlFor","classes","id","name","selectName","autocomplete","required","isRequired","onChange","selectUpdated","icon","selectIcon","tabindex","onClick","map","hidden","disabled","title"],"sources":["./src/components/forms/partials/kdx-dropdown-list/kdx-dropdown-list.scss?tag=kdx-dropdown-list","./src/components/forms/partials/kdx-dropdown-list/kdx-dropdown-list.tsx"],"sourcesContent":["kdx-dropdown-list {\r\n display: flex;\r\n position: relative;\r\n\r\n //Wrapper for the custom select\r\n .kdx-dropdown-list {\r\n position: absolute;\r\n top: calc(50%);\r\n left: 0;\r\n right: 0;\r\n transform: translateY(-50%);\r\n display: none; // hide by default, mouse check will display\r\n\r\n &.show { \r\n z-index: 1;\r\n }\r\n }\r\n\r\n //Styles for both the native select and custom select\r\n .dropdown-select {\r\n background-color: white;\r\n border: none;\r\n border-radius: 5px;\r\n color: black;\r\n box-shadow: 0px 3px 6px rgba(0, 0, 0, 0.16);\r\n display: inline-flex;\r\n height: 100%;\r\n max-height: 2.75rem;\r\n min-width: 7.5rem;\r\n padding-block: 0.5rem;\r\n padding-inline: 1rem 5.5rem;\r\n position: relative;\r\n text-align: left;\r\n text-decoration: none;\r\n width: 100%;\r\n font-weight: 700;\r\n\r\n //Hide native select arrow\r\n -webkit-appearance: none;\r\n -moz-appearance: none;\r\n appearance: none;\r\n \r\n overflow: hidden;\r\n text-overflow: ellipsis;\r\n white-space: nowrap;\r\n\r\n\r\n option {\r\n //Customize native option styles\r\n width: 100%;\r\n }\r\n\r\n &:hover, &:focus {\r\n color: currentColor;\r\n }\r\n\r\n //Icon sizing for the native select and custom select\r\n + .svg-icon, .svg-icon {\r\n svg {\r\n @include svg-format(12px, 12px, $secondary);\r\n // color: currentColor;\r\n // max-height: 0.75rem;\r\n // max-width: 0.75rem;\r\n // min-width: 0.75rem;\r\n // width: 100%;\r\n @include svg-format(14px, 16px, $primary);\r\n transform: rotate(0);\r\n transition: transform ease-in-out 0.125s;\r\n }\r\n }\r\n\r\n //Spacing adjustments for the native select icon\r\n + .svg-icon {\r\n position: absolute;\r\n top: calc(0.375rem + 1px);\r\n right: calc(1rem + 1px);\r\n }\r\n\r\n //Spacing adjustments for the custom select icon\r\n .svg-icon {\r\n position: absolute;\r\n margin-top: -1px;\r\n right: 1rem;\r\n\r\n &:is(button) {\r\n background-color: transparent;\r\n border: none;\r\n padding: 0;\r\n }\r\n }\r\n }\r\n\r\n //The options list for the custom select\r\n .dropdownmenu {\r\n background-color: white;\r\n border: none;\r\n border-bottom-left-radius: 5px;\r\n border-bottom-right-radius: 5px;\r\n box-shadow: 0px 3px 6px rgba(0, 0, 0, 0.16); \r\n display: none;\r\n max-height: 40vh;\r\n max-width: 100%;\r\n overflow-y: auto;\r\n padding: 0.625rem 0;\r\n position: absolute;\r\n top: 100%;\r\n width: 100%;\r\n\r\n &.show {\r\n display: block;\r\n }\r\n\r\n .dropdown-item {\r\n cursor: default;\r\n overflow: hidden;\r\n padding-block: calc(0.375rem - 1px) 0.375rem;\r\n padding-inline: 1rem;\r\n white-space: normal;\r\n text-overflow: ellipsis;\r\n \r\n &.hidden {\r\n display: none;\r\n }\r\n \r\n &:hover,\r\n &:focus {\r\n background-color: #EDEDED;\r\n color: $quinary;\r\n }\r\n }\r\n }\r\n\r\n //The placeholder in the custom select\r\n .dropdown-text {\r\n color: currentColor;\r\n font-weight: 700;\r\n }\r\n\r\n &.homepage-pageselector {\r\n\r\n .kdx-dropdown-list { \r\n border-bottom: 1px solid #000000;\r\n \r\n .dropdown-select {\r\n .svg-icon {\r\n right: 0.5rem;\r\n }\r\n }\r\n }\r\n\r\n .dropdown-select {\r\n box-shadow: none;\r\n max-width: 100%;\r\n padding-inline: 0;\r\n padding-block: 0;\r\n border-radius: 0;\r\n border: none;\r\n border-bottom: 1px solid #000000;\r\n\r\n +.svg-icon { \r\n right: 0; \r\n top: 0;\r\n }\r\n\r\n .dropdown-item {\r\n width: 100%;\r\n }\r\n }\r\n\r\n @include media-breakpoint-down(md) {\r\n .dropdown-select {\r\n padding-block: 0;\r\n border-bottom: 1px solid #000000;\r\n }\r\n }\r\n }\r\n}\r\n\r\n/* Styles for mouse/stylus users only */\r\n@media (hover: hover) {\r\n kdx-dropdown-list {\r\n .kdx-dropdown-list {\r\n display: block;\r\n }\r\n \r\n /* Show native select if keyboard controls */\r\n select:focus ~ .kdx-dropdown-list {\r\n display: none;\r\n }\r\n }\r\n}\r\n\r\n@include media-breakpoint-down(lg) {\r\n kdx-dropdown-list {\r\n .dropdown-select {\r\n max-width: 100%;\r\n }\r\n }\r\n} ","import { Component, h, Prop, Element, Event, EventEmitter, Host, Listen } from '@stencil/core';\r\n\r\n@Component({\r\n\ttag: 'kdx-dropdown-list',\r\n\tstyleUrl: 'kdx-dropdown-list.scss',\r\n\tshadow: false\r\n})\r\nexport class DropdownList {\r\n\r\n\t/**\r\n * Bind 'this' to updateActiveIndex\r\n */\r\n\tconstructor() {\r\n\t\tthis.updateActiveIndex = this.updateActiveIndex.bind(this);\r\n\t}\r\n\r\n\t@Element() root: HTMLElement;\r\n\r\n\t/**\r\n\t * If true, the dropdown is a required component of the form\r\n\t */\r\n\t@Prop() isRequired: boolean = false;\r\n\t/**\r\n\t * The current value of the select tag\r\n\t */\r\n\t@Prop({\r\n\t\tmutable: true,\r\n\t\treflect: true\r\n\t}) activeItemIndex: number = 0;\r\n\t/**\r\n\t * Additional css classes\r\n\t */\r\n\t@Prop() classes?: string;\r\n\t/**\r\n\t * If true, the dropdown items become anchor tags\r\n\t */\r\n\t@Prop() containsLinks: boolean;\r\n\t/**\r\n\t * Placeholder text for custom select\r\n\t */\r\n\t@Prop() dropdownText: string;\r\n\t/**\r\n\t * The ID of the select tag\r\n\t */\r\n\t@Prop({\r\n\t\tmutable: true,\r\n\t\treflect: true\r\n\t}) selectId: string;\r\n\t/**\r\n\t * The name attribute of the select tag\r\n\t */\r\n\t@Prop() selectName: string;\r\n\t/**\r\n\t * The dropdown icon\r\n\t */\r\n\t@Prop() selectIcon: string = \"chevron-down\";\r\n\t\r\n\t@Prop() labelText?: string;\r\n\t \r\n\t/**\r\n\t * Generated GUID for toggling custom dropdown\r\n\t */\r\n\tguid: string = Math.random().toString(36).slice(2);\r\n\t/**\r\n\t * Select options list\r\n\t */\r\n\tselectOptions: Array = [];\r\n\r\n\t// Used to share the selected value between other components\r\n\t@Event() selectUpdated: EventEmitter;\r\n\r\n\t// Get the active index from the custom select and update the native select value\r\n\t@Event() activeIndexUpdated: EventEmitter;\t\r\n\t@Listen('activeIndexUpdated', {target: 'document'})\r\n\tactiveIndexUpdatedHandler(event: CustomEvent<{elem: string, val: number}>) {\r\n\t if(event.detail.elem == this.selectId && event.detail.val >= 0 && this.selectOptions.length >= event.detail.val + 1) {\r\n\t\t const currVal = this.selectOptions[event.detail.val].value;\r\n\t\t const el = (document.getElementById(this.selectId) as HTMLSelectElement);\r\n\t\t el.value = currVal;\r\n\t\t el.selectedIndex = event.detail.val;\r\n\t\t el.dispatchEvent(new window.Event('change', { bubbles: true }));\r\n\t }\r\n\t}\r\n\r\n\t/**\r\n * Get the custom select option chosen, update the display value, and trigger the index updated event\r\n */\r\n\tupdateActiveIndex(event: Event) {\r\n\t\tthis.activeItemIndex = parseInt((event.target as HTMLElement).getAttribute('item-index') || '0');\r\n\t\t(this.root.querySelector('.kdx-dropdown-list > .dropdown-select > .dropdown-text') as HTMLElement).innerText = ((event.target as HTMLElement)).innerText;\r\n\t\tthis.closeDropdown();\r\n\t\tthis.activeIndexUpdated.emit({elem: this.selectId, val: this.activeItemIndex});\r\n\t}\r\n\r\n\t/**\r\n * Toggles the custom select dropdown visibility\r\n\t * \r\n\t * @param event - onClick event\r\n */\r\n\thandleClick(event: Event) {\r\n\t\tevent.preventDefault();\r\n\t\tconst targetElem = event.target as HTMLElement;\r\n\r\n\t\t(targetElem.closest('.kdx-dropdown-list') as HTMLElement).classList.toggle('show');\r\n\t\tconst dropdownBoxHeight = (targetElem.closest('.kdx-dropdown-list') as HTMLElement).clientHeight\r\n\t\tconst menuElem = (targetElem.closest('.kdx-dropdown-list') as HTMLElement).querySelector('.dropdownmenu');\r\n\t\tmenuElem!.classList.toggle('show');\r\n\t\tconst rect = menuElem!.getBoundingClientRect();\r\n\t\t//set margin to negative value to move menu up\r\n\t\tif ((window.innerHeight - rect.top) < rect.height && rect.height < rect.top)\r\n\t\t\t(menuElem as any).style.marginTop = \"-\" + (rect.height + dropdownBoxHeight).toString() + \"px\";\r\n\r\n\t\t//when closing dropdownmenu, remove top margin\r\n\t\tif (!menuElem?.classList.contains('show'))\r\n\t\t\t(menuElem as any).style.marginTop = \"0\";\r\n\t}\r\n\r\n\t/**\r\n\t * Closes the custom select dropdown menu\r\n\t *\r\n\t * @remarks\r\n\t * Used to manually close list\r\n\t */\r\n\tcloseDropdown() {\r\n\t\t(this.root.querySelector('.kdx-dropdown-list') as HTMLElement).classList.remove('show');\r\n\t\t(this.root.querySelector('.kdx-dropdown-list > .dropdownmenu') as HTMLElement).classList.remove('show');\r\n\t}\r\n\r\n\t/**\r\n * Builds a URL based on value of the selected option and then does a redirect\r\n\t * simulating a \"click browser link\" experience.\r\n\t * \r\n\t * @remarks\r\n\t * Used alongside the 'containsLinks' prop\r\n\t * \r\n\t * @param optionIndex - The currently selected value of the native select\r\n */\r\n\tredirectOptionLink(optionIndex: HTMLOptionElement) {\r\n\t\tif(optionIndex && optionIndex.value.startsWith(\"http\")) {\r\n\t\t\twindow.location.href = optionIndex.value;\r\n\t\t}\r\n\t\telse if (optionIndex && optionIndex.value.startsWith(\"/\")) {\r\n\t\t\twindow.location.href = window.location.origin + optionIndex.value;\r\n\t\t}\r\n\t\telse {\r\n\t\t\twindow.location.href = this.getQueriesLink(optionIndex.value);\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Generates URL by comparing new query values with old ones, replacing/adding as neccessary\r\n\t * \r\n\t * @remarks\r\n\t * Used alongside 'containsLinks' prop. Called by redirectOptionLink() and render() when rendering anchor tags\r\n\t * \r\n\t * @param newParams - The query string\r\n\t * \r\n\t * @returns\r\n\t * The newly generated URL\r\n\t */\r\n\tgetQueriesLink(newParams) {\r\n\t\tconst newSearchParams = new URLSearchParams(newParams);\r\n\t\tconst urlSearchParams = new URLSearchParams(window.location.search);\r\n\r\n\t\tfor (const[k, v] of newSearchParams) {\r\n\t\t\tif(urlSearchParams.has(k))\r\n\t\t\t\turlSearchParams.set(k, v);\r\n\t\t\telse\r\n\t\t\t\turlSearchParams.append(k, v);\r\n\t\t}\r\n\t\t\r\n\t\treturn window.location.href.split('?')[0] + '?' + urlSearchParams.toString();\r\n\t}\r\n\r\n\tcomponentWillLoad() {\r\n\t\t// Create unique ID\r\n\t\tthis.selectId = (!this.selectId) ? \"kdx-dropdown-list-\" + this.guid : this.selectId;\r\n\t\t// Add click listener for expanding the custom dropdown\r\n\t\tdocument.addEventListener('click', (event) => {\r\n\t\t\tif (this.root.querySelector('.kdx-dropdown-list.show') && ! (this.root.querySelector('.kdx-dropdown-list.show')?.contains(event.target as HTMLElement)) ) {\r\n\t\t\t\tthis.closeDropdown();\r\n\t\t\t};\r\n\t\t});\r\n\t\t\r\n\t\t// Get the options list\r\n\t\tthis.selectOptions = [...this.root.querySelectorAll(':scope > option')];\r\n\t\t// Get the last selected option, falling back to the first one\r\n\t\tconst selectedOption: HTMLOptionElement | undefined = [...this.selectOptions].reverse().find(option => option.selected) ?? this.selectOptions[0];\r\n\t\tthis.activeItemIndex = this.selectOptions.indexOf(selectedOption);\r\n\t}\r\n\r\n\tcomponentDidLoad() {\r\n\t\r\n\t\tthis.root.querySelector('select').selectedIndex = this.activeItemIndex;\r\n\t\t// Get placeholder text if no prop was provided\r\n\t\tif(!this.dropdownText) {\r\n\t\t\t(this.root.querySelector('.kdx-dropdown-list > .dropdown-select > .dropdown-text') as HTMLElement).innerHTML = \r\n\t\t\t\t(this.selectOptions.length >= this.activeItemIndex + 1) ? this.selectOptions[this.activeItemIndex].label : this.selectOptions[0].label;\r\n\t\t}\r\n\t\t// If both dropdownText and activeItemIndex are provided, activeItemIndex takes priority \r\n\t\telse if (this.dropdownText && this.activeItemIndex > 0) {\r\n\t\t\t(this.root.querySelector('.kdx-dropdown-list > .dropdown-select > .dropdown-text') as HTMLElement).innerText = \r\n (this.selectOptions.length >= this.activeItemIndex + 1) ? this.selectOptions[this.activeItemIndex].label : this.dropdownText;\r\n\t\t}\r\n\t\t\r\n\t}\r\n\r\n\tcomponentDidRender() {\r\n\t\t// Add event listener for clicking custom dropdown options\r\n\t\tif (!this.containsLinks) {\r\n\t\t\tArray.from(this.root.querySelectorAll('.kdx-dropdown-list > .dropdownmenu > .dropdown-item')).forEach((link, index) => {\r\n\t\t\t\tlink.setAttribute('item-index', `${index}`);\r\n\t\t\t\tlink.addEventListener('click', this.updateActiveIndex);\r\n\t\t\t});\r\n\t\t}\r\n\t}\r\n\r\n\trender() {\r\n\t\treturn (\r\n\t\t\t\r\n\t\t\t\t{this.labelText ?\r\n\t\t\t\t\t \r\n\t\t\t\t: \"\"}\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t
\r\n\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t{this.dropdownText}\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\r\n\r\n\t\t\t\t\t
\r\n\t\t\t\t\t\t{this.containsLinks ? \r\n\t\t\t\t\t\t\tthis.selectOptions.map((option) => {\r\n\t\t\t\t\t\t\t\tif (!option.getAttribute(\"value\"))\r\n\t\t\t\t\t\t\t\t\toption.value = \"\";\r\n\t\t\t\t\t\t\t\treturn \r\n\t\t\t\t\t\t\t\t\t\t {option.label}\r\n\t\t\t\t\t\t\t\t\t \r\n\t\t\t\t\t\t\t}) \r\n\t\t\t\t\t\t\t:\r\n\t\t\t\t\t\t\tthis.selectOptions.map((option) => {\r\n\t\t\t\t\t\t\t\tif (!option.getAttribute(\"value\"))\r\n\t\t\t\t\t\t\t\t\toption.value = \"\";\r\n\t\t\t\t\t\t\t\treturn
\r\n\t\t\t\t\t\t\t\t\t\t\t{option.label}\r\n\t\t\t\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t})\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t
\r\n\t\t\t\t
\r\n\t\t\t
\r\n\t\t);\r\n\t}\r\n}\r\n"],"mappings":"gEAAA,MAAMA,EAAqB,mzK,MCOdC,EAAY,MAKxBC,YAAAC,G,8GAkDAC,KAAAC,KAAeC,KAAKC,SAASC,SAAS,IAAIC,MAAM,GAIhDL,KAAAM,cAA0C,G,gBA7CZ,M,qBAOD,E,kJA2BA,e,yBA1C5BN,KAAKO,kBAAoBP,KAAKO,kBAAkBC,KAAKR,K,CA6DtDS,0BAA0BC,GACxB,GAAGA,EAAMC,OAAOC,MAAQZ,KAAKa,UAAYH,EAAMC,OAAOG,KAAO,GAAKd,KAAKM,cAAcS,QAAUL,EAAMC,OAAOG,IAAM,EAAG,CACpH,MAAME,EAAUhB,KAAKM,cAAcI,EAAMC,OAAOG,KAAKG,MACrD,MAAMC,EAAMC,SAASC,eAAepB,KAAKa,UACzCK,EAAGD,MAAQD,EACX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