import{d as C,f as _,u,U as t,a2 as v,ad as y,af as n,k as r,a4 as g,G as b}from"./vue-vendor-CxLCUzY4.js";import{C as k}from"./index-BRTtls-l.js";import{bl as w,u as x,_ as B}from"./index-CYriLmQo.js";import{P as h}from"./index-BxgvQLkr.js";import"./antd-vue-vendor-CDWW6V_M.js";import"./index-DOuVMe-q.js";import"./index-CxQILSKV.js";import"./index-ByLO0zSl.js";import"./useTimeout-DC8132dd.js";import"./vxe-table-vendor-B5h3MVdD.js";import"./useIntersectionObserver-FVRzwlSd.js";import"./useContentHeight-DtBiGC0g.js";import"./useWindowSizeFn-BxrEMPtP.js";import"./useContentViewHeight-D71xl1HH.js";import"./usePageContext-CCgh0KDo.js";import"./injectionKey-DPVn4AgL.js";const P=C({name:"Copy",components:{CollapseContainer:k,PageWrapper:h},setup(){const o=_(""),{createMessage:e}=x(),{clipboardRef:p,copiedRef:s}=w();function i(){const a=u(o);if(!a){e.warning("请输入要拷贝的内容！");return}p.value=a,u(s)&&e.warning("copy success！")}return{handleCopy:i,value:o}}}),$={class:"flex justify-center"};function F(o,e,p,s,i,a){const l=t("a-input"),m=t("a-button"),c=t("CollapseContainer"),d=t("PageWrapper");return v(),y(d,{title:"文本复制示例"},{default:n(()=>[r(c,{class:"w-full h-32 bg-white rounded-md",title:"Copy Example"},{default:n(()=>[g("div",$,[r(l,{placeholder:"请输入",value:o.value,"onUpdate:value":e[0]||(e[0]=f=>o.value=f)},null,8,["value"]),r(m,{type:"primary",onClick:o.handleCopy},{default:n(()=>e[1]||(e[1]=[b(" Copy ")])),_:1},8,["onClick"])])]),_:1})]),_:1})}const J=B(P,[["render",F]]);export{J as default};
