5 lines
1.0 KiB
JavaScript
5 lines
1.0 KiB
JavaScript
|
|
/*!
|
||
|
|
Build based on gin-vue-admin
|
||
|
|
Time : 1776662816000 */
|
||
|
|
import{O as e,P as a,a as t,af as s,c as n,d as r,o,K as l,n as u,x as i}from"./087AC4D233B64EB0index.D-00lXMX.js";const c=["src","alt"],g="/logo-dark.png",d="/logo.png",p={__name:"index",props:{size:{type:Number,default:2}},setup(p){const v=p,x=e(),{isDark:y}=a(x),f=t(""),m=t(!1);function b(e){return new Promise(a=>{const t=new Image;t.onload=()=>a(!0),t.onerror=()=>a(!1),t.src=e})}function k(){return{width:"".concat(16*v.size,"px"),height:"".concat(16*v.size,"px")}}return s(async()=>{m.value=!1,y.value&&await b(g)?f.value=g:await b(d)?f.value=d:m.value=!0}),(e,a)=>!m.value&&f.value?(o(),n("img",{key:0,src:f.value,alt:e.$GIN_VUE_ADMIN.appName,class:u(["object-contain",{"filter invert-[90%] hue-rotate-180 brightness-110":i(y)&&"/logo.png"===f.value}]),style:l({...k()})},null,14,c)):m.value?(o(),n("div",{key:1,class:"rounded-full bg-gray-300 dark:bg-gray-600 flex items-center justify-center text-gray-700 dark:text-gray-200 font-bold text-xs",style:l({...k()})}," GVA ",4)):r("",!0)}};export{p as _};
|