import{Q as C,aw as q,R as F,d as x,a4 as H,W as S,b as $,o as l,c as _,a6 as g,e as t,K as b,r as P,ap as K,X as L,q as m,a0 as y,p as v,aH as M,L as V,z as k,h as j,bw as z,aq as A,u as G,a as W,d8 as J,cF as O,m as N,bu as Q,I as X,J as U,B as Y,G as E,ae as Z,$ as w,w as ee,aF as te,T as ae}from"./index-XuO881sr.js";const se=C({separator:{type:String,default:"/"},separatorIcon:{type:q}}),R=Symbol("breadcrumbKey"),re=C({to:{type:F([String,Object]),default:""},replace:Boolean}),ne=["aria-label"];var oe=x({name:"ElBreadcrumb",__name:"breadcrumb",props:se,setup(p){const{t:n}=H(),i=p,u=S("breadcrumb"),a=P();return K(R,i),$(()=>{const s=a.value.querySelectorAll(`.${u.e("item")}`);s.length&&s[s.length-1].setAttribute("aria-current","page")}),(s,h)=>(l(),_("div",{ref_key:"breadcrumb",ref:a,class:b(t(u).b()),"aria-label":t(n)("el.breadcrumb.label"),role:"navigation"},[g(s.$slots,"default")],10,ne))}}),ce=oe,le=x({name:"ElBreadcrumbItem",__name:"breadcrumb-item",props:re,setup(p){const n=p,i=j(),u=L(R,void 0),a=S("breadcrumb"),s=i.appContext.config.globalProperties.$router,h=()=>{!n.to||!s||(n.replace?s.replace(n.to):s.push(n.to))};return(f,I)=>(l(),_("span",{class:b(t(a).e("item"))},[m("span",{class:b([t(a).e("inner"),t(a).is("link",!!p.to)]),role:"link",onClick:h},[g(f.$slots,"default")],2),t(u)?.separatorIcon?(l(),y(t(V),{key:0,class:b(t(a).e("separator"))},{default:v(()=>[(l(),y(M(t(u).separatorIcon)))]),_:1},8,["class"])):(l(),_("span",{key:1,class:b(t(a).e("separator")),role:"presentation"},k(t(u)?.separator),3))],2))}}),T=le;const ie=A(ce,{BreadcrumbItem:T}),ue=z(T),de={key:0,class:"no-redirect"},pe=["onClick"],me=x({__name:"index",setup(p){const n=G(),i=W(),u=J(),a=P([]),s=()=>{let e=[];if(h(n.path)>2){const r=/\/\w+/gi,d=n.path.match(r).map((o,B)=>(B!==0&&(o=o.slice(1)),o));f(d,u.defaultRoutes,e)}else e=n.matched.filter(r=>r.meta&&r.meta.title);I(e[0])||(e=[{path:"/index",meta:{title:"首页"}}].concat(e)),a.value=e.filter(r=>r.meta&&r.meta.title&&r.meta.breadcrumb!==!1)},h=(e,c="/")=>typeof e!="string"||e.length===0?0:e.split(c).length-1,f=(e,c,r)=>{const d=c.find(o=>o.path==e[0]||(o.name+="").toLowerCase()==e[0]);d&&(r.push(d),d.children&&e.length&&(e.shift(),f(e,d.children,r)))},I=e=>{const c=e&&e.name;return c?c.trim()==="Index":!1},D=e=>{const{redirect:c,path:r}=e;c?i.push(c):i.push(r)};return O(()=>{n.path.startsWith("/redirect/")||s()}),$(()=>{s()}),(e,c)=>{const r=ue,d=ie;return l(),y(d,{class:"app-breadcrumb",separator:">"},{default:v(()=>[N(Q,{name:"breadcrumb"},{default:v(()=>[(l(!0),_(X,null,U(t(a),(o,B)=>(l(),y(r,{key:o.path},{default:v(()=>[o.redirect==="noRedirect"||B==t(a).length-1?(l(),_("span",de,k(o.meta?.title),1)):(l(),_("a",{key:1,onClick:Y(xe=>D(o),["prevent"])},k(o.meta?.title),9,pe))]),_:2},1024))),128))]),_:1})]),_:1})}}}),_e=E(me,[["__scopeId","data-v-77b492cd"]]),be={class:"PageHeaderBox"},he={class:"leftbox"},fe={class:"pageTitleBox flex items-center"},ve={class:"pagetitle"},ge={class:"h-20px"},ye={class:"rightbox"},ke=x({__name:"index",props:{title:{type:String,default:"房屋管理"}},setup(p){const n=Z(),i=ae(()=>n.content&&n.content().length>0),u=p;return(a,s)=>(l(),_("div",be,[m("div",he,[N(_e,{class:"breadcrumb-container"}),m("div",fe,[s[0]||(s[0]=m("div",{class:"line"},null,-1)),m("div",ve,k(u.title),1)]),t(i)?g(a.$slots,"content",{key:0},void 0,!0):w("",!0),ee(m("div",ge,null,512),[[te,!t(i)]])]),m("div",ye,[t(i)?g(a.$slots,"operate",{key:0},void 0,!0):w("",!0)])]))}}),Ie=E(ke,[["__scopeId","data-v-1d8e0d22"]]);export{Ie as P};
