import{Y as e,Z as o,a$ as t,b0 as i,o as a,j as r,w as s,m as n,y as d,e as l,F as c,k as u,z as v,I as m,l as _,B as h,A as f}from"./index-d4baa715.js";import{p as y}from"./uv-loading-icon.vue_vue_type_style_index_0_scoped_bad0efbf_lang.8998f762.js";import{_ as g}from"./_plugin-vue_export-helper.1b428a4d.js";const p=g({name:"uv-loading-icon",mixins:[e,o,y],data:()=>({array12:Array.from({length:12}),aniAngel:360,webviewHide:!1,loading:!1}),computed:{otherBorderColor(){const e=t(this.color,"#ffffff",100)[80];return"circle"===this.mode?this.inactiveColor?this.inactiveColor:e:"transparent"}},watch:{show(e){}},mounted(){this.init()},methods:{init(){setTimeout((()=>{}),20)},addEventListenerToWebview(){const e=i(),o=e[e.length-1].$getAppWebview();o.addEventListener("hide",(()=>{this.webviewHide=!0})),o.addEventListener("show",(()=>{this.webviewHide=!1}))}}},[["render",function(e,o,t,i,y,g){const p=h,w=f;return e.show?(a(),r(p,{key:0,class:n(["uv-loading-icon",[e.vertical&&"uv-loading-icon--vertical"]]),style:d([e.$uv.addStyle(e.customStyle)])},{default:s((()=>[y.webviewHide?v("",!0):(a(),r(p,{key:0,class:n(["uv-loading-icon__spinner",[`uv-loading-icon__spinner--${e.mode}`]]),ref:"ani",style:d({color:e.color,width:e.$uv.addUnit(e.size),height:e.$uv.addUnit(e.size),borderTopColor:e.color,borderBottomColor:g.otherBorderColor,borderLeftColor:g.otherBorderColor,borderRightColor:g.otherBorderColor,"animation-duration":`${e.duration}ms`,"animation-timing-function":"semicircle"===e.mode||"circle"===e.mode?e.timingFunction:""})},{default:s((()=>["spinner"===e.mode?(a(!0),l(c,{key:0},u(y.array12,((e,o)=>(a(),r(p,{key:o,class:"uv-loading-icon__dot"})))),128)):v("",!0)])),_:1},8,["class","style"])),e.text?(a(),r(w,{key:1,class:"uv-loading-icon__text",style:d([{fontSize:e.$uv.addUnit(e.textSize),color:e.textColor},e.$uv.addStyle(e.textStyle)])},{default:s((()=>[m(_(e.text),1)])),_:1},8,["style"])):v("",!0)])),_:1},8,["style","class"])):v("",!0)}],["__scopeId","data-v-bad0efbf"]]);export{p as _};
