PageSourceSearch

https://cada-edu.com/hubfs/hub_generated/template_assets/1/84761857981/1790862082191/template_LinkNav.min.js

js cada-edu.com collected 2026-10-02 19:11:28 UTC 3,063 bytes, 2 lines download raw bytes

1!function(e,t){"function"==typeof define&&define.amd?define(["exports"],t):"undefined"!=typeof exports?t(exports):(t(t={}),e.LinkNav=t)}("undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:this,function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,e.default={template:'<div :class="classes" @focusout="handleFocusOut" @keydown="handleKeydown" > <button class="link-nav__toggle" @click="handleToggleClick" :aria-controls="id" aria-haspopup="true" :aria-pressed="active" :aria-describedby="labelId" ref="toggle" > <template> {{ label }} <span v-html="dropdownIcon"></span></template> </button> <ul class="link-nav__options" ref="options" :class="classes" @focusout="handleFocusOut" @keydown="handleKeydown"> <li v-for="option, index in mappedOptions" :key="index"> <button @click="handleOptionClick(option)" :class="option.class"> {{ option.name }} <span class="screen-reader-text" v-if="option.screenReader">({{ option.screenReader }})</span> </button> </li> </ul> </div>',props:{id:{type:String,required:!0},name:{type:String},labelId:{type:String},label:{type:String,required:!0},dropdownIcon:{type:String},options:{type:Array},value:{type:[Object,Array,null]},strings:{type:Object,default:()=>({view_all:"View All"})}},data:()=>({active:!1}),watch:{active(e){e&&Vue.nextTick(()=>{window.themeUtility.getFocusable(this.$refs.options)[0]?.focus()})}},computed:{mappedOptions(){return[{name:this.strings.view_all,value:null,screenReader:this.label,class:{button:!0,"button--horizontal-tabs":!0}},...this.options.map((e,t)=>({...e,value:e,id:this.id+"-"+t,class:{active:this.value&&e.name===(this.value.name||this.value[0].name),button:!0,"button--horizontal-tabs":!0}}))]},selectedValueLabel(){return this.value?[this.value].map(e=>e.name).join(", "):""},classes(){return{"link-nav":!0,"link-nav--active":this.active}}},methods:{valuesEqual:(e,n)=>e===n||!(null===e&&null!==n||null!==e&&null===n)&&e.length===n.length&&e.filter(t=>n.find(e=>t.id===e.id)).length===e.length,handleToggleClick(){this.active=!this.active},handleFocusOut(){requestAnimationFrame(()=>{!document.activeElement||this.$el===document.activeElement||this.$el.contains(document.activeElement)||document.activeElement.contains(this.$el)||(this.active=!1)})},handleClickOutside(e){this.$el.contains(e.target)||(this.active=!1)},handleOptionClick(e){this.$emit("input",e.value),this.active=!1},handleKeydown(t){if(this.active)switch(t.code){case"ArrowDown":case"ArrowUp":t.preventDefault();var n=this.$refs.options.querySelectorAll("button, input");let e=[...n].indexOf(document.activeElement)+("ArrowUp"===t.code?-1:1);return void n[e=(e=e<0?n.length-1:e)>n.length-1?0:e].focus();case"Escape":return this.active=!1,void this.$refs.toggle.focus()}}},mounted(){window.addEventListener("click",this.handleClickOutside)},destroyed(){window.removeEventListener("click",this.handleClickOutside)}}});
2//# sourceURL=https://143285883.fs1.hubspotusercontent-eu1.net/hubfs/143285883/hub_generated/template_assets/1/84761857981/1790862082191/template_LinkNav.js

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.