var E=Object.defineProperty;var c=Object.getOwnPropertySymbols;var _=Object.prototype.hasOwnProperty,D=Object.prototype.propertyIsEnumerable;var F=(e,o,n)=>o in e?E(e,o,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[o]=n,L=(e,o)=>{for(var n in o||(o={}))_.call(o,n)&&F(e,n,o[n]);if(c)for(var n of c(o))D.call(o,n)&&F(e,n,o[n]);return e};import{d as W,f as C,r as A,I as T,U as r,v as w,q as P,a2 as $,ad as N,af as i,a4 as R,k as a,G as u}from"./vue-vendor-CxLCUzY4.js";import{be as k,bf as V,_ as q}from"./index-Cy4uayzW.js";import{P as G}from"./index-CRgSyMPH.js";import{A as b}from"./antd-vue-vendor-CahNzUUa.js";import"./vxe-table-vendor-Cdi8WfTx.js";import"./useContentHeight-XU-h1taH.js";import"./useWindowSizeFn-DDyhhqyw.js";import"./useContentViewHeight-Qm4QNm5l.js";import"./usePageContext-CXQdt-5h.js";import"./injectionKey-DPVn4AgL.js";const I=W({components:{Loading:V,PageWrapper:G,[b.name]:b},setup(){const e=C(null),o=C(!1),n=A({absolute:!1,loading:!1,theme:"dark",background:"rgba(111,111,111,.7)",tip:"加载中..."}),[m,g]=k({tip:"加载中..."}),[f,s]=k({target:e,props:{tip:"加载中...",absolute:!0}});function t(B){n.absolute=B,n.loading=!0,setTimeout(()=>{n.loading=!1},2e3)}function l(){t(!1)}function p(){t(!0)}function d(){m(),setTimeout(()=>{g()},2e3)}function y(){f(),setTimeout(()=>{s()},2e3)}function v(){o.value=!0,setTimeout(()=>{o.value=!1},2e3)}return L({openCompFullLoading:l,openFnFullLoading:d,openFnWrapLoading:y,openCompAbsolute:p,wrapEl:e,loadingRef:o,openDirectiveLoading:v},T(n))}}),S={ref:"wrapEl"};function U(e,o,n,m,g,f){const s=r("a-alert"),t=r("a-button"),l=r("Loading"),p=r("PageWrapper"),d=w("loading");return P(($(),N(p,{"loading-tip":"加载中...",title:"Loading组件示例"},{default:i(()=>[R("div",S,[a(s,{message:"组件方式"}),a(t,{class:"my-4 mr-4",type:"primary",onClick:e.openCompFullLoading},{default:i(()=>o[0]||(o[0]=[u(" 全屏 Loading ")])),_:1},8,["onClick"]),a(t,{class:"my-4",type:"primary",onClick:e.openCompAbsolute},{default:i(()=>o[1]||(o[1]=[u(" 容器内 Loading ")])),_:1},8,["onClick"]),a(l,{loading:e.loading,absolute:e.absolute,theme:e.theme,background:e.background,tip:e.tip},null,8,["loading","absolute","theme","background","tip"]),a(s,{message:"函数方式"}),a(t,{class:"my-4 mr-4",type:"primary",onClick:e.openFnFullLoading},{default:i(()=>o[2]||(o[2]=[u(" 全屏 Loading ")])),_:1},8,["onClick"]),a(t,{class:"my-4",type:"primary",onClick:e.openFnWrapLoading},{default:i(()=>o[3]||(o[3]=[u(" 容器内 Loading ")])),_:1},8,["onClick"]),a(s,{message:"指令方式"}),a(t,{class:"my-4 mr-4",type:"primary",onClick:e.openDirectiveLoading},{default:i(()=>o[4]||(o[4]=[u(" 打开指令Loading ")])),_:1},8,["onClick"])],512)]),_:1})),[[d,e.loadingRef]])}const h=q(I,[["render",U]]);export{h as default};
