nodality 1.0.0-beta.47 → 1.0.0-beta.49
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.
- package/dist/animator.cjs.js.LICENSE.txt +1 -1
- package/dist/animator.esm.js.LICENSE.txt +1 -1
- package/dist/appleanim.cjs.js.LICENSE.txt +1 -1
- package/dist/appleanim.esm.js.LICENSE.txt +1 -1
- package/dist/audionew.cjs.js.LICENSE.txt +1 -1
- package/dist/audionew.esm.js.LICENSE.txt +1 -1
- package/dist/base.cjs.js.LICENSE.txt +1 -1
- package/dist/base.esm.js.LICENSE.txt +1 -1
- package/dist/betaDesktopBar.esm.js.LICENSE.txt +1 -1
- package/dist/betaMobileBar.esm.js.LICENSE.txt +1 -1
- package/dist/bundle.umd.js +1 -1
- package/dist/bundle.umd.js.LICENSE.txt +1 -1
- package/dist/button.cjs.js.LICENSE.txt +1 -1
- package/dist/button.esm.js.LICENSE.txt +1 -1
- package/dist/cardGetter.cjs.js.LICENSE.txt +1 -1
- package/dist/cardGetter.esm.js.LICENSE.txt +1 -1
- package/dist/center.cjs.js.LICENSE.txt +1 -1
- package/dist/center.esm.js.LICENSE.txt +1 -1
- package/dist/checkbox.cjs.js.LICENSE.txt +1 -1
- package/dist/checkbox.esm.js.LICENSE.txt +1 -1
- package/dist/code.cjs.js.LICENSE.txt +1 -1
- package/dist/code.esm.js.LICENSE.txt +1 -1
- package/dist/container.cjs.js.LICENSE.txt +1 -1
- package/dist/container.esm.js.LICENSE.txt +1 -1
- package/dist/datalist.cjs.js.LICENSE.txt +1 -1
- package/dist/datalist.esm.js.LICENSE.txt +1 -1
- package/dist/designer.cjs.js +1 -1
- package/dist/designer.cjs.js.LICENSE.txt +1 -1
- package/dist/designer.esm.js +1 -1
- package/dist/designer.esm.js.LICENSE.txt +1 -1
- package/dist/dropdown.cjs.js.LICENSE.txt +1 -1
- package/dist/dropdown.esm.js.LICENSE.txt +1 -1
- package/dist/elementMapper.cjs.js +1 -1
- package/dist/elementMapper.cjs.js.LICENSE.txt +1 -1
- package/dist/elementMapper.esm.js +1 -1
- package/dist/elementMapper.esm.js.LICENSE.txt +1 -1
- package/dist/finalresult.esm.js +1 -1
- package/dist/finalresult.esm.js.LICENSE.txt +1 -1
- package/dist/flexCard.cjs.js.LICENSE.txt +1 -1
- package/dist/flexCard.esm.js.LICENSE.txt +1 -1
- package/dist/flexGrid.cjs.js.LICENSE.txt +1 -1
- package/dist/flexGrid.esm.js.LICENSE.txt +1 -1
- package/dist/flexRow.cjs.js.LICENSE.txt +1 -1
- package/dist/flexRow.esm.js.LICENSE.txt +1 -1
- package/dist/floatingInput.cjs.js.LICENSE.txt +1 -1
- package/dist/floatingInput.esm.js.LICENSE.txt +1 -1
- package/dist/free.cjs.js.LICENSE.txt +1 -1
- package/dist/free.esm.js.LICENSE.txt +1 -1
- package/dist/horizontalScroller.esm.js.LICENSE.txt +1 -1
- package/dist/image.cjs.js.LICENSE.txt +1 -1
- package/dist/image.esm.js.LICENSE.txt +1 -1
- package/dist/imagePicker.cjs.js.LICENSE.txt +1 -1
- package/dist/imagePicker.esm.js.LICENSE.txt +1 -1
- package/dist/index.cjs.js +1 -1
- package/dist/index.cjs.js.LICENSE.txt +1 -1
- package/dist/index.esm.js +1 -1
- package/dist/index.esm.js.LICENSE.txt +1 -1
- package/dist/link.cjs.js.LICENSE.txt +1 -1
- package/dist/link.esm.js.LICENSE.txt +1 -1
- package/dist/linkGetter.cjs.js +1 -1
- package/dist/linkGetter.cjs.js.LICENSE.txt +1 -1
- package/dist/linkGetter.esm.js +1 -1
- package/dist/linkGetter.esm.js.LICENSE.txt +1 -1
- package/dist/metaAdder.cjs.js.LICENSE.txt +1 -1
- package/dist/metaAdder.esm.js.LICENSE.txt +1 -1
- package/dist/modal2025.cjs.js.LICENSE.txt +1 -1
- package/dist/modal2025.esm.js.LICENSE.txt +1 -1
- package/dist/multiswitchers.esm.js.LICENSE.txt +1 -1
- package/dist/newNavBar.cjs.js.LICENSE.txt +1 -1
- package/dist/newNavBar.esm.js.LICENSE.txt +1 -1
- package/dist/picker.cjs.js.LICENSE.txt +1 -1
- package/dist/picker.esm.js.LICENSE.txt +1 -1
- package/dist/progress.cjs.js.LICENSE.txt +1 -1
- package/dist/progress.esm.js.LICENSE.txt +1 -1
- package/dist/radio.cjs.js.LICENSE.txt +1 -1
- package/dist/radio.esm.js.LICENSE.txt +1 -1
- package/dist/range.cjs.js.LICENSE.txt +1 -1
- package/dist/range.esm.js.LICENSE.txt +1 -1
- package/dist/scrollvideo.cjs.js.LICENSE.txt +1 -1
- package/dist/scrollvideo.esm.js.LICENSE.txt +1 -1
- package/dist/sideBar.cjs.js.LICENSE.txt +1 -1
- package/dist/sideBar.esm.js.LICENSE.txt +1 -1
- package/dist/sideNavBar.cjs.js.LICENSE.txt +1 -1
- package/dist/sideNavBar.esm.js.LICENSE.txt +1 -1
- package/dist/simpleBar.cjs.js.LICENSE.txt +1 -1
- package/dist/simpleBar.esm.js.LICENSE.txt +1 -1
- package/dist/stack.cjs.js.LICENSE.txt +1 -1
- package/dist/stack.esm.js.LICENSE.txt +1 -1
- package/dist/stacker.cjs.js.LICENSE.txt +1 -1
- package/dist/stacker.esm.js.LICENSE.txt +1 -1
- package/dist/table.cjs.js.LICENSE.txt +1 -1
- package/dist/table.esm.js.LICENSE.txt +1 -1
- package/dist/text.cjs.js.LICENSE.txt +1 -1
- package/dist/text.esm.js.LICENSE.txt +1 -1
- package/dist/textField.cjs.js.LICENSE.txt +1 -1
- package/dist/textField.esm.js.LICENSE.txt +1 -1
- package/dist/transformanim.cjs.js.LICENSE.txt +1 -1
- package/dist/transformanim.esm.js.LICENSE.txt +1 -1
- package/dist/wrap.cjs.js.LICENSE.txt +1 -1
- package/dist/wrap.esm.js.LICENSE.txt +1 -1
- package/dist/zoomCard.cjs.js.LICENSE.txt +1 -1
- package/dist/zoomCard.esm.js.LICENSE.txt +1 -1
- package/layout/DEPRECATED-PARAGRAPH.js +1 -1
- package/layout/animator.js +1 -1
- package/layout/audio.js +1 -1
- package/layout/audionew.js +1 -1
- package/layout/base-2.js +1 -1
- package/layout/base.js +1 -1
- package/layout/betaDesktopBar.js +1 -1
- package/layout/betaMobileBar.js +1 -1
- package/layout/box.js +1 -1
- package/layout/button.js +1 -1
- package/layout/cards.js +1 -1
- package/layout/center.js +1 -1
- package/layout/checkbox.js +1 -1
- package/layout/cleanRow.js +1 -1
- package/layout/code.js +1 -1
- package/layout/container.js +1 -1
- package/layout/custom.js +1 -1
- package/layout/divImage.js +1 -1
- package/layout/dropdown.js +1 -1
- package/layout/dropdown2025.js +1 -1
- package/layout/emptyElement.js +1 -1
- package/layout/externalStylesheet.js +1 -1
- package/layout/flexCard.js +1 -1
- package/layout/flexGrid.js +1 -1
- package/layout/flexrow.js +1 -1
- package/layout/footer.js +1 -1
- package/layout/formComponents/custom.js +1 -1
- package/layout/formComponents/dataList.js +1 -1
- package/layout/formComponents/floatingInput.js +1 -1
- package/layout/formComponents/form-all.js +1 -1
- package/layout/formComponents/form.js +1 -1
- package/layout/formComponents/imagePicker.js +1 -1
- package/layout/formComponents/picker.js +1 -1
- package/layout/formComponents/radio.js +1 -1
- package/layout/formComponents/radiogroup.js +1 -1
- package/layout/formComponents/range.js +1 -1
- package/layout/free.js +1 -1
- package/layout/grid-new.js +1 -1
- package/layout/grid.js +1 -1
- package/layout/gridSwitcher.js +1 -1
- package/layout/group.js +1 -1
- package/layout/header.js +1 -1
- package/layout/horizontalScroller.js +1 -1
- package/layout/image-old.js +1 -1
- package/layout/image.js +1 -1
- package/layout/index.js +1 -1
- package/layout/label.js +1 -1
- package/layout/link.js +1 -1
- package/layout/list-OLD.js +1 -1
- package/layout/list.js +1 -1
- package/layout/metaAdder.js +1 -1
- package/layout/modal2025.js +1 -1
- package/layout/modernwrap.js +1 -1
- package/layout/multiswitcher.js +1 -1
- package/layout/multiswitcherBeta.js +1 -1
- package/layout/navBar-OLD.js +1 -1
- package/layout/navBar.js +1 -1
- package/layout/navFactor/customDiv.js +1 -1
- package/layout/newFlatAdder.js +1 -1
- package/layout/newNavBar copy 2.js +1 -1
- package/layout/newNavBar copy.js +1 -1
- package/layout/newNavBar.js +1 -1
- package/layout/offsetContainer.js +1 -1
- package/layout/progress.js +1 -1
- package/layout/row.js +1 -1
- package/layout/savedNewNavBar.js +1 -1
- package/layout/scrollvideo.js +1 -1
- package/layout/sideBar.js +1 -1
- package/layout/sideNavBar.js +1 -1
- package/layout/simpleBar.js +1 -1
- package/layout/slider2025.js +1 -1
- package/layout/spacer.js +1 -1
- package/layout/stack.js +1 -1
- package/layout/styler.js +1 -1
- package/layout/switcher.js +1 -1
- package/layout/table.js +1 -1
- package/layout/text.js +1 -1
- package/layout/textField.js +1 -1
- package/layout/ulist.js +1 -1
- package/layout/video.js +1 -1
- package/layout/withoutNew.js +1 -1
- package/layout/wrap.js +1 -1
- package/layout/zoomCard.js +1 -1
- package/lib/AppleAnim.js +1 -1
- package/lib/Stacker.js +1 -1
- package/lib/TransformAnim.js +1 -1
- package/lib/cardGetter.js +1 -1
- package/lib/designer.js +1 -1
- package/lib/elementMapper.js +1 -1
- package/lib/linkGetter.js +4 -1
- package/lib/scrollvideo.js +1 -1
- package/package.json +1 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/*! For license information please see elementMapper.cjs.js.LICENSE.txt */
|
|
2
|
-
(()=>{"use strict";var t={d:(e,r)=>{for(var n in r)t.o(r,n)&&!t.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:r[n]})},o:(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r:t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})}},e={};function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}function n(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==e);l=!0);}catch(t){c=!0,i=t}finally{try{if(!l&&null!=r.return&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}(t,e)||s(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function o(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=s(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,i=function(){};return{s:i,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,l=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return a=t.done,t},e:function(t){l=!0,o=t},f:function(){try{a||null==r.return||r.return()}finally{if(l)throw o}}}}function s(t,e){if(t){if("string"==typeof t)return a(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?a(t,e):void 0}}function a(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function l(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,c(n.key),n)}}function c(t){var e=function(t){if("object"!=r(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=r(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==r(e)?e:e+""}t.r(e),t.d(e,{ElementMapper:()=>_r});var u=function(){return t=function t(){var e,r,n,i=this;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),e=this,n=function(t){if(t.transform||t.op&&t.op.transform){var e=t.transform;t.transform||(e=t.op.transform),e.duration||(e.duration="3s-ease-in-out"),i.setDefault=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"0px";return 0===t.length?e+" ":t};var r=function(){var r="",n="",o="",s="",a="",l="",c="",u="",d="";if(0!==e.values.length){e.values.forEach((function(t){t.startsWith("tx:")&&(r=t.replace("tx:","")),t.startsWith("ty:")&&(n=t.replace("ty:","")),t.startsWith("tz:")?o=t.replace("tz:",""):t.startsWith("scale(")?s=t:t.startsWith("skew(")?a=t:t.startsWith("rotate(")?l=function(t){var e=t.match(/rotate\(([^)]+)\)/);if(!e)return t;var r=e[1].split(",").map((function(t){return t.trim()}));return 1===r.length?"rotate(".concat(r[0],")"):2===r.length?"rotateX(".concat(r[0],") rotateY(").concat(r[1],")"):3===r.length?"rotateX(".concat(r[0],") rotateY(").concat(r[1],") rotate(").concat(r[2],")"):t}(t):t.startsWith("perspective(")?c=t:t.startsWith("matrix(")?u=t:t.startsWith("opacity:")&&(d=t.replace("opacity:",""))})),r=i.setDefault(r),n=i.setDefault(n),o=i.setDefault(o);var h="";if("0px"!=n&&"0px"!=r&&"0px"!=o?h+="translate3d(".concat(r,", ").concat(n,", ").concat(o,")"):"0px"==n&&"0px"==r||(h+="translate(".concat(r,", ").concat(n,")")),s&&(h+=" ".concat(s)),l&&(h+=" ".concat(l)),a&&(h+=" ".concat(a)),c&&(h+=" ".concat(c)),u&&(h+=" ".concat(u)),h){if(t.op.transform.duration){var f=t.op.transform.duration.replace(/^(\d+)(s)-/,(function(t,e,r){return e/2+r+" "})),y="transform ".concat(f,", opacity ").concat(f);i.res.style.transition=y}else i.res.style.transition="transform 3s ease-in-out, opacity 3s ease-in-out";i.res.style.transform=h,i.res.style.opacity=d}}};e.on?i.res.addEventListener(e.on,(function(){e.delay?setTimeout((function(){r()}),e.delay):r()})):window.addEventListener("load",(function(){e.delay?setTimeout((function(){r()}),e.delay):r()}));var n=function(){var t="";e.values.forEach((function(e){e.startsWith("tx:")?t+="translateX(0) ":e.startsWith("ty:")?t+="translateY(0) ":e.startsWith("tz:")?t+="translateZ(0) ":e.startsWith("scale(")?t+="scale(1) ":e.startsWith("skew(")?t+="skew(0, 0) ":e.startsWith("rotate(")?t+="rotate(0) ":e.startsWith("perspective(")?t+="perspective(0) ":e.startsWith("matrix(")&&(t+="matrix(1, 0, 0, 1, 0, 0) "),i.res.style.opacity="1"})),t&&(i.res.style.transform=t.trim())};if(e.on)i.res.addEventListener("mouseout",(function(){e.keep||n()}));else{var o=1e3*parseFloat(e.duration),s=e.closeAfter?e.closeAfter:0;setTimeout((function(){e.keep||n()}),o/2+s)}}},(r=c(r="reactOnTransform"))in e?Object.defineProperty(e,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[r]=n,this.state={isExpanded:!1,isMovedUp:!1,isMovedDown:!1}},e=[{key:"keySet",value:function(t){return this.temporaryVal=1,this.res.style[t.key]=t.value,this}},{key:"onScroll",value:function(t){var e=this;"opacity"===t.value?this.res.style.opacity=t.valMin:"scale"===t.value&&(this.res.style.transform="scale(".concat(t.valMax,")")),window.addEventListener("scroll",(function(){var r=e.smartRange(window.scrollY,{min:t.from,max:t.to},{min:t.valMin,max:t.valMax});"opacity"===t.value?e.res.style.opacity=r:"scale"===t.value&&(e.res.style.transform="scale(".concat(r,")"))}))}},{key:"setAny",value:function(t){this[Object.keys(t)[0]]=[Object.values(t)[0]]}},{key:"setID",value:function(t){this.id=t}},{key:"setPrevText",value:function(t){this.prevText=t}},{key:"getCSS",value:function(){return this.css}},{key:"getPX",value:function(t){return{xs:"0px",sm:"576px",md:"768px",lg:"992px",xl:"1200px",xxl:"1400px",mxxl:"1800px"}[t]||"Invalid breakpoint"}},{key:"respad",value:function(t){var e=this,r=function(){e.pad(t[0].values);for(var r=0;r<t.length;r++){var n=t[r].breakpoint;window.matchMedia("(min-width: ".concat(e.getPX(n))).matches&&e.pad(t[r].values)}};window.addEventListener("resize",r),r()}},{key:"resmar",value:function(t){var e=this,r=function(){e.mar(t[0].values);for(var r=0;r<t.length;r++){var n=t[r].breakpoint;window.matchMedia("(max-width: ".concat(e.getPX(n))).matches&&e.mar(t[r].values)}};window.addEventListener("resize",r),r()}},{key:"resprop",value:function(t){var e=this;this.prevBackground=this.res.style.background,this.prevWidth=this.res.style.width,this.prevHeight=this.res.style.height,this.prevBorder=this.res.style.border;var r=function(){e.res.style.background=e.prevBackground,e.res.style.width=e.prevWidth,e.res.style.height=e.prevHeight,e.res.style.border=e.prevBorder;for(var r=0;r<t.length;r++){var n=t[r].breakpoint;if(window.matchMedia("(max-width: ".concat(e.getPX(n))).matches){var i={};for(var o in t[r])"breakpoint"!==o&&(i[o]=t[r][o]);e.set(i)}}};window.addEventListener("resize",r),r()}},{key:"isNumber",value:function(t){return"number"==typeof t&&!isNaN(t)}},{key:"pad",value:function(t){for(var e=0;e<t.length;e++)for(var r=Object.keys(t[e]),n=0;n<r.length;n++)for(var i=r[n],o=t[e][i],s=0;s<i.length;s++)switch(i[s]){case"a":this.res.style.padding=this.isNumber(o)?"".concat(o,"px"):o;break;case"t":this.res.style.paddingTop=this.isNumber(o)?"".concat(o,"px"):o;break;case"l":this.res.style.paddingLeft=this.isNumber(o)?"".concat(o,"px"):o;break;case"r":this.res.style.paddingRight=this.isNumber(o)?"".concat(o,"px"):o;break;case"b":this.res.style.paddingBottom=this.isNumber(o)?"".concat(o,"px"):o}return this}},{key:"as",value:function(t){return this.res.style.alignSelf=t,this}},{key:"mar",value:function(t){for(var e=0;e<t.length;e++)for(var r=Object.keys(t[e]),n=0;n<r.length;n++)for(var i=r[n],o=t[e][i],s=0;s<i.length;s++){switch(i[s]){case"a":this.res.style.margin=this.isNumber(o)?"".concat(o,"px"):o;break;case"t":this.res.style.marginTop=this.isNumber(o)?"".concat(o,"px"):o;break;case"l":this.res.style.marginLeft=this.isNumber(o)?"".concat(o,"px"):o;break;case"r":this.res.style.marginRight=this.isNumber(o)?"".concat(o,"px"):o;break;case"b":this.res.style.marginBottom=this.isNumber(o)?"".concat(o,"px"):o}"auto"===i[s]&&(this.res.style.marginLeft="auto",this.res.style.marginRight="auto")}return this}},{key:"smartRange",value:function(t,e,r){t<e.min&&(t=e.min),t>e.max&&(t=e.max);var n=(t-e.min)/(e.max-e.min);e.min>e.max&&(n=(t-e.max)/(e.min-e.max));var i=(r.min-r.max)*n-r.min;if(i=Math.abs(i),r.min<r.max){var o=(r.max+Math.abs(r.min))*n;i=r.min+o}return i}},{key:"gpos",value:function(t){return this.res.style.gridColumn=t.col,this.res.style.gridRow=t.row,this}},{key:"fluidCopy",value:function(t){if(t instanceof Object){this.prevStylex=this.res.style,this.res=document.createElement("h1"),this.res.style.cssText=this.prevStylex.cssText;var e=document.createTextNode(this.text);return this.res.appendChild(e),this.res.style.fontSize=t.exact,this}if("S1"===t){this.prevStylex=this.res.style,this.res=document.createElement("h1"),this.res.style.cssText=this.prevStylex.cssText;var r=document.createTextNode(this.text);this.res.appendChild(r),this.res.style.fontSize="calc(1.625rem + 5.075vw)"}if("S2"===t){this.prevStylex=this.res.style,this.res=document.createElement("h2"),this.res.style.cssText=this.prevStylex.cssText;var n=document.createTextNode(this.text);this.res.appendChild(n),this.res.style.fontSize="calc(1.500rem + 4.3vw)"}if("S3"===t){this.prevStylex=this.res.style,this.res=document.createElement("h3"),this.res.style.cssText=this.prevStylex.cssText;var i=document.createTextNode(this.text);this.res.appendChild(i),this.res.style.fontSize="calc(1.375rem + 3.525vw)"}if("S4"===t){this.prevStylex=this.res.style,this.res=document.createElement("h4"),this.res.style.cssText=this.prevStylex.cssText;var o=document.createTextNode(this.text);this.res.appendChild(o),this.res.style.fontSize="calc(1.250rem + 2.75vw)"}if("S5"===t){this.prevStylex=this.res.style,this.res=document.createElement("h5"),this.res.style.cssText=this.prevStylex.cssText;var s=document.createTextNode(this.text);this.res.appendChild(s),this.res.style.fontSize="calc(1.125rem + 1.975vw)"}return"S6"===t&&(this.res.style.fontSize="calc(1rem + 0.5vw)"),this}},{key:"setIndex",value:function(t){this.index=t}},{key:"borderObj",value:function(t){var e,r=null!==(e=t.type)&&void 0!==e?e:"solid";return this.res.style.border="".concat(t.width," ").concat(r," ").concat(t.color),this.res.style.borderRadius=t.radius,this}},{key:"protoReact",value:function(t,e){var r=this;t.sort((function(t,e){return parseInt(t.range[0])-parseInt(e.range[0])}));var i=function(){var i=window.innerWidth,s="";r.storedQueries=t.map((function(t){return t.target})).filter((function(t){return null!=t}));var a,l=o(t);try{for(l.s();!(a=l.n()).done;){var c=a.value;r.counterIndex++;var u=n(c.range,2),d=u[0],h=u[1],f=parseInt(d),y=parseInt(h),p=!0;if(c.target){p=!1;for(var m=0;m<c.target.length;m++)c.target[m]===e&&(p=!0)}i>=f&&i<=y&&p&&("gradient"===c.log&&(s+="gradient"),"blast"===c.log&&(s+="blast"),"animation"===c.log&&(s+="animation"),"shadow"===c.log&&(s+="shadow"),"span"===c.log&&(s+="span"),"filter"===c.log&&(s+="filter"),"background"===c.log&&(s+="background"))}}catch(t){l.e(t)}finally{l.f()}r.res.style.margin="";var v,b=r.res.style.color;for(t.map((function(t){return t.log})).filter((function(t){return null!=t})).includes("gradient")&&(r.res.style.WebkitBackgroundClip="",r.res.style.background=""),r.res.style["-webkit-text-stroke"]="",r.res.style.filter="",r.res.style.textShadow="",r.res.style.border="";r.res.firstChild;)r.res.removeChild(r.res.firstChild);if(r.res.textContent=r.text,""===s&&(r.res.style["-webkit-text-fill-color"]="",r.res.style.color=b),"blast"===s){for(m=0;m<t.length;m++){var g=t[m].op.offsets;g&&void 0!==r.index&&(r.res.style.margin=g[Number(r.index)]+"px")}for(r.res.style["-webkit-text-fill-color"]="transparent",r.res.style["-webkit-text-stroke"]=r.globalBlast,m=0;m<t.length;m++){var w=t[m].op.offsets;w&&void 0!==r.index&&(r.res.style.margin=w[Number(r.index)]+"px")}}if("gradient"===s&&(r.res.style["-webkit-text-fill-color"]="transparent",r.res.style.background=r.globalGradient,r.res.style["-webkit-background-clip"]="text",r.res.style.border="1px solid orange"),"background"===s&&(r.res.style.background="orange"),"gradientblast"===s&&(r.res.style["-webkit-text-fill-color"]="transparent",r.res.style.background=r.globalGradient,r.res.style["-webkit-background-clip"]="text",r.res.style["-webkit-text-stroke"]=r.globalBlast),"gradientanimation"===s&&(r.res.style["-webkit-text-fill-color"]="transparent",r.res.style.background=r.globalGradient,r.res.style["-webkit-background-clip"]="text"),"gradientanimationshadow"===s&&(r.res.style["-webkit-text-fill-color"]="transparent",r.res.style.background=r.globalGradient,r.res.style["-webkit-background-clip"]="text",r.res.style.textShadow=r.globalShadow),"animationshadow"===s&&(r.res.style["-webkit-text-fill-color"]="",r.res.style.textShadow=r.globalShadow),"shadow"===s&&(r.res.style["-webkit-text-fill-color"]="",r.res.style.textShadow=r.globalShadow),"span"===s&&r.options.span)for(v=Array.isArray(r.options.span)?r.options.span.filter((function(t){return"span"===t.op.name}))[0]:r.options.span,r.res.textContent="",m=0;m<v.op.parts.length;m++){var k=v.op.parts[m].style,x=new Text(v.op.parts[m].text).setup({type:"span"}).set(k).render();r.res.appendChild(x)}if("filter"===s){var S=r.options.filtera.op.filter;r.res.style.filter=S,r.res.style.border="8px solid orange"}};window.addEventListener("resize",i),i()}},{key:"setPref",value:function(t){this.preffersId=t}},{key:"setClass",value:function(t){this.class=t}},{key:"betaReact",value:function(t,e){var r=this;this.ap=!1,this.cta=0,this.once=!1,t.sort((function(t,e){return parseInt(t.range[0])-parseInt(e.range[0])}));var i=function(){var i=window.innerWidth,s="";r.resCopy=r.res,r.storedQueries=t.map((function(t){return t.target})).filter((function(t){return null!=t}));var a,l=o(t);try{for(l.s();!(a=l.n()).done;){var c=a.value;r.counterIndex++;var u=n(c.range,2),d=u[0],h=u[1],f=parseInt(d),y=parseInt(h),p=!0;if(c.target){p=!1;for(var m=0;m<c.target.length;m++)c.target[m]===e&&(p=!0)}i>=f&&i<=y&&p&&("blast"===c.log&&(s+="blast"),"shadow"===c.log&&(s+="shadow"),"background"===c.log&&(s+="background"),"gradient"===c.log&&(s+="gradient"),"spana"===c.log&&(s+="spana"),"layout"===c.log&&(s+="layout"),"margin"===c.log&&(s+="margin"),c.op&&c.op.margin&&(r.useMargin=c.op.margin))}}catch(t){l.e(t)}finally{l.f()}if(r.res.style.background="",r.res.style.backgroundColor="",r.res.style.textShadow="",r.res.style.border="",r.res.style.margin="",r.res.style["-webkit-text-fill-color"]="",r.res.style["-webkit-text-stroke"]="",r.res.style["-webkit-text-stroke-width"]="","background"===s&&(r.res.style.backgroundColor="green"),"margin"===s)for(m=0;m<t.length;m++)if(t[m].op){var v=t[m].op.offsets;v&&void 0!==r.index&&(r.res.style.margin=v[Number(r.index)]+"px")}if("blastbackgroundmargin"===s){for(m=0;m<t.length;m++)if(t[m].op){var b=t[m].op.offsets;b&&void 0!==r.index&&(r.res.style.margin=b[Number(r.index)]+"px")}r.res.style.backgroundColor="green","FlexRowLayoutElement"===r.getType()?r.res.style.border="1px solid orange":(r.res.textContent=r.text,r.res.style["-webkit-text-fill-color"]="transparent",r.res.style["-webkit-text-stroke-color"]="orange",r.res.style["-webkit-text-stroke-width"]="1px"),r.res.style["-webkit-text-fill-color"]="transparent",r.res.style["-webkit-text-stroke-color"]="orange",r.res.style["-webkit-text-stroke-width"]="1px"}if("blastbackground"===s){for(m=0;m<t.length;m++)if(t[m].op){var g=t[m].op.offsets;g&&void 0!==r.index&&(r.res.style.margin=g[Number(r.index)]+"px")}r.res.style.backgroundColor="green",r.useMargin?r.res.style.margin="1rem":r.res.setAttribute("id","iofhwoiefhoih"),"FlexRowLayoutElement"===r.getType()?r.res.style.border="1px solid orange":(r.res.textContent=r.text,r.res.style["-webkit-text-fill-color"]="transparent",r.res.style["-webkit-text-stroke-color"]="orange",r.res.style["-webkit-text-stroke-width"]="1px"),r.res.style["-webkit-text-fill-color"]="transparent",r.res.style["-webkit-text-stroke-color"]="orange",r.res.style["-webkit-text-stroke-width"]="1px"}if("layout"===s&&(r.res.style.alignSelf="start",r.res.style.border="1px solid purple"),"blast"===s){for(m=0;m<t.length;m++)if(t[m].op){var w=t[m].op.offsets;w&&void 0!==r.index&&(r.res.style.margin=w[Number(r.index)]+"px")}"FlexRowLayoutElement"===r.getType()?r.res.style.border="1px solid orange":(r.res.textContent=r.text,r.res.style["-webkit-text-fill-color"]="transparent",r.res.style["-webkit-background-clip"]="text",r.res.style["-webkit-text-stroke-color"]="orange",r.res.style["-webkit-text-stroke-width"]="1px"),r.res.style["-webkit-text-fill-color"]="transparent",r.res.style["-webkit-text-stroke"]="orange",r.res.style["-webkit-text-stroke-width"]="1px"}"blastgradientbackground"===s&&(r.res.style.border="1px solid yellow",r.res.style["-webkit-text-stroke-color"]="orange",r.res.style["-webkit-text-stroke-width"]="1px"),"gradient"===s&&(r.res.style.background="linear-gradient(to left, #3498db, #1abc9c)","FlexRowLayoutElement"===r.getType()||(r.res.children[0]&&r.res.removeChild(r.res.children[0]),r.res.style["-webkit-text-fill-color"]="transparent",r.res.style["-webkit-background-clip"]="text",r.res.textContent=r.text)),"shadow"===s&&("FlexRowLayoutElement"===r.getType()||(r.res.children[0]&&r.res.removeChild(r.res.children[0]),r.res.style["-webkit-text-fill-color"]="",r.res.style["-webkit-text-fill-color"]="",r.res.style.textShadow="#1abc9cff -6px 6px , #1abc9c40 -12px 12px",r.res.textContent=r.text))};window.addEventListener("resize",i),i()}},{key:"cssGen",value:function(t,e,r,n){return this.css=[""],[""]}},{key:"chainReact",value:function(t,e,r){var i=this;this.cssGen(t,e,this.class,void 0!==this.class),this.ap=!1,this.cta=0,this.once=!1;var s,a=o(t);try{for(a.s();!(s=a.n()).done;){var l=s.value;l.range||(l.range=["0px","999999px"])}}catch(t){a.e(t)}finally{a.f()}t.sort((function(t,e){return parseInt(t.range[0])-parseInt(e.range[0])}));var c=function(){var s=window.visualViewport.width,a=[],l=[];i.resCopy=i.res,i.storedQueries=t.map((function(t){return t.target})).filter((function(t){return null!=t}));var c,u=o(t);try{for(u.s();!(c=u.n()).done;){var d=c.value;i.counterIndex++;var h=n(d.range,2),f=h[0],y=h[1],p=parseInt(f),m=parseInt(y),v=!0;if(d.target){v=!1;for(var b=0;b<d.target.length;b++)d.target[b]===e&&(v=!0)}s>=p&&s<=m&&v&&(a.push(d.log),l.push(d),d.op&&d.op.margin&&(i.useMargin=d.op.margin))}}catch(t){u.e(t)}finally{u.f()}if(r&&!r.includes("background")&&(i.res.style.background="",i.res.style.backgroundColor=""),i.res.style.textShadow="",r&&!r.includes("border")&&(i.res.style.border=""),r&&!r.includes("margin")&&(i.res.style.margin=""),i.res.style["-webkit-text-fill-color"]="",i.res.style["-webkit-text-stroke-color"]="",i.res.style["-webkit-text-stroke-width"]="",i.res.style.filter="",(a.includes("gradient")||a.includes("shadow"))&&(i.res.style.position="relative",i.res.style.zIndex=-1),a.includes("blast")){var g,w=l.filter((function(t){return"blast"===t.log}))[0].op.color,k=null!==(g=l.filter((function(t){return"blast"===t.log}))[0].op.width)&&void 0!==g?g:"1px";"FlexRowLayoutElement"===i.getType()?i.res.style.border="".concat(k,"px solid orange"):(i.res.textContent=i.text,i.res.style["-webkit-text-fill-color"]="transparent",i.res.style["-webkit-text-stroke-color"]=w,i.res.style["-webkit-text-stroke-width"]="".concat(k))}if(a.includes("filter")){var x=l.filter((function(t){return"filter"===t.log}))[0].op.filter;i.res.style.filter=x}if(a.includes("background")&&(i.res.style.backgroundColor="green"),a.includes("gradient")&&(i.res.style["-webkit-text-fill-color"]="transparent",i.res.style.background=i.globalGradient,i.res.style["background-clip"]="text"),a.includes("shadow"))if("FlexRowLayoutElement"===i.getType());else{var S="",O=0;for(b=0;b<i.options.shadow.op.steps;b++)S+="drop-shadow(".concat(O+=3,"px ").concat(O,"px ").concat(O,"px gray) ");i.res.style.filter=S}if(a.includes("margin"))for(b=0;b<t.length;b++)if(t[b].op){var C=t[b].op.offsets;C&&void 0!==i.index&&(i.res.style.margin=C[Number(i.index)]+"px")}if(a.includes("spana")||a.includes("span")){if(i.res=i.resCopy,i.options.span){var j;for(j=Array.isArray(i.options.span)?i.options.span.filter((function(t){return"span"===t.op.name}))[0]:i.options.span,i.res.textContent="",b=0;b<j.op.parts.length;b++){var E=j.op.parts[b].style,T=new i.constructor(j.op.parts[b].text).setup({type:"span"}).set(E).render();i.res.appendChild(T)}}}else{for(;i.res.firstChild;)i.res.removeChild(i.res.firstChild);var P=new i.constructor(i.prevText).set({}).render();i.res.appendChild(P)}if(a.includes("animation")){if(i.options.animation&&!i.hasAnimated&&!i.options.animation.op.fireAt){i.hasAnimated=!0;var A=i.options.animation.op;i.res.animate(A.keyframesClose,{duration:0,fill:"forwards"}),i.res.animate(A.keyframesOpen,A.openOptions)}if(i.options.animation&&i.options.animation.op.fireAt&&i.options.animation.op.fireAt.endsWith("px")){var R=i.options.animation.op;i.res.animate(R.keyframesClose,{duration:0,fill:"forwards"});var L=function(){window.scrollY>parseFloat(R.fireAt)&&(i.res.animate(R.keyframesOpen,R.openOptions),window.removeEventListener("scroll",L))};window.addEventListener("scroll",L)}if(i.options.animation&&i.options.animation.op.fireAt&&"inview"===i.options.animation.op.fireAt){var z=i.options.animation.op;i.res.animate(z.keyframesClose,{duration:0,fill:"forwards"}),new IntersectionObserver((function(t,e){t.forEach((function(t){t.isIntersecting&&(i.res.animate(z.keyframesOpen,z.openOptions),e.disconnect())}))})).observe(i.res)}}};window.addEventListener("resize",c),c()}},{key:"maxWidth",value:function(t){return this.res.style.maxWidth=t,this}},{key:"removeQuotesFromFirstWord",value:function(t){return t.replace(/"([^"]+)":/g,"$1:")}},{key:"arrayMargin",value:function(t,e){return t.includes("left")&&(this.res.style.marginLeft=e),t.includes("right")&&(this.res.style.marginRight=e),t.includes("top")&&(this.res.style.marginTop=e),t.includes("bottom")&&(this.res.style.marginBottom=e),t.includes("all")&&(this.res.style.margin=e),e||(this.res.style.marginBottom=t),this}},{key:"navBarExpand",value:function(){return this.res.style.backgroundColor="green",this.res.animate([{transform:"scaleY(3.0)"}],{duration:2e3,iterations:1,fill:"both"}),this}},{key:"scrollFade",value:function(t,e){return this.res.style.visibility="hidden",this.faden(t,e,"scroll"),this}},{key:"expand",value:function(t){var e=this;return!1===this.state.isExpanded?"click"===t.on?this.res.addEventListener("click",(function(){e.innerExpand(t)})):this.innerExpand(t):this.innerExpandBack(t),this.state.isExpanded=!this.state.isExpanded,this}},{key:"move",value:function(t){var e=this;return"click"===t.on?this.res.addEventListener("click",(function(){e.moveUpa(t)})):("up"===t.direction&&this.moveUpa(t),"down"===t.direction&&this.moveDowna(t),this.state.isMovedUp=!this.state.isMovedUp,"left"===t.direction&&this.moveLeft(t)),this}},{key:"moveLeft",value:function(t){return this.res.animate([{transform:"translateX(0px)"},{transform:"translateX(-".concat(t.distance,")")}],{duration:900,iterations:t.iterations,fill:"both"}).play(),this}},{key:"moveUpa",value:function(t){return!1===this.state.isMovedUp?this.res.animate([{transform:"translateX(0px)"},{transform:"translateY(-".concat(t.distance,")")}],{duration:900,iterations:t.iterations,fill:"both"}).play():this.res.animate([{transform:"translateX(0px)"},{transform:"translateY(".concat(t.distance,")")}],{duration:900,iterations:t.iterations,fill:"both"}).play(),this}},{key:"moveDowna",value:function(t){return!1===this.state.isMovedDown?this.res.animate([{transform:"translateX(0px)"},{transform:"translateY(".concat(t.distance,")")}],{duration:900,iterations:t.iterations,fill:"both"}).play():this.res.animate([{transform:"translateX(0px)"},{transform:"translateY(-".concat(t.distance,")")}],{duration:900,iterations:t.iterations,fill:"both"}).play(),this}},{key:"moveUpaBack",value:function(t){return this.res.animate([{transform:"translateX(0px)"}],{duration:900,iterations:t.iterations,fill:"both"}).play(),this}},{key:"innerExpandBack",value:function(t){this.res.animate([{width:this.prevWidth,height:this.prevHeight}],{duration:900,iterations:t.iterations,fill:"both"})}},{key:"innerExpand",value:function(t){var e,r;return this.prevWidth=this.res.style.width,this.prevHeight=this.res.style.height,this.res.animate([{width:this.prevWidth,height:this.prevHeight},{width:null!==(e=t.width)&&void 0!==e?e:this.prevWidth,height:null!==(r=t.height)&&void 0!==r?r:this.prevHeight}],{duration:900,iterations:t.iterations,fill:"both"}),this}},{key:"fade",value:function(t){return this.res.style.visibility="hidden",this.faden(t.duration,t.from,"load"),t.finalOpacity&&(this.finalOpacity=t.finalOpacity),this}},{key:"faden",value:function(t,e,r){var n=this;return this.res.style.visibility="hidden",this.scrolled=!1,window.addEventListener(r,(function(){n.res.style.visibility="visible";var i=window.innerHeight;(n.res.getBoundingClientRect().top-i<=0||"load"==r)&&0==n.scrolled&&("left"==e&&n.res.animate([{transform:"translateX(-30px)"},{transform:"translateX(0px)"}],{duration:t,iterations:1}),"right"==e&&n.res.animate([{transform:"translateX(30px)"},{transform:"translateX(0px)"}],{duration:t,iterations:1}),"top"==e&&n.res.animate([{transform:"translateY(-30px)"},{transform:"translateY(0px)"}],{duration:t,iterations:1}),"bottom"==e&&n.res.animate([{transform:"translateY(30px)"},{transform:"translateY(0px)"}],{duration:t,iterations:1}),n.res.animate([{opacity:"0.0"},{opacity:"1.0"}],{duration:t,iterations:1}),n.scrolled=!0)})),this}}],e&&l(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function d(t){return d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},d(t)}function h(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==e);l=!0);}catch(t){c=!0,i=t}finally{try{if(!l&&null!=r.return&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}(t,e)||f(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function f(t,e){if(t){if("string"==typeof t)return y(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?y(t,e):void 0}}function y(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function p(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,m(n.key),n)}}function m(t){var e=function(t){if("object"!=d(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=d(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==d(e)?e:e+""}function v(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(v=function(){return!!t})()}function b(t,e,r,n){var i=g(w(1&n?t.prototype:t),e,r);return 2&n&&"function"==typeof i?function(t){return i.apply(r,t)}:i}function g(){return g="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(t,e,r){var n=function(t,e){for(;!{}.hasOwnProperty.call(t,e)&&null!==(t=w(t)););return t}(t,e);if(n){var i=Object.getOwnPropertyDescriptor(n,e);return i.get?i.get.call(arguments.length<3?t:r):i.value}},g.apply(null,arguments)}function w(t){return w=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},w(t)}function k(t,e){return k=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},k(t,e)}var x=function(t){function e(t,r){var n;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(n=function(t,e,r){return e=w(e),function(t,e){if(e&&("object"==d(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,v()?Reflect.construct(e,r||[],w(t).constructor):e.apply(t,r))}(this,e)).text=t,n.res=null,n.setup(r),n.code=[],n.elCSS=[],n.html=[],n.react=[],n.code.push('new Text("'.concat(n.text,'")')),console.log("AAAAA"),n}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&k(t,e)}(e,t),r=e,n=[{key:"flexOne",value:function(){return this.res.style.flex="1",this}},{key:"setGridWithoutCode",value:function(){return this.res.style.border="1px solid white",this}},{key:"setArea",value:function(t){return this.res.style.gridArea=t,this}},{key:"toCodea",value:function(){return this.excludeFromCodeTrue&&(this.code=[""]),this.code}},{key:"toCode",value:function(){if(this.excludeFromCodeTrue)return[""];var t=Object.fromEntries(Object.entries(this.options).filter((function(t){var e=h(t,2);return e[0],null!==e[1]}))),e=JSON.stringify(t,null,4).replace(/"([^"]+)":/g,"$1:");return console.log("OCO"),console.log(e),['new Text("'.concat(this.text,'").set(').concat(e,")")]}},{key:"toCSS",value:function(){return this.css}},{key:"toHTMLA",value:function(){return this.html}},{key:"toElCSS",value:function(){return this.elCSS=this.elCSS.map((function(t){return" "+t})),this.preffersId?this.elCSS.unshift(this.res.id+" { \n"):this.elCSS.unshift("."+this.class+" { \n"),this.elCSS.push(" } \n \n"),this.elCSS}},{key:"getType",value:function(){return"S1"===this.options.fluidc?"HTMLHeaderElement":"HTMLParagraphElement"}},{key:"gradientOptions",value:function(t){var e=this;if(0===t.length)return this;var r=t.filter((function(t){return"gradient"===t.op.name}))[0];if(void 0===r)return this;var n=r.op;if(r.point){var i=function(){window.matchMedia("(min-width: ".concat(r.range[0],") and (max-width: ").concat(r.range[1],")")).matches&&(e.prevBackground=e.res.style.color.toString(),e.res.style.background=n.gradient,e.res.style.WebkitBackgroundClip="text")};i(),window.addEventListener("resize",i)}}},{key:"strokeOptions",value:function(t){var e=this;if(0===t.length)return this;var r=t.filter((function(t){return"blast"===t.op.name}))[0];if(void 0===r)return this;console.log("DEL");var n=r.op;if(r.point){var i=function(){window.matchMedia("(min-width: ".concat(r.range[0],") and (max-width: ").concat(r.range[1],")")).matches&&(n.color?e.res.style["-webkit-text-stroke"]="".concat(n.width?n.width:"1px"," ").concat(n.color):e.res.style["-webkit-text-stroke"]="1px orange",e.res.style["-webkit-text-fill-color"]="transparent")};i(),window.addEventListener("resize",i)}else n.color&&(this.res.style["-webkit-text-stroke"]="".concat(n.width?n.width:"1px"," ").concat(n.color)),this.res.style["-webkit-text-fill-color"]="transparent"}},{key:"stroke",value:function(){return this.res.style["-webkit-text-stroke"]="3px orange",this}},{key:"fill",value:function(){return this.res.style["-webkit-text-fill-color"]="transparent",this}},{key:"rowCol",value:function(t,e){return this.res.style.gridRow=t,this.res.style.gridColumn=e,this}},{key:"setGridRow",value:function(t){return this.res.style.gridRow=t,this}},{key:"setGridCol",value:function(t){return this.res.style.gridColumn=t,this}},{key:"toHTML",value:function(){return this.res}},{key:"onTap",value:function(t){return this.res.addEventListener("click",t),this}},{key:"setClass",value:function(t){return this.res.setAttribute("class",t),this}},{key:"setRandom",value:function(){for(var t="LAYOUT-",e=90;e>0;--e)t+="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"[Math.floor(62*Math.random())];return t+=(new Date).getTime(),this.res.setAttribute("class",t),this}},{key:"styled",value:function(t){return this.set(t),this}},{key:"removeQuotesFromFirstWord",value:function(t){return t.replace(/"([^"]+)":/g,"$1:")}},{key:"set",value:function(t){this.resCopy=this.res,this.options=t,b(e,"setPrevText",this,3)([this.text]),t.maxWidth&&(this.res.style.maxWidth=t.maxWidth),t.cursor&&(this.res.style.cursor="hand"),t.gpos&&this.gpos(t.gpos),t.vtn&&(this.res.style.viewTransitionName=t.vtn),t.index&&b(e,"setIndex",this,3)([t.index]),t.index&&(this.index=t.index),t.preffersId&&(this.preffersId=t.preffersId),b(e,"setPref",this,3)([t.preffersId]),t.removeDecoration&&(this.res.style.textDecoration="none"),t.block&&(this.res.style.display="block"),t.area&&this.setArea(t.area),t.icon&&this.addIcon(t.icon),t.color&&this.color(t.color),t.color&&this.elCSS.push("color: ".concat(t.color,"; \n")),t.class&&this.setClass(t.class),t.size&&this.fluidCopy(t.size),t.fluidc&&this.fluidCopy(t.fluidc),t.initLetter&&this.initLetter(t.initLetter),t.onTap&&this.onTap(t.onTap),"S6"===t.fluidc?t.fluidc&&this.elCSS.push("font-size: calc(1.1rem + 2.075vw); \n"):t.fluidc&&this.elCSS.push("font-size: calc(1.625rem + 5.075vw); \n"),this.options.id&&this.res.setAttribute("id",this.options.id),b(e,"setID",this,3)([this.options.id]),this.options.class&&this.res.setAttribute("class",this.options.class),b(e,"setClass",this,3)([this.options.class]),t.clampc&&this.clampCopy(t.clampc),t.arrpad&&this.arrayPadding(t.arrpad.sides,t.arrpad.value),t.pad&&this.pad(t.pad),t.respad&&this.respad(t.respad),t.resmar&&this.resmar(t.resmar),t.mar&&this.mar(t.mar),t.exact&&(this.res.style.fontSize=t.exact),t.zIndex&&(this.res.style.zIndex=t.zIndex),t.absolute&&(this.res.style.position="absolute"),t.arrayMargin&&this.arrayMargin(t.arrayMargin.sides,t.arrayMargin.value),t.em&&this.em(t.em),t.fluid&&this.fluid(t.fluid),t.font&&this.font(t.font),t.fluidc&&this.elCSS.push("font-family: ".concat(t.font,"; \n")),t.align&&(this.res.style.textAlign=t.align),t.weight&&(this.res.style.fontWeight=t.weight),t.padding&&this.padding(t.padding),t.breakWord&&(this.res.style.wordWrap="break-word"),t.center&&(this.res.style.marginRight="auto"),t.center&&(this.res.style.marginLeft="auto"),t.width&&(this.res.style.width=t.width),t.height&&(this.res.style.height=t.height),t.background&&(this.res.style.backgroundColor=t.background),t.radius&&(this.res.style.borderRadius=t.radius),t.italic&&this.italic(),t.responsive&&this.responsive(),t.border&&(this.res.style.border="".concat(t.border)),t.onScroll&&this.onScroll(t.onScroll),t.keySet&&this.keySet(t.keySet),t.maxHeight&&(this.res.style.maxHeight=t.maxHeight),t.transform&&this.reactOnTransform(t.transform),console.log("OGA"),console.log(t);var r=[];if(t.stroke||t.gradient||t.span||t.backgroundOp||t.layout||t.shadow||t.animation||t.filtera||t.transform){t.gradient&&(this.globalGradient=t.gradient.op.gradient),t.stroke&&b(e,"setAny",this,3)([{globalBlast:"".concat(t.stroke.op.width," ").concat(t.stroke.op.color)}]),t.span&&(t.span.prevText=this.text);var n=[t.stroke,t.gradient,t.animation,t.span,t.backgroundOp,t.layout,t.marginOp,t.shadow,t.animation,t.filtera,t.transform];n=n.filter((function(t){return null!=t}));for(var i=0;i<n.length;i++)r.push({range:n[i].range,log:n[i].op.name,target:n[i].target,op:n[i].op});var o=[];t.borderObj&&o.push("border"),t.background&&o.push("background"),t.mar&&o.push("margin"),t.animation&&o.push("animation"),t.span&&o.push("span"),console.log("ARA IS "),console.log(r),this.chainReact(r,this.options.id,o)}return this}},{key:"excludeFromCode",value:function(){return this.excludeFromCodeTrue=!0,this}},{key:"addIcon",value:function(t){var e=document.createElement("img");return e.style.width="20px",e.style.marginLeft="10px",e.style.height="auto",e.setAttribute("src",t.url),this.res.appendChild(e),this}},{key:"checkForAnimation",value:function(t){t.sort((function(t,e){return parseInt(t.range[0])-parseInt(e.range[0])}));var e,r=window.innerWidth,n=function(t){var e="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=f(t))){e&&(t=e);var r=0,n=function(){};return{s:n,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,o=!0,s=!1;return{s:function(){e=e.call(t)},n:function(){var t=e.next();return o=t.done,t},e:function(t){s=!0,i=t},f:function(){try{o||null==e.return||e.return()}finally{if(s)throw i}}}}(t);try{for(n.s();!(e=n.n()).done;){var i=e.value,o=h(i.range,2),s=o[0],a=o[1],l=parseInt(s),c=parseInt(a);r>=l&&r<=c&&"animation"===i.log&&this.res.animate([{opacity:0,transform:"translateY(100px)"},{opacity:1,transform:"translateY(0)"}],{duration:1e3,easing:"ease"})}}catch(t){n.e(t)}finally{n.f()}}},{key:"resetSmall",value:function(){this.res.style["-webkit-text-stroke"]="",this.res.style["-webkit-text-fill-color"]=""}},{key:"resetGradient",value:function(){return this.res.style.WebkitBackgroundClip="text",this.res.style.background="transparent",this}},{key:"resetStroke",value:function(){this.res.style["-webkit-text-stroke"]="",this.res.style["-webkit-text-fill-color"]=""}},{key:"innerStroke",value:function(t){t.color?this.res.style["-webkit-text-stroke"]="".concat(t.width?t.width:"1px"," ").concat(t.color):this.res.style["-webkit-text-stroke"]="1px orange",this.res.style["-webkit-text-fill-color"]="transparent"}},{key:"innerGradient",value:function(t){this.res.style.background="linear-gradient(45deg, #ff0000, #00ff00)",this.res.style["-webkit-background-clip"]="text"}},{key:"arrayMargin",value:function(t,e){return e||(this.res.style.marginLeft="".concat(t[0],"px"),this.res.style.marginTop="".concat(t[1],"px"),this.res.style.marginRight="".concat(t[2],"px"),this.res.style.marginBottom="".concat(t[3],"px")),t.includes("left")&&(this.res.style.marginLeft=e),t.includes("right")&&(this.res.style.marginRight=e),t.includes("top")&&(this.res.style.marginTop=e),t.includes("bottom")&&(this.res.style.marginBottom=e),e||(this.res.style.marginBottom=t),this}},{key:"clampExperiment",value:function(){return this.res.style.fontSize="clamp(1rem, calc(1rem * 10rem), 3rem)",this}},{key:"between",value:function(t){return"S1"===t&&(this.res.style.fontSize="clamp(2rem, 8vw, 2.5rem)"),"S2"===t&&(this.res.style.fontSize="clamp(4rem, 8vw, 5rem)"),"S3"===t&&(this.res.style.fontSize="clamp(2rem, 5vw, 2.5rem)"),"S4"===t&&(this.res.style.fontSize="clamp(1.5rem, 2vw, 1.6rem)"),"S5"===t&&(this.res.style.fontSize="clamp(1.2rem, 2vw, 1.3rem)"),"S6"===t&&(this.res.style.fontSize="clamp(1rem, 2vw, 1.3rem)"),this}},{key:"betweenCopy",value:function(t){return"S1"===t&&(this.res.style.fontSize="clamp(2rem, 8vw, 2.5rem)"),"S2"===t&&(this.res.style.fontSize="clamp(4rem, 8vw, 5rem)"),"S3"===t&&(this.res.style.fontSize="clamp(2rem, 5vw, 2.5rem)"),"S4"===t&&(this.res.style.fontSize="clamp(1.5rem, 2vw, 1.6rem)"),"S5"===t&&(this.res.style.fontSize="clamp(1.2rem, 2vw, 1.3rem)"),"S6"===t&&(this.res.style.fontSize="clamp(1rem, 2vw, 1.3rem)"),this}},{key:"stringGen",value:function(t){for(var e="",r=0;r<t;r++)e+="abcdefghijklmnopqrstuvwxyz".charAt(Math.floor(26*Math.random()));return e}},{key:"initLetter",value:function(t){var e=document.createElement("style");document.body.appendChild(e),Math.random();var r=this.stringGen(1e3);return this.res.setAttribute("id",r),document.styleSheets[0].insertRule("#".concat(r,"::first-letter { color: green; font-size: 3em; padding: 0.1em }"),0),this}},{key:"constant",value:function(t){return"S1"===t&&this.jumbotron(),"S2"===t&&this.large(),"S3"===t&&this.medium(),this}},{key:"minusMargin",value:function(){return this.res.style.marginRight="-3.1em",this}},{key:"fluid",value:function(t){if("S1"===t){this.res=document.createElement("h1");var e=document.createTextNode(this.text);this.res.appendChild(e),this.res.style.fontSize="calc(1.625rem + 4.3vw)"}if("S2"===t){this.res=document.createElement("h2");var r=document.createTextNode(this.text);this.res.appendChild(r),this.res.style.fontSize="calc(1.525rem + 3.525vw)"}if("S3"===t){this.res=document.createElement("h3");var n=document.createTextNode(this.text);this.res.appendChild(n),this.res.style.fontSize="calc(1.375rem + 2.75vw)"}if("S4"===t){this.res=document.createElement("h4");var i=document.createTextNode(this.text);this.res.appendChild(i),this.res.style.fontSize="calc(1.275rem + 1.975vw)"}return"S5"===t&&(this.res.style.fontSize="calc(1.1rem + 1.2vw)"),this}},{key:"getClampValue",value:function(t){return"S7"===t?"clamp(1.45rem, 2vw + 1.5rem, 1.69rem)":"S6"===t?"clamp(2.25rem, 2vw+1.5rem, 3.25rem)":"S5"===t?"clamp(2.75rem, 2vw + 1.5rem, 3.25rem)":"S4"===t?"clamp(3.5rem, 2vw + 1.5rem, 3.25rem)":"S3"===t?"clamp(4.25rem, 2vw + 1.5rem, 3.25rem)":"S2"===t?"clamp(5rem, 2vw + 1.5rem, 3.25rem)":"S1"===t?"clamp(6rem, 2vw + 1.5rem, 3.25rem)":void 0}},{key:"clampCopy",value:function(t){return this.res.style.fontSize=this.getClampValue(t),this}},{key:"fluidCopy",value:function(t){if(t instanceof Object){this.prevStylex=this.res.style,this.res=document.createElement("h1"),this.res.style.cssText=this.prevStylex.cssText;var e=document.createTextNode(this.text);return this.res.appendChild(e),this.res.style.fontSize=t.exact,this}if("S1"===t){this.prevStylex=this.res.style,this.res=document.createElement("h1"),this.res.style.cssText=this.prevStylex.cssText;var r=document.createTextNode(this.text);this.res.appendChild(r),this.res.style.fontSize="calc(1.625rem + 5.075vw)"}if("S2"===t){this.prevStylex=this.res.style,this.res=document.createElement("h2"),this.res.style.cssText=this.prevStylex.cssText;var n=document.createTextNode(this.text);this.res.appendChild(n),this.res.style.fontSize="calc(1.500rem + 4.3vw)"}if("S3"===t){this.prevStylex=this.res.style,this.res=document.createElement("h3"),this.res.style.cssText=this.prevStylex.cssText;var i=document.createTextNode(this.text);this.res.appendChild(i),this.res.style.fontSize="calc(1.375rem + 3.525vw)"}if("S4"===t){this.prevStylex=this.res.style,this.res=document.createElement("h4"),this.res.style.cssText=this.prevStylex.cssText;var o=document.createTextNode(this.text);this.res.appendChild(o),this.res.style.fontSize="calc(1.250rem + 2.75vw)"}if("S5"===t){this.prevStylex=this.res.style,this.res=document.createElement("h5"),this.res.style.cssText=this.prevStylex.cssText;var s=document.createTextNode(this.text);this.res.appendChild(s),this.res.style.fontSize="calc(1.125rem + 1.975vw)"}return"S6"===t&&(this.options&&!1===this.options.preffersId?this.html.push('<p class="'.concat(this.options.class,'">').concat(this.text,"</p> \n \n")):this.options&&this.options.id&&this.html.push('<p id="'.concat(this.options.id.substr(1),'">').concat(this.text,"</p> \n \n")),this.res.style.fontSize="calc(1rem + 0.5vw)"),this}},{key:"toReactComponent",value:function(){return this.react.push("function Godzilla() { \n"),this.react.push('return <h1 class="'.concat(this.options.class,'">').concat(this.text,"</h1> \n")),this.react.push("} \n \n"),this.react}},{key:"myself",value:function(t){var e=this,r=function(){window.matchMedia("(max-device-width: 415px)").matches?e.res.style.fontSize=t.desktop:e.res.style.fontSize=t.phone};return r(),window.addEventListener("resize",r),this}},{key:"jumbotron",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?t.res.style.fontSize="8rem":t.res.style.fontSize="6rem"};return e(),window.addEventListener("resize",e),this}},{key:"large",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?t.res.style.fontSize="7rem":t.res.style.fontSize="5rem"};return e(),window.addEventListener("resize",e),this}},{key:"frame",value:function(t){return this.res.style.width=t.width,this.res.style.height=t.height,this}},{key:"vw",value:function(t,e,r){}},{key:"responsive",value:function(t){var e=this;this.set=!1,this.setB=!1;var r=function(){window.innerWidth<t.minw?(e.setB=!1,e.set||(e.res.style.color="#3498db",e.res.style.fontSize="".concat(t.baseVW/100*window.innerWidth,"px"),e.set=!0)):window.innerWidth>t.maxw?(e.set=!1,e.setB||(e.res.style.color="orange",e.res.style.fontSize="".concat(t.baseVW/100*t.maxw,"px"),e.setB=!0)):(e.set=!1,e.setB=!1,e.res.style.color="black",e.res.style.fontSize="".concat(t.baseVW,"vw"))};return r(),window.addEventListener("resize",r),this}},{key:"xlarge",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?t.res.style.fontSize="6.5rem":t.res.style.fontSize="8.5rem"};return e(),window.addEventListener("resize",e),this}},{key:"medium",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?t.res.style.fontSize="2.25rem":t.res.style.fontSize="1.5em"};return e(),window.addEventListener("resize",e),this}},{key:"auto",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?t.res.style.fontSize="2rem":t.res.style.fontSize="1rem"};return e(),window.addEventListener("resize",e),this}},{key:"small",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?t.res.style.fontSize="1.5em":t.res.style.fontSize="1em"};return e(),window.addEventListener("resize",e),this}},{key:"sizes",value:function(t){var e=this;this.res.style.fontSize="".concat(t[0].size,"rem");var r=function(){for(var r=0;r<t.length;r++)t[r].width&&window.matchMedia("(min-width: ".concat(t[r].width,"px)")).matches&&(e.res.style.fontSize="".concat(t[r].size));window.matchMedia("(max-device-width: 415px)").matches&&(e.res.style.fontSize="".concat(t[t.length-1].mobile))};return r(),window.addEventListener("resize",r),this}},{key:"setup",value:function(t){var e;t?((e=document.createElement(t.type)).setAttribute("id",t.id),t.type):e=document.createElement("p");var r=document.createTextNode(this.text);return e.appendChild(r),this.res=e,this.res.style.padding=0,this.res.style.margin=0,this}},{key:"hide",value:function(){return this.res.style.visibility="hidden",this}},{key:"font",value:function(t){return this.res.style.fontFamily=t,this}},{key:"center",value:function(){return this.res.style.textAlign="center",this}},{key:"size",value:function(t){return this.res.style.fontSize=t,this}},{key:"em",value:function(t){return this.res.style.fontSize="".concat(t,"em"),this}},{key:"color",value:function(t){return this.res.style.color=t,this}},{key:"align",value:function(t){return this.res.style.textAlign="".concat(t),this}},{key:"weight",value:function(t){return this.res.style.fontWeight=t,this}},{key:"bold",value:function(){return this.res.style.fontWeight="bold",this}},{key:"italic",value:function(){return this.res.style.fontStyle="italic",this}},{key:"width",value:function(t,e){return this.res.style.width=t,e&&(this.res.style.marginLeft="auto",this.res.style.marginRight="auto"),this}},{key:"offset",value:function(t){return this.res.style.gridRow=2,this.res.style.gridColumn=2,this.res.style.marginLeft="-60px",this}},{key:"border",value:function(t,e){return this.res.style.border="".concat(e,"px solid ").concat(t),this}},{key:"padding",value:function(t,e,r,n){return(t||e||r||n)&&(this.res.style.paddingLeft=t,this.res.style.paddingTop=e,this.res.style.paddingRight=r,this.res.style.paddingBottom=n),e||r||n||(this.res.style.padding=t),this}},{key:"arrayPadding",value:function(t,e){return t.includes("left")&&(this.res.style.paddingLeft=e),t.includes("right")&&(this.res.style.paddingRight=e),t.includes("top")&&(this.res.style.paddingTop=e),t.includes("bottom")&&(this.res.style.paddingBottom=e),e||(this.res.style.paddingBottom=t),this}},{key:"margin",value:function(t,e){return"top"==t?this.res.style.marginTop=e:"bottom"==t?this.res.style.marginBottom=e:"left"==t?this.res.style.marginLeft=e:"right"==t&&(this.res.style.marginRight=e),this}},{key:"headline",value:function(){return this.em(4),this.font("Arial"),this.bold(),this}},{key:"caption",value:function(){return this.bold(),this.res.style.fontFamily="Arial",this.color("gray"),this.padding("top",20),this.res.style.fontSize="1em",window.matchMedia("(max-device-width: 415px)").matches?this.res.style.fontSize="2em":this.res.style.fontSize="1em",this}},{key:"updating",value:function(t,e){var r=this.res,n=this.text;return Object.defineProperty(t,e,{set:function(t){var e=document.createTextNode(n.replace("$",t));r.replaceChild(e,r.childNodes[0])}}),this}},{key:"style",value:function(t){return this.res.style.color=t.styles.color,this.res.style.fontWeight=t.styles.fontWeight,this.res.style.paddingLeft=t.styles.padding[0],this.res.style.paddingTop=t.styles.padding[1],this.res.style.paddingRight=t.styles.padding[2],this.res.style.paddingBottom=t.styles.padding[3],this.res.style.marginLeft=t.styles.margin[0],this.res.style.paddingTop=t.styles.margin[1],this.res.style.paddingRight=t.styles.margin[2],this.res.style.paddingBottom=t.styles.margin[3],this.res.style.opacity=t.styles.opacity,this}},{key:"applyStyle",value:function(t,e){return window.matchMedia("(max-width: ".concat(t,"px)")).matches&&Object.assign(this.res.style,e.styles),this}},{key:"nextApply",value:function(t){for(var e=this,r=[],n=(this.res.style,function(n){r[0].matches?Object.assign(e.res.style,t[0].styles):r[1].matches?Object.assign(e.res.style,t[1].styles):Object.assign(e.res.style,t[t.length-1].styles)}),i=0;i<t.length;i++){var o=t[i],s=window.matchMedia("(min-width: ".concat(o.min,"px) and (max-width: ").concat(o.max,"px)"));r.push(s),r[i].addListener(n)}return n(),this}},{key:"apply",value:function(t){var e=this,r=this.res.styles,n=function(){for(var n=0;n<t.length;n++){var i=t[n];i.min&&i.max?window.matchMedia("(min-width: ".concat(i.min,"px) and (max-width: ").concat(i.max,"px)")).matches?Object.assign(e.res.style,i.styles):(alert("YES min max, but does not match"),Object.assign(e.res.style,r)):window.matchMedia("(max-width: ".concat(i.max,"px)")).matches?Object.assign(e.res.style,i.styles):(alert("NO min max, and does not match"),Object.assign(e.res.style,r))}};return n(),window.addEventListener("resize",n),this}},{key:"render",value:function(t){if(!t)return this.res;this.options&&this.options.id&&this.res.setAttribute("id",this.options.id),document.querySelector(t).appendChild(this.res)}}],n&&p(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function S(t){return S="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},S(t)}function O(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function C(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,j(n.key),n)}}function j(t){var e=function(t){if("object"!=S(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=S(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==S(e)?e:e+""}function E(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(E=function(){return!!t})()}function T(t,e,r,n){var i=P(A(1&n?t.prototype:t),e,r);return 2&n&&"function"==typeof i?function(t){return i.apply(r,t)}:i}function P(){return P="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(t,e,r){var n=function(t,e){for(;!{}.hasOwnProperty.call(t,e)&&null!==(t=A(t)););return t}(t,e);if(n){var i=Object.getOwnPropertyDescriptor(n,e);return i.get?i.get.call(arguments.length<3?t:r):i.value}},P.apply(null,arguments)}function A(t){return A=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},A(t)}function R(t,e){return R=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},R(t,e)}var L=function(t){function e(t,r,n,i){var o;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(o=function(t,e,r){return e=A(e),function(t,e){if(e&&("object"==S(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,E()?Reflect.construct(e,r||[],A(t).constructor):e.apply(t,r))}(this,e)).url=t,o.res=null,o.code=[],o}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&R(t,e)}(e,t),r=e,n=[{key:"removeQuotesFromFirstWord",value:function(t){return t.replace(/"([^"]+)":/g,"$1:")}},{key:"setType",value:function(t){t.url;var e=t.type,r=t.mode;if(this.code=[],"exact"===e){var n='new Image("'.concat(this.url,'", "exact")');this.code.push(n)}else if("uncover"===e){var i='new Image("'.concat(this.url,'", "uncover")');this.code.push(i)}else this.code.push("new Image('".concat(this.url,"')"));return this.image(this.url,r,e),this}},{key:"flexOne",value:function(){return this.res.style.flex="1",this}},{key:"hand",value:function(){return this.res.style.cursor="hand",this}},{key:"setGridWithoutCode",value:function(){return this.res.style.border="1px solid white",this}},{key:"maxWidth",value:function(t){return this.res.style.maxWidth=t,this}},{key:"getHeight",value:function(){return this.res.height}},{key:"getWidth",value:function(){return this.res.width}},{key:"getType",value:function(){return"HTMLImageElement"}},{key:"toCode",value:function(){var t=this.options;this.res.style.border&&(t.border=this.res.style.border);var e=Object.fromEntries(Object.entries(t).filter((function(t){var e=function(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==e);l=!0);}catch(t){c=!0,i=t}finally{try{if(!l&&null!=r.return&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}(t,e)||function(t,e){if(t){if("string"==typeof t)return O(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?O(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(t,2);return e[0],null!==e[1]})));return["new Image().set(".concat(JSON.stringify(e,null,2).replace(/"(\w+)"\s*:/g,"$1:"),")")]}},{key:"formatObj",value:function(t){return JSON.stringify(t,null,2).replace(/"(\w+)"\s*:/g,"$1:")}},{key:"set",value:function(t){var r="";this.options=t;var n=t.isFull;if(n?this.image(t.url,"exact",n,"a"):this.setup(),t.url&&this.res.setAttribute("src",t.url),"exact"===n?'new Image("'.concat(this.url,'", "exact")'):"uncover"===n&&'new Image("'.concat(this.url,'", "uncover")'),t.vtn&&(this.res.style.viewTransitionName=t.vtn),this.vtn=t.vtn,t.minHeight&&(this.res.style.minHeight=t.minHeight),t.index&&T(e,"setIndex",this,3)([t.index]),t.index&&(this.index=t.index),t.index&&(r+='\n index: "'.concat(t.index,'",')),t.centerSelf&&(this.res.style.marginRight="auto",this.res.style.marginLeft="auto"),t.fitContent&&(this.res.style.width="100%",this.res.style.height="100%",this.res.style.marginRight="auto",this.res.style.marginTop="auto",this.res.style.objectFit="cover"),t.objectFit&&(this.res.style.objectFit=t.objectFit),t.objectFit&&(r+='\n objectFit: "'.concat(t.objectFit,'",')),t.as&&this.as(t.as),t.onScroll&&this.onScroll(t.onScroll),t.class&&this.res.setAttribute("class",t.class),t.gpos&&(this.gposObject=t.gpos),t.gpos&&(this.res.style.gridColumn=t.gpos.col,this.res.style.gridRow=t.gpos.row,r+="\n gpos: ".concat(this.removeQuotesFromFirstWord(JSON.stringify(t.gpos)),", ")),t.filtera){var i;i=Array.isArray(t.filtera)?c.filtera.filter((function(t){return"filter"===t.op.name}))[0]:t.filtera;var o=this.removeQuotesFromFirstWord(JSON.stringify(i));r+="\n filtera: ".concat(o,", \n")}if(t.keySet&&this.keySet(t.keySet),t.stype&&this.setType(t.stype),t.isBackground&&(this.isBackground=t.isBackground),t.zIndex&&(this.res.style.zIndex=t.zIndex),t.zIndex&&(r+='\n zIndex: "'.concat(t.zIndex,'", \n')),t.id&&this.res.setAttribute("id",t.id),t.id&&(r+=' id: "'.concat(t.id,'", \n')),this.id=t.id,t.area&&this.setArea(t.area),t.area&&(r+='area: "'.concat(t.area,'", \n')),t.opacity&&(this.res.style.opacity=t.opacity),t.width&&(this.res.style.width=t.width),t.width&&(r+='width: "'.concat(t.width,'", ')),t.maxWidth&&(this.res.style.maxWidth=t.maxWidth),t.maxWidth&&(r+='maxWidth: "'.concat(t.maxWidth,'", ')),t.height&&(this.res.style.height=t.height),t.height&&(r+='height: "'.concat(t.height,'", ')),t.multimargin&&this.makeMultiMargin(t.multimargin),t.multimargin&&(r+="multimargin: [ \n"),t.arrayMargin&&this.arrayMargin(t.arrayMargin.sides,t.arrayMargin.value),t.multimargin){for(var s=0;s<t.multimargin.length;s++){var a=t.multimargin[s];r+='{side: "'.concat(a.side,'", value: "').concat(a.value,'"}, \n')}r+="], \n"}if(t.maxWidth&&this.maxWidth(t.maxWidth),t.maxWidth&&(r+='maxWidth: "'.concat(t.maxWidth,'", \n')),t.radius&&this.cornerRadius(t.radius),t.radius&&(r+='radius: "'.concat(t.radius,'", \n')),t.marginOp){var l=this.removeQuotesFromFirstWord(JSON.stringify(t.marginOp));r+="\n marginOp: ".concat(l,",")}t.clipPath&&this.clipPath(t.clipPath),t.clipPath&&(r+='clipPath: "'.concat(t.clipPath,'", \n'));var c=t;if(c.stroke||c.gradient||c.span||c.backgroundOp||c.layout||c.marginOp||c.shadow||c.filtera||c.animation){c.gradient,c.gradient&&(this.globalGradient=c.gradient.op.gradient),c.stroke&&T(e,"setAny",this,3)([{globalBlast:"".concat(c.stroke.op.width," ").concat(c.stroke.op.color)}]);var u=[c.stroke,c.gradient,c.animation,c.span,c.backgroundOp,c.layout,c.marginOp,c.shadow,c.filtera,c.animation];u=u.filter((function(t){return null!=t}));var d=[];for(s=0;s<u.length;s++)d.push({range:u[s].range,log:u[s].op.name,target:u[s].target,op:u[s].op});this.chainReact(d,this.options.id)}if(c.shadow){var h=c.shadow,f=this.removeQuotesFromFirstWord(JSON.stringify(h));r+="\n shadow: ".concat(f,",")}if(c.animation){var y=c.animation,p=this.removeQuotesFromFirstWord(JSON.stringify(y));r+="\n animation: ".concat(p,",")}var m="\n .set({".concat(r,"}) \n \n");return Object.keys(t).length>0?this.code.push(m):this.code.push(","),this}},{key:"setFilter",value:function(t){var e=[],r=[t];r=r.filter((function(t){return null!=t}));for(var n=0;n<r.length;n++)e.push({range:r[n].range,log:r[n].op.name,target:r[n].target})}},{key:"makeMultiMargin",value:function(t){for(var e=0;e<t.length;e++)"left"===t[e].side&&(this.res.style.marginLeft=t[e].value),"right"===t[e].side&&(this.res.style.marginRight=t[e].value),"top"===t[e].side&&(this.res.style.marginTop=t[e].value),"bottom"===t[e].side&&(this.res.style.marginBottom=t[e].value);return this}},{key:"setID",value:function(t){return this.res.setAttribute("id",t),this}},{key:"square",value:function(){return this.res.style.width="30%",this.res.style.paddingBottom="30%",this}},{key:"opacity",value:function(t){return this.res.style.opacity="".concat(t),this}},{key:"rowCol",value:function(t,e){return this.res.style.gridRow=t,this.res.style.gridColumn=e,this}},{key:"setArea",value:function(t){return this.res.style.gridArea=t,this}},{key:"setGridRow",value:function(t){return this.res.style.gridRow=t,this}},{key:"setGridCol",value:function(t){return this.res.style.gridColumn=t,this}},{key:"setGrid",value:function(){return this.res.style.gridRow="span 2",this.res.style.gridColumn="span 3",this}},{key:"transform",value:function(t){return this.res.style.transform=t,this}},{key:"offset",value:function(){return this.res.style.marginLeft="-60px",this}},{key:"offseta",value:function(){return this.res.style.marginLeft="90px",this.res.style.marginTop="-30px",this}},{key:"borderAround",value:function(t){return this.res.style.border=t,this}},{key:"setClass",value:function(t){return this.res.setAttribute("class",t),this}},{key:"scale",value:function(t){var e=this;return this.res.style.width,this.res.style.transition="0.5s all",this.res.addEventListener("mouseover",(function(){e.res.style.width,e.res.style.transform="scale(1.04)"})),this.res.addEventListener("mouseout",(function(){e.res.style.width,e.res.style.transform="scale(1.0)"})),this}},{key:"onTap",value:function(t){return this.res.addEventListener("click",t),this}},{key:"border",value:function(t){return this.res.style.borderTopLeftRadius="16px",this.res.style.borderTopRightRadius="16px",this}},{key:"allRound",value:function(t){return this.res.style.borderRadius=t,this}},{key:"mobileWidth",value:function(){return window.matchMedia("(max-device-width: 415px)").matches&&(this.res.style.width="120%"),this}},{key:"image",value:function(t,e,r,n,i){var o=window.matchMedia("(max-device-width: 415px)"),s=document.createElement("div");return s.style.viewTransitionName=n,s.style.width="100%",s.style.height="200",i&&(s.style.gridColumn=i.gridColumn,s.style.gridRow=i.gridRow),o.matches&&(s.style.height="500"),s.style.backgroundImage="url(".concat(t,")"),s.style.backgroundPosition="center center",s.style.backgroundRepeat="no-repeat",s.style.backgroundSize="cover","uncover"===r&&(s.style.backgroundSize="contain"),"contain"===e&&(s.style.backgroundSize="contain"),this.res=s,this}},{key:"arrayPadding",value:function(t,e){return t.includes("left")&&(this.res.style.paddingLeft=e),t.includes("right")&&(this.res.style.paddingRight=e),t.includes("top")&&(this.res.style.paddingTop=e),t.includes("bottom")&&(this.res.style.paddingBottom=e),this}},{key:"arrayMargin",value:function(t,e){return t.includes("left")&&(this.res.style.marginLeft=e),t.includes("right")&&(this.res.style.marginRight=e),t.includes("top")&&(this.res.style.marginTop=e),t.includes("bottom")&&(this.res.style.marginBottom=e),this}},{key:"setup",value:function(){var t=document.createElement("img");return t.style.width="100%",t.src=this.url,this.res=t,this}},{key:"autoW",value:function(){return this.res.style.width="initial",this}},{key:"float",value:function(t){return this.res.style.float="".concat(t),this}},{key:"fillAvailable",value:function(){return this.res.style.height="-webkit-fill-available",this}},{key:"grayscale",value:function(t){return this.res.style.filter="grayscale(".concat(t,"%)"),this}},{key:"flex",value:function(t){return this.res.style.flex=1,this}},{key:"height",value:function(t){return this.res.style.height=t,this.res.style.width="auto",this}},{key:"expand",value:function(t){var e=this,r=function(){var r,n;if(window.matchMedia("(min-width: ".concat(t.at,")")).matches){e.res.style.width="".concat(t.width);var i=window.innerWidth/2-(n=r=t.width,(r.includes("%")||r.includes("px"))&&(n=n.substr(0,2)),(r.includes("%")?Number(n/100*window.innerWidth):r.includes("px")?Number(n):void 0)/2);e.res.style.marginLeft="".concat(i,"px")}else e.res.style.width="100%",e.res.style.marginLeft="0px";window.matchMedia("(max-device-width: 415px)").matches&&(e.res.style.width="100%",e.res.style.marginLeft="0px")};return r(),window.addEventListener("resize",r),this}},{key:"width",value:function(t){return this.res.style.width=t,this.res.style.height="auto",this}},{key:"toBack",value:function(){return this.res.style.zIndex="-1",this}},{key:"margin",value:function(t,e,r,n){return(t||e||r||n)&&(this.res.style.marginLeft=t,this.res.style.marginTop=e,this.res.style.marginRight=r,this.res.style.marginBottom=n),e||r||n||0===e&&0===r&&0===n||(this.res.style.margin=t),this}},{key:"padding",value:function(t){return this.res.style.padding=t,this}},{key:"size",value:function(t,e){return t&&e?(this.res.style.width=t,this.res.style.height=e):(this.res.style.width=t,this.res.style.height=t),this}},{key:"frame",value:function(t){var e=t.width,r=t.height;return e&&r?(this.res.style.width=e,this.res.style.height=r):(this.res.style.width=e,this.res.style.height=e),this}},{key:"RSize",value:function(t,e,r){var n=window.matchMedia("(max-device-width: 420px)");return t&&e?(this.res.style.width=n.matches?t*r:t,this.res.style.height=n.matches?e*r:e):(this.res.style.width=n.matches?t*r:t,this.res.style.height=n.matches?t*r:t),this}},{key:"shadow",value:function(t){return"mild"===t.type?this.res.style.boxShadow="0px 3px 15px rgba(0,0,0,0.2)":this.res.style.boxShadow="".concat(t.x,"px ").concat(t.y,"px ").concat(t.radius,"px ").concat(t.color),this}},{key:"clipShape",value:function(t){return this.res.style.borderRadius="50%",this}},{key:"cornerRadius",value:function(t){return this.res.style.borderRadius=t,this}},{key:"clipPath",value:function(t){this.res.style.clipPath='path("'.concat(t,'")');var e=document.createElementNS("http://www.w3.org/2000/svg","svg");return e.style.display="block",e.style.width="100%",e.style.height="100%",e.style.overflow="visible",this}},{key:"render",value:function(t){var e=this.res;if(!t)return e;document.querySelector(t).appendChild(e)}}],n&&C(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function z(t){return z="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},z(t)}function M(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,I(n.key),n)}}function I(t){var e=function(t){if("object"!=z(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=z(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==z(e)?e:e+""}function B(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(B=function(){return!!t})()}function N(t,e,r,n){var i=W(_(1&n?t.prototype:t),e,r);return 2&n&&"function"==typeof i?function(t){return i.apply(r,t)}:i}function W(){return W="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(t,e,r){var n=function(t,e){for(;!{}.hasOwnProperty.call(t,e)&&null!==(t=_(t)););return t}(t,e);if(n){var i=Object.getOwnPropertyDescriptor(n,e);return i.get?i.get.call(arguments.length<3?t:r):i.value}},W.apply(null,arguments)}function _(t){return _=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},_(t)}function F(t,e){return F=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},F(t,e)}var D=function(t){function e(t,r,n){var i;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(i=function(t,e,r){return e=_(e),function(t,e){if(e&&("object"==z(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,B()?Reflect.construct(e,r||[],_(t).constructor):e.apply(t,r))}(this,e)).link=r,i.text=t,i.code=[],i.css=[],i.elCSS=[],i.html=[],i.res=null,i.stopEM=n,i.setup(),i.inlineBlock(),i}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&F(t,e)}(e,t),r=e,(n=[{key:"toCSS",value:function(){return this.css}},{key:"toHTMLA",value:function(){return this.html}},{key:"toElCSS",value:function(){return this.preffersId?this.elCSS.unshift(this.res.id+" { \n"):this.elCSS.unshift("."+this.class+" { \n"),this.elCSS.push(" } \n \n"),this.elCSS}},{key:"getType",value:function(){return"HTMLAnchorElement"}},{key:"toCode",value:function(){return this.code}},{key:"setArea",value:function(t){return this.res.style.gridArea=t,this}},{key:"setup",value:function(){var t=document.createElement("a");t.setAttribute("href",this.link),t.style.textDecoration="none",t.style.color="black",t.style.textAlign="center",t.style.fontFamily="Arial";var e=document.createTextNode(this.text);return t.appendChild(e),this.res=t,!1===this.stopEM&&this.em(1),this}},{key:"appendImageAsChild",value:function(t,e){var r=document.createElement("a");t.options.vtn&&(r.style.viewTransitionName=t.options.vtn),r.setAttribute("href",t.options.url);var n=document.createElement("img");return t.options&&(n.style.width=t.options.size,t.options.radius&&(n.style.borderRadius=t.options.radius),n.setAttribute("src",t.options.img),r.appendChild(n)),this.res=r,e&&(this.res.style.marginLeft=e),this}},{key:"addIcon",value:function(t){var e=document.createElement("img");return e.style.width="20px",e.style.height="auto",e.style.marginLeft=t.padding?t.padding:"10px",e.setAttribute("src",t.url),this.res.appendChild(e),this}},{key:"removeQuotesFromFirstWord",value:function(t){if(t)return t.replace(/"([^"]+)":/g,"$1:")}},{key:"set",value:function(t){this.elCSS.push("text-decoration: none; \n"),this.options=t;var r="";t.id&&this.res.setAttribute("id",t.id),t.id&&N(e,"setID",this,3)([t.id]),t.pad&&this.pad(t.pad);var n=this.removeQuotesFromFirstWord(JSON.stringify(t.pad));if(t.pad&&(r+="\n pad: ".concat(n,",")),t.preffersId&&(this.preffersId=t.preffersId),null!=t.preffersId&&(r+="\n preffersId: ".concat(t.preffersId,",")),t.class&&N(e,"setClass",this,3)([t.class]),t.class&&(r+='\n class: "'.concat(t.class,'",')),t.borderObj){this.res.style.border="".concat(t.borderObj.width," solid ").concat(t.borderObj.color),this.res.style.borderRadius="".concat(t.borderObj.radius);var i=this.removeQuotesFromFirstWord(JSON.stringify(t.borderObj));r+="\n borderObj: ".concat(i,",")}if(!1===this.options.preffersId?this.html.push('<a class="'.concat(t.class,'" href="#hello">').concat(t.text,"</a> \n \n")):t.id&&this.html.push('<a id="'.concat(t.id.substr(1),'" href="#hello">').concat(t.text,"</a> \n \n")),null!=t.blastData){var o=this.removeQuotesFromFirstWord(JSON.stringify(t.blastData));N(e,"setAny",this,3)([{globalBlast:"1px ".concat(t.blastData.color)}]),t.blastData&&(r+="\n blastData: ".concat(o,","))}t.nowrap&&(this.res.style.whiteSpace="nowrap"),t.font&&this.font(t.font),t.font&&(r+='\n font: "'.concat(t.font,'",')),t.font&&this.elCSS.push('font-family: "'.concat(t.font,'"; \n')),t.fluidc&&this.fluidCopy(t.fluidc),t.fluidc&&(r+='\n fluidc: "'.concat(t.fluidc,'",')),t.size&&this.fluidCopy(t.size),t.size&&(r+='\n size: "'.concat(t.size,'",')),"S6"===t.fluidc?t.fluidc&&this.elCSS.push("font-size: calc(1rem + 1.075vw); \n"):t.fluidc&&this.elCSS.push("font-size: calc(1.625rem + 5.075vw); \n"),t.clampc&&this.clampCopy(t.clampc),this.options.id&&(r+='\n id: "'.concat(this.options.id,'",')),t.align&&this.leftAlign(),t.align&&(r+='\n align: "'.concat(t.align,'",')),t.type&&(this.res.style.display="block"),t.color&&this.color(t.color),t.color&&(r+='\n color: "'.concat(t.color,'",')),t.color&&this.elCSS.push('color: "'.concat(t.color,'"; \n')),t.background&&this.background(t.background);var s=this.removeQuotesFromFirstWord(JSON.stringify(t.background));t.background&&(r+="\n background: ".concat(s,",")),t.hover&&this.hover(t.hover);var a=this.removeQuotesFromFirstWord(JSON.stringify(t.hover));if(t.hover&&(r+="\n hover: ".concat(a,",")),t.weight&&(this.res.style.fontWeight=t.weight),t.blast&&(this.blastData=t.blast),t.bold&&(this.res.style.fontWeight="bold"),t.bold&&(r+="\n bold: ".concat(t.bold,",")),t.block&&this.toBlock(),t.block&&(r+="\n block: ".concat(t.block,",")),t.radius&&this.radius(t.radius),t.radius&&(r+='\n radius: "'.concat(t.radius,'",')),t.width&&this.width(t.width),t.width&&(r+='\n width: "'.concat(t.width,'",')),t.arrayPadding){var l=t.arrayPadding.sides.map((function(t){return'"'.concat(t,'"')})).join(", ");t.arrayPadding&&this.arrayPadding(t.arrayPadding.sides,t.arrayPadding.value),t.arrayPadding&&(r+="\n arrayPadding: {sides: [".concat(l,'], value: "').concat(t.arrayPadding.value,'"},'))}if(t.arrayMargin&&this.arrayMargin(t.arrayMargin.sides,t.arrayMargin.value),t.arrayMargin&&(r+="\n arrayMargin: {sides: [".concat(t.arrayMargin.sides.map((function(t){return'"'.concat(t,'", ')})),'], value: "').concat(t.arrayMargin.value,'"},')),t.maxWidth&&this.maxWidth(t.maxWidth),t.url&&this.res.setAttribute("href",t.url),r+='\n url: "'.concat(t.url,'",'),t.text&&(this.res.textContent=t.text),r+='\n text: "'.concat(t.text,'",'),t.data){t.data&&this.appendImageAsChild(t.data,"20px");var c=this.removeQuotesFromFirstWord(JSON.stringify(t.data));t.data&&(r+="\n data: ".concat(c))}if(t.icon){this.addIcon(t.icon);var u=this.removeQuotesFromFirstWord(JSON.stringify(t.icon));r+="\n icon: ".concat(u,",")}if(t.shadow){var d=t.shadow,h=this.removeQuotesFromFirstWord(JSON.stringify(d));r+="\n shadow: ".concat(h,",")}if(t.stroke){var f=this.removeQuotesFromFirstWord(JSON.stringify(t.stroke));t.stroke&&(r+="\n stroke: ".concat(f,","))}if(t.backgroundOp){var y=this.removeQuotesFromFirstWord(JSON.stringify(t.backgroundOp));r+="\n backgroundOp: ".concat(y,",")}if(t.marginOp){var p=this.removeQuotesFromFirstWord(JSON.stringify(t.marginOp));r+="\n marginOp: ".concat(p,",")}if(t.gradient){var m=this.removeQuotesFromFirstWord(JSON.stringify(t.gradient));r+="\n gradient: ".concat(m,",")}if(t.animation){var v=this.removeQuotesFromFirstWord(JSON.stringify(t.animation));r+="\n animation: ".concat(v,",")}if(t.transform){var b=this.removeQuotesFromFirstWord(JSON.stringify(t.transform));r+="\n transform: ".concat(b,",")}var g="new Link().set({".concat(r,"}) \n");this.code.push(g),t.color&&this.color(t.color),t.rounded&&this.round(),t.transform&&t.transform.transform?this.reactOnTransform(t.transform):this.reactOnTransform(t);var w=[],k=[t.border,t.gradient,t.animation,t.span,t.shadow,t.backgroundOp,t.animation];if((k=k.filter((function(t){return null!=t}))).length>0){for(var x=0;x<k.length;x++)w.push({range:k[x].range,log:k[x].op.name,target:k[x].target,op:k[x].op});var S=[];t.borderObj&&S.push("border"),t.background&&S.push("background"),t.mar&&S.push("margin"),t.animation&&S.push("animation"),this.chainReact(w,t.id,S,t.isNavA),this.res.style.zIndex=1}return t.mar&&this.mar(t.mar),this}},{key:"color",value:function(t){return this.res.style.color=t,this}},{key:"maxWidth",value:function(t){return this.res.style.maxWidth=t,this}},{key:"background",value:function(t){return this.res.style.backgroundColor=t,this}},{key:"leftAlign",value:function(){return this.res.style.textAlign="left",this}},{key:"arrayPadding",value:function(t,e){return e||(this.res.style.marginLeft="".concat(t[0],"px"),this.res.style.marginTop="".concat(t[1],"px"),this.res.style.marginRight="".concat(t[2],"px"),this.res.style.marginBottom="".concat(t[3],"px")),"all"===t[0]&&(this.res.style.paddingLeft=e,this.res.style.paddingTop=e,this.res.style.paddingRight=e,this.res.style.paddingBottom=e),t.includes("left")&&(this.res.style.paddingLeft=e),t.includes("right")&&(this.res.style.paddingRight=e),t.includes("top")&&(this.res.style.paddingTop=e),t.includes("bottom")&&(this.res.style.paddingBottom=e),e||(this.res.style.paddingBottom=t),this}},{key:"arrayMargin",value:function(t,e){return t.includes("left")&&(this.res.style.marginLeft=e),t.includes("right")&&(this.res.style.marginRight=e),t.includes("top")&&(this.res.style.marginTop=e),t.includes("bottom")&&(this.res.style.marginBottom=e),t.includes("all")&&(this.res.style.margin=e),e||(this.res.style.marginBottom=t),this}},{key:"getClampValue",value:function(t){return"S6"===t?"clamp(2.25rem, 2vw+1.5rem, 3.25rem)":"S5"===t?"clamp(2.75rem, 2vw + 1.5rem, 3.25rem)":"S4"===t?"clamp(3.5rem, 2vw + 1.5rem, 3.25rem)":"S3"===t?"clamp(4.25rem, 2vw + 1.5rem, 3.25rem)":"S2"===t?"clamp(5rem, 2vw + 1.5rem, 3.25rem)":"S1"===t?"clamp(6rem, 2vw + 1.5rem, 3.25rem)":void 0}},{key:"clampCopy",value:function(t){return this.res.style.fontSize=this.getClampValue(t),this}},{key:"fluidCopy",value:function(t){return"S1"===t&&(this.res.style.fontSize="calc(1.625rem + 5.075vw)"),"S2"===t&&(this.res.style.fontSize="calc(1.500rem + 4.3vw)"),"S3"===t&&(this.res.style.fontSize="calc(1.375rem + 3.525vw)"),"S4"===t&&(this.res.style.fontSize="calc(1.250rem + 2.75vw)"),"S5"===t&&(this.res.style.fontSize="calc(1.125rem + 1.975vw)"),"S6"===t&&(this.res.style.fontSize="calc(1rem + 0.5vw)"),this}},{key:"inlineBlock",value:function(){return this.res.style.display="inline-block",this}},{key:"toBlock",value:function(){return this.res.style.display="block",this}},{key:"myself",value:function(t){var e=this,r=function(){window.matchMedia("(max-device-width: 415px)").matches?e.res.style.fontSize=t.desktop:e.res.style.fontSize=t.phone};return r(),window.addEventListener("resize",r),this}},{key:"style",value:function(t){return this.res.style.color=t.styles.color,this.res.style.fontWeight=t.styles.fontWeight,this.res.style.paddingLeft=t.styles.padding[0],this.res.style.paddingTop=t.styles.padding[1],this.res.style.paddingRight=t.styles.padding[2],this.res.style.paddingBottom=t.styles.padding[3],this}},{key:"round",value:function(){return this.res.style.borderRadius="0.5rem",this.options.rounded&&(this.res.children[0].style.borderRadius="0.5rem"),this}},{key:"newWindow",value:function(){return this.res.target="_new",this}},{key:"radius",value:function(t){return this.res.style.borderRadius="".concat(t),this}},{key:"transition",value:function(t){return this.res.style.transition="".concat(t,"s ease-in-out"),this.res.style.transionProperty="background, color",this}},{key:"width",value:function(t){return this.res.style.width=t,this}},{key:"italic",value:function(){return this.res.style.fontStyle="italic",this}},{key:"padding",value:function(t,e,r,n){return t&&e&&r&&n?(this.res.style.paddingLeft=t,this.res.style.paddingTop=e,this.res.style.paddingRight=r,this.res.style.paddingBottom=n):this.res.style.padding=t,this}},{key:"medium",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?t.res.style.fontSize="2rem":t.res.style.fontSize="1.5em"};return e(),window.addEventListener("resize",e),this}},{key:"opacity",value:function(t){return this.res.style.opacity=t,this}},{key:"margin",value:function(t,e,r,n){return this.res.style.marginTop=t,this.res.style.marginLeft=e,this.res.style.marginRight=r,this.res.style.marginBottom=n,this}},{key:"hover",value:function(t){var e=this;if(t.border){var r=t.border.width;this.res.style.border=r?"".concat(r,"px solid transparent"):"1px solid transparent"}var n=this.options.borderObj;return n&&(this.res.style.border="".concat(n.width,"px solid ").concat(n.color)),this.prevColor=this.res.style.backgroundColor,this.foreColor=this.res.style.color,this.prevBorder=this.res.style.border,t.animation&&(this.res.style.transition="".concat(t.animation),this.res.style.transionProperty="background, color"),this.res.onmouseout=function(){e.res.style.backgroundColor="".concat(e.prevColor),e.res.style.color="".concat(e.foreColor),e.res.style.border=e.prevBorder},this.res.onmouseover=function(){if(e.res.style.color=t.color,e.res.style.backgroundColor=t.background,t.border){var r,n=t.border.width,i=null!==(r=t.border.color)&&void 0!==r?r:"#2ECC71";e.res.style.border=n?"".concat(n,"px solid ").concat(i):"1px solid #2ECC71"}},this}},{key:"em",value:function(t){var e=this,r=window.matchMedia("(max-device-width: 415px)"),n=function(){r.matches?e.res.style.fontSize="2em":e.res.style.fontSize="1em"};return n(),window.addEventListener("resize",n),this}},{key:"font",value:function(t){return this.res.style.fontFamily=t,this}},{key:"render",value:function(t){return t?(document.querySelector(t).appendChild(this.res),this):this.res}}])&&M(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function H(t){return H="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},H(t)}function J(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,q(n.key),n)}}function q(t){var e=function(t){if("object"!=H(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=H(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==H(e)?e:e+""}function G(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(G=function(){return!!t})()}function Q(){return Q="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(t,e,r){var n=function(t,e){for(;!{}.hasOwnProperty.call(t,e)&&null!==(t=X(t)););return t}(t,e);if(n){var i=Object.getOwnPropertyDescriptor(n,e);return i.get?i.get.call(arguments.length<3?t:r):i.value}},Q.apply(null,arguments)}function X(t){return X=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},X(t)}function $(t,e){return $=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},$(t,e)}var Y=function(t){function e(){var t;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(t=function(t,e,r){return e=X(e),function(t,e){if(e&&("object"==H(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,G()?Reflect.construct(e,r||[],X(t).constructor):e.apply(t,r))}(this,e)).navbar=document.createElement("nav"),t.navbar.classList.add("desktop-navbar"),t.navbarHeader=document.createElement("div"),t.navbarHeader.classList.add("navbar-header"),t.brand=document.createElement("div"),t.brand.classList.add("navbar-brand"),t.navContent=document.createElement("div"),t.navContent.classList.add("navbar-content"),t.navContent.style.width="100%",t.navbarHeader.appendChild(t.brand),t.navbarHeader.appendChild(t.navContent),t.navbar.appendChild(t.navbarHeader),t.res=t.navbar,t}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&$(t,e)}(e,t),r=e,n=[{key:"set",value:function(t){var r,n,i;return console.warn(t),this.obj=t,t.background&&(this.res.style.backgroundColor=t.background),t.mar&&(r=e,n=this,"function"==typeof(i=Q(X(1&3?r.prototype:r),"mar",n))?function(t){return i.apply(n,t)}:i)([t.mar]),t.brand&&this.setBrand(t.brand),t.radius&&(this.res.style.borderRadius=t.radius),t.maxHeight&&(this.res.style.maxHeight=t.maxHeight),t.hamburgerColour&&(this.hamburgerColour=t.hamburgerColour),this.setStyles(),this}},{key:"setStyles",value:function(){this.navbar.style.display="flex",this.navbar.style.flexDirection="column",this.navbar.style.padding="1rem",this.navbar.style.backgroundColor="#333",this.navbar.style.color="white",this.navbarHeader.style.display="flex",this.navbarHeader.style.alignItems="center",this.navbarHeader.style.justifyContent="space-between",this.navbarHeader.style.width="100%",this.brand.style.fontSize="1.5rem",this.navContent.style.display="flex",this.navContent.style.gap="1rem"}},{key:"setBrand",value:function(t){return console.warn("SETA"),console.log(t),this.brand.innerHTML="",this.brand.appendChild(t),this}},{key:"add",value:function(t){this.items=t;for(var e=0;e<t.length;e++)t[e],this.navContent.appendChild(t[e].render());return this}},{key:"toCode",value:function(){console.warn(this.items);var t=this.items.map((function(t){return t.toCode()})).flatMap((function(t){return t}));return console.log("ITSA"),console.log(t),console.log("".concat(t.join(","))),"new DesktopBar().set(".concat(this.removeQuotesFromFirstWord(JSON.stringify(this.obj)),").add([\n ").concat(t.join(","),"\n\n \n \n\n ])")}},{key:"render",value:function(t){return t&&document.querySelector(t).appendChild(this.navbar),this.navbar}}],n&&J(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function V(t){return V="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},V(t)}function U(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,K(n.key),n)}}function K(t){var e=function(t){if("object"!=V(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=V(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==V(e)?e:e+""}function Z(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(Z=function(){return!!t})()}function tt(){return tt="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(t,e,r){var n=function(t,e){for(;!{}.hasOwnProperty.call(t,e)&&null!==(t=et(t)););return t}(t,e);if(n){var i=Object.getOwnPropertyDescriptor(n,e);return i.get?i.get.call(arguments.length<3?t:r):i.value}},tt.apply(null,arguments)}function et(t){return et=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},et(t)}function rt(t,e){return rt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},rt(t,e)}var nt=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e,r){return e=et(e),function(t,e){if(e&&("object"==V(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,Z()?Reflect.construct(e,r||[],et(t).constructor):e.apply(t,r))}(this,e)}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&rt(t,e)}(e,t),r=e,n=[{key:"removeQuotesFromBoth",value:function(t){if(t)return t.replace(/"([^"]+)":\s*"([^"]+)"/g,"$1: $2")}},{key:"removeQuotesFromFirstWord",value:function(t){if(t)return t.replace(/"([^"]+)":/g,"$1:")}},{key:"toCode",value:function(){console.warn(this.items);var t=this.items.map((function(t){return t.toCode()})).flatMap((function(t){return t}));console.log("BAD CONV"),console.log(this.removeQuotesFromFirstWord(JSON.stringify(this.obj,null,4)));var e=this.removeQuotesFromFirstWord(JSON.stringify(this.obj));console.log(e),console.log("REPL"),console.log(e);var r='\nbackground: "'.concat(this.obj.background,'",\nbrand: ').concat(this.obj.brand.toCode(),",\nmar: ").concat(JSON.stringify(this.obj.mar),",\npad: ").concat(JSON.stringify(this.obj.mar),",\nradius: ").concat(JSON.stringify(this.obj.radius),",\n");return"new MobileBar().set({".concat(r,"}).add([\n ").concat(t.join(","),"\n\n ])")}},{key:"set",value:function(t){var r,n,i;return this.obj=t,console.log("After passing to set:"),console.log("OBJ IN SET"),this.obj=t,this.makeNavbar(t),t.mar&&(r=e,n=this,"function"==typeof(i=tt(et(1&3?r.prototype:r),"mar",n))?function(t){return i.apply(n,t)}:i)([t.mar]),t.maxHeight&&(this.res.style.maxHeight=t.maxHeight),t.radius&&(this.res.style.borderRadius=t.radius),t.hamburgerColour&&(this.hamburgerColour=t.hamburgerColour),this.setStyles(t),this}},{key:"makeNavbar",value:function(t){var e=this;console.log("OBJ IN SETA");var r=t.brand;this.navbar=document.createElement("nav"),this.navbar.classList.add("mobile-navbar"),this.navbarHeader=document.createElement("div"),this.navbarHeader.classList.add("navbar-header"),this.brand=document.createElement("div"),this.brand.classList.add("navbar-brand"),console.log("BRIS"),console.log("APPENDED-"),t.brand&&"function"==typeof r.render?(console.log("Appending brand:",r.render()),this.brand.appendChild(r.render())):console.warn("Brand does not have a valid render method:",t.brand),this.toggleButton=document.createElement("button"),this.toggleButton.classList.add("navbar-toggle"),this.toggleButton.innerHTML="☰",this.navContent=document.createElement("div"),this.navContent.classList.add("navbar-content"),this.navbarHeader.appendChild(this.brand),this.navbarHeader.appendChild(this.toggleButton),this.navbar.appendChild(this.navbarHeader),this.navbar.appendChild(this.navContent),this.isMobileNavOpen=!1,this.toggleButton.addEventListener("click",(function(){e.toggleMobileNav()})),this.res=this.navbar}},{key:"setStyles",value:function(t){var e,r;this.navbar.style.display="flex",this.navbar.style.flexDirection="column",this.navbar.style.padding="1rem",this.navbar.style.backgroundColor=null!==(e=t.background)&&void 0!==e?e:"orange",this.navbarHeader.style.display="flex",this.navbarHeader.style.alignItems="center",this.navbarHeader.style.justifyContent="space-between",this.navbarHeader.style.width="100%",this.brand.style.fontSize="1.5rem",this.toggleButton.style.background="none",this.toggleButton.style.border="none",this.toggleButton.style.color=null!==(r=this.hamburgerColour)&&void 0!==r?r:"white",this.toggleButton.style.fontSize="1.5rem",this.toggleButton.style.cursor="pointer",this.navContent.style.display="none"}},{key:"add",value:function(t){console.log(t),this.items=t;for(var e=0;e<t.length;e++){var r=t[e];this.navContent.appendChild(r.render())}return this}},{key:"toggleMobileNav",value:function(){this.isMobileNavOpen=!this.isMobileNavOpen,this.navContent.style.display=this.isMobileNavOpen?"flex":"none",this.isMobileNavOpen?(this.navContent.style.flexDirection="column",this.navContent.style.gap="0.5rem",this.navContent.style.padding="1rem"):(this.navContent.style.flexDirection="",this.navContent.style.gap="",this.navContent.style.backgroundColor="",this.navContent.style.padding="")}},{key:"render",value:function(t){return t&&document.querySelector(t).appendChild(this.navbar),this.navbar}}],n&&U(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function it(t){return it="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},it(t)}function ot(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function st(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?ot(Object(r),!0).forEach((function(e){at(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):ot(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function at(t,e,r){return(e=ct(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function lt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,ct(n.key),n)}}function ct(t){var e=function(t){if("object"!=it(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=it(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==it(e)?e:e+""}function ut(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(ut=function(){return!!t})()}function dt(t){return dt=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},dt(t)}function ht(t,e){return ht=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},ht(t,e)}var ft=function(t){function e(){var t;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(t=function(t,e,r){return e=dt(e),function(t,e){if(e&&("object"==it(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,ut()?Reflect.construct(e,r||[],dt(t).constructor):e.apply(t,r))}(this,e)).breakpoints=[],t.container=null,t.currentView=null,t.internalDiv=null,t.resizeListener=null,t}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&ht(t,e)}(e,t),r=e,n=[{key:"set",value:function(t){var e=t.breakpoints;if(this.options={breakpoints:e},!Array.isArray(e))throw new Error("Breakpoints should be an array of objects with 'at' and 'view' properties.");return this.breakpoints=e.map((function(t){if("string"!=typeof t.at||!(t.view.render()instanceof HTMLElement))throw new Error("Each breakpoint must have 'at' as a string and 'view' as an HTMLElement.");return st(st({},t),{},{at:parseInt(t.at,10)})})),this.breakpoints.sort((function(t,e){return t.at-e.at})),this}},{key:"toCode",value:function(){JSON.stringify(this.options.breakpoints.map((function(t){return t.view.toCode()})).flat(),null,4),JSON.stringify(this.options.breakpoints.map((function(t){return t.at})),null,4),JSON.stringify(this.options.breakpoints,null,4);for(var t="",e=0;e<this.options.breakpoints.length;e++)t+='{ at: "'.concat(this.options.breakpoints[e].at,'", view: ').concat(this.options.breakpoints[e].view.toCode()," }, \n");return["new Switcher().set({\n breakpoints: [\n ".concat(t,"\n ]\n })")]}},{key:"render",value:function(t){return this.internalDiv=document.createElement("div"),this.applyView(),this.resizeListener=this.applyView.bind(this),window.addEventListener("resize",this.resizeListener),void 0!==t&&document.querySelector(t).appendChild(this.internalDiv),this.internalDiv}},{key:"createRanges",value:function(t){for(var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:99999,r=[],n=0;n<t.length;n++)r.push({from:t[n],to:n<t.length-1?t[n+1]-1:e});return r}},{key:"addRanges",value:function(t,e){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:99999;return t.map((function(t,n){var i=e[n],o=n<e.length-1?e[n+1]-1:r;return st(st({},t),{},{range:{from:i,to:o}})}))}},{key:"applyView",value:function(){var t=this;console.log("MAKE RANGES"),window.innerWidth,console.log(this.breakpoints),console.log(this.breakpoints.map((function(t){return t.at})));var e=this.breakpoints.map((function(t){return t.at})),r=this.breakpoints.map((function(t){return t.at})),n=(this.createRanges(r),this.addRanges(this.breakpoints,e));console.log(n),n.forEach((function(e){var r="(min-width: ".concat(e.range.from,"px) and (max-width: ").concat(e.range.to,"px)"),n=window.matchMedia(r);console.warn(r),n.matches&&(console.log("Viewport width is within the range: ".concat(e.range.from,"px to ").concat(e.range.to,"px")),t.currentView!==e.view.render()&&(t.internalDiv.innerHTML="",t.internalDiv.appendChild(e.view.render()),t.currentView=e.view.render()))})),console.log("MBO")}},{key:"destroy",value:function(){this.resizeListener&&(window.removeEventListener("resize",this.resizeListener),this.resizeListener=null),this.internalDiv&&this.container&&this.container.removeChild(this.internalDiv),this.container=null,this.currentView=null,this.internalDiv=null}}],n&<(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function yt(t){return yt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},yt(t)}function pt(t,e){if(t){if("string"==typeof t)return mt(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?mt(t,e):void 0}}function mt(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function vt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,bt(n.key),n)}}function bt(t){var e=function(t){if("object"!=yt(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=yt(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==yt(e)?e:e+""}function gt(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(gt=function(){return!!t})()}function wt(t){return wt=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},wt(t)}function kt(t,e){return kt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},kt(t,e)}var xt=function(t){function e(){var t;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(t=function(t,e,r){return e=wt(e),function(t,e){if(e&&("object"==yt(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,gt()?Reflect.construct(e,r||[],wt(t).constructor):e.apply(t,r))}(this,e)).res=document.createElement("div"),t.toggleWrap=document.createElement("div"),t.toggleWrap.style.zIndex=9999,t.toggleWrap.style.borderRadius="0.3rem",t.toggleWrap.style.height="40px",t.toggleWrap.style.cursor="pointer",t.toggleWrap.style.display="flex",t.toggleWrap.style.alignItems="center",t.toggleWrap.style.justifyContent="center",t.res.appendChild(t.toggleWrap),t.contentWrap=document.createElement("div"),t.contentWrap.style.position="absolute",t.contentWrap.style.background="#ecf0f1",t.contentWrap.style.borderRadius="0.3rem",t.contentWrap.style.boxShadow="0 2px 5px rgba(0, 0, 0, 0.15)",t.contentWrap.style.marginTop="10px",t.contentWrap.style.width="250px",t.contentWrap.style.display="none",t.res.appendChild(t.contentWrap),t.styles={},t.children=[],t.isExpanded=!1,t.toggleWrap.addEventListener("click",(function(){return t.toggle()})),t}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&kt(t,e)}(e,t),r=e,(n=[{key:"set",value:function(t){var e=this;this.options=t,t.title&&(this.toggleWrap.textContent=t.title),t.width&&(this.toggleWrap.style.width=t.width),t.contentWidth&&(this.contentWrap.style.width=t.contentWidth),t.background&&(this.contentWrap.style.backgroundColor=t.background),t.mar&&this.mar(t.mar);var r=function(){var r,n=window.matchMedia("(max-device-width: 415px)"),i=window.matchMedia("(max-width: ".concat(null!==(r=t.breakpoint)&&void 0!==r?r:"600px",")"));n.matches||i.matches?e.contentWrap.style.position="relative":e.contentWrap.style.position="absolute"};return window.addEventListener("resize",r),r(),this}},{key:"add",value:function(t){var e,r=this;if(!Array.isArray(t))throw new Error("The 'add' method expects an array of children.");if(t.forEach((function(t,e){if(0!==e){if(!(t.res instanceof HTMLElement))throw new Error("Each child must have a valid 'element' property that is an HTMLElement.");r.contentWrap.appendChild(t.res)}})),!this.options||!this.options.title){var n=t[0];n&&n.res&&this.toggleWrap.appendChild(n.res)}return(e=this.children).push.apply(e,function(t){return function(t){if(Array.isArray(t))return mt(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||pt(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(t)),this}},{key:"toggle",value:function(){this.isExpanded=!this.isExpanded,this.contentWrap.style.display=this.isExpanded?"block":"none"}},{key:"toCode",value:function(){var t=this,e=this.options?Object.entries(this.options).map((function(t){var e=function(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==e);l=!0);}catch(t){c=!0,i=t}finally{try{if(!l&&null!=r.return&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}(t,e)||pt(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(t,2),r=e[0],n=e[1];return"string"==typeof n?"".concat(r,': "').concat(n,'"'):"object"===yt(n)?"".concat(r,": ").concat(JSON.stringify(n)):"".concat(r,": ").concat(n)})).join(",\n "):"",r=this.children.map((function(e,r){return e.toCode().flatMap((function(t){return t})).join("")+(r<t.children.length-1?",":"")})).join("");return["new Dropdown().set({\n ".concat(e,"\n}).add([\n ").concat(r,"\n])")]}},{key:"render",value:function(t){return t&&document.querySelector(t).appendChild(this.res),this.res}}])&&vt(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function St(t){return St="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},St(t)}function Ot(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=function(t,e){if(t){if("string"==typeof t)return Ct(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Ct(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,i=function(){};return{s:i,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,s=!0,a=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return s=t.done,t},e:function(t){a=!0,o=t},f:function(){try{s||null==r.return||r.return()}finally{if(a)throw o}}}}function Ct(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function jt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Et(n.key),n)}}function Et(t){var e=function(t){if("object"!=St(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=St(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==St(e)?e:e+""}function Tt(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(Tt=function(){return!!t})()}function Pt(){return Pt="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(t,e,r){var n=function(t,e){for(;!{}.hasOwnProperty.call(t,e)&&null!==(t=At(t)););return t}(t,e);if(n){var i=Object.getOwnPropertyDescriptor(n,e);return i.get?i.get.call(arguments.length<3?t:r):i.value}},Pt.apply(null,arguments)}function At(t){return At=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},At(t)}function Rt(t,e){return Rt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},Rt(t,e)}var Lt=function(t){function e(t){var r;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(r=function(t,e,r){return e=At(e),function(t,e){if(e&&("object"==St(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,Tt()?Reflect.construct(e,r||[],At(t).constructor):e.apply(t,r))}(this,e)).res=null,r.setup(t),r.code=[],r.isLast=!1,r.code.push("\n new Wrapper() \n"),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Rt(t,e)}(e,t),r=e,n=[{key:"isLasta",value:function(){return this.isLast=!0,this}},{key:"toCode",value:function(){return this.code}},{key:"getType",value:function(){return"LayoutWrapperElement"}},{key:"setArea",value:function(t){return this.res.style.gridArea=t,this}},{key:"removeQuotesFromFirstWord",value:function(t){return t.replace(/"([^"]+)":/g,"$1:")}},{key:"clicked",value:function(t){return this.res.addEventListener("click",t),this}},{key:"gpos",value:function(t){return this.res.style.gridColumn=t.col,this.res.style.gridRow=t.row,this}},{key:"set",value:function(t){var r,n,i,o=".set({";if(t.pad&&this.pad(t.pad),t.arrpad&&(o+="pad: {sides: [".concat(t.arrpad.sides.map((function(t){return'"'.concat(t,'"')})).join(", "),'], value: "').concat(t.arrpad.value,'"}, ')),t.gpos&&this.gpos(t.gpos),t&&t.id&&t.stroke||t&&t.id&&t.gradient||t&&t.id&&t.span||t&&t.id&&t.layout){t.gradient,t.gradient&&(this.globalGradient=t.gradient.op.gradient),t.stroke&&(r=e,n=this,"function"==typeof(i=Pt(At(1&3?r.prototype:r),"setAny",n))?function(t){return i.apply(n,t)}:i)([{globalBlast:"".concat(t.stroke.op.width," ").concat(t.stroke.op.color)}]);var s=[t.stroke,t.gradient,t.animation,t.span,t.layout];s=s.filter((function(t){return null!=t}));for(var a=[],l=0;l<s.length;l++)a.push({range:s[l].range,log:s[l].op.name,target:s[l].target});this.res.setAttribute("id",t.id),this.betaReact(a,t.id)}if(t.socenter&&(this.res.style.display="flex",this.res.style.flexDirection="column",this.res.style.alignItems="center",t.socenter&&(o+="socenter: ".concat(t.socenter,","))),t.mboth&&(this.res.style.marginRight="auto")&&(this.res.style.marginLeft="auto"),t.mar&&this.mar(t.mar),t.sticky&&this.sticky(),t.transition&&(this.res.style.transition=t.transition),t.class&&this.res.setAttribute("class",t.class),t.ga&&(this.res.style.gridArea=t.ga),t.opacity&&(0==t.opacity&&(this.res.style.opacity=0),t.opacity&&(this.res.style.opacity=t.opacity)),t.maxHeight&&(this.res.style.maxHeight=t.maxHeight),t.id&&this.res.setAttribute("id",t.id),t.arrpad&&this.arrayPadding(t.arrpad.sides,t.arrpad.value),t.arrpad&&(o+="arrpad: {sides: [".concat(t.arrpad.sides.map((function(t){return'"'.concat(t,'"')})).join(", "),'], value: "').concat(t.arrpad.value,'"}, ')),t.arrayMargin&&this.arrayMargin(t.arrayMargin.sides,t.arrayMargin.value),t.arrayMargin&&(o+='\n arrayMargin: {sides: ["'.concat(t.arrayMargin.sides,'"], value: "').concat(t.arrayMargin.value,'"},')),t.center&&this.toCenter(t.center),t.center&&(o+='center: "'.concat(t.center,'",')),t.simpleCenter&&this.simpleCenter(),t.simpleCenter&&(o+='center: "'.concat(t.simpleCenter,'",')),t.filter&&(this.res.style.backdropFilter="blur(3px)"),t.radius&&this.corner(t.radius),t.radius&&(o+='\n radius: "'.concat(t.radius,'",')),t.border&&this.border(t.border),t.simpleBorder&&(this.res.style.border=t.simpleBorder),t.width&&this.width(t.width),t.width&&(o+='\n width: "'.concat(t.width,'",')),t.overflow&&(this.res.style.overflow="hidden"),t.overflow&&(o+='\n overflow: "'.concat(t.overflow,'",')),t.height&&this.heightNoAuto(t.height),t.height&&(o+='\n height: "'.concat(t.height,'",')),t.align&&this.flexAlign(t.align),t.align&&(o+='\n align: "'.concat(t.align,'",')),t.borderObj&&(this.res.style.borderRight="".concat(t.borderObj.width," solid ").concat(t.borderObj.color),this.res.style.borderRadius=t.borderObj.radius),t.borderObja&&(this.res.style.border="".concat(t.borderObja.width," solid ").concat(t.borderObja.color),this.res.style.borderRadius=t.borderObja.radius),t.font&&this.font(t.font),t.font&&(o+='font: "'.concat(t.font,'",')),t.maxWidth&&this.maxWidth(t.maxWidth),t.flexCenter&&this.flexc(t.flexCenter),t.multipad&&this.makeMultiPad(t.multipad),t.multimargin&&this.makeMultiMargin(t.multimargin),t.color&&this.color(t.color),t.background&&this.background(t.background),t.background&&(o+='background: "'.concat(t.background,'",')),t.weight&&this.weight(t.weight),t.paddings&&this.paddingo(t.paddings),t.area&&this.setArea(t.area),t.area&&(o+='area: "'.concat(t.area,'"')),t.column&&this.makeCol(),t.column&&(o+='\n column: "'.concat(t.column,'",')),t.alignIts&&(this.res.style.background="gray"),t.alignIts&&(this.res.style.alignItems="flex-start"),t.alignIts&&(this.res.style.justifyItems="flex-start"),t.customAlign&&(this.res.style.alignItems=t.customAlign),t.customJustify&&(this.res.style.justifyItems=t.customJustify),t.disp&&(this.res.style.display=t.disp),t.flexDir&&(this.res.style.flexDirection=t.flexDir),t.flexDir&&(this.res.style.display="flex"),t.flexDir&&(o+='\n flexDir: "'.concat(t.flexDir,'",')),t.zIndex&&(this.res.style.zIndex=t.zIndex),t.name&&(this.name=t.name),t.responsive&&this.rsp(t.responsive),t.stretch){t.stretch&&this.stretch(t.stretch);var c=this.removeQuotesFromFirstWord(JSON.stringify(t.stretch));o+="\n stretch: ".concat(c,",")}for(var u in t)if("margin"===u){var d=t[u];if(Array.isArray(d)&&d.length>0){var h,f=Ot(d);try{for(f.s();!(h=f.n()).done;){var y=h.value;y.hasOwnProperty("top")&&(this.res.style.marginTop=y.top),y.hasOwnProperty("right")&&(this.res.style.marginRight=y.right),y.hasOwnProperty("bottom")&&(this.res.style.marginBottom=y.bottom),y.hasOwnProperty("left")&&(this.res.style.marginLeft=y.left)}}catch(t){f.e(t)}finally{f.f()}}}return 8===(o+="})\n").length&&(o=""),this.code.push(o),this}},{key:"rsp",value:function(t){var e=this;this.res.style.display="flex";var r=t.sequence.split("-"),n=function(){var n=t.ranges;"0px"!==n[0]&&n.unshift("0px");for(var i=0;i<n.length-1;i++)(window.matchMedia("(min-width: ".concat(n[i],") and (max-width: ").concat(n[i+1],")")).matches||window.matchMedia("(min-width: ".concat(n[n.length-1],")")).matches)&&("row"===r[i]&&(e.res.style.flexDirection="row",e.res.style.border="3px solid green"),"col"===r[i]&&(e.res.style.flexDirection="column",e.res.style.border="3px solid purple"));return e};window.addEventListener("resize",n),n()}},{key:"sticky",value:function(){return this.res.style.position="sticky",this.res.style.top=0,this}},{key:"toSticky",value:function(){return this.res.style.position="sticky",this.res.style.top="0",this}},{key:"stretch",value:function(t){var e=this,r=function(){window.matchMedia("(max-width: ".concat(t.at,")")).matches?e.res.style.width="auto":window.matchMedia("(max-device-width: 415px)").matches?e.res.style.width="100%":e.res.style.width=t.backTo};r(),window.addEventListener("resize",r)}},{key:"makeCol",value:function(){return this.res.style.display="flex",this.res.style.flexDirection="column",this.res.style.alignItems="flex-start",this}},{key:"paddingo",value:function(t){return this.res.style.padding=t,this}},{key:"toCenter",value:function(t){return this.res.style.display="flex",this.res.style.flexDirection="column",this.res.style.justifyContent="center","both"===t&&(this.res.style.alignItems="center"),this}},{key:"simpleCenter",value:function(){return this.res.style.justifyContent="center",this.res.style.justifyItems="center",this.res.style.alignContent="center",this.res.style.alignItems="center",this}},{key:"color",value:function(t){return this.res.style.color=t,this}},{key:"weight",value:function(t){return this.res.style.fontWeight=t,this}},{key:"makeMultiPad",value:function(t){for(var e=0;e<t.length;e++)"left"===t[e].side&&(this.res.style.paddingLeft=t[e].value),"right"===t[e].side&&(this.res.style.paddingRight=t[e].value);return this}},{key:"makeMultiMargin",value:function(t){this.res.style.zIndex="1";for(var e=0;e<t.length;e++)"left"===t[e].side&&(this.res.style.marginLeft=t[e].value),"right"===t[e].side&&(this.res.style.marginRight=t[e].value),"top"===t[e].side&&(this.res.style.marginTop=t[e].value),"bottom"===t[e].side&&(this.res.style.marginBottom=t[e].value);return this}},{key:"flexc",value:function(t){return this.res.style.display="flex",this.res.style.flexDirection="column",this.res.style.justifyContent="center",this}},{key:"maxWidth",value:function(t){return this.res.style.maxWidth=t,this}},{key:"font",value:function(t){return this.res.style.fontFamily=t,this}},{key:"flexAlign",value:function(t){return this.res.style.display="flex",this.res.style.justifyContent="flex-start",this.res.style.alignItems="flex-start","center"===t?(this.res.style.display="flex",this.res.style.flexDirection="column",this.res.style.alignItems="center",this):this}},{key:"width",value:function(t){return this.res.style.width=t,this}},{key:"heightNoAuto",value:function(t){return this.res.style.height=t,this}},{key:"border",value:function(t){return this.res.style.borderRadius="".concat(t.radius,"px"),this.res.style.padding="0.25em",this.res.style.border="".concat(t.width,"px solid ").concat(t.color),this}},{key:"toCol",value:function(){return this.res.style.display="flex",this.res.style.flexDirection="column",this.res.style.justifyContent="center",this.res.style.alignItems="center",this}},{key:"add",value:function(t){this.items=t,this.code.push(".add([ \n");var e=t.map((function(e,r){return e.toCode().flatMap((function(t){return t})).join("")+(r<t.length-1?",":"")})).join("");this.code.push(e);for(var r=0;r<t.length;r++)if(void 0!==t[r]&&void 0!==t[r].toCode){var n=t[r].render();this.res.appendChild(n)}return this.code.push("])"),this}},{key:"arrayPadding",value:function(t,e){return t.includes("left")&&(this.res.style.paddingLeft=e),t.includes("right")&&(this.res.style.paddingRight=e),t.includes("top")&&(this.res.style.paddingTop=e),t.includes("bottom")&&(this.res.style.paddingBottom=e),this}},{key:"arrayMargin",value:function(t,e){return e||(this.res.style.marginLeft="".concat(t[0],"px"),this.res.style.marginTop="".concat(t[1],"px"),this.res.style.marginRight="".concat(t[2],"px"),this.res.style.marginBottom="".concat(t[3],"px")),t.includes("left")&&(this.res.style.marginLeft=e),t.includes("right")&&(this.res.style.marginRight=e),t.includes("top")&&(this.res.style.marginTop=e),t.includes("bottom")&&(this.res.style.marginBottom=e),this}},{key:"setWidth",value:function(t){this.res.style.width="100vw"}},{key:"setHeight",value:function(t){return this.res.style.height="".concat(t),this}},{key:"setup",value:function(t){var e=t?document.createElement(t.isLink?"a":"div"):document.createElement("div");return t&&t.isLink&&(e.style.textDecoration="none",e.setAttribute("href",t.child)),this.res=e,this.res.style.margin=0,this.res.style.padding=0,t&&!0===t.hideOverflow&&(this.res.style.overflow="hidden",this.res.style.overflowY="scroll"),t&&!0===t.center&&(this.res.style.display="flex",this.res.style.flexDirection="column",this.res.style.justifyContent="center",this.res.style.alignItems="center"),t&&"left"===t.align&&(this.res.style.alignItems="flex-start"),t&&"right"===t.align&&(this.res.style.alignItems="flex-end"),t&&t.height&&(this.res.style.height=t.height),t&&t.width&&(this.res.style.width=t.width,this.res.style.marginLeft="auto",this.res.style.marginRight="auto",window.matchMedia("(max-device-width: 415px)").matches&&(this.res.style.width="95%")),this}},{key:"height",value:function(t){return this.res.style.width="auto",this.res.style.height="".concat(t),this}},{key:"size",value:function(t,e){return this.w=t,this.h=e,this.w?this.res.style.width=this.w:this.res.style.width=window.innerWidth,this.h?this.res.style.height=this.h:this.res.style.height=window.innerHeight,this}},{key:"background",value:function(t){return this.res.style.background=t,this}},{key:"corner",value:function(t){return this.res.style.borderRadius=t,this}},{key:"padding",value:function(t,e,r,n){return this.res.style.paddingLeft=t,this.res.style.paddingTop=e,this.res.style.paddingRight=r,this.res.style.paddingBottom=n,this}},{key:"margin",value:function(t,e,r,n){return this.res.style.marginLeft=t,this.res.style.marginTop=e,this.res.style.marginRight=r,this.res.style.marginBottom=n,this}},{key:"itemWidth",value:function(t){for(var e=0;e<this.res.childNodes.length;e++)this.res.childNodes[e].style.width=t;return this}},{key:"apply",value:function(t){var e=this,r=function(){for(var r=0;r<t.length;r++){var n=t[r],i=window.matchMedia("(max-width: ".concat(n.width,"px)"));n.device&&(i=window.matchMedia("(max-device-width: ".concat(n.width,"px)")),alert(n.device)),i.matches&&Object.assign(e.res.style,n.styles)}},n=window.matchMedia("(max-width: ".concat(t[0].width,"px)"));return t[0].device&&(n=window.matchMedia("(max-device-width: ".concat(t[0].width,"px)"))),n.matches||Object.assign(this.res.style,t[0].styles),r(),window.addEventListener("resize",r),this}},{key:"mount",value:function(t){document.querySelector(t).appendChild(this.res)}},{key:"render",value:function(t){return t?(document.querySelector("#mount"),document.querySelector(t).appendChild(this.res),this):this.res}}],n&&jt(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function zt(t){return zt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},zt(t)}function Mt(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=function(t,e){if(t){if("string"==typeof t)return It(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?It(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,i=function(){};return{s:i,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,s=!0,a=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return s=t.done,t},e:function(t){a=!0,o=t},f:function(){try{s||null==r.return||r.return()}finally{if(a)throw o}}}}function It(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function Bt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Nt(n.key),n)}}function Nt(t){var e=function(t){if("object"!=zt(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=zt(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==zt(e)?e:e+""}function Wt(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(Wt=function(){return!!t})()}function _t(t){return _t=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},_t(t)}function Ft(t,e){return Ft=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},Ft(t,e)}var Dt=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e,r){return e=_t(e),function(t,e){if(e&&("object"==zt(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,Wt()?Reflect.construct(e,r||[],_t(t).constructor):e.apply(t,r))}(this,e)}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Ft(t,e)}(e,t),r=e,(n=[{key:"setup",value:function(t){return this.obj=t,this.animate=void 0===this.obj.animate||this.obj.animate,this.res=this.createSideNav(t),this.res.style.position="relative",this.res.style.zIndex=3,this.closed=!0,this}},{key:"toggleSideNav",value:function(t){this.closed=!this.closed;var e=this.res.children[0];if(this.closed)if(e.style.overflowX="hidden",t.style.opacity=1,this.animate){e.animate([{transform:"translateX(0)"},{transform:"translateX(100%)"}],{duration:300,fill:"forwards"});var r,n=-1,i=Mt(e.children);try{for(i.s();!(r=i.n()).done;){var o=r.value;if(n+=1,this.masterEL[n]){var s,a=Mt(o.children);try{for(a.s();!(s=a.n()).done;){var l=s.value,c=this.masterEL[n].options.animation;c&&this.mappedIDS.includes(l.id)&&l.animate(c.op.keyframesClose,c.op.closeOptions)}}catch(t){a.e(t)}finally{a.f()}}}}catch(t){i.e(t)}finally{i.f()}}else e.style.display="none";else{e.style.overflowX="none",e.children[1].style.border="1px solid orange";var u,d=-1,h=Mt(e.children);try{for(h.s();!(u=h.n()).done;){var f=u.value;d+=1;var y,p=Mt(f.children);try{for(p.s();!(y=p.n()).done;){var m=y.value;if(this.mappedIDS.includes(m.id)&&void 0!==this.masterEL[0]){var v=this.masterEL[d].options.animation;if(v){console.log("OPEN KEYFRAMES"),console.log(v.op.keyframesOpen);var b=v.op.openOptions;b.delay||(b.delay=1),b.duration||(b.duration=300),console.log(b),m.animate(v.op.keyframesOpen,b)}}}}catch(t){p.e(t)}finally{p.f()}}}catch(t){h.e(t)}finally{h.f()}t.style.opacity=0,this.animate?(e.style.display="flex",e.animate([{transform:"translateX(100%)"},{transform:"translateX(0)"}],{duration:300,fill:"forwards"})):e.style.display="flex"}}},{key:"createToggleButton",value:function(t){var e=document.createElement("button");return e.innerText="☰",e.style.padding="10px 20px",e.style.backgroundColor="transparent",e.style.color=null!=t?t:"#3498db",e.style.border="none",e.style.borderRadius="5px",e.style.cursor="pointer",e.style.zIndex=1,e.style.fontSize="1.6rem",e}},{key:"createCloseButton",value:function(t){var e=document.createElement("button");return e.innerText="×",e.style.fontSize="1.6rem",e.style.padding="10px 20px",e.style.backgroundColor="transparent",e.style.color=null!=t?t:"black",e.style.border="none",e.style.borderRadius="5px",e.style.cursor="pointer",e.style.zIndex=1,e.style.alignSelf="flex-end",e}},{key:"createSideNav",value:function(t){var e=this,r=document.createElement("div");r.style.display="flex",r.style.justifyContent="flex-end";var n=document.createElement("div");n.style.display="none",n.style.background=this.obj.background||"#1abc9c",n.style.height="100%",window.matchMedia("(max-device-width: 415px)").matches?n.style.width="100%":n.style.width=this.obj.width||"400px",n.style.position="fixed",n.style.right=0,this.animate&&(n.style.transform="translateX(100%)"),n.style.flexDirection="column",n.style.justifyContent="flex-start";var i=this.createToggleButton(this.obj.hamColour.opened),o=this.createCloseButton(this.obj.hamColour.closed);return i.addEventListener("click",(function(){return e.toggleSideNav(i)})),o.addEventListener("click",(function(){return e.toggleSideNav(i)})),n.appendChild(o),r.appendChild(n),r.appendChild(i),r}},{key:"items",value:function(t){this.masterEL=t.items.filter((function(t){return void 0!==t.link})),console.log("EXTRACT IDs"),console.log(t);var e=t.items.filter((function(t){return void 0===t.items})).map((function(t){return t.id}));if(this.mappedIDS=e,this.item=t,this.res.children[0].appendChild(t.render()),void 0!==this.masterEL[0]){console.log("ANNAX"),console.log(this.masterEL[0]);var r=this.masterEL[0].options.animation;if(r){var n,i=Mt(this.res.children[0].children);try{for(i.s();!(n=i.n()).done;){var o,s=Mt(n.value.children);try{for(s.s();!(o=s.n()).done;){var a=o.value;if(this.mappedIDS.includes(a.id)){var l=r.op.closeOptions;l.delay=0,console.log("ANNAX"),console.log("SETTING INITIAL STATE ZEROING THE DELAY"),console.log(r.op.keyframesClose),console.log(l),a.animate(r.op.keyframesClose,r.op.closeOptions)}}}catch(t){s.e(t)}finally{s.f()}}}catch(t){i.e(t)}finally{i.f()}}}return this}},{key:"toCode",value:function(){var t="new SideNav().setup(".concat(this.formatObj(this.obj),")");if(this.item){var e=this.item.toCode?this.item.toCode().join(""):this.formatObj(this.item);e=e.replace(/,\s*(\.set\(|\.add\()/g,"\n $1"),t+=".items(".concat(e,")")}return t}},{key:"formatObj",value:function(t){return JSON.stringify(t,null,2).replace(/"(\w+)"\s*:/g,"$1:")}},{key:"render",value:function(t){return t&&document.querySelector(t).appendChild(this.res),this.res}}])&&Bt(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function Ht(t){return Ht="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ht(t)}function Jt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,qt(n.key),n)}}function qt(t){var e=function(t){if("object"!=Ht(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Ht(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Ht(e)?e:e+""}var Gt=function(){return t=function t(e){if(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.hide=e,e){var r=document.createElement("div");r.style.flex="1",this.res=r}return e&&this.res.setAttribute("class","innerHider"),this},(e=[{key:"toCode",value:function(){return["new Spacer(".concat(this.hide,")")]}},{key:"render",value:function(){var t,e=document.createElement("h2");return e.style.display="none !important",null!==(t=this.res)&&void 0!==t?t:e}}])&&Jt(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function Qt(t){return Qt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Qt(t)}function Xt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,$t(n.key),n)}}function $t(t){var e=function(t){if("object"!=Qt(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Qt(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Qt(e)?e:e+""}function Yt(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(Yt=function(){return!!t})()}function Vt(t){return Vt=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},Vt(t)}function Ut(t,e){return Ut=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},Ut(t,e)}var Kt=function(t){function e(){var t;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(t=function(t,e,r){return e=Vt(e),function(t,e){if(e&&("object"==Qt(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,Yt()?Reflect.construct(e,r||[],Vt(t).constructor):e.apply(t,r))}(this,e)).el=null,t}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Ut(t,e)}(e,t),r=e,(n=[{key:"set",value:function(t){this.options=t;var e=document.createElement("div"),r=document.createElement("label");r.style.position="relative",r.style.display="block";var n=document.createTextNode(t.title);r.appendChild(n),r.style.opacity=0;var i=document.createElement("input");return"textarea"===t.type&&(i=document.createElement("textarea")),i.style.position="relative",i.placeholder=t.title,i.style.fontSize="1rem",i.style.padding=".4rem .75rem",e.appendChild(r),e.appendChild(i),this.res=e,t.mar&&this.mar(t.mar),t.pad&&this.pad(t.pad),i.addEventListener("focus",(function(){r.style.transition="transform ease 0.2s",r.style.transform="scale(0.80)",r.style.textTransform="uppercase",r.style.transformOrigin="left top",r.style.fontWeight="bold",i.placeholder="",r.style.opacity="1.0",t.font&&(r.style.fontFamily=t.font),t.color&&(r.style.color=t.color),t.exact&&(r.style.fontSize=t.exact)})),i.addEventListener("focusout",(function(){r.style.transform="scale(1.0)",i.placeholder=t.title,r.style.opacity="0.0"})),t.name&&i.setAttribute("name",t.name),window.matchMedia("(max-device-width: 415px)").matches&&(i.style.width="100%",e.style.width="100%"),i.style.fontSize="1rem",this.el=e,this}},{key:"getValue",value:function(){return this.el.children[1].value}},{key:"toCode",value:function(){var t=JSON.stringify(this.options,null,4);return t=t.replace(/"(\w+)"(?=\s*:)/g,"$1"),["new FloatingInput().set(".concat(t,")")]}},{key:"margin",value:function(t){return this.el.style.margin=t,this}},{key:"render",value:function(t){if(!t)return this.el;document.querySelector(t).appendChild(this.el)}}])&&Xt(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function Zt(t){return Zt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Zt(t)}function te(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,ee(n.key),n)}}function ee(t){var e=function(t){if("object"!=Zt(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Zt(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Zt(e)?e:e+""}window.FloatingInput=Kt;var re=function(){return t=function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.el=null,this.minLabel=null,this.maxLabel=null,this.currentLabel=null},(e=[{key:"padding",value:function(t){return this.el.style.padding=t,this}},{key:"toCode",value:function(){var t=JSON.stringify(this.options,null,4);return["new Range().set(".concat(t,")")]}},{key:"set",value:function(t){var e,r,n=this;this.options=t;var i=document.createElement("input");if(i.setAttribute("id","slider"),i.setAttribute("type","range"),i.setAttribute("min",t.min),i.setAttribute("max",t.max),i.setAttribute("value",t.min),i.style.width=null!==(e=t.width)&&void 0!==e?e:"100%",!t.plain){var o,s;i.style.setProperty("-webkit-appearance","none"),i.style.appearance="none",i.style.height="9px",i.style.background=null!==(o=t.style.trackColor)&&void 0!==o?o:"orange",i.style.borderRadius="5px";var a="\n #slider::-webkit-slider-thumb {\n -webkit-appearance: none;\n appearance: none;\n width: 25px;\n height: 25px;\n border-radius: 50%;\n background: ".concat(null!==(s=t.style.thumbColor)&&void 0!==s?s:"4CAF50",";\n cursor: pointer;\n }\n "),l=document.createElement("style");l.appendChild(document.createTextNode(a)),document.head.appendChild(l)}var c=document.createElement("div");c.style.display="flex",c.style.flexDirection="column",c.style.alignItems="center",c.style.width="100%";var u=document.createElement("div");if(u.style.display="flex",u.style.justifyContent="space-between",u.style.width=null!==(r=t.width)&&void 0!==r?r:"100%",this.minLabel=document.createElement("span"),this.minLabel.textContent=t.min,this.maxLabel=document.createElement("span"),this.maxLabel.textContent=t.max,this.currentLabel=document.createElement("span"),this.currentLabel.textContent=i.value,t.font&&(this.currentLabel.style.fontFamily=t.font),t.font&&(this.minLabel.style.fontFamily=t.font),t.font&&(this.maxLabel.style.fontFamily=t.font),t.plain||(u.appendChild(this.minLabel),u.appendChild(this.currentLabel),u.appendChild(this.maxLabel)),i.addEventListener("input",(function(){n.currentLabel.textContent=i.value})),window.matchMedia("(max-device-width: 415px)").matches)if(t.plain)i.style.width="80%";else{var d,h;i.style.height="20px",i.style.background=null!==(d=t.style.trackColor)&&void 0!==d?d:"1abc9C",i.style.borderRadius="10px",i.style.fontSize="3rem",i.style.width="80%";var f="\n #slider::-webkit-slider-thumb {\n -webkit-appearance: none;\n appearance: none;\n width: 25px;\n height: 25px;\n border-radius: 50%;\n background: ".concat(null!==(h=t.style.thumbColor)&&void 0!==h?h:"blue",";\n cursor: pointer;\n }\n "),y=document.createElement("style");y.appendChild(document.createTextNode(f)),document.head.appendChild(y)}return c.appendChild(u),c.appendChild(i),this.el=c,this}},{key:"value",value:function(){return this.el.querySelector("#slider").value}},{key:"render",value:function(t){if(!t)return this.el;document.querySelector(t).appendChild(this.el)}}])&&te(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function ne(t){return ne="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ne(t)}function ie(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,oe(n.key),n)}}function oe(t){var e=function(t){if("object"!=ne(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=ne(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==ne(e)?e:e+""}window.Range=re;var se=function(){return t=function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.el=null,this.radioCount=0},(e=[{key:"set",value:function(t){this.options=t,console.log("ORARA"),console.log(this.options),this.radioCount=t.items.length;for(var e=document.createElement("div"),r=t.items,n=0;n<r.length;n++){var i=document.createElement("label");r.font&&(i.style.font=r.font),r.color&&(i.style.color=r.color),r.exact&&(i.style.fontSize=r.exact);var o=document.createTextNode(r[n]);i.appendChild(o),i.setAttribute("for",r[n]);var s=document.createElement("input");s.setAttribute("type","radio"),s.setAttribute("id","S".concat(n)),s.setAttribute("value",r[n].split(" ").join("")),s.style.appearance="none",s.style.width="20px",s.style.height="20px",s.style.border=this.options.tint?"2px solid ".concat(this.options.tint):"2px solid #007BFF",s.style.borderRadius="50%",s.style.outline="none",s.style.cursor="pointer",s.style.transition="0.3s",this.options.font&&(i.style.fontFamily=this.options.font),t.multiple?s.setAttribute("name",r[n].split(" ").join("")):s.setAttribute("name",t.name),e.appendChild(s),e.appendChild(i),e.innerHTML+="</br>"}return this.el=e,this.responsive(),this}},{key:"padding",value:function(t){return this.el.style.padding=t,this}},{key:"getCheckedValues",value:function(){console.log("NOW");for(var t=[],e=0;e<this.radioCount;e++)if(document.querySelector("#S".concat(e)).checked){var r=document.querySelector("#S".concat(e));console.log("VALUE IS "+r.value),t.push(r.value)}return t}},{key:"toCode",value:function(){var t=JSON.stringify(this.options,null,4);return t=t.replace(/"(\w+)"(?=\s*:)/g,"$1"),["new RadioGroup().set(".concat(t,")")]}},{key:"responsive",value:function(){return window.matchMedia("(max-device-width: 415px)").matches&&(this.el.style.fontSize="1.7em"),this}},{key:"render",value:function(t){var e=this;if(!t){console.log("MULA");for(var r=function(){var t=e.el.children[n];"[object HTMLInputElement]"===t.toString()&&t.addEventListener("change",(function(){if(t.checked){t.style.backgroundColor=e.options.tint?e.options.tint:"#007BFF",t.style.boxShadow=e.options.tint?"0 0 0 2px ".concat(e.options.tint," inset"):"0 0 0 2px #0056b3 inset";for(var r=0;r<e.el.children.length;r++){var n=e.el.children[r];"INPUT"===n.tagName&&"radio"===n.type&&!1===e.options.multiple&&n!==t&&(n.style.backgroundColor="transparent",n.style.boxShadow="none")}}else t.style.backgroundColor="transparent",t.style.boxShadow="none"}))},n=0;n<this.el.children.length;n++)r();return this.el}document.querySelector(t).appendChild(this.el)}}])&&ie(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function ae(t){return ae="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ae(t)}function le(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,ce(n.key),n)}}function ce(t){var e=function(t){if("object"!=ae(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=ae(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==ae(e)?e:e+""}function ue(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(ue=function(){return!!t})()}function de(t){return de=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},de(t)}function he(t,e){return he=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},he(t,e)}window.RadioGroup=se;var fe=function(t){function e(){var t;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(t=function(t,e,r){return e=de(e),function(t,e){if(e&&("object"==ae(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,ue()?Reflect.construct(e,r||[],de(t).constructor):e.apply(t,r))}(this,e)).el=null,t.file=null,t.selected="",t}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&he(t,e)}(e,t),r=e,n=[{key:"setup",value:function(t,e){document.createElement("div");var r=document.createElement("select");r.setAttribute("type","file"),r.setAttribute("name",e),r.addEventListener("change",(function(){r.options[r.selectedIndex].value}));for(var n=0;n<t.length;n++)r.appendChild(this.addNode(t[n][0],t[n][1]));return this.el=r,this}},{key:"set",value:function(t){return this.options=t,t.items&&this.setup(t.items,t.name),t.arrayPadding&&this.arrayPadding(t.arrayPadding.sides,t.arrayPadding.value),t.arrayMargin&&this.arrayMargin(t.arrayMargin.sides,t.arrayMargin.value),t.pad&&this.pad(t.pad),t.mar&&this.mar(t.mar),t.radius&&(this.el.style.borderRadius=t.radius),t.background&&(this.el.style.background=t.background),this}},{key:"arrayPadding",value:function(t,e){return t.includes("left")&&(this.el.style.paddingLeft=e),t.includes("right")&&(this.el.style.paddingRight=e),t.includes("top")&&(this.el.style.paddingTop=e),t.includes("bottom")&&(this.el.style.paddingBottom=e),t.includes("all")&&(this.el.style.padding=e),this}},{key:"arrayMargin",value:function(t,e){return t.includes("left")&&(this.el.style.marginLeft=e),t.includes("right")&&(this.el.style.marginRight=e),t.includes("top")&&(this.el.style.marginTop=e),t.includes("bottom")&&(this.el.style.marginBottom=e),t.includes("all")&&(this.el.style.margin=e),this}},{key:"addNode",value:function(t,e){var r=document.createElement("option");r.setAttribute("value",t);var n=document.createTextNode(e);return r.appendChild(n),r}},{key:"padding",value:function(t){return this.el.style.padding=t,this}},{key:"font",value:function(t){return this.el.style.fontFamily=t,this}},{key:"margin",value:function(t){return this.el.style.margin=t,this}},{key:"toCode",value:function(){var t=JSON.stringify(this.options,null,4);return t=t.replace(/"(\w+)"(?=\s*:)/g,"$1"),["new Picker().set(".concat(t,")")]}},{key:"rounded",value:function(t){return this.el.style.borderRadius="4px",this}},{key:"auto",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?t.el.style.fontSize="3rem":t.el.style.fontSize="1rem"};return e(),window.addEventListener("resize",e),this}},{key:"render",value:function(t){if(!t)return this.el;document.querySelector(t).appendChild(this.el)}}],n&&le(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function ye(t){return ye="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ye(t)}function pe(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,me(n.key),n)}}function me(t){var e=function(t){if("object"!=ye(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=ye(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==ye(e)?e:e+""}function ve(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(ve=function(){return!!t})()}function be(t){return be=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},be(t)}function ge(t,e){return ge=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},ge(t,e)}window.Picker=fe;var we=function(t){function e(){var t;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(t=function(t,e,r){return e=be(e),function(t,e){if(e&&("object"==ye(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,ve()?Reflect.construct(e,r||[],be(t).constructor):e.apply(t,r))}(this,e)).el=null,t.file=null,t}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&ge(t,e)}(e,t),r=e,(n=[{key:"set",value:function(t){var e=this;this.options=t,this.okayColor=t.okayColor,window.matchMedia("(max-device-width: 415px)");var r=document.createElement("div");r.style.paddingBottom="1em",r.style.display="flex",document.createElement("div");var n=document.createElement("input");n.setAttribute("type","text"),n.style.display="none",n.style.margin="0.5em";var i=document.createElement("input");i.setAttribute("type","file"),i.setAttribute("name",t.name),t.accept&&(i.accept=t.accept),i.setAttribute("id",t.id),i.style.visibility="hidden",i.style.display="none",window.matchMedia("(max-device-width: 415px)").matches&&(i.style.fontSize="1rem");var o=document.createElement("label");return o.setAttribute("for",t.id),o.innerText=t.title,o.style.marginRight=12,o.style.padding="0.5em",t.color&&(o.style.color=t.color),t.background&&(o.style.background=t.background,o.style.padding="10"),i.addEventListener("change",(function(){n.style.display="block",t.hideField&&(n.style.display="none"),o.innerText="Change",e.file=i.files[0],e.onLoad(e.file),ke[t.index]=e.file,n.setAttribute("value",e.file.name),n.setAttribute("readonly","true"),e.getLoaded(),e.highlight()})),r.appendChild(i),r.appendChild(o),r.appendChild(n),this.el=r,t.font&&this.font(t.font),t.radius&&this.borderRadius(t.radius),this}},{key:"borderRadius",value:function(t){return this.el.style.borderRadius=t,this}},{key:"addClass",value:function(t){return this.el.setAttribute("class",t),this}},{key:"font",value:function(t){return this.el.style.fontFamily=t,this}},{key:"bold",value:function(){return this.el.style.fontWeight="bold",this}},{key:"rounded",value:function(){return this.el.children[1].style.borderRadius="8px",this}},{key:"highlight",value:function(){return null===this.file?(this.hasFile=!1,this.el.children[1].style.background="red"):(this.hasFile=!0,this.okayColor?this.el.children[1].style.background=this.okayColor:this.el.children[1].style.background="#1abc9c"),this}},{key:"auto",value:function(){var t=function(){window.matchMedia("(max-device-width: 415px)").matches};return t(),window.addEventListener("resize",t),this}},{key:"onLoad",value:function(t){return this.returnObject(this.file),this}},{key:"getLoaded",value:function(){return this.file}},{key:"returnObject",value:function(t){return t}},{key:"loadCall",value:function(t){return this.func=t,this.func(this.file),this}},{key:"toCode",value:function(){var t=JSON.stringify(this.options,null,4);return t=t.replace(/"(\w+)"(?=\s*:)/g,"$1"),["new FilePickera().set(".concat(t,")")]}},{key:"render",value:function(t){return t?(document.querySelector(t).appendChild(this.el),this):this.el}}])&&pe(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u),ke=[];function xe(t,e){return xe=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},xe(t,e)}function Se(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(Se=function(){return!!t})()}function Oe(t){return Oe="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Oe(t)}function Ce(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,je(n.key),n)}}function je(t){var e=function(t){if("object"!=Oe(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Oe(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Oe(e)?e:e+""}var Ee=function(){return t=function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.res=null,this.currentItem=""},(e=[{key:"set",value:function(t){var e=this,r=t;this.options=t;var n=document.createElement("input");n.setAttribute("list","dlCities"),n.setAttribute("id","my");var i=t.data,o=0,s=i.length,a=document.createElement("datalist");for(a.id="dlCities",o=0;o<s;o+=1){var l=document.createElement("option");l.value=i[o],a.appendChild(l)}return n.appendChild(a),n.addEventListener("change",(function(){var t=document.querySelector("#my").value;console.log(t),e.currentItem=t})),n.setAttribute("placeholder","Type value"),n.style.padding=".4rem .75rem",n.style.fontSize="1rem",this.res=n,this.responsive(),r.arrayPadding&&this.arrayPadding(r.arrayPadding.sides,r.arrayPadding.value),r.arrayMargin&&this.arrayMargin(r.arrayMargin.sides,r.arrayMargin.value),r.pad&&this.pad(r.pad),r.mar&&this.mar(r.mar),this}},{key:"toCode",value:function(){var t=JSON.stringify(this.options,null,4);return["new DataList().set(".concat(t,")")]}},{key:"getValue",value:function(){return this.res.value}},{key:"arrayPadding",value:function(t,e){return console.log(t),t.includes("left")&&(this.res.style.paddingLeft=e),t.includes("right")&&(this.res.style.paddingRight=e),t.includes("top")&&(this.res.style.paddingTop=e),t.includes("bottom")&&(this.res.style.paddingBottom=e),t.includes("all")&&(this.res.style.padding=e),this}},{key:"arrayMargin",value:function(t,e){return console.log(t),t.includes("left")&&(this.res.style.marginLeft=e),t.includes("right")&&(this.res.style.marginRight=e),t.includes("top")&&(this.res.style.marginTop=e),t.includes("bottom")&&(this.res.style.marginBottom=e),t.includes("all")&&(this.res.style.margin=e),this}},{key:"margin",value:function(t){return this.res.style.margin=t,this}},{key:"responsive",value:function(){return window.matchMedia("(max-device-width: 415px)").matches&&(this.res.style.width="100%"),this}},{key:"render",value:function(t){if(!t)return this.res;document.querySelector(t).appendChild(this.res)}}])&&Ce(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}(),Te=Ee;function Pe(t){return Pe="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Pe(t)}function Ae(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function Re(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Le(n.key),n)}}function Le(t){var e=function(t){if("object"!=Pe(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Pe(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Pe(e)?e:e+""}Ee=function(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];return function(t,e,r){if(Se())return Reflect.construct.apply(null,arguments);var n=[null];n.push.apply(n,e);var i=new(t.bind.apply(t,n));return r&&xe(i,r.prototype),i}(Te,e)},window.DataList=Ee;var ze=function(){return t=function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"POST";!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.action=e,this.method=r,this.elements=[],this.formElement=document.createElement("form"),this.formElement.action=this.action,this.formElement.method=this.method},e=[{key:"add",value:function(t){var e=this;return this.elements=t,console.log("CODEA"),console.log(this.elements),console.log(this.elements.length),t.forEach((function(t){if(!t||"function"!=typeof t.render)throw new Error("Each element in the array must have a render method that returns an HTML DOM element.");e.formElement.appendChild(t.render())})),console.log(this.elements),this}},{key:"toCode",value:function(){var t=this.elements.map((function(t){return t.toCode()})),e=Object.entries(this.obj).map((function(t){var e=function(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==e);l=!0);}catch(t){c=!0,i=t}finally{try{if(!l&&null!=r.return&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}(t,e)||function(t,e){if(t){if("string"==typeof t)return Ae(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Ae(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(t,2),r=e[0],n=e[1],i="string"==typeof n?'"'.concat(n,'"'):n;return"".concat(r,": ").concat(i)})).join(", ");return console.log("FORM DQ"),console.log(t),["new Form().set({".concat(e,"}).add([ \n ").concat(t.join(", \n"),"])")]}},{key:"set",value:function(t){return this.obj=t,t.action&&this.setAction(t.action),t.method&&this.setMethod(t.method),this}},{key:"setAction",value:function(t){this.action=t,this.formElement.action=this.action}},{key:"setMethod",value:function(t){this.method=t,this.formElement.method=this.method}},{key:"render",value:function(t){return t&&document.querySelector(t).appendChild(this.formElement),this.formElement}}],e&&Re(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function Me(t){return Me="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Me(t)}function Ie(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Be(n.key),n)}}function Be(t){var e=function(t){if("object"!=Me(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Me(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Me(e)?e:e+""}function Ne(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(Ne=function(){return!!t})()}function We(t){return We=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},We(t)}function _e(t,e){return _e=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},_e(t,e)}var Fe=function(t){function e(t,r){var n;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(n=function(t,e,r){return e=We(e),function(t,e){if(e&&("object"==Me(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,Ne()?Reflect.construct(e,r||[],We(t).constructor):e.apply(t,r))}(this,e)).text=t,n.res=null,n.val=r,n.setup(),n}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&_e(t,e)}(e,t),r=e,n=[{key:"setup",value:function(t){return this}},{key:"hover",value:function(t){var e=this;return this.prevColor=this.res.style.backgroundColor,this.foreColor=this.res.style.color,t.animation&&(this.res.style.transition="".concat(t.animation,"s ease-in-out"),this.res.style.transionProperty="background, color"),this.res.onmouseout=function(){e.res.style.backgroundColor="".concat(e.prevColor),e.res.style.color="".concat(e.foreColor)},this.res.onmouseover=function(){e.res.style.backgroundColor=t.background,e.res.style.color=t.color},this}},{key:"set",value:function(t){this.options=t;var e=document.createElement("button");if(e.style.background="transparent",t.url){var r=document.createElement("img");r.setAttribute("src",t.url),r.style.width=t.frame.width,r.style.height=t.frame.height,e.appendChild(r)}else{var n=document.createTextNode(this.text.replace("$",this.val));e.appendChild(n)}return this.res=e,t&&"submit"===t.type&&e.setAttribute("type",t.type),this.border("none"),this.res.style.display="block",t.background&&this.background(t.background),t.padding&&this.padding(t.padding),t.margin&&this.margin(t.margin),t.mar&&this.mar(t.mar),t.pad&&this.pad(t.pad),t.centered&&(this.res.style.marginRight="auto",this.res.style.marginLeft="auto",this.res.style.backgroundColor="black"),t.border&&this.border(t.border),t.radius&&this.borderRadius(t.radius),t.class&&this.setClass(t.class),t.color&&this.color(t.color),t.auto&&this.auto(),t.weight&&(this.res.style.fontWeight=t.weight),t.fluidc&&this.fluidButtonCopy(t.fluidc),t.fluidc&&'\n fluidc: "'.concat(t.fluidc,'",'),t.onTap&&this.onTap(t.onTap),t.frame&&this.frame(t.frame),t.frame&&'\n frame: "'.concat(t.frame,'",'),t.arrpad&&this.arrayPadding(t.arrpad.sides,t.arrpad.value),t.arrpad&&'\n arrpad: {sides: ["'.concat(t.arrpad.sides,'"], value: "').concat(t.arrpad.value,'"},'),t.arrayMargin&&this.arrayMargin(t.arrayMargin.sides,t.arrayMargin.value),t.arrayMargin&&'\n arrayMargin: {sides: ["'.concat(t.arrayMargin.sides,'"], value: "').concat(t.arrayMargin.value,'"},'),t.keySet&&this.keySet(t.keySet),this}},{key:"arrayPadding",value:function(t,e){return t.includes("left")&&(this.res.style.paddingLeft=e),t.includes("right")&&(this.res.style.paddingRight=e),t.includes("top")&&(this.res.style.paddingTop=e),t.includes("bottom")&&(this.res.style.paddingBottom=e),t.includes("all")&&(this.res.style.padding=e),e||(this.res.style.paddingBottom=t),this}},{key:"arrayMargin",value:function(t,e){return e||(this.res.style.marginLeft="".concat(t[0],"px"),this.res.style.marginTop="".concat(t[1],"px"),this.res.style.marginRight="".concat(t[2],"px"),this.res.style.marginBottom="".concat(t[3],"px")),t.includes("left")&&(this.res.style.marginLeft=e),t.includes("right")&&(this.res.style.marginRight=e),t.includes("top")&&(this.res.style.marginTop=e),t.includes("bottom")&&(this.res.style.marginBottom=e),t.includes("all")&&(this.res.style.margin=e),e||(this.res.style.marginBottom=t),this}},{key:"fluidButtonCopy",value:function(t){if(t instanceof Object){this.prevStylex=this.res.style,this.res=document.createElement("button"),this.res.style.cssText=this.prevStylex.cssText;var e=document.createTextNode(this.text);return this.res.appendChild(e),this.res.style.fontSize=t.exact,this}if("S1"===t){this.prevStylex=this.res.style,this.res=document.createElement("button"),this.res.style.cssText=this.prevStylex.cssText;var r=document.createTextNode(this.text);this.res.appendChild(r),this.res.style.fontSize="calc(1.625rem + 5.075vw)"}if("S2"===t){this.prevStylex=this.res.style,this.res=document.createElement("button"),this.res.style.cssText=this.prevStylex.cssText;var n=document.createTextNode(this.text);this.res.appendChild(n),this.res.style.fontSize="calc(1.500rem + 4.3vw)"}if("S3"===t){this.prevStylex=this.res.style,this.res=document.createElement("button"),this.res.style.cssText=this.prevStylex.cssText;var i=document.createTextNode(this.text);this.res.appendChild(i),this.res.style.fontSize="calc(1.375rem + 3.525vw)"}if("S4"===t){this.prevStylex=this.res.style,this.res=document.createElement("button"),this.res.style.cssText=this.prevStylex.cssText;var o=document.createTextNode(this.text);this.res.appendChild(o),this.res.style.fontSize="calc(1.250rem + 2.75vw)"}if("S5"===t){this.prevStylex=this.res.style,this.res=document.createElement("button"),this.res.style.cssText=this.prevStylex.cssText;var s=document.createTextNode(this.text);this.res.appendChild(s),this.res.style.fontSize="calc(1.125rem + 1.975vw)"}return"S6"===t&&(this.res.style.fontSize="calc(1rem + 0.5vw)"),this}},{key:"setClass",value:function(t){return this.res.setAttribute("class",t),this}},{key:"color",value:function(t){return this.res.style.color=t,this}},{key:"background",value:function(t){return this.res.style.background=t,this}},{key:"width",value:function(t){return this.res.style.width=t,this}},{key:"borderRadius",value:function(t){return this.res.style.borderRadius=t,this}},{key:"padding",value:function(t,e,r,n){return t&&e&&r&&n?(this.res.style.paddingLeft=t,this.res.style.paddingTop=e,this.res.style.paddingRight=r,this.res.style.paddingBottom=n):this.res.style.padding=t,this}},{key:"margin",value:function(t,e,r,n){return t&&e&&r&&n?(this.res.style.marginLeft=t,this.res.style.marginTop=e,this.res.style.marginRight=r,this.res.style.marginBottom=n):this.res.style.margin=t,this}},{key:"auto",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?t.res.style.fontSize="2.2rem":t.res.style.fontSize="1rem"};return e(),window.addEventListener("resize",e),this}},{key:"large",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?(alert("WOW"),t.res.style.fontSize="6rem"):t.res.style.fontSize="3rem"};return e(),window.addEventListener("resize",e),this}},{key:"border",value:function(t,e){return"none"===t&&(this.res.style.border="none"),this.res.style.border="".concat(t," solid ").concat(e,"px"),this}},{key:"frame",value:function(t){return this.res.style.width=t.width,this.res.style.height=t.height,this}},{key:"updating",value:function(t,e){var r=this.res,n=this.text;return Object.defineProperty(t,e,{set:function(t){var e=document.createTextNode(n.replace("$",t));r.replaceChild(e,r.childNodes[0])}}),this}},{key:"onTap",value:function(t){return this.res.addEventListener("click",t),this}},{key:"toCode",value:function(){var t=JSON.stringify(this.options,(function(t,e){return"function"==typeof e?e.toString():e}),4).replace(/"(\w+)":/g,"$1:").replace(/"(\(\)\s*=>\s*{[^}]*})"/g,"$1").replace(/\\n/g,"").replace(/\\"/g,'"');return['new Button("'.concat(this.text,'").set(').concat(t,")")]}},{key:"render",value:function(t){if(!t)return this.res;document.querySelector(t).appendChild(this.res)}}],n&&Ie(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function De(t){return De="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},De(t)}function He(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Je(n.key),n)}}function Je(t){var e=function(t){if("object"!=De(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=De(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==De(e)?e:e+""}var qe=function(){return t=function t(e,r){if(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.container=document.createElement("div"),this.elements=e,this.currentSlideIndex=0,this.buttons=r,!this.buttons){var n={leftButton:new Fe("L").set({url:"https://static-00.iconduck.com/assets.00/circle-arrow-left-icon-512x512-xp8okg5c.png",color:"#1abc9c",frame:{width:50,height:50},radius:"100%",arrayMargin:{sides:["all"],value:"1rem"}}),rightButton:new Fe("R").set({url:"https://static-00.iconduck.com/assets.00/arrow-right-circle-icon-2048x2048-m0qcnetg.png",color:"#1abc9c",frame:{width:50,height:50},radius:"100%",arrayMargin:{sides:["all"],value:"1rem"}})};this.buttons=n}this.createSlider(),this.init()},e=[{key:"toCode",value:function(){var t="new Slider([".concat(this.elements.map((function(t){return t.toCode()})),"], null)");return[t=t.replace(/,\s*\./g,".")]}},{key:"createSlider",value:function(){this.slider=document.createElement("div"),this.slider.style.width="100%",this.slider.style.height="400px",this.slider.style.margin="20px auto",this.slider.style.textAlign="center",this.slider.style.borderRadius="20px",this.slider.style.overflow="hidden",this.slider.style.position="relative";var t=document.createElement("div");this.slidesWrapper=t,t.style.display="flex",t.style.overflowX="scroll",t.style.scrollBehavior="smooth",t.style.scrollSnapType="x mandatory",this.elements.forEach((function(e,r){var n=document.createElement("div");n.setAttribute("class","slide"),n.style.display="flex",n.style.justifyContent="center",n.style.alignItems="center",n.style.flexShrink="0",n.style.width="100%",n.style.height="400px",n.style.background=r%2==0?"rgb(250, 246, 212)":"white",n.style.transformOrigin="center center",n.style.transform="scale(1)",n.style.scrollSnapAlign="center",n.appendChild(e.render()),t.appendChild(n)})),this.arrowPrev=this.buttons.leftButton.render(),this.arrowPrev.style.position="absolute",this.arrowPrev.style.left="10px",this.arrowPrev.style.top="50%",this.arrowPrev.style.transform="translateY(-50%)",this.arrowPrev.style.zIndex="1",this.arrowNext=this.buttons.rightButton.render(),this.arrowNext.style.position="absolute",this.arrowNext.style.right="10px",this.arrowNext.style.top="50%",this.arrowNext.style.transform="translateY(-50%)",this.arrowNext.style.zIndex="1";var e=document.createElement("div");e.style.position="absolute",e.style.bottom="10%",e.style.left="50%",e.style.width="200px",e.style.transform="translateX(-50%)",e.style.textAlign="center",this.elements.forEach((function(t,r){var n=document.createElement("a");n.style.display="inline-block",n.style.height="15px",n.style.width="15px",n.style.borderRadius="50%",n.style.backgroundColor="black",n.style.margin="0 10px",n.style.cursor="pointer",n.dataset.index=r,e.appendChild(n)})),this.slider.appendChild(this.arrowPrev),this.slider.appendChild(this.arrowNext),this.slider.appendChild(t),this.slider.appendChild(e),this.container.appendChild(this.slider),this.slidesWrapper=t,this.navLinks=e.querySelectorAll("a")}},{key:"init",value:function(){this.updateActiveSlide(),this.attachEventListeners()}},{key:"attachEventListeners",value:function(){var t=this;this.arrowPrev.addEventListener("click",(function(){t.moveToSlide(t.currentSlideIndex-1<0?t.elements.length-1:t.currentSlideIndex-1)})),this.arrowNext.addEventListener("click",(function(){t.moveToSlide((t.currentSlideIndex+1)%t.elements.length)})),this.navLinks.forEach((function(e){e.addEventListener("click",(function(r){r.preventDefault();var n=parseInt(e.dataset.index,10);t.moveToSlide(n)}))})),document.addEventListener("keydown",(function(e){"ArrowLeft"===e.key?t.moveToSlide(t.currentSlideIndex-1<0?t.elements.length-1:t.currentSlideIndex-1):"ArrowRight"===e.key&&t.moveToSlide((t.currentSlideIndex+1)%t.elements.length)}))}},{key:"moveToSlide",value:function(t){this.currentSlideIndex=t,this.updateActiveSlide()}},{key:"updateActiveSlide",value:function(){var t=this;this.navLinks.forEach((function(e,r){e.style.backgroundColor=r===t.currentSlideIndex?"green":"gray"}));var e=this.slidesWrapper.querySelector(".slide").offsetWidth;this.slidesWrapper.scrollTo({left:this.currentSlideIndex*e,behavior:"smooth"})}},{key:"render",value:function(t){if(!t)return this.slider;document.querySelector(t).appendChild(this.slider)}}],e&&He(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function Ge(t){return Ge="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ge(t)}function Qe(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Xe(n.key),n)}}function Xe(t){var e=function(t){if("object"!=Ge(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Ge(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Ge(e)?e:e+""}function $e(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return($e=function(){return!!t})()}function Ye(t){return Ye=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},Ye(t)}function Ve(t,e){return Ve=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},Ve(t,e)}var Ue=function(t){function e(t){var r;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(r=function(t,e,r){return e=Ye(e),function(t,e){if(e&&("object"==Ge(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,$e()?Reflect.construct(e,r||[],Ye(t).constructor):e.apply(t,r))}(this,e)).url=t,r.res=null,r.setup(),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Ve(t,e)}(e,t),r=e,(n=[{key:"setup",value:function(){this.res=document.createElement("audio"),this.res.setAttribute("src",this.url),this.res.setAttribute("controls","controls")}},{key:"set",value:function(t){return this.options=t,t.background&&this.background(t.background),this}},{key:"background",value:function(t){var e=document.createElement("style");return e.type="text/css",e.textContent="\n\taudio::-webkit-media-controls-panel {\n\t\tbackground-color: ".concat(t,";\n\t}\n"),document.head.appendChild(e),this}},{key:"toCode",value:function(){return JSON.stringify(this.options,null,4),['new Audio("'.concat(this.url,'")')]}},{key:"size",value:function(t){return this.res.style.width=t,this}},{key:"render",value:function(t){if(!t)return this.res;document.querySelector(t).appendChild(this.res)}}])&&Qe(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function Ke(t){return Ke="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ke(t)}function Ze(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,tr(n.key),n)}}function tr(t){var e=function(t){if("object"!=Ke(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Ke(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Ke(e)?e:e+""}function er(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(er=function(){return!!t})()}function rr(t){return rr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},rr(t)}function nr(t,e){return nr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},nr(t,e)}var ir=function(t){function e(t){var r;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(r=function(t,e,r){return e=rr(e),function(t,e){if(e&&("object"==Ke(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,er()?Reflect.construct(e,r||[],rr(t).constructor):e.apply(t,r))}(this,e)).url=t,r.res=null,r.setup(),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&nr(t,e)}(e,t),r=e,(n=[{key:"setup",value:function(){this.res=document.createElement("video"),this.res.setAttribute("src",this.url),this.res.setAttribute("controls","controls")}},{key:"set",value:function(t){return this.options=t,t.radius&&(this.res.style.borderRadius="1rem"),t.width&&(this.res.style.width="".concat(t.width)),t.opacity&&(this.res.style.opacity=t.opacity),this}},{key:"size",value:function(t){return this.res.style.width=t,this}},{key:"toCode",value:function(){var t=JSON.stringify(this.options,null,4);return['new Video("'.concat(this.url,'").set(').concat(t,")")]}},{key:"render",value:function(t){if(!t)return this.res;document.querySelector(t).appendChild(this.res)}}])&&Ze(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function or(t){return or="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},or(t)}function sr(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function ar(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,lr(n.key),n)}}function lr(t){var e=function(t){if("object"!=or(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=or(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==or(e)?e:e+""}function cr(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(cr=function(){return!!t})()}function ur(t){return ur=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},ur(t)}function dr(t,e){return dr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},dr(t,e)}var hr=function(t){function e(){var t;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(t=function(t,e,r){return e=ur(e),function(t,e){if(e&&("object"==or(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,cr()?Reflect.construct(e,r||[],ur(t).constructor):e.apply(t,r))}(this,e)).res=document.createElement("div"),t.res.style.display="grid",t.attributes={},t}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&dr(t,e)}(e,t),r=e,n=[{key:"set",value:function(t){return this.options=t,this.attributes=t,this.templateCols=t.templateCols,t.templateCols&&(this.res.style.gridTemplateColumns="repeat(".concat(t.templateCols.cols,", 1fr)"),this.res.style.gridTemplateRows="repeat(".concat(t.templateCols.cols,", 1fr)")),this.res.style.height=t.height?t.height:"600px",t.positions&&(this.storedPositions=t.positions),this}},{key:"generateGridPositions",value:function(t){var e=this,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:30,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:50,i=document.createElement("div");i.classList.add("container"),i.style.display="grid",i.style.gridTemplateColumns="repeat(".concat(n,", 1fr)"),i.style.gridTemplateRows="repeat(".concat(r,", 1fr)"),i.style.width="100%",i.style.height="100vh";var o=t.map((function(t,e){return{row:Math.floor(r/2)+e,col:Math.floor(n/2)+e}}));return t.forEach((function(i,s){var a=o[s],l=a.row,c=a.col,u=function(e){var r=0,n=0;return t.forEach((function(t,i){var s=t.weight,a=t.direction,l=o[e],c=o[i],u=l.col-c.col,d=l.row-c.row,h=s*(1/(Math.sqrt(u*u+d*d)+1));switch(a){case"L":r-=h;break;case"R":r+=h;break;case"U":n-=h;break;case"B":n+=h}})),{forceX:r,forceY:n}}(s),d=u.forceX,h=u.forceY;c=Math.max(1,Math.min(n,c+Math.round(d))),l=Math.max(1,Math.min(r,l+Math.round(h))),console.log(e.items.map((function(t){return t.id}))),console.log(i.attract.slice(1));var f=e.items.filter((function(t){return t.id===i.attract.slice(1)}))[0].render();console.log(f),f.style.gridRowStart=l,f.style.gridRowEnd=l+3,f.style.gridColumnStart=c,f.style.gridColumnEnd=c+5,f.style.border="3px solid #".concat(Math.floor(16777215*Math.random()).toString(16).padStart(6,"0")),f.style.display="flex",f.style.alignItems="center",f.style.justifyContent="center",f.style.fontWeight="bold",f.style.color="white",e.res.appendChild(f)})),console.log("ARAO"),console.log(this.res.children.length),this}},{key:"add",value:function(t){this.items=t;var e,r=function(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=function(t,e){if(t){if("string"==typeof t)return sr(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?sr(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,i=function(){};return{s:i,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,s=!0,a=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return s=t.done,t},e:function(t){a=!0,o=t},f:function(){try{s||null==r.return||r.return()}finally{if(a)throw o}}}}(t);try{for(r.s();!(e=r.n()).done;){var n=e.value;this.res.appendChild(n.render())}}catch(t){r.e(t)}finally{r.f()}return this.storedPositions&&this.generateGridPositions(this.storedPositions),console.log("MORAA"),console.log(this.res.children.length),this}},{key:"toCode",value:function(){if(this.excludeFromCodeTrue)return[""];var t=JSON.stringify(this.options,null,4).replace(/"([^"]+)":/g,"$1:"),e="";return e+=".add([\n",e+=this.items.map((function(t){return t.toCode().join("").trim()})).join(",\n"),e+="\n])",["new Free().set(".concat(t,")").concat(e)]}},{key:"render",value:function(t){if(console.log("CHILDREN IN RENDER"),console.log(this.res.children.length),!t)return this.res;document.querySelector(t).appendChild(this.res)}}],n&&ar(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function fr(t){return fr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},fr(t)}function yr(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function pr(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,mr(n.key),n)}}function mr(t){var e=function(t){if("object"!=fr(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=fr(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==fr(e)?e:e+""}function vr(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(vr=function(){return!!t})()}function br(t){return br=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},br(t)}function gr(t,e){return gr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},gr(t,e)}var wr=function(t){function e(){var t;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(t=function(t,e,r){return e=br(e),function(t,e){if(e&&("object"==fr(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,vr()?Reflect.construct(e,r||[],br(t).constructor):e.apply(t,r))}(this,e)).el=null,t}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&gr(t,e)}(e,t),r=e,(n=[{key:"set",value:function(t){var e,r;this.options=t;var n=document.createElement("div");n.style.display="flex",n.style.alignItems="center";var i=document.createElement("input");i.type="checkbox",i.style.position="relative",i.style.marginRight="0.5rem";var o=t.size||"24px";i.style.width=o,i.style.height=o,t.customStyle&&(i.style.appearance="none"),i.style.border="2px solid #ccc",i.style.borderRadius="4px",i.style.backgroundColor=t.backgroundColor||"white",i.style.cursor="pointer",i.style.transition="background-color 0.2s ease, border-color 0.2s ease",i.style.display="inline-block",i.style.setProperty("--checked-bg-color",t.checkedBackgroundColor||"#4CAF50"),i.style.setProperty("--checkmark-color","white"),i.style.setProperty("--checkmark-clip-path",null!==(e=this.options.clipPath)&&void 0!==e?e:"polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%)");var s=document.createElement("style");s.textContent='\n input[type="checkbox"] {\n appearance: none;\n -webkit-appearance: none; /* For Safari */\n width: var(--size, 24px);\n height: var(--size, 24px);\n border: 2px solid #ccc;\n border-radius: 4px;\n background-color: white;\n position: relative;\n cursor: pointer;\n transition: background-color 0.2s ease, border-color 0.2s ease;\n }\n\n input[type="checkbox"]:checked {\n background-color: var(--checked-bg-color, #4CAF50);\n border-color: var(--checked-bg-color, #4CAF50);\n }\n\n input[type="checkbox"]::after {\n content: \'\';\n position: absolute;\n width: 50%;\n height: 50%;\n top: 25%;\n left: 25%;\n transform: scale(0);\n background-color: var(--checkmark-color, white);\n clip-path: var(--checkmark-clip-path);\n -webkit-clip-path: var(--checkmark-clip-path);\n transition: transform 0.2s ease;\n }\n\n input[type="checkbox"]:checked::after {\n transform: scale(1);\n }\n',t.customStyle&&document.head.appendChild(s),t.mar&&this.mar(t.mar),t.pad&&this.pad(t.pad),t.respad&&this.respad(t.respad),t.resmar&&this.resmar(t.resmar),i.addEventListener("change",(function(){i.checked?(i.style.backgroundColor=t.checkedBackgroundColor||"#4CAF50",i.style.borderColor=t.checkedBackgroundColor||"#4CAF50"):(i.style.backgroundColor=t.backgroundColor||"white",i.style.borderColor="#ccc")})),t.name&&i.setAttribute("name",t.name),n.appendChild(i);var a=document.createElement("div");if("function"==typeof(null===(r=t.label)||void 0===r?void 0:r.render))a.appendChild(t.label.render());else{var l=document.createTextNode(t.title||"Label");a.appendChild(l)}return a.style.opacity=.8,a.style.transition="opacity ease 0.2s, transform ease 0.2s",n.appendChild(a),this.el=n,this}},{key:"getValue",value:function(){return this.el.children[0].checked}},{key:"toCode",value:function(){var t=Object.entries(this.options).map((function(t){var e=function(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==e);l=!0);}catch(t){c=!0,i=t}finally{try{if(!l&&null!=r.return&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}(t,e)||function(t,e){if(t){if("string"==typeof t)return yr(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?yr(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(t,2),r=e[0],n=e[1];return"string"==typeof n?"".concat(r,': "').concat(n,'"'):"object"===fr(n)&&null!==n?"function"==typeof n.toCode?"".concat(r,": ").concat(n.toCode()[0]):"".concat(r,": ").concat(JSON.stringify(n,null,4)):"".concat(r,": ").concat(n)})).join(",\n ");return["new Checkbox().set({\n ".concat(t,"\n})")]}},{key:"margin",value:function(t){return this.el.style.margin=t,this}},{key:"render",value:function(t){if(!t)return this.el;document.querySelector(t).appendChild(this.el)}}])&&pr(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function kr(t){return kr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},kr(t)}function xr(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Sr(n.key),n)}}function Sr(t){var e=function(t){if("object"!=kr(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=kr(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==kr(e)?e:e+""}window.Checkbox=wr;var Or=function(){return t=function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.res=null,this.st=e},(e=[{key:"setup",value:function(){var t=document.createElement("div");return t.style.display="grid",this.res=t,this.st&&this.sticky(),this}},{key:"set",value:function(t){return this.setup(),t.height&&(this.res.style.height=t.height),t.sticky&&this.sticky(),this}},{key:"sticky",value:function(){return this.res.style.position="sticky",this.res.style.top=0,this}},{key:"add",value:function(t){this.children=t;for(var e=0;e<t.length;e++){var r=t[e].render();r.style.gridColumn=1,r.style.gridRow=1,this.res.appendChild(r)}return this}},{key:"toCode",value:function(){var t="new Stack().set({})";if(this.children.length>0){var e=this.children.map((function(t){return t.toCode()})).join(",\n");t+=".add([\n \n ".concat(e," \n \n])")}return[t]}},{key:"render",value:function(t){if(!t)return this.res;document.querySelector("body").style.margin=0,document.querySelector("body").style.padding=0,document.querySelector(t).appendChild(this.res)}}])&&xr(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function Cr(t){return Cr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Cr(t)}function jr(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Er(n.key),n)}}function Er(t){var e=function(t){if("object"!=Cr(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Cr(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Cr(e)?e:e+""}var Tr=function(){return t=function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t)},e=[{key:"style",value:function(t){for(var e=t.bst,r=t.el,n=t.re,i=(t.options,[]),o=0;o<e.length;o++)e[o].target&&(r.id,e[o].target[0]);for(o=0;o<e.length;o++){var s=!0;e[o].target&&(s=!1,r.id===e[o].target[0]&&(s=!0));var a=e[o].op.ops.split("-");s&&a.includes("air")&&(n.borderObj={color:"#1abc9c",radius:"0rem",width:"3px"},n.color="#1abc9c",n.background="transparent"),s&&a.includes("round")&&(a.includes("air")?n.borderObj={width:"4px",radius:"0.7rem",color:"#1abc9c"}:n.borderObj={width:"0px",radius:"0.7rem",color:"#1abc9c"}),s&&a.includes("full")&&(n.background="#3498db",n.borderObj&&n.borderObj.radius?n.borderObj.radius="0.3rem":n.color="white"),s&&a.includes("pill")&&(n.background="#3498db",n.borderObj.radius="9999px",n.color="white"),s&&a.includes("hover")&&(n.hover={color:"#1abc9c",background:"orange"}),i.push((new Link).set(n))}return i}}],null&&jr(t.prototype,null),e&&jr(t,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function Pr(t){return Pr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Pr(t)}function Ar(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Rr(n.key),n)}}function Rr(t){var e=function(t){if("object"!=Pr(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Pr(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Pr(e)?e:e+""}var Lr=function(){return t=function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t)},e=[{key:"cards",value:function(t,e,r){console.log("PP"),console.log(r);for(var n=[],i=0;i<t.children.length;i++){var o=t.children[i];"text"===o&&this.insertTextToCard(n,e,t,r),"image"!==o||t.backgroundCard||n.push('\n new Image("https://upload.wikimedia.org/wikipedia/commons/3/3a/Starship_S20.jpg").set({})'),"link"===o&&(e.op?n.push("\n ".concat(r.tabSpace(6)," ").concat(r.link[e.op.theme.toLowerCase()].code)):n.push("\n ".concat(r.tabSpace(6)," ").concat(r.link.base.code)))}return n}},{key:"insertTextToCard",value:function(t,e,r,n){if(e.op)if(e.op.ops&&e.op.ops.includes("text-blast")){var i="\n ".concat(n.tabSpace(6)," ").concat(n.text[e.op.theme.toLowerCase()].code),o=n.ops[e.op.theme.toLowerCase()].blast.code;r.backgroundCard||(o=n.ops[e.op.theme.toLowerCase()].blastFun(1));var s=this.insertTextBetween(i,o);t.push(s)}else t.push("\n ".concat(n.tabSpace(6)," ").concat(n.text[e.op.theme.toLowerCase()].code));else t.push("\n ".concat(n.tabSpace(6)," ").concat(n.text.base.code))}},{key:"insertTextBetween",value:function(t,e){var r=t.match(/(color: ".+?",)(.+?)(id: ".+?")/);if(r){var n=r.index+r[0].length,i=t.slice(0,n)+", "+e+", "+t.slice(n);return console.log("RETA"),console.log(i),i}return t}}],null&&Ar(t.prototype,null),e&&Ar(t,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function zr(t){return zr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},zr(t)}function Mr(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Ir(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Mr(Object(r),!0).forEach((function(e){Br(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Mr(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function Br(t,e,r){return(e=Wr(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function Nr(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Wr(n.key),n)}}function Wr(t){var e=function(t){if("object"!=zr(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=zr(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==zr(e)?e:e+""}var _r=function(){return t=function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t)},e=[{key:"mapType",value:function(t){return["h1","h2","h3","h4","h5","h6","p"].includes(t.el.type)?this.mapText(t):"img"===t.el.type?this.mapImage(t):"a"===t.el.type?this.mapLink(t):"cards"===t.el.type?this.mapGrid(t):"free"===t.el.type?this.mapFree(t):"nav"===t.el.type?this.protoNav(t):"sideNav"===t.el.type?this.sideNav(t):"dropdown"===t.el.type?this.dropdown(t):"modal"===t.el.type?this.modal(t):"slider"===t.el.type?this.slider(t):"table"===t.el.type?this.table(t):"radio"===t.el.type?this.radio(t):"input"===t.el.type?this.input(t):"labelInput"===t.el.type?this.floatInput(t):"filePicker"===t.el.type?this.filePicker(t):"picker"===t.el.type?this.picker(t):"video"===t.el.type?this.video(t):"audio"===t.el.type?this.audio(t):"multiswitcher"===t.el.type?this.multiswitcher(t):"button"===t.el.type?this.button(t):"form"===t.el.type?this.form(t):"checkbox"===t.el.type?this.checkbox(t):"stack"===t.el.type?this.stack(t):"simple"===t.el.type?this.simple(t):void 0}},{key:"button",value:function(){return new Fe("Submit").set({fluidc:"S6",color:"white",background:"#1abc9c",arrpad:{sides:["all"],value:".3rem"},radius:".3rem",onTap:function(){alert("Nice")},keySet:{key:"border",value:"3px solid green"}})}},{key:"multiswitcher",value:function(){return(new ft).set({breakpoints:[{at:"0px",view:new x("First").set({})},{at:"700px",view:new x("Nice").set({})},{at:"800px",view:new x("Best").set({})}]})}},{key:"video",value:function(){return new ir("https://www.w3schools.com/html/mov_bbb.mp4").set({})}},{key:"audio",value:function(){return new Ue("rouska.mp3").set({background:"#1abc9c"})}},{key:"radio",value:function(t){return(new se).set({items:["Male","Female","Third shit"],multiple:!0})}},{key:"input",value:function(t){return(new TextField).set({type:"text",placeholder:"Enter swimming time",arrayMargin:{sides:["all"],value:"1rem"}})}},{key:"floatInput",value:function(t){return(new Kt).set({title:"Your name",type:"input"})}},{key:"filePicker",value:function(t){return(new we).set({id:"A",title:"Add profile picture",background:"#3498DB",color:"white",font:"Arial",radius:"3rem",accept:"application/pdf"})}},{key:"picker",value:function(t){return(new fe).set({items:[["none","select a car---"],["tesla","Tesla"],["audi","Audi"]],font:"Arial",arrayPadding:{sides:["all"],value:"0.5rem"},rounded:!0})}},{key:"modal",value:function(t){}},{key:"slider",value:function(t){var e=[(new Lt).set({}).add([new x("One").set({fluidc:"S1",color:"#1abc9c",font:"Arial"}),new x("First time").set({font:"Arial"})]),new x("Two").set({fluidc:"S1",color:"#1abc9c",font:"Arial"}),new x("Three").set({fluidc:"S1",color:"#1abc9c",font:"Arial"}),new x("Four").set({fluidc:"S1",color:"#1abc9c",font:"Arial"})];return new qe(e,null)}},{key:"dropdown",value:function(t){t.el.items||(t.el.items=["Flower","Car","Maseratti"]);var e=t.el.items.map((function(t){return(new D).set({pad:[{a:10}],font:"Arial",bold:!0,link:"https://www.apple.com",text:t,icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/32/32339.png"},hover:{color:"wheat",animation:.3}})}));return(new xt).set({behaviour:"mouseover",pad:[{a:"1rem"}],mar:[{a:"1rem"}],border:"1px solid black",width:"180px",radius:"1rem"}).add([new x(t.el.items[0]).set({font:"Arial",fluidc:"S6",weight:"bold",align:"center",cursor:"hand",icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/60/60995.png"},pad:[{l:10,r:10}]}),(new Lt).set({border:"1px solid green",background:"#1abc9c",radius:"0.7rem",socenter:!0}).add(e.slice(1))])}},{key:"protoNav",value:function(t){t.customOptions;var e=[{title:"Fire",link:"@e"},{title:"and",link:"@e"},{title:"smoke",link:"@e"}],r=e.map((function(t,e){return new D('"'.concat(t.title,'"')).set({fluidc:"S6",text:t.title,link:t.link,font:"Arial",pad:[{a:40}],bold:!0,hover:{color:"wheat",animation:.3}})})),n=e.map((function(t,e){return new D('"'.concat(t.title,'"')).set({fluidc:"S6",text:t.title,link:t.link,font:"Arial",pad:[{a:40}],bold:!0,hover:{color:"wheat",animation:.3},animation:{range:["0px","1900px"],op:{name:"animation",color:"green",width:"1px",keyframesOpen:[{transform:"translate(100%, ".concat(10*e,"%)"),opacity:0},{transform:"translate(0%)",opacity:1}],keyframesClose:[{transform:"translate(0%)",opacity:1},{transform:"translate(100%, ".concat(10*e,"%)"),opacity:0}],openOptions:{duration:300,fill:"forwards",delay:1e3},closeOptions:{duration:1,fill:"forwards",delay:1e3}}}})}));if(t.el.dropdown){var i=(new xt).set({behaviour:"mouseover",pad:[{a:40}],padding:"10px",border:"1px solid black"}).add([new x("First").set({cursor:"hand",icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/60/60995.png"},fluidc:"S6",pad:[{l:20,r:10}],font:"Arial",align:"center",weight:"bold"}),(new Lt).set({socenter:!0,radius:"0.7rem",background:"#1abc9c",makeResponsiveBehaviour:"undefined"}).add([(new D).set({pad:[{a:10}],font:"Arial",hover:{color:"wheat",animation:.3},bold:!0,link:"https://www.apple.com",text:"Second",icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/32/32339.png"}}),(new D).set({pad:[{a:10}],font:"Arial",hover:{color:"wheat",animation:.3},bold:!0,link:"https://www.apple.com",text:"Third",icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/32/32339.png"}})])]);n.push(i),r.push(i)}return t.el.animation,(new ft).set({breakpoints:[{at:"0px",view:(new nt).set({background:"green",mar:[{a:21}],brand:new x("A").set({size:"S1"}),hamburgerColour:"#3498db",radius:"1rem"}).add([new D("A").set({text:"A",url:"#a"}),(new xt).set({behaviour:"mouseover",pad:[{a:40}],mar:[{lr:"auto"}],breakpoint:"1200px",padding:"10px",border:"1px solid black",height:"auto"}).add([new x("First").set({cursor:"hand",icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/60/60995.png"},fluidc:"S6",pad:[{l:10,r:10}],font:"Arial",align:"center",weight:"bold"}),new x("Firsti").set({cursor:"hand",fluidc:"S6",pad:[{l:10,r:10}],font:"Arial",align:"center",weight:"bold"}),new x("Firstiuu").set({cursor:"hand",fluidc:"S6",pad:[{l:10,r:10}],font:"Arial",align:"center",weight:"bold"})]),new D("B").set({text:"B",url:"#b"}),new D("C").set({text:"C",url:"https://www.abcnews.com"})])},{at:"1200px",view:(new Y).set({background:"green",mar:[{a:21}],maxHeight:"100px",radius:"1rem"}).add([new x("A").set({size:"S1"}),new Gt(!0),(new xt).set({behaviour:"mouseover",pad:[{a:40}],padding:"10px",border:"1px solid black",radius:"30px",width:"130px"}).add([new x("First").set({cursor:"hand",icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/60/60995.png"},fluidc:"S6",pad:[{l:10,r:10}],font:"Arial",align:"center",weight:"bold"}),(new Lt).set({flexDir:"column",background:"orange",mar:[{t:"10px"}],radius:".3rem"}).add([new D("").set({text:"A",url:"jk",cursor:"hand",fluidc:"S6",pad:[{l:10,r:10}],font:"Arial",align:"center",weight:"bold"}),new D("").set({text:"Kivi new TV",url:"#u",cursor:"hand",fluidc:"S6",pad:[{l:10,r:10}],font:"Arial",align:"center",weight:"bold"}),new D("").set({text:"Thanks GPT",url:"#u",cursor:"hand",fluidc:"S6",pad:[{l:10,r:10}],font:"Arial",align:"center",weight:"bold"})])]),new D("Desktop bar").set({text:"Desktop bar",url:"#a"}),new D("B").set({text:"B",url:"#a"}),new D("C").set({text:"C",url:"#a"})])}]})}},{key:"sideNav",value:function(t){t.customOptions;var e=[{title:"Home",link:"@e"},{title:"Projects",link:"@e"},{title:"Services",link:"@e"}],r=e.map((function(t,e){return new D('"'.concat(t.title,'"')).set({fluidc:"S4",text:t.title,link:t.link,isNavA:!0,url:"#e",id:"#"+t.title.toLowerCase(),font:"Arial",pad:[{a:20}],bold:!0,align:"left"})})),n=(new xt).set({behaviour:"mouseover",pad:[{a:40}],padding:"10px",border:"1px solid black",animation:{range:["0px","1900px"],op:{name:"animation",color:"green",width:"1px",keyframesOpen:[{transform:"translate(100%, ".concat(10,"%)"),opacity:0},{transform:"translate(0%)",opacity:1}],keyframesClose:[{transform:"translate(0%)",opacity:1},{transform:"translate(100%, ".concat(10,"%)"),opacity:0}],openOptions:{duration:300,fill:"forwards",delay:1e3},closeOptions:{duration:1,fill:"forwards",delay:1e3}}}}).add([new x("First").set({cursor:"hand",icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/60/60995.png"},fluidc:"S6",pad:[{l:10,r:10}],font:"Arial",align:"center",weight:"bold"}),(new Lt).set({socenter:!0,radius:"0.7rem",background:"#1abc9c",makeResponsiveBehaviour:"undefined"}).add([(new D).set({pad:[{a:10}],font:"Arial",hover:{color:"wheat",animation:.3},bold:!0,link:"https://www.apple.com",text:"Second",icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/32/32339.png"}}),(new D).set({pad:[{a:10}],font:"Arial",hover:{color:"wheat",animation:.3},bold:!0,link:"https://www.apple.com",text:"Third",icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/32/32339.png"}})])]),i=e.map((function(t,e){return new D('"'.concat(t.title,'"')).set({fluidc:"S4",text:t.title,link:t.link,isNavA:!0,url:"#e",id:"#"+t.title.toLowerCase(),font:"Arial",pad:[{a:20}],bold:!0,align:"left",animation:{range:["0px","1900px"],op:{name:"animation",color:"green",width:"1px",keyframesOpen:[{transform:"translate(100%, ".concat(10*e,"%)"),opacity:0},{transform:"translate(0%)",opacity:1}],keyframesClose:[{transform:"translate(0%)",opacity:1},{transform:"translate(100%, ".concat(10*e,"%)"),opacity:0}],openOptions:{duration:300,fill:"forwards",delay:1e3},closeOptions:{duration:1,fill:"forwards",delay:1e3}}}})}));t.el.dropdown&&(i.push(n),r.push(n));var o=(new Lt).set({column:!0}).add([new x("Ultra Reckoning").set({fluidc:"S6",font:"Arial",id:"#olod",italic:!0,animation:{range:["0px","1900px"],op:{name:"animation",color:"green",width:"1px"}},pad:[{l:40},{t:20}]}),t.el.animation?i[0]:r[0],t.el.animation?i[1]:r[1],t.el.animation?i[2]:r[2],t.el.animation&&t.el.dropdown?i[3]:new x("").set({}).excludeFromCode(),new x("Paramount, 2024").set({pad:[{a:20}],animation:{range:["0px","1900px"],op:{name:"animation",color:"green",width:"1px"}}})]),s=(new Lt).set({column:!0}).add([new x("Off canvas").set({fluidc:"S6",font:"Arial",id:"#olod",italic:!0,animation:t.el.animation?{range:["0px","1900px"],op:{name:"animation",color:"green",width:"1px"}}:null,pad:[{l:40},{t:20}]})]);return(new Dt).setup({animate:!0,radius:"1rem",isSide:!0,background:"#ecf0f1",hamColour:{opened:"#1abc9c",closed:"#e67e22"},mobileSize:"1.2em"}).items(t.el.offcanvas?s:o)}},{key:"mapFree",value:function(t){var e=t.customOptions.filter((function(t){return"slayout"===t.op.name||"layout"===t.op.name}))[0],r=null,n={cols:6,rows:6};return"text-above-image"!==e.op.value&&"image-above-text"!==e.op.value||(r=null,n=null),"image-overlay-text"===e.op.value&&(r={text:{row:"1 / span 2",col:"3 / span 2"},image:{row:"2 / span 3",col:"3 / 3"}}),"image-leftof-text"===e.op.value&&(r={text:{row:"1",col:"1 / 3"},image:{row:"1",col:"3 / 4"}}),(new hr).set({id:"#3",templateCols:n,height:"600px"}).add([new x("I am free").set({border:"3px solid green",font:"Arial",fluidc:"S1",color:"#1abc9c",gpos:null!=r?r.text:null,zIndex:1}),new L("https://www.cruisemapper.com/images/ships/2183-e9681865a61.jpg").set({url:"https://www.cruisemapper.com/images/ships/2183-e9681865a61.jpg",width:"400px",height:"auto",gpos:null!=r?r.image:null})])}},{key:"mapText",value:function(t){var e,r=t.el;return console.log("OXERO"),console.log(t.customOptions),console.log(this.filtero("span",r.id,t.customOptions)),new x(r.text||r.value).set({id:r.id,class:r.class,color:r.color,size:this.getElType(r.type),font:null!==(e=r.font)&&void 0!==e?e:"Arial",stroke:this.filtero("blast",r.id,t.customOptions),gradient:this.filtero("gradient",r.id,t.customOptions),animation:this.filtero("animation",r.id,t.customOptions),shadow:this.filtero("shadow",r.id,t.customOptions),span:this.filtero("span",r.id,t.customOptions),backgroundOp:this.filtero("background",r.id,t.customOptions),marginOp:this.filtero("margin",r.id,t.customOptions),transform:this.filtero("transform",r.id,t.customOptions),filtera:this.filtero("filter",r.id,t.customOptions)})}},{key:"mapImage",value:function(t){var e=t.el;return new L(e.url).set(Ir(Ir({},e),{},{isFull:e.isFull,animation:this.filtero("animation",e.id,t.customOptions),shadow:this.filtero("shadow",e.id,t.customOptions),marginOp:this.filtero("margin",e.id,t.customOptions),filtera:this.filtero("filter",e.id,t.customOptions)}))}},{key:"mapLink",value:function(t){var e=t.customOptions.filter((function(t){return"link-style"===t.op.name})),r=t.el;return t.el.id&&(r.id=t.el.id),t.el.link&&t.el.text&&(r.url=t.el.link,r.text=t.el.text),r.keySet={key:"background",value:"shadow: 3px 3px solid green"},r.animation=this.filtero("animation",t.el.id,t.customOptions),r.class=t.el.class,r.width=t.el.width,r.font="Arial",r.fluidc=t.el.fluidc,r.index=t.i+"",r.shadow=this.filtero("shadow",t.el.id,t.customOptions),r.backgroundOp=this.filtero("background",t.el.id,t.customOptions),r.pad=[{a:10}],e.length>0?Tr.style({el:t.el,re:r,bst:e,options:t.customOptions})[e.length-1]:(new D).set(r)}},{key:"mapGrid",value:function(t){var e;console.log("OBJ IS"),console.log(t.storage);var r=[],n=null!==(e=t.customOptions.filter((function(t){return"card-style"===t.op.name}))[0])&&void 0!==e?e:{};r=Lr.cards(t.el,n,t.storage);var i='new Card()\n .set({\n width: "300px", radius: "0.7rem", mar: { sides: ["all"], value: "0.8rem" }})\n .items(['.concat(r.join(",")," \n ])");t.el.backgroundCard&&(i='new ZoomCard().set({url: "https://img.freepik.com/free-photo/seascape-texture-waves-water-generative-ai_169016-30500.jpg", font: "Arial", mar: { sides: ["all"], value: "0.8rem" }, inpad: "1rem", useBrightness: true})\n .items([ \n '.concat(r.join(","),",\n ]), \n"));var o=Array(3).fill(i);return'\n \n new FlexGrid()\n .set({colat: "700px", wrap: true, align: "center"}) \n .items(['.concat(o,"])\n \n")}},{key:"mapCDiv",value:function(t){if(t.customOptions,rta){var e=el;e.makeResponsiveBehaviour=rta.op.hash[0].l,e.index=i;var r={width:"200px",height:"100px"};if(ela=(new Lt).set(e),rta.op.hash[0].child){r.makeResponsiveBehaviour=rta.op.hash[0].child.l;var n=(new Lt).set(r).add([new x("Hello")]);ela=(new Lt).set(e).add([n])}}}},{key:"checkbox",value:function(t){return(new wr).set({name:"acceptTerms",label:new x("Check it out!").set({size:"S6",color:"#1abc9c",font:"Arial"}),mar:"10px"})}},{key:"stack",value:function(t){return(new Or).set({}).add([(new L).set({url:"https://pbs.twimg.com/media/DwYvbCBVAAEKY_R.jpg"}),new x("Samuel Suresh").set({color:"#00ae56",font:"SF Pro Display",fluidc:"S2",pad:{sides:["top","left"],value:20}})])}},{key:"form",value:function(t){return(new ze).set({action:"file.php"}).add([(new Kt).set({title:"Your name",type:"input",name:"name"}),(new Kt).set({title:"Your email",type:"input",name:"email",color:"#3498db",font:"Arial",mar:[{a:"1rem"}]}),(new se).set({name:"gender",items:["Male","Female","Third shit"],multiple:!1,tint:"#1abc9c",font:"Arial",exact:"3rem"}),(new fe).set({name:"car",items:[["none","select a car---"],["tesla","Tesla"],["audi","Audi"]],font:"Arial",arrayPadding:{sides:["all"],value:"0.5rem"},radius:"1rem",background:"#1abc9c"}),(new we).set({id:"A",name:"image",title:"Add profile picture",background:"#3498DB",color:"white",font:"Arial",radius:"3rem"}),new Fe("Submit form").set({type:"submit",background:"#3498db",color:"white",weight:"bold",radius:"1rem",pad:[{a:"1rem"}],mar:[{b:"1rem"}]})])}},{key:"simple",value:function(t){return'new Simple()\n .set({ gap: "10px", height: "700px" })\n .react([\n {\n at: "0", // Default size\n color: "red",\n template: [\n "aaaaaa",\n "bbbbbb",\n "cccccc",\n "dddddd",\n "eeeeee",\n ],\n },\n {\n at: "768", // Medium screen size\n color: "blue",\n template: [\n "aa bbb",\n "aa bbb",\n "cc ddd",\n "ee ddd",\n ],\n },\n {\n at: "1024", // Large screen size\n color: "green",\n template: [\n "aaa bbb",\n "ccc ddd",\n "eee ddd",\n ],\n },\n ])\n .add([\n new Text("Hello A").set({size: "S1"}),\n new Text("Hello B").set({size: "S1"}),\n new Text("Hello C").set({size: "S1"}),\n new Text("Hello D").set({size: "S1"}),\n new Text("Hello E").set({size: "S1"})\n ])'}},{key:"getElType",value:function(t){return"S".concat(t.substr(1))}},{key:"filtero",value:function(t,e,r){return r.filter((function(e){return e.op.name===t})).filter((function(t){return!t.target||t.target.includes(e)}))[0]}}],null&&Nr(t.prototype,null),e&&Nr(t,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();module.exports=e})();
|
|
2
|
+
(()=>{"use strict";var t={d:(e,r)=>{for(var n in r)t.o(r,n)&&!t.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:r[n]})},o:(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r:t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})}},e={};function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}function n(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==e);l=!0);}catch(t){c=!0,i=t}finally{try{if(!l&&null!=r.return&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}(t,e)||s(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function o(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=s(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,i=function(){};return{s:i,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,l=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return a=t.done,t},e:function(t){l=!0,o=t},f:function(){try{a||null==r.return||r.return()}finally{if(l)throw o}}}}function s(t,e){if(t){if("string"==typeof t)return a(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?a(t,e):void 0}}function a(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function l(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,c(n.key),n)}}function c(t){var e=function(t){if("object"!=r(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=r(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==r(e)?e:e+""}t.r(e),t.d(e,{ElementMapper:()=>_r});var u=function(){return t=function t(){var e,r,n,i=this;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),e=this,n=function(t){if(t.transform||t.op&&t.op.transform){var e=t.transform;t.transform||(e=t.op.transform),e.duration||(e.duration="3s-ease-in-out"),i.setDefault=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"0px";return 0===t.length?e+" ":t};var r=function(){var r="",n="",o="",s="",a="",l="",c="",u="",d="";if(0!==e.values.length){e.values.forEach((function(t){t.startsWith("tx:")&&(r=t.replace("tx:","")),t.startsWith("ty:")&&(n=t.replace("ty:","")),t.startsWith("tz:")?o=t.replace("tz:",""):t.startsWith("scale(")?s=t:t.startsWith("skew(")?a=t:t.startsWith("rotate(")?l=function(t){var e=t.match(/rotate\(([^)]+)\)/);if(!e)return t;var r=e[1].split(",").map((function(t){return t.trim()}));return 1===r.length?"rotate(".concat(r[0],")"):2===r.length?"rotateX(".concat(r[0],") rotateY(").concat(r[1],")"):3===r.length?"rotateX(".concat(r[0],") rotateY(").concat(r[1],") rotate(").concat(r[2],")"):t}(t):t.startsWith("perspective(")?c=t:t.startsWith("matrix(")?u=t:t.startsWith("opacity:")&&(d=t.replace("opacity:",""))})),r=i.setDefault(r),n=i.setDefault(n),o=i.setDefault(o);var h="";if("0px"!=n&&"0px"!=r&&"0px"!=o?h+="translate3d(".concat(r,", ").concat(n,", ").concat(o,")"):"0px"==n&&"0px"==r||(h+="translate(".concat(r,", ").concat(n,")")),s&&(h+=" ".concat(s)),l&&(h+=" ".concat(l)),a&&(h+=" ".concat(a)),c&&(h+=" ".concat(c)),u&&(h+=" ".concat(u)),h){if(t.op.transform.duration){var f=t.op.transform.duration.replace(/^(\d+)(s)-/,(function(t,e,r){return e/2+r+" "})),y="transform ".concat(f,", opacity ").concat(f);i.res.style.transition=y}else i.res.style.transition="transform 3s ease-in-out, opacity 3s ease-in-out";i.res.style.transform=h,i.res.style.opacity=d}}};e.on?i.res.addEventListener(e.on,(function(){e.delay?setTimeout((function(){r()}),e.delay):r()})):window.addEventListener("load",(function(){e.delay?setTimeout((function(){r()}),e.delay):r()}));var n=function(){var t="";e.values.forEach((function(e){e.startsWith("tx:")?t+="translateX(0) ":e.startsWith("ty:")?t+="translateY(0) ":e.startsWith("tz:")?t+="translateZ(0) ":e.startsWith("scale(")?t+="scale(1) ":e.startsWith("skew(")?t+="skew(0, 0) ":e.startsWith("rotate(")?t+="rotate(0) ":e.startsWith("perspective(")?t+="perspective(0) ":e.startsWith("matrix(")&&(t+="matrix(1, 0, 0, 1, 0, 0) "),i.res.style.opacity="1"})),t&&(i.res.style.transform=t.trim())};if(e.on)i.res.addEventListener("mouseout",(function(){e.keep||n()}));else{var o=1e3*parseFloat(e.duration),s=e.closeAfter?e.closeAfter:0;setTimeout((function(){e.keep||n()}),o/2+s)}}},(r=c(r="reactOnTransform"))in e?Object.defineProperty(e,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[r]=n,this.state={isExpanded:!1,isMovedUp:!1,isMovedDown:!1}},e=[{key:"keySet",value:function(t){return this.temporaryVal=1,this.res.style[t.key]=t.value,this}},{key:"onScroll",value:function(t){var e=this;"opacity"===t.value?this.res.style.opacity=t.valMin:"scale"===t.value&&(this.res.style.transform="scale(".concat(t.valMax,")")),window.addEventListener("scroll",(function(){var r=e.smartRange(window.scrollY,{min:t.from,max:t.to},{min:t.valMin,max:t.valMax});"opacity"===t.value?e.res.style.opacity=r:"scale"===t.value&&(e.res.style.transform="scale(".concat(r,")"))}))}},{key:"setAny",value:function(t){this[Object.keys(t)[0]]=[Object.values(t)[0]]}},{key:"setID",value:function(t){this.id=t}},{key:"setPrevText",value:function(t){this.prevText=t}},{key:"getCSS",value:function(){return this.css}},{key:"getPX",value:function(t){return{xs:"0px",sm:"576px",md:"768px",lg:"992px",xl:"1200px",xxl:"1400px",mxxl:"1800px"}[t]||"Invalid breakpoint"}},{key:"respad",value:function(t){var e=this,r=function(){e.pad(t[0].values);for(var r=0;r<t.length;r++){var n=t[r].breakpoint;window.matchMedia("(min-width: ".concat(e.getPX(n))).matches&&e.pad(t[r].values)}};window.addEventListener("resize",r),r()}},{key:"resmar",value:function(t){var e=this,r=function(){e.mar(t[0].values);for(var r=0;r<t.length;r++){var n=t[r].breakpoint;window.matchMedia("(max-width: ".concat(e.getPX(n))).matches&&e.mar(t[r].values)}};window.addEventListener("resize",r),r()}},{key:"resprop",value:function(t){var e=this;this.prevBackground=this.res.style.background,this.prevWidth=this.res.style.width,this.prevHeight=this.res.style.height,this.prevBorder=this.res.style.border;var r=function(){e.res.style.background=e.prevBackground,e.res.style.width=e.prevWidth,e.res.style.height=e.prevHeight,e.res.style.border=e.prevBorder;for(var r=0;r<t.length;r++){var n=t[r].breakpoint;if(window.matchMedia("(max-width: ".concat(e.getPX(n))).matches){var i={};for(var o in t[r])"breakpoint"!==o&&(i[o]=t[r][o]);e.set(i)}}};window.addEventListener("resize",r),r()}},{key:"isNumber",value:function(t){return"number"==typeof t&&!isNaN(t)}},{key:"pad",value:function(t){for(var e=0;e<t.length;e++)for(var r=Object.keys(t[e]),n=0;n<r.length;n++)for(var i=r[n],o=t[e][i],s=0;s<i.length;s++)switch(i[s]){case"a":this.res.style.padding=this.isNumber(o)?"".concat(o,"px"):o;break;case"t":this.res.style.paddingTop=this.isNumber(o)?"".concat(o,"px"):o;break;case"l":this.res.style.paddingLeft=this.isNumber(o)?"".concat(o,"px"):o;break;case"r":this.res.style.paddingRight=this.isNumber(o)?"".concat(o,"px"):o;break;case"b":this.res.style.paddingBottom=this.isNumber(o)?"".concat(o,"px"):o}return this}},{key:"as",value:function(t){return this.res.style.alignSelf=t,this}},{key:"mar",value:function(t){for(var e=0;e<t.length;e++)for(var r=Object.keys(t[e]),n=0;n<r.length;n++)for(var i=r[n],o=t[e][i],s=0;s<i.length;s++){switch(i[s]){case"a":this.res.style.margin=this.isNumber(o)?"".concat(o,"px"):o;break;case"t":this.res.style.marginTop=this.isNumber(o)?"".concat(o,"px"):o;break;case"l":this.res.style.marginLeft=this.isNumber(o)?"".concat(o,"px"):o;break;case"r":this.res.style.marginRight=this.isNumber(o)?"".concat(o,"px"):o;break;case"b":this.res.style.marginBottom=this.isNumber(o)?"".concat(o,"px"):o}"auto"===i[s]&&(this.res.style.marginLeft="auto",this.res.style.marginRight="auto")}return this}},{key:"smartRange",value:function(t,e,r){t<e.min&&(t=e.min),t>e.max&&(t=e.max);var n=(t-e.min)/(e.max-e.min);e.min>e.max&&(n=(t-e.max)/(e.min-e.max));var i=(r.min-r.max)*n-r.min;if(i=Math.abs(i),r.min<r.max){var o=(r.max+Math.abs(r.min))*n;i=r.min+o}return i}},{key:"gpos",value:function(t){return this.res.style.gridColumn=t.col,this.res.style.gridRow=t.row,this}},{key:"fluidCopy",value:function(t){if(t instanceof Object){this.prevStylex=this.res.style,this.res=document.createElement("h1"),this.res.style.cssText=this.prevStylex.cssText;var e=document.createTextNode(this.text);return this.res.appendChild(e),this.res.style.fontSize=t.exact,this}if("S1"===t){this.prevStylex=this.res.style,this.res=document.createElement("h1"),this.res.style.cssText=this.prevStylex.cssText;var r=document.createTextNode(this.text);this.res.appendChild(r),this.res.style.fontSize="calc(1.625rem + 5.075vw)"}if("S2"===t){this.prevStylex=this.res.style,this.res=document.createElement("h2"),this.res.style.cssText=this.prevStylex.cssText;var n=document.createTextNode(this.text);this.res.appendChild(n),this.res.style.fontSize="calc(1.500rem + 4.3vw)"}if("S3"===t){this.prevStylex=this.res.style,this.res=document.createElement("h3"),this.res.style.cssText=this.prevStylex.cssText;var i=document.createTextNode(this.text);this.res.appendChild(i),this.res.style.fontSize="calc(1.375rem + 3.525vw)"}if("S4"===t){this.prevStylex=this.res.style,this.res=document.createElement("h4"),this.res.style.cssText=this.prevStylex.cssText;var o=document.createTextNode(this.text);this.res.appendChild(o),this.res.style.fontSize="calc(1.250rem + 2.75vw)"}if("S5"===t){this.prevStylex=this.res.style,this.res=document.createElement("h5"),this.res.style.cssText=this.prevStylex.cssText;var s=document.createTextNode(this.text);this.res.appendChild(s),this.res.style.fontSize="calc(1.125rem + 1.975vw)"}return"S6"===t&&(this.res.style.fontSize="calc(1rem + 0.5vw)"),this}},{key:"setIndex",value:function(t){this.index=t}},{key:"borderObj",value:function(t){var e,r=null!==(e=t.type)&&void 0!==e?e:"solid";return this.res.style.border="".concat(t.width," ").concat(r," ").concat(t.color),this.res.style.borderRadius=t.radius,this}},{key:"protoReact",value:function(t,e){var r=this;t.sort((function(t,e){return parseInt(t.range[0])-parseInt(e.range[0])}));var i=function(){var i=window.innerWidth,s="";r.storedQueries=t.map((function(t){return t.target})).filter((function(t){return null!=t}));var a,l=o(t);try{for(l.s();!(a=l.n()).done;){var c=a.value;r.counterIndex++;var u=n(c.range,2),d=u[0],h=u[1],f=parseInt(d),y=parseInt(h),p=!0;if(c.target){p=!1;for(var m=0;m<c.target.length;m++)c.target[m]===e&&(p=!0)}i>=f&&i<=y&&p&&("gradient"===c.log&&(s+="gradient"),"blast"===c.log&&(s+="blast"),"animation"===c.log&&(s+="animation"),"shadow"===c.log&&(s+="shadow"),"span"===c.log&&(s+="span"),"filter"===c.log&&(s+="filter"),"background"===c.log&&(s+="background"))}}catch(t){l.e(t)}finally{l.f()}r.res.style.margin="";var v,b=r.res.style.color;for(t.map((function(t){return t.log})).filter((function(t){return null!=t})).includes("gradient")&&(r.res.style.WebkitBackgroundClip="",r.res.style.background=""),r.res.style["-webkit-text-stroke"]="",r.res.style.filter="",r.res.style.textShadow="",r.res.style.border="";r.res.firstChild;)r.res.removeChild(r.res.firstChild);if(r.res.textContent=r.text,""===s&&(r.res.style["-webkit-text-fill-color"]="",r.res.style.color=b),"blast"===s){for(m=0;m<t.length;m++){var g=t[m].op.offsets;g&&void 0!==r.index&&(r.res.style.margin=g[Number(r.index)]+"px")}for(r.res.style["-webkit-text-fill-color"]="transparent",r.res.style["-webkit-text-stroke"]=r.globalBlast,m=0;m<t.length;m++){var w=t[m].op.offsets;w&&void 0!==r.index&&(r.res.style.margin=w[Number(r.index)]+"px")}}if("gradient"===s&&(r.res.style["-webkit-text-fill-color"]="transparent",r.res.style.background=r.globalGradient,r.res.style["-webkit-background-clip"]="text",r.res.style.border="1px solid orange"),"background"===s&&(r.res.style.background="orange"),"gradientblast"===s&&(r.res.style["-webkit-text-fill-color"]="transparent",r.res.style.background=r.globalGradient,r.res.style["-webkit-background-clip"]="text",r.res.style["-webkit-text-stroke"]=r.globalBlast),"gradientanimation"===s&&(r.res.style["-webkit-text-fill-color"]="transparent",r.res.style.background=r.globalGradient,r.res.style["-webkit-background-clip"]="text"),"gradientanimationshadow"===s&&(r.res.style["-webkit-text-fill-color"]="transparent",r.res.style.background=r.globalGradient,r.res.style["-webkit-background-clip"]="text",r.res.style.textShadow=r.globalShadow),"animationshadow"===s&&(r.res.style["-webkit-text-fill-color"]="",r.res.style.textShadow=r.globalShadow),"shadow"===s&&(r.res.style["-webkit-text-fill-color"]="",r.res.style.textShadow=r.globalShadow),"span"===s&&r.options.span)for(v=Array.isArray(r.options.span)?r.options.span.filter((function(t){return"span"===t.op.name}))[0]:r.options.span,r.res.textContent="",m=0;m<v.op.parts.length;m++){var k=v.op.parts[m].style,x=new Text(v.op.parts[m].text).setup({type:"span"}).set(k).render();r.res.appendChild(x)}if("filter"===s){var S=r.options.filtera.op.filter;r.res.style.filter=S,r.res.style.border="8px solid orange"}};window.addEventListener("resize",i),i()}},{key:"setPref",value:function(t){this.preffersId=t}},{key:"setClass",value:function(t){this.class=t}},{key:"betaReact",value:function(t,e){var r=this;this.ap=!1,this.cta=0,this.once=!1,t.sort((function(t,e){return parseInt(t.range[0])-parseInt(e.range[0])}));var i=function(){var i=window.innerWidth,s="";r.resCopy=r.res,r.storedQueries=t.map((function(t){return t.target})).filter((function(t){return null!=t}));var a,l=o(t);try{for(l.s();!(a=l.n()).done;){var c=a.value;r.counterIndex++;var u=n(c.range,2),d=u[0],h=u[1],f=parseInt(d),y=parseInt(h),p=!0;if(c.target){p=!1;for(var m=0;m<c.target.length;m++)c.target[m]===e&&(p=!0)}i>=f&&i<=y&&p&&("blast"===c.log&&(s+="blast"),"shadow"===c.log&&(s+="shadow"),"background"===c.log&&(s+="background"),"gradient"===c.log&&(s+="gradient"),"spana"===c.log&&(s+="spana"),"layout"===c.log&&(s+="layout"),"margin"===c.log&&(s+="margin"),c.op&&c.op.margin&&(r.useMargin=c.op.margin))}}catch(t){l.e(t)}finally{l.f()}if(r.res.style.background="",r.res.style.backgroundColor="",r.res.style.textShadow="",r.res.style.border="",r.res.style.margin="",r.res.style["-webkit-text-fill-color"]="",r.res.style["-webkit-text-stroke"]="",r.res.style["-webkit-text-stroke-width"]="","background"===s&&(r.res.style.backgroundColor="green"),"margin"===s)for(m=0;m<t.length;m++)if(t[m].op){var v=t[m].op.offsets;v&&void 0!==r.index&&(r.res.style.margin=v[Number(r.index)]+"px")}if("blastbackgroundmargin"===s){for(m=0;m<t.length;m++)if(t[m].op){var b=t[m].op.offsets;b&&void 0!==r.index&&(r.res.style.margin=b[Number(r.index)]+"px")}r.res.style.backgroundColor="green","FlexRowLayoutElement"===r.getType()?r.res.style.border="1px solid orange":(r.res.textContent=r.text,r.res.style["-webkit-text-fill-color"]="transparent",r.res.style["-webkit-text-stroke-color"]="orange",r.res.style["-webkit-text-stroke-width"]="1px"),r.res.style["-webkit-text-fill-color"]="transparent",r.res.style["-webkit-text-stroke-color"]="orange",r.res.style["-webkit-text-stroke-width"]="1px"}if("blastbackground"===s){for(m=0;m<t.length;m++)if(t[m].op){var g=t[m].op.offsets;g&&void 0!==r.index&&(r.res.style.margin=g[Number(r.index)]+"px")}r.res.style.backgroundColor="green",r.useMargin?r.res.style.margin="1rem":r.res.setAttribute("id","iofhwoiefhoih"),"FlexRowLayoutElement"===r.getType()?r.res.style.border="1px solid orange":(r.res.textContent=r.text,r.res.style["-webkit-text-fill-color"]="transparent",r.res.style["-webkit-text-stroke-color"]="orange",r.res.style["-webkit-text-stroke-width"]="1px"),r.res.style["-webkit-text-fill-color"]="transparent",r.res.style["-webkit-text-stroke-color"]="orange",r.res.style["-webkit-text-stroke-width"]="1px"}if("layout"===s&&(r.res.style.alignSelf="start",r.res.style.border="1px solid purple"),"blast"===s){for(m=0;m<t.length;m++)if(t[m].op){var w=t[m].op.offsets;w&&void 0!==r.index&&(r.res.style.margin=w[Number(r.index)]+"px")}"FlexRowLayoutElement"===r.getType()?r.res.style.border="1px solid orange":(r.res.textContent=r.text,r.res.style["-webkit-text-fill-color"]="transparent",r.res.style["-webkit-background-clip"]="text",r.res.style["-webkit-text-stroke-color"]="orange",r.res.style["-webkit-text-stroke-width"]="1px"),r.res.style["-webkit-text-fill-color"]="transparent",r.res.style["-webkit-text-stroke"]="orange",r.res.style["-webkit-text-stroke-width"]="1px"}"blastgradientbackground"===s&&(r.res.style.border="1px solid yellow",r.res.style["-webkit-text-stroke-color"]="orange",r.res.style["-webkit-text-stroke-width"]="1px"),"gradient"===s&&(r.res.style.background="linear-gradient(to left, #3498db, #1abc9c)","FlexRowLayoutElement"===r.getType()||(r.res.children[0]&&r.res.removeChild(r.res.children[0]),r.res.style["-webkit-text-fill-color"]="transparent",r.res.style["-webkit-background-clip"]="text",r.res.textContent=r.text)),"shadow"===s&&("FlexRowLayoutElement"===r.getType()||(r.res.children[0]&&r.res.removeChild(r.res.children[0]),r.res.style["-webkit-text-fill-color"]="",r.res.style["-webkit-text-fill-color"]="",r.res.style.textShadow="#1abc9cff -6px 6px , #1abc9c40 -12px 12px",r.res.textContent=r.text))};window.addEventListener("resize",i),i()}},{key:"cssGen",value:function(t,e,r,n){return this.css=[""],[""]}},{key:"chainReact",value:function(t,e,r){var i=this;this.cssGen(t,e,this.class,void 0!==this.class),this.ap=!1,this.cta=0,this.once=!1;var s,a=o(t);try{for(a.s();!(s=a.n()).done;){var l=s.value;l.range||(l.range=["0px","999999px"])}}catch(t){a.e(t)}finally{a.f()}t.sort((function(t,e){return parseInt(t.range[0])-parseInt(e.range[0])}));var c=function(){var s=window.visualViewport.width,a=[],l=[];i.resCopy=i.res,i.storedQueries=t.map((function(t){return t.target})).filter((function(t){return null!=t}));var c,u=o(t);try{for(u.s();!(c=u.n()).done;){var d=c.value;i.counterIndex++;var h=n(d.range,2),f=h[0],y=h[1],p=parseInt(f),m=parseInt(y),v=!0;if(d.target){v=!1;for(var b=0;b<d.target.length;b++)d.target[b]===e&&(v=!0)}s>=p&&s<=m&&v&&(a.push(d.log),l.push(d),d.op&&d.op.margin&&(i.useMargin=d.op.margin))}}catch(t){u.e(t)}finally{u.f()}if(r&&!r.includes("background")&&(i.res.style.background="",i.res.style.backgroundColor=""),i.res.style.textShadow="",r&&!r.includes("border")&&(i.res.style.border=""),r&&!r.includes("margin")&&(i.res.style.margin=""),i.res.style["-webkit-text-fill-color"]="",i.res.style["-webkit-text-stroke-color"]="",i.res.style["-webkit-text-stroke-width"]="",i.res.style.filter="",(a.includes("gradient")||a.includes("shadow"))&&(i.res.style.position="relative",i.res.style.zIndex=-1),a.includes("blast")){var g,w=l.filter((function(t){return"blast"===t.log}))[0].op.color,k=null!==(g=l.filter((function(t){return"blast"===t.log}))[0].op.width)&&void 0!==g?g:"1px";"FlexRowLayoutElement"===i.getType()?i.res.style.border="".concat(k,"px solid orange"):(i.res.textContent=i.text,i.res.style["-webkit-text-fill-color"]="transparent",i.res.style["-webkit-text-stroke-color"]=w,i.res.style["-webkit-text-stroke-width"]="".concat(k))}if(a.includes("filter")){var x=l.filter((function(t){return"filter"===t.log}))[0].op.filter;i.res.style.filter=x}if(a.includes("background")&&(i.res.style.backgroundColor="green"),a.includes("gradient")&&(i.res.style["-webkit-text-fill-color"]="transparent",i.res.style.background=i.globalGradient,i.res.style["background-clip"]="text"),a.includes("shadow"))if("FlexRowLayoutElement"===i.getType());else{var S="",O=0;for(b=0;b<i.options.shadow.op.steps;b++)S+="drop-shadow(".concat(O+=3,"px ").concat(O,"px ").concat(O,"px gray) ");i.res.style.filter=S}if(a.includes("margin"))for(b=0;b<t.length;b++)if(t[b].op){var C=t[b].op.offsets;C&&void 0!==i.index&&(i.res.style.margin=C[Number(i.index)]+"px")}if(a.includes("spana")||a.includes("span")){if(i.res=i.resCopy,i.options.span){var j;for(j=Array.isArray(i.options.span)?i.options.span.filter((function(t){return"span"===t.op.name}))[0]:i.options.span,i.res.textContent="",b=0;b<j.op.parts.length;b++){var E=j.op.parts[b].style,T=new i.constructor(j.op.parts[b].text).setup({type:"span"}).set(E).render();i.res.appendChild(T)}}}else{for(;i.res.firstChild;)i.res.removeChild(i.res.firstChild);var P=new i.constructor(i.prevText).set({}).render();i.res.appendChild(P)}if(a.includes("animation")){if(i.options.animation&&!i.hasAnimated&&!i.options.animation.op.fireAt){i.hasAnimated=!0;var A=i.options.animation.op;i.res.animate(A.keyframesClose,{duration:0,fill:"forwards"}),i.res.animate(A.keyframesOpen,A.openOptions)}if(i.options.animation&&i.options.animation.op.fireAt&&i.options.animation.op.fireAt.endsWith("px")){var R=i.options.animation.op;i.res.animate(R.keyframesClose,{duration:0,fill:"forwards"});var L=function(){window.scrollY>parseFloat(R.fireAt)&&(i.res.animate(R.keyframesOpen,R.openOptions),window.removeEventListener("scroll",L))};window.addEventListener("scroll",L)}if(i.options.animation&&i.options.animation.op.fireAt&&"inview"===i.options.animation.op.fireAt){var z=i.options.animation.op;i.res.animate(z.keyframesClose,{duration:0,fill:"forwards"}),new IntersectionObserver((function(t,e){t.forEach((function(t){t.isIntersecting&&(i.res.animate(z.keyframesOpen,z.openOptions),e.disconnect())}))})).observe(i.res)}}};window.addEventListener("resize",c),c()}},{key:"maxWidth",value:function(t){return this.res.style.maxWidth=t,this}},{key:"removeQuotesFromFirstWord",value:function(t){return t.replace(/"([^"]+)":/g,"$1:")}},{key:"arrayMargin",value:function(t,e){return t.includes("left")&&(this.res.style.marginLeft=e),t.includes("right")&&(this.res.style.marginRight=e),t.includes("top")&&(this.res.style.marginTop=e),t.includes("bottom")&&(this.res.style.marginBottom=e),t.includes("all")&&(this.res.style.margin=e),e||(this.res.style.marginBottom=t),this}},{key:"navBarExpand",value:function(){return this.res.style.backgroundColor="green",this.res.animate([{transform:"scaleY(3.0)"}],{duration:2e3,iterations:1,fill:"both"}),this}},{key:"scrollFade",value:function(t,e){return this.res.style.visibility="hidden",this.faden(t,e,"scroll"),this}},{key:"expand",value:function(t){var e=this;return!1===this.state.isExpanded?"click"===t.on?this.res.addEventListener("click",(function(){e.innerExpand(t)})):this.innerExpand(t):this.innerExpandBack(t),this.state.isExpanded=!this.state.isExpanded,this}},{key:"move",value:function(t){var e=this;return"click"===t.on?this.res.addEventListener("click",(function(){e.moveUpa(t)})):("up"===t.direction&&this.moveUpa(t),"down"===t.direction&&this.moveDowna(t),this.state.isMovedUp=!this.state.isMovedUp,"left"===t.direction&&this.moveLeft(t)),this}},{key:"moveLeft",value:function(t){return this.res.animate([{transform:"translateX(0px)"},{transform:"translateX(-".concat(t.distance,")")}],{duration:900,iterations:t.iterations,fill:"both"}).play(),this}},{key:"moveUpa",value:function(t){return!1===this.state.isMovedUp?this.res.animate([{transform:"translateX(0px)"},{transform:"translateY(-".concat(t.distance,")")}],{duration:900,iterations:t.iterations,fill:"both"}).play():this.res.animate([{transform:"translateX(0px)"},{transform:"translateY(".concat(t.distance,")")}],{duration:900,iterations:t.iterations,fill:"both"}).play(),this}},{key:"moveDowna",value:function(t){return!1===this.state.isMovedDown?this.res.animate([{transform:"translateX(0px)"},{transform:"translateY(".concat(t.distance,")")}],{duration:900,iterations:t.iterations,fill:"both"}).play():this.res.animate([{transform:"translateX(0px)"},{transform:"translateY(-".concat(t.distance,")")}],{duration:900,iterations:t.iterations,fill:"both"}).play(),this}},{key:"moveUpaBack",value:function(t){return this.res.animate([{transform:"translateX(0px)"}],{duration:900,iterations:t.iterations,fill:"both"}).play(),this}},{key:"innerExpandBack",value:function(t){this.res.animate([{width:this.prevWidth,height:this.prevHeight}],{duration:900,iterations:t.iterations,fill:"both"})}},{key:"innerExpand",value:function(t){var e,r;return this.prevWidth=this.res.style.width,this.prevHeight=this.res.style.height,this.res.animate([{width:this.prevWidth,height:this.prevHeight},{width:null!==(e=t.width)&&void 0!==e?e:this.prevWidth,height:null!==(r=t.height)&&void 0!==r?r:this.prevHeight}],{duration:900,iterations:t.iterations,fill:"both"}),this}},{key:"fade",value:function(t){return this.res.style.visibility="hidden",this.faden(t.duration,t.from,"load"),t.finalOpacity&&(this.finalOpacity=t.finalOpacity),this}},{key:"faden",value:function(t,e,r){var n=this;return this.res.style.visibility="hidden",this.scrolled=!1,window.addEventListener(r,(function(){n.res.style.visibility="visible";var i=window.innerHeight;(n.res.getBoundingClientRect().top-i<=0||"load"==r)&&0==n.scrolled&&("left"==e&&n.res.animate([{transform:"translateX(-30px)"},{transform:"translateX(0px)"}],{duration:t,iterations:1}),"right"==e&&n.res.animate([{transform:"translateX(30px)"},{transform:"translateX(0px)"}],{duration:t,iterations:1}),"top"==e&&n.res.animate([{transform:"translateY(-30px)"},{transform:"translateY(0px)"}],{duration:t,iterations:1}),"bottom"==e&&n.res.animate([{transform:"translateY(30px)"},{transform:"translateY(0px)"}],{duration:t,iterations:1}),n.res.animate([{opacity:"0.0"},{opacity:"1.0"}],{duration:t,iterations:1}),n.scrolled=!0)})),this}}],e&&l(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function d(t){return d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},d(t)}function h(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==e);l=!0);}catch(t){c=!0,i=t}finally{try{if(!l&&null!=r.return&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}(t,e)||f(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function f(t,e){if(t){if("string"==typeof t)return y(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?y(t,e):void 0}}function y(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function p(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,m(n.key),n)}}function m(t){var e=function(t){if("object"!=d(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=d(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==d(e)?e:e+""}function v(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(v=function(){return!!t})()}function b(t,e,r,n){var i=g(w(1&n?t.prototype:t),e,r);return 2&n&&"function"==typeof i?function(t){return i.apply(r,t)}:i}function g(){return g="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(t,e,r){var n=function(t,e){for(;!{}.hasOwnProperty.call(t,e)&&null!==(t=w(t)););return t}(t,e);if(n){var i=Object.getOwnPropertyDescriptor(n,e);return i.get?i.get.call(arguments.length<3?t:r):i.value}},g.apply(null,arguments)}function w(t){return w=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},w(t)}function k(t,e){return k=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},k(t,e)}var x=function(t){function e(t,r){var n;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(n=function(t,e,r){return e=w(e),function(t,e){if(e&&("object"==d(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,v()?Reflect.construct(e,r||[],w(t).constructor):e.apply(t,r))}(this,e)).text=t,n.res=null,n.setup(r),n.code=[],n.elCSS=[],n.html=[],n.react=[],n.code.push('new Text("'.concat(n.text,'")')),console.log("AAAAA"),n}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&k(t,e)}(e,t),r=e,n=[{key:"flexOne",value:function(){return this.res.style.flex="1",this}},{key:"setGridWithoutCode",value:function(){return this.res.style.border="1px solid white",this}},{key:"setArea",value:function(t){return this.res.style.gridArea=t,this}},{key:"toCodea",value:function(){return this.excludeFromCodeTrue&&(this.code=[""]),this.code}},{key:"toCode",value:function(){if(this.excludeFromCodeTrue)return[""];var t=Object.fromEntries(Object.entries(this.options).filter((function(t){var e=h(t,2);return e[0],null!==e[1]}))),e=JSON.stringify(t,null,4).replace(/"([^"]+)":/g,"$1:");return console.log("OCO"),console.log(e),['new Text("'.concat(this.text,'").set(').concat(e,")")]}},{key:"toCSS",value:function(){return this.css}},{key:"toHTMLA",value:function(){return this.html}},{key:"toElCSS",value:function(){return this.elCSS=this.elCSS.map((function(t){return" "+t})),this.preffersId?this.elCSS.unshift(this.res.id+" { \n"):this.elCSS.unshift("."+this.class+" { \n"),this.elCSS.push(" } \n \n"),this.elCSS}},{key:"getType",value:function(){return"S1"===this.options.fluidc?"HTMLHeaderElement":"HTMLParagraphElement"}},{key:"gradientOptions",value:function(t){var e=this;if(0===t.length)return this;var r=t.filter((function(t){return"gradient"===t.op.name}))[0];if(void 0===r)return this;var n=r.op;if(r.point){var i=function(){window.matchMedia("(min-width: ".concat(r.range[0],") and (max-width: ").concat(r.range[1],")")).matches&&(e.prevBackground=e.res.style.color.toString(),e.res.style.background=n.gradient,e.res.style.WebkitBackgroundClip="text")};i(),window.addEventListener("resize",i)}}},{key:"strokeOptions",value:function(t){var e=this;if(0===t.length)return this;var r=t.filter((function(t){return"blast"===t.op.name}))[0];if(void 0===r)return this;console.log("DEL");var n=r.op;if(r.point){var i=function(){window.matchMedia("(min-width: ".concat(r.range[0],") and (max-width: ").concat(r.range[1],")")).matches&&(n.color?e.res.style["-webkit-text-stroke"]="".concat(n.width?n.width:"1px"," ").concat(n.color):e.res.style["-webkit-text-stroke"]="1px orange",e.res.style["-webkit-text-fill-color"]="transparent")};i(),window.addEventListener("resize",i)}else n.color&&(this.res.style["-webkit-text-stroke"]="".concat(n.width?n.width:"1px"," ").concat(n.color)),this.res.style["-webkit-text-fill-color"]="transparent"}},{key:"stroke",value:function(){return this.res.style["-webkit-text-stroke"]="3px orange",this}},{key:"fill",value:function(){return this.res.style["-webkit-text-fill-color"]="transparent",this}},{key:"rowCol",value:function(t,e){return this.res.style.gridRow=t,this.res.style.gridColumn=e,this}},{key:"setGridRow",value:function(t){return this.res.style.gridRow=t,this}},{key:"setGridCol",value:function(t){return this.res.style.gridColumn=t,this}},{key:"toHTML",value:function(){return this.res}},{key:"onTap",value:function(t){return this.res.addEventListener("click",t),this}},{key:"setClass",value:function(t){return this.res.setAttribute("class",t),this}},{key:"setRandom",value:function(){for(var t="LAYOUT-",e=90;e>0;--e)t+="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"[Math.floor(62*Math.random())];return t+=(new Date).getTime(),this.res.setAttribute("class",t),this}},{key:"styled",value:function(t){return this.set(t),this}},{key:"removeQuotesFromFirstWord",value:function(t){return t.replace(/"([^"]+)":/g,"$1:")}},{key:"set",value:function(t){this.resCopy=this.res,this.options=t,b(e,"setPrevText",this,3)([this.text]),t.maxWidth&&(this.res.style.maxWidth=t.maxWidth),t.cursor&&(this.res.style.cursor="hand"),t.gpos&&this.gpos(t.gpos),t.vtn&&(this.res.style.viewTransitionName=t.vtn),t.index&&b(e,"setIndex",this,3)([t.index]),t.index&&(this.index=t.index),t.preffersId&&(this.preffersId=t.preffersId),b(e,"setPref",this,3)([t.preffersId]),t.removeDecoration&&(this.res.style.textDecoration="none"),t.block&&(this.res.style.display="block"),t.area&&this.setArea(t.area),t.icon&&this.addIcon(t.icon),t.color&&this.color(t.color),t.color&&this.elCSS.push("color: ".concat(t.color,"; \n")),t.class&&this.setClass(t.class),t.size&&this.fluidCopy(t.size),t.fluidc&&this.fluidCopy(t.fluidc),t.initLetter&&this.initLetter(t.initLetter),t.onTap&&this.onTap(t.onTap),"S6"===t.fluidc?t.fluidc&&this.elCSS.push("font-size: calc(1.1rem + 2.075vw); \n"):t.fluidc&&this.elCSS.push("font-size: calc(1.625rem + 5.075vw); \n"),this.options.id&&this.res.setAttribute("id",this.options.id),b(e,"setID",this,3)([this.options.id]),this.options.class&&this.res.setAttribute("class",this.options.class),b(e,"setClass",this,3)([this.options.class]),t.clampc&&this.clampCopy(t.clampc),t.arrpad&&this.arrayPadding(t.arrpad.sides,t.arrpad.value),t.pad&&this.pad(t.pad),t.respad&&this.respad(t.respad),t.resmar&&this.resmar(t.resmar),t.mar&&this.mar(t.mar),t.exact&&(this.res.style.fontSize=t.exact),t.zIndex&&(this.res.style.zIndex=t.zIndex),t.absolute&&(this.res.style.position="absolute"),t.arrayMargin&&this.arrayMargin(t.arrayMargin.sides,t.arrayMargin.value),t.em&&this.em(t.em),t.fluid&&this.fluid(t.fluid),t.font&&this.font(t.font),t.fluidc&&this.elCSS.push("font-family: ".concat(t.font,"; \n")),t.align&&(this.res.style.textAlign=t.align),t.weight&&(this.res.style.fontWeight=t.weight),t.padding&&this.padding(t.padding),t.breakWord&&(this.res.style.wordWrap="break-word"),t.center&&(this.res.style.marginRight="auto"),t.center&&(this.res.style.marginLeft="auto"),t.width&&(this.res.style.width=t.width),t.height&&(this.res.style.height=t.height),t.background&&(this.res.style.backgroundColor=t.background),t.radius&&(this.res.style.borderRadius=t.radius),t.italic&&this.italic(),t.responsive&&this.responsive(),t.border&&(this.res.style.border="".concat(t.border)),t.onScroll&&this.onScroll(t.onScroll),t.keySet&&this.keySet(t.keySet),t.maxHeight&&(this.res.style.maxHeight=t.maxHeight),t.transform&&this.reactOnTransform(t.transform),console.log("OGA"),console.log(t);var r=[];if(t.stroke||t.gradient||t.span||t.backgroundOp||t.layout||t.shadow||t.animation||t.filtera||t.transform){t.gradient&&(this.globalGradient=t.gradient.op.gradient),t.stroke&&b(e,"setAny",this,3)([{globalBlast:"".concat(t.stroke.op.width," ").concat(t.stroke.op.color)}]),t.span&&(t.span.prevText=this.text);var n=[t.stroke,t.gradient,t.animation,t.span,t.backgroundOp,t.layout,t.marginOp,t.shadow,t.animation,t.filtera,t.transform];n=n.filter((function(t){return null!=t}));for(var i=0;i<n.length;i++)r.push({range:n[i].range,log:n[i].op.name,target:n[i].target,op:n[i].op});var o=[];t.borderObj&&o.push("border"),t.background&&o.push("background"),t.mar&&o.push("margin"),t.animation&&o.push("animation"),t.span&&o.push("span"),console.log("ARA IS "),console.log(r),this.chainReact(r,this.options.id,o)}return this}},{key:"excludeFromCode",value:function(){return this.excludeFromCodeTrue=!0,this}},{key:"addIcon",value:function(t){var e=document.createElement("img");return e.style.width="20px",e.style.marginLeft="10px",e.style.height="auto",e.setAttribute("src",t.url),this.res.appendChild(e),this}},{key:"checkForAnimation",value:function(t){t.sort((function(t,e){return parseInt(t.range[0])-parseInt(e.range[0])}));var e,r=window.innerWidth,n=function(t){var e="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=f(t))){e&&(t=e);var r=0,n=function(){};return{s:n,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,o=!0,s=!1;return{s:function(){e=e.call(t)},n:function(){var t=e.next();return o=t.done,t},e:function(t){s=!0,i=t},f:function(){try{o||null==e.return||e.return()}finally{if(s)throw i}}}}(t);try{for(n.s();!(e=n.n()).done;){var i=e.value,o=h(i.range,2),s=o[0],a=o[1],l=parseInt(s),c=parseInt(a);r>=l&&r<=c&&"animation"===i.log&&this.res.animate([{opacity:0,transform:"translateY(100px)"},{opacity:1,transform:"translateY(0)"}],{duration:1e3,easing:"ease"})}}catch(t){n.e(t)}finally{n.f()}}},{key:"resetSmall",value:function(){this.res.style["-webkit-text-stroke"]="",this.res.style["-webkit-text-fill-color"]=""}},{key:"resetGradient",value:function(){return this.res.style.WebkitBackgroundClip="text",this.res.style.background="transparent",this}},{key:"resetStroke",value:function(){this.res.style["-webkit-text-stroke"]="",this.res.style["-webkit-text-fill-color"]=""}},{key:"innerStroke",value:function(t){t.color?this.res.style["-webkit-text-stroke"]="".concat(t.width?t.width:"1px"," ").concat(t.color):this.res.style["-webkit-text-stroke"]="1px orange",this.res.style["-webkit-text-fill-color"]="transparent"}},{key:"innerGradient",value:function(t){this.res.style.background="linear-gradient(45deg, #ff0000, #00ff00)",this.res.style["-webkit-background-clip"]="text"}},{key:"arrayMargin",value:function(t,e){return e||(this.res.style.marginLeft="".concat(t[0],"px"),this.res.style.marginTop="".concat(t[1],"px"),this.res.style.marginRight="".concat(t[2],"px"),this.res.style.marginBottom="".concat(t[3],"px")),t.includes("left")&&(this.res.style.marginLeft=e),t.includes("right")&&(this.res.style.marginRight=e),t.includes("top")&&(this.res.style.marginTop=e),t.includes("bottom")&&(this.res.style.marginBottom=e),e||(this.res.style.marginBottom=t),this}},{key:"clampExperiment",value:function(){return this.res.style.fontSize="clamp(1rem, calc(1rem * 10rem), 3rem)",this}},{key:"between",value:function(t){return"S1"===t&&(this.res.style.fontSize="clamp(2rem, 8vw, 2.5rem)"),"S2"===t&&(this.res.style.fontSize="clamp(4rem, 8vw, 5rem)"),"S3"===t&&(this.res.style.fontSize="clamp(2rem, 5vw, 2.5rem)"),"S4"===t&&(this.res.style.fontSize="clamp(1.5rem, 2vw, 1.6rem)"),"S5"===t&&(this.res.style.fontSize="clamp(1.2rem, 2vw, 1.3rem)"),"S6"===t&&(this.res.style.fontSize="clamp(1rem, 2vw, 1.3rem)"),this}},{key:"betweenCopy",value:function(t){return"S1"===t&&(this.res.style.fontSize="clamp(2rem, 8vw, 2.5rem)"),"S2"===t&&(this.res.style.fontSize="clamp(4rem, 8vw, 5rem)"),"S3"===t&&(this.res.style.fontSize="clamp(2rem, 5vw, 2.5rem)"),"S4"===t&&(this.res.style.fontSize="clamp(1.5rem, 2vw, 1.6rem)"),"S5"===t&&(this.res.style.fontSize="clamp(1.2rem, 2vw, 1.3rem)"),"S6"===t&&(this.res.style.fontSize="clamp(1rem, 2vw, 1.3rem)"),this}},{key:"stringGen",value:function(t){for(var e="",r=0;r<t;r++)e+="abcdefghijklmnopqrstuvwxyz".charAt(Math.floor(26*Math.random()));return e}},{key:"initLetter",value:function(t){var e=document.createElement("style");document.body.appendChild(e),Math.random();var r=this.stringGen(1e3);return this.res.setAttribute("id",r),document.styleSheets[0].insertRule("#".concat(r,"::first-letter { color: green; font-size: 3em; padding: 0.1em }"),0),this}},{key:"constant",value:function(t){return"S1"===t&&this.jumbotron(),"S2"===t&&this.large(),"S3"===t&&this.medium(),this}},{key:"minusMargin",value:function(){return this.res.style.marginRight="-3.1em",this}},{key:"fluid",value:function(t){if("S1"===t){this.res=document.createElement("h1");var e=document.createTextNode(this.text);this.res.appendChild(e),this.res.style.fontSize="calc(1.625rem + 4.3vw)"}if("S2"===t){this.res=document.createElement("h2");var r=document.createTextNode(this.text);this.res.appendChild(r),this.res.style.fontSize="calc(1.525rem + 3.525vw)"}if("S3"===t){this.res=document.createElement("h3");var n=document.createTextNode(this.text);this.res.appendChild(n),this.res.style.fontSize="calc(1.375rem + 2.75vw)"}if("S4"===t){this.res=document.createElement("h4");var i=document.createTextNode(this.text);this.res.appendChild(i),this.res.style.fontSize="calc(1.275rem + 1.975vw)"}return"S5"===t&&(this.res.style.fontSize="calc(1.1rem + 1.2vw)"),this}},{key:"getClampValue",value:function(t){return"S7"===t?"clamp(1.45rem, 2vw + 1.5rem, 1.69rem)":"S6"===t?"clamp(2.25rem, 2vw+1.5rem, 3.25rem)":"S5"===t?"clamp(2.75rem, 2vw + 1.5rem, 3.25rem)":"S4"===t?"clamp(3.5rem, 2vw + 1.5rem, 3.25rem)":"S3"===t?"clamp(4.25rem, 2vw + 1.5rem, 3.25rem)":"S2"===t?"clamp(5rem, 2vw + 1.5rem, 3.25rem)":"S1"===t?"clamp(6rem, 2vw + 1.5rem, 3.25rem)":void 0}},{key:"clampCopy",value:function(t){return this.res.style.fontSize=this.getClampValue(t),this}},{key:"fluidCopy",value:function(t){if(t instanceof Object){this.prevStylex=this.res.style,this.res=document.createElement("h1"),this.res.style.cssText=this.prevStylex.cssText;var e=document.createTextNode(this.text);return this.res.appendChild(e),this.res.style.fontSize=t.exact,this}if("S1"===t){this.prevStylex=this.res.style,this.res=document.createElement("h1"),this.res.style.cssText=this.prevStylex.cssText;var r=document.createTextNode(this.text);this.res.appendChild(r),this.res.style.fontSize="calc(1.625rem + 5.075vw)"}if("S2"===t){this.prevStylex=this.res.style,this.res=document.createElement("h2"),this.res.style.cssText=this.prevStylex.cssText;var n=document.createTextNode(this.text);this.res.appendChild(n),this.res.style.fontSize="calc(1.500rem + 4.3vw)"}if("S3"===t){this.prevStylex=this.res.style,this.res=document.createElement("h3"),this.res.style.cssText=this.prevStylex.cssText;var i=document.createTextNode(this.text);this.res.appendChild(i),this.res.style.fontSize="calc(1.375rem + 3.525vw)"}if("S4"===t){this.prevStylex=this.res.style,this.res=document.createElement("h4"),this.res.style.cssText=this.prevStylex.cssText;var o=document.createTextNode(this.text);this.res.appendChild(o),this.res.style.fontSize="calc(1.250rem + 2.75vw)"}if("S5"===t){this.prevStylex=this.res.style,this.res=document.createElement("h5"),this.res.style.cssText=this.prevStylex.cssText;var s=document.createTextNode(this.text);this.res.appendChild(s),this.res.style.fontSize="calc(1.125rem + 1.975vw)"}return"S6"===t&&(this.options&&!1===this.options.preffersId?this.html.push('<p class="'.concat(this.options.class,'">').concat(this.text,"</p> \n \n")):this.options&&this.options.id&&this.html.push('<p id="'.concat(this.options.id.substr(1),'">').concat(this.text,"</p> \n \n")),this.res.style.fontSize="calc(1rem + 0.5vw)"),this}},{key:"toReactComponent",value:function(){return this.react.push("function Godzilla() { \n"),this.react.push('return <h1 class="'.concat(this.options.class,'">').concat(this.text,"</h1> \n")),this.react.push("} \n \n"),this.react}},{key:"myself",value:function(t){var e=this,r=function(){window.matchMedia("(max-device-width: 415px)").matches?e.res.style.fontSize=t.desktop:e.res.style.fontSize=t.phone};return r(),window.addEventListener("resize",r),this}},{key:"jumbotron",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?t.res.style.fontSize="8rem":t.res.style.fontSize="6rem"};return e(),window.addEventListener("resize",e),this}},{key:"large",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?t.res.style.fontSize="7rem":t.res.style.fontSize="5rem"};return e(),window.addEventListener("resize",e),this}},{key:"frame",value:function(t){return this.res.style.width=t.width,this.res.style.height=t.height,this}},{key:"vw",value:function(t,e,r){}},{key:"responsive",value:function(t){var e=this;this.set=!1,this.setB=!1;var r=function(){window.innerWidth<t.minw?(e.setB=!1,e.set||(e.res.style.color="#3498db",e.res.style.fontSize="".concat(t.baseVW/100*window.innerWidth,"px"),e.set=!0)):window.innerWidth>t.maxw?(e.set=!1,e.setB||(e.res.style.color="orange",e.res.style.fontSize="".concat(t.baseVW/100*t.maxw,"px"),e.setB=!0)):(e.set=!1,e.setB=!1,e.res.style.color="black",e.res.style.fontSize="".concat(t.baseVW,"vw"))};return r(),window.addEventListener("resize",r),this}},{key:"xlarge",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?t.res.style.fontSize="6.5rem":t.res.style.fontSize="8.5rem"};return e(),window.addEventListener("resize",e),this}},{key:"medium",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?t.res.style.fontSize="2.25rem":t.res.style.fontSize="1.5em"};return e(),window.addEventListener("resize",e),this}},{key:"auto",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?t.res.style.fontSize="2rem":t.res.style.fontSize="1rem"};return e(),window.addEventListener("resize",e),this}},{key:"small",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?t.res.style.fontSize="1.5em":t.res.style.fontSize="1em"};return e(),window.addEventListener("resize",e),this}},{key:"sizes",value:function(t){var e=this;this.res.style.fontSize="".concat(t[0].size,"rem");var r=function(){for(var r=0;r<t.length;r++)t[r].width&&window.matchMedia("(min-width: ".concat(t[r].width,"px)")).matches&&(e.res.style.fontSize="".concat(t[r].size));window.matchMedia("(max-device-width: 415px)").matches&&(e.res.style.fontSize="".concat(t[t.length-1].mobile))};return r(),window.addEventListener("resize",r),this}},{key:"setup",value:function(t){var e;t?((e=document.createElement(t.type)).setAttribute("id",t.id),t.type):e=document.createElement("p");var r=document.createTextNode(this.text);return e.appendChild(r),this.res=e,this.res.style.padding=0,this.res.style.margin=0,this}},{key:"hide",value:function(){return this.res.style.visibility="hidden",this}},{key:"font",value:function(t){return this.res.style.fontFamily=t,this}},{key:"center",value:function(){return this.res.style.textAlign="center",this}},{key:"size",value:function(t){return this.res.style.fontSize=t,this}},{key:"em",value:function(t){return this.res.style.fontSize="".concat(t,"em"),this}},{key:"color",value:function(t){return this.res.style.color=t,this}},{key:"align",value:function(t){return this.res.style.textAlign="".concat(t),this}},{key:"weight",value:function(t){return this.res.style.fontWeight=t,this}},{key:"bold",value:function(){return this.res.style.fontWeight="bold",this}},{key:"italic",value:function(){return this.res.style.fontStyle="italic",this}},{key:"width",value:function(t,e){return this.res.style.width=t,e&&(this.res.style.marginLeft="auto",this.res.style.marginRight="auto"),this}},{key:"offset",value:function(t){return this.res.style.gridRow=2,this.res.style.gridColumn=2,this.res.style.marginLeft="-60px",this}},{key:"border",value:function(t,e){return this.res.style.border="".concat(e,"px solid ").concat(t),this}},{key:"padding",value:function(t,e,r,n){return(t||e||r||n)&&(this.res.style.paddingLeft=t,this.res.style.paddingTop=e,this.res.style.paddingRight=r,this.res.style.paddingBottom=n),e||r||n||(this.res.style.padding=t),this}},{key:"arrayPadding",value:function(t,e){return t.includes("left")&&(this.res.style.paddingLeft=e),t.includes("right")&&(this.res.style.paddingRight=e),t.includes("top")&&(this.res.style.paddingTop=e),t.includes("bottom")&&(this.res.style.paddingBottom=e),e||(this.res.style.paddingBottom=t),this}},{key:"margin",value:function(t,e){return"top"==t?this.res.style.marginTop=e:"bottom"==t?this.res.style.marginBottom=e:"left"==t?this.res.style.marginLeft=e:"right"==t&&(this.res.style.marginRight=e),this}},{key:"headline",value:function(){return this.em(4),this.font("Arial"),this.bold(),this}},{key:"caption",value:function(){return this.bold(),this.res.style.fontFamily="Arial",this.color("gray"),this.padding("top",20),this.res.style.fontSize="1em",window.matchMedia("(max-device-width: 415px)").matches?this.res.style.fontSize="2em":this.res.style.fontSize="1em",this}},{key:"updating",value:function(t,e){var r=this.res,n=this.text;return Object.defineProperty(t,e,{set:function(t){var e=document.createTextNode(n.replace("$",t));r.replaceChild(e,r.childNodes[0])}}),this}},{key:"style",value:function(t){return this.res.style.color=t.styles.color,this.res.style.fontWeight=t.styles.fontWeight,this.res.style.paddingLeft=t.styles.padding[0],this.res.style.paddingTop=t.styles.padding[1],this.res.style.paddingRight=t.styles.padding[2],this.res.style.paddingBottom=t.styles.padding[3],this.res.style.marginLeft=t.styles.margin[0],this.res.style.paddingTop=t.styles.margin[1],this.res.style.paddingRight=t.styles.margin[2],this.res.style.paddingBottom=t.styles.margin[3],this.res.style.opacity=t.styles.opacity,this}},{key:"applyStyle",value:function(t,e){return window.matchMedia("(max-width: ".concat(t,"px)")).matches&&Object.assign(this.res.style,e.styles),this}},{key:"nextApply",value:function(t){for(var e=this,r=[],n=(this.res.style,function(n){r[0].matches?Object.assign(e.res.style,t[0].styles):r[1].matches?Object.assign(e.res.style,t[1].styles):Object.assign(e.res.style,t[t.length-1].styles)}),i=0;i<t.length;i++){var o=t[i],s=window.matchMedia("(min-width: ".concat(o.min,"px) and (max-width: ").concat(o.max,"px)"));r.push(s),r[i].addListener(n)}return n(),this}},{key:"apply",value:function(t){var e=this,r=this.res.styles,n=function(){for(var n=0;n<t.length;n++){var i=t[n];i.min&&i.max?window.matchMedia("(min-width: ".concat(i.min,"px) and (max-width: ").concat(i.max,"px)")).matches?Object.assign(e.res.style,i.styles):(alert("YES min max, but does not match"),Object.assign(e.res.style,r)):window.matchMedia("(max-width: ".concat(i.max,"px)")).matches?Object.assign(e.res.style,i.styles):(alert("NO min max, and does not match"),Object.assign(e.res.style,r))}};return n(),window.addEventListener("resize",n),this}},{key:"render",value:function(t){if(!t)return this.res;this.options&&this.options.id&&this.res.setAttribute("id",this.options.id),document.querySelector(t).appendChild(this.res)}}],n&&p(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function S(t){return S="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},S(t)}function O(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function C(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,j(n.key),n)}}function j(t){var e=function(t){if("object"!=S(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=S(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==S(e)?e:e+""}function E(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(E=function(){return!!t})()}function T(t,e,r,n){var i=P(A(1&n?t.prototype:t),e,r);return 2&n&&"function"==typeof i?function(t){return i.apply(r,t)}:i}function P(){return P="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(t,e,r){var n=function(t,e){for(;!{}.hasOwnProperty.call(t,e)&&null!==(t=A(t)););return t}(t,e);if(n){var i=Object.getOwnPropertyDescriptor(n,e);return i.get?i.get.call(arguments.length<3?t:r):i.value}},P.apply(null,arguments)}function A(t){return A=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},A(t)}function R(t,e){return R=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},R(t,e)}var L=function(t){function e(t,r,n,i){var o;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(o=function(t,e,r){return e=A(e),function(t,e){if(e&&("object"==S(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,E()?Reflect.construct(e,r||[],A(t).constructor):e.apply(t,r))}(this,e)).url=t,o.res=null,o.code=[],o}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&R(t,e)}(e,t),r=e,n=[{key:"removeQuotesFromFirstWord",value:function(t){return t.replace(/"([^"]+)":/g,"$1:")}},{key:"setType",value:function(t){t.url;var e=t.type,r=t.mode;if(this.code=[],"exact"===e){var n='new Image("'.concat(this.url,'", "exact")');this.code.push(n)}else if("uncover"===e){var i='new Image("'.concat(this.url,'", "uncover")');this.code.push(i)}else this.code.push("new Image('".concat(this.url,"')"));return this.image(this.url,r,e),this}},{key:"flexOne",value:function(){return this.res.style.flex="1",this}},{key:"hand",value:function(){return this.res.style.cursor="hand",this}},{key:"setGridWithoutCode",value:function(){return this.res.style.border="1px solid white",this}},{key:"maxWidth",value:function(t){return this.res.style.maxWidth=t,this}},{key:"getHeight",value:function(){return this.res.height}},{key:"getWidth",value:function(){return this.res.width}},{key:"getType",value:function(){return"HTMLImageElement"}},{key:"toCode",value:function(){var t=this.options;this.res.style.border&&(t.border=this.res.style.border);var e=Object.fromEntries(Object.entries(t).filter((function(t){var e=function(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==e);l=!0);}catch(t){c=!0,i=t}finally{try{if(!l&&null!=r.return&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}(t,e)||function(t,e){if(t){if("string"==typeof t)return O(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?O(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(t,2);return e[0],null!==e[1]})));return["new Image().set(".concat(JSON.stringify(e,null,2).replace(/"(\w+)"\s*:/g,"$1:"),")")]}},{key:"formatObj",value:function(t){return JSON.stringify(t,null,2).replace(/"(\w+)"\s*:/g,"$1:")}},{key:"set",value:function(t){var r="";this.options=t;var n=t.isFull;if(n?this.image(t.url,"exact",n,"a"):this.setup(),t.url&&this.res.setAttribute("src",t.url),"exact"===n?'new Image("'.concat(this.url,'", "exact")'):"uncover"===n&&'new Image("'.concat(this.url,'", "uncover")'),t.vtn&&(this.res.style.viewTransitionName=t.vtn),this.vtn=t.vtn,t.minHeight&&(this.res.style.minHeight=t.minHeight),t.index&&T(e,"setIndex",this,3)([t.index]),t.index&&(this.index=t.index),t.index&&(r+='\n index: "'.concat(t.index,'",')),t.centerSelf&&(this.res.style.marginRight="auto",this.res.style.marginLeft="auto"),t.fitContent&&(this.res.style.width="100%",this.res.style.height="100%",this.res.style.marginRight="auto",this.res.style.marginTop="auto",this.res.style.objectFit="cover"),t.objectFit&&(this.res.style.objectFit=t.objectFit),t.objectFit&&(r+='\n objectFit: "'.concat(t.objectFit,'",')),t.as&&this.as(t.as),t.onScroll&&this.onScroll(t.onScroll),t.class&&this.res.setAttribute("class",t.class),t.gpos&&(this.gposObject=t.gpos),t.gpos&&(this.res.style.gridColumn=t.gpos.col,this.res.style.gridRow=t.gpos.row,r+="\n gpos: ".concat(this.removeQuotesFromFirstWord(JSON.stringify(t.gpos)),", ")),t.filtera){var i;i=Array.isArray(t.filtera)?c.filtera.filter((function(t){return"filter"===t.op.name}))[0]:t.filtera;var o=this.removeQuotesFromFirstWord(JSON.stringify(i));r+="\n filtera: ".concat(o,", \n")}if(t.keySet&&this.keySet(t.keySet),t.stype&&this.setType(t.stype),t.isBackground&&(this.isBackground=t.isBackground),t.zIndex&&(this.res.style.zIndex=t.zIndex),t.zIndex&&(r+='\n zIndex: "'.concat(t.zIndex,'", \n')),t.id&&this.res.setAttribute("id",t.id),t.id&&(r+=' id: "'.concat(t.id,'", \n')),this.id=t.id,t.area&&this.setArea(t.area),t.area&&(r+='area: "'.concat(t.area,'", \n')),t.opacity&&(this.res.style.opacity=t.opacity),t.width&&(this.res.style.width=t.width),t.width&&(r+='width: "'.concat(t.width,'", ')),t.maxWidth&&(this.res.style.maxWidth=t.maxWidth),t.maxWidth&&(r+='maxWidth: "'.concat(t.maxWidth,'", ')),t.height&&(this.res.style.height=t.height),t.height&&(r+='height: "'.concat(t.height,'", ')),t.multimargin&&this.makeMultiMargin(t.multimargin),t.multimargin&&(r+="multimargin: [ \n"),t.arrayMargin&&this.arrayMargin(t.arrayMargin.sides,t.arrayMargin.value),t.multimargin){for(var s=0;s<t.multimargin.length;s++){var a=t.multimargin[s];r+='{side: "'.concat(a.side,'", value: "').concat(a.value,'"}, \n')}r+="], \n"}if(t.maxWidth&&this.maxWidth(t.maxWidth),t.maxWidth&&(r+='maxWidth: "'.concat(t.maxWidth,'", \n')),t.radius&&this.cornerRadius(t.radius),t.radius&&(r+='radius: "'.concat(t.radius,'", \n')),t.marginOp){var l=this.removeQuotesFromFirstWord(JSON.stringify(t.marginOp));r+="\n marginOp: ".concat(l,",")}t.clipPath&&this.clipPath(t.clipPath),t.clipPath&&(r+='clipPath: "'.concat(t.clipPath,'", \n'));var c=t;if(c.stroke||c.gradient||c.span||c.backgroundOp||c.layout||c.marginOp||c.shadow||c.filtera||c.animation){c.gradient,c.gradient&&(this.globalGradient=c.gradient.op.gradient),c.stroke&&T(e,"setAny",this,3)([{globalBlast:"".concat(c.stroke.op.width," ").concat(c.stroke.op.color)}]);var u=[c.stroke,c.gradient,c.animation,c.span,c.backgroundOp,c.layout,c.marginOp,c.shadow,c.filtera,c.animation];u=u.filter((function(t){return null!=t}));var d=[];for(s=0;s<u.length;s++)d.push({range:u[s].range,log:u[s].op.name,target:u[s].target,op:u[s].op});this.chainReact(d,this.options.id)}if(c.shadow){var h=c.shadow,f=this.removeQuotesFromFirstWord(JSON.stringify(h));r+="\n shadow: ".concat(f,",")}if(c.animation){var y=c.animation,p=this.removeQuotesFromFirstWord(JSON.stringify(y));r+="\n animation: ".concat(p,",")}var m="\n .set({".concat(r,"}) \n \n");return Object.keys(t).length>0?this.code.push(m):this.code.push(","),this}},{key:"setFilter",value:function(t){var e=[],r=[t];r=r.filter((function(t){return null!=t}));for(var n=0;n<r.length;n++)e.push({range:r[n].range,log:r[n].op.name,target:r[n].target})}},{key:"makeMultiMargin",value:function(t){for(var e=0;e<t.length;e++)"left"===t[e].side&&(this.res.style.marginLeft=t[e].value),"right"===t[e].side&&(this.res.style.marginRight=t[e].value),"top"===t[e].side&&(this.res.style.marginTop=t[e].value),"bottom"===t[e].side&&(this.res.style.marginBottom=t[e].value);return this}},{key:"setID",value:function(t){return this.res.setAttribute("id",t),this}},{key:"square",value:function(){return this.res.style.width="30%",this.res.style.paddingBottom="30%",this}},{key:"opacity",value:function(t){return this.res.style.opacity="".concat(t),this}},{key:"rowCol",value:function(t,e){return this.res.style.gridRow=t,this.res.style.gridColumn=e,this}},{key:"setArea",value:function(t){return this.res.style.gridArea=t,this}},{key:"setGridRow",value:function(t){return this.res.style.gridRow=t,this}},{key:"setGridCol",value:function(t){return this.res.style.gridColumn=t,this}},{key:"setGrid",value:function(){return this.res.style.gridRow="span 2",this.res.style.gridColumn="span 3",this}},{key:"transform",value:function(t){return this.res.style.transform=t,this}},{key:"offset",value:function(){return this.res.style.marginLeft="-60px",this}},{key:"offseta",value:function(){return this.res.style.marginLeft="90px",this.res.style.marginTop="-30px",this}},{key:"borderAround",value:function(t){return this.res.style.border=t,this}},{key:"setClass",value:function(t){return this.res.setAttribute("class",t),this}},{key:"scale",value:function(t){var e=this;return this.res.style.width,this.res.style.transition="0.5s all",this.res.addEventListener("mouseover",(function(){e.res.style.width,e.res.style.transform="scale(1.04)"})),this.res.addEventListener("mouseout",(function(){e.res.style.width,e.res.style.transform="scale(1.0)"})),this}},{key:"onTap",value:function(t){return this.res.addEventListener("click",t),this}},{key:"border",value:function(t){return this.res.style.borderTopLeftRadius="16px",this.res.style.borderTopRightRadius="16px",this}},{key:"allRound",value:function(t){return this.res.style.borderRadius=t,this}},{key:"mobileWidth",value:function(){return window.matchMedia("(max-device-width: 415px)").matches&&(this.res.style.width="120%"),this}},{key:"image",value:function(t,e,r,n,i){var o=window.matchMedia("(max-device-width: 415px)"),s=document.createElement("div");return s.style.viewTransitionName=n,s.style.width="100%",s.style.height="200",i&&(s.style.gridColumn=i.gridColumn,s.style.gridRow=i.gridRow),o.matches&&(s.style.height="500"),s.style.backgroundImage="url(".concat(t,")"),s.style.backgroundPosition="center center",s.style.backgroundRepeat="no-repeat",s.style.backgroundSize="cover","uncover"===r&&(s.style.backgroundSize="contain"),"contain"===e&&(s.style.backgroundSize="contain"),this.res=s,this}},{key:"arrayPadding",value:function(t,e){return t.includes("left")&&(this.res.style.paddingLeft=e),t.includes("right")&&(this.res.style.paddingRight=e),t.includes("top")&&(this.res.style.paddingTop=e),t.includes("bottom")&&(this.res.style.paddingBottom=e),this}},{key:"arrayMargin",value:function(t,e){return t.includes("left")&&(this.res.style.marginLeft=e),t.includes("right")&&(this.res.style.marginRight=e),t.includes("top")&&(this.res.style.marginTop=e),t.includes("bottom")&&(this.res.style.marginBottom=e),this}},{key:"setup",value:function(){var t=document.createElement("img");return t.style.width="100%",t.src=this.url,this.res=t,this}},{key:"autoW",value:function(){return this.res.style.width="initial",this}},{key:"float",value:function(t){return this.res.style.float="".concat(t),this}},{key:"fillAvailable",value:function(){return this.res.style.height="-webkit-fill-available",this}},{key:"grayscale",value:function(t){return this.res.style.filter="grayscale(".concat(t,"%)"),this}},{key:"flex",value:function(t){return this.res.style.flex=1,this}},{key:"height",value:function(t){return this.res.style.height=t,this.res.style.width="auto",this}},{key:"expand",value:function(t){var e=this,r=function(){var r,n;if(window.matchMedia("(min-width: ".concat(t.at,")")).matches){e.res.style.width="".concat(t.width);var i=window.innerWidth/2-(n=r=t.width,(r.includes("%")||r.includes("px"))&&(n=n.substr(0,2)),(r.includes("%")?Number(n/100*window.innerWidth):r.includes("px")?Number(n):void 0)/2);e.res.style.marginLeft="".concat(i,"px")}else e.res.style.width="100%",e.res.style.marginLeft="0px";window.matchMedia("(max-device-width: 415px)").matches&&(e.res.style.width="100%",e.res.style.marginLeft="0px")};return r(),window.addEventListener("resize",r),this}},{key:"width",value:function(t){return this.res.style.width=t,this.res.style.height="auto",this}},{key:"toBack",value:function(){return this.res.style.zIndex="-1",this}},{key:"margin",value:function(t,e,r,n){return(t||e||r||n)&&(this.res.style.marginLeft=t,this.res.style.marginTop=e,this.res.style.marginRight=r,this.res.style.marginBottom=n),e||r||n||0===e&&0===r&&0===n||(this.res.style.margin=t),this}},{key:"padding",value:function(t){return this.res.style.padding=t,this}},{key:"size",value:function(t,e){return t&&e?(this.res.style.width=t,this.res.style.height=e):(this.res.style.width=t,this.res.style.height=t),this}},{key:"frame",value:function(t){var e=t.width,r=t.height;return e&&r?(this.res.style.width=e,this.res.style.height=r):(this.res.style.width=e,this.res.style.height=e),this}},{key:"RSize",value:function(t,e,r){var n=window.matchMedia("(max-device-width: 420px)");return t&&e?(this.res.style.width=n.matches?t*r:t,this.res.style.height=n.matches?e*r:e):(this.res.style.width=n.matches?t*r:t,this.res.style.height=n.matches?t*r:t),this}},{key:"shadow",value:function(t){return"mild"===t.type?this.res.style.boxShadow="0px 3px 15px rgba(0,0,0,0.2)":this.res.style.boxShadow="".concat(t.x,"px ").concat(t.y,"px ").concat(t.radius,"px ").concat(t.color),this}},{key:"clipShape",value:function(t){return this.res.style.borderRadius="50%",this}},{key:"cornerRadius",value:function(t){return this.res.style.borderRadius=t,this}},{key:"clipPath",value:function(t){this.res.style.clipPath='path("'.concat(t,'")');var e=document.createElementNS("http://www.w3.org/2000/svg","svg");return e.style.display="block",e.style.width="100%",e.style.height="100%",e.style.overflow="visible",this}},{key:"render",value:function(t){var e=this.res;if(!t)return e;document.querySelector(t).appendChild(e)}}],n&&C(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function z(t){return z="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},z(t)}function M(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,I(n.key),n)}}function I(t){var e=function(t){if("object"!=z(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=z(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==z(e)?e:e+""}function B(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(B=function(){return!!t})()}function N(t,e,r,n){var i=W(_(1&n?t.prototype:t),e,r);return 2&n&&"function"==typeof i?function(t){return i.apply(r,t)}:i}function W(){return W="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(t,e,r){var n=function(t,e){for(;!{}.hasOwnProperty.call(t,e)&&null!==(t=_(t)););return t}(t,e);if(n){var i=Object.getOwnPropertyDescriptor(n,e);return i.get?i.get.call(arguments.length<3?t:r):i.value}},W.apply(null,arguments)}function _(t){return _=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},_(t)}function F(t,e){return F=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},F(t,e)}var D=function(t){function e(t,r,n){var i;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(i=function(t,e,r){return e=_(e),function(t,e){if(e&&("object"==z(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,B()?Reflect.construct(e,r||[],_(t).constructor):e.apply(t,r))}(this,e)).link=r,i.text=t,i.code=[],i.css=[],i.elCSS=[],i.html=[],i.res=null,i.stopEM=n,i.setup(),i.inlineBlock(),i}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&F(t,e)}(e,t),r=e,(n=[{key:"toCSS",value:function(){return this.css}},{key:"toHTMLA",value:function(){return this.html}},{key:"toElCSS",value:function(){return this.preffersId?this.elCSS.unshift(this.res.id+" { \n"):this.elCSS.unshift("."+this.class+" { \n"),this.elCSS.push(" } \n \n"),this.elCSS}},{key:"getType",value:function(){return"HTMLAnchorElement"}},{key:"toCode",value:function(){return this.code}},{key:"setArea",value:function(t){return this.res.style.gridArea=t,this}},{key:"setup",value:function(){var t=document.createElement("a");t.setAttribute("href",this.link),t.style.textDecoration="none",t.style.color="black",t.style.textAlign="center",t.style.fontFamily="Arial";var e=document.createTextNode(this.text);return t.appendChild(e),this.res=t,!1===this.stopEM&&this.em(1),this}},{key:"appendImageAsChild",value:function(t,e){var r=document.createElement("a");t.options.vtn&&(r.style.viewTransitionName=t.options.vtn),r.setAttribute("href",t.options.url);var n=document.createElement("img");return t.options&&(n.style.width=t.options.size,t.options.radius&&(n.style.borderRadius=t.options.radius),n.setAttribute("src",t.options.img),r.appendChild(n)),this.res=r,e&&(this.res.style.marginLeft=e),this}},{key:"addIcon",value:function(t){var e=document.createElement("img");return e.style.width="20px",e.style.height="auto",e.style.marginLeft=t.padding?t.padding:"10px",e.setAttribute("src",t.url),this.res.appendChild(e),this}},{key:"removeQuotesFromFirstWord",value:function(t){if(t)return t.replace(/"([^"]+)":/g,"$1:")}},{key:"set",value:function(t){this.elCSS.push("text-decoration: none; \n"),this.options=t;var r="";t.id&&this.res.setAttribute("id",t.id),t.id&&N(e,"setID",this,3)([t.id]),t.pad&&this.pad(t.pad);var n=this.removeQuotesFromFirstWord(JSON.stringify(t.pad));if(t.pad&&(r+="\n pad: ".concat(n,",")),t.preffersId&&(this.preffersId=t.preffersId),null!=t.preffersId&&(r+="\n preffersId: ".concat(t.preffersId,",")),t.class&&N(e,"setClass",this,3)([t.class]),t.class&&(r+='\n class: "'.concat(t.class,'",')),t.borderObj){this.res.style.border="".concat(t.borderObj.width," solid ").concat(t.borderObj.color),this.res.style.borderRadius="".concat(t.borderObj.radius);var i=this.removeQuotesFromFirstWord(JSON.stringify(t.borderObj));r+="\n borderObj: ".concat(i,",")}if(!1===this.options.preffersId?this.html.push('<a class="'.concat(t.class,'" href="#hello">').concat(t.text,"</a> \n \n")):t.id&&this.html.push('<a id="'.concat(t.id.substr(1),'" href="#hello">').concat(t.text,"</a> \n \n")),null!=t.blastData){var o=this.removeQuotesFromFirstWord(JSON.stringify(t.blastData));N(e,"setAny",this,3)([{globalBlast:"1px ".concat(t.blastData.color)}]),t.blastData&&(r+="\n blastData: ".concat(o,","))}t.nowrap&&(this.res.style.whiteSpace="nowrap"),t.font&&this.font(t.font),t.font&&(r+='\n font: "'.concat(t.font,'",')),t.font&&this.elCSS.push('font-family: "'.concat(t.font,'"; \n')),t.fluidc&&this.fluidCopy(t.fluidc),t.fluidc&&(r+='\n fluidc: "'.concat(t.fluidc,'",')),t.size&&this.fluidCopy(t.size),t.size&&(r+='\n size: "'.concat(t.size,'",')),"S6"===t.fluidc?t.fluidc&&this.elCSS.push("font-size: calc(1rem + 1.075vw); \n"):t.fluidc&&this.elCSS.push("font-size: calc(1.625rem + 5.075vw); \n"),t.clampc&&this.clampCopy(t.clampc),this.options.id&&(r+='\n id: "'.concat(this.options.id,'",')),t.align&&this.leftAlign(),t.align&&(r+='\n align: "'.concat(t.align,'",')),t.type&&(this.res.style.display="block"),t.color&&this.color(t.color),t.color&&(r+='\n color: "'.concat(t.color,'",')),t.color&&this.elCSS.push('color: "'.concat(t.color,'"; \n')),t.background&&this.background(t.background);var s=this.removeQuotesFromFirstWord(JSON.stringify(t.background));t.background&&(r+="\n background: ".concat(s,",")),t.hover&&this.hover(t.hover);var a=this.removeQuotesFromFirstWord(JSON.stringify(t.hover));if(t.hover&&(r+="\n hover: ".concat(a,",")),t.weight&&(this.res.style.fontWeight=t.weight),t.blast&&(this.blastData=t.blast),t.bold&&(this.res.style.fontWeight="bold"),t.bold&&(r+="\n bold: ".concat(t.bold,",")),t.block&&this.toBlock(),t.block&&(r+="\n block: ".concat(t.block,",")),t.radius&&this.radius(t.radius),t.radius&&(r+='\n radius: "'.concat(t.radius,'",')),t.width&&this.width(t.width),t.width&&(r+='\n width: "'.concat(t.width,'",')),t.arrayPadding){var l=t.arrayPadding.sides.map((function(t){return'"'.concat(t,'"')})).join(", ");t.arrayPadding&&this.arrayPadding(t.arrayPadding.sides,t.arrayPadding.value),t.arrayPadding&&(r+="\n arrayPadding: {sides: [".concat(l,'], value: "').concat(t.arrayPadding.value,'"},'))}if(t.arrayMargin&&this.arrayMargin(t.arrayMargin.sides,t.arrayMargin.value),t.arrayMargin&&(r+="\n arrayMargin: {sides: [".concat(t.arrayMargin.sides.map((function(t){return'"'.concat(t,'", ')})),'], value: "').concat(t.arrayMargin.value,'"},')),t.maxWidth&&this.maxWidth(t.maxWidth),t.url&&this.res.setAttribute("href",t.url),r+='\n url: "'.concat(t.url,'",'),t.text&&(this.res.textContent=t.text),r+='\n text: "'.concat(t.text,'",'),t.data){t.data&&this.appendImageAsChild(t.data,"20px");var c=this.removeQuotesFromFirstWord(JSON.stringify(t.data));t.data&&(r+="\n data: ".concat(c))}if(t.icon){this.addIcon(t.icon);var u=this.removeQuotesFromFirstWord(JSON.stringify(t.icon));r+="\n icon: ".concat(u,",")}if(t.shadow){var d=t.shadow,h=this.removeQuotesFromFirstWord(JSON.stringify(d));r+="\n shadow: ".concat(h,",")}if(t.stroke){var f=this.removeQuotesFromFirstWord(JSON.stringify(t.stroke));t.stroke&&(r+="\n stroke: ".concat(f,","))}if(t.backgroundOp){var y=this.removeQuotesFromFirstWord(JSON.stringify(t.backgroundOp));r+="\n backgroundOp: ".concat(y,",")}if(t.marginOp){var p=this.removeQuotesFromFirstWord(JSON.stringify(t.marginOp));r+="\n marginOp: ".concat(p,",")}if(t.gradient){var m=this.removeQuotesFromFirstWord(JSON.stringify(t.gradient));r+="\n gradient: ".concat(m,",")}if(t.animation){var v=this.removeQuotesFromFirstWord(JSON.stringify(t.animation));r+="\n animation: ".concat(v,",")}if(t.transform){var b=this.removeQuotesFromFirstWord(JSON.stringify(t.transform));r+="\n transform: ".concat(b,",")}var g="new Link().set({".concat(r,"}) \n");this.code.push(g),t.color&&this.color(t.color),t.rounded&&this.round(),t.transform&&t.transform.transform?this.reactOnTransform(t.transform):this.reactOnTransform(t);var w=[],k=[t.border,t.gradient,t.animation,t.span,t.shadow,t.backgroundOp,t.animation];if((k=k.filter((function(t){return null!=t}))).length>0){for(var x=0;x<k.length;x++)w.push({range:k[x].range,log:k[x].op.name,target:k[x].target,op:k[x].op});var S=[];t.borderObj&&S.push("border"),t.background&&S.push("background"),t.mar&&S.push("margin"),t.animation&&S.push("animation"),this.chainReact(w,t.id,S,t.isNavA),this.res.style.zIndex=1}return t.mar&&this.mar(t.mar),this}},{key:"color",value:function(t){return this.res.style.color=t,this}},{key:"maxWidth",value:function(t){return this.res.style.maxWidth=t,this}},{key:"background",value:function(t){return this.res.style.backgroundColor=t,this}},{key:"leftAlign",value:function(){return this.res.style.textAlign="left",this}},{key:"arrayPadding",value:function(t,e){return e||(this.res.style.marginLeft="".concat(t[0],"px"),this.res.style.marginTop="".concat(t[1],"px"),this.res.style.marginRight="".concat(t[2],"px"),this.res.style.marginBottom="".concat(t[3],"px")),"all"===t[0]&&(this.res.style.paddingLeft=e,this.res.style.paddingTop=e,this.res.style.paddingRight=e,this.res.style.paddingBottom=e),t.includes("left")&&(this.res.style.paddingLeft=e),t.includes("right")&&(this.res.style.paddingRight=e),t.includes("top")&&(this.res.style.paddingTop=e),t.includes("bottom")&&(this.res.style.paddingBottom=e),e||(this.res.style.paddingBottom=t),this}},{key:"arrayMargin",value:function(t,e){return t.includes("left")&&(this.res.style.marginLeft=e),t.includes("right")&&(this.res.style.marginRight=e),t.includes("top")&&(this.res.style.marginTop=e),t.includes("bottom")&&(this.res.style.marginBottom=e),t.includes("all")&&(this.res.style.margin=e),e||(this.res.style.marginBottom=t),this}},{key:"getClampValue",value:function(t){return"S6"===t?"clamp(2.25rem, 2vw+1.5rem, 3.25rem)":"S5"===t?"clamp(2.75rem, 2vw + 1.5rem, 3.25rem)":"S4"===t?"clamp(3.5rem, 2vw + 1.5rem, 3.25rem)":"S3"===t?"clamp(4.25rem, 2vw + 1.5rem, 3.25rem)":"S2"===t?"clamp(5rem, 2vw + 1.5rem, 3.25rem)":"S1"===t?"clamp(6rem, 2vw + 1.5rem, 3.25rem)":void 0}},{key:"clampCopy",value:function(t){return this.res.style.fontSize=this.getClampValue(t),this}},{key:"fluidCopy",value:function(t){return"S1"===t&&(this.res.style.fontSize="calc(1.625rem + 5.075vw)"),"S2"===t&&(this.res.style.fontSize="calc(1.500rem + 4.3vw)"),"S3"===t&&(this.res.style.fontSize="calc(1.375rem + 3.525vw)"),"S4"===t&&(this.res.style.fontSize="calc(1.250rem + 2.75vw)"),"S5"===t&&(this.res.style.fontSize="calc(1.125rem + 1.975vw)"),"S6"===t&&(this.res.style.fontSize="calc(1rem + 0.5vw)"),this}},{key:"inlineBlock",value:function(){return this.res.style.display="inline-block",this}},{key:"toBlock",value:function(){return this.res.style.display="block",this}},{key:"myself",value:function(t){var e=this,r=function(){window.matchMedia("(max-device-width: 415px)").matches?e.res.style.fontSize=t.desktop:e.res.style.fontSize=t.phone};return r(),window.addEventListener("resize",r),this}},{key:"style",value:function(t){return this.res.style.color=t.styles.color,this.res.style.fontWeight=t.styles.fontWeight,this.res.style.paddingLeft=t.styles.padding[0],this.res.style.paddingTop=t.styles.padding[1],this.res.style.paddingRight=t.styles.padding[2],this.res.style.paddingBottom=t.styles.padding[3],this}},{key:"round",value:function(){return this.res.style.borderRadius="0.5rem",this.options.rounded&&(this.res.children[0].style.borderRadius="0.5rem"),this}},{key:"newWindow",value:function(){return this.res.target="_new",this}},{key:"radius",value:function(t){return this.res.style.borderRadius="".concat(t),this}},{key:"transition",value:function(t){return this.res.style.transition="".concat(t,"s ease-in-out"),this.res.style.transionProperty="background, color",this}},{key:"width",value:function(t){return this.res.style.width=t,this}},{key:"italic",value:function(){return this.res.style.fontStyle="italic",this}},{key:"padding",value:function(t,e,r,n){return t&&e&&r&&n?(this.res.style.paddingLeft=t,this.res.style.paddingTop=e,this.res.style.paddingRight=r,this.res.style.paddingBottom=n):this.res.style.padding=t,this}},{key:"medium",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?t.res.style.fontSize="2rem":t.res.style.fontSize="1.5em"};return e(),window.addEventListener("resize",e),this}},{key:"opacity",value:function(t){return this.res.style.opacity=t,this}},{key:"margin",value:function(t,e,r,n){return this.res.style.marginTop=t,this.res.style.marginLeft=e,this.res.style.marginRight=r,this.res.style.marginBottom=n,this}},{key:"hover",value:function(t){var e=this;if(t.border){var r=t.border.width;this.res.style.border=r?"".concat(r,"px solid transparent"):"1px solid transparent"}var n=this.options.borderObj;return n&&(this.res.style.border="".concat(n.width,"px solid ").concat(n.color)),this.prevColor=this.res.style.backgroundColor,this.foreColor=this.res.style.color,this.prevBorder=this.res.style.border,t.animation&&(this.res.style.transition="".concat(t.animation),this.res.style.transionProperty="background, color"),this.res.onmouseout=function(){e.res.style.backgroundColor="".concat(e.prevColor),e.res.style.color="".concat(e.foreColor),e.res.style.border=e.prevBorder},this.res.onmouseover=function(){if(e.res.style.color=t.color,e.res.style.backgroundColor=t.background,t.border){var r,n=t.border.width,i=null!==(r=t.border.color)&&void 0!==r?r:"#2ECC71";e.res.style.border=n?"".concat(n,"px solid ").concat(i):"1px solid #2ECC71"}},this}},{key:"em",value:function(t){var e=this,r=window.matchMedia("(max-device-width: 415px)"),n=function(){r.matches?e.res.style.fontSize="2em":e.res.style.fontSize="1em"};return n(),window.addEventListener("resize",n),this}},{key:"font",value:function(t){return this.res.style.fontFamily=t,this}},{key:"render",value:function(t){return t?(document.querySelector(t).appendChild(this.res),this):this.res}}])&&M(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function H(t){return H="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},H(t)}function J(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,q(n.key),n)}}function q(t){var e=function(t){if("object"!=H(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=H(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==H(e)?e:e+""}function G(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(G=function(){return!!t})()}function Q(){return Q="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(t,e,r){var n=function(t,e){for(;!{}.hasOwnProperty.call(t,e)&&null!==(t=X(t)););return t}(t,e);if(n){var i=Object.getOwnPropertyDescriptor(n,e);return i.get?i.get.call(arguments.length<3?t:r):i.value}},Q.apply(null,arguments)}function X(t){return X=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},X(t)}function $(t,e){return $=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},$(t,e)}var Y=function(t){function e(){var t;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(t=function(t,e,r){return e=X(e),function(t,e){if(e&&("object"==H(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,G()?Reflect.construct(e,r||[],X(t).constructor):e.apply(t,r))}(this,e)).navbar=document.createElement("nav"),t.navbar.classList.add("desktop-navbar"),t.navbarHeader=document.createElement("div"),t.navbarHeader.classList.add("navbar-header"),t.brand=document.createElement("div"),t.brand.classList.add("navbar-brand"),t.navContent=document.createElement("div"),t.navContent.classList.add("navbar-content"),t.navContent.style.width="100%",t.navbarHeader.appendChild(t.brand),t.navbarHeader.appendChild(t.navContent),t.navbar.appendChild(t.navbarHeader),t.res=t.navbar,t}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&$(t,e)}(e,t),r=e,n=[{key:"set",value:function(t){var r,n,i;return console.warn(t),this.obj=t,t.background&&(this.res.style.backgroundColor=t.background),t.mar&&(r=e,n=this,"function"==typeof(i=Q(X(1&3?r.prototype:r),"mar",n))?function(t){return i.apply(n,t)}:i)([t.mar]),t.brand&&this.setBrand(t.brand),t.radius&&(this.res.style.borderRadius=t.radius),t.maxHeight&&(this.res.style.maxHeight=t.maxHeight),t.hamburgerColour&&(this.hamburgerColour=t.hamburgerColour),this.setStyles(),this}},{key:"setStyles",value:function(){this.navbar.style.display="flex",this.navbar.style.flexDirection="column",this.navbar.style.padding="1rem",this.navbar.style.backgroundColor="#333",this.navbar.style.color="white",this.navbarHeader.style.display="flex",this.navbarHeader.style.alignItems="center",this.navbarHeader.style.justifyContent="space-between",this.navbarHeader.style.width="100%",this.brand.style.fontSize="1.5rem",this.navContent.style.display="flex",this.navContent.style.gap="1rem"}},{key:"setBrand",value:function(t){return console.warn("SETA"),console.log(t),this.brand.innerHTML="",this.brand.appendChild(t),this}},{key:"add",value:function(t){this.items=t;for(var e=0;e<t.length;e++)t[e],this.navContent.appendChild(t[e].render());return this}},{key:"toCode",value:function(){console.warn(this.items);var t=this.items.map((function(t){return t.toCode()})).flatMap((function(t){return t}));return console.log("ITSA"),console.log(t),console.log("".concat(t.join(","))),"new DesktopBar().set(".concat(this.removeQuotesFromFirstWord(JSON.stringify(this.obj)),").add([\n ").concat(t.join(","),"\n\n \n \n\n ])")}},{key:"render",value:function(t){return t&&document.querySelector(t).appendChild(this.navbar),this.navbar}}],n&&J(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function V(t){return V="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},V(t)}function U(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,K(n.key),n)}}function K(t){var e=function(t){if("object"!=V(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=V(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==V(e)?e:e+""}function Z(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(Z=function(){return!!t})()}function tt(){return tt="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(t,e,r){var n=function(t,e){for(;!{}.hasOwnProperty.call(t,e)&&null!==(t=et(t)););return t}(t,e);if(n){var i=Object.getOwnPropertyDescriptor(n,e);return i.get?i.get.call(arguments.length<3?t:r):i.value}},tt.apply(null,arguments)}function et(t){return et=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},et(t)}function rt(t,e){return rt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},rt(t,e)}var nt=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e,r){return e=et(e),function(t,e){if(e&&("object"==V(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,Z()?Reflect.construct(e,r||[],et(t).constructor):e.apply(t,r))}(this,e)}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&rt(t,e)}(e,t),r=e,n=[{key:"removeQuotesFromBoth",value:function(t){if(t)return t.replace(/"([^"]+)":\s*"([^"]+)"/g,"$1: $2")}},{key:"removeQuotesFromFirstWord",value:function(t){if(t)return t.replace(/"([^"]+)":/g,"$1:")}},{key:"toCode",value:function(){console.warn(this.items);var t=this.items.map((function(t){return t.toCode()})).flatMap((function(t){return t}));console.log("BAD CONV"),console.log(this.removeQuotesFromFirstWord(JSON.stringify(this.obj,null,4)));var e=this.removeQuotesFromFirstWord(JSON.stringify(this.obj));console.log(e),console.log("REPL"),console.log(e);var r='\nbackground: "'.concat(this.obj.background,'",\nbrand: ').concat(this.obj.brand.toCode(),",\nmar: ").concat(JSON.stringify(this.obj.mar),",\npad: ").concat(JSON.stringify(this.obj.mar),",\nradius: ").concat(JSON.stringify(this.obj.radius),",\n");return"new MobileBar().set({".concat(r,"}).add([\n ").concat(t.join(","),"\n\n ])")}},{key:"set",value:function(t){var r,n,i;return this.obj=t,console.log("After passing to set:"),console.log("OBJ IN SET"),this.obj=t,this.makeNavbar(t),t.mar&&(r=e,n=this,"function"==typeof(i=tt(et(1&3?r.prototype:r),"mar",n))?function(t){return i.apply(n,t)}:i)([t.mar]),t.maxHeight&&(this.res.style.maxHeight=t.maxHeight),t.radius&&(this.res.style.borderRadius=t.radius),t.hamburgerColour&&(this.hamburgerColour=t.hamburgerColour),this.setStyles(t),this}},{key:"makeNavbar",value:function(t){var e=this;console.log("OBJ IN SETA");var r=t.brand;this.navbar=document.createElement("nav"),this.navbar.classList.add("mobile-navbar"),this.navbarHeader=document.createElement("div"),this.navbarHeader.classList.add("navbar-header"),this.brand=document.createElement("div"),this.brand.classList.add("navbar-brand"),console.log("BRIS"),console.log("APPENDED-"),t.brand&&"function"==typeof r.render?(console.log("Appending brand:",r.render()),this.brand.appendChild(r.render())):console.warn("Brand does not have a valid render method:",t.brand),this.toggleButton=document.createElement("button"),this.toggleButton.classList.add("navbar-toggle"),this.toggleButton.innerHTML="☰",this.navContent=document.createElement("div"),this.navContent.classList.add("navbar-content"),this.navbarHeader.appendChild(this.brand),this.navbarHeader.appendChild(this.toggleButton),this.navbar.appendChild(this.navbarHeader),this.navbar.appendChild(this.navContent),this.isMobileNavOpen=!1,this.toggleButton.addEventListener("click",(function(){e.toggleMobileNav()})),this.res=this.navbar}},{key:"setStyles",value:function(t){var e,r;this.navbar.style.display="flex",this.navbar.style.flexDirection="column",this.navbar.style.padding="1rem",this.navbar.style.backgroundColor=null!==(e=t.background)&&void 0!==e?e:"orange",this.navbarHeader.style.display="flex",this.navbarHeader.style.alignItems="center",this.navbarHeader.style.justifyContent="space-between",this.navbarHeader.style.width="100%",this.brand.style.fontSize="1.5rem",this.toggleButton.style.background="none",this.toggleButton.style.border="none",this.toggleButton.style.color=null!==(r=this.hamburgerColour)&&void 0!==r?r:"white",this.toggleButton.style.fontSize="1.5rem",this.toggleButton.style.cursor="pointer",this.navContent.style.display="none"}},{key:"add",value:function(t){console.log(t),this.items=t;for(var e=0;e<t.length;e++){var r=t[e];this.navContent.appendChild(r.render())}return this}},{key:"toggleMobileNav",value:function(){this.isMobileNavOpen=!this.isMobileNavOpen,this.navContent.style.display=this.isMobileNavOpen?"flex":"none",this.isMobileNavOpen?(this.navContent.style.flexDirection="column",this.navContent.style.gap="0.5rem",this.navContent.style.padding="1rem"):(this.navContent.style.flexDirection="",this.navContent.style.gap="",this.navContent.style.backgroundColor="",this.navContent.style.padding="")}},{key:"render",value:function(t){return t&&document.querySelector(t).appendChild(this.navbar),this.navbar}}],n&&U(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function it(t){return it="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},it(t)}function ot(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function st(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?ot(Object(r),!0).forEach((function(e){at(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):ot(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function at(t,e,r){return(e=ct(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function lt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,ct(n.key),n)}}function ct(t){var e=function(t){if("object"!=it(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=it(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==it(e)?e:e+""}function ut(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(ut=function(){return!!t})()}function dt(t){return dt=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},dt(t)}function ht(t,e){return ht=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},ht(t,e)}var ft=function(t){function e(){var t;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(t=function(t,e,r){return e=dt(e),function(t,e){if(e&&("object"==it(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,ut()?Reflect.construct(e,r||[],dt(t).constructor):e.apply(t,r))}(this,e)).breakpoints=[],t.container=null,t.currentView=null,t.internalDiv=null,t.resizeListener=null,t}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&ht(t,e)}(e,t),r=e,n=[{key:"set",value:function(t){var e=t.breakpoints;if(this.options={breakpoints:e},!Array.isArray(e))throw new Error("Breakpoints should be an array of objects with 'at' and 'view' properties.");return this.breakpoints=e.map((function(t){if("string"!=typeof t.at||!(t.view.render()instanceof HTMLElement))throw new Error("Each breakpoint must have 'at' as a string and 'view' as an HTMLElement.");return st(st({},t),{},{at:parseInt(t.at,10)})})),this.breakpoints.sort((function(t,e){return t.at-e.at})),this}},{key:"toCode",value:function(){JSON.stringify(this.options.breakpoints.map((function(t){return t.view.toCode()})).flat(),null,4),JSON.stringify(this.options.breakpoints.map((function(t){return t.at})),null,4),JSON.stringify(this.options.breakpoints,null,4);for(var t="",e=0;e<this.options.breakpoints.length;e++)t+='{ at: "'.concat(this.options.breakpoints[e].at,'", view: ').concat(this.options.breakpoints[e].view.toCode()," }, \n");return["new Switcher().set({\n breakpoints: [\n ".concat(t,"\n ]\n })")]}},{key:"render",value:function(t){return this.internalDiv=document.createElement("div"),this.applyView(),this.resizeListener=this.applyView.bind(this),window.addEventListener("resize",this.resizeListener),void 0!==t&&document.querySelector(t).appendChild(this.internalDiv),this.internalDiv}},{key:"createRanges",value:function(t){for(var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:99999,r=[],n=0;n<t.length;n++)r.push({from:t[n],to:n<t.length-1?t[n+1]-1:e});return r}},{key:"addRanges",value:function(t,e){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:99999;return t.map((function(t,n){var i=e[n],o=n<e.length-1?e[n+1]-1:r;return st(st({},t),{},{range:{from:i,to:o}})}))}},{key:"applyView",value:function(){var t=this;console.log("MAKE RANGES"),window.innerWidth,console.log(this.breakpoints),console.log(this.breakpoints.map((function(t){return t.at})));var e=this.breakpoints.map((function(t){return t.at})),r=this.breakpoints.map((function(t){return t.at})),n=(this.createRanges(r),this.addRanges(this.breakpoints,e));console.log(n),n.forEach((function(e){var r="(min-width: ".concat(e.range.from,"px) and (max-width: ").concat(e.range.to,"px)"),n=window.matchMedia(r);console.warn(r),n.matches&&(console.log("Viewport width is within the range: ".concat(e.range.from,"px to ").concat(e.range.to,"px")),t.currentView!==e.view.render()&&(t.internalDiv.innerHTML="",t.internalDiv.appendChild(e.view.render()),t.currentView=e.view.render()))})),console.log("MBO")}},{key:"destroy",value:function(){this.resizeListener&&(window.removeEventListener("resize",this.resizeListener),this.resizeListener=null),this.internalDiv&&this.container&&this.container.removeChild(this.internalDiv),this.container=null,this.currentView=null,this.internalDiv=null}}],n&<(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function yt(t){return yt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},yt(t)}function pt(t,e){if(t){if("string"==typeof t)return mt(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?mt(t,e):void 0}}function mt(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function vt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,bt(n.key),n)}}function bt(t){var e=function(t){if("object"!=yt(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=yt(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==yt(e)?e:e+""}function gt(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(gt=function(){return!!t})()}function wt(t){return wt=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},wt(t)}function kt(t,e){return kt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},kt(t,e)}var xt=function(t){function e(){var t;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(t=function(t,e,r){return e=wt(e),function(t,e){if(e&&("object"==yt(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,gt()?Reflect.construct(e,r||[],wt(t).constructor):e.apply(t,r))}(this,e)).res=document.createElement("div"),t.toggleWrap=document.createElement("div"),t.toggleWrap.style.zIndex=9999,t.toggleWrap.style.borderRadius="0.3rem",t.toggleWrap.style.height="40px",t.toggleWrap.style.cursor="pointer",t.toggleWrap.style.display="flex",t.toggleWrap.style.alignItems="center",t.toggleWrap.style.justifyContent="center",t.res.appendChild(t.toggleWrap),t.contentWrap=document.createElement("div"),t.contentWrap.style.position="absolute",t.contentWrap.style.background="#ecf0f1",t.contentWrap.style.borderRadius="0.3rem",t.contentWrap.style.boxShadow="0 2px 5px rgba(0, 0, 0, 0.15)",t.contentWrap.style.marginTop="10px",t.contentWrap.style.width="250px",t.contentWrap.style.display="none",t.res.appendChild(t.contentWrap),t.styles={},t.children=[],t.isExpanded=!1,t.toggleWrap.addEventListener("click",(function(){return t.toggle()})),t}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&kt(t,e)}(e,t),r=e,(n=[{key:"set",value:function(t){var e=this;this.options=t,t.title&&(this.toggleWrap.textContent=t.title),t.width&&(this.toggleWrap.style.width=t.width),t.contentWidth&&(this.contentWrap.style.width=t.contentWidth),t.background&&(this.contentWrap.style.backgroundColor=t.background),t.mar&&this.mar(t.mar);var r=function(){var r,n=window.matchMedia("(max-device-width: 415px)"),i=window.matchMedia("(max-width: ".concat(null!==(r=t.breakpoint)&&void 0!==r?r:"600px",")"));n.matches||i.matches?e.contentWrap.style.position="relative":e.contentWrap.style.position="absolute"};return window.addEventListener("resize",r),r(),this}},{key:"add",value:function(t){var e,r=this;if(!Array.isArray(t))throw new Error("The 'add' method expects an array of children.");if(t.forEach((function(t,e){if(0!==e){if(!(t.res instanceof HTMLElement))throw new Error("Each child must have a valid 'element' property that is an HTMLElement.");r.contentWrap.appendChild(t.res)}})),!this.options||!this.options.title){var n=t[0];n&&n.res&&this.toggleWrap.appendChild(n.res)}return(e=this.children).push.apply(e,function(t){return function(t){if(Array.isArray(t))return mt(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||pt(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(t)),this}},{key:"toggle",value:function(){this.isExpanded=!this.isExpanded,this.contentWrap.style.display=this.isExpanded?"block":"none"}},{key:"toCode",value:function(){var t=this,e=this.options?Object.entries(this.options).map((function(t){var e=function(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==e);l=!0);}catch(t){c=!0,i=t}finally{try{if(!l&&null!=r.return&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}(t,e)||pt(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(t,2),r=e[0],n=e[1];return"string"==typeof n?"".concat(r,': "').concat(n,'"'):"object"===yt(n)?"".concat(r,": ").concat(JSON.stringify(n)):"".concat(r,": ").concat(n)})).join(",\n "):"",r=this.children.map((function(e,r){return e.toCode().flatMap((function(t){return t})).join("")+(r<t.children.length-1?",":"")})).join("");return["new Dropdown().set({\n ".concat(e,"\n}).add([\n ").concat(r,"\n])")]}},{key:"render",value:function(t){return t&&document.querySelector(t).appendChild(this.res),this.res}}])&&vt(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function St(t){return St="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},St(t)}function Ot(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=function(t,e){if(t){if("string"==typeof t)return Ct(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Ct(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,i=function(){};return{s:i,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,s=!0,a=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return s=t.done,t},e:function(t){a=!0,o=t},f:function(){try{s||null==r.return||r.return()}finally{if(a)throw o}}}}function Ct(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function jt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Et(n.key),n)}}function Et(t){var e=function(t){if("object"!=St(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=St(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==St(e)?e:e+""}function Tt(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(Tt=function(){return!!t})()}function Pt(){return Pt="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(t,e,r){var n=function(t,e){for(;!{}.hasOwnProperty.call(t,e)&&null!==(t=At(t)););return t}(t,e);if(n){var i=Object.getOwnPropertyDescriptor(n,e);return i.get?i.get.call(arguments.length<3?t:r):i.value}},Pt.apply(null,arguments)}function At(t){return At=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},At(t)}function Rt(t,e){return Rt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},Rt(t,e)}var Lt=function(t){function e(t){var r;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(r=function(t,e,r){return e=At(e),function(t,e){if(e&&("object"==St(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,Tt()?Reflect.construct(e,r||[],At(t).constructor):e.apply(t,r))}(this,e)).res=null,r.setup(t),r.code=[],r.isLast=!1,r.code.push("\n new Wrapper() \n"),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Rt(t,e)}(e,t),r=e,n=[{key:"isLasta",value:function(){return this.isLast=!0,this}},{key:"toCode",value:function(){return this.code}},{key:"getType",value:function(){return"LayoutWrapperElement"}},{key:"setArea",value:function(t){return this.res.style.gridArea=t,this}},{key:"removeQuotesFromFirstWord",value:function(t){return t.replace(/"([^"]+)":/g,"$1:")}},{key:"clicked",value:function(t){return this.res.addEventListener("click",t),this}},{key:"gpos",value:function(t){return this.res.style.gridColumn=t.col,this.res.style.gridRow=t.row,this}},{key:"set",value:function(t){var r,n,i,o=".set({";if(t.pad&&this.pad(t.pad),t.arrpad&&(o+="pad: {sides: [".concat(t.arrpad.sides.map((function(t){return'"'.concat(t,'"')})).join(", "),'], value: "').concat(t.arrpad.value,'"}, ')),t.gpos&&this.gpos(t.gpos),t&&t.id&&t.stroke||t&&t.id&&t.gradient||t&&t.id&&t.span||t&&t.id&&t.layout){t.gradient,t.gradient&&(this.globalGradient=t.gradient.op.gradient),t.stroke&&(r=e,n=this,"function"==typeof(i=Pt(At(1&3?r.prototype:r),"setAny",n))?function(t){return i.apply(n,t)}:i)([{globalBlast:"".concat(t.stroke.op.width," ").concat(t.stroke.op.color)}]);var s=[t.stroke,t.gradient,t.animation,t.span,t.layout];s=s.filter((function(t){return null!=t}));for(var a=[],l=0;l<s.length;l++)a.push({range:s[l].range,log:s[l].op.name,target:s[l].target});this.res.setAttribute("id",t.id),this.betaReact(a,t.id)}if(t.socenter&&(this.res.style.display="flex",this.res.style.flexDirection="column",this.res.style.alignItems="center",t.socenter&&(o+="socenter: ".concat(t.socenter,","))),t.mboth&&(this.res.style.marginRight="auto")&&(this.res.style.marginLeft="auto"),t.mar&&this.mar(t.mar),t.sticky&&this.sticky(),t.transition&&(this.res.style.transition=t.transition),t.class&&this.res.setAttribute("class",t.class),t.ga&&(this.res.style.gridArea=t.ga),t.opacity&&(0==t.opacity&&(this.res.style.opacity=0),t.opacity&&(this.res.style.opacity=t.opacity)),t.maxHeight&&(this.res.style.maxHeight=t.maxHeight),t.id&&this.res.setAttribute("id",t.id),t.arrpad&&this.arrayPadding(t.arrpad.sides,t.arrpad.value),t.arrpad&&(o+="arrpad: {sides: [".concat(t.arrpad.sides.map((function(t){return'"'.concat(t,'"')})).join(", "),'], value: "').concat(t.arrpad.value,'"}, ')),t.arrayMargin&&this.arrayMargin(t.arrayMargin.sides,t.arrayMargin.value),t.arrayMargin&&(o+='\n arrayMargin: {sides: ["'.concat(t.arrayMargin.sides,'"], value: "').concat(t.arrayMargin.value,'"},')),t.center&&this.toCenter(t.center),t.center&&(o+='center: "'.concat(t.center,'",')),t.simpleCenter&&this.simpleCenter(),t.simpleCenter&&(o+='center: "'.concat(t.simpleCenter,'",')),t.filter&&(this.res.style.backdropFilter="blur(3px)"),t.radius&&this.corner(t.radius),t.radius&&(o+='\n radius: "'.concat(t.radius,'",')),t.border&&this.border(t.border),t.simpleBorder&&(this.res.style.border=t.simpleBorder),t.width&&this.width(t.width),t.width&&(o+='\n width: "'.concat(t.width,'",')),t.overflow&&(this.res.style.overflow="hidden"),t.overflow&&(o+='\n overflow: "'.concat(t.overflow,'",')),t.height&&this.heightNoAuto(t.height),t.height&&(o+='\n height: "'.concat(t.height,'",')),t.align&&this.flexAlign(t.align),t.align&&(o+='\n align: "'.concat(t.align,'",')),t.borderObj&&(this.res.style.borderRight="".concat(t.borderObj.width," solid ").concat(t.borderObj.color),this.res.style.borderRadius=t.borderObj.radius),t.borderObja&&(this.res.style.border="".concat(t.borderObja.width," solid ").concat(t.borderObja.color),this.res.style.borderRadius=t.borderObja.radius),t.font&&this.font(t.font),t.font&&(o+='font: "'.concat(t.font,'",')),t.maxWidth&&this.maxWidth(t.maxWidth),t.flexCenter&&this.flexc(t.flexCenter),t.multipad&&this.makeMultiPad(t.multipad),t.multimargin&&this.makeMultiMargin(t.multimargin),t.color&&this.color(t.color),t.background&&this.background(t.background),t.background&&(o+='background: "'.concat(t.background,'",')),t.weight&&this.weight(t.weight),t.paddings&&this.paddingo(t.paddings),t.area&&this.setArea(t.area),t.area&&(o+='area: "'.concat(t.area,'"')),t.column&&this.makeCol(),t.column&&(o+='\n column: "'.concat(t.column,'",')),t.alignIts&&(this.res.style.background="gray"),t.alignIts&&(this.res.style.alignItems="flex-start"),t.alignIts&&(this.res.style.justifyItems="flex-start"),t.customAlign&&(this.res.style.alignItems=t.customAlign),t.customJustify&&(this.res.style.justifyItems=t.customJustify),t.disp&&(this.res.style.display=t.disp),t.flexDir&&(this.res.style.flexDirection=t.flexDir),t.flexDir&&(this.res.style.display="flex"),t.flexDir&&(o+='\n flexDir: "'.concat(t.flexDir,'",')),t.zIndex&&(this.res.style.zIndex=t.zIndex),t.name&&(this.name=t.name),t.responsive&&this.rsp(t.responsive),t.stretch){t.stretch&&this.stretch(t.stretch);var c=this.removeQuotesFromFirstWord(JSON.stringify(t.stretch));o+="\n stretch: ".concat(c,",")}for(var u in t)if("margin"===u){var d=t[u];if(Array.isArray(d)&&d.length>0){var h,f=Ot(d);try{for(f.s();!(h=f.n()).done;){var y=h.value;y.hasOwnProperty("top")&&(this.res.style.marginTop=y.top),y.hasOwnProperty("right")&&(this.res.style.marginRight=y.right),y.hasOwnProperty("bottom")&&(this.res.style.marginBottom=y.bottom),y.hasOwnProperty("left")&&(this.res.style.marginLeft=y.left)}}catch(t){f.e(t)}finally{f.f()}}}return 8===(o+="})\n").length&&(o=""),this.code.push(o),this}},{key:"rsp",value:function(t){var e=this;this.res.style.display="flex";var r=t.sequence.split("-"),n=function(){var n=t.ranges;"0px"!==n[0]&&n.unshift("0px");for(var i=0;i<n.length-1;i++)(window.matchMedia("(min-width: ".concat(n[i],") and (max-width: ").concat(n[i+1],")")).matches||window.matchMedia("(min-width: ".concat(n[n.length-1],")")).matches)&&("row"===r[i]&&(e.res.style.flexDirection="row",e.res.style.border="3px solid green"),"col"===r[i]&&(e.res.style.flexDirection="column",e.res.style.border="3px solid purple"));return e};window.addEventListener("resize",n),n()}},{key:"sticky",value:function(){return this.res.style.position="sticky",this.res.style.top=0,this}},{key:"toSticky",value:function(){return this.res.style.position="sticky",this.res.style.top="0",this}},{key:"stretch",value:function(t){var e=this,r=function(){window.matchMedia("(max-width: ".concat(t.at,")")).matches?e.res.style.width="auto":window.matchMedia("(max-device-width: 415px)").matches?e.res.style.width="100%":e.res.style.width=t.backTo};r(),window.addEventListener("resize",r)}},{key:"makeCol",value:function(){return this.res.style.display="flex",this.res.style.flexDirection="column",this.res.style.alignItems="flex-start",this}},{key:"paddingo",value:function(t){return this.res.style.padding=t,this}},{key:"toCenter",value:function(t){return this.res.style.display="flex",this.res.style.flexDirection="column",this.res.style.justifyContent="center","both"===t&&(this.res.style.alignItems="center"),this}},{key:"simpleCenter",value:function(){return this.res.style.justifyContent="center",this.res.style.justifyItems="center",this.res.style.alignContent="center",this.res.style.alignItems="center",this}},{key:"color",value:function(t){return this.res.style.color=t,this}},{key:"weight",value:function(t){return this.res.style.fontWeight=t,this}},{key:"makeMultiPad",value:function(t){for(var e=0;e<t.length;e++)"left"===t[e].side&&(this.res.style.paddingLeft=t[e].value),"right"===t[e].side&&(this.res.style.paddingRight=t[e].value);return this}},{key:"makeMultiMargin",value:function(t){this.res.style.zIndex="1";for(var e=0;e<t.length;e++)"left"===t[e].side&&(this.res.style.marginLeft=t[e].value),"right"===t[e].side&&(this.res.style.marginRight=t[e].value),"top"===t[e].side&&(this.res.style.marginTop=t[e].value),"bottom"===t[e].side&&(this.res.style.marginBottom=t[e].value);return this}},{key:"flexc",value:function(t){return this.res.style.display="flex",this.res.style.flexDirection="column",this.res.style.justifyContent="center",this}},{key:"maxWidth",value:function(t){return this.res.style.maxWidth=t,this}},{key:"font",value:function(t){return this.res.style.fontFamily=t,this}},{key:"flexAlign",value:function(t){return this.res.style.display="flex",this.res.style.justifyContent="flex-start",this.res.style.alignItems="flex-start","center"===t?(this.res.style.display="flex",this.res.style.flexDirection="column",this.res.style.alignItems="center",this):this}},{key:"width",value:function(t){return this.res.style.width=t,this}},{key:"heightNoAuto",value:function(t){return this.res.style.height=t,this}},{key:"border",value:function(t){return this.res.style.borderRadius="".concat(t.radius,"px"),this.res.style.padding="0.25em",this.res.style.border="".concat(t.width,"px solid ").concat(t.color),this}},{key:"toCol",value:function(){return this.res.style.display="flex",this.res.style.flexDirection="column",this.res.style.justifyContent="center",this.res.style.alignItems="center",this}},{key:"add",value:function(t){this.items=t,this.code.push(".add([ \n");var e=t.map((function(e,r){return e.toCode().flatMap((function(t){return t})).join("")+(r<t.length-1?",":"")})).join("");this.code.push(e);for(var r=0;r<t.length;r++)if(void 0!==t[r]&&void 0!==t[r].toCode){var n=t[r].render();this.res.appendChild(n)}return this.code.push("])"),this}},{key:"arrayPadding",value:function(t,e){return t.includes("left")&&(this.res.style.paddingLeft=e),t.includes("right")&&(this.res.style.paddingRight=e),t.includes("top")&&(this.res.style.paddingTop=e),t.includes("bottom")&&(this.res.style.paddingBottom=e),this}},{key:"arrayMargin",value:function(t,e){return e||(this.res.style.marginLeft="".concat(t[0],"px"),this.res.style.marginTop="".concat(t[1],"px"),this.res.style.marginRight="".concat(t[2],"px"),this.res.style.marginBottom="".concat(t[3],"px")),t.includes("left")&&(this.res.style.marginLeft=e),t.includes("right")&&(this.res.style.marginRight=e),t.includes("top")&&(this.res.style.marginTop=e),t.includes("bottom")&&(this.res.style.marginBottom=e),this}},{key:"setWidth",value:function(t){this.res.style.width="100vw"}},{key:"setHeight",value:function(t){return this.res.style.height="".concat(t),this}},{key:"setup",value:function(t){var e=t?document.createElement(t.isLink?"a":"div"):document.createElement("div");return t&&t.isLink&&(e.style.textDecoration="none",e.setAttribute("href",t.child)),this.res=e,this.res.style.margin=0,this.res.style.padding=0,t&&!0===t.hideOverflow&&(this.res.style.overflow="hidden",this.res.style.overflowY="scroll"),t&&!0===t.center&&(this.res.style.display="flex",this.res.style.flexDirection="column",this.res.style.justifyContent="center",this.res.style.alignItems="center"),t&&"left"===t.align&&(this.res.style.alignItems="flex-start"),t&&"right"===t.align&&(this.res.style.alignItems="flex-end"),t&&t.height&&(this.res.style.height=t.height),t&&t.width&&(this.res.style.width=t.width,this.res.style.marginLeft="auto",this.res.style.marginRight="auto",window.matchMedia("(max-device-width: 415px)").matches&&(this.res.style.width="95%")),this}},{key:"height",value:function(t){return this.res.style.width="auto",this.res.style.height="".concat(t),this}},{key:"size",value:function(t,e){return this.w=t,this.h=e,this.w?this.res.style.width=this.w:this.res.style.width=window.innerWidth,this.h?this.res.style.height=this.h:this.res.style.height=window.innerHeight,this}},{key:"background",value:function(t){return this.res.style.background=t,this}},{key:"corner",value:function(t){return this.res.style.borderRadius=t,this}},{key:"padding",value:function(t,e,r,n){return this.res.style.paddingLeft=t,this.res.style.paddingTop=e,this.res.style.paddingRight=r,this.res.style.paddingBottom=n,this}},{key:"margin",value:function(t,e,r,n){return this.res.style.marginLeft=t,this.res.style.marginTop=e,this.res.style.marginRight=r,this.res.style.marginBottom=n,this}},{key:"itemWidth",value:function(t){for(var e=0;e<this.res.childNodes.length;e++)this.res.childNodes[e].style.width=t;return this}},{key:"apply",value:function(t){var e=this,r=function(){for(var r=0;r<t.length;r++){var n=t[r],i=window.matchMedia("(max-width: ".concat(n.width,"px)"));n.device&&(i=window.matchMedia("(max-device-width: ".concat(n.width,"px)")),alert(n.device)),i.matches&&Object.assign(e.res.style,n.styles)}},n=window.matchMedia("(max-width: ".concat(t[0].width,"px)"));return t[0].device&&(n=window.matchMedia("(max-device-width: ".concat(t[0].width,"px)"))),n.matches||Object.assign(this.res.style,t[0].styles),r(),window.addEventListener("resize",r),this}},{key:"mount",value:function(t){document.querySelector(t).appendChild(this.res)}},{key:"render",value:function(t){return t?(document.querySelector("#mount"),document.querySelector(t).appendChild(this.res),this):this.res}}],n&&jt(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function zt(t){return zt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},zt(t)}function Mt(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=function(t,e){if(t){if("string"==typeof t)return It(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?It(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,i=function(){};return{s:i,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,s=!0,a=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return s=t.done,t},e:function(t){a=!0,o=t},f:function(){try{s||null==r.return||r.return()}finally{if(a)throw o}}}}function It(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function Bt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Nt(n.key),n)}}function Nt(t){var e=function(t){if("object"!=zt(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=zt(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==zt(e)?e:e+""}function Wt(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(Wt=function(){return!!t})()}function _t(t){return _t=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},_t(t)}function Ft(t,e){return Ft=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},Ft(t,e)}var Dt=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e,r){return e=_t(e),function(t,e){if(e&&("object"==zt(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,Wt()?Reflect.construct(e,r||[],_t(t).constructor):e.apply(t,r))}(this,e)}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Ft(t,e)}(e,t),r=e,(n=[{key:"setup",value:function(t){return this.obj=t,this.animate=void 0===this.obj.animate||this.obj.animate,this.res=this.createSideNav(t),this.res.style.position="relative",this.res.style.zIndex=3,this.closed=!0,this}},{key:"toggleSideNav",value:function(t){this.closed=!this.closed;var e=this.res.children[0];if(this.closed)if(e.style.overflowX="hidden",t.style.opacity=1,this.animate){e.animate([{transform:"translateX(0)"},{transform:"translateX(100%)"}],{duration:300,fill:"forwards"});var r,n=-1,i=Mt(e.children);try{for(i.s();!(r=i.n()).done;){var o=r.value;if(n+=1,this.masterEL[n]){var s,a=Mt(o.children);try{for(a.s();!(s=a.n()).done;){var l=s.value,c=this.masterEL[n].options.animation;c&&this.mappedIDS.includes(l.id)&&l.animate(c.op.keyframesClose,c.op.closeOptions)}}catch(t){a.e(t)}finally{a.f()}}}}catch(t){i.e(t)}finally{i.f()}}else e.style.display="none";else{e.style.overflowX="none",e.children[1].style.border="1px solid orange";var u,d=-1,h=Mt(e.children);try{for(h.s();!(u=h.n()).done;){var f=u.value;d+=1;var y,p=Mt(f.children);try{for(p.s();!(y=p.n()).done;){var m=y.value;if(this.mappedIDS.includes(m.id)&&void 0!==this.masterEL[0]){var v=this.masterEL[d].options.animation;if(v){console.log("OPEN KEYFRAMES"),console.log(v.op.keyframesOpen);var b=v.op.openOptions;b.delay||(b.delay=1),b.duration||(b.duration=300),console.log(b),m.animate(v.op.keyframesOpen,b)}}}}catch(t){p.e(t)}finally{p.f()}}}catch(t){h.e(t)}finally{h.f()}t.style.opacity=0,this.animate?(e.style.display="flex",e.animate([{transform:"translateX(100%)"},{transform:"translateX(0)"}],{duration:300,fill:"forwards"})):e.style.display="flex"}}},{key:"createToggleButton",value:function(t){var e=document.createElement("button");return e.innerText="☰",e.style.padding="10px 20px",e.style.backgroundColor="transparent",e.style.color=null!=t?t:"#3498db",e.style.border="none",e.style.borderRadius="5px",e.style.cursor="pointer",e.style.zIndex=1,e.style.fontSize="1.6rem",e}},{key:"createCloseButton",value:function(t){var e=document.createElement("button");return e.innerText="×",e.style.fontSize="1.6rem",e.style.padding="10px 20px",e.style.backgroundColor="transparent",e.style.color=null!=t?t:"black",e.style.border="none",e.style.borderRadius="5px",e.style.cursor="pointer",e.style.zIndex=1,e.style.alignSelf="flex-end",e}},{key:"createSideNav",value:function(t){var e=this,r=document.createElement("div");r.style.display="flex",r.style.justifyContent="flex-end";var n=document.createElement("div");n.style.display="none",n.style.background=this.obj.background||"#1abc9c",n.style.height="100%",window.matchMedia("(max-device-width: 415px)").matches?n.style.width="100%":n.style.width=this.obj.width||"400px",n.style.position="fixed",n.style.right=0,this.animate&&(n.style.transform="translateX(100%)"),n.style.flexDirection="column",n.style.justifyContent="flex-start";var i=this.createToggleButton(this.obj.hamColour.opened),o=this.createCloseButton(this.obj.hamColour.closed);return i.addEventListener("click",(function(){return e.toggleSideNav(i)})),o.addEventListener("click",(function(){return e.toggleSideNav(i)})),n.appendChild(o),r.appendChild(n),r.appendChild(i),r}},{key:"items",value:function(t){this.masterEL=t.items.filter((function(t){return void 0!==t.link})),console.log("EXTRACT IDs"),console.log(t);var e=t.items.filter((function(t){return void 0===t.items})).map((function(t){return t.id}));if(this.mappedIDS=e,this.item=t,this.res.children[0].appendChild(t.render()),void 0!==this.masterEL[0]){console.log("ANNAX"),console.log(this.masterEL[0]);var r=this.masterEL[0].options.animation;if(r){var n,i=Mt(this.res.children[0].children);try{for(i.s();!(n=i.n()).done;){var o,s=Mt(n.value.children);try{for(s.s();!(o=s.n()).done;){var a=o.value;if(this.mappedIDS.includes(a.id)){var l=r.op.closeOptions;l.delay=0,console.log("ANNAX"),console.log("SETTING INITIAL STATE ZEROING THE DELAY"),console.log(r.op.keyframesClose),console.log(l),a.animate(r.op.keyframesClose,r.op.closeOptions)}}}catch(t){s.e(t)}finally{s.f()}}}catch(t){i.e(t)}finally{i.f()}}}return this}},{key:"toCode",value:function(){var t="new SideNav().setup(".concat(this.formatObj(this.obj),")");if(this.item){var e=this.item.toCode?this.item.toCode().join(""):this.formatObj(this.item);e=e.replace(/,\s*(\.set\(|\.add\()/g,"\n $1"),t+=".items(".concat(e,")")}return t}},{key:"formatObj",value:function(t){return JSON.stringify(t,null,2).replace(/"(\w+)"\s*:/g,"$1:")}},{key:"render",value:function(t){return t&&document.querySelector(t).appendChild(this.res),this.res}}])&&Bt(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function Ht(t){return Ht="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ht(t)}function Jt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,qt(n.key),n)}}function qt(t){var e=function(t){if("object"!=Ht(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Ht(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Ht(e)?e:e+""}var Gt=function(){return t=function t(e){if(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.hide=e,e){var r=document.createElement("div");r.style.flex="1",this.res=r}return e&&this.res.setAttribute("class","innerHider"),this},(e=[{key:"toCode",value:function(){return["new Spacer(".concat(this.hide,")")]}},{key:"render",value:function(){var t,e=document.createElement("h2");return e.style.display="none !important",null!==(t=this.res)&&void 0!==t?t:e}}])&&Jt(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function Qt(t){return Qt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Qt(t)}function Xt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,$t(n.key),n)}}function $t(t){var e=function(t){if("object"!=Qt(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Qt(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Qt(e)?e:e+""}function Yt(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(Yt=function(){return!!t})()}function Vt(t){return Vt=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},Vt(t)}function Ut(t,e){return Ut=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},Ut(t,e)}var Kt=function(t){function e(){var t;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(t=function(t,e,r){return e=Vt(e),function(t,e){if(e&&("object"==Qt(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,Yt()?Reflect.construct(e,r||[],Vt(t).constructor):e.apply(t,r))}(this,e)).el=null,t}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Ut(t,e)}(e,t),r=e,(n=[{key:"set",value:function(t){this.options=t;var e=document.createElement("div"),r=document.createElement("label");r.style.position="relative",r.style.display="block";var n=document.createTextNode(t.title);r.appendChild(n),r.style.opacity=0;var i=document.createElement("input");return"textarea"===t.type&&(i=document.createElement("textarea")),i.style.position="relative",i.placeholder=t.title,i.style.fontSize="1rem",i.style.padding=".4rem .75rem",e.appendChild(r),e.appendChild(i),this.res=e,t.mar&&this.mar(t.mar),t.pad&&this.pad(t.pad),i.addEventListener("focus",(function(){r.style.transition="transform ease 0.2s",r.style.transform="scale(0.80)",r.style.textTransform="uppercase",r.style.transformOrigin="left top",r.style.fontWeight="bold",i.placeholder="",r.style.opacity="1.0",t.font&&(r.style.fontFamily=t.font),t.color&&(r.style.color=t.color),t.exact&&(r.style.fontSize=t.exact)})),i.addEventListener("focusout",(function(){r.style.transform="scale(1.0)",i.placeholder=t.title,r.style.opacity="0.0"})),t.name&&i.setAttribute("name",t.name),window.matchMedia("(max-device-width: 415px)").matches&&(i.style.width="100%",e.style.width="100%"),i.style.fontSize="1rem",this.el=e,this}},{key:"getValue",value:function(){return this.el.children[1].value}},{key:"toCode",value:function(){var t=JSON.stringify(this.options,null,4);return t=t.replace(/"(\w+)"(?=\s*:)/g,"$1"),["new FloatingInput().set(".concat(t,")")]}},{key:"margin",value:function(t){return this.el.style.margin=t,this}},{key:"render",value:function(t){if(!t)return this.el;document.querySelector(t).appendChild(this.el)}}])&&Xt(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function Zt(t){return Zt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Zt(t)}function te(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,ee(n.key),n)}}function ee(t){var e=function(t){if("object"!=Zt(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Zt(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Zt(e)?e:e+""}window.FloatingInput=Kt;var re=function(){return t=function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.el=null,this.minLabel=null,this.maxLabel=null,this.currentLabel=null},(e=[{key:"padding",value:function(t){return this.el.style.padding=t,this}},{key:"toCode",value:function(){var t=JSON.stringify(this.options,null,4);return["new Range().set(".concat(t,")")]}},{key:"set",value:function(t){var e,r,n=this;this.options=t;var i=document.createElement("input");if(i.setAttribute("id","slider"),i.setAttribute("type","range"),i.setAttribute("min",t.min),i.setAttribute("max",t.max),i.setAttribute("value",t.min),i.style.width=null!==(e=t.width)&&void 0!==e?e:"100%",!t.plain){var o,s;i.style.setProperty("-webkit-appearance","none"),i.style.appearance="none",i.style.height="9px",i.style.background=null!==(o=t.style.trackColor)&&void 0!==o?o:"orange",i.style.borderRadius="5px";var a="\n #slider::-webkit-slider-thumb {\n -webkit-appearance: none;\n appearance: none;\n width: 25px;\n height: 25px;\n border-radius: 50%;\n background: ".concat(null!==(s=t.style.thumbColor)&&void 0!==s?s:"4CAF50",";\n cursor: pointer;\n }\n "),l=document.createElement("style");l.appendChild(document.createTextNode(a)),document.head.appendChild(l)}var c=document.createElement("div");c.style.display="flex",c.style.flexDirection="column",c.style.alignItems="center",c.style.width="100%";var u=document.createElement("div");if(u.style.display="flex",u.style.justifyContent="space-between",u.style.width=null!==(r=t.width)&&void 0!==r?r:"100%",this.minLabel=document.createElement("span"),this.minLabel.textContent=t.min,this.maxLabel=document.createElement("span"),this.maxLabel.textContent=t.max,this.currentLabel=document.createElement("span"),this.currentLabel.textContent=i.value,t.font&&(this.currentLabel.style.fontFamily=t.font),t.font&&(this.minLabel.style.fontFamily=t.font),t.font&&(this.maxLabel.style.fontFamily=t.font),t.plain||(u.appendChild(this.minLabel),u.appendChild(this.currentLabel),u.appendChild(this.maxLabel)),i.addEventListener("input",(function(){n.currentLabel.textContent=i.value})),window.matchMedia("(max-device-width: 415px)").matches)if(t.plain)i.style.width="80%";else{var d,h;i.style.height="20px",i.style.background=null!==(d=t.style.trackColor)&&void 0!==d?d:"1abc9C",i.style.borderRadius="10px",i.style.fontSize="3rem",i.style.width="80%";var f="\n #slider::-webkit-slider-thumb {\n -webkit-appearance: none;\n appearance: none;\n width: 25px;\n height: 25px;\n border-radius: 50%;\n background: ".concat(null!==(h=t.style.thumbColor)&&void 0!==h?h:"blue",";\n cursor: pointer;\n }\n "),y=document.createElement("style");y.appendChild(document.createTextNode(f)),document.head.appendChild(y)}return c.appendChild(u),c.appendChild(i),this.el=c,this}},{key:"value",value:function(){return this.el.querySelector("#slider").value}},{key:"render",value:function(t){if(!t)return this.el;document.querySelector(t).appendChild(this.el)}}])&&te(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function ne(t){return ne="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ne(t)}function ie(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,oe(n.key),n)}}function oe(t){var e=function(t){if("object"!=ne(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=ne(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==ne(e)?e:e+""}window.Range=re;var se=function(){return t=function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.el=null,this.radioCount=0},(e=[{key:"set",value:function(t){this.options=t,console.log("ORARA"),console.log(this.options),this.radioCount=t.items.length;for(var e=document.createElement("div"),r=t.items,n=0;n<r.length;n++){var i=document.createElement("label");r.font&&(i.style.font=r.font),r.color&&(i.style.color=r.color),r.exact&&(i.style.fontSize=r.exact);var o=document.createTextNode(r[n]);i.appendChild(o),i.setAttribute("for",r[n]);var s=document.createElement("input");s.setAttribute("type","radio"),s.setAttribute("id","S".concat(n)),s.setAttribute("value",r[n].split(" ").join("")),s.style.appearance="none",s.style.width="20px",s.style.height="20px",s.style.border=this.options.tint?"2px solid ".concat(this.options.tint):"2px solid #007BFF",s.style.borderRadius="50%",s.style.outline="none",s.style.cursor="pointer",s.style.transition="0.3s",this.options.font&&(i.style.fontFamily=this.options.font),t.multiple?s.setAttribute("name",r[n].split(" ").join("")):s.setAttribute("name",t.name),e.appendChild(s),e.appendChild(i),e.innerHTML+="</br>"}return this.el=e,this.responsive(),this}},{key:"padding",value:function(t){return this.el.style.padding=t,this}},{key:"getCheckedValues",value:function(){console.log("NOW");for(var t=[],e=0;e<this.radioCount;e++)if(document.querySelector("#S".concat(e)).checked){var r=document.querySelector("#S".concat(e));console.log("VALUE IS "+r.value),t.push(r.value)}return t}},{key:"toCode",value:function(){var t=JSON.stringify(this.options,null,4);return t=t.replace(/"(\w+)"(?=\s*:)/g,"$1"),["new RadioGroup().set(".concat(t,")")]}},{key:"responsive",value:function(){return window.matchMedia("(max-device-width: 415px)").matches&&(this.el.style.fontSize="1.7em"),this}},{key:"render",value:function(t){var e=this;if(!t){console.log("MULA");for(var r=function(){var t=e.el.children[n];"[object HTMLInputElement]"===t.toString()&&t.addEventListener("change",(function(){if(t.checked){t.style.backgroundColor=e.options.tint?e.options.tint:"#007BFF",t.style.boxShadow=e.options.tint?"0 0 0 2px ".concat(e.options.tint," inset"):"0 0 0 2px #0056b3 inset";for(var r=0;r<e.el.children.length;r++){var n=e.el.children[r];"INPUT"===n.tagName&&"radio"===n.type&&!1===e.options.multiple&&n!==t&&(n.style.backgroundColor="transparent",n.style.boxShadow="none")}}else t.style.backgroundColor="transparent",t.style.boxShadow="none"}))},n=0;n<this.el.children.length;n++)r();return this.el}document.querySelector(t).appendChild(this.el)}}])&&ie(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function ae(t){return ae="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ae(t)}function le(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,ce(n.key),n)}}function ce(t){var e=function(t){if("object"!=ae(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=ae(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==ae(e)?e:e+""}function ue(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(ue=function(){return!!t})()}function de(t){return de=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},de(t)}function he(t,e){return he=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},he(t,e)}window.RadioGroup=se;var fe=function(t){function e(){var t;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(t=function(t,e,r){return e=de(e),function(t,e){if(e&&("object"==ae(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,ue()?Reflect.construct(e,r||[],de(t).constructor):e.apply(t,r))}(this,e)).el=null,t.file=null,t.selected="",t}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&he(t,e)}(e,t),r=e,n=[{key:"setup",value:function(t,e){document.createElement("div");var r=document.createElement("select");r.setAttribute("type","file"),r.setAttribute("name",e),r.addEventListener("change",(function(){r.options[r.selectedIndex].value}));for(var n=0;n<t.length;n++)r.appendChild(this.addNode(t[n][0],t[n][1]));return this.el=r,this}},{key:"set",value:function(t){return this.options=t,t.items&&this.setup(t.items,t.name),t.arrayPadding&&this.arrayPadding(t.arrayPadding.sides,t.arrayPadding.value),t.arrayMargin&&this.arrayMargin(t.arrayMargin.sides,t.arrayMargin.value),t.pad&&this.pad(t.pad),t.mar&&this.mar(t.mar),t.radius&&(this.el.style.borderRadius=t.radius),t.background&&(this.el.style.background=t.background),this}},{key:"arrayPadding",value:function(t,e){return t.includes("left")&&(this.el.style.paddingLeft=e),t.includes("right")&&(this.el.style.paddingRight=e),t.includes("top")&&(this.el.style.paddingTop=e),t.includes("bottom")&&(this.el.style.paddingBottom=e),t.includes("all")&&(this.el.style.padding=e),this}},{key:"arrayMargin",value:function(t,e){return t.includes("left")&&(this.el.style.marginLeft=e),t.includes("right")&&(this.el.style.marginRight=e),t.includes("top")&&(this.el.style.marginTop=e),t.includes("bottom")&&(this.el.style.marginBottom=e),t.includes("all")&&(this.el.style.margin=e),this}},{key:"addNode",value:function(t,e){var r=document.createElement("option");r.setAttribute("value",t);var n=document.createTextNode(e);return r.appendChild(n),r}},{key:"padding",value:function(t){return this.el.style.padding=t,this}},{key:"font",value:function(t){return this.el.style.fontFamily=t,this}},{key:"margin",value:function(t){return this.el.style.margin=t,this}},{key:"toCode",value:function(){var t=JSON.stringify(this.options,null,4);return t=t.replace(/"(\w+)"(?=\s*:)/g,"$1"),["new Picker().set(".concat(t,")")]}},{key:"rounded",value:function(t){return this.el.style.borderRadius="4px",this}},{key:"auto",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?t.el.style.fontSize="3rem":t.el.style.fontSize="1rem"};return e(),window.addEventListener("resize",e),this}},{key:"render",value:function(t){if(!t)return this.el;document.querySelector(t).appendChild(this.el)}}],n&&le(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function ye(t){return ye="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ye(t)}function pe(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,me(n.key),n)}}function me(t){var e=function(t){if("object"!=ye(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=ye(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==ye(e)?e:e+""}function ve(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(ve=function(){return!!t})()}function be(t){return be=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},be(t)}function ge(t,e){return ge=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},ge(t,e)}window.Picker=fe;var we=function(t){function e(){var t;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(t=function(t,e,r){return e=be(e),function(t,e){if(e&&("object"==ye(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,ve()?Reflect.construct(e,r||[],be(t).constructor):e.apply(t,r))}(this,e)).el=null,t.file=null,t}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&ge(t,e)}(e,t),r=e,(n=[{key:"set",value:function(t){var e=this;this.options=t,this.okayColor=t.okayColor,window.matchMedia("(max-device-width: 415px)");var r=document.createElement("div");r.style.paddingBottom="1em",r.style.display="flex",document.createElement("div");var n=document.createElement("input");n.setAttribute("type","text"),n.style.display="none",n.style.margin="0.5em";var i=document.createElement("input");i.setAttribute("type","file"),i.setAttribute("name",t.name),t.accept&&(i.accept=t.accept),i.setAttribute("id",t.id),i.style.visibility="hidden",i.style.display="none",window.matchMedia("(max-device-width: 415px)").matches&&(i.style.fontSize="1rem");var o=document.createElement("label");return o.setAttribute("for",t.id),o.innerText=t.title,o.style.marginRight=12,o.style.padding="0.5em",t.color&&(o.style.color=t.color),t.background&&(o.style.background=t.background,o.style.padding="10"),i.addEventListener("change",(function(){n.style.display="block",t.hideField&&(n.style.display="none"),o.innerText="Change",e.file=i.files[0],e.onLoad(e.file),ke[t.index]=e.file,n.setAttribute("value",e.file.name),n.setAttribute("readonly","true"),e.getLoaded(),e.highlight()})),r.appendChild(i),r.appendChild(o),r.appendChild(n),this.el=r,t.font&&this.font(t.font),t.radius&&this.borderRadius(t.radius),this}},{key:"borderRadius",value:function(t){return this.el.style.borderRadius=t,this}},{key:"addClass",value:function(t){return this.el.setAttribute("class",t),this}},{key:"font",value:function(t){return this.el.style.fontFamily=t,this}},{key:"bold",value:function(){return this.el.style.fontWeight="bold",this}},{key:"rounded",value:function(){return this.el.children[1].style.borderRadius="8px",this}},{key:"highlight",value:function(){return null===this.file?(this.hasFile=!1,this.el.children[1].style.background="red"):(this.hasFile=!0,this.okayColor?this.el.children[1].style.background=this.okayColor:this.el.children[1].style.background="#1abc9c"),this}},{key:"auto",value:function(){var t=function(){window.matchMedia("(max-device-width: 415px)").matches};return t(),window.addEventListener("resize",t),this}},{key:"onLoad",value:function(t){return this.returnObject(this.file),this}},{key:"getLoaded",value:function(){return this.file}},{key:"returnObject",value:function(t){return t}},{key:"loadCall",value:function(t){return this.func=t,this.func(this.file),this}},{key:"toCode",value:function(){var t=JSON.stringify(this.options,null,4);return t=t.replace(/"(\w+)"(?=\s*:)/g,"$1"),["new FilePickera().set(".concat(t,")")]}},{key:"render",value:function(t){return t?(document.querySelector(t).appendChild(this.el),this):this.el}}])&&pe(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u),ke=[];function xe(t,e){return xe=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},xe(t,e)}function Se(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(Se=function(){return!!t})()}function Oe(t){return Oe="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Oe(t)}function Ce(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,je(n.key),n)}}function je(t){var e=function(t){if("object"!=Oe(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Oe(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Oe(e)?e:e+""}var Ee=function(){return t=function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.res=null,this.currentItem=""},(e=[{key:"set",value:function(t){var e=this,r=t;this.options=t;var n=document.createElement("input");n.setAttribute("list","dlCities"),n.setAttribute("id","my");var i=t.data,o=0,s=i.length,a=document.createElement("datalist");for(a.id="dlCities",o=0;o<s;o+=1){var l=document.createElement("option");l.value=i[o],a.appendChild(l)}return n.appendChild(a),n.addEventListener("change",(function(){var t=document.querySelector("#my").value;console.log(t),e.currentItem=t})),n.setAttribute("placeholder","Type value"),n.style.padding=".4rem .75rem",n.style.fontSize="1rem",this.res=n,this.responsive(),r.arrayPadding&&this.arrayPadding(r.arrayPadding.sides,r.arrayPadding.value),r.arrayMargin&&this.arrayMargin(r.arrayMargin.sides,r.arrayMargin.value),r.pad&&this.pad(r.pad),r.mar&&this.mar(r.mar),this}},{key:"toCode",value:function(){var t=JSON.stringify(this.options,null,4);return["new DataList().set(".concat(t,")")]}},{key:"getValue",value:function(){return this.res.value}},{key:"arrayPadding",value:function(t,e){return console.log(t),t.includes("left")&&(this.res.style.paddingLeft=e),t.includes("right")&&(this.res.style.paddingRight=e),t.includes("top")&&(this.res.style.paddingTop=e),t.includes("bottom")&&(this.res.style.paddingBottom=e),t.includes("all")&&(this.res.style.padding=e),this}},{key:"arrayMargin",value:function(t,e){return console.log(t),t.includes("left")&&(this.res.style.marginLeft=e),t.includes("right")&&(this.res.style.marginRight=e),t.includes("top")&&(this.res.style.marginTop=e),t.includes("bottom")&&(this.res.style.marginBottom=e),t.includes("all")&&(this.res.style.margin=e),this}},{key:"margin",value:function(t){return this.res.style.margin=t,this}},{key:"responsive",value:function(){return window.matchMedia("(max-device-width: 415px)").matches&&(this.res.style.width="100%"),this}},{key:"render",value:function(t){if(!t)return this.res;document.querySelector(t).appendChild(this.res)}}])&&Ce(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}(),Te=Ee;function Pe(t){return Pe="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Pe(t)}function Ae(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function Re(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Le(n.key),n)}}function Le(t){var e=function(t){if("object"!=Pe(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Pe(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Pe(e)?e:e+""}Ee=function(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];return function(t,e,r){if(Se())return Reflect.construct.apply(null,arguments);var n=[null];n.push.apply(n,e);var i=new(t.bind.apply(t,n));return r&&xe(i,r.prototype),i}(Te,e)},window.DataList=Ee;var ze=function(){return t=function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"POST";!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.action=e,this.method=r,this.elements=[],this.formElement=document.createElement("form"),this.formElement.action=this.action,this.formElement.method=this.method},e=[{key:"add",value:function(t){var e=this;return this.elements=t,console.log("CODEA"),console.log(this.elements),console.log(this.elements.length),t.forEach((function(t){if(!t||"function"!=typeof t.render)throw new Error("Each element in the array must have a render method that returns an HTML DOM element.");e.formElement.appendChild(t.render())})),console.log(this.elements),this}},{key:"toCode",value:function(){var t=this.elements.map((function(t){return t.toCode()})),e=Object.entries(this.obj).map((function(t){var e=function(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==e);l=!0);}catch(t){c=!0,i=t}finally{try{if(!l&&null!=r.return&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}(t,e)||function(t,e){if(t){if("string"==typeof t)return Ae(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Ae(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(t,2),r=e[0],n=e[1],i="string"==typeof n?'"'.concat(n,'"'):n;return"".concat(r,": ").concat(i)})).join(", ");return console.log("FORM DQ"),console.log(t),["new Form().set({".concat(e,"}).add([ \n ").concat(t.join(", \n"),"])")]}},{key:"set",value:function(t){return this.obj=t,t.action&&this.setAction(t.action),t.method&&this.setMethod(t.method),this}},{key:"setAction",value:function(t){this.action=t,this.formElement.action=this.action}},{key:"setMethod",value:function(t){this.method=t,this.formElement.method=this.method}},{key:"render",value:function(t){return t&&document.querySelector(t).appendChild(this.formElement),this.formElement}}],e&&Re(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function Me(t){return Me="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Me(t)}function Ie(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Be(n.key),n)}}function Be(t){var e=function(t){if("object"!=Me(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Me(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Me(e)?e:e+""}function Ne(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(Ne=function(){return!!t})()}function We(t){return We=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},We(t)}function _e(t,e){return _e=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},_e(t,e)}var Fe=function(t){function e(t,r){var n;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(n=function(t,e,r){return e=We(e),function(t,e){if(e&&("object"==Me(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,Ne()?Reflect.construct(e,r||[],We(t).constructor):e.apply(t,r))}(this,e)).text=t,n.res=null,n.val=r,n.setup(),n}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&_e(t,e)}(e,t),r=e,n=[{key:"setup",value:function(t){return this}},{key:"hover",value:function(t){var e=this;return this.prevColor=this.res.style.backgroundColor,this.foreColor=this.res.style.color,t.animation&&(this.res.style.transition="".concat(t.animation,"s ease-in-out"),this.res.style.transionProperty="background, color"),this.res.onmouseout=function(){e.res.style.backgroundColor="".concat(e.prevColor),e.res.style.color="".concat(e.foreColor)},this.res.onmouseover=function(){e.res.style.backgroundColor=t.background,e.res.style.color=t.color},this}},{key:"set",value:function(t){this.options=t;var e=document.createElement("button");if(e.style.background="transparent",t.url){var r=document.createElement("img");r.setAttribute("src",t.url),r.style.width=t.frame.width,r.style.height=t.frame.height,e.appendChild(r)}else{var n=document.createTextNode(this.text.replace("$",this.val));e.appendChild(n)}return this.res=e,t&&"submit"===t.type&&e.setAttribute("type",t.type),this.border("none"),this.res.style.display="block",t.background&&this.background(t.background),t.padding&&this.padding(t.padding),t.margin&&this.margin(t.margin),t.mar&&this.mar(t.mar),t.pad&&this.pad(t.pad),t.centered&&(this.res.style.marginRight="auto",this.res.style.marginLeft="auto",this.res.style.backgroundColor="black"),t.border&&this.border(t.border),t.radius&&this.borderRadius(t.radius),t.class&&this.setClass(t.class),t.color&&this.color(t.color),t.auto&&this.auto(),t.weight&&(this.res.style.fontWeight=t.weight),t.fluidc&&this.fluidButtonCopy(t.fluidc),t.fluidc&&'\n fluidc: "'.concat(t.fluidc,'",'),t.onTap&&this.onTap(t.onTap),t.frame&&this.frame(t.frame),t.frame&&'\n frame: "'.concat(t.frame,'",'),t.arrpad&&this.arrayPadding(t.arrpad.sides,t.arrpad.value),t.arrpad&&'\n arrpad: {sides: ["'.concat(t.arrpad.sides,'"], value: "').concat(t.arrpad.value,'"},'),t.arrayMargin&&this.arrayMargin(t.arrayMargin.sides,t.arrayMargin.value),t.arrayMargin&&'\n arrayMargin: {sides: ["'.concat(t.arrayMargin.sides,'"], value: "').concat(t.arrayMargin.value,'"},'),t.keySet&&this.keySet(t.keySet),this}},{key:"arrayPadding",value:function(t,e){return t.includes("left")&&(this.res.style.paddingLeft=e),t.includes("right")&&(this.res.style.paddingRight=e),t.includes("top")&&(this.res.style.paddingTop=e),t.includes("bottom")&&(this.res.style.paddingBottom=e),t.includes("all")&&(this.res.style.padding=e),e||(this.res.style.paddingBottom=t),this}},{key:"arrayMargin",value:function(t,e){return e||(this.res.style.marginLeft="".concat(t[0],"px"),this.res.style.marginTop="".concat(t[1],"px"),this.res.style.marginRight="".concat(t[2],"px"),this.res.style.marginBottom="".concat(t[3],"px")),t.includes("left")&&(this.res.style.marginLeft=e),t.includes("right")&&(this.res.style.marginRight=e),t.includes("top")&&(this.res.style.marginTop=e),t.includes("bottom")&&(this.res.style.marginBottom=e),t.includes("all")&&(this.res.style.margin=e),e||(this.res.style.marginBottom=t),this}},{key:"fluidButtonCopy",value:function(t){if(t instanceof Object){this.prevStylex=this.res.style,this.res=document.createElement("button"),this.res.style.cssText=this.prevStylex.cssText;var e=document.createTextNode(this.text);return this.res.appendChild(e),this.res.style.fontSize=t.exact,this}if("S1"===t){this.prevStylex=this.res.style,this.res=document.createElement("button"),this.res.style.cssText=this.prevStylex.cssText;var r=document.createTextNode(this.text);this.res.appendChild(r),this.res.style.fontSize="calc(1.625rem + 5.075vw)"}if("S2"===t){this.prevStylex=this.res.style,this.res=document.createElement("button"),this.res.style.cssText=this.prevStylex.cssText;var n=document.createTextNode(this.text);this.res.appendChild(n),this.res.style.fontSize="calc(1.500rem + 4.3vw)"}if("S3"===t){this.prevStylex=this.res.style,this.res=document.createElement("button"),this.res.style.cssText=this.prevStylex.cssText;var i=document.createTextNode(this.text);this.res.appendChild(i),this.res.style.fontSize="calc(1.375rem + 3.525vw)"}if("S4"===t){this.prevStylex=this.res.style,this.res=document.createElement("button"),this.res.style.cssText=this.prevStylex.cssText;var o=document.createTextNode(this.text);this.res.appendChild(o),this.res.style.fontSize="calc(1.250rem + 2.75vw)"}if("S5"===t){this.prevStylex=this.res.style,this.res=document.createElement("button"),this.res.style.cssText=this.prevStylex.cssText;var s=document.createTextNode(this.text);this.res.appendChild(s),this.res.style.fontSize="calc(1.125rem + 1.975vw)"}return"S6"===t&&(this.res.style.fontSize="calc(1rem + 0.5vw)"),this}},{key:"setClass",value:function(t){return this.res.setAttribute("class",t),this}},{key:"color",value:function(t){return this.res.style.color=t,this}},{key:"background",value:function(t){return this.res.style.background=t,this}},{key:"width",value:function(t){return this.res.style.width=t,this}},{key:"borderRadius",value:function(t){return this.res.style.borderRadius=t,this}},{key:"padding",value:function(t,e,r,n){return t&&e&&r&&n?(this.res.style.paddingLeft=t,this.res.style.paddingTop=e,this.res.style.paddingRight=r,this.res.style.paddingBottom=n):this.res.style.padding=t,this}},{key:"margin",value:function(t,e,r,n){return t&&e&&r&&n?(this.res.style.marginLeft=t,this.res.style.marginTop=e,this.res.style.marginRight=r,this.res.style.marginBottom=n):this.res.style.margin=t,this}},{key:"auto",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?t.res.style.fontSize="2.2rem":t.res.style.fontSize="1rem"};return e(),window.addEventListener("resize",e),this}},{key:"large",value:function(){var t=this,e=function(){window.matchMedia("(max-device-width: 415px)").matches?(alert("WOW"),t.res.style.fontSize="6rem"):t.res.style.fontSize="3rem"};return e(),window.addEventListener("resize",e),this}},{key:"border",value:function(t,e){return"none"===t&&(this.res.style.border="none"),this.res.style.border="".concat(t," solid ").concat(e,"px"),this}},{key:"frame",value:function(t){return this.res.style.width=t.width,this.res.style.height=t.height,this}},{key:"updating",value:function(t,e){var r=this.res,n=this.text;return Object.defineProperty(t,e,{set:function(t){var e=document.createTextNode(n.replace("$",t));r.replaceChild(e,r.childNodes[0])}}),this}},{key:"onTap",value:function(t){return this.res.addEventListener("click",t),this}},{key:"toCode",value:function(){var t=JSON.stringify(this.options,(function(t,e){return"function"==typeof e?e.toString():e}),4).replace(/"(\w+)":/g,"$1:").replace(/"(\(\)\s*=>\s*{[^}]*})"/g,"$1").replace(/\\n/g,"").replace(/\\"/g,'"');return['new Button("'.concat(this.text,'").set(').concat(t,")")]}},{key:"render",value:function(t){if(!t)return this.res;document.querySelector(t).appendChild(this.res)}}],n&&Ie(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function De(t){return De="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},De(t)}function He(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Je(n.key),n)}}function Je(t){var e=function(t){if("object"!=De(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=De(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==De(e)?e:e+""}var qe=function(){return t=function t(e,r){if(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.container=document.createElement("div"),this.elements=e,this.currentSlideIndex=0,this.buttons=r,!this.buttons){var n={leftButton:new Fe("L").set({url:"https://static-00.iconduck.com/assets.00/circle-arrow-left-icon-512x512-xp8okg5c.png",color:"#1abc9c",frame:{width:50,height:50},radius:"100%",arrayMargin:{sides:["all"],value:"1rem"}}),rightButton:new Fe("R").set({url:"https://static-00.iconduck.com/assets.00/arrow-right-circle-icon-2048x2048-m0qcnetg.png",color:"#1abc9c",frame:{width:50,height:50},radius:"100%",arrayMargin:{sides:["all"],value:"1rem"}})};this.buttons=n}this.createSlider(),this.init()},e=[{key:"toCode",value:function(){var t="new Slider([".concat(this.elements.map((function(t){return t.toCode()})),"], null)");return[t=t.replace(/,\s*\./g,".")]}},{key:"createSlider",value:function(){this.slider=document.createElement("div"),this.slider.style.width="100%",this.slider.style.height="400px",this.slider.style.margin="20px auto",this.slider.style.textAlign="center",this.slider.style.borderRadius="20px",this.slider.style.overflow="hidden",this.slider.style.position="relative";var t=document.createElement("div");this.slidesWrapper=t,t.style.display="flex",t.style.overflowX="scroll",t.style.scrollBehavior="smooth",t.style.scrollSnapType="x mandatory",this.elements.forEach((function(e,r){var n=document.createElement("div");n.setAttribute("class","slide"),n.style.display="flex",n.style.justifyContent="center",n.style.alignItems="center",n.style.flexShrink="0",n.style.width="100%",n.style.height="400px",n.style.background=r%2==0?"rgb(250, 246, 212)":"white",n.style.transformOrigin="center center",n.style.transform="scale(1)",n.style.scrollSnapAlign="center",n.appendChild(e.render()),t.appendChild(n)})),this.arrowPrev=this.buttons.leftButton.render(),this.arrowPrev.style.position="absolute",this.arrowPrev.style.left="10px",this.arrowPrev.style.top="50%",this.arrowPrev.style.transform="translateY(-50%)",this.arrowPrev.style.zIndex="1",this.arrowNext=this.buttons.rightButton.render(),this.arrowNext.style.position="absolute",this.arrowNext.style.right="10px",this.arrowNext.style.top="50%",this.arrowNext.style.transform="translateY(-50%)",this.arrowNext.style.zIndex="1";var e=document.createElement("div");e.style.position="absolute",e.style.bottom="10%",e.style.left="50%",e.style.width="200px",e.style.transform="translateX(-50%)",e.style.textAlign="center",this.elements.forEach((function(t,r){var n=document.createElement("a");n.style.display="inline-block",n.style.height="15px",n.style.width="15px",n.style.borderRadius="50%",n.style.backgroundColor="black",n.style.margin="0 10px",n.style.cursor="pointer",n.dataset.index=r,e.appendChild(n)})),this.slider.appendChild(this.arrowPrev),this.slider.appendChild(this.arrowNext),this.slider.appendChild(t),this.slider.appendChild(e),this.container.appendChild(this.slider),this.slidesWrapper=t,this.navLinks=e.querySelectorAll("a")}},{key:"init",value:function(){this.updateActiveSlide(),this.attachEventListeners()}},{key:"attachEventListeners",value:function(){var t=this;this.arrowPrev.addEventListener("click",(function(){t.moveToSlide(t.currentSlideIndex-1<0?t.elements.length-1:t.currentSlideIndex-1)})),this.arrowNext.addEventListener("click",(function(){t.moveToSlide((t.currentSlideIndex+1)%t.elements.length)})),this.navLinks.forEach((function(e){e.addEventListener("click",(function(r){r.preventDefault();var n=parseInt(e.dataset.index,10);t.moveToSlide(n)}))})),document.addEventListener("keydown",(function(e){"ArrowLeft"===e.key?t.moveToSlide(t.currentSlideIndex-1<0?t.elements.length-1:t.currentSlideIndex-1):"ArrowRight"===e.key&&t.moveToSlide((t.currentSlideIndex+1)%t.elements.length)}))}},{key:"moveToSlide",value:function(t){this.currentSlideIndex=t,this.updateActiveSlide()}},{key:"updateActiveSlide",value:function(){var t=this;this.navLinks.forEach((function(e,r){e.style.backgroundColor=r===t.currentSlideIndex?"green":"gray"}));var e=this.slidesWrapper.querySelector(".slide").offsetWidth;this.slidesWrapper.scrollTo({left:this.currentSlideIndex*e,behavior:"smooth"})}},{key:"render",value:function(t){if(!t)return this.slider;document.querySelector(t).appendChild(this.slider)}}],e&&He(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function Ge(t){return Ge="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ge(t)}function Qe(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Xe(n.key),n)}}function Xe(t){var e=function(t){if("object"!=Ge(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Ge(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Ge(e)?e:e+""}function $e(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return($e=function(){return!!t})()}function Ye(t){return Ye=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},Ye(t)}function Ve(t,e){return Ve=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},Ve(t,e)}var Ue=function(t){function e(t){var r;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(r=function(t,e,r){return e=Ye(e),function(t,e){if(e&&("object"==Ge(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,$e()?Reflect.construct(e,r||[],Ye(t).constructor):e.apply(t,r))}(this,e)).url=t,r.res=null,r.setup(),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Ve(t,e)}(e,t),r=e,(n=[{key:"setup",value:function(){this.res=document.createElement("audio"),this.res.setAttribute("src",this.url),this.res.setAttribute("controls","controls")}},{key:"set",value:function(t){return this.options=t,t.background&&this.background(t.background),this}},{key:"background",value:function(t){var e=document.createElement("style");return e.type="text/css",e.textContent="\n\taudio::-webkit-media-controls-panel {\n\t\tbackground-color: ".concat(t,";\n\t}\n"),document.head.appendChild(e),this}},{key:"toCode",value:function(){return JSON.stringify(this.options,null,4),['new Audio("'.concat(this.url,'")')]}},{key:"size",value:function(t){return this.res.style.width=t,this}},{key:"render",value:function(t){if(!t)return this.res;document.querySelector(t).appendChild(this.res)}}])&&Qe(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function Ke(t){return Ke="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ke(t)}function Ze(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,tr(n.key),n)}}function tr(t){var e=function(t){if("object"!=Ke(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Ke(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Ke(e)?e:e+""}function er(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(er=function(){return!!t})()}function rr(t){return rr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},rr(t)}function nr(t,e){return nr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},nr(t,e)}var ir=function(t){function e(t){var r;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(r=function(t,e,r){return e=rr(e),function(t,e){if(e&&("object"==Ke(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,er()?Reflect.construct(e,r||[],rr(t).constructor):e.apply(t,r))}(this,e)).url=t,r.res=null,r.setup(),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&nr(t,e)}(e,t),r=e,(n=[{key:"setup",value:function(){this.res=document.createElement("video"),this.res.setAttribute("src",this.url),this.res.setAttribute("controls","controls")}},{key:"set",value:function(t){return this.options=t,t.radius&&(this.res.style.borderRadius="1rem"),t.width&&(this.res.style.width="".concat(t.width)),t.opacity&&(this.res.style.opacity=t.opacity),this}},{key:"size",value:function(t){return this.res.style.width=t,this}},{key:"toCode",value:function(){var t=JSON.stringify(this.options,null,4);return['new Video("'.concat(this.url,'").set(').concat(t,")")]}},{key:"render",value:function(t){if(!t)return this.res;document.querySelector(t).appendChild(this.res)}}])&&Ze(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function or(t){return or="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},or(t)}function sr(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function ar(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,lr(n.key),n)}}function lr(t){var e=function(t){if("object"!=or(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=or(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==or(e)?e:e+""}function cr(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(cr=function(){return!!t})()}function ur(t){return ur=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},ur(t)}function dr(t,e){return dr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},dr(t,e)}var hr=function(t){function e(){var t;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(t=function(t,e,r){return e=ur(e),function(t,e){if(e&&("object"==or(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,cr()?Reflect.construct(e,r||[],ur(t).constructor):e.apply(t,r))}(this,e)).res=document.createElement("div"),t.res.style.display="grid",t.attributes={},t}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&dr(t,e)}(e,t),r=e,n=[{key:"set",value:function(t){return this.options=t,this.attributes=t,this.templateCols=t.templateCols,t.templateCols&&(this.res.style.gridTemplateColumns="repeat(".concat(t.templateCols.cols,", 1fr)"),this.res.style.gridTemplateRows="repeat(".concat(t.templateCols.cols,", 1fr)")),this.res.style.height=t.height?t.height:"600px",t.positions&&(this.storedPositions=t.positions),this}},{key:"generateGridPositions",value:function(t){var e=this,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:30,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:50,i=document.createElement("div");i.classList.add("container"),i.style.display="grid",i.style.gridTemplateColumns="repeat(".concat(n,", 1fr)"),i.style.gridTemplateRows="repeat(".concat(r,", 1fr)"),i.style.width="100%",i.style.height="100vh";var o=t.map((function(t,e){return{row:Math.floor(r/2)+e,col:Math.floor(n/2)+e}}));return t.forEach((function(i,s){var a=o[s],l=a.row,c=a.col,u=function(e){var r=0,n=0;return t.forEach((function(t,i){var s=t.weight,a=t.direction,l=o[e],c=o[i],u=l.col-c.col,d=l.row-c.row,h=s*(1/(Math.sqrt(u*u+d*d)+1));switch(a){case"L":r-=h;break;case"R":r+=h;break;case"U":n-=h;break;case"B":n+=h}})),{forceX:r,forceY:n}}(s),d=u.forceX,h=u.forceY;c=Math.max(1,Math.min(n,c+Math.round(d))),l=Math.max(1,Math.min(r,l+Math.round(h))),console.log(e.items.map((function(t){return t.id}))),console.log(i.attract.slice(1));var f=e.items.filter((function(t){return t.id===i.attract.slice(1)}))[0].render();console.log(f),f.style.gridRowStart=l,f.style.gridRowEnd=l+3,f.style.gridColumnStart=c,f.style.gridColumnEnd=c+5,f.style.border="3px solid #".concat(Math.floor(16777215*Math.random()).toString(16).padStart(6,"0")),f.style.display="flex",f.style.alignItems="center",f.style.justifyContent="center",f.style.fontWeight="bold",f.style.color="white",e.res.appendChild(f)})),console.log("ARAO"),console.log(this.res.children.length),this}},{key:"add",value:function(t){this.items=t;var e,r=function(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=function(t,e){if(t){if("string"==typeof t)return sr(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?sr(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,i=function(){};return{s:i,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,s=!0,a=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return s=t.done,t},e:function(t){a=!0,o=t},f:function(){try{s||null==r.return||r.return()}finally{if(a)throw o}}}}(t);try{for(r.s();!(e=r.n()).done;){var n=e.value;this.res.appendChild(n.render())}}catch(t){r.e(t)}finally{r.f()}return this.storedPositions&&this.generateGridPositions(this.storedPositions),console.log("MORAA"),console.log(this.res.children.length),this}},{key:"toCode",value:function(){if(this.excludeFromCodeTrue)return[""];var t=JSON.stringify(this.options,null,4).replace(/"([^"]+)":/g,"$1:"),e="";return e+=".add([\n",e+=this.items.map((function(t){return t.toCode().join("").trim()})).join(",\n"),e+="\n])",["new Free().set(".concat(t,")").concat(e)]}},{key:"render",value:function(t){if(console.log("CHILDREN IN RENDER"),console.log(this.res.children.length),!t)return this.res;document.querySelector(t).appendChild(this.res)}}],n&&ar(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function fr(t){return fr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},fr(t)}function yr(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function pr(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,mr(n.key),n)}}function mr(t){var e=function(t){if("object"!=fr(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=fr(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==fr(e)?e:e+""}function vr(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(t){}return(vr=function(){return!!t})()}function br(t){return br=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},br(t)}function gr(t,e){return gr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},gr(t,e)}var wr=function(t){function e(){var t;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(t=function(t,e,r){return e=br(e),function(t,e){if(e&&("object"==fr(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(t,vr()?Reflect.construct(e,r||[],br(t).constructor):e.apply(t,r))}(this,e)).el=null,t}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&gr(t,e)}(e,t),r=e,(n=[{key:"set",value:function(t){var e,r;this.options=t;var n=document.createElement("div");n.style.display="flex",n.style.alignItems="center";var i=document.createElement("input");i.type="checkbox",i.style.position="relative",i.style.marginRight="0.5rem";var o=t.size||"24px";i.style.width=o,i.style.height=o,t.customStyle&&(i.style.appearance="none"),i.style.border="2px solid #ccc",i.style.borderRadius="4px",i.style.backgroundColor=t.backgroundColor||"white",i.style.cursor="pointer",i.style.transition="background-color 0.2s ease, border-color 0.2s ease",i.style.display="inline-block",i.style.setProperty("--checked-bg-color",t.checkedBackgroundColor||"#4CAF50"),i.style.setProperty("--checkmark-color","white"),i.style.setProperty("--checkmark-clip-path",null!==(e=this.options.clipPath)&&void 0!==e?e:"polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%)");var s=document.createElement("style");s.textContent='\n input[type="checkbox"] {\n appearance: none;\n -webkit-appearance: none; /* For Safari */\n width: var(--size, 24px);\n height: var(--size, 24px);\n border: 2px solid #ccc;\n border-radius: 4px;\n background-color: white;\n position: relative;\n cursor: pointer;\n transition: background-color 0.2s ease, border-color 0.2s ease;\n }\n\n input[type="checkbox"]:checked {\n background-color: var(--checked-bg-color, #4CAF50);\n border-color: var(--checked-bg-color, #4CAF50);\n }\n\n input[type="checkbox"]::after {\n content: \'\';\n position: absolute;\n width: 50%;\n height: 50%;\n top: 25%;\n left: 25%;\n transform: scale(0);\n background-color: var(--checkmark-color, white);\n clip-path: var(--checkmark-clip-path);\n -webkit-clip-path: var(--checkmark-clip-path);\n transition: transform 0.2s ease;\n }\n\n input[type="checkbox"]:checked::after {\n transform: scale(1);\n }\n',t.customStyle&&document.head.appendChild(s),t.mar&&this.mar(t.mar),t.pad&&this.pad(t.pad),t.respad&&this.respad(t.respad),t.resmar&&this.resmar(t.resmar),i.addEventListener("change",(function(){i.checked?(i.style.backgroundColor=t.checkedBackgroundColor||"#4CAF50",i.style.borderColor=t.checkedBackgroundColor||"#4CAF50"):(i.style.backgroundColor=t.backgroundColor||"white",i.style.borderColor="#ccc")})),t.name&&i.setAttribute("name",t.name),n.appendChild(i);var a=document.createElement("div");if("function"==typeof(null===(r=t.label)||void 0===r?void 0:r.render))a.appendChild(t.label.render());else{var l=document.createTextNode(t.title||"Label");a.appendChild(l)}return a.style.opacity=.8,a.style.transition="opacity ease 0.2s, transform ease 0.2s",n.appendChild(a),this.el=n,this}},{key:"getValue",value:function(){return this.el.children[0].checked}},{key:"toCode",value:function(){var t=Object.entries(this.options).map((function(t){var e=function(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,i,o,s,a=[],l=!0,c=!1;try{if(o=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=o.call(r)).done)&&(a.push(n.value),a.length!==e);l=!0);}catch(t){c=!0,i=t}finally{try{if(!l&&null!=r.return&&(s=r.return(),Object(s)!==s))return}finally{if(c)throw i}}return a}}(t,e)||function(t,e){if(t){if("string"==typeof t)return yr(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?yr(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(t,2),r=e[0],n=e[1];return"string"==typeof n?"".concat(r,': "').concat(n,'"'):"object"===fr(n)&&null!==n?"function"==typeof n.toCode?"".concat(r,": ").concat(n.toCode()[0]):"".concat(r,": ").concat(JSON.stringify(n,null,4)):"".concat(r,": ").concat(n)})).join(",\n ");return["new Checkbox().set({\n ".concat(t,"\n})")]}},{key:"margin",value:function(t){return this.el.style.margin=t,this}},{key:"render",value:function(t){if(!t)return this.el;document.querySelector(t).appendChild(this.el)}}])&&pr(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(u);function kr(t){return kr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},kr(t)}function xr(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Sr(n.key),n)}}function Sr(t){var e=function(t){if("object"!=kr(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=kr(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==kr(e)?e:e+""}window.Checkbox=wr;var Or=function(){return t=function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.res=null,this.st=e},(e=[{key:"setup",value:function(){var t=document.createElement("div");return t.style.display="grid",this.res=t,this.st&&this.sticky(),this}},{key:"set",value:function(t){return this.setup(),t.height&&(this.res.style.height=t.height),t.sticky&&this.sticky(),this}},{key:"sticky",value:function(){return this.res.style.position="sticky",this.res.style.top=0,this}},{key:"add",value:function(t){this.children=t;for(var e=0;e<t.length;e++){var r=t[e].render();r.style.gridColumn=1,r.style.gridRow=1,this.res.appendChild(r)}return this}},{key:"toCode",value:function(){var t="new Stack().set({})";if(this.children.length>0){var e=this.children.map((function(t){return t.toCode()})).join(",\n");t+=".add([\n \n ".concat(e," \n \n])")}return[t]}},{key:"render",value:function(t){if(!t)return this.res;document.querySelector("body").style.margin=0,document.querySelector("body").style.padding=0,document.querySelector(t).appendChild(this.res)}}])&&xr(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function Cr(t){return Cr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Cr(t)}function jr(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Er(n.key),n)}}function Er(t){var e=function(t){if("object"!=Cr(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Cr(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Cr(e)?e:e+""}var Tr=function(){return t=function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t)},e=[{key:"style",value:function(t){for(var e=t.bst,r=t.el,n=t.re,i=(t.options,[]),o=0;o<e.length;o++)e[o].target&&(r.id,e[o].target[0]);for(o=0;o<e.length;o++){var s=!0;e[o].target&&(s=!1,r.id===e[o].target[0]&&(s=!0)),console.log("OMESTE"),console.log(e[o]);var a=e[o].op.ops.split("-");s&&a.includes("air")&&(n.borderObj={color:"#1abc9c",radius:"0rem",width:"3px"},n.color="#1abc9c",n.background="transparent"),s&&a.includes("round")&&(a.includes("air")?n.borderObj={width:"4px",radius:"0.7rem",color:"#1abc9c"}:n.borderObj={width:"0px",radius:"0.7rem",color:"#1abc9c"}),s&&a.includes("full")&&(n.background="#3498db",n.borderObj&&n.borderObj.radius?n.borderObj.radius="0.3rem":n.color="white"),s&&a.includes("pill")&&(n.background="#3498db",n.borderObj.radius="9999px",n.color="white"),s&&a.includes("hover")&&(n.hover={color:"#1abc9c",background:"orange"}),i.push((new D).set(n))}return i}}],null&&jr(t.prototype,null),e&&jr(t,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function Pr(t){return Pr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Pr(t)}function Ar(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Rr(n.key),n)}}function Rr(t){var e=function(t){if("object"!=Pr(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=Pr(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==Pr(e)?e:e+""}var Lr=function(){return t=function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t)},e=[{key:"cards",value:function(t,e,r){console.log("PP"),console.log(r);for(var n=[],i=0;i<t.children.length;i++){var o=t.children[i];"text"===o&&this.insertTextToCard(n,e,t,r),"image"!==o||t.backgroundCard||n.push('\n new Image("https://upload.wikimedia.org/wikipedia/commons/3/3a/Starship_S20.jpg").set({})'),"link"===o&&(e.op?n.push("\n ".concat(r.tabSpace(6)," ").concat(r.link[e.op.theme.toLowerCase()].code)):n.push("\n ".concat(r.tabSpace(6)," ").concat(r.link.base.code)))}return n}},{key:"insertTextToCard",value:function(t,e,r,n){if(e.op)if(e.op.ops&&e.op.ops.includes("text-blast")){var i="\n ".concat(n.tabSpace(6)," ").concat(n.text[e.op.theme.toLowerCase()].code),o=n.ops[e.op.theme.toLowerCase()].blast.code;r.backgroundCard||(o=n.ops[e.op.theme.toLowerCase()].blastFun(1));var s=this.insertTextBetween(i,o);t.push(s)}else t.push("\n ".concat(n.tabSpace(6)," ").concat(n.text[e.op.theme.toLowerCase()].code));else t.push("\n ".concat(n.tabSpace(6)," ").concat(n.text.base.code))}},{key:"insertTextBetween",value:function(t,e){var r=t.match(/(color: ".+?",)(.+?)(id: ".+?")/);if(r){var n=r.index+r[0].length,i=t.slice(0,n)+", "+e+", "+t.slice(n);return console.log("RETA"),console.log(i),i}return t}}],null&&Ar(t.prototype,null),e&&Ar(t,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();function zr(t){return zr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},zr(t)}function Mr(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Ir(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Mr(Object(r),!0).forEach((function(e){Br(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Mr(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function Br(t,e,r){return(e=Wr(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function Nr(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,Wr(n.key),n)}}function Wr(t){var e=function(t){if("object"!=zr(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=zr(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==zr(e)?e:e+""}var _r=function(){return t=function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t)},e=[{key:"mapType",value:function(t){return["h1","h2","h3","h4","h5","h6","p"].includes(t.el.type)?this.mapText(t):"img"===t.el.type?this.mapImage(t):"a"===t.el.type?this.mapLink(t):"cards"===t.el.type?this.mapGrid(t):"free"===t.el.type?this.mapFree(t):"nav"===t.el.type?this.protoNav(t):"sideNav"===t.el.type?this.sideNav(t):"dropdown"===t.el.type?this.dropdown(t):"modal"===t.el.type?this.modal(t):"slider"===t.el.type?this.slider(t):"table"===t.el.type?this.table(t):"radio"===t.el.type?this.radio(t):"input"===t.el.type?this.input(t):"labelInput"===t.el.type?this.floatInput(t):"filePicker"===t.el.type?this.filePicker(t):"picker"===t.el.type?this.picker(t):"video"===t.el.type?this.video(t):"audio"===t.el.type?this.audio(t):"multiswitcher"===t.el.type?this.multiswitcher(t):"button"===t.el.type?this.button(t):"form"===t.el.type?this.form(t):"checkbox"===t.el.type?this.checkbox(t):"stack"===t.el.type?this.stack(t):"simple"===t.el.type?this.simple(t):void 0}},{key:"button",value:function(){return new Fe("Submit").set({fluidc:"S6",color:"white",background:"#1abc9c",arrpad:{sides:["all"],value:".3rem"},radius:".3rem",onTap:function(){alert("Nice")},keySet:{key:"border",value:"3px solid green"}})}},{key:"multiswitcher",value:function(){return(new ft).set({breakpoints:[{at:"0px",view:new x("First").set({})},{at:"700px",view:new x("Nice").set({})},{at:"800px",view:new x("Best").set({})}]})}},{key:"video",value:function(){return new ir("https://www.w3schools.com/html/mov_bbb.mp4").set({})}},{key:"audio",value:function(){return new Ue("rouska.mp3").set({background:"#1abc9c"})}},{key:"radio",value:function(t){return(new se).set({items:["Male","Female","Third shit"],multiple:!0})}},{key:"input",value:function(t){return(new TextField).set({type:"text",placeholder:"Enter swimming time",arrayMargin:{sides:["all"],value:"1rem"}})}},{key:"floatInput",value:function(t){return(new Kt).set({title:"Your name",type:"input"})}},{key:"filePicker",value:function(t){return(new we).set({id:"A",title:"Add profile picture",background:"#3498DB",color:"white",font:"Arial",radius:"3rem",accept:"application/pdf"})}},{key:"picker",value:function(t){return(new fe).set({items:[["none","select a car---"],["tesla","Tesla"],["audi","Audi"]],font:"Arial",arrayPadding:{sides:["all"],value:"0.5rem"},rounded:!0})}},{key:"modal",value:function(t){}},{key:"slider",value:function(t){var e=[(new Lt).set({}).add([new x("One").set({fluidc:"S1",color:"#1abc9c",font:"Arial"}),new x("First time").set({font:"Arial"})]),new x("Two").set({fluidc:"S1",color:"#1abc9c",font:"Arial"}),new x("Three").set({fluidc:"S1",color:"#1abc9c",font:"Arial"}),new x("Four").set({fluidc:"S1",color:"#1abc9c",font:"Arial"})];return new qe(e,null)}},{key:"dropdown",value:function(t){t.el.items||(t.el.items=["Flower","Car","Maseratti"]);var e=t.el.items.map((function(t){return(new D).set({pad:[{a:10}],font:"Arial",bold:!0,link:"https://www.apple.com",text:t,icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/32/32339.png"},hover:{color:"wheat",animation:.3}})}));return(new xt).set({behaviour:"mouseover",pad:[{a:"1rem"}],mar:[{a:"1rem"}],border:"1px solid black",width:"180px",radius:"1rem"}).add([new x(t.el.items[0]).set({font:"Arial",fluidc:"S6",weight:"bold",align:"center",cursor:"hand",icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/60/60995.png"},pad:[{l:10,r:10}]}),(new Lt).set({border:"1px solid green",background:"#1abc9c",radius:"0.7rem",socenter:!0}).add(e.slice(1))])}},{key:"protoNav",value:function(t){t.customOptions;var e=[{title:"Fire",link:"@e"},{title:"and",link:"@e"},{title:"smoke",link:"@e"}],r=e.map((function(t,e){return new D('"'.concat(t.title,'"')).set({fluidc:"S6",text:t.title,link:t.link,font:"Arial",pad:[{a:40}],bold:!0,hover:{color:"wheat",animation:.3}})})),n=e.map((function(t,e){return new D('"'.concat(t.title,'"')).set({fluidc:"S6",text:t.title,link:t.link,font:"Arial",pad:[{a:40}],bold:!0,hover:{color:"wheat",animation:.3},animation:{range:["0px","1900px"],op:{name:"animation",color:"green",width:"1px",keyframesOpen:[{transform:"translate(100%, ".concat(10*e,"%)"),opacity:0},{transform:"translate(0%)",opacity:1}],keyframesClose:[{transform:"translate(0%)",opacity:1},{transform:"translate(100%, ".concat(10*e,"%)"),opacity:0}],openOptions:{duration:300,fill:"forwards",delay:1e3},closeOptions:{duration:1,fill:"forwards",delay:1e3}}}})}));if(t.el.dropdown){var i=(new xt).set({behaviour:"mouseover",pad:[{a:40}],padding:"10px",border:"1px solid black"}).add([new x("First").set({cursor:"hand",icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/60/60995.png"},fluidc:"S6",pad:[{l:20,r:10}],font:"Arial",align:"center",weight:"bold"}),(new Lt).set({socenter:!0,radius:"0.7rem",background:"#1abc9c",makeResponsiveBehaviour:"undefined"}).add([(new D).set({pad:[{a:10}],font:"Arial",hover:{color:"wheat",animation:.3},bold:!0,link:"https://www.apple.com",text:"Second",icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/32/32339.png"}}),(new D).set({pad:[{a:10}],font:"Arial",hover:{color:"wheat",animation:.3},bold:!0,link:"https://www.apple.com",text:"Third",icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/32/32339.png"}})])]);n.push(i),r.push(i)}return t.el.animation,(new ft).set({breakpoints:[{at:"0px",view:(new nt).set({background:"green",mar:[{a:21}],brand:new x("A").set({size:"S1"}),hamburgerColour:"#3498db",radius:"1rem"}).add([new D("A").set({text:"A",url:"#a"}),(new xt).set({behaviour:"mouseover",pad:[{a:40}],mar:[{lr:"auto"}],breakpoint:"1200px",padding:"10px",border:"1px solid black",height:"auto"}).add([new x("First").set({cursor:"hand",icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/60/60995.png"},fluidc:"S6",pad:[{l:10,r:10}],font:"Arial",align:"center",weight:"bold"}),new x("Firsti").set({cursor:"hand",fluidc:"S6",pad:[{l:10,r:10}],font:"Arial",align:"center",weight:"bold"}),new x("Firstiuu").set({cursor:"hand",fluidc:"S6",pad:[{l:10,r:10}],font:"Arial",align:"center",weight:"bold"})]),new D("B").set({text:"B",url:"#b"}),new D("C").set({text:"C",url:"https://www.abcnews.com"})])},{at:"1200px",view:(new Y).set({background:"green",mar:[{a:21}],maxHeight:"100px",radius:"1rem"}).add([new x("A").set({size:"S1"}),new Gt(!0),(new xt).set({behaviour:"mouseover",pad:[{a:40}],padding:"10px",border:"1px solid black",radius:"30px",width:"130px"}).add([new x("First").set({cursor:"hand",icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/60/60995.png"},fluidc:"S6",pad:[{l:10,r:10}],font:"Arial",align:"center",weight:"bold"}),(new Lt).set({flexDir:"column",background:"orange",mar:[{t:"10px"}],radius:".3rem"}).add([new D("").set({text:"A",url:"jk",cursor:"hand",fluidc:"S6",pad:[{l:10,r:10}],font:"Arial",align:"center",weight:"bold"}),new D("").set({text:"Kivi new TV",url:"#u",cursor:"hand",fluidc:"S6",pad:[{l:10,r:10}],font:"Arial",align:"center",weight:"bold"}),new D("").set({text:"Thanks GPT",url:"#u",cursor:"hand",fluidc:"S6",pad:[{l:10,r:10}],font:"Arial",align:"center",weight:"bold"})])]),new D("Desktop bar").set({text:"Desktop bar",url:"#a"}),new D("B").set({text:"B",url:"#a"}),new D("C").set({text:"C",url:"#a"})])}]})}},{key:"sideNav",value:function(t){t.customOptions;var e=[{title:"Home",link:"@e"},{title:"Projects",link:"@e"},{title:"Services",link:"@e"}],r=e.map((function(t,e){return new D('"'.concat(t.title,'"')).set({fluidc:"S4",text:t.title,link:t.link,isNavA:!0,url:"#e",id:"#"+t.title.toLowerCase(),font:"Arial",pad:[{a:20}],bold:!0,align:"left"})})),n=(new xt).set({behaviour:"mouseover",pad:[{a:40}],padding:"10px",border:"1px solid black",animation:{range:["0px","1900px"],op:{name:"animation",color:"green",width:"1px",keyframesOpen:[{transform:"translate(100%, ".concat(10,"%)"),opacity:0},{transform:"translate(0%)",opacity:1}],keyframesClose:[{transform:"translate(0%)",opacity:1},{transform:"translate(100%, ".concat(10,"%)"),opacity:0}],openOptions:{duration:300,fill:"forwards",delay:1e3},closeOptions:{duration:1,fill:"forwards",delay:1e3}}}}).add([new x("First").set({cursor:"hand",icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/60/60995.png"},fluidc:"S6",pad:[{l:10,r:10}],font:"Arial",align:"center",weight:"bold"}),(new Lt).set({socenter:!0,radius:"0.7rem",background:"#1abc9c",makeResponsiveBehaviour:"undefined"}).add([(new D).set({pad:[{a:10}],font:"Arial",hover:{color:"wheat",animation:.3},bold:!0,link:"https://www.apple.com",text:"Second",icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/32/32339.png"}}),(new D).set({pad:[{a:10}],font:"Arial",hover:{color:"wheat",animation:.3},bold:!0,link:"https://www.apple.com",text:"Third",icon:{padding:30,url:"https://cdn-icons-png.flaticon.com/512/32/32339.png"}})])]),i=e.map((function(t,e){return new D('"'.concat(t.title,'"')).set({fluidc:"S4",text:t.title,link:t.link,isNavA:!0,url:"#e",id:"#"+t.title.toLowerCase(),font:"Arial",pad:[{a:20}],bold:!0,align:"left",animation:{range:["0px","1900px"],op:{name:"animation",color:"green",width:"1px",keyframesOpen:[{transform:"translate(100%, ".concat(10*e,"%)"),opacity:0},{transform:"translate(0%)",opacity:1}],keyframesClose:[{transform:"translate(0%)",opacity:1},{transform:"translate(100%, ".concat(10*e,"%)"),opacity:0}],openOptions:{duration:300,fill:"forwards",delay:1e3},closeOptions:{duration:1,fill:"forwards",delay:1e3}}}})}));t.el.dropdown&&(i.push(n),r.push(n));var o=(new Lt).set({column:!0}).add([new x("Ultra Reckoning").set({fluidc:"S6",font:"Arial",id:"#olod",italic:!0,animation:{range:["0px","1900px"],op:{name:"animation",color:"green",width:"1px"}},pad:[{l:40},{t:20}]}),t.el.animation?i[0]:r[0],t.el.animation?i[1]:r[1],t.el.animation?i[2]:r[2],t.el.animation&&t.el.dropdown?i[3]:new x("").set({}).excludeFromCode(),new x("Paramount, 2024").set({pad:[{a:20}],animation:{range:["0px","1900px"],op:{name:"animation",color:"green",width:"1px"}}})]),s=(new Lt).set({column:!0}).add([new x("Off canvas").set({fluidc:"S6",font:"Arial",id:"#olod",italic:!0,animation:t.el.animation?{range:["0px","1900px"],op:{name:"animation",color:"green",width:"1px"}}:null,pad:[{l:40},{t:20}]})]);return(new Dt).setup({animate:!0,radius:"1rem",isSide:!0,background:"#ecf0f1",hamColour:{opened:"#1abc9c",closed:"#e67e22"},mobileSize:"1.2em"}).items(t.el.offcanvas?s:o)}},{key:"mapFree",value:function(t){var e=t.customOptions.filter((function(t){return"slayout"===t.op.name||"layout"===t.op.name}))[0],r=null,n={cols:6,rows:6};return"text-above-image"!==e.op.value&&"image-above-text"!==e.op.value||(r=null,n=null),"image-overlay-text"===e.op.value&&(r={text:{row:"1 / span 2",col:"3 / span 2"},image:{row:"2 / span 3",col:"3 / 3"}}),"image-leftof-text"===e.op.value&&(r={text:{row:"1",col:"1 / 3"},image:{row:"1",col:"3 / 4"}}),(new hr).set({id:"#3",templateCols:n,height:"600px"}).add([new x("I am free").set({border:"3px solid green",font:"Arial",fluidc:"S1",color:"#1abc9c",gpos:null!=r?r.text:null,zIndex:1}),new L("https://www.cruisemapper.com/images/ships/2183-e9681865a61.jpg").set({url:"https://www.cruisemapper.com/images/ships/2183-e9681865a61.jpg",width:"400px",height:"auto",gpos:null!=r?r.image:null})])}},{key:"mapText",value:function(t){var e,r=t.el;return console.log("OXERO"),console.log(t.customOptions),console.log(this.filtero("span",r.id,t.customOptions)),new x(r.text||r.value).set({id:r.id,class:r.class,color:r.color,size:this.getElType(r.type),font:null!==(e=r.font)&&void 0!==e?e:"Arial",stroke:this.filtero("blast",r.id,t.customOptions),gradient:this.filtero("gradient",r.id,t.customOptions),animation:this.filtero("animation",r.id,t.customOptions),shadow:this.filtero("shadow",r.id,t.customOptions),span:this.filtero("span",r.id,t.customOptions),backgroundOp:this.filtero("background",r.id,t.customOptions),marginOp:this.filtero("margin",r.id,t.customOptions),transform:this.filtero("transform",r.id,t.customOptions),filtera:this.filtero("filter",r.id,t.customOptions)})}},{key:"mapImage",value:function(t){var e=t.el;return new L(e.url).set(Ir(Ir({},e),{},{isFull:e.isFull,animation:this.filtero("animation",e.id,t.customOptions),shadow:this.filtero("shadow",e.id,t.customOptions),marginOp:this.filtero("margin",e.id,t.customOptions),filtera:this.filtero("filter",e.id,t.customOptions)}))}},{key:"mapLink",value:function(t){var e=t.customOptions.filter((function(t){return"link-style"===t.op.name})),r=t.el;return t.el.id&&(r.id=t.el.id),t.el.link&&t.el.text&&(r.url=t.el.link,r.text=t.el.text),r.keySet={key:"background",value:"shadow: 3px 3px solid green"},r.animation=this.filtero("animation",t.el.id,t.customOptions),r.class=t.el.class,r.width=t.el.width,r.font="Arial",r.fluidc=t.el.fluidc,r.index=t.i+"",r.shadow=this.filtero("shadow",t.el.id,t.customOptions),r.backgroundOp=this.filtero("background",t.el.id,t.customOptions),r.pad=[{a:10}],e.length>0?Tr.style({el:t.el,re:r,bst:e,options:t.customOptions})[e.length-1]:(new D).set(r)}},{key:"mapGrid",value:function(t){var e;console.log("OBJ IS"),console.log(t.storage);var r=[],n=null!==(e=t.customOptions.filter((function(t){return"card-style"===t.op.name}))[0])&&void 0!==e?e:{};r=Lr.cards(t.el,n,t.storage);var i='new Card()\n .set({\n width: "300px", radius: "0.7rem", mar: { sides: ["all"], value: "0.8rem" }})\n .items(['.concat(r.join(",")," \n ])");t.el.backgroundCard&&(i='new ZoomCard().set({url: "https://img.freepik.com/free-photo/seascape-texture-waves-water-generative-ai_169016-30500.jpg", font: "Arial", mar: { sides: ["all"], value: "0.8rem" }, inpad: "1rem", useBrightness: true})\n .items([ \n '.concat(r.join(","),",\n ]), \n"));var o=Array(3).fill(i);return'\n \n new FlexGrid()\n .set({colat: "700px", wrap: true, align: "center"}) \n .items(['.concat(o,"])\n \n")}},{key:"mapCDiv",value:function(t){if(t.customOptions,rta){var e=el;e.makeResponsiveBehaviour=rta.op.hash[0].l,e.index=i;var r={width:"200px",height:"100px"};if(ela=(new Lt).set(e),rta.op.hash[0].child){r.makeResponsiveBehaviour=rta.op.hash[0].child.l;var n=(new Lt).set(r).add([new x("Hello")]);ela=(new Lt).set(e).add([n])}}}},{key:"checkbox",value:function(t){return(new wr).set({name:"acceptTerms",label:new x("Check it out!").set({size:"S6",color:"#1abc9c",font:"Arial"}),mar:"10px"})}},{key:"stack",value:function(t){return(new Or).set({}).add([(new L).set({url:"https://pbs.twimg.com/media/DwYvbCBVAAEKY_R.jpg"}),new x("Samuel Suresh").set({color:"#00ae56",font:"SF Pro Display",fluidc:"S2",pad:{sides:["top","left"],value:20}})])}},{key:"form",value:function(t){return(new ze).set({action:"file.php"}).add([(new Kt).set({title:"Your name",type:"input",name:"name"}),(new Kt).set({title:"Your email",type:"input",name:"email",color:"#3498db",font:"Arial",mar:[{a:"1rem"}]}),(new se).set({name:"gender",items:["Male","Female","Third shit"],multiple:!1,tint:"#1abc9c",font:"Arial",exact:"3rem"}),(new fe).set({name:"car",items:[["none","select a car---"],["tesla","Tesla"],["audi","Audi"]],font:"Arial",arrayPadding:{sides:["all"],value:"0.5rem"},radius:"1rem",background:"#1abc9c"}),(new we).set({id:"A",name:"image",title:"Add profile picture",background:"#3498DB",color:"white",font:"Arial",radius:"3rem"}),new Fe("Submit form").set({type:"submit",background:"#3498db",color:"white",weight:"bold",radius:"1rem",pad:[{a:"1rem"}],mar:[{b:"1rem"}]})])}},{key:"simple",value:function(t){return'new Simple()\n .set({ gap: "10px", height: "700px" })\n .react([\n {\n at: "0", // Default size\n color: "red",\n template: [\n "aaaaaa",\n "bbbbbb",\n "cccccc",\n "dddddd",\n "eeeeee",\n ],\n },\n {\n at: "768", // Medium screen size\n color: "blue",\n template: [\n "aa bbb",\n "aa bbb",\n "cc ddd",\n "ee ddd",\n ],\n },\n {\n at: "1024", // Large screen size\n color: "green",\n template: [\n "aaa bbb",\n "ccc ddd",\n "eee ddd",\n ],\n },\n ])\n .add([\n new Text("Hello A").set({size: "S1"}),\n new Text("Hello B").set({size: "S1"}),\n new Text("Hello C").set({size: "S1"}),\n new Text("Hello D").set({size: "S1"}),\n new Text("Hello E").set({size: "S1"})\n ])'}},{key:"getElType",value:function(t){return"S".concat(t.substr(1))}},{key:"filtero",value:function(t,e,r){return r.filter((function(e){return e.op.name===t})).filter((function(t){return!t.target||t.target.includes(e)}))[0]}}],null&&Nr(t.prototype,null),e&&Nr(t,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();module.exports=e})();
|