{
  "version": 3,
  "sources": ["/cdn/shop/t/27/assets/custom-select.js?enable_js_minification=1"],
  "sourcesContent": ["var x, i, j, l, ll, selElmnt, a, b, c;\n/* Look for any elements with the class \"custom-select\": */\nx = document.getElementsByClassName(\"custom-select\");\nl = x.length;\nfor (i = 0; i < l; i++) {\n  selElmnt = x[i].getElementsByTagName(\"select\")[0];\n  ll = selElmnt.length;\n  /* For each element, create a new DIV that will act as the selected item: */\n  a = document.createElement(\"DIV\");\n  a.setAttribute(\"class\", \"select-selected\");\n  a.innerHTML = selElmnt.options[selElmnt.selectedIndex].innerHTML;\n  x[i].appendChild(a);\n  /* For each element, create a new DIV that will contain the option list: */\n  b = document.createElement(\"DIV\");\n  b.setAttribute(\"class\", \"select-items select-hide\");\n  for (j = 1; j < ll; j++) {\n    /* For each option in the original select element,\n    create a new DIV that will act as an option item: */\n    c = document.createElement(\"DIV\");\n    c.innerHTML = selElmnt.options[j].innerHTML;\n    c.addEventListener(\"click\", function(e) {\n        /* When an item is clicked, update the original select box,\n        and the selected item: */\n        var y, i, k, s, h, sl, yl;\n        s = this.parentNode.parentNode.getElementsByTagName(\"select\")[0];\n        sl = s.length;\n        h = this.parentNode.previousSibling;\n        for (i = 0; i < sl; i++) {\n          if (s.options[i].innerHTML == this.innerHTML) {\n            s.selectedIndex = i;\n            h.innerHTML = this.innerHTML;\n            y = this.parentNode.getElementsByClassName(\"same-as-selected\");\n            yl = y.length;\n            for (k = 0; k < yl; k++) {\n              y[k].removeAttribute(\"class\");\n            }\n            this.setAttribute(\"class\", \"same-as-selected\");\n            break;\n          }\n        }\n        h.click();\n    });\n    b.appendChild(c);\n  }\n  x[i].appendChild(b);\n  a.addEventListener(\"click\", function(e) {\n    /* When the select box is clicked, close any other select boxes,\n    and open/close the current select box: */\n    e.stopPropagation();\n    closeAllSelect(this);\n    this.nextSibling.classList.toggle(\"select-hide\");\n    this.classList.toggle(\"select-arrow-active\");\n  });\n}\n\nfunction closeAllSelect(elmnt) {\n  /* A function that will close all select boxes in the document,\n  except the current select box: */\n  var x, y, i, xl, yl, arrNo = [];\n  x = document.getElementsByClassName(\"select-items\");\n  y = document.getElementsByClassName(\"select-selected\");\n  xl = x.length;\n  yl = y.length;\n  for (i = 0; i < yl; i++) {\n    if (elmnt == y[i]) {\n      arrNo.push(i)\n    } else {\n      y[i].classList.remove(\"select-arrow-active\");\n    }\n  }\n  for (i = 0; i < xl; i++) {\n    if (arrNo.indexOf(i)) {\n      x[i].classList.add(\"select-hide\");\n    }\n  }\n}\n\n/* If the user clicks anywhere outside the select box,\nthen close all select boxes: */\ndocument.addEventListener(\"click\", closeAllSelect); "],
  "mappings": "AAAA,IAAI,EAAG,EAAG,EAAG,EAAG,GAAI,SAAU,EAAG,EAAG,EAIpC,IAFA,EAAI,SAAS,uBAAuB,eAAe,EACnD,EAAI,EAAE,OACD,EAAI,EAAG,EAAI,EAAG,IAAK,CAWtB,IAVA,SAAW,EAAE,CAAC,EAAE,qBAAqB,QAAQ,EAAE,CAAC,EAChD,GAAK,SAAS,OAEd,EAAI,SAAS,cAAc,KAAK,EAChC,EAAE,aAAa,QAAS,iBAAiB,EACzC,EAAE,UAAY,SAAS,QAAQ,SAAS,aAAa,EAAE,UACvD,EAAE,CAAC,EAAE,YAAY,CAAC,EAElB,EAAI,SAAS,cAAc,KAAK,EAChC,EAAE,aAAa,QAAS,0BAA0B,EAC7C,EAAI,EAAG,EAAI,GAAI,IAGlB,EAAI,SAAS,cAAc,KAAK,EAChC,EAAE,UAAY,SAAS,QAAQ,CAAC,EAAE,UAClC,EAAE,iBAAiB,QAAS,SAAS,EAAG,CAGpC,IAAI,EAAGA,GAAG,EAAG,EAAG,EAAG,GAAI,GAIvB,IAHA,EAAI,KAAK,WAAW,WAAW,qBAAqB,QAAQ,EAAE,CAAC,EAC/D,GAAK,EAAE,OACP,EAAI,KAAK,WAAW,gBACfA,GAAI,EAAGA,GAAI,GAAIA,KAClB,GAAI,EAAE,QAAQA,EAAC,EAAE,WAAa,KAAK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