Plugin Directory

Changeset 2765301


Ignore:
Timestamp:
08/02/2022 04:56:21 PM (4 years ago)
Author:
aseran
Message:

Update concept, less js/css animation code of preloader

Location:
vmv-preloader/trunk
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • vmv-preloader/trunk/vmv-preloader.php

    r2735219 r2765301  
    5151define( 'VMV_ONE__AJAX_URL', admin_url( 'admin-ajax.php' ) );
    5252define( 'VMV_ONE__PLUGIN_URL', plugin_dir_url( __FILE__ ) );
    53 define( 'VMV_ONE__PLUGIN_VERSION', '1.0.0' );
     53define( 'VMV_ONE__PLUGIN_VERSION', '1.1.0' );
    5454
    5555foreach ( glob( VMV_ONE__PLUGIN_DIR . '*.php' ) as $file ) {
    5656  require_once( $file );
    5757}
    58 add_action( 'admin_enqueue_scripts', 'vmv_preloader_frontend' );
    59 add_action( 'admin_menu', 'vmv_preloader_setup_menu' );
     58add_action( 'admin_enqueue_scripts', 'vmv_admin_frontend' );
     59add_action( 'admin_menu', 'vmv_admin_setup_menu' );
    6060add_action( 'init', 'vmv_preloader_activate' );
     61
     62// Plugin init actions
     63add_action( 'wp_head', 'vmv_preloader_head_section', 1 );
     64add_action( 'wp_footer', 'vmv_preloader_footer_section', 1 );
    6165
    6266// ajax actions
     
    6872add_action( 'wp_ajax_vmv_list_premium_animations', 'vmv_list_premium_animations' );
    6973
    70 // Init preloader script
    71 add_action( 'wp_head', 'vmv_preloader_animation_script', 1 );
    72 add_filter( 'plugin_action_links', 'vmv_preloader_plugin_links', 10, 2 );
     74add_filter( 'plugin_action_links', 'vmv_admin_plugin_links', 10, 2 );
    7375
    7476register_activation_hook( VMV_ONE__PLUGIN_FILE, 'vmv_preloader_on_activation' );
  • vmv-preloader/trunk/vmv/front-end-vue3/dist/assets/index.js

    r2735219 r2765301  
    1 import{d as se,i as oe,a as P,r as _,s as W,o as X,P as z,w as V,c as F,b as m,e as v,u as a,f as e,g as U,v as Y,h as A,j as E,k as l,l as p,n as g,S as ae,m as C,t as b,F as k,p as j,L as I,q as R,T,x as B,y as L,z as O,A as K,B as H,C as N,D as $,E as le,G as re,H as ne,I as ie,J as de,K as ce,M as ue,N as M,O as fe,Q as me,R as he,U as q,V as ve,W as pe,X as _e,Y as ge,Z as xe}from"./vendor.js";const be=function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))i(o);new MutationObserver(o=>{for(const r of o)if(r.type==="childList")for(const u of r.addedNodes)u.tagName==="LINK"&&u.rel==="modulepreload"&&i(u)}).observe(document,{childList:!0,subtree:!0});function s(o){const r={};return o.integrity&&(r.integrity=o.integrity),o.referrerpolicy&&(r.referrerPolicy=o.referrerpolicy),o.crossorigin==="use-credentials"?r.credentials="include":o.crossorigin==="anonymous"?r.credentials="omit":r.credentials="same-origin",r}function i(o){if(o.ep)return;o.ep=!0;const r=s(o);fetch(o.href,r)}};be();function we(n){const t=n.indexOf("__"),s=n.substring(t+2,n.length-3);return atob(s).split(",")}function ye(n){const t=n.indexOf("__");return n.substring(0,t)}function G(n,t){const i=ye(n).replace(/([A-Z])/g," $1"),o=i.charAt(0).toUpperCase()+i.slice(1);return{value:n,isPremium:t,name:o}}const w=se("appStore",{state:()=>({savingData:!1,formAction:null,formKey:null,dataLoaded:!1,listDefaultThemes:null,listPremiumThemes:null,countReloadDemo:0,countResetData:0,saveCount:0,serverData:null,availableParams:null,dataForm:{vmv_preloader:"end",pluginActivated:!1,c1:"#ffffff",l1:"Site name",w1:0,w2:0,w3:0,w4:0,b0:"",b1:"",b2:"",b3:"radial",b4:"at top",t1:10,t2:5,t4:null,themeFile:"KadisokaFont__bDEsYzEsYzIsYix3LHQ=.js",isPremium:!1}}),getters:{dataIsChange:n=>!oe(n.serverData,n.dataForm),listThemes:n=>{const t=[];return Array.isArray(n.listDefaultThemes)&&n.listDefaultThemes.forEach(s=>{t.push(G(s,!1))}),Array.isArray(n.listPremiumThemes)&&n.listPremiumThemes.forEach(s=>{t.push(G(s,!0))}),t}},actions:{updateParamsSettings(){this.availableParams=we(this.dataForm.themeFile)},async saveData(){if(!this.savingData){this.savingData=!0,this.dataForm.t4=new Date().getTime();const n=new FormData;n.append("action","vmv_set_params"),n.append("vmv_token",this.formKey);for(let t in this.dataForm)n.append(t,this.dataForm[t]);await P.post(this.formAction,n),this.savingData=!1,this.serverData=Object.assign({},this.dataForm),this.saveCount++,this.countReloadDemo++,this.updateParamsSettings()}},async loadData(){{let n=new FormData;n.append("action","vmv_get_params"),n.append("vmv_token",this.formKey);const t=await P.post(this.formAction,n);this.dataForm=Object.assign({},t.data.options),this.serverData=Object.assign({},t.data.options)}this.countResetData++,this.dataLoaded=!0,this.updateParamsSettings()},async getListFilesAnimation(){var n;{let t=new FormData;t.append("action","vmv_list_base_animations"),t.append("vmv_token",this.formKey);const s=await P.post(this.formAction,t);this.listDefaultThemes=(n=s==null?void 0:s.data)==null?void 0:n.data.list_files}},async getListFilesAnimationPremium(){var n;{let t=new FormData;t.append("action","vmv_list_premium_animations"),t.append("vmv_token",this.formKey);const s=await P.post(this.formAction,t);this.listPremiumThemes=(n=s==null?void 0:s.data)==null?void 0:n.data.list_files}},async deleteFile(n){let t=new FormData;t.append("action","vmv_delete_file_premium_animations"),t.append("vmv_token",this.formKey),t.append("filename_to_delete",n),await P.post(this.formAction,t),this.getListFilesAnimationPremium()}}});var S={preview:!0,opacity:!1,hue:!0,interaction:{hex:!1,rgba:!1,hsla:!1,hsva:!1,cmyk:!1,input:!0,clear:!1,save:!0}};const $e=e("div",{class:"mb-4 font-bold text-sm uppercase text-gray-600"}," Base settings ",-1),ke={key:0},Fe=e("div",{class:"text-xs text-gray-400 font-medium mb-2"},"Animated text",-1),Ae={class:"relative mb-4"},Ve=e("div",{class:"absolute left-0 w-full pr-1 mt-1 text-xs leading-none text-right text-red-500 top-full"},[e("div",{class:"hidden"},"Field is required")],-1),Pe={class:"flex space-x-4"},Ce={class:"w-1/2"},De=e("div",{class:"text-xs text-gray-400 font-medium mb-2"},"Filling color",-1),Te={class:"pickr-wrapper w-full h-9 self-end flex-shrink-0 rounded inline-block ring-2 ring-white shadow-round"},ze={class:"w-1/2"},Se=e("div",{class:"text-xs text-gray-400 font-medium mb-2"},"Color shadow",-1),Le={class:"pickr-wrapper w-full h-9 self-end flex-shrink-0 rounded inline-block ring-2 ring-white shadow-round"},Me={setup(n){let t,s;const i=_(null),o=_(null),r=_(""),u=Object.assign({},S);u.opacity=!0;const c=w(),{availableParams:h}=W(c);r.value=c.dataForm.l1,X(()=>{t=z.create({el:i.value,default:c.dataForm.c1,theme:"nano",components:S}),t.on("save",(f,x)=>{c.dataForm.c1=f.toHEXA().toString(),x.hide()}),s=z.create({el:o.value,default:c.dataForm.c2,theme:"nano",components:u}),s.on("save",(f,x)=>{c.dataForm.c2=f.toRGBA().toString(),x.hide()})}),V(r,f=>{f&&(c.dataForm.l1=r.value)});const d=F(()=>h.value.includes("l1"));return(f,x)=>(m(),v("div",null,[$e,a(d)?(m(),v("div",ke,[Fe,e("div",Ae,[U(e("input",{id:"animatedText","onUpdate:modelValue":x[0]||(x[0]=y=>r.value=y),class:"w-full leading-none transition flex outline-0 items-center h-10 px-4 text-base rounded shadow-sm border border-solid placeholder-opacity-40 bg-white border-gray-200 hover:border-gray-300 focus:ring-2 ring-blue-300 text-gray-700 placeholder-gray-700 box-border shadow-sm",placeholder:"Your text",type:"text"},null,512),[[Y,r.value]]),Ve])])):A("",!0),e("div",Pe,[e("div",Ce,[De,e("div",Te,[e("div",{ref_key:"colorPickerFillEl",ref:i},null,512)])]),e("div",ze,[Se,e("div",Le,[e("div",{ref_key:"colorPickerShadowEl",ref:o},null,512)])])])]))}},Ue={class:"flex items-center justify-between"},Ee=e("div",{class:"text-gray-500 text-lg font-bold mr-4"}," Activate preloader on the site ",-1),je=e("span",{class:"sr-only"},"Use setting",-1),Ie=e("svg",{class:"h-3 w-3 text-gray-400",fill:"none",viewBox:"0 0 12 12"},[e("path",{d:"M4 8l2-2m0 0l2-2M6 6L4 4m2 2l2 2",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1),Be=[Ie],Oe=e("svg",{class:"h-3 w-3 text-blue-600",fill:"currentColor",viewBox:"0 0 12 12"},[e("path",{d:"M3.707 5.293a1 1 0 00-1.414 1.414l1.414-1.414zM5 8l-.707.707a1 1 0 001.414 0L5 8zm4.707-3.293a1 1 0 00-1.414-1.414l1.414 1.414zm-7.414 2l2 2 1.414-1.414-2-2-1.414 1.414zm3.414 2l4-4-1.414-1.414-4 4 1.414 1.414z"})],-1),He=[Oe],Re={setup(n){const t=w(),s=_(null);return s.value=t.dataForm.pluginActivated,E(()=>{t.dataForm.pluginActivated=s.value}),(i,o)=>(m(),v("div",Ue,[Ee,l(a(ae),{modelValue:s.value,"onUpdate:modelValue":o[0]||(o[0]=r=>s.value=r),class:g([s.value?"bg-blue-600":"bg-gray-200","relative inline-flex flex-shrink-0 h-6 w-11 border-2 border-transparent rounded-full cursor-pointer transition-colors ease-in-out duration-200 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-300 m-0 p-0"])},{default:p(()=>[je,e("span",{class:g([s.value?"translate-x-5":"translate-x-0","pointer-events-none relative inline-block h-5 w-5 rounded-full bg-white shadow transform ring-0 transition ease-in-out duration-200"])},[e("span",{class:g([s.value?"opacity-0 ease-out duration-100":"opacity-100 ease-in duration-200","absolute inset-0 h-full w-full flex items-center justify-center transition-opacity"]),"aria-hidden":"true"},Be,2),e("span",{class:g([s.value?"opacity-100 ease-in duration-200":"opacity-0 ease-out duration-100","absolute inset-0 h-full w-full flex items-center justify-center transition-opacity"]),"aria-hidden":"true"},He,2)],2)]),_:1},8,["modelValue","class"])]))}},Ke={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 276.22 503.6"},Ne=e("path",{d:"M223.63 0H53.5C24.58 0 0 23.58 0 52.5v398.66c0 28.92 24.06 52.44 53 52.44l170.41-.18A52.62 52.62 0 0 0 275.97 451l.25-398.5A52.51 52.51 0 0 0 223.63 0zM113.99 31.48h49.32c10.42.41 10.45 15.31 0 15.73h-49.32a7.87 7.87 0 1 1 0-15.73zM84.31 34a8.16 8.16 0 0 1 11.14 0c5 4.86 1.37 13.47-5.55 13.46A7.93 7.93 0 0 1 84.31 34zm52.75 454a23.58 23.58 0 0 1-23.54-23.55c1.29-31.24 45.8-31.23 47.09 0A23.58 23.58 0 0 1 137.08 488zm114.72-63.1H27.54V74.76H251.8v350.15z"},null,-1),qe=[Ne];function Ge(n,t){return m(),v("svg",Ke,qe)}var Q={render:Ge};const We={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 353.94 503.59"},Xe=e("path",{d:"M353.81 27.85A27.9 27.9 0 0 0 325.96 0H27.83A27.87 27.87 0 0 0 0 27.85l.17 447.89A27.87 27.87 0 0 0 28 503.59h298.1a27.87 27.87 0 0 0 27.83-27.85zm-196.28 3.62h38.88c10.43.39 10.44 15.35 0 15.74h-38.88a7.87 7.87 0 0 1 0-15.74zm-29.36 2.44a8.12 8.12 0 0 1 11.14 0 7.87 7.87 0 1 1-11.14 0zm47.26 454.22a23.58 23.58 0 0 1-23.55-23.55c1.3-31.24 45.8-31.23 47.09 0a23.56 23.56 0 0 1-23.58 23.55zM19.59 424.9V74.75h314.75V424.9z"},null,-1),Ye=[Xe];function Qe(n,t){return m(),v("svg",We,Ye)}var Z={render:Qe};const Ze={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 503.82 334.42"},Je=e("path",{d:"M499.42 291.15h-23.25V30.42c0-17.78-14.72-30.39-32.5-30.39h-384c-17.79 0-32 12.61-32 30.39v260.72H3.91c-2.17 0-3.8-.2-3.8 2-1.64 20.84 14.42 41.34 35.62 41.28h431.86c21.19.05 37.81-20.39 36.11-41.31 0-2.17-2.11-1.96-4.28-1.96zM246.11 12.1a8 8 0 0 1 11.09 0c5 4.82 1.38 13.48-5.54 13.41s-10.55-8.61-5.55-13.41zm206.44 263.32H51.25v-240h401.3z"},null,-1),et=[Je];function tt(n,t){return m(),v("svg",Ze,et)}var J={render:tt};const st={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 503.66 424.91"},ot=e("path",{d:"M468 0H35.79A35.72 35.72 0 0 0 .1 35.68L0 330.14a35.77 35.77 0 0 0 35.68 35.75h141.4v35.41h-27.61a3.94 3.94 0 0 0-3.86 4v15.53a4 4 0 0 0 3.86 4.06h204c2.17 0 4.59-1.89 4.59-4.06v-15.51c0-2.18-2.42-4-4.59-4h-26.89v-35.43h141.3a35.79 35.79 0 0 0 35.69-35.75l.09-294.42A35.73 35.73 0 0 0 468 0zM251.34 338.14a11.8 11.8 0 0 1-11.8-11.8c.62-15.65 23-15.65 23.6 0a11.8 11.8 0 0 1-11.8 11.8zm220.81-50.94H31.51V31.47h440.64z"},null,-1),at=[ot];function lt(n,t){return m(),v("svg",st,at)}var ee={render:lt},D={target:"relative box-border select-none touch-none tap-highlight-transparent touch-callout-none disabled:cursor-not-allowed",focused:"slider-focused",tooltipFocus:"slider-tooltip-focus",tooltipDrag:"slider-tooltip-drag",ltr:"slider-ltr",rtl:"slider-rtl",horizontal:"slider-horizontal h-1.5",vertical:"slider-vertical w-1.5 h-80",textDirectionRtl:"slider-txt-rtl",textDirectionLtr:"slider-txt-ltr",base:"w-full h-full relative z-1 bg-gray-300 rounded",connects:"w-full h-full relative overflow-hidden z-0 rounded",connect:"absolute z-1 top-0 right-0 transform-origin-0 transform-style-flat h-full w-full bg-green-500 cursor-pointer tap:duration-300 tap:transition-transform disabled:bg-gray-400 disabled:cursor-not-allowed",origin:"slider-origin absolute z-1 top-0 right-0 transform-origin-0 transform-style-flat h-full w-full h:h-0 v:-top-full txt-rtl-h:left-0 txt-rtl-h:right-auto v:w-0 tap:duration-300 tap:transition-transform",handle:"absolute rounded-full bg-white border-0 shadow-slider cursor-grab focus:outline-none h:w-4 h:h-4 h:-top-1.5 h:-right-2 txt-rtl-h:-left-2 txt-rtl-h:right-auto v:w-4 v:h-4 v:-top-2 v:-right-1.25 disabled:cursor-not-allowed focus:ring focus:ring-green-500 focus:ring-opacity-30",touchArea:"h-full w-full",tooltip:"absolute block text-sm font-semibold whitespace-nowrap py-1 px-1.5 min-w-5 text-center text-white rounded border border-green-500 bg-green-500 transform h:-translate-x-1/2 h:left-1/2 v:-translate-y-1/2 v:top-1/2 disabled:bg-gray-400 disabled:border-gray-400 merge-h:translate-x-1/2 merge-h:left-auto merge-v:-translate-x-4 merge-v:top-auto tt-focus:hidden tt-focused:block tt-drag:hidden tt-dragging:block",tooltipTop:"bottom-6 h:arrow-bottom merge-h:bottom-3.5",tooltipBottom:"top-6 h:arrow-top merge-h:top-5",tooltipLeft:"right-6 v:arrow-right merge-v:right-1",tooltipRight:"left-6 v:arrow-left merge-v:left-7",tooltipHidden:"slider-tooltip-hidden",active:"slider-active shadow-slider-active cursor-grabbing",draggable:"cursor-ew-resize v:cursor-ns-resize",tap:"slider-state-tap",drag:"slider-state-drag"};const rt=e("div",{class:"mb-4 font-bold text-sm uppercase text-gray-600"}," Filling settings ",-1),nt={class:"space-y-3"},it={class:"flex w-full items-center"},dt={class:"w-16 text-center pr-3"},ct={class:"flex-grow"},ut=e("div",{class:"text-gray-500 text-xs mb-2 font-medium"}," Fill width for mobile devices ",-1),ft={class:"flex w-full items-center"},mt={class:"flex-grow"},ht={class:"ml-4 text-right w-14 font-bold"},vt={class:"flex w-full items-center"},pt={class:"w-16 text-center pr-3"},_t={class:"flex-grow"},gt=e("div",{class:"text-gray-500 text-xs mb-2 font-medium"}," Fill width for tablet devices ",-1),xt={class:"flex w-full items-center"},bt={class:"flex-grow"},wt={class:"ml-4 text-right w-14 font-bold"},yt={class:"flex w-full items-center"},$t={class:"w-16 text-center pr-3"},kt={class:"flex-grow"},Ft=e("div",{class:"text-gray-500 text-xs mb-2 font-medium"}," Fill width for laptop devices ",-1),At={class:"flex w-full items-center"},Vt={class:"flex-grow"},Pt={class:"ml-4 text-right w-14 font-bold"},Ct={class:"flex w-full items-center"},Dt={class:"w-16 text-center pr-3"},Tt={class:"flex-grow"},zt=e("div",{class:"text-gray-500 text-xs mb-2 font-medium"}," Fill width for desktop devices ",-1),St={class:"flex w-full items-center"},Lt={class:"flex-grow"},Mt={class:"ml-4 text-right w-14 font-bold"},Ut={setup(n){const t=w(),s=_(80),i=_(0),o=_(0),r=_(0);s.value=t.dataForm.w1,i.value=t.dataForm.w2,o.value=t.dataForm.w3,r.value=t.dataForm.w4;function u(c){return`${Math.round(c)}%`}return E(()=>{t.dataForm.w1=s.value,t.dataForm.w2=i.value,t.dataForm.w3=o.value,t.dataForm.w4=r.value}),(c,h)=>(m(),v(k,null,[rt,e("div",nt,[e("div",it,[e("div",dt,[l(a(Q),{class:"fill-current transition text-gray-600",height:"40"})]),e("div",ct,[ut,e("div",ft,[e("div",mt,[l(a(C),{modelValue:s.value,"onUpdate:modelValue":h[0]||(h[0]=d=>s.value=d),classes:a(D),format:u,max:100,min:50,showTooltip:"focus"},null,8,["modelValue","classes"])]),e("span",ht,b(s.value)+"%",1)])])]),e("div",vt,[e("div",pt,[l(a(Z),{class:"fill-current transition text-gray-600",height:"40"})]),e("div",_t,[gt,e("div",xt,[e("div",bt,[l(a(C),{modelValue:i.value,"onUpdate:modelValue":h[1]||(h[1]=d=>i.value=d),classes:a(D),format:u,showTooltip:"focus"},null,8,["modelValue","classes"])]),e("span",wt,b(i.value)+"%",1)])])]),e("div",yt,[e("div",$t,[l(a(J),{class:"fill-current transition text-gray-600",height:"30"})]),e("div",kt,[Ft,e("div",At,[e("div",Vt,[l(a(C),{modelValue:o.value,"onUpdate:modelValue":h[2]||(h[2]=d=>o.value=d),classes:a(D),format:u,showTooltip:"focus"},null,8,["modelValue","classes"])]),e("span",Pt,b(o.value)+"%",1)])])]),e("div",Ct,[e("div",Dt,[l(a(ee),{class:"fill-current transition text-gray-600",height:"35"})]),e("div",Tt,[zt,e("div",St,[e("div",Lt,[l(a(C),{modelValue:r.value,"onUpdate:modelValue":h[3]||(h[3]=d=>r.value=d),classes:a(D),format:u,showTooltip:"focus"},null,8,["modelValue","classes"])]),e("span",Mt,b(r.value)+"%",1)])])])])],64))}},Et=e("div",{class:"text-xs text-gray-400 font-medium mb-2"}," Background gradient type ",-1),jt={class:"mt-1 relative"},It={class:"block truncate"},Bt={class:"absolute inset-y-0 right-0 flex items-center pr-2 pointer-events-none"},Ot={setup(n){const t=w(),s=[{value:"radial",name:"Radial"},{value:"linear",name:"Linear"}],i=j(s,r=>r.value===t.dataForm.b3),o=_(s[i]);return V(o,r=>{r&&(t.dataForm.b3=o.value.value)}),(r,u)=>(m(),v("div",null,[Et,l(a(H),{as:"div",modelValue:o.value,"onUpdate:modelValue":u[0]||(u[0]=c=>o.value=c)},{default:p(()=>[e("div",jt,[l(a(I),{class:"bg-white relative w-full border border-solid border-gray-300 rounded-md shadow-sm pl-3 pr-10 py-2 text-left cursor-default focus:outline-none focus:ring-1 focus:ring-blue-300 focus:border-blue-300 sm:text-sm"},{default:p(()=>[e("span",It,b(o.value.name),1),e("span",Bt,[l(a(R),{class:"h-5 w-5 text-gray-400","aria-hidden":"true"})])]),_:1}),l(T,{"leave-active-class":"transition ease-in duration-100","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:p(()=>[l(a(B),{class:"absolute z-10 mt-1 w-full bg-white shadow-lg max-h-60 rounded-md py-1 text-base ring-1 ring-black ring-opacity-5 overflow-auto focus:outline-none sm:text-sm pl-0"},{default:p(()=>[(m(),v(k,null,L(s,c=>l(a(O),{as:"template",key:c.id,value:c},{default:p(({active:h,selected:d})=>[e("li",{class:g([h?"text-white bg-blue-400":"text-gray-900","cursor-default select-none relative py-2 pl-3 pr-9"])},[e("span",{class:g([d?"font-semibold":"font-normal","block truncate"])},b(c.name),3),d?(m(),v("span",{key:0,class:g([h?"text-white":"text-blue-600","absolute inset-y-0 right-0 flex items-center pr-4"])},[l(a(K),{class:"h-5 w-5","aria-hidden":"true"})],2)):A("",!0)],2)]),_:2},1032,["value"])),64))]),_:1})]),_:1})])]),_:1},8,["modelValue"])]))}},Ht=e("div",{class:"text-xs text-gray-400 font-medium mb-2"},"Gradient direction",-1),Rt={class:"mt-1 relative"},Kt={class:"block truncate capitalize"},Nt={class:"absolute inset-y-0 right-0 flex items-center pr-2 pointer-events-none"},qt={setup(n){const t=w(),s=F(()=>{let c;return t.dataForm.b3==="radial"&&(c=i),t.dataForm.b3==="linear"&&(c=o),c}),i=[{id:"at_top",value:"at top"},{id:"at_bottom",value:"at bottom"},{id:"at_left",value:"at left"},{id:"at_right",value:"at right"},{id:"at_center",value:"at center"}],o=[{id:"to_top",value:"to top"},{id:"to_left",value:"to left"},{id:"to_right",value:"to right"},{id:"to_bottom",value:"to bottom"}],r=j(s.value,c=>c.value===t.dataForm.b4),u=_(s.value[r]);return V(s,c=>{u.value=c[0]}),E(()=>{t.dataForm.b4=u.value.value}),(c,h)=>(m(),v("div",null,[Ht,l(a(H),{as:"div",modelValue:u.value,"onUpdate:modelValue":h[0]||(h[0]=d=>u.value=d)},{default:p(()=>[e("div",Rt,[l(a(I),{class:"bg-white relative w-full border border-solid border-gray-300 rounded-md shadow-sm pl-3 pr-10 py-2 text-left cursor-default focus:outline-none focus:ring-1 focus:ring-blue-300 focus:border-blue-300 sm:text-sm"},{default:p(()=>[e("span",Kt,b(u.value.value),1),e("span",Nt,[l(a(R),{class:"h-5 w-5 text-gray-400","aria-hidden":"true"})])]),_:1}),l(T,{"leave-active-class":"transition ease-in duration-100","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:p(()=>[l(a(B),{class:"absolute z-10 mt-1 w-full bg-white shadow-lg max-h-60 rounded-md py-1 text-base ring-1 ring-black ring-opacity-5 overflow-auto focus:outline-none sm:text-sm pl-0"},{default:p(()=>[(m(!0),v(k,null,L(a(s),d=>(m(),N(a(O),{as:"template",key:d.id,value:d},{default:p(({active:f,selected:x})=>[e("li",{class:g([f?"text-white bg-blue-400":"text-gray-900","cursor-default select-none relative py-2 pl-3 pr-9"])},[e("span",{class:g([[x?"font-semibold":"font-normal","block truncate"],"capitalize"])},b(d.value),3),x?(m(),v("span",{key:0,class:g([f?"text-white":"text-blue-600","absolute inset-y-0 right-0 flex items-center pr-4"])},[l(a(K),{class:"h-5 w-5","aria-hidden":"true"})],2)):A("",!0)],2)]),_:2},1032,["value"]))),128))]),_:1})]),_:1})])]),_:1},8,["modelValue"])]))}},Gt={class:"flex space-x-4"},Wt={class:"w-1/3"},Xt=e("div",{class:"text-xs text-gray-400 font-medium mb-2"},"Main color",-1),Yt={class:"pickr-wrapper w-full h-9 self-end flex-shrink-0 rounded inline-block ring-2 ring-white shadow-round"},Qt={class:"w-1/3"},Zt=e("div",{class:"text-xs text-gray-400 font-medium mb-2"},"Color stop1",-1),Jt={class:"pickr-wrapper w-full h-9 self-end flex-shrink-0 rounded inline-block ring-2 ring-white shadow-round"},es={class:"w-1/3"},ts=e("div",{class:"text-xs text-gray-400 font-medium mb-2"},"Color stop2",-1),ss={class:"pickr-wrapper w-full h-9 self-end flex-shrink-0 rounded inline-block ring-2 ring-white shadow-round"},os={setup(n){const t=w(),s=_(null),i=_(null),o=_(null);return X(()=>{z.create({el:s.value,default:t.dataForm.b0,theme:"nano",components:S}).on("save",(r,u)=>{t.dataForm.b0=r.toHEXA().toString(),u.hide()}),z.create({el:i.value,default:t.dataForm.b1,theme:"nano",components:S}).on("save",(r,u)=>{t.dataForm.b1=r.toHEXA().toString(),u.hide()}),z.create({el:o.value,default:t.dataForm.b2,theme:"nano",components:S}).on("save",(r,u)=>{t.dataForm.b2=r.toHEXA().toString(),u.hide()})}),(r,u)=>(m(),v("div",Gt,[e("div",Wt,[Xt,e("div",Yt,[e("div",{ref_key:"colorPickerElMain",ref:s},null,512)])]),e("div",Qt,[Zt,e("div",Jt,[e("div",{ref_key:"colorPickerElStop1",ref:i},null,512)])]),e("div",es,[ts,e("div",ss,[e("div",{ref_key:"colorPickerElStop2",ref:o},null,512)])])]))}},as={class:"flex space-x-4"},ls=["onClick"],rs=["onClick"],ns={setup(n){const t=w(),s=F(()=>t.dataIsChange);function i(){s.value&&t.saveData()}function o(){t.loadData()}return(r,u)=>(m(),v("div",as,[e("button",{type:"button",onClick:$(o,["prevent"]),class:"w-1/2 justify-center inline-flex items-center px-6 py-3 border border-gray-300 shadow-sm text-base font-medium rounded-md border-solid text-gray-700 bg-white hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500 cursor-pointer"}," Cancel ",8,ls),e("button",{type:"button",onClick:$(i,["prevent"]),class:g([a(s)?"bg-blue-500  hover:bg-blue-600 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500":"bg-gray-300 cursor-not-allowed","transition inline-flex w-1/2 justify-center cursor-pointer border-solid items-center px-6 py-3 border border-transparent text-base font-medium rounded-md shadow-sm text-white"])}," Save ",10,rs)]))}},is={class:"relative flex items-start border-solid border-x-0 border-2 border-gray-200 py-2 pr-4 select-none mt-8"},ds={class:"flex items-center h-4 mt-2"},cs=e("div",{class:"ml-3 text-sm"},[e("label",{class:"font-medium text-gray-500 cursor-pointer",for:"comments"}," Delete settings on deactivation? "),e("p",{id:"comments-description",class:"text-gray-400 m-0 text-xs"}," Check this box to delete your settings above when you deactivate the plugin. ")],-1),us={setup(n){const t=w(),s=F({get:()=>t.dataForm.delete_option_on_deactivate,set:i=>{t.dataForm.delete_option_on_deactivate=i}});return(i,o)=>(m(),v("div",is,[e("div",ds,[U(e("input",{id:"comments","onUpdate:modelValue":o[0]||(o[0]=r=>re(s)?s.value=r:null),"aria-describedby":"comments-description",class:"focus:ring-indigo-500 h-4 w-4 text-indigo-600 border-gray-300 rounded m-0",name:"comments",type:"checkbox"},null,512),[[le,a(s)]])]),cs]))}},fs={class:"space-y-3"},ms=e("div",{class:"text-xs text-gray-400 font-medium mb-2"}," Hide preloader after: ",-1),hs={class:"mt-1 relative"},vs={class:"block truncate"},ps={class:"absolute inset-y-0 right-0 flex items-center pr-2 pointer-events-none"},_s={class:"flex w-full items-center"},gs={class:"flex-grow"},xs={class:"text-xs text-gray-400 font-medium mb-2"},bs={key:0},ws={key:1},ys={class:"flex w-full items-center select-none"},$s={class:"flex-grow"},ks={class:"ml-4 text-right w-14 font-bold"},Fs={class:"flex w-full items-center"},As={class:"flex-grow"},Vs=e("div",{class:"text-xs text-gray-400 font-medium mb-2"}," The rate of speed animation ",-1),Ps={class:"flex w-full items-center select-none"},Cs={class:"flex-grow"},Ds={class:"ml-4 text-right w-14 font-bold"},Ts={setup(n){const t=[{value:"end",name:"Animation ended"},{value:"fullLoad",name:"Page Full load "}],s=w(),i=_(10),o=_(5);i.value=s.dataForm.t1,o.value=s.dataForm.t2;function r(h){return`${Math.round(h)}s`}E(()=>{s.dataForm.t1=i.value,s.dataForm.t2=o.value});const u=j(t,h=>h.value===s.dataForm.vmv_preloader),c=_(t[u]);return V(c,h=>{h&&(s.dataForm.vmv_preloader=c.value.value)}),(h,d)=>(m(),v("div",fs,[e("div",null,[ms,l(a(H),{modelValue:c.value,"onUpdate:modelValue":d[0]||(d[0]=f=>c.value=f),as:"div"},{default:p(()=>[e("div",hs,[l(a(I),{class:"bg-white relative w-full border border-solid border-gray-300 rounded-md shadow-sm pl-3 pr-10 py-2 text-left cursor-default focus:outline-none focus:ring-1 focus:ring-blue-300 focus:border-blue-300 sm:text-sm"},{default:p(()=>[e("span",vs,b(c.value.name),1),e("span",ps,[l(a(R),{"aria-hidden":"true",class:"h-5 w-5 text-gray-400"})])]),_:1}),l(T,{"leave-active-class":"transition ease-in duration-100","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:p(()=>[l(a(B),{class:"absolute z-10 mt-1 w-full bg-white shadow-lg max-h-60 rounded-md py-1 text-base ring-1 ring-black ring-opacity-5 overflow-auto focus:outline-none sm:text-sm pl-0"},{default:p(()=>[(m(),v(k,null,L(t,f=>l(a(O),{key:f.id,value:f,as:"template"},{default:p(({active:x,selected:y})=>[e("li",{class:g([x?"text-white bg-blue-400":"text-gray-900","cursor-default select-none relative py-2 pl-3 pr-9"])},[e("span",{class:g([y?"font-semibold":"font-normal","block truncate"])},b(f.name),3),y?(m(),v("span",{key:0,class:g([x?"text-white":"text-blue-600","absolute inset-y-0 right-0 flex items-center pr-4"])},[l(a(K),{"aria-hidden":"true",class:"h-5 w-5"})],2)):A("",!0)],2)]),_:2},1032,["value"])),64))]),_:1})]),_:1})])]),_:1},8,["modelValue"])]),e("div",_s,[e("div",gs,[e("div",xs,[c.value.value==="end"?(m(),v("span",bs,' "animation ended" + delay ')):(m(),v("span",ws," Max time for showing the preloader (will hide preloader even page is not fully loaded) "))]),e("div",ys,[e("div",$s,[l(a(C),{modelValue:i.value,"onUpdate:modelValue":d[1]||(d[1]=f=>i.value=f),classes:a(D),format:r,max:30,min:0,showTooltip:"focus"},null,8,["modelValue","classes"])]),e("span",ks,b(i.value)+" s ",1)])])]),e("div",Fs,[e("div",As,[Vs,e("div",Ps,[e("div",Cs,[l(a(C),{modelValue:o.value,"onUpdate:modelValue":d[2]||(d[2]=f=>o.value=f),classes:a(D),max:20,min:1,showTooltip:"focus"},null,8,["modelValue","classes"])]),e("span",Ds,b(o.value),1)])])])]))}},zs={class:"relative select-none"},Ss=e("div",{class:"text-xs text-gray-400 font-medium mb-2"}," Upload preloader animation file. ",-1),Ls={class:"mb-4 flex"},Ms={class:"relative flex-grow"},Us={class:"absolute top-0 left-0 w-full h-full"},Es=e("div",{class:"absolute left-0 w-full pr-1 mt-1 text-xs leading-none text-right text-red-500 top-full"},[e("div",{class:"hidden"},"Field is required")],-1),js={class:"relative ml-3"},Is=["data-tt1","data-tt2","disabled","onClick"],Bs={setup(n){const t=_(null),s=_(null),i=_(null),o=_(null),r=w(),u=".js",c=()=>{t.value.files.length>0?(s.value=t.value.files[0],i.value=s.value.name):(s.value=null,i.value=null)};function h(){t.value.setAttribute("type","text"),t.value.setAttribute("type","file"),s.value=null,i.value=null,o.value=null}function d(){if(!o.value&&i.value){o.value=!0;const f=new FormData;f.append("action","vmv_upload_file_premium_animations"),f.append("vmv_token",r.formKey),f.append("file",s.value),P.post(r.formAction,f,{headers:{"Content-Type":"multipart/form-data"}}).then(function(){h(),r.saveCount++,r.getListFilesAnimationPremium(),setTimeout(()=>{console.log(r.listThemes)},2e3)}).catch(function(){o.value=null})}}return(f,x)=>(m(),v("div",zs,[Ss,e("div",Ls,[e("div",Ms,[U(e("input",{"onUpdate:modelValue":x[0]||(x[0]=y=>i.value=y),class:"w-full leading-none transition flex outline-0 items-center h-10 px-4 text-base rounded shadow-sm border border-solid placeholder-opacity-40 bg-white border-gray-200 hover:border-gray-300 focus:ring-2 ring-blue-300 text-gray-700 placeholder-gray-700 box-border shadow-sm",placeholder:"Upload preloader file (*.js)",readonly:"",type:"text"},null,512),[[Y,i.value]]),e("label",Us,[U(e("input",{ref_key:"file",ref:t,accept:u,type:"file",onChange:c},null,544),[[ne,!1]])]),Es]),e("div",js,[e("button",{class:g([[i.value?"bg-blue-500  hover:bg-blue-600 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500":"bg-gray-300 cursor-not-allowed","transition inline-flex h-10  justify-center cursor-pointer border-solid items-center leading-none px-2 border border-transparent text-base font-small rounded-md shadow-sm text-white",o.value?"after:box-border text-opacity-0 cursor-not-allowed after:border-r-transparent after:border-solid  after:border-white after:animate-spin after:rounded-full after:w-4 after:h-4 after:left-1/2 after:top-1/2 after:block after:absolute after:border-2  after:-ml-2 after:-mt-2 ":""],"relative after:absolute"]),"data-tt1":o.value,"data-tt2":!i.value,disabled:!i.value||o.value,type:"button",onClick:$(d,["prevent"])}," Upload ",10,Is)])])]))}},Os={key:0,class:"space-y-3"},Hs=e("div",{class:"text-xs text-gray-400 font-medium mb-2"}," Select theme preloader: ",-1),Rs={class:"mt-1 relative"},Ks={class:"block truncate"},Ns={class:"absolute inset-y-0 right-0 flex items-center pr-2 pointer-events-none"},qs=["onClick"],Gs={setup(n){const t=w(),{listThemes:s}=W(t),i=j(s.value,c=>c.value===t.dataForm.themeFile),o=_(s.value[i]);V(o,c=>{c&&(t.dataForm.themeFile=o.value.value,t.dataForm.isPremium=o.value.isPremium)});function r(c,h){let d="";return c&&h&&(d+="bg-blue-500 text-white cursor-default"),!c&&h&&(d+="bg-blue-400 text-white cursor-pointer"),c&&!h&&(d+="bg-blue-500 text-white"),!c&&!h&&(d+="text-gray-900"),d}function u(c){t.deleteFile(c),t.saveData()}return(c,h)=>a(s)?(m(),v("div",Os,[e("div",null,[Hs,l(a(H),{modelValue:o.value,"onUpdate:modelValue":h[0]||(h[0]=d=>o.value=d),as:"div"},{default:p(()=>[e("div",Rs,[l(a(I),{class:"bg-white relative w-full border border-solid border-gray-300 rounded-md shadow-sm pl-3 pr-10 py-2 text-left cursor-default focus:outline-none focus:ring-1 focus:ring-blue-300 focus:border-blue-300 sm:text-sm"},{default:p(()=>[e("span",Ks,b(o.value.name),1),e("span",Ns,[l(a(ie),{"aria-hidden":"true",class:"h-5 w-5 text-gray-400"})])]),_:1}),l(T,{"leave-active-class":"transition ease-in duration-100","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:p(()=>[l(a(B),{class:"absolute z-10 mt-1 w-full bg-white shadow-lg max-h-60 rounded-md py-1 text-base ring-1 ring-black ring-opacity-5 overflow-auto focus:outline-none sm:text-sm pl-0"},{default:p(()=>[(m(!0),v(k,null,L(a(s),(d,f)=>(m(),N(a(O),{key:`item-${f}`,value:d,as:"template"},{default:p(({active:x,selected:y})=>[e("li",{class:g([r(y,x),"select-none relative py-2 pl-3 pr-9"])},[e("span",{class:g([y?"font-semibold":"font-normal","block truncate "])},b(d.name),3),d.isPremium&&a(t).dataForm.themeFile!==d.value?(m(),v("span",{key:0,class:"absolute inset-y-0 right-3 items-center inline-flex cursor-pointer",onClick:$(Fo=>u(d.value),["stop","prevent"])},[l(a(de),{"aria-hidden":"true",class:"h-5 w-5"})],8,qs)):A("",!0)],2)]),_:2},1032,["value"]))),128))]),_:1})]),_:1})])]),_:1},8,["modelValue"])])])):A("",!0)}},Ws=e("div",{class:"text-3xl text-gray-700 font-bold mb-4"},[me(" VMV Preloader "),e("a",{class:"text-sm no-underline text-blue-400 font-normal",href:"https://vmv.one",target:"_blank"},"(Learn more)")],-1),Xs={class:"space-y-6"},Ys={class:"-mb-px flex"},Qs={class:"flex space-x-4"},Zs={setup(n){const t=[{id:"main_set",name:"Main"},{id:"theme_set",name:"Theme"},{id:"background_set",name:"Background"},{id:"timing_set",name:"Timing"}];return(s,i)=>(m(),v(k,null,[Ws,e("div",Xs,[l(Re),l(a(fe),null,{default:p(()=>[l(a(ce),{class:"border-b border-gray-200"},{default:p(()=>[e("div",Ys,[(m(),v(k,null,L(t,o=>l(a(he),{key:o.id,as:"template"},{default:p(({selected:r})=>[e("button",{class:g(["w-1/3 py-4 px-1 text-center border-b-2 font-medium text-sm bg-transparent border-solid border-t-0 border-x-0 cursor-pointer transition focus:outline-0 focus:shadow-none",r?"border-blue-400 text-blue-500 shadow-none":"border-transparent text-gray-500 hover:text-gray-700 hover:border-gray-300"])},b(o.name),3)]),_:2},1024)),64))])]),_:1}),l(a(ue),null,{default:p(()=>[l(a(M),null,{default:p(()=>[l(Bs),l(Gs),l(us)]),_:1}),l(a(M),null,{default:p(()=>[l(Me,{class:"mb-6"}),l(Ut)]),_:1}),l(a(M),null,{default:p(()=>[e("div",Qs,[l(Ot,{class:"w-7/12 mb-4"}),l(qt,{class:"w-5/12"})]),l(os)]),_:1}),l(a(M),null,{default:p(()=>[l(Ts)]),_:1})]),_:1})]),_:1}),l(ns)])],64))}};var Js=(n,t)=>{const s=n.__vccOpts||n;for(const[i,o]of t)s[i]=o;return s};const eo={class:"flex space-x-4 justify-center mb-5"},to={class:"flex w-full justify-center"},so={class:"overflow-x-auto overflow-y-hidden h-full relative w-full border-solid border-8 border-gray-300 rounded-lg mx-auto select-none box-border shadow-round"},oo=["src"],ao=["onClick"],lo={setup(n){const t=w(),s=_("tablet"),i=_(null),o=_("");o.value="/vmv-preloader-preview/";function r(d){s.value=d}function u(){i.value.src+=""}const c=F(()=>{let d;switch(s.value){case"mobile":d={width:375,height:600};break;case"tablet":d={width:768,height:900};break;case"laptop":d={width:1100,height:900};break;case"desktop":d={width:1401,height:900};break;default:d={width:375,height:600};break}return d}),h=F(()=>t.countReloadDemo);return V(h,d=>{d&&u()}),(d,f)=>(m(),v(k,null,[e("div",eo,[e("a",{class:g([[s.value==="mobile"?"text-blue-400 focus:text-blue-400":"text-gray-500 focus:text-gray-500 hover:text-blue-300"],"focus:outline-none shadow-none"]),href:"#3",onClick:f[0]||(f[0]=$(x=>r("mobile"),["prevent"]))},[l(a(Q),{class:"fill-current transition",height:"40"})],2),e("a",{class:g([[s.value==="tablet"?"text-blue-400 focus:text-blue-400":"text-gray-500 focus:text-gray-500 hover:text-blue-300"],"focus:outline-none shadow-none"]),href:"#3",onClick:f[1]||(f[1]=$(x=>r("tablet"),["prevent"]))},[l(a(Z),{class:"fill-current transition",height:"40"})],2),e("a",{class:g([[s.value==="laptop"?"text-blue-400 focus:text-blue-400":"text-gray-500 focus:text-gray-500 hover:text-blue-300"],"focus:outline-none shadow-none"]),href:"#3",onClick:f[2]||(f[2]=$(x=>r("laptop"),["prevent"]))},[l(a(J),{class:"fill-current transition",height:"40"})],2),e("a",{class:g([[s.value==="desktop"?"text-blue-400 focus:text-blue-400":"text-gray-500 focus:text-gray-500 hover:text-blue-300"],"focus:outline-none shadow-none"]),href:"#3",onClick:f[3]||(f[3]=$(x=>r("desktop"),["prevent"]))},[l(a(ee),{class:"fill-current transition",height:"40"})],2)]),e("div",to,[e("div",{style:q({"max-width":a(c).width+16+"px",height:a(c).height+16+"px"}),class:"relative w-full transition-all"},[e("div",so,[e("div",{style:q({width:a(c).width+"px",height:a(c).height+"px"}),class:"absolute inline-block w-full transition-all"},[e("iframe",{ref_key:"demoIframe",ref:i,src:o.value,class:"border-0 block",height:"100%",width:"100%"},null,8,oo)],4)]),e("a",{class:"absolute bottom-5 right-5 z-10 w-10 h-10 cursor-pointer rounded-lg inline-flex bg-gray-400 text-white justify-center items-center hover:bg-gray-300",href:"#3",onClick:$(u,["prevent"])},[l(a(ve),{class:"w-4 h-4"})],8,ao)],4)])],64))}};var ro=Js(lo,[["__scopeId","data-v-0ec3945e"]]);const no={"aria-live":"assertive",class:"fixed top-10 inset-0 flex items-end px-4 py-6 pointer-events-none sm:p-6 sm:items-start"},io={class:"w-full flex flex-col items-center space-y-4 sm:items-end"},co={key:0,class:"max-w-sm w-full bg-white shadow-lg rounded-lg pointer-events-auto ring-1 ring-black ring-opacity-5 overflow-hidden"},uo={class:"p-4"},fo={class:"flex items-start"},mo={class:"flex-shrink-0"},ho=e("div",{class:"ml-3 w-0 flex-1 pt-0.5"},[e("p",{class:"text-sm font-medium text-gray-900 p-0 m-0"}," Successfully saved! ")],-1),vo={class:"ml-4 flex-shrink-0 flex"},po=e("span",{class:"sr-only"},"Close",-1),_o={setup(n){const t=w(),s=_(!1),i=F(()=>t.saveCount);return V(i,()=>{s.value=!0,setTimeout(()=>{s.value=!1},1500)}),(o,r)=>(m(),v("div",no,[e("div",io,[l(T,{"enter-active-class":"transform ease-out duration-300 transition","enter-from-class":"translate-y-2 opacity-0 sm:translate-y-0 sm:translate-x-2","enter-to-class":"translate-y-0 opacity-100 sm:translate-x-0","leave-active-class":"transition ease-in duration-100","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:p(()=>[s.value?(m(),v("div",co,[e("div",uo,[e("div",fo,[e("div",mo,[l(a(pe),{class:"h-6 w-6 text-green-400","aria-hidden":"true"})]),ho,e("div",vo,[e("button",{onClick:r[0]||(r[0]=u=>s.value=!1),class:"bg-white border-solid border-0 rounded-md inline-flex text-gray-400 hover:text-gray-500 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500"},[po,l(a(_e),{class:"h-5 w-5","aria-hidden":"true"})])])])])])):A("",!0)]),_:1})])]))}},go={key:0,class:"flex w-full pr-5 font-sans"},xo={class:"w-96 bg-white p-5 flex-shrink-0 shadow-lg z-1"},bo={class:"flex-grow bg-white px-6 py-5"},wo={key:1,class:"w-full h-full flex justify-center items-center"},yo=e("div",{class:"flex justify-center items-center pt-32"},[e("svg",{height:"24",viewBox:"0 0 128 128",width:"24",xmlns:"http://www.w3.org/2000/svg"},[e("rect",{fill:"none",height:"100%",width:"100%"}),e("g",null,[e("circle",{cx:"16",cy:"64",fill:"#a1a1a1",r:"16"}),e("circle",{cx:"16",cy:"64",fill:"silver",r:"16",transform:"rotate(45 64 64)"}),e("circle",{cx:"16",cy:"64",fill:"#d8d8d8",r:"16",transform:"rotate(90 64 64)"}),e("circle",{cx:"16",cy:"64",fill:"#ececec",r:"16",transform:"rotate(135 64 64)"}),e("circle",{cx:"16",cy:"64",fill:"#f4f4f4",r:"16",transform:"rotate(180 64 64)"}),e("circle",{cx:"16",cy:"64",fill:"#f4f4f4",r:"16",transform:"rotate(225 64 64)"}),e("circle",{cx:"16",cy:"64",fill:"#f4f4f4",r:"16",transform:"rotate(270 64 64)"}),e("circle",{cx:"16",cy:"64",fill:"#f4f4f4",r:"16",transform:"rotate(315 64 64)"}),e("animateTransform",{attributeName:"transform",calcMode:"discrete",dur:"720ms",repeatCount:"indefinite",type:"rotate",values:"0 64 64;315 64 64;270 64 64;225 64 64;180 64 64;135 64 64;90 64 64;45 64 64"})])]),e("div",{class:"text-2xl ml-4 font-medium font-sans text-gray-600"}," Loading... ")],-1),$o=[yo],ko={setup(n){const t=w(),s=document.querySelector("#app-vmv").getAttribute("data-vmv-action"),i=document.querySelector("#app-vmv").getAttribute("data-vmv-token");return t.formAction=s,t.formKey=i,t.loadData(),t.getListFilesAnimation(),t.getListFilesAnimationPremium(),(o,r)=>(m(),N(T,{mode:"out-in"},{default:p(()=>[a(t).dataLoaded?(m(),v("div",go,[e("div",xo,[l(Zs)]),e("div",bo,[l(ro)]),l(_o)])):(m(),v("div",wo,$o))]),_:1}))}};const te=ge(ko);te.use(xe());te.mount("#app-vmv");
     1import{d as se,i as oe,a as P,r as _,s as W,o as X,P as z,w as V,c as F,b as m,e as v,u as a,f as e,g as U,v as Y,h as A,j as E,k as l,l as p,n as g,S as ae,m as C,t as b,F as k,p as j,L as I,q as R,T,x as B,y as L,z as O,A as K,B as H,C as N,D as $,E as le,G as re,H as ne,I as ie,J as de,K as ce,M as ue,N as M,O as fe,Q as me,R as he,U as q,V as ve,W as pe,X as _e,Y as ge,Z as xe}from"./vendor.js";const be=function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))i(o);new MutationObserver(o=>{for(const r of o)if(r.type==="childList")for(const u of r.addedNodes)u.tagName==="LINK"&&u.rel==="modulepreload"&&i(u)}).observe(document,{childList:!0,subtree:!0});function s(o){const r={};return o.integrity&&(r.integrity=o.integrity),o.referrerpolicy&&(r.referrerPolicy=o.referrerpolicy),o.crossorigin==="use-credentials"?r.credentials="include":o.crossorigin==="anonymous"?r.credentials="omit":r.credentials="same-origin",r}function i(o){if(o.ep)return;o.ep=!0;const r=s(o);fetch(o.href,r)}};be();function we(n){const t=n.indexOf("__"),s=n.substring(t+2,n.length-5);return atob(s).split(",")}function ye(n){const t=n.indexOf("__");return n.substring(0,t)}function G(n,t){const i=ye(n).replace(/([A-Z])/g," $1"),o=i.charAt(0).toUpperCase()+i.slice(1);return{value:n,isPremium:t,name:o}}const w=se("appStore",{state:()=>({savingData:!1,formAction:null,formKey:null,dataLoaded:!1,listDefaultThemes:null,listPremiumThemes:null,countReloadDemo:0,countResetData:0,saveCount:0,serverData:null,availableParams:null,dataForm:{vmv_preloader:"end",pluginActivated:!1,c1:"#ffffff",l1:"Site name",w1:0,w2:0,w3:0,w4:0,b0:"",b1:"",b2:"",b3:"radial",b4:"at top",t1:10,t2:5,t4:null,themeFile:"KadisokaFont__bDEsYzEsYzIsYix3LHQ=.js",isPremium:!1}}),getters:{dataIsChange:n=>!oe(n.serverData,n.dataForm),listThemes:n=>{const t=[];return Array.isArray(n.listDefaultThemes)&&n.listDefaultThemes.forEach(s=>{t.push(G(s,!1))}),Array.isArray(n.listPremiumThemes)&&n.listPremiumThemes.forEach(s=>{t.push(G(s,!0))}),t}},actions:{updateParamsSettings(){this.availableParams=we(this.dataForm.themeFile)},async saveData(){if(!this.savingData){this.savingData=!0,this.dataForm.t4=new Date().getTime();const n=new FormData;n.append("action","vmv_set_params"),n.append("vmv_token",this.formKey);for(let t in this.dataForm)n.append(t,this.dataForm[t]);await P.post(this.formAction,n),this.savingData=!1,this.serverData=Object.assign({},this.dataForm),this.saveCount++,this.countReloadDemo++,this.updateParamsSettings()}},async loadData(){{let n=new FormData;n.append("action","vmv_get_params"),n.append("vmv_token",this.formKey);const t=await P.post(this.formAction,n);this.dataForm=Object.assign({},t.data.options),this.serverData=Object.assign({},t.data.options)}this.countResetData++,this.dataLoaded=!0,this.updateParamsSettings()},async getListFilesAnimation(){var n;{let t=new FormData;t.append("action","vmv_list_base_animations"),t.append("vmv_token",this.formKey);const s=await P.post(this.formAction,t);this.listDefaultThemes=(n=s==null?void 0:s.data)==null?void 0:n.data.list_files}},async getListFilesAnimationPremium(){var n;{let t=new FormData;t.append("action","vmv_list_premium_animations"),t.append("vmv_token",this.formKey);const s=await P.post(this.formAction,t);this.listPremiumThemes=(n=s==null?void 0:s.data)==null?void 0:n.data.list_files}},async deleteFile(n){let t=new FormData;t.append("action","vmv_delete_file_premium_animations"),t.append("vmv_token",this.formKey),t.append("filename_to_delete",n),await P.post(this.formAction,t),this.getListFilesAnimationPremium()}}});var S={preview:!0,opacity:!1,hue:!0,interaction:{hex:!1,rgba:!1,hsla:!1,hsva:!1,cmyk:!1,input:!0,clear:!1,save:!0}};const $e=e("div",{class:"mb-4 font-bold text-sm uppercase text-gray-600"}," Base settings ",-1),ke={key:0},Fe=e("div",{class:"text-xs text-gray-400 font-medium mb-2"},"Animated text",-1),Ae={class:"relative mb-4"},Ve=e("div",{class:"absolute left-0 w-full pr-1 mt-1 text-xs leading-none text-right text-red-500 top-full"},[e("div",{class:"hidden"},"Field is required")],-1),Pe={class:"flex space-x-4"},Ce={class:"w-1/2"},De=e("div",{class:"text-xs text-gray-400 font-medium mb-2"},"Filling color",-1),Te={class:"pickr-wrapper w-full h-9 self-end flex-shrink-0 rounded inline-block ring-2 ring-white shadow-round"},ze={class:"w-1/2"},Se=e("div",{class:"text-xs text-gray-400 font-medium mb-2"},"Color shadow",-1),Le={class:"pickr-wrapper w-full h-9 self-end flex-shrink-0 rounded inline-block ring-2 ring-white shadow-round"},Me={setup(n){let t,s;const i=_(null),o=_(null),r=_(""),u=Object.assign({},S);u.opacity=!0;const c=w(),{availableParams:h}=W(c);r.value=c.dataForm.l1,X(()=>{t=z.create({el:i.value,default:c.dataForm.c1,theme:"nano",components:S}),t.on("save",(f,x)=>{c.dataForm.c1=f.toHEXA().toString(),x.hide()}),s=z.create({el:o.value,default:c.dataForm.c2,theme:"nano",components:u}),s.on("save",(f,x)=>{c.dataForm.c2=f.toRGBA().toString(),x.hide()})}),V(r,f=>{f&&(c.dataForm.l1=r.value)});const d=F(()=>h.value.includes("l1"));return(f,x)=>(m(),v("div",null,[$e,a(d)?(m(),v("div",ke,[Fe,e("div",Ae,[U(e("input",{id:"animatedText","onUpdate:modelValue":x[0]||(x[0]=y=>r.value=y),class:"w-full leading-none transition flex outline-0 items-center h-10 px-4 text-base rounded shadow-sm border border-solid placeholder-opacity-40 bg-white border-gray-200 hover:border-gray-300 focus:ring-2 ring-blue-300 text-gray-700 placeholder-gray-700 box-border shadow-sm",placeholder:"Your text",type:"text"},null,512),[[Y,r.value]]),Ve])])):A("",!0),e("div",Pe,[e("div",Ce,[De,e("div",Te,[e("div",{ref_key:"colorPickerFillEl",ref:i},null,512)])]),e("div",ze,[Se,e("div",Le,[e("div",{ref_key:"colorPickerShadowEl",ref:o},null,512)])])])]))}},Ue={class:"flex items-center justify-between"},Ee=e("div",{class:"text-gray-500 text-lg font-bold mr-4"}," Activate preloader on the site ",-1),je=e("span",{class:"sr-only"},"Use setting",-1),Ie=e("svg",{class:"h-3 w-3 text-gray-400",fill:"none",viewBox:"0 0 12 12"},[e("path",{d:"M4 8l2-2m0 0l2-2M6 6L4 4m2 2l2 2",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1),Be=[Ie],Oe=e("svg",{class:"h-3 w-3 text-blue-600",fill:"currentColor",viewBox:"0 0 12 12"},[e("path",{d:"M3.707 5.293a1 1 0 00-1.414 1.414l1.414-1.414zM5 8l-.707.707a1 1 0 001.414 0L5 8zm4.707-3.293a1 1 0 00-1.414-1.414l1.414 1.414zm-7.414 2l2 2 1.414-1.414-2-2-1.414 1.414zm3.414 2l4-4-1.414-1.414-4 4 1.414 1.414z"})],-1),He=[Oe],Re={setup(n){const t=w(),s=_(null);return s.value=t.dataForm.pluginActivated,E(()=>{t.dataForm.pluginActivated=s.value}),(i,o)=>(m(),v("div",Ue,[Ee,l(a(ae),{modelValue:s.value,"onUpdate:modelValue":o[0]||(o[0]=r=>s.value=r),class:g([s.value?"bg-blue-600":"bg-gray-200","relative inline-flex flex-shrink-0 h-6 w-11 border-2 border-transparent rounded-full cursor-pointer transition-colors ease-in-out duration-200 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-300 m-0 p-0"])},{default:p(()=>[je,e("span",{class:g([s.value?"translate-x-5":"translate-x-0","pointer-events-none relative inline-block h-5 w-5 rounded-full bg-white shadow transform ring-0 transition ease-in-out duration-200"])},[e("span",{class:g([s.value?"opacity-0 ease-out duration-100":"opacity-100 ease-in duration-200","absolute inset-0 h-full w-full flex items-center justify-center transition-opacity"]),"aria-hidden":"true"},Be,2),e("span",{class:g([s.value?"opacity-100 ease-in duration-200":"opacity-0 ease-out duration-100","absolute inset-0 h-full w-full flex items-center justify-center transition-opacity"]),"aria-hidden":"true"},He,2)],2)]),_:1},8,["modelValue","class"])]))}},Ke={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 276.22 503.6"},Ne=e("path",{d:"M223.63 0H53.5C24.58 0 0 23.58 0 52.5v398.66c0 28.92 24.06 52.44 53 52.44l170.41-.18A52.62 52.62 0 0 0 275.97 451l.25-398.5A52.51 52.51 0 0 0 223.63 0zM113.99 31.48h49.32c10.42.41 10.45 15.31 0 15.73h-49.32a7.87 7.87 0 1 1 0-15.73zM84.31 34a8.16 8.16 0 0 1 11.14 0c5 4.86 1.37 13.47-5.55 13.46A7.93 7.93 0 0 1 84.31 34zm52.75 454a23.58 23.58 0 0 1-23.54-23.55c1.29-31.24 45.8-31.23 47.09 0A23.58 23.58 0 0 1 137.08 488zm114.72-63.1H27.54V74.76H251.8v350.15z"},null,-1),qe=[Ne];function Ge(n,t){return m(),v("svg",Ke,qe)}var Q={render:Ge};const We={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 353.94 503.59"},Xe=e("path",{d:"M353.81 27.85A27.9 27.9 0 0 0 325.96 0H27.83A27.87 27.87 0 0 0 0 27.85l.17 447.89A27.87 27.87 0 0 0 28 503.59h298.1a27.87 27.87 0 0 0 27.83-27.85zm-196.28 3.62h38.88c10.43.39 10.44 15.35 0 15.74h-38.88a7.87 7.87 0 0 1 0-15.74zm-29.36 2.44a8.12 8.12 0 0 1 11.14 0 7.87 7.87 0 1 1-11.14 0zm47.26 454.22a23.58 23.58 0 0 1-23.55-23.55c1.3-31.24 45.8-31.23 47.09 0a23.56 23.56 0 0 1-23.58 23.55zM19.59 424.9V74.75h314.75V424.9z"},null,-1),Ye=[Xe];function Qe(n,t){return m(),v("svg",We,Ye)}var Z={render:Qe};const Ze={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 503.82 334.42"},Je=e("path",{d:"M499.42 291.15h-23.25V30.42c0-17.78-14.72-30.39-32.5-30.39h-384c-17.79 0-32 12.61-32 30.39v260.72H3.91c-2.17 0-3.8-.2-3.8 2-1.64 20.84 14.42 41.34 35.62 41.28h431.86c21.19.05 37.81-20.39 36.11-41.31 0-2.17-2.11-1.96-4.28-1.96zM246.11 12.1a8 8 0 0 1 11.09 0c5 4.82 1.38 13.48-5.54 13.41s-10.55-8.61-5.55-13.41zm206.44 263.32H51.25v-240h401.3z"},null,-1),et=[Je];function tt(n,t){return m(),v("svg",Ze,et)}var J={render:tt};const st={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 503.66 424.91"},ot=e("path",{d:"M468 0H35.79A35.72 35.72 0 0 0 .1 35.68L0 330.14a35.77 35.77 0 0 0 35.68 35.75h141.4v35.41h-27.61a3.94 3.94 0 0 0-3.86 4v15.53a4 4 0 0 0 3.86 4.06h204c2.17 0 4.59-1.89 4.59-4.06v-15.51c0-2.18-2.42-4-4.59-4h-26.89v-35.43h141.3a35.79 35.79 0 0 0 35.69-35.75l.09-294.42A35.73 35.73 0 0 0 468 0zM251.34 338.14a11.8 11.8 0 0 1-11.8-11.8c.62-15.65 23-15.65 23.6 0a11.8 11.8 0 0 1-11.8 11.8zm220.81-50.94H31.51V31.47h440.64z"},null,-1),at=[ot];function lt(n,t){return m(),v("svg",st,at)}var ee={render:lt},D={target:"relative box-border select-none touch-none tap-highlight-transparent touch-callout-none disabled:cursor-not-allowed",focused:"slider-focused",tooltipFocus:"slider-tooltip-focus",tooltipDrag:"slider-tooltip-drag",ltr:"slider-ltr",rtl:"slider-rtl",horizontal:"slider-horizontal h-1.5",vertical:"slider-vertical w-1.5 h-80",textDirectionRtl:"slider-txt-rtl",textDirectionLtr:"slider-txt-ltr",base:"w-full h-full relative z-1 bg-gray-300 rounded",connects:"w-full h-full relative overflow-hidden z-0 rounded",connect:"absolute z-1 top-0 right-0 transform-origin-0 transform-style-flat h-full w-full bg-green-500 cursor-pointer tap:duration-300 tap:transition-transform disabled:bg-gray-400 disabled:cursor-not-allowed",origin:"slider-origin absolute z-1 top-0 right-0 transform-origin-0 transform-style-flat h-full w-full h:h-0 v:-top-full txt-rtl-h:left-0 txt-rtl-h:right-auto v:w-0 tap:duration-300 tap:transition-transform",handle:"absolute rounded-full bg-white border-0 shadow-slider cursor-grab focus:outline-none h:w-4 h:h-4 h:-top-1.5 h:-right-2 txt-rtl-h:-left-2 txt-rtl-h:right-auto v:w-4 v:h-4 v:-top-2 v:-right-1.25 disabled:cursor-not-allowed focus:ring focus:ring-green-500 focus:ring-opacity-30",touchArea:"h-full w-full",tooltip:"absolute block text-sm font-semibold whitespace-nowrap py-1 px-1.5 min-w-5 text-center text-white rounded border border-green-500 bg-green-500 transform h:-translate-x-1/2 h:left-1/2 v:-translate-y-1/2 v:top-1/2 disabled:bg-gray-400 disabled:border-gray-400 merge-h:translate-x-1/2 merge-h:left-auto merge-v:-translate-x-4 merge-v:top-auto tt-focus:hidden tt-focused:block tt-drag:hidden tt-dragging:block",tooltipTop:"bottom-6 h:arrow-bottom merge-h:bottom-3.5",tooltipBottom:"top-6 h:arrow-top merge-h:top-5",tooltipLeft:"right-6 v:arrow-right merge-v:right-1",tooltipRight:"left-6 v:arrow-left merge-v:left-7",tooltipHidden:"slider-tooltip-hidden",active:"slider-active shadow-slider-active cursor-grabbing",draggable:"cursor-ew-resize v:cursor-ns-resize",tap:"slider-state-tap",drag:"slider-state-drag"};const rt=e("div",{class:"mb-4 font-bold text-sm uppercase text-gray-600"}," Filling settings ",-1),nt={class:"space-y-3"},it={class:"flex w-full items-center"},dt={class:"w-16 text-center pr-3"},ct={class:"flex-grow"},ut=e("div",{class:"text-gray-500 text-xs mb-2 font-medium"}," Fill width for mobile devices ",-1),ft={class:"flex w-full items-center"},mt={class:"flex-grow"},ht={class:"ml-4 text-right w-14 font-bold"},vt={class:"flex w-full items-center"},pt={class:"w-16 text-center pr-3"},_t={class:"flex-grow"},gt=e("div",{class:"text-gray-500 text-xs mb-2 font-medium"}," Fill width for tablet devices ",-1),xt={class:"flex w-full items-center"},bt={class:"flex-grow"},wt={class:"ml-4 text-right w-14 font-bold"},yt={class:"flex w-full items-center"},$t={class:"w-16 text-center pr-3"},kt={class:"flex-grow"},Ft=e("div",{class:"text-gray-500 text-xs mb-2 font-medium"}," Fill width for laptop devices ",-1),At={class:"flex w-full items-center"},Vt={class:"flex-grow"},Pt={class:"ml-4 text-right w-14 font-bold"},Ct={class:"flex w-full items-center"},Dt={class:"w-16 text-center pr-3"},Tt={class:"flex-grow"},zt=e("div",{class:"text-gray-500 text-xs mb-2 font-medium"}," Fill width for desktop devices ",-1),St={class:"flex w-full items-center"},Lt={class:"flex-grow"},Mt={class:"ml-4 text-right w-14 font-bold"},Ut={setup(n){const t=w(),s=_(80),i=_(0),o=_(0),r=_(0);s.value=t.dataForm.w1,i.value=t.dataForm.w2,o.value=t.dataForm.w3,r.value=t.dataForm.w4;function u(c){return`${Math.round(c)}%`}return E(()=>{t.dataForm.w1=s.value,t.dataForm.w2=i.value,t.dataForm.w3=o.value,t.dataForm.w4=r.value}),(c,h)=>(m(),v(k,null,[rt,e("div",nt,[e("div",it,[e("div",dt,[l(a(Q),{class:"fill-current transition text-gray-600",height:"40"})]),e("div",ct,[ut,e("div",ft,[e("div",mt,[l(a(C),{modelValue:s.value,"onUpdate:modelValue":h[0]||(h[0]=d=>s.value=d),classes:a(D),format:u,max:100,min:50,showTooltip:"focus"},null,8,["modelValue","classes"])]),e("span",ht,b(s.value)+"%",1)])])]),e("div",vt,[e("div",pt,[l(a(Z),{class:"fill-current transition text-gray-600",height:"40"})]),e("div",_t,[gt,e("div",xt,[e("div",bt,[l(a(C),{modelValue:i.value,"onUpdate:modelValue":h[1]||(h[1]=d=>i.value=d),classes:a(D),format:u,showTooltip:"focus"},null,8,["modelValue","classes"])]),e("span",wt,b(i.value)+"%",1)])])]),e("div",yt,[e("div",$t,[l(a(J),{class:"fill-current transition text-gray-600",height:"30"})]),e("div",kt,[Ft,e("div",At,[e("div",Vt,[l(a(C),{modelValue:o.value,"onUpdate:modelValue":h[2]||(h[2]=d=>o.value=d),classes:a(D),format:u,showTooltip:"focus"},null,8,["modelValue","classes"])]),e("span",Pt,b(o.value)+"%",1)])])]),e("div",Ct,[e("div",Dt,[l(a(ee),{class:"fill-current transition text-gray-600",height:"35"})]),e("div",Tt,[zt,e("div",St,[e("div",Lt,[l(a(C),{modelValue:r.value,"onUpdate:modelValue":h[3]||(h[3]=d=>r.value=d),classes:a(D),format:u,showTooltip:"focus"},null,8,["modelValue","classes"])]),e("span",Mt,b(r.value)+"%",1)])])])])],64))}},Et=e("div",{class:"text-xs text-gray-400 font-medium mb-2"}," Background gradient type ",-1),jt={class:"mt-1 relative"},It={class:"block truncate"},Bt={class:"absolute inset-y-0 right-0 flex items-center pr-2 pointer-events-none"},Ot={setup(n){const t=w(),s=[{value:"radial",name:"Radial"},{value:"linear",name:"Linear"}],i=j(s,r=>r.value===t.dataForm.b3),o=_(s[i]);return V(o,r=>{r&&(t.dataForm.b3=o.value.value)}),(r,u)=>(m(),v("div",null,[Et,l(a(H),{as:"div",modelValue:o.value,"onUpdate:modelValue":u[0]||(u[0]=c=>o.value=c)},{default:p(()=>[e("div",jt,[l(a(I),{class:"bg-white relative w-full border border-solid border-gray-300 rounded-md shadow-sm pl-3 pr-10 py-2 text-left cursor-default focus:outline-none focus:ring-1 focus:ring-blue-300 focus:border-blue-300 sm:text-sm"},{default:p(()=>[e("span",It,b(o.value.name),1),e("span",Bt,[l(a(R),{class:"h-5 w-5 text-gray-400","aria-hidden":"true"})])]),_:1}),l(T,{"leave-active-class":"transition ease-in duration-100","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:p(()=>[l(a(B),{class:"absolute z-10 mt-1 w-full bg-white shadow-lg max-h-60 rounded-md py-1 text-base ring-1 ring-black ring-opacity-5 overflow-auto focus:outline-none sm:text-sm pl-0"},{default:p(()=>[(m(),v(k,null,L(s,c=>l(a(O),{as:"template",key:c.id,value:c},{default:p(({active:h,selected:d})=>[e("li",{class:g([h?"text-white bg-blue-400":"text-gray-900","cursor-default select-none relative py-2 pl-3 pr-9"])},[e("span",{class:g([d?"font-semibold":"font-normal","block truncate"])},b(c.name),3),d?(m(),v("span",{key:0,class:g([h?"text-white":"text-blue-600","absolute inset-y-0 right-0 flex items-center pr-4"])},[l(a(K),{class:"h-5 w-5","aria-hidden":"true"})],2)):A("",!0)],2)]),_:2},1032,["value"])),64))]),_:1})]),_:1})])]),_:1},8,["modelValue"])]))}},Ht=e("div",{class:"text-xs text-gray-400 font-medium mb-2"},"Gradient direction",-1),Rt={class:"mt-1 relative"},Kt={class:"block truncate capitalize"},Nt={class:"absolute inset-y-0 right-0 flex items-center pr-2 pointer-events-none"},qt={setup(n){const t=w(),s=F(()=>{let c;return t.dataForm.b3==="radial"&&(c=i),t.dataForm.b3==="linear"&&(c=o),c}),i=[{id:"at_top",value:"at top"},{id:"at_bottom",value:"at bottom"},{id:"at_left",value:"at left"},{id:"at_right",value:"at right"},{id:"at_center",value:"at center"}],o=[{id:"to_top",value:"to top"},{id:"to_left",value:"to left"},{id:"to_right",value:"to right"},{id:"to_bottom",value:"to bottom"}],r=j(s.value,c=>c.value===t.dataForm.b4),u=_(s.value[r]);return V(s,c=>{u.value=c[0]}),E(()=>{t.dataForm.b4=u.value.value}),(c,h)=>(m(),v("div",null,[Ht,l(a(H),{as:"div",modelValue:u.value,"onUpdate:modelValue":h[0]||(h[0]=d=>u.value=d)},{default:p(()=>[e("div",Rt,[l(a(I),{class:"bg-white relative w-full border border-solid border-gray-300 rounded-md shadow-sm pl-3 pr-10 py-2 text-left cursor-default focus:outline-none focus:ring-1 focus:ring-blue-300 focus:border-blue-300 sm:text-sm"},{default:p(()=>[e("span",Kt,b(u.value.value),1),e("span",Nt,[l(a(R),{class:"h-5 w-5 text-gray-400","aria-hidden":"true"})])]),_:1}),l(T,{"leave-active-class":"transition ease-in duration-100","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:p(()=>[l(a(B),{class:"absolute z-10 mt-1 w-full bg-white shadow-lg max-h-60 rounded-md py-1 text-base ring-1 ring-black ring-opacity-5 overflow-auto focus:outline-none sm:text-sm pl-0"},{default:p(()=>[(m(!0),v(k,null,L(a(s),d=>(m(),N(a(O),{as:"template",key:d.id,value:d},{default:p(({active:f,selected:x})=>[e("li",{class:g([f?"text-white bg-blue-400":"text-gray-900","cursor-default select-none relative py-2 pl-3 pr-9"])},[e("span",{class:g([[x?"font-semibold":"font-normal","block truncate"],"capitalize"])},b(d.value),3),x?(m(),v("span",{key:0,class:g([f?"text-white":"text-blue-600","absolute inset-y-0 right-0 flex items-center pr-4"])},[l(a(K),{class:"h-5 w-5","aria-hidden":"true"})],2)):A("",!0)],2)]),_:2},1032,["value"]))),128))]),_:1})]),_:1})])]),_:1},8,["modelValue"])]))}},Gt={class:"flex space-x-4"},Wt={class:"w-1/3"},Xt=e("div",{class:"text-xs text-gray-400 font-medium mb-2"},"Main color",-1),Yt={class:"pickr-wrapper w-full h-9 self-end flex-shrink-0 rounded inline-block ring-2 ring-white shadow-round"},Qt={class:"w-1/3"},Zt=e("div",{class:"text-xs text-gray-400 font-medium mb-2"},"Color stop1",-1),Jt={class:"pickr-wrapper w-full h-9 self-end flex-shrink-0 rounded inline-block ring-2 ring-white shadow-round"},es={class:"w-1/3"},ts=e("div",{class:"text-xs text-gray-400 font-medium mb-2"},"Color stop2",-1),ss={class:"pickr-wrapper w-full h-9 self-end flex-shrink-0 rounded inline-block ring-2 ring-white shadow-round"},os={setup(n){const t=w(),s=_(null),i=_(null),o=_(null);return X(()=>{z.create({el:s.value,default:t.dataForm.b0,theme:"nano",components:S}).on("save",(r,u)=>{t.dataForm.b0=r.toHEXA().toString(),u.hide()}),z.create({el:i.value,default:t.dataForm.b1,theme:"nano",components:S}).on("save",(r,u)=>{t.dataForm.b1=r.toHEXA().toString(),u.hide()}),z.create({el:o.value,default:t.dataForm.b2,theme:"nano",components:S}).on("save",(r,u)=>{t.dataForm.b2=r.toHEXA().toString(),u.hide()})}),(r,u)=>(m(),v("div",Gt,[e("div",Wt,[Xt,e("div",Yt,[e("div",{ref_key:"colorPickerElMain",ref:s},null,512)])]),e("div",Qt,[Zt,e("div",Jt,[e("div",{ref_key:"colorPickerElStop1",ref:i},null,512)])]),e("div",es,[ts,e("div",ss,[e("div",{ref_key:"colorPickerElStop2",ref:o},null,512)])])]))}},as={class:"flex space-x-4"},ls=["onClick"],rs=["onClick"],ns={setup(n){const t=w(),s=F(()=>t.dataIsChange);function i(){s.value&&t.saveData()}function o(){t.loadData()}return(r,u)=>(m(),v("div",as,[e("button",{type:"button",onClick:$(o,["prevent"]),class:"w-1/2 justify-center inline-flex items-center px-6 py-3 border border-gray-300 shadow-sm text-base font-medium rounded-md border-solid text-gray-700 bg-white hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500 cursor-pointer"}," Cancel ",8,ls),e("button",{type:"button",onClick:$(i,["prevent"]),class:g([a(s)?"bg-blue-500  hover:bg-blue-600 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500":"bg-gray-300 cursor-not-allowed","transition inline-flex w-1/2 justify-center cursor-pointer border-solid items-center px-6 py-3 border border-transparent text-base font-medium rounded-md shadow-sm text-white"])}," Save ",10,rs)]))}},is={class:"relative flex items-start border-solid border-x-0 border-2 border-gray-200 py-2 pr-4 select-none mt-8"},ds={class:"flex items-center h-4 mt-2"},cs=e("div",{class:"ml-3 text-sm"},[e("label",{class:"font-medium text-gray-500 cursor-pointer",for:"comments"}," Delete settings on deactivation? "),e("p",{id:"comments-description",class:"text-gray-400 m-0 text-xs"}," Check this box to delete your settings above when you deactivate the plugin. ")],-1),us={setup(n){const t=w(),s=F({get:()=>t.dataForm.delete_option_on_deactivate,set:i=>{t.dataForm.delete_option_on_deactivate=i}});return(i,o)=>(m(),v("div",is,[e("div",ds,[U(e("input",{id:"comments","onUpdate:modelValue":o[0]||(o[0]=r=>re(s)?s.value=r:null),"aria-describedby":"comments-description",class:"focus:ring-indigo-500 h-4 w-4 text-indigo-600 border-gray-300 rounded m-0",name:"comments",type:"checkbox"},null,512),[[le,a(s)]])]),cs]))}},fs={class:"space-y-3"},ms=e("div",{class:"text-xs text-gray-400 font-medium mb-2"}," Hide preloader after: ",-1),hs={class:"mt-1 relative"},vs={class:"block truncate"},ps={class:"absolute inset-y-0 right-0 flex items-center pr-2 pointer-events-none"},_s={class:"flex w-full items-center"},gs={class:"flex-grow"},xs={class:"text-xs text-gray-400 font-medium mb-2"},bs={key:0},ws={key:1},ys={class:"flex w-full items-center select-none"},$s={class:"flex-grow"},ks={class:"ml-4 text-right w-14 font-bold"},Fs={class:"flex w-full items-center"},As={class:"flex-grow"},Vs=e("div",{class:"text-xs text-gray-400 font-medium mb-2"}," The rate of speed animation ",-1),Ps={class:"flex w-full items-center select-none"},Cs={class:"flex-grow"},Ds={class:"ml-4 text-right w-14 font-bold"},Ts={setup(n){const t=[{value:"end",name:"Animation ended"},{value:"fullLoad",name:"Page Full load "}],s=w(),i=_(10),o=_(5);i.value=s.dataForm.t1,o.value=s.dataForm.t2;function r(h){return`${Math.round(h)}s`}E(()=>{s.dataForm.t1=i.value,s.dataForm.t2=o.value});const u=j(t,h=>h.value===s.dataForm.vmv_preloader),c=_(t[u]);return V(c,h=>{h&&(s.dataForm.vmv_preloader=c.value.value)}),(h,d)=>(m(),v("div",fs,[e("div",null,[ms,l(a(H),{modelValue:c.value,"onUpdate:modelValue":d[0]||(d[0]=f=>c.value=f),as:"div"},{default:p(()=>[e("div",hs,[l(a(I),{class:"bg-white relative w-full border border-solid border-gray-300 rounded-md shadow-sm pl-3 pr-10 py-2 text-left cursor-default focus:outline-none focus:ring-1 focus:ring-blue-300 focus:border-blue-300 sm:text-sm"},{default:p(()=>[e("span",vs,b(c.value.name),1),e("span",ps,[l(a(R),{"aria-hidden":"true",class:"h-5 w-5 text-gray-400"})])]),_:1}),l(T,{"leave-active-class":"transition ease-in duration-100","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:p(()=>[l(a(B),{class:"absolute z-10 mt-1 w-full bg-white shadow-lg max-h-60 rounded-md py-1 text-base ring-1 ring-black ring-opacity-5 overflow-auto focus:outline-none sm:text-sm pl-0"},{default:p(()=>[(m(),v(k,null,L(t,f=>l(a(O),{key:f.id,value:f,as:"template"},{default:p(({active:x,selected:y})=>[e("li",{class:g([x?"text-white bg-blue-400":"text-gray-900","cursor-default select-none relative py-2 pl-3 pr-9"])},[e("span",{class:g([y?"font-semibold":"font-normal","block truncate"])},b(f.name),3),y?(m(),v("span",{key:0,class:g([x?"text-white":"text-blue-600","absolute inset-y-0 right-0 flex items-center pr-4"])},[l(a(K),{"aria-hidden":"true",class:"h-5 w-5"})],2)):A("",!0)],2)]),_:2},1032,["value"])),64))]),_:1})]),_:1})])]),_:1},8,["modelValue"])]),e("div",_s,[e("div",gs,[e("div",xs,[c.value.value==="end"?(m(),v("span",bs,' "animation ended" + delay ')):(m(),v("span",ws," Max time for showing the preloader (will hide preloader even page is not fully loaded) "))]),e("div",ys,[e("div",$s,[l(a(C),{modelValue:i.value,"onUpdate:modelValue":d[1]||(d[1]=f=>i.value=f),classes:a(D),format:r,max:30,min:0,showTooltip:"focus"},null,8,["modelValue","classes"])]),e("span",ks,b(i.value)+" s ",1)])])]),e("div",Fs,[e("div",As,[Vs,e("div",Ps,[e("div",Cs,[l(a(C),{modelValue:o.value,"onUpdate:modelValue":d[2]||(d[2]=f=>o.value=f),classes:a(D),max:20,min:1,showTooltip:"focus"},null,8,["modelValue","classes"])]),e("span",Ds,b(o.value),1)])])])]))}},zs={class:"relative select-none"},Ss=e("div",{class:"text-xs text-gray-400 font-medium mb-2"}," Upload preloader animation file. ",-1),Ls={class:"mb-4 flex"},Ms={class:"relative flex-grow"},Us={class:"absolute top-0 left-0 w-full h-full"},Es=e("div",{class:"absolute left-0 w-full pr-1 mt-1 text-xs leading-none text-right text-red-500 top-full"},[e("div",{class:"hidden"},"Field is required")],-1),js={class:"relative ml-3"},Is=["data-tt1","data-tt2","disabled","onClick"],Bs={setup(n){const t=_(null),s=_(null),i=_(null),o=_(null),r=w(),u=".json",c=()=>{t.value.files.length>0?(s.value=t.value.files[0],i.value=s.value.name):(s.value=null,i.value=null)};function h(){t.value.setAttribute("type","text"),t.value.setAttribute("type","file"),s.value=null,i.value=null,o.value=null}function d(){if(!o.value&&i.value){o.value=!0;const f=new FormData;f.append("action","vmv_upload_file_premium_animations"),f.append("vmv_token",r.formKey),f.append("file",s.value),P.post(r.formAction,f,{headers:{"Content-Type":"multipart/form-data"}}).then(function(){h(),r.saveCount++,r.getListFilesAnimationPremium(),setTimeout(()=>{console.log(r.listThemes)},2e3)}).catch(function(){o.value=null})}}return(f,x)=>(m(),v("div",zs,[Ss,e("div",Ls,[e("div",Ms,[U(e("input",{"onUpdate:modelValue":x[0]||(x[0]=y=>i.value=y),class:"w-full leading-none transition flex outline-0 items-center h-10 px-4 text-base rounded shadow-sm border border-solid placeholder-opacity-40 bg-white border-gray-200 hover:border-gray-300 focus:ring-2 ring-blue-300 text-gray-700 placeholder-gray-700 box-border shadow-sm",placeholder:"Upload preloader file (*.json)",readonly:"",type:"text"},null,512),[[Y,i.value]]),e("label",Us,[U(e("input",{ref_key:"file",ref:t,accept:u,type:"file",onChange:c},null,544),[[ne,!1]])]),Es]),e("div",js,[e("button",{class:g([[i.value?"bg-blue-500  hover:bg-blue-600 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500":"bg-gray-300 cursor-not-allowed","transition inline-flex h-10  justify-center cursor-pointer border-solid items-center leading-none px-2 border border-transparent text-base font-small rounded-md shadow-sm text-white",o.value?"after:box-border text-opacity-0 cursor-not-allowed after:border-r-transparent after:border-solid  after:border-white after:animate-spin after:rounded-full after:w-4 after:h-4 after:left-1/2 after:top-1/2 after:block after:absolute after:border-2  after:-ml-2 after:-mt-2 ":""],"relative after:absolute"]),"data-tt1":o.value,"data-tt2":!i.value,disabled:!i.value||o.value,type:"button",onClick:$(d,["prevent"])}," Upload ",10,Is)])])]))}},Os={key:0,class:"space-y-3"},Hs=e("div",{class:"text-xs text-gray-400 font-medium mb-2"}," Select theme preloader: ",-1),Rs={class:"mt-1 relative"},Ks={class:"block truncate"},Ns={class:"absolute inset-y-0 right-0 flex items-center pr-2 pointer-events-none"},qs=["onClick"],Gs={setup(n){const t=w(),{listThemes:s}=W(t),i=j(s.value,c=>c.value===t.dataForm.themeFile),o=_(s.value[i]);V(o,c=>{c&&(t.dataForm.themeFile=o.value.value,t.dataForm.isPremium=o.value.isPremium)});function r(c,h){let d="";return c&&h&&(d+="bg-blue-500 text-white cursor-default"),!c&&h&&(d+="bg-blue-400 text-white cursor-pointer"),c&&!h&&(d+="bg-blue-500 text-white"),!c&&!h&&(d+="text-gray-900"),d}function u(c){t.deleteFile(c),t.saveData()}return(c,h)=>a(s)?(m(),v("div",Os,[e("div",null,[Hs,l(a(H),{modelValue:o.value,"onUpdate:modelValue":h[0]||(h[0]=d=>o.value=d),as:"div"},{default:p(()=>[e("div",Rs,[l(a(I),{class:"bg-white relative w-full border border-solid border-gray-300 rounded-md shadow-sm pl-3 pr-10 py-2 text-left cursor-default focus:outline-none focus:ring-1 focus:ring-blue-300 focus:border-blue-300 sm:text-sm"},{default:p(()=>[e("span",Ks,b(o.value.name),1),e("span",Ns,[l(a(ie),{"aria-hidden":"true",class:"h-5 w-5 text-gray-400"})])]),_:1}),l(T,{"leave-active-class":"transition ease-in duration-100","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:p(()=>[l(a(B),{class:"absolute z-10 mt-1 w-full bg-white shadow-lg max-h-60 rounded-md py-1 text-base ring-1 ring-black ring-opacity-5 overflow-auto focus:outline-none sm:text-sm pl-0"},{default:p(()=>[(m(!0),v(k,null,L(a(s),(d,f)=>(m(),N(a(O),{key:`item-${f}`,value:d,as:"template"},{default:p(({active:x,selected:y})=>[e("li",{class:g([r(y,x),"select-none relative py-2 pl-3 pr-9"])},[e("span",{class:g([y?"font-semibold":"font-normal","block truncate "])},b(d.name),3),d.isPremium&&a(t).dataForm.themeFile!==d.value?(m(),v("span",{key:0,class:"absolute inset-y-0 right-3 items-center inline-flex cursor-pointer",onClick:$(Fo=>u(d.value),["stop","prevent"])},[l(a(de),{"aria-hidden":"true",class:"h-5 w-5"})],8,qs)):A("",!0)],2)]),_:2},1032,["value"]))),128))]),_:1})]),_:1})])]),_:1},8,["modelValue"])])])):A("",!0)}},Ws=e("div",{class:"text-3xl text-gray-700 font-bold mb-4"},[me(" VMV Preloader "),e("a",{class:"text-sm no-underline text-blue-400 font-normal",href:"https://vmv.one",target:"_blank"},"(Learn more)")],-1),Xs={class:"space-y-6"},Ys={class:"-mb-px flex"},Qs={class:"flex space-x-4"},Zs={setup(n){const t=[{id:"main_set",name:"Main"},{id:"theme_set",name:"Theme"},{id:"background_set",name:"Background"},{id:"timing_set",name:"Timing"}];return(s,i)=>(m(),v(k,null,[Ws,e("div",Xs,[l(Re),l(a(fe),null,{default:p(()=>[l(a(ce),{class:"border-b border-gray-200"},{default:p(()=>[e("div",Ys,[(m(),v(k,null,L(t,o=>l(a(he),{key:o.id,as:"template"},{default:p(({selected:r})=>[e("button",{class:g(["w-1/3 py-4 px-1 text-center border-b-2 font-medium text-sm bg-transparent border-solid border-t-0 border-x-0 cursor-pointer transition focus:outline-0 focus:shadow-none",r?"border-blue-400 text-blue-500 shadow-none":"border-transparent text-gray-500 hover:text-gray-700 hover:border-gray-300"])},b(o.name),3)]),_:2},1024)),64))])]),_:1}),l(a(ue),null,{default:p(()=>[l(a(M),null,{default:p(()=>[l(Bs),l(Gs),l(us)]),_:1}),l(a(M),null,{default:p(()=>[l(Me,{class:"mb-6"}),l(Ut)]),_:1}),l(a(M),null,{default:p(()=>[e("div",Qs,[l(Ot,{class:"w-7/12 mb-4"}),l(qt,{class:"w-5/12"})]),l(os)]),_:1}),l(a(M),null,{default:p(()=>[l(Ts)]),_:1})]),_:1})]),_:1}),l(ns)])],64))}};var Js=(n,t)=>{const s=n.__vccOpts||n;for(const[i,o]of t)s[i]=o;return s};const eo={class:"flex space-x-4 justify-center mb-5"},to={class:"flex w-full justify-center"},so={class:"overflow-x-auto overflow-y-hidden h-full relative w-full border-solid border-8 border-gray-300 rounded-lg mx-auto select-none box-border shadow-round"},oo=["src"],ao=["onClick"],lo={setup(n){const t=w(),s=_("tablet"),i=_(null),o=_("");o.value="/vmv-preloader-preview/";function r(d){s.value=d}function u(){i.value.src+=""}const c=F(()=>{let d;switch(s.value){case"mobile":d={width:375,height:600};break;case"tablet":d={width:768,height:900};break;case"laptop":d={width:1100,height:900};break;case"desktop":d={width:1401,height:900};break;default:d={width:375,height:600};break}return d}),h=F(()=>t.countReloadDemo);return V(h,d=>{d&&u()}),(d,f)=>(m(),v(k,null,[e("div",eo,[e("a",{class:g([[s.value==="mobile"?"text-blue-400 focus:text-blue-400":"text-gray-500 focus:text-gray-500 hover:text-blue-300"],"focus:outline-none shadow-none"]),href:"#3",onClick:f[0]||(f[0]=$(x=>r("mobile"),["prevent"]))},[l(a(Q),{class:"fill-current transition",height:"40"})],2),e("a",{class:g([[s.value==="tablet"?"text-blue-400 focus:text-blue-400":"text-gray-500 focus:text-gray-500 hover:text-blue-300"],"focus:outline-none shadow-none"]),href:"#3",onClick:f[1]||(f[1]=$(x=>r("tablet"),["prevent"]))},[l(a(Z),{class:"fill-current transition",height:"40"})],2),e("a",{class:g([[s.value==="laptop"?"text-blue-400 focus:text-blue-400":"text-gray-500 focus:text-gray-500 hover:text-blue-300"],"focus:outline-none shadow-none"]),href:"#3",onClick:f[2]||(f[2]=$(x=>r("laptop"),["prevent"]))},[l(a(J),{class:"fill-current transition",height:"40"})],2),e("a",{class:g([[s.value==="desktop"?"text-blue-400 focus:text-blue-400":"text-gray-500 focus:text-gray-500 hover:text-blue-300"],"focus:outline-none shadow-none"]),href:"#3",onClick:f[3]||(f[3]=$(x=>r("desktop"),["prevent"]))},[l(a(ee),{class:"fill-current transition",height:"40"})],2)]),e("div",to,[e("div",{style:q({"max-width":a(c).width+16+"px",height:a(c).height+16+"px"}),class:"relative w-full transition-all"},[e("div",so,[e("div",{style:q({width:a(c).width+"px",height:a(c).height+"px"}),class:"absolute inline-block w-full transition-all"},[e("iframe",{ref_key:"demoIframe",ref:i,src:o.value,class:"border-0 block",height:"100%",width:"100%"},null,8,oo)],4)]),e("a",{class:"absolute bottom-5 right-5 z-10 w-10 h-10 cursor-pointer rounded-lg inline-flex bg-gray-400 text-white justify-center items-center hover:bg-gray-300",href:"#3",onClick:$(u,["prevent"])},[l(a(ve),{class:"w-4 h-4"})],8,ao)],4)])],64))}};var ro=Js(lo,[["__scopeId","data-v-0ec3945e"]]);const no={"aria-live":"assertive",class:"fixed top-10 inset-0 flex items-end px-4 py-6 pointer-events-none sm:p-6 sm:items-start"},io={class:"w-full flex flex-col items-center space-y-4 sm:items-end"},co={key:0,class:"max-w-sm w-full bg-white shadow-lg rounded-lg pointer-events-auto ring-1 ring-black ring-opacity-5 overflow-hidden"},uo={class:"p-4"},fo={class:"flex items-start"},mo={class:"flex-shrink-0"},ho=e("div",{class:"ml-3 w-0 flex-1 pt-0.5"},[e("p",{class:"text-sm font-medium text-gray-900 p-0 m-0"}," Successfully saved! ")],-1),vo={class:"ml-4 flex-shrink-0 flex"},po=e("span",{class:"sr-only"},"Close",-1),_o={setup(n){const t=w(),s=_(!1),i=F(()=>t.saveCount);return V(i,()=>{s.value=!0,setTimeout(()=>{s.value=!1},1500)}),(o,r)=>(m(),v("div",no,[e("div",io,[l(T,{"enter-active-class":"transform ease-out duration-300 transition","enter-from-class":"translate-y-2 opacity-0 sm:translate-y-0 sm:translate-x-2","enter-to-class":"translate-y-0 opacity-100 sm:translate-x-0","leave-active-class":"transition ease-in duration-100","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:p(()=>[s.value?(m(),v("div",co,[e("div",uo,[e("div",fo,[e("div",mo,[l(a(pe),{class:"h-6 w-6 text-green-400","aria-hidden":"true"})]),ho,e("div",vo,[e("button",{onClick:r[0]||(r[0]=u=>s.value=!1),class:"bg-white border-solid border-0 rounded-md inline-flex text-gray-400 hover:text-gray-500 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500"},[po,l(a(_e),{class:"h-5 w-5","aria-hidden":"true"})])])])])])):A("",!0)]),_:1})])]))}},go={key:0,class:"flex w-full pr-5 font-sans"},xo={class:"w-96 bg-white p-5 flex-shrink-0 shadow-lg z-1"},bo={class:"flex-grow bg-white px-6 py-5"},wo={key:1,class:"w-full h-full flex justify-center items-center"},yo=e("div",{class:"flex justify-center items-center pt-32"},[e("svg",{height:"24",viewBox:"0 0 128 128",width:"24",xmlns:"http://www.w3.org/2000/svg"},[e("rect",{fill:"none",height:"100%",width:"100%"}),e("g",null,[e("circle",{cx:"16",cy:"64",fill:"#a1a1a1",r:"16"}),e("circle",{cx:"16",cy:"64",fill:"silver",r:"16",transform:"rotate(45 64 64)"}),e("circle",{cx:"16",cy:"64",fill:"#d8d8d8",r:"16",transform:"rotate(90 64 64)"}),e("circle",{cx:"16",cy:"64",fill:"#ececec",r:"16",transform:"rotate(135 64 64)"}),e("circle",{cx:"16",cy:"64",fill:"#f4f4f4",r:"16",transform:"rotate(180 64 64)"}),e("circle",{cx:"16",cy:"64",fill:"#f4f4f4",r:"16",transform:"rotate(225 64 64)"}),e("circle",{cx:"16",cy:"64",fill:"#f4f4f4",r:"16",transform:"rotate(270 64 64)"}),e("circle",{cx:"16",cy:"64",fill:"#f4f4f4",r:"16",transform:"rotate(315 64 64)"}),e("animateTransform",{attributeName:"transform",calcMode:"discrete",dur:"720ms",repeatCount:"indefinite",type:"rotate",values:"0 64 64;315 64 64;270 64 64;225 64 64;180 64 64;135 64 64;90 64 64;45 64 64"})])]),e("div",{class:"text-2xl ml-4 font-medium font-sans text-gray-600"}," Loading... ")],-1),$o=[yo],ko={setup(n){const t=w(),s=document.querySelector("#app-vmv").getAttribute("data-vmv-action"),i=document.querySelector("#app-vmv").getAttribute("data-vmv-token");return t.formAction=s,t.formKey=i,t.loadData(),t.getListFilesAnimation(),t.getListFilesAnimationPremium(),(o,r)=>(m(),N(T,{mode:"out-in"},{default:p(()=>[a(t).dataLoaded?(m(),v("div",go,[e("div",xo,[l(Zs)]),e("div",bo,[l(ro)]),l(_o)])):(m(),v("div",wo,$o))]),_:1}))}};const te=ge(ko);te.use(xe());te.mount("#app-vmv");
  • vmv-preloader/trunk/vmv/preview-template/vmv-preloader-preview.php

    r2735219 r2765301  
    1313  <title>Document</title>
    1414  <?php wp_head(); ?>
     15
     16  <style>
     17    .vmv_demo_template {
     18      text-align: center;
     19      margin-top: 20%;
     20    }
     21  </style>
    1522</head>
    1623<body>
    17 <div>Demo preloader page</div>
     24<div>
     25  <div class="vmv_demo_template">
     26    <h4>Demo preloader page</h4>
     27  </div>
     28  <?php wp_footer(); ?>
     29</div>
    1830</body>
    1931</html>
  • vmv-preloader/trunk/vmv/vmv-activate.php

    r2735219 r2765301  
    2828    wp_insert_post( $vmv_demo_preview );
    2929  }
     30
     31
    3032}
    3133
  • vmv-preloader/trunk/vmv/vmv-admin-menu.php

    r2735219 r2765301  
    55}
    66
    7 function vmv_preloader_setup_menu() {
     7function vmv_admin_setup_menu() {
    88  add_menu_page(
    99    VMV_ONE__PLUGIN_NAME,
  • vmv-preloader/trunk/vmv/vmv-ajax-actions.php

    r2735219 r2765301  
    4545  foreach ( $_POST as $key => $value ) {
    4646    if ( $key === 'pluginActivated' || $key === 'delete_option_on_deactivate' || $key === 'isPremium' ) {
     47     
    4748      $new_option[ $key ] = filter_var( sanitize_text_field( $value ), FILTER_VALIDATE_BOOLEAN );
     49
     50      if($key === 'isPremium' && $new_option[ $key ] === true  ) {
     51        echo sanitize_text_field( $value );
     52        // setData
     53        $path_preloader_sources = 'premium-animations/';
     54        $f_json = VMV_ONE__PLUGIN_DIR . $path_preloader_sources . $option['themeFile'];
     55        $jsonDecoded = json_decode(file_get_contents($f_json), true);
     56        $new_option[ 'premiumDataSVG' ] =  $jsonDecoded[ 'svg' ];
     57        $new_option[ 'premiumDataSVGWidth' ] =  $jsonDecoded[ 'SVGWidth' ];
     58        $new_option[ 'premiumDataSVGHeight' ] =  $jsonDecoded[ 'SVGHeight' ];
     59        $new_option[ 'premiumSelectedThemeFile' ] =  $option['themeFile'];
     60        $new_option[ 'premiumDataSVGPulseLeft' ] =  $jsonDecoded[ 'pulseLeft' ];
     61        $new_option[ 'premiumDataSVGPulseBottom' ] =  $jsonDecoded[ 'pulseBottom' ];
     62      }
     63
    4864    } else if ( $key !== 'action' && $key !== 'vmv_token' ) {
    4965      $new_option[ $key ] = sanitize_text_field( $value );
    5066    }
     67  }
     68
     69  if($new_option['isPremium'] === true && $option['premiumSelectedThemeFile'] !== $new_option['themeFile']) {
     70    // setData
     71    $path_preloader_sources = 'premium-animations/';
     72    $f_json = VMV_ONE__PLUGIN_DIR . $path_preloader_sources . $new_option['themeFile'];
     73    $jsonDecoded = json_decode(file_get_contents($f_json), true);
     74    $new_option[ 'premiumDataSVG' ] =  $jsonDecoded[ 'svg' ];
     75    $new_option[ 'premiumDataSVGWidth' ] =  $jsonDecoded[ 'SVGWidth' ];
     76    $new_option[ 'premiumDataSVGHeight' ] =  $jsonDecoded[ 'SVGHeight' ];
     77    $new_option[ 'premiumSelectedThemeFile' ] =  $option['themeFile'];
     78    $new_option[ 'premiumDataSVGPulseLeft' ] =  $jsonDecoded[ 'pulseLeft' ];
     79    $new_option[ 'premiumDataSVGPulseBottom' ] =  $jsonDecoded[ 'pulseBottom' ];
     80    $new_option[ 'premiumSelectedThemeFile' ] =  $new_option['themeFile'];
    5181  }
    5282
  • vmv-preloader/trunk/vmv/vmv-miscellaneous.php

    r2736175 r2765301  
    33  exit;
    44}
    5 function vmv_preloader_frontend() {
     5
     6function vmv_admin_frontend() {
    67  wp_register_script( 'vmv_preloader_frontend_appjs', VMV_ONE__PLUGIN_URL . VMV_ONE__BASE . 'front-end-vue3/dist/assets/index.js', array(), VMV_ONE__PLUGIN_VERSION, false );
    7 
    88  wp_register_script( 'vmv_preloader_frontend_vendors', VMV_ONE__PLUGIN_URL . VMV_ONE__BASE . 'front-end-vue3/dist/assets/vendor.js', array(), VMV_ONE__PLUGIN_VERSION, false );
    9 
    109  wp_register_style( 'vmv_preloader_css', VMV_ONE__PLUGIN_URL . VMV_ONE__BASE . 'front-end-vue3/dist/assets/index.css', array(), VMV_ONE__PLUGIN_VERSION, 'screen' );
    11 
    1210  if ( ( is_admin() ) && ( array_key_exists( 'page', $_GET ) ) ) {
    1311    if ( $_GET['page'] == VMV_ONE__ADMIN_PAGE ) {
     
    2624    $tag = '<link rel="modulepreload" href="' . $src . '">';
    2725  }
    28 
    2926  return $tag;
    3027}
    31 
    3228add_filter( 'script_loader_tag', 'set_scripts_type_attribute', 10, 3 );
    3329
    3430
    35 function vmv_preloader_plugin_links( $links, $file ) {
     31function vmv_admin_plugin_links( $links, $file ) {
    3632  $plugin_file = explode( VMV_ONE__PLUGIN_DIR_NAME . '/', VMV_ONE__PLUGIN_FILE );
    3733  $plugin_file = VMV_ONE__PLUGIN_DIR_NAME . '/' . $plugin_file[1];
     
    4036    array_unshift( $links, $settings );
    4137  }
    42 
    4338  return $links;
    4439}
    4540
    46 function vmv_preloader_animation_script() {
     41
     42function vmv_preloader_head_section() {
    4743  $option = vmv_preloader_get_option();
    48 
    4944  $pluginActivated = $option['pluginActivated'];
    5045
    51   $vmv_preloader = esc_html( stripslashes( $option['vmv_preloader'] ) );
    52   $l1            = esc_html( stripslashes( $option['l1'] ) );
     46  $b0 = esc_html( stripslashes( $option['b0'] ) );
     47  $t4 = esc_html( stripslashes( $option['t4'] ) );
    5348
     49  global $post;
     50  $post_slug = $post->post_name;
     51  $demoView = 'false';
     52
     53  if ( $post_slug == 'vmv-preloader-preview' ) {
     54    $demoView = 'true';
     55  }
     56
     57  $currentCookie = 'vmv_PredL_' . $t4;
     58  if ( ( ! isset( $_COOKIE[ $currentCookie ] ) && $pluginActivated ) || $demoView == 'true' ) {
     59    echo '
     60      <style data-vmv-s0  data-stamp="'.$t4.'" data-y1="'.$demoView.'">
     61        body, html,#_vmv,#_vmv_fade{background-color:'.$b0.'!important;}
     62        #_vmv,#_vmv_fade{position: fixed;top: 0;left: 0;height: 100vh;width: 100vw; z-index: 2147483638;transform: translateZ(2147483638em);}
     63      </style>
     64      <script data-vmv-j1>
     65      window._vmv_s0=document.querySelector("style[data-vmv-s0]"),window._vmv_prefix="vmv_PredL",window._vmv_stamp=_vmv_s0.dataset.stamp,window._vmv_demo="true"===_vmv_s0.dataset.y1||!1,window._vmv_hidden=!!localStorage.getItem(`${_vmv_prefix}_${_vmv_stamp}`),"true"===_vmv_s0.dataset.y1&&(window._vmv_hidden=!1),_vmv_hidden||document.querySelector(":root").insertAdjacentHTML("afterbegin","<div id=\"_vmv_fade\"></div>");
     66      </script>'
     67    ;
     68  }
     69}
     70
     71// Use demo template for
     72function vmv_add_custom_demo_template( $template ) {
     73  global $post;
     74  if ( $post->post_type == 'page' && $post->post_name == 'vmv-preloader-preview' ) {
     75    return VMV_ONE__PLUGIN_DIR . 'preview-template/vmv-preloader-preview.php';
     76  }
     77  return $template;
     78}
     79
     80add_filter( 'page_template', 'vmv_add_custom_demo_template' );
     81
     82function vmv_preloader_footer_section(){
     83  $option = vmv_preloader_get_option();
     84  $pluginActivated = $option['pluginActivated'];
     85
     86  $strategy = esc_html( stripslashes( $option['vmv_preloader'] ) );
     87
     88  $l1 = esc_html( stripslashes( $option['l1'] ) );
    5489  $c1 = esc_html( stripslashes( $option['c1'] ) );
    5590  $c2 = esc_html( stripslashes( $option['c2'] ) );
     
    69104  $t2 = esc_html( stripslashes( $option['t2'] ) );
    70105  $t4 = esc_html( stripslashes( $option['t4'] ) );
     106 
     107  $previousL1 = esc_html( stripslashes( $option['previousL1'] ) );
     108  $dataLetters = esc_html( stripslashes( $option['dataLetters'] ) );
    71109
    72   $themeFile          = esc_html( stripslashes( $option['themeFile'] ) );
     110  $themeFile = esc_html( stripslashes( $option['themeFile'] ) );
    73111  $themeFileIsPremium = $option['isPremium'];
    74 
    75   $attrs = ' data-vmv_preloader="' . $vmv_preloader . '"';
    76   $attrs .= ' data-l1="' . $l1 . '"';
    77   $attrs .= ' data-c1="' . $c1 . '"';
    78   $attrs .= ' data-c2="' . $c2 . '"';
    79   $attrs .= ' data-b0="' . $b0 . '"';
    80   $attrs .= ' data-b1="' . $b1 . '"';
    81   $attrs .= ' data-b2="' . $b2 . '"';
    82   $attrs .= ' data-b3="' . $b3 . '"';
    83   $attrs .= ' data-b4="' . $b4 . '"';
    84 
    85   $attrs .= ' data-w1="' . $w1 . '"';
    86   $attrs .= ' data-w2="' . $w2 . '"';
    87   $attrs .= ' data-w3="' . $w3 . '"';
    88   $attrs .= ' data-w4="' . $w4 . '"';
    89 
    90   // Always
    91   $attrs .= ' data-t1="' . $t1 . '"';
    92   $attrs .= ' data-t2="' . $t2 . '"';
    93   $attrs .= ' data-t4="' . $t4 . '"';
     112  $premiumSelectedThemeFile = $option['premiumSelectedThemeFile'];
     113  $premiumDataSVG = $option['premiumDataSVG'];
     114  $premiumDataSVGWidth = $option['premiumDataSVGWidth'];
     115  $premiumDataSVGHeight = $option['premiumDataSVGHeight'];
     116  $premiumDataSVGPulseLeft = $option['premiumDataSVGPulseLeft'];
     117  $premiumDataSVGPulseBottom = $option['premiumDataSVGPulseBottom'];
    94118
    95119  global $post;
    96120  $post_slug = $post->post_name;
     121  $demoView = 'false';
     122
    97123  if ( $post_slug == 'vmv-preloader-preview' ) {
    98     $attrs .= ' data-d1="true"';
    99   }
    100 
    101   if ( $themeFile == 'KadisokaFont__bDEsYzEsYzIsYix3LHQ=.js' ) {
    102     $path_preloader_sources = VMV_ONE__PRELOADER_SRC;
    103     $f_json                 = $path_preloader_sources . 'Kadisoka_font_glyphs.php';
    104     include $f_json;
    105     $jsonDecoded = json_decode( $glyphsAlphabet, true );
    106     $logoLetters = str_split( $l1 );
    107     $arrayGlyphs = [];
    108     foreach ( $logoLetters as $itemLetter ) {
    109       $itemExist = array_search( 'G__' . ord( $itemLetter ), array_column( $arrayGlyphs, 'id' ) );
    110       if ( $itemExist === false ) {
    111         $itemIndex = array_search( 'G__' . ord( $itemLetter ), array_column( $jsonDecoded, 'id' ) );
    112         array_push( $arrayGlyphs, $jsonDecoded[ $itemIndex ] );
    113       }
    114     }
     124    $demoView = 'true';
    115125  }
    116126
    117127  $currentCookie = 'vmv_PredL_' . $t4;
    118   if ( ( ! isset( $_COOKIE[ $currentCookie ] ) && $pluginActivated ) || $post_slug == 'vmv-preloader-preview' ) {
    119     if ( $themeFile == 'KadisokaFont__bDEsYzEsYzIsYix3LHQ=.js' ) {
    120       echo "<script data-preloader-data>window.VMVPreloaderData=" . json_encode( $arrayGlyphs ) . ";</script>";
    121     }
     128  if ( ( ! isset( $_COOKIE[ $currentCookie ] ) && $pluginActivated ) || $demoView == 'true' ) {
     129    if ( $themeFile == 'KadisokaFont__bDEsYzEsYzIsYix3LHQ=.json' ) {
     130      if($previousL1 !== $l1) {
     131        $new_option = array();
     132        $path_preloader_sources = 'base-animations/';
     133        $f_json = VMV_ONE__PLUGIN_DIR . $path_preloader_sources . $themeFile;
     134        $jsonDecoded = json_decode(file_get_contents($f_json), true);
     135        $logoLetters = str_split( $l1 );
     136        $arrayGlyphs = [];
     137        foreach ( $logoLetters as $itemLetter ) {
     138          $itemExist = array_search( 'G__' . ord( $itemLetter ), array_column( $arrayGlyphs, 'id' ) );
     139          if ( $itemExist === false ) {
     140            $itemIndex = array_search( 'G__' . ord( $itemLetter ), array_column( $jsonDecoded, 'id' ) );
     141            array_push( $arrayGlyphs, $jsonDecoded[ $itemIndex ] );
     142          }
     143        }
     144        $jsonGlyphs = json_encode( $arrayGlyphs );
     145        $new_option[ 'previousL1' ] = $l1;
     146        $new_option[ 'dataLetters' ] = base64_encode($jsonGlyphs);
     147        vmv_preloader_update_option( $new_option, $option );
     148        $dataLettersToTemplate = $jsonGlyphs;
     149      }
     150      if($previousL1 == $l1) {
     151        $dataLettersToTemplate = base64_decode($dataLetters);
     152      }
     153      echo <<<END
     154        <div data-l1="$l1" id="_vmv_" data-w1="$w1" data-w2="$w2" data-w3="$w3" data-w4="$w4" data-t2="$t2" data-bg3="$b3" data-t1="$t1" data-strategy="$strategy"><div class="_vmv_pr__b"><div class="_vmv_pr__b-in"><div class="_vmv_pr__b-in-in"><svg class="_vmv_pr__svg" xmlns="http://www.w3.org/2000/svg"><defs class="_vmv_pr__svg-defs"></defs><g fill-rule="evenodd" fill="none" class="_vmv_pr__svg-glyphs"></g></svg><div class="_vmv_pr__ind"><div class="_vmv_pr__ind-in pr-1"></div><div class="_vmv_pr__ind-in pr-2"></div></div></div></div></div></div>
     155        <style data-vmv-s1 >#_vmv_{--bg-b0: $b0;--bg-b1: $b1;--bg-b2: $b2;--bg-b4: $b4;--fill: $c1;--fill-shadow: $c2;position: fixed;top: 0;left: 0;height: 100vh;width: 100vw;background-color: var(--bg-b0);z-index: 2147483638;background-blend-mode: screen;line-height: 1;font-size: 1px;overflow: hidden;transform: translateZ(2147483638em)}#_vmv_.is-hidding{transition: all 0.5s}._vmv_pr__b{opacity: 1;display: flex;height: 100%;width: 100%;justify-content: center;align-items: center;position: relative}._vmv_pr__b-in{position: relative;transform: scale(var(--vmv_scale))}._vmv_pr__b-in-in{transform: scale(var(--scaleBox))}._vmv_pr__b--r-bg{background: radial-gradient(var(--bg-b4), var(--bg-b1), var(--bg-b2))}._vmv_pr__b--l-bg{background: linear-gradient(var(--bg-b4), var(--bg-b1), var(--bg-b2))}._vmv_pr__svg{max-width: none;overflow: visible;filter: drop-shadow(1px 1px 3px var(--fill-shadow));transform: translateZ(2111221em)}._vmv_pr__svg-glyphs{stroke: var(--fill) !important}._vmv_pr__svg{position: relative}._vmv_pr__ind{opacity: 0;transition: opacity .2s;position: absolute;bottom: 4%;left: 100%;margin-left: 20px;width: 100px;height: 100px;transform-origin: 0 100%}._vmv_pr__ind-in{width: 0;position: absolute;border-radius: 50%;border: 1px solid $c1;top: 50%;left: 50%;transform: translateX(-50%) translateY(-50%);filter: drop-shadow(1px 1px 3px var(--str-shadow))}._vmv_pr__ind-in.pr-1{animation: pulse 1.5s ease infinite 0s}._vmv_pr__ind-in.pr-2{animation: pulse 1.5s ease infinite 0.4s}._vmv_pr__ind-in::before{content: '';display: block;padding-top: 100%}@keyframes pulse{0%{width: 0;opacity: 0}30%{opacity:1}100%{width: 100%;opacity:0}}.vmv-fill{transition: none;stroke-dasharray: var(--pathLength);stroke-dashoffset: var(--pathLength);animation: filling var(--timeDuration) linear forwards var(--timeDelay)}@keyframes filling{0%{stroke-dashoffset: var(--pathLength)}100%{stroke-dashoffset: 0}}</style>
     156      END;
     157      echo '<script data-vmv-j1>
     158      const _VMV_dataGlyphs='.$dataLettersToTemplate.';
     159      const _VMV_logo = "'.$l1.'";
     160      const _VMV_fontSpaceScale = 0.06;
     161      const _VMV_baseHeight = 55;
     162      (()=>{const t=document.getElementById("_vmv_"),e=1e3*t.dataset.t1||0,i=t.dataset.strategy,o=t.dataset.w1||80,s=t.dataset.w2||0,n=t.dataset.w3||0,d=t.dataset.w4||0,a=t.dataset.t2||5;let r=0;let _,c=!1,l=!1;if(void 0===window._vmv_hidden||window._vmv_hidden&&t)return t.remove(),b(),!1;"fullLoad"===i&&(_=setTimeout((()=>{l=!0,y()}),e),window.onload=function(){y&&(clearTimeout(_),l=!0,y())}),setTimeout((()=>{window._vmv_s0.remove(),document.getElementById("_vmv_fade").remove()}),500);const m=t.querySelector("._vmv_pr__svg"),h=t.querySelector("._vmv_pr__svg-defs"),w=t.querySelector("._vmv_pr__svg-glyphs");_VMV_dataGlyphs.forEach((t=>{t.defs.forEach((t=>{h.innerHTML+=t}))}));const u=_VMV_logo.split(""),v=_VMV_dataGlyphs.map((function(t){return t.id}));u.forEach((t=>{const e=t.charCodeAt(0),i=v.indexOf(`G__${e}`);-1!==i&&(w.innerHTML+=_VMV_dataGlyphs[i].glyph)}));const p=m.querySelectorAll("._vmv_pr__svg-glyphs > g");let g=0;p.forEach((t=>{const e=t.getAttribute("data-space-end"),i=t.getAttribute("data-space-start");g+=i*_VMV_fontSpaceScale,t.style.transform=`translateX(${g}px)`,g+=1*t.dataset.width+e*_VMV_fontSpaceScale,r+=1*t.dataset.width+i*_VMV_fontSpaceScale+e*_VMV_fontSpaceScale})),m.setAttribute("viewBox",`0 0 ${r} ${_VMV_baseHeight}`),m.style.width=4*r+"px",m.style.height=4*_VMV_baseHeight+"px";const f=t.querySelector("._vmv_pr__b");function y(){c&&!l&&(t.querySelector("._vmv_pr__ind").style.opacity=1),c&&l&&(t.classList.add("is-hidding"),setTimeout((()=>{t.style.opacity=0}),500),setTimeout((()=>{t.remove(),b(),function(){if(window._vmv_demo)return!1;(function(){const t=Object.assign({},localStorage);for(let e in t)e.includes(window._vmv_prefix)&&localStorage.removeItem(e);document.cookie.split(";").forEach((t=>{t.includes(window._vmv_prefix)&&(document.cookie=`${t}; max-age=-1;`)}))})(),localStorage.setItem(`${window._vmv_prefix}_${window._vmv_stamp}`,"done"),document.cookie=`${window._vmv_prefix}_${window._vmv_stamp}=done; max-age=31104000; path=/`}()}),1e3))}function b(){[...document.querySelectorAll("script, style")].forEach((t=>{const e=t?.dataset;if(e)for(const[i]of Object.entries(e))(i.includes("vmvJ")||i.includes("vmvS"))&&t.remove()}))}!function(){const o=document.querySelector("._vmv_pr__svg");[...o.querySelectorAll("._vmv_pr__svg-glyphs > g")].forEach(((t,e)=>{const i=t.getAttribute("id");t.setAttribute("id",`${i}__ROOT__${e}`)}));const s=o.querySelectorAll("path[clip-path]"),n=document.createElement("style");n.setAttribute("data-vmv-s2","");const d=document.querySelector("style[data-vmv-s1]");let r=.2,_="",m=1;const h=s.length;var w,u;s.forEach(((t,o)=>{t.classList.add("vmv-fill");let s=t.parentElement;const d=`${t.getAttribute("id")}-t${o}`;t.setAttribute("id",d),s.getAttribute("id").includes("__ROOT__")||(s=s.parentElement);const w=s.getAttribute("id"),u=Number(t.getTotalLength().toFixed(3));_===w?m++:m=1;const v=Number(t.parentElement.dataset.duration)||1,p=Number((u*a*v/1e3).toFixed(3));n.innerHTML+=`#${w} path#${d} {--pathLength: ${u};--timeDelay: ${r}s; --timeDuration: ${p}s;}`,r=Number((r+p).toFixed(3)),_=w,h-1===o&&t.addEventListener("animationend",(function(){c=!0,"end"===i&&e>=1e3&&setTimeout((()=>{l=!0,y()}),e),y()}),!1)})),u=n,(w=d).parentNode.insertBefore(u,w.nextSibling);const v="radial"===t.dataset.bg3?"_vmv_pr__b--r-bg":"_vmv_pr__b--l-bg";f.classList.add(v)}(),setTimeout((()=>{f.style.width="101%"}));const x=new class{constructor(t,e,i,o){this.mobile=window.matchMedia("(max-width:767px)"),this.tablet=window.matchMedia("(min-width:768px) and (max-width: 1023px)"),this.desktop=window.matchMedia("(min-width:1024px) and (max-width: 1399px)"),this.wide_desktop=window.matchMedia("(min-width:1400px)"),this.w1_width=null,this.w2_width=null,this.w3_width=null,this.w4_width=null,this.initWidth(t,e,i,o)}initWidth(t,e,i,o){this.w1_width=0===Number(t)?.8:Number(t)/100,this.w2_width=0===Number(e)?this.w1_width:Number(e)/100,this.w3_width=0===Number(i)?this.w2_width:Number(i)/100,this.w4_width=0===Number(o)?this.w3_width:Number(o)/100}getWidthCorrection(){return this.mobile.matches?this.w1_width:this.tablet.matches?this.w2_width:this.desktop.matches?this.w3_width:this.wide_desktop.matches?this.w4_width:void 0}}(o,s,n,d);let S=0;function V(){t.style.paddingLeft="1px",S=t.getBoundingClientRect().width,t.style.paddingLeft="0px",animationBoxWidth=S*x.getWidthCorrection(),t.style.setProperty("--vmv_scale",""+animationBoxWidth/(r+70))}t.style.setProperty("--scaleBox","0.25"),window.addEventListener("resize",V),V()})();
     163      </script>';
     164    } else if($themeFileIsPremium) {
     165      $dataSVGToTemplate = base64_decode($premiumDataSVG);
     166      $dataSVGWidthToTemplate = $premiumDataSVGWidth;
     167      $dataSVGHeightToTemplate = $premiumDataSVGHeight;
     168      $dataSVGPulseLeftToTemplate = $premiumDataSVGPulseLeft;
     169      $dataSVGPulseBottomToTemplate = $premiumDataSVGPulseBottom;
    122170
    123     if ( $themeFileIsPremium ) {
    124       echo '<script src="' . VMV_ONE__PLUGIN_URL . VMV_ONE__BASE . 'premium-animations/' . $themeFile . '"' . $attrs . '></script>';
    125     } else {
    126       echo '<script src="' . VMV_ONE__PLUGIN_URL . VMV_ONE__BASE . 'base-animations/' . $themeFile . '"' . $attrs . '></script>';
     171      echo <<<END
     172        <div data-l1="$l1" id="_vmv_" data-w1="$w1" data-w2="$w2" data-w3="$w3" data-w4="$w4" data-t2="$t2" data-bg3="$b3" data-t1="$t1" data-strategy="$strategy"><div class="_vmv_pr__b"><div class="_vmv_pr__b-in"><div class="_vmv_pr__b-in-in"><svg class="_vmv_pr__svg" xmlns="http://www.w3.org/2000/svg"><defs class="_vmv_pr__svg-defs"></defs><g fill-rule="evenodd" fill="none" class="_vmv_pr__svg-glyphs">$dataSVGToTemplate</g></svg><div class="_vmv_pr__ind"><div class="_vmv_pr__ind-in _vmv_pr__ind-in-pr-1"></div><div class="_vmv_pr__ind-in _vmv_pr__ind-in-pr-2"></div></div></div></div></div></div>
     173        <style data-vmv-s1 >
     174        #_vmv_{--bg-b0: $b0;--bg-b1: $b1;--bg-b2: $b2;--bg-b4: $b4;--fill: $c1;--fill-shadow: $c2;--pulse-left: $dataSVGPulseLeftToTemplate;--pulse-bottom:$dataSVGPulseBottomToTemplate;position:fixed;top:0;left:0;height:100vh;width:100vw;background-color:var(--bg-b0);z-index:2147483638;background-blend-mode:screen;line-height:1;font-size:1px;overflow:hidden;transform:translateZ(2147483638em)}#_vmv_.is-hidding{transition:all .5s}._vmv_pr__b{opacity:1;display:flex;height:100%;width:100%;justify-content:center;align-items:center;position:relative}._vmv_pr__b-in{position:relative;transform:scale(var(--vmv_scale))}._vmv_pr__b-in-in{transform:scale(var(--scaleBox))}._vmv_pr__b--r-bg{background:radial-gradient(var(--bg-b4),var(--bg-b1),var(--bg-b2))}._vmv_pr__b--l-bg{background:linear-gradient(var(--bg-b4),var(--bg-b1),var(--bg-b2))}._vmv_pr__svg{max-width:none;overflow:visible;filter:drop-shadow(1px 1px 3px var(--fill-shadow));transform:translateZ(2111221em)}._vmv_pr__svg{position:relative}._vmv_pr__ind{opacity:0;transition:opacity .2s;position:absolute;bottom:0;left:100%;margin-left:var(--pulse-left);margin-bottom:var(--pulse-bottom);width:100px;height:100px;transform-origin:0 100%}
     175        ._vmv_pr__ind-in{width:0;position:absolute;border-radius:50%;border:1px solid  $c1;top:50%;left:50%;transform:translateX(-50%) translateY(-50%);filter:drop-shadow(1px 1px 3px var(--str-shadow))}._vmv_pr__ind-in-pr-1{animation:pulse 1.5s ease infinite 0s}._vmv_pr__ind-in-pr-2{animation:pulse 1.5s ease infinite .4s}._vmv_pr__ind-in:before{content:'';display:block;padding-top:100%}@keyframes pulse{0%{width:0;opacity:0}30%{opacity:1}100%{width:100%;opacity:0}}.vmv-fill{stroke-dasharray:var(--pathLength);stroke-dashoffset:var(--pathLength);animation:filling var(--timeDuration) linear forwards var(--timeDelay);transition:none}@keyframes filling{0%{stroke-dashoffset:var(--pathLength)}100%{stroke-dashoffset:0}}
     176        </style>
     177      END;
     178
     179      echo '<script data-vmv-j1>
     180      const _VMV_baseHeight = '.$dataSVGHeightToTemplate.';
     181      const _VMV_baseWidth = '.$dataSVGWidthToTemplate.';
     182      (()=>{const t=document.getElementById("_vmv_"),e=1e3*t.dataset.t1||0,i=t.dataset.strategy,d=t.dataset.w1||80,o=t.dataset.w2||0,s=t.dataset.w3||0,n=t.dataset.w4||0,a=t.dataset.t2||5;let r,_=!1,m=!1;if(void 0===window._vmv_hidden||window._vmv_hidden&&t)return t.remove(),w(),!1;"fullLoad"===i&&(r=setTimeout((()=>{m=!0,h()}),e),window.onload=function(){h&&(clearTimeout(r),m=!0,h())}),setTimeout((()=>{window._vmv_s0.remove(),document.getElementById("_vmv_fade").remove()}),500);const l=t.querySelector("._vmv_pr__svg");t.querySelector("._vmv_pr__svg-defs"),t.querySelector("._vmv_pr__svg-glyphs"),l.querySelectorAll("#Signature > g");l.setAttribute("viewBox",`0 0 ${_VMV_baseWidth} ${_VMV_baseHeight}`),l.style.width=4*_VMV_baseWidth+"px",l.style.height=4*_VMV_baseHeight+"px";const c=t.querySelector("._vmv_pr__b");function h(){_&&!m&&(t.querySelector("._vmv_pr__ind").style.opacity=1),_&&m&&(t.classList.add("is-hidding"),setTimeout((()=>{t.style.opacity=0}),500),setTimeout((()=>{t.remove(),w(),function(){if(window._vmv_demo)return!1;(function(){const t=Object.assign({},localStorage);for(let e in t)e.includes(window._vmv_prefix)&&localStorage.removeItem(e);document.cookie.split(";").forEach((t=>{t.includes(window._vmv_prefix)&&(document.cookie=`${t}; max-age=-1;`)}))})(),localStorage.setItem(`${window._vmv_prefix}_${window._vmv_stamp}`,"done"),document.cookie=`${window._vmv_prefix}_${window._vmv_stamp}=done; max-age=31104000; path=/`}()}),1e3))}function w(){[...document.querySelectorAll("script, style")].forEach((t=>{const e=t?.dataset;if(e)for(const[i]of Object.entries(e))(i.includes("vmvJ")||i.includes("vmvS"))&&t.remove()}))}!function(){const d=document.querySelector("._vmv_pr__svg");[...d.querySelectorAll("#Signature > g")].forEach(((t,e)=>{const i=t.getAttribute("id");t.setAttribute("id",`${i}__ROOT__${e}`)}));const o=d.querySelectorAll("path[clip-path]"),s=document.createElement("style");s.setAttribute("data-vmv-s2","");const n=document.querySelector("style[data-vmv-s1]");let r=.2,l="",w=1;const u=o.length;var v,p;o.forEach(((t,d)=>{t.classList.add("vmv-fill");let o=t.parentElement;const n=`${t.getAttribute("id")}-t${d}`;t.setAttribute("id",n),o.getAttribute("id").includes("__ROOT__")||(o=o.parentElement);const c=o.getAttribute("id"),v=Number(t.getTotalLength().toFixed(3));l===c?w++:w=1;const p=Number(t.parentElement.dataset.duration)||1,g=Number((v*a*p/1e3).toFixed(3));s.innerHTML+=`#${c} path#${n} {--pathLength: ${v};--timeDelay: ${r}s; --timeDuration: ${g}s;}`,r=Number((r+g).toFixed(3)),l=c,u-1===d&&(s.innerHTML+="._vmv_pr__svg-glyphs {stroke: var(--fill) !important;}",t.addEventListener("animationend",(function(){_=!0,"end"===i&&e>=1e3&&setTimeout((()=>{m=!0,h()}),e),h()}),!1))})),p=s,(v=n).parentNode.insertBefore(p,v.nextSibling);const g="radial"===t.dataset.bg3?"_vmv_pr__b--r-bg":"_vmv_pr__b--l-bg";c.classList.add(g)}(),setTimeout((()=>{c.style.width="101%"}));const u=new class{constructor(t,e,i,d){this.mobile=window.matchMedia("(max-width:767px)"),this.tablet=window.matchMedia("(min-width:768px) and (max-width: 1023px)"),this.desktop=window.matchMedia("(min-width:1024px) and (max-width: 1399px)"),this.wide_desktop=window.matchMedia("(min-width:1400px)"),this.w1_width=null,this.w2_width=null,this.w3_width=null,this.w4_width=null,this.initWidth(t,e,i,d)}initWidth(t,e,i,d){this.w1_width=0===Number(t)?.8:Number(t)/100,this.w2_width=0===Number(e)?this.w1_width:Number(e)/100,this.w3_width=0===Number(i)?this.w2_width:Number(i)/100,this.w4_width=0===Number(d)?this.w3_width:Number(d)/100}getWidthCorrection(){return this.mobile.matches?this.w1_width:this.tablet.matches?this.w2_width:this.desktop.matches?this.w3_width:this.wide_desktop.matches?this.w4_width:void 0}}(d,o,s,n);let v=0;function p(){t.style.paddingLeft="1px",v=t.getBoundingClientRect().width,t.style.paddingLeft="0px",animationBoxWidth=v*u.getWidthCorrection(),t.style.setProperty("--vmv_scale",""+animationBoxWidth/(_VMV_baseWidth+70))}t.style.setProperty("--scaleBox","0.25"),window.addEventListener("resize",p),p()})();
     183      </script>';
    127184    }
    128185  }
    129186}
    130 
    131 // Use demo template for
    132 function vmv_add_custom_demo_template( $template ) {
    133   global $post;
    134   if ( $post->post_type == 'page' && $post->post_name == 'vmv-preloader-preview' ) {
    135     return VMV_ONE__PLUGIN_DIR . 'preview-template/vmv-preloader-preview.php';
    136   }
    137 
    138   return $template;
    139 }
    140 
    141 add_filter( 'page_template', 'vmv_add_custom_demo_template' );
  • vmv-preloader/trunk/vmv/vmv-option.php

    r2735219 r2765301  
    88    'pluginActivated'             => false,
    99    'delete_option_on_deactivate' => false,
    10     'l1'                          => 'Your logo',
     10    'l1'                          => 'Your name',
    1111    'c1'                          => '#EBEBEB',
    12     'c2'                          => 'rgba(0, 0, 0, 0.2)',
     12    'c2'                          => 'rgba(0, 0, 0, 0.8)',
    1313    'b0'                          => '#004E98',
    1414    'b1'                          => '#5D9CDF',
     
    2424    't4'                          => '1644573315',
    2525    'vmv_preloader'               => 'end',
    26     'themeFile'                   => 'KadisokaFont__bDEsYzEsYzIsYix3LHQ=.js',
     26    'vmvBgIsActive'               => false,
     27    'vmvBgData'                   => null,
     28    'themeFile'                   => 'KadisokaFont__bDEsYzEsYzIsYix3LHQ=.json',
    2729    'isPremium'                   => false,
     30    'previousL1'                  => '',
     31    'dataLetters'                 => null,
     32    'premiumSelectedThemeFile'    => null,
     33    'premiumDataSVG'              => null,
     34    'premiumDataSVGWidth'         => null,
     35    'premiumDataSVGHeight'        => null,
     36    'premiumDataSVGPulseLeft'     => null,
     37    'premiumDataSVGPulseBottom'   => null,
    2838  );
    2939
Note: See TracChangeset for help on using the changeset viewer.