PageSourceSearch

https://mabainaghareeb.com/cdn/shop/t/3/assets/variant-picker.js?v=66761027898496351631780572221

js mabainaghareeb.com collected 2026-10-02 16:03:55 UTC 1,987 bytes, 2 lines download raw bytes

1if(!customElements.get("variant-picker")){class VariantPicker extends HTMLElement{constructor(){super()}get selectedOptionValues(){const options=this.querySelectorAll(".m-product-option select, .m-product-option input"),selectedValues=new Map;options.forEach(field=>{const fieldName=field.name||field.dataset.fieldName;if(field.tagName.toLowerCase()==="select"){const selectedOption=Array.from(field.options).find(opt=>opt.selected&&!opt.disabled);selectedOption&&selectedValues.set(fieldName,selectedOption.dataset.optionValueId)}else if(field.tagName.toLowerCase()==="input"&&field.type==="radio"){const checkedInput=field.checked?field:null;checkedInput&&selectedValues.set(fieldName,checkedInput.dataset.optionValueId)}}),options.forEach(field=>{const fieldName=field.name||field.dataset.fieldName;if(!selectedValues.has(fieldName)){if(field.tagName.toLowerCase()==="select"){const firstValidOption=Array.from(field.options).find(opt=>!opt.disabled);firstValidOption&&selectedValues.set(fieldName,firstValidOption.dataset.optionValueId)}else if(field.tagName.toLowerCase()==="input"&&field.type==="radio"){const firstInput=field;firstInput&&selectedValues.set(fieldName,firstInput.dataset.optionValueId)}}});const result=[];return options.forEach(field=>{const fieldName=field.name||field.dataset.fieldName;if(selectedValues.has(fieldName)){const optionValueId=selectedValues.get(fieldName);optionValueId&&!result.includes(optionValueId)&&result.push(optionValueId)}}),result}connectedCallback(){this.addEventListener("change",event=>{const target=this.getInputForEventTarget(event.target);MinimogEvents.emit(MinimogTheme.pubSubEvents.optionValueSelectionChange,{data:{selectedOptionValues:this.selectedOptionValues,event,target}})})}getInputForEventTarget(target){return target.tagName==="SELECT"?target.selectedOptions[0]:target}}customElements.define("variant-picker",VariantPicker)}
2//# sourceMappingURL=/cdn/shop/t/3/assets/variant-picker.js.map?v=66761027898496351631780572221

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.