import{bO as we,cu as xe,cv as $e,cw as Se,cx as Ce,cy as Ie,bQ as Me,cz as Qe,bS as Ve,bU as Oe,cA as Pe,cB as Ke,cC as Te,cD as qe,cE as Be,aS as R,b5 as oe,af as De,cF as He,bC as X,aC as ne,cG as We,q as K,b$ as Xe,cH as pe,I as n,cI as Ee,cJ as Ne,c7 as le,ar as A,c9 as Ye,aF as Je,cK as Ze,cL as et,bD as tt,as as at,cd as F,aK as l,u as f,bH as o,c5 as re,s as _,v as b,b9 as p,t as h,bM as st,cj as C,cl as Y,cm as de,H as P,cn as Re,co as ee,cp as ue,cq as _e,cr as nt,bi as D,cM as Ae,ak as ie,aX as I,F as U,aV as Q,ch as B,ci as V,az as rt,ce as it,bc as fe,cN as ot,aI as lt,cO as me,cf as ct,cP as dt,aQ as ut,cQ as _t,cR as ht,cS as pt,cc as ft,cT as mt,cU as bt,cV as yt,cW as gt,cX as vt,cY as kt,cZ as jt,c_ as wt,bW as xt,bd as $t,bT as St,ct as Ct,at as be,cs as It}from"./index-UvaAT40e.js";import{T as Vt}from"./ThreeColumnLayout-BRd-Jgmr.js";import{_ as Ot}from"./PlaceHolderImage-OI0HV4no.js";import{d as x,I as Pt,O as Tt}from"./MainPartTS-BwEa5n97.js";import{V as G,C as qt}from"./ChildTreeSearchButton-C65ZPLlZ.js";import{V as Fe}from"./VDialog-D0VE7Pjp.js";import{t as ye,a as Bt,c as Dt}from"./triplestore-YmGWX4yk.js";import{S as Et,B as Nt,N as Rt,g as H,Q as At,G as Ft,D as Lt,a as zt,F as Ut}from"./graph-B_VAwInf.js";import{O as ge,a as Le}from"./ObjectCard-Ck5X7LdM.js";import{V as ze}from"./VContainer-DgTE6ig0.js";import{L as Gt}from"./LoadingSpinner-CRcacgcO.js";import{V as Mt,b as Qt,a as Kt,c as Ht}from"./VTabs-CxMeqQ0V.js";import{u as Wt}from"./vue.8fc199ce-I-_LDAN3.js";import"./Anchor-DbUVFTxQ.js";import"./ImageViewer-B7OLRv7S.js";import"./_commonjsHelpers-C4iS2aBk.js";import"./VSlider-tpXMn7rf.js";import"./VSliderTrack-BSvqM6gM.js";import"./VInput-tBjZAjEz.js";import"./transform-CA9Jdjju.js";import"./VSlideGroup-BkB-Mi6K.js";function Xt(e){const t=oe(e());let a=-1;function s(){clearInterval(a)}function i(){s(),at(()=>t.value=e())}function r(c){const d=c?getComputedStyle(c):{transitionDuration:.2},y=parseFloat(d.transitionDuration)*1e3||200;if(s(),t.value<=0)return;const v=performance.now();a=window.setInterval(()=>{const g=performance.now()-v+y;t.value=Math.max(e()-g,0),t.value<=0&&s()},y)}return Je(s),{clear:s,time:t,start:r,reset:i}}const Yt=we({multiLine:Boolean,text:String,timer:[Boolean,String],timeout:{type:[Number,String],default:5e3},vertical:Boolean,...xe({location:"bottom"}),...$e(),...Se(),...Ce(),...Ie(),...Me(Qe({transition:"v-snackbar-transition"}),["persistent","noClickAnimation","scrim","scrollStrategy"])},"VSnackbar"),Ue=Ve()({name:"VSnackbar",props:Yt(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:a}=t;const s=Oe(e,"modelValue"),{positionClasses:i}=Pe(e),{scopeId:r}=Ke(),{themeClasses:c}=Te(e),{colorClasses:d,colorStyles:y,variantClasses:v}=qe(e),{roundedClasses:g}=Be(e),E=Xt(()=>Number(e.timeout)),T=R(),w=R(),$=oe(!1),L=oe(0),u=R(),m=De(Ze,void 0);He(()=>!!m,()=>{const q=et();tt(()=>{u.value=q.mainStyles.value})}),X(s,S),X(()=>e.timeout,S),ne(()=>{s.value&&S()});let j=-1;function S(){E.reset(),window.clearTimeout(j);const q=Number(e.timeout);if(!s.value||q===-1)return;const Z=We(w.value);E.start(Z),j=window.setTimeout(()=>{s.value=!1},q)}function k(){E.reset(),window.clearTimeout(j)}function O(){$.value=!0,k()}function N(){$.value=!1,S()}function J(q){L.value=q.touches[0].clientY}function z(q){Math.abs(L.value-q.changedTouches[0].clientY)>50&&(s.value=!1)}function te(){$.value&&N()}const M=K(()=>e.location.split(" ").reduce((q,Z)=>(q[`v-snackbar--${Z}`]=!0,q),{}));return Xe(()=>{const q=pe.filterProps(e),Z=!!(a.default||a.text||e.text);return n(pe,A({ref:T,class:["v-snackbar",{"v-snackbar--active":s.value,"v-snackbar--multi-line":e.multiLine&&!e.vertical,"v-snackbar--timer":!!e.timer,"v-snackbar--vertical":e.vertical},M.value,i.value,e.class],style:[u.value,e.style]},q,{modelValue:s.value,"onUpdate:modelValue":ae=>s.value=ae,contentProps:A({class:["v-snackbar__wrapper",c.value,d.value,g.value,v.value],style:[y.value],onPointerenter:O,onPointerleave:N},q.contentProps),persistent:!0,noClickAnimation:!0,scrim:!1,scrollStrategy:"none",_disableGlobalStack:!0,onTouchstartPassive:J,onTouchend:z,onAfterLeave:te},r),{default:()=>{var ae,he;return[Ee(!1,"v-snackbar"),e.timer&&!$.value&&n("div",{key:"timer",class:"v-snackbar__timer"},[n(Ne,{ref:w,color:typeof e.timer=="string"?e.timer:"info",max:e.timeout,"model-value":E.time.value},null)]),Z&&n("div",{key:"content",class:"v-snackbar__content",role:"status","aria-live":"polite"},[((ae=a.text)==null?void 0:ae.call(a))??e.text,(he=a.default)==null?void 0:he.call(a)]),a.actions&&n(le,{defaults:{VBtn:{variant:"text",ripple:!1,slim:!0}}},{default:()=>[n("div",{class:"v-snackbar__actions"},[a.actions({isActive:s})])]})]},activator:a.activator})}),Ye({},T)}}),Jt={props:{path:{type:String,default:""},id:{type:String,default:""}},data:function(){return{dialog:!1,snackbar:!1,timeout:1e3,base_url:"https://db.antiquitatum-thesaurus.eu"}},computed:{today(){return new Date().toLocaleDateString()},perma_url(){return`${this.base_url}/${this.path}/${this.id}`}},methods:{copy_inner_text(e){this.copy_to_clipboard(e.target.innerText)},async copy_to_clipboard(e){try{await navigator.clipboard.writeText(e),this.snackbar=!0}catch{alert("Cannot copy")}}}},Zt={class:"text-caption permalink text-primary"},ea={class:"mt-4 text-body"},ta={italic:""},aa={class:"permalink-title"},sa={key:0};function na(e,t,a,s,i,r){return l(),f("span",Zt,[n(C,{size:"20",icon:"mdi-information-outline",onClick:t[0]||(t[0]=st(c=>e.dialog=!0,["stop"]))},{default:o(()=>[n(re,{size:"18"}),e.$vuetify.display.sm||e.$vuetify.display.xs?h("",!0):(l(),_(G,{key:0,location:"left","open-delay":"500",activator:"parent"},{default:o(()=>[b("span",null,p(e.$t("user_info.permalink_info_short")),1)]),_:1}))]),_:1}),n(Fe,{modelValue:e.dialog,"onUpdate:modelValue":t[3]||(t[3]=c=>e.dialog=c),width:"500"},{default:o(()=>[n(Y,null,{default:o(()=>[n(de,{class:"text-h5 mt-2 px-5"},{default:o(()=>t[7]||(t[7]=[P(" Zitierhinweis ")])),_:1}),n(Re,{class:"px-5 pt-0",style:{"font-size":"0.875rem"}},{default:o(()=>[n(ee),b("p",ea,p(e.$t("user_info.citation_note_p1")),1),t[8]||(t[8]=b("br",null,null,-1)),b("p",null,p(e.$t("user_info.citation_note_p2")),1),t[9]||(t[9]=b("br",null,null,-1)),b("p",ta,[n(G,{location:"bottom","open-delay":"300"},{activator:o(({props:c})=>[b("a",A(c,{onClick:t[1]||(t[1]=(...d)=>r.copy_inner_text&&r.copy_inner_text(...d))}),"Antiquitatum Thesaurus, ID "+p(a.id)+", "+p(r.perma_url)+" ("+p(e.$t("user_info.citation_note_accessed"))+" "+p(r.today)+").",17)]),default:o(()=>[b("span",null,p(e.$t("user_info.copy_to_clipboard_info")),1)]),_:1})])]),_:1}),n(ue,null,{default:o(()=>[n(_e),n(C,{color:"#c60c30",variant:"text",onClick:t[2]||(t[2]=c=>e.dialog=!1)},{default:o(()=>[P(p(e.$t("site_navigation.close")),1)]),_:1})]),_:1})]),_:1})]),_:1},8,["modelValue"]),b("span",aa,[t[10]||(t[10]=P(" Permalink: ")),e.$vuetify.display.xs?(l(),f("br",sa)):h("",!0),b("a",{onClick:t[4]||(t[4]=(...c)=>r.copy_inner_text&&r.copy_inner_text(...c))},[P(p(r.perma_url)+" ",1),e.$vuetify.display.sm||e.$vuetify.display.xs?h("",!0):(l(),_(G,{key:0,location:"bottom","open-delay":"300",activator:"parent"},{default:o(()=>[b("span",null,p(e.$t("user_info.copy_to_clipboard_info")),1)]),_:1}))])]),n(Ue,{modelValue:e.snackbar,"onUpdate:modelValue":t[6]||(t[6]=c=>e.snackbar=c),timeout:e.timeout},{actions:o(({attrs:c})=>[n(C,A({color:"rgb(198, 12, 48)",variant:"text"},c,{onClick:t[5]||(t[5]=d=>e.snackbar=!1)}),{default:o(()=>[P(p(e.$t("site_navigation.close")),1)]),_:2},1040)]),default:o(()=>[P(p(e.$t("user_info.copied"))+" ",1)]),_:1},8,["modelValue","timeout"])])}const ra=F(Jt,[["render",na],["__scopeId","data-v-0f0998d3"]]),ia={key:0},oa={__name:"BackToSearchButton",setup(e){const t=nt();return(a,s)=>D(t).last_search?(l(),f("div",ia,[n(C,{variant:"text",color:"primary",to:{name:"Search",query:D(t).last_search}},{default:o(()=>[P(p(a.$t("label.back_to_search")),1)]),_:1},8,["to"])])):h("",!0)}},la=Ae("comparison",{state:()=>({savedObject:null}),actions:{saveObject(e){this.savedObject=e},deleteSavedObject(){this.savedObject=null}}}),ca={__name:"ObjectComparisonButtons",setup(e){const t=la();let a=R(!1);return(s,i)=>(l(),f("div",null,[D(t).savedObject?(l(),_(G,{key:0,location:"right","open-delay":"300"},{activator:o(({props:r})=>[n(C,A({class:"mt-2",icon:"mdi-pin-off",size:"28"},r,{onClick:D(t).deleteSavedObject}),{default:o(()=>[n(re,{color:"rgb(198, 12, 48)"})]),_:2},1040,["onClick"])]),default:o(()=>[b("span",null,p(s.$t("site_navigation.delete_preselection")),1)]),_:1})):(l(),_(G,{key:1,location:"right","open-delay":"300"},{activator:o(({props:r})=>[n(C,A({class:"mt-2",icon:"mdi-pin",size:"28"},r,{onClick:i[0]||(i[0]=()=>{ie(a)?a.value=!0:a=!0,D(t).saveObject(s.$route.params.objectid)})}),null,16)]),default:o(()=>[b("span",null,p(s.$t("site_navigation.preselect_for_comparison")),1)]),_:1})),D(t).savedObject&&D(t).savedObject!=s.$route.params.objectid?(l(),_(G,{key:2,location:"right","open-delay":"300"},{activator:o(({props:r})=>[n(C,A({class:"mt-2",icon:"mdi-compare",size:"28"},r,{onClick:i[1]||(i[1]=c=>s.$router.push(`/comparison/${D(t).savedObject}/with/${s.$route.params.objectid}`))}),null,16)]),default:o(()=>[b("span",null,p(s.$t("site_navigation.compare_with_preselection")),1)]),_:1})):h("",!0),n(Ue,{modelValue:D(a),"onUpdate:modelValue":i[3]||(i[3]=r=>ie(a)?a.value=r:a=r),"multi-line":"",timeout:"8000"},{actions:o(({attrs:r})=>[n(C,A({color:"rgb(198, 12, 48)",variant:"text"},r,{onClick:i[2]||(i[2]=c=>ie(a)?a.value=!1:a=!1)}),{default:o(()=>[P(p(s.$t("site_navigation.close")),1)]),_:2},1040)]),default:o(()=>[P(p(s.$t("site_navigation.comparison_instructions"))+" ",1)]),_:1},8,["modelValue"])]))}},ve={sorting:"production_date_asc",results_per_page:60},da={name:"DetailPaginator",inject:["parent_ac"],data(){return{ac:this.parent_ac,filter_object_id:null,results_per_page:null,page:null,sort:null,result:[],total_count:null,results_loaded:!1}},computed:{current_index(){return this.results_loaded?this.result.findIndex(e=>e.iri.endsWith("/"+this.$route.params.objectid)):-1}},created(){this.ac=new AbortController,this.read_component_states_from_url(),this.dispatch_search()},unmounted(){this.ac.abort()},methods:{read_component_states_from_url(){this.page=parseInt(this.$route.query.page)||1,this.results_per_page=parseInt(this.$route.query.items)||ve.results_per_page,this.sort=this.$route.query.sorting||ve.sorting,this.filter_object_id=this.$route.query.parent_id||null},async dispatch_search(){this.results_loaded=!1;try{this.result=await ye.search({q:this.$route.query.q,qfilter:this.$route.query.qfilter,filter_object_id:this.filter_object_id,limit:this.results_per_page,offset:this.results_per_page*(this.page-1),sorting:this.sort,signal:this.ac.signal}),this.total_count=await ye.get_total_count({q:this.$route.query.q,qfilter:this.$route.query.qfilter,filter_object_id:this.filter_object_id,signal:this.ac.signal}),this.results_loaded=!0}catch(e){e.name!="AbortError"&&(this.results_loaded=!1,console.error(e))}},async next_object(e){let t=Object.assign({},this.$route.query),a=null;e=="forward"?this.current_index+1==this.result.length?(this.page++,this.ac.abort(),this.ac=new AbortController,await this.dispatch_search(),t.page?t.page++:t.page=2,a=this.result[0].iri.split("/").slice(-1)[0]):a=this.result[this.current_index+1].iri.split("/").slice(-1)[0]:this.current_index==0?(this.page--,this.ac.abort(),this.ac=new AbortController,await this.dispatch_search(),t.page==2?delete t.page:t.page--,a=this.result[this.results_per_page-1].iri.split("/").slice(-1)[0]):a=this.result[this.current_index-1].iri.split("/").slice(-1)[0],this.$router.push({name:"Object",params:{objectid:a},query:t})}}},ua={key:0},_a={class:"text-button text-primary",style:{"user-select":"none"}};function ha(e,t,a,s,i,r){return i.results_loaded?(l(),f("div",ua,[n(C,{icon:"mdi-chevron-left",size:"24",disabled:r.current_index==0&&i.page==1,onClick:t[0]||(t[0]=c=>r.next_object("backward"))},null,8,["disabled"]),b("span",_a,p(r.current_index+1+i.results_per_page*(i.page-1))+" / "+p(i.total_count),1),n(C,{icon:"mdi-chevron-right",size:"24",disabled:r.current_index+1+i.results_per_page*(i.page-1)==i.total_count,onClick:t[1]||(t[1]=c=>r.next_object("forward"))},null,8,["disabled"])])):h("",!0)}const pa=F(da,[["render",ha]]),Ge=Ae("graph",{state:()=>({saved_raw_networks:{inverted_idx:{}},saved_prepared_networks:{},graph_empty:!1}),actions:{save_tree(e,t){e.forEach(a=>this.saved_prepared_networks[a]=t)},save_networks(e){this.saved_raw_networks=e}},getters:{getNetworkForId:e=>t=>{const a=e.saved_raw_networks.inverted_idx[t],s={nodes:{},links:[]};for(let i of a){let r=e.saved_raw_networks.links[i];r.source in s.nodes||(s.nodes[r.source]=e.saved_raw_networks.nodes[r.source]),r.target in s.nodes||(s.nodes[r.target]=e.saved_raw_networks.nodes[r.target]),s.links.push(r)}return s}}}),fa={class:"d-flex flex-nowrap"},ma={class:"d-flex flex-nowrap"},ba={style:{"min-width":"70px"}},ya={style:{"max-width":"calc(100% - 70px)"}},ga={__name:"ObjectTree",props:{children:{type:Array,default:()=>[]}},setup(e){async function t(a){if(a.children.length==0){let s=a.iri.split("/").slice(-1)[0],r=(await x.get_children(s)).children;for(let c of r)c.has_child&&(c.children=[]);a.children=r}}return(a,s)=>{const i=I("v-treeview");return l(),f("div",null,[n(i,{items:e.children,"load-children":t,density:"compact"},{title:o(({item:r})=>[b("div",fa,[r.has_child?h("",!0):(l(),_(_e,{key:0,style:{width:"34px"}})),n(Y,{variant:"outlined",width:"100%",class:"ma-1 object-card text-decoration-none",to:{name:"Object",params:{objectid:r.iri.split("/").slice(-1)[0]}}},{default:o(()=>[b("div",ma,[b("div",ba,[n(D(ge),{images:r.images,"with-tree-button":!1,"image-height":60},null,8,["images"])]),b("div",ya,[n(de,{class:"text-body-2 hyphenate",style:{"line-height":"1.25rem","white-space":"normal"}},{default:o(()=>[P(p(r.title),1)]),_:2},1024)]),r.children?(l(),_(ue,{key:0,class:"ml-auto"},{default:o(()=>[n(D(qt),{objectid:r.iri.split("/").slice(-1)[0]},null,8,["objectid"])]),_:2},1024)):h("",!0),r&&!(a.$vuetify.display.sm||a.$vuetify.display.xs)?(l(),_(G,{key:1,activator:"parent",location:"left",width:"40vh","open-delay":"600","content-class":"image-tooltip"},{default:o(()=>[n(D(ge),{images:r.images,"image-height":"40vh"},null,8,["images"])]),_:2},1024)):h("",!0)])]),_:2},1032,["to"])])]),_:1},8,["items"])])}}},va=F(ga,[["__scopeId","data-v-9ce54215"]]),ka={components:{ObjectCard:Le,ObjectTree:va},props:{data:{type:Array,default:()=>[]},panels:{type:Boolean,default:!1},tree:{type:Boolean,default:!1}},data:function(){return{image_height:140,active_panel:[]}},methods:{fill_row:function(e){let t=e.length%3;return t?3-t:0},has_comment:function(e){return e.comment?!0:(this.$emit("show_error","missing_objectdata"),!1)}}},ja={key:0};function wa(e,t,a,s,i,r){const c=I("ObjectTree"),d=I("ObjectCard");return a.data.length?(l(),f("span",ja,[a.tree?(l(),_(c,{key:0,children:a.data},null,8,["children"])):(l(),_(B,{key:1},{default:o(()=>[(l(!0),f(U,null,Q(a.data,(y,v)=>(l(),_(V,{key:v,class:"d-flex child-flex",cols:"6",md:"6",lg:"4",sm:"4"},{default:o(()=>[n(d,{iri:y,"image-height":140,"with-breadcrumbs":"","tooltip-enabled":""},null,8,["iri"])]),_:2},1024))),128))]),_:1}))])):h("",!0)}const xa=F(ka,[["render",wa]]);class se extends Et{constructor(t,a){super(a),this.object_iris=t}}class W{constructor(t,a=100,s=100,i="",r=!1){this.url=t,this.width=a,this.height=s,this.style=i,this.is_placeholder=r}}class ce extends Rt{constructor(t,a,s,i,r,c){super(t,a,s,i),this.node_iri=r,this.node_img=c}}class ke extends ce{constructor(t,a,s,i,r,c,d){super(t,a,s,i,r,c),this.dating=d}}class $a extends Nt{constructor(){super()}get_root_node(t){const a=t.split("/").slice(-1)[0],s=new se([t],null);return new ce("","","root",a,s,t,new W(""))}create_node(t,a){const s=t.node_iri.split("/").slice(-1)[0],i=new se([t.node_iri],a);let r=null;t.node_img?r=new W(t.node_img):r=new W("/logo.jpg",70,70,"",!0);let c="";return t.node_label&&(c=t.node_label),new ce(c,"object",s,i,t.node_iri,r)}}class Sa extends $a{constructor(){super()}get_root_node(t){const a=t.split("/").slice(-1)[0],s=new se([t],null);return new ke("","","root",a,s,t,new W(""),{from:"",to:""})}create_node(t,a){const s=t.node_iri.split("/").slice(-1)[0],i=new se([t.node_iri],a);let r=null;return t.node_img?r=new W(t.node_img):r=new W("/logo.jpg",70,70,"",!0),new ke(`${t.node_label}`,"object",s,i,t.node_iri,r,t.dating||{from:"",to:""})}}class Ca extends At{async get_children(t,a){return H.get_relations_for(t,a)}async get_node(t,a){const s=await H.get_node(t,a);return s.node.edge_label="",s}}class Ia extends Ca{async get_children(t,a){return H.get_relations_for(t,a,!1)}async get_dating(t,a){return x.get_dating_for_object(t,a)}async get_all_relations(t){return H.get_all_relations(t)}async get_all_nodes(t){return H.get_all_nodes(t)}}const je={__name:"ObjectGraph",props:{objectId:{type:Number,required:!0},width:{type:String,default:""},height:{type:String,default:""},reload:{type:Boolean,default:!1},graphtype:{type:String,default:"time"},expanded:{type:Boolean,default:!1}},setup(e){rt(()=>a.graph_empty=!1);const t=it(),a=Ge(),s=e,i=R(!1),r=K(()=>s.expanded?"outlined":"flat");X(()=>s.graphtype,(u,m)=>{u!=m&&T()});const c=new Sa,d=new Ia;let y=De("parent_ac");function v(u){let m=[];return u.forEach(j=>{var S;(S=j.dating)!=null&&S.from||m.push(d.get_dating(`https://db.antiquitatum-thesaurus.eu/object/${j.id}`,y.value.signal))}),m}function g(){i.value=!0,s.objectId in a.saved_prepared_networks||s.objectId in a.saved_raw_networks.inverted_idx?T():new Ut(c,d).create_networks(y.value.signal).then(m=>{a.save_networks(m),T()})}function E(u){const{getNetworkForId:m}=ot(a),j=[u],S=new Set([u]);let k={nodes:{},links:[]};for(;j.length>0;){const O=j.shift();let N=m.value(O);const J=new Set([...k.links,...N.links]);k={nodes:{...k.nodes,...N.nodes},links:[...J]};for(const z of Object.values(N.nodes))S.has(z.id)||(S.add(z.id),j.push(z.id))}return k}function T(){if(s.objectId&&s.width&&s.height)if(i.value=!0,s.objectId in a.saved_prepared_networks){i.value=!1;let u=a.saved_prepared_networks[s.objectId];u={nodes:Object.values(u.nodes),links:u.links},u=w(s.objectId,u),$(u)}else{i.value=!1;let u=E(s.objectId);const m=v(Object.values(u.nodes));Promise.allSettled(m).then(async j=>{console.info("load dating"),i.value=!1,j.forEach(k=>{const O=k.value,N=u.nodes[O.obj];O.dating&&(N.dating=O.dating)}),u.links.forEach(k=>{const O=u.nodes[k.source],N=u.nodes[k.target];k.source=fe(O),k.target=fe(N)}),u={nodes:Object.values(u.nodes),links:u.links};const S=u.nodes.map(k=>k.id);a.save_tree(S,u),u=w(s.objectId,u),console.info("render loaded graph"),$(u)})}}s.reload&&ne(()=>{g()});function w(u,m){const j=m.nodes.find(k=>k.type=="root");j&&(j.type="object");const S=m.nodes.find(k=>k.id==u);return S.type="root",m}async function $(u){let m=null;if(u.nodes.length>1){a.graph_empty=!1;const j={object:"#F5F5F5",root:"#C60C30",links:{depiction:"#d37676",copy:"#B0C5A4",precursor:"#F1EF99",duplicate:"#AD88C6",version:"#3077F9"}},S=new Ft({width:s.width,height:s.height});s.graphtype=="network"?m=new Lt(S,j,{width:50,height:50}):m=new zt(S,j),m.clear_canvas(),m.draw_network(u,"div#tree").then(async()=>{await new Promise(O=>setTimeout(O,500)),m.zoom_to_full_extent(),console.info("Graph drawn")},O=>console.log(O))}else console.info("No children can't render tree"),a.graph_empty=!0}function L(u){t.push({name:"Object",params:{objectid:u.detail.node.id},query:{graphtype:s.graphtype}})}return(u,m)=>(l(),_(ze,{class:"py-4 pb-4 pt-1"},{default:o(()=>[i.value?(l(),_(B,{key:0},{default:o(()=>[n(V,null,{default:o(()=>[n(Ne,{indeterminate:"",color:"red-lighten-2"})]),_:1})]),_:1})):h("",!0),n(Y,{class:"pa-0",variant:r.value},{default:o(()=>[b("div",{id:"tree","on:nodeClicked":L},null,32)]),_:1},8,["variant"])]),_:1}))}},Va={__name:"RelationsGraph",props:{objectId:{type:Number,required:!0}},setup(e){const t=R(!0),a=R(!1),s=R(!1),i=R("time"),r=ct();X(()=>r.params.objectid,async d=>{console.log("new id",d)}),X(a,d=>{d==!1&&(s.value=!1)}),ne(()=>{r.query&&r.query.graphtype&&(i.value=r.query.graphtype)}),lt(()=>{r.query&&r.query.graphtype&&(i.value=r.query.graphtype)});function c(){a.value=!a.value}return(d,y)=>(l(),_(ze,null,{default:o(()=>[a.value?h("",!0):(l(),_(Y,{key:0,variant:"outlined"},{default:o(()=>[n(B,null,{default:o(()=>[n(V,{class:"pb-1"},{default:o(()=>[n(C,{icon:"mdi-expand-all-outline",onClick:c}),n(me,{modelValue:i.value,"onUpdate:modelValue":y[0]||(y[0]=v=>i.value=v),variant:"plain",mandatory:""},{default:o(()=>[n(C,{class:"network_btn timeline_icon",icon:"mdi-chart-timeline",value:"time"}),n(C,{class:"network_btn",icon:"mdi-hub-outline",value:"network"})]),_:1},8,["modelValue"])]),_:1})]),_:1}),n(je,{"object-id":e.objectId,reload:t.value,graphtype:i.value,expanded:a.value,width:"100%",height:"550"},null,8,["object-id","reload","graphtype","expanded"])]),_:1})),n(Fe,{modelValue:a.value,"onUpdate:modelValue":y[3]||(y[3]=v=>a.value=v),width:"80%",height:"90%"},{default:o(()=>[n(Y,null,{default:o(()=>[n(B,null,{default:o(()=>[n(V,{class:"pb-1"},{default:o(()=>[n(C,{class:"collapse_icon",icon:"mdi-collapse-all-outline",onClick:y[1]||(y[1]=v=>a.value=!1)}),n(me,{modelValue:i.value,"onUpdate:modelValue":y[2]||(y[2]=v=>i.value=v),variant:"plain",mandatory:""},{default:o(()=>[n(C,{class:"network_btn timeline_icon",icon:"mdi-chart-timeline",value:"time"}),n(C,{class:"network_btn",icon:"mdi-hub-outline",value:"network"})]),_:1},8,["modelValue"])]),_:1})]),_:1}),a.value?(l(),_(je,{key:0,"object-id":e.objectId,graphtype:i.value,reload:t.value,expanded:a.value,width:"100%",height:"70vh"},null,8,["object-id","graphtype","reload","expanded"])):h("",!0)]),_:1})]),_:1},8,["modelValue"])]),_:1}))}},Oa=F(Va,[["__scopeId","data-v-7a1dddf6"]]),Pa={methods:{parse_children_mixin(e){let t=[];if(e&&e.length)for(let a of e)a.has_child?t.push({...a,children:[]}):t.push(a);return t}}},Ta=` BASE <https://db.antiquitatum-thesaurus.eu> PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#> PREFIX crm: <http://www.cidoc-crm.org/cidoc-crm/> PREFIX owl: <http://www.w3.org/2002/07/owl#> PREFIX at: <https://db.antiquitatum-thesaurus.eu/ontology/> `,qa={async get_census_documents(e,t=null){let a=` ${Ta} SELECT ?document ?census_id_content ?ref_label ?instance_name_content ?mid ?path_title WHERE { SERVICE <https://censussparql.culture.hu-berlin.de/CENSUS/query> { VALUES ?instance {<https://semantic.census.de/physicalthing/${e}>} ?instance crm:P2_has_type <http://vocab.getty.edu/aat/300133025> . ?instance crm:P67i_is_referred_to_by ?ref . ?ref crm:P128i_is_carried_by ?document . ?document crm:P2_has_type <http://vocab.getty.edu/aat/300026030> . ?document crm:P1_is_identified_by ?instance_name . ?instance_name crm:P190_has_symbolic_content ?instance_name_content . ?instance_name crm:P2_has_type <http://vocab.getty.edu/aat/300404670> . ?document crm:P1_is_identified_by ?census_id . ?census_id crm:P190_has_symbolic_content ?census_id_content . ?census_id crm:P2_has_type <http://vocab.getty.edu/aat/300435704> . ?document crm:P46i_forms_part_of* ?mid . ?mid crm:P1_is_identified_by ?title_path_iri . ?title_path_iri crm:P2_has_type <http://vocab.getty.edu/aat/300404670> . ?title_path_iri crm:P190_has_symbolic_content ?path_title . } }`;const s=await Bt(a,{signal:t});return Dt(s,{census:[{document:"document",id:"census_id_content",ref_label:"ref_label",name:"instance_name_content",path:{title:"path_title",objectId:"mid"}}]})}},Ba={key:0},Da={class:"external-doc-headline text-primary"},Ea={__name:"ExternalDocuments",props:{sourceKey:{type:String,default:""},sourceName:{type:String,default:""}},setup(e){const t=R([]),a=e;function s(){a.sourceName&&a.sourceKey&&a.sourceName=="Census"&&qa.get_census_documents(a.sourceKey).then(i=>{if(Object.keys(i).length){const r=i.census.reduce((c,d)=>(d.id in c?c[d.id].path.push(d.path):c[d.id]={title:d.name,link:`https://database.census.de/#/detail/${d.id}`,path:[],images:["C"]},c),{});for(const c in r)r[c].path.reverse();t.value=Object.values(r).toSorted((c,d)=>c.path.length==0||!c.path[0].title?1:d.path.length==0||!d.path[0].title?-1:c.path[0].title.localeCompare(d.path[0].title))}})}return ne(()=>{s()}),X(()=>a.sourceKey,i=>{i?s():t.value=[]}),(i,r)=>t.value?(l(),f("div",Ba,[n(ee,{class:"mt-4"}),n(B,{class:"mt-0"},{default:o(()=>[n(V,null,{default:o(()=>[b("span",Da,p(i.$t("label.external_documents"))+":",1)]),_:1})]),_:1}),n(B,null,{default:o(()=>[n(V,null,{default:o(()=>[b("h5",null,p(e.sourceName),1)]),_:1})]),_:1}),n(B,null,{default:o(()=>[(l(!0),f(U,null,Q(t.value,(c,d)=>(l(),_(V,{key:d,class:"d-flex child-flex",cols:"6",md:"6",lg:"4",sm:"4"},{default:o(()=>[n(D(Le),{"object-data":c,"image-height":140,"with-breadcrumbs":""},null,8,["object-data"])]),_:2},1024))),128))]),_:1})])):h("",!0)}},Na=F(Ea,[["__scopeId","data-v-c71b0ed0"]]),Ra={components:{Relations:xa,RelationsGraph:Oa,ExternalDocuments:Na,LoadingSpinner:Gt},mixins:[Pa],inject:["parent_ac"],props:{objectId:{type:Number,default:0},objectTitle:{type:String,default:""},hasChildren:{type:Boolean,default:!1}},data(){return{active_tab:0,loaded_dates:0,sidebar_tabs:{relations:{type:"relations",loading:!0,loading_relations:{},loading_dating:{},count:0},relations_graph:{type:"relations_graph",loading:!0,count:0},children:{type:"children",loading:!0,count:0},artefacts:{type:"artefacts",loading:!0,count:0}},relations:new Map([]),has_relationships:!1,external_reference:[],retrievable_refs:{Census:{key:e=>{let t="";return e.ref_link.indexOf("censusID=")!=-1?t=e.ref_link.substring(e.ref_link.indexOf("censusID=")+9):t=e.ref_link.split("/").slice(-1)[0],t}}},artefacts:[],children:[],depictions:[]}},computed:{...dt(Ge),display_data(){return this.has_relationships||this.hasChildren}},watch:{objectId(){this.reset_data(),this.load_from_ts()},relations(){if(this.relations&&this.relations.length)for(let e of this.relations)e.iris=e.rels.split(","),this.sidebar_tabs.relations.count+=Number(e.rel_cnt),this.sidebar_tabs.relations_graph.count+=Number(e.rel_cnt)}},mounted(){this.$router.query&&this.$router.query.keys().includes("graphtype")&&(this.active_tab=1)},created(){this.reset_data(),this.load_from_ts(),this.graphStore.$subscribe((e,t)=>{t.graph_empty&&this.clear_graph_tab()})},methods:{buildQueryBuilderQuery(e){let a=[{field:{is_depicted_in:"depicts"}[e],iri:[{value:`object/${this.objectId}`,label:this.objectTitle}]}];return JSON.stringify(a)},node_clicked(){this.active_tab=1},check_relation_map(){this.relations.size==0&&delete this.sidebar_tabs.relations},clear_graph_tab(){delete this.sidebar_tabs.relations_graph},is_valid_response(e){return e===null?!1:!(e.id&&e.id!=this.objectId)},read_response(e,t){if(e&&this.is_valid_response(e)&&e.relations&&e.relations.length){this.sidebar_tabs.relations.loading_relations[t]=e.relations.length;const a=ut({loading:!0,loaded:0,from:e.relations.length});this.sidebar_tabs.relations.loading_dating[t]=a,this.relations.set(t,"loading");const s=[];e.relations.forEach(i=>{s.push(x.get_dating_for_object(i.obj).then(r=>(a.loaded++,r)))}),Promise.allSettled(s).then(i=>{const r=i.map(c=>c.value).toSorted((c,d)=>{if(!c.dating&&!d.dating)return 0;if(!c.dating&&d.dating)return 1;if(c.dating&&!d.dating)return-1;{const y=new Date(c.dating.from),v=new Date(d.dating.from);return y-v}}).map(c=>c.obj);this.sidebar_tabs.relations.loading_dating[t]=!1,this.relations.set(t,r),this.sidebar_tabs.relations.count+=r.length})}},load_from_ts(){H.has_relationships(this.objectId,this.parent_ac.signal).then(e=>{e.exists?(this.has_relationships=!0,this.graphStore.graph_empty=!1):(this.has_relationships=!1,delete this.sidebar_tabs.relations_graph)}).then(()=>{const e=[];this.has_relationships?(e.push(x.get_depicts_relations(this.objectId,this.parent_ac.signal).then(t=>{this.read_response(t,"depicts")})),e.push(x.get_depicted_relations(this.objectId,this.parent_ac.signal).then(t=>{this.read_response(t,"is_depicted_in")})),e.push(x.get_duplicate_relations(this.objectId,this.parent_ac.signal).then(t=>{this.read_response(t,"is_duplicate_of")})),e.push(x.get_is_copy_after_relations(this.objectId,this.parent_ac.signal).then(t=>{this.read_response(t,"is_copy_after")})),e.push(x.get_has_copy_relations(this.objectId,this.parent_ac.signal).then(t=>{this.read_response(t,"has_copy")})),e.push(x.get_has_precursor_relations(this.objectId,this.parent_ac.signal).then(t=>{this.read_response(t,"is_based_on")})),e.push(x.get_was_precursor_relations(this.objectId,this.parent_ac.signal).then(t=>{this.read_response(t,"is_precursor_for")})),e.push(x.get_related_to_relations(this.objectId,this.parent_ac.signal).then(t=>{this.read_response(t,"is_related_to")})),e.push(x.get_has_version_relations(this.objectId,this.parent_ac.signal).then(t=>{this.read_response(t,"has_version")})),e.push(x.get_is_version_of_relations(this.objectId,this.parent_ac.signal).then(t=>{this.read_response(t,"is_version_of")})),Promise.allSettled(e).then(()=>{this.sidebar_tabs.relations.loading=!1,this.check_relation_map()})):delete this.sidebar_tabs.relations}),x.get_children(this.objectId,this.parent_ac.signal).then(e=>{if(e&&e.children&&e.children.length&&e.id==this.objectId){let t=this.parse_children_mixin(e.children);this.children=t,this.sidebar_tabs.children.loading=!1,this.sidebar_tabs.children.count=t.length}else delete this.sidebar_tabs.children}),x.get_external_reference(this.objectId,this.$i18n.locale,this.parent_ac.signal).then(e=>{if(e&&Object.keys(e).includes("references")){const t=e.references.filter(s=>s.ref_source in this.retrievable_refs),a=[];for(let s of t){const r=this.retrievable_refs[s.ref_source].key(s);a.push({source:s.ref_source,key:r})}this.external_reference=a}else this.external_reference=[]}),x.get_related_artefacts(this.objectId,this.parent_ac.signal).then(e=>{e&&e.artefacts&&e.artefacts.length&&e.id==this.objectId?(this.artefacts=e.artefacts,this.sidebar_tabs.artefacts.loading=!1,this.sidebar_tabs.artefacts.count=e.artefacts.length):delete this.sidebar_tabs.artefacts})},reset_data(){this.relations=new Map([["depicts",[]],["is_depicted_in",[]],["is_copy_after",[]],["has_copy",[]],["is_based_on",[]],["is_precursor_for",[]],["is_duplicate_of",[]],["is_version_of",[]],["has_version",[]],["is_related_to",[]]]),this.children=[],this.sidebar_tabs={relations:{type:"relations",loading:!0,count:0,loading_relations:{},loading_dating:{}},children:{type:"children",loading:!0,count:0},artefacts:{type:"artefacts",loading:!0,count:0},relations_graph:{type:"relations_graph",loading:!1,count:0}}}}},Aa={key:0},Fa={key:0,class:"pl-1"},La={key:1,class:"pl-1"},za={key:0},Ua={key:0},Ga={key:2},Ma={key:3};function Qa(e,t,a,s,i,r){const c=I("loading-spinner"),d=I("Relations"),y=I("external-documents"),v=I("RelationsGraph");return r.display_data?(l(),f("div",Aa,[n(Mt,{modelValue:i.active_tab,"onUpdate:modelValue":t[0]||(t[0]=g=>i.active_tab=g),"show-arrows":"",class:"text-primary"},{default:o(()=>[(l(!0),f(U,null,Q(i.sidebar_tabs,(g,E,T)=>(l(),_(Kt,{key:T},{default:o(()=>[P(p(e.$t("label."+g.type))+" ",1),g.loading?(l(),f("span",Fa,[n(_t,{width:3,size:20,indeterminate:"",color:"grey-lighten-1"})])):h("",!0),g.count?(l(),f("span",La,"("+p(g.count)+")",1)):h("",!0)]),_:2},1024))),128))]),_:1},8,["modelValue"]),n(Qt,{modelValue:i.active_tab,"onUpdate:modelValue":t[2]||(t[2]=g=>i.active_tab=g)},{default:o(()=>[(l(!0),f(U,null,Q(i.sidebar_tabs,(g,E,T)=>(l(),_(Ht,{key:T,class:"px-1 pt-4",value:`${g.type}`},{default:o(()=>[g.type=="relations"?(l(),f("div",za,[(l(!0),f(U,null,Q(i.relations,([w,$])=>(l(),_(B,{key:w},{default:o(()=>[$.length?(l(),_(V,{key:0,class:"mb-1"},{default:o(()=>[n(B,{align:"center"},{default:o(()=>[n(V,{cols:"11"},{default:o(()=>[b("h5",null,p(e.$t("label."+w)),1)]),_:2},1024),$.length>1&&w=="is_depicted_in"?(l(),_(V,{key:0,cols:"1",class:"ma-0 pa-0"},{default:o(()=>[n(C,{style:{"text-decoration":"none"},density:"compact",icon:"mdi-text-search-variant",to:{name:"Search",query:{q:r.buildQueryBuilderQuery(w)}}},null,8,["to"]),e.$vuetify.display.sm||e.$vuetify.display.xs?h("",!0):(l(),_(G,{key:0,location:"bottom","open-delay":"500",activator:"parent"},{default:o(()=>[b("span",null,p(e.$t("user_info.open_as_search_result")),1)]),_:1}))]),_:2},1024)):h("",!0)]),_:2},1024),n(B,null,{default:o(()=>[$=="loading"?(l(),_(V,{key:0,class:"ma-0 pa-0"},{default:o(()=>[n(c)]),_:1})):$.length?(l(),_(V,{key:1},{default:o(()=>[n(d,{data:$},null,8,["data"])]),_:2},1024)):h("",!0)]),_:2},1024)]),_:2},1024)):h("",!0)]),_:2},1024))),128)),i.external_reference?(l(),f("span",Ua,[(l(!0),f(U,null,Q(i.external_reference,(w,$)=>(l(),_(B,{key:`${w.source}-${$}`},{default:o(()=>[n(V,{class:"mb-1"},{default:o(()=>[n(y,{"source-key":w.key,"source-name":w.source},null,8,["source-key","source-name"])]),_:2},1024)]),_:2},1024))),128))])):h("",!0)])):g.type=="relations_graph"?(l(),f("div",{key:1,"on:nodeClicked":t[1]||(t[1]=(...w)=>r.node_clicked&&r.node_clicked(...w))},[n(B,null,{default:o(()=>[n(V,{class:"mb-1"},{default:o(()=>[n(v,{"object-id":a.objectId},null,8,["object-id"])]),_:1})]),_:1})],32)):g.type=="artefacts"?(l(),f("div",Ga,[n(V,{class:"mb-1"},{default:o(()=>[n(d,{data:i.artefacts},null,8,["data"])]),_:1})])):g.type=="children"?(l(),f("div",Ma,[n(d,{data:i.children,tree:""},null,8,["data"])])):h("",!0)]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue"])])):h("",!0)}const Ka=F(Ra,[["render",Qa],["__scopeId","data-v-7518c5d7"]]),Ha=ht("v-alert-title"),Wa=["success","info","warning","error"],Xa=we({border:{type:[Boolean,String],validator:e=>typeof e=="boolean"||["top","end","bottom","start"].includes(e)},borderColor:String,closable:Boolean,closeIcon:{type:pt,default:"$close"},closeLabel:{type:String,default:"$vuetify.close"},icon:{type:[Boolean,String,Function,Object],default:null},modelValue:{type:Boolean,default:!0},prominent:Boolean,title:String,text:String,type:{type:String,validator:e=>Wa.includes(e)},...ft(),...mt(),...bt(),...yt(),...xe(),...$e(),...Se(),...gt(),...Ie(),...Ce({variant:"flat"})},"VAlert"),Ya=Ve()({name:"VAlert",props:Xa(),emits:{"click:close":e=>!0,"update:modelValue":e=>!0},setup(e,t){let{emit:a,slots:s}=t;const i=Oe(e,"modelValue"),r=K(()=>{if(e.icon!==!1)return e.type?e.icon??`$${e.type}`:e.icon}),c=K(()=>({color:e.color??e.type,variant:e.variant})),{themeClasses:d}=Te(e),{colorClasses:y,colorStyles:v,variantClasses:g}=qe(c),{densityClasses:E}=vt(e),{dimensionStyles:T}=kt(e),{elevationClasses:w}=jt(e),{locationStyles:$}=wt(e),{positionClasses:L}=Pe(e),{roundedClasses:u}=Be(e),{textColorClasses:m,textColorStyles:j}=xt($t(e,"borderColor")),{t:S}=St(),k=K(()=>({"aria-label":S(e.closeLabel),onClick(O){i.value=!1,a("click:close",O)}}));return()=>{const O=!!(s.prepend||r.value),N=!!(s.title||e.title),J=!!(s.close||e.closable);return i.value&&n(e.tag,{class:["v-alert",e.border&&{"v-alert--border":!!e.border,[`v-alert--border-${e.border===!0?"start":e.border}`]:!0},{"v-alert--prominent":e.prominent},d.value,y.value,E.value,w.value,L.value,u.value,g.value,e.class],style:[v.value,T.value,$.value,e.style],role:"alert"},{default:()=>{var z,te;return[Ee(!1,"v-alert"),e.border&&n("div",{key:"border",class:["v-alert__border",m.value],style:j.value},null),O&&n("div",{key:"prepend",class:"v-alert__prepend"},[s.prepend?n(le,{key:"prepend-defaults",disabled:!r.value,defaults:{VIcon:{density:e.density,icon:r.value,size:e.prominent?44:28}}},s.prepend):n(re,{key:"prepend-icon",density:e.density,icon:r.value,size:e.prominent?44:28},null)]),n("div",{class:"v-alert__content"},[N&&n(Ha,{key:"title"},{default:()=>{var M;return[((M=s.title)==null?void 0:M.call(s))??e.title]}}),((z=s.text)==null?void 0:z.call(s))??e.text,(te=s.default)==null?void 0:te.call(s)]),s.append&&n("div",{key:"append",class:"v-alert__append"},[s.append()]),J&&n("div",{key:"close",class:"v-alert__close"},[s.close?n(le,{key:"close-defaults",defaults:{VBtn:{icon:e.closeIcon,size:"x-small",variant:"text"}}},{default:()=>{var M;return[(M=s.close)==null?void 0:M.call(s,{props:k.value})]}}):n(C,A({key:"close-btn",icon:e.closeIcon,size:"x-small",variant:"text"},k.value),null)])]}})}}}),Ja={name:"ErrorResponse",props:{type:{type:String,default:""},error:{type:Error,default:null}},computed:{error_message:function(){let e="";return this.error&&(this.error.response?e="error.not_found":this.error.request?e="error.network_error":this.error.message?e="error."+this.error.message:e="error.unknown"),e},error_color:function(){let e="error";return this.error&&this.error.response&&(e="accent"),e}}},Za={key:0};function es(e,t,a,s,i,r){return a.type?(l(),f("span",Za,[a.type==="symbole"?(l(),f(U,{key:0},[n(re,{size:"large",color:r.error_color},{default:o(()=>t[0]||(t[0]=[P("mdi-alert-circle-outline")])),_:1},8,["color"]),P(" Â "+p(e.$t(r.error_message)),1)],64)):a.type==="bar"?(l(),_(Ya,{key:1,density:"compact",variant:"outlined",type:"error"},{default:o(()=>[P(" Â "+p(e.$t(r.error_message)),1)]),_:1})):h("",!0)])):h("",!0)}const ts=F(Ja,[["render",es]]),as={name:"ObjectDetail",components:{MainContainer:Ct,ThreeColumnLayout:Vt,ImageSection:Pt,PermaLink:ra,Sidebar:Ka,ObjectComparisonButtons:ca,DetailPaginator:pa,ErrorResponse:ts,BackToSearchButton:oa,ObjectDetailTS:Tt,ObjectTitle:Ot},provide(){return{parent_ac:K(()=>this.ac)}},data(){return{loading:!0,objectId:null,object_path:[],title:"",has_children:!1,errors:[],trip_data:[],cataloging:[],ac:null,exists:2}},computed:{mailto_link:function(){return"mailto:thesaurus@bbaw.de?subject=Feedback zu Objekt: "+this.objectId}},watch:{objectId(e,t){t&&e!=t&&(this.ac.abort(),this.ac=new AbortController,this.object_path=[],this.title="",this.has_children=!1,this.cataloging=[],this.load_from_ts())}},updated(){this.objectId=Number(this.$route.params.objectid)},created(){this.ac=new AbortController,this.objectId=Number(this.$route.params.objectid),this.load_from_ts()},mounted(){Wt({title:()=>`${this.title} - Antiquitatum Thesaurus`,meta:[{property:"og:title",content:()=>`${this.title} - Antiquitatum Thesaurus`}]})},methods:{onShowError:function(e){this.errors.push(new Error(e))},load_data(){x.get_preferred_title(this.objectId,"de",this.ac.signal).then(e=>{e&&(this.title=e)}),x.get_parents_path(this.objectId,this.ac.signal).then(e=>{e&&e.path&&e.id==this.objectId&&(this.object_path=e.path)}),x.has_children(this.objectId,this.ac.signal).then(e=>{e&&e.children&&e.id==this.objectId&&(this.has_children=e.children)})},load_from_ts(){x.object_exists(this.objectId).then(e=>{this.exists=e.exists,this.exists&&this.load_data()})}}},ss={key:0},ns={key:0},rs={class:"sticky t-100"},is={key:0,class:"text-center"},os={class:"pa-2",align:"right"},ls=["href"],cs={key:1};function ds(e,t,a,s,i,r){const c=I("ErrorResponse"),d=I("BackToSearchButton"),y=I("DetailPaginator"),v=I("PermaLink"),g=I("ObjectTitle"),E=I("ImageSection"),T=I("ObjectComparisonButtons"),w=I("ObjectDetailTS"),$=I("Sidebar"),L=I("ThreeColumnLayout"),u=I("MainContainer");return l(),_(u,null,{default:o(()=>[i.exists===!0?(l(),f("div",ss,[i.errors.length?(l(),_(B,{key:0,onShow_error:r.onShowError},{default:o(()=>[(l(!0),f(U,null,Q(i.errors,(m,j)=>(l(),_(c,{key:j,type:"bar",error:m},null,8,["error"]))),128))]),_:1},8,["onShow_error"])):h("",!0),n(B,{class:"ma-0 pa-0",align:"center",justify:"center",style:{"min-height":"40px"}},{default:o(()=>[n(V,{class:be(["ma-0 pa-0",{"text-center":e.$vuetify.display.sm||e.$vuetify.display.xs}]),cols:"12",md:"5"},{default:o(()=>[e.$route.query.mode=="objects"|!e.$route.query.mode?(l(),_(d,{key:0})):h("",!0)]),_:1},8,["class"]),n(V,{class:"ma-0 pa-0 text-center",cols:"12",md:"2"},{default:o(()=>[e.$route.query.mode=="objects"?(l(),_(y,{key:0})):(l(),_(_e,{key:1,style:{height:"36px"}}))]),_:1}),e.$vuetify.display.xs?h("",!0):(l(),_(V,{key:0,class:be(["ma-0 pa-0",{"text-center":e.$vuetify.display.sm||e.$vuetify.display.xs,"text-right":!(e.$vuetify.display.sm||e.$vuetify.display.xs)}]),cols:"12","align-self":"end",md:"5"},{default:o(()=>[n(v,{id:i.objectId.toString(),path:"object"},null,8,["id"])]),_:1},8,["class"]))]),_:1}),n(ee),n(L,null,{"col-1":o(()=>[e.$vuetify.display.xs?(l(),f("div",ns,[n(g,{title:i.title,"object-path":i.object_path,"has-children":i.has_children},null,8,["title","object-path","has-children"]),n(ee,{class:"mt-4"})])):h("",!0),b("div",rs,[n(E,{"object-id":i.objectId,max_width:430},null,8,["object-id"]),e.$vuetify.display.xs||e.$vuetify.display.sm?h("",!0):(l(),_(T,{key:0}))])]),"col-2":o(()=>[n(It,{class:"px-2 pb-2"},{default:o(()=>[e.$vuetify.display.xs?h("",!0):(l(),_(g,{key:0,title:i.title,"object-path":i.object_path,"has-children":i.has_children},null,8,["title","object-path","has-children"])),n(w,{"object-id":i.objectId},null,8,["object-id"])]),_:1}),n(ee),e.$vuetify.display.xs?(l(),f("div",is,[n(v,{id:i.objectId.toString(),path:"object"},null,8,["id"])])):h("",!0),b("div",os,[b("a",{class:"text-caption feedback",href:r.mailto_link},"Feedback",8,ls)])]),"col-3":o(()=>[n($,{style:{"margin-top":"3.5px"},"object-id":i.objectId,"object-title":i.title,"has-children":i.has_children},null,8,["object-id","object-title","has-children"])]),_:1})])):i.exists===!1?(l(),f("div",cs,[n(Y,{variant:"outlined",rounded:"0","max-width":"500",class:"mx-auto my-10"},{default:o(()=>[n(de,null,{default:o(()=>[P(p(e.$t("error.object_not_found")),1)]),_:1}),n(Re,null,{default:o(()=>[P(p(e.$t("error.wrong_object_id")),1)]),_:1}),n(ue,null,{default:o(()=>[n(C,{variant:"text",color:"#C60C30",to:{name:"Search"}},{default:o(()=>t[0]||(t[0]=[P("Suche")])),_:1})]),_:1})]),_:1})])):h("",!0)]),_:1})}const Ts=F(as,[["render",ds],["__scopeId","data-v-baff3d76"]]);export{Ts as default};