nodality 1.0.85 → 1.0.104
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 +1 -2
- package/dist/animator.esm.js +1 -2
- package/dist/appleanim.cjs.js +1 -1
- package/dist/appleanim.esm.js +1 -1
- package/dist/audionew.cjs.js +1 -2
- package/dist/audionew.esm.js +1 -2
- package/dist/base.cjs.js +0 -1
- package/dist/base.esm.js +1 -2
- package/dist/beta-desktop-bar.cjs.js +1 -0
- package/dist/beta-desktop-bar.esm.js +1 -0
- package/dist/beta-mobile-bar.cjs.js +1 -0
- package/dist/beta-mobile-bar.esm.js +1 -0
- package/dist/betaDesktopBar.esm.js +1 -1
- package/dist/betaMobileBar.esm.js +1 -1
- package/dist/bundle.umd.js +1 -2
- package/dist/button.cjs.js +1 -2
- package/dist/button.esm.js +1 -2
- package/dist/card-getter.cjs.js +1 -0
- package/dist/card-getter.esm.js +1 -0
- package/dist/cardGetter.esm.js +1 -1
- package/dist/center.cjs.js +1 -2
- package/dist/center.esm.js +1 -2
- package/dist/checkbox.cjs.js +1 -2
- package/dist/checkbox.esm.js +1 -2
- package/dist/code.cjs.js +1 -2
- package/dist/code.esm.js +1 -2
- package/dist/container.cjs.js +1 -2
- package/dist/container.esm.js +1 -2
- package/dist/data-list.cjs.js +1 -0
- package/dist/data-list.esm.js +1 -0
- package/dist/designer.cjs.js +1 -2
- package/dist/designer.esm.js +1 -2
- package/dist/dropdown.cjs.js +1 -2
- package/dist/dropdown.esm.js +1 -2
- package/dist/element-mapper.cjs.js +1 -0
- package/dist/element-mapper.esm.js +1 -0
- package/dist/elementMapper.cjs.js +1 -1
- package/dist/elementMapper.esm.js +1 -1
- package/dist/finalresult.esm.js +1 -2
- package/dist/flex-card.cjs.js +1 -0
- package/dist/flex-card.esm.js +1 -0
- package/dist/flex-grid.cjs.js +1 -0
- package/dist/flex-grid.esm.js +1 -0
- package/dist/flex-row.cjs.js +1 -0
- package/dist/flex-row.esm.js +1 -0
- package/dist/flexCard.cjs.js +1 -1
- package/dist/flexCard.esm.js +1 -1
- package/dist/floating-input.cjs.js +1 -0
- package/dist/floating-input.esm.js +1 -0
- package/dist/free.cjs.js +1 -2
- package/dist/free.esm.js +1 -2
- package/dist/horizontal-scroller.cjs.js +1 -0
- package/dist/horizontal-scroller.esm.js +1 -0
- package/dist/image-picker.cjs.js +1 -0
- package/dist/image-picker.esm.js +1 -0
- package/dist/image.cjs.js +1 -2
- package/dist/image.esm.js +1 -2
- package/dist/index.cjs.js +1 -2
- package/dist/index.esm.js +1 -2
- package/dist/keyframe-animation.cjs.js +1 -0
- package/dist/keyframe-animation.esm.js +1 -0
- package/dist/link-getter.cjs.js +1 -0
- package/dist/link-getter.esm.js +1 -0
- package/dist/link.cjs.js +1 -2
- package/dist/link.esm.js +1 -2
- package/dist/linkGetter.cjs.js +1 -1
- package/dist/linkGetter.esm.js +1 -1
- package/dist/meta-adder.cjs.js +1 -0
- package/dist/meta-adder.esm.js +1 -0
- package/dist/modal-2025.cjs.js +1 -0
- package/dist/modal-2025.esm.js +1 -0
- package/dist/multiswitcher.cjs.js +1 -0
- package/dist/multiswitcher.esm.js +1 -0
- package/dist/new-nav-bar.cjs.js +1 -0
- package/dist/new-nav-bar.esm.js +1 -0
- package/dist/picker.cjs.js +1 -2
- package/dist/picker.esm.js +1 -2
- package/dist/progress.cjs.js +1 -2
- package/dist/progress.esm.js +1 -2
- package/dist/radio.cjs.js +1 -2
- package/dist/radio.esm.js +1 -2
- package/dist/range.cjs.js +1 -2
- package/dist/range.esm.js +1 -2
- package/dist/scroll-video.cjs.js +1 -0
- package/dist/scroll-video.esm.js +1 -0
- package/dist/scrollvideo.cjs.js +1 -1
- package/dist/scrollvideo.esm.js +1 -1
- package/dist/side-bar.cjs.js +1 -0
- package/dist/side-bar.esm.js +1 -0
- package/dist/side-nav-bar.cjs.js +1 -0
- package/dist/side-nav-bar.esm.js +1 -0
- package/dist/simple-bar.cjs.js +1 -0
- package/dist/simple-bar.esm.js +1 -0
- package/dist/slider-2025.cjs.js +1 -0
- package/dist/slider-2025.esm.js +1 -0
- package/dist/spacer.cjs.js +0 -1
- package/dist/spacer.esm.js +1 -0
- package/dist/stack.cjs.js +1 -2
- package/dist/stack.esm.js +1 -2
- package/dist/stacker.cjs.js +1 -2
- package/dist/stacker.esm.js +1 -2
- package/dist/table.cjs.js +1 -2
- package/dist/table.esm.js +1 -2
- package/dist/text-field.cjs.js +1 -0
- package/dist/text-field.esm.js +1 -0
- package/dist/text.cjs.js +1 -2
- package/dist/text.esm.js +1 -2
- package/dist/transform-anim.cjs.js +1 -0
- package/dist/transform-anim.esm.js +1 -0
- package/dist/transformanim.cjs.js +1 -1
- package/dist/transformanim.esm.js +1 -1
- package/dist/ulist.cjs.js +1 -2
- package/dist/ulist.esm.js +1 -2
- package/dist/video.cjs.js +1 -0
- package/dist/video.esm.js +1 -2
- package/dist/wrap.cjs.js +0 -1
- package/dist/wrap.esm.js +1 -2
- package/dist/zoom-card.cjs.js +1 -0
- package/dist/zoom-card.esm.js +1 -0
- 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 → beta-desktop-bar.js} +1 -1
- package/layout/{betaMobileBar.js → beta-mobile-bar.js} +1 -1
- package/layout/box.js +1 -1
- package/layout/button.js +1 -1
- package/layout/cards.js +2 -1
- package/layout/center.js +1 -1
- package/layout/checkbox.js +1 -1
- package/layout/circle.js +1 -1
- package/layout/{cleanRow.js → clean-row.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 → div-image.js} +1 -1
- package/layout/{dropdown2025.js → dropdown-2025.js} +1 -1
- package/layout/dropdown.js +1 -1
- package/layout/{emptyElement.js → empty-element.js} +1 -1
- package/layout/{externalStylesheet.js → external-stylesheet.js} +1 -1
- package/layout/{flexCard.js → flex-card.js} +3 -1
- package/layout/{flexGrid.js → flex-grid.js} +1 -1
- package/layout/{flexrow.js → flex-row.js} +1 -1
- package/layout/footer.js +1 -1
- package/layout/{formComponents → form-components}/custom.js +1 -1
- package/layout/{formComponents/dataList.js → form-components/data-list.js} +1 -1
- package/layout/{formComponents/floatingInput.js → form-components/floating-input.js} +1 -1
- package/layout/{formComponents → form-components}/form-all.js +1 -1
- package/layout/{formComponents → form-components}/form.js +1 -1
- package/layout/{formComponents/imagePicker.js → form-components/image-picker.js} +1 -1
- package/layout/{formComponents → form-components}/picker.js +1 -1
- package/layout/{formComponents → form-components}/radio.js +1 -1
- package/layout/{formComponents → form-components}/radiogroup.js +1 -1
- package/layout/{formComponents → form-components}/range.js +1 -1
- package/layout/free.js +1 -1
- package/layout/grid-new.js +1 -1
- package/layout/{gridSwitcher.js → grid-switcher.js} +1 -1
- package/layout/grid.js +1 -1
- package/layout/group.js +1 -1
- package/layout/header.js +1 -1
- package/layout/{horizontalScroller.js → horizontal-scroller.js} +1 -1
- package/layout/image-old.js +1 -1
- package/layout/image.js +1 -1
- package/layout/index.js +49 -37
- 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 → meta-adder.js} +1 -1
- package/layout/{modal2025.js → modal-2025.js} +1 -1
- package/layout/modernwrap.js +1 -1
- package/layout/multiswitcher.js +1 -1
- package/layout/multiswitcherBeta.js +1 -1
- package/layout/{navBar.js → nav-bar.js} +1 -1
- package/layout/{navFactor/customDiv.js → nav-factor/custom-div.js} +1 -1
- package/layout/navBar-OLD.js +1 -1
- package/layout/{newFlatAdder.js → new-flat-adder.js} +1 -1
- package/layout/{newNavBar.js → new-nav-bar.js} +1 -1
- package/layout/{offsetContainer.js → offset-container.js} +1 -1
- package/layout/polygon.js +1 -1
- package/layout/progress.js +1 -1
- package/layout/row.js +1 -1
- package/layout/{savedNewNavBar.js → saved-new-nav-bar.js} +1 -1
- package/layout/{scrollvideo.js → scroll-video.js} +1 -1
- package/layout/{sideBar.js → side-bar.js} +1 -1
- package/layout/{sideNavBar.js → side-nav-bar.js} +1 -1
- package/layout/{simpleBar.js → simple-bar.js} +1 -1
- package/layout/{slider2025.js → slider-2025.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/{textField.js → text-field.js} +1 -1
- package/layout/text.js +1 -1
- package/layout/ulist.js +1 -1
- package/layout/video.js +1 -1
- package/layout/{withoutNew.js → without-new.js} +1 -1
- package/layout/wrap.js +1 -1
- package/layout/{zoomCard.js → zoom-card.js} +1 -1
- package/lib/{cardGetter.js → card-getter.js} +1 -1
- package/lib/designer.js +49 -49
- package/lib/{elementMapper.js → element-mapper.js} +56 -37
- package/lib/{KeyframeAnimation.js → keyframe-animation.js} +1 -1
- package/lib/{linkGetter.js → link-getter.js} +1 -1
- package/lib/{scrollvideo.js → scroll-video.js} +1 -1
- package/lib/{Stacker.js → stacker.js} +2 -1
- package/lib/{TransformAnim.js → transform-anim.js} +1 -1
- package/package.json +4 -2
- package/dist/KeyframeAnimation.cjs.js +0 -2
- package/dist/KeyframeAnimation.cjs.js.LICENSE.txt +0 -5
- package/dist/KeyframeAnimation.esm.js +0 -2
- package/dist/KeyframeAnimation.esm.js.LICENSE.txt +0 -5
- package/dist/animator.cjs.js.LICENSE.txt +0 -5
- package/dist/animator.esm.js.LICENSE.txt +0 -5
- package/dist/appleanim.cjs.js.LICENSE.txt +0 -5
- package/dist/appleanim.esm.js.LICENSE.txt +0 -5
- package/dist/audionew.cjs.js.LICENSE.txt +0 -5
- package/dist/audionew.esm.js.LICENSE.txt +0 -5
- package/dist/base.cjs.js.LICENSE.txt +0 -5
- package/dist/base.esm.js.LICENSE.txt +0 -5
- package/dist/betaDesktopBar.esm.js.LICENSE.txt +0 -5
- package/dist/betaMobileBar.esm.js.LICENSE.txt +0 -5
- package/dist/bundle.umd.js.LICENSE.txt +0 -5
- package/dist/button.cjs.js.LICENSE.txt +0 -5
- package/dist/button.esm.js.LICENSE.txt +0 -5
- package/dist/cardGetter.cjs.js.LICENSE.txt +0 -5
- package/dist/cardGetter.esm.js.LICENSE.txt +0 -5
- package/dist/center.cjs.js.LICENSE.txt +0 -5
- package/dist/center.esm.js.LICENSE.txt +0 -5
- package/dist/checkbox.cjs.js.LICENSE.txt +0 -5
- package/dist/checkbox.esm.js.LICENSE.txt +0 -5
- package/dist/circle.cjs.js +0 -2
- package/dist/circle.cjs.js.LICENSE.txt +0 -5
- package/dist/circle.esm.js +0 -2
- package/dist/circle.esm.js.LICENSE.txt +0 -5
- package/dist/code.cjs.js.LICENSE.txt +0 -5
- package/dist/code.esm.js.LICENSE.txt +0 -5
- package/dist/container.cjs.js.LICENSE.txt +0 -5
- package/dist/container.esm.js.LICENSE.txt +0 -5
- package/dist/datalist.cjs.js.LICENSE.txt +0 -5
- package/dist/datalist.esm.js.LICENSE.txt +0 -5
- package/dist/designer.cjs.js.LICENSE.txt +0 -5
- package/dist/designer.esm.js.LICENSE.txt +0 -5
- package/dist/dropdown.cjs.js.LICENSE.txt +0 -5
- package/dist/dropdown.esm.js.LICENSE.txt +0 -5
- package/dist/elementMapper.cjs.js.LICENSE.txt +0 -5
- package/dist/elementMapper.esm.js.LICENSE.txt +0 -5
- package/dist/finalresult.esm.js.LICENSE.txt +0 -5
- package/dist/flexCard.cjs.js.LICENSE.txt +0 -5
- package/dist/flexCard.esm.js.LICENSE.txt +0 -5
- package/dist/flexGrid.cjs.js.LICENSE.txt +0 -5
- package/dist/flexGrid.esm.js.LICENSE.txt +0 -5
- package/dist/flexRow.cjs.js.LICENSE.txt +0 -5
- package/dist/flexRow.esm.js.LICENSE.txt +0 -5
- package/dist/floatingInput.cjs.js.LICENSE.txt +0 -5
- package/dist/floatingInput.esm.js.LICENSE.txt +0 -5
- package/dist/free.cjs.js.LICENSE.txt +0 -5
- package/dist/free.esm.js.LICENSE.txt +0 -5
- package/dist/gridSwitcher.cjs.js +0 -2
- package/dist/gridSwitcher.cjs.js.LICENSE.txt +0 -5
- package/dist/gridSwitcher.esm.js +0 -2
- package/dist/gridSwitcher.esm.js.LICENSE.txt +0 -5
- package/dist/horizontalScroller.esm.js.LICENSE.txt +0 -5
- package/dist/image.cjs.js.LICENSE.txt +0 -5
- package/dist/image.esm.js.LICENSE.txt +0 -5
- package/dist/imagePicker.cjs.js.LICENSE.txt +0 -5
- package/dist/imagePicker.esm.js.LICENSE.txt +0 -5
- package/dist/index.cjs.js.LICENSE.txt +0 -5
- package/dist/index.esm.js.LICENSE.txt +0 -5
- package/dist/link.cjs.js.LICENSE.txt +0 -5
- package/dist/link.esm.js.LICENSE.txt +0 -5
- package/dist/linkGetter.cjs.js.LICENSE.txt +0 -5
- package/dist/linkGetter.esm.js.LICENSE.txt +0 -5
- package/dist/metaAdder.cjs.js.LICENSE.txt +0 -5
- package/dist/metaAdder.esm.js.LICENSE.txt +0 -5
- package/dist/modal2025.cjs.js.LICENSE.txt +0 -5
- package/dist/modal2025.esm.js.LICENSE.txt +0 -5
- package/dist/multiswitchers.esm.js.LICENSE.txt +0 -5
- package/dist/newNavBar.cjs.js.LICENSE.txt +0 -5
- package/dist/newNavBar.esm.js.LICENSE.txt +0 -5
- package/dist/picker.cjs.js.LICENSE.txt +0 -5
- package/dist/picker.esm.js.LICENSE.txt +0 -5
- package/dist/polygon.cjs.js +0 -2
- package/dist/polygon.cjs.js.LICENSE.txt +0 -5
- package/dist/polygon.esm.js +0 -2
- package/dist/polygon.esm.js.LICENSE.txt +0 -5
- package/dist/progress.cjs.js.LICENSE.txt +0 -5
- package/dist/progress.esm.js.LICENSE.txt +0 -5
- package/dist/radio.cjs.js.LICENSE.txt +0 -5
- package/dist/radio.esm.js.LICENSE.txt +0 -5
- package/dist/range.cjs.js.LICENSE.txt +0 -5
- package/dist/range.esm.js.LICENSE.txt +0 -5
- package/dist/scrollvideo.cjs.js.LICENSE.txt +0 -5
- package/dist/scrollvideo.esm.js.LICENSE.txt +0 -5
- package/dist/sideBar.cjs.js.LICENSE.txt +0 -5
- package/dist/sideBar.esm.js.LICENSE.txt +0 -5
- package/dist/sideNavBar.cjs.js.LICENSE.txt +0 -5
- package/dist/sideNavBar.esm.js.LICENSE.txt +0 -5
- package/dist/simpleBar.cjs.js.LICENSE.txt +0 -5
- package/dist/simpleBar.esm.js.LICENSE.txt +0 -5
- package/dist/slider2025.cjs.js +0 -2
- package/dist/slider2025.cjs.js.LICENSE.txt +0 -5
- package/dist/slider2025.esm.js +0 -2
- package/dist/slider2025.esm.js.LICENSE.txt +0 -5
- package/dist/spacer.cjs.js.LICENSE.txt +0 -5
- package/dist/stack.cjs.js.LICENSE.txt +0 -5
- package/dist/stack.esm.js.LICENSE.txt +0 -5
- package/dist/stacker.cjs.js.LICENSE.txt +0 -5
- package/dist/stacker.esm.js.LICENSE.txt +0 -5
- package/dist/table.cjs.js.LICENSE.txt +0 -5
- package/dist/table.esm.js.LICENSE.txt +0 -5
- package/dist/text.cjs.js.LICENSE.txt +0 -5
- package/dist/text.esm.js.LICENSE.txt +0 -5
- package/dist/textField.cjs.js.LICENSE.txt +0 -5
- package/dist/textField.esm.js.LICENSE.txt +0 -5
- package/dist/transformanim.cjs.js.LICENSE.txt +0 -5
- package/dist/transformanim.esm.js.LICENSE.txt +0 -5
- package/dist/ulist.cjs.js.LICENSE.txt +0 -5
- package/dist/ulist.esm.js.LICENSE.txt +0 -5
- package/dist/video.esm.js.LICENSE.txt +0 -5
- package/dist/wrap.cjs.js.LICENSE.txt +0 -5
- package/dist/wrap.esm.js.LICENSE.txt +0 -5
- package/dist/zoomCard.cjs.js.LICENSE.txt +0 -5
- package/dist/zoomCard.esm.js.LICENSE.txt +0 -5
- package/layout/<head> +0 -59
- package/layout/DEADJOE +0 -49
- package/layout/DEPRECATED-PARAGRAPH.js +0 -109
- package/layout/edit.sh +0 -39
- package/layout/formComponents/edit.sh +0 -39
- package/layout/navFactor/edit.sh +0 -39
- package/layout/newNavBar copy 2.js +0 -921
- package/layout/newNavBar copy.js +0 -780
- package/lib/AppleAnim.js +0 -794
package/dist/picker.cjs.js
CHANGED
|
@@ -1,2 +1 @@
|
|
|
1
|
-
/*! For license information please see picker.cjs.js.LICENSE.txt */
|
|
2
|
-
(()=>{"use strict";var e={d:(t,r)=>{for(var n in r)e.o(r,n)&&!e.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:r[n]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},t={};function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}function n(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,s,o,a=[],l=!0,c=!1;try{if(s=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=s.call(r)).done)&&(a.push(n.value),a.length!==t);l=!0);}catch(e){c=!0,i=e}finally{try{if(!l&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(c)throw i}}return a}}(e,t)||s(e,t)||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 i(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=s(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,i=function(){};return{s:i,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},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(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){l=!0,o=e},f:function(){try{a||null==r.return||r.return()}finally{if(l)throw o}}}}function s(e,t){if(e){if("string"==typeof e)return o(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?o(e,t):void 0}}function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function a(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,l(n.key),n)}}function l(e){var t=function(e){if("object"!=r(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=r(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==r(t)?t:t+""}function c(e){return c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},c(e)}function u(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,p(n.key),n)}}function p(e){var t=function(e){if("object"!=c(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=c(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==c(t)?t:t+""}function d(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(d=function(){return!!e})()}function f(e){return f=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},f(e)}function y(e,t){return y=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},y(e,t)}e.r(t),e.d(t,{Picker:()=>h});var h=function(e){function t(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(e=function(e,t,r){return t=f(t),function(e,t){if(t&&("object"==c(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,d()?Reflect.construct(t,r||[],f(e).constructor):t.apply(e,r))}(this,t)).el=null,e.file=null,e.selected="",e}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&y(e,t)}(t,e),r=t,n=[{key:"setup",value:function(e,t){document.createElement("div");var r=document.createElement("select");r.setAttribute("type","file"),r.setAttribute("name",t),r.addEventListener("change",(function(){r.options[r.selectedIndex].value}));for(var n=0;n<e.length;n++)r.appendChild(this.addNode(e[n][0],e[n][1]));return this.el=r,this}},{key:"set",value:function(e){return this.options=e,e.items&&this.setup(e.items,e.name),e.arrayPadding&&this.arrayPadding(e.arrayPadding.sides,e.arrayPadding.value),e.arrayMargin&&this.arrayMargin(e.arrayMargin.sides,e.arrayMargin.value),e.pad&&this.pad(e.pad),e.mar&&this.mar(e.mar),e.radius&&(this.el.style.borderRadius=e.radius),e.background&&(this.el.style.background=e.background),this}},{key:"arrayPadding",value:function(e,t){return e.includes("left")&&(this.el.style.paddingLeft=t),e.includes("right")&&(this.el.style.paddingRight=t),e.includes("top")&&(this.el.style.paddingTop=t),e.includes("bottom")&&(this.el.style.paddingBottom=t),e.includes("all")&&(this.el.style.padding=t),this}},{key:"arrayMargin",value:function(e,t){return e.includes("left")&&(this.el.style.marginLeft=t),e.includes("right")&&(this.el.style.marginRight=t),e.includes("top")&&(this.el.style.marginTop=t),e.includes("bottom")&&(this.el.style.marginBottom=t),e.includes("all")&&(this.el.style.margin=t),this}},{key:"addNode",value:function(e,t){var r=document.createElement("option");r.setAttribute("value",e);var n=document.createTextNode(t);return r.appendChild(n),r}},{key:"padding",value:function(e){return this.el.style.padding=e,this}},{key:"font",value:function(e){return this.el.style.fontFamily=e,this}},{key:"margin",value:function(e){return this.el.style.margin=e,this}},{key:"toCode",value:function(){var e=JSON.stringify(this.options,null,4);return e=e.replace(/"(\w+)"(?=\s*:)/g,"$1"),["new Picker().set(".concat(e,")")]}},{key:"rounded",value:function(e){return this.el.style.borderRadius="4px",this}},{key:"auto",value:function(){var e=this,t=function(){window.matchMedia("(max-device-width: 415px)").matches?e.el.style.fontSize="3rem":e.el.style.fontSize="1rem"};return t(),window.addEventListener("resize",t),this}},{key:"render",value:function(e){if(!e)return this.el;document.querySelector(e).appendChild(this.el)}}],n&&u(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(function(){return e=function e(){var t,r,n,i=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),t=this,n=function(e){if(console.log("LOBJO IS"),console.log(e),e.transform||e.op&&e.op.transform){var t=e.transform;e.transform||(t=e.op.transform),t.duration||(t.duration="3s-ease-in-out"),i.setDefault=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"0px";return 0===e.length?t+" ":e};var r=function(){var r="",n="",s="",o="",a="",l="",c="",u="",p="";if(0!==t.values.length){t.values.forEach((function(e){e.startsWith("tx:")&&(r=e.replace("tx:","")),e.startsWith("ty:")&&(n=e.replace("ty:","")),e.startsWith("tz:")?s=e.replace("tz:",""):e.startsWith("scale(")?o=e:e.startsWith("skew(")?a=e:e.startsWith("rotate(")?l=function(e){var t=e.match(/rotate\(([^)]+)\)/);if(!t)return e;var r=t[1].split(",").map((function(e){return e.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],")"):e}(e):e.startsWith("perspective(")?c=e:e.startsWith("matrix(")?u=e:e.startsWith("opacity:")&&(p=e.replace("opacity:",""))})),r=i.setDefault(r),n=i.setDefault(n),s=i.setDefault(s);var d="";if("0px"!=n&&"0px"!=r&&"0px"!=s?d+="translate3d(".concat(r,", ").concat(n,", ").concat(s,")"):"0px"==n&&"0px"==r||(d+="translate(".concat(r,", ").concat(n,")")),o&&(d+=" ".concat(o)),l&&(d+=" ".concat(l)),a&&(d+=" ".concat(a)),c&&(d+=" ".concat(c)),u&&(d+=" ".concat(u)),d){if(e.op.transform.duration){var f=e.op.transform.duration.replace(/^(\d+)(s)-/,(function(e,t,r){return t/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";e.op.transform.static&&(i.res.style.transition=""),(i.blastTarget||i.res).style.transform=d,i.res.style.opacity=p}else alert("OPE")}};t.on?i.res.addEventListener(t.on,(function(){t.delay?setTimeout((function(){r()}),t.delay):r()})):window.addEventListener("load",(function(){t.delay?setTimeout((function(){r()}),t.delay):r()}));var n=function(){var e="";t.values.forEach((function(t){t.startsWith("tx:")?e+="translateX(0) ":t.startsWith("ty:")?e+="translateY(0) ":t.startsWith("tz:")?e+="translateZ(0) ":t.startsWith("scale(")?e+="scale(1) ":t.startsWith("skew(")?e+="skew(0, 0) ":t.startsWith("rotate(")?e+="rotate(0) ":t.startsWith("perspective(")?e+="perspective(0) ":t.startsWith("matrix(")&&(e+="matrix(1, 0, 0, 1, 0, 0) "),i.res.style.opacity="1"})),e&&(i.res.style.transform=e.trim())};if(t.on)i.res.addEventListener("mouseout",(function(){t.keep||n()}));else{var s=1e3*parseFloat(t.duration),o=t.closeAfter?t.closeAfter:0;setTimeout((function(){t.keep||n()}),s/2+o)}t.hardCSS&&(i.res.style.transform=t.hardCSS)}else alert("THIS FIRE WITH GRADIENT (invalid block"),console.log("INVALID BLOCKA"),console.log(e)},(r=l(r="reactOnTransform"))in t?Object.defineProperty(t,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[r]=n,this.state={isExpanded:!1,isMovedUp:!1,isMovedDown:!1},this.openedElements=new WeakMap},t=[{key:"isHidden",value:function(e){e&&(this.res.style.display="none")}},{key:"keySet",value:function(e){return this.temporaryVal=1,this.res.style[e.key]=e.value,this}},{key:"commonMethods",value:function(e){var t={exact:"fontSize",zIndex:"zIndex",position:"position",top:"top",cursor:"cursor",width:"width",maxWidth:"maxWidth",height:"height",maxHeight:"maxHeight",radius:"borderRadius",lineHeight:"lineHeight",background:"background",font:"fontFamily",opacity:"opacity"};for(var r in t)null!=e[r]&&(this.res.style[t[r]]=e[r]);return e.pad&&this.pad(e.pad),e.mar&&this.mar(e.mar),e.respad&&this.respad(e.respad),e.resmar&&this.resmar(e.resmar),e.hover&&this.hover(e.hover),e.size&&this.fluidCopy(e.size),e.resprop&&this.resprop(e.resprop),e.keySet&&this.keySet(e.keySet),e.hide&&this.isHidden(e.hide),e.bold?this.res.style.fontWeight="bold":null!=e.weight&&(this.res.style.fontWeight=e.weight),this}},{key:"hover",value:function(e){var t=this;if(e.border){var r=e.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,e.animation&&(this.res.style.transition="".concat(e.animation),this.res.style.transionProperty="background, color"),this.res.onmouseout=function(){t.res.style.backgroundColor="".concat(t.prevColor),t.res.style.color="".concat(t.foreColor),t.res.style.border=t.prevBorder},this.res.onmouseover=function(){if(t.res.style.color=e.color,t.res.style.backgroundColor=e.background,e.border){var r,n=e.border.width,i=null!==(r=e.border.color)&&void 0!==r?r:"#2ECC71";t.res.style.border=n?"".concat(n,"px solid ").concat(i):"1px solid #2ECC71"}},this}},{key:"onScroll",value:function(e){var t=this;"opacity"===e.value?this.res.style.opacity=e.valMin:"scale"===e.value&&(this.res.style.transform="scale(".concat(e.valMax,")")),window.addEventListener("scroll",(function(){var r=t.smartRange(window.scrollY,{min:e.from,max:e.to},{min:e.valMin,max:e.valMax});"opacity"===e.value?t.res.style.opacity=r:"scale"===e.value&&(t.res.style.transform="scale(".concat(r,")"))}))}},{key:"setAny",value:function(e){this[Object.keys(e)[0]]=[Object.values(e)[0]]}},{key:"setID",value:function(e){this.id=e}},{key:"setPrevText",value:function(e){this.prevText=e}},{key:"getCSS",value:function(){return this.css}},{key:"getPX",value:function(e){return{xs:"0px",sm:"576px",md:"768px",lg:"992px",xl:"1200px",xxl:"1400px",mxxl:"1800px"}[e]||"Invalid breakpoint"}},{key:"respad",value:function(e){var t=this;this._applyResponsive(e,(function(e){console.log("Applying padding for",e.breakpoint),t.pad(e.values)}))}},{key:"_applyResponsive",value:function(e,t){var r={default:0,xs:0,sm:576,md:768,lg:992,xl:1200,xxl:1400};e.forEach((function(e){void 0!==r[e.breakpoint]?e._value=r[e.breakpoint]:e._value=parseInt(e.breakpoint,10)})),e.sort((function(e,t){return e._value-t._value}));var n=e.find((function(e){return"default"===e.breakpoint})),i=function(){for(var r=window.innerWidth,i=n||null,s=0;s<e.length;s++){var o=e[s];if("default"!==o.breakpoint&&r<=o._value){i=o;break}}i&&t(i)};this._responsiveHandler&&window.removeEventListener("resize",this._responsiveHandler),this._responsiveHandler=i,window.addEventListener("resize",i),i()}},{key:"resmar",value:function(e){var t=this;this._applyResponsive(e,(function(e){console.log("Applying margin for",e.breakpoint),t.mar(e.values)}))}},{key:"resprop",value:function(e){var t=this;this.prevStyles={};for(var r=0;r<this.res.style.length;r++){var n=this.res.style[r];this.prevStyles[n]=this.res.style[n]}this._applyResponsive(e,(function(e){for(var r in console.log("Applying styles for",e.breakpoint),t.prevStyles)t.res.style[r]=t.prevStyles[r];for(var n in e)"breakpoint"!==n&&"_value"!==n&&"values"!==n&&(t.res.style[n]=e[n])}))}},{key:"isNumber",value:function(e){return"number"==typeof e&&!isNaN(e)}},{key:"pad",value:function(e){for(var t=0;t<e.length;t++)for(var r=Object.keys(e[t]),n=0;n<r.length;n++)for(var i=r[n],s=e[t][i],o=0;o<i.length;o++)switch(i[o]){case"a":this.res.style.padding=this.isNumber(s)?"".concat(s,"px"):s;break;case"t":this.res.style.paddingTop=this.isNumber(s)?"".concat(s,"px"):s;break;case"l":this.res.style.paddingLeft=this.isNumber(s)?"".concat(s,"px"):s;break;case"r":this.res.style.paddingRight=this.isNumber(s)?"".concat(s,"px"):s;break;case"b":this.res.style.paddingBottom=this.isNumber(s)?"".concat(s,"px"):s}return this}},{key:"as",value:function(e){return this.res.style.alignSelf=e,this}},{key:"mar",value:function(e){for(var t=0;t<e.length;t++)for(var r=Object.keys(e[t]),n=0;n<r.length;n++)for(var i=r[n],s=e[t][i],o=0;o<i.length;o++){switch(i[o]){case"a":this.res.style.margin=this.isNumber(s)?"".concat(s,"px"):s;break;case"t":this.res.style.marginTop=this.isNumber(s)?"".concat(s,"px"):s;break;case"l":this.res.style.marginLeft=this.isNumber(s)?"".concat(s,"px"):s;break;case"r":this.res.style.marginRight=this.isNumber(s)?"".concat(s,"px"):s;break;case"b":this.res.style.marginBottom=this.isNumber(s)?"".concat(s,"px"):s}"auto"===i[o]&&(this.res.style.marginLeft="auto",this.res.style.marginRight="auto")}return this}},{key:"smartRange",value:function(e,t,r){e<t.min&&(e=t.min),e>t.max&&(e=t.max);var n=(e-t.min)/(t.max-t.min);t.min>t.max&&(n=(e-t.max)/(t.min-t.max));var i=(r.min-r.max)*n-r.min;if(i=Math.abs(i),r.min<r.max){var s=(r.max+Math.abs(r.min))*n;i=r.min+s}return i}},{key:"gpos",value:function(e){return this.res.style.gridColumn=e.col,this.res.style.gridRow=e.row,this}},{key:"fluidCopy",value:function(e){if(e instanceof Object){this.prevStylex=this.res.style,this.res=document.createElement("h1"),this.res.style.cssText=this.prevStylex.cssText;var t=document.createTextNode(this.text);return this.res.appendChild(t),this.res.style.fontSize=e.exact,this}if("S1"===e){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"===e){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"===e){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"===e){this.prevStylex=this.res.style,this.res=document.createElement("h4"),this.res.style.cssText=this.prevStylex.cssText;var s=document.createTextNode(this.text);this.res.appendChild(s),this.res.style.fontSize="calc(1.250rem + 2.75vw)"}if("S5"===e){this.prevStylex=this.res.style,this.res=document.createElement("h5"),this.res.style.cssText=this.prevStylex.cssText;var o=document.createTextNode(this.text);this.res.appendChild(o),this.res.style.fontSize="calc(1.125rem + 1.975vw)"}return"S6"===e&&(this.res.style.fontSize="calc(1rem + 0.5vw)"),this}},{key:"setIndex",value:function(e){this.index=e}},{key:"borderObj",value:function(e){var t,r=null!==(t=e.type)&&void 0!==t?t:"solid";return this.res.style.border="".concat(e.width," ").concat(r," ").concat(e.color),this.res.style.borderRadius=e.radius,this}},{key:"setPref",value:function(e){this.preffersId=e}},{key:"setClass",value:function(e){this.class=e}},{key:"setTags",value:function(e){this.openTag=e.open,this.closeTag=e.close,console.log("TAGS SET"),console.log(e)}},{key:"chainReact",value:function(e,t,r){var s=this;console.log("0P"),this.ap=!1,this.cta=0,this.once=!1;var o,a=i(e);try{for(a.s();!(o=a.n()).done;){var l=o.value;l.range||(l.range=["0px","999999px"])}}catch(e){a.e(e)}finally{a.f()}e.sort((function(e,t){return parseInt(e.range[0])-parseInt(t.range[0])}));var c=function(o){var a=window.visualViewport.width,l=[],c=[];s.resCopy=s.res,s.storedQueries=e.map((function(e){return e.target})).filter((function(e){return null!=e}));var u,p=i(e);try{for(p.s();!(u=p.n()).done;){var d=u.value;s.counterIndex++;var f=n(d.range,2),y=f[0],h=f[1],v=parseInt(y),m=parseInt(h),g=!0;if(d.target){g=!1;for(var b=0;b<d.target.length;b++)d.target[b]===t&&(g=!0)}a>=v&&a<=m&&g&&(l.push(d.log),c.push(d),d.op&&d.op.margin&&(s.useMargin=d.op.margin))}}catch(e){p.e(e)}finally{p.f()}if(r&&!r.includes("background")&&(s.res.style.background="",s.res.style.backgroundColor=""),s.res.style.textShadow="",r&&!r.includes("border")&&(s.res.style.border=""),r&&!r.includes("margin")&&(s.res.style.margin=""),s.res.style["-webkit-text-fill-color"]="",s.res.style["-webkit-text-stroke-color"]="",s.res.style["-webkit-text-stroke-width"]="",s.res.style.filter="",s.options.background&&(console.log(s.options.background),s.res.style.background=s.options.background),l.includes("gradient"),(l.includes("gradient")||l.includes("shadow"))&&(s.res.style.position="relative"),l.includes("blast")){var x,k=c.filter((function(e){return"blast"===e.log}))[0].op.color,w=null!==(x=c.filter((function(e){return"blast"===e.log}))[0].op.width)&&void 0!==x?x:"1px";"FlexRowLayoutElement"===s.getType()||"LayoutWrapperElement"===s.getType()?(s.res.style.border="".concat("number"==typeof w?w+"px":w," solid orange"),s.res.style.display="inline-block","FlexRowLayoutElement"===s.getType()&&(s.res.style.display="flex"),s.res.style.boxSizing="border-box",s.res.style.transformOrigin="center",s.blastTarget=s.res):(s.text,s.res.style["-webkit-text-fill-color"]="transparent",s.res.style["-webkit-text-stroke-color"]=k,s.res.style["-webkit-text-stroke-width"]="".concat(w))}if(l.includes("filter")){var S=c.filter((function(e){return"filter"===e.log}))[0].op.filter;s.res.style.filter=S}if(l.includes("background")&&(s.res.style.backgroundColor="green"),l.includes("gradient")&&("LayoutWrapperElement"!==s.getType()&&"FlexRowLayoutElement"!==s.getType()&&(s.res.style["-webkit-text-fill-color"]="transparent"),s.res.style.background=s.globalGradient,"LayoutWrapperElement"!==s.getType()&&"FlexRowLayoutElement"!==s.getType()&&(s.res.style["background-clip"]="text")),l.includes("shadow")){var T,E,O,C,j=s.options.shadow.op;console.log("OP IS",j);var P=null!==(T=j.steps)&&void 0!==T?T:1,W=null!==(E=j.colors)&&void 0!==E?E:["gray"],A=null!==(O=j.movements)&&void 0!==O?O:["3px","3px"],L=null!==(C=j.radius)&&void 0!==C?C:"3px";if(1===A.length&&(A=[A[0],A[0]]),"FlexRowLayoutElement"===s.getType()||"LayoutWrapperElement"===s.getType()){for(var I=[],R=0;R<P;R++){var N,_=null!==(N=W[R])&&void 0!==N?N:W[0],z=A[0],M=A[1];I.push("".concat(z," ").concat(M," ").concat(L," ").concat(_))}s.res.style.boxShadow=I.join(", ")}else{for(var B=[],F=0;F<P;F++){var H,D=null!==(H=W[F])&&void 0!==H?H:W[0],Y=A[0],X=A[1];B.push("drop-shadow(".concat(Y," ").concat(X," ").concat(L," ").concat(D,")"))}s.res.style.filter=B.join(" ")}}if(l.includes("margin"))for(b=0;b<e.length;b++)if(e[b].op){var G=e[b].op.offsets;G&&void 0!==s.index&&(s.res.style.margin=G[Number(s.index)]+"px")}if(l.includes("spana")||l.includes("span")){var V=document.createElement("div");if(V.setAttribute("id","oroa"),Object.assign(V.style,{position:"absolute",inset:"0",background:"linear-gradient(90deg, rgb(52,152,219), rgb(26,188,156))",WebkitBackgroundClip:"text",WebkitTextFillColor:"transparent",pointerEvents:"none"}),s.res&&s.res.querySelector("span"))return;s.res=s.resCopy,s.res.textContent="",s.options.span&&(Array.isArray(s.options.span)?s.options.span:[s.options.span]).forEach((function(e){if(e.op&&"span"===e.op.name&&Array.isArray(e.op.parts)){var t=0,r=s.prevText||"";if(e.op.parts.forEach((function(e){var n=e.text,i=e.style||{};if(t<r.length){var o=r.indexOf(n,t);if(o>t){var a=r.substring(t,o);s.res.appendChild(new s.constructor(a).setup({type:"span",id:i.id,animation:i.animation}).set({}).render())}t=o+n.length}var l=new s.constructor(n).setup({type:"span",id:i.id,animation:i.animation}).set(i).render();s.res.appendChild(l)})),t<r.length){var n=r.substring(t);s.res.appendChild(new s.constructor(n).setup({type:"span"}).set({}).render())}}}))}else{var $=new s.constructor(s.prevText).set({}).render();s.prevText&&s.prevText.length>0&&o&&s.res.appendChild($)}if(l.includes("animation")){if(s.options.animation&&!s.hasAnimated&&!s.options.animation.op.fireAt){console.warn(s.openTag),s.hasAnimated=!0;var q=s.options.animation.op;window.addEventListener("sidebar:open",(function(){s.res.animate(q.keyframesOpen,q.openOptions)})),window.addEventListener("sidebar:closed",(function(){s.res.animate(q.keyframesClose,q.closeOptions)})),s.res.animate(q.keyframesClose,{duration:0,fill:"forwards"}),s.openTag&&s.closeTag&&(window.addEventListener(s.openTag,(function(){s.res.animate(q.keyframesOpen,q.openOptions)})),window.addEventListener(s.closeTag,(function(){s.res.animate(q.keyframesClose,q.closeOptions)})))}if(s.options.animation&&s.options.animation.op.fireAt&&s.options.animation.op.fireAt.endsWith("px")){var J=s.options.animation.op;s.res.animate(J.keyframesClose,{duration:0,fill:"forwards"});var Q=function(){window.scrollY>parseFloat(J.fireAt)&&(s.res.animate(J.keyframesOpen,J.openOptions),window.removeEventListener("scroll",Q))};window.addEventListener("scroll",Q)}if(s.options.animation&&"inview"===s.options.animation.op.fireAt){var U=s.options.animation.op;s.res.animate(U.keyframesClose,{duration:0,fill:"forwards"});var K=!1;new IntersectionObserver((function(e,t){e.forEach((function(e){e.isIntersecting&&!K&&(K=!0,s.res.animate(U.keyframesOpen,U.openOptions),t.disconnect())}))})).observe(s.res)}}};this.options.animation||window.addEventListener("resize",(function(){return c()})),c()}},{key:"maxWidth",value:function(e){return this.res.style.maxWidth=e,this}},{key:"removeQuotesFromFirstWord",value:function(e){return e.replace(/"([^"]+)":/g,"$1:")}},{key:"arrayMargin",value:function(e,t){return e.includes("left")&&(this.res.style.marginLeft=t),e.includes("right")&&(this.res.style.marginRight=t),e.includes("top")&&(this.res.style.marginTop=t),e.includes("bottom")&&(this.res.style.marginBottom=t),e.includes("all")&&(this.res.style.margin=t),t||(this.res.style.marginBottom=e),this}}],t&&a(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}());window.Picker=h,module.exports=t})();
|
|
1
|
+
(()=>{"use strict";var e={d:(t,r)=>{for(var n in r)e.o(r,n)&&!e.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:r[n]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},t={};function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}function n(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,s,o,a=[],l=!0,c=!1;try{if(s=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=s.call(r)).done)&&(a.push(n.value),a.length!==t);l=!0);}catch(e){c=!0,i=e}finally{try{if(!l&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(c)throw i}}return a}}(e,t)||s(e,t)||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 i(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=s(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,i=function(){};return{s:i,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},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(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){l=!0,o=e},f:function(){try{a||null==r.return||r.return()}finally{if(l)throw o}}}}function s(e,t){if(e){if("string"==typeof e)return o(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?o(e,t):void 0}}function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function a(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,l(n.key),n)}}function l(e){var t=function(e){if("object"!=r(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=r(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==r(t)?t:t+""}function c(e){return c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},c(e)}function u(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,p(n.key),n)}}function p(e){var t=function(e){if("object"!=c(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=c(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==c(t)?t:t+""}function d(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(d=function(){return!!e})()}function f(e){return f=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},f(e)}function y(e,t){return y=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},y(e,t)}e.r(t),e.d(t,{Picker:()=>h});var h=function(e){function t(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(e=function(e,t,r){return t=f(t),function(e,t){if(t&&("object"==c(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,d()?Reflect.construct(t,r||[],f(e).constructor):t.apply(e,r))}(this,t)).el=null,e.file=null,e.selected="",e}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&y(e,t)}(t,e),r=t,n=[{key:"setup",value:function(e,t){document.createElement("div");var r=document.createElement("select");r.setAttribute("type","file"),r.setAttribute("name",t),r.addEventListener("change",function(){r.options[r.selectedIndex].value});for(var n=0;n<e.length;n++)r.appendChild(this.addNode(e[n][0],e[n][1]));return this.el=r,this}},{key:"set",value:function(e){return this.options=e,e.items&&this.setup(e.items,e.name),e.arrayPadding&&this.arrayPadding(e.arrayPadding.sides,e.arrayPadding.value),e.arrayMargin&&this.arrayMargin(e.arrayMargin.sides,e.arrayMargin.value),e.pad&&this.pad(e.pad),e.mar&&this.mar(e.mar),e.radius&&(this.el.style.borderRadius=e.radius),e.background&&(this.el.style.background=e.background),this}},{key:"arrayPadding",value:function(e,t){return e.includes("left")&&(this.el.style.paddingLeft=t),e.includes("right")&&(this.el.style.paddingRight=t),e.includes("top")&&(this.el.style.paddingTop=t),e.includes("bottom")&&(this.el.style.paddingBottom=t),e.includes("all")&&(this.el.style.padding=t),this}},{key:"arrayMargin",value:function(e,t){return e.includes("left")&&(this.el.style.marginLeft=t),e.includes("right")&&(this.el.style.marginRight=t),e.includes("top")&&(this.el.style.marginTop=t),e.includes("bottom")&&(this.el.style.marginBottom=t),e.includes("all")&&(this.el.style.margin=t),this}},{key:"addNode",value:function(e,t){var r=document.createElement("option");r.setAttribute("value",e);var n=document.createTextNode(t);return r.appendChild(n),r}},{key:"padding",value:function(e){return this.el.style.padding=e,this}},{key:"font",value:function(e){return this.el.style.fontFamily=e,this}},{key:"margin",value:function(e){return this.el.style.margin=e,this}},{key:"toCode",value:function(){var e=JSON.stringify(this.options,null,4);return e=e.replace(/"(\w+)"(?=\s*:)/g,"$1"),["new Picker().set(".concat(e,")")]}},{key:"rounded",value:function(e){return this.el.style.borderRadius="4px",this}},{key:"auto",value:function(){var e=this,t=function(){window.matchMedia("(max-device-width: 415px)").matches?e.el.style.fontSize="3rem":e.el.style.fontSize="1rem"};return t(),window.addEventListener("resize",t),this}},{key:"render",value:function(e){if(!e)return this.el;document.querySelector(e).appendChild(this.el)}}],n&&u(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(function(){return e=function e(){var t,r,n,i=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),t=this,n=function(e){if(console.log("LOBJO IS"),console.log(e),e.transform||e.op&&e.op.transform){var t=e.transform;e.transform||(t=e.op.transform),t.duration||(t.duration="3s-ease-in-out"),i.setDefault=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"0px";return 0===e.length?t+" ":e};var r=function(){var r="",n="",s="",o="",a="",l="",c="",u="",p="";if(0!==t.values.length){t.values.forEach(function(e){e.startsWith("tx:")&&(r=e.replace("tx:","")),e.startsWith("ty:")&&(n=e.replace("ty:","")),e.startsWith("tz:")?s=e.replace("tz:",""):e.startsWith("scale(")?o=e:e.startsWith("skew(")?a=e:e.startsWith("rotate(")?l=function(e){var t=e.match(/rotate\(([^)]+)\)/);if(!t)return e;var r=t[1].split(",").map(function(e){return e.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],")"):e}(e):e.startsWith("perspective(")?c=e:e.startsWith("matrix(")?u=e:e.startsWith("opacity:")&&(p=e.replace("opacity:",""))}),r=i.setDefault(r),n=i.setDefault(n),s=i.setDefault(s);var d="";if("0px"!=n&&"0px"!=r&&"0px"!=s?d+="translate3d(".concat(r,", ").concat(n,", ").concat(s,")"):"0px"==n&&"0px"==r||(d+="translate(".concat(r,", ").concat(n,")")),o&&(d+=" ".concat(o)),l&&(d+=" ".concat(l)),a&&(d+=" ".concat(a)),c&&(d+=" ".concat(c)),u&&(d+=" ".concat(u)),d){if(e.op.transform.duration){var f=e.op.transform.duration.replace(/^(\d+)(s)-/,function(e,t,r){return t/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";e.op.transform.static&&(i.res.style.transition=""),(i.blastTarget||i.res).style.transform=d,i.res.style.opacity=p}else alert("OPE")}};t.on?i.res.addEventListener(t.on,function(){t.delay?setTimeout(function(){r()},t.delay):r()}):window.addEventListener("load",function(){t.delay?setTimeout(function(){r()},t.delay):r()});var n=function(){var e="";t.values.forEach(function(t){t.startsWith("tx:")?e+="translateX(0) ":t.startsWith("ty:")?e+="translateY(0) ":t.startsWith("tz:")?e+="translateZ(0) ":t.startsWith("scale(")?e+="scale(1) ":t.startsWith("skew(")?e+="skew(0, 0) ":t.startsWith("rotate(")?e+="rotate(0) ":t.startsWith("perspective(")?e+="perspective(0) ":t.startsWith("matrix(")&&(e+="matrix(1, 0, 0, 1, 0, 0) "),i.res.style.opacity="1"}),e&&(i.res.style.transform=e.trim())};if(t.on)i.res.addEventListener("mouseout",function(){t.keep||n()});else{var s=1e3*parseFloat(t.duration),o=t.closeAfter?t.closeAfter:0;setTimeout(function(){t.keep||n()},s/2+o)}t.hardCSS&&(i.res.style.transform=t.hardCSS)}else alert("THIS FIRE WITH GRADIENT (invalid block"),console.log("INVALID BLOCKA"),console.log(e)},(r=l(r="reactOnTransform"))in t?Object.defineProperty(t,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[r]=n,this.state={isExpanded:!1,isMovedUp:!1,isMovedDown:!1},this.openedElements=new WeakMap},t=[{key:"isHidden",value:function(e){e&&(this.res.style.display="none")}},{key:"keySet",value:function(e){return this.temporaryVal=1,this.res.style[e.key]=e.value,this}},{key:"commonMethods",value:function(e){var t={exact:"fontSize",zIndex:"zIndex",position:"position",top:"top",cursor:"cursor",width:"width",maxWidth:"maxWidth",height:"height",maxHeight:"maxHeight",radius:"borderRadius",lineHeight:"lineHeight",background:"background",font:"fontFamily",opacity:"opacity"};for(var r in t)null!=e[r]&&(this.res.style[t[r]]=e[r]);return e.pad&&this.pad(e.pad),e.mar&&this.mar(e.mar),e.respad&&this.respad(e.respad),e.resmar&&this.resmar(e.resmar),e.hover&&this.hover(e.hover),e.size&&this.fluidCopy(e.size),e.resprop&&this.resprop(e.resprop),e.keySet&&this.keySet(e.keySet),e.hide&&this.isHidden(e.hide),e.bold?this.res.style.fontWeight="bold":null!=e.weight&&(this.res.style.fontWeight=e.weight),this}},{key:"hover",value:function(e){var t=this;if(e.border){var r=e.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,e.animation&&(this.res.style.transition="".concat(e.animation),this.res.style.transionProperty="background, color"),this.res.onmouseout=function(){t.res.style.backgroundColor="".concat(t.prevColor),t.res.style.color="".concat(t.foreColor),t.res.style.border=t.prevBorder},this.res.onmouseover=function(){if(t.res.style.color=e.color,t.res.style.backgroundColor=e.background,e.border){var r,n=e.border.width,i=null!==(r=e.border.color)&&void 0!==r?r:"#2ECC71";t.res.style.border=n?"".concat(n,"px solid ").concat(i):"1px solid #2ECC71"}},this}},{key:"onScroll",value:function(e){var t=this;"opacity"===e.value?this.res.style.opacity=e.valMin:"scale"===e.value&&(this.res.style.transform="scale(".concat(e.valMax,")")),window.addEventListener("scroll",function(){var r=t.smartRange(window.scrollY,{min:e.from,max:e.to},{min:e.valMin,max:e.valMax});"opacity"===e.value?t.res.style.opacity=r:"scale"===e.value&&(t.res.style.transform="scale(".concat(r,")"))})}},{key:"setAny",value:function(e){this[Object.keys(e)[0]]=[Object.values(e)[0]]}},{key:"setID",value:function(e){this.id=e}},{key:"setPrevText",value:function(e){this.prevText=e}},{key:"getCSS",value:function(){return this.css}},{key:"getPX",value:function(e){return{xs:"0px",sm:"576px",md:"768px",lg:"992px",xl:"1200px",xxl:"1400px",mxxl:"1800px"}[e]||"Invalid breakpoint"}},{key:"respad",value:function(e){var t=this;this._applyResponsive(e,function(e){console.log("Applying padding for",e.breakpoint),t.pad(e.values)})}},{key:"_applyResponsive",value:function(e,t){var r={default:0,xs:0,sm:576,md:768,lg:992,xl:1200,xxl:1400};e.forEach(function(e){void 0!==r[e.breakpoint]?e._value=r[e.breakpoint]:e._value=parseInt(e.breakpoint,10)}),e.sort(function(e,t){return e._value-t._value});var n=e.find(function(e){return"default"===e.breakpoint}),i=function(){for(var r=window.innerWidth,i=n||null,s=0;s<e.length;s++){var o=e[s];if("default"!==o.breakpoint&&r<=o._value){i=o;break}}i&&t(i)};this._responsiveHandler&&window.removeEventListener("resize",this._responsiveHandler),this._responsiveHandler=i,window.addEventListener("resize",i),i()}},{key:"resmar",value:function(e){var t=this;this._applyResponsive(e,function(e){console.log("Applying margin for",e.breakpoint),t.mar(e.values)})}},{key:"resprop",value:function(e){var t=this;this.prevStyles={};for(var r=0;r<this.res.style.length;r++){var n=this.res.style[r];this.prevStyles[n]=this.res.style[n]}this._applyResponsive(e,function(e){for(var r in console.log("Applying styles for",e.breakpoint),t.prevStyles)t.res.style[r]=t.prevStyles[r];for(var n in e)"breakpoint"!==n&&"_value"!==n&&"values"!==n&&(t.res.style[n]=e[n])})}},{key:"isNumber",value:function(e){return"number"==typeof e&&!isNaN(e)}},{key:"pad",value:function(e){for(var t=0;t<e.length;t++)for(var r=Object.keys(e[t]),n=0;n<r.length;n++)for(var i=r[n],s=e[t][i],o=0;o<i.length;o++)switch(i[o]){case"a":this.res.style.padding=this.isNumber(s)?"".concat(s,"px"):s;break;case"t":this.res.style.paddingTop=this.isNumber(s)?"".concat(s,"px"):s;break;case"l":this.res.style.paddingLeft=this.isNumber(s)?"".concat(s,"px"):s;break;case"r":this.res.style.paddingRight=this.isNumber(s)?"".concat(s,"px"):s;break;case"b":this.res.style.paddingBottom=this.isNumber(s)?"".concat(s,"px"):s}return this}},{key:"as",value:function(e){return this.res.style.alignSelf=e,this}},{key:"mar",value:function(e){for(var t=0;t<e.length;t++)for(var r=Object.keys(e[t]),n=0;n<r.length;n++)for(var i=r[n],s=e[t][i],o=0;o<i.length;o++){switch(i[o]){case"a":this.res.style.margin=this.isNumber(s)?"".concat(s,"px"):s;break;case"t":this.res.style.marginTop=this.isNumber(s)?"".concat(s,"px"):s;break;case"l":this.res.style.marginLeft=this.isNumber(s)?"".concat(s,"px"):s;break;case"r":this.res.style.marginRight=this.isNumber(s)?"".concat(s,"px"):s;break;case"b":this.res.style.marginBottom=this.isNumber(s)?"".concat(s,"px"):s}"auto"===i[o]&&(this.res.style.marginLeft="auto",this.res.style.marginRight="auto")}return this}},{key:"smartRange",value:function(e,t,r){e<t.min&&(e=t.min),e>t.max&&(e=t.max);var n=(e-t.min)/(t.max-t.min);t.min>t.max&&(n=(e-t.max)/(t.min-t.max));var i=(r.min-r.max)*n-r.min;if(i=Math.abs(i),r.min<r.max){var s=(r.max+Math.abs(r.min))*n;i=r.min+s}return i}},{key:"gpos",value:function(e){return this.res.style.gridColumn=e.col,this.res.style.gridRow=e.row,this}},{key:"fluidCopy",value:function(e){if(e instanceof Object){this.prevStylex=this.res.style,this.res=document.createElement("h1"),this.res.style.cssText=this.prevStylex.cssText;var t=document.createTextNode(this.text);return this.res.appendChild(t),this.res.style.fontSize=e.exact,this}if("S1"===e){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"===e){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"===e){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"===e){this.prevStylex=this.res.style,this.res=document.createElement("h4"),this.res.style.cssText=this.prevStylex.cssText;var s=document.createTextNode(this.text);this.res.appendChild(s),this.res.style.fontSize="calc(1.250rem + 2.75vw)"}if("S5"===e){this.prevStylex=this.res.style,this.res=document.createElement("h5"),this.res.style.cssText=this.prevStylex.cssText;var o=document.createTextNode(this.text);this.res.appendChild(o),this.res.style.fontSize="calc(1.125rem + 1.975vw)"}return"S6"===e&&(this.res.style.fontSize="calc(1rem + 0.5vw)"),this}},{key:"setIndex",value:function(e){this.index=e}},{key:"borderObj",value:function(e){var t,r=null!==(t=e.type)&&void 0!==t?t:"solid";return this.res.style.border="".concat(e.width," ").concat(r," ").concat(e.color),this.res.style.borderRadius=e.radius,this}},{key:"setPref",value:function(e){this.preffersId=e}},{key:"setClass",value:function(e){this.class=e}},{key:"setTags",value:function(e){this.openTag=e.open,this.closeTag=e.close,console.log("TAGS SET"),console.log(e)}},{key:"chainReact",value:function(e,t,r){var s=this;console.log("0P"),this.ap=!1,this.cta=0,this.once=!1;var o,a=i(e);try{for(a.s();!(o=a.n()).done;){var l=o.value;l.range||(l.range=["0px","999999px"])}}catch(e){a.e(e)}finally{a.f()}e.sort(function(e,t){return parseInt(e.range[0])-parseInt(t.range[0])});var c=function(o){var a=window.visualViewport.width,l=[],c=[];s.resCopy=s.res,s.storedQueries=e.map(function(e){return e.target}).filter(function(e){return null!=e});var u,p=i(e);try{for(p.s();!(u=p.n()).done;){var d=u.value;s.counterIndex++;var f=n(d.range,2),y=f[0],h=f[1],v=parseInt(y),m=parseInt(h),g=!0;if(d.target){g=!1;for(var b=0;b<d.target.length;b++)d.target[b]===t&&(g=!0)}a>=v&&a<=m&&g&&(l.push(d.log),c.push(d),d.op&&d.op.margin&&(s.useMargin=d.op.margin))}}catch(e){p.e(e)}finally{p.f()}if(r&&!r.includes("background")&&(s.res.style.background="",s.res.style.backgroundColor=""),s.res.style.textShadow="",r&&!r.includes("border")&&(s.res.style.border=""),r&&!r.includes("margin")&&(s.res.style.margin=""),s.res.style["-webkit-text-fill-color"]="",s.res.style["-webkit-text-stroke-color"]="",s.res.style["-webkit-text-stroke-width"]="",s.res.style.filter="",s.options.background&&(console.log(s.options.background),s.res.style.background=s.options.background),l.includes("gradient"),(l.includes("gradient")||l.includes("shadow"))&&(s.res.style.position="relative"),l.includes("blast")){var x,k=c.filter(function(e){return"blast"===e.log})[0].op.color,w=null!==(x=c.filter(function(e){return"blast"===e.log})[0].op.width)&&void 0!==x?x:"1px";"FlexRowLayoutElement"===s.getType()||"LayoutWrapperElement"===s.getType()?(s.res.style.border="".concat("number"==typeof w?w+"px":w," solid orange"),s.res.style.display="inline-block","FlexRowLayoutElement"===s.getType()&&(s.res.style.display="flex"),s.res.style.boxSizing="border-box",s.res.style.transformOrigin="center",s.blastTarget=s.res):(s.text,s.res.style["-webkit-text-fill-color"]="transparent",s.res.style["-webkit-text-stroke-color"]=k,s.res.style["-webkit-text-stroke-width"]="".concat(w))}if(l.includes("filter")){var S=c.filter(function(e){return"filter"===e.log})[0].op.filter;s.res.style.filter=S}if(l.includes("background")&&(s.res.style.backgroundColor="green"),l.includes("gradient")&&("LayoutWrapperElement"!==s.getType()&&"FlexRowLayoutElement"!==s.getType()&&(s.res.style["-webkit-text-fill-color"]="transparent"),s.res.style.background=s.globalGradient,"LayoutWrapperElement"!==s.getType()&&"FlexRowLayoutElement"!==s.getType()&&(s.res.style["background-clip"]="text")),l.includes("shadow")){var T,E,O,C,j=s.options.shadow.op;console.log("OP IS",j);var P=null!==(T=j.steps)&&void 0!==T?T:1,W=null!==(E=j.colors)&&void 0!==E?E:["gray"],A=null!==(O=j.movements)&&void 0!==O?O:["3px","3px"],L=null!==(C=j.radius)&&void 0!==C?C:"3px";if(1===A.length&&(A=[A[0],A[0]]),"FlexRowLayoutElement"===s.getType()||"LayoutWrapperElement"===s.getType()){for(var I=[],R=0;R<P;R++){var N,_=null!==(N=W[R])&&void 0!==N?N:W[0],z=A[0],M=A[1];I.push("".concat(z," ").concat(M," ").concat(L," ").concat(_))}s.res.style.boxShadow=I.join(", ")}else{for(var B=[],F=0;F<P;F++){var H,D=null!==(H=W[F])&&void 0!==H?H:W[0],Y=A[0],X=A[1];B.push("drop-shadow(".concat(Y," ").concat(X," ").concat(L," ").concat(D,")"))}s.res.style.filter=B.join(" ")}}if(l.includes("margin"))for(b=0;b<e.length;b++)if(e[b].op){var G=e[b].op.offsets;G&&void 0!==s.index&&(s.res.style.margin=G[Number(s.index)]+"px")}if(l.includes("spana")||l.includes("span")){var V=document.createElement("div");if(V.setAttribute("id","oroa"),Object.assign(V.style,{position:"absolute",inset:"0",background:"linear-gradient(90deg, rgb(52,152,219), rgb(26,188,156))",WebkitBackgroundClip:"text",WebkitTextFillColor:"transparent",pointerEvents:"none"}),s.res&&s.res.querySelector("span"))return;s.res=s.resCopy,s.res.textContent="",s.options.span&&(Array.isArray(s.options.span)?s.options.span:[s.options.span]).forEach(function(e){if(e.op&&"span"===e.op.name&&Array.isArray(e.op.parts)){var t=0,r=s.prevText||"";if(e.op.parts.forEach(function(e){var n=e.text,i=e.style||{};if(t<r.length){var o=r.indexOf(n,t);if(o>t){var a=r.substring(t,o);s.res.appendChild(new s.constructor(a).setup({type:"span",id:i.id,animation:i.animation}).set({}).render())}t=o+n.length}var l=new s.constructor(n).setup({type:"span",id:i.id,animation:i.animation}).set(i).render();s.res.appendChild(l)}),t<r.length){var n=r.substring(t);s.res.appendChild(new s.constructor(n).setup({type:"span"}).set({}).render())}}})}else{var $=new s.constructor(s.prevText).set({}).render();s.prevText&&s.prevText.length>0&&o&&s.res.appendChild($)}if(l.includes("animation")){if(s.options.animation&&!s.hasAnimated&&!s.options.animation.op.fireAt){console.warn(s.openTag),s.hasAnimated=!0;var q=s.options.animation.op;window.addEventListener("sidebar:open",function(){s.res.animate(q.keyframesOpen,q.openOptions)}),window.addEventListener("sidebar:closed",function(){s.res.animate(q.keyframesClose,q.closeOptions)}),s.res.animate(q.keyframesClose,{duration:0,fill:"forwards"}),s.openTag&&s.closeTag&&(window.addEventListener(s.openTag,function(){s.res.animate(q.keyframesOpen,q.openOptions)}),window.addEventListener(s.closeTag,function(){s.res.animate(q.keyframesClose,q.closeOptions)}))}if(s.options.animation&&s.options.animation.op.fireAt&&s.options.animation.op.fireAt.endsWith("px")){var J=s.options.animation.op;s.res.animate(J.keyframesClose,{duration:0,fill:"forwards"});var Q=function(){window.scrollY>parseFloat(J.fireAt)&&(s.res.animate(J.keyframesOpen,J.openOptions),window.removeEventListener("scroll",Q))};window.addEventListener("scroll",Q)}if(s.options.animation&&"inview"===s.options.animation.op.fireAt){var U=s.options.animation.op;s.res.animate(U.keyframesClose,{duration:0,fill:"forwards"});var K=!1;new IntersectionObserver(function(e,t){e.forEach(function(e){e.isIntersecting&&!K&&(K=!0,s.res.animate(U.keyframesOpen,U.openOptions),t.disconnect())})}).observe(s.res)}}};this.options.animation||window.addEventListener("resize",function(){return c()}),c()}},{key:"maxWidth",value:function(e){return this.res.style.maxWidth=e,this}},{key:"removeQuotesFromFirstWord",value:function(e){return e.replace(/"([^"]+)":/g,"$1:")}},{key:"arrayMargin",value:function(e,t){return e.includes("left")&&(this.res.style.marginLeft=t),e.includes("right")&&(this.res.style.marginRight=t),e.includes("top")&&(this.res.style.marginTop=t),e.includes("bottom")&&(this.res.style.marginBottom=t),e.includes("all")&&(this.res.style.margin=t),t||(this.res.style.marginBottom=e),this}}],t&&a(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}());window.Picker=h,module.exports=t})();
|
package/dist/picker.esm.js
CHANGED
|
@@ -1,2 +1 @@
|
|
|
1
|
-
/*! For license information please see picker.esm.js.LICENSE.txt */
|
|
2
|
-
function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e(t)}function t(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,s,o,a=[],l=!0,c=!1;try{if(s=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=s.call(r)).done)&&(a.push(n.value),a.length!==t);l=!0);}catch(e){c=!0,i=e}finally{try{if(!l&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(c)throw i}}return a}}(e,t)||n(e,t)||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 r(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=n(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var i=0,s=function(){};return{s,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:s}}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(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){l=!0,o=e},f:function(){try{a||null==r.return||r.return()}finally{if(l)throw o}}}}function n(e,t){if(e){if("string"==typeof e)return i(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?i(e,t):void 0}}function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function s(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,o(n.key),n)}}function o(t){var r=function(t){if("object"!=e(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,"string");if("object"!=e(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==e(r)?r:r+""}var a=function(){return e=function e(){var t,r,n,i=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),t=this,n=function(e){if(console.log("LOBJO IS"),console.log(e),e.transform||e.op&&e.op.transform){var t=e.transform;e.transform||(t=e.op.transform),t.duration||(t.duration="3s-ease-in-out"),i.setDefault=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"0px";return 0===e.length?t+" ":e};var r=function(){var r="",n="",s="",o="",a="",l="",c="",u="",p="";if(0!==t.values.length){t.values.forEach((function(e){e.startsWith("tx:")&&(r=e.replace("tx:","")),e.startsWith("ty:")&&(n=e.replace("ty:","")),e.startsWith("tz:")?s=e.replace("tz:",""):e.startsWith("scale(")?o=e:e.startsWith("skew(")?a=e:e.startsWith("rotate(")?l=function(e){var t=e.match(/rotate\(([^)]+)\)/);if(!t)return e;var r=t[1].split(",").map((function(e){return e.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],")"):e}(e):e.startsWith("perspective(")?c=e:e.startsWith("matrix(")?u=e:e.startsWith("opacity:")&&(p=e.replace("opacity:",""))})),r=i.setDefault(r),n=i.setDefault(n),s=i.setDefault(s);var d="";if("0px"!=n&&"0px"!=r&&"0px"!=s?d+="translate3d(".concat(r,", ").concat(n,", ").concat(s,")"):"0px"==n&&"0px"==r||(d+="translate(".concat(r,", ").concat(n,")")),o&&(d+=" ".concat(o)),l&&(d+=" ".concat(l)),a&&(d+=" ".concat(a)),c&&(d+=" ".concat(c)),u&&(d+=" ".concat(u)),d){if(e.op.transform.duration){var f=e.op.transform.duration.replace(/^(\d+)(s)-/,(function(e,t,r){return t/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";e.op.transform.static&&(i.res.style.transition=""),(i.blastTarget||i.res).style.transform=d,i.res.style.opacity=p}else alert("OPE")}};t.on?i.res.addEventListener(t.on,(function(){t.delay?setTimeout((function(){r()}),t.delay):r()})):window.addEventListener("load",(function(){t.delay?setTimeout((function(){r()}),t.delay):r()}));var n=function(){var e="";t.values.forEach((function(t){t.startsWith("tx:")?e+="translateX(0) ":t.startsWith("ty:")?e+="translateY(0) ":t.startsWith("tz:")?e+="translateZ(0) ":t.startsWith("scale(")?e+="scale(1) ":t.startsWith("skew(")?e+="skew(0, 0) ":t.startsWith("rotate(")?e+="rotate(0) ":t.startsWith("perspective(")?e+="perspective(0) ":t.startsWith("matrix(")&&(e+="matrix(1, 0, 0, 1, 0, 0) "),i.res.style.opacity="1"})),e&&(i.res.style.transform=e.trim())};if(t.on)i.res.addEventListener("mouseout",(function(){t.keep||n()}));else{var s=1e3*parseFloat(t.duration),o=t.closeAfter?t.closeAfter:0;setTimeout((function(){t.keep||n()}),s/2+o)}t.hardCSS&&(i.res.style.transform=t.hardCSS)}else alert("THIS FIRE WITH GRADIENT (invalid block"),console.log("INVALID BLOCKA"),console.log(e)},(r=o(r="reactOnTransform"))in t?Object.defineProperty(t,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[r]=n,this.state={isExpanded:!1,isMovedUp:!1,isMovedDown:!1},this.openedElements=new WeakMap},n=[{key:"isHidden",value:function(e){e&&(this.res.style.display="none")}},{key:"keySet",value:function(e){return this.temporaryVal=1,this.res.style[e.key]=e.value,this}},{key:"commonMethods",value:function(e){var t={exact:"fontSize",zIndex:"zIndex",position:"position",top:"top",cursor:"cursor",width:"width",maxWidth:"maxWidth",height:"height",maxHeight:"maxHeight",radius:"borderRadius",lineHeight:"lineHeight",background:"background",font:"fontFamily",opacity:"opacity"};for(var r in t)null!=e[r]&&(this.res.style[t[r]]=e[r]);return e.pad&&this.pad(e.pad),e.mar&&this.mar(e.mar),e.respad&&this.respad(e.respad),e.resmar&&this.resmar(e.resmar),e.hover&&this.hover(e.hover),e.size&&this.fluidCopy(e.size),e.resprop&&this.resprop(e.resprop),e.keySet&&this.keySet(e.keySet),e.hide&&this.isHidden(e.hide),e.bold?this.res.style.fontWeight="bold":null!=e.weight&&(this.res.style.fontWeight=e.weight),this}},{key:"hover",value:function(e){var t=this;if(e.border){var r=e.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,e.animation&&(this.res.style.transition="".concat(e.animation),this.res.style.transionProperty="background, color"),this.res.onmouseout=function(){t.res.style.backgroundColor="".concat(t.prevColor),t.res.style.color="".concat(t.foreColor),t.res.style.border=t.prevBorder},this.res.onmouseover=function(){if(t.res.style.color=e.color,t.res.style.backgroundColor=e.background,e.border){var r,n=e.border.width,i=null!==(r=e.border.color)&&void 0!==r?r:"#2ECC71";t.res.style.border=n?"".concat(n,"px solid ").concat(i):"1px solid #2ECC71"}},this}},{key:"onScroll",value:function(e){var t=this;"opacity"===e.value?this.res.style.opacity=e.valMin:"scale"===e.value&&(this.res.style.transform="scale(".concat(e.valMax,")")),window.addEventListener("scroll",(function(){var r=t.smartRange(window.scrollY,{min:e.from,max:e.to},{min:e.valMin,max:e.valMax});"opacity"===e.value?t.res.style.opacity=r:"scale"===e.value&&(t.res.style.transform="scale(".concat(r,")"))}))}},{key:"setAny",value:function(e){this[Object.keys(e)[0]]=[Object.values(e)[0]]}},{key:"setID",value:function(e){this.id=e}},{key:"setPrevText",value:function(e){this.prevText=e}},{key:"getCSS",value:function(){return this.css}},{key:"getPX",value:function(e){return{xs:"0px",sm:"576px",md:"768px",lg:"992px",xl:"1200px",xxl:"1400px",mxxl:"1800px"}[e]||"Invalid breakpoint"}},{key:"respad",value:function(e){var t=this;this._applyResponsive(e,(function(e){console.log("Applying padding for",e.breakpoint),t.pad(e.values)}))}},{key:"_applyResponsive",value:function(e,t){var r={default:0,xs:0,sm:576,md:768,lg:992,xl:1200,xxl:1400};e.forEach((function(e){void 0!==r[e.breakpoint]?e._value=r[e.breakpoint]:e._value=parseInt(e.breakpoint,10)})),e.sort((function(e,t){return e._value-t._value}));var n=e.find((function(e){return"default"===e.breakpoint})),i=function(){for(var r=window.innerWidth,i=n||null,s=0;s<e.length;s++){var o=e[s];if("default"!==o.breakpoint&&r<=o._value){i=o;break}}i&&t(i)};this._responsiveHandler&&window.removeEventListener("resize",this._responsiveHandler),this._responsiveHandler=i,window.addEventListener("resize",i),i()}},{key:"resmar",value:function(e){var t=this;this._applyResponsive(e,(function(e){console.log("Applying margin for",e.breakpoint),t.mar(e.values)}))}},{key:"resprop",value:function(e){var t=this;this.prevStyles={};for(var r=0;r<this.res.style.length;r++){var n=this.res.style[r];this.prevStyles[n]=this.res.style[n]}this._applyResponsive(e,(function(e){for(var r in console.log("Applying styles for",e.breakpoint),t.prevStyles)t.res.style[r]=t.prevStyles[r];for(var n in e)"breakpoint"!==n&&"_value"!==n&&"values"!==n&&(t.res.style[n]=e[n])}))}},{key:"isNumber",value:function(e){return"number"==typeof e&&!isNaN(e)}},{key:"pad",value:function(e){for(var t=0;t<e.length;t++)for(var r=Object.keys(e[t]),n=0;n<r.length;n++)for(var i=r[n],s=e[t][i],o=0;o<i.length;o++)switch(i[o]){case"a":this.res.style.padding=this.isNumber(s)?"".concat(s,"px"):s;break;case"t":this.res.style.paddingTop=this.isNumber(s)?"".concat(s,"px"):s;break;case"l":this.res.style.paddingLeft=this.isNumber(s)?"".concat(s,"px"):s;break;case"r":this.res.style.paddingRight=this.isNumber(s)?"".concat(s,"px"):s;break;case"b":this.res.style.paddingBottom=this.isNumber(s)?"".concat(s,"px"):s}return this}},{key:"as",value:function(e){return this.res.style.alignSelf=e,this}},{key:"mar",value:function(e){for(var t=0;t<e.length;t++)for(var r=Object.keys(e[t]),n=0;n<r.length;n++)for(var i=r[n],s=e[t][i],o=0;o<i.length;o++){switch(i[o]){case"a":this.res.style.margin=this.isNumber(s)?"".concat(s,"px"):s;break;case"t":this.res.style.marginTop=this.isNumber(s)?"".concat(s,"px"):s;break;case"l":this.res.style.marginLeft=this.isNumber(s)?"".concat(s,"px"):s;break;case"r":this.res.style.marginRight=this.isNumber(s)?"".concat(s,"px"):s;break;case"b":this.res.style.marginBottom=this.isNumber(s)?"".concat(s,"px"):s}"auto"===i[o]&&(this.res.style.marginLeft="auto",this.res.style.marginRight="auto")}return this}},{key:"smartRange",value:function(e,t,r){e<t.min&&(e=t.min),e>t.max&&(e=t.max);var n=(e-t.min)/(t.max-t.min);t.min>t.max&&(n=(e-t.max)/(t.min-t.max));var i=(r.min-r.max)*n-r.min;if(i=Math.abs(i),r.min<r.max){var s=(r.max+Math.abs(r.min))*n;i=r.min+s}return i}},{key:"gpos",value:function(e){return this.res.style.gridColumn=e.col,this.res.style.gridRow=e.row,this}},{key:"fluidCopy",value:function(e){if(e instanceof Object){this.prevStylex=this.res.style,this.res=document.createElement("h1"),this.res.style.cssText=this.prevStylex.cssText;var t=document.createTextNode(this.text);return this.res.appendChild(t),this.res.style.fontSize=e.exact,this}if("S1"===e){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"===e){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"===e){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"===e){this.prevStylex=this.res.style,this.res=document.createElement("h4"),this.res.style.cssText=this.prevStylex.cssText;var s=document.createTextNode(this.text);this.res.appendChild(s),this.res.style.fontSize="calc(1.250rem + 2.75vw)"}if("S5"===e){this.prevStylex=this.res.style,this.res=document.createElement("h5"),this.res.style.cssText=this.prevStylex.cssText;var o=document.createTextNode(this.text);this.res.appendChild(o),this.res.style.fontSize="calc(1.125rem + 1.975vw)"}return"S6"===e&&(this.res.style.fontSize="calc(1rem + 0.5vw)"),this}},{key:"setIndex",value:function(e){this.index=e}},{key:"borderObj",value:function(e){var t,r=null!==(t=e.type)&&void 0!==t?t:"solid";return this.res.style.border="".concat(e.width," ").concat(r," ").concat(e.color),this.res.style.borderRadius=e.radius,this}},{key:"setPref",value:function(e){this.preffersId=e}},{key:"setClass",value:function(e){this.class=e}},{key:"setTags",value:function(e){this.openTag=e.open,this.closeTag=e.close,console.log("TAGS SET"),console.log(e)}},{key:"chainReact",value:function(e,n,i){var s=this;console.log("0P"),this.ap=!1,this.cta=0,this.once=!1;var o,a=r(e);try{for(a.s();!(o=a.n()).done;){var l=o.value;l.range||(l.range=["0px","999999px"])}}catch(e){a.e(e)}finally{a.f()}e.sort((function(e,t){return parseInt(e.range[0])-parseInt(t.range[0])}));var c=function(o){var a=window.visualViewport.width,l=[],c=[];s.resCopy=s.res,s.storedQueries=e.map((function(e){return e.target})).filter((function(e){return null!=e}));var u,p=r(e);try{for(p.s();!(u=p.n()).done;){var d=u.value;s.counterIndex++;var f=t(d.range,2),y=f[0],h=f[1],v=parseInt(y),m=parseInt(h),g=!0;if(d.target){g=!1;for(var b=0;b<d.target.length;b++)d.target[b]===n&&(g=!0)}a>=v&&a<=m&&g&&(l.push(d.log),c.push(d),d.op&&d.op.margin&&(s.useMargin=d.op.margin))}}catch(e){p.e(e)}finally{p.f()}if(i&&!i.includes("background")&&(s.res.style.background="",s.res.style.backgroundColor=""),s.res.style.textShadow="",i&&!i.includes("border")&&(s.res.style.border=""),i&&!i.includes("margin")&&(s.res.style.margin=""),s.res.style["-webkit-text-fill-color"]="",s.res.style["-webkit-text-stroke-color"]="",s.res.style["-webkit-text-stroke-width"]="",s.res.style.filter="",s.options.background&&(console.log(s.options.background),s.res.style.background=s.options.background),l.includes("gradient"),(l.includes("gradient")||l.includes("shadow"))&&(s.res.style.position="relative"),l.includes("blast")){var x,k=c.filter((function(e){return"blast"===e.log}))[0].op.color,w=null!==(x=c.filter((function(e){return"blast"===e.log}))[0].op.width)&&void 0!==x?x:"1px";"FlexRowLayoutElement"===s.getType()||"LayoutWrapperElement"===s.getType()?(s.res.style.border="".concat("number"==typeof w?w+"px":w," solid orange"),s.res.style.display="inline-block","FlexRowLayoutElement"===s.getType()&&(s.res.style.display="flex"),s.res.style.boxSizing="border-box",s.res.style.transformOrigin="center",s.blastTarget=s.res):(s.text,s.res.style["-webkit-text-fill-color"]="transparent",s.res.style["-webkit-text-stroke-color"]=k,s.res.style["-webkit-text-stroke-width"]="".concat(w))}if(l.includes("filter")){var S=c.filter((function(e){return"filter"===e.log}))[0].op.filter;s.res.style.filter=S}if(l.includes("background")&&(s.res.style.backgroundColor="green"),l.includes("gradient")&&("LayoutWrapperElement"!==s.getType()&&"FlexRowLayoutElement"!==s.getType()&&(s.res.style["-webkit-text-fill-color"]="transparent"),s.res.style.background=s.globalGradient,"LayoutWrapperElement"!==s.getType()&&"FlexRowLayoutElement"!==s.getType()&&(s.res.style["background-clip"]="text")),l.includes("shadow")){var T,E,O,C,W=s.options.shadow.op;console.log("OP IS",W);var j=null!==(T=W.steps)&&void 0!==T?T:1,A=null!==(E=W.colors)&&void 0!==E?E:["gray"],L=null!==(O=W.movements)&&void 0!==O?O:["3px","3px"],P=null!==(C=W.radius)&&void 0!==C?C:"3px";if(1===L.length&&(L=[L[0],L[0]]),"FlexRowLayoutElement"===s.getType()||"LayoutWrapperElement"===s.getType()){for(var I=[],R=0;R<j;R++){var N,z=null!==(N=A[R])&&void 0!==N?N:A[0],_=L[0],M=L[1];I.push("".concat(_," ").concat(M," ").concat(P," ").concat(z))}s.res.style.boxShadow=I.join(", ")}else{for(var B=[],F=0;F<j;F++){var H,D=null!==(H=A[F])&&void 0!==H?H:A[0],Y=L[0],X=L[1];B.push("drop-shadow(".concat(Y," ").concat(X," ").concat(P," ").concat(D,")"))}s.res.style.filter=B.join(" ")}}if(l.includes("margin"))for(b=0;b<e.length;b++)if(e[b].op){var G=e[b].op.offsets;G&&void 0!==s.index&&(s.res.style.margin=G[Number(s.index)]+"px")}if(l.includes("spana")||l.includes("span")){var V=document.createElement("div");if(V.setAttribute("id","oroa"),Object.assign(V.style,{position:"absolute",inset:"0",background:"linear-gradient(90deg, rgb(52,152,219), rgb(26,188,156))",WebkitBackgroundClip:"text",WebkitTextFillColor:"transparent",pointerEvents:"none"}),s.res&&s.res.querySelector("span"))return;s.res=s.resCopy,s.res.textContent="",s.options.span&&(Array.isArray(s.options.span)?s.options.span:[s.options.span]).forEach((function(e){if(e.op&&"span"===e.op.name&&Array.isArray(e.op.parts)){var t=0,r=s.prevText||"";if(e.op.parts.forEach((function(e){var n=e.text,i=e.style||{};if(t<r.length){var o=r.indexOf(n,t);if(o>t){var a=r.substring(t,o);s.res.appendChild(new s.constructor(a).setup({type:"span",id:i.id,animation:i.animation}).set({}).render())}t=o+n.length}var l=new s.constructor(n).setup({type:"span",id:i.id,animation:i.animation}).set(i).render();s.res.appendChild(l)})),t<r.length){var n=r.substring(t);s.res.appendChild(new s.constructor(n).setup({type:"span"}).set({}).render())}}}))}else{var $=new s.constructor(s.prevText).set({}).render();s.prevText&&s.prevText.length>0&&o&&s.res.appendChild($)}if(l.includes("animation")){if(s.options.animation&&!s.hasAnimated&&!s.options.animation.op.fireAt){console.warn(s.openTag),s.hasAnimated=!0;var q=s.options.animation.op;window.addEventListener("sidebar:open",(function(){s.res.animate(q.keyframesOpen,q.openOptions)})),window.addEventListener("sidebar:closed",(function(){s.res.animate(q.keyframesClose,q.closeOptions)})),s.res.animate(q.keyframesClose,{duration:0,fill:"forwards"}),s.openTag&&s.closeTag&&(window.addEventListener(s.openTag,(function(){s.res.animate(q.keyframesOpen,q.openOptions)})),window.addEventListener(s.closeTag,(function(){s.res.animate(q.keyframesClose,q.closeOptions)})))}if(s.options.animation&&s.options.animation.op.fireAt&&s.options.animation.op.fireAt.endsWith("px")){var J=s.options.animation.op;s.res.animate(J.keyframesClose,{duration:0,fill:"forwards"});var Q=function(){window.scrollY>parseFloat(J.fireAt)&&(s.res.animate(J.keyframesOpen,J.openOptions),window.removeEventListener("scroll",Q))};window.addEventListener("scroll",Q)}if(s.options.animation&&"inview"===s.options.animation.op.fireAt){var U=s.options.animation.op;s.res.animate(U.keyframesClose,{duration:0,fill:"forwards"});var K=!1;new IntersectionObserver((function(e,t){e.forEach((function(e){e.isIntersecting&&!K&&(K=!0,s.res.animate(U.keyframesOpen,U.openOptions),t.disconnect())}))})).observe(s.res)}}};this.options.animation||window.addEventListener("resize",(function(){return c()})),c()}},{key:"maxWidth",value:function(e){return this.res.style.maxWidth=e,this}},{key:"removeQuotesFromFirstWord",value:function(e){return e.replace(/"([^"]+)":/g,"$1:")}},{key:"arrayMargin",value:function(e,t){return e.includes("left")&&(this.res.style.marginLeft=t),e.includes("right")&&(this.res.style.marginRight=t),e.includes("top")&&(this.res.style.marginTop=t),e.includes("bottom")&&(this.res.style.marginBottom=t),e.includes("all")&&(this.res.style.margin=t),t||(this.res.style.marginBottom=e),this}}],n&&s(e.prototype,n),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,n}();function l(e){return l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},l(e)}function c(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,u(n.key),n)}}function u(e){var t=function(e){if("object"!=l(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=l(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==l(t)?t:t+""}function p(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(p=function(){return!!e})()}function d(e){return d=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},d(e)}function f(e,t){return f=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},f(e,t)}var y=function(){function e(){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),(t=function(e,t,r){return t=d(t),function(e,t){if(t&&("object"==l(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,p()?Reflect.construct(t,r||[],d(e).constructor):t.apply(e,r))}(this,e)).el=null,t.file=null,t.selected="",t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&f(e,t)}(e,a),t=e,r=[{key:"setup",value:function(e,t){document.createElement("div");var r=document.createElement("select");r.setAttribute("type","file"),r.setAttribute("name",t),r.addEventListener("change",(function(){r.options[r.selectedIndex].value}));for(var n=0;n<e.length;n++)r.appendChild(this.addNode(e[n][0],e[n][1]));return this.el=r,this}},{key:"set",value:function(e){return this.options=e,e.items&&this.setup(e.items,e.name),e.arrayPadding&&this.arrayPadding(e.arrayPadding.sides,e.arrayPadding.value),e.arrayMargin&&this.arrayMargin(e.arrayMargin.sides,e.arrayMargin.value),e.pad&&this.pad(e.pad),e.mar&&this.mar(e.mar),e.radius&&(this.el.style.borderRadius=e.radius),e.background&&(this.el.style.background=e.background),this}},{key:"arrayPadding",value:function(e,t){return e.includes("left")&&(this.el.style.paddingLeft=t),e.includes("right")&&(this.el.style.paddingRight=t),e.includes("top")&&(this.el.style.paddingTop=t),e.includes("bottom")&&(this.el.style.paddingBottom=t),e.includes("all")&&(this.el.style.padding=t),this}},{key:"arrayMargin",value:function(e,t){return e.includes("left")&&(this.el.style.marginLeft=t),e.includes("right")&&(this.el.style.marginRight=t),e.includes("top")&&(this.el.style.marginTop=t),e.includes("bottom")&&(this.el.style.marginBottom=t),e.includes("all")&&(this.el.style.margin=t),this}},{key:"addNode",value:function(e,t){var r=document.createElement("option");r.setAttribute("value",e);var n=document.createTextNode(t);return r.appendChild(n),r}},{key:"padding",value:function(e){return this.el.style.padding=e,this}},{key:"font",value:function(e){return this.el.style.fontFamily=e,this}},{key:"margin",value:function(e){return this.el.style.margin=e,this}},{key:"toCode",value:function(){var e=JSON.stringify(this.options,null,4);return e=e.replace(/"(\w+)"(?=\s*:)/g,"$1"),["new Picker().set(".concat(e,")")]}},{key:"rounded",value:function(e){return this.el.style.borderRadius="4px",this}},{key:"auto",value:function(){var e=this,t=function(){window.matchMedia("(max-device-width: 415px)").matches?e.el.style.fontSize="3rem":e.el.style.fontSize="1rem"};return t(),window.addEventListener("resize",t),this}},{key:"render",value:function(e){if(!e)return this.el;document.querySelector(e).appendChild(this.el)}}],r&&c(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,r}();window.Picker=y;export{y as Picker};
|
|
1
|
+
var e={};function t(e){return t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},t(e)}function r(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,s,o,a=[],l=!0,c=!1;try{if(s=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=s.call(r)).done)&&(a.push(n.value),a.length!==t);l=!0);}catch(e){c=!0,i=e}finally{try{if(!l&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(c)throw i}}return a}}(e,t)||i(e,t)||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 n(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=i(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,s=function(){};return{s,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:s}}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(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){l=!0,o=e},f:function(){try{a||null==r.return||r.return()}finally{if(l)throw o}}}}function i(e,t){if(e){if("string"==typeof e)return s(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?s(e,t):void 0}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function o(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,a(n.key),n)}}function a(e){var r=function(e){if("object"!=t(e)||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,"string");if("object"!=t(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==t(r)?r:r+""}e.d=(t,r)=>{for(var n in r)e.o(r,n)&&!e.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:r[n]})},e.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var l=function(){return e=function e(){var t,r,n,i=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),t=this,n=function(e){if(console.log("LOBJO IS"),console.log(e),e.transform||e.op&&e.op.transform){var t=e.transform;e.transform||(t=e.op.transform),t.duration||(t.duration="3s-ease-in-out"),i.setDefault=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"0px";return 0===e.length?t+" ":e};var r=function(){var r="",n="",s="",o="",a="",l="",c="",u="",p="";if(0!==t.values.length){t.values.forEach(function(e){e.startsWith("tx:")&&(r=e.replace("tx:","")),e.startsWith("ty:")&&(n=e.replace("ty:","")),e.startsWith("tz:")?s=e.replace("tz:",""):e.startsWith("scale(")?o=e:e.startsWith("skew(")?a=e:e.startsWith("rotate(")?l=function(e){var t=e.match(/rotate\(([^)]+)\)/);if(!t)return e;var r=t[1].split(",").map(function(e){return e.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],")"):e}(e):e.startsWith("perspective(")?c=e:e.startsWith("matrix(")?u=e:e.startsWith("opacity:")&&(p=e.replace("opacity:",""))}),r=i.setDefault(r),n=i.setDefault(n),s=i.setDefault(s);var d="";if("0px"!=n&&"0px"!=r&&"0px"!=s?d+="translate3d(".concat(r,", ").concat(n,", ").concat(s,")"):"0px"==n&&"0px"==r||(d+="translate(".concat(r,", ").concat(n,")")),o&&(d+=" ".concat(o)),l&&(d+=" ".concat(l)),a&&(d+=" ".concat(a)),c&&(d+=" ".concat(c)),u&&(d+=" ".concat(u)),d){if(e.op.transform.duration){var f=e.op.transform.duration.replace(/^(\d+)(s)-/,function(e,t,r){return t/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";e.op.transform.static&&(i.res.style.transition=""),(i.blastTarget||i.res).style.transform=d,i.res.style.opacity=p}else alert("OPE")}};t.on?i.res.addEventListener(t.on,function(){t.delay?setTimeout(function(){r()},t.delay):r()}):window.addEventListener("load",function(){t.delay?setTimeout(function(){r()},t.delay):r()});var n=function(){var e="";t.values.forEach(function(t){t.startsWith("tx:")?e+="translateX(0) ":t.startsWith("ty:")?e+="translateY(0) ":t.startsWith("tz:")?e+="translateZ(0) ":t.startsWith("scale(")?e+="scale(1) ":t.startsWith("skew(")?e+="skew(0, 0) ":t.startsWith("rotate(")?e+="rotate(0) ":t.startsWith("perspective(")?e+="perspective(0) ":t.startsWith("matrix(")&&(e+="matrix(1, 0, 0, 1, 0, 0) "),i.res.style.opacity="1"}),e&&(i.res.style.transform=e.trim())};if(t.on)i.res.addEventListener("mouseout",function(){t.keep||n()});else{var s=1e3*parseFloat(t.duration),o=t.closeAfter?t.closeAfter:0;setTimeout(function(){t.keep||n()},s/2+o)}t.hardCSS&&(i.res.style.transform=t.hardCSS)}else alert("THIS FIRE WITH GRADIENT (invalid block"),console.log("INVALID BLOCKA"),console.log(e)},(r=a(r="reactOnTransform"))in t?Object.defineProperty(t,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[r]=n,this.state={isExpanded:!1,isMovedUp:!1,isMovedDown:!1},this.openedElements=new WeakMap},t=[{key:"isHidden",value:function(e){e&&(this.res.style.display="none")}},{key:"keySet",value:function(e){return this.temporaryVal=1,this.res.style[e.key]=e.value,this}},{key:"commonMethods",value:function(e){var t={exact:"fontSize",zIndex:"zIndex",position:"position",top:"top",cursor:"cursor",width:"width",maxWidth:"maxWidth",height:"height",maxHeight:"maxHeight",radius:"borderRadius",lineHeight:"lineHeight",background:"background",font:"fontFamily",opacity:"opacity"};for(var r in t)null!=e[r]&&(this.res.style[t[r]]=e[r]);return e.pad&&this.pad(e.pad),e.mar&&this.mar(e.mar),e.respad&&this.respad(e.respad),e.resmar&&this.resmar(e.resmar),e.hover&&this.hover(e.hover),e.size&&this.fluidCopy(e.size),e.resprop&&this.resprop(e.resprop),e.keySet&&this.keySet(e.keySet),e.hide&&this.isHidden(e.hide),e.bold?this.res.style.fontWeight="bold":null!=e.weight&&(this.res.style.fontWeight=e.weight),this}},{key:"hover",value:function(e){var t=this;if(e.border){var r=e.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,e.animation&&(this.res.style.transition="".concat(e.animation),this.res.style.transionProperty="background, color"),this.res.onmouseout=function(){t.res.style.backgroundColor="".concat(t.prevColor),t.res.style.color="".concat(t.foreColor),t.res.style.border=t.prevBorder},this.res.onmouseover=function(){if(t.res.style.color=e.color,t.res.style.backgroundColor=e.background,e.border){var r,n=e.border.width,i=null!==(r=e.border.color)&&void 0!==r?r:"#2ECC71";t.res.style.border=n?"".concat(n,"px solid ").concat(i):"1px solid #2ECC71"}},this}},{key:"onScroll",value:function(e){var t=this;"opacity"===e.value?this.res.style.opacity=e.valMin:"scale"===e.value&&(this.res.style.transform="scale(".concat(e.valMax,")")),window.addEventListener("scroll",function(){var r=t.smartRange(window.scrollY,{min:e.from,max:e.to},{min:e.valMin,max:e.valMax});"opacity"===e.value?t.res.style.opacity=r:"scale"===e.value&&(t.res.style.transform="scale(".concat(r,")"))})}},{key:"setAny",value:function(e){this[Object.keys(e)[0]]=[Object.values(e)[0]]}},{key:"setID",value:function(e){this.id=e}},{key:"setPrevText",value:function(e){this.prevText=e}},{key:"getCSS",value:function(){return this.css}},{key:"getPX",value:function(e){return{xs:"0px",sm:"576px",md:"768px",lg:"992px",xl:"1200px",xxl:"1400px",mxxl:"1800px"}[e]||"Invalid breakpoint"}},{key:"respad",value:function(e){var t=this;this._applyResponsive(e,function(e){console.log("Applying padding for",e.breakpoint),t.pad(e.values)})}},{key:"_applyResponsive",value:function(e,t){var r={default:0,xs:0,sm:576,md:768,lg:992,xl:1200,xxl:1400};e.forEach(function(e){void 0!==r[e.breakpoint]?e._value=r[e.breakpoint]:e._value=parseInt(e.breakpoint,10)}),e.sort(function(e,t){return e._value-t._value});var n=e.find(function(e){return"default"===e.breakpoint}),i=function(){for(var r=window.innerWidth,i=n||null,s=0;s<e.length;s++){var o=e[s];if("default"!==o.breakpoint&&r<=o._value){i=o;break}}i&&t(i)};this._responsiveHandler&&window.removeEventListener("resize",this._responsiveHandler),this._responsiveHandler=i,window.addEventListener("resize",i),i()}},{key:"resmar",value:function(e){var t=this;this._applyResponsive(e,function(e){console.log("Applying margin for",e.breakpoint),t.mar(e.values)})}},{key:"resprop",value:function(e){var t=this;this.prevStyles={};for(var r=0;r<this.res.style.length;r++){var n=this.res.style[r];this.prevStyles[n]=this.res.style[n]}this._applyResponsive(e,function(e){for(var r in console.log("Applying styles for",e.breakpoint),t.prevStyles)t.res.style[r]=t.prevStyles[r];for(var n in e)"breakpoint"!==n&&"_value"!==n&&"values"!==n&&(t.res.style[n]=e[n])})}},{key:"isNumber",value:function(e){return"number"==typeof e&&!isNaN(e)}},{key:"pad",value:function(e){for(var t=0;t<e.length;t++)for(var r=Object.keys(e[t]),n=0;n<r.length;n++)for(var i=r[n],s=e[t][i],o=0;o<i.length;o++)switch(i[o]){case"a":this.res.style.padding=this.isNumber(s)?"".concat(s,"px"):s;break;case"t":this.res.style.paddingTop=this.isNumber(s)?"".concat(s,"px"):s;break;case"l":this.res.style.paddingLeft=this.isNumber(s)?"".concat(s,"px"):s;break;case"r":this.res.style.paddingRight=this.isNumber(s)?"".concat(s,"px"):s;break;case"b":this.res.style.paddingBottom=this.isNumber(s)?"".concat(s,"px"):s}return this}},{key:"as",value:function(e){return this.res.style.alignSelf=e,this}},{key:"mar",value:function(e){for(var t=0;t<e.length;t++)for(var r=Object.keys(e[t]),n=0;n<r.length;n++)for(var i=r[n],s=e[t][i],o=0;o<i.length;o++){switch(i[o]){case"a":this.res.style.margin=this.isNumber(s)?"".concat(s,"px"):s;break;case"t":this.res.style.marginTop=this.isNumber(s)?"".concat(s,"px"):s;break;case"l":this.res.style.marginLeft=this.isNumber(s)?"".concat(s,"px"):s;break;case"r":this.res.style.marginRight=this.isNumber(s)?"".concat(s,"px"):s;break;case"b":this.res.style.marginBottom=this.isNumber(s)?"".concat(s,"px"):s}"auto"===i[o]&&(this.res.style.marginLeft="auto",this.res.style.marginRight="auto")}return this}},{key:"smartRange",value:function(e,t,r){e<t.min&&(e=t.min),e>t.max&&(e=t.max);var n=(e-t.min)/(t.max-t.min);t.min>t.max&&(n=(e-t.max)/(t.min-t.max));var i=(r.min-r.max)*n-r.min;if(i=Math.abs(i),r.min<r.max){var s=(r.max+Math.abs(r.min))*n;i=r.min+s}return i}},{key:"gpos",value:function(e){return this.res.style.gridColumn=e.col,this.res.style.gridRow=e.row,this}},{key:"fluidCopy",value:function(e){if(e instanceof Object){this.prevStylex=this.res.style,this.res=document.createElement("h1"),this.res.style.cssText=this.prevStylex.cssText;var t=document.createTextNode(this.text);return this.res.appendChild(t),this.res.style.fontSize=e.exact,this}if("S1"===e){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"===e){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"===e){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"===e){this.prevStylex=this.res.style,this.res=document.createElement("h4"),this.res.style.cssText=this.prevStylex.cssText;var s=document.createTextNode(this.text);this.res.appendChild(s),this.res.style.fontSize="calc(1.250rem + 2.75vw)"}if("S5"===e){this.prevStylex=this.res.style,this.res=document.createElement("h5"),this.res.style.cssText=this.prevStylex.cssText;var o=document.createTextNode(this.text);this.res.appendChild(o),this.res.style.fontSize="calc(1.125rem + 1.975vw)"}return"S6"===e&&(this.res.style.fontSize="calc(1rem + 0.5vw)"),this}},{key:"setIndex",value:function(e){this.index=e}},{key:"borderObj",value:function(e){var t,r=null!==(t=e.type)&&void 0!==t?t:"solid";return this.res.style.border="".concat(e.width," ").concat(r," ").concat(e.color),this.res.style.borderRadius=e.radius,this}},{key:"setPref",value:function(e){this.preffersId=e}},{key:"setClass",value:function(e){this.class=e}},{key:"setTags",value:function(e){this.openTag=e.open,this.closeTag=e.close,console.log("TAGS SET"),console.log(e)}},{key:"chainReact",value:function(e,t,i){var s=this;console.log("0P"),this.ap=!1,this.cta=0,this.once=!1;var o,a=n(e);try{for(a.s();!(o=a.n()).done;){var l=o.value;l.range||(l.range=["0px","999999px"])}}catch(e){a.e(e)}finally{a.f()}e.sort(function(e,t){return parseInt(e.range[0])-parseInt(t.range[0])});var c=function(o){var a=window.visualViewport.width,l=[],c=[];s.resCopy=s.res,s.storedQueries=e.map(function(e){return e.target}).filter(function(e){return null!=e});var u,p=n(e);try{for(p.s();!(u=p.n()).done;){var d=u.value;s.counterIndex++;var f=r(d.range,2),y=f[0],h=f[1],v=parseInt(y),m=parseInt(h),g=!0;if(d.target){g=!1;for(var b=0;b<d.target.length;b++)d.target[b]===t&&(g=!0)}a>=v&&a<=m&&g&&(l.push(d.log),c.push(d),d.op&&d.op.margin&&(s.useMargin=d.op.margin))}}catch(e){p.e(e)}finally{p.f()}if(i&&!i.includes("background")&&(s.res.style.background="",s.res.style.backgroundColor=""),s.res.style.textShadow="",i&&!i.includes("border")&&(s.res.style.border=""),i&&!i.includes("margin")&&(s.res.style.margin=""),s.res.style["-webkit-text-fill-color"]="",s.res.style["-webkit-text-stroke-color"]="",s.res.style["-webkit-text-stroke-width"]="",s.res.style.filter="",s.options.background&&(console.log(s.options.background),s.res.style.background=s.options.background),l.includes("gradient"),(l.includes("gradient")||l.includes("shadow"))&&(s.res.style.position="relative"),l.includes("blast")){var x,k=c.filter(function(e){return"blast"===e.log})[0].op.color,w=null!==(x=c.filter(function(e){return"blast"===e.log})[0].op.width)&&void 0!==x?x:"1px";"FlexRowLayoutElement"===s.getType()||"LayoutWrapperElement"===s.getType()?(s.res.style.border="".concat("number"==typeof w?w+"px":w," solid orange"),s.res.style.display="inline-block","FlexRowLayoutElement"===s.getType()&&(s.res.style.display="flex"),s.res.style.boxSizing="border-box",s.res.style.transformOrigin="center",s.blastTarget=s.res):(s.text,s.res.style["-webkit-text-fill-color"]="transparent",s.res.style["-webkit-text-stroke-color"]=k,s.res.style["-webkit-text-stroke-width"]="".concat(w))}if(l.includes("filter")){var S=c.filter(function(e){return"filter"===e.log})[0].op.filter;s.res.style.filter=S}if(l.includes("background")&&(s.res.style.backgroundColor="green"),l.includes("gradient")&&("LayoutWrapperElement"!==s.getType()&&"FlexRowLayoutElement"!==s.getType()&&(s.res.style["-webkit-text-fill-color"]="transparent"),s.res.style.background=s.globalGradient,"LayoutWrapperElement"!==s.getType()&&"FlexRowLayoutElement"!==s.getType()&&(s.res.style["background-clip"]="text")),l.includes("shadow")){var T,E,O,C,j=s.options.shadow.op;console.log("OP IS",j);var W=null!==(T=j.steps)&&void 0!==T?T:1,A=null!==(E=j.colors)&&void 0!==E?E:["gray"],L=null!==(O=j.movements)&&void 0!==O?O:["3px","3px"],P=null!==(C=j.radius)&&void 0!==C?C:"3px";if(1===L.length&&(L=[L[0],L[0]]),"FlexRowLayoutElement"===s.getType()||"LayoutWrapperElement"===s.getType()){for(var I=[],R=0;R<W;R++){var N,z=null!==(N=A[R])&&void 0!==N?N:A[0],_=L[0],M=L[1];I.push("".concat(_," ").concat(M," ").concat(P," ").concat(z))}s.res.style.boxShadow=I.join(", ")}else{for(var B=[],F=0;F<W;F++){var H,D=null!==(H=A[F])&&void 0!==H?H:A[0],Y=L[0],X=L[1];B.push("drop-shadow(".concat(Y," ").concat(X," ").concat(P," ").concat(D,")"))}s.res.style.filter=B.join(" ")}}if(l.includes("margin"))for(b=0;b<e.length;b++)if(e[b].op){var G=e[b].op.offsets;G&&void 0!==s.index&&(s.res.style.margin=G[Number(s.index)]+"px")}if(l.includes("spana")||l.includes("span")){var V=document.createElement("div");if(V.setAttribute("id","oroa"),Object.assign(V.style,{position:"absolute",inset:"0",background:"linear-gradient(90deg, rgb(52,152,219), rgb(26,188,156))",WebkitBackgroundClip:"text",WebkitTextFillColor:"transparent",pointerEvents:"none"}),s.res&&s.res.querySelector("span"))return;s.res=s.resCopy,s.res.textContent="",s.options.span&&(Array.isArray(s.options.span)?s.options.span:[s.options.span]).forEach(function(e){if(e.op&&"span"===e.op.name&&Array.isArray(e.op.parts)){var t=0,r=s.prevText||"";if(e.op.parts.forEach(function(e){var n=e.text,i=e.style||{};if(t<r.length){var o=r.indexOf(n,t);if(o>t){var a=r.substring(t,o);s.res.appendChild(new s.constructor(a).setup({type:"span",id:i.id,animation:i.animation}).set({}).render())}t=o+n.length}var l=new s.constructor(n).setup({type:"span",id:i.id,animation:i.animation}).set(i).render();s.res.appendChild(l)}),t<r.length){var n=r.substring(t);s.res.appendChild(new s.constructor(n).setup({type:"span"}).set({}).render())}}})}else{var $=new s.constructor(s.prevText).set({}).render();s.prevText&&s.prevText.length>0&&o&&s.res.appendChild($)}if(l.includes("animation")){if(s.options.animation&&!s.hasAnimated&&!s.options.animation.op.fireAt){console.warn(s.openTag),s.hasAnimated=!0;var q=s.options.animation.op;window.addEventListener("sidebar:open",function(){s.res.animate(q.keyframesOpen,q.openOptions)}),window.addEventListener("sidebar:closed",function(){s.res.animate(q.keyframesClose,q.closeOptions)}),s.res.animate(q.keyframesClose,{duration:0,fill:"forwards"}),s.openTag&&s.closeTag&&(window.addEventListener(s.openTag,function(){s.res.animate(q.keyframesOpen,q.openOptions)}),window.addEventListener(s.closeTag,function(){s.res.animate(q.keyframesClose,q.closeOptions)}))}if(s.options.animation&&s.options.animation.op.fireAt&&s.options.animation.op.fireAt.endsWith("px")){var J=s.options.animation.op;s.res.animate(J.keyframesClose,{duration:0,fill:"forwards"});var Q=function(){window.scrollY>parseFloat(J.fireAt)&&(s.res.animate(J.keyframesOpen,J.openOptions),window.removeEventListener("scroll",Q))};window.addEventListener("scroll",Q)}if(s.options.animation&&"inview"===s.options.animation.op.fireAt){var U=s.options.animation.op;s.res.animate(U.keyframesClose,{duration:0,fill:"forwards"});var K=!1;new IntersectionObserver(function(e,t){e.forEach(function(e){e.isIntersecting&&!K&&(K=!0,s.res.animate(U.keyframesOpen,U.openOptions),t.disconnect())})}).observe(s.res)}}};this.options.animation||window.addEventListener("resize",function(){return c()}),c()}},{key:"maxWidth",value:function(e){return this.res.style.maxWidth=e,this}},{key:"removeQuotesFromFirstWord",value:function(e){return e.replace(/"([^"]+)":/g,"$1:")}},{key:"arrayMargin",value:function(e,t){return e.includes("left")&&(this.res.style.marginLeft=t),e.includes("right")&&(this.res.style.marginRight=t),e.includes("top")&&(this.res.style.marginTop=t),e.includes("bottom")&&(this.res.style.marginBottom=t),e.includes("all")&&(this.res.style.margin=t),t||(this.res.style.marginBottom=e),this}}],t&&o(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();function c(e){return c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},c(e)}function u(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,p(n.key),n)}}function p(e){var t=function(e){if("object"!=c(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=c(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==c(t)?t:t+""}function d(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(d=function(){return!!e})()}function f(e){return f=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},f(e)}function y(e,t){return y=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},y(e,t)}var h=function(){function e(){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),(t=function(e,t,r){return t=f(t),function(e,t){if(t&&("object"==c(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,d()?Reflect.construct(t,r||[],f(e).constructor):t.apply(e,r))}(this,e)).el=null,t.file=null,t.selected="",t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&y(e,t)}(e,l),t=e,r=[{key:"setup",value:function(e,t){document.createElement("div");var r=document.createElement("select");r.setAttribute("type","file"),r.setAttribute("name",t),r.addEventListener("change",function(){r.options[r.selectedIndex].value});for(var n=0;n<e.length;n++)r.appendChild(this.addNode(e[n][0],e[n][1]));return this.el=r,this}},{key:"set",value:function(e){return this.options=e,e.items&&this.setup(e.items,e.name),e.arrayPadding&&this.arrayPadding(e.arrayPadding.sides,e.arrayPadding.value),e.arrayMargin&&this.arrayMargin(e.arrayMargin.sides,e.arrayMargin.value),e.pad&&this.pad(e.pad),e.mar&&this.mar(e.mar),e.radius&&(this.el.style.borderRadius=e.radius),e.background&&(this.el.style.background=e.background),this}},{key:"arrayPadding",value:function(e,t){return e.includes("left")&&(this.el.style.paddingLeft=t),e.includes("right")&&(this.el.style.paddingRight=t),e.includes("top")&&(this.el.style.paddingTop=t),e.includes("bottom")&&(this.el.style.paddingBottom=t),e.includes("all")&&(this.el.style.padding=t),this}},{key:"arrayMargin",value:function(e,t){return e.includes("left")&&(this.el.style.marginLeft=t),e.includes("right")&&(this.el.style.marginRight=t),e.includes("top")&&(this.el.style.marginTop=t),e.includes("bottom")&&(this.el.style.marginBottom=t),e.includes("all")&&(this.el.style.margin=t),this}},{key:"addNode",value:function(e,t){var r=document.createElement("option");r.setAttribute("value",e);var n=document.createTextNode(t);return r.appendChild(n),r}},{key:"padding",value:function(e){return this.el.style.padding=e,this}},{key:"font",value:function(e){return this.el.style.fontFamily=e,this}},{key:"margin",value:function(e){return this.el.style.margin=e,this}},{key:"toCode",value:function(){var e=JSON.stringify(this.options,null,4);return e=e.replace(/"(\w+)"(?=\s*:)/g,"$1"),["new Picker().set(".concat(e,")")]}},{key:"rounded",value:function(e){return this.el.style.borderRadius="4px",this}},{key:"auto",value:function(){var e=this,t=function(){window.matchMedia("(max-device-width: 415px)").matches?e.el.style.fontSize="3rem":e.el.style.fontSize="1rem"};return t(),window.addEventListener("resize",t),this}},{key:"render",value:function(e){if(!e)return this.el;document.querySelector(e).appendChild(this.el)}}],r&&u(t.prototype,r),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,r}();window.Picker=h;export{h as Picker};
|
package/dist/progress.cjs.js
CHANGED
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
(()=>{"use strict";var e={d:(t,r)=>{for(var i in r)e.o(r,i)&&!e.o(t,i)&&Object.defineProperty(t,i,{enumerable:!0,get:r[i]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},t={};function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}function i(e,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,n(i.key),i)}}function n(e){var t=function(e){if("object"!=r(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var i=t.call(e,"string");if("object"!=r(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==r(t)?t:t+""}e.r(t),e.d(t,{Progress:()=>s});var s=function(){return e=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.res=null,this.value=t,this.setup()},t=[{key:"setup",value:function(){var e=document.createElement("div"),t=document.createElement("div"),r=document.createElement("div");return t.style.position="absolute",r.style.position="relative",e.appendChild(t),e.appendChild(r),this.res=e,this}},{key:"padding",value:function(e,t,r,i){return(e||t||r||i)&&(this.res.style.paddingLeft=e,this.res.style.paddingTop=t,this.res.style.paddingRight=r,this.res.style.paddingBottom=i),t||r||i||(this.res.style.padding=e),this}},{key:"arrayPadding",value:function(e,t){return e.includes("left")&&(this.res.style.paddingLeft=t),e.includes("right")&&(this.res.style.paddingRight=t),e.includes("top")&&(this.res.style.paddingTop=t),e.includes("bottom")&&(this.res.style.paddingBottom=t),this}},{key:"size",value:function(e){var t=this,r=e.width.split("%")[0],i=e.height;this.res.children[0].style.width=r/100*window.innerWidth,this.res.children[0].style.height=i,this.res.children[1].style.width=r/100*window.innerWidth*this.value,this.res.children[1].style.height=i;var n=function(){t.res.children[0].style.width=r/100*window.innerWidth,t.res.children[0].style.height=i,t.res.children[1].style.width=r/100*window.innerWidth*t.value,t.res.children[1].style.height=i};return window.addEventListener("resize",n),n(),this}},{key:"colors",value:function(e,t){return this.res.children[0].style.background=e,this.res.children[1].style.background=t,this}},{key:"round",value:function(e){return this.res.children[0].style.borderRadius="".concat(e,"px"),this.res.children[1].style.borderRadius="".concat(e,"px"),this}},{key:"render",value:function(e){if(Array.from(this.res.children).forEach((function(e){return e.style.padding=0})),Array.from(this.res.children).forEach((function(e){return e.style.margin=0})),!e)return this.res;document.querySelector(e).appendChild(this.res)}}],t&&i(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();module.exports=t})();
|
|
1
|
+
(()=>{"use strict";var e={d:(t,r)=>{for(var i in r)e.o(r,i)&&!e.o(t,i)&&Object.defineProperty(t,i,{enumerable:!0,get:r[i]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},t={};function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}function i(e,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,n(i.key),i)}}function n(e){var t=function(e){if("object"!=r(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var i=t.call(e,"string");if("object"!=r(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==r(t)?t:t+""}e.r(t),e.d(t,{Progress:()=>s});var s=function(){return e=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.res=null,this.value=t,this.setup()},t=[{key:"setup",value:function(){var e=document.createElement("div"),t=document.createElement("div"),r=document.createElement("div");return t.style.position="absolute",r.style.position="relative",e.appendChild(t),e.appendChild(r),this.res=e,this}},{key:"padding",value:function(e,t,r,i){return(e||t||r||i)&&(this.res.style.paddingLeft=e,this.res.style.paddingTop=t,this.res.style.paddingRight=r,this.res.style.paddingBottom=i),t||r||i||(this.res.style.padding=e),this}},{key:"arrayPadding",value:function(e,t){return e.includes("left")&&(this.res.style.paddingLeft=t),e.includes("right")&&(this.res.style.paddingRight=t),e.includes("top")&&(this.res.style.paddingTop=t),e.includes("bottom")&&(this.res.style.paddingBottom=t),this}},{key:"size",value:function(e){var t=this,r=e.width.split("%")[0],i=e.height;this.res.children[0].style.width=r/100*window.innerWidth,this.res.children[0].style.height=i,this.res.children[1].style.width=r/100*window.innerWidth*this.value,this.res.children[1].style.height=i;var n=function(){t.res.children[0].style.width=r/100*window.innerWidth,t.res.children[0].style.height=i,t.res.children[1].style.width=r/100*window.innerWidth*t.value,t.res.children[1].style.height=i};return window.addEventListener("resize",n),n(),this}},{key:"colors",value:function(e,t){return this.res.children[0].style.background=e,this.res.children[1].style.background=t,this}},{key:"round",value:function(e){return this.res.children[0].style.borderRadius="".concat(e,"px"),this.res.children[1].style.borderRadius="".concat(e,"px"),this}},{key:"render",value:function(e){if(Array.from(this.res.children).forEach(function(e){return e.style.padding=0}),Array.from(this.res.children).forEach(function(e){return e.style.margin=0}),!e)return this.res;document.querySelector(e).appendChild(this.res)}}],t&&i(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();module.exports=t})();
|
package/dist/progress.esm.js
CHANGED
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
var e={d:(t,r)=>{for(var i in r)e.o(r,i)&&!e.o(t,i)&&Object.defineProperty(t,i,{enumerable:!0,get:r[i]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t)},t={};function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}function i(e,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,n(i.key),i)}}function n(e){var t=function(e){if("object"!=r(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var i=t.call(e,"string");if("object"!=r(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==r(t)?t:t+""}e.d(t,{k:()=>s});var s=function(){return e=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.res=null,this.value=t,this.setup()},t=[{key:"setup",value:function(){var e=document.createElement("div"),t=document.createElement("div"),r=document.createElement("div");return t.style.position="absolute",r.style.position="relative",e.appendChild(t),e.appendChild(r),this.res=e,this}},{key:"padding",value:function(e,t,r,i){return(e||t||r||i)&&(this.res.style.paddingLeft=e,this.res.style.paddingTop=t,this.res.style.paddingRight=r,this.res.style.paddingBottom=i),t||r||i||(this.res.style.padding=e),this}},{key:"arrayPadding",value:function(e,t){return e.includes("left")&&(this.res.style.paddingLeft=t),e.includes("right")&&(this.res.style.paddingRight=t),e.includes("top")&&(this.res.style.paddingTop=t),e.includes("bottom")&&(this.res.style.paddingBottom=t),this}},{key:"size",value:function(e){var t=this,r=e.width.split("%")[0],i=e.height;this.res.children[0].style.width=r/100*window.innerWidth,this.res.children[0].style.height=i,this.res.children[1].style.width=r/100*window.innerWidth*this.value,this.res.children[1].style.height=i;var n=function(){t.res.children[0].style.width=r/100*window.innerWidth,t.res.children[0].style.height=i,t.res.children[1].style.width=r/100*window.innerWidth*t.value,t.res.children[1].style.height=i};return window.addEventListener("resize",n),n(),this}},{key:"colors",value:function(e,t){return this.res.children[0].style.background=e,this.res.children[1].style.background=t,this}},{key:"round",value:function(e){return this.res.children[0].style.borderRadius="".concat(e,"px"),this.res.children[1].style.borderRadius="".concat(e,"px"),this}},{key:"render",value:function(e){if(Array.from(this.res.children).forEach((function(e){return e.style.padding=0})),Array.from(this.res.children).forEach((function(e){return e.style.margin=0})),!e)return this.res;document.querySelector(e).appendChild(this.res)}}],t&&i(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}(),o=t.k;export{o as Progress};
|
|
1
|
+
var e={d:(t,r)=>{for(var i in r)e.o(r,i)&&!e.o(t,i)&&Object.defineProperty(t,i,{enumerable:!0,get:r[i]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t)},t={};function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}function i(e,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,n(i.key),i)}}function n(e){var t=function(e){if("object"!=r(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var i=t.call(e,"string");if("object"!=r(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==r(t)?t:t+""}e.d(t,{k:()=>s});var s=function(){return e=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.res=null,this.value=t,this.setup()},t=[{key:"setup",value:function(){var e=document.createElement("div"),t=document.createElement("div"),r=document.createElement("div");return t.style.position="absolute",r.style.position="relative",e.appendChild(t),e.appendChild(r),this.res=e,this}},{key:"padding",value:function(e,t,r,i){return(e||t||r||i)&&(this.res.style.paddingLeft=e,this.res.style.paddingTop=t,this.res.style.paddingRight=r,this.res.style.paddingBottom=i),t||r||i||(this.res.style.padding=e),this}},{key:"arrayPadding",value:function(e,t){return e.includes("left")&&(this.res.style.paddingLeft=t),e.includes("right")&&(this.res.style.paddingRight=t),e.includes("top")&&(this.res.style.paddingTop=t),e.includes("bottom")&&(this.res.style.paddingBottom=t),this}},{key:"size",value:function(e){var t=this,r=e.width.split("%")[0],i=e.height;this.res.children[0].style.width=r/100*window.innerWidth,this.res.children[0].style.height=i,this.res.children[1].style.width=r/100*window.innerWidth*this.value,this.res.children[1].style.height=i;var n=function(){t.res.children[0].style.width=r/100*window.innerWidth,t.res.children[0].style.height=i,t.res.children[1].style.width=r/100*window.innerWidth*t.value,t.res.children[1].style.height=i};return window.addEventListener("resize",n),n(),this}},{key:"colors",value:function(e,t){return this.res.children[0].style.background=e,this.res.children[1].style.background=t,this}},{key:"round",value:function(e){return this.res.children[0].style.borderRadius="".concat(e,"px"),this.res.children[1].style.borderRadius="".concat(e,"px"),this}},{key:"render",value:function(e){if(Array.from(this.res.children).forEach(function(e){return e.style.padding=0}),Array.from(this.res.children).forEach(function(e){return e.style.margin=0}),!e)return this.res;document.querySelector(e).appendChild(this.res)}}],t&&i(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();const o=t.k;export{o as Progress};
|
package/dist/radio.cjs.js
CHANGED
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
(()=>{"use strict";var t={d:(e,o)=>{for(var n in o)t.o(o,n)&&!t.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:o[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 o(t){return o="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},o(t)}function n(t,e){for(var o=0;o<e.length;o++){var n=e[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,r(n.key),n)}}function r(t){var e=function(t){if("object"!=o(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=o(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==o(e)?e:e+""}t.r(e),t.d(e,{RadioGroup:()=>i});var i=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"),o=t.items,n=0;n<o.length;n++){var r=document.createElement("label");o.font&&(r.style.font=o.font),o.color&&(r.style.color=o.color),o.exact&&(r.style.fontSize=o.exact);var i=document.createTextNode(o[n]);r.appendChild(i),r.setAttribute("for",o[n]);var l=document.createElement("input");l.setAttribute("type","radio"),l.setAttribute("id","S".concat(n)),l.setAttribute("value",o[n].split(" ").join("")),l.style.appearance="none",l.style.width="20px",l.style.height="20px",l.style.border=this.options.tint?"2px solid ".concat(this.options.tint):"2px solid #007BFF",l.style.borderRadius="50%",l.style.outline="none",l.style.cursor="pointer",l.style.transition="0.3s",this.options.font&&(r.style.fontFamily=this.options.font),t.multiple?l.setAttribute("name",o[n].split(" ").join("")):l.setAttribute("name",t.name),e.appendChild(l),e.appendChild(r),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 o=document.querySelector("#S".concat(e));console.log("VALUE IS "+o.value),t.push(o.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 o=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 o=0;o<e.el.children.length;o++){var n=e.el.children[o];"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++)o();return this.el}document.querySelector(t).appendChild(this.el)}}])&&n(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();window.RadioGroup=i,module.exports=e})();
|
|
1
|
+
(()=>{"use strict";var t={d:(e,o)=>{for(var n in o)t.o(o,n)&&!t.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:o[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 o(t){return o="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},o(t)}function n(t,e){for(var o=0;o<e.length;o++){var n=e[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,r(n.key),n)}}function r(t){var e=function(t){if("object"!=o(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=o(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==o(e)?e:e+""}t.r(e),t.d(e,{RadioGroup:()=>i});var i=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"),o=t.items,n=0;n<o.length;n++){var r=document.createElement("label");o.font&&(r.style.font=o.font),o.color&&(r.style.color=o.color),o.exact&&(r.style.fontSize=o.exact);var i=document.createTextNode(o[n]);r.appendChild(i),r.setAttribute("for",o[n]);var l=document.createElement("input");l.setAttribute("type","radio"),l.setAttribute("id","S".concat(n)),l.setAttribute("value",o[n].split(" ").join("")),l.style.appearance="none",l.style.width="20px",l.style.height="20px",l.style.border=this.options.tint?"2px solid ".concat(this.options.tint):"2px solid #007BFF",l.style.borderRadius="50%",l.style.outline="none",l.style.cursor="pointer",l.style.transition="0.3s",this.options.font&&(r.style.fontFamily=this.options.font),t.multiple?l.setAttribute("name",o[n].split(" ").join("")):l.setAttribute("name",t.name),e.appendChild(l),e.appendChild(r),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 o=document.querySelector("#S".concat(e));console.log("VALUE IS "+o.value),t.push(o.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 o=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 o=0;o<e.el.children.length;o++){var n=e.el.children[o];"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++)o();return this.el}document.querySelector(t).appendChild(this.el)}}])&&n(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();window.RadioGroup=i,module.exports=e})();
|
package/dist/radio.esm.js
CHANGED
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
var t={d:(e,o)=>{for(var n in o)t.o(o,n)&&!t.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:o[n]})},o:(t,e)=>Object.prototype.hasOwnProperty.call(t,e)},e={};function o(t){return o="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},o(t)}function n(t,e){for(var o=0;o<e.length;o++){var n=e[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,r(n.key),n)}}function r(t){var e=function(t){if("object"!=o(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=o(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==o(e)?e:e+""}t.d(e,{z:()=>i});var i=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"),o=t.items,n=0;n<o.length;n++){var r=document.createElement("label");o.font&&(r.style.font=o.font),o.color&&(r.style.color=o.color),o.exact&&(r.style.fontSize=o.exact);var i=document.createTextNode(o[n]);r.appendChild(i),r.setAttribute("for",o[n]);var l=document.createElement("input");l.setAttribute("type","radio"),l.setAttribute("id","S".concat(n)),l.setAttribute("value",o[n].split(" ").join("")),l.style.appearance="none",l.style.width="20px",l.style.height="20px",l.style.border=this.options.tint?"2px solid ".concat(this.options.tint):"2px solid #007BFF",l.style.borderRadius="50%",l.style.outline="none",l.style.cursor="pointer",l.style.transition="0.3s",this.options.font&&(r.style.fontFamily=this.options.font),t.multiple?l.setAttribute("name",o[n].split(" ").join("")):l.setAttribute("name",t.name),e.appendChild(l),e.appendChild(r),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 o=document.querySelector("#S".concat(e));console.log("VALUE IS "+o.value),t.push(o.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 o=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 o=0;o<e.el.children.length;o++){var n=e.el.children[o];"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++)o();return this.el}document.querySelector(t).appendChild(this.el)}}])&&n(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();window.RadioGroup=i;var l=e.z;export{l as RadioGroup};
|
|
1
|
+
var t={d:(e,o)=>{for(var n in o)t.o(o,n)&&!t.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:o[n]})},o:(t,e)=>Object.prototype.hasOwnProperty.call(t,e)},e={};function o(t){return o="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},o(t)}function n(t,e){for(var o=0;o<e.length;o++){var n=e[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,r(n.key),n)}}function r(t){var e=function(t){if("object"!=o(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=o(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==o(e)?e:e+""}t.d(e,{z:()=>i});var i=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"),o=t.items,n=0;n<o.length;n++){var r=document.createElement("label");o.font&&(r.style.font=o.font),o.color&&(r.style.color=o.color),o.exact&&(r.style.fontSize=o.exact);var i=document.createTextNode(o[n]);r.appendChild(i),r.setAttribute("for",o[n]);var l=document.createElement("input");l.setAttribute("type","radio"),l.setAttribute("id","S".concat(n)),l.setAttribute("value",o[n].split(" ").join("")),l.style.appearance="none",l.style.width="20px",l.style.height="20px",l.style.border=this.options.tint?"2px solid ".concat(this.options.tint):"2px solid #007BFF",l.style.borderRadius="50%",l.style.outline="none",l.style.cursor="pointer",l.style.transition="0.3s",this.options.font&&(r.style.fontFamily=this.options.font),t.multiple?l.setAttribute("name",o[n].split(" ").join("")):l.setAttribute("name",t.name),e.appendChild(l),e.appendChild(r),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 o=document.querySelector("#S".concat(e));console.log("VALUE IS "+o.value),t.push(o.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 o=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 o=0;o<e.el.children.length;o++){var n=e.el.children[o];"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++)o();return this.el}document.querySelector(t).appendChild(this.el)}}])&&n(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e}();window.RadioGroup=i;const l=e.z;export{l as RadioGroup};
|
package/dist/range.cjs.js
CHANGED
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
(()=>{"use strict";var e={d:(t,n)=>{for(var r in n)e.o(n,r)&&!e.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:n[r]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},t={};function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,i(r.key),r)}}function i(e){var t=function(e){if("object"!=n(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=n(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==n(t)?t:t+""}e.r(t),e.d(t,{Range:()=>l});var l=function(){return e=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.el=null,this.minLabel=null,this.maxLabel=null,this.currentLabel=null},(t=[{key:"padding",value:function(e){return this.el.style.padding=e,this}},{key:"toCode",value:function(){var e=JSON.stringify(this.options,null,4);return["new Range().set(".concat(e,")")]}},{key:"set",value:function(e){var t,n,r=this;this.options=e;var i=document.createElement("input");if(i.setAttribute("id","slider"),i.setAttribute("type","range"),i.setAttribute("min",e.min),i.setAttribute("max",e.max),i.setAttribute("value",e.min),i.style.width=null!==(t=e.width)&&void 0!==t?t:"100%",!e.plain){var l,a;i.style.setProperty("-webkit-appearance","none"),i.style.appearance="none",i.style.height="9px",i.style.background=null!==(l=e.style.trackColor)&&void 0!==l?l:"orange",i.style.borderRadius="5px";var o="\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!==(a=e.style.thumbColor)&&void 0!==a?a:"4CAF50",";\n cursor: pointer;\n }\n "),u=document.createElement("style");u.appendChild(document.createTextNode(o)),document.head.appendChild(u)}var s=document.createElement("div");s.style.display="flex",s.style.flexDirection="column",s.style.alignItems="center",s.style.width="100%";var d=document.createElement("div");if(d.style.display="flex",d.style.justifyContent="space-between",d.style.width=null!==(n=e.width)&&void 0!==n?n:"100%",this.minLabel=document.createElement("span"),this.minLabel.textContent=e.min,this.maxLabel=document.createElement("span"),this.maxLabel.textContent=e.max,this.currentLabel=document.createElement("span"),this.currentLabel.textContent=i.value,e.font&&(this.currentLabel.style.fontFamily=e.font),e.font&&(this.minLabel.style.fontFamily=e.font),e.font&&(this.maxLabel.style.fontFamily=e.font),e.plain||(d.appendChild(this.minLabel),d.appendChild(this.currentLabel),d.appendChild(this.maxLabel)),i.addEventListener("input",(function(){r.currentLabel.textContent=i.value})),window.matchMedia("(max-device-width: 415px)").matches)if(e.plain)i.style.width="80%";else{var c,p;i.style.height="20px",i.style.background=null!==(c=e.style.trackColor)&&void 0!==c?c:"1abc9C",i.style.borderRadius="10px",i.style.fontSize="3rem",i.style.width="80%";var y="\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!==(p=e.style.thumbColor)&&void 0!==p?p:"blue",";\n cursor: pointer;\n }\n "),m=document.createElement("style");m.appendChild(document.createTextNode(y)),document.head.appendChild(m)}return s.appendChild(d),s.appendChild(i),this.el=s,this}},{key:"value",value:function(){return this.el.querySelector("#slider").value}},{key:"render",value:function(e){if(!e)return this.el;document.querySelector(e).appendChild(this.el)}}])&&r(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();window.Range=l,module.exports=t})();
|
|
1
|
+
(()=>{"use strict";var e={d:(t,n)=>{for(var r in n)e.o(n,r)&&!e.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:n[r]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},t={};function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,i(r.key),r)}}function i(e){var t=function(e){if("object"!=n(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=n(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==n(t)?t:t+""}e.r(t),e.d(t,{Range:()=>l});var l=function(){return e=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.el=null,this.minLabel=null,this.maxLabel=null,this.currentLabel=null},(t=[{key:"padding",value:function(e){return this.el.style.padding=e,this}},{key:"toCode",value:function(){var e=JSON.stringify(this.options,null,4);return["new Range().set(".concat(e,")")]}},{key:"set",value:function(e){var t,n,r=this;this.options=e;var i=document.createElement("input");if(i.setAttribute("id","slider"),i.setAttribute("type","range"),i.setAttribute("min",e.min),i.setAttribute("max",e.max),i.setAttribute("value",e.min),i.style.width=null!==(t=e.width)&&void 0!==t?t:"100%",!e.plain){var l,a;i.style.setProperty("-webkit-appearance","none"),i.style.appearance="none",i.style.height="9px",i.style.background=null!==(l=e.style.trackColor)&&void 0!==l?l:"orange",i.style.borderRadius="5px";var o="\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!==(a=e.style.thumbColor)&&void 0!==a?a:"4CAF50",";\n cursor: pointer;\n }\n "),u=document.createElement("style");u.appendChild(document.createTextNode(o)),document.head.appendChild(u)}var s=document.createElement("div");s.style.display="flex",s.style.flexDirection="column",s.style.alignItems="center",s.style.width="100%";var d=document.createElement("div");if(d.style.display="flex",d.style.justifyContent="space-between",d.style.width=null!==(n=e.width)&&void 0!==n?n:"100%",this.minLabel=document.createElement("span"),this.minLabel.textContent=e.min,this.maxLabel=document.createElement("span"),this.maxLabel.textContent=e.max,this.currentLabel=document.createElement("span"),this.currentLabel.textContent=i.value,e.font&&(this.currentLabel.style.fontFamily=e.font),e.font&&(this.minLabel.style.fontFamily=e.font),e.font&&(this.maxLabel.style.fontFamily=e.font),e.plain||(d.appendChild(this.minLabel),d.appendChild(this.currentLabel),d.appendChild(this.maxLabel)),i.addEventListener("input",function(){r.currentLabel.textContent=i.value}),window.matchMedia("(max-device-width: 415px)").matches)if(e.plain)i.style.width="80%";else{var c,p;i.style.height="20px",i.style.background=null!==(c=e.style.trackColor)&&void 0!==c?c:"1abc9C",i.style.borderRadius="10px",i.style.fontSize="3rem",i.style.width="80%";var y="\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!==(p=e.style.thumbColor)&&void 0!==p?p:"blue",";\n cursor: pointer;\n }\n "),m=document.createElement("style");m.appendChild(document.createTextNode(y)),document.head.appendChild(m)}return s.appendChild(d),s.appendChild(i),this.el=s,this}},{key:"value",value:function(){return this.el.querySelector("#slider").value}},{key:"render",value:function(e){if(!e)return this.el;document.querySelector(e).appendChild(this.el)}}])&&r(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();window.Range=l,module.exports=t})();
|
package/dist/range.esm.js
CHANGED
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
var e={d:(t,n)=>{for(var i in n)e.o(n,i)&&!e.o(t,i)&&Object.defineProperty(t,i,{enumerable:!0,get:n[i]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t)},t={};function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}function i(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,r(i.key),i)}}function r(e){var t=function(e){if("object"!=n(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var i=t.call(e,"string");if("object"!=n(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==n(t)?t:t+""}e.d(t,{Q:()=>a});var a=function(){return e=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.el=null,this.minLabel=null,this.maxLabel=null,this.currentLabel=null},(t=[{key:"padding",value:function(e){return this.el.style.padding=e,this}},{key:"toCode",value:function(){var e=JSON.stringify(this.options,null,4);return["new Range().set(".concat(e,")")]}},{key:"set",value:function(e){var t,n,i=this;this.options=e;var r=document.createElement("input");if(r.setAttribute("id","slider"),r.setAttribute("type","range"),r.setAttribute("min",e.min),r.setAttribute("max",e.max),r.setAttribute("value",e.min),r.style.width=null!==(t=e.width)&&void 0!==t?t:"100%",!e.plain){var a,l;r.style.setProperty("-webkit-appearance","none"),r.style.appearance="none",r.style.height="9px",r.style.background=null!==(a=e.style.trackColor)&&void 0!==a?a:"orange",r.style.borderRadius="5px";var o="\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!==(l=e.style.thumbColor)&&void 0!==l?l:"4CAF50",";\n cursor: pointer;\n }\n "),u=document.createElement("style");u.appendChild(document.createTextNode(o)),document.head.appendChild(u)}var s=document.createElement("div");s.style.display="flex",s.style.flexDirection="column",s.style.alignItems="center",s.style.width="100%";var d=document.createElement("div");if(d.style.display="flex",d.style.justifyContent="space-between",d.style.width=null!==(n=e.width)&&void 0!==n?n:"100%",this.minLabel=document.createElement("span"),this.minLabel.textContent=e.min,this.maxLabel=document.createElement("span"),this.maxLabel.textContent=e.max,this.currentLabel=document.createElement("span"),this.currentLabel.textContent=r.value,e.font&&(this.currentLabel.style.fontFamily=e.font),e.font&&(this.minLabel.style.fontFamily=e.font),e.font&&(this.maxLabel.style.fontFamily=e.font),e.plain||(d.appendChild(this.minLabel),d.appendChild(this.currentLabel),d.appendChild(this.maxLabel)),r.addEventListener("input",(function(){i.currentLabel.textContent=r.value})),window.matchMedia("(max-device-width: 415px)").matches)if(e.plain)r.style.width="80%";else{var c,p;r.style.height="20px",r.style.background=null!==(c=e.style.trackColor)&&void 0!==c?c:"1abc9C",r.style.borderRadius="10px",r.style.fontSize="3rem",r.style.width="80%";var y="\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!==(p=e.style.thumbColor)&&void 0!==p?p:"blue",";\n cursor: pointer;\n }\n "),h=document.createElement("style");h.appendChild(document.createTextNode(y)),document.head.appendChild(h)}return s.appendChild(d),s.appendChild(r),this.el=s,this}},{key:"value",value:function(){return this.el.querySelector("#slider").value}},{key:"render",value:function(e){if(!e)return this.el;document.querySelector(e).appendChild(this.el)}}])&&i(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();window.Range=a;var l=t.Q;export{l as Range};
|
|
1
|
+
var e={d:(t,n)=>{for(var i in n)e.o(n,i)&&!e.o(t,i)&&Object.defineProperty(t,i,{enumerable:!0,get:n[i]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t)},t={};function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}function i(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,r(i.key),i)}}function r(e){var t=function(e){if("object"!=n(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var i=t.call(e,"string");if("object"!=n(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==n(t)?t:t+""}e.d(t,{Q:()=>l});var l=function(){return e=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.el=null,this.minLabel=null,this.maxLabel=null,this.currentLabel=null},(t=[{key:"padding",value:function(e){return this.el.style.padding=e,this}},{key:"toCode",value:function(){var e=JSON.stringify(this.options,null,4);return["new Range().set(".concat(e,")")]}},{key:"set",value:function(e){var t,n,i=this;this.options=e;var r=document.createElement("input");if(r.setAttribute("id","slider"),r.setAttribute("type","range"),r.setAttribute("min",e.min),r.setAttribute("max",e.max),r.setAttribute("value",e.min),r.style.width=null!==(t=e.width)&&void 0!==t?t:"100%",!e.plain){var l,a;r.style.setProperty("-webkit-appearance","none"),r.style.appearance="none",r.style.height="9px",r.style.background=null!==(l=e.style.trackColor)&&void 0!==l?l:"orange",r.style.borderRadius="5px";var o="\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!==(a=e.style.thumbColor)&&void 0!==a?a:"4CAF50",";\n cursor: pointer;\n }\n "),u=document.createElement("style");u.appendChild(document.createTextNode(o)),document.head.appendChild(u)}var s=document.createElement("div");s.style.display="flex",s.style.flexDirection="column",s.style.alignItems="center",s.style.width="100%";var d=document.createElement("div");if(d.style.display="flex",d.style.justifyContent="space-between",d.style.width=null!==(n=e.width)&&void 0!==n?n:"100%",this.minLabel=document.createElement("span"),this.minLabel.textContent=e.min,this.maxLabel=document.createElement("span"),this.maxLabel.textContent=e.max,this.currentLabel=document.createElement("span"),this.currentLabel.textContent=r.value,e.font&&(this.currentLabel.style.fontFamily=e.font),e.font&&(this.minLabel.style.fontFamily=e.font),e.font&&(this.maxLabel.style.fontFamily=e.font),e.plain||(d.appendChild(this.minLabel),d.appendChild(this.currentLabel),d.appendChild(this.maxLabel)),r.addEventListener("input",function(){i.currentLabel.textContent=r.value}),window.matchMedia("(max-device-width: 415px)").matches)if(e.plain)r.style.width="80%";else{var c,p;r.style.height="20px",r.style.background=null!==(c=e.style.trackColor)&&void 0!==c?c:"1abc9C",r.style.borderRadius="10px",r.style.fontSize="3rem",r.style.width="80%";var y="\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!==(p=e.style.thumbColor)&&void 0!==p?p:"blue",";\n cursor: pointer;\n }\n "),h=document.createElement("style");h.appendChild(document.createTextNode(y)),document.head.appendChild(h)}return s.appendChild(d),s.appendChild(r),this.el=s,this}},{key:"value",value:function(){return this.el.querySelector("#slider").value}},{key:"render",value:function(e){if(!e)return this.el;document.querySelector(e).appendChild(this.el)}}])&&i(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();window.Range=l;const a=t.Q;export{a as Range};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(()=>{"use strict";var e={d:(t,i)=>{for(var r in i)e.o(i,r)&&!e.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:i[r]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},t={};function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function r(e,t){for(var i=0;i<t.length;i++){var r=t[i];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,o(r.key),r)}}function o(e){var t=function(e){if("object"!=i(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=i(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==i(t)?t:t+""}e.r(t),e.d(t,{ScrollVideo:()=>n});var n=function(){return e=function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.frameNumber=0,this.res=document.createElement("div"),this.vid=null,this.minScrollHeight=0,this.maxScrollHeight=1e3,this.videoUrl=""},t=[{key:"set",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.minScrollHeight,i=void 0===t?0:t,r=e.maxScrollHeight,o=void 0===r?1e3:r,n=e.videoUrl,l=void 0===n?"":n;return this.minScrollHeight=i,this.maxScrollHeight=o,this.videoUrl=l,this.createElements("V0"),this.vid=this.res.children[0],this.init(),this}},{key:"createElements",value:function(e){var t=document.createElement("video");t.id=e,t.setAttribute("tabindex","0"),t.setAttribute("autobuffer","autobuffer"),t.setAttribute("preload","preload"),t.style.position="sticky",t.style.top="0",t.style.left="0",t.style.width="100%",t.style.height="100vh",t.style.border="1px solid orange";var i=document.createElement("source");i.type='video/mp4; codecs="avc1.42E01E, mp4a.40.2"',i.src=this.videoUrl,t.appendChild(i),this.res.appendChild(t);var r=document.createElement("p");r.id="time",r.style.fontFamily="Helvetica, Arial, sans-serif",r.style.fontSize="24px",this.res.appendChild(r);var o=document.createElement("div");o.id="set-height",o.style.display="block",this.setop=o,this.res.appendChild(o)}},{key:"sticky",value:function(){return this.res.style.position="sticky",this.res.style.top=0,this}},{key:"init",value:function(){var e=this;this.vid.addEventListener("loadedmetadata",function(){var t=e.setop;if(t){var i=e.maxScrollHeight-e.minScrollHeight;t.style.height="".concat(i,"px")}else console.error("Error: 'set-height' element not found.")}),this.scrollPlay()}},{key:"scrollPlay",value:function(){var e=this;if(this.vid&&!isNaN(this.vid.duration)){var t=Math.max(this.minScrollHeight,Math.min(window.pageYOffset,this.maxScrollHeight)),i=this.maxScrollHeight-this.minScrollHeight,r=(t-this.minScrollHeight)/i;this.vid.currentTime=r*this.vid.duration,window.requestAnimationFrame(function(){return e.scrollPlay()})}else window.requestAnimationFrame(function(){return e.scrollPlay()})}},{key:"toCode",value:function(){return[""]}},{key:"render",value:function(e){if(!e)return this.res;document.querySelector(e).appendChild(this.res)}}],t&&r(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();module.exports=t})();
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var e={d:(t,i)=>{for(var r in i)e.o(i,r)&&!e.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:i[r]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t)},t={};function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function r(e,t){for(var i=0;i<t.length;i++){var r=t[i];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,o(r.key),r)}}function o(e){var t=function(e){if("object"!=i(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=i(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==i(t)?t:t+""}e.d(t,{z:()=>n});var n=function(){return e=function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.frameNumber=0,this.res=document.createElement("div"),this.vid=null,this.minScrollHeight=0,this.maxScrollHeight=1e3,this.videoUrl=""},t=[{key:"set",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.minScrollHeight,i=void 0===t?0:t,r=e.maxScrollHeight,o=void 0===r?1e3:r,n=e.videoUrl,l=void 0===n?"":n;return this.minScrollHeight=i,this.maxScrollHeight=o,this.videoUrl=l,this.createElements("V0"),this.vid=this.res.children[0],this.init(),this}},{key:"createElements",value:function(e){var t=document.createElement("video");t.id=e,t.setAttribute("tabindex","0"),t.setAttribute("autobuffer","autobuffer"),t.setAttribute("preload","preload"),t.style.position="sticky",t.style.top="0",t.style.left="0",t.style.width="100%",t.style.height="100vh",t.style.border="1px solid orange";var i=document.createElement("source");i.type='video/mp4; codecs="avc1.42E01E, mp4a.40.2"',i.src=this.videoUrl,t.appendChild(i),this.res.appendChild(t);var r=document.createElement("p");r.id="time",r.style.fontFamily="Helvetica, Arial, sans-serif",r.style.fontSize="24px",this.res.appendChild(r);var o=document.createElement("div");o.id="set-height",o.style.display="block",this.setop=o,this.res.appendChild(o)}},{key:"sticky",value:function(){return this.res.style.position="sticky",this.res.style.top=0,this}},{key:"init",value:function(){var e=this;this.vid.addEventListener("loadedmetadata",function(){var t=e.setop;if(t){var i=e.maxScrollHeight-e.minScrollHeight;t.style.height="".concat(i,"px")}else console.error("Error: 'set-height' element not found.")}),this.scrollPlay()}},{key:"scrollPlay",value:function(){var e=this;if(this.vid&&!isNaN(this.vid.duration)){var t=Math.max(this.minScrollHeight,Math.min(window.pageYOffset,this.maxScrollHeight)),i=this.maxScrollHeight-this.minScrollHeight,r=(t-this.minScrollHeight)/i;this.vid.currentTime=r*this.vid.duration,window.requestAnimationFrame(function(){return e.scrollPlay()})}else window.requestAnimationFrame(function(){return e.scrollPlay()})}},{key:"toCode",value:function(){return[""]}},{key:"render",value:function(e){if(!e)return this.res;document.querySelector(e).appendChild(this.res)}}],t&&r(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();const l=t.z;export{l as ScrollVideo};
|
package/dist/scrollvideo.cjs.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/*! For license information please see scrollvideo.cjs.js.LICENSE.txt */
|
|
2
|
-
(()=>{"use strict";var e={d:(t,r)=>{for(var n in r)e.o(r,n)&&!e.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:r[n]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},t={};function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}function n(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,o,s,i,a=[],l=!0,c=!1;try{if(s=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=s.call(r)).done)&&(a.push(n.value),a.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(c)throw o}}return a}}(e,t)||s(e,t)||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(e,t){var r="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=s(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,o=function(){};return{s:o,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:o}}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,a=!0,l=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return a=e.done,e},e:function(e){l=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(l)throw i}}}}function s(e,t){if(e){if("string"==typeof e)return i(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?i(e,t):void 0}}function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function a(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,l(n.key),n)}}function l(e){var t=function(e){if("object"!=r(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=r(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==r(t)?t:t+""}function c(e){return c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},c(e)}function u(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,p(n.key),n)}}function p(e){var t=function(e){if("object"!=c(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=c(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==c(t)?t:t+""}function f(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(f=function(){return!!e})()}function y(e){return y=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},y(e)}function d(e,t){return d=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},d(e,t)}e.r(t),e.d(t,{Video:()=>h});var h=function(e){function t(e){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(r=function(e,t,r){return t=y(t),function(e,t){if(t&&("object"==c(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,f()?Reflect.construct(t,r||[],y(e).constructor):t.apply(e,r))}(this,t)).url=e,r.res=null,r.setup(),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&d(e,t)}(t,e),r=t,(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(e){return this.options=e,e.radius&&(this.res.style.borderRadius=e.radius),e.width&&(this.res.style.width="".concat(e.width)),e.opacity&&(this.res.style.opacity=e.opacity),this}},{key:"size",value:function(e){return this.res.style.width=e,this}},{key:"toCode",value:function(){var e=JSON.stringify(this.options,null,4);return['new Video("'.concat(this.url,'").set(').concat(e,")")]}},{key:"render",value:function(e){if(!e)return this.res;document.querySelector(e).appendChild(this.res)}}])&&u(r.prototype,n),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,n}(function(){return e=function e(){var t,r,n,o=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),t=this,n=function(e){if(console.log("LOBJO IS"),console.log(e),e.transform||e.op&&e.op.transform){var t=e.transform;e.transform||(t=e.op.transform),t.duration||(t.duration="3s-ease-in-out"),o.setDefault=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"0px";return 0===e.length?t+" ":e};var r=function(){var r="",n="",s="",i="",a="",l="",c="",u="",p="";if(0!==t.values.length){t.values.forEach((function(e){e.startsWith("tx:")&&(r=e.replace("tx:","")),e.startsWith("ty:")&&(n=e.replace("ty:","")),e.startsWith("tz:")?s=e.replace("tz:",""):e.startsWith("scale(")?i=e:e.startsWith("skew(")?a=e:e.startsWith("rotate(")?l=function(e){var t=e.match(/rotate\(([^)]+)\)/);if(!t)return e;var r=t[1].split(",").map((function(e){return e.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],")"):e}(e):e.startsWith("perspective(")?c=e:e.startsWith("matrix(")?u=e:e.startsWith("opacity:")&&(p=e.replace("opacity:",""))})),r=o.setDefault(r),n=o.setDefault(n),s=o.setDefault(s);var f="";if("0px"!=n&&"0px"!=r&&"0px"!=s?f+="translate3d(".concat(r,", ").concat(n,", ").concat(s,")"):"0px"==n&&"0px"==r||(f+="translate(".concat(r,", ").concat(n,")")),i&&(f+=" ".concat(i)),l&&(f+=" ".concat(l)),a&&(f+=" ".concat(a)),c&&(f+=" ".concat(c)),u&&(f+=" ".concat(u)),f){if(e.op.transform.duration){var y=e.op.transform.duration.replace(/^(\d+)(s)-/,(function(e,t,r){return t/2+r+" "})),d="transform ".concat(y,", opacity ").concat(y);o.res.style.transition=d}else o.res.style.transition="transform 3s ease-in-out, opacity 3s ease-in-out";e.op.transform.static&&(o.res.style.transition=""),(o.blastTarget||o.res).style.transform=f,o.res.style.opacity=p}else alert("OPE")}};t.on?o.res.addEventListener(t.on,(function(){t.delay?setTimeout((function(){r()}),t.delay):r()})):window.addEventListener("load",(function(){t.delay?setTimeout((function(){r()}),t.delay):r()}));var n=function(){var e="";t.values.forEach((function(t){t.startsWith("tx:")?e+="translateX(0) ":t.startsWith("ty:")?e+="translateY(0) ":t.startsWith("tz:")?e+="translateZ(0) ":t.startsWith("scale(")?e+="scale(1) ":t.startsWith("skew(")?e+="skew(0, 0) ":t.startsWith("rotate(")?e+="rotate(0) ":t.startsWith("perspective(")?e+="perspective(0) ":t.startsWith("matrix(")&&(e+="matrix(1, 0, 0, 1, 0, 0) "),o.res.style.opacity="1"})),e&&(o.res.style.transform=e.trim())};if(t.on)o.res.addEventListener("mouseout",(function(){t.keep||n()}));else{var s=1e3*parseFloat(t.duration),i=t.closeAfter?t.closeAfter:0;setTimeout((function(){t.keep||n()}),s/2+i)}t.hardCSS&&(o.res.style.transform=t.hardCSS)}else alert("THIS FIRE WITH GRADIENT (invalid block"),console.log("INVALID BLOCKA"),console.log(e)},(r=l(r="reactOnTransform"))in t?Object.defineProperty(t,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[r]=n,this.state={isExpanded:!1,isMovedUp:!1,isMovedDown:!1},this.openedElements=new WeakMap},t=[{key:"isHidden",value:function(e){e&&(this.res.style.display="none")}},{key:"keySet",value:function(e){return this.temporaryVal=1,this.res.style[e.key]=e.value,this}},{key:"commonMethods",value:function(e){var t={exact:"fontSize",zIndex:"zIndex",position:"position",top:"top",cursor:"cursor",width:"width",maxWidth:"maxWidth",height:"height",maxHeight:"maxHeight",radius:"borderRadius",lineHeight:"lineHeight",background:"background",font:"fontFamily",opacity:"opacity"};for(var r in t)null!=e[r]&&(this.res.style[t[r]]=e[r]);return e.pad&&this.pad(e.pad),e.mar&&this.mar(e.mar),e.respad&&this.respad(e.respad),e.resmar&&this.resmar(e.resmar),e.hover&&this.hover(e.hover),e.size&&this.fluidCopy(e.size),e.resprop&&this.resprop(e.resprop),e.keySet&&this.keySet(e.keySet),e.hide&&this.isHidden(e.hide),e.bold?this.res.style.fontWeight="bold":null!=e.weight&&(this.res.style.fontWeight=e.weight),this}},{key:"hover",value:function(e){var t=this;if(e.border){var r=e.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,e.animation&&(this.res.style.transition="".concat(e.animation),this.res.style.transionProperty="background, color"),this.res.onmouseout=function(){t.res.style.backgroundColor="".concat(t.prevColor),t.res.style.color="".concat(t.foreColor),t.res.style.border=t.prevBorder},this.res.onmouseover=function(){if(t.res.style.color=e.color,t.res.style.backgroundColor=e.background,e.border){var r,n=e.border.width,o=null!==(r=e.border.color)&&void 0!==r?r:"#2ECC71";t.res.style.border=n?"".concat(n,"px solid ").concat(o):"1px solid #2ECC71"}},this}},{key:"onScroll",value:function(e){var t=this;"opacity"===e.value?this.res.style.opacity=e.valMin:"scale"===e.value&&(this.res.style.transform="scale(".concat(e.valMax,")")),window.addEventListener("scroll",(function(){var r=t.smartRange(window.scrollY,{min:e.from,max:e.to},{min:e.valMin,max:e.valMax});"opacity"===e.value?t.res.style.opacity=r:"scale"===e.value&&(t.res.style.transform="scale(".concat(r,")"))}))}},{key:"setAny",value:function(e){this[Object.keys(e)[0]]=[Object.values(e)[0]]}},{key:"setID",value:function(e){this.id=e}},{key:"setPrevText",value:function(e){this.prevText=e}},{key:"getCSS",value:function(){return this.css}},{key:"getPX",value:function(e){return{xs:"0px",sm:"576px",md:"768px",lg:"992px",xl:"1200px",xxl:"1400px",mxxl:"1800px"}[e]||"Invalid breakpoint"}},{key:"respad",value:function(e){var t=this;this._applyResponsive(e,(function(e){console.log("Applying padding for",e.breakpoint),t.pad(e.values)}))}},{key:"_applyResponsive",value:function(e,t){var r={default:0,xs:0,sm:576,md:768,lg:992,xl:1200,xxl:1400};e.forEach((function(e){void 0!==r[e.breakpoint]?e._value=r[e.breakpoint]:e._value=parseInt(e.breakpoint,10)})),e.sort((function(e,t){return e._value-t._value}));var n=e.find((function(e){return"default"===e.breakpoint})),o=function(){for(var r=window.innerWidth,o=n||null,s=0;s<e.length;s++){var i=e[s];if("default"!==i.breakpoint&&r<=i._value){o=i;break}}o&&t(o)};this._responsiveHandler&&window.removeEventListener("resize",this._responsiveHandler),this._responsiveHandler=o,window.addEventListener("resize",o),o()}},{key:"resmar",value:function(e){var t=this;this._applyResponsive(e,(function(e){console.log("Applying margin for",e.breakpoint),t.mar(e.values)}))}},{key:"resprop",value:function(e){var t=this;this.prevStyles={};for(var r=0;r<this.res.style.length;r++){var n=this.res.style[r];this.prevStyles[n]=this.res.style[n]}this._applyResponsive(e,(function(e){for(var r in console.log("Applying styles for",e.breakpoint),t.prevStyles)t.res.style[r]=t.prevStyles[r];for(var n in e)"breakpoint"!==n&&"_value"!==n&&"values"!==n&&(t.res.style[n]=e[n])}))}},{key:"isNumber",value:function(e){return"number"==typeof e&&!isNaN(e)}},{key:"pad",value:function(e){for(var t=0;t<e.length;t++)for(var r=Object.keys(e[t]),n=0;n<r.length;n++)for(var o=r[n],s=e[t][o],i=0;i<o.length;i++)switch(o[i]){case"a":this.res.style.padding=this.isNumber(s)?"".concat(s,"px"):s;break;case"t":this.res.style.paddingTop=this.isNumber(s)?"".concat(s,"px"):s;break;case"l":this.res.style.paddingLeft=this.isNumber(s)?"".concat(s,"px"):s;break;case"r":this.res.style.paddingRight=this.isNumber(s)?"".concat(s,"px"):s;break;case"b":this.res.style.paddingBottom=this.isNumber(s)?"".concat(s,"px"):s}return this}},{key:"as",value:function(e){return this.res.style.alignSelf=e,this}},{key:"mar",value:function(e){for(var t=0;t<e.length;t++)for(var r=Object.keys(e[t]),n=0;n<r.length;n++)for(var o=r[n],s=e[t][o],i=0;i<o.length;i++){switch(o[i]){case"a":this.res.style.margin=this.isNumber(s)?"".concat(s,"px"):s;break;case"t":this.res.style.marginTop=this.isNumber(s)?"".concat(s,"px"):s;break;case"l":this.res.style.marginLeft=this.isNumber(s)?"".concat(s,"px"):s;break;case"r":this.res.style.marginRight=this.isNumber(s)?"".concat(s,"px"):s;break;case"b":this.res.style.marginBottom=this.isNumber(s)?"".concat(s,"px"):s}"auto"===o[i]&&(this.res.style.marginLeft="auto",this.res.style.marginRight="auto")}return this}},{key:"smartRange",value:function(e,t,r){e<t.min&&(e=t.min),e>t.max&&(e=t.max);var n=(e-t.min)/(t.max-t.min);t.min>t.max&&(n=(e-t.max)/(t.min-t.max));var o=(r.min-r.max)*n-r.min;if(o=Math.abs(o),r.min<r.max){var s=(r.max+Math.abs(r.min))*n;o=r.min+s}return o}},{key:"gpos",value:function(e){return this.res.style.gridColumn=e.col,this.res.style.gridRow=e.row,this}},{key:"fluidCopy",value:function(e){if(e instanceof Object){this.prevStylex=this.res.style,this.res=document.createElement("h1"),this.res.style.cssText=this.prevStylex.cssText;var t=document.createTextNode(this.text);return this.res.appendChild(t),this.res.style.fontSize=e.exact,this}if("S1"===e){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"===e){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"===e){this.prevStylex=this.res.style,this.res=document.createElement("h3"),this.res.style.cssText=this.prevStylex.cssText;var o=document.createTextNode(this.text);this.res.appendChild(o),this.res.style.fontSize="calc(1.375rem + 3.525vw)"}if("S4"===e){this.prevStylex=this.res.style,this.res=document.createElement("h4"),this.res.style.cssText=this.prevStylex.cssText;var s=document.createTextNode(this.text);this.res.appendChild(s),this.res.style.fontSize="calc(1.250rem + 2.75vw)"}if("S5"===e){this.prevStylex=this.res.style,this.res=document.createElement("h5"),this.res.style.cssText=this.prevStylex.cssText;var i=document.createTextNode(this.text);this.res.appendChild(i),this.res.style.fontSize="calc(1.125rem + 1.975vw)"}return"S6"===e&&(this.res.style.fontSize="calc(1rem + 0.5vw)"),this}},{key:"setIndex",value:function(e){this.index=e}},{key:"borderObj",value:function(e){var t,r=null!==(t=e.type)&&void 0!==t?t:"solid";return this.res.style.border="".concat(e.width," ").concat(r," ").concat(e.color),this.res.style.borderRadius=e.radius,this}},{key:"setPref",value:function(e){this.preffersId=e}},{key:"setClass",value:function(e){this.class=e}},{key:"setTags",value:function(e){this.openTag=e.open,this.closeTag=e.close,console.log("TAGS SET"),console.log(e)}},{key:"chainReact",value:function(e,t,r){var s=this;console.log("0P"),this.ap=!1,this.cta=0,this.once=!1;var i,a=o(e);try{for(a.s();!(i=a.n()).done;){var l=i.value;l.range||(l.range=["0px","999999px"])}}catch(e){a.e(e)}finally{a.f()}e.sort((function(e,t){return parseInt(e.range[0])-parseInt(t.range[0])}));var c=function(i){var a=window.visualViewport.width,l=[],c=[];s.resCopy=s.res,s.storedQueries=e.map((function(e){return e.target})).filter((function(e){return null!=e}));var u,p=o(e);try{for(p.s();!(u=p.n()).done;){var f=u.value;s.counterIndex++;var y=n(f.range,2),d=y[0],h=y[1],v=parseInt(d),m=parseInt(h),b=!0;if(f.target){b=!1;for(var g=0;g<f.target.length;g++)f.target[g]===t&&(b=!0)}a>=v&&a<=m&&b&&(l.push(f.log),c.push(f),f.op&&f.op.margin&&(s.useMargin=f.op.margin))}}catch(e){p.e(e)}finally{p.f()}if(r&&!r.includes("background")&&(s.res.style.background="",s.res.style.backgroundColor=""),s.res.style.textShadow="",r&&!r.includes("border")&&(s.res.style.border=""),r&&!r.includes("margin")&&(s.res.style.margin=""),s.res.style["-webkit-text-fill-color"]="",s.res.style["-webkit-text-stroke-color"]="",s.res.style["-webkit-text-stroke-width"]="",s.res.style.filter="",s.options.background&&(console.log(s.options.background),s.res.style.background=s.options.background),l.includes("gradient"),(l.includes("gradient")||l.includes("shadow"))&&(s.res.style.position="relative"),l.includes("blast")){var x,w=c.filter((function(e){return"blast"===e.log}))[0].op.color,k=null!==(x=c.filter((function(e){return"blast"===e.log}))[0].op.width)&&void 0!==x?x:"1px";"FlexRowLayoutElement"===s.getType()||"LayoutWrapperElement"===s.getType()?(s.res.style.border="".concat("number"==typeof k?k+"px":k," solid orange"),s.res.style.display="inline-block","FlexRowLayoutElement"===s.getType()&&(s.res.style.display="flex"),s.res.style.boxSizing="border-box",s.res.style.transformOrigin="center",s.blastTarget=s.res):(s.text,s.res.style["-webkit-text-fill-color"]="transparent",s.res.style["-webkit-text-stroke-color"]=w,s.res.style["-webkit-text-stroke-width"]="".concat(k))}if(l.includes("filter")){var S=c.filter((function(e){return"filter"===e.log}))[0].op.filter;s.res.style.filter=S}if(l.includes("background")&&(s.res.style.backgroundColor="green"),l.includes("gradient")&&("LayoutWrapperElement"!==s.getType()&&"FlexRowLayoutElement"!==s.getType()&&(s.res.style["-webkit-text-fill-color"]="transparent"),s.res.style.background=s.globalGradient,"LayoutWrapperElement"!==s.getType()&&"FlexRowLayoutElement"!==s.getType()&&(s.res.style["background-clip"]="text")),l.includes("shadow")){var T,E,O,C,j=s.options.shadow.op;console.log("OP IS",j);var W=null!==(T=j.steps)&&void 0!==T?T:1,A=null!==(E=j.colors)&&void 0!==E?E:["gray"],L=null!==(O=j.movements)&&void 0!==O?O:["3px","3px"],I=null!==(C=j.radius)&&void 0!==C?C:"3px";if(1===L.length&&(L=[L[0],L[0]]),"FlexRowLayoutElement"===s.getType()||"LayoutWrapperElement"===s.getType()){for(var P=[],R=0;R<W;R++){var N,_=null!==(N=A[R])&&void 0!==N?N:A[0],z=L[0],M=L[1];P.push("".concat(z," ").concat(M," ").concat(I," ").concat(_))}s.res.style.boxShadow=P.join(", ")}else{for(var F=[],B=0;B<W;B++){var H,D=null!==(H=A[B])&&void 0!==H?H:A[0],V=L[0],Y=L[1];F.push("drop-shadow(".concat(V," ").concat(Y," ").concat(I," ").concat(D,")"))}s.res.style.filter=F.join(" ")}}if(l.includes("margin"))for(g=0;g<e.length;g++)if(e[g].op){var X=e[g].op.offsets;X&&void 0!==s.index&&(s.res.style.margin=X[Number(s.index)]+"px")}if(l.includes("spana")||l.includes("span")){var G=document.createElement("div");if(G.setAttribute("id","oroa"),Object.assign(G.style,{position:"absolute",inset:"0",background:"linear-gradient(90deg, rgb(52,152,219), rgb(26,188,156))",WebkitBackgroundClip:"text",WebkitTextFillColor:"transparent",pointerEvents:"none"}),s.res&&s.res.querySelector("span"))return;s.res=s.resCopy,s.res.textContent="",s.options.span&&(Array.isArray(s.options.span)?s.options.span:[s.options.span]).forEach((function(e){if(e.op&&"span"===e.op.name&&Array.isArray(e.op.parts)){var t=0,r=s.prevText||"";if(e.op.parts.forEach((function(e){var n=e.text,o=e.style||{};if(t<r.length){var i=r.indexOf(n,t);if(i>t){var a=r.substring(t,i);s.res.appendChild(new s.constructor(a).setup({type:"span",id:o.id,animation:o.animation}).set({}).render())}t=i+n.length}var l=new s.constructor(n).setup({type:"span",id:o.id,animation:o.animation}).set(o).render();s.res.appendChild(l)})),t<r.length){var n=r.substring(t);s.res.appendChild(new s.constructor(n).setup({type:"span"}).set({}).render())}}}))}else{var q=new s.constructor(s.prevText).set({}).render();s.prevText&&s.prevText.length>0&&i&&s.res.appendChild(q)}if(l.includes("animation")){if(s.options.animation&&!s.hasAnimated&&!s.options.animation.op.fireAt){console.warn(s.openTag),s.hasAnimated=!0;var J=s.options.animation.op;window.addEventListener("sidebar:open",(function(){s.res.animate(J.keyframesOpen,J.openOptions)})),window.addEventListener("sidebar:closed",(function(){s.res.animate(J.keyframesClose,J.closeOptions)})),s.res.animate(J.keyframesClose,{duration:0,fill:"forwards"}),s.openTag&&s.closeTag&&(window.addEventListener(s.openTag,(function(){s.res.animate(J.keyframesOpen,J.openOptions)})),window.addEventListener(s.closeTag,(function(){s.res.animate(J.keyframesClose,J.closeOptions)})))}if(s.options.animation&&s.options.animation.op.fireAt&&s.options.animation.op.fireAt.endsWith("px")){var Q=s.options.animation.op;s.res.animate(Q.keyframesClose,{duration:0,fill:"forwards"});var U=function(){window.scrollY>parseFloat(Q.fireAt)&&(s.res.animate(Q.keyframesOpen,Q.openOptions),window.removeEventListener("scroll",U))};window.addEventListener("scroll",U)}if(s.options.animation&&"inview"===s.options.animation.op.fireAt){var $=s.options.animation.op;s.res.animate($.keyframesClose,{duration:0,fill:"forwards"});var K=!1;new IntersectionObserver((function(e,t){e.forEach((function(e){e.isIntersecting&&!K&&(K=!0,s.res.animate($.keyframesOpen,$.openOptions),t.disconnect())}))})).observe(s.res)}}};this.options.animation||window.addEventListener("resize",(function(){return c()})),c()}},{key:"maxWidth",value:function(e){return this.res.style.maxWidth=e,this}},{key:"removeQuotesFromFirstWord",value:function(e){return e.replace(/"([^"]+)":/g,"$1:")}},{key:"arrayMargin",value:function(e,t){return e.includes("left")&&(this.res.style.marginLeft=t),e.includes("right")&&(this.res.style.marginRight=t),e.includes("top")&&(this.res.style.marginTop=t),e.includes("bottom")&&(this.res.style.marginBottom=t),e.includes("all")&&(this.res.style.margin=t),t||(this.res.style.marginBottom=e),this}}],t&&a(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}());module.exports=t})();
|
|
2
|
+
(()=>{"use strict";var e={d:(t,i)=>{for(var r in i)e.o(i,r)&&!e.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:i[r]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},t={};function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function r(e,t){for(var i=0;i<t.length;i++){var r=t[i];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,o(r.key),r)}}function o(e){var t=function(e){if("object"!=i(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=i(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==i(t)?t:t+""}e.r(t),e.d(t,{ScrollVideo:()=>n});var n=function(){return e=function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.frameNumber=0,this.res=document.createElement("div"),this.vid=null,this.minScrollHeight=0,this.maxScrollHeight=1e3,this.videoUrl=""},t=[{key:"set",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.minScrollHeight,i=void 0===t?0:t,r=e.maxScrollHeight,o=void 0===r?1e3:r,n=e.videoUrl,l=void 0===n?"":n;return this.minScrollHeight=i,this.maxScrollHeight=o,this.videoUrl=l,this.createElements("V0"),this.vid=this.res.children[0],this.init(),this}},{key:"createElements",value:function(e){var t=document.createElement("video");t.id=e,t.setAttribute("tabindex","0"),t.setAttribute("autobuffer","autobuffer"),t.setAttribute("preload","preload"),t.style.position="sticky",t.style.top="0",t.style.left="0",t.style.width="100%",t.style.height="100vh",t.style.border="1px solid orange";var i=document.createElement("source");i.type='video/mp4; codecs="avc1.42E01E, mp4a.40.2"',i.src=this.videoUrl,t.appendChild(i),this.res.appendChild(t);var r=document.createElement("p");r.id="time",r.style.fontFamily="Helvetica, Arial, sans-serif",r.style.fontSize="24px",this.res.appendChild(r);var o=document.createElement("div");o.id="set-height",o.style.display="block",this.setop=o,this.res.appendChild(o)}},{key:"sticky",value:function(){return this.res.style.position="sticky",this.res.style.top=0,this}},{key:"init",value:function(){var e=this;this.vid.addEventListener("loadedmetadata",function(){var t=e.setop;if(t){var i=e.maxScrollHeight-e.minScrollHeight;t.style.height="".concat(i,"px")}else console.error("Error: 'set-height' element not found.")}),this.scrollPlay()}},{key:"scrollPlay",value:function(){var e=this;if(this.vid&&!isNaN(this.vid.duration)){var t=Math.max(this.minScrollHeight,Math.min(window.pageYOffset,this.maxScrollHeight)),i=this.maxScrollHeight-this.minScrollHeight,r=(t-this.minScrollHeight)/i;this.vid.currentTime=r*this.vid.duration,window.requestAnimationFrame(function(){return e.scrollPlay()})}else window.requestAnimationFrame(function(){return e.scrollPlay()})}},{key:"toCode",value:function(){return[""]}},{key:"render",value:function(e){if(!e)return this.res;document.querySelector(e).appendChild(this.res)}}],t&&r(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();module.exports=t})();
|
package/dist/scrollvideo.esm.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/*! For license information please see scrollvideo.esm.js.LICENSE.txt */
|
|
2
|
-
var e={d:(t,i)=>{for(var r in i)e.o(i,r)&&!e.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:i[r]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t)},t={};function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function r(e,t){for(var i=0;i<t.length;i++){var r=t[i];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,o(r.key),r)}}function o(e){var t=function(e){if("object"!=i(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=i(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==i(t)?t:t+""}e.d(t,{z:()=>n});var n=function(){return e=function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.frameNumber=0,this.res=document.createElement("div"),this.vid=null,this.minScrollHeight=0,this.maxScrollHeight=1e3,this.videoUrl=""},t=[{key:"set",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.minScrollHeight,i=void 0===t?0:t,r=e.maxScrollHeight,o=void 0===r?1e3:r,n=e.videoUrl,l=void 0===n?"":n;return this.minScrollHeight=i,this.maxScrollHeight=o,this.videoUrl=l,this.createElements("V0"),this.vid=this.res.children[0],this.init(),this}},{key:"createElements",value:function(e){var t=document.createElement("video");t.id=e,t.setAttribute("tabindex","0"),t.setAttribute("autobuffer","autobuffer"),t.setAttribute("preload","preload"),t.style.position="sticky",t.style.top="0",t.style.left="0",t.style.width="100%",t.style.height="100vh",t.style.border="1px solid orange";var i=document.createElement("source");i.type='video/mp4; codecs="avc1.42E01E, mp4a.40.2"',i.src=this.videoUrl,t.appendChild(i),this.res.appendChild(t);var r=document.createElement("p");r.id="time",r.style.fontFamily="Helvetica, Arial, sans-serif",r.style.fontSize="24px",this.res.appendChild(r);var o=document.createElement("div");o.id="set-height",o.style.display="block",this.setop=o,this.res.appendChild(o)}},{key:"sticky",value:function(){return this.res.style.position="sticky",this.res.style.top=0,this}},{key:"init",value:function(){var e=this;this.vid.addEventListener("loadedmetadata",
|
|
2
|
+
var e={d:(t,i)=>{for(var r in i)e.o(i,r)&&!e.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:i[r]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t)},t={};function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function r(e,t){for(var i=0;i<t.length;i++){var r=t[i];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,o(r.key),r)}}function o(e){var t=function(e){if("object"!=i(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=i(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==i(t)?t:t+""}e.d(t,{z:()=>n});var n=function(){return e=function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.frameNumber=0,this.res=document.createElement("div"),this.vid=null,this.minScrollHeight=0,this.maxScrollHeight=1e3,this.videoUrl=""},t=[{key:"set",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.minScrollHeight,i=void 0===t?0:t,r=e.maxScrollHeight,o=void 0===r?1e3:r,n=e.videoUrl,l=void 0===n?"":n;return this.minScrollHeight=i,this.maxScrollHeight=o,this.videoUrl=l,this.createElements("V0"),this.vid=this.res.children[0],this.init(),this}},{key:"createElements",value:function(e){var t=document.createElement("video");t.id=e,t.setAttribute("tabindex","0"),t.setAttribute("autobuffer","autobuffer"),t.setAttribute("preload","preload"),t.style.position="sticky",t.style.top="0",t.style.left="0",t.style.width="100%",t.style.height="100vh",t.style.border="1px solid orange";var i=document.createElement("source");i.type='video/mp4; codecs="avc1.42E01E, mp4a.40.2"',i.src=this.videoUrl,t.appendChild(i),this.res.appendChild(t);var r=document.createElement("p");r.id="time",r.style.fontFamily="Helvetica, Arial, sans-serif",r.style.fontSize="24px",this.res.appendChild(r);var o=document.createElement("div");o.id="set-height",o.style.display="block",this.setop=o,this.res.appendChild(o)}},{key:"sticky",value:function(){return this.res.style.position="sticky",this.res.style.top=0,this}},{key:"init",value:function(){var e=this;this.vid.addEventListener("loadedmetadata",function(){var t=e.setop;if(t){var i=e.maxScrollHeight-e.minScrollHeight;t.style.height="".concat(i,"px")}else console.error("Error: 'set-height' element not found.")}),this.scrollPlay()}},{key:"scrollPlay",value:function(){var e=this;if(this.vid&&!isNaN(this.vid.duration)){var t=Math.max(this.minScrollHeight,Math.min(window.pageYOffset,this.maxScrollHeight)),i=this.maxScrollHeight-this.minScrollHeight,r=(t-this.minScrollHeight)/i;this.vid.currentTime=r*this.vid.duration,window.requestAnimationFrame(function(){return e.scrollPlay()})}else window.requestAnimationFrame(function(){return e.scrollPlay()})}},{key:"toCode",value:function(){return[""]}},{key:"render",value:function(e){if(!e)return this.res;document.querySelector(e).appendChild(this.res)}}],t&&r(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t}();const l=t.z;export{l as ScrollVideo};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(()=>{"use strict";var e={d:(t,n)=>{for(var r in n)e.o(n,r)&&!e.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:n[r]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},t={};function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,i(r.key),r)}}function i(e){var t=function(e){if("object"!=n(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=n(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==n(t)?t:t+""}function o(){return o="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(e,t,n){var r=function(e,t){for(;!{}.hasOwnProperty.call(e,t)&&null!==(e=l(e)););return e}(e,t);if(r){var i=Object.getOwnPropertyDescriptor(r,t);return i.get?i.get.call(arguments.length<3?e:n):i.value}},o.apply(null,arguments)}function l(e){return l=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},l(e)}e.r(t),e.d(t,{SideBar:()=>a});var a=function(){function e(t,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.ele=null,this.width="16em",this.height="100vh",this.els=t}return t=e,n=[{key:"setup",value:function(t){var n,r,i,a=this;t.tags&&(n=e,r=this,"function"==typeof(i=o(l(1&3?n.prototype:n),"setTags",r))?function(e){return i.apply(r,e)}:i)([t.tags]),t.width&&(this.width=t.width),t.height&&(this.height=t.height);var s=document.createElement("div");s.style.position="absolute";var c=document.createElement("button");c.style.position="absolute",c.style.background="white",c.style.opacity=.8,c.style.border="none",c.width="1.5em",c.height="1.5em",c.style.borderRadius="50%",c.style.zIndex=2;var u=document.createTextNode("☰");c.appendChild(u),c.style.fontSize="2em",window.matchMedia("(max-device-width: 400px)").matches&&(c.style.fontSize="6em"),window.matchMedia("(max-device-width: 400px)").matches&&t.fullMobile&&(this.width="100vw"),s.appendChild(c);var d=document.createElement("div");return d.style.position="absolute",d.style.backgroundColor="#fff",d.style.flexDirection="column",d.style.display="flex",d.style.alignItems="center",d.style.margin=0,d.style.padding=0,d.style.width=this.width,d.style.margin=0,d.style.marginTop="-10px",d.style.paddingTop="1em",d.style.paddingBottom="1em",d.style.height="".concat(this.height),d.style.transform="translateX(-".concat(this.width,")"),d.style.transition="all 0.80s",s.appendChild(d),this.hidden=!1,c.addEventListener("click",function(){a.hidden=!a.hidden;for(var e=0;e<d.children.length;e++)"☰"!==d.textContent&&(a.hidden?d.style.transform="translateX(0em)":d.style.transform="translateX(-".concat(a.width,")"))}),this.ele=s,this.els&&this.items(this.els),this}},{key:"background",value:function(e){return this.ele.children[1].style.backgroundColor=e.color,this.ele.children[1].style.opacity=e.opacity,this}},{key:"items",value:function(e){this.itemCount=e.length;for(var t=0;t<e.length;t++)this.ele.children[1].appendChild(e[t].render());return this}},{key:"render",value:function(e){return e?(document.querySelector(e).style.padding=0,document.querySelector(e).style.margin=0,document.querySelector(e).appendChild(this.ele),this.ele):this.ele}}],n&&r(t.prototype,n),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,n}();module.exports=t})();
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var t={d:(e,n)=>{for(var i in n)t.o(n,i)&&!t.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:n[i]})},o:(t,e)=>Object.prototype.hasOwnProperty.call(t,e)},e={};function n(t){return n="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},n(t)}function i(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,r(i.key),i)}}function r(t){var e=function(t){if("object"!=n(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,"string");if("object"!=n(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==n(e)?e:e+""}function o(){return o="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(t,e,n){var i=function(t,e){for(;!{}.hasOwnProperty.call(t,e)&&null!==(t=l(t)););return t}(t,e);if(i){var r=Object.getOwnPropertyDescriptor(i,e);return r.get?r.get.call(arguments.length<3?t:n):r.value}},o.apply(null,arguments)}function l(t){return l=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},l(t)}t.d(e,{z:()=>a});var a=function(){function t(e,n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.ele=null,this.width="16em",this.height="100vh",this.els=e}return e=t,n=[{key:"setup",value:function(e){var n,i,r,a=this;e.tags&&(n=t,i=this,"function"==typeof(r=o(l(1&3?n.prototype:n),"setTags",i))?function(t){return r.apply(i,t)}:r)([e.tags]),e.width&&(this.width=e.width),e.height&&(this.height=e.height);var s=document.createElement("div");s.style.position="absolute";var c=document.createElement("button");c.style.position="absolute",c.style.background="white",c.style.opacity=.8,c.style.border="none",c.width="1.5em",c.height="1.5em",c.style.borderRadius="50%",c.style.zIndex=2;var u=document.createTextNode("☰");c.appendChild(u),c.style.fontSize="2em",window.matchMedia("(max-device-width: 400px)").matches&&(c.style.fontSize="6em"),window.matchMedia("(max-device-width: 400px)").matches&&e.fullMobile&&(this.width="100vw"),s.appendChild(c);var d=document.createElement("div");return d.style.position="absolute",d.style.backgroundColor="#fff",d.style.flexDirection="column",d.style.display="flex",d.style.alignItems="center",d.style.margin=0,d.style.padding=0,d.style.width=this.width,d.style.margin=0,d.style.marginTop="-10px",d.style.paddingTop="1em",d.style.paddingBottom="1em",d.style.height="".concat(this.height),d.style.transform="translateX(-".concat(this.width,")"),d.style.transition="all 0.80s",s.appendChild(d),this.hidden=!1,c.addEventListener("click",function(){a.hidden=!a.hidden;for(var t=0;t<d.children.length;t++)"☰"!==d.textContent&&(a.hidden?d.style.transform="translateX(0em)":d.style.transform="translateX(-".concat(a.width,")"))}),this.ele=s,this.els&&this.items(this.els),this}},{key:"background",value:function(t){return this.ele.children[1].style.backgroundColor=t.color,this.ele.children[1].style.opacity=t.opacity,this}},{key:"items",value:function(t){this.itemCount=t.length;for(var e=0;e<t.length;e++)this.ele.children[1].appendChild(t[e].render());return this}},{key:"render",value:function(t){return t?(document.querySelector(t).style.padding=0,document.querySelector(t).style.margin=0,document.querySelector(t).appendChild(this.ele),this.ele):this.ele}}],n&&i(e.prototype,n),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,n}();const s=e.z;export{s as SideBar};
|