@micrio/client 5.3.1 → 5.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/micrio.min.js CHANGED
@@ -1,5 +1,5 @@
1
- /* Micrio Client 5.3.1
2
- * Copyright © 2015 - 2025 Q42 Internet B.V., Micrio <https://micr.io>
1
+ /* Micrio Client 5.3.2
2
+ * Copyright (C) 2015 - 2025 Q42 Internet B.V., Micrio <https://micr.io>
3
3
  *
4
4
  * Permission is hereby granted, free of charge, to any person obtaining a copy of this software
5
5
  * and associated documentation files (the "Software"), to deal in the Software without
@@ -18,9 +18,9 @@
18
18
  */
19
19
 
20
20
  ((M,I,C,R='O')=>{
21
- if(!(typeof window !== undefined && typeof window !== 'undefined')) return;M='H4sIAAAAAAACCt19a4AdRZloVXX3#X2mzsypSWZgyASp08nqkSQyCsZJeMzpYRImEiFAx#ByyQyZCZnJa5KZQNAJMwpiVnFFXF3Iop5HIqys1+ALloCEVVdQvLK+1rs+LurqinB3s153F1eXXL$vq+6uPmcCYff+uhM43VX1VXU9v$rqexUbntz#GWP86244xGfYkJiZYUN8hs8MiZlpfJsecmZmKIXPDHkz09PTkDDNp4cYnxlyZzAsZiAig6kzDLNAGdMQ685gAc4MpQB4lgBN2BQTlY9ZFUJAwLzwmaEW80ohmYQgiN$GWuRmTE6sIxvyZqgCPj6j+u3D32k2lJkxbXJm9s0wqgmLioNc+EIFmBox8w0q1zVdch#fgX6ZoQbzmeiD+F6gT9vNETP7+MxQdmYf$lGX85mhjgi#YLEMKKFzrvi4z6IuSLoz7pRpqovpTzMsMzC2+3BU92FH0APG2ww#9J7Jhe+FqL$pw81R0zhZ4BPT4p95mz#643pv+Nqdu6dYwd0+PLajZXJ06sqxybFrt40yjjHZ4R1jAzt3jDKGQX94x1iIGSgsrx8bvWFi5+6pK0anWJaikjJeZwppmxydWj+2bfTSieFNY1M3spUWIGVnr8Ko3#To1JuGp3aP7Y2+N7J7+IbL9gyPsFdTS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q8k0sfLjt5QzMdpxGw01d+rs5Sll6EqXAUI9FpYUPF+S6tQ2lnHMSpWxlYzgZASFsaqrbbap5iS04wWKJ84YPq5#dJGNs#xtGpNM8SX6n0ksMvuub0hKou9vnRgJhXC$NxhhcpDHKtrMJNsVuh#Xbni6725Qt0su3AWqhgXLSKG7e3GW56UV8AigvBfXkCaAy6XqdACqbrtf8uaH8dL3mnwwie$KkoJ47Kajb#k5qS+iYG003zyFCpDtx#0qjvf8Lh39cpBLJAAA=',I=window.DecompressionStream,C=(b,t,d,a)=>(a=atob(b.replace(/\$/g,'/').replace(/#/g,'O')).split('').map(x=>x.charCodeAt(0)),d=I?new Response(new Blob([new Uint8Array(a)]).stream().pipeThrough(new I('gzip'))):(new Zlib.Gunzip(a)).decompress())&&(I?t?d.arrayBuffer():d.text():t?d:new self.TextDecoder('utf-8').decode(d));(I?new Promise(a=>a()):fetch('https://r2.micr.io/gunzip.min.js').then(r=>r.text()).then(js=>Function(js)())).then(()=>(function(){const [_c,_u,_b]=arguments,_css=document.createElement('style');
21
+ if(!(typeof window !== undefined && typeof window !== 'undefined')) return;M='H4sIAAAAAAACA919a4AdRZloVXX3#X2mzsypSWZgyASp08nqkSQyCsZJeMzpYRImEiFAx#ByyQyZCZnJa5KZQNAJMwpiVnFFXF3Iop5HIqys1+ALloCEVVdQvLK+1rs+LurqinB3s153F1eXXL$vq+6uPmcCYff+uhM43VX1VXU9v$rqexUbntz#GWP86244xGfYkJiZYUN8hs8MiZlpfJsecmZmKIXPDHkz09PTkDDNp4cYnxlyZzAsZiAig6kzDLNAGdMQ685gAc4MpQB4lgBN2BQTlY9ZFUJAwLzwmaEW80ohmYQgiN$GWuRmTE6sIxvyZqgCPj6j+u3D32k2lJkxbXJm9s0wqgmLioNc+EIFmBox8w0q1zVdch#fgX6ZoQbzmeiD+F6gT9vNETP7+MxQdmYf$lGX85mhjgi#YLEMKKFzrvi4z6IuSLoz7pRpqovpTzMsMzC2+3BU92FH0APG2ww#9J7Jhe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ivCmjZ9978Zb7v71iituPv6nz59xbuk3j7y3$ax$Ktzp$egbNy3ffsb2lrdu7lt96Q#5r73qKw+9as+yX2786L+tyJ7$9n$+2bP3b$zt1l$ecfl7Vvc4V$r$7X1n6Ie$cey+rW$$3fAHfvrnpy$$9YGN77pr1#$++TWz3zv+vvKWSsdb#j#Z175q8k0sfLjt5QzMdpxGw01d+rs5Sll6EqXAUI9FpYUPF+S6tQ2lnHMSpWxlYzgZASFsaqrbbap5iS04wWKJ84YPq5#dJGNs#xtGpNM8SX6n0ksMvuub0hKou9vnRgJhXC$NxhhcpDHKtrMJNsVuh#Xbni6725Qt0su3AWqhgXLSKG7e3GW56UV8AigvBfXkCaAy6XqdACqbrtf8uaH8dL3mnwwie$KkoJ47Kajb#k5qS+iYG003zyFCpDtx#0qjvf8Lh39cpBLJAAA=',I=window.DecompressionStream,C=(b,t,d,a)=>(a=atob(b.replace(/\$/g,'/').replace(/#/g,'O')).split('').map(x=>x.charCodeAt(0)),d=I?new Response(new Blob([new Uint8Array(a)]).stream().pipeThrough(new I('gzip'))):(new Zlib.Gunzip(a)).decompress())&&(I?t?d.arrayBuffer():d.text():t?d:new self.TextDecoder('utf-8').decode(d));(I?new Promise(a=>a()):fetch('https://r2.micr.io/gunzip.min.js').then(r=>r.text()).then(js=>Function(js)())).then(()=>(function(){const [_c,_u,_b]=arguments,_css=document.createElement('style');
22
22
  _css.className='micrio-interface';_css.textContent=_c;
23
23
  document.head.insertBefore(_css,document.head.firstChild);
24
- !function(){"use strict";var t;"undefined"!=typeof window&&((t=window.__svelte??(window.__svelte={})).v??(t.v=new Set)).add("5");const e=Symbol(),i=!1,r=32,n=64,s=128,o=256,a=512,l=1024,c=2048,u=4096,d=8192,h=16384,m=65536,v=1<<20,p=1<<21,f=Symbol("$state"),g=Symbol("legacy props"),w=Symbol("");var b=Array.isArray,y=Array.prototype.indexOf,k=Array.from,T=Object.defineProperty,_=Object.getOwnPropertyDescriptor,x=Object.getOwnPropertyDescriptors,E=Object.prototype,$=Array.prototype,A=Object.getPrototypeOf,S=Object.isExtensible;function I(t){return"function"==typeof t}const M=()=>{};function L(t){return t()}function P(t){for(var e=0;e<t.length;e++)t[e]()}let C=[],D=[];function R(){var t=C;C=[],P(t)}function z(t){0===C.length&&queueMicrotask(R),C.push(t)}function O(){var t;C.length>0&&R(),D.length>0&&(t=D,D=[],P(t))}function N(t){return t===this.v}function F(t,e){return t!=t?e==e:t!==e||null!==t&&"object"==typeof t||"function"==typeof t}function V(t){return!F(t,this.v)}let U=!1;function B(t,i){if("object"!=typeof t||null===t||f in t)return t;const r=A(t);if(r!==E&&r!==$)return t;var n=new Map,s=b(t),o=j(0),a=bt,l=t=>{var e,i=bt;return kt(a),e=t(),kt(i),e};return s&&n.set("length",j(t.length)),new Proxy(t,{defineProperty(t,e,i){"value"in i&&!1!==i.configurable&&!1!==i.enumerable&&!1!==i.writable||function(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}();var r=n.get(e);return void 0===r?(r=l((()=>j(i.value))),n.set(e,r)):Y(r,l((()=>B(i.value)))),!0},deleteProperty(t,i){var r=n.get(i);if(void 0===r)i in t&&n.set(i,l((()=>j(e))));else{if(s&&"string"==typeof i){var a=n.get("length"),c=Number(i);Number.isInteger(c)&&c<a.v&&Y(a,c)}Y(r,e),q(o)}return!0},get(i,r,s){var o;if(r===f)return t;var a=n.get(r),c=r in i;if(void 0!==a||c&&!(null==(o=_(i,r))?void 0:o.writable)||(a=l((()=>j(B(c?i[r]:e)))),n.set(r,a)),void 0!==a){var u=jt(a);return u===e?void 0:u}return Reflect.get(i,r,s)},getOwnPropertyDescriptor(t,i){var r=Reflect.getOwnPropertyDescriptor(t,i);if(r&&"value"in r){var s=n.get(i);s&&(r.value=jt(s))}else if(void 0===r){var o=n.get(i),a=null==o?void 0:o.v;if(void 0!==o&&a!==e)return{enumerable:!0,configurable:!0,value:a,writable:!0}}return r},has(t,i){var r;if(i===f)return!0;var s=n.get(i),o=void 0!==s&&s.v!==e||Reflect.has(t,i);if((void 0!==s||null!==Tt&&(!o||(null==(r=_(t,i))?void 0:r.writable)))&&(void 0===s&&(s=l((()=>j(o?B(t[i]):e))),n.set(i,s)),jt(s)===e))return!1;return o},set(t,i,r,a){var c,u=n.get(i),d=i in t;if(s&&"length"===i)for(var h=r;h<u.v;h+=1){var m=n.get(h+"");void 0!==m?Y(m,e):h in t&&(m=l((()=>j(e))),n.set(h+"",m))}void 0===u?d&&!(null==(c=_(t,i))?void 0:c.writable)||(Y(u=l((()=>j(void 0))),l((()=>B(r)))),n.set(i,u)):(d=u.v!==e,Y(u,l((()=>B(r)))));var v=Reflect.getOwnPropertyDescriptor(t,i);if((null==v?void 0:v.set)&&v.set.call(a,r),!d){if(s&&"string"==typeof i){var p=n.get("length"),f=Number(i);Number.isInteger(f)&&f>=p.v&&Y(p,f+1)}q(o)}return!0},ownKeys(t){jt(o);var i=Reflect.ownKeys(t).filter((t=>{var i=n.get(t);return void 0===i||i.v!==e}));for(var[r,s]of n)s.v===e||r in t||i.push(r);return i},setPrototypeOf(){!function(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}()}})}function q(t,e=1){Y(t,t.v+e)}const W=new Map;function X(t,e){return{f:0,v:t,reactions:null,equals:N,rv:0,wv:0}}function j(t,e){const i=X(t);return Et(i),i}function G(t,e=!1){var i;const r=X(t);return e||(r.equals=V),U&&null!==we&&null!==we.l&&((i=we.l).s??(i.s=[])).push(r),r}function Y(t,e,i=!1){return null!==bt&&!yt&&xe()&&18&bt.f&&!(null==xt?void 0:xt.includes(t))&&function(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}(),H(t,i?B(e):e)}function H(t,e){if(!t.equals(e)){var i=t.v;ft?W.set(t,e):W.set(t,i),t.v=e,t.wv=Pt(),Z(t,c),xe()&&null!==Tt&&Tt.f&l&&!(96&Tt.f)&&(null===St?function(t){St=t}([t]):St.push(t))}return e}function Z(t,e){var i=t.reactions;if(null!==i)for(var r=xe(),n=i.length,s=0;s<n;s++){var o=i[s],a=o.f;a&c||(r||o!==Tt)&&(Ht(o,e),1280&a&&(2&a?Z(o,u):qt(o)))}}function K(t){var e=2050,i=null!==bt&&2&bt.f?bt:null;null===Tt||null!==i&&i.f&o?e|=o:Tt.f|=v;return{ctx:we,deps:null,effects:null,equals:N,f:e,fn:t,reactions:null,rv:0,v:null,wv:0,parent:i??Tt}}function J(t){const e=K(t);return Et(e),e}function Q(t){const e=K(t);return e.equals=V,e}function tt(t){var e=t.effects;if(null!==e){t.effects=null;for(var i=0;i<e.length;i+=1)ue(e[i])}}function et(t){var e=function(t){var e,i=Tt;_t(function(t){for(var e=t.parent;null!==e;){if(!(2&e.f))return e;e=e.parent}return null}(t));try{tt(t),e=zt(t)}finally{_t(i)}return e}(t);Ht(t,(Lt||t.f&o)&&null!==t.deps?u:l),t.equals(e)||(t.v=e,t.wv=Pt())}var it,rt,nt,st;function ot(t=""){return document.createTextNode(t)}function at(t){return nt.call(t)}function lt(t){return st.call(t)}function ct(t,e){return at(t)}function ut(t,e){var i=at(t);return i instanceof Comment&&""===i.data?lt(i):i}function dt(t,e=1,i=!1){let r=t;for(;e--;)r=lt(r);return r}let ht=!1,mt=!1,vt=null,pt=!1,ft=!1;function gt(t){ft=t}let wt=[],bt=null,yt=!1;function kt(t){bt=t}let Tt=null;function _t(t){Tt=t}let xt=null;function Et(t){null!==bt&&bt.f&p&&(null===xt?xt=[t]:xt.push(t))}let $t=null,At=0,St=null;let It=1,Mt=0,Lt=!1;function Pt(){return++It}function Ct(t){var e,i=t.f;if(i&c)return!0;if(i&u){var r=t.deps,n=!!(i&o);if(null!==r){var s,d,h=!!(i&a),m=n&&null!==Tt&&!Lt,v=r.length;if(h||m){var p=t,f=p.parent;for(s=0;s<v;s++)d=r[s],!h&&(null==(e=null==d?void 0:d.reactions)?void 0:e.includes(p))||(d.reactions??(d.reactions=[])).push(p);h&&(p.f^=a),!m||null===f||f.f&o||(p.f^=o)}for(s=0;s<v;s++)if(Ct(d=r[s])&&et(d),d.wv>t.wv)return!0}n&&(null===Tt||Lt)||Ht(t,l)}return!1}function Dt(t,e,i,r){if(ht){if(null===i&&(ht=!1),function(t){return!(t.f&h||null!==t.parent&&t.parent.f&s)}(e))throw t}else null!==i&&(ht=!0),function(t,e){for(var i=e;null!==i;){if(i.f&s)try{return void i.fn(t)}catch{i.f^=s}i=i.parent}throw ht=!1,t}(t,e)}function Rt(t,e,i=!0){var r=t.reactions;if(null!==r)for(var n=0;n<r.length;n++){var s=r[n];(null==xt?void 0:xt.includes(t))||(2&s.f?Rt(s,e,!1):e===s&&(i?Ht(s,c):s.f&l&&Ht(s,u),qt(s)))}}function zt(t){var e,i=$t,r=At,n=St,s=bt,a=Lt,l=xt,c=we,u=yt,d=t.f;$t=null,At=0,St=null,Lt=!!(d&o)&&(yt||!pt||null===bt),bt=96&d?null:t,xt=null,be(t.ctx),yt=!1,Mt++,t.f|=p;try{var h=(0,t.fn)(),m=t.deps;if(null!==$t){var v;if(Nt(t,At),null!==m&&At>0)for(m.length=At+$t.length,v=0;v<$t.length;v++)m[At+v]=$t[v];else t.deps=m=$t;if(!Lt)for(v=At;v<m.length;v++)((e=m[v]).reactions??(e.reactions=[])).push(t)}else null!==m&&At<m.length&&(Nt(t,At),m.length=At);if(xe()&&null!==St&&!yt&&null!==m&&!(6146&t.f))for(v=0;v<St.length;v++)Rt(St[v],t);return null!==s&&(Mt++,null!==St&&(null===n?n=St:n.push(...St))),h}finally{$t=i,At=r,St=n,bt=s,Lt=a,xt=l,be(c),yt=u,t.f^=p}}function Ot(t,e){let i=e.reactions;if(null!==i){var r=y.call(i,t);if(-1!==r){var n=i.length-1;0===n?i=e.reactions=null:(i[r]=i[n],i.pop())}}null===i&&2&e.f&&(null===$t||!$t.includes(e))&&(Ht(e,u),768&e.f||(e.f^=a),tt(e),Nt(e,0))}function Nt(t,e){var i=t.deps;if(null!==i)for(var r=e;r<i.length;r++)Ot(t,i[r])}function Ft(t){var e=t.f;if(!(e&h)){Ht(t,l);var n=Tt,s=we,o=pt;Tt=t,pt=!0;try{16&e?function(t){var e=t.first;for(;null!==e;){var i=e.next;e.f&r||ue(e),e=i}}(t):ce(t),le(t);var a=zt(t);t.teardown="function"==typeof a?a:null,t.wv=It;t.deps;i}catch(c){Dt(c,t,n,s||t.ctx)}finally{pt=o,Tt=n}}}function Vt(){try{!function(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}()}catch(t){if(null===vt)throw t;Dt(t,vt,null)}}function Ut(){var t=pt;try{var e=0;for(pt=!0;wt.length>0;){e++>1e3&&Vt();var i=wt,r=i.length;wt=[];for(var n=0;n<r;n++){Bt(Wt(i[n]))}}}finally{mt=!1,pt=t,vt=null,W.clear()}}function Bt(t){var e=t.length;if(0!==e)for(var i=0;i<e;i++){var r=t[i];if(!(24576&r.f))try{Ct(r)&&(Ft(r),null===r.deps&&null===r.first&&null===r.nodes_start&&(null===r.teardown?de(r):r.fn=null))}catch(n){Dt(n,r,null,r.ctx)}}}function qt(t){mt||(mt=!0,queueMicrotask(Ut));for(var e=vt=t;null!==e.parent;){var i=(e=e.parent).f;if(96&i){if(!(i&l))return;e.f^=l}}wt.push(e)}function Wt(t){for(var e=[],i=t;null!==i;){var r=i.f,n=!!(96&r);if(!(n&&!!(r&l)||r&d)){if(4&r)e.push(i);else if(n)i.f^=l;else{var s=bt;try{bt=i,Ct(i)&&Ft(i)}catch(c){Dt(c,i,null,i.ctx)}finally{bt=s}}var o=i.first;if(null!==o){i=o;continue}}var a=i.parent;for(i=i.next;null===i&&null!==a;)i=a.next,a=a.parent}return e}async function Xt(){await Promise.resolve(),function(){for(O();wt.length>0;)mt=!0,Ut(),O()}()}function jt(t){var e=!!(2&t.f);if(null===bt||yt){if(e&&null===t.deps&&null===t.effects){var i=t,r=i.parent;null===r||r.f&o||(i.f^=o)}}else if(!(null==xt?void 0:xt.includes(t))){var n=bt.deps;t.rv<Mt&&(t.rv=Mt,null===$t&&null!==n&&n[At]===t?At++:null===$t?$t=[t]:Lt&&$t.includes(t)||$t.push(t))}return e&&Ct(i=t)&&et(i),ft&&W.has(t)?W.get(t):t.v}function Gt(t){var e=yt;try{return yt=!0,t()}finally{yt=e}}const Yt=-7169;function Ht(t,e){t.f=t.f&Yt|e}function Zt(t){if("object"==typeof t&&t&&!(t instanceof EventTarget))if(f in t)Kt(t);else if(!Array.isArray(t))for(let e in t){const i=t[e];"object"==typeof i&&i&&f in i&&Kt(i)}}function Kt(t,e=new Set){if(!("object"!=typeof t||null===t||t instanceof EventTarget||e.has(t))){e.add(t),t instanceof Date&&t.getTime();for(let n in t)try{Kt(t[n],e)}catch(i){}const r=A(t);if(r!==Object.prototype&&r!==Array.prototype&&r!==Map.prototype&&r!==Set.prototype&&r!==Date.prototype){const e=x(r);for(let r in e){const n=e[r].get;if(n)try{n.call(t)}catch(i){}}}}}function Jt(t){null===Tt&&null===bt&&function(){throw new Error("https://svelte.dev/e/effect_orphan")}(),null!==bt&&bt.f&o&&null===Tt&&function(){throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}(),ft&&function(){throw new Error("https://svelte.dev/e/effect_in_teardown")}()}function Qt(t,e,i,r=!0){var n=Tt,s={ctx:we,deps:null,nodes_start:null,nodes_end:null,f:t|c,first:null,fn:e,last:null,next:null,parent:n,prev:null,teardown:null,transitions:null,wv:0};if(i)try{Ft(s),s.f|=32768}catch(a){throw ue(s),a}else null!==e&&qt(s);if(!(i&&null===s.deps&&null===s.first&&null===s.nodes_start&&null===s.teardown&&!(1048704&s.f))&&r&&(null!==n&&function(t,e){var i=e.last;null===i?e.last=e.first=t:(i.next=t,t.prev=i,e.last=t)}(s,n),null!==bt&&2&bt.f)){var o=bt;(o.effects??(o.effects=[])).push(s)}return s}function te(t){const e=Qt(8,null,!1);return Ht(e,l),e.teardown=t,e}function ee(t){if(Jt(),!(null!==Tt&&!!(Tt.f&r)&&null!==we&&!we.m))return ie(t);var e=we;(e.e??(e.e=[])).push({fn:t,effect:Tt,reaction:bt})}function ie(t){return Qt(4,t,!1)}function re(t,e){var i=we,r={effect:null,ran:!1};i.l.r1.push(r),r.effect=ne((()=>{t(),r.ran||(r.ran=!0,Y(i.l.r2,!0),Gt(e))}))}function ne(t){return Qt(8,t,!0)}function se(t,e=[],i=K){const r=e.map(i);return oe((()=>t(...r.map(jt))))}function oe(t,e=0){return Qt(24|e,t,!0)}function ae(t,e=!0){return Qt(40,t,!0,e)}function le(t){var e=t.teardown;if(null!==e){const t=ft,i=bt;gt(!0),kt(null);try{e.call(null)}finally{gt(t),kt(i)}}}function ce(t,e=!1){var i=t.first;for(t.first=t.last=null;null!==i;){var r=i.next;i.f&n?i.parent=null:ue(i,e),i=r}}function ue(t,e=!0){var i=!1;if((e||524288&t.f)&&null!==t.nodes_start){for(var r=t.nodes_start,n=t.nodes_end;null!==r;){var s=r===n?null:lt(r);r.remove(),r=s}i=!0}ce(t,e&&!i),Nt(t,0),Ht(t,h);var o=t.transitions;if(null!==o)for(const l of o)l.stop();le(t);var a=t.parent;null!==a&&null!==a.first&&de(t),t.next=t.prev=t.teardown=t.ctx=t.deps=t.fn=t.nodes_start=t.nodes_end=null}function de(t){var e=t.parent,i=t.prev,r=t.next;null!==i&&(i.next=r),null!==r&&(r.prev=i),null!==e&&(e.first===t&&(e.first=r),e.last===t&&(e.last=i))}function he(t,e){var i=[];ve(t,i,!0),me(i,(()=>{ue(t),e&&e()}))}function me(t,e){var i=t.length;if(i>0){var r=()=>--i||e();for(var n of t)n.out(r)}else e()}function ve(t,e,i){if(!(t.f&d)){if(t.f^=d,null!==t.transitions)for(const r of t.transitions)(r.is_global||i)&&e.push(r);for(var n=t.first;null!==n;){var s=n.next;ve(n,e,!!(!!(n.f&m)||!!(n.f&r))&&i),n=s}}}function pe(t){fe(t,!0)}function fe(t,e){if(t.f&d){t.f^=d,t.f&l||(t.f^=l),Ct(t)&&(Ht(t,c),qt(t));for(var i=t.first;null!==i;){var n=i.next;fe(i,!!(!!(i.f&m)||!!(i.f&r))&&e),i=n}if(null!==t.transitions)for(const i of t.transitions)(i.is_global||e)&&i.in()}}function ge(t){throw new Error("https://svelte.dev/e/lifecycle_outside_component")}let we=null;function be(t){we=t}function ye(t){return Ee().get(t)}function ke(t,e){return Ee().set(t,e),e}function Te(t,e=!1,i){var r=we={p:we,c:null,d:!1,e:null,m:!1,s:t,x:null,l:null};U&&!e&&(we.l={s:null,u:null,r1:[],r2:X(!1)}),te((()=>{r.d=!0}))}function _e(t){const e=we;if(null!==e){void 0!==t&&(e.x=t);const o=e.e;if(null!==o){var i=Tt,r=bt;e.e=null;try{for(var n=0;n<o.length;n++){var s=o[n];_t(s.effect),kt(s.reaction),ie(s.fn)}}finally{_t(i),kt(r)}}we=e.p,e.m=!0}return t||{}}function xe(){return!U||null!==we&&null===we.l}function Ee(t){return null===we&&ge(),we.c??(we.c=new Map(function(t){let e=t.p;for(;null!==e;){const t=e.c;if(null!==t)return t;e=e.p}return null}(we)||void 0))}function $e(t){return t.endsWith("capture")&&"gotpointercapture"!==t&&"lostpointercapture"!==t}const Ae=["beforeinput","click","change","dblclick","contextmenu","focusin","focusout","input","keydown","keyup","mousedown","mousemove","mouseout","mouseover","mouseup","pointerdown","pointermove","pointerout","pointerover","pointerup","touchend","touchmove","touchstart"];function Se(t){return Ae.includes(t)}const Ie={formnovalidate:"formNoValidate",ismap:"isMap",nomodule:"noModule",playsinline:"playsInline",readonly:"readOnly",defaultvalue:"defaultValue",defaultchecked:"defaultChecked",srcobject:"srcObject",novalidate:"noValidate",allowfullscreen:"allowFullscreen",disablepictureinpicture:"disablePictureInPicture",disableremoteplayback:"disableRemotePlayback"};function Me(t){return t=t.toLowerCase(),Ie[t]??t}const Le=["touchstart","touchmove"];function Pe(t){return Le.includes(t)}function Ce(t,e){if(e){const e=document.body;t.autofocus=!0,z((()=>{document.activeElement===e&&t.focus()}))}}function De(t,e,i,r=!0){for(var n of(r&&i(),e))t.addEventListener(n,i);te((()=>{for(var r of e)t.removeEventListener(r,i)}))}function Re(t){var e=bt,i=Tt;kt(null),_t(null);try{return t()}finally{kt(e),_t(i)}}const ze=new Set,Oe=new Set;function Ne(t,e,i,r={}){function n(t){if(r.capture||Ue.call(e,t),!t.cancelBubble)return Re((()=>null==i?void 0:i.call(this,t)))}return t.startsWith("pointer")||t.startsWith("touch")||"wheel"===t?z((()=>{e.addEventListener(t,n,r)})):e.addEventListener(t,n,r),n}function Fe(t,e,i,r,n){var s={capture:r,passive:n},o=Ne(t,e,i,s);e!==document.body&&e!==window&&e!==document||te((()=>{e.removeEventListener(t,o,s)}))}function Ve(t){for(var e=0;e<t.length;e++)ze.add(t[e]);for(var i of Oe)i(t)}function Ue(t){var e,i=this,r=i.ownerDocument,n=t.type,s=(null==(e=t.composedPath)?void 0:e.call(t))||[],o=s[0]||t.target,a=0,l=t.__root;if(l){var c=s.indexOf(l);if(-1!==c&&(i===document||i===window))return void(t.__root=i);var u=s.indexOf(i);if(-1===u)return;c<=u&&(a=c)}if((o=s[a]||t.target)!==i){T(t,"currentTarget",{configurable:!0,get:()=>o||r});var d=bt,h=Tt;kt(null),_t(null);try{for(var m,v=[];null!==o;){var p=o.assignedSlot||o.parentNode||o.host||null;try{var f=o["__"+n];if(null!=f&&(!o.disabled||t.target===o))if(b(f)){var[g,...w]=f;g.apply(o,[t,...w])}else f.call(o,t)}catch(y){m?v.push(y):m=y}if(t.cancelBubble||p===i||null===p)break;o=p}if(m){for(let t of v)queueMicrotask((()=>{throw t}));throw m}}finally{t.__root=i,delete t.currentTarget,kt(d),_t(h)}}}function Be(t){var e=document.createElement("template");return e.innerHTML=t,e.content}function qe(t,e){var i=Tt;null===i.nodes_start&&(i.nodes_start=t,i.nodes_end=e)}function We(t,e){var i,r=!!(1&e),n=!!(2&e),s=!t.startsWith("<!>");return()=>{void 0===i&&(i=Be(s?t:"<!>"+t),r||(i=at(i)));var e=n||rt?document.importNode(i,!0):i.cloneNode(!0);r?qe(at(e),e.lastChild):qe(e,e);return e}}function Xe(t,e,i="svg"){var r,n=!t.startsWith("<!>"),s=!!(1&e),o=`<${i}>${n?t:"<!>"+t}</${i}>`;return()=>{if(!r){var t=at(Be(o));if(s)for(r=document.createDocumentFragment();at(t);)r.appendChild(at(t));else r=at(t)}var e=r.cloneNode(!0);s?qe(at(e),e.lastChild):qe(e,e);return e}}function je(t=""){var e=ot(t+"");return qe(e,e),e}function Ge(){var t=document.createDocumentFragment(),e=document.createComment(""),i=ot();return t.append(e,i),qe(e,i),t}function Ye(t,e){null!==t&&t.before(e)}let He=!0;function Ze(t){He=t}function Ke(t,e){var i=null==e?"":"object"==typeof e?e+"":e;i!==(t.__t??(t.__t=t.nodeValue))&&(t.__t=i,t.nodeValue=i+"")}function Je(t,e){return function(t,{target:e,anchor:i,props:r={},events:s,context:o,intro:a=!0}){!function(){if(void 0===it){it=window,rt=/Firefox/.test(navigator.userAgent);var t=Element.prototype,e=Node.prototype,i=Text.prototype;nt=_(e,"firstChild").get,st=_(e,"nextSibling").get,S(t)&&(t.__click=void 0,t.__className=void 0,t.__attributes=null,t.__style=void 0,t.__e=void 0),S(i)&&(i.__t=void 0)}}();var l=new Set,c=t=>{for(var i=0;i<t.length;i++){var r=t[i];if(!l.has(r)){l.add(r);var n=Pe(r);e.addEventListener(r,Ue,{passive:n});var s=Qe.get(r);void 0===s?(document.addEventListener(r,Ue,{passive:n}),Qe.set(r,1)):Qe.set(r,s+1)}}};c(k(ze)),Oe.add(c);var u=void 0,d=function(t){const e=Qt(n,t,!0);return(t={})=>new Promise((i=>{t.outro?he(e,(()=>{ue(e),i(void 0)})):(ue(e),i(void 0))}))}((()=>{var n=i??e.appendChild(ot());return ae((()=>{o&&(Te({}),we.c=o);s&&(r.$$events=s),He=a,u=t(n,r)||{},He=!0,o&&_e()})),()=>{var t;for(var r of l){e.removeEventListener(r,Ue);var s=Qe.get(r);0==--s?(document.removeEventListener(r,Ue),Qe.delete(r)):Qe.set(r,s)}Oe.delete(c),n!==i&&(null==(t=n.parentNode)||t.removeChild(n))}}));return ti.set(u,d),u}(t,e)}const Qe=new Map;let ti=new WeakMap;function ei(t,i,[r,n]=[0,0]){var s=t,o=null,a=null,l=e,c=!1;const u=(t,e=!0)=>{c=!0,d(e,t)},d=(t,e)=>{l!==(l=t)&&(l?(o?pe(o):e&&(o=ae((()=>e(s)))),a&&he(a,(()=>{a=null}))):(a?pe(a):e&&(a=ae((()=>e(s,[r+1,n])))),o&&he(o,(()=>{o=null}))))};oe((()=>{c=!1,i(u),c||d(null,null)}),r>0?m:0)}function ii(t,e){return e}function ri(t,e,i,r,n,s=null){var o=t,a={flags:e,items:new Map,first:null};!(4&e)||(o=t.appendChild(ot()));var l=null,c=!1,u=Q((()=>{var t=i();return b(t)?t:null==t?[]:k(t)}));oe((()=>{var t=jt(u),h=t.length;c&&0===h||(c=0===h,function(t,e,i,r,n,s,o){var a,l,c,u,h,m,v,p,f,g,w=!!(8&n),b=!!(3&n),y=t.length,T=e.items,_=e.first,x=_,E=null,$=[],A=[];if(w)for(g=0;g<y;g+=1)p=s(v=t[g],g),void 0!==(f=T.get(p))&&(null==(a=f.a)||a.measure(),(m??(m=new Set)).add(f));for(g=0;g<y;g+=1)if(p=s(v=t[g],g),void 0!==(f=T.get(p))){if(b&&ni(f,v,g,n),f.e.f&d&&(pe(f.e),w&&(null==(l=f.a)||l.unfix(),(m??(m=new Set)).delete(f))),f!==x){if(void 0!==h&&h.has(f)){if($.length<A.length){var S,I=A[0];E=I.prev;var M=$[0],L=$[$.length-1];for(S=0;S<$.length;S+=1)oi($[S],I,i);for(S=0;S<A.length;S+=1)h.delete(A[S]);ai(e,M.prev,L.next),ai(e,E,M),ai(e,L,I),x=I,E=L,g-=1,$=[],A=[]}else h.delete(f),oi(f,x,i),ai(e,f.prev,f.next),ai(e,f,null===E?e.first:E.next),ai(e,E,f),E=f;continue}for($=[],A=[];null!==x&&x.k!==p;)x.e.f&d||(h??(h=new Set)).add(x),A.push(x),x=x.next;if(null===x)continue;f=x}$.push(f),E=f,x=f.next}else{E=si(x?x.e.nodes_start:i,e,E,null===E?e.first:E.next,v,p,g,r,n,o),T.set(p,E),$=[],A=[],x=E.next}if(null!==x||void 0!==h){for(var P=void 0===h?[]:k(h);null!==x;)x.e.f&d||P.push(x),x=x.next;var C=P.length;if(C>0){var D=4&n&&0===y?i:null;if(w){for(g=0;g<C;g+=1)null==(c=P[g].a)||c.measure();for(g=0;g<C;g+=1)null==(u=P[g].a)||u.fix()}!function(t,e,i,r){for(var n=[],s=e.length,o=0;o<s;o++)ve(e[o].e,n,!0);var a=s>0&&0===n.length&&null!==i;if(a){var l=i.parentNode;l.textContent="",l.append(i),r.clear(),ai(t,e[0].prev,e[s-1].next)}me(n,(()=>{for(var i=0;i<s;i++){var n=e[i];a||(r.delete(n.k),ai(t,n.prev,n.next)),ue(n.e,!a)}}))}(e,P,D,T)}}w&&z((()=>{var t;if(void 0!==m)for(f of m)null==(t=f.a)||t.apply()}));Tt.first=e.first&&e.first.e,Tt.last=E&&E.e}(t,a,o,n,e,r,i),null!==s&&(0===h?l?pe(l):l=ae((()=>s(o))):null!==l&&he(l,(()=>{l=null}))),jt(u))}))}function ni(t,e,i,r){1&r&&H(t.v,e),2&r?H(t.i,i):t.i=i}function si(t,e,i,r,n,s,o,a,l,c){var u=!!(1&l)?!(16&l)?G(n):X(n):n,d=2&l?X(o):o,h={i:d,v:u,k:s,a:null,e:null,prev:i,next:r};try{return h.e=ae((()=>a(t,u,d,c)),false),h.e.prev=i&&i.e,h.e.next=r&&r.e,null===i?e.first=h:(i.next=h,i.e.next=h.e),null!==r&&(r.prev=h,r.e.prev=h.e),h}finally{}}function oi(t,e,i){for(var r=t.next?t.next.e.nodes_start:i,n=e?e.e.nodes_start:i,s=t.e.nodes_start;s!==r;){var o=lt(s);n.before(s),s=o}}function ai(t,e,i){null===e?t.first=i:(e.next=i,e.e.next=i&&i.e),null!==i&&(i.prev=e,i.e.prev=e&&e.e)}function li(t,e,i,r,n){var s,o=t,a="";oe((()=>{a!==(a=e()??"")&&(void 0!==s&&(ue(s),s=void 0),""!==a&&(s=ae((()=>{var t=Be(a+"");qe(at(t),t.lastChild),o.before(t)}))))}))}function ci(t,e,...i){var r,n=t,s=M;oe((()=>{s!==(s=e())&&(r&&(ue(r),r=null),r=ae((()=>s(n,...i))))}),m)}function ui(t,e,i,r,n,s){var o,a,l,c=null,u=t;oe((()=>{const t=e()||null;var i="svg"===t?"http://www.w3.org/2000/svg":null;t!==o&&(l&&(null===t?he(l,(()=>{l=null,a=null})):t===a?pe(l):(ue(l),Ze(!1))),t&&t!==a&&(l=ae((()=>{if(qe(c=i?document.createElementNS(i,t):document.createElement(t),c),r){var e=c.appendChild(ot());r(c,e)}Tt.nodes_end=c,u.before(c)}))),(o=t)&&(a=o),Ze(!0))}),m)}function di(t){var e,i,r="";if("string"==typeof t||"number"==typeof t)r+=t;else if("object"==typeof t)if(Array.isArray(t)){var n=t.length;for(e=0;e<n;e++)t[e]&&(i=di(t[e]))&&(r&&(r+=" "),r+=i)}else for(i in t)t[i]&&(r&&(r+=" "),r+=i);return r}function hi(t){return"object"==typeof t?function(){for(var t,e,i=0,r="",n=arguments.length;i<n;i++)(t=arguments[i])&&(e=di(t))&&(r&&(r+=" "),r+=e);return r}(t):t??""}const mi=[..." \t\n\r\f \v\ufeff"];function vi(t,e=!1){var i=e?" !important;":";",r="";for(var n in t){var s=t[n];null!=s&&""!==s&&(r+=" "+n+": "+s+i)}return r}function pi(t){return"-"!==t[0]||"-"!==t[1]?t.toLowerCase():t}function fi(t,e,i,r,n,s){var o=t.__className;if(o!==i||void 0===o){var a=function(t,e,i){var r=null==t?"":""+t;if(e&&(r=r?r+" "+e:e),i)for(var n in i)if(i[n])r=r?r+" "+n:n;else if(r.length)for(var s=n.length,o=0;(o=r.indexOf(n,o))>=0;){var a=o+s;0!==o&&!mi.includes(r[o-1])||a!==r.length&&!mi.includes(r[a])?o=a:r=(0===o?"":r.substring(0,o))+r.substring(a+1)}return""===r?null:r}(i,r,s);null==a?t.removeAttribute("class"):e?t.className=a:t.setAttribute("class",a),t.__className=i}else if(s&&n!==s)for(var l in s){var c=!!s[l];null!=n&&c===!!n[l]||t.classList.toggle(l,c)}return s}function gi(t,e={},i,r){for(var n in i){var s=i[n];e[n]!==s&&(null==i[n]?t.style.removeProperty(n):t.style.setProperty(n,s,r))}}function wi(t,e,i,r){if(t.__style!==e){var n=function(t,e){if(e){var i,r,n="";if(Array.isArray(e)?(i=e[0],r=e[1]):i=e,t){t=String(t).replaceAll(/\s*\/\*.*?\*\/\s*/g,"").trim();var s=!1,o=0,a=!1,l=[];i&&l.push(...Object.keys(i).map(pi)),r&&l.push(...Object.keys(r).map(pi));var c=0,u=-1;const e=t.length;for(var d=0;d<e;d++){var h=t[d];if(a?"/"===h&&"*"===t[d-1]&&(a=!1):s?s===h&&(s=!1):"/"===h&&"*"===t[d+1]?a=!0:'"'===h||"'"===h?s=h:"("===h?o++:")"===h&&o--,!a&&!1===s&&0===o)if(":"===h&&-1===u)u=d;else if(";"===h||d===e-1){if(-1!==u){var m=pi(t.substring(c,u).trim());l.includes(m)||(";"!==h&&d++,n+=" "+t.substring(c,d).trim()+";")}c=d+1,u=-1}}}return i&&(n+=vi(i)),r&&(n+=vi(r,!0)),""===(n=n.trim())?null:n}return null==t?null:String(t)}(e,r);null==n?t.removeAttribute("style"):t.style.cssText=n,t.__style=e}else r&&(Array.isArray(r)?(gi(t,null==i?void 0:i[0],r[0]),gi(t,null==i?void 0:i[1],r[1],"important")):gi(t,i,r));return r}const bi=Symbol("class"),yi=Symbol("style"),ki=Symbol("is custom element"),Ti=Symbol("is html");function _i(t,e){e?t.hasAttribute("selected")||t.setAttribute("selected",""):t.removeAttribute("selected")}function xi(t,e,i,r){var n=Ai(t);n[e]!==(n[e]=i)&&("loading"===e&&(t[w]=i),null==i?t.removeAttribute(e):"string"!=typeof i&&Ii(t).includes(e)?t[e]=i:t.setAttribute(e,i))}function Ei(t,e,i){var r=bt,n=Tt;kt(null),_t(null);try{"style"!==e&&(Si.has(t.nodeName)||!customElements||customElements.get(t.tagName.toLowerCase())?Ii(t).includes(e):i&&"object"==typeof i)?t[e]=i:xi(t,e,null==i?i:String(i))}finally{kt(r),_t(n)}}function $i(t,e,i,r,n=!1){var s=Ai(t),o=s[ki],a=!s[Ti],l=e||{},c="OPTION"===t.tagName;for(var u in e)u in i||(i[u]=null);i.class?i.class=hi(i.class):(r||i[bi])&&(i.class=null),i[yi]&&(i.style??(i.style=null));var d=Ii(t);for(const g in i){let n=i[g];if(c&&"value"===g&&null==n)t.value=t.__value="",l[g]=n;else if("class"!==g)if("style"!==g){var h=l[g];if(n!==h){l[g]=n;var m=g[0]+g[1];if("$$"!==m)if("on"===m){const e={},i="$$"+g;let r=g.slice(2);var v=Se(r);if($e(r)&&(r=r.slice(0,-7),e.capture=!0),!v&&h){if(null!=n)continue;t.removeEventListener(r,l[i],e),l[i]=null}if(null!=n)if(v)t[`__${r}`]=n,Ve([r]);else{let n=function(t){l[g].call(this,t)};l[i]=Ne(r,t,n,e)}else v&&(t[`__${r}`]=void 0)}else if("style"===g)xi(t,g,n);else if("autofocus"===g)Ce(t,Boolean(n));else if(o||"__value"!==g&&("value"!==g||null==n))if("selected"===g&&c)_i(t,n);else{var p=g;a||(p=Me(p));var f="defaultValue"===p||"defaultChecked"===p;if(null!=n||o||f)f||d.includes(p)&&(o||"string"!=typeof n)?t[p]=n:"function"!=typeof n&&xi(t,p,n);else if(s[g]=null,"value"===p||"checked"===p){let i=t;const r=void 0===e;if("value"===p){let t=i.defaultValue;i.removeAttribute(p),i.defaultValue=t,i.value=i.__value=r?t:null}else{let t=i.defaultChecked;i.removeAttribute(p),i.defaultChecked=t,i.checked=!!r&&t}}else t.removeAttribute(g)}else t.value=t.__value=n}}else wi(t,n,null==e?void 0:e[yi],i[yi]),l[g]=n,l[yi]=i[yi];else fi(t,"http://www.w3.org/1999/xhtml"===t.namespaceURI,n,r,null==e?void 0:e[bi],i[bi]),l[g]=n,l[bi]=i[bi]}return l}function Ai(t){return t.__attributes??(t.__attributes={[ki]:t.nodeName.includes("-"),[Ti]:"http://www.w3.org/1999/xhtml"===t.namespaceURI})}var Si=new Map;function Ii(t){var e,i=Si.get(t.nodeName);if(i)return i;Si.set(t.nodeName,i=[]);for(var r=t,n=Element.prototype;n!==r;){for(var s in e=x(r))e[s].set&&i.push(s);r=A(r)}return i}const Mi={tick:t=>requestAnimationFrame(t),now:()=>performance.now(),tasks:new Set};function Li(){const t=Mi.now();Mi.tasks.forEach((e=>{e.c(t)||(Mi.tasks.delete(e),e.f())})),0!==Mi.tasks.size&&Mi.tick(Li)}function Pi(t,e){Re((()=>{t.dispatchEvent(new CustomEvent(e))}))}function Ci(t){if("float"===t)return"cssFloat";if("offset"===t)return"cssOffset";if(t.startsWith("--"))return t;const e=t.split("-");return 1===e.length?e[0]:e[0]+e.slice(1).map((t=>t[0].toUpperCase()+t.slice(1))).join("")}function Di(t){const e={},i=t.split(";");for(const r of i){const[t,i]=r.split(":");if(!t||void 0===i)break;e[Ci(t.trim())]=i.trim()}return e}const Ri=t=>t;function zi(t,e,i,r){var n,s,o,a=!!(1&t),l=!!(2&t),c=!!(4&t),u=a&&l?"both":a?"in":"out",d=e.inert,h=e.style.overflow;function v(){var t=bt,s=Tt;kt(null),_t(null);try{return n??(n=i()(e,(null==r?void 0:r())??{},{direction:u}))}finally{kt(t),_t(s)}}var p={is_global:c,in(){var t;if(e.inert=d,!a)return null==o||o.abort(),void(null==(t=null==o?void 0:o.reset)||t.call(o));l||null==s||s.abort(),Pi(e,"introstart"),s=Oi(e,v(),o,1,(()=>{Pi(e,"introend"),null==s||s.abort(),s=n=void 0,e.style.overflow=h}))},out(t){if(!l)return null==t||t(),void(n=void 0);e.inert=!0,Pi(e,"outrostart"),o=Oi(e,v(),s,0,(()=>{Pi(e,"outroend"),null==t||t()}))},stop:()=>{null==s||s.abort(),null==o||o.abort()}},f=Tt;if((f.transitions??(f.transitions=[])).push(p),a&&He){var g=c;if(!g){for(var w=f.parent;w&&w.f&m;)for(;(w=w.parent)&&!(16&w.f););g=!w||!!(32768&w.f)}g&&ie((()=>{Gt((()=>p.in()))}))}}function Oi(t,e,i,r,n){var s=1===r;if(I(e)){var o,a=!1;return z((()=>{if(!a){var l=e({direction:s?"in":"out"});o=Oi(t,l,i,r,n)}})),{abort:()=>{a=!0,null==o||o.abort()},deactivate:()=>o.deactivate(),reset:()=>o.reset(),t:()=>o.t()}}if(null==i||i.deactivate(),!(null==e?void 0:e.duration))return n(),{abort:M,deactivate:M,reset:M,t:()=>r};const{delay:l=0,css:c,tick:u,easing:d=Ri}=e;var h=[];if(s&&void 0===i&&(u&&u(0,1),c)){var m=Di(c(0,1));h.push(m,m)}var v=()=>1-r,p=t.animate(h,{duration:l});return p.onfinish=()=>{var s=(null==i?void 0:i.t())??1-r;null==i||i.abort();var o=r-s,a=e.duration*Math.abs(o),l=[];if(a>0){var h=!1;if(c)for(var m=Math.ceil(a/(1e3/60)),f=0;f<=m;f+=1){var g=s+o*d(f/m),w=Di(c(g,1-g));l.push(w),h||(h="hidden"===w.overflow)}h&&(t.style.overflow="hidden"),v=()=>{var t=p.currentTime;return s+o*d(t/a)},u&&function(t){let e;0===Mi.tasks.size&&Mi.tick(Li),new Promise((i=>{Mi.tasks.add(e={c:t,f:i})}))}((()=>{if("running"!==p.playState)return!1;var t=v();return u(t,1-t),!0}))}(p=t.animate(l,{duration:a,fill:"forwards"})).onfinish=()=>{v=()=>r,null==u||u(r,1-r),n()}},{abort:()=>{p&&(p.cancel(),p.effect=null,p.onfinish=M)},deactivate:()=>{n=M},reset:()=>{0===r&&(null==u||u(1,0))},t:()=>v()}}function Ni(t,e,i=e){var r,n,s=()=>{cancelAnimationFrame(r),t.paused||(r=requestAnimationFrame(s));var e=t.currentTime;n!==e&&i(n=e)};r=requestAnimationFrame(s),t.addEventListener("timeupdate",s),ne((()=>{var i=Number(e());n===i||isNaN(i)||(t.currentTime=n=i)})),te((()=>{cancelAnimationFrame(r),t.removeEventListener("timeupdate",s)}))}function Fi(t,e){De(t,["seeking","seeked"],(()=>e(t.seeking)))}function Vi(t,e,i=e){var r=e();De(t,["play","pause","canplay"],(()=>{r!==t.paused&&i(r=t.paused)}),null==r),ie((()=>{(r=!!e())!==t.paused&&(r?t.pause():t.play().catch((()=>{i(r=!0)})))}))}function Ui(t,e,i=e){var r=()=>{i(t.muted)};null==e()&&r(),De(t,["volumechange"],r,!1),ne((()=>{var i=!!e();t.muted!==i&&(t.muted=i)}))}function Bi(t,e){return t===e||(null==t?void 0:t[f])===e}function qi(t={},e,i,r){return ie((()=>{var r,n;return ne((()=>{r=n,n=[],Gt((()=>{t!==i(...n)&&(e(t,...n),r&&Bi(i(...r),t)&&e(null,...r))}))})),()=>{z((()=>{n&&Bi(i(...n),t)&&e(null,...n)}))}})),t}function Wi(t,e,i,r,n){var s=()=>{r(i[t])};i.addEventListener(e,s),s(),i!==document.body&&i!==window&&i!==document||te((()=>{i.removeEventListener(e,s)}))}function Xi(t=!1){const e=we,i=e.l.u;if(!i)return;let r=()=>Zt(e.s);if(t){let t=0,i={};const n=K((()=>{let r=!1;const n=e.s;for(const t in n)n[t]!==i[t]&&(i[t]=n[t],r=!0);return r&&t++,t}));r=()=>jt(n)}var n;i.b.length&&(n=()=>{ji(e,r),P(i.b)},Jt(),ne(n)),ee((()=>{const t=Gt((()=>i.m.map(L)));return()=>{for(const e of t)"function"==typeof e&&e()}})),i.a.length&&ee((()=>{ji(e,r),P(i.a)}))}function ji(t,e){if(t.l.s)for(const i of t.l.s)jt(i);e()}function Gi(t){var e,i;null===we&&ge(),U&&null!==we.l?(e=we,i=e.l,i.u??(i.u={a:[],b:[],m:[]})).m.push(t):ee((()=>{const e=Gt(t);if("function"==typeof e)return e}))}function Yi(t,e,i){if(null==t)return e(void 0),M;const r=Gt((()=>t.subscribe(e,i)));return r.unsubscribe?()=>r.unsubscribe():r}const Hi=[];function Zi(t,e=M){let i=null;const r=new Set;function n(e){if(F(t,e)&&(t=e,i)){const e=!Hi.length;for(const i of r)i[1](),Hi.push(i,t);if(e){for(let t=0;t<Hi.length;t+=2)Hi[t][0](Hi[t+1]);Hi.length=0}}}function s(e){n(e(t))}return{set:n,update:s,subscribe:function(o,a=M){const l=[o,a];return r.add(l),1===r.size&&(i=e(n,s)||M),o(t),()=>{r.delete(l),0===r.size&&i&&(i(),i=null)}}}}function Ki(t){let e;return Yi(t,(t=>e=t))(),e}let Ji=!1,Qi=Symbol();function tr(t,e,i){const r=i[e]??(i[e]={store:null,source:G(void 0),unsubscribe:M});if(r.store!==t&&!(Qi in i))if(r.unsubscribe(),r.store=t??null,null==t)r.source.v=void 0,r.unsubscribe=M;else{var n=!0;r.unsubscribe=Yi(t,(t=>{n?r.source.v=t:Y(r.source,t)})),n=!1}return t&&Qi in i?Ki(t):jt(r.source)}function er(t,e,i){let r=i[e];return r&&r.store!==t&&(r.unsubscribe(),r.unsubscribe=M),t}function ir(){const t={};return[t,function(){te((()=>{for(var e in t){t[e].unsubscribe()}T(t,Qi,{enumerable:!1,value:!0})}))}]}const rr={get(t,e){let i=t.props.length;for(;i--;){let r=t.props[i];if(I(r)&&(r=r()),"object"==typeof r&&null!==r&&e in r)return r[e]}},set(t,e,i){let r=t.props.length;for(;r--;){let n=t.props[r];I(n)&&(n=n());const s=_(n,e);if(s&&s.set)return s.set(i),!0}return!1},getOwnPropertyDescriptor(t,e){let i=t.props.length;for(;i--;){let r=t.props[i];if(I(r)&&(r=r()),"object"==typeof r&&null!==r&&e in r){const t=_(r,e);return t&&!t.configurable&&(t.configurable=!0),t}}},has(t,e){if(e===f||e===g)return!1;for(let i of t.props)if(I(i)&&(i=i()),null!=i&&e in i)return!0;return!1},ownKeys(t){const e=[];for(let i of t.props){I(i)&&(i=i());for(const t in i)e.includes(t)||e.push(t)}return e}};function nr(...t){return new Proxy({props:t},rr)}function sr(t){var e;return(null==(e=t.ctx)?void 0:e.d)??!1}function or(t,e,i,r){var n,s,o=!!(1&i),a=!U||!!(2&i),l=!!(8&i),c=!!(16&i),u=!1;l?[s,u]=function(t){var e=Ji;try{return Ji=!1,[t(),Ji]}finally{Ji=e}}((()=>t[e])):s=t[e];var d,h=f in t||g in t,m=l&&((null==(n=_(t,e))?void 0:n.set)??(h&&e in t&&(i=>t[e]=i)))||void 0,v=r,p=!0,w=!1,b=()=>(w=!0,p&&(p=!1,v=c?Gt(r):r),v);if(void 0===s&&void 0!==r&&(m&&a&&function(){throw new Error("https://svelte.dev/e/props_invalid_value")}(),s=b(),m&&m(s)),a)d=()=>{var i=t[e];return void 0===i?b():(p=!0,w=!1,i)};else{var y=(o?K:Q)((()=>t[e]));y.f|=131072,d=()=>{var t=jt(y);return void 0!==t&&(v=void 0),void 0===t?v:t}}if(!(4&i))return d;if(m){var k=t.$$legacy;return function(t,e){return arguments.length>0?(a&&e&&!k&&!u||m(e?d():t),t):d()}}var T=!1,x=G(s),E=K((()=>{var t=d(),e=jt(x);return T?(T=!1,e):x.v=t}));return l&&jt(E),o||(E.equals=V),function(t,e){if(arguments.length>0){const i=e?jt(E):a&&l?B(t):t;if(!E.equals(i)){if(T=!0,Y(x,i),w&&void 0!==v&&(v=i),sr(E))return t;Gt((()=>jt(E)))}return t}return sr(E)?E.v:jt(E)}}const ar=(t,e)=>Math.sqrt(t*t+e*e),lr=(t,e=1)=>(t%e+e)%e,cr=()=>ur()+ur()+"-"+ur()+"-"+ur()+"-"+ur()+"-"+ur()+ur()+ur(),ur=()=>Math.floor(65536*(1+Math.random())).toString(16).substring(1),dr=t=>new Promise((e=>t?setTimeout(e,t):e())),hr=navigator.userAgent,mr={iOS:/ipad|iphone|ipod/i.test(hr),firefox:/firefox/i.test(hr),OSX:/macintosh/i.test(hr)&&/os\ x/i.test(hr),hasTouch:"TouchEvent"in self,safari:!1};function vr(t,e,i={}){for(let r in t)t[r]&&null!=t[r].constructor&&"Object"==t[r].constructor.name?(e[r]&&"object"==typeof e[r]||(e[r]={}),vr(t[r],e[r],i)):i.mergeArrays&&e[r]instanceof Array&&t[r]instanceof Array?e[r].push(...t[r]):i.noOverwrite&&r in e||(e[r]=t[r]);return e}mr.safari=(mr.OSX||mr.iOS)&&(/safari/i.test(hr)||/instagram/i.test(hr))&&!/chrome/i.test(hr),mr.OSX&&mr.safari&&"TouchEvent"in self&&(mr.iOS=!0,mr.OSX=!1);const pr=t=>{if(void 0===t)return t;t=(t=t.replace(/^\s+|\s+$/g,"")).toLowerCase();const e="àáäâèéëêìíïîòóöôùúüûñç·/_,:;";for(var i=0;i<28;i++)t=t.replace(new RegExp(e.charAt(i),"g"),"aaaaeeeeiiiioooouuuunc------".charAt(i));return t=t.replace(/[^a-z0-9 -]/g,"").replace(/\s+/g,"-").replace(/-+/g,"-")},fr=[],gr=(t,e,i)=>new Promise(((r,n)=>{if(i||fr.indexOf(t)>=0)return r();const s=document.createElement("script"),o=()=>{fr.push(t),r()};e?self[e]=o:s.onload=o,s.onerror=()=>n&&n(),s.async=!0,s.defer=!0,self.crossOriginIsolated&&(s.crossOrigin="anonymous"),s.src=t,document.head.appendChild(s)}));function wr(t){const e=t<0;e&&(t*=-1);let i=[0,0,Math.ceil(t)];for(let r of[0,1])for(;i[2-r]>=60&&(i[2-r]-=60,++i[1-r]););return(e?"-":"")+i.filter(((t,e)=>e>0||t)).map(((t,e)=>(t<10&&e?"0":"")+t)).join(":")}const br=(t,e={})=>new Promise((i=>{let r,n=!0;r=t.subscribe((t=>{n&&e.allowUndefined&&void 0===t||(n=!1,(void 0!==e.targetValue?t===e.targetValue:e.allowUndefined||void 0!==t)&&(r?r():Xt().then((()=>r())),i(t)))}))})),yr=new Map,kr=new Map,Tr=async(t,e)=>{if(!e&&yr.has(t))return yr.get(t);if(kr.has(t))return kr.get(t);const i=fetch(t+(e?"?"+Math.random():"")).then((async t=>{if(200==t.status)return t.json();throw await t.text()})).then((i=>(e||yr.set(t,i),kr.delete(t),i))).catch((e=>{kr.delete(t)}));return kr.set(t,i),i},_r=t=>"MICRIO_DATA"in self?(null==self?void 0:self.MICRIO_DATA).find((e=>e[0]==t)):void 0,xr=(t,e,i)=>{var r;const n=null==(r=_r(t))?void 0:r[1];return n?Promise.resolve(n):Tr(`${e??"https://i.micr.io/"}${t}/info.json`,i).then((t=>(t&&("Height"in t&&(t.height=t.Height,t.version=1,t.tileSize=512),"Width"in t&&(t.width=t.Width)),Ar(t),t)))},Er={"micrio-cdn.azureedge.net":"micrio.vangoghmuseum.nl/micrio","micrio-cdn.vangoghmuseum.nl":"micrio.vangoghmuseum.nl/micrio","rijks-micrio.azureedge.net":"micrio.rijksmuseum.nl"},$r=t=>{if(t instanceof Object&&"fileUrl"in t&&!t.src&&(t.src=t.fileUrl),null==t?void 0:t.src)for(let e in Er)t.src.includes(e)&&(t.src=t.src.replace(e,Er[e]))},Ar=t=>{var e,i,r,n,s,o,a,l;t&&($r(null==(e=t.organisation)?void 0:e.logo),$r(null==(r=null==(i=t.settings)?void 0:i._markers)?void 0:r.markerIcon),null==(o=null==(s=null==(n=t.settings)?void 0:n._markers)?void 0:s.customIcons)||o.forEach($r),$r(null==(l=null==(a=t.settings)?void 0:a._360)?void 0:l.video))},Sr=t=>{var e;$r(t.image),null==(e=t.children)||e.forEach(Sr)},Ir=(t,e,i)=>{var r,n,s,o;t.data||(t.data={}),t.id||(t.id=cr()),t.tags||(t.tags=[]),"type"in t||(t.type="default"),t.popupType||(t.popupType="popup"),"string"==typeof t.data.icon&&(t.data.icon={title:"",size:0,uploaded:0,width:-1,height:-1,src:t.data.icon}),null==(r=t.images)||r.forEach($r),$r(t.positionalAudio),$r(null==(n=t.data)?void 0:n.icon),Object.values(t.i18n??{}).forEach((t=>$r(t.audio)));const a="embedImages"in t?t.embedImages:void 0;a&&a.forEach((t=>$r(t)));const l=null==(o=null==(s=t.data)?void 0:s._meta)?void 0:o.secondary;l&&(t.data.micrioSplitLink=l),i&&"class"in t&&t.tags.push(...t.class.split(" ").map((t=>t.trim())).filter((e=>!!e&&!t.tags.includes(e)))),t.tags.includes("default")&&(t.type="default"),e&&t.view&&t.view[2]<t.view[0]&&t.view[2]++};async function Mr(t,e,i,r){if(!("steps"in e)||e.stepInfo)return;let n=e.steps.map((t=>t.split(",")[1])).filter((e=>!!e&&e!=t.id));n=n.filter(((t,e)=>n.indexOf(t)==e));const s=await Promise.all(n.map((e=>Tr((e=>t.dataPath+(t.isV5?e+"/data/pub.json":e+"/data."+i+".json"))(e)))));s.forEach((e=>{var i;return null==(i=null==e?void 0:e.markers)?void 0:i.forEach((e=>Ir(e,t.is360,!t.isV5)))})),$r(e.image);let o=-1;const a=[];e.stepInfo=e.steps.map(((e,l)=>{var c,u,d,h,m,v,p,f,g,w;const[b,y]=e.split(","),k=s[n.indexOf(y)]??r,T=null==(c=null==k?void 0:k.markers)?void 0:c.find((t=>t.id==b)),_=(null==(u=null==T?void 0:T.i18n)?void 0:u[i])??T;(null==_?void 0:_.title)&&(o=l);const x=(null==T?void 0:T.videoTour)?"timeline"in T.videoTour?T:(null==(d=T.videoTour.i18n)?void 0:d[i])??void 0:void 0;return $r(null==x?void 0:x.audio),$r(null==x?void 0:x.subtitle),T?($r(null==_?void 0:_.audio),{markerId:b,marker:T,micrioId:y||t.id,duration:Number((null==x?void 0:x.duration)||(null==(h=null==_?void 0:_.audio)?void 0:h.duration)||0),startView:(null==(m=null==x?void 0:x.timeline)?void 0:m.length)?x.timeline[0].rect:null==T?void 0:T.view,imageHasOtherMarkers:!!y&&!!(null==(v=null==k?void 0:k.markers)?void 0:v.find((t=>t.id!=b&&!t.noMarker))),gridView:!(!(null==(f=null==(p=T.data)?void 0:p._meta)?void 0:f.gridView)&&!(null==(w=null==(g=T.data)?void 0:g._meta)?void 0:w.gridAction)),chapter:o,hasSubtitle:!!(null==x?void 0:x.subtitle)}):(console.warn(`[Micrio] Warning: tour step ${l+1} with id [${b}] not found! Removing it from the tour`),void a.push(l))})).filter((t=>"object"==typeof t)),a.reverse().forEach((t=>e.steps.splice(t,1))),e.initialStep=0,e.duration=e.stepInfo.reduce(((t,e)=>t+(e.duration||0)),0)}const Lr=t=>{let e=t.charCodeAt(0),i=e<91;return(e-=i?65:97)-(e>7?1:0)+(i?24:e>10?-1:0)},Pr=t=>6==t.length||7==t.length;function Cr(t,e){var i,r,n,s;const o=t.$current;if(!o)return;const a=null==(i=t.spaceData)?void 0:i.images.find((t=>t.id==o.id)),l=null==(r=t.spaceData)?void 0:r.images.find((t=>t.id==e));if(!a||!l)return;const c=[(l.x??.5)-(a.x??.5),(a.y??.5)-(l.y??.5),(l.z??.5)-(a.z??.5)];let u=c[0]*c[0]+c[1]*c[1]+c[2]*c[2];u>0&&(u=1/Math.sqrt(u));const d=[c[0]*u,c[1]*u,c[2]*u],h=.5-((null==(s=null==(n=o.$settings)?void 0:n._360)?void 0:s.trueNorth)??.5),m=lr(Math.atan2(-d[0],d[2])/Math.PI/2);return{v:c,vN:d,directionX:m,vector:{direction:m%1-h,distanceX:Math.max(0,Math.min(.4,Math.sqrt(d[0]*d[0]+d[2]*d[2]))),distanceY:-c[1]}}}const Dr=t=>{const e=t??document.createElement("video");return!(!e.canPlayType("application/vnd.apple.mpegurl")&&!e.canPlayType("application/x-mpegURL"))},Rr=t=>t;function zr(t){const e=t-1;return e*e*e+1}function Or(t){const e="string"==typeof t&&t.match(/^\s*(-?[\d.]+)([^\s]*)\s*$/);return e?[parseFloat(e[1]),e[2]||"px"]:[t,"px"]}function Nr(t,{delay:e=0,duration:i=400,easing:r=Rr}={}){const n=+getComputedStyle(t).opacity;return{delay:e,duration:i,easing:r,css:t=>"opacity: "+t*n}}function Fr(t,{delay:e=0,duration:i=400,easing:r=zr,x:n=0,y:s=0,opacity:o=0}={}){const a=getComputedStyle(t),l=+a.opacity,c="none"===a.transform?"":a.transform,u=l*(1-o),[d,h]=Or(n),[m,v]=Or(s);return{delay:e,duration:i,easing:r,css:(t,e)=>`\n\t\t\ttransform: ${c} translate(${(1-t)*d}${h}, ${(1-t)*m}${v});\n\t\t\topacity: ${l-u*e}`}}var Vr=We('<a rel="noopener" href="https://micr.io/" title="Powered by Micrio" aria-label="Micrio homepage"></a>');function Ur(t,e){Te(e,!0);const[i,r]=ir(),n=ye("micrio"),{tour:s,marker:o}=n.state,a=/micr\.io/.test(location.origin)&&self.parent==self?void 0:"_blank";let l,c=j(!1);Gi((()=>n.loading.subscribe((t=>{clearTimeout(l),t?jt(c)||(l=setTimeout((()=>Y(c,!0)),750)):Y(c,!1)}))));let u=J((()=>!!tr(s,"$tour",i)||!!tr(o,"$marker",i)));var d=Ge(),h=ut(d),m=t=>{var e=Vr();let i;xi(e,"target",a),se((t=>i=fi(e,1,"micrio-logo",null,i,t)),[()=>({loading:jt(c)})]),zi(3,e,(()=>Nr),(()=>({duration:200}))),Ye(t,e)};ei(h,(t=>{jt(u)||t(m)})),Ye(t,d),_e(),r()}var Br=We('<a rel="noopener" target="_blank" class="micrio-logo-org"><img alt="Logo" class="micrio-logo-org"></a>');function qr(t,e){Te(e,!0);const[i,r]=ir(),n=ye("micrio"),{tour:s,marker:o,popover:a}=n.state;let l=J((()=>!!tr(s,"$tour",i)||!!tr(o,"$marker",i)||!!tr(a,"$popover",i)));var c=Ge(),u=ut(c),d=t=>{var i=Br(),r=ct(i);se((t=>{xi(i,"href",e.organisation.href??"#"),xi(i,"title",e.organisation.name),xi(i,"aria-label",`${e.organisation.name??""} homepage`),xi(r,"src",t)}),[()=>function(t){if("string"==typeof t)return t;let e=0,i=Math.max(t.width,t.height);for(;i>1024;)e++,i/=2;return t.micrioId&&t.width>1024?"https://r2.micr.io/"+t.micrioId+"/"+e+"/0-0."+(t.isPng?"png":t.isWebP?"webp":"jpg"):t.src}(e.organisation.logo)]),zi(3,i,(()=>Nr),(()=>({duration:200}))),Ye(t,i)};ei(u,(t=>{!jt(l)&&e.organisation.logo&&t(d)})),Ye(t,c),_e(),r()}const Wr={en:{close:"Close",zoomIn:"Zoom in",zoomOut:"Zoom out",fullscreenToggle:"Toggle fullscreen",switchLanguage:"Switch language",share:"Share",audioMute:"Mute audio",audioUnmute:"Unmute audio",closeMarker:"Close this marker",tourStepNext:"Next step",tourStepPrev:"Previous step",tourStop:"Stop this tour",minimize:"Minimize",play:"Play",pause:"Pause",stop:"Stop",subtitlesToggle:"Toggle subtitles",galleryPrev:"Previous image",galleryNext:"Next image",menuToggle:"Toggle menu",waypointFollow:"Go this way"},nl:{close:"Sluit",zoomIn:"Zoom in",zoomOut:"Zoom uit",fullscreenToggle:"Volledig scherm aan / uit",switchLanguage:"Kies taal",share:"Deel",audioMute:"Geluid uit",audioUnmute:"Geluid aan",closeMarker:"Sluit deze marker",tourStepNext:"Volgende stap",tourStepPrev:"Vorige stap",tourStop:"Stop deze tour",minimize:"Minimaliseer",play:"Start",pause:"Pauzeer",stop:"Stop",subtitlesToggle:"Ondertitels aan / uit",galleryPrev:"Vorige afbeelding",galleryNext:"Volgende afbeelding",menuToggle:"Menu openen / sluiten",waypointFollow:"Ga deze richting"}},Xr=Zi(Wr.en),jr={prefix:"fas",iconName:"bars",icon:[448,512,["navicon"],"f0c9","M0 96C0 78.3 14.3 64 32 64l384 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L32 128C14.3 128 0 113.7 0 96zM0 256c0-17.7 14.3-32 32-32l384 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L32 288c-17.7 0-32-14.3-32-32zM448 416c0 17.7-14.3 32-32 32L32 448c-17.7 0-32-14.3-32-32s14.3-32 32-32l384 0c17.7 0 32 14.3 32 32z"]},Gr={prefix:"fas",iconName:"circle-exclamation",icon:[512,512,["exclamation-circle"],"f06a","M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zm0-384c13.3 0 24 10.7 24 24l0 112c0 13.3-10.7 24-24 24s-24-10.7-24-24l0-112c0-13.3 10.7-24 24-24zM224 352a32 32 0 1 1 64 0 32 32 0 1 1 -64 0z"]},Yr={prefix:"fas",iconName:"compress",icon:[448,512,[],"f066","M160 64c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 64-64 0c-17.7 0-32 14.3-32 32s14.3 32 32 32l96 0c17.7 0 32-14.3 32-32l0-96zM32 320c-17.7 0-32 14.3-32 32s14.3 32 32 32l64 0 0 64c0 17.7 14.3 32 32 32s32-14.3 32-32l0-96c0-17.7-14.3-32-32-32l-96 0zM352 64c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 96c0 17.7 14.3 32 32 32l96 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-64 0 0-64zM320 320c-17.7 0-32 14.3-32 32l0 96c0 17.7 14.3 32 32 32s32-14.3 32-32l0-64 64 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-96 0z"]},Hr={prefix:"fas",iconName:"globe",icon:[512,512,[127760],"f0ac","M352 256c0 22.2-1.2 43.6-3.3 64l-185.3 0c-2.2-20.4-3.3-41.8-3.3-64s1.2-43.6 3.3-64l185.3 0c2.2 20.4 3.3 41.8 3.3 64zm28.8-64l123.1 0c5.3 20.5 8.1 41.9 8.1 64s-2.8 43.5-8.1 64l-123.1 0c2.1-20.6 3.2-42 3.2-64s-1.1-43.4-3.2-64zm112.6-32l-116.7 0c-10-63.9-29.8-117.4-55.3-151.6c78.3 20.7 142 77.5 171.9 151.6zm-149.1 0l-176.6 0c6.1-36.4 15.5-68.6 27-94.7c10.5-23.6 22.2-40.7 33.5-51.5C239.4 3.2 248.7 0 256 0s16.6 3.2 27.8 13.8c11.3 10.8 23 27.9 33.5 51.5c11.6 26 20.9 58.2 27 94.7zm-209 0L18.6 160C48.6 85.9 112.2 29.1 190.6 8.4C165.1 42.6 145.3 96.1 135.3 160zM8.1 192l123.1 0c-2.1 20.6-3.2 42-3.2 64s1.1 43.4 3.2 64L8.1 320C2.8 299.5 0 278.1 0 256s2.8-43.5 8.1-64zM194.7 446.6c-11.6-26-20.9-58.2-27-94.6l176.6 0c-6.1 36.4-15.5 68.6-27 94.6c-10.5 23.6-22.2 40.7-33.5 51.5C272.6 508.8 263.3 512 256 512s-16.6-3.2-27.8-13.8c-11.3-10.8-23-27.9-33.5-51.5zM135.3 352c10 63.9 29.8 117.4 55.3 151.6C112.2 482.9 48.6 426.1 18.6 352l116.7 0zm358.1 0c-30 74.1-93.6 130.9-171.9 151.6c25.5-34.2 45.2-87.7 55.3-151.6l116.7 0z"]},Zr={prefix:"fas",iconName:"image",icon:[512,512,[],"f03e","M0 96C0 60.7 28.7 32 64 32l384 0c35.3 0 64 28.7 64 64l0 320c0 35.3-28.7 64-64 64L64 480c-35.3 0-64-28.7-64-64L0 96zM323.8 202.5c-4.5-6.6-11.9-10.5-19.8-10.5s-15.4 3.9-19.8 10.5l-87 127.6L170.7 297c-4.6-5.7-11.5-9-18.7-9s-14.2 3.3-18.7 9l-64 80c-5.8 7.2-6.9 17.1-2.9 25.4s12.4 13.6 21.6 13.6l96 0 32 0 208 0c8.9 0 17.1-4.9 21.2-12.8s3.6-17.4-1.4-24.7l-120-176zM112 192a48 48 0 1 0 0-96 48 48 0 1 0 0 96z"]},Kr={prefix:"fas",iconName:"circle-play",icon:[512,512,[61469,"play-circle"],"f144","M0 256a256 256 0 1 1 512 0A256 256 0 1 1 0 256zM188.3 147.1c-7.6 4.2-12.3 12.3-12.3 20.9l0 176c0 8.7 4.7 16.7 12.3 20.9s16.8 4.1 24.3-.5l144-88c7.1-4.4 11.5-12.1 11.5-20.5s-4.4-16.1-11.5-20.5l-144-88c-7.4-4.5-16.7-4.7-24.3-.5z"]},Jr={prefix:"fas",iconName:"pause",icon:[320,512,[9208],"f04c","M48 64C21.5 64 0 85.5 0 112L0 400c0 26.5 21.5 48 48 48l32 0c26.5 0 48-21.5 48-48l0-288c0-26.5-21.5-48-48-48L48 64zm192 0c-26.5 0-48 21.5-48 48l0 288c0 26.5 21.5 48 48 48l32 0c26.5 0 48-21.5 48-48l0-288c0-26.5-21.5-48-48-48l-32 0z"]},Qr={prefix:"fas",iconName:"layer-group",icon:[576,512,[],"f5fd","M264.5 5.2c14.9-6.9 32.1-6.9 47 0l218.6 101c8.5 3.9 13.9 12.4 13.9 21.8s-5.4 17.9-13.9 21.8l-218.6 101c-14.9 6.9-32.1 6.9-47 0L45.9 149.8C37.4 145.8 32 137.3 32 128s5.4-17.9 13.9-21.8L264.5 5.2zM476.9 209.6l53.2 24.6c8.5 3.9 13.9 12.4 13.9 21.8s-5.4 17.9-13.9 21.8l-218.6 101c-14.9 6.9-32.1 6.9-47 0L45.9 277.8C37.4 273.8 32 265.3 32 256s5.4-17.9 13.9-21.8l53.2-24.6 152 70.2c23.4 10.8 50.4 10.8 73.8 0l152-70.2zm-152 198.2l152-70.2 53.2 24.6c8.5 3.9 13.9 12.4 13.9 21.8s-5.4 17.9-13.9 21.8l-218.6 101c-14.9 6.9-32.1 6.9-47 0L45.9 405.8C37.4 401.8 32 393.3 32 384s5.4-17.9 13.9-21.8l53.2-24.6 152 70.2c23.4 10.8 50.4 10.8 73.8 0z"]},tn={prefix:"fas",iconName:"arrow-up-right-from-square",icon:[512,512,["external-link"],"f08e","M320 0c-17.7 0-32 14.3-32 32s14.3 32 32 32l82.7 0L201.4 265.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L448 109.3l0 82.7c0 17.7 14.3 32 32 32s32-14.3 32-32l0-160c0-17.7-14.3-32-32-32L320 0zM80 32C35.8 32 0 67.8 0 112L0 432c0 44.2 35.8 80 80 80l320 0c44.2 0 80-35.8 80-80l0-112c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 112c0 8.8-7.2 16-16 16L80 448c-8.8 0-16-7.2-16-16l0-320c0-8.8 7.2-16 16-16l112 0c17.7 0 32-14.3 32-32s-14.3-32-32-32L80 32z"]},en={prefix:"fas",iconName:"arrow-right",icon:[448,512,[8594],"f061","M438.6 278.6c12.5-12.5 12.5-32.8 0-45.3l-160-160c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L338.8 224 32 224c-17.7 0-32 14.3-32 32s14.3 32 32 32l306.7 0L233.4 393.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0l160-160z"]},rn={prefix:"fas",iconName:"volume-high",icon:[640,512,[128266,"volume-up"],"f028","M533.6 32.5C598.5 85.2 640 165.8 640 256s-41.5 170.7-106.4 223.5c-10.3 8.4-25.4 6.8-33.8-3.5s-6.8-25.4 3.5-33.8C557.5 398.2 592 331.2 592 256s-34.5-142.2-88.7-186.3c-10.3-8.4-11.8-23.5-3.5-33.8s23.5-11.8 33.8-3.5zM473.1 107c43.2 35.2 70.9 88.9 70.9 149s-27.7 113.8-70.9 149c-10.3 8.4-25.4 6.8-33.8-3.5s-6.8-25.4 3.5-33.8C475.3 341.3 496 301.1 496 256s-20.7-85.3-53.2-111.8c-10.3-8.4-11.8-23.5-3.5-33.8s23.5-11.8 33.8-3.5zm-60.5 74.5C434.1 199.1 448 225.9 448 256s-13.9 56.9-35.4 74.5c-10.3 8.4-25.4 6.8-33.8-3.5s-6.8-25.4 3.5-33.8C393.1 284.4 400 271 400 256s-6.9-28.4-17.7-37.3c-10.3-8.4-11.8-23.5-3.5-33.8s23.5-11.8 33.8-3.5zM301.1 34.8C312.6 40 320 51.4 320 64l0 384c0 12.6-7.4 24-18.9 29.2s-25 3.1-34.4-5.3L131.8 352 64 352c-35.3 0-64-28.7-64-64l0-64c0-35.3 28.7-64 64-64l67.8 0L266.7 40.1c9.4-8.4 22.9-10.4 34.4-5.3z"]},nn={prefix:"fas",iconName:"arrow-left",icon:[448,512,[8592],"f060","M9.4 233.4c-12.5 12.5-12.5 32.8 0 45.3l160 160c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L109.2 288 416 288c17.7 0 32-14.3 32-32s-14.3-32-32-32l-306.7 0L214.6 118.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-160 160z"]},sn={prefix:"fas",iconName:"minus",icon:[448,512,[8211,8722,10134,"subtract"],"f068","M432 256c0 17.7-14.3 32-32 32L48 288c-17.7 0-32-14.3-32-32s14.3-32 32-32l352 0c17.7 0 32 14.3 32 32z"]},on={prefix:"fas",iconName:"ellipsis-vertical",icon:[128,512,["ellipsis-v"],"f142","M64 360a56 56 0 1 0 0 112 56 56 0 1 0 0-112zm0-160a56 56 0 1 0 0 112 56 56 0 1 0 0-112zM120 96A56 56 0 1 0 8 96a56 56 0 1 0 112 0z"]},an={prefix:"fas",iconName:"closed-captioning",icon:[576,512,[],"f20a","M0 96C0 60.7 28.7 32 64 32l448 0c35.3 0 64 28.7 64 64l0 320c0 35.3-28.7 64-64 64L64 480c-35.3 0-64-28.7-64-64L0 96zM200 208c14.2 0 27 6.1 35.8 16c8.8 9.9 24 10.7 33.9 1.9s10.7-24 1.9-33.9c-17.5-19.6-43.1-32-71.5-32c-53 0-96 43-96 96s43 96 96 96c28.4 0 54-12.4 71.5-32c8.8-9.9 8-25-1.9-33.9s-25-8-33.9 1.9c-8.8 9.9-21.6 16-35.8 16c-26.5 0-48-21.5-48-48s21.5-48 48-48zm144 48c0-26.5 21.5-48 48-48c14.2 0 27 6.1 35.8 16c8.8 9.9 24 10.7 33.9 1.9s10.7-24 1.9-33.9c-17.5-19.6-43.1-32-71.5-32c-53 0-96 43-96 96s43 96 96 96c28.4 0 54-12.4 71.5-32c8.8-9.9 8-25-1.9-33.9s-25-8-33.9 1.9c-8.8 9.9-21.6 16-35.8 16c-26.5 0-48-21.5-48-48z"]},ln={prefix:"fas",iconName:"arrow-down",icon:[384,512,[8595],"f063","M169.4 470.6c12.5 12.5 32.8 12.5 45.3 0l160-160c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L224 370.8 224 64c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 306.7L54.6 265.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l160 160z"]},cn={prefix:"fas",iconName:"link",icon:[640,512,[128279,"chain"],"f0c1","M579.8 267.7c56.5-56.5 56.5-148 0-204.5c-50-50-128.8-56.5-186.3-15.4l-1.6 1.1c-14.4 10.3-17.7 30.3-7.4 44.6s30.3 17.7 44.6 7.4l1.6-1.1c32.1-22.9 76-19.3 103.8 8.6c31.5 31.5 31.5 82.5 0 114L422.3 334.8c-31.5 31.5-82.5 31.5-114 0c-27.9-27.9-31.5-71.8-8.6-103.8l1.1-1.6c10.3-14.4 6.9-34.4-7.4-44.6s-34.4-6.9-44.6 7.4l-1.1 1.6C206.5 251.2 213 330 263 380c56.5 56.5 148 56.5 204.5 0L579.8 267.7zM60.2 244.3c-56.5 56.5-56.5 148 0 204.5c50 50 128.8 56.5 186.3 15.4l1.6-1.1c14.4-10.3 17.7-30.3 7.4-44.6s-30.3-17.7-44.6-7.4l-1.6 1.1c-32.1 22.9-76 19.3-103.8-8.6C74 372 74 321 105.5 289.5L217.7 177.2c31.5-31.5 82.5-31.5 114 0c27.9 27.9 31.5 71.8 8.6 103.9l-1.1 1.6c-10.3 14.4-6.9 34.4 7.4 44.6s34.4 6.9 44.6-7.4l1.1-1.6C433.5 260.8 427 182 377 132c-56.5-56.5-148-56.5-204.5 0L60.2 244.3z"]},un={prefix:"fas",iconName:"play",icon:[384,512,[9654],"f04b","M73 39c-14.8-9.1-33.4-9.4-48.5-.9S0 62.6 0 80L0 432c0 17.4 9.4 33.4 24.5 41.9s33.7 8.1 48.5-.9L361 297c14.3-8.7 23-24.2 23-41s-8.7-32.2-23-41L73 39z"]},dn={prefix:"fas",iconName:"chevron-down",icon:[512,512,[],"f078","M233.4 406.6c12.5 12.5 32.8 12.5 45.3 0l192-192c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L256 338.7 86.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l192 192z"]},hn={prefix:"fas",iconName:"arrow-up",icon:[384,512,[8593],"f062","M214.6 41.4c-12.5-12.5-32.8-12.5-45.3 0l-160 160c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L160 141.2 160 448c0 17.7 14.3 32 32 32s32-14.3 32-32l0-306.7L329.4 246.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3l-160-160z"]},mn={prefix:"fas",iconName:"volume-xmark",icon:[576,512,["volume-mute","volume-times"],"f6a9","M301.1 34.8C312.6 40 320 51.4 320 64l0 384c0 12.6-7.4 24-18.9 29.2s-25 3.1-34.4-5.3L131.8 352 64 352c-35.3 0-64-28.7-64-64l0-64c0-35.3 28.7-64 64-64l67.8 0L266.7 40.1c9.4-8.4 22.9-10.4 34.4-5.3zM425 167l55 55 55-55c9.4-9.4 24.6-9.4 33.9 0s9.4 24.6 0 33.9l-55 55 55 55c9.4 9.4 9.4 24.6 0 33.9s-24.6 9.4-33.9 0l-55-55-55 55c-9.4 9.4-24.6 9.4-33.9 0s-9.4-24.6 0-33.9l55-55-55-55c-9.4-9.4-9.4-24.6 0-33.9s24.6-9.4 33.9 0z"]},vn={prefix:"fas",iconName:"plus",icon:[448,512,[10133,61543,"add"],"2b","M256 80c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 144L48 224c-17.7 0-32 14.3-32 32s14.3 32 32 32l144 0 0 144c0 17.7 14.3 32 32 32s32-14.3 32-32l0-144 144 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-144 0 0-144z"]},pn={prefix:"fas",iconName:"expand",icon:[448,512,[],"f065","M32 32C14.3 32 0 46.3 0 64l0 96c0 17.7 14.3 32 32 32s32-14.3 32-32l0-64 64 0c17.7 0 32-14.3 32-32s-14.3-32-32-32L32 32zM64 352c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 96c0 17.7 14.3 32 32 32l96 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-64 0 0-64zM320 32c-17.7 0-32 14.3-32 32s14.3 32 32 32l64 0 0 64c0 17.7 14.3 32 32 32s32-14.3 32-32l0-96c0-17.7-14.3-32-32-32l-96 0zM448 352c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 64-64 0c-17.7 0-32 14.3-32 32s14.3 32 32 32l96 0c17.7 0 32-14.3 32-32l0-96z"]},fn={prefix:"fas",iconName:"xmark",icon:[384,512,[128473,10005,10006,10060,215,"close","multiply","remove","times"],"f00d","M342.6 150.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192 210.7 86.6 105.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L146.7 256 41.4 361.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L192 301.3 297.4 406.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L237.3 256 342.6 150.6z"]},gn={prefix:"fas",iconName:"share",icon:[512,512,["mail-forward"],"f064","M307 34.8c-11.5 5.1-19 16.6-19 29.2l0 64-112 0C78.8 128 0 206.8 0 304C0 417.3 81.5 467.9 100.2 478.1c2.5 1.4 5.3 1.9 8.1 1.9c10.9 0 19.7-8.9 19.7-19.7c0-7.5-4.3-14.4-9.8-19.5C108.8 431.9 96 414.4 96 384c0-53 43-96 96-96l96 0 0 64c0 12.6 7.4 24.1 19 29.2s25 3 34.4-5.4l160-144c6.7-6.1 10.6-14.7 10.6-23.8s-3.8-17.7-10.6-23.8l-160-144c-9.4-8.5-22.9-10.6-34.4-5.4z"]},wn={prefix:"fas",iconName:"video",icon:[576,512,["video-camera"],"f03d","M0 128C0 92.7 28.7 64 64 64l256 0c35.3 0 64 28.7 64 64l0 256c0 35.3-28.7 64-64 64L64 448c-35.3 0-64-28.7-64-64L0 128zM559.1 99.8c10.4 5.6 16.9 16.4 16.9 28.2l0 256c0 11.8-6.5 22.6-16.9 28.2s-23 5-32.9-1.6l-96-64L416 337.1l0-17.1 0-128 0-17.1 14.2-9.5 96-64c9.8-6.5 22.4-7.2 32.9-1.6z"]};function bn(t,e){t.style.fontSize=e&&"lg"!==e&&"sm"!==e&&"xs"!==e?e.replace("x","em"):""}U=!0;var yn=Xe('<title class="micrio-fa"> </title>'),kn=Xe('<path class="micrio-fa"></path>'),Tn=Xe('<path class="micrio-fa"></path><path class="micrio-fa"></path>',1),_n=Xe('<svg aria-hidden="true" role="img" xmlns="http://www.w3.org/2000/svg"><!><g class="micrio-fa"><g class="micrio-fa"><!></g></g></svg>');function xn(t,e){Te(e,!1);const i=G(),r=G();let n=or(e,"class",24,(()=>{})),s=or(e,"id",24,(()=>{})),o=or(e,"style",24,(()=>{})),a=or(e,"icon",8),c=or(e,"title",24,(()=>{})),d=or(e,"size",24,(()=>{})),h=or(e,"color",24,(()=>{})),m=or(e,"fw",8,!1),v=or(e,"pull",24,(()=>{})),p=or(e,"scale",8,1),f=or(e,"translateX",8,0),g=or(e,"translateY",8,0),w=or(e,"rotate",24,(()=>{})),b=or(e,"flip",24,(()=>{})),y=or(e,"spin",8,!1),k=or(e,"pulse",8,!1),T=or(e,"primaryColor",8,""),_=or(e,"secondaryColor",8,""),x=or(e,"primaryOpacity",8,1),E=or(e,"secondaryOpacity",8,.4),$=or(e,"swapOpacity",8,!1),A=G();var S;re((()=>(jt(A),Zt(d()),bn)),(()=>{jt(A)&&d()&&bn(jt(A),d())})),re((()=>Zt(a())),(()=>{Y(i,a()&&a().icon||[0,0,"",[],""])})),re((()=>(Zt(p()),Zt(f()),Zt(g()),Zt(w()),Zt(b()))),(()=>{Y(r,function(t,e,i,r,n,s=1,o="",a=""){let l=1,c=1;n&&("horizontal"==n?l=-1:"vertical"==n?c=-1:l=c=-1),"string"==typeof t&&(t=parseFloat(t)),"string"==typeof e&&(e=parseFloat(e)),"string"==typeof i&&(i=parseFloat(i));let u=`translate(${e*s}${o},${i*s}${o}) scale(${l*t},${c*t})`;return r&&(u+=` rotate(${r}${a})`),u}(p(),f(),g(),w(),b(),512))})),S=we,ne((()=>{if(jt(S.l.r2)){for(var t of S.l.r1){var e=t.effect;e.f&l&&Ht(e,u),Ct(e)&&Ft(e),t.ran=!1}S.l.r2.v=!1}})),Xi();var I=Ge(),M=ut(I),L=t=>{var e=_n();let a;var l=ct(e),u=t=>{var e=yn(),i=ct(e);se((()=>Ke(i,c()))),Ye(t,e)};ei(l,(t=>{c()&&t(u)}));var p=dt(l),f=ct(p),g=ct(f),w=t=>{var e=kn();se((()=>{xi(e,"d",jt(i)[4]),xi(e,"fill",h()||T()||"currentColor"),xi(e,"transform",`translate(${jt(i)[0]/-2} ${jt(i)[1]/-2})`)})),Ye(t,e)},b=t=>{var e=Tn(),r=ut(e),n=dt(r);se((()=>{xi(r,"d",jt(i)[4][0]),xi(r,"fill",_()||h()||"currentColor"),xi(r,"fill-opacity",0!=$()?x():E()),xi(r,"transform",`translate(${jt(i)[0]/-2} ${jt(i)[1]/-2})`),xi(n,"d",jt(i)[4][1]),xi(n,"fill",T()||h()||"currentColor"),xi(n,"fill-opacity",0!=$()?E():x()),xi(n,"transform",`translate(${jt(i)[0]/-2} ${jt(i)[1]/-2})`)})),Ye(t,e)};ei(g,(t=>{"string"==typeof jt(i)[4]?t(w):t(b,!1)})),qi(e,(t=>Y(A,t)),(()=>jt(A))),se((t=>{xi(e,"id",s()),a=fi(e,0,`svelte-fa svelte-fa-base ${n()??""}`,"micrio-fa",a,t),wi(e,o()),xi(e,"viewBox",`0 0 ${jt(i)[0]??""} ${jt(i)[1]??""}`),xi(p,"transform",`translate(${jt(i)[0]/2} ${jt(i)[1]/2})`),xi(p,"transform-origin",jt(i)[0]/4+" 0"),xi(f,"transform",jt(r))}),[()=>({pulse:k(),"svelte-fa-size-lg":"lg"===d(),"svelte-fa-size-sm":"sm"===d(),"svelte-fa-size-xs":"xs"===d(),"svelte-fa-fw":m(),"svelte-fa-pull-left":"left"===v(),"svelte-fa-pull-right":"right"===v(),spin:y()})],Q),Ye(t,e)};ei(M,(t=>{jt(i)[4]&&t(L)})),Ye(t,I),_e()}function En(t,e){var i,r;Te(e,!0);let n=or(e,"style",3,void 0);const s=ye("micrio"),o="chevron-down"==e.name||"link-ext"==e.name,a=null==(r=null==(i=s.defaultSettings)?void 0:i.ui)?void 0:r.icons;let l=J((()=>a&&("zoom-in"==e.name?a.zoomIn:"zoom-out"==e.name?a.zoomOut:"maximize"==e.name?a.fullscreenEnter:"minimize"==e.name?a.fullscreenLeave:"close"==e.name?a.close:"arrow-right"==e.name?a.next:"arrow-left"==e.name?a.prev:"arrow-up"==e.name?a.up:"arrow-down"==e.name?a.down:"play"==e.name?a.play:"pause"==e.name?a.pause:"subtitles"==e.name?a.subtitles:"subtitles-off"==e.name?a.subtitlesOff:"volume-off"==e.name?a.muted:"volume-up"==e.name?a.unmuted:null)));const c=new Map([["play",un],["pause",Jr],["close",fn],["play-filled",Kr],["a11y",Hr],["menu",jr],["zoom-in",vn],["zoom-out",sn],["maximize",pn],["minimize",Yr],["volume-off",mn],["volume-up",rn],["subtitles",an],["subtitles-off",an],["arrow-left",nn],["arrow-up",hn],["arrow-right",en],["arrow-down",ln],["video",wn],["audio",rn],["image",Zr],["share",gn],["error",Gr],["chevron-down",dn],["link",cn],["link-ext",tn],["ellipsis-vertical",on]]);let u=J((()=>c.get(e.name)));var d=Ge(),h=ut(d),m=t=>{var e=Ge();li(ut(e),(()=>jt(l))),Ye(t,e)},v=(t,e)=>{var i=t=>{xn(t,{get icon(){return jt(u)},size:o?"xs":"sm",get style(){return n()}})};ei(t,(t=>{jt(u)&&t(i)}),e)};ei(h,(t=>{jt(l)?t(m):t(v,!1)})),Ye(t,d),_e()}const $n=Zi(void 0),An=()=>$n.set(void 0);let Sn=!1;$n.subscribe((t=>{t?Sn||window.addEventListener("click",An):Sn&&window.removeEventListener("click",An),Sn=!!t}));var In=We('<a class="micrio-menu-action micrio-menu"><strong class="micrio-menu"> <!></strong></a>'),Mn=We('<button class="micrio-menu-action micrio-menu" type="button"><!> <strong class="micrio-menu"> <!></strong></button>'),Ln=We('<div class="items micrio-menu"></div>'),Pn=We("<menu><!> <!></menu>");function Cn(t,e){Te(e,!0);const[i,r]=ir(),n=()=>tr($n,"$opened",i);let s=or(e,"menu",15),o=or(e,"originalId",3,null);const a=ye("micrio"),{events:l,state:c,_lang:u}=a;let d=j(void 0);let h=J((()=>{return t=s(),e=tr(u,"$_lang",i),(null==(r=t.i18n)?void 0:r[e])??t;var t,e,r}));function m(t){var i;s().link||t.preventDefault(),s().action&&s().action();const r=!!(jt(p)||s().action||s().link);$n.set(r?void 0:s()),r&&(null==(i=e.onclose)||i.call(e))}Gi((()=>{var t,e,i,r;(null==(t=jt(h))?void 0:t.title)||1!=(null==(e=s().children)?void 0:e.length)||s(s().children[0]),s().action||(s().markerId?s(s().action=()=>{var t,e;o()&&(null==(t=a.$current)?void 0:t.id)!=o()&&a.open(o()),null==(e=a.$current)||e.state.marker.set(s().markerId)},!0):((null==(i=jt(h))?void 0:i.content)||(null==(r=jt(h))?void 0:r.embed)||s().image)&&s(s().action=()=>{l.dispatch("page-open",s()),c.popover.set({contentPage:s()})},!0)),s(s()._button=jt(d),!0)}));const v=t=>{var e;return t==n()||!!(null==(e=t.children)?void 0:e.some(v))};let p=J((()=>n()&&v(s())));var f=Pn();let g;var w=ct(f),b=t=>{var e=In();e.__click=m;var i=ct(e),r=ct(i),n=dt(r);const o=J((()=>s().linkTargetBlank?"link-ext":"link"));En(n,{style:"opacity:.75",get name(){return jt(o)}}),se((()=>{var t;xi(e,"href",s().link),xi(e,"target",s().linkTargetBlank?"_blank":void 0),Ke(r,`${(null==(t=jt(h))?void 0:t.title)??"(Unknown)"} `)})),Ye(t,e)},y=t=>{var e=Mn();e.__click=m;var i=ct(e),r=t=>{xn(t,{get icon(){return s().icon},style:"margin-right:10px;"})};ei(i,(t=>{s().icon&&t(r)}));var n=ct(dt(i,2)),o=dt(n),a=t=>{En(t,{name:"chevron-down"})};ei(o,(t=>{s().children&&s().children.length&&t(a)})),qi(e,(t=>Y(d,t)),(()=>jt(d))),se((()=>{var t;return Ke(n,`${(null==(t=jt(h))?void 0:t.title)??"(Unknown)"} `)})),Ye(t,e)};ei(w,(t=>{s().link?t(b):t(y,!1)}));var k=dt(w,2),T=t=>{var e=Ln();ri(e,23,(()=>s().children),((t,e)=>e+t.id),((t,e)=>{Cn(t,{get menu(){return jt(e)},get originalId(){return o()},onclose:An})})),Ye(t,e)};ei(k,(t=>{s().children&&s().children.length&&t(T)})),se(((t,e)=>{xi(f,"data-title",t),g=fi(f,1,"micrio-menu",null,g,e)}),[()=>{var t,e;return null==(e=null==(t=jt(h))?void 0:t.title)?void 0:e.toLowerCase()},()=>({opened:jt(p)})]),Ye(t,f),_e(),r()}Ve(["click"]);var Dn=We('<img alt="Icon" class="micrio-button">'),Rn=We("<!><!>",1);function zn(t,e){Te(e,!0);let i=or(e,"type",3,void 0),r=or(e,"icon",3,void 0),n=or(e,"title",3,null),s=or(e,"disabled",3,!1),o=or(e,"active",3,!1),a=or(e,"className",3,""),l=or(e,"href",3,void 0),c=or(e,"blankTarget",3,!1),u=or(e,"noClick",3,!1);var d=Ge();ui(ut(d),(()=>l()?"a":"button"),0,((t,d)=>{var h=t=>{var i;return null==(i=e.onclick)?void 0:i.call(e,t)},m=t=>{var i;return null==(i=e.onfocus)?void 0:i.call(e,t)},v=t=>{var i;return null==(i=e.onpointerdown)?void 0:i.call(e,t)};let p;se((e=>p=$i(t,p,{href:l(),target:c()?"_blank":void 0,disabled:!!s()||void 0,title:n(),"aria-label":n(),role:l()?void 0:"button",tabindex:l()?void 0:0,class:`micrio-button ${i()??""} ${a()??""}`,onclick:h,onfocus:m,onpointerdown:v,[bi]:e},"micrio-button")),[()=>({active:o(),"no-click":u()})]);var f=Rn(),g=ut(f),w=t=>{En(t,{get name(){return i()}})},b=(t,e)=>{var i=t=>{var e=Dn();se((()=>xi(e,"src",r().src))),Ye(t,e)};ei(t,(t=>{r()&&t(i)}),e)};ei(g,(t=>{i()?t(w):t(b,!1)})),ci(dt(g),(()=>e.children??M)),Ye(d,f)})),Ye(t,d),_e()}var On=We("<menu><!> <!> <!></menu> <!>",1);function Nn(t,e){Te(e,!0);const[i,r]=ir(),n=()=>tr(c,"$current",i),s=()=>tr(u,"$_lang",i);let o=j(void 0);const a=ye("micrio"),{state:l,current:c,_lang:u,spaceData:d}=a,{tour:h,marker:m,popover:v}=l;let p=j(!1),f=j(!1);const g=n().id;let w=j(void 0),b=j(window.innerWidth<=500);const y=()=>Y(b,window.innerWidth<=500),k=()=>{jt(b)&&Y(p,!1)};let T=J((()=>!!tr(h,"$tour",i)||!!tr(m,"$marker",i)||!!tr(v,"$popover",i))),_=J((()=>{var t;return((null==(t=jt(o))?void 0:t.markerTours)??[]).concat((null==d?void 0:d.markerTours)??[])})),x=J((()=>{var t;return(null==(t=jt(_))?void 0:t.length)>0})),E=J((()=>{var t,e,i;return(null==(t=jt(o))?void 0:t.tours)&&(null==(i=null==(e=jt(o))?void 0:e.tours)?void 0:i.length)>0})),$=J((()=>jt(x)&&jt(E))),A=J((()=>{var t;return!((null==(t=jt(w))?void 0:t.length)||jt(x)||jt(E))}));const S=[],I=(t,e)=>{var i,r;return("title"in t?t.title:null==(r=null==(i=t.i18n)?void 0:i[e])?void 0:r.title)??"(Untitled)"};Gi((()=>{const t=a.current.subscribe((t=>{var e;if(t){for(;S.length;)null==(e=S.shift())||e();br(t.info).then((()=>Y(f,!t.$settings.noLogo))),S.push(t.data.subscribe((t=>{Y(o,t,!0),Xt().then((()=>{var e,i,r;if(!(null==t?void 0:t.pages))return;jt(w)||Y(w,null==(e=t.pages)?void 0:e.filter((t=>{var e;return!(null==(e=t.id)?void 0:e.startsWith("_"))})),!0);const n=null==(i=t.pages)?void 0:i.filter((t=>{var e;return null==(e=t.id)?void 0:e.startsWith("_")}));n.length&&Y(w,[...(null==(r=jt(w))?void 0:r.filter((t=>{var e;return!(null==(e=t.id)?void 0:e.startsWith("_"))})))??[],...n],!0)}))})))}}));return window.addEventListener("resize",y),()=>{var e;for(window.removeEventListener("resize",y);S.length;)null==(e=S.shift())||e();t()}}));var M=Ge(),L=ut(M),P=t=>{var e=On(),r=ut(e);let l;var c=ct(r),u=t=>{var e=Ge();ri(ut(e),17,(()=>jt(w)),(t=>t.id),((t,e)=>{Cn(t,{get menu(){return jt(e)},originalId:g,onclose:k})})),Ye(t,e)};ei(c,(t=>{jt(w)&&t(u)}));var d=dt(c,2),m=t=>{const e=J((()=>({id:cr(),i18n:{[s()]:{title:jt($)?"Marker tours":"Tours"}},children:jt(_).map((t=>({id:cr(),i18n:{[s()]:{title:I(t,s())}},action:()=>{t.initialStep=0,h.set(t)}})))})));Cn(t,{onclose:k,get menu(){return jt(e)}})};ei(d,(t=>{jt(x)&&t(m)}));var v=dt(d,2),y=t=>{const e=J((()=>({id:cr(),i18n:{[s()]:{title:jt($)?"Video tours":"Tours"}},children:jt(o)&&jt(o).tours?jt(o).tours.map((t=>({id:cr(),i18n:{[s()]:{title:I(t,s())}},action:()=>{n()&&n().id!=g&&a.open(g),h.set(t)}}))):[]})));Cn(t,{onclose:k,get menu(){return jt(e)}})};ei(v,(t=>{jt(E)&&t(y)}));var A=dt(r,2),S=t=>{const e=J((()=>jt(p)?"close":"ellipsis-vertical")),r=J((()=>"toggle transparent"+(jt(f)?" indent":"")));zn(t,{get title(){return tr(Xr,"$i18n",i).menuToggle},get type(){return jt(e)},get className(){return jt(r)},onclick:()=>Y(p,!jt(p))})};ei(A,(t=>{jt(b)&&t(S)})),se((t=>l=fi(r,1,"micrio-toolbar micrio-toolbar",null,l,t)),[()=>({shown:!jt(T)&&jt(p),indent:jt(f)})]),zi(3,r,(()=>Nr),(()=>({duration:200}))),Ye(t,e)};ei(L,(t=>{jt(A)||jt(T)||t(P)})),Ye(t,M),_e(),r()}var Fn=We("<canvas></canvas>");function Vn(t,e){Te(e,!0);const[i,r]=ir(),n=ye("micrio"),{current:s}=n,o=n.canvas.viewport,a=e.image.$info,l=e.image.camera,c=e.image.$settings,u=c.minimapWidth??200,d=c.minimapHeight??160,h=!c.alwaysShowMinimap,m=!!c.noControls,v=a.width/a.height,p=u/v>d?Math.round(d*v):u,f=u/v<=d?Math.round(u/v):d;let g,w=j(void 0),b=j(!1),y=j(B(!a.is360&&l.isZoomedOut()));function k(t){if(t&&g){if(S(),g.clearRect(0,0,p,f),e.image.thumbSrc?(g.globalCompositeOperation="source-over",g.fillStyle="rgba(0,0,0,.5)",g.fillRect(0,0,p,f),g.globalAlpha=1,g.globalCompositeOperation="destination-out"):(g.fillStyle="rgba(0,0,0,.5)",g.fillRect(0,0,p,f)),g.beginPath(),g.fillStyle="white",a.is360){const t=function(){const t=[],e=o.width*o.ratio,i=o.height*o.ratio,r=l.getCoo(e/2,i/2).slice(0),n=[];for(let s=0;s<8;s++)n.push(s/8*e,0);for(let s=0;s<8;s++)n.push(e,s/8*i);for(let s=0;s<8;s++)n.push((1-s/8)*e,i);for(let s=0;s<8;s++)n.push(0,(1-s/8)*i);for(let s=0;s<n.length;s+=2){const e=l.getCoo(n[s],n[s+1]);(s>40||s<8)&&e[0]>r[0]?e[0]-=1:s>8&&s<40&&e[0]<r[0]&&(e[0]+=1),t.push(e[0],e[1])}return t}();g.moveTo(t[0]*p,t[1]*f);for(let e=2;e<t.length;e+=2)g.lineTo(t[e]*p,t[e+1]*f);g.closePath()}else Y(y,l.isZoomedOut(),!0),g.rect(Math.floor(t[0]*p),Math.floor(t[1]*f),Math.ceil((t[2]-t[0])*p),Math.ceil((t[3]-t[1])*f));e.image.thumbSrc&&(g.fill(),g.globalCompositeOperation="source-over"),g.stroke()}}const T=-1!=navigator.userAgent.indexOf("Firefox");let _,x,E=j(!1);function $(t){if(_){const e=Math.max(0,Math.min(1,(t.clientX-_.left)/_.width)),i=Math.max(0,Math.min(1,(t.clientY-_.top)/_.height));l.setCoo(e,i)}}function A(){window.removeEventListener("mousemove",$),window.removeEventListener("mouseup",A),Y(E,!1)}function S(){Y(b,!1),clearTimeout(x),x=setTimeout((()=>Y(b,!0)),2500)}const I=.5-e.image.camera.trueNorth,M=self.crossOriginIsolated;let L=j(B(M?void 0:e.image.thumbSrc));const P={passive:!0};let C=j(!1);Gi((()=>{let t;g=jt(w).getContext("2d"),g&&(g.lineWidth=1,g.strokeStyle="white"),M&&e.image.thumbSrc&&fetch(e.image.thumbSrc).then((t=>t.blob())).then((e=>Y(L,t=URL.createObjectURL(e),!0))),n.canvas.element.addEventListener("mousemove",S,P);const i=e.image.state.view.subscribe(k);return setTimeout((()=>Y(C,!0)),10),()=>{t&&URL.revokeObjectURL(t),n.canvas.element.removeEventListener("mousemove",S,P),A(),i()}}));let D=J((()=>jt(L)?`background-image: url('${jt(L)}')`+(0!=I?`;background-position-x:${p*I}px`:""):null));var R=Fn();let z;xi(R,"width",p),xi(R,"height",f),R.__mousedown=function(t){0==t.button&&(window.addEventListener("mousemove",$),window.addEventListener("mouseup",A),_=jt(w).getClientRects()[0],$(t),Y(E,!0))},qi(R,(t=>Y(w,t)),(()=>jt(w))),se((t=>{wi(R,jt(D)),z=fi(R,1,"micrio-minimap",null,z,t)}),[()=>({hidden:!jt(C)||tr(s,"$current",i)!=e.image||h&&(jt(y)||jt(b)),dragging:jt(E),controls:!m})]),Fe("wheel",R,(function(t){l.zoom(t.deltaY*(T?50:1))})),Ye(t,R),_e(),r()}Ve(["mousedown"]);const Un=(null==navigator?void 0:navigator.language)??"en-EN",Bn="Intl"in self&&Intl.DisplayNames?new Intl.DisplayNames([Un],{type:"language"}):void 0,qn=["ar","ar-AE","ar-BH","ar-DJ","ar-DZ","ar-EG","ar-IQ","ar-JO","ar-KW","ar-LB","ar-LY","ar-MA","ar-OM","ar-QA","ar-SA","ar-SD","ar-SY","ar-TN","ar-YE","dv","dv-MV","fa","fa-AF","fa-IR","he","he-IL","iw","iw-PS","kd","ku","ku-IQ","ku-IR","ku-SY","ku-TR","pk-PK","ps","ps-AF","sd","sd-PK","syr-SY","ug","ug-CN","ur","ur-IN","ur-PK","yi","yi-IL","yi-US"];var Wn=We("<div><!></div>");function Xn(t,e){let i=or(e,"className",3,"");var r=Wn();ci(ct(r),(()=>e.children??M)),se((()=>fi(r,1,hi(i()),"micrio-button-group"))),Ye(t,r)}function jn(t,e){Te(e,!0);const[i,r]=ir(),n="requestFullscreen"in e.el,s="webkitRequestFullscreen"in e.el,o=ye("micrio"),a=()=>n?document.fullscreenElement:document.webkitFullscreenElement??null;let l=j(a()===e.el);const c=n||s&&!a(),u=()=>new Promise((t=>setTimeout(t,500)));let d;function h(){jt(l)?async function(){n?(await document.exitFullscreen().then(u),d&&d instanceof HTMLElement&&d.requestFullscreen(),d=void 0):"webkitExitFullscreen"in document&&document.webkitExitFullscreen()}():async function(){n?(d=a(),mr.safari&&d&&await document.exitFullscreen().then(u),e.el.requestFullscreen()):"webkitRequestFullscreen"in e.el&&e.el.webkitRequestFullscreen()}()}const m=e.el==o&&!o.events.scrollHooked,v=()=>{Y(l,a()===e.el),m&&(jt(l)?o.events.hookScroll():o.events.unhookScroll())};c&&Gi((()=>{const t=n?"fullscreenchange":"webkitfullscreenchange";return document.addEventListener(t,v),()=>document.removeEventListener(t,v)}));var p=Ge(),f=ut(p),g=t=>{const e=J((()=>jt(l)?"minimize":"maximize"));zn(t,{get type(){return jt(e)},get title(){return tr(Xr,"$i18n",i).fullscreenToggle},onclick:h})};ei(f,(t=>{c&&t(g)})),Ye(t,p),_e(),r()}var Gn=We("<!> <!>",1);function Yn(t,e){Te(e,!0);const[i,r]=ir(),n=()=>tr(Xr,"$i18n",i);let s=or(e,"image",15,void 0);const o=ye("micrio");let a=j(!1),l=j(!1),c=j(!1);const u=()=>{o.events.clicked=!0},d=()=>{var t;u(),null==(t=s())||t.camera.zoomIn().then((()=>o.events.clicked=!1))},h=()=>{var t;u(),null==(t=s())||t.camera.zoomOut().then((()=>o.events.clicked=!1))};function m(){var t,e;Y(a,(null==(t=s())?void 0:t.camera.isZoomedIn())??!0,!0),Y(l,(null==(e=s())?void 0:e.camera.isZoomedOut(!0))??!0,!0)}let v,p;Gi((()=>(s()?v=s().state.view.subscribe(m):p=o.current.subscribe((t=>{v&&(v(),v=void 0),Y(c,!0),s(t)?br(t.info).then((()=>{s()&&(v=s().state.view.subscribe(m)),Y(c,!1)})):Y(c,!1)})),()=>{p&&p(),v&&v()})));var f=Ge(),g=ut(f),w=t=>{var e=Gn(),i=ut(e);const r=J((()=>jt(c)||jt(a)));zn(i,{type:"zoom-in",get title(){return n().zoomIn},get disabled(){return jt(r)},onclick:d});var s=dt(i,2);const o=J((()=>jt(c)||jt(l)));zn(s,{type:"zoom-out",get title(){return n().zoomOut},get disabled(){return jt(o)},onclick:h}),Ye(t,e)};ei(g,(t=>{jt(a)&&jt(l)||t(w)})),Ye(t,f),_e(),r()}var Hn=We('<menu class="popout micrio-controls"><!> <!></menu>'),Zn=We("<!> <!>",1),Kn=We("<aside><!></aside>"),Jn=We('<aside class="micrio-controls"><!> <!> <!> <!></aside> <!>',1);function Qn(t,e){Te(e,!0);const[i,r]=ir(),n=()=>tr(m,"$current",i),s=()=>tr(jt(k),"$info",i),o=()=>tr(f,"$_lang",i),a=()=>tr(g,"$tour",i),l=()=>tr(b,"$zoom",i),c=()=>tr(p,"$isMuted",i),u=()=>tr(Xr,"$i18n",i);let d=or(e,"hasAudio",3,!1);const h=B(ye("micrio")),{current:m,state:v,isMuted:p,_lang:f}=h,g=v.tour,{controls:w,zoom:b,hidden:y}=h.state.ui;let k=J((()=>{var t;return null==(t=n())?void 0:t.info})),T=J((()=>{var t;return s()&&n()?n().isV5?Object.keys(s().revision??{[o()]:0}):(null==(t="cultures"in s()?s().cultures:"")?void 0:t.split(","))??[]:[]})),_=J((()=>a()&&"steps"in a()&&a().isSerialTour));function x(){var t,e,i;if(navigator.share&&(null==(t=n())?void 0:t.$info)){const t=n().$data?(null==(e=n().$data)?void 0:e.i18n)?n().$data.i18n[o()]:n().$data:void 0;navigator.share({title:null==(i=n().$info)?void 0:i.title,text:(null==t?void 0:t.description)||`${n().$info.width} x ${n().$info.height} | Micrio`,url:location.href})}}let E=j(null),$=j(!1);function A(t){const e=t.detail;Y($,h.canvas.viewport.portrait,!0),e.opts.isPassive||Y(E,e,!0)}function S(){Y(E,null)}let I=j(!1),M=j(!1),L=j(!1);function P(t){var e,i;b.set(!t.noZoom),w.set(!t.noControls),Y(I,!!(null==(i=null==(e=t.ui)?void 0:e.controls)?void 0:i.cultureSwitch)),Y(M,!!t.social),Y(L,!!t.fullscreen)}n()&&P(n().$settings),Gi((()=>{let t;h.addEventListener("splitscreen-start",A),h.addEventListener("splitscreen-stop",S);const e=h.current.subscribe((e=>{e&&br(e.info).then((i=>{!i||a()&&"steps"in a()||(null==t||t(),t=e.settings.subscribe(P))}))}));return()=>{h.removeEventListener("splitscreen-start",A),h.removeEventListener("splitscreen-stop",S),null==t||t(),e()}}));let C=J((()=>"micrioAudioContext"in window||d())),D=J((()=>jt(I)&&jt(T).length>1)),R=J((()=>jt(M)&&"share"in navigator)),z=J((()=>jt(L)&&!jt(_))),O=J((()=>tr(w,"$controls",i)&&!tr(y,"$hidden",i)&&(jt(C)||jt(D)||jt(R)||l()||jt(z))));var N=Ge(),F=ut(N),V=t=>{var e=Jn(),i=ut(e),r=ct(i),n=t=>{const e=J((()=>c()?"volume-off":"volume-up")),i=J((()=>c()?u().audioUnmute:u().audioMute));zn(t,{get type(){return jt(e)},get title(){return jt(i)},onclick:()=>p.set(!c())})};ei(r,(t=>{jt(C)&&t(n)}));var s=dt(r,2),a=t=>{var e=Hn(),i=ct(e);zn(i,{get title(){return u().switchLanguage},type:"a11y"}),ri(dt(i,2),17,(()=>jt(T)),ii,((t,e)=>{const i=J((()=>(null==Bn?void 0:Bn.of(jt(e)))??jt(e))),r=J((()=>jt(e)==o()));zn(t,{onclick:()=>h.lang=jt(e),get title(){return jt(i)},get active(){return jt(r)},children:(t,i)=>{var r=je();se((t=>Ke(r,t)),[()=>jt(e).toUpperCase()]),Ye(t,r)},$$slots:{default:!0}})})),Ye(t,e)};ei(s,(t=>{jt(D)&&t(a)}));var d=dt(s,2),m=t=>{zn(t,{type:"share",get title(){return u().share},onclick:x})};ei(d,(t=>{jt(R)&&t(m)})),Xn(dt(d,2),{children:(t,e)=>{var i=Zn(),r=ut(i),n=t=>{var e=Ge(),i=ut(e),r=t=>{Yn(t,{get image(){return jt(E)}})},n=t=>{Yn(t,{})};ei(i,(t=>{jt(E)?t(r):t(n,!1)})),Ye(t,e)};ei(r,(t=>{l()&&t(n)}));var s=dt(r,2),o=t=>{jn(t,{get el(){return h}})};ei(s,(t=>{jt(z)&&t(o)})),Ye(t,i)},$$slots:{default:!0}});var v=dt(i,2),f=t=>{var e=Kn();let i;Xn(ct(e),{children:(t,e)=>{Yn(t,{})},$$slots:{default:!0}}),se((t=>i=fi(e,1,"primary micrio-controls",null,i,t)),[()=>({portrait:jt($)})]),zi(3,e,(()=>Nr)),Ye(t,e)};ei(v,(t=>{l()&&jt(E)&&t(f)})),Ye(t,e)};ei(F,(t=>{jt(O)&&t(V)})),Ye(t,N),_e(),r()}class ts{constructor(t,e){var i;this.image=t,this.data=e,this.timeline=[],this._paused=!0,this.playing=!1,this.wasPaused=!1,this.unhookEvents=!1,this.micrio=t.wasm.micrio,this.initialView=t.camera.getView();const r="timeline"in e?e:(null==(i=e.i18n)?void 0:i[Ki(this.micrio._lang)])??void 0;if(!r)throw new Error("No valid content for video tour!");this.content=r,this.unhookEvents=!e.keepInteraction&&this.micrio.events.$enabled,e.instance=this,this.read(),this.micrio.events.dispatch("videotour-start",this.data)}destroy(){this.unhookEvents&&this.micrio.events.enabled.set(!0),this.playing&&(this.image.camera.stop(),this.micrio.removeAttribute("data-videotour-playing"),this.micrio.events.dispatch("videotour-stop",this.data),this.playing=!1,delete this.startedAt,delete this.data.instance,this.startAt=void 0,clearTimeout(this._to))}read(){const t=!!this.data.i18n?1:this.content.duration,e=this.content.timeline;this.timeline.length=0;for(let i=0;i<e.length;i++){const r=e[i],n=e[i-1],s=n?n.end*t:0;this.timeline.push({view:r.rect,start:1e3*s,duration:1e3*(r.start*t-s),pauseDuration:(r.end-r.start)*t*1e3})}this.startedAt&&!this.playing&&(this.progress=this.currentTime)}get duration(){return Number(this.content.duration)}set duration(t){this.content.duration=t}get paused(){return this._paused}get ended(){return this.currentTime>=this.duration}get currentTime(){return(this.pausedAt?this.pausedAt:this.startedAt?Date.now()-this.startedAt:0)/1e3}set currentTime(t){this.setProgress(t/this.content.duration)}get progress(){return this.currentTime/this.content.duration}set progress(t){this.setProgress(t)}play(){this.startedPlaying(),this.wasPaused=!1,this.pausedAt?(this.startedAt=Date.now()-this.pausedAt,this._paused=!1,this.gotoTime(this.pausedAt),this.pausedAt=void 0):this.playing||(this.startedAt=Date.now(),void 0===this.startAt?this.gotoStep(0,0):this.gotoTime(this.duration*this.startAt*1e3),this.startAt=void 0),this._paused=!1,this.playing=!0}pause(){this._paused||null==this.currentIndex||null==this.startedAt||(this._paused=!0,this.stoppedPlaying(),clearTimeout(this._to),this.currentIndex>=0&&this.image.camera.stop(),this.ended?this.reset():this.pausedAt=Date.now()-this.startedAt)}reset(){this.stoppedPlaying(),this.pausedAt=void 0,this.playing=!1,this.read()}gotoStep(t,e){if(null==this.startedAt)return;if(clearTimeout(this._to),!this.timeline[t]){if(!this.paused||!this.wasPaused){const t=Math.max(0,Math.round(1e3*this.duration-(Date.now()-this.startedAt)));this._to=setTimeout((()=>this.pause()),t)}return}const i=this.timeline[t],r=Math.round(i.start-(Date.now()-this.startedAt));this.currentIndex=t,this.image.camera.stop(),r>0?this._paused||(this._to=setTimeout((()=>this.startAni(e)),r)):this.startAni(e)}nextStep(){null!=this.currentIndex&&this.gotoStep(this.currentIndex+1)}getView(t){const e=this.timeline[t];return null==e?this.initialView??this.image.camera.getView():e.view}startAni(t=0){var e;if(null==this.currentIndex||isNaN(t))return;const i=this.timeline[this.currentIndex];if(null==i)return;const r=i.view,n=this.getView(this.currentIndex-1),s=null==(e=this.image.opts)?void 0:e.area;if(this.wasPaused&&n){const e=this.micrio.wasm.e.ease(t);this.image.camera.setView([n[0]*(1-e)+r[0]*e,n[1]*(1-e)+r[1]*e,n[2]*(1-e)+r[2]*e,n[3]*(1-e)+r[3]*e],{noLimit:!0,area:s}),this.nextStep()}else this.image.camera.flyToView(r,{duration:i.duration,progress:t,prevView:n,area:s}).then((()=>{null!=this.currentIndex&&i==this.timeline[this.currentIndex]&&this.nextStep()})).catch((()=>{}))}startedPlaying(){this.micrio.setAttribute("data-videotour-playing",""),this.micrio.events.dispatch("videotour-play"),this.unhookEvents&&this.micrio.events.enabled.set(!1)}stoppedPlaying(){this.micrio.removeAttribute("data-videotour-playing"),this.micrio.events.dispatch("videotour-pause"),this.unhookEvents&&this.micrio.events.enabled.set(!0)}setProgress(t){t=Math.max(0,Math.min(1,t)),this.wasPaused=!!this.paused||!this.playing,this.pause(),this.wasPaused||(this._paused=!1,this.startedPlaying());const e=this.duration*t*1e3;this.pausedAt=e,this.gotoTime(e),this.wasPaused?this.pause():(this.pausedAt=void 0,this._paused=!1)}gotoTime(t){let e=null,i=0;for(;i<this.timeline.length&&!(this.timeline[i].start>t);i++)e=this.timeline[i];if(i--,e||!(i>0))if(e){this.image.camera.stop();const r=e.duration>0?(t-e.start)/e.duration:0;this.startedAt=Date.now()-e.start-e.duration*r,isNaN(this.startedAt)&&(this.startedAt=Date.now()-t),r>1?(this.gotoStep(i+1),null!=e.view&&this.image.camera.setView(e.view,{noLimit:!0})):(i>0&&this.image.camera.setView(this.timeline[i-1].view,{noLimit:!0}),this.gotoStep(i,r))}else this.timeline.length&&this.image.camera.stop(),this.paused||this.gotoStep(0)}}window.MicrioVideoTour=ts;var es=(t=>(t[t.None=0]="None",t[t.IFrame=1]="IFrame",t[t.Video=2]="Video",t[t.Audio=3]="Audio",t[t.VideoTour=4]="VideoTour",t[t.Micrio=5]="Micrio",t))(es||{}),is=(t=>(t[t.YouTube=1]="YouTube",t[t.Vimeo=2]="Vimeo",t))(is||{});const rs="micrio-captions-disable",ns=Zi("1"!=localStorage.getItem(rs));ns.subscribe((t=>{t?localStorage.removeItem(rs):localStorage.setItem(rs,"1")}));var ss=We('<div><p class="micrio-subtitles"> </p></div>');function os(t,e){Te(e,!0);const[i,r]=ir();let n=or(e,"raised",3,!1);const s=[];fetch(e.src).then((t=>t.text())).then((t=>{const e=t.split("\n");for(let i=0;i<e.length;i++)if(/-->/.test(e[i])){let t=i+1;const r=[];for(;!e[t]&&t<e.length;)t++;for(;e[t]&&e[t].trim();)r.push(e[t++]);const[n,o]=e[i].split(" --\x3e ").map((t=>t.trim().replace(",",".").split(":").map(Number))).map((t=>3600*t[0]+60*t[1]+t[2]));s.push({start:n,end:o,data:r.join("\n")}),i+=r.length+1}}));const o=ye("micrio");let a=j(0);const l=t=>Y(a,t.detail,!0);Gi((()=>(o.addEventListener("timeupdate",l),()=>o.removeEventListener("timeupdate",l))));let c=J((()=>s.filter((t=>t.start<=jt(a)&&t.end>=jt(a)))));var u=Ge(),d=ut(u),h=t=>{var e=Ge();ri(ut(e),16,(()=>jt(c)),(t=>t),((t,e)=>{var i=ss();let r;var s=ct(i),o=ct(s);se((t=>{r=fi(i,1,"micrio-subtitles",null,r,t),Ke(o,e.data)}),[()=>({raised:n()})]),zi(3,i,(()=>Nr)),Ye(t,i)})),Ye(t,e)};ei(d,(t=>{tr(ns,"$captionsEnabled",i)&&t(h)})),Ye(t,u),_e(),r()}var as=t=>t.stopPropagation(),ls=t=>t.stopPropagation(),cs=We('<div class="container micrio-progress-bar"><div class="bars micrio-progress-bar"><!></div> <div class="time micrio-progress-bar"> </div></div>');function us(t,e){Te(e,!0);let i=or(e,"ended",11,!1);var r=cs();r.__click=[as],r.__keydown=[ls];var n=ct(r);ci(ct(n),(()=>e.children??M));var s=ct(dt(n,2));se(((t,e)=>{wi(r,t),Ke(s,e)}),[()=>`--progress: ${Math.round((e.currentTime??0)/e.duration*1e4)/100}%;--time: '${wr(e.currentTime??0)}';`,()=>wr(i()||!e.currentTime||e.currentTime<=0?e.duration:(e.currentTime??0)-e.duration)]),Ye(t,r),_e()}Ve(["click","keydown"]);var ds=t=>t.stopPropagation(),hs=t=>t.stopPropagation(),ms=Xe('<svg height="42" width="42" class="micrio-media-controls"><circle r="19" cx="21" cy="21" class="micrio-media-controls"></circle></svg>'),vs=We("<!> <!> <!>",1),ps=We('<div class="bar active"></div>'),fs=We('<aside class="micrio-media-controls"><!> <!></aside> <!>',1);function gs(t,e){Te(e,!0);let i=or(e,"currentTime",11,0);const r=ye("micrio");e.events.forEach((t=>{t.start=Number(t.start||0),t.end=Math.min(Number(t.end||0),e.duration)}));const n=t=>e.events.forEach((e=>{const i=e.start<=t&&e.end>=t;i!=!!e.active&&(e.active=i,r.events.dispatch("tour-event",{...e}))}));var s;ee((()=>{n(i())})),s=()=>n(1/0),null===we&&ge(),Gi((()=>()=>Gt(s))),_e()}Ve(["click","keydown","mousedown"]);const ws=new Audio;var bs=(t,e,i)=>{t.target==jt(e)&&i(t)},ys=We("<iframe></iframe>"),ks=We('<source type="video/mp4;codecs=hvc1">'),Ts=We("<!> <source>",1),_s=We('<video playsinline="" class="micrio-media"><!></video>',2),xs=We("<audio></audio>"),Es=We("<micr-io></micr-io>",2),$s=We("<aside><!></aside>"),As=We('<figcaption class="micrio-media"><!></figcaption>'),Ss=We('<div class="show-play micrio-media"><!></div>'),Is=We("<figure><div><!> <!> <!></div> <!></figure> <!>",1);function Ms(t,e){var i,r,n,s,o,a,l;Te(e,!0);const[c,u]=ir(),d=()=>tr(X,"$_lang",c),h=ye("micrio");let m=or(e,"src",15,void 0),v=or(e,"volume",15,1),p=or(e,"width",3,640),f=or(e,"height",3,380),g=or(e,"frameScale",3,1),w=or(e,"autoplay",15,!1),b=or(e,"loop",3,!1),y=or(e,"loopDelay",3,void 0),k=or(e,"controls",15,!1),T=or(e,"title",3,void 0),_=or(e,"figcaption",3,null),x=or(e,"paused",15,!0),E=or(e,"forcePause",3,void 0),$=or(e,"seeking",15,!0),A=or(e,"duration",31,(()=>-1)),S=or(e,"currentTime",15),I=or(e,"muted",31,(()=>0==v())),M=or(e,"is360",3,!1),L=or(e,"tour",3,null),P=or(e,"secondary",3,!1),C=or(e,"fullscreen",3,void 0),D=or(e,"className",3,null),R=or(e,"hasTransparentH265",3,!1),z=or(e,"noPlayOverlay",3,!1),O=or(e,"uuid",15,""),N=or(e,"image",19,(()=>Ki(h.current))),F=or(e,"_media",15,void 0);const V=I();O(O()+(m()??(null==(i=L())?void 0:i.id)));const U=N().$info,{events:q,state:W,_lang:X}=h,G=ye("volume"),H=0==tr(G,"$mainVolume",c),Z=ye("srt");let K;const Q=W.mediaState.get(O());Q&&(S(Q.currentTime),w(!x(Q.paused))),W.mediaState.set(O(),{get currentTime(){return S()??0},set currentTime(t){Rt(t)},get paused(){return x()},set paused(t){t?Dt():Ct()}}),m()&&/<iframe /.test(m())&&m(m().replace(/^.* src="([^"]+)".*$/,"$1")),(null==(r=m())?void 0:r.startsWith("video://"))&&m(m().replace("video:","https:"));const tt="https://www.youtube-nocookie.com";let et=j(B(m()));const it=m()&&m().startsWith("cfvid://"),rt=m()&&m().toLowerCase(),nt=rt?rt.endsWith("mp3")?es.Audio:rt.endsWith(".mp4")||rt.endsWith(".webm")||it?es.Video:rt.startsWith("micrio://")?es.Micrio:rt.startsWith("http")?es.IFrame:es.None:L()?es.VideoTour:es.None,st=nt==es.Micrio?null==(n=m())?void 0:n.slice(9).split(","):null;let ot,at,lt,ht;st&&x(!1);let mt=-1,vt=j(!1);const pt=nt==es.Audio&&mr.iOS;let ft=j(void 0);const gt=h.hasAttribute("data-native-frame"),wt=m()&&/((?:https?:)?\/\/)?((?:www|m)\.)?((?:youtube\.com|youtu.be|youtube-nocookie\.com))(\/(?:[\w\-]+\?v=|embed\/|v\/)?)([\w\-]+)(\S+)?/.exec(m()),bt=/^.*t=(\d+).*$/;if(m()&&!gt&&wt&&wt[5])if("playlist"==wt[5]){const t=/list=([^&]+)/.exec(m());(null==t?void 0:t[1])&&Y(et,`${tt}/embed/videoseries?list=${t[1]}`)}else{ot=is.YouTube;const t=Math.round((bt.test(m())?Number(m().replace(bt,"$1")):S())??0);Y(et,`${tt}/embed/${wt[5]}?autoplay=0&enablejsapi=1&controls=0&start=${t}`),Y(vt,!0)}if(!gt&&m()&&/vimeo\.com/.test(m())){const t=m().match(/\/(\d+)/);if(t&&t[1]){const e=m().slice(m().indexOf(t[1])+t[1].length+1).replace(/\?.*$/,"");ot=is.Vimeo,Y(et,`https://player.vimeo.com/video/${t[1]}?${e?`h=${e}&`:""}title=0&portrait=0&sidedock=0&byline=0&controls=0#t=`+Math.round(S()??0)+"s"),Y(vt,!0)}}let yt;it&&m()&&(yt=`https://videodelivery.net/${m().slice(8)}/manifest/video.m3u8`,Y(et,void 0));let kt=j(void 0);if(L()){const t=new ts(N(),L());null!=S()&&S()>0&&(t.currentTime=S()),nt==es.VideoTour&&(A("duration"in L()?Number(L().duration):(null==(o=null==(s=L().i18n)?void 0:s[d()])?void 0:o.duration)??0),v(NaN)),Y(kt,t,!0)}(nt==es.Micrio||nt==es.IFrame&&!ot)&&k(!1);const Tt=L()&&!("steps"in L())?"subtitle"in L()?L().subtitle:null==(l=null==(a=L().i18n)?void 0:a[h.lang])?void 0:l.subtitle:void 0,_t=Tt&&("fileUrl"in Tt?Tt.fileUrl:Tt.src);function xt(){$(!1),M()&&N()&&!N()._video&&N().video.set(F())}let Et=j(!1);function $t(){Y(Et,!1),x(!1),jt(kt)&&F()&&(jt(kt).duration=F().duration,jt(kt).currentTime=F().currentTime,jt(kt).play())}function At(t){t&&"button"in t&&0!=t.button||(x()?Ct():Dt())}const St=async()=>F()?F().paused:jt(kt)?x():at?[-1,0,2].indexOf(at.getPlayerState())>=0:ot==is.YouTube?x():!!lt&&await lt.getPaused();let It=j(!1),Mt=!1;const Lt=ye("mediaPaused");let Pt;async function Ct(t){var i,r,n,s;if(!(t&&t instanceof PointerEvent&&0!=t.button)&&(!Mt||await St())){switch(Y(Nt,!1),A()>0&&null!=S()&&S()>=A()&&S(0),!P()&&_t&&Z.set(_t),nt){case es.VideoTour:x($(!1)),null==(i=jt(kt))||i.play(),Vt();break;case es.Audio:case es.Video:null==(r=F())||r.addEventListener("play",$t,{once:!0}),null==(n=F())||n.play().catch((t=>{var i;z()?x(!0):/pause\(\)/.test(t.toString())||(Y(Et,!0),h.events.dispatch("media-blocked"),null==(i=e.onblocked)||i.call(e))}));break;case es.IFrame:switch(ot){case is.YouTube:at&&at.playVideo();break;case is.Vimeo:lt&&lt.play()}break;default:return}Mt=!0,q.dispatch("media-play"),Lt.set(!1),null==(s=e.onplay)||s.call(e),M()||H||jt(kt)&&!F()||G.set(N().$settings.mutedVolume||0)}}function Dt(){q.dispatch("media-pause"),Lt.set(!0),F()?(F().pause(),pt&&x(!0)):jt(kt)?(jt(kt).pause(),x(!0),Ut()):(null==at?void 0:at.pauseVideo)&&!jt(Xt)?at.pauseVideo():(null==lt?void 0:lt.pause)&&lt.pause()}function Rt(t){$(!0),F()?F(F().currentTime=t,!0):jt(kt)?(S(jt(kt).currentTime=t),$(!1)):(null==at?void 0:at.seekTo)?at.seekTo(t):(null==lt?void 0:lt.setCurrentTime)&&lt.setCurrentTime(t)}function zt(){jt(kt)?(S(jt(kt).currentTime),jt(kt).ended&&Ft()):(null==at?void 0:at.getCurrentTime)&&S(at.getCurrentTime()),Ot()}function Ot(){P()||q.dispatch("timeupdate",S())}let Nt=j(!1);function Ft(){var t;jt(Nt)||(jt(kt)?Dt():(x(!0),Ut()),Y(Nt,!0),q.dispatch("media-ended"),null==(t=e.onended)||t.call(e),Wt())}function Vt(){mt>=0||(mt=setInterval(zt,250),zt())}function Ut(){clearInterval(mt),mt=-1}async function Bt(){if(it&&!Dr(F()))return gr("https://i.micr.io/hls-1.5.17.min.js",void 0,"Hls"in window?{}:void 0).then((()=>{ht=new window.Hls,ht.loadSource(yt),F()&&ht.attachMedia(F())}));if(nt==es.IFrame){if(ot==is.YouTube)return async function(){if(!at){if(window.YT||await gr("https://i.micr.io/youtube.js","onYouTubeIframeAPIReady"),window.YT)return $(!0),new Promise(((t,e)=>{at=new window.YT.Player(jt(ft),{host:tt,width:jt(ie).toString(),height:jt(re).toString(),playerVars:{controls:0},events:{onError:e,onReady:()=>{jt(Xt)?e():(I(at.isMuted()),A(at.getDuration()),$(!1),t())},onStateChange:t=>{switch(t.data){case-1:Y(It,x(!0),!0),Ut();break;case 0:Ft();break;case 1:Vt(),Y(It,x($(!1)),!0);break;case 2:x(!0),Ut();break;case 3:zt(),$(!0),Ut()}}}})}));Y(vt,!1)}}();if(ot==is.Vimeo)return async function(){if(!lt){if(window.Vimeo||await gr("https://i.micr.io/vimeo.min.js"),window.Vimeo)return $(!0),new Promise(((t,e)=>{const i=lt=new window.Vimeo.Player(jt(ft),{width:jt(ie).toString(),height:jt(re).toString(),title:!1,autoplay:!1});i.on("error",e),i.on("loaded",(()=>i.getVolume().then((i=>{jt(Xt)?e():(I(0==v(i)),t())})))),i.on("play",(()=>x($(!1)))),i.on("bufferstart",(()=>$(!0))),i.on("seeked",(()=>{$(!1)})),i.on("pause",(()=>x(!0))),i.on("volumechange",(t=>{t&&I(0==v(t.volume))})),i.on("timeupdate",(t=>{t&&(A(t.duration),S(t.seconds))})),i.on("ended",Ft)}));Y(vt,!1)}}()}else F()&&(it&&Y(et,yt,!0),function(){if(!F())return;F(F().ontimeupdate=Ot,!0),jt(kt)&&(F(F().onpause=()=>jt(kt).pause(),!0),F(F().onseeked=()=>{F()&&!F().ended&&(jt(kt).currentTime=F().currentTime,qt&&(F().pause(),qt=!1))},!0));null!=S()&&S()>0&&(F().duration>0?F(F().currentTime=S(),!0):F(F().oncanplay=()=>{F()&&(F(F().oncanplay=null,!0),w()||(F().play(),qt=!0),F(F().currentTime=K,!0))},!0));const t=b()&&void 0!==y()?y():-1;F(F().onended=t>=0?()=>{clearTimeout(Pt),Pt=setTimeout((()=>{var t;E()||null==(t=F())||t.play()}),1e3*t)}:Ft,!0)}())}let qt=!1;function Wt(){H||G.set(1)}let Xt=j(!1);const Gt=()=>{var t;return S((null==(t=F())?void 0:t.currentTime)??0)};const Yt=nt==es.Video;let Ht=j(B(Yt&&it&&1!=g()&&mr.iOS));Gi((()=>{var t,i;null==(t=e.onid)||t.call(e,O()),m()&&pt&&(F(ws),F(F().controls=!1,!0),F(F().onloadedmetadata=()=>{var t;return A((null==(t=F())?void 0:t.duration)??0)},!0),F(F().src=m(),!0),F(F().oncanplay=xt,!0),F(F().onended=Ft,!0),F().addEventListener("timeupdate",Gt),F(F().onseeking=()=>$(!0),!0),F(F().onseeked=()=>$(!1),!0)),K=S()||0,Y(vt,ot==is.YouTube||ot==is.Vimeo,!0),Bt().then((()=>{w()&&Ct()})).catch((()=>{})),jt(Ht)&&(null==(i=F())||i.addEventListener("playing",(()=>Y(Ht,!1)),{once:!0}));const r=h.isMuted.subscribe((t=>function(t){V||(I(t),F()?F(F().muted=t,!0):(null==at?void 0:at.mute)?(t?at.mute():at.unMute(),setTimeout((()=>{at&&I(at.isMuted())}),50)):lt&&lt.setVolume(t?0:1))}(t)));return()=>{!function(){if(!jt(Xt)){if(Y(Xt,!0),M()&&N()&&N().video.set(void 0),W.mediaState.delete(O()),Ut(),Dt(),Wt(),_t&&Z.set(void 0),F()&&(F(F().onended=null,!0),pt&&(F(F().onloadedmetadata=F(F().onplay=F(F().onseeking=F(F().onseeked=null,!0),!0),!0),!0),F().removeEventListener("timeupdate",Gt)),F(F().ontimeupdate=F(F().onpause=F(F().onseeked=F(F().oncanplay=null,!0),!0),!0),!0)),jt(kt))jt(kt).destroy();else if(lt)for(let t of["error","loaded","play","bufferstart","seeked","pause","volumechange","timeupdate","ended"])lt.off(t);ht?ht.destroy():at?at.destroy():lt&&lt.destroy()}}(),r(),pt&&F(void 0),ht?ht.destroy():at?at.destroy():lt&&lt.destroy()}})),ee((()=>{F()&&nt==es.Video&&!I()&&F(F().muted=0==v(),!0)})),ee((()=>{void 0!==E()&&x(E())})),ee((()=>{b()&&void 0!==y()&&clearTimeout(Pt)}));let Zt=J((()=>{var t,e;return jt(kt)&&L()?"events"in L()?L().events:(null==(e=null==(t=L().i18n)?void 0:t[d()])?void 0:e.events)??void 0:void 0})),Kt=j(void 0),Jt=j(void 0);const Qt=U.is360?Math.PI/2:1;let te=J((()=>Yt?g()*Qt:nt==es.IFrame?Math.max(g(),Math.min(p()/512,f()/512)):1)),ie=J((()=>Yt?p():Math.round(p()/jt(te)*Qt))),re=J((()=>Yt?f():Math.round(f()/jt(te)*Qt)));var ne=Ge(),oe=ut(ne),ae=t=>{var e=Is(),i=ut(e);let r;wi(i,null);var n=ct(i);let s;n.__pointerup=[bs,Jt,At];var o=ct(n),a=t=>{var e=ys();let i;qi(e,(t=>Y(ft,t)),(()=>jt(ft))),se(((t,r)=>i=$i(e,i,{...t,title:T(),src:jt(et),width:jt(ie),height:jt(re),frameborder:"0",allow:"fullscreen *;autoplay *;encrypted-media *",[bi]:r},"micrio-media")),[()=>({credentialless:!0}),()=>({hooked:jt(vt)&&!jt(It)})]),Ye(t,e)},l=(t,e)=>{var i=t=>{var e=_s();e.controls=!1;var i=ct(e),r=t=>{var e=Ts(),i=ut(e),r=t=>{var e=ks();se((t=>xi(e,"src",t)),[()=>jt(et).replace(".webm",".mp4")]),Ye(t,e)};ei(i,(t=>{R()&&jt(et).endsWith(".webm")&&t(r)}));var n=dt(i,2);xi(n,"type",it?"application/x-mpegURL":void 0),se((()=>xi(n,"src",jt(et)))),Ye(t,e)};ei(i,(t=>{jt(et)&&t(r)})),qi(e,(t=>F(t)),(()=>F())),se((()=>{e.loop=b()&&(null==y()||y()<=0),xi(e,"width",p()),xi(e,"height",f()),wi(e,jt(Ht)?"opacity: 0":void 0),e.autoplay=!!w()})),Fe("canplay",e,xt),Fe("ended",e,Ft),Wi("duration","durationchange",e,A),Ui(e,I),Ni(e,S),Fi(e,$),Vi(e,x),Ye(t,e)},r=(t,e)=>{var i=t=>{var e=xs();e.controls=!1,qi(e,(t=>F(t)),(()=>F())),se((()=>xi(e,"src",jt(et)))),Fe("canplay",e,(()=>$(!1))),Fe("ended",e,Ft),Wi("duration","durationchange",e,A),Ui(e,I),Ni(e,S),Fi(e,$),Vi(e,x),Ye(t,e)},r=(t,e)=>{var i=t=>{var e=Es();Ei(e,"data-logo","false"),se((()=>Ei(e,"id",st[0]))),se((()=>Ei(e,"width",st[1]))),se((()=>Ei(e,"height",st[2]))),se((()=>Ei(e,"lang",st[3]))),se((()=>Ei(e,"data-path",U.path))),Ye(t,e)};ei(t,(t=>{nt==es.Micrio&&st&&t(i)}),e)};ei(t,(t=>{nt!=es.Audio||pt?t(r,!1):t(i)}),e)};ei(t,(t=>{nt==es.Video?t(i):t(r,!1)}),e)};ei(o,(t=>{nt==es.IFrame?t(a):t(l,!1)}));var u=dt(o,2),d=t=>{gs(0,{get events(){return jt(Zt)},get currentTime(){return S()},set currentTime(t){S(t)},get duration(){return A()},set duration(t){A(t)}})};ei(u,(t=>{var e;(null==(e=jt(Zt))?void 0:e.length)&&A()>0&&!jt(Xt)&&t(d)}));var m=dt(u,2),g=t=>{var e=$s();let i;var r=ct(e);const n=J((()=>M()||nt!=es.IFrame&&nt!=es.Video?C():jt(Kt)));!function(t,e){Te(e,!0);const[i,r]=ir(),n=()=>tr(Xr,"$i18n",i),s=()=>tr(ns,"$captionsEnabled",i);let o=or(e,"currentTime",15),a=or(e,"duration",11,0),l=or(e,"seeking",11,!0),c=or(e,"muted",11,!1),u=or(e,"minimal",3,!1),d=or(e,"ended",15),h=or(e,"fullscreen",3,void 0),m=or(e,"subtitles",3,!1),v=J((()=>!isNaN(e.volume))),p=j(void 0);function f(t){0==t.button&&(window.addEventListener("mousemove",g),window.addEventListener("mouseup",w),g(t))}function g(t){var i;const r=jt(p).getClientRects()[0],n=Math.min(1,Math.max(0,(t.clientX-r.left)/r.width));null==(i=e.onseek)||i.call(e,n*a())}function w(){window.removeEventListener("mousemove",g),window.removeEventListener("mouseup",w)}var b=fs(),y=ut(b);y.__click=[ds],y.__keydown=[hs];var k=ct(y);const T=J((()=>e.paused?"play":"pause")),_=J((()=>e.paused?n().play:n().pause));zn(k,{get type(){return jt(T)},get title(){return jt(_)},get onclick(){return e.onplaypause},children:(t,e)=>{var i=Ge(),r=ut(i),n=t=>{var e=ms(),i=ct(e);se((()=>xi(i,"stroke-dashoffset",119.4*(1-o()/a())))),Ye(t,e)};ei(r,(t=>{u()&&void 0!==o()&&o()>0&&t(n)})),Ye(t,i)},$$slots:{default:!0}});var x=dt(k,2),E=t=>{var i=vs(),r=ut(i),o=t=>{const i=J((()=>c()?"volume-off":"volume-up")),r=J((()=>c()?n().audioUnmute:n().audioMute));zn(t,{get disabled(){return l()},get type(){return jt(i)},get title(){return jt(r)},get onclick(){return e.onmute}})};ei(r,(t=>{jt(v)&&t(o)}));var a=dt(r,2),u=t=>{const e=J((()=>s()?"subtitles":"subtitles-off"));zn(t,{get type(){return jt(e)},get active(){return s()},get title(){return n().subtitlesToggle},onclick:()=>ns.set(!s())})};ei(a,(t=>{m()&&t(u)}));var d=dt(a,2),p=t=>{jn(t,{get el(){return h()}})};ei(d,(t=>{h()&&t(p)})),Ye(t,i)};ei(x,(t=>{u()||t(E)}));var $=dt(y,2),A=t=>{us(t,{get duration(){return a()},get currentTime(){return o()},set currentTime(t){o(t)},get ended(){return d()},set ended(t){d(t)},children:(t,e)=>{var i=ps();i.__mousedown=f,qi(i,(t=>Y(p,t)),(()=>jt(p))),se((()=>wi(i,`--progress:${(o()??0)/a()*100}%;`))),Ye(t,i)},$$slots:{default:!0}})};ei($,(t=>{u()||t(A)})),Ye(t,b),_e(),r()}(r,{subtitles:!!_t,get fullscreen(){return jt(n)},onplaypause:At,onmute:()=>h.isMuted.set(!I()),onseek:t=>Rt(t),get paused(){return x()},set paused(t){x(t)},get seeking(){return $()},set seeking(t){$(t)},get duration(){return A()},set duration(t){A(t)},get currentTime(){return S()},set currentTime(t){S(t)},get muted(){return I()},set muted(t){I(t)},get volume(){return v()},set volume(t){v(t)},get ended(){return jt(Nt)},set ended(t){Y(Nt,t,!0)}}),se((t=>i=fi(e,1,"micrio-media",null,i,t)),[()=>({inside:"inside"==k()})]),Ye(t,e)};ei(m,(t=>{k()&&t(g)})),qi(n,(t=>Y(Jt,t)),(()=>jt(Jt)));var E=dt(n,2),L=t=>{var e=As();li(ct(e),_),Ye(t,e)};ei(E,(t=>{_()&&t(L)})),qi(i,(t=>Y(Kt,t)),(()=>jt(Kt)));var P=dt(i,2),z=t=>{var e=Ss();e.__pointerup=Ct,zn(ct(e),{get title(){return tr(Xr,"$i18n",c).play},type:"play"}),Ye(t,e)};ei(P,(t=>{jt(Et)&&t(z)})),se(((t,e)=>{r=fi(i,1,hi(D()),"micrio-media",r,t),wi(n,1==jt(te)||nt!=es.Video&&U.is360?"":`transform:scale(${jt(te)})`),s=fi(n,1,"micrio-media",null,s,e)}),[()=>({paused:x(),is360:M(),"media-video":nt==es.IFrame||nt==es.Video,"media-micrio":nt==es.Micrio}),()=>({videotour:!!jt(kt)})]),Ye(t,e)};ei(oe,(t=>{N().$settings.noUI||t(ae)})),Ye(t,ne),_e(),u()}Ve(["pointerup"]);var Ls=t=>t.stopPropagation(),Ps=We("<article><!></article>");function Cs(t,e){Te(e,!0);let i=or(e,"cn",3,null);function r(t){var e;t.target&&t.target instanceof HTMLAnchorElement&&!(null==(e=t.target.getAttribute("href"))?void 0:e.startsWith("#"))&&(t.target.target="_blank")}var n=Ps();n.__click=[Ls],n.__keydown=r,n.__pointerdown=r,ci(ct(n),(()=>e.children??M)),se((()=>fi(n,1,hi(i()),"micrio-article"))),Ye(t,n),_e()}Ve(["click","keydown","pointerdown"]);var Ds=We('<h1 class="micrio-marker-content"> </h1>'),Rs=We('<figcaption class="micrio-marker-content"> </figcaption>'),zs=We('<button class="micrio-marker-content"><figure class="micrio-marker-content"><img class="micrio-marker-content"> <!></figure></button>'),Os=We('<section class="micrio-marker-content"></section>'),Ns=We("<!> <!>",1),Fs=We("<main><!> <!> <!> <!> <!> <!> <!></main>");function Vs(t,e){var i,r,n;Te(e,!0);const[s,o]=ir(),a=()=>tr(f,"$tour",s),l=()=>tr(p,"$lang",s);let c=or(e,"noEmbed",3,!1),u=or(e,"noImages",3,!1),d=or(e,"noGallery",3,!1),h=or(e,"_content",15),m=or(e,"_title",15);const v=ye("micrio"),p=v._lang,f=v.state.tour,g=a()&&"steps"in a()&&a().isSerialTour,w=ye("markerImages").get(e.marker.id),b=w.$settings._markers??{},y=!b.preventAutoPlay,k=!(null==(i=e.marker.data)?void 0:i.preventImageOpen)&&!d(),T=1==(null==(r=e.marker.images)?void 0:r.length);let _=J((()=>e.marker.i18n?e.marker.i18n[l()]:e.marker)),x=J((()=>{var t,i,r,n,s;return!((null==(t=jt(_))?void 0:t.title)||(null==(i=jt(_))?void 0:i.audio)||e.marker.images&&e.marker.images.length||(null==(r=jt(_))?void 0:r.embedUrl)||e.marker.videoTour||(null==(n=jt(_))?void 0:n.body)||(null==(s=jt(_))?void 0:s.bodySecondary))}));const E=()=>{var t;a()&&"steps"in a()&&(a().isSerialTour||b.tourAutoProgress)&&(null==(t=e.onclose)||t.call(e))};const $=J((()=>{var t;return!y||!(null==(t=e.marker)?void 0:t.audioAutoPlay)})),A=J((()=>{var t,i,r;return!1===(null==(t=e.marker)?void 0:t.embedAutoPlay)||!y||!(!(null==(i=jt(_))?void 0:i.audio)||!(null==(r=e.marker)?void 0:r.audioAutoPlay))})),S=null==(n=w.tileBase)?void 0:n.includes("micrio.dev"),I=t=>{var e,i;return null==(i=null==(e=t.i18n)?void 0:e[l()])?void 0:i.title};let M=J((()=>{var t,i,r,n;return(null==(r=null==(i=null==(t=e.marker.videoTour)?void 0:t.i18n)?void 0:i[l()])?void 0:r.audio)??(null==(n=jt(_))?void 0:n.audio)})),L=J((()=>jt(M)?"fileUrl"in jt(M)?jt(M).fileUrl:jt(M).src:void 0)),P=J((()=>{var t,i,r,n;return T&&(null==(n=null==(r=null==(i=null==(t=e.marker.images)?void 0:t[0])?void 0:i.i18n)?void 0:r[l()])?void 0:n.description)}));var C=Ge(),D=ut(C),R=t=>{var i=Fs();let r;var n=ct(i),s=t=>{var e=Ds(),i=ct(e);qi(e,(t=>m(t)),(()=>m())),se((()=>Ke(i,jt(_).title))),Ye(t,e)};ei(n,(t=>{jt(_).title&&t(s)}));var o=dt(n,2),a=t=>{Cs(t,{children:(t,e)=>{var i=Ge();li(ut(i),(()=>jt(_).body)),Ye(t,i)},$$slots:{default:!0}})};ei(o,(t=>{jt(_).body&&b.primaryBodyFirst&&t(a)}));var l=dt(o,2),d=t=>{const i=J((()=>e.marker.audioAutoPlay||!jt(_).audio&&!!e.marker.videoTour)),r=J((()=>!e.marker.videoTour||!jt(_)||!jt(_).embedUrl));Ms(t,{get src(){return jt(L)},noPlayOverlay:!0,image:w,get uuid(){return e.marker.id},get tour(){return e.marker.videoTour},get autoplay(){return jt(i)},get controls(){return jt(r)},onended:E,get paused(){return jt($)}})};ei(l,(t=>{!g&&((!jt(_)||!jt(_).embedUrl)&&e.marker.videoTour||jt(_)&&jt(_).audio)&&t(d)}));var p=dt(l,2),f=t=>{var i=Os();ri(i,21,(()=>e.marker.images),(t=>t.id??t.src),((t,i)=>{var r=zs();r.__click=function(...t){var r;null==(r=k?()=>{return t=jt(i).micrioId,void(k&&v.state.popover.set({gallery:e.marker.images,galleryStart:t,image:w}));var t}:void 0)||r.apply(this,t)},r.disabled=!k;var n=ct(r),s=ct(n),o=dt(s,2),a=t=>{var e=Rs(),i=ct(e);se((()=>Ke(i,jt(P)))),Ye(t,e)};ei(o,(t=>{jt(P)&&t(a)})),se(((t,e,i)=>{xi(r,"title",t),xi(s,"alt",e),xi(s,"src",i)}),[()=>I(jt(i)),()=>I(jt(i)),()=>jt(i).micrioId?`https://iiif.${S?"micrio.dev":"micr.io"}/${jt(i).micrioId}/full/${T?"^"+Math.min(jt(i).width,640)+",":"^,320"}/0/default.webp`:jt(i).src]),Ye(t,r)})),Ye(t,i)};ei(p,(t=>{var i;!u()&&(null==(i=e.marker.images)?void 0:i.length)&&t(f)}));var M=dt(p,2),C=t=>{var i=Ns(),r=ut(i),n=t=>{Ms(t,{image:w,className:"hidden",get uuid(){return e.marker.id},get tour(){return e.marker.videoTour},autoplay:y,secondary:!0})};ei(r,(t=>{!jt(_).audio&&e.marker.videoTour&&t(n)}));var s=dt(r,2);const o=J((()=>!jt(A)));Ms(s,{image:w,get src(){return jt(_).embedUrl},get uuid(){return e.marker.id},width:400,height:240,controls:!0,get title(){return jt(_).embedTitle},get figcaption(){return jt(_).embedDescription},get autoplay(){return jt(o)},onended:E,get paused(){return jt(A)}}),Ye(t,i)};ei(M,(t=>{jt(_).embedUrl&&!c()&&t(C)}));var D=dt(M,2),R=t=>{Cs(t,{children:(t,e)=>{var i=Ge();li(ut(i),(()=>jt(_).body)),Ye(t,i)},$$slots:{default:!0}})};ei(D,(t=>{jt(_).body&&!b.primaryBodyFirst&&t(R)}));var z=dt(D,2),O=t=>{Cs(t,{cn:"secondary",children:(t,e)=>{var i=Ge();li(ut(i),(()=>jt(_).bodySecondary)),Ye(t,i)},$$slots:{default:!0}})};ei(z,(t=>{jt(_).bodySecondary&&t(O)})),qi(i,(t=>h(t)),(()=>h())),se((t=>r=fi(i,1,"micrio-marker-content",null,r,t)),[()=>({empty:jt(x)})]),Ye(t,i)};ei(D,(t=>{jt(_)&&t(R)})),Ye(t,C),_e(),o()}Ve(["click"]);var Us=We('<button class="micrio-button tour-step micrio-marker-popup" disabled> </button>'),Bs=We("<!> <!> <!>",1),qs=We('<progress class="progress micrio-marker-popup"></progress> <!>',1),Ws=We('<div><aside class="micrio-marker-popup"><!> <!> <!></aside> <!></div>');function Xs(t,e){Te(e,!0);const[i,r]=ir(),n=()=>tr(c,"$tour",i),s=()=>tr(l,"$current",i),o=()=>tr(Xr,"$i18n",i),a=ye("micrio"),{current:l}=a,c=a.state.tour,u=ye("markerImages").get(e.marker.id),d=u.$settings._markers??{},h=e.marker.data||{},m=d.canMinimizePopup;let v=j(void 0);function p(t){var e,i,r;n()&&jt(f)&&"steps"in n()?t instanceof Event&&jt(b)?c.set(void 0):null==(i=(e=n()).next)||i.call(e):s()&&!u.opts.secondaryTo&&s().id!=u.id&&(null==(r=h.micrioLink)?void 0:r.id)==s().id?(a.open(u.id),u.state.marker.set(void 0),a.state.popup.set(void 0)):u.state.marker.set(void 0)}let f=J((()=>n()&&"steps"in n()&&n().steps.findIndex((t=>t.startsWith(e.marker.id)))>=0)),g=J((()=>n()&&"steps"in n()&&jt(f)&&!n().isSerialTour&&d.tourControlsInPopup)),w=J((()=>(n()&&"steps"in n()?n().currentStep:void 0)??-1)),b=J((()=>jt(g)||n()&&"steps"in n()&&n().currentStep==n().steps.length-1)),y=j(!1);const k=()=>{var t,e;n()&&"steps"in n()&&(null==(e=(t=n()).prev)||e.call(t),Y(y,!0),setTimeout((()=>Y(y,!1)),200))},T=()=>{var t,e;n()&&"steps"in n()&&(null==(e=(t=n()).next)||e.call(t),Y(y,!0),setTimeout((()=>Y(y,!1)),200))};let _=j(!1),x=j(void 0),E=j(void 0);const $=new WeakMap,A=()=>{if(Y(_,!jt(_)),jt(x))for(let t=0;t<jt(x).children.length;t++){const e=jt(x).children[t];e instanceof HTMLElement&&e!=jt(E)&&($.has(e)||($.set(e,e.offsetHeight),e.style.height=e.offsetHeight+"px"),setTimeout((()=>{e.style.height=jt(_)?"0px":$.get(e)+"px"}),100))}};let S=j(!1);Gi((()=>{var t;e.marker.tags.forEach((t=>{var e;return null==(e=jt(v))?void 0:e.classList.add(t)})),setTimeout((()=>{var t,e;return null==(e=null==(t=jt(v))?void 0:t.querySelector("button"))?void 0:e.focus()}),500);const i="embedImages"in e.marker?e.marker.embedImages:void 0;i&&(null==(t=a.$current)||t.data.update((t=>(t||(t={embeds:[]}),t.embeds=[...t.embeds??[],...i],t))));const r=a.state.popup.subscribe((t=>Y(S,!t||t!=e.marker,!0)));return()=>{var t;r(),i&&(null==(t=a.$current)||t.data.update((t=>(null==t?void 0:t.embeds)?(t.embeds=t.embeds.filter((t=>!i.find((e=>e.id==t.id)))),t):t)))}}));var I=Ws();let M;var L=ct(I),P=ct(L),C=t=>{const e=J((()=>!jt(f)||jt(b)?"close":"arrow-right")),i=J((()=>!jt(f)||jt(b)?o().closeMarker:o().tourStepNext));zn(t,{get type(){return jt(e)},get title(){return jt(i)},get disabled(){return jt(y)},onclick:p})};ei(P,(t=>{h.alwaysOpen||t(C)}));var D=dt(P,2),R=t=>{const e=J((()=>jt(_)?"arrow-up":"arrow-down"));zn(t,{get type(){return jt(e)},get title(){return o().minimize},onclick:A})};ei(D,(t=>{m&&t(R)}));var z=dt(D,2),O=t=>{var e=qs(),i=ut(e);xi(i,"aria-hidden",!0),Xn(dt(i,2),{className:"micrio-tour-controls",children:(t,e)=>{var i=Bs(),r=ut(i);const s=J((()=>jt(y)||0==jt(w)));zn(r,{type:"arrow-left",get disabled(){return jt(s)},get title(){return o().tourStepPrev},onclick:k});var a=dt(r,2),l=t=>{var e=Us(),i=ct(e);se((()=>Ke(i,`${jt(w)+1} / ${n().steps.length??""}`))),Ye(t,e)};ei(a,(t=>{d.tourStepCounterInPopup&&t(l)}));var c=dt(a,2);const u=J((()=>jt(y)||jt(w)+1==n().steps.length));zn(c,{type:"arrow-right",get disabled(){return jt(u)},get title(){return o().tourStepNext},onclick:T}),Ye(t,i)},$$slots:{default:!0}}),se((()=>{return t=i,e=(jt(w)+1)/n().steps.length,void((r=Ai(t)).value!==(r.value=e??void 0)&&(t.value!==e||0===e&&"PROGRESS"===t.nodeName)&&(t.value=e??""));var t,e,r})),Ye(t,e)};ei(z,(t=>{jt(g)&&n()&&"steps"in n()&&t(O)})),Vs(dt(L,2),{get marker(){return e.marker},onclose:p,get _content(){return jt(x)},set _content(t){Y(x,t,!0)},get _title(){return jt(E)},set _title(t){Y(E,t,!0)}}),qi(I,(t=>Y(v,t)),(()=>jt(v))),se((t=>M=fi(I,1,"micrio-marker-popup",null,M,t)),[()=>({destroying:jt(S),minimized:jt(_)})]),zi(3,I,(()=>Fr),(()=>d.popupAnimation)),Ye(t,I),_e(),r()}var js=We('<li><button class="micrio-serial-tour"> </button></li>'),Gs=We('<ol class="micrio-serial-tour"></ol>'),Ys=We("<!> <!> <!> <!>",1),Hs=We('<div role="progressbar"></div>'),Zs=We('<!> <aside class="micrio-media-controls micrio-serial-tour"><!> <!></aside> <!>',1);function Ks(t,e){var i,r;Te(e,!0);const[n,s]=ir(),o=()=>tr(d,"$lang",n),a=()=>tr(Xr,"$i18n",n),l=()=>tr(ns,"$captionsEnabled",n),c=e.tour.stepInfo,u=ye("micrio"),d=u._lang,h=u.$current,m=u.state.marker,v=h.$settings,p=!!(null==(r=null==(i=null==v?void 0:v.ui)?void 0:i.controls)?void 0:r.serialTourNoTimeScrub),f=c.reduce(((t,e)=>t+e.duration),0)??0,g="controls"in e.tour?!1!==e.tour.controls:!e.tour.noControls;let w=j(!1),b=j(!1),y=j(B(Ki(u.isMuted))),k=j(void 0),T=j(void 0),_=j(0),x=j("");function E(){const t=u.state.mediaState.get(jt(x));t&&(t.paused=Y(w,!t.paused)),jt(w)?(u.events.dispatch("serialtour-pause",e.tour),u.events.enabled.set(!0)):(u.events.dispatch("serialtour-play",e.tour),u.events.enabled.set(!1))}function $(t,i){var r;if(!e.tour.goto)return;const n=t==e.tour.currentStep;if(p&&n)return;n||e.tour.goto(t);const s=!p&&i?i.offsetX/i.target.offsetWidth:0;c.forEach(((e,r)=>e.ended=!i&&r<t)),I();const o=c[t];o.currentTime=s*o.duration,n&&(null==(r=jt(k))?void 0:r.instance)&&(jt(k).instance.currentTime=o.currentTime),L(t)}function A(){u.isMuted.set(Y(y,!jt(y)))}function S(){var t;const i=jt(T);i&&(i.ended=!0),null!=e.tour.currentStep&&e.tour.currentStep<e.tour.steps.length-1&&e.tour.next?e.tour.next():(Y(w,Y(b,!0),!0),null==(t=e.onended)||t.call(e)),Xt().then((()=>{I(),i&&(i.ended=!1)}))}function I(){var t;null==(t=e.tour.stepInfo)||t.forEach((t=>t.currentTime=0))}const M=Zi([]);function L(t=e.tour.currentStep??0){const i=c.map(((e,i)=>i<t||e.ended||jt(b)?100:i==t?Math.round((e.currentTime||0)/e.duration*1e4)/100:0));Y(_,i.reduce(((t,e,i)=>t+e/100*c[i].duration),0),!0),M.set(i)}function P(t){const i=t&&!!e.tour.steps.find((e=>e.startsWith(t.id)));Y(k,void 0),i&&t.videoTour&&setTimeout((()=>{const i=c[e.tour.currentStep??0];i.markerId==t.id&&(i.ended=!1,Y(T,i,!0),Y(k,t.videoTour,!0),L())}),10)}const C=t=>{var e;return t.i18n?null==(e=t.i18n[o()])?void 0:e.title:t.title};Gi((()=>{const t=()=>L();u.addEventListener("timeupdate",t);const e=m.subscribe(P);return()=>{e(),u.removeEventListener("timeupdate",t),I()}}));let D=J((()=>{var t,e;return jt(k)?"audio"in jt(k)?jt(k).audio:null==(e=null==(t=jt(k).i18n)?void 0:t[o()])?void 0:e.audio:void 0})),R=J((()=>jt(D)?"fileUrl"in jt(D)?jt(D).fileUrl:jt(D).src:void 0)),z=J((()=>{var t;return!!(null==(t=jt(T))?void 0:t.hasSubtitle)})),O=J((()=>c.some((t=>t.hasSubtitle))));var N=Zs(),F=ut(N),V=t=>{var e=Gs();ri(e,21,(()=>c),ii,((t,e,i)=>{var r=Ge(),n=ut(r),s=t=>{var r=js();let n;var s=ct(r);s.__click=()=>$(i);var o=ct(s);se(((t,e)=>{n=fi(r,1,"micrio-serial-tour",null,n,t),Ke(o,e)}),[()=>({active:jt(T)&&jt(T).chapter==i,enriched:jt(e).imageHasOtherMarkers}),()=>C(jt(e).marker)]),Ye(t,r)};ei(n,(t=>{C(jt(e).marker)&&t(s)})),Ye(t,r)})),Ye(t,e)};ei(F,(t=>{e.tour.printChapters&&t(V)}));var U=dt(F,2),q=ct(U),W=t=>{const e=J((()=>!jt(w)));Ms(t,{get tour(){return jt(k)},get src(){return jt(R)},get autoplay(){return jt(e)},onid:t=>Y(x,t,!0),onended:S,onplay:()=>Y(w,!1),onblocked:()=>Y(w,!0),get muted(){return jt(y)},set muted(t){Y(y,t,!0)},get currentTime(){return jt(T).currentTime},set currentTime(t){jt(T).currentTime=t}})};ei(q,(t=>{jt(k)&&jt(T)&&t(W)}));var X=dt(q,2),G=t=>{var e=Ys(),i=ut(e);const r=J((()=>jt(w)?"play":"pause")),n=J((()=>jt(w)?a().play:a().pause));zn(i,{get type(){return jt(r)},get title(){return jt(n)},onclick:E});var s=dt(i,2);const o=J((()=>jt(y)?"volume-off":"volume-up")),c=J((()=>jt(y)?a().audioUnmute:a().audioMute));zn(s,{get type(){return jt(o)},get title(){return jt(c)},onclick:A});var d=dt(s,2),h=t=>{const e=J((()=>!jt(z))),i=J((()=>l()?"subtitles":"subtitles-off"));zn(t,{get disabled(){return jt(e)},get type(){return jt(i)},get active(){return l()},get title(){return a().subtitlesToggle},onclick:()=>ns.set(!l())})};ei(d,(t=>{jt(O)&&t(h)})),jn(dt(d,2),{el:u}),Ye(t,e)};ei(X,(t=>{g&&t(G)}));var H=dt(U,2),Z=t=>{us(t,{duration:f,get currentTime(){return jt(_)},set currentTime(t){Y(_,t,!0)},get ended(){return jt(b)},set ended(t){Y(b,t,!0)},children:(t,i)=>{var r=Ge();ri(ut(r),17,(()=>c),ii,((t,i,r)=>{var s=Ge(),o=ut(s),a=t=>{var s=Hs();let o;s.__click=t=>$(r,t),se(((t,e)=>{o=fi(s,1,"bar",null,o,t),xi(s,"title",e),wi(s,`width:${jt(i).duration/f*100}%; --progress: ${tr(M,"$times",n)[r]||0}%`)}),[()=>({active:r==e.tour.currentStep}),()=>C(jt(i).marker)]),Fe("keypress",s,(t=>{"Enter"===t.key&&$(r)})),Ye(t,s)};ei(o,(t=>{jt(i).duration>0&&t(a)})),Ye(t,s)})),Ye(t,r)},$$slots:{default:!0}})};ei(H,(t=>{g&&t(Z)})),Ye(t,N),_e(),s()}Ve(["click"]);var Js=We('<article class="scroll-tour micrio-tour"></article> <!>',1),Qs=We("<!> <!> <!>",1),to=We("<div><!> <!></div>");function eo(t,e){var i,r;Te(e,!0);const[n,s]=ir(),o=()=>tr(m,"$_lang",n),a=()=>tr(Xr,"$i18n",n);let l=or(e,"tour",15),c=or(e,"noHTML",3,!1);const u=ye("micrio"),{events:d,state:h,_lang:m}=u,v=u.$current,p=v.$data,f=v.$settings,g=u.canvases[0].grid,w=v.state.marker,b="steps"in l()&&l().isSerialTour,y=!("steps"in l()),k="scrollable"in l()&&l().scrollable,T="steps"in l()&&("controls"in l()?!1!==l().controls:!l().noControls),_=!(!b&&"steps"in l()&&(null==(i=f._markers)?void 0:i.tourControlsInPopup)),x=_&&(y||b),E=!!(null==(r=f._markers)?void 0:r.keepPopupsDuringTourTransitions),$=()=>M(jt(R)-1),A=()=>M(jt(R)+1),S=()=>d.enabled.set(!0);let I;function M(t){var e,i,r,n;if(!("steps"in l())||!l().stepInfo)return;const s=l().stepInfo[t];if(s&&s.markerId==(null==(e=u.state.$marker)?void 0:e.id))return L(s);const o=null==(r=null==(i=l().stepInfo[jt(R)])?void 0:i.micrioImage)?void 0:r.state;o&&o.marker.set(void 0),null==(n=u.$current)||n.state.marker.set(void 0),E||u.state.popup.set(void 0),u.removeEventListener("marker-opened",S),w.set(void 0),s&&(I=setTimeout(P,200,s))}async function L(t){var e,i,r,n,s,o,a;let c=v,d=!1;if(g&&!t.gridView&&g.images.find((e=>e.id==t.micrioId))){const s=!!("steps"in l()&&l().stepInfo&&t)&&(null==(e=l().stepInfo)?void 0:e.indexOf(t))<jt(R),o=(null==(i=t.marker.data)?void 0:i.gridTourTransition)??(null==(n=null==(r=t.marker.data)?void 0:r._meta)?void 0:n.gridTourTransition),a=(null==o?void 0:o.startsWith("slide"))?"slide":"swipe";await Xt().then((()=>{const e=g.focus(c=g.images.find((e=>e.id==t.micrioId)),{view:t.startView,transition:o==a||o==`${a}-horiz`?s?`${a}-left`:`${a}-right`:o==`${a}-vert`?s?`${a}-up`:`${a}-down`:"behind"==o?s?"behind-left":"behind-right":o}).catch((()=>d=!0));return u.events.enabled.set(!1),e}))}else if((null==(s=u.$current)?void 0:s.id)!=t.micrioId){if(t.gridView&&(null==(a=null==(o=t.marker.data)?void 0:o._meta)?void 0:a.gridAction)&&g){t.micrioImage||(t.micrioImage=g.images.find((e=>e.id==t.micrioId))),c=t.micrioImage;const e=t.marker.data._meta.gridAction.split("|");g.action(e.shift(),e.join("|"))}else"steps"in l()&&l().stepInfo&&Y(R,l().stepInfo.indexOf(t),!0),c=u.open(t.micrioId,{gridView:t.gridView,startView:t.startView});await Xt()}else c=u.$current;return[c,d]}async function P(t){let e=v,i=!1;t.micrioId&&([e,i]=await L(t)),i||(t.micrioImage||(t.micrioImage=e),d.enabled.set(!1),e.state.marker.set(t.markerId),u.addEventListener("marker-opened",S,{once:!0}),await Xt(),d.dispatch("tour-step",l()))}function C(){h.tour.set(void 0)}function D(){d.dispatch("tour-ended",l()),l().closeOnFinish&&C()}let R=j(-1),z=j(!1);const O=v.camera.getView(),N=f._markers;"steps"in l()&&(l(l().prev=$,!0),l(l().next=A,!0),l(l().goto=M,!0),ee((()=>{l(l().currentStep=jt(R),!0)})));const F=Zi(!1);let V;function U(){F.set(!1),clearTimeout(V),V=setTimeout((()=>F.set(!0)),5e3)}F.subscribe((t=>d.dispatch("tour-minimize",t)));let B,q=j(void 0);function W(t){var e,i;if(!("steps"in l())||!jt(q))return;const r=l().steps,n=t.filter((t=>t.isIntersecting)).map((t=>t.target))[0];if(n)for(let s=0;s<jt(q).children.length;s++)if(jt(q).children[s]==n){const t=null==(e=p.markers)?void 0:e.find((t=>t.id==r[s].split(",")[0]));return void(t&&(null==(i=u.$current)||i.camera.flyToView(t.view).catch((()=>{}))))}}let X=[];Gi((()=>("steps"in l()&&Mr(v,l(),o(),v.$data).then((()=>function(t){var e;if(k||(null==(e=u.$current)?void 0:e.state.$marker)||void 0!==t.initialStep&&M(t.initialStep),k&&jt(q)){B=new IntersectionObserver(W,{root:jt(q),threshold:1});for(let t=0;t<jt(q).children.length;t++)B.observe(jt(q).children[t])}X.push(u.state.marker.subscribe((e=>{if(!e)return void Y(z,!1);const i="string"==typeof e?e:e.id,r=t.steps.findIndex((t=>t.startsWith(i)));if(r>=0&&t.stepInfo){const e=t.stepInfo[Y(R,r,!0)];e&&!e.micrioImage&&(e.micrioImage=u.canvases.find((t=>t.id==e.micrioId))??(null==g?void 0:g.images.find((t=>t.id==e.micrioId)))??u.$current)}Y(z,r<0)})))}(l()))),T||X.push(F.subscribe((t=>{var i;return null==(i=e.onminimize)?void 0:i.call(e,t)}))),c()||"steps"in l()&&!b||!1===l().minimize||(u.addEventListener("pointermove",U),u.addEventListener("touchstart",U),U()),x&&u.setAttribute("data-tour-active",""),()=>{var t,e;for(clearTimeout(V),clearTimeout(I);X.length;)null==(t=X.shift())||t();u.removeEventListener("pointermove",U),u.removeEventListener("touchstart",U),u.removeEventListener("marker-opened",S),x&&u.removeAttribute("data-tour-active"),S(),B&&B.disconnect();const i=u.state.$marker;if("steps"in l()&&l().stepInfo&&null!=l().currentStep){const t=l().stepInfo[l().currentStep];delete l().goto,delete l().next,delete l().prev,i&&(null==t?void 0:t.markerId)==i.id&&(null==(e=t.micrioImage)||e.state.marker.set(void 0),u.state.marker.set(void 0))}v.camera.aniDone=void 0,g||"steps"in l()&&l().keepLastStep||u.$current==v||u.open(v.id),Xt().then((()=>{d.dispatch("tour-stop",l()),"steps"in l()&&delete l().currentStep,!("steps"in l())&&(null==N?void 0:N.zoomOutAfterClose)&&!i&&O&&v.camera.flyToView(O,{speed:null==N?void 0:N.zoomOutAfterCloseSpeed,noTrueNorth:!0})}))}))),d.dispatch("tour-start",l());let G=j(0),H=j(!1),Z=J((()=>"steps"in l()?void 0:l())),K=J((()=>{var t,e;return jt(Z)?"audio"in l()?l().audio:null==(e=null==(t=jt(Z).i18n)?void 0:t[o()])?void 0:e.audio:void 0})),Q=J((()=>jt(K)?"fileUrl"in jt(K)?jt(K).fileUrl:jt(K).src:void 0));var tt=Ge(),et=ut(tt),it=t=>{var e=Ge(),i=ut(e),r=t=>{var e=Js(),i=ut(e);ri(i,21,(()=>l().steps.map((t=>p.markers&&p.markers.find((e=>e.id==t.split(",")[0]))))),ii,((t,e)=>{var i=Ge(),r=ut(i),n=t=>{Xs(t,{get marker(){return jt(e)}})};ei(r,(t=>{jt(e)&&t(n)})),Ye(t,i)})),qi(i,(t=>Y(q,t)),(()=>jt(q)));var r=dt(i,2),n=t=>{zn(t,{type:"close",get title(){return a().tourStop},className:"scroll-tour-end",onclick:C})};ei(r,(t=>{l().cannotClose||t(n)})),Ye(t,e)},s=(t,e)=>{var i=t=>{var e=to();let i;var r=ct(e),s=t=>{var e=Ge(),i=ut(e),r=t=>{Ks(t,{get tour(){return l()},onended:D})},n=t=>{var e=Qs(),i=ut(e);const r=J((()=>0==jt(R)));zn(i,{type:"arrow-left",get title(){return a().tourStepPrev},get disabled(){return jt(r)},onclick:$});var n=dt(i,2);zn(n,{noClick:!0,children:(t,e)=>{var i=je();se((()=>Ke(i,`${jt(R)+1} / ${l().steps.length??""}`))),Ye(t,i)},$$slots:{default:!0}});var s=dt(n,2);const o=J((()=>jt(R)==l().steps.length-1));zn(s,{type:"arrow-right",get title(){return a().tourStepNext},get disabled(){return jt(o)},onclick:A}),Ye(t,e)};ei(i,(t=>{b?t(r):t(n,!1)})),Ye(t,e)},o=t=>{Ms(t,{get tour(){return l()},get src(){return jt(Q)},fullscreen:u,controls:!0,autoplay:!0,onended:D,get paused(){return jt(H)},set paused(t){Y(H,t,!0)},get currentTime(){return jt(G)},set currentTime(t){Y(G,t,!0)}})};ei(r,(t=>{"steps"in l()?t(s):t(o,!1)}));var c=dt(r,2),d=t=>{zn(t,{type:"close",get title(){return a().close},onclick:C})};ei(c,(t=>{l().cannotClose||t(d)})),se((t=>i=fi(e,1,"micrio-tour",null,i,t)),[()=>({left:b,"serial-tour":b,"video-tour":y,"no-controls":T,minimized:!jt(H)&&(tr(F,"$minimized",n)||jt(z))})]),zi(1,e,(()=>Nr),(()=>({duration:200}))),Ye(t,e)},r=(t,e)=>{var i=t=>{Ms(t,{get tour(){return jt(Z)},get src(){return jt(Q)},autoplay:!0,onended:D,get currentTime(){return jt(G)},set currentTime(t){Y(G,t,!0)}})};ei(t,(t=>{jt(Z)&&t(i)}),e)};ei(t,(t=>{_?t(i):t(r,!1)}),e)};ei(i,(t=>{k&&"steps"in l()?t(r):t(s,!1)})),Ye(t,e)},rt=(t,e)=>{var i=t=>{Ms(t,{get tour(){return jt(Z)},get src(){return jt(Q)},autoplay:!0,onended:D,get currentTime(){return jt(G)},set currentTime(t){Y(G,t,!0)}})};ei(t,(t=>{jt(Z)&&t(i)}),e)};ei(et,(t=>{c()?t(rt,!1):t(it)})),Ye(t,tt),_e(),s()}class io{constructor(t,e,i,r={}){this.micrio=t,this.length=e,this.goto=i,this.opts=r,this.hitTresh=!1,this.snapTo=[],this.pointers=new Map,this.isFullWidth=!1,this.startedWithShift=!1,this.isDragging=()=>2==this.pointers.size||(this.isFullWidth||this.startedWithShift)&&1==this.pointers.size,r.sensitivity||(r.sensitivity=Number(t.getAttribute("data-swipe-sensitivity")??1));const n=t.getAttribute("data-swipe-snap");n&&(this.snapTo=n.split(",").map(Number)),this.micrio.setAttribute("data-hooked",""),this.dStart=this.dStart.bind(this),this.dMove=this.dMove.bind(this),this.dStop=this.dStop.bind(this),this.mouseleave=this.mouseleave.bind(this),this.image=t.$current,this.image.state.view.subscribe((t=>this.isFullWidth=r.coverLimit?this.image.camera.isZoomedOut():!t||Math.round(1e3*(t[2]-t[0]))/1e3>=1));const s=t.wasm.getPtr();t.wasm.e.setNoPinchPan(s,!0),t.wasm.e.setIsSwipe(s,!0),this.micrio.canvas.element.addEventListener("pointerdown",this.dStart)}get currentIndex(){return this.micrio.wasm.e._getActiveImageIdx(this.image.ptr)}destroy(){this.micrio.canvas.element.removeEventListener("pointerdown",this.dStart),this.mouseleave()}dStart(t){this.startedWithShift=t.shiftKey;const e=!this.isDragging();this.pointers.set(t.pointerId,!0),this.pointers.size>2&&this.mouseleave(),e&&(this.hitTresh=!1,this.micrio.setAttribute("data-panning",""),this.startIndex=this.currentIndex,this.startX=t.clientX,this.firstTouchId=t.pointerId,this.micrio.addEventListener("pointermove",this.dMove),this.micrio.addEventListener("pointerup",this.dStop),this.micrio.setPointerCapture(t.pointerId))}dMove(t){if(!this.isDragging()||t.pointerId!=this.firstTouchId||void 0===this.startX||void 0===this.startIndex)return;if(!this.hitTresh&&void 0!==this.startX&&(this.hitTresh=2!=this.pointers.size||Math.abs(t.clientX-this.startX)>(this.micrio.events.pinchFactor&&this.micrio.events.pinchFactor>1.25?.3:.15)*this.micrio.offsetWidth)&&(this.startX=t.clientX),!this.hitTresh)return;const e=this.micrio.$current.camera,i=this.opts.continuous?Math.max(.1,(e.getXY(1,.5)[0]-e.getXY(0,.5)[0])/this.micrio.offsetWidth):1,r=Math.round((t.clientX-this.startX)/(this.micrio.offsetWidth*i)*this.length*(this.opts.sensitivity??1));let n=this.startIndex-r;if(this.opts.continuous){for(;n<0;)n+=this.length;for(;n>this.length-1;)n-=this.length}n=Math.max(0,Math.min(this.length-1,n)),n!=this.currentIndex&&this.goto(n)}dStop(t){this.pointers.delete(t.pointerId),t.pointerId==this.firstTouchId&&(this.micrio.releasePointerCapture(this.firstTouchId),this.firstTouchId=void 0),this.pointers.size||this.swipeEnd()}mouseleave(){this.pointers.clear(),this.swipeEnd()}swipeEnd(){if(this.micrio.removeAttribute("data-panning"),this.micrio.removeEventListener("pointermove",this.dMove),this.micrio.removeEventListener("pointerup",this.dStop),this.hitTresh=!1,this.snapTo.length){const t=this.snapTo[this.snapTo.map(((t,e)=>[e,Math.abs(t-this.currentIndex)])).sort(((t,e)=>t[1]>e[1]?1:t[1]<e[1]?-1:0))[0][0]];t!=this.currentIndex&&this.animateTo(t)}}animateTo(t){this.raf&&cancelAnimationFrame(this.raf);const e=performance.now(),i=this.currentIndex,r=i-t,n=t=>{const s=Math.min(1,(t-e)/250);s<1&&(this.raf=requestAnimationFrame(n));const o=i-Math.round(this.micrio.wasm.e.ease(s)*r);o!=this.currentIndex&&this.goto(o)};this.raf=requestAnimationFrame(n)}}var ro=We('<span class="micrio-dial"> </span>'),no=We('<div data-scroll-through="" class="micrio-dial"><!></div>');function so(t,e,i,r){jt(e)||Y(i,r(t)[1],!0)}var oo=We("<button>&#10021;</button>"),ao=We('<li><button class="bullet micrio-gallery">&bull;</button></li>'),lo=We('<div><!> <ul class="micrio-gallery"><!> <button aria-label="drag handle"></button></ul> <!></div>');function co(t,e){var i,r,n,s,o,a;Te(e,!0);const[l,c]=ir(),u=()=>tr(_,"$settings",l),d=()=>tr(T,"$layer",l),h=()=>tr(Xr,"$i18n",l);let m=or(e,"images",19,(()=>[])),v=or(e,"omni",3,null);const p=ye("micrio"),{wasm:f,current:g,events:w,_lang:b}=p,y=tr(g,"$current",l),k=y.$info,T=y.state.layer,_=y.settings,x=y.camera;if(v())for(let j=0;j<v().frames;j++)m().push({id:k.id+"/"+j,image:y,visible:Zi(!1),frame:j,opts:{area:[0,0,1,1]},ptr:-1,baseTileIdx:-1,thumbSrc:y.getTileSrc(y.levels,0,0,j)});const E=u().gallery,$="omni"==E.type,A=$||"swipe-full"==E.type,S=A||"switch"==E.type,I=$,M=!!E.isSpreads,L=E.coverPages??0,P=u().omni,C=$&&!!(null==P?void 0:P.twoAxes),D=E.startId||p.getAttribute("data-gallery-start-id"),R=E.archive,z=!!u().limitToCoverScale,O=!!u().noUI,N=(null==P?void 0:P.frontIndex)??0,F=(null==(i=null==P?void 0:P.layers)?void 0:i.length)??1,V=p.hasAttribute("data-gallery-start")?Number(p.getAttribute("data-gallery-start")):null==(n=null==(r=u())?void 0:r.omni)?void 0:n.startIndex;let U=null==V||isNaN(V)?D?m().findIndex((t=>t.id==D)):0:V;U<0&&(U=0);const B=[],q=[];if(m())for(let j=0;j<m().length;j++){let t=null==(s=m()[j].opts)?void 0:s.area;if(!t)continue;const e=t.slice(0);if(q.push([j]),M&&j-L>=0&&(j-L)%2==0&&m()[j+1]){if(t=null==(o=m()[++j].opts)?void 0:o.area,!t)continue;q[q.length-1].push(j),e[2]=t[2],e[3]=t[3]}B.push(e)}const W=B.length/F,X=(null==(a=null==P?void 0:P.layers)?void 0:a.map((t=>({i18n:Object.fromEntries(Object.entries(t.i18n).map((([t,e],i)=>[t,{title:e??"Layer "+(i+1)}])))}))))??[];Object.keys(k.revision??{[(()=>tr(b,"$_lang",l))()]:0}).forEach((t=>X.forEach(((e,i)=>{e.i18n[t]||(e.i18n[t]={title:"Layer "+(i+1)})}))));let G=j(-1),H=S,Z=j(!0),K=j(!1),Q=j(!0),tt=!1,et=j(0);function rt(t,e=!1,i=150,r=!1){if(I){for(;t<0;)t+=W;t%=W}const n=t=Math.round(Math.max(0,Math.min(W-1,t))),s=r||n!=jt(G);if(Y(G,n,!0),s&&nt(),S)s&&(f.setActiveImage(y.ptr,q[jt(G)][0],q[jt(G)].length-1),$?f.render():(x.flyToView(B[jt(G)],{duration:i,speed:2}).then((()=>ht(B[jt(G)],!0))).catch((()=>{})),Ut()));else{const r=x.getView(),n=B[t],o=tt&&(H&&!jt(K)||s||r[0]<n[0]!=r[2]>n[2]);Y(K,!1),o?x.flyToView(n,{duration:i,speed:1,progress:e?.5:0}).then((()=>ht(n,!0))).catch((()=>{})):(n&&0==i&&x.setView(n),ht(n,!0))}y.album.hooked=tt=!0}function nt(t){if(Ft&&t){if(Ft.currentIndex==jt(G))return;Y(G,Ft.currentIndex,!0)}lt(jt(G)),w.dispatch("gallery-show",jt(G)),$&&Y(et,(jt(G)-N)/W*360)}const st="requestIdleCallback"in self?$?Math.max(36,2*Math.floor(m().length/8)):100:50,ot=new Map,at=self.requestIdleCallback??self.requestAnimationFrame;function lt(t){const e=[];X.length&&(t+=d()*Math.floor(m().length/X.length)),M&&t>=L&&(t=2*t-L);const i=Math.floor(t/Pt);for(let r=-st;r<=st;r++)if(r){let n=t+r;if(C){const t=Math.floor(n/Pt);t<i&&(n+=Pt),t>i&&(n-=Pt)}if(I){for(;n<0;)n+=m().length;for(;n>=m().length;)n-=m().length}e.push(n)}if(C)for(let r=-st;r<=st;r++)r&&e.push(t+r*Pt);e.filter(((t,i)=>t>=0&&t<m().length&&e.indexOf(t)==i)).map((t=>m()[t])).filter((t=>!!t&&!ot.has(t.id))).forEach((t=>ot.set(t.id,at((()=>f.getTexture(t.baseTileIdx,t.thumbSrc,!1,{force:!!R}))))))}function ht(t,e){H=x.isZoomedOut(),x.setLimit(!e&&H?[-1,t[1],2,t[3]]:t)}function mt(t){var e;const i=null==(e=jt(pt))?void 0:e.childNodes[t];return i?-2+i.offsetLeft+i.offsetWidth/2:0}let vt,pt=j(void 0),ft=j(0),gt=J((()=>!jt(pt)||jt(Z)?jt(ft):mt(jt(G)))),wt=!1;function bt(t){t.preventDefault(),t.stopPropagation(),jt(Z)||(wt="button"in t)&&0!=t.button||!jt(pt)||(vt=jt(pt).getClientRects()[0],p.keepRendering=Y(Z,!0),Y(xt,-1),window.addEventListener(wt?"pointermove":"touchmove",kt),window.addEventListener(wt?"pointerup":"touchend",Et),kt(t))}function yt(t){const e=vt??jt(pt).getClientRects()[0],i="button"in t?t.clientX:t.touches[0].clientX,r=Math.min(1,Math.max(0,(i-e.left-14)/(e.width-32)));return[r,Math.max(0,Math.min(W-1,Math.floor(r*W)))]}function kt(t){const[e,i]=yt(t);Y(ft,16+e*(vt.width-32)),i!=jt(G)&&rt(i,!0)}let Tt,_t,xt=j(-1);function Et(){window.removeEventListener(wt?"pointermove":"touchmove",kt),window.removeEventListener(wt?"pointerup":"touchend",Et),Y(Z,p.keepRendering=!1,!0),rt(jt(G))}function $t(){H&&(_t=Tt=jt(G),Y(K,H,!0),ht(B[jt(G)],!1))}function At(t){const e=t.detail;"panend"!=t.type||e?rt(_t!=jt(G)?_t:jt(G)+(Tt==jt(G)&&jt(K)&&e?Math.round(Math.min(1,Math.max(-1,-e.movedX/e.duration))):0)):Y(K,!1)}function St(t){if(!t)return;const e=t[0]+(t[2]-t[0])/2,i=B.map(((i,r)=>(1-Math.min(Math.abs(e-i[0]),Math.abs(e-i[2])))*Math.max(0,(Math.min(t[2],i[2])-Math.max(t[0],i[0]))/(i[2]-i[0]))*(1-.1*Math.abs(jt(G)-r))));f.setFocus(y.ptr,B[_t=i.every((t=>!t))?jt(G):i.indexOf(Math.max(...i))],jt(K)),H=x.isZoomedOut()}let It=0,Mt=[0,0,0,0];function Lt(t){t.stopPropagation(),t.preventDefault(),0==t.button&&(Y(Z,!0),Mt=[t.clientX,t.clientY,jt(G),It],window.addEventListener("pointermove",Dt),window.addEventListener("pointerup",Rt))}const Pt=m().length,Ct=1;function Dt(t){It=Math.max(0,Math.min(Ct-1,Mt[3]+Math.round((Mt[1]-t.clientY)/360*Ct)));let e=(Mt[2]+Math.round((Mt[0]-t.clientX)/360*Pt))%Pt;for(;e<0;)e+=Pt;rt(It*Pt+e)}function Rt(){removeEventListener("pointermove",Dt),removeEventListener("pointerup",Rt),Y(Z,!1)}let zt=-1;const Ot=()=>{X.length&&y.data.update((t=>{t||(t={}),t.pages||(t.pages=[]);const e={id:"_omni-layers",i18n:X[d()].i18n,icon:Qr,children:X.map(((t,e)=>({id:"omni-layer-"+e,i18n:t.i18n,action:()=>{T.set(e),lt(jt(G))}}))).filter((t=>t.id!="omni-layer-"+d()))};return zt>=0&&zt<t.pages.length?t.pages.splice(zt,1,e):t.pages.push(e),zt=t.pages.length-1,t}))};let Nt,Ft,Vt=p.state.ui.hidden;function Ut(){Vt.set(!1),clearTimeout(Nt),Nt=setTimeout((()=>Vt.set(!0)),2e3)}y.album={numPages:B.length,get currentIndex(){return jt(G)},info:y.$settings.album,prev:()=>rt(jt(G)-1),next:()=>rt(jt(G)+1),goto:rt},Gi((()=>{Promise.all(m().map((t=>("state"in t&&!("image"in t)&&(t.camera=y.camera),f.addEmbed(t,y,{opacity:0,asImage:"camera"in t}))))).then((()=>{f.setActiveImage(y.ptr,U),rt(U,!1,0),Y(Z,!1)})),$&&F>1&&Ot(),Y(Q,!1),p.goto=rt;const t=[],e=[];return $&&t.push(y.state.layer.subscribe(Ot)),A&&(Ft=y.swiper=new io(p,W,rt,{continuous:I,coverLimit:z})),e.push((()=>{p.canvas.element.removeEventListener("pointermove",Ut),p.canvas.element.removeEventListener("pointerdown",Ut)})),$||C||A||(p.canvas.element.addEventListener("pointermove",Ut),p.canvas.element.addEventListener("pointerdown",Ut),Ut()),S&&t.push(y.state.view.subscribe((()=>{H=x.isZoomedOut()}))),S||A||m().length<=1||(C||Y(ft,mt(U),!0),t.push(y.state.view.subscribe(St)),p.addEventListener("panstart",$t),p.addEventListener("panend",At),p.addEventListener("pinchend",At),e.push((()=>{p.removeEventListener("panstart",$t),p.removeEventListener("panend",At),p.removeEventListener("pinchend",At)}))),$&&p.addEventListener("move",nt),()=>{var i,r;for(Ft&&Ft.destroy();t.length;)null==(i=t.shift())||i();for(;e.length;)null==(r=e.shift())||r();$&&p.removeEventListener("move",nt)}}));var Bt=Ge();Fe("keydown",it,(function(t){var e;if(!(null==(e=u().omni)?void 0:e.noKeys)){switch(t.key){case"PageUp":case"ArrowLeft":rt(jt(G)-($?-1:1),!0);break;case"PageDown":case"ArrowRight":rt(jt(G)+($?-1:1),!0);break;case"ArrowUp":C&&rt(jt(G)+Pt);break;case"ArrowDown":C&&rt(jt(G)-Pt);break;case"Home":rt(0);break;case"End":rt(W);break;default:return}Ut()}}));var qt=ut(Bt),Wt=t=>{var e=Ge(),i=ut(e),r=t=>{var e=oo();let i;se((t=>i=fi(e,1,"angular micrio-gallery",null,i,t)),[()=>({dragging:jt(Z)})]),Fe("pointerdown",e,Lt,!0),Ye(t,e)},n=(t,e)=>{var i=t=>{const e=J((()=>{var t;return null==(t=u().omni)?void 0:t.showDegrees}));!function(t,e){Te(e,!0);const i=ye("micrio"),r=i.$current.camera;let n,s=j(void 0),o=0,a=0;function l(t){var n;const l=Math.max(1,(r.getXY(1,.5)[0]-r.getXY(0,.5)[0])/i.offsetWidth),c=(a/360+(o-t.clientX)/(jt(s).offsetWidth*l))*e.frames;null==(n=e.onturn)||n.call(e,c)}function c(){n&&i.releasePointerCapture(n),i.removeAttribute("data-panning"),i.removeEventListener("pointermove",l),i.removeEventListener("pointerup",c)}let u=J((()=>{var t;return-e.currentRotation/360*((null==(t=jt(s))?void 0:t.offsetWidth)??0)}));var d=no(),h=ct(d),m=t=>{var i=ro(),r=ct(i);se((t=>Ke(r,`${t??""}º`)),[()=>Math.round(10*e.currentRotation)/10]),Ye(t,i)};ei(h,(t=>{e.degrees&&t(m)})),qi(d,(t=>Y(s,t)),(()=>jt(s))),se((()=>wi(d,`--micrio-dial-offset:${jt(u)??""}px;`))),Fe("pointerdown",d,(function(t){t.stopPropagation(),t.preventDefault(),0==t.button&&(i.addEventListener("pointermove",l),i.addEventListener("pointerup",c),i.setAttribute("data-panning",""),i.setPointerCapture(n=t.pointerId),a=e.currentRotation,o=t.clientX)}),!0),Ye(t,d),_e()}(t,{get currentRotation(){return jt(et)},frames:W,get degrees(){return jt(e)},onturn:t=>rt(t)})},r=(t,e)=>{var i=t=>{var e=lo();let i;var r=ct(e);const n=J((()=>0==jt(G)));zn(r,{type:"arrow-left",get title(){return h().galleryPrev},className:"gallery-btn",onpointerdown:()=>rt(jt(G)-1),get disabled(){return jt(n)}});var s=dt(r,2);s.__pointermove=[so,Z,xt,yt];var o=ct(s);ri(o,17,(()=>B),ii,((t,e,i)=>{var r=ao();let n;var s=ct(r);s.__click=()=>rt(i,!0),se((t=>n=fi(r,1,"micrio-gallery",null,n,t)),[()=>({active:i==jt(G),hover:i==jt(xt)})]),Fe("keypress",s,(t=>{"Enter"===t.key&&rt(i,!0)})),Ye(t,r)}));var a=dt(o,2);let c;qi(s,(t=>Y(pt,t)),(()=>jt(pt)));var u=dt(s,2);const d=J((()=>jt(G)==m().length-1));zn(u,{type:"arrow-right",get title(){return h().galleryNext},className:"gallery-btn",onpointerdown:()=>rt(jt(G)+1),get disabled(){return jt(d)}}),se(((t,r)=>{i=fi(e,1,"micrio-gallery",null,i,t),wi(a,`left: ${jt(gt)}px`),c=fi(a,1,"micrio-gallery",null,c,r)}),[()=>({hidden:jt(Q)||tr(Vt,"$hidden",l)&&!jt(Z)&&!jt(K)}),()=>({dragging:jt(Z)})]),Fe("pointerleave",s,(()=>Y(xt,-1))),Fe("pointerdown",a,bt,!0),Fe("touchstart",a,bt,!0,!0),Ye(t,e)};ei(t,(t=>{!A&&m().length>1&&t(i)}),e)};ei(t,(t=>{P&&!P.noDial&&$?t(i):t(r,!1)}),e)};ei(i,(t=>{C?t(r):t(n,!1)})),Ye(t,e)};ei(qt,(t=>{O||t(Wt)})),Ye(t,Bt),_e(),c()}let uo;Ve(["pointermove","click"]);const ho={},mo=Zi();let vo,po;const fo=Zi(!1);function go(t,e,i){po&&(po.setPosition?po.setPosition(t,e,i):"positionX"in po&&(po.positionX.value=t,po.positionY.value=e,po.positionZ.value=i))}function wo(t,e,i){po&&(po.setOrientation?po.setOrientation(t,e,i,0,1,0):"forwardX"in po&&(po.forwardX.value=t,po.forwardY.value=e,po.forwardZ.value=i))}function bo(t,e){Te(e,!0);const[i,r]=ir();let n=or(e,"volume",3,1);const{events:s,current:o}=ye("micrio"),a=tr(o,"$current",i),l=a.$info,c=l.height/l.width,u="AudioContext"in window||"webkitAudioContext"in window;const d=()=>fo.set(!0),h=new Audio("data:audio/mpeg;base64,/+MYxAAAAANIAUAAAASEEB/jwOFM/0MM/90b/+RhST//w4NFwOjf///PZu////9lns5GFDv//l9GlUIEEIAAAgIg8Ir/JGq3/+MYxDsLIj5QMYcoAP0dv9HIjUcH//yYSg+CIbkGP//8w0bLVjUP///3Z0x5QCAv/yLjwtGKTEFNRTMuOTeqqqqqqqqqqqqq/+MYxEkNmdJkUYc4AKqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq");h.volume=mr.iOS?0:1e-4,u&&Gi((()=>{let t,i;return i=fo.subscribe((r=>{var o;r&&(vo||(!function(t){if(!uo){if(vo||(vo="micrioAudioContext"in window?window.micrioAudioContext:"AudioContext"in window?new window.AudioContext:"webkitAudioContext"in window?new window.webkitAudioContext:null),!vo)return console.warn("[Micrio] Your browser does not support the Web Audio API");uo=vo.createGain(),uo.connect(vo.destination),uo.gain.value=t,mo.set(vo),po=vo.listener,"upX"in po&&(po.upX.value=0,po.upY.value=1,po.upZ.value=0)}}(n()),s.dispatch("audio-init")),vo&&(null==(o=e.data.markers)?void 0:o.filter((t=>!!t.positionalAudio)).length)&&(t=a.state.view.subscribe((t=>{if(!t)return;const i=t[2]-t[0],r=t[3]-t[1],n=Math.max(0,1.05-a.camera.getScale());!function(t,i,r){if(e.is360){t*=2*-Math.PI,i-=.5,i*=-Math.PI;const e=10*(1-r),n=Math.cos(i)*Math.sin(t)*e,s=Math.sin(i)*e,o=Math.cos(i)*Math.cos(t)*e;go(n,s,o);let a=n*n+s*s+o*o;a>0&&(a=1/Math.sqrt(a)),wo(n*a,s*a,o*a)}else go(2*(t-.5),2*(.5-i)*c,r),wo(0,0,-1)}(t[0]+i/2,t[1]+r/2,n*(e.is360?1:1.5))}))),i&&(i(),i=null))})),vo||h.play().then(d).catch((()=>{s.dispatch("autoplay-blocked"),addEventListener("pointerup",d,{once:!0})})),()=>{t&&t(),i&&i(),removeEventListener("pointerup",d)}})),ee((()=>{uo&&(uo.gain.value=n())}));var m=Ge(),v=ut(m),p=t=>{const i=J((()=>n()*(e.data.music.volume??1)));!function(t,e){Te(e,!0);let i=or(e,"loop",3,!0),r=or(e,"volume",3,1);const n=B(new Audio);n.preload="none",n.loop=!1,n.onended=o;let s=-1;function o(){if(!i()&&s+1==e.list.length)return;const t=e.list[++s%e.list.length];n.src="fileUrl"in t?t.fileUrl:t.src,n.play()}Gi((()=>(o(),()=>n.pause()))),ee((()=>{n.volume=r()})),_e()}(0,{get list(){return e.data.music.items},get loop(){return e.data.music.loop},get volume(){return jt(i)}})};ei(v,(t=>{var r;tr(fo,"$interacted",i)&&tr(mo,"$ctx",i)&&(null==(r=e.data.music)?void 0:r.items.length)&&t(p)})),Ye(t,m),_e(),r()}var yo=We('<cite class="micrio-details"> </cite>'),ko=We('<small class="micrio-details"> </small>'),To=We('<summary class="micrio-details"><!> <!></summary>'),_o=We('<p class="micrio-details"><a rel="noopener noreferrer" target="_blank"> </a></p>'),xo=We("<details><!> <!> <!> <!></details>");function Eo(t,e){Te(e,!0);const[i,r]=ir(),n=()=>tr(a,"$current",i),s=()=>tr(e.data,"$data",i),{_lang:o,current:a}=ye("micrio");let l=j(!1);function c(t){let e="cm";return t>=1e5?(e="km",t/=1e5):t>=100?(e="m",t/=100):t<1e-6?(e="nm",t*=1e7):t<.001?(e="µm",t*=1e4):t<1&&(e="mm",t*=10),t.toFixed(2)+" "+e}let u=J((()=>{var t;return null==(t=n())?void 0:t.$settings.cmWidth})),d=J((()=>{var t;return null==(t=n())?void 0:t.$settings.cmHeight})),h=J((()=>{var t;return s()?(null==(t=s())?void 0:t.i18n)?s().i18n[tr(o,"$_lang",i)]:s():void 0})),m=J((()=>{var t,r;return(null==(t=jt(h))?void 0:t.title)??(null==(r=tr(e.info,"$info",i))?void 0:r.title)??""})),v=J((()=>{var t;return null==(t=jt(h))?void 0:t.description})),p=J((()=>{var t;return null==(t=jt(h))?void 0:t.sourceUrl})),f=J((()=>{var t;return null==(t=jt(h))?void 0:t.copyright})),g=J((()=>jt(u)&&jt(d)?c(jt(u))+" x "+c(jt(d)):null)),w=j(void 0);Gi((()=>{jt(w).ontoggle=()=>{Y(l,jt(w).open,!0)}}));var b=Ge(),y=ut(b),k=t=>{var e=xo();let r;var n=ct(e),s=t=>{var e=To(),i=ct(e),r=t=>{var e=yo(),i=ct(e);se((()=>Ke(i,jt(m)))),Ye(t,e)};ei(i,(t=>{jt(m)&&t(r)}));var n=dt(i,2),s=t=>{var e=ko(),i=ct(e);se((()=>Ke(i,jt(g)))),Ye(t,e)};ei(n,(t=>{jt(g)&&t(s)})),Ye(t,e)};ei(n,(t=>{(jt(m)||jt(g))&&t(s)}));var o=dt(n,2),a=t=>{var e=Ge();li(ut(e),(()=>jt(v))),Ye(t,e)};ei(o,(t=>{jt(v)&&t(a)}));var c=dt(o,2),u=t=>{var e=_o(),i=ct(e),r=ct(i);se((()=>{xi(i,"href",jt(p)),Ke(r,jt(f)||jt(p))})),Ye(t,e)};ei(c,(t=>{jt(p)&&t(u)}));var d=dt(c,2),h=t=>{zn(t,{type:"close",get title(){return tr(Xr,"$i18n",i).close},onclick:()=>jt(w).open=!1})};ei(d,(t=>{jt(l)&&t(h)})),qi(e,(t=>Y(w,t)),(()=>jt(w))),se((t=>r=fi(e,1,"micrio-details",null,r,t)),[()=>({opened:jt(l)})]),zi(3,e,(()=>Nr),(()=>({duration:200}))),Ye(t,e)};ei(y,(t=>{(jt(m)||jt(v)||jt(p))&&t(k)})),Ye(t,b),_e(),r()}var $o=We('<div class="micrio-error"><!> </div>');var Ao=We("<figcaption><!></figcaption>"),So=We("<figure><micr-io></micr-io> <!></figure>",2);function Io(t,e){Te(e,!0);const[i,r]=ir(),n=()=>tr(l,"$current",i);let s=or(e,"startId",3,void 0);const o=ye("micrio"),{_lang:a,current:l}=o;let c=j(0);let u=J((()=>e.gallery[jt(c)])),d=J((()=>{var t,e,r;return(null==(r=null==(e=null==(t=jt(u))?void 0:t.i18n)?void 0:e[tr(a,"$_lang",i)])?void 0:r.description)??void 0}));var h=So(),m=ct(h);se((()=>Ei(m,"data-gallery",e.gallery.map((t=>{var e,i;return`${t.micrioId},${t.width},${t.height},${t.isDeepZoom?"d":""}${t.isWebP?",w":t.isPng||!(null==(e=n())?void 0:e.isV5)&&(null==(i=t.src)?void 0:i.endsWith(".png"))?",p":""}`})).join(";")))),se((()=>Ei(m,"data-start",s()))),se((()=>Ei(m,"data-path",n()&&n().$info&&n().$info.path))),Ei(m,"data-logo","false"),fi(m,1,"micrio-micrio-gallery");var v=dt(m,2),p=t=>{var e=Ao();li(ct(e),(()=>jt(d))),Ye(t,e)};ei(v,(t=>{jt(d)&&t(p)})),Fe("gallery-show",m,(t=>{Y(c,t.detail,!0)})),Ye(t,h),_e(),r()}var Mo=We("<!> <!>",1),Lo=We("<aside><!> <!></aside>"),Po=We("<!> <!>",1),Co=We('<menu class="micrio-popover"></menu>'),Do=We('<h2 class="micrio-popover"> </h2>'),Ro=We('<img alt="">'),zo=We("<!> <!> <!> <!>",1),Oo=We('<menu class="right micrio-popover"></menu>'),No=We("<!> <!> <!>",1),Fo=We("<dialog><!> <!></dialog>");function Vo(t,e){var i;Te(e,!0);const[r,n]=ir(),s=()=>tr(d,"$current",r),o=()=>tr(h,"$_lang",r),a=()=>tr(Xr,"$i18n",r),l=B(ye("micrio")),{events:c,state:u,current:d,_lang:h}=l,m=null==(i=s())?void 0:i.$data,v=Object.keys((null==m?void 0:m.revision)??{[o()]:0});function p(){var t;null==(t=jt(b))||t.close()}const f=Zi(!1);let g=j(!0),w=o(),b=j(void 0);Gi((()=>{jt(b).showModal(),Xt().then((()=>{const t=jt(b).querySelector("button.active")??jt(b).querySelector("button");null==t||t.focus()}));const t=h.subscribe((t=>{t&&t!=w&&(Y(g,!1),w=t,setTimeout((()=>Y(g,!0)),200))}));return()=>{t()}}));let y=J((()=>e.popover.marker)),k=J((()=>jt(y)?jt(y).i18n?jt(y).i18n[o()]:jt(y):void 0)),T=J((()=>e.popover.markerTour)),_=J((()=>e.popover.contentPage)),x=J((()=>{var t;return jt(_)?(null==(t=jt(_).i18n)?void 0:t[o()])??jt(_):void 0})),E=J((()=>{var t,e;return jt(_)&&jt(x)&&!(null==(e=null==(t=jt(_))?void 0:t.buttons)?void 0:e.length)?!(!jt(x).embed||jt(x).content&&!(jt(x).content.length<250)||jt(_).image):void 0})),$=J((()=>{var t;return(null==(t=jt(_))?void 0:t.image)?"string"==typeof jt(_).image?jt(_).image:jt(_).image.src:void 0})),A=J((()=>{var t;return!!(null==(t=jt(x))?void 0:t.embed)||!!jt($)})),S=J((()=>{var t,e;return!!(null==(e=null==(t=jt(_))?void 0:t.buttons)?void 0:e.find((t=>"close"==t.type)))})),I=J((()=>{var t;return!!(null==(t=e.popover.marker)?void 0:t.images)&&e.popover.marker.images.length>0})),M=J((()=>!(!jt(k)||!jt(k).body)||jt(I))),L=J((()=>{var t;return jt(k)&&jt(k).body||jt(I)&&(null==(t=jt(x))?void 0:t.embed)})),P=J((()=>!jt(S)||jt(T)&&null!=jt(T).currentStep));var C=Fo();let D;var R=ct(C),z=t=>{var e=Lo();let i;var r=ct(e),n=t=>{zn(t,{type:"close",get title(){return a().close},className:"close-popover",onclick:p})};ei(r,(t=>{jt(S)||t(n)}));var s=dt(r,2),o=t=>{var e=Mo(),i=ut(e),r=t=>{zn(t,{type:"arrow-left",get title(){return a().tourStepPrev},className:"prev-tour-step",onclick:()=>jt(T)&&jt(T).prev&&jt(T).prev()})};ei(i,(t=>{jt(T).currentStep>0&&t(r)}));var n=dt(i,2),s=t=>{zn(t,{type:"arrow-right",get title(){return a().tourStepNext},className:"next-tour-step",onclick:()=>jt(T)&&jt(T).next&&jt(T).next()})};ei(n,(t=>{jt(T).currentStep<jt(T).steps.length-1&&t(s)})),Ye(t,e)};ei(s,(t=>{jt(T)&&null!=jt(T).currentStep&&t(o)})),se((t=>i=fi(e,1,"micrio-popover",null,i,t)),[()=>{var t;return{inside:jt(_)?!jt(E):!jt(M)&&!(null==(t=jt(k))?void 0:t.embedUrl)}}]),Ye(t,e)};ei(R,(t=>{jt(P)&&t(z)}));var O=dt(R,2),N=t=>{var e=Po(),i=ut(e),r=t=>{Ms(t,{get src(){return jt(k).embedUrl},get uuid(){return jt(y).id},get figcaption(){return jt(k).embedDescription},controls:!0,get autoplay(){return jt(y).embedAutoPlay}})},n=(t,e)=>{var i=t=>{Io(t,{get gallery(){return jt(y).images}})};ei(t,(t=>{jt(y).images&&jt(y).images.length&&t(i)}),e)};ei(i,(t=>{jt(k)&&jt(k).embedUrl?t(r):t(n,!1)}));var s=dt(i,2),o=t=>{const e=J((()=>!jt(k)||!jt(k).embedUrl));Vs(t,{get marker(){return jt(y)},noEmbed:!0,noGallery:!0,get noImages(){return jt(e)},onclose:p})};ei(s,(t=>{jt(L)&&t(o)})),Ye(t,e)},F=(t,i)=>{var r=t=>{Io(t,{get gallery(){return e.popover.gallery},get startId(){return e.popover.galleryStart}})},n=(t,e)=>{var i=t=>{var e=No(),i=ut(e),r=t=>{var e=Co();ri(e,21,(()=>v),ii,((t,e)=>{const i=J((()=>(null==Bn?void 0:Bn.of(jt(e)))??jt(e))),r=J((()=>jt(e)==o()));zn(t,{onclick:()=>l.lang=jt(e),get title(){return jt(i)},get active(){return jt(r)},children:(t,i)=>{var r=je();se((t=>Ke(r,t)),[()=>jt(e).toUpperCase()]),Ye(t,r)},$$slots:{default:!0}})})),Ye(t,e)};ei(i,(t=>{v.length>1&&t(r)}));var n=dt(i,2),a=t=>{var e=Ge(),i=ut(e),r=t=>{Ms(t,{get src(){return jt(x).embed},get figcaption(){return jt(x).content},controls:!0,autoplay:!0})};ei(i,(t=>{jt(g)&&t(r)})),Ye(t,e)},c=t=>{Cs(t,{children:(t,e)=>{var i=zo(),r=ut(i),n=t=>{var e=Do(),i=ct(e);se((()=>Ke(i,jt(x).title))),Ye(t,e)};ei(r,(t=>{jt(x).title&&t(n)}));var s=dt(r,2),o=t=>{Ms(t,{get src(){return jt(x).embed},controls:!0})};ei(s,(t=>{jt(x).embed&&jt(g)&&t(o)}));var a=dt(s,2),l=t=>{var e=Ro();se((()=>xi(e,"src",jt($)))),Ye(t,e)};ei(a,(t=>{jt($)&&t(l)}));var c=dt(a,2),u=t=>{var e=Ge();li(ut(e),(()=>jt(x).content)),Ye(t,e)};ei(c,(t=>{jt(x).content&&t(u)})),Ye(t,i)},$$slots:{default:!0}})};ei(n,(t=>{jt(E)?t(a):t(c,!1)}));var u=dt(n,2),d=t=>{var e=Oo();ri(e,21,(()=>jt(_).buttons),ii,((t,e)=>{const i=J((()=>"link"==jt(e).type?jt(e).action:void 0));zn(t,{get href(){return jt(i)},get blankTarget(){return jt(e).blankTarget},onclick:()=>function(t){p(),"close"!=t.type&&setTimeout((()=>{var e,i,r;switch(t.type){case"marker":null==(e=s())||e.state.marker.set(t.action);break;case"mtour":l.state.tour.set(null==(i=null==m?void 0:m.markerTours)?void 0:i.find((e=>e.id==t.action)));break;case"vtour":l.state.tour.set(null==(r=null==m?void 0:m.tours)?void 0:r.find((e=>e.id==t.action)))}}),200)}(jt(e)),children:(t,i)=>{var r=je();se((()=>Ke(r,jt(e).i18nTitle[o()]))),Ye(t,r)},$$slots:{default:!0}})})),Ye(t,e)};ei(u,(t=>{jt(_).buttons&&jt(_).buttons.length&&t(d)})),Ye(t,e)};ei(t,(t=>{jt(_)&&jt(x)&&t(i)}),e)};ei(t,(t=>{e.popover.gallery?t(r):t(n,!1)}),i)};ei(O,(t=>{jt(y)?t(N):t(F,!1)})),qi(C,(t=>Y(b,t)),(()=>jt(b))),se((t=>D=fi(C,1,"micrio-popover",null,D,t)),[()=>({page:!!jt(_),article:!!jt(_)&&!jt(E),"has-media":jt(A)})]),Fe("close",C,(function(){var t;e.popover.contentPage?c.dispatch("page-closed"):jt(T)?u.tour.set(void 0):e.popover.marker&&(null==(t=e.popover.image)||t.state.marker.set(void 0)),u.popover.set(void 0)})),Fe("outrostart",C,(()=>f.set(!0))),Ye(t,C),_e(),n()}function Uo(t,e){Te(e,!0);let i=J((()=>e.marker.positionalAudio));const r=e.ctx.createGain();r.connect(uo);const n=ye("micrio"),s=n.$current.$info,o=s.width,a=s.height,l=e.ctx.createPanner();l.panningModel="equalpower",l.rolloffFactor=1,l.coneOuterGain=0;function c(){if(r.gain.value=jt(i).volume??1,e.is360){l.refDistance=2.75*jt(i).radius,l.maxDistance=jt(i).radius*(11/3);const t=e.marker.x*-Math.PI*2,r=(e.marker.y-.5)*-Math.PI,n=l.positionX.value=Math.cos(r)*Math.sin(t)*11,s=l.positionY.value=11*Math.sin(r),o=l.positionZ.value=Math.cos(r)*Math.cos(t)*11;let a=n*n+s*s+o*o;a>0&&(a=1/Math.sqrt(a)),l.orientationX.value=n*a,l.orientationY.value=s*a,l.orientationZ.value=o*a}else l.distanceModel="linear",l.positionX.value=2*(e.marker.x-.5),l.positionY.value=2*(.5-e.marker.y)*(a/o),l.positionZ.value=-.2,l.rolloffFactor=2,l.refDistance=jt(i).radius*jt(i).radius*10,l.maxDistance=5*jt(i).radius}let u,d;function h(){u&&u.disconnect(),u=e.ctx.createBufferSource(),jt(i).loop&&(jt(i).repeatAfter>0?u.onended=()=>{d=setTimeout(h,1e3*jt(i).repeatAfter)}:u.loop=!0),r.gain.value=jt(i).volume??1,u.buffer=ho[jt(i).src],u.connect(l),u.start()}let m=j(B(JSON.stringify(e.marker.positionalAudio)));ee((()=>{const t=JSON.stringify(jt(i));jt(m)!=t&&Y(m,t,!0)&&c()})),Gi((()=>(c(),l.connect(r),async function(){jt(i).src&&(ho[jt(i).src]||(ho[jt(i).src]=await fetch(jt(i).src).then((t=>t.arrayBuffer())).then((t=>e.ctx.decodeAudioData(t)))),jt(i).alwaysPlay&&jt(i).repeatAfter>0?d=setTimeout(h,1e3*jt(i).repeatAfter):h())}(),n.addEventListener("audio-update",c),()=>{n.removeEventListener("audio-update",c),u&&u.disconnect(),clearTimeout(d),l.disconnect(),r.disconnect()}))),_e()}function Bo(t,e,i,r,n,s,o){var a,l;if(e(),i().onclick)return i().onclick(i());if(!r.noMarkerActions)if("cluster"==i().type){if(i().view&&(null==(a=n())?void 0:a.$info)){const t=n().camera.getScale(),e=[20/n().$info.width*t,20/n().$info.height*t];o().camera.flyToView([i().view[0]-e[0],i().view[1]-e[1],i().view[2]+e[0],i().view[3]+e[1]],{area:null==(l=o().opts)?void 0:l.area,limitZoom:!0})}}else o().state.marker.set(i())}function qo(t,e,i){const r=t.detail;e(e().x=r.x,!0),e(e().y=r.y,!0),i()}var Wo=We('<img alt="" class="micrio-marker">'),Xo=We('<label data-scroll-through=""> </label>'),jo=We('<button data-scroll-through="" class="micrio-marker"><!> <!></button>'),Go=We("<div><!></div>"),Yo=We("<!> <!>",1);function Ho(t,e){var i,r,n,s,o,a,l,c,u,d,h,m;Te(e,!0);const[v,p]=ir(),f=()=>tr(_,"$current",v),g=()=>tr(C,"$tour",v),w=()=>tr(P,"$currentPopup",v),b=()=>tr($,"$_lang",v),y=()=>tr(S,"$isMobile",v),k=()=>tr(mo,"$ctx",v),T=ye("micrio"),{current:_,events:x,state:E,_lang:$,spaceData:A}=T,S=T.canvas.isMobile,I=E.markerHoverId,M=ye("inView"),L=ye("markerImages"),P=T.state.popup,C=E.tour;let D=or(e,"marker",15),R=or(e,"image",31,(()=>B(f()))),z=or(e,"forceHidden",3,!1),O=or(e,"coords",3,void 0),N=or(e,"overlapped",3,!1);D().tags||D(D().tags=[],!0);const F=L.has(D().id);!F&&R()&&L.set(D().id,R());const V=!(!R().isOmni||!(null==(i=R().$settings.omni)?void 0:i.sideLabels)||(null==(r=R().$settings._markers)?void 0:r.noTitles)),U=t=>t.steps.findIndex((t=>t.startsWith(D().id)))>=0,q=D().data??{},W=q._meta||{},X=R().$settings.omni;D().imageLayer&&D().imageLayer>((null==(n=null==X?void 0:X.layers)?void 0:n.length)??1)-1&&delete D().imageLayer,(null==(a=null==(o=null==(s=f())?void 0:s.$data)?void 0:o.markers)?void 0:a.find((t=>{var e,i;return(null==(i=null==(e=t.data)?void 0:e._micrioSplitLink)?void 0:i.markerId)==D().id&&"none"!=t.popupType})))&&(D(D().popupType="none",!0),D(D().noMarker=!0,!0)),"embedUrl"in D()&&D().embedUrl&&"embedInPopover"in D()&&D().embedInPopover&&D(D().popupType="popover",!0);const G=R().$settings._markers??{},H=!!R().$settings.doTourJumps,Z=D().tags.join(" "),K="cluster"==D().type,Q=!!G.noTitles||!!(null==X?void 0:X.sideLabels),tt=!!q.scales||!!R().$settings.markersScale,et=tt&&!!G.titlesNoScale,it=q._micrioSplitLink,rt=!!G.keepPopupsDuringTourTransitions,nt=/[?&]micrioNoTooltips/.test(location.search)||!!(null==X?void 0:X.sideLabels),st=W.gridAction,ot=(null==(c=null==(l=R().$settings)?void 0:l._markers)?void 0:c.autoStartTour)?T.wasm.images.map((t=>{var e,i;return"camera"in t?null==(i=null==(e=t.$data)?void 0:e.markerTours)?void 0:i.find(U):void 0})).filter((t=>!!t))[0]??(null==(u=null==A?void 0:A.markerTours)?void 0:u.find(U)):void 0,at=null==ot?void 0:ot.steps.findIndex((t=>t.startsWith(D().id))),lt=!!(null==(h=null==(d=R().$settings)?void 0:d._markers)?void 0:h.autoStartTourAtBeginning);let ht=!F&&(!!q.alwaysOpen||E.$marker==D())||(null==(m=E.$tour)?void 0:m.id)==(null==ot?void 0:ot.id)&&(null==ot?void 0:ot.currentStep)==(at??0);const mt=F&&R().state.$marker==D();let vt,pt,ft,gt=j(B(mt)),wt=j(B(mt)),bt=j(!1),yt=j(""),kt=j(0),Tt=j(0),_t=j(1),xt=!1;function Et(){var t,e;G.noMarkerActions||(null==(e=null==(t=jt(zt))?void 0:t.parentNode)||e.scrollTo(0,0),$t(),ft=setTimeout((()=>{const t=R().camera.getXY(D().x,D().y);!jt(gt)&&(t[0]<0||t[0]>=T.offsetWidth||t[1]<0||t[1]>=T.offsetHeight||R().is360&&t[3]>4)&&R().camera.flyToCoo([D().x,D().y],{speed:2,limit:!0}).catch((()=>{}))}),150))}function $t(){clearTimeout(ft)}const At=()=>I.set(D().id),St=()=>I.set(void 0);let It;async function Mt(){var t,e,i,r,n;if(K)return;if(R().state.$marker!=D())return R().state.marker.set(D());if(G.noMarkerActions)return;if(ot&&ot.id!=(null==(t=g())?void 0:t.id)){ot.initialStep=lt?0:at;const t=null==(e=ot.stepInfo)?void 0:e[0];if(lt&&t&&t.micrioId!=R().id){const e=null==(i=T.canvases[0])?void 0:i.grid;(null==e?void 0:e.images.find((e=>e.id==t.micrioId)))?T.current.set(e.image):T.open(t.micrioId)}if(C.set(ot),setTimeout((()=>W.gridAction=st),100),lt&&null!=at&&at>0)return void R().state.marker.set(void 0);await Xt()}ht=!1,Y(wt,!0),x.dispatch("marker-opened",D());const s=g()&&"steps"in g()&&g().isSerialTour&&g().printChapters&&g().steps.findIndex((t=>t.startsWith(D().id)))>=0&&D().videoTour;var o;s||(jt(Bt)?"popover"==D().popupType?(await Xt(),T.state.popover.set({marker:D(),image:R(),markerTour:g()&&"steps"in g()?g():void 0})):D().videoTour&&!g()&&(C.set(D().videoTour),(o=C,new Promise((t=>{let e;e=o.subscribe((i=>{null==i&&(e?e():Xt().then((()=>e())),t(i))}))}))).then((()=>R().state.marker.set(void 0)))):Xt().then((()=>P.set(D()))));const a=null==(r=q.micrioLink)?void 0:r.id;if(a&&Xt().then((()=>{R().camera.stop();const t=Cr(T,a);t&&(R(R().openedView=void 0,!0),R().state.marker.set(void 0)),T.open(a,{vector:null==t?void 0:t.vector})})),it&&!xt&&!R().opts.secondaryTo){const t=null==(n=T.canvases[0])?void 0:n.grid;(null==t?void 0:t.lastPromise)&&await t.lastPromise,It=setTimeout((()=>{it&&(pt=T.open(it.micrioId,{splitScreen:!0,splitTo:R(),isPassive:!(!it.follows||T.state.$tour),startView:it.view}),xt=!0)}),200)}}let Lt,Pt,Ct=j(!1);function Dt(){var t,e,i,r,n,s;if(R().is360&&tt)Y(yt,R().camera.getMatrix(D().x,D().y,1,1,0,0,0).join(","),!0);else{let o=jt(kt),a=jt(Tt);if(s=R().camera.getXYDirect(D().x,D().y,{radius:D().radius,rotation:D().rotation}),Y(kt,s[0],!0),Y(Tt,s[1],!0),Y(_t,s[2],!0),vt=s[3],R().is360)Y(bt,vt>0);else if(R().isOmni&&X){if(null!=jt(Wt)[0]&&null!=jt(Wt)[1]&&null!=D().rotation){const i=X.frames/((null==(t=X.layers)?void 0:t.length)??1);let r=((null==(e=R().swiper)?void 0:e.currentIndex)??0)-(jt(qt)??0);r>i/2&&(r-=i),r<-i/2&&(r+=i),Y(bt,r<=jt(Wt)[0]||r>=jt(Wt)[1],!0)}else X.distance&&Y(bt,vt<0);X.sideLabels&&!G.noTitles&&(null==(i=jt(Ft))?void 0:i.title)&&M&&(o!=jt(kt)||a!=jt(Tt))&&function(t,e){const i=T.canvas.element.offsetWidth,r=T.canvas.element.offsetHeight,n=!(t<0||t>i||e<0||e>r||jt(bt));(n||jt(Ct))&&M.update((r=>{const s=r.findIndex((([t])=>t==D()));return n?s>=0?r[s]=[D(),t/i,e]:r.push([D(),t/i,e]):s>=0&&r.splice(s,1),Y(Ct,n,!0),r}))}(jt(kt),jt(Tt))}R().$settings.clusterMarkers&&O()&&O().set(D().id,[jt(kt),jt(Tt),N()?Lt:Lt=null==(r=jt(Ot))?void 0:r.offsetWidth,N()?Pt:Pt=null==(n=jt(Ot))?void 0:n.offsetHeight])}}let Rt=j(void 0),zt=j(void 0),Ot=j(void 0);const Nt=ye("mediaPaused");Gi((()=>{var t,e;if(D().videoTour){const i="timeline"in D().videoTour?D().videoTour.timeline:null==(e=null==(t=D().videoTour.i18n)?void 0:t[b()])?void 0:e.timeline;(null==i?void 0:i.length)&&D(D().view=i[0].rect,!0)}const i=[R().state.marker.subscribe((t=>{"string"==typeof t&&t==D().id?R().state.marker.set(D()):t==D()?async function(){var t,e;if(jt(gt))return;if(Y(gt,!0),$t(),G.noMarkerActions)return;x.dispatch("marker-open",D()),!g()||"steps"in g()&&(U(g())||g().cannotClose)||(C.set(void 0),await Xt());const i=g()&&"steps"in g();jt(Bt)||i&&rt||(P.set(void 0),T.state.popover.set(void 0)),St(),(null==it?void 0:it.markerId)&&(pt||(pt=T.canvases.find((t=>t.id==it.micrioId))),pt&&(xt=Ki(pt.visible),xt&&(null==it?void 0:it.view)&&pt.camera.flyToView(it.view,{isJump:!0}).catch((()=>{})))),void 0!==D().imageLayer&&R().state.layer.set(D().imageLayer);const r=ot&&lt&&ot!=g()&&null!=at&&at>0;r&&delete W.gridAction,r||!D().view||q.noAnimate||D().videoTour||W.gridView?Mt():ht?(R().camera.setView(D().view,{area:null==(t=R().opts)?void 0:t.area}),Mt()):R().camera.flyToView(D().view,{omniIndex:jt(qt),noTrueNorth:!0,area:null==(e=R().opts)?void 0:e.area,isJump:!!q.doJump||H&&!!E.$tour}).then(Mt).catch((()=>{g()||R().state.marker.set(void 0)}))}():q.alwaysOpen||(jt(gt)&&function(){var t;if(clearTimeout(It),x.dispatch("marker-closed",D()),D().videoTour&&R().openedView?setTimeout((()=>R().camera.aniDoneAdd.push((()=>{var t;return null==(t=jt(Rt))?void 0:t.focus()}))),10):null==(t=jt(Rt))||t.focus(),T.state.popover.set(void 0),!jt(Bt)){const t=g()&&"steps"in g();w()!=D()||t&&rt||P.set(void 0);const e=T.canvases.find((t=>t!=R()&&t.state.$marker));e&&Xt().then((()=>{const t=e.state.$marker;t&&"popup"==t.popupType&&P.set(t)}))}it&&pt&&setTimeout((()=>{var t,e;const i=Ki(T.state.marker);pt&&it.micrioId!=(null==(e=null==(t=null==i?void 0:i.data)?void 0:t._micrioSplitLink)?void 0:e.micrioId)&&T.close(pt)}),210)}(),Y(gt,Y(wt,!1),!0))}))];return jt(Ut)||(i.push(R().camera.image.state.view.subscribe(Dt)),Dt()),z()||Xt().then((()=>{jt(gt)&&!D().noMarker&&w()&&w()!=D()&&!g()?R().state.marker.set(void 0):(ht||q.alwaysOpen)&&Mt()})),D().htmlElement&&jt(zt)&&jt(zt).appendChild(D().htmlElement),()=>{var t;for(clearTimeout(It);i.length;)null==(t=i.shift())||t()}}));let Ft=J((()=>D().i18n?D().i18n[b()]:D())),Vt=J((()=>{var t,e,i,r;return!((null==(t=jt(Ft))?void 0:t.title)||(null==(e=jt(Ft))?void 0:e.body)||(null==(i=jt(Ft))?void 0:i.bodySecondary)||(null==(r=jt(Ft))?void 0:r.embedUrl)||D().images&&D().images.length)})),Ut=J((()=>z()||D().noMarker)),Bt=J((()=>"popup"!=D().popupType||jt(Vt))),qt=J((()=>R().camera.getOmniFrame((D().rotation??0)+(D().backside?Math.PI:0)))),Wt=J((()=>D().visibleArc?[R().camera.getOmniFrame(D().visibleArc[0]),R().camera.getOmniFrame(D().visibleArc[1])]:[])),Gt=J((()=>g()&&(!("steps"in g())&&!g().keepMarkers||G.hideMarkersDuringTour&&!tr(Nt,"$tourPaused",v))&&!jt(gt)));ee((()=>{jt(Gt)&&jt(Ct)&&M.update((t=>{const e=t.findIndex((t=>t[0]==D()));return e>=0&&t.splice(e,1),t}))}));let Yt=J((()=>"default"==D().type?void 0:"link"==D().type?"link":"media"==D().type?"play":"cluster"==D().type?void 0:D().type??void 0)),Ht=J((()=>{var t,e,i,r,n;return(null!=(null==(t=D().data)?void 0:t.customIconIdx)?null==(r=null==(e=R().$settings._markers)?void 0:e.customIcons)?void 0:r[null==(i=D().data)?void 0:i.customIconIdx]:void 0)??(null==(n=D().data)?void 0:n.icon)??G.markerIcon??void 0})),Zt=J((()=>!!jt(Yt)||!!jt(Ht))),Kt=J((()=>!("class"in D()&&""===D().class||!jt(Zt)&&"default"!=D().type))),Jt=J((()=>jt(Ft)&&(!Q||y()&&V)&&(jt(Ft).label||jt(Ft).title)));var Qt=Yo(),te=ut(Qt),ie=t=>{var e=Go();let i;e.__change=[qo,D,Dt];var r=ct(e),n=t=>{var e=jo();e.__click=[Bo,$t,D,G,f,_,R];var i=ct(e),r=t=>{var e=Wo();se((()=>xi(e,"src",jt(Ht).src))),Ye(t,e)},n=(t,e)=>{var i=t=>{En(t,{get name(){return jt(Yt)}})};ei(t,(t=>{jt(Yt)&&t(i)}),e)};ei(i,(t=>{jt(Ht)?t(r):t(n,!1)}));var s=dt(i,2),o=t=>{var e=Xo();fi(e,1,"micrio-marker",null,{},{static:et});var i=ct(e);qi(e,(t=>Y(Ot,t)),(()=>jt(Ot))),se((()=>{xi(e,"for",D().id),Ke(i,jt(Ft).label||jt(Ft).title)})),Ye(t,e)};ei(s,(t=>{jt(Jt)&&t(o)})),qi(e,(t=>Y(Rt,t)),(()=>jt(Rt))),se((()=>{xi(e,"title",nt||K?null:jt(Ft)?jt(Ft).label||jt(Ft).title:null),xi(e,"id",D().id)})),Fe("focus",e,Et),Fe("blur",e,$t),Fe("mouseenter",e,At),Fe("mouseleave",e,St),Ye(t,e)};ei(r,(t=>{D().htmlElement||t(n)})),qi(e,(t=>Y(zt,t)),(()=>jt(zt))),se((t=>{xi(e,"id",`m-${D().id}`),i=fi(e,1,hi(Z),"micrio-marker",i,t),wi(e,jt(yt)?`--mat:matrix3d(${jt(yt)})`:jt(kt)?`--x:${jt(kt)}px;--y:${jt(Tt)}px${tt?`;--scale:${jt(_t)}`:""}`:null)}),[()=>({overlapped:N()&&!jt(gt),cluster:K,behind:jt(bt),hovered:tr(I,"$hovered",v)==D().id,default:jt(Kt),mat3d:!!jt(yt),opened:jt(gt),"micrio-link":!!q.micrioLink,"has-icon":jt(Zt),"has-custom-icon":!!jt(Ht)})]),Ye(t,e)};ei(te,(t=>{jt(Ut)||!R()||jt(Gt)||t(ie)}));var re=dt(te,2),ne=t=>{Uo(0,{get marker(){return D()},get ctx(){return k()},get is360(){return R().is360}})};ei(re,(t=>{D().positionalAudio&&k()&&(!D().positionalAudio.noMobile||y())&&(D().positionalAudio.alwaysPlay||jt(gt))&&t(ne)})),Ye(t,Qt),_e(),p()}Ve(["change","click"]);var Zo=We("<div><!></div>");function Ko(t,e){var i,r;Te(e,!0);const[n,s]=ir(),o=()=>tr(u,"$_lang",n);let a=or(e,"settings",31,(()=>B({i18n:{}}))),l=or(e,"image",15);const c=ye("micrio"),{_lang:u,spaceData:d}=c,h=l().$info,m=l().$settings,v=null==(i=_r(e.targetId))?void 0:i[2],p=Cr(c,e.targetId);p||console.error(`[Micrio Waypoint] Could not calculate vector for target ${e.targetId}`);const{directionX:f,v:g,vN:w,vector:b}=p;let y=j(void 0);const k=Math.abs(w[1])<.3,T=k?.65:.5+w[1]/10,_={x:f,y:T,baseScale:h.width/1024,scale:1,rotX:(1+(k?-(1-T):w[1]))*Math.PI/2,rotY:0,rotZ:0},x=(null==(r=a())?void 0:r.coords)??(E=_,JSON.parse(JSON.stringify(E)));var E;let $,A=x.custom,S=A?x:_;function I(){var t;(null==(t=m._markers)?void 0:t.noMarkerActions)||(jt(y).parentNode.scrollTo(0,0),clearTimeout($),$=setTimeout((()=>{const t=l().camera.getXY(S.x,S.y);!jt(C)&&(t[0]<0||t[0]>=c.offsetWidth||t[1]<0||t[1]>=c.offsetHeight||l().is360&&t[3]>4)&&l().camera.flyToCoo([S.x,S.y],{speed:2,limit:!0}).catch((()=>{}))}),150))}let M=j(""),L=a().customIconIdx;const P=()=>{z.deleted?Y(R,!0):(L!=z.settings.customIconIdx&&(a(a().customIconIdx=z.settings.customIconIdx,!0),L=a().customIconIdx),x.custom!=A&&(A=x.custom,S=A?x:_),Y(M,l().camera.getMatrix(S.x,S.y,S.baseScale*S.scale,1,S.rotX,S.rotY,S.rotZ).join(","),!0))};let C=j(!1);function D(){var t;(null==(t=m._markers)?void 0:t.noMarkerActions)||(Y(C,!0),l(l().openedView=void 0,!0),l().state.marker.set(void 0),c.open(e.targetId,{vector:b}))}let R=j(!1);const z={coords:x,settings:a()};P(),Gi((()=>{z.el=jt(y),jt(y)._iface=z,c.dispatchEvent(new CustomEvent("wp-print",{detail:z}));const t=l().state.view.subscribe(P);return()=>t()}));let O=J((()=>{var t,e,i,r;return(null==(e=null==(t=a().i18n)?void 0:t[o()])?void 0:e.title)||(null==(r=null==(i=null==v?void 0:v.i18n)?void 0:i[o()])?void 0:r.title)})),N=J((()=>{var t;return null==(t=null==d?void 0:d.icons)?void 0:t[a().customIconIdx??-1]}));var F=Ge(),V=ut(F),U=t=>{var i=Zo();let r;var s=ct(i);const o=J((()=>jt(N)?void 0:"arrow-up")),a=J((()=>jt(O)??tr(Xr,"$i18n",n).waypointFollow));zn(s,{get type(){return jt(o)},get icon(){return jt(N)},onclick:D,onfocus:I,get title(){return jt(a)}}),qi(i,(t=>Y(y,t)),(()=>jt(y))),se((t=>{wi(i,`--matrix: matrix3d(${jt(M)??""})`),xi(i,"id",`w-${e.targetId}`),r=fi(i,1,"micrio-waypoint",null,r,t)}),[()=>({clicked:jt(C),active:jt(C),"direction-up":g[1]<0,"direction-down":g[1]>0})]),zi(3,i,(()=>Nr)),Ye(t,i)};ei(V,(t=>{jt(R)||t(U)})),Ye(t,F),_e(),s()}var Jo=Xe("<line></line>"),Qo=We('<article class="micrio-markers"><label> </label></article>'),ta=We('<article class="micrio-markers"><label> </label></article>'),ea=We('<svg class="micrio-markers"></svg> <aside class="micrio-markers"><section class="micrio-markers"></section> <section class="micrio-markers"></section></aside>',1),ia=We("<!> <!>",1),ra=We("<div><!> <!></div>"),na=We("<!> <!> <!>",1);function sa(t,e){var i;Te(e,!0);const[r,n]=ir(),s=()=>tr(v,"$settings",r),o=()=>tr($,"$inView",r),a=()=>tr(E,"$hoveredId",r),l=()=>tr(g,"$switching",r),c=()=>tr(h,"$data",r),u=()=>tr(w,"$_lang",r);let d=or(e,"image",15);const{data:h,info:m,settings:v}=d(),p=d().state.marker,f=d().wasm.micrio,{switching:g,_lang:w,state:b}=f,y=f.canvas.isMobile,k=null==(i=f.canvases[0])?void 0:i.grid,T=null==k?void 0:k.focussed,_=null==k?void 0:k.markersShown,x=s().clusterMarkerRadius??16,E=b.markerHoverId,$=Zi([]);ke("inView",$);const A=s()._markers??{},S=s().omni,I=!(!!A.noTitles||!!(null==S?void 0:S.sideLabels))&&!!A.showTitles;function M(t){var e;t?"string"==typeof t||d().openedView||t.noMarker||!t.view||d(d().openedView=f.state.$tour||null==(e=d().state.$view)?void 0:e.slice(0),!0):d().openedView&&!f.state.$tour&&Xt().then((()=>{var t,e;jt(K)||d().camera.aniDone||!d().openedView||d().camera.flyToView((e=d().openedView,[Math.max(0,e[0]),Math.max(0,e[1]),Math.min(1,e[2]),Math.min(1,e[3])]),{speed:null==(t=s()._markers)?void 0:t.zoomOutAfterCloseSpeed,noTrueNorth:!0}).catch((()=>{})),d(d().openedView=void 0,!0)}))}b.tour.subscribe((t=>{t&&"steps"in t&&t.keepLastStep&&d(d().openedView=void 0,!0)}));const L=[];let P=j(""),C=j(!1),D=j(!1);const R=t=>(t=null==t?void 0:t.map((t=>Math.round(100*t)/100)))&&Y(P,[...L,t[0]?`left: ${t[0]}px`:null,t[1]?`top: ${t[1]}px`:null,`width: ${t[2]}px`,`height: ${t[3]}px`].filter((t=>!!t)).join(";")+";");let z=j(B([])),O=x,N=j(B([]));const F=new Map,V=([t,e,i=0,r=0],[n,s,o=0,a=0])=>{const l=Math.max(r/2,O),c=Math.max(a/2,O);return!(t+i+O<n-O||t-O>n+o+O||e+l<s-c||e-l>s+c)},U=()=>{var t;if(!jt(tt))return Y(z,[],!0),void Y(N,[],!0);const e=jt(tt),i=[],r=e.length;let n=0,s=0;for(Y(z,[],!0),n=0;n<r;n++)for(s=n+1;s<r;s++){if(null==(t=e[s].tags)?void 0:t.includes("no-cluster"))continue;const r=F.get(e[n].id),o=F.get(e[s].id);if(r&&o&&V(r,o)){jt(z).push(n,s);const t=i.find((t=>t.findIndex((t=>t==n||t==s))>-1));t?t.push(n,s):i.push([n,s])}}Y(N,i.map((t=>t.filter(((e,i)=>t.indexOf(e)==i)))).map(((t,i)=>({title:t.length+"",type:"cluster",view:i=[0,1,2,3].map((i=>(i<2?Math.min:Math.max)(...t.map((t=>{var r;return(null==(r=e[t].view)?void 0:r[i])??(i%2==0?e[t].x:e[t].y)}))))),x:i[0]+(i[2]-i[0])/2,y:i[1]+(i[3]-i[1])/2,id:""+t,data:{},popupType:"none",tags:[]}))),!0)},q=[];Gi((()=>{const t=[];return br(m).then((e=>{var i,r,n;if(!e)return;Y(C,!!e.is360);const o=s()._markers;if(!o)return;const a=Number(e.version)>=4.2;o.markerIcon&&L.push(`--micrio-marker-icon: url("${o.markerIcon}")`),o.markerColor&&o.markerColor!=(a?"#ffffff":"#ffbb00")&&L.push("--micrio-marker-color: "+o.markerColor),o.markerSize&&o.markerSize!=(a?"16":"25")&&L.push("--micrio-marker-size: "+(O=Number(o.markerSize))+"px"),t.push(d().viewport.subscribe(R)),s().clusterMarkers&&(t.push(d().state.view.subscribe(U)),t.push(d().data.subscribe((()=>Xt().then(U))))),!d().grid&&(null==(i=s()._markers)?void 0:i.zoomOutAfterClose)&&t.push(d().state.marker.subscribe(M));!(!d().isOmni||!(null==(r=s().omni)?void 0:r.sideLabels)||(null==(n=s()._markers)?void 0:n.noTitles))&&t.push(y.subscribe((t=>{t&&jt(D)?function(){for(var t;q.length;)null==(t=q.shift())||t()}():t||jt(D)||(q.push(d().state.view.subscribe(H)),q.push(E.subscribe(H)),q.push(p.subscribe(H))),Y(D,!t)})))})),()=>{for(var e;t.length;)null==(e=t.shift())||e()}}));const W=t=>!t.noMarker;let X=j(void 0),G=j(B([]));function H(){Xt().then((()=>{if(!jt(X))return;const t=f.canvas,e=t.element.offsetWidth,i=[];o().forEach((([r,n,s])=>{var o;const l=null==(o=jt(X).querySelector('label[for="'+r.id+'"]'))?void 0:o.getBoundingClientRect();(null==l?void 0:l.width)&&l.width>0&&i.push([n*e,s,(n>=.5?l.left:l.right)-t.viewport.left,l.top+l.height/2-t.viewport.top,a()==r.id])})),Y(G,i,!0)}))}const Z=(t,e)=>{var i;return t.i18n?null==(i=t.i18n[e])?void 0:i.title:t.title};let K=J((()=>k&&tr(T,"$focussed",r)!=d()&&_&&Ki(_).indexOf(d())<0)),Q=J((()=>!l()&&f.spaceData?f.spaceData.links.filter((t=>t[0]==d().id||t[1]==d().id)).map((t=>{var e;return{targetId:t[0]==d().id?t[1]:t[0],settings:null==(e=t[2])?void 0:e[d().id]}})):void 0)),tt=J((()=>{var t,e;return jt(K)?[]:null==(e=null==(t=c())?void 0:t.markers)?void 0:e.filter(W)})),et=J((()=>{var t,e,i;return jt(K)?null==(t=c())?void 0:t.markers:null==(i=null==(e=c())?void 0:e.markers)?void 0:i.filter((t=>!W(t)))})),it=J((()=>{var t,e;return!(!(null==(t=jt(tt))?void 0:t.length)&&!(null==(e=jt(Q))?void 0:e.length))})),rt=J((()=>o().sort((([,,t],[,,e])=>t>e?1:t<e?-1:0))));var nt=na(),st=ut(nt),ot=t=>{var e=ea(),i=ut(e);ri(i,21,(()=>jt(G)),ii,((t,e)=>{var i=Jo();let r;se((t=>{xi(i,"x1",jt(e)[0]),xi(i,"y1",jt(e)[1]),xi(i,"x2",jt(e)[2]),xi(i,"y2",jt(e)[3]),r=fi(i,0,"micrio-markers",null,r,t)}),[()=>({hovered:jt(e)[4]})]),Ye(t,i)}));var r=dt(i,2),n=ct(r);ri(n,21,(()=>jt(rt).filter((([,t])=>t<.5))),(t=>t[0].id),((t,e)=>{var i=Qo(),r=ct(i);let n;var s=ct(r);se(((t,i)=>{xi(r,"for",jt(e)[0].id),n=fi(r,1,"micrio-markers",null,n,t),Ke(s,i)}),[()=>({hover:a()==jt(e)[0].id}),()=>Z(jt(e)[0],u())]),Fe("mouseenter",r,(()=>E.set(jt(e)[0].id))),Fe("mouseleave",r,(()=>E.set(void 0))),Ye(t,i)})),ri(dt(n,2),21,(()=>jt(rt).filter((([,t])=>t>=.5))),(t=>t[0].id),((t,e)=>{var i=ta(),r=ct(i);let n;var s=ct(r);se(((t,i)=>{xi(r,"for",jt(e)[0].id),n=fi(r,1,"micrio-markers",null,n,t),Ke(s,i)}),[()=>({hover:a()==jt(e)[0].id}),()=>Z(jt(e)[0],u())]),Fe("mouseenter",r,(()=>E.set(jt(e)[0].id))),Fe("mouseleave",r,(()=>E.set(void 0))),Ye(t,i)})),qi(r,(t=>Y(X,t)),(()=>jt(X))),Ye(t,e)};ei(st,(t=>{jt(D)&&jt(rt).length&&!tr(p,"$currentMarker",r)&&t(ot)}));var at=dt(st,2),lt=t=>{var e=ra();let i;var r=ct(e),n=t=>{var e=Ge();ri(ut(e),17,(()=>jt(Q)),(t=>t.targetId),((t,e)=>{Ko(t,nr({get image(){return d()}},(()=>jt(e))))})),Ye(t,e)};ei(r,(t=>{jt(Q)&&jt(Q).length&&t(n)}));var s=dt(r,2),o=t=>{var e=ia(),i=ut(e);ri(i,19,(()=>jt(tt)),(t=>t.id),((t,e,i)=>{const r=J((()=>jt(z).includes(jt(i))));Ho(t,{get marker(){return jt(e)},get image(){return d()},coords:F,get overlapped(){return jt(r)}})})),ri(dt(i,2),17,(()=>jt(N)),(t=>t.id),((t,e)=>{Ho(t,{get marker(){return jt(e)},get image(){return d()}})})),Ye(t,e)};ei(s,(t=>{jt(tt)&&t(o)})),se((t=>{wi(e,jt(it)?jt(P):null),i=fi(e,1,"micrio-markers",null,i,t)}),[()=>({"show-titles":I,is360:jt(C),inactive:jt(K)||jt(C)&&l()})]),Ye(t,e)};ei(at,(t=>{jt(it)&&t(lt)}));var ht=dt(at,2),mt=t=>{var e=Ge();ri(ut(e),17,(()=>jt(et)),(t=>t.id),((t,e)=>{Ho(t,{get marker(){return jt(e)},get image(){return d()},forceHidden:!0})})),Ye(t,e)};ei(ht,(t=>{jt(et)&&t(mt)})),Ye(t,nt),_e(),n()}const oa="5.3.1",aa="https://b.micr.io/",la="https://r2.micr.io/",ca=["ttBWO","IicaE","KLTce","xjQrB","pfhXT","rNIPa","rdFIY","mvRXc"],ua={b64:_b,ugz:_u},da="micrio-muted",ha={id:"",version:Number(oa.replace(/(\d+)\.(\d+).*/,"$1.$2")),path:aa,width:0,height:0,tileSize:1024,lang:"en",settings:{camspeed:1,view:[0,0,1,1],restrict:[0,0,1,1],focus:[.5,.5],zoomLimit:1,fullscreen:!0,crossfadeDuration:.25,hookEvents:!0,hookScroll:!0,hookPinch:!0,hookDrag:!0,minimap:!0,doTourJumps:!0,audio:!0,startVolume:1,mutedVolume:0,_markers:{showTitles:!1,popupAnimation:{duration:200,x:-50},zoomOutAfterClose:!0},ui:{controls:{cultureSwitch:!0}},_360:{},_meta:{}}},ma={STRINGS:{id:{r:!0},lang:{r:!0},"data-thumb":{f:"thumbSrc"},"data-title":{r:!0},"data-format":{r:!0},"data-extension":{r:!0,f:"tileExtension"},"data-tiles":{r:!0,f:"tilesId"},"data-path":{r:!0},"data-sources":{r:!0},"data-inittype":{f:"initType"},"data-type":{},"data-start":{f:"gallery.startId"},"data-gallery":{f:"gallery.archive"},"data-gallery-sort":{f:"gallery.sort"},"data-iiif":{r:!0,f:"iiifManifest"},"data-grid":{r:!0},"data-gallery-type":{f:"gallery.type"}},BOOLEANS:{"data-static":{},muted:{f:"audio",n:!0},"data-png":{r:!0,f:"isPng"},"data-webp":{r:!0,f:"isWebP"},"data-dz":{r:!0,f:"isDeepZoom"},"data-is360":{r:!0},"data-no-externals":{f:"noExternals"},"data-skipmeta":{f:"skipMeta"},"data-force-data-refresh":{f:"forceDataRefresh"},"data-keeprendering":{f:"keepRendering"},"data-coverlimit":{f:"limitToCoverScale"},"data-events":{f:"hookEvents"},"data-keys":{f:"hookKeys"},"data-zooming":{f:"noZoom",n:!0},"data-scroll-zoom":{f:"hookScroll"},"data-pinch-zoom":{f:"hookPinch"},"data-dragging":{f:"hookDrag"},"data-two-finger-pan":{f:"twoFingerPan"},"data-control-zoom":{f:"controlZoom"},"data-ui":{f:"noUI",n:!0},"data-gtag":{f:"noGTag",n:!0},"data-controls":{f:"noControls",n:!0},"data-logo":{f:"noLogo",n:!0},"data-logo-org":{f:"noOrgLogo",n:!0},"data-toolbar":{f:"noToolbar",n:!0},"data-show-info":{f:"showInfo"},"data-social":{},"data-fullscreen":{},"data-minimap":{},"data-minimap-hide":{f:"alwaysShowMinimap",n:!0},"data-omni-y":{f:"OmniTwoAxes"},"data-normalize-dpr":{f:"zoomLimitDPRFix"},"data-grid-clickable":{f:"gridClickable"},"data-gallery-spreads":{f:"gallery.isSpreads"},"data-freemove":{f:"freeMove"},"data-force-path":{f:"forceInfoPath",r:!0}},NUMBERS:{"data-version":{r:!0},height:{r:!0},width:{r:!0},volume:{f:"startVolume"},"data-tilesize":{r:!0,f:"tileSize"},"data-camspeed":{},"data-zoomlimit":{f:"zoomLimit"},"data-minimap-height":{f:"minimapHeight"},"data-minimap-width":{f:"minimapWidth"},"data-mutedvolume":{f:"mutedVolume"},"data-width-cm":{f:"cmWidth"},"data-height-cm":{f:"cmHeight"},"data-gallery-cover-pages":{f:"gallery.coverPages"},lazyload:{dN:0},"data-elasticity":{f:"dragElasticity"},"data-skip-base-levels":{f:"skipBaseLevels"}},ARRAYS:{"data-focus":{},"data-view":{}}};var va,pa,fa,ga,wa,ba,ya;pa=va||(va={}),fa=pa.Grid||(pa.Grid={}),(ga=fa.GridActionType||(fa.GridActionType={}))[ga.focus=0]="focus",ga[ga.flyTo=1]="flyTo",ga[ga.focusWithTagged=2]="focusWithTagged",ga[ga.focusTagged=3]="focusTagged",ga[ga.reset=4]="reset",ga[ga.back=5]="back",ga[ga.switchToGrid=6]="switchToGrid",ga[ga.filterTourImages=7]="filterTourImages",ga[ga.nextFadeDuration=8]="nextFadeDuration",wa=pa.Camera||(pa.Camera={}),(ba=wa.TimingFunction||(wa.TimingFunction={}))[ba.ease=0]="ease",ba[ba["ease-in"]=1]="ease-in",ba[ba["ease-out"]=2]="ease-out",ba[ba.linear=3]="linear";class ka{constructor(t){var e;if(this.image=t,this.center=[0,0,1],this.trueNorth=.5,this.aniDoneAdd=[],this.cooToArea=(t,e,i)=>({x:i[0]+t*(i[2]-i[0]),y:i[1]+e*(i[3]-i[1])}),this.viewToArea=(t,e)=>[...Object.values(this.cooToArea(t[0],t[1],e)),...Object.values(this.cooToArea(t[2],t[3],e))],this.getView=()=>{var t;return null==(t=this._view)?void 0:t.slice(0)},this.getCoo=(t,e,i=!1,r=!1)=>this.getCooDirect(t,e,i,r).slice(0).map((t=>Math.round(1e6*t)/1e6)),this.getXY=(t,e,i=!1,r,n,s)=>this.getXYDirect(t,e,{abs:i,radius:r,rotation:n,noTrueNorth:s}).slice(0),this.getScale=()=>this.center[2]??1,this.setScale=t=>this.setCoo(this.center[0],this.center[1],t),this.getCoverScale=()=>{var t;return(null==(t=this.e)?void 0:t._getCoverScale(this.image.ptr))??1},this.getMinScale=()=>{var t;return(null==(t=this.e)?void 0:t._getMinScale(this.image.ptr))??.1},this.isZoomedIn=()=>{var t;return 1==(null==(t=this.e)?void 0:t._isZoomedIn(this.image.ptr))},this.isZoomedOut=(t=!1)=>{var e;return 1==(null==(e=this.e)?void 0:e._isZoomedOut(this.image.ptr,t))},this.getCoverLimit=()=>{var t;return!!(null==(t=this.e)?void 0:t._getCoverLimit(this.image.ptr))},this.flyToView=(t,e={})=>new Promise(((i,r)=>{var n,s;if(!this.e)return r(new Error("Wasm not ready"));if(e.area&&(t=this.viewToArea(t,e.area)),e.prevView){const t=e.prevView;this.e._setStartView(this.image.ptr,t[0],t[1],t[2],t[3])}if(null==(n=this.image.$settings.omni)?void 0:n.frames){const i=(null==(s=this.image.$settings.omni.layers)?void 0:s.length)??1,r=this.image.$settings.omni.frames/i;null==e.omniIndex&&void 0!==t[5]&&(e.omniIndex=Math.round(lr(t[5]/(2*Math.PI))*r)),null!=e.omniIndex&&(e.omniIndex=lr(e.omniIndex,r))}const o=this.e._flyTo(this.image.ptr,t[0],t[1],t[2],t[3],e.duration??-1,e.speed??-1,e.progress??0,!!e.isJump,!!e.limit,!!e.limitZoom,e.omniIndex??0,!!e.noTrueNorth,va.Camera.TimingFunction[e.timingFunction??"ease"],performance.now());this.image.wasm.render(),0==o?i():this.setAniPromises(i,r)})),this.flyToFullView=(t={})=>this.flyToCoo([.5,.5,this.getMinScale()],t),this.flyToCoverView=(t={})=>{const e=this.image.$settings.focus??[.5,.5];return e[2]=this.getCoverScale(),this.flyToCoo(e,t)},this.flyToCoo=(t,e={})=>new Promise(((i,r)=>{if(!this.e)return r(new Error("Wasm not ready"));e.duration=this.e._setCoo(this.image.ptr,t[0],t[1],t[2]||this.center[2],e.duration??-1,e.speed??-1,e.limit??!1,va.Camera.TimingFunction[e.timingFunction??"ease"],performance.now()),this.image.wasm.render(),0==e.duration?i():this.setAniPromises(i,r)})),this.zoom=(t,e=0,i=void 0,r=void 0,n=1,s=!1)=>new Promise(((o,a)=>{if(!this.e)return a(new Error("Wasm not ready"));const l=this.getXY(this.center[0],this.center[1]);if(null==i&&(i=l[0]),null==r&&(r=l[1]),this.image.album&&!this.image.album.hooked)return o();e=this.e._zoom(this.image.ptr,t,i,r,e,n,s,performance.now()),this.image.wasm.render(),0==e?o():this.setAniPromises(o,a)})),this.zoomIn=(t=1,e=250,i=1)=>this.zoom(200*-t,e,void 0,void 0,i).catch((()=>{})),this.zoomOut=(t=1,e=250,i=1)=>{const r=this.image.wasm.micrio.canvas.viewport,n=r.width/r.height,s=this.image.$info.width/this.image.$info.height;return this.zoom(t*(400/Math.max(1,n/s/2)),e,void 0,void 0,i).catch((()=>{}))},this.getDirection=()=>{var t;return(null==(t=this.e)?void 0:t._getYaw(this.image.ptr))??0},this.getPitch=()=>{var t;return(null==(t=this.e)?void 0:t._getPitch(this.image.ptr))??0},!t.is360){const i=t.state.$view;i&&(null==(e=t.$info)?void 0:e.width)&&Xt().then((()=>this.setView(i)))}}assign(t,e,i,r,n,s){this.e=t,this._view=e,this._xy=i,this._coo=r,this._mat=n,this._quad=s}viewChanged(){var t;const e=this._view,i=this.center.join(","),r=this.getCoo(0,0);this.center[0]=e[0]+(e[2]-e[0])/2,this.center[1]=e[1]+(e[3]-e[1])/2,this.center[2]=r[2],this.image.is360&&(this.center[3]=r[3],this.center[4]=r[4]),this.image.isOmni&&(this.center[5]=null==(t=this.image.swiper)?void 0:t.currentIndex),(this.center.join(",")!=i||this.image.wasm.micrio.canvas.resizing||this.image.wasm.e._areaAnimating(this.image.ptr))&&this.image.state.view.set(this._view)}getXYDirect(t,e,i={}){var r;const n=this.image.is360&&!i.noTrueNorth?.5-((null==(r=this.image.$settings._360)?void 0:r.trueNorth)??.5):0;return this.e._getXY(this.image.ptr,t-n,e,!0===i.abs,i.radius,i.rotation),this._xy}getCooDirect(t,e,i=!1,r=!1){if(i){const i=this.image.wasm.micrio.getBoundingClientRect();t-=i.left,e-=i.top}return this.e._getCoo(this.image.ptr,t,e,!0===i,!0===r),this._coo}setView(t,e={}){this.e&&(e.area&&(t=this.viewToArea(t,e.area)),this.e._setView(this.image.ptr,t[0],t[1],t[2],t[3],!!e.noLimit,!1,e.correctNorth),e.noRender||this.image.wasm.render())}setCoo(t,e,i=this.center[2]??1){this.e&&(this.e._setCoo(this.image.ptr,t,e,i,0,0),this.image.wasm.render())}getQuad(t,e,i,r,n=0,s=0,o=0,a=1,l=1){return this.e?(this.e._getQuad(this.image.ptr,t,e,i,r,a,l,n,s,o),this._quad):new Float32Array(16)}getMatrix(t,e,i,r,n,s,o,a,l,c){return this.e?(this.e._getMatrix(this.image.ptr,t,e,i,r,n||0,s||0,o||0,a||0,l??1,c??1),this._mat):new Float32Array(16)}setMinScale(t){var e;null==(e=this.e)||e._setMinScale(this.image.ptr,t)}setMinScreenSize(t){var e;this.image.album||null==(e=this.e)||e._setMinSize(this.image.ptr,Math.max(0,Math.min(1,t??1)))}setLimit(t){this.e&&(this.e._setLimit(this.image.ptr,t[0],t[1],t[2],t[3]),this.image.wasm.render())}setCoverLimit(t){this.e&&this.e._setCoverLimit(this.image.ptr,!!t)}set360RangeLimit(t=0,e=0){this.e&&(this.e._set360RangeLimit(this.image.ptr,t,e),this.image.wasm.render())}setAniPromises(t,e){this.aniDone=t,this.aniAbort=e}pan(t,e,i=0,r={}){this.e&&(this.e._pan(this.image.ptr,t,e,i,!!r.noLimit,performance.now()),r.render&&this.image.wasm.render())}stop(){this.e&&this.e._aniStop(this.image.ptr)}pause(){this.e&&this.e._aniPause(this.image.ptr,performance.now())}resume(){this.e&&(this.e._aniResume(this.image.ptr,performance.now()),this.image.wasm.render())}aniIsKinetic(){var t;return!!(null==(t=this.e)?void 0:t._isKinetic(this.image.ptr))}setDirection(t,e){if(!this.e)return;const i=this.image.wasm;i.e._setDirection(this.image.ptr,t,e),i.render()}setArea(t,e={}){if(!this.e)return;const i=this.image.wasm.e;this.image.opts.isEmbed?this.image.ptr>0&&(this.image.opts.area=t,i._setImageArea(this.image.ptr,t[0],t[1],t[2],t[3])):(this.image.opts.area=t,i._setArea(this.image.ptr,t[0],t[1],t[2],t[3],!!e.direct,!!e.noDispatch)),e.noRender||this.image.wasm.render()}setRotation(t=0,e=0,i=0){!this.image.opts.isEmbed||this.image.ptr<=0||!this.e||(this.image.wasm.e._setImageRotation(this.image.ptr,t,e,i),this.image.wasm.render())}getOmniRotation(){var t,e;const i=this.image.$settings.omni;return i&&this.e?((null==(t=this.image.swiper)?void 0:t.currentIndex)??0)/(((null==i?void 0:i.frames)??1)/((null==(e=null==i?void 0:i.layers)?void 0:e.length)??1))*Math.PI*2:0}getOmniFrame(t){var e;const i=this.image.$settings.omni;if(!i||null==t)return;const r=i.frames/((null==(e=i.layers)?void 0:e.length)??1);return Math.floor(t/(2*Math.PI)*r)}getOmniXY(t,e,i){return this.e?(this.e._getOmniXY(this.image.ptr,t,e,i),this._xy):new Float64Array(5)}setOmniSettings(){const t=this.image,e=t.$settings.omni;e&&this.e&&(t.wasm.e._setOmniSettings(t.ptr,-e.distance||0,e.fieldOfView??0,e.verticalAngle??0,e.offsetX??0),this.image.state.view.set(this._view))}}(t=>{t.Main=class{constructor(t){this.micrio=t,this.tour=Zi(),this.marker=Zi(),this.markerHoverId=Zi(),this.popup=Zi(),this.popover=Zi(),this.ui={controls:Zi(!0),zoom:Zi(!0),hidden:Zi(!1)},this.mediaState=new Map,this.tour.subscribe((t=>{"string"!=typeof t&&(this._tour=t)})),this.marker.subscribe((t=>{"string"!=typeof t&&(this._marker=t)}))}get $tour(){return this._tour}get $marker(){return this._marker}get(){if(this.micrio.$current)return this.value={id:this.micrio.$current.id,c:this.micrio.canvases.map((t=>t.state.get()))},this._tour&&(this.value.t=[this._tour.id],"instance"in this._tour&&this._tour.instance&&this.value.t.push(this._tour.instance.currentTime,this._tour.instance.paused?"p":void 0)),this.value}async set(t){var e,i,r;if(this.value=t){if(void 0!==(null==(e=t.t)?void 0:e[1])){const e=t.t[0],i=this.mediaState.get(e);i?(i.currentTime=t.t[1],i.paused="p"==t.t[2]):this.mediaState.set(e,{currentTime:t.t[1],paused:"p"==t.t[2]})}if(null==(i=t.c)||i.forEach((t=>{if(void 0!==t[6]&&void 0!==t[7]){const e=t[6],i=this.mediaState.get(e);i?(i.currentTime=t[7],i.paused="p"==t[8]):this.mediaState.set(e,{currentTime:t[7],paused:"p"==t[8]})}})),t.t&&await this.setTour(t.t[0]),(null==(r=this.micrio.$current)?void 0:r.id)!=t.id&&(this.micrio.open(t.id),this.micrio.$current&&await br(this.micrio.$current.data,{allowUndefined:!0})),this.micrio.canvases.forEach((e=>{e.state.set(t.c.find((t=>t[0]==e.id)))})),t.t)return this.setTour(t.t[0]);{const e=t.c.find((e=>e[0]==t.id));e&&!e[5]&&this.micrio.$current&&this.micrio.$current.camera.flyToView(e.slice(1,5),{speed:2}).catch((()=>{}))}}}async setTour(t){var e,i,r;if(!this.micrio.$current||(null==(e=this._tour)?void 0:e.id)==t)return;const n=await br(this.micrio.$current.data,{allowUndefined:!0});n&&this.tour.set((null==(i=n.markerTours)?void 0:i.find((e=>e.id==t)))||(null==(r=n.tours)?void 0:r.find((e=>e.id==t))))}};t.Image=class{constructor(t){this.image=t,this.view=Zi(void 0),this.marker=Zi(void 0),this.layer=Zi(0);const e=t.wasm.micrio;let i,r,n;this.view.subscribe((s=>{this._view=s;const o=null==s?void 0:s.toString(),a={image:t,view:s};if(s&&o&&i!=o){i=o;const t=s[2]-s[0],l=s[3]-s[1];(!r||!n||Math.abs(t-r+(l-n))>1e-5)&&(e.events.dispatch("zoom",a),r=t,n=l),e.events.dispatch("move",a)}})),this.marker.subscribe((t=>{const i=this._marker;this._marker=t&&"string"!=typeof t?t:void 0,this._marker?e.state.marker.set(this._marker):t||e.state.$marker!=i||e.state.marker.set(void 0)}))}get $view(){return this._view}get $marker(){return this._marker}hookOmni(){const t=this.image;this.layer.subscribe((e=>{t.ptr<0||!t.wasm.e||(t.wasm.setActiveLayer(t.ptr,e),t.wasm.render())}))}get(){const t=this._marker,e=t?Array.from(this.image.wasm.micrio.state.mediaState).reverse().find((e=>e[0].startsWith(t.id))):null;return[this.image.id,...this._view?[].slice.call(this._view):[0,0,1,1],...t?[t.id,...e?[e[0],e[1].currentTime,e[1].paused?"p":void 0]:[]]:[void 0]].filter((t=>void 0!==t))}set(t){var e;(null==t?void 0:t.length)&&(this.view.set([t[1],t[2],t[3],t[4]]),t[5]?(null==(e=this._marker)?void 0:e.id)!=t[5]&&this.marker.set(t[5]):this._marker&&this.marker.set(void 0))}}})(ya||(ya={}));const Ta=new class{constructor(){this.data=new Map,this.db=new Map,this.images=[],this.get=t=>new Promise(((e,i)=>{const r=this.db.get(t);if(!r||!this.data.has(r[0]))return i(new Error("Could not get blob: "+t));const n=new FileReader;n.onload=()=>e(JSON.parse(n.result)),n.readAsText(new Blob([new Uint8Array(this.data.get(r[0]),r[1],r[2])]))})),this.getImage=async t=>new Promise(((e,i)=>{const r=this.db.get(t);if(!r||!this.data.has(r[0]))return i(new Error("Could not get blob: "+t));const n=new Blob([new Uint8Array(this.data.get(r[0]),r[1],r[2])]);if("createImageBitmap"in self)e(self.createImageBitmap(n));else{let t=this.images.find((t=>!t.src));t||this.images.push(t=new Image),t.onload=()=>{t&&(e(t),requestAnimationFrame((()=>{t&&(URL.revokeObjectURL(t.src),t.src=null)})))},t.src=URL.createObjectURL(n)}}))}async load(t,e,i){if(this.data.has(e))return;const r=e.replace(/^.*\//,"").split(".")[0],n=/\/base$/.test(e),s=n||Pr(r),o=new XMLHttpRequest,a=await new Promise(((r,n)=>{let a=0;o.responseType="arraybuffer",o.onprogress=t=>{a||(a=Number(o.getResponseHeader("Content-Length"))),null==i||i(Math.min(1,t.loaded/a))},o.onload=()=>{4===o.readyState&&200===o.status?(null==i||i(1),r(o.response)):n()},o.onerror=n,o.open("GET",t+e+(s?".bin":".mdp")),o.send()}));if(!a)return;this.data.set(e,a);const l=n?e.split("/")[0]+"/":"";let c=0;for(;c<a.byteLength&&!(c+32>a.byteLength);){const i=this.parseHeader(new Uint8Array(a,c,32));if(i.name&&i.size>0)this.db.set(t+l+i.name.replace("./",""),[e,c+32,i.size]);else if(0===i.size&&!i.name)break;c+=32+i.size}}parseHeader(t){const e=(new TextDecoder).decode(t),i=t=>e.slice(r,r+=t).replace(/\x00/g,"").trim();let r=0;return{name:i(20),size:parseInt(i(12),8)}}},_a=[];class xa{constructor(t,e,i={}){this.wasm=t,this.attr=e,this.opts=i,this.uuid=cr(),this.__info=JSON.parse(JSON.stringify(ha)),this.settings=Zi({}),this.data=Zi(void 0),this.video=Zi(void 0),this.visible=Zi(!1),this.ptr=-1,this.baseTileIdx=-1,this.is360=!1,this.isVideo=!1,this.isOmni=!1,this.levels=1,this.dzLevels=0,this.noImage=!1,this.opacity=1,this.viewport=Zi(),this.embeds=[],this.isV5=!1,this._loadedData=!1,this.embedElements=new Map,this.state=new ya.Image(this),i.useParentCamera||(this.camera=new ka(this)),this.id=(e.id??"").replace("https://i.micr.io/",""),this.isV5=Pr(this.id.split("/")[0]),this.infoBasePath=e.path&&e.forceInfoPath?e.path:void 0,this.dataPath=e.path||this.__info.path,this.isV5&&!e.path&&(this.dataPath=la),i.secondaryTo?(this.opacity=0,i.area=this.wasm.micrio.canvas.viewport.portrait?[0,1,1,1]:[1,0,1,1],void 0===i.isPassive&&(i.isPassive=!0)):i.area||(i.area=[0,0,1,1]),this.preset=_r(this.id);let r=!1;this.info={subscribe:Zi(void 0,(t=>{r?t(this.__info):this.load().then(t),r=!0})).subscribe};const n=this.wasm.micrio,s=!!this.attr.revision;let o,a=Ki(this.visible);i.isEmbed&&!s||this.visible.subscribe((t=>{t!=a&&(a=t,t&&!this._loadedData&&(!s&&this.isV5?(this._loadedData=!0,this.data.set(void 0)):this.loadData()),i.secondaryTo&&(i.isPassive&&(o?(o(),o=null):t&&(o=i.secondaryTo.state.view.subscribe((t=>{t&&!this.camera.aniDone&&this.camera.setView(t,{noLimit:!0})})))),t?n.events.dispatch("splitscreen-start",this):n.events.dispatch("splitscreen-stop",this)),n.visible.update((e=>(t?e.push(this):e.splice(e.indexOf(this),1),e))),t&&n.$current==this&&n.switching.set(!1))})),this.video.subscribe((t=>this._video=t)),this.data.subscribe((t=>((t,e,i)=>{var r,n,s,o,a;t&&(t.revision&&(t.revision=Object.fromEntries(Object.entries(t.revision??{}).filter((t=>Number(t[1])>0)))),null==(r=t.embeds)||r.forEach((t=>{t.uuid||(t.uuid=(t.id??t.micrioId)+"-"+Math.random()),$r(t.video),$r(t)})),null==(n=t.markers)||n.forEach((t=>Ir(t,e,!i))),null==(o=null==(s=t.music)?void 0:s.items)||o.forEach($r),null==(a=t.pages)||a.forEach(Sr))})(t,this.is360,this.isV5)))}get $info(){return this.__info}get $settings(){return Ki(this.settings)}get $data(){return Ki(this.data)}setError(t,e){throw this.wasm.micrio.printError(this.error=e??(null==t?void 0:t.message)??(null==t?void 0:t.toString())??"An unknown error has occurred"),this.wasm.micrio.loading.set(!1),t}async load(){var t,e,i,r,n,s,o,a,l,c,u,d,h,m,v,p,f,g,w,b;let y=this.__info;const k=this.attr,T=this.wasm.micrio;k.id&&k.width&&(k.settings&&vr(ha.settings,k.settings,{noOverwrite:!0}),this.__info=y=k);let _=y.iiifManifest||k.iiifManifest;y.isIIIF=this.id.startsWith("http")||"iiif"==y.format;const x=!!(null==(t=k.settings)?void 0:t.forceDataRefresh);if(!this.id||k.width&&k.height&&!_)(null==(o=this.preset)?void 0:o[1])&&vr(this.preset[1],y);else{const t=t=>this.setError(t,'Image with id "'+this.id+'" not found, published, or embeddable.');vr((null==(e=this.preset)?void 0:e[1])||await(y.isIIIF?Tr(this.id):xr(this.id,this.infoBasePath,x)).catch(t),y),!_&&y.iiifManifest&&(_=y.iiifManifest),y.isIIIF||(y.isIIIF=!!_),_&&vr(await Tr(_).catch(t),y),(null==(r=null==(i=y.settings)?void 0:i._meta)?void 0:r.noLogo)&&(y.settings.noLogo=!0),(null==(s=null==(n=y.settings)?void 0:n._meta)?void 0:s.noSmoothing)&&(y.settings.noSmoothing=!0)}const E="https://iiif.micr.io/";if(y.id.startsWith(E)&&(y.id=y.id.slice(21)),7==(null==(a=this.id)?void 0:a.length)){const t=Lr(this.id[1+Lr(this.id)%6]);y.is360=!!(t>>4&1),y.isWebP=!(3&t),y.isPng=2==(3&t),t>>3&1&&Pr(y.tilesId??this.id)&&(y.format="dz"),y.path||(y.path=`https://${t>>2&1?"eu":"r2"}.micr.io/`)}const $=this.isV5&&this.id.startsWith("i")&&!this.id.includes("/");$&&!y.tilesId&&(y.tilesId=this.id.slice(1));const A=ca.indexOf(y.id)>=0||y.tilesId&&ca.indexOf(y.tilesId)>=0;vr(k,y);const S=$&&!(null==(l=y.tileBasePath)?void 0:l.includes("micr.io"));if(this.tileBase=S?y.tileBasePath??aa:A||$?aa:y.tileBasePath??y.path??(this.isV5?la:aa),(null==(c=y.organisation)?void 0:c.baseUrl)&&!k.path?(this.dataPath=y.path=y.organisation.baseUrl,$&&!A||(this.tileBase=this.dataPath)):"https://eu.micr.io/"==y.path&&(this.dataPath=y.path),(null==(u=y.settings)?void 0:u.omni)&&(this.isOmni=!0,y.version>=5&&(await Ta.load(this.tileBase??this.dataPath,(y.tilesId??y.id)+"/base",(t=>{var e,i;return null==(i=null==(e=T._ui)?void 0:e.setProps)?void 0:i.call(e,{loadingProgress:t})})).catch((t=>this.setError(t,"Could not find object base package."))),y.settings.gallery||(y.settings.gallery={}),y.settings.gallery.type="omni",y.settings.gallery.archive=y.id)),!(null==(d=y.organisation)?void 0:d.branding)||y.settings&&y.settings.noUI||this.loadStyle(this.dataPath+"style/"+y.organisation.slug+".css").then((()=>{var t;const e=null==(t=getComputedStyle(this.wasm.micrio).getPropertyValue("--micrio-font-family"))?void 0:t.replace(/^'([^']+)'.*$/,"$1");e&&document.fonts.ready.then((()=>{document.fonts.check("16px "+e)||this.loadStyle(`https://fonts.googleapis.com/css2?family=${e}:ital,wght@0,300;0,400;0,500;0,600;0,800;1,300;1,400;1,500;1,600;1,800&display=swap`)}))})),y.isIIIF)if(y.sequences&&y.sequences.length)this.parseIIIFSequence(y,!!_);else{const t=(_||("@id"in y?y["@id"]:y.id)).replace("/info.json","");y.path=t.replace(/\/[^/]*$/,""),y.id=t.replace(/^.*\/([^/]*)$/,"$1")}if(y.spacesId&&!T.spaceData&&(T.spaceData="MICRIO_SPACE_DATA"in self?self.MICRIO_SPACE_DATA:await Tr("https://i.micr.io/spaces/"+y.spacesId+".json")),null==(h=y.settings)?void 0:h._360){const t=(null==(v=null==(m=T.spaceData)?void 0:m.images.find((t=>t.id==this.id)))?void 0:v.rotationY)??0;y.settings._360.trueNorth=.5+t/Math.PI/2}this.noImage=this.noImage||this.isOmni||!y.id&&!y.tilesId,this.extension=y.tileExtension||y.isPng&&"png"||y.isWebP&&"webp"||"jpg","dz"==y.format&&(y.isDeepZoom=!0),this.is360=!!y.is360,this.isVideo=!!y.isVideo;let I=this.isV5?Ki(T._lang):("cultures"in y?void 0:k.lang)??void 0;if(this.isV5){if(y.revision){const t=Object.keys(y.revision);t.length&&t.indexOf(I)<0&&(T.lang=t[0])}}else if(!(null==(p=y.settings)?void 0:p.skipMeta)&&"cultures"in y){const t=(y.cultures||"").split(","),e=this.opts.isEmbed||!!this.opts.area,i=(null==(f=y.settings)?void 0:f.onlyPreferredLang)||e;I=y.lang&&t.indexOf(y.lang)>=0?y.lang:i?void 0:t[0],I&&!e&&(T.lang=I)}const M=y.settings;M&&!(null==M?void 0:M.noExternals)&&await Promise.all([M.css?this.loadStyle(M.css.href):null,M.js?this.loadScript(M.js.href,I):null].filter((t=>!!t)));for(let P=y.tileSize;P<Math.max(y.width,y.height);P*=2,this.levels++);let L=Math.max(y.width,y.height);do{this.dzLevels++}while((L/=2)>1);return(null==(g=null==M?void 0:M.gallery)?void 0:g.archive)&&(this.levels-=1-(M.gallery.archiveLayerOffset??0)),this.noImage||(this.thumbSrc=this.getTileSrc(this.levels,0,0)),T.events.dispatch("pre-info",y),this.isV5&&null!=y.revision&&!this.opts.isEmbed?await this.loadData():(null==(w=y.settings)?void 0:w.skipMeta)||this.opts.isEmbed||this.isV5||T._lang.subscribe((t=>{var e,i;t&&this.id&&(!("cultures"in this.__info)||(this.__info.cultures||"").split(",").indexOf(t)<0)&&(t=void 0),this.data.set(void 0),!t&&(null==(e=this.preset)?void 0:e[2])&&(t="preset"),t&&this.id&&((null==(i=this.preset)?void 0:i[2])?this.enrichData(this.preset[2]).then((t=>{var e;this.data.set(t),(null==(e=this.preset)?void 0:e[2])&&(this.preset[2]=void 0)})):Tr(this.dataPath+this.id+"/data."+t+".json").catch((()=>{})).then((t=>t&&this.enrichData(t).then((t=>this.data.update((e=>(vr(t,e||(e={}),{mergeArrays:!0}),e))))))))})),(null==(b=y.settings)?void 0:b.micrioSplitLink)&&!this.opts.secondaryTo&&T.open({id:y.settings.micrioSplitLink,settings:{hookEvents:!1!==y.settings.secondaryInteractive}},{splitScreen:!0,isPassive:!y.settings.noFollow}),y.settings&&this.settings.set(y.settings),delete y.settings,this.isOmni&&this.state.hookOmni(),y}async loadData(){var t,e,i,r;const n=(null==(t=this.$settings)?void 0:t.skipMeta)||(null==(e=this.__info.settings)?void 0:e.skipMeta);if(this._loadedData||n)return Promise.resolve();this._loadedData=!0;const s=(null==(i=this.preset)?void 0:i[2])??(this.isV5&&await Tr(this.dataPath+this.id+"/data/pub.json",null==(r=this.__info.settings)?void 0:r.forceDataRefresh).catch((()=>{})));s&&this.enrichData(s).then((t=>this.data.set(t)))}getTileSrc(t,e,i,r){var n,s,o;const a=this.__info;if(a){if(a.isDeepZoom&&(t=this.dzLevels-t),a.isIIIF){const r=a.tileSize,n=Math.pow(2,t)*r,s=Math.min(a.width,e*n),o=Math.min(a.height,i*n),l=Math.min(a.width-s,n),c=Math.min(a.height-o,n),u=Math.round(Math.min(r,l/n*r)),d=Math.round(Math.min(r,c/n*r));return`${a.path}/${a.id}/${[s,o,l,c].join(",")}/${[u,d].join(",")}/0/default.jpg`}if(null==(o=null==(s=null==(n=a.settings)?void 0:n._360)?void 0:s.video)?void 0:o.src)throw"Video thumb";return`${this.tileBase}${a.tilesId||a.id}/${void 0!==r?r+"/":""}${t}/${e}${a.isDeepZoom?"_":"-"}${i}.${this.extension}`}}loadScript(t,e=""){return new Promise((i=>{if(_a.indexOf(t)>=0||document.querySelector('script[src="'+t+'"]'))i();else{_a.push(t);const r=document.createElement("script");r.type="text/javascript",r.async=!0,r.defer=!0,r.micrioElement=this.wasm.micrio,r.src=t.replace("$lang",e),r.onload=i,document.head.appendChild(r)}}))}loadStyle(t){return new Promise((e=>{if(_a.indexOf(t)>=0||document.head.querySelector('link[href="'+t+'"]'))e();else{_a.push(t);const i=document.createElement("link");i.setAttribute("type","text/css"),i.setAttribute("rel","stylesheet"),i.setAttribute("href",t),i.onload=e,document.head.appendChild(i)}}))}async enrichData(t){var e,i,r,n,s;if(!t)return t;"error"in t&&(this.__info.error="403"==t.status?"Could not load image data. Are you logged in and do you have the right credentials?":t.error);const o=this.wasm.micrio.lang,a=[];null==(e=t.markers)||e.forEach((t=>{var e;if(Ir(t,this.is360,!this.isV5),null==(e=t.data)?void 0:e.micrioSplitLink){const e=t.data.micrioSplitLink.split(",").map((t=>t.trim())),i=t.data._micrioSplitLink={micrioId:e[0],markerId:e[1],follows:!!e[2]&&"false"!=e[2]};i.markerId&&a.push(i.micrioId)}})),(null==(i=t.markerTours)?void 0:i.length)&&a.push(...[].concat.apply([],t.markerTours.map((t=>t.steps))).map((t=>t.split(",")[1])).filter((t=>!!t&&t!=this.id)));const l=t=>"autostart"in t&&t.autostart,c=(null==(r=t.markerTours)?void 0:r.find(l))||(null==(n=t.tours)?void 0:n.find(l));c&&(this.$settings.start={type:"steps"in c?"markerTour":"tour",id:c.id});const u=a.filter(((t,e)=>a.indexOf(t)==e));Promise.all(u.map((t=>xr(t,this.infoBasePath))));const d=t=>this.dataPath+(this.isV5?t+"/data/pub.json":t+"/data."+o+".json"),h=await Promise.all(u.map((t=>Tr(d(t)))));h.forEach(((t,e)=>{var i;return null==(i=null==t?void 0:t.markers)?void 0:i.forEach((t=>Ir(t,this.is360,5==u[e].length)))}));const m=this.wasm.micrio.spaceData;return t.markerTours&&(await Promise.all(t.markerTours.map((e=>Mr(this,e,o,t)))),m&&(t.markerTours=t.markerTours.filter((t=>!t.steps.find((t=>t.includes(","))))))),(null==m?void 0:m.markerTours)&&await Promise.all(m.markerTours.filter((t=>!t.stepInfo)).map((e=>Mr(this,e,o,t)))),null==(s=t.markers)||s.forEach((t=>{var e,i,r,n,s;if(!(null==(e=t.data)?void 0:e._micrioSplitLink))return;const o=null==(r=null==(i=t.data)?void 0:i._micrioSplitLink)?void 0:r.markerId;if(o)for(let a=0;a<h.length;a++){const e=null==(s=null==(n=h[a])?void 0:n.markers)?void 0:s.find((t=>t.id==o));if(e)return void(t.data._micrioSplitLink.view=e.view)}})),this.wasm.micrio.events.dispatch("pre-data",{[this.id]:t,...Object.fromEntries(u.map(((t,e)=>[t,h[e]])))}),h.forEach(((t,e)=>{if(t){const r=this.wasm.images.find((t=>t.id==u[e]));r&&r instanceof xa&&!r.$data&&(i=d(r.id),!yr.has(i))&&r.data.set(t)}var i})),t}parseIIIFSequence(t,e=!1){var i;const r=null==(i=t.sequences)?void 0:i[0];if(!r)return;const n="top-to-bottom"==r.viewingDirection,s=r.canvases.map((t=>t.images[0])).map((t=>t.resource));this.noImage=!0,t.width=n?Math.max(...s.map((t=>t.width))):s.reduce(((t,e)=>t+e.width),0),t.height=n?s.reduce(((t,e)=>t+e.height),0):Math.max(...s.map((t=>t.height)));let o=0,a=this.embeds;t.settings||(t.settings={}),e&&s.length>10&&(a=t.gallery=[],t.settings.gallery||(t.settings.gallery={})),s.forEach((e=>{const i=[(1-e.width/t.width)/2,(1-e.height/t.height)/2];a.push(new xa(this.wasm,{id:e.service["@id"],width:e.width,height:e.height,isPng:"image/png"==e.format,settings:{}},{area:n?[i[0],o/t.height,1-i[0],(o+e.height)/t.height]:[o/t.width,i[1],(o+e.width)/t.width,1-i[1]]})),o+=n?e.height:e.width}))}addEmbed(t,e,i={}){const r=e.slice(0),n=new xa(this.wasm,t,{area:r,isEmbed:!0,useParentCamera:i.asImage});return n.camera||(n.camera=this.camera),this.embeds.push(n),void 0===i.opacity&&(i.opacity=1),br(n.info).then((t=>{if(t){if("cover"==i.fit||"contain"==i.fit){const e=this.is360?2:1,n="cover"==i.fit,s=r[2]-r[0],o=r[3]-r[1],a=r[0]+s/2,l=r[1]+o/2,c=s/o*e,u=t.width/t.height;if(n&&u<c||!n&&u>=c){const t=s/u*e;r[1]=l-t/2,r[3]=l+t/2}else{const t=o*u/e;r[0]=a-t/2,r[2]=a+t/2}}this.wasm.addEmbed(n,this,i),this.wasm.render()}})),n}setEmbedMediaElement(t,e){e?this.embedElements.set(t,e):this.embedElements.delete(t)}getEmbedMediaElement(t){return this.embedElements.get(t)}splitStart(){var t,e,i;const r=this.wasm.micrio.canvas.viewport.portrait;null==(t=this.opts.secondaryTo)||t.camera.setArea(r?[0,0,1,.5]:[0,0,.5,1],{noRender:!0}),this.camera.setArea(r?[0,.5,1,1]:[.5,0,1,1],{noRender:!0}),this.camera.setView((null==(i=null==(e=this.__info)?void 0:e.settings)?void 0:i.view)??[0,0,1,1]),this.wasm.render()}splitEnd(){var t,e;const i=this.opts.area;if(!i)return;const r=i[2]-i[0],n=i[3]-i[1];if(Math.round(1e3*r)/1e3==0||Math.round(1e3*n)/1e3==0)return;const s=r>n;this.camera.setArea(s?[0,1,1,1]:[1,0,1,1],{noRender:!0}),(null==(t=this.opts.secondaryTo)?void 0:t.grid)&&this.opts.secondaryTo.camera.aniDone||null==(e=this.opts.secondaryTo)||e.camera.setArea([0,0,1,1],{noRender:!0}),this.wasm.render()}fadeIn(t=!1){this.wasm.fadeImage(this.ptr,1,t),this.wasm.render()}fadeOut(t=!1){this.wasm.fadeImage(this.ptr,0,t),this.wasm.render()}}class Ea{constructor(t,e,i,r,n){var s,o,a;this.wasm=t,this.image=e,this.embed=i,this.paused=r,this.moved=n,this.ism3u=!1,this.hlsPlayer=void 0,this.usVid=void 0,this.vidRepeatTo=void 0,this.placeTo=void 0,this.autoplay=!0,this._vid=void 0,this.isMounted=!0,this.events={play:()=>this.setPlaying(!0),pause:()=>this.setPlaying(!1),playing:()=>{this.image._video||this.image.video.set(this._vid)},canplayEvt:mr.iOS?"loadedmetadata":"canplay",canplay:()=>{this._vid&&this.isMounted&&(this.autoplay&&!this.paused?(this._vid.play().catch((t=>console.warn("WebGL Embed video play() failed on canplay:",t))),this.moved()):this.embed.hideWhenPaused||(this.setPlaying(!0),Xt().then((()=>{this.setPlaying(!1),setTimeout((()=>{var t;return null==(t=this._vid)?void 0:t.remove()}),50)}))))}},this.ism3u=!!(null==(s=i.video)?void 0:s.streamId)&&!(null==(o=i.video)?void 0:o.transparent),this._vid=e._video,this.autoplay=(null==(a=i.video)?void 0:a.autoplay)??!0;let l=!0;this.usVid=this.image.visible.subscribe((t=>{clearTimeout(this.placeTo),this.placeTo=t?setTimeout((()=>{this.isMounted&&(this._vid?(this.hook(),this.autoplay&&!this.paused&&this._vid.play().catch((t=>console.warn("WebGL Embed video play() failed",t)))):this.load())}),l?0:100):setTimeout((()=>{var t;return null==(t=this._vid)?void 0:t.pause()}),0),l=!1}))}unmount(){var t,e;this.isMounted=!1,clearTimeout(this.placeTo),clearTimeout(this.vidRepeatTo),null==(t=this._vid)||t.pause(),this.unhook(),null==(e=this.usVid)||e.call(this)}setPlaying(t){this._vid&&(this.paused=!t,t?this._vid.dataset.playing="1":delete this._vid.dataset.playing,this.wasm.e._setImageVideoPlaying(this.image.ptr,t),this.embed.hideWhenPaused&&this.wasm.fadeImage(this.image.ptr,t?1:0),t&&this.wasm.render())}load(){if(!this.embed.video||this._vid)return;const t=this.ism3u?`https://videodelivery.net/${this.embed.video.streamId}/manifest/video.m3u8`:this.embed.video.src;t?(this._vid=document.createElement("video"),this._vid.crossOrigin="anonymous",this._vid.playsInline=!0,this._vid.width=.5*this.embed.width,this._vid.height=.5*this.embed.height,this._vid.muted=this.embed.video.muted,this.hook(),!this.ism3u||Dr(this._vid)?this._vid.src=t:gr("https://i.micr.io/hls-1.5.17.min.js",void 0,"Hls"in window?{}:void 0).then((()=>{this.hlsPlayer=new window.Hls,this.hlsPlayer.loadSource(t),this._vid&&this.hlsPlayer.attachMedia(this._vid)})).catch((t=>console.error("[Micrio GL Embed] Failed to load HLS.js:",t)))):console.error("[Micrio GL Embed] No video source found for embed:",this.embed.id)}hook(){if(!this.embed.video||!this._vid)return;const t=this.embed.video.loopAfter;this.embed.video.loop&&t?(this._vid.loop=!1,this._vid.onended=()=>{this.setPlaying(!1),this.vidRepeatTo=setTimeout((()=>{var t;return null==(t=this._vid)?void 0:t.play().catch((t=>console.warn("WebGL Embed video loop play() failed:",t)))}),1e3*t)},this._vid.onplay=()=>this.setPlaying(!0)):(this._vid.loop=this.embed.video.loop,this._vid.onended=null,this._vid.onplay=null),this._vid.parentNode||this.autoplay||this.ism3u||(this._vid.setAttribute("style","opacity:0;position:absolute;top:0;left:0;transform-origin:left top;transform:scale(0.1);pointer-events:none;"),document.body.appendChild(this._vid)),this._vid.addEventListener("play",this.events.play),this._vid.addEventListener("pause",this.events.pause),this._vid.addEventListener("playing",this.events.playing,{once:!0}),this._vid.addEventListener(this.events.canplayEvt,this.events.canplay,{once:!0})}unhook(){this._vid&&(this._vid.removeEventListener("play",this.events.play),this._vid.removeEventListener("pause",this.events.pause),this._vid.removeEventListener("playing",this.events.playing),this._vid.removeEventListener(this.events.canplayEvt,this.events.canplay),this._vid.onended=null,this._vid.onplay=null)}}var $a=We('<img alt="Embed" data-scroll-through="" class="micrio-embed">'),Aa=We('<button data-scroll-through="" aria-label="embed-button" class="micrio-embed"></button>');function Sa(t,e){var i,r;Te(e,!0);const[n,s]=ir(),o=()=>tr(l,"$current",n),a=ye("micrio"),{current:l,wasm:c,canvas:u}=a;let d=or(e,"embed",15);const h=o(),m=h.$info;d().uuid||d(d().uuid=cr(),!0);const v=d().uuid,p=h.is360,f=(null==(i=d().video)?void 0:i.autoplay)??!0;let g=h.embeds.find((t=>{var e;return t.uuid==v||(null==(e=t.$info)?void 0:e.title)==v}));const w=window.matchMedia("(dynamic-range: high)").matches||mr.OSX,b=d().area,y=null==(r=d().src)?void 0:r.toLowerCase().endsWith(".svg"),k=!(!d().width||!d().height)&&d().width*d().height<Math.pow(1024,2),T=/iPhone OS 14_/i.test(navigator.userAgent),_="data-embeds-inside-gl",x=a.getAttribute(_),E=!(y||T||!w&&!a.hasAttribute(_)||"false"==x||(!d().micrioId||k&&d().src)&&(!d().video||d().video.controls||d().video.transparent)),$=!d().clickAction&&!d().frameSrc,A="href"==d().clickAction?d().clickTarget:void 0,S=A&&d().clickTargetBlank;let I=b[2]-b[0],M=b[3]-b[1],L=b[0]+I/2,P=b[1]+M/2,C=d().scale||1,D=d().rotX??0,R=d().rotY??0,z=d().rotZ??0,O=d().scaleX??1,N=d().scaleY??1,F=j("");function V(){const t=d().area;p&&t[0]>t[2]&&t[0]--,I=t[2]-t[0],M=t[3]-t[1],L=t[0]+I/2,P=t[1]+M/2,C=d().scale||1,D=d().rotX??0,R=d().rotY??0,z=d().rotZ??0,O=d().scaleX??1,N=d().scaleY??1,Y(F,`--ratio:${I/M*m.width/m.height};--scale:${I*m.width/(d().width??100)/(E?1:C)*(p?Math.PI/2:1)};`),y&&Y(F,jt(F)+`height:${d().height}px`),E&&d().micrioId&&d().width&&Y(F,jt(F)+`width:${d().width}px`)}V();let U,B=J((()=>Math.round(I*m.width))),q=J((()=>Math.round(M*m.height))),W=j(!1),X=j(0),G=j(0),H=j(""),Z=j("");function K(){var t,e,i,r,n;if(h.camera.e&&(n=h.camera.getXYDirect(L,P),Y(X,n[0],!0),Y(G,n[1],!0),U=n[2],p&&Y(H,h.camera.getMatrix(L,P,C,1,D,R,z,void 0,O,N).join(","),!0),Y(Z,(p?`transform:matrix3d(${jt(H)});`:`--x:${jt(X)}px;--y:${jt(G)}px;--s:${U};`)+(void 0!==d().opacity&&1!==d().opacity?`--opacity:${d().opacity};`:"")),((null==(t=d().video)?void 0:t.pauseWhenSmallerThan)||(null==(e=d().video)?void 0:e.pauseWhenLargerThan))&&jt(B))){const t=jt(W);Y(W,function(){var t,e;if(!(null==(t=d().video)?void 0:t.pauseWhenSmallerThan)&&!(null==(e=d().video)?void 0:e.pauseWhenLargerThan))return!f;const i=U?Math.max(jt(B)*U/u.viewport.width,jt(q)*U/u.viewport.height):0;return!!(d().video.pauseWhenSmallerThan&&i<d().video.pauseWhenSmallerThan||d().video.pauseWhenLargerThan&&i>d().video.pauseWhenLargerThan)}(),!0),(null==(i=jt(rt))?void 0:i._vid)&&jt(W)!=t&&(jt(W)?jt(rt)._vid.pause():((null==(r=null==h?void 0:h.$settings)?void 0:r.embedRestartWhenShown)&&(jt(rt)._vid.currentTime=0),jt(rt)._vid.play()))}}function Q(){o()&&"markerId"==d().clickAction&&d().clickTarget&&o().state.marker.set(d().clickTarget)}function tt(t){if(t&&"detail"in t){const e=t.detail;for(const t in e)d(d()[t]=e[t],!0)}V(),K()}const et=Zi(!1);d().video&&(d().video.controls||d(d().video.muted=!0,!0));const it=E&&!!d().video;let rt=j(void 0);const nt=!E||!!d().clickAction;let st=j(void 0);ee((()=>{var t;d().video&&d().id&&o()&&o().setEmbedMediaElement(d().id,jt(st)??(null==(t=jt(rt))?void 0:t._vid))}));let ot=J((()=>d().video?Math.min(d().video.width,jt(B)):jt(B))),at=J((()=>d().video?Math.min(d().video.height,jt(q)):jt(q))),lt=J((()=>jt(B)/jt(ot)));Gi((()=>{var t,e;const i=[];return E&&function(){const t=d().hideWhenPaused?.01:d().opacity??1;g&&g.ptr>=0?(g.camera.setArea(d().area),g.camera.setRotation(d().rotX,d().rotY,d().rotZ),c.fadeImage(g.ptr,t)):g=h.addEmbed({id:d().video?d().id:d().micrioId,title:v,width:d().width,height:d().height,isPng:d().isPng,isWebP:d().isWebP,isDeepZoom:d().isDeepZoom,path:m.tileBasePath??m.path,isSingle:!!d().video,isVideo:!!d().video,settings:{_360:{rotX:D,rotY:R,rotZ:z}}},d().area,{opacity:t,asImage:!1}),it&&br(g.visible,{targetValue:!0}).then((()=>{Y(rt,new Ea(c,g,d(),jt(W),K),!0)})),c.render()}(),(nt||(null==(t=d().video)?void 0:t.pauseWhenSmallerThan)||(null==(e=d().video)?void 0:e.pauseWhenLargerThan))&&i.push(h.state.view.subscribe(K)),()=>{var t,e;for(null==(t=jt(rt))||t.unmount(),g&&g.ptr>=0&&(c.fadeImage(g.ptr,0),c.render()),d().video&&d().id&&o()&&o().setEmbedMediaElement(d().id);i.length;)null==(e=i.shift())||e()}}));var ct=Ge(),dt=ut(ct),ht=t=>{var e=Ge();ui(ut(e),(()=>A?"a":"div"),0,((t,e)=>{let i;se((()=>i=$i(t,i,{id:d().id?"e-"+d().id:void 0,style:jt(Z),role:A?void 0:"figure",onclick:Q,onkeypress:Q,onchange:tt,href:A,target:A&&S?"_blank":null,class:"",[bi]:{"embed-container":!0,embed3d:p,"no-events":$}},"micrio-embed")));var r=Ge(),n=ut(r),s=t=>{const e=J((()=>d().video.streamId&&!d().video.transparent?"cfvid://"+d().video.streamId:d().video.src)),i=J((()=>!jt(W)&&d().video.autoplay)),r=J((()=>d().video.transparent&&d().video.hasH265));Ms(t,{get forcePause(){return jt(W)},get src(){return jt(e)},get width(){return jt(ot)},get height(){return jt(at)},get frameScale(){return jt(lt)},get controls(){return d().video.controls},destroying:et,get loop(){return d().video.loop},get loopDelay(){return d().video.loopAfter},get muted(){return d().video.muted},get autoplay(){return jt(i)},get hasTransparentH265(){return jt(r)},get _media(){return jt(st)},set _media(t){Y(st,t,!0)}})},o=(t,e)=>{var i=t=>{Ms(t,{get src(){return d().frameSrc},get width(){return jt(B)},get height(){return jt(q)},get frameScale(){return d().scale},get autoplay(){return d().autoplayFrame},destroying:et})},r=(t,e)=>{var i=t=>{var e=$a();se((()=>{xi(e,"src",d().src),wi(e,jt(F)),xi(e,"width",y?d().width:void 0),xi(e,"height",y?d().height:void 0)})),Ye(t,e)},r=t=>{var e=Aa();se((()=>{wi(e,jt(F)),xi(e,"title",d().title)})),Ye(t,e)};ei(t,(t=>{!E&&d().src?t(i):t(r,!1)}),e)};ei(t,(t=>{d().frameSrc?t(i):t(r,!1)}),e)};ei(n,(t=>{d().video&&!E?t(s):t(o,!1)})),Ye(e,r)})),Ye(t,e)};ei(dt,(t=>{nt&&(jt(H)||jt(X)||jt(G))&&t(ht)})),Ye(t,ct),_e(),s()}var Ia=Xe('<svg width="100" height="100" class="micrio-progress-circle"><circle fill="transparent" stroke="#e0e0e0" stroke-width="8px" class="micrio-progress-circle"></circle><circle fill="transparent" stroke="#00d4ee" stroke-width="8px" class="micrio-progress-circle"></circle></svg>');var Ma=We("<!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!>",1);const La=!self.createImageBitmap,Pa=URL.createObjectURL(new Blob(["let controller = null, prevUri = null;\nself.addEventListener('message', e => {\n\t// Handle abort message\n\tif(e.data == 'abort') return controller && controller.abort();\n\t// Create new AbortController for this fetch\n\tcontroller = new AbortController();\n\t// Fetch the image blob\n\tfetch(e.data.src, { signal: controller.signal })\n\t\t.then(r => r.blob())"+(La?"\n\t\t// Fallback for older Safari: create Object URL\n\t\t.then(blob => {\n\t\t\t// Revoke previous Object URL to free memory\n\t\t\tURL.revokeObjectURL(prevUri);\n\t\t\t// Post Object URL back\n\t\t\tself.postMessage({src: (prevUri = URL.createObjectURL(blob, {type: e.data.type}))})\n\t\t})":"\n\t\t// If createImageBitmap is supported, use it (preferred)\n\t\t.then(blob => self.createImageBitmap(blob))\n\t\t// Post ImageBitmap back, transferring ownership\n\t\t.then(data => self.postMessage({data:data, src:e.data.src}, [data]))")+"\n\t\t// Handle fetch errors (including abort)\n\t\t.catch(err => self.postMessage({error: e.data.src+': '+err.message, type: err.name}))\n})"],{type:"text/javascript"})),Ca=Math.max(2,Math.min(6,(navigator.hardwareConcurrency||2)-1)),Da=[],Ra=new Map,za=new Map,Oa=[],Na=new Map;for(let ml=0;ml<Ca;ml++){const t=new Worker(Pa);t.onmessage=t=>Va(ml,t.data.src,t.data.data,t.data.error,t.data.type),Ra.set(ml,t),La&&za.set(ml,new Image)}const Fa=t=>new Promise(((e,i)=>{Oa.push([t,e,i]),function(){if(!Oa.length)return;let t=0;for(;t<Ca&&!(Da.indexOf(t)<0);t++);if(t>=Ca)return;Da.push(t);const e=Oa.shift();if(!e)return void Da.splice(Da.indexOf(t),1);Na.set(t,e);const i=Ra.get(t);if(!i)return console.error(`[Micrio Texture] Worker ${t} not found!`),e[2]("Internal error: Worker not found"),void Da.splice(Da.indexOf(t),1);i.postMessage({src:e[0],type:"image/"+e[0].split(".").pop()})}()}));function Va(t,e,i,r,n){const s=Na.get(t);if(null!=s)if(Na.delete(t),setTimeout((()=>{Da.splice(Da.indexOf(t),1)}),50),r)s[2](r),"AbortError"!=n&&console.error(`[Micrio Texture] Error loading ${s[0]}: ${n} - ${r}`);else if(i)s[1](i);else if(e&&La){const i=za.get(t);if(!i)return void s[2]("Internal error: Image element fallback not found");i.onload=()=>{s[1](i)},i.onerror=()=>{s[2](`Failed to load image from Object URL: ${e}`)},i.src=e}else s[2](`Worker ${t} sent invalid message.`),console.error(`[Micrio Texture] Worker ${t} sent invalid message for ${s[0]}`);else console.warn(`[Micrio Texture] Received message from worker ${t} but no matching promise found.`)}function Ua(){return Da.length}function Ba(t){const e=[...Na.entries()].find((e=>e[1][0]==t));if(null==e)return;const i=Ra.get(e[0]);i&&i.postMessage("abort")}const qa=ua.ugz?ua.ugz(ua.b64,!0):fetch("http://localhost:2000/build/optimized.wasm").then((t=>t.arrayBuffer())),Wa=class t{constructor(t){this.micrio=t,this.ready=!1,this.memory=new self.WebAssembly.Memory({initial:100,maximum:100}),this.b=this.memory.buffer,this.i=-1,this.c=-1,this.now=-1,this.raf=-1,this.drawing=!1,this.images=[],this.bareBone=!1,this.baseTiles=[],this.drawn=[],this.prevDrawn=[],this.toDelete={},this.textures={},this.requests=new Map,this.timeouts={},this.tileLoaded={},this.tileOpacity={},this.loadStates={},this.unsubscribe=[],this.cameras=new Map,this.preventDirectionSet=!1,this._pMatrices={},this.isGallery=!1,this.imports={env:{memory:this.memory,abort:console.error},main:{"console.log":console.log,"console.log2":console.log,"console.log3":console.log,"console.log4":console.log,drawTile:this.drawTile.bind(this),drawQuad:t=>this.micrio.webgl.drawTile(void 0,t),aniAbort:t=>{const e=this.cameras.get(t);e&&(e.aniAbort&&e.aniAbort(),e.aniDoneAdd.length=0,e.aniAbort=e.aniDone=void 0)},aniDone:t=>{var e;const i=this.cameras.get(t);if(i){for(i.aniDone&&i.aniDone();i.aniDoneAdd.length;)null==(e=i.aniDoneAdd.shift())||e();i.aniAbort=i.aniDone=void 0}},getTileOpacity:t=>this.tileOpacity[t],setTileOpacity:(t,e=!1,i=1)=>{const r=this.tileOpacity,n=this.tileLoaded;return(!r[t]||r[t]<1)&&(r[t]=e?1:n[t]>0?Math.min(1,(this.now-n[t])/250)*i:0),r[t]||0},setMatrix:t=>this.micrio.webgl.gl.uniformMatrix4fv(this.micrio.webgl.pmLoc,!1,this._pMatrices[t]),setViewport:(t,e,i,r)=>this.micrio.webgl.gl.viewport(Math.floor(t),Math.floor(e),Math.ceil(i),Math.ceil(r)),viewSet:t=>{var e;return null==(e=this.cameras.get(t))?void 0:e.viewChanged()},viewportSet:(t,e,i,r,n)=>{const s=this.images.find((e=>e.ptr==t));s&&"camera"in s&&s.viewport.set([e,i,r,n])},setVisible:(t,e)=>{var i;return null==(i=this.images.find((e=>e.ptr==t)))?void 0:i.visible.set(1===e)},setVisible2:(t,e)=>{var i;return null==(i=this.images.find((e=>e.ptr==t)))?void 0:i.visible.set(1===e)}}},this.addImage=async(t,e,i=!1,r=1)=>br(t.info).then((n=>{if(!n)return;this.images.push(t);const s=t.opts.area??[0,0,1,1],o=t.$settings._360??{};if(t.ptr=i?this.e._addImage(e.ptr,s[0],s[1],s[2],s[3],n.width,n.height,n.tileSize||1024,n.isSingle??!1,n.isVideo??!1,r,o.rotX??0,o.rotY??0,o.rotZ??0,o.scale??1,0):this.e._addChild(e.ptr,s[0],s[1],s[2],s[3],n.width,n.height),!i){this.bindCamera(t),t.$settings.focus&&this.e._setCoo(t.ptr,t.$settings.focus[0],t.$settings.focus[1],0,0,performance.now());const e=this.e._getPMatrix(t.ptr);this._pMatrices[e]=new Float32Array(this.b,e+32,16);const i=t.$info.view;i&&"0,0,1,1"!=i.toString()&&this.e._setView(t.ptr,i[0],i[1],i[2],i[3]),this.e._sendViewport(t.ptr)}this.tileOpacity[t.baseTileIdx=this.e.getNumTiles(this.i)-1]=1,this.baseTiles.push(t.baseTileIdx)})),this.addChild=(t,e)=>this.addImage(t,e),this.render=this.render.bind(this),this.draw=this.draw.bind(this),this.unsubscribe.push(t.current.subscribe(this.setCanvas.bind(this)))}static getTextureBuffer(t,e){const i=new Float32Array(12*t*e),r=1/t,n=1/e;for(let s=0,o=0;o<e;o++)for(let e=0;e<t;e++,s+=12)i[s+3]=i[s+7]=i[s+9]=(i[s+1]=i[s+5]=i[s+11]=o*n)+n,i[s+4]=i[s+8]=i[s+10]=(i[s+0]=i[s+2]=i[s+6]=e*r)+r;return i}async load(){if(this.i>=0)return;this.i=0;const e=await qa;if(!(e instanceof Uint8Array||e instanceof ArrayBuffer))throw"Wasm binary is no array buffer!";const i=await self.WebAssembly.instantiate(e,this.imports);this.e=i.instance.exports,this.i=this.e.constructor(),t.segsX=this.e.segsX.value,t.segsY=this.e.segsY.value,t._textureBuffer360=t.getTextureBuffer(t.segsX,t.segsY),this._vertexBuffer=new Float32Array(this.b,this.e.getVertexBuffer(this.i)+32,18),this._vertexBuffer360=new Float32Array(this.b,this.e.getVertexBuffer360(this.i)+32,18*t.segsX*t.segsY),this.unsubscribe.push(this.micrio.barebone.subscribe((t=>this.e.setBareBone(this.i,this.bareBone=t))))}unbind(){var t;for(this.stop();this.unsubscribe.length;)null==(t=this.unsubscribe.shift())||t();this.requests.forEach((t=>Ba(t))),this.requests.clear();for(let e in this.timeouts)clearTimeout(this.timeouts[e]);this.timeouts={},this.loadStates={},this.tileLoaded={},this.tileOpacity={};for(let e in this.tileLoaded)this.deleteTile(Number(e));this.i>0&&this.e.reset(this.i)}getPtr(){return this.i}addCanvas(t){var e,i,r,n,s,o,a,l,c,u,d;const h=t.$info;if(!h)return;if(t.error)return void this.micrio.loading.set(!1);if(!(t.noImage||h.width&&h.height))throw"Invalid Micrio image size";const m=t.$settings;this.isGallery=!!h.gallery||t.isOmni,(null==(e=m.gallery)?void 0:e.archive)&&this.e.setHasArchive(this.i,!0,m.gallery.archiveLayerOffset??0),h.version&&Number(h.version)<=3.1&&this.e.setNoUnderzoom(this.i,!0);const v=!!m.limitToCoverScale,p=v||"cover"==m.initType;t.noImage&&this.micrio.loading.set(!1);const f=[.5,.5],g=m.focus,w=!!h.spacesId;g&&(isNaN(g[0])||null===g[0]||(f[0]=g[0]),isNaN(g[1])||null===g[1]||(f[1]=g[1])),h.is360&&(t.camera.trueNorth=(null==(i=m._360)?void 0:i.trueNorth)??.5);const b=null==(r=m._360)?void 0:r.video,y=h.is360&&b&&(b.src||"video"in b&&b.video),k=!!this.isGallery&&("switch"==(null==(n=m.gallery)?void 0:n.type)||"omni"==(null==(s=m.gallery)?void 0:s.type)||"swipe-full"==(null==(o=m.gallery)?void 0:o.type)),T=(null==(l=null==(a=m.omni)?void 0:a.layers)?void 0:l.length)??1;m.omni&&(m.omni.layerStartIndex=Math.min(T-1,(null==(c=m.omni)?void 0:c.layerStartIndex)??0)),t.ptr=this.e._constructor(this.i,h.width,h.height,h.tileSize??1024,h.is360??!1,t.noImage,!(!h.isSingle&&!y),t.opacity,m.freeMove??!1,v,p,(m.zoomLimit||1)*(!1!==m.zoomLimitDPRFix?this.micrio.canvas.getRatio(t.$settings):1),m.camspeed??1,t.camera.trueNorth,k,!!(null==(u=m.gallery)?void 0:u.isSpreads)&&"swipe"==m.gallery.type,t.isOmni,m.pinchZoomOutLimit??!1,T,(null==(d=m.omni)?void 0:d.layerStartIndex)??0),this.bindCamera(t),t.opts.area&&t.camera.setArea(t.opts.area,{direct:!0,noDispatch:!0,noRender:!0}),(null==m?void 0:m.crossfadeDuration)&&this.e.setCrossfadeDuration(this.i,m.crossfadeDuration),(null==m?void 0:m.embedFadeDuration)&&this.e.setEmbedFadeDuration(this.i,m.embedFadeDuration),void 0!==(null==m?void 0:m.dragElasticity)&&this.e.setDragElasticity(this.i,m.dragElasticity),(null==m?void 0:m.skipBaseLevels)&&this.e.setSkipBaseLevels(this.i,m.skipBaseLevels),(null==m?void 0:m.omni)&&t.camera.setOmniSettings(),this.micrio.hasAttribute("data-limited")&&this.e._setLimited(t.ptr,!0),this.images.push(t),this.e._sendViewport(t.ptr);const _=this.e.getNumTiles(this.i);_>0&&(this.tileOpacity[_-1]=1,this.baseTiles.push(_-1));const x=this.e._getPMatrix(t.ptr);this._pMatrices[x]=new Float32Array(this.b,x+32,16);const E=Ki(t.state.view)||m.view;E&&"0,0,1,1"!=E.toString()?this.e._setView(t.ptr,E[0],E[1],E[2],E[3],!1,!1,!1):!w&&h.is360||!f||"0.5,0.5"==f.toString()||(this.e._setCoo(t.ptr,f[0],f[1],0,0,performance.now()),m.focus=void 0),t.video.subscribe((t=>t&&t.addEventListener("play",this.render))),t.noImage&&t.visible.set(!0),this.setCanvas(t)}bindCamera(t){this.cameras.set(t.ptr,t.camera),t.camera.assign(this.e,new Float64Array(this.b,this.e._getView(t.ptr)+32,4),new Float64Array(this.b,this.e._getXY(t.ptr,0,0)+32,5),new Float64Array(this.b,this.e._getCoo(t.ptr,0,0)+32,5),new Float32Array(this.b,this.e._getMatrix(t.ptr)+32,16),new Float32Array(this.b,this.e._getQuad(t.ptr,0,0,0,0,0,0)+32,16))}setCanvas(t){var e;if(t&&!(t.ptr>0&&t.ptr==this.c))if(t.ptr<0)br(t.info).then((e=>{e&&this.micrio.$current&&(e.isIIIF||t.opts.secondaryTo||e.id==this.micrio.$current.id)&&(this.addCanvas(t),t.embeds.length&&t.embeds.forEach((e=>this.addEmbed(e,t))))}));else if(this.c!=t.ptr){const i=t.is360&&this.c>=0?this.e._getYaw(this.c):0,r=t.is360&&this.c>=0?this.e._getPitch(this.c):0;this.c=t.ptr,t.is360&&!this.preventDirectionSet&&i&&r&&this.e._setDirection(this.c,i,r,!0),0==this.e._getTargetOpacity(t.ptr)&&this.e._fadeIn(t.ptr),(null==(e=t.$settings.omni)?void 0:e.layerStartIndex)&&t.state.layer.set(t.$settings.omni.layerStartIndex),this.preventDirectionSet=!1,this.ready=!0,this.render()}}removeCanvas(t){if(t.ptr<0)throw"Canvas is not placed yet";this.e._remove(t.ptr),this.render()}render(){this.raf<0&&(this.raf=this.micrio.webgl.display.requestAnimationFrame(this.draw))}draw(t=performance.now()){var e,i;this.micrio.isConnected&&(this.raf=-1,this.drawing=!1,this.now=t,(1==this.e.shouldDraw(this.i,t)||this.micrio.keepRendering||this.micrio.events.isNavigating||!1===(null==(i=null==(e=this.micrio._current)?void 0:e._video)?void 0:i.paused))&&this.render(),this.isGallery&&this.drawStart(),this.drawn.length=0,this.e.draw(this.i),this.micrio.events.dispatch("draw"),this.cleanup(),this.micrio.webgl.drawEnd())}stop(){this.raf<0||(this.micrio.webgl.display.cancelAnimationFrame(this.raf),this.raf=-1)}drawTile(t,e,i,r,n,s,o,a){this.drawn.push(e),e in this.toDelete&&delete this.toDelete[e];const l=Ua(),c=this.images[t],u="camera"in c&&c.isVideo,d="camera"in c&&c.is360,h="camera"in c?c:c.image,m="frame"in c?c.frame:void 0;if(!this.loadStates[e]&&l<Ca){if(this.bareBone?l>2&&o:a&&o&&l>0)return!1;if(u&&!d)this.loadStates[e]=2,this.textures[e]=this.micrio.webgl.getTexture();else{this.loadStates[e]=1;const t=h.getTileSrc(i,r,n,m);if(!t)return this.loadStates[e]=0,!1;this.getTexture(e,t,o,{noSmoothing:"$info"in c&&c.$settings.noSmoothing})}}else if(this.loadStates[e]>=2){this.drawing||this.drawStart();const t=this.textures[e];if(null!=t){if(u){if(!h._video||!h._video.dataset.playing)return!1;this.micrio.webgl.updateTexture(t,h._video)}this.micrio.webgl.drawTile(t,s,d)}return 2==this.loadStates[e]&&(this.loadStates[e]=3,this.tileLoaded[e]=this.now),!0}return!1}drawStart(){this.drawing||(this.micrio.webgl.drawStart(),this.drawing=!0)}getTexture(t,e,i,r={}){if(this.textures[t]||this.requests.has(t)||!r.force&&Ua()>=Ca)return;const n=Ta.db.has(e);n||this.micrio.loading.set(!0),this.requests.set(t,e),(n?Ta.getImage(e):Fa(e)).then((e=>this.gotTexture(t,e,i,r.noSmoothing))).catch((()=>this.deleteRequest(t)))}gotTexture(t,e,i,r){this.textures[t]=this.micrio.webgl.getTexture(e,this.textures[t],r),null!=self.ImageBitmap&&e instanceof ImageBitmap&&e.close instanceof Function&&e.close(),this.loadStates[t]=2,this.timeouts[t]=setTimeout((()=>{this.deleteRequest(t)}),i?150:50)}deleteRequest(t){this.requests.delete(t),clearTimeout(this.timeouts[t]),delete this.timeouts[t],this.requests.size||this.micrio.loading.set(!1)}deleteTile(t){this.micrio.webgl.gl.deleteTexture(this.textures[t]),delete this.textures[t],delete this.toDelete[t],delete this.loadStates[t],delete this.tileOpacity[t],delete this.tileLoaded[t],clearTimeout(this.timeouts[t]),delete this.timeouts[t]}cleanup(){const t=this.prevDrawn.filter((t=>this.drawn.indexOf(t)<0&&this.loadStates[t]>0&&this.baseTiles.indexOf(t)<0)),e=performance.now();for(let r=0;r<t.length;r++){const i=t[r];switch(this.tileOpacity[r]=0,this.loadStates[i]){case 1:const t=this.requests.get(i);t&&Ba(t),delete this.loadStates[i];break;case 2:this.requests.has(i)&&this.deleteRequest(i),delete this.loadStates[i],this.deleteTile(i);break;case 3:i in this.toDelete||(this.toDelete[i]=e)}}this.prevDrawn=this.drawn.slice(0);const i=mr.iOS?5:30;for(let r in this.toDelete)(e-this.toDelete[r])/1e3>i&&this.deleteTile(Number(r))}resize(t){this.e.resize(this.i,t.width,t.height,t.left,t.top,t.ratio,t.scale,t.portrait),this.ready&&(this.stop(),this.draw())}addEmbed(t,e,i={}){if("camera"in t&&i.asImage)return this.addImage(t,e,!0,i.opacity??1);{const r="$info"in t?t.$info:e.$info;if(!r)return;this.images.push(t);const n=t.opts.area??[0,0,1,1],s=t instanceof xa?t.$settings._360??{}:{};t.ptr=this.e._addImage(e.ptr,n[0],n[1],n[2],n[3],r.width,r.height,r.tileSize||1024,r.isSingle??!1,r.isVideo??!1,i.opacity??1,s.rotX??0,s.rotY??0,s.rotZ??0,s.scale??1,i.fromScale??0),this.tileOpacity[t.baseTileIdx=this.e.getNumTiles(this.i)-1]=1,this.baseTiles.push(t.baseTileIdx)}}setActiveImage(t,e,i){this.e._setActiveImage(t,e,i??0)}setActiveLayer(t,e){this.e._setActiveLayer(t,e)}fadeImage(t,e,i=!1){this.cameras.has(t)?this.e._fadeTo(t,e,i):this.e._fadeImage(t,e,i),this.render()}setFocus(t,e,i=!1){this.e._setFocus(t,e[0],e[1],e[2],e[3],i)}};Wa._textureBuffer=Wa.getTextureBuffer(1,1);let Xa=Wa;const ja=new Float32Array([-1,-1,0,0,1,-1,1,0,-1,1,0,1,1,1,1,1]);class Ga{constructor(t,e,i){if(this.gl=t,this.program=t.createProgram(),e.webgl.getShader(this.program,t.VERTEX_SHADER,"\nattribute vec2 a_position; // Vertex position (-1 to 1)\nattribute vec2 a_texCoord; // Texture coordinate (0 to 1)\n\nvarying vec2 v_texCoord; // Pass texCoord to fragment shader\n\nvoid main() {\n\tv_texCoord = a_texCoord; // Pass through texture coordinate\n\tgl_Position = vec4(a_position, 0.0, 1.0); // Set clip space position\n}"),e.webgl.getShader(this.program,t.FRAGMENT_SHADER,i),t.linkProgram(this.program),t.getProgramParameter(this.program,t.LINK_STATUS)||console.error("Postprocess shader link error:",t.getProgramInfoLog(this.program)),t.useProgram(this.program),this.ppPositionLoc=t.getAttribLocation(this.program,"a_position"),this.ppTexCoordLoc=t.getAttribLocation(this.program,"a_texCoord"),this.ppTimeLoc=t.getUniformLocation(this.program,"u_time"),this.texture=t.createTexture(),t.bindTexture(t.TEXTURE_2D,this.texture),t.texImage2D(t.TEXTURE_2D,0,t.RGBA,this.gl.drawingBufferWidth,this.gl.drawingBufferHeight,0,t.RGBA,t.UNSIGNED_BYTE,null),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MIN_FILTER,t.LINEAR),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MAG_FILTER,t.LINEAR),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_S,t.CLAMP_TO_EDGE),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_T,t.CLAMP_TO_EDGE),this.frameBuffer=t.createFramebuffer(),t.bindFramebuffer(t.FRAMEBUFFER,this.frameBuffer),t.framebufferTexture2D(t.FRAMEBUFFER,t.COLOR_ATTACHMENT0,t.TEXTURE_2D,this.texture,0),t.checkFramebufferStatus(t.FRAMEBUFFER)!==t.FRAMEBUFFER_COMPLETE)throw new Error("Framebuffer not complete");t.bindFramebuffer(t.FRAMEBUFFER,null),this.quad=t.createBuffer(),t.bindBuffer(t.ARRAY_BUFFER,this.quad),t.bufferData(t.ARRAY_BUFFER,ja,t.STATIC_DRAW)}render(){const t=this.gl;t.bindFramebuffer(t.FRAMEBUFFER,null),t.useProgram(this.program),t.bindBuffer(t.ARRAY_BUFFER,this.quad),t.enableVertexAttribArray(this.ppPositionLoc),t.vertexAttribPointer(this.ppPositionLoc,2,t.FLOAT,!1,4*Float32Array.BYTES_PER_ELEMENT,0),t.enableVertexAttribArray(this.ppTexCoordLoc),t.vertexAttribPointer(this.ppTexCoordLoc,2,t.FLOAT,!1,4*Float32Array.BYTES_PER_ELEMENT,2*Float32Array.BYTES_PER_ELEMENT),t.activeTexture(t.TEXTURE0),t.bindTexture(t.TEXTURE_2D,this.texture),t.uniform1f(this.ppTimeLoc,performance.now()/1e3),t.drawArrays(t.TRIANGLE_STRIP,0,4)}resize(){const t=this.gl;t.bindTexture(t.TEXTURE_2D,this.texture),t.texImage2D(t.TEXTURE_2D,0,t.RGBA,this.gl.drawingBufferWidth,this.gl.drawingBufferHeight,0,t.RGBA,t.UNSIGNED_BYTE,null),t.bindTexture(t.TEXTURE_2D,null)}}const Ya=/firefox/i.test(navigator.userAgent),Ha=`\nprecision mediump float; // Use medium precision for fragment calculations\n\nvarying highp vec2 vTextureCoord; // Received texture coordinate from vertex shader\n\nuniform sampler2D uSampler; // The tile texture\nuniform float opacity; // Tile opacity (for fading)\nuniform int noTexture; // Flag indicating if texture is missing/not loaded\n\nvoid main() {\n\tif(noTexture==1) { // If texture is missing\n\t\tgl_FragColor = vec4(.1,.1,.1,.1); // Draw a placeholder color (dark semi-transparent gray)\n\t} else {\n\t${Ya?"\n\t\t// Firefox premultiplied alpha workaround\n\t\tvec4 textureColor = texture2D(uSampler, vTextureCoord);\n\t\t// Manually apply opacity to RGB based on new alpha\n\t\tfloat newAlpha = min(1., textureColor.a * opacity);\n\t\tgl_FragColor = vec4(textureColor.rgb * newAlpha, newAlpha);":"\n\t\t// Standard alpha blending (premultiplied alpha assumed in blendFunc)\n\t\tgl_FragColor = texture2D(uSampler, vTextureCoord) * opacity;"}\n\t\t// Debug: Draw red instead of texture\n\t\t//gl_FragColor = vec4(1.,0.,0.,1.);\n\t}\n}`;class Za{constructor(t){this.micrio=t,this.display=self,this.txtAttr=-1,this.posAttr=-1,this.was360=!1}init(){var t;const e="WebGL2RenderingContext"in window,i=this.micrio.canvas.element.getContext(e?"webgl2":"webgl",{alpha:!0,preserveDrawingBuffer:this.micrio.hasAttribute("data-preserve-drawing-buffer"),stencil:!1,antialias:!1,depth:!1,desynchronized:!1,powerPreference:"high-performance"});if(e?!(i instanceof window.WebGL2RenderingContext):!(i instanceof window.WebGLRenderingContext))throw"Error creating WebGL context. Does your browser support WebGL?";this.gl=i;const r=null==(t=this.micrio.$current)?void 0:t.$settings.postProcessingFragmentShader;r&&(this.postpocessor=new Ga(i,this.micrio,r),this.micrio.keepRendering=!0);const n=i.createProgram();if(!(n instanceof WebGLProgram))throw"Could not create shader program";this.program=n,this.getShader(this.program,i.VERTEX_SHADER,"\nuniform mat4 GLMatrix; // Combined ModelViewProjection matrix from Wasm\n\nattribute vec3 pos; // Vertex position (from Wasm buffer)\nattribute vec2 aTextureCoord; // Texture coordinate (from static buffer)\n\nvarying highp vec2 vTextureCoord; // Pass texture coordinate to fragment shader\n\nvoid main()\n{\n\tgl_Position = GLMatrix * vec4(pos, 1.0); // Calculate clip space position\n\tvTextureCoord = aTextureCoord; // Pass through texture coordinate\n}"),this.getShader(this.program,i.FRAGMENT_SHADER,Ha),i.linkProgram(this.program),i.getProgramParameter(this.program,i.LINK_STATUS)||console.error("Main shader link error:",i.getProgramInfoLog(this.program)),i.useProgram(this.program),i.blendFunc(i.ONE,i.ONE_MINUS_SRC_ALPHA),i.enable(i.BLEND),i.disable(i.DEPTH_TEST),i.clearColor(0,0,0,0);const s=i.getUniformLocation(this.program,"opacity");if(!s)throw"Could not create opacity WebGL binding!";this.opaLoc=s;const o=i.getUniformLocation(this.program,"GLMatrix");if(!o)throw"Could not create matrix WebGL binding!";this.pmLoc=o;const a=i.getUniformLocation(this.program,"noTexture");if(!a)throw"Could not bind noTexture uniform";this.noTxtLoc=a,this.txtAttr=i.getAttribLocation(this.program,"aTextureCoord");const l=i.createBuffer();if(!l)throw"Could not connect texture buffer";this.txtBuffer=l,i.bindBuffer(i.ARRAY_BUFFER,this.txtBuffer),i.bufferData(i.ARRAY_BUFFER,Xa._textureBuffer,i.STATIC_DRAW);const c=i.createBuffer();if(!c)throw"Could not bind geometry buffer";this.geomBuffer=c,this.posAttr=i.getAttribLocation(this.program,"pos"),this.linkBuffers(),i.viewport(0,0,this.gl.drawingBufferWidth,this.gl.drawingBufferHeight)}linkBuffers(){const t=this.gl;t.bindBuffer(t.ARRAY_BUFFER,this.geomBuffer),t.bufferData(t.ARRAY_BUFFER,this.micrio.wasm._vertexBuffer,t.STATIC_DRAW),t.enableVertexAttribArray(this.txtAttr),t.bindBuffer(t.ARRAY_BUFFER,this.txtBuffer),t.vertexAttribPointer(this.txtAttr,2,t.FLOAT,!1,0,0),t.enableVertexAttribArray(this.posAttr),t.bindBuffer(t.ARRAY_BUFFER,this.geomBuffer),t.vertexAttribPointer(this.posAttr,3,t.FLOAT,!1,0,0)}dispose(t=!1){const e=this.gl;if(e){if(e.bindBuffer(e.ARRAY_BUFFER,null),e.bindTexture(e.TEXTURE_2D,null),e.deleteBuffer(this.txtBuffer),e.deleteBuffer(this.geomBuffer),t){const t=e.getExtension("WEBGL_lose_context");t instanceof Object&&t.loseContext instanceof Function&&t.loseContext()}this.gl=null}}getShader(t,e,i){const r=this.gl.createShader(e);if(!r)throw"Could not create shader!";if(this.gl.shaderSource(r,i),this.gl.compileShader(r),!this.gl.getShaderParameter(r,this.gl.COMPILE_STATUS))throw console.error("Error compiling shader",this.gl.getShaderInfoLog(r)),this.gl.deleteProgram(t),new Error(`Shader compilation failed: ${this.gl.getShaderInfoLog(r)}`);this.gl.attachShader(t,r),this.gl.deleteShader(r)}getTexture(t,e,i){const r=this.gl,n=e??r.createTexture();if(!n)throw"Could not create texture!";return r.bindTexture(r.TEXTURE_2D,n),t&&r.texImage2D(r.TEXTURE_2D,0,r.RGBA,r.RGBA,r.UNSIGNED_BYTE,t),r.texParameteri(r.TEXTURE_2D,r.TEXTURE_WRAP_S,r.CLAMP_TO_EDGE),r.texParameteri(r.TEXTURE_2D,r.TEXTURE_WRAP_T,r.CLAMP_TO_EDGE),r.texParameteri(r.TEXTURE_2D,r.TEXTURE_MIN_FILTER,r.LINEAR),r.texParameteri(r.TEXTURE_2D,r.TEXTURE_MAG_FILTER,i?r.NEAREST:r.LINEAR),n}updateTexture(t,e){const i=this.gl;i.bindTexture(i.TEXTURE_2D,t),i.texImage2D(i.TEXTURE_2D,0,i.RGBA,i.RGBA,i.UNSIGNED_BYTE,e),i.bindTexture(i.TEXTURE_2D,null)}drawStart(){const t=this.gl;this.postpocessor&&t.bindFramebuffer(t.FRAMEBUFFER,this.postpocessor.frameBuffer),this.gl.clear(this.gl.COLOR_BUFFER_BIT)}drawEnd(){this.postpocessor&&(this.postpocessor.render(),this.gl.useProgram(this.program),this.linkBuffers())}drawTile(t,e=1,i=!1){this.gl.uniform1i(this.noTxtLoc,t?0:1),this.gl.uniform1f(this.opaLoc,e),t&&(this.gl.activeTexture(this.gl.TEXTURE0),this.gl.bindTexture(this.gl.TEXTURE_2D,t));const r=i?6*Xa.segsX*Xa.segsY:6;i!=this.was360&&(this.gl.bindBuffer(this.gl.ARRAY_BUFFER,this.txtBuffer),this.gl.bufferData(this.gl.ARRAY_BUFFER,i?Xa._textureBuffer360:Xa._textureBuffer,this.gl.STATIC_DRAW),this.gl.bindBuffer(this.gl.ARRAY_BUFFER,this.geomBuffer),this.was360=i),this.gl.bufferData(this.gl.ARRAY_BUFFER,i?this.micrio.wasm._vertexBuffer360:this.micrio.wasm._vertexBuffer,this.gl.STATIC_DRAW),this.gl.drawArrays(this.gl.TRIANGLES,0,r)}}const Ka={passive:!0},Ja={passive:!0,capture:!0},Qa={passive:!1};function tl(t){t.stopPropagation(),t.preventDefault()}const el=["move","marker-open","marker-opened","marker-closed","tour-start","tour-step","tour-stop","tour-event","media-play","media-pause","splitscreen-start","splitscreen-stop"];class il{constructor(t){this.micrio=t,this.enabled=Zi(!1),this.hooked=!1,this.hookedDrag=!1,this.panning=!1,this.pinching=!1,this.clicked=!1,this.wheeling=!1,this.controlZoom=!1,this.twoFingerPan=!1,this.pScale=1,this.wheelEndTo=-1,this.hasTouch=mr.hasTouch&&"ontouchstart"in self,this.hasUsedCtrl=!1,this.vars={drag:{prev:void 0,start:[0,0,0]},dbltap:{lastTapped:0},pinch:{image:void 0,sDst:0,wasPanning:!1},updates:{to:-1,stack:[]}},this.scrollHooked=!1,this.el=t.canvas.element,this.dStart=this.dStart.bind(this),this.dMove=this.dMove.bind(this),this.dStop=this.dStop.bind(this),this.pStart=this.pStart.bind(this),this.pMove=this.pMove.bind(this),this.pStop=this.pStop.bind(this),this.gesture=this.gesture.bind(this),this.keydown=this.keydown.bind(this),this.wheel=this.wheel.bind(this),this.wheelEnd=this.wheelEnd.bind(this),this.dbltap=this.dbltap.bind(this),this.dblclick=this.dblclick.bind(this),this.updateEvent=this.updateEvent.bind(this),this.dispatchUpdate=this.dispatchUpdate.bind(this),this.enabled.subscribe((t=>{t?this.hook():this.unhook()})),t.visible.subscribe((t=>this.visible=t)),t.current.subscribe((t=>{t&&!this.settings&&br(t.info).then((e=>{e&&(this.settings=t.$settings,!t.error&&this.settings.hookEvents&&this.enabled.set(!0))}))}))}get $enabled(){return Ki(this.enabled)}get isNavigating(){return this.panning||this.pinching||this.wheeling||this.clicked}dispatch(t,e){this.micrio.dispatchEvent(new CustomEvent(t,void 0!==e?{detail:e}:void 0))}getImage(t){var e;if(!this.visible)return;const i=this.micrio.offsetWidth,r=this.micrio.offsetHeight,n=Math.max(0,Math.min(1,t.x/i)),s=Math.max(0,Math.min(1,t.y/r)),o=null==(e=this.visible)?void 0:e.find((t=>!!t.opts.secondaryTo)),a=1==this.visible.length?this.visible[0]:this.visible.find((({grid:t,opts:{area:e}})=>(!o||!t)&&(!!e&&(n>=e[0]&&n<=e[2]&&s>=e[1]&&s<=e[3]))));return a&&a.opts.secondaryTo&&a.opts.isPassive&&a.opts.area&&(t.x-=a.opts.area[0]*i,t.y-=a.opts.area[1]*r),!a||a.grid||a.opts.secondaryTo&&a.opts.isPassive?this.micrio.$current:a}hook(){if(this.hooked)return;this.hooked=!0;const t=this.settings;t&&(this.twoFingerPan=!!t.twoFingerPan,this.twoFingerPan?this.micrio.setAttribute("data-can-pan",""):this.micrio.removeAttribute("data-can-pan"),(null==t?void 0:t.hookKeys)&&this.hookKeys(),t.hookDrag&&this.hookDrag(),t.noZoom||this.hookZoom(),this.hookUpdate())}unhook(){this.hooked&&(this.hooked=!1,this.unhookDrag(),this.unhookZoom(),this.unhookKeys(),this.unhookUpdate())}hookKeys(){document.addEventListener("keydown",this.keydown)}unhookKeys(){document.removeEventListener("keydown",this.keydown)}hookZoom(){const t=this.settings;this.controlZoom=!!(null==t?void 0:t.controlZoom),t&&!t.hookPinch||this.hookPinch(),(!t||t.hookScroll||this.controlZoom)&&this.hookScroll(),this.micrio.canvas.$isMobile?this.el.addEventListener("touchstart",this.dbltap):this.el.addEventListener("dblclick",this.dblclick)}unhookZoom(){this.unhookPinch(),this.unhookScroll(),this.micrio.canvas.$isMobile?this.el.removeEventListener("touchstart",this.dbltap):this.el.removeEventListener("dblclick",this.dblclick)}hookScroll(){this.scrollHooked||(this.micrio.addEventListener("wheel",this.wheel,Qa),this.scrollHooked=!0)}unhookScroll(){this.micrio.removeEventListener("wheel",this.wheel,Qa),this.scrollHooked=!1}hookPinch(){this.hasTouch&&this.el.addEventListener("touchstart",this.pStart,Ka),mr.OSX&&(this.micrio.addEventListener("gesturestart",this.gesture,Qa),this.micrio.addEventListener("gesturechange",this.gesture,Qa),this.micrio.addEventListener("gestureend",this.gesture,Qa))}unhookPinch(){this.el.removeEventListener("touchstart",this.pStart,Ka),mr.OSX&&(this.micrio.removeEventListener("gesturestart",this.gesture,Qa),this.micrio.removeEventListener("gesturechange",this.gesture,Qa),this.micrio.removeEventListener("gestureend",this.gesture,Qa))}hookDrag(){this.hookedDrag||(this.hookedDrag=!0,this.micrio.addEventListener("dragstart",tl),this.micrio.addEventListener("pointerdown",this.dStart,Ka),this.micrio.setAttribute("data-hooked",""))}unhookDrag(){this.hookedDrag&&(this.hookedDrag=!1,this.micrio.removeEventListener("pointerdown",this.dStart,Ka),this.micrio.removeEventListener("dragstart",tl),this.micrio.removeAttribute("data-hooked"))}dStart(t,e=!1){var i;if(0!=t.button||"touch"==t.pointerType&&this.twoFingerPan)return;if(!e&&t.target!=this.el)return;if((null==(i=this.micrio.$current)?void 0:i.isOmni)&&t.shiftKey)return;if(this.panning)return void(t instanceof TouchEvent&&t.touches.length>1&&this.dStop());const r=this.getImage({x:t.clientX,y:t.clientY});r&&(this.panning=!0,this.vars.drag.start=[t.clientX,t.clientY,performance.now()],this.micrio.addEventListener("pointermove",this.dMove,Ka),this.micrio.addEventListener("pointerup",this.dStop,Ka),this.micrio.setAttribute("data-panning",""),this.micrio.wasm.e._panStart(r.ptr),this.micrio.wasm.render(),this.dispatch("panstart"))}dMove(t){var e;const i=t.clientX,r=t.clientY,n=ar(this.vars.drag.start[0]-t.clientX,this.vars.drag.start[1]-t.clientY);!this.capturedPointerId&&n>10&&this.micrio.setPointerCapture(this.capturedPointerId=t.pointerId),this.vars.drag.prev&&(null==(e=this.getImage({x:i,y:r}))||e.camera.pan(this.vars.drag.prev[0]-i,this.vars.drag.prev[1]-r)),this.vars.drag.prev=[i,r]}dStop(t,e=!1,i=!1){if(this.panning){if(this.panning=!1,this.vars.drag.prev=void 0,this.micrio.removeEventListener("pointermove",this.dMove,Ka),this.micrio.removeEventListener("pointerup",this.dStop,Ka),this.capturedPointerId&&this.micrio.releasePointerCapture(this.capturedPointerId),this.capturedPointerId=void 0,this.micrio.removeAttribute("data-panning"),t&&0==e){const e=this.getImage({x:t.clientX,y:t.clientY});e&&(this.micrio.wasm.e._panStop(e.ptr),this.micrio.wasm.render())}i||this.dispatch("panend",t?{duration:performance.now()-this.vars.drag.start[2],movedX:t.clientX-this.vars.drag.start[0],movedY:t.clientY-this.vars.drag.start[1]}:void 0)}}pStart(t){if(!(mr.hasTouch&&t instanceof TouchEvent))return;if(this.twoFingerPan&&t.touches.length<2)return;if(this.pinching||2!=t.touches.length)return void this.pStop(t);t.stopPropagation(),this.vars.pinch.wasPanning=this.panning,this.dStop(void 0,!1,!0);const e=t.touches;this.pinching=!0,self.addEventListener("touchmove",this.pMove,Ja),self.addEventListener("touchend",this.pStop,Ja),this.micrio.setAttribute("data-pinching",""),this.vars.pinch.image=this.getImage({x:e[0].clientX,y:e[0].clientY}),this.vars.pinch.sDst=ar(e[0].clientX-e[1].clientX,e[0].clientY-e[1].clientY),this.pinchFactor=void 0,this.vars.pinch.image&&this.micrio.wasm.e._pinchStart(this.vars.pinch.image.ptr),this.micrio.wasm.render(),this.dispatch("pinchstart"),this.twoFingerPan&&this.dispatch("panstart")}pMove(t){if(!(mr.hasTouch&&t instanceof TouchEvent))return;const e=t.touches;if((null==e?void 0:e.length)<2)return;const i={x:e[0].clientX,y:e[0].clientY},r={x:e[1].clientX,y:e[1].clientY},n=this.vars.pinch,s=n.image;if(s){if((null==s?void 0:s.opts.secondaryTo)&&s.opts.isPassive&&s.opts.area){const t=s.opts.area[0]*this.micrio.offsetWidth,e=s.opts.area[1]*this.micrio.offsetHeight;i.x-=t,r.x-=t,i.y-=e,r.y-=e}this.pinchFactor=ar(e[0].clientX-e[1].clientX,e[0].clientY-e[1].clientY)/n.sDst,this.micrio.wasm.e._pinch(s.ptr,i.x,i.y,r.x,r.y)}}pStop(t){if(!this.pinching)return;this.pinching=!1,self.removeEventListener("touchmove",this.pMove,Ja),self.removeEventListener("touchend",this.pStop,Ja),this.micrio.removeAttribute("data-pinching");const e=this.vars.pinch.image;e&&(this.micrio.wasm.e._pinchStop(e.ptr,performance.now()),this.micrio.wasm.render()),this.vars.pinch.image=void 0,this.pinchFactor=void 0,this.dispatch("pinchend"),this.twoFingerPan&&!this.vars.pinch.wasPanning&&this.dispatch("panend"),t instanceof TouchEvent&&1==t.touches.length&&this.dStart(t,!0)}gesture(t){var e;const i=t.scale;if(1==i)return;const r=this.pScale-i;if(this.pScale=i,t.stopPropagation(),t.preventDefault(),"gesturechange"==t.type){const i=t;null==(e=this.getImage({x:i.clientX,y:i.clientY}))||e.camera.zoom(r*this.micrio.canvas.viewport.height,0,i.clientX,i.clientY)}}wheel(t,e=!1,i=0){var r;if(!(t instanceof WheelEvent))return;if(this.controlZoom&&!t.ctrlKey)return;if(!e&&t.target instanceof Element&&t.target!=this.el&&!t.target.classList.contains("marker")&&!t.target.hasAttribute("data-scroll-through"))return;let n=t.deltaY;t.ctrlKey&&(this.hasUsedCtrl=!0);const s=this.controlZoom&&10*n%1==0,o=this.hasUsedCtrl&&!s,a=mr.firefox||t.ctrlKey||!o;if(this.twoFingerPan&&(null==(r=this.micrio.$current)?void 0:r.camera.isZoomedOut()))return;t.stopPropagation(),t.preventDefault(),(mr.OSX||o)&&t.ctrlKey&&(n*=10);const l={x:t.clientX,y:t.clientY},c=this.getImage(l);if(c){if(a){const t=this.micrio.canvas.viewport;let e=0;const r=this.micrio.getBoundingClientRect();c.camera.zoom(1*n/Math.sqrt(t.scale),0,l.x-i-r.left,l.y-r.top-e)}else c.camera.pan(t.deltaX,t.deltaY);this.wheeling=!0,clearTimeout(this.wheelEndTo),this.wheelEndTo=setTimeout(this.wheelEnd,50)}}wheelEnd(){this.wheeling=!1}dbltap(t){if(!(mr.hasTouch&&t instanceof TouchEvent))return;const e=performance.now();1==t.touches.length&&e-this.vars.dbltap.lastTapped<250&&(t.stopPropagation(),t.preventDefault(),this.dblclick(t)),this.vars.dbltap.lastTapped=e}dblclick(t){var e;const i=t instanceof TouchEvent?t.touches[0]:t,r=this.getImage({x:i.clientX,y:i.clientY});null==r||r.camera.zoom(-300,500,i.clientX,i.clientY,1,!(null==(e=this.micrio.$current)?void 0:e.album)).catch((()=>{}))}keydown(t){var e;if(this.panning||this.pinching||!(null==(e=this.micrio.$current)?void 0:e.camera))return;const i=this.micrio.$current.camera,r=this.micrio.offsetWidth/2,n=this.micrio.offsetHeight/2;let s=0,o=0;switch(t.key){case"ArrowUp":o-=n;break;case"ArrowDown":o+=n;break;case"ArrowLeft":s-=r;break;case"ArrowRight":s+=r;break;case"+":case"=":i.zoom(-200,150);break;case"-":case"_":i.zoom(200,150);break;default:return}t.preventDefault(),t.stopPropagation(),0==s&&0==o||i.pan(s,o,150)}hookUpdate(){el.forEach((t=>this.micrio.addEventListener(t,this.updateEvent)))}unhookUpdate(){el.forEach((t=>this.micrio.removeEventListener(t,this.updateEvent)))}updateEvent(t){if("move"==t.type&&!this.isNavigating)return;const e=this.vars.updates.stack;e[e.length-1]!=t.type&&e.push(t.type),clearTimeout(this.vars.updates.to),this.vars.updates.to<0&&(this.vars.updates.to=setTimeout(this.dispatchUpdate))}dispatchUpdate(){const t=this.vars.updates;clearTimeout(t.to),t.to=-1,t.stack.length&&(this.dispatch("update",t.stack),t.stack.length=0,t.to=setTimeout(this.dispatchUpdate,500))}}const rl=class t{constructor(t){this.micrio=t,this.isStatic=!1,this.loaded=!1,this.inited=!1,this.setting=!1,this.writeTitle=!1}hook(){this.isStatic="static"==this.micrio.getAttribute("data-router"),this.read=this.read.bind(this),this.write=this.write.bind(this),this.writeDeferred=this.writeDeferred.bind(this),br(this.micrio.current).then((()=>{this.loaded=!0,this.read()})),t.events.forEach((t=>this.micrio.addEventListener(t,this.write))),"i.micr.io"==location.hostname&&(this.writeTitle=!0),window.addEventListener(this.isStatic?"popstate":"hashchange",this.read)}unhook(){t.events.forEach((t=>this.micrio.removeEventListener(t,this.write))),window.removeEventListener(this.isStatic?"popstate":"hashchange",this.read)}findPage(t,e,i){var r,n;if(e)for(let s=0;s<e.length;s++){const o=(null==(n=null==(r=e[s])?void 0:r.i18n)?void 0:n[i])??e[s];let a=pr(o.title)==t?e[s]:this.findPage(t,e[s].children,i);if(a)return a}}read(){if(!this.loaded||this.setting)return;this.route=(this.isStatic?location.pathname:location.hash).slice(1);const[t,e,i,r,n]=this.route.split("/"),s=this.micrio.$current,o=t&&(null==s?void 0:s.id)!=t?this.micrio.open(t):void 0;s&&Promise.all([br(s.data,{allowUndefined:!0}),o?br(o.data,{allowUndefined:!0}):void 0]).then((t=>{var i,a;if(!t[0])return this.inited=!0;if(void 0===this.prevLang&&(this.prevLang=this.micrio.lang),!1===(null==o?void 0:o.$settings.routerMarkerTours))return;if((null==(i=t[0].pages)?void 0:i.length)&&r){const i=this.findPage(r.toLowerCase(),t[0].pages,e);if(i)return void this.micrio.state.popover.set({contentPage:i})}const l=r?n?t.map((t=>{var i;return null==(i=null==t?void 0:t.markerTours)?void 0:i.find((t=>{var i,n;return pr(null==(n=null==(i=t.i18n)?void 0:i[e])?void 0:n.slug)==r}))}))[0]:t.map((t=>{var i;return null==(i=null==t?void 0:t.tours)?void 0:i.find((t=>{var i,n;return pr(null==(n=null==(i=t.i18n)?void 0:i[e])?void 0:n.slug)==r}))}))[0]:void 0,c=n||!l&&r,u=c?null==(a=(t[1]??t[0]).markers)?void 0:a.find((t=>{var i,r,n;return((null==(r=null==(i=t.i18n)?void 0:i[e])?void 0:r.slug)??pr(t.title))==c||l&&"steps"in l&&(null==(n=l.stepInfo)?void 0:n.map((t=>t.marker)).find((t=>{var i,r;return(null==(r=null==(i=t.i18n)?void 0:i[e])?void 0:r.slug)==c})))})):void 0;u&&l&&"steps"in l?l.initialStep=l.steps.findIndex((t=>t.startsWith(u.id))):(u||this.micrio.state.popup.set(void 0),(o??s).state.marker.set(u)),this.micrio.state.tour.set(l),this.writeTitle&&this.setTitle(),this.inited=!0}))}setTitle(){var t,e,i,r,n,s,o,a,l,c;const u=Ki(this.micrio._lang),d=this.micrio.$current;if(!d)return;const h=[(null==(i=null==(e=null==(t=d.$data)?void 0:t.i18n)?void 0:e[u])?void 0:i.title)??(null==(r=null==d?void 0:d.$info)?void 0:r.title),null==(o=null==(s=null==(n=this.micrio.state.$tour)?void 0:n.i18n)?void 0:s[u])?void 0:o.title,null==(c=null==(l=null==(a=this.micrio.state.$marker)?void 0:a.i18n)?void 0:l[u])?void 0:c.title].filter((t=>!!t)).reverse();document.title=h.join(" - ")+" | Micrio"}write(t){if(this.micrio.$current&&this.loaded&&this.inited){if("marker-open"===t.type){const t=this.micrio.state.$marker;if(t&&t.data&&t.data.micrioLink)return}clearTimeout(this._to),this._to=setTimeout((()=>this.writeDeferred("load"==t.type)),50)}}writeDeferred(t){var e,i,r,n,s,o,a,l,c;const u=this.micrio.state.$tour;let d=this.micrio.$current,h=null==d?void 0:d.state.$marker;const m=this.micrio.lang;m!=this.prevLang&&(t=!0,this.prevLang=m);const v=(null==(r=null==(i=null==(e=null==d?void 0:d.$data)?void 0:e.i18n)?void 0:i[m])?void 0:r.title)??(null==(n=null==d?void 0:d.$info)?void 0:n.title)??"",p=!1===(null==d?void 0:d.$settings.routerMarkerTours),f=h&&"string"!=typeof h?(null==(s=h.i18n)?void 0:s[m])??h:void 0,g=null==(o=Ki(this.micrio.state.popover))?void 0:o.contentPage,w=g?(null==(a=g.i18n)?void 0:a[m])??g:void 0;let b=null==d?void 0:d.id;if(u&&"steps"in u&&u.steps.length&&u.stepInfo){const t=u.stepInfo.find((t=>t.markerId==u.steps.find((t=>!t.includes(",")))));t&&(b=t.micrioId,d=this.micrio.wasm.images.find((t=>t.id==b)),h||void 0===u.initialStep||(h=u.stepInfo[u.initialStep].marker))}const y=[b,m,pr(v)??"",...p?[]:w?[pr(w.title)]:[(null==(c=null==(l=null==u?void 0:u.i18n)?void 0:l[m])?void 0:c.slug)??null,(null==f?void 0:f.slug)??pr(null==f?void 0:f.title)??null]].filter((t=>!!t)).join("/");y!=this.route&&(this.setting=!0,this.isStatic?t?history.replaceState(null,"","/"+y+location.search):history.pushState(null,"","/"+y+location.search):location.hash=y,this.route=y,this.writeTitle&&this.setTitle(),setTimeout((()=>this.setting=!1),250))}};rl.events=["load","tour-start","tour-stop","marker-open","marker-closed","page-open","page-closed","lang-switch"];let nl=rl;const sl=class t{constructor(t){this.micrio=t,this.gtag="gtag"in window?window.gtag:void 0,this.hooked=!1,this.tag=this.tag.bind(this)}hook(){!this.hooked&&this.gtag&&(this.hooked=!0,this.tag(new CustomEvent("init")),t.events.forEach((t=>this.micrio.addEventListener(t,this.tag))))}unhook(){this.hooked&&(this.hooked=!1,this.tag(new CustomEvent("hide")),t.events.forEach((t=>this.micrio.removeEventListener(t,this.tag))))}tag(t){if(!this.gtag)return;const e=t.detail,i=this.micrio.$current,r={event_category:"Micrio",event_action:t.type};this.micrio.lang&&(r.culture=this.micrio.lang),"init"==t.type&&(r.micrio_version=oa),"load"==t.type&&(null==i?void 0:i.$info)&&(r.image_version=i.$info.version);const n=null!==e&&"object"==typeof e&&"currentStep"in e?e.currentStep:null;null!=n&&(r.event_value=n);const s=e&&e.title?e.title:i&&i.$info&&i.$info.title;r.event_label=this.micrio.id+(s?" - "+s:""),this.gtag("event",t.type,r)}};sl.events=["load","show","hide","marker-open","marker-opened","marker-closed","tour-start","tour-stop","tour-step","tour-ended"];let ol=sl;const al=t=>Math.round(1e5*t)/1e5,ll=class t{constructor(e,i){var r;this.micrio=e,this.image=i,this.images=[],this.current=[],this._grid=document.createElement("div"),this._buttons=new Map,this.clickable=!1,this.focussed=Zi(),this.markersShown=Zi([]),this.history=[],this.depth=Zi(0),this.aniDurationIn=1.5,this.aniDurationOut=.5,this.transitionDelay=.5,this.isHorizontal=!1,this.cellSizes=new Map,this.nextSize=new Map,this.timingFunction="ease",this.getString=(e,i={})=>{var r;return t.getString(e,{view:i.view,area:i.area,size:i.size??this.nextSize.get(e.id),cultures:null==(r="cultures"in e&&e.cultures?e.cultures:"")?void 0:r.replace(/,/g,"-")})},this.tourEvent=this.tourEvent.bind(this),this.updateGrid=this.updateGrid.bind(this);const n=i.$settings;this.clickable=!!n.gridClickable,void 0!==n.gridTransitionDuration&&(this.aniDurationIn=this.aniDurationOut=n.gridTransitionDuration),void 0!==n.gridTransitionDurationOut&&(this.aniDurationOut=n.gridTransitionDurationOut),this._grid.className="micrio-grid",this.set(null==(r=i.$info)?void 0:r.grid);const s=()=>Xt().then((()=>{this.hook(),e.events.dispatch("grid-load")}));i.isV5?s():e._lang.subscribe((t=>{t?Promise.all(this.images.filter((e=>{var i;return(e.$info&&"cultures"in e.$info&&(null==(i=e.$info)?void 0:i.cultures)||"").indexOf(t)>=0})).map((t=>br(t.data)))).then(s):s()})),e.events.dispatch("grid-init",this)}get $focussed(){return Ki(this.focussed)}hook(){if(this.micrio.state.marker.subscribe((t=>{var e,i;if(t&&"string"!=typeof t){const r=null==(e=t.data)?void 0:e._meta;if(null==r?void 0:r.gridSize){const e="number"==typeof r.gridSize?[r.gridSize,r.gridSize]:r.gridSize.split(",").map(Number),n=null==(i=this.images.find((e=>{var i,r;return null==(r=null==(i=e.$data)?void 0:i.markers)?void 0:r.find((e=>e==t))})))?void 0:i.id;n&&this.nextSize.set(n,e)}Xt().then((()=>{var t;const e=null==(t=null==r?void 0:r.gridAction)?void 0:t.split("|");(null==e?void 0:e.length)&&"string"==typeof e[0]&&this.action(e.shift(),e.join("|"))}))}})),this.clickable){this._grid.addEventListener("click",(t=>{const e=t.target.dataset.id;e&&this.focus(this.images.find((t=>t.id==e)))}));const t=t=>{t?this.removeGrid():this.placeGrid()};this.micrio.state.tour.subscribe(t),this.micrio.state.marker.subscribe(t),this.focussed.subscribe(t)}this.micrio.addEventListener("tour-event",this.tourEvent),this.micrio.addEventListener("serialtour-pause",(()=>this.images.forEach((t=>t.camera.pause())))),this.micrio.addEventListener("serialtour-play",(()=>this.images.forEach((t=>t.camera.resume()))))}clearTimeouts(){clearTimeout(this._to),clearTimeout(this._fadeTo)}set(t="",e={}){return this.lastPromise=new Promise(((i,r)=>{var n,s,o;null==(s=null==(n=this.image.$info)?void 0:n.settings)||delete s.focus,this.lastAction=void 0,!1===e.cover&&e.coverLimit&&(e.coverLimit=!1),e.coverLimit&&null==e.cover&&(e.cover=e.coverLimit),"string"!=typeof t&&(t=t.map((t=>t instanceof xa?{image:t}:t)).filter((t=>!!t.image.$info)).map((t=>this.getString(t.image.$info,t))).join(";"));const a=t.split(";").filter((t=>!!t)).map((t=>this.getImage(t))),l=this.$focussed,c=null==(o=e.transition)?void 0:o.endsWith("-delayed"),u="behind-delayed"==e.transition;switch(e.transition){case"crossfade":e.duration=0;break;case"behind":case"behind-delayed":const t=!0===e.coverLimit;e.forceAni=!0,e.coverLimit=t,e.forceAreaAni=!0;const i=c?1/a.length:1;let r=0;this.images.forEach((e=>{e.camera.setCoverLimit(t),a.find((t=>t.id==e.id))&&(e.camera.setArea([0,0,(null==l?void 0:l.id)==e.id?1:i,1],{noDispatch:!0,direct:!0}),e!=l&&e.camera.setView([0,0,1,1]),c&&this.micrio.wasm.e._setZIndex(e.ptr,a.length-r++))})),a.forEach((t=>t.view=[0,0,1,1]))}const d=this.image.ptr>=0,h=e.duration??(e.noHistory?this.aniDurationOut:this.aniDurationIn),m=this.nextCrossFadeDuration??this.image.$settings.crossfadeDuration??1,v=(h||this.aniDurationIn)/(u?2:1);if(this.nextCrossFadeDuration=void 0,d){const t=this.micrio.wasm.getPtr();this.micrio.wasm.e.setGridTransitionDuration(t,h),this.micrio.wasm.e.setCrossfadeDuration(t,v)}const p=!e.noBlur&&l;p&&this.blur(),!e.noHistory&&this.current.length&&this.depth.set(this.history.push({layout:this.current.map((t=>this.getString(t.$info,{view:t.state.$view,size:this.cellSizes.get(t.id)}))).join(";"),horizontal:this.isHorizontal,view:this.image.camera.getView()})),this.isHorizontal=!!e.horizontal,this.removeImages(this.images.filter((t=>!a.find((e=>e.id==t.id))))),this.printGrid(a,{horizontal:e.horizontal,keepGrid:e.keepGrid,scale:e.scale,columns:e.columns}),this.clearTimeouts();let f=!1;const g=()=>{this.clearTimeouts(),f||r()};d&&!e.noCamAni&&(e.view?this.image.camera.flyToView(e.view,{duration:1e3*h}).catch(g):this.image.camera.flyToFullView({duration:1e3*h}).catch(g)),this.nextSize.clear(),null==e.coverLimit&&(e.coverLimit=!0),e.coverLimit||a.forEach((t=>{var i;return null==(i=this.images.find((e=>e.id==t.id)))?void 0:i.camera.setCoverLimit(!!e.coverLimit)}));const w="appear-delayed"==e.transition,b=t=>t*this.transitionDelay+(t>0&&w?h:0);this.current=a.map(((t,i)=>this.placeImage(t,{duration:!e.forceAni&&p&&t.id!=(null==l?void 0:l.id)?0:h,delay:c?b(i):0,noCamAni:!!(w&&i>0)||!!e.noCamAni,forceAreaAni:!(w&&i>0)&&e.forceAreaAni,cover:e.cover}))),w&&this.current.slice(1).forEach((t=>this.micrio.wasm.e._fadeTo(t.ptr,.9999,!0)));const y=()=>this.current.forEach(((t,e)=>dr(c?1e3*(b(e)+(u?h/2:0)):0).then((()=>this.micrio.wasm.e._fadeIn(t.ptr))))),k=()=>{this.clearTimeouts(),requestAnimationFrame((()=>this.micrio.wasm.e.setCrossfadeDuration(this.micrio.wasm.getPtr(),m))),c&&this.images.forEach((t=>this.micrio.wasm.e._setZIndex(t.ptr,0))),e.coverLimit&&a.forEach((t=>{var i;return null==(i=this.images.find((e=>e.id==t.id)))?void 0:i.camera.setCoverLimit(!!e.coverLimit)})),this.clickable&&this.placeGrid(),this.lastAction=void 0,f=!0,i(this.current)};h||v?(e.noFade||(this._fadeTo=setTimeout(y,Math.max(0,h/2*1e3))),this._to=setTimeout(k,1e3*(Math.max(v,h)+(c?(a.length-1)*this.transitionDelay:0)))):(e.noFade||y(),k())}))}hasChanged(){return this.current.map((t=>t.id)).join(",")!=this.images.map((t=>t.id)).join(",")}getImage(t){var e,i;const r=t.split("|"),n=r[0].split(","),s=r[1]?r[1].split(",").map(Number):[1];let o=0,a=0;return{path:null==(e=this.image.$info)?void 0:e.path,id:n[0],width:o=Number(n[1])||o,height:a=Number(n[2])||a,isDeepZoom:"d"==n[3],isPng:"p"==n[4],isWebP:"w"==n[4],size:s,view:n[5]?n[5].split("/").map(Number):void 0,area:n[6]?n[6].split("/").map(Number):void 0,settings:vr(this.image.$settings||{},{focus:n[7]?n[7].split("-").map(Number):null}),cultures:(null==(i=n[8])?void 0:i.replace(/\-/g,","))||void 0}}getCols(t,e){let i=Math.ceil(e/Math.ceil(Math.sqrt(e)));if(t==e){const e=Math.floor(Math.sqrt(t)),r=[];for(let n=e;n<i+e;n++)t%n||r.push(n);r.length&&(i=r[Math.floor(r.length/2)])}return i}printGrid(t,e){var i;e.keepGrid||this.removeGrid();const r=t.reduce(((t,e)=>t+e.size.reduce(((t,e)=>e*t),1)),0),n=e.columns??(e.horizontal?t.length:this.getCols(t.length,r));this._grid.style.gridTemplateColumns=`repeat(${n}, auto)`,this._grid.textContent="",this._grid.style.removeProperty("--translate"),this._grid.style.removeProperty("--scale"),t.forEach((t=>{if(!t.id)return;this._buttons.has(t.id)||this._buttons.set(t.id,document.createElement("button"));const e=this._buttons.get(t.id);"1"!=t.size.toString()?(e.style.gridArea=`auto / auto / span ${t.size[1]} / span ${t.size[0]||t.size[1]}`,this.cellSizes.set(t.id,t.size)):(e.style.removeProperty("grid-area"),this.cellSizes.delete(t.id)),e.dataset.id=t.id,this._grid.appendChild(e)})),e.keepGrid&&this._grid.parentNode||this.micrio.insertBefore(this._grid,(null==(i=this.micrio.firstChild)?void 0:i.nextSibling)??null),this.micrio.events.dispatch("grid-layout-set",this);const s=this.micrio.offsetWidth,o=this.micrio.offsetHeight,a=Math.max(0,Math.min(1,1-(e.scale??1)));this._grid.style.transform="",this._grid.childNodes.forEach((e=>{if(!e)return;const i=e,r=i.dataset.id,n=i.getBoundingClientRect(),l=t.find((t=>t.id==r)),c=[a/2*n.width,a/2*n.height];l&&!l.area&&(l.area=[(n.x+c[0])/s,(n.y+c[1])/o,(n.x+n.width-c[0])/s,(n.y+n.height-c[1])/o])})),e.keepGrid||this._grid.remove()}placeGrid(){var t;!this.clickable||this.micrio.state.$tour||this.micrio.state.$marker||this._grid.parentNode||(this.micrio.insertBefore(this._grid,(null==(t=this.micrio.firstChild)?void 0:t.nextSibling)??null),this.viewUnsub=this.image.state.view.subscribe(this.updateGrid))}removeGrid(){this._grid.parentNode&&(this.viewUnsub&&this.viewUnsub(),this._grid.remove())}updateGrid(){const t=this.image.camera.getXY(0,0,!0);this._grid.style.setProperty("--translate",`translate3d(${t[0]}px, ${t[1]}px, 0)`),this._grid.style.setProperty("--scale",this.image.camera.getScale().toString()),this._grid.dispatchEvent(new CustomEvent("update"))}placeImage(t,e){let i=this.images.find((e=>e.id==t.id));i&&t.area?dr(1e3*e.delay).then((()=>{i.camera.setArea(t.area,{direct:0==e.duration||!e.forceAreaAni&&!Ki(i.visible)}),e.delay&&this.micrio.wasm.render()})):(t.lang=this.micrio.lang,this.micrio.wasm.addChild(i=new xa(this.micrio.wasm,t,{area:t.area}),this.image),this.images.push(i));const r={duration:1e3*e.duration,timingFunction:this.timingFunction,limit:!1};if(!e.noCamAni&&!i.camera.aniDone&&i.ptr>0){const n=!!e.cover||i.camera.getCoverLimit();if(t.view||!n)i.camera.flyToView(t.view??[0,0,1,1],r).catch((()=>{}));else if(t.area&&t.width&&t.height){const e=(t.area[2]-t.area[0])*this.micrio.offsetWidth/((t.area[3]-t.area[1])*this.micrio.offsetHeight);i.camera.flyToView(e<t.width/t.height?[.5,0,.5,1]:[0,.5,1,.5],r).catch((()=>{}))}else i.camera.flyToCoverView(r).catch((()=>{}))}return i}removeImages(t){t.forEach((t=>{t.ptr>=0&&this.micrio.wasm.e._fadeOut(t.ptr)})),this.micrio.wasm.render()}insideGrid(){const t=this.micrio.$current;return t==this.image||!!this.images.find((e=>e==t))}async reset(t,e,i){var r,n;const s=this.history[0];return this.images.forEach((t=>t.camera.stop())),this.image.camera.stop(),this.markersShown.set([]),await Xt(),i||e||!(null==(r=this.micrio.camera)?void 0:r.isZoomedOut())||this.micrio.state.$tour||this.$focussed||this.hasChanged()||(t=0),this.set((null==s?void 0:s.layout)||(null==(n=this.image.$info)?void 0:n.grid),{noHistory:!0,duration:t,noCamAni:e,forceAni:i,horizontal:!!s&&s.horizontal}).then((t=>(this.depth.set(this.history.length=0),this.micrio.current.set(this.image),t)))}switchToGrid(){const t=this.$focussed;if(!t)return;const e=t.camera.getView();e&&this.reset(0,!0).then((()=>{t.opts.area&&this.image.camera.setView(t.opts.area,{noLimit:!0}),t.camera.setView(e,{noLimit:!0}),this.micrio.current.set(this.image)}))}async flyToMarkers(t,e,i){const r=null==t?void 0:t.split("|").map((t=>t.trim())),n=(null==r?void 0:r[0])??"",s=n?this.images.filter((t=>{var e,i;return!!(null==(i=null==(e=t.$data)?void 0:e.markers)?void 0:i.find((t=>t.tags.includes(n))))})):this.images;return this.set(s.map((t=>{var e,r;const s=null==(r=null==(e=t.$data)?void 0:e.markers)?void 0:r.find((t=>t.tags.indexOf(n)>=0));return this.getString(t.$info,{view:i||null==s?void 0:s.view})})).join(";"),{duration:e,horizontal:"h"==(null==r?void 0:r[1])})}async back(t){const e=this.history.pop();if(!e)return;this.depth.set(this.history.length),this.micrio.current.set(this.image);this.$focussed&&this.blur(),await this.set(e.layout,{duration:t,noHistory:!0,horizontal:e.horizontal,view:e.view})}setTimingFunction(t){const e=this.micrio.wasm.getPtr();this.micrio.wasm.e.setGridTransitionTimingFunction(e,va.Camera.TimingFunction[this.timingFunction=t])}async focus(t,e={}){var i;if(!t)return this.back();e.coverLimit&&(e.cover=!0);const r=!e.view&&!e.cover,n=this.micrio;Ki(n.visible).find((t=>t==this.image))||n.current.set(this.image);const s=this.$focussed;if(s==t)return;!(null==(i=e.transition)?void 0:i.startsWith("slide-"))&&(0==e.duration||s&&!n.wasm.e._areaAnimating(s.ptr)&&!this.current.find((e=>e==t)))&&t.camera.setArea([0,0,1,1],{noDispatch:!0,direct:!0}),s&&this.blur(),t.camera.setCoverLimit(!!e.cover),this.setTimingFunction("ease");const o=await this.transition(t,s,this.getString(t.$info,{view:e.view}),e);return n.wasm.e._setZIndex(t.ptr,3),this.focussed.set(t),Ki(t.visible)||"crossfade"!=e.transition&&e.transition||(e.duration=0),this.set(o,{noBlur:!0,duration:e.duration,forceAreaAni:"crossfade"!=e.transition,cover:!!e.cover,coverLimit:!!e.coverLimit}).then((()=>{n.events.dispatch("grid-focus",t);const e=t.$info;this.removeGrid(),n.$current!=t&&n.current.set(t);const i=n.offsetWidth/n.offsetHeight,s=(1-e.width/e.height/i)/2;!t.camera.aniDone&&r&&t.camera.flyToFullView({duration:1e3*this.aniDurationIn}).catch((()=>{})),this.image.camera.setLimit([s,0,1-s,1])})).catch((()=>{}))}async transition(t,e,i,{duration:r,view:n,transition:s,noViewAni:o,exitView:a,blur:l,cover:c}){if(!s)return i;if("crossfade"==s&&(t.camera.setArea([0,0,1,1]),o=!0),n&&o&&t.camera.setView(n,{noRender:!0,noLimit:!0}),!e||"crossfade"==s)return i;const u=s.startsWith("slide")||s.startsWith("swipe"),d=s.startsWith("behind"),h=u?s.endsWith("-up")?0:s.endsWith("-down")?180:s.endsWith("-left")?270:90:void 0;if((u||d)&&this.micrio.wasm.e._fadeTo(t.ptr,.9999,!0),s.startsWith("slide"))t.camera.setArea(0==h?[0,-.5,1,0]:180==h?[0,1,1,1.5]:270==h?[-.5,0,0,1]:[1,0,1.5,1],{noDispatch:!0,direct:!0});else if(s.startsWith("swipe"))t.camera.setArea(0==h?[0,-1,1,0]:180==h?[0,1,1,2]:270==h?[-1,0,0,1]:[1,0,2,1],{noDispatch:!0,direct:!0}),i=[this.getString(e.$info,{view:a??e.camera.getView(),area:0==h?[0,1,1,2]:180==h?[0,-1,1,0]:270==h?[1,0,2,1]:[-1,0,0,1]}),this.getString(t.$info,{view:n,area:[0,0,1,1]})].join(";");else if(d){t.camera.setArea([0,0,1,1]),t.camera.setView([0,0,1,1]);const i=[this.getString(e.$info,{view:[0,0,1,1]}),this.getString(t.$info,{view:[0,0,1,1]})];"behind-left"==s&&i.reverse(),await this.set(i.join(";"),{noBlur:!0,horizontal:!0,coverLimit:c}).then((()=>dr(200)))}if(l&&!isNaN(l)&&l>0){const t=(r=r??this.nextCrossFadeDuration??this.aniDurationIn)/2,e=this.micrio.canvas.element.style;e.transition=`filter ${t}s ease`,e.filter=`blur(${l}px)`,setTimeout((()=>{e.filter="",setTimeout((()=>e.transform=""),1e3*t)}),1e3*t)}return i}blur(){const t=this.$focussed;t&&(this.micrio.wasm.e._setZIndex(t.ptr,2),this.micrio.events.dispatch("grid-blur"),this.focussed.set(void 0),this.image.camera.setLimit([0,0,1,1]),this.micrio.current.set(this.image))}tourEvent(t){var e;const i=t.detail;i&&(null==(e=i.action)?void 0:e.startsWith("grid:"))&&i.active&&this.action(i.action.slice(5),i.data,i.end-i.start)}action(t,e,i){"string"==typeof t&&(t=va.Grid.GridActionType[t]);const r=t+(e??"");if(this.lastAction!=r){switch(t){case va.Grid.GridActionType.focus:const t=null==e?void 0:e.split("|").map((t=>t.trim())),r=(null==t?void 0:t[0])??"",n=null==r?void 0:r.split(",").map((t=>this.images.find((e=>e.id==(null==t?void 0:t.trim()))))).filter((t=>void 0!==t));1==n.length?this.focus(n[0],{duration:i}):n.length>0&&this.set(n.map((t=>this.getString(t.$info))).join(";"),{duration:i,horizontal:"h"==(null==t?void 0:t[1])});break;case va.Grid.GridActionType.flyTo:const s=null==e?void 0:e.split(",").map((t=>this.current.find((e=>e.id==(null==t?void 0:t.trim())))));(null==s?void 0:s.length)?this.image.camera.flyToView([Math.min(...s.map((t=>{var e;return(null==(e=null==t?void 0:t.opts.area)?void 0:e[0])??0}))),Math.min(...s.map((t=>{var e;return(null==(e=null==t?void 0:t.opts.area)?void 0:e[1])??0}))),Math.max(...s.map((t=>{var e;return(null==(e=null==t?void 0:t.opts.area)?void 0:e[2])??1}))),Math.max(...s.map((t=>{var e;return(null==(e=null==t?void 0:t.opts.area)?void 0:e[3])??1})))],{duration:i?1e3*i:void 0}).catch((()=>{})):console.warn("Given image IDs gave no current displayed images",event);break;case va.Grid.GridActionType.focusTagged:this.flyToMarkers(e,i);break;case va.Grid.GridActionType.focusWithTagged:this.flyToMarkers(e,i,!0);break;case va.Grid.GridActionType.reset:this.reset(i);break;case va.Grid.GridActionType.back:this.back(i);break;case va.Grid.GridActionType.switchToGrid:this.switchToGrid();break;case va.Grid.GridActionType.nextFadeDuration:this.nextCrossFadeDuration=Number(e);break;case va.Grid.GridActionType.filterTourImages:br(this.micrio.state.tour).then((t=>{if(!t)return;if(!("steps"in t)||!t.stepInfo)return;const r=t.stepInfo.map((t=>t.micrioId)),n=r.filter(((t,e)=>r.indexOf(t)==e)).map((t=>this.images.find((e=>e.id==t)))).filter((t=>!!t)).map((t=>this.getString(t.$info))).join(";");n&&this.set(n,{duration:i,horizontal:"h"==e})}));break;default:console.warn("Warning: unknown grid tour event",event)}this.lastAction=r}}async enlarge(t,e,i=e){var r;return this.set(((null==(r=this.history[this.history.length-1])?void 0:r.layout)||this.image.$info.grid).split(";").map(((r,n)=>`${r}|${n==t?`${e},${i}`:1}`)).join(";"),{noHistory:!0,keepGrid:!0,duration:500})}getRelativeView(t,e){const i=t.opts.area??[0,0,1,1],r=i[2]-i[0],n=i[3]-i[1];return[i[0]+r*e[0],i[1]+n*e[1],i[0]+r*e[2],i[1]+n*e[3]]}};ll.getString=(t,e)=>{var i,r,n,s;return[t.id,t.width,t.height,t.isDeepZoom?"d":"",t.isPng?"p":t.isWebP?"w":"",null==(i=e.view)?void 0:i.map(al).join("/"),null==(r=e.area)?void 0:r.map(al).join("/"),null==(s=null==(n=t.settings)?void 0:n.focus)?void 0:s.map(al).join("-"),e.cultures].join(",").replace(/,+$/,"")+(e.size?`|${e.size.join(",")}`:"")};let cl=ll;class ul{constructor(t){this.micrio=t,this.element=document.createElement("canvas"),this.resizing=!1,this.hasPerspective=!1,this.viewport={width:0,height:0,left:0,top:0,ratio:0,scale:0,portrait:!1},this.isMobile=Zi(!1),this.getRatio=(t=(t=>null==(t=this.micrio.$current)?void 0:t.$settings)()??{})=>!mr.iOS&&!(null==t?void 0:t.noRetina)&&self.devicePixelRatio&&Math.max(1,Math.min(2,self.devicePixelRatio))||1,this.onresize=this.onresize.bind(this),self.ResizeObserver&&(this.resizeObserver=new self.ResizeObserver(this.onresize)),this.element.className="micrio"}get $isMobile(){return Ki(this.isMobile)}place(){if(this.element.parentNode)return;const t=this.micrio.querySelector("img.preview");this.micrio.insertBefore(this.element,t?t.nextSibling:this.micrio.firstChild)}hook(){this.onresize(),this.resizeObserver?this.resizeObserver.observe(this.element):window.addEventListener("resize",this.onresize)}unhook(){this.resizeObserver?this.resizeObserver.unobserve(this.element):window.removeEventListener("resize",this.onresize)}onresize(){var t,e,i;const r=this.element.getBoundingClientRect();(null==(t=this.micrio.$current)?void 0:t.is360)&&(this.hasPerspective=!0);let n=r.width,s=r.height;if(!n||!s)return;const o=self.getComputedStyle(this.element),a=parseFloat(o.width);isNaN(a)||(s=parseFloat(o.height)*n/Math.max(1,a));const l=this.micrio.hasAttribute("data-static")?1:Math.floor(n)/this.micrio.offsetWidth;n/=l,s/=l;const c=1!=l?1:this.getRatio(),u=this.viewport;u.width==n&&u.height==s&&u.ratio==c&&u.scale==l||(this.hasPerspective&&(this.micrio.style.perspective=s/2+"px"),u.width=n,u.height=s,u.ratio=c,u.scale=l,u.top=r.top,u.left=r.left,u.portrait=(null==(e=window.matchMedia("(orientation: portrait)"))?void 0:e.matches)??s>n,this.resizing=!0,this.element.width=n*c,this.element.height=s*c,this.micrio.webgl.gl.viewport(0,0,u.width*u.ratio,u.height*u.ratio),null==(i=this.micrio.webgl.postpocessor)||i.resize(),this.micrio.wasm.resize(u),this.resizing=!1,this.micrio.events.dispatch("resize",r),setTimeout((()=>this.isMobile.set(/mobile/i.test(navigator.userAgent))),10))}setMargins(t,e){this.micrio.wasm.e&&this.micrio.wasm.e.setArea(this.micrio.wasm.getPtr(),t,e)}}const dl=class t extends HTMLElement{constructor(){super(),this.printed=!1,this.canvases=[],this.current=Zi(),this.visible=Zi([]),this.canvas=new ul(this),this.events=new il(this),this.state=new ya.Main(this),this.analytics=new ol(this),this._router=new nl(this),this.barebone=Zi(!1),this.webgl=new Za(this),this.wasm=new Xa(this),this.defaultSettings=this.defaultSettings,this.loading=Zi(!0),this.switching=Zi(!1),this.isMuted=Zi("1"==localStorage.getItem(da)),this._lang=Zi(),this.keepRendering=!1,this.loadV5Album=(t,e)=>(t=>"MICRIO_ALBUM"in self?Promise.resolve(self.MICRIO_ALBUM):Tr(`https://i.micr.io/album/${t}.json`))(t).then((t=>{var i;if(!t)return;const r=t.id+"."+t.revision,n=e.path=(null==(i=t.organisation)?void 0:i.baseUrl)??la;return e.organisation=t.organisation,e.settings.album=t,e.settings.gallery={archive:r,sort:t.sort,type:t.type,startId:e.id,isSpreads:t.isSpreads,coverPages:t.coverPages,revisions:t.published},delete e.id,this.loadArchiveBin(n,r).then((()=>this.loadGallery(e,n,!0)))}),(t=>this.printError((null==t?void 0:t.message)||t))),this.getArchiveIndex=async(t,e=aa)=>Ta.get(`${e}${t}.json`).then((t=>(t.images.forEach((t=>yr.set(`${e}${t.id}/info.json`,t))),t))),this.current.subscribe((t=>this._current=t));let t=!1;br(this.loading,{targetValue:!1}).then((()=>{this.setAttribute("data-loaded",""),this.switching.subscribe((e=>{e?this.setAttribute("data-switching",""):(t||Xt().then((()=>this.events.dispatch("show",this))),t=!0,this.removeAttribute("data-switching"))}));const e=this.querySelector("img.preview");e&&setTimeout((()=>e.remove()),500)}))}static get observedAttributes(){return["id","muted","data-grid","data-limited","lang"]}get $current(){return this._current}get camera(){var t;return null==(t=this._current)?void 0:t.camera}attributeChangedCallback(t,e,i){var r,n,s,o;switch(t){case"id":if(!this.isConnected||!i)return;this.printed?this.open(i):this.print();break;case"muted":this.isMuted.set(null!==i);break;case"data-grid":this.printed?null==(n=null==(r=this.$current)?void 0:r.grid)||n.set(i):this.print();break;case"data-limited":(null==(s=this.wasm)?void 0:s._vertexBuffer)&&(null==(o=this.$current)?void 0:o.ptr)&&this.wasm.e._setLimited(this.$current.ptr,!!i);break;case"lang":{let t=Ki(this._lang);t!=i&&(this._lang.set(i),Xr.set(Wr[i]??Wr.en),i&&(qn.indexOf(i)>=0?this.setAttribute("dir","rtl"):this.removeAttribute("dir")),t&&this.events.dispatch("lang-switch",i));break}}}connectedCallback(){this.canvas.place(),(this.hasAttribute("data-router")||this.hasAttribute("data-space"))&&"false"!=this.getAttribute("data-router")&&this._router.hook(),!this.id&&!this.hasAttribute("data-gallery")||this.printed||this.print(),"muted"in this||(Object.defineProperty(this,"muted",{get(){return Ki(this.isMuted)},set(t){t?this.setAttribute("muted",""):this.removeAttribute("muted")}}),this.isMuted.subscribe((t=>{this.muted=t,t?(localStorage.setItem(da,"1"),this.events.dispatch("audio-mute")):(localStorage.removeItem(da),this.events.dispatch("audio-unmute"))})))}destroy(){this.current.set(void 0),this._router.unhook(),this.events.enabled.set(!1),this.canvas.unhook(),this.analytics.unhook(),this.wasm.unbind(),this._ui&&function(t,e){const i=ti.get(t);i?(ti.delete(t),i(e)):Promise.resolve()}(this._ui),delete this._ui,this.printed=!1}loadArchiveBin(t,e){return this.printUI(!0,!0),Ta.load(t,"g/"+e,(t=>{var e,i;return null==(i=null==(e=this._ui)?void 0:e.setProps)?void 0:i.call(e,{loadingProgress:t})}))}async print(){var t,e,i,r;if(this.printed)return;this.printed=!0,await Xt();const n=this.getOptions();if(n.settings||(n.settings={}),n.settings.noControls&&this.state.ui.controls.set(!1),null==(t=n.settings.gallery)?void 0:t.archive){const t=null==(e=n.settings.gallery)?void 0:e.archive,i=/\.\d+$/.test(t),r=n.path||(Pr(t.replace(/\.\d+$/,""))?la:aa);i&&await this.loadArchiveBin(r,t),n.settings.gallery.startId=n.id,n.grid?await this.setGrid(n,r):await this.loadGallery(n,r,i),i||delete n.settings.gallery.archive,n.path||(n.path=r),delete n.id}else(null==(i=n.id)?void 0:i.startsWith("album/"))?await this.loadV5Album(n.id.replace("album/",""),n):n.id&&Pr(n.id)&&!this.hasAttribute("width")&&!this.hasAttribute("height")&&await xr(n.id,n.forceInfoPath?n.path:void 0,null==(r=n.settings)?void 0:r.forceDataRefresh).then((t=>(null==t?void 0:t.albumId)?this.loadV5Album(t.albumId,n):void 0));this.keepRendering=!!n.settings.keepRendering;const s=n.id||n.gallery||n.grid;if(this.events.dispatch("print",n),void 0!==n.settings.lazyload&&"IntersectionObserver"in window){const t=new IntersectionObserver((e=>{e[0]&&e[0].isIntersecting&&(t.unobserve(this),s&&this.open(n))}),{rootMargin:100*n.settings.lazyload+"% 0px"});t.observe(this)}else s&&requestAnimationFrame((()=>this.open(n)))}printUI(e,i){var r,n;this._ui?null==(n=(r=this._ui).setProps)||n.call(r,{noHTML:e,noLogo:i}):this._ui=Je(t.Svelte,{target:this,props:{micrio:this,noHTML:e,noLogo:i}})}printError(t){var e,i;null==(i=null==(e=this._ui)?void 0:e.setProps)||i.call(e,{error:t??"An unknown error has occurred"})}open(t,e={}){var i,r,n,s;this.printed||this.print();const o="string"==typeof t,a=this.getOptions();let l=o?{...a,id:t}:t;if(l.settings||(l.settings={}),(null==(r=null==(i=a.settings)?void 0:i.gallery)?void 0:r.archive)&&(/\.\d+$/.test(a.settings.gallery.archive)||delete a.settings.gallery.archive),o||vr(a.settings,l.settings),this.defaultSettings&&vr(this.defaultSettings,l.settings),this.$current&&l.id==(null==(n=this.$current)?void 0:n.id))return this.$current;e.splitScreen||e.gridView||!this.$current||this.switching.set(!0),l.settings.noGTag||this.analytics.hook(),this.printed=!0,this.printUI(!!l.settings.noUI,!!l.settings.noLogo);let c=this.canvases.find((t=>l.id&&t.id==l.id)),u=!1;const d=null==(s=this.canvases[0])?void 0:s.grid;if(!c&&d){const t=l.id?d.images.find((t=>t.id==l.id)):void 0;u=!!t,c=l.id?t:this.canvases[0],u&&!d.insideGrid()&&this.current.set(this.canvases[0])}if(!c){if(this.canvases.length){const t=this.canvases[0];l.path=t.dataPath,l.lang=this.lang}this.canvases.push(c=new xa(this.wasm,l,e.splitScreen?{secondaryTo:e.splitTo??this._current,isPassive:e.isPassive}:void 0));const t=this.state.value&&this.state.value.c.find((t=>t[0]==l.id));t&&c.state.set(t)}e.startView&&(c.state.view.set(l.settings.view=e.startView),c.ptr&&c.camera.e&&c.camera.setView(l.settings.view,{noRender:!0})),this.lang||(this.lang="en");const h=()=>{var t,i,r,n;c&&(br(c.info).then((t=>{var i;if(t&&c){if(!this.webgl.gl)switch(this.webgl.init(),this.canvas.hook(),null==(i=t.settings)?void 0:i.theme){case"light":this.setAttribute("data-light-mode","");break;case"os":this.setAttribute("data-auto-scheme","")}t.grid&&!c.grid&&(c.grid=new cl(this,c)),Xt().then((()=>this.dispatchEvent(new CustomEvent("load",{detail:c})))),e.splitScreen&&Xt().then((()=>{c&&((null==d?void 0:d.image.camera.aniDoneAdd)&&d.image.camera.aniDoneAdd.length>0?d.image.camera.aniDoneAdd.push((()=>null==c?void 0:c.splitStart())):c.splitStart())}))}})),this.wasm.e.set360Orientation(this.wasm.getPtr(),(null==(t=e.vector)?void 0:t.direction)??0,(null==(i=e.vector)?void 0:i.distanceX)??0,(null==(r=e.vector)?void 0:r.distanceY)??0),this.wasm.preventDirectionSet=!e.vector,!u||e.gridView&&(null==d?void 0:d.current.find((t=>t.id==l.id)))?e.splitScreen?this.wasm.setCanvas(c):this.current.set(c):null==d||d.focus(c,{view:null==(n=l.settings)?void 0:n.view}).then((()=>this.current.set(c))))};return this.wasm.ready?h():this.wasm.load().then(h),c.noImage&&this.loading.set(!1),c}close(t){t.opts.secondaryTo?t.splitEnd():this.wasm.removeCanvas(t)}getOptions(){const t={gallery:{}},e={settings:t,id:this.id},i=(t,e,i)=>{const r=e.split(".");for(let n=0;n<r.length-1;n++)t=t[r[n]];t[r[r.length-1]]=i};for(const r in ma.STRINGS){const n=ma.STRINGS[r],s=this.getAttribute(r),o=n.f||r.replace("data-","");s&&i(n.r?e:t,o,s)}for(const r in ma.BOOLEANS){const n=ma.BOOLEANS[r],s=this.getAttribute(r),o=n.f||r.replace("data-",""),a=null!=s&&""==s||"true"==s;(a||"false"==s)&&i(n.r?e:t,o,n.n?!a:!!a)}for(const r in ma.NUMBERS){const n=ma.NUMBERS[r],s=n.f||r.replace("data-","");let o=this.getAttribute(r);void 0!==n.dN&&null==o&&(o=n.dN),null==o||isNaN(Number(o))||i(n.r?e:t,s,Number(o))}for(const r in ma.ARRAYS){const n=ma.ARRAYS[r],s=this.getAttribute(r),o=n.f||r.replace("data-","");null!=s&&i(n.r?e:t,o,s.split(",").map((t=>Number(t))))}return t.static&&(t.noUI=t.skipMeta=!0,t.hookEvents=!1),e.settings&&e.grid&&e.grid.indexOf(".")>0&&(e.settings.gallery.archive=e.grid),e}async loadGallery(t,e,i){var r;let n=null==(r=t.settings)?void 0:r.gallery,s=null==n?void 0:n.archive;if(!n||!s)return;const o=t.settings;if(i){const t=await this.getArchiveIndex(s.split(".")[0],e);n.archiveLayerOffset=t.delta,s=t.images.sort("name"==n.sort?(t,e)=>t.title&&e.title?t.title<e.title?-1:t.title>e.title?1:0:0:"-name"==n.sort?(t,e)=>t.title&&e.title?t.title<e.title?1:t.title>e.title?-1:0:0:"-created"==n.sort?(t,e)=>t.created&&e.created?t.created<e.created?1:t.created>e.created?-1:0:0:(t,e)=>t.created&&e.created?t.created<e.created?-1:t.created>e.created?1:0:0).map((t=>`${t.id},${t.width},${t.height},${t.isDeepZoom?"d":""},${t.isPng?"p":t.isWebP?"w":""},${t.tileSize||""}`.replace(/\,+$/,""))).join(";")}const a=s.split(";").map((t=>t.trim()));if(!i){const t=a.filter((t=>t.startsWith("http"))).map((t=>Tr(t)));t.length&&await Promise.all(t).then((t=>t.forEach(((t,e)=>{t&&(a[e]=`${t["@id"]},${t.width},${t.height}`)}))))}const l=a.map((t=>t.split(",").map((t=>isNaN(t)?t:Number(t)))));l.forEach(((t,e)=>{e>0&&!t[2]&&t.push(...l[e-1].slice(1))}));const c=t.height=Math.max(...l.map((t=>t[2])));n.type||(n.type="swipe");const u="switch"==n.type||"swipe-full"==n.type||"omni"==n.type,d=n.isSpreads,h=d&&!u?Math.round(l[0][1]/20):0,m=d?n.coverPages??0:0,v=t.width=u?Math.max(...l.map((t=>t[1]*(d?2:1)))):l.reduce(((t,e)=>t+e[1]+h),0);let p=0;t.gallery=l.map(((t,i)=>{var r;return new xa(this.wasm,{id:t[0],path:e,width:t[1],height:t[2],isDeepZoom:"d"==t[3],isPng:"p"==t[4],isWebP:"w"==t[4],tileSize:t[5]||1024,revision:null==(r=null==n?void 0:n.revisions)?void 0:r[t[0]],settings:{skipMeta:!0,gallery:n}},{isEmbed:u,useParentCamera:u,area:u?d?i-m<0||i==l.length-1&&(i-m)%2==0?[.25,0,.75,1]:(i-m)%2==0?[0,0,.5,1]:[.5,0,1,1]:[0,0,1,1]:[(p+=i>0&&(i<m||(i-m)%2==0)?h:0)/v,(c-t[2])/2/c,(p+=t[1])/v,((c-t[2])/2+t[2])/c]})})),o.pinchZoomOutLimit=!0,t.gallery.length&&(o.view=t.gallery[Math.max(0,t.gallery.findIndex((t=>t.id==n.startId)))].opts.area)}async setGrid(t,e){var i;t.settings&&t.grid&&((null==(i=t.settings.gallery)?void 0:i.archive)==t.grid&&(this.gridInfoData=await this.getArchiveIndex(t.grid.split(".")[0],e),t.grid=this.gridInfoData.images.map((t=>cl.getString(t,{cultures:"cultures"in t?t.cultures.join("-"):void 0}))).join(";")),t.width=this.offsetWidth*this.canvas.getRatio(),t.height=this.offsetHeight*this.canvas.getRatio(),t.settings.zoomLimit=15,t.settings.minimap=!1,t.settings.initType="cover",this.removeAttribute("data-grid"))}get lang(){return Ki(this._lang)}set lang(t){this.setAttribute("lang",t)}};dl.jsonCache=yr;let hl=dl;hl.Svelte=function(t,e){Te(e,!0);const[i,r]=ir(),n=()=>tr(jt(A),"$settings",i),s=()=>tr(jt(E),"$info",i),o=()=>tr(jt($),"$data",i),a=()=>tr(k,"$tour",i),l=()=>tr(P,"$volume",i),c=()=>tr(w,"$visible",i),u=()=>tr(_,"$markerPopup",i),d=()=>tr(x,"$popover",i);let h=or(e,"noHTML",15),m=or(e,"noLogo",23,h),v=or(e,"loadingProgress",7,1),p=or(e,"error",7,void 0);ke("micrio",e.micrio),ke("markerImages",new Map);const f="markers"==e.micrio.getAttribute("data-ui");f&&h(!0);const g="false"!=e.micrio.getAttribute("data-embeds"),{visible:w,state:b,isMuted:y}=e.micrio,{tour:k,marker:T,popup:_,popover:x}=b;let E=j(void 0),$=j(void 0),A=j(void 0);function S(t,e){if(e)for(let i,r=0;r<e.length;r++)if(e[r].id==t||(i=S(t,e[r].children)))return i??e[r]}let I=j(!1),M=j(void 0);const L=[];e.micrio.current.subscribe((t=>{t&&(er(Y(E,t.info,!0),"$info",i),er(Y(A,void 0),"$settings",i),jt(E)&&br(jt(E)).then((e=>{var r;e&&(Y(I,!0),er(Y(A,t.settings,!0),"$settings",i),!jt(M)&&(null==(r=e.organisation)?void 0:r.logo)&&Y(M,e.organisation,!0))})),er(Y($,t.data,!0),"$data",i)&&L.indexOf(t.id)<0&&br(jt($)).then((async i=>{var r,n;if(!i)return;if(L.push(t.id),await Xt().then(Xt),Ki(e.micrio.state.popover)||Ki(e.micrio.state.marker)||Ki(e.micrio.state.tour))return;const s=t.$settings.start;if(s)switch(s.type){case"marker":t.state.marker.set(s.id);break;case"markerTour":const o=null==(r=i.markerTours)?void 0:r.find((t=>t.id==s.id));o&&e.micrio.state.tour.set(o);break;case"tour":const a=null==(n=i.tours)?void 0:n.find((t=>t.id==s.id));a&&e.micrio.state.tour.set(a);break;case"page":const l=S(s.id,i.pages);l&&e.micrio.state.popover.set({contentPage:l,showLangSelect:!0})}})))}));const P=Zi(tr(y,"$isMuted",i)?0:1);ke("volume",P),y.subscribe((t=>P.set(t?0:1))),ke("mediaPaused",Zi(!1));let C=j(!1),D=j(B([]));ke("srt",Zi()).subscribe((t=>setTimeout((()=>{Y(D,t?[t]:[],!0)}),20)));let R=J((()=>{var t,e;return null==(e=null==(t=n())?void 0:t._360)?void 0:e.video})),z=J((()=>{var t;return null==(t=jt(R))?void 0:t.src})),O=J((()=>{var t;return null==(t=n())?void 0:t.omni})),N=J((()=>{var t;return null==(t=s())?void 0:t.gallery})),F=J((()=>{var t,e;return null==(e=null==(t=o())?void 0:t.markers)?void 0:e.filter((t=>!!t.positionalAudio))})),V=J((()=>{var t,e,i;return!!(null==(e=null==(t=o())?void 0:t.music)?void 0:e.items.length)||!!(null==(i=jt(F))?void 0:i.length)})),U=J((()=>a()||tr(T,"$marker",i))),q=J((()=>!h()||f)),W=J((()=>{var t;return!(m()||s()&&h()||(null==(t=n())?void 0:t.noLogo))})),X=J((()=>{var t;return h()||!jt(W)||(null==(t=n())?void 0:t.noOrgLogo)?void 0:jt(M)})),G=J((()=>{var t;return!(h()||jt(O)||e.micrio.spaceData||a()||(null==(t=s())?void 0:t.gallery))})),H=J((()=>!!jt(N)||!!jt(O))),Z=J((()=>!h()&&!!s())),K=J((()=>{var t;return!h()&&!jt(U)&&(null==(t=n())?void 0:t.showInfo)})),Q=J((()=>{var t;return!h()&&jt(I)&&!(null==(t=n())?void 0:t.noToolbar)}));var tt=Ma(),et=ut(tt),it=t=>{const e=J((()=>!!s().is360));bo(t,{get volume(){return l()},get data(){return o()},get is360(){return jt(e)}})};ei(et,(t=>{jt(V)&&o()&&s()&&t(it)}));var rt=dt(et,2),nt=t=>{Ms(t,nr({get src(){return jt(z)},get volume(){return l()},is360:!0,get width(){return s().width},get height(){return s().height}},(()=>jt(R))))};ei(rt,(t=>{jt(z)&&s()&&t(nt)}));var st=dt(rt,2),ot=t=>{var e=Ge();ri(ut(e),1,(()=>o().embeds),(t=>t.uuid),((t,e)=>{Sa(t,{get embed(){return jt(e)}})})),Ye(t,e)};ei(st,(t=>{g&&o()&&o().embeds&&t(ot)}));var at=dt(st,2),lt=t=>{Ur(t,{})};ei(at,(t=>{jt(W)&&t(lt)}));var ht=dt(at,2),mt=t=>{Nn(t,{})};ei(ht,(t=>{jt(Q)&&t(mt)}));var vt=dt(ht,2),pt=t=>{var e=Ge();ri(ut(e),1,c,(t=>t.uuid),((t,e)=>{sa(t,{get image(){return jt(e)}})})),Ye(t,e)};ei(vt,(t=>{jt(q)&&t(pt)}));var ft=dt(vt,2),gt=t=>{var e=Ge();ri(ut(e),1,(()=>c().filter((t=>t.$settings.minimap))),(t=>t.uuid),((t,e)=>{Vn(t,{get image(){return jt(e)}})})),Ye(t,e)};ei(ft,(t=>{jt(G)&&t(gt)}));var wt=dt(ft,2),bt=t=>{const e=J((()=>jt(V)||!(!jt(z)||!jt(R)||jt(R).muted)));Qn(t,{get hasAudio(){return jt(e)}})};ei(wt,(t=>{jt(Z)&&t(bt)}));var yt=dt(wt,2),kt=t=>{co(t,{get images(){return jt(N)},get omni(){return jt(O)}})};ei(yt,(t=>{jt(H)&&t(kt)}));var Tt=dt(yt,2),_t=t=>{qr(t,{get organisation(){return jt(X)}})};ei(Tt,(t=>{jt(X)&&t(_t)}));var xt=dt(Tt,2),Et=t=>{Eo(t,{get info(){return jt(E)},get data(){return jt($)}})};ei(xt,(t=>{jt(K)&&jt(E)&&jt($)&&t(Et)}));var $t=dt(xt,2),At=t=>{Xs(t,{get marker(){return u()}})};ei($t,(t=>{u()&&t(At)}));var St=dt($t,2),It=t=>{eo(t,{get tour(){return a()},get noHTML(){return h()},onminimize:t=>Y(C,!t)})};ei(St,(t=>{a()&&t(It)}));var Mt=dt(St,2),Lt=t=>{Vo(t,{get popover(){return d()}})};ei(Mt,(t=>{d()&&t(Lt)}));var Pt=dt(Mt,2);ri(Pt,16,(()=>jt(D)),(t=>t),((t,e)=>{os(t,{get src(){return e},get raised(){return jt(C)}})}));var Ct=dt(Pt,2),Dt=t=>{!function(t,e){var i=$o(),r=ct(i);En(r,{name:"error"});var n=dt(r);se((()=>Ke(n,` ${e.message??""}`))),Ye(t,i)}(t,{get message(){return p()}})};ei(Ct,(t=>{p()&&t(Dt)}));var Rt=dt(Ct,2),zt=t=>{!function(t,e){const i=2*Math.PI*40;let r=J((()=>i*(1-e.progress)));var n=Ia();xi(n,"viewBox","0 0 100 100");var s=ct(n);xi(s,"r",40),xi(s,"cx",50),xi(s,"cy",50);var o=dt(s);xi(o,"r",40),xi(o,"cx",50),xi(o,"cy",50),xi(o,"stroke-dasharray",`${i??""}px`),se((()=>xi(o,"stroke-dashoffset",`${jt(r)??""}px`))),zi(1,n,(()=>Nr),(()=>({delay:500}))),zi(2,n,(()=>Nr)),Ye(t,n)}(t,{get progress(){return v()}})};ei(Rt,(t=>{v()<1&&t(zt)})),Ye(t,tt);var Ot=_e({setProps:function(t){"error"in t&&p(t.error),void 0!==t.noHTML&&h(t.noHTML),void 0!==t.noLogo&&m(t.noLogo),void 0!==t.loadingProgress&&v(t.loadingProgress)}});return r(),Ot},hl.VERSION=oa,customElements.define("micr-io",hl),console.log("%c◈%c Micrio %cv5.3.1 - https://micr.io/","color: #00d4ee","color: #c5ff5b","color: inherit")}();
24
+ !function(){"use strict";var t;"undefined"!=typeof window&&((t=window.__svelte??(window.__svelte={})).v??(t.v=new Set)).add("5");const e=Symbol(),i=!1,r=32,n=64,s=128,o=256,a=512,l=1024,c=2048,u=4096,d=8192,h=16384,m=65536,v=1<<20,p=1<<21,f=Symbol("$state"),g=Symbol("legacy props"),w=Symbol("");var b=Array.isArray,y=Array.prototype.indexOf,k=Array.from,T=Object.defineProperty,_=Object.getOwnPropertyDescriptor,x=Object.getOwnPropertyDescriptors,E=Object.prototype,$=Array.prototype,A=Object.getPrototypeOf,S=Object.isExtensible;function I(t){return"function"==typeof t}const M=()=>{};function L(t){return t()}function P(t){for(var e=0;e<t.length;e++)t[e]()}let C=[],D=[];function R(){var t=C;C=[],P(t)}function z(t){0===C.length&&queueMicrotask(R),C.push(t)}function O(){var t;C.length>0&&R(),D.length>0&&(t=D,D=[],P(t))}function N(t){return t===this.v}function F(t,e){return t!=t?e==e:t!==e||null!==t&&"object"==typeof t||"function"==typeof t}function V(t){return!F(t,this.v)}let U=!1;function B(t,i){if("object"!=typeof t||null===t||f in t)return t;const r=A(t);if(r!==E&&r!==$)return t;var n=new Map,s=b(t),o=j(0),a=bt,l=t=>{var e,i=bt;return kt(a),e=t(),kt(i),e};return s&&n.set("length",j(t.length)),new Proxy(t,{defineProperty(t,e,i){"value"in i&&!1!==i.configurable&&!1!==i.enumerable&&!1!==i.writable||function(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}();var r=n.get(e);return void 0===r?(r=l((()=>j(i.value))),n.set(e,r)):Y(r,l((()=>B(i.value)))),!0},deleteProperty(t,i){var r=n.get(i);if(void 0===r)i in t&&n.set(i,l((()=>j(e))));else{if(s&&"string"==typeof i){var a=n.get("length"),c=Number(i);Number.isInteger(c)&&c<a.v&&Y(a,c)}Y(r,e),q(o)}return!0},get(i,r,s){var o;if(r===f)return t;var a=n.get(r),c=r in i;if(void 0!==a||c&&!(null==(o=_(i,r))?void 0:o.writable)||(a=l((()=>j(B(c?i[r]:e)))),n.set(r,a)),void 0!==a){var u=jt(a);return u===e?void 0:u}return Reflect.get(i,r,s)},getOwnPropertyDescriptor(t,i){var r=Reflect.getOwnPropertyDescriptor(t,i);if(r&&"value"in r){var s=n.get(i);s&&(r.value=jt(s))}else if(void 0===r){var o=n.get(i),a=null==o?void 0:o.v;if(void 0!==o&&a!==e)return{enumerable:!0,configurable:!0,value:a,writable:!0}}return r},has(t,i){var r;if(i===f)return!0;var s=n.get(i),o=void 0!==s&&s.v!==e||Reflect.has(t,i);if((void 0!==s||null!==Tt&&(!o||(null==(r=_(t,i))?void 0:r.writable)))&&(void 0===s&&(s=l((()=>j(o?B(t[i]):e))),n.set(i,s)),jt(s)===e))return!1;return o},set(t,i,r,a){var c,u=n.get(i),d=i in t;if(s&&"length"===i)for(var h=r;h<u.v;h+=1){var m=n.get(h+"");void 0!==m?Y(m,e):h in t&&(m=l((()=>j(e))),n.set(h+"",m))}void 0===u?d&&!(null==(c=_(t,i))?void 0:c.writable)||(Y(u=l((()=>j(void 0))),l((()=>B(r)))),n.set(i,u)):(d=u.v!==e,Y(u,l((()=>B(r)))));var v=Reflect.getOwnPropertyDescriptor(t,i);if((null==v?void 0:v.set)&&v.set.call(a,r),!d){if(s&&"string"==typeof i){var p=n.get("length"),f=Number(i);Number.isInteger(f)&&f>=p.v&&Y(p,f+1)}q(o)}return!0},ownKeys(t){jt(o);var i=Reflect.ownKeys(t).filter((t=>{var i=n.get(t);return void 0===i||i.v!==e}));for(var[r,s]of n)s.v===e||r in t||i.push(r);return i},setPrototypeOf(){!function(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}()}})}function q(t,e=1){Y(t,t.v+e)}const W=new Map;function X(t,e){return{f:0,v:t,reactions:null,equals:N,rv:0,wv:0}}function j(t,e){const i=X(t);return Et(i),i}function G(t,e=!1){var i;const r=X(t);return e||(r.equals=V),U&&null!==we&&null!==we.l&&((i=we.l).s??(i.s=[])).push(r),r}function Y(t,e,i=!1){return null!==bt&&!yt&&xe()&&18&bt.f&&!(null==xt?void 0:xt.includes(t))&&function(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}(),H(t,i?B(e):e)}function H(t,e){if(!t.equals(e)){var i=t.v;ft?W.set(t,e):W.set(t,i),t.v=e,t.wv=Pt(),Z(t,c),xe()&&null!==Tt&&Tt.f&l&&!(96&Tt.f)&&(null===St?function(t){St=t}([t]):St.push(t))}return e}function Z(t,e){var i=t.reactions;if(null!==i)for(var r=xe(),n=i.length,s=0;s<n;s++){var o=i[s],a=o.f;a&c||(r||o!==Tt)&&(Ht(o,e),1280&a&&(2&a?Z(o,u):qt(o)))}}function K(t){var e=2050,i=null!==bt&&2&bt.f?bt:null;null===Tt||null!==i&&i.f&o?e|=o:Tt.f|=v;return{ctx:we,deps:null,effects:null,equals:N,f:e,fn:t,reactions:null,rv:0,v:null,wv:0,parent:i??Tt}}function J(t){const e=K(t);return Et(e),e}function Q(t){const e=K(t);return e.equals=V,e}function tt(t){var e=t.effects;if(null!==e){t.effects=null;for(var i=0;i<e.length;i+=1)ue(e[i])}}function et(t){var e=function(t){var e,i=Tt;_t(function(t){for(var e=t.parent;null!==e;){if(!(2&e.f))return e;e=e.parent}return null}(t));try{tt(t),e=zt(t)}finally{_t(i)}return e}(t);Ht(t,(Lt||t.f&o)&&null!==t.deps?u:l),t.equals(e)||(t.v=e,t.wv=Pt())}var it,rt,nt,st;function ot(t=""){return document.createTextNode(t)}function at(t){return nt.call(t)}function lt(t){return st.call(t)}function ct(t,e){return at(t)}function ut(t,e){var i=at(t);return i instanceof Comment&&""===i.data?lt(i):i}function dt(t,e=1,i=!1){let r=t;for(;e--;)r=lt(r);return r}let ht=!1,mt=!1,vt=null,pt=!1,ft=!1;function gt(t){ft=t}let wt=[],bt=null,yt=!1;function kt(t){bt=t}let Tt=null;function _t(t){Tt=t}let xt=null;function Et(t){null!==bt&&bt.f&p&&(null===xt?xt=[t]:xt.push(t))}let $t=null,At=0,St=null;let It=1,Mt=0,Lt=!1;function Pt(){return++It}function Ct(t){var e,i=t.f;if(i&c)return!0;if(i&u){var r=t.deps,n=!!(i&o);if(null!==r){var s,d,h=!!(i&a),m=n&&null!==Tt&&!Lt,v=r.length;if(h||m){var p=t,f=p.parent;for(s=0;s<v;s++)d=r[s],!h&&(null==(e=null==d?void 0:d.reactions)?void 0:e.includes(p))||(d.reactions??(d.reactions=[])).push(p);h&&(p.f^=a),!m||null===f||f.f&o||(p.f^=o)}for(s=0;s<v;s++)if(Ct(d=r[s])&&et(d),d.wv>t.wv)return!0}n&&(null===Tt||Lt)||Ht(t,l)}return!1}function Dt(t,e,i,r){if(ht){if(null===i&&(ht=!1),function(t){return!(t.f&h||null!==t.parent&&t.parent.f&s)}(e))throw t}else null!==i&&(ht=!0),function(t,e){for(var i=e;null!==i;){if(i.f&s)try{return void i.fn(t)}catch{i.f^=s}i=i.parent}throw ht=!1,t}(t,e)}function Rt(t,e,i=!0){var r=t.reactions;if(null!==r)for(var n=0;n<r.length;n++){var s=r[n];(null==xt?void 0:xt.includes(t))||(2&s.f?Rt(s,e,!1):e===s&&(i?Ht(s,c):s.f&l&&Ht(s,u),qt(s)))}}function zt(t){var e,i=$t,r=At,n=St,s=bt,a=Lt,l=xt,c=we,u=yt,d=t.f;$t=null,At=0,St=null,Lt=!!(d&o)&&(yt||!pt||null===bt),bt=96&d?null:t,xt=null,be(t.ctx),yt=!1,Mt++,t.f|=p;try{var h=(0,t.fn)(),m=t.deps;if(null!==$t){var v;if(Nt(t,At),null!==m&&At>0)for(m.length=At+$t.length,v=0;v<$t.length;v++)m[At+v]=$t[v];else t.deps=m=$t;if(!Lt)for(v=At;v<m.length;v++)((e=m[v]).reactions??(e.reactions=[])).push(t)}else null!==m&&At<m.length&&(Nt(t,At),m.length=At);if(xe()&&null!==St&&!yt&&null!==m&&!(6146&t.f))for(v=0;v<St.length;v++)Rt(St[v],t);return null!==s&&(Mt++,null!==St&&(null===n?n=St:n.push(...St))),h}finally{$t=i,At=r,St=n,bt=s,Lt=a,xt=l,be(c),yt=u,t.f^=p}}function Ot(t,e){let i=e.reactions;if(null!==i){var r=y.call(i,t);if(-1!==r){var n=i.length-1;0===n?i=e.reactions=null:(i[r]=i[n],i.pop())}}null===i&&2&e.f&&(null===$t||!$t.includes(e))&&(Ht(e,u),768&e.f||(e.f^=a),tt(e),Nt(e,0))}function Nt(t,e){var i=t.deps;if(null!==i)for(var r=e;r<i.length;r++)Ot(t,i[r])}function Ft(t){var e=t.f;if(!(e&h)){Ht(t,l);var n=Tt,s=we,o=pt;Tt=t,pt=!0;try{16&e?function(t){var e=t.first;for(;null!==e;){var i=e.next;e.f&r||ue(e),e=i}}(t):ce(t),le(t);var a=zt(t);t.teardown="function"==typeof a?a:null,t.wv=It;t.deps;i}catch(c){Dt(c,t,n,s||t.ctx)}finally{pt=o,Tt=n}}}function Vt(){try{!function(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}()}catch(t){if(null===vt)throw t;Dt(t,vt,null)}}function Ut(){var t=pt;try{var e=0;for(pt=!0;wt.length>0;){e++>1e3&&Vt();var i=wt,r=i.length;wt=[];for(var n=0;n<r;n++){Bt(Wt(i[n]))}}}finally{mt=!1,pt=t,vt=null,W.clear()}}function Bt(t){var e=t.length;if(0!==e)for(var i=0;i<e;i++){var r=t[i];if(!(24576&r.f))try{Ct(r)&&(Ft(r),null===r.deps&&null===r.first&&null===r.nodes_start&&(null===r.teardown?de(r):r.fn=null))}catch(n){Dt(n,r,null,r.ctx)}}}function qt(t){mt||(mt=!0,queueMicrotask(Ut));for(var e=vt=t;null!==e.parent;){var i=(e=e.parent).f;if(96&i){if(!(i&l))return;e.f^=l}}wt.push(e)}function Wt(t){for(var e=[],i=t;null!==i;){var r=i.f,n=!!(96&r);if(!(n&&!!(r&l)||r&d)){if(4&r)e.push(i);else if(n)i.f^=l;else{var s=bt;try{bt=i,Ct(i)&&Ft(i)}catch(c){Dt(c,i,null,i.ctx)}finally{bt=s}}var o=i.first;if(null!==o){i=o;continue}}var a=i.parent;for(i=i.next;null===i&&null!==a;)i=a.next,a=a.parent}return e}async function Xt(){await Promise.resolve(),function(){for(O();wt.length>0;)mt=!0,Ut(),O()}()}function jt(t){var e=!!(2&t.f);if(null===bt||yt){if(e&&null===t.deps&&null===t.effects){var i=t,r=i.parent;null===r||r.f&o||(i.f^=o)}}else if(!(null==xt?void 0:xt.includes(t))){var n=bt.deps;t.rv<Mt&&(t.rv=Mt,null===$t&&null!==n&&n[At]===t?At++:null===$t?$t=[t]:Lt&&$t.includes(t)||$t.push(t))}return e&&Ct(i=t)&&et(i),ft&&W.has(t)?W.get(t):t.v}function Gt(t){var e=yt;try{return yt=!0,t()}finally{yt=e}}const Yt=-7169;function Ht(t,e){t.f=t.f&Yt|e}function Zt(t){if("object"==typeof t&&t&&!(t instanceof EventTarget))if(f in t)Kt(t);else if(!Array.isArray(t))for(let e in t){const i=t[e];"object"==typeof i&&i&&f in i&&Kt(i)}}function Kt(t,e=new Set){if(!("object"!=typeof t||null===t||t instanceof EventTarget||e.has(t))){e.add(t),t instanceof Date&&t.getTime();for(let n in t)try{Kt(t[n],e)}catch(i){}const r=A(t);if(r!==Object.prototype&&r!==Array.prototype&&r!==Map.prototype&&r!==Set.prototype&&r!==Date.prototype){const e=x(r);for(let r in e){const n=e[r].get;if(n)try{n.call(t)}catch(i){}}}}}function Jt(t){null===Tt&&null===bt&&function(){throw new Error("https://svelte.dev/e/effect_orphan")}(),null!==bt&&bt.f&o&&null===Tt&&function(){throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}(),ft&&function(){throw new Error("https://svelte.dev/e/effect_in_teardown")}()}function Qt(t,e,i,r=!0){var n=Tt,s={ctx:we,deps:null,nodes_start:null,nodes_end:null,f:t|c,first:null,fn:e,last:null,next:null,parent:n,prev:null,teardown:null,transitions:null,wv:0};if(i)try{Ft(s),s.f|=32768}catch(a){throw ue(s),a}else null!==e&&qt(s);if(!(i&&null===s.deps&&null===s.first&&null===s.nodes_start&&null===s.teardown&&!(1048704&s.f))&&r&&(null!==n&&function(t,e){var i=e.last;null===i?e.last=e.first=t:(i.next=t,t.prev=i,e.last=t)}(s,n),null!==bt&&2&bt.f)){var o=bt;(o.effects??(o.effects=[])).push(s)}return s}function te(t){const e=Qt(8,null,!1);return Ht(e,l),e.teardown=t,e}function ee(t){if(Jt(),!(null!==Tt&&!!(Tt.f&r)&&null!==we&&!we.m))return ie(t);var e=we;(e.e??(e.e=[])).push({fn:t,effect:Tt,reaction:bt})}function ie(t){return Qt(4,t,!1)}function re(t,e){var i=we,r={effect:null,ran:!1};i.l.r1.push(r),r.effect=ne((()=>{t(),r.ran||(r.ran=!0,Y(i.l.r2,!0),Gt(e))}))}function ne(t){return Qt(8,t,!0)}function se(t,e=[],i=K){const r=e.map(i);return oe((()=>t(...r.map(jt))))}function oe(t,e=0){return Qt(24|e,t,!0)}function ae(t,e=!0){return Qt(40,t,!0,e)}function le(t){var e=t.teardown;if(null!==e){const t=ft,i=bt;gt(!0),kt(null);try{e.call(null)}finally{gt(t),kt(i)}}}function ce(t,e=!1){var i=t.first;for(t.first=t.last=null;null!==i;){var r=i.next;i.f&n?i.parent=null:ue(i,e),i=r}}function ue(t,e=!0){var i=!1;if((e||524288&t.f)&&null!==t.nodes_start){for(var r=t.nodes_start,n=t.nodes_end;null!==r;){var s=r===n?null:lt(r);r.remove(),r=s}i=!0}ce(t,e&&!i),Nt(t,0),Ht(t,h);var o=t.transitions;if(null!==o)for(const l of o)l.stop();le(t);var a=t.parent;null!==a&&null!==a.first&&de(t),t.next=t.prev=t.teardown=t.ctx=t.deps=t.fn=t.nodes_start=t.nodes_end=null}function de(t){var e=t.parent,i=t.prev,r=t.next;null!==i&&(i.next=r),null!==r&&(r.prev=i),null!==e&&(e.first===t&&(e.first=r),e.last===t&&(e.last=i))}function he(t,e){var i=[];ve(t,i,!0),me(i,(()=>{ue(t),e&&e()}))}function me(t,e){var i=t.length;if(i>0){var r=()=>--i||e();for(var n of t)n.out(r)}else e()}function ve(t,e,i){if(!(t.f&d)){if(t.f^=d,null!==t.transitions)for(const r of t.transitions)(r.is_global||i)&&e.push(r);for(var n=t.first;null!==n;){var s=n.next;ve(n,e,!!(!!(n.f&m)||!!(n.f&r))&&i),n=s}}}function pe(t){fe(t,!0)}function fe(t,e){if(t.f&d){t.f^=d,t.f&l||(t.f^=l),Ct(t)&&(Ht(t,c),qt(t));for(var i=t.first;null!==i;){var n=i.next;fe(i,!!(!!(i.f&m)||!!(i.f&r))&&e),i=n}if(null!==t.transitions)for(const i of t.transitions)(i.is_global||e)&&i.in()}}function ge(t){throw new Error("https://svelte.dev/e/lifecycle_outside_component")}let we=null;function be(t){we=t}function ye(t){return Ee().get(t)}function ke(t,e){return Ee().set(t,e),e}function Te(t,e=!1,i){var r=we={p:we,c:null,d:!1,e:null,m:!1,s:t,x:null,l:null};U&&!e&&(we.l={s:null,u:null,r1:[],r2:X(!1)}),te((()=>{r.d=!0}))}function _e(t){const e=we;if(null!==e){void 0!==t&&(e.x=t);const o=e.e;if(null!==o){var i=Tt,r=bt;e.e=null;try{for(var n=0;n<o.length;n++){var s=o[n];_t(s.effect),kt(s.reaction),ie(s.fn)}}finally{_t(i),kt(r)}}we=e.p,e.m=!0}return t||{}}function xe(){return!U||null!==we&&null===we.l}function Ee(t){return null===we&&ge(),we.c??(we.c=new Map(function(t){let e=t.p;for(;null!==e;){const t=e.c;if(null!==t)return t;e=e.p}return null}(we)||void 0))}function $e(t){return t.endsWith("capture")&&"gotpointercapture"!==t&&"lostpointercapture"!==t}const Ae=["beforeinput","click","change","dblclick","contextmenu","focusin","focusout","input","keydown","keyup","mousedown","mousemove","mouseout","mouseover","mouseup","pointerdown","pointermove","pointerout","pointerover","pointerup","touchend","touchmove","touchstart"];function Se(t){return Ae.includes(t)}const Ie={formnovalidate:"formNoValidate",ismap:"isMap",nomodule:"noModule",playsinline:"playsInline",readonly:"readOnly",defaultvalue:"defaultValue",defaultchecked:"defaultChecked",srcobject:"srcObject",novalidate:"noValidate",allowfullscreen:"allowFullscreen",disablepictureinpicture:"disablePictureInPicture",disableremoteplayback:"disableRemotePlayback"};function Me(t){return t=t.toLowerCase(),Ie[t]??t}const Le=["touchstart","touchmove"];function Pe(t){return Le.includes(t)}function Ce(t,e){if(e){const e=document.body;t.autofocus=!0,z((()=>{document.activeElement===e&&t.focus()}))}}function De(t,e,i,r=!0){for(var n of(r&&i(),e))t.addEventListener(n,i);te((()=>{for(var r of e)t.removeEventListener(r,i)}))}function Re(t){var e=bt,i=Tt;kt(null),_t(null);try{return t()}finally{kt(e),_t(i)}}const ze=new Set,Oe=new Set;function Ne(t,e,i,r={}){function n(t){if(r.capture||Ue.call(e,t),!t.cancelBubble)return Re((()=>null==i?void 0:i.call(this,t)))}return t.startsWith("pointer")||t.startsWith("touch")||"wheel"===t?z((()=>{e.addEventListener(t,n,r)})):e.addEventListener(t,n,r),n}function Fe(t,e,i,r,n){var s={capture:r,passive:n},o=Ne(t,e,i,s);e!==document.body&&e!==window&&e!==document||te((()=>{e.removeEventListener(t,o,s)}))}function Ve(t){for(var e=0;e<t.length;e++)ze.add(t[e]);for(var i of Oe)i(t)}function Ue(t){var e,i=this,r=i.ownerDocument,n=t.type,s=(null==(e=t.composedPath)?void 0:e.call(t))||[],o=s[0]||t.target,a=0,l=t.__root;if(l){var c=s.indexOf(l);if(-1!==c&&(i===document||i===window))return void(t.__root=i);var u=s.indexOf(i);if(-1===u)return;c<=u&&(a=c)}if((o=s[a]||t.target)!==i){T(t,"currentTarget",{configurable:!0,get:()=>o||r});var d=bt,h=Tt;kt(null),_t(null);try{for(var m,v=[];null!==o;){var p=o.assignedSlot||o.parentNode||o.host||null;try{var f=o["__"+n];if(null!=f&&(!o.disabled||t.target===o))if(b(f)){var[g,...w]=f;g.apply(o,[t,...w])}else f.call(o,t)}catch(y){m?v.push(y):m=y}if(t.cancelBubble||p===i||null===p)break;o=p}if(m){for(let t of v)queueMicrotask((()=>{throw t}));throw m}}finally{t.__root=i,delete t.currentTarget,kt(d),_t(h)}}}function Be(t){var e=document.createElement("template");return e.innerHTML=t,e.content}function qe(t,e){var i=Tt;null===i.nodes_start&&(i.nodes_start=t,i.nodes_end=e)}function We(t,e){var i,r=!!(1&e),n=!!(2&e),s=!t.startsWith("<!>");return()=>{void 0===i&&(i=Be(s?t:"<!>"+t),r||(i=at(i)));var e=n||rt?document.importNode(i,!0):i.cloneNode(!0);r?qe(at(e),e.lastChild):qe(e,e);return e}}function Xe(t,e,i="svg"){var r,n=!t.startsWith("<!>"),s=!!(1&e),o=`<${i}>${n?t:"<!>"+t}</${i}>`;return()=>{if(!r){var t=at(Be(o));if(s)for(r=document.createDocumentFragment();at(t);)r.appendChild(at(t));else r=at(t)}var e=r.cloneNode(!0);s?qe(at(e),e.lastChild):qe(e,e);return e}}function je(t=""){var e=ot(t+"");return qe(e,e),e}function Ge(){var t=document.createDocumentFragment(),e=document.createComment(""),i=ot();return t.append(e,i),qe(e,i),t}function Ye(t,e){null!==t&&t.before(e)}let He=!0;function Ze(t){He=t}function Ke(t,e){var i=null==e?"":"object"==typeof e?e+"":e;i!==(t.__t??(t.__t=t.nodeValue))&&(t.__t=i,t.nodeValue=i+"")}function Je(t,e){return function(t,{target:e,anchor:i,props:r={},events:s,context:o,intro:a=!0}){!function(){if(void 0===it){it=window,rt=/Firefox/.test(navigator.userAgent);var t=Element.prototype,e=Node.prototype,i=Text.prototype;nt=_(e,"firstChild").get,st=_(e,"nextSibling").get,S(t)&&(t.__click=void 0,t.__className=void 0,t.__attributes=null,t.__style=void 0,t.__e=void 0),S(i)&&(i.__t=void 0)}}();var l=new Set,c=t=>{for(var i=0;i<t.length;i++){var r=t[i];if(!l.has(r)){l.add(r);var n=Pe(r);e.addEventListener(r,Ue,{passive:n});var s=Qe.get(r);void 0===s?(document.addEventListener(r,Ue,{passive:n}),Qe.set(r,1)):Qe.set(r,s+1)}}};c(k(ze)),Oe.add(c);var u=void 0,d=function(t){const e=Qt(n,t,!0);return(t={})=>new Promise((i=>{t.outro?he(e,(()=>{ue(e),i(void 0)})):(ue(e),i(void 0))}))}((()=>{var n=i??e.appendChild(ot());return ae((()=>{o&&(Te({}),we.c=o);s&&(r.$$events=s),He=a,u=t(n,r)||{},He=!0,o&&_e()})),()=>{var t;for(var r of l){e.removeEventListener(r,Ue);var s=Qe.get(r);0==--s?(document.removeEventListener(r,Ue),Qe.delete(r)):Qe.set(r,s)}Oe.delete(c),n!==i&&(null==(t=n.parentNode)||t.removeChild(n))}}));return ti.set(u,d),u}(t,e)}const Qe=new Map;let ti=new WeakMap;function ei(t,i,[r,n]=[0,0]){var s=t,o=null,a=null,l=e,c=!1;const u=(t,e=!0)=>{c=!0,d(e,t)},d=(t,e)=>{l!==(l=t)&&(l?(o?pe(o):e&&(o=ae((()=>e(s)))),a&&he(a,(()=>{a=null}))):(a?pe(a):e&&(a=ae((()=>e(s,[r+1,n])))),o&&he(o,(()=>{o=null}))))};oe((()=>{c=!1,i(u),c||d(null,null)}),r>0?m:0)}function ii(t,e){return e}function ri(t,e,i,r,n,s=null){var o=t,a={flags:e,items:new Map,first:null};!(4&e)||(o=t.appendChild(ot()));var l=null,c=!1,u=Q((()=>{var t=i();return b(t)?t:null==t?[]:k(t)}));oe((()=>{var t=jt(u),h=t.length;c&&0===h||(c=0===h,function(t,e,i,r,n,s,o){var a,l,c,u,h,m,v,p,f,g,w=!!(8&n),b=!!(3&n),y=t.length,T=e.items,_=e.first,x=_,E=null,$=[],A=[];if(w)for(g=0;g<y;g+=1)p=s(v=t[g],g),void 0!==(f=T.get(p))&&(null==(a=f.a)||a.measure(),(m??(m=new Set)).add(f));for(g=0;g<y;g+=1)if(p=s(v=t[g],g),void 0!==(f=T.get(p))){if(b&&ni(f,v,g,n),f.e.f&d&&(pe(f.e),w&&(null==(l=f.a)||l.unfix(),(m??(m=new Set)).delete(f))),f!==x){if(void 0!==h&&h.has(f)){if($.length<A.length){var S,I=A[0];E=I.prev;var M=$[0],L=$[$.length-1];for(S=0;S<$.length;S+=1)oi($[S],I,i);for(S=0;S<A.length;S+=1)h.delete(A[S]);ai(e,M.prev,L.next),ai(e,E,M),ai(e,L,I),x=I,E=L,g-=1,$=[],A=[]}else h.delete(f),oi(f,x,i),ai(e,f.prev,f.next),ai(e,f,null===E?e.first:E.next),ai(e,E,f),E=f;continue}for($=[],A=[];null!==x&&x.k!==p;)x.e.f&d||(h??(h=new Set)).add(x),A.push(x),x=x.next;if(null===x)continue;f=x}$.push(f),E=f,x=f.next}else{E=si(x?x.e.nodes_start:i,e,E,null===E?e.first:E.next,v,p,g,r,n,o),T.set(p,E),$=[],A=[],x=E.next}if(null!==x||void 0!==h){for(var P=void 0===h?[]:k(h);null!==x;)x.e.f&d||P.push(x),x=x.next;var C=P.length;if(C>0){var D=4&n&&0===y?i:null;if(w){for(g=0;g<C;g+=1)null==(c=P[g].a)||c.measure();for(g=0;g<C;g+=1)null==(u=P[g].a)||u.fix()}!function(t,e,i,r){for(var n=[],s=e.length,o=0;o<s;o++)ve(e[o].e,n,!0);var a=s>0&&0===n.length&&null!==i;if(a){var l=i.parentNode;l.textContent="",l.append(i),r.clear(),ai(t,e[0].prev,e[s-1].next)}me(n,(()=>{for(var i=0;i<s;i++){var n=e[i];a||(r.delete(n.k),ai(t,n.prev,n.next)),ue(n.e,!a)}}))}(e,P,D,T)}}w&&z((()=>{var t;if(void 0!==m)for(f of m)null==(t=f.a)||t.apply()}));Tt.first=e.first&&e.first.e,Tt.last=E&&E.e}(t,a,o,n,e,r,i),null!==s&&(0===h?l?pe(l):l=ae((()=>s(o))):null!==l&&he(l,(()=>{l=null}))),jt(u))}))}function ni(t,e,i,r){1&r&&H(t.v,e),2&r?H(t.i,i):t.i=i}function si(t,e,i,r,n,s,o,a,l,c){var u=!!(1&l)?!(16&l)?G(n):X(n):n,d=2&l?X(o):o,h={i:d,v:u,k:s,a:null,e:null,prev:i,next:r};try{return h.e=ae((()=>a(t,u,d,c)),false),h.e.prev=i&&i.e,h.e.next=r&&r.e,null===i?e.first=h:(i.next=h,i.e.next=h.e),null!==r&&(r.prev=h,r.e.prev=h.e),h}finally{}}function oi(t,e,i){for(var r=t.next?t.next.e.nodes_start:i,n=e?e.e.nodes_start:i,s=t.e.nodes_start;s!==r;){var o=lt(s);n.before(s),s=o}}function ai(t,e,i){null===e?t.first=i:(e.next=i,e.e.next=i&&i.e),null!==i&&(i.prev=e,i.e.prev=e&&e.e)}function li(t,e,i,r,n){var s,o=t,a="";oe((()=>{a!==(a=e()??"")&&(void 0!==s&&(ue(s),s=void 0),""!==a&&(s=ae((()=>{var t=Be(a+"");qe(at(t),t.lastChild),o.before(t)}))))}))}function ci(t,e,...i){var r,n=t,s=M;oe((()=>{s!==(s=e())&&(r&&(ue(r),r=null),r=ae((()=>s(n,...i))))}),m)}function ui(t,e,i,r,n,s){var o,a,l,c=null,u=t;oe((()=>{const t=e()||null;var i="svg"===t?"http://www.w3.org/2000/svg":null;t!==o&&(l&&(null===t?he(l,(()=>{l=null,a=null})):t===a?pe(l):(ue(l),Ze(!1))),t&&t!==a&&(l=ae((()=>{if(qe(c=i?document.createElementNS(i,t):document.createElement(t),c),r){var e=c.appendChild(ot());r(c,e)}Tt.nodes_end=c,u.before(c)}))),(o=t)&&(a=o),Ze(!0))}),m)}function di(t){var e,i,r="";if("string"==typeof t||"number"==typeof t)r+=t;else if("object"==typeof t)if(Array.isArray(t)){var n=t.length;for(e=0;e<n;e++)t[e]&&(i=di(t[e]))&&(r&&(r+=" "),r+=i)}else for(i in t)t[i]&&(r&&(r+=" "),r+=i);return r}function hi(t){return"object"==typeof t?function(){for(var t,e,i=0,r="",n=arguments.length;i<n;i++)(t=arguments[i])&&(e=di(t))&&(r&&(r+=" "),r+=e);return r}(t):t??""}const mi=[..." \t\n\r\f \v\ufeff"];function vi(t,e=!1){var i=e?" !important;":";",r="";for(var n in t){var s=t[n];null!=s&&""!==s&&(r+=" "+n+": "+s+i)}return r}function pi(t){return"-"!==t[0]||"-"!==t[1]?t.toLowerCase():t}function fi(t,e,i,r,n,s){var o=t.__className;if(o!==i||void 0===o){var a=function(t,e,i){var r=null==t?"":""+t;if(e&&(r=r?r+" "+e:e),i)for(var n in i)if(i[n])r=r?r+" "+n:n;else if(r.length)for(var s=n.length,o=0;(o=r.indexOf(n,o))>=0;){var a=o+s;0!==o&&!mi.includes(r[o-1])||a!==r.length&&!mi.includes(r[a])?o=a:r=(0===o?"":r.substring(0,o))+r.substring(a+1)}return""===r?null:r}(i,r,s);null==a?t.removeAttribute("class"):e?t.className=a:t.setAttribute("class",a),t.__className=i}else if(s&&n!==s)for(var l in s){var c=!!s[l];null!=n&&c===!!n[l]||t.classList.toggle(l,c)}return s}function gi(t,e={},i,r){for(var n in i){var s=i[n];e[n]!==s&&(null==i[n]?t.style.removeProperty(n):t.style.setProperty(n,s,r))}}function wi(t,e,i,r){if(t.__style!==e){var n=function(t,e){if(e){var i,r,n="";if(Array.isArray(e)?(i=e[0],r=e[1]):i=e,t){t=String(t).replaceAll(/\s*\/\*.*?\*\/\s*/g,"").trim();var s=!1,o=0,a=!1,l=[];i&&l.push(...Object.keys(i).map(pi)),r&&l.push(...Object.keys(r).map(pi));var c=0,u=-1;const e=t.length;for(var d=0;d<e;d++){var h=t[d];if(a?"/"===h&&"*"===t[d-1]&&(a=!1):s?s===h&&(s=!1):"/"===h&&"*"===t[d+1]?a=!0:'"'===h||"'"===h?s=h:"("===h?o++:")"===h&&o--,!a&&!1===s&&0===o)if(":"===h&&-1===u)u=d;else if(";"===h||d===e-1){if(-1!==u){var m=pi(t.substring(c,u).trim());l.includes(m)||(";"!==h&&d++,n+=" "+t.substring(c,d).trim()+";")}c=d+1,u=-1}}}return i&&(n+=vi(i)),r&&(n+=vi(r,!0)),""===(n=n.trim())?null:n}return null==t?null:String(t)}(e,r);null==n?t.removeAttribute("style"):t.style.cssText=n,t.__style=e}else r&&(Array.isArray(r)?(gi(t,null==i?void 0:i[0],r[0]),gi(t,null==i?void 0:i[1],r[1],"important")):gi(t,i,r));return r}const bi=Symbol("class"),yi=Symbol("style"),ki=Symbol("is custom element"),Ti=Symbol("is html");function _i(t,e){e?t.hasAttribute("selected")||t.setAttribute("selected",""):t.removeAttribute("selected")}function xi(t,e,i,r){var n=Ai(t);n[e]!==(n[e]=i)&&("loading"===e&&(t[w]=i),null==i?t.removeAttribute(e):"string"!=typeof i&&Ii(t).includes(e)?t[e]=i:t.setAttribute(e,i))}function Ei(t,e,i){var r=bt,n=Tt;kt(null),_t(null);try{"style"!==e&&(Si.has(t.nodeName)||!customElements||customElements.get(t.tagName.toLowerCase())?Ii(t).includes(e):i&&"object"==typeof i)?t[e]=i:xi(t,e,null==i?i:String(i))}finally{kt(r),_t(n)}}function $i(t,e,i,r,n=!1){var s=Ai(t),o=s[ki],a=!s[Ti],l=e||{},c="OPTION"===t.tagName;for(var u in e)u in i||(i[u]=null);i.class?i.class=hi(i.class):(r||i[bi])&&(i.class=null),i[yi]&&(i.style??(i.style=null));var d=Ii(t);for(const g in i){let n=i[g];if(c&&"value"===g&&null==n)t.value=t.__value="",l[g]=n;else if("class"!==g)if("style"!==g){var h=l[g];if(n!==h){l[g]=n;var m=g[0]+g[1];if("$$"!==m)if("on"===m){const e={},i="$$"+g;let r=g.slice(2);var v=Se(r);if($e(r)&&(r=r.slice(0,-7),e.capture=!0),!v&&h){if(null!=n)continue;t.removeEventListener(r,l[i],e),l[i]=null}if(null!=n)if(v)t[`__${r}`]=n,Ve([r]);else{let n=function(t){l[g].call(this,t)};l[i]=Ne(r,t,n,e)}else v&&(t[`__${r}`]=void 0)}else if("style"===g)xi(t,g,n);else if("autofocus"===g)Ce(t,Boolean(n));else if(o||"__value"!==g&&("value"!==g||null==n))if("selected"===g&&c)_i(t,n);else{var p=g;a||(p=Me(p));var f="defaultValue"===p||"defaultChecked"===p;if(null!=n||o||f)f||d.includes(p)&&(o||"string"!=typeof n)?t[p]=n:"function"!=typeof n&&xi(t,p,n);else if(s[g]=null,"value"===p||"checked"===p){let i=t;const r=void 0===e;if("value"===p){let t=i.defaultValue;i.removeAttribute(p),i.defaultValue=t,i.value=i.__value=r?t:null}else{let t=i.defaultChecked;i.removeAttribute(p),i.defaultChecked=t,i.checked=!!r&&t}}else t.removeAttribute(g)}else t.value=t.__value=n}}else wi(t,n,null==e?void 0:e[yi],i[yi]),l[g]=n,l[yi]=i[yi];else fi(t,"http://www.w3.org/1999/xhtml"===t.namespaceURI,n,r,null==e?void 0:e[bi],i[bi]),l[g]=n,l[bi]=i[bi]}return l}function Ai(t){return t.__attributes??(t.__attributes={[ki]:t.nodeName.includes("-"),[Ti]:"http://www.w3.org/1999/xhtml"===t.namespaceURI})}var Si=new Map;function Ii(t){var e,i=Si.get(t.nodeName);if(i)return i;Si.set(t.nodeName,i=[]);for(var r=t,n=Element.prototype;n!==r;){for(var s in e=x(r))e[s].set&&i.push(s);r=A(r)}return i}const Mi={tick:t=>requestAnimationFrame(t),now:()=>performance.now(),tasks:new Set};function Li(){const t=Mi.now();Mi.tasks.forEach((e=>{e.c(t)||(Mi.tasks.delete(e),e.f())})),0!==Mi.tasks.size&&Mi.tick(Li)}function Pi(t,e){Re((()=>{t.dispatchEvent(new CustomEvent(e))}))}function Ci(t){if("float"===t)return"cssFloat";if("offset"===t)return"cssOffset";if(t.startsWith("--"))return t;const e=t.split("-");return 1===e.length?e[0]:e[0]+e.slice(1).map((t=>t[0].toUpperCase()+t.slice(1))).join("")}function Di(t){const e={},i=t.split(";");for(const r of i){const[t,i]=r.split(":");if(!t||void 0===i)break;e[Ci(t.trim())]=i.trim()}return e}const Ri=t=>t;function zi(t,e,i,r){var n,s,o,a=!!(1&t),l=!!(2&t),c=!!(4&t),u=a&&l?"both":a?"in":"out",d=e.inert,h=e.style.overflow;function v(){var t=bt,s=Tt;kt(null),_t(null);try{return n??(n=i()(e,(null==r?void 0:r())??{},{direction:u}))}finally{kt(t),_t(s)}}var p={is_global:c,in(){var t;if(e.inert=d,!a)return null==o||o.abort(),void(null==(t=null==o?void 0:o.reset)||t.call(o));l||null==s||s.abort(),Pi(e,"introstart"),s=Oi(e,v(),o,1,(()=>{Pi(e,"introend"),null==s||s.abort(),s=n=void 0,e.style.overflow=h}))},out(t){if(!l)return null==t||t(),void(n=void 0);e.inert=!0,Pi(e,"outrostart"),o=Oi(e,v(),s,0,(()=>{Pi(e,"outroend"),null==t||t()}))},stop:()=>{null==s||s.abort(),null==o||o.abort()}},f=Tt;if((f.transitions??(f.transitions=[])).push(p),a&&He){var g=c;if(!g){for(var w=f.parent;w&&w.f&m;)for(;(w=w.parent)&&!(16&w.f););g=!w||!!(32768&w.f)}g&&ie((()=>{Gt((()=>p.in()))}))}}function Oi(t,e,i,r,n){var s=1===r;if(I(e)){var o,a=!1;return z((()=>{if(!a){var l=e({direction:s?"in":"out"});o=Oi(t,l,i,r,n)}})),{abort:()=>{a=!0,null==o||o.abort()},deactivate:()=>o.deactivate(),reset:()=>o.reset(),t:()=>o.t()}}if(null==i||i.deactivate(),!(null==e?void 0:e.duration))return n(),{abort:M,deactivate:M,reset:M,t:()=>r};const{delay:l=0,css:c,tick:u,easing:d=Ri}=e;var h=[];if(s&&void 0===i&&(u&&u(0,1),c)){var m=Di(c(0,1));h.push(m,m)}var v=()=>1-r,p=t.animate(h,{duration:l});return p.onfinish=()=>{var s=(null==i?void 0:i.t())??1-r;null==i||i.abort();var o=r-s,a=e.duration*Math.abs(o),l=[];if(a>0){var h=!1;if(c)for(var m=Math.ceil(a/(1e3/60)),f=0;f<=m;f+=1){var g=s+o*d(f/m),w=Di(c(g,1-g));l.push(w),h||(h="hidden"===w.overflow)}h&&(t.style.overflow="hidden"),v=()=>{var t=p.currentTime;return s+o*d(t/a)},u&&function(t){let e;0===Mi.tasks.size&&Mi.tick(Li),new Promise((i=>{Mi.tasks.add(e={c:t,f:i})}))}((()=>{if("running"!==p.playState)return!1;var t=v();return u(t,1-t),!0}))}(p=t.animate(l,{duration:a,fill:"forwards"})).onfinish=()=>{v=()=>r,null==u||u(r,1-r),n()}},{abort:()=>{p&&(p.cancel(),p.effect=null,p.onfinish=M)},deactivate:()=>{n=M},reset:()=>{0===r&&(null==u||u(1,0))},t:()=>v()}}function Ni(t,e,i=e){var r,n,s=()=>{cancelAnimationFrame(r),t.paused||(r=requestAnimationFrame(s));var e=t.currentTime;n!==e&&i(n=e)};r=requestAnimationFrame(s),t.addEventListener("timeupdate",s),ne((()=>{var i=Number(e());n===i||isNaN(i)||(t.currentTime=n=i)})),te((()=>{cancelAnimationFrame(r),t.removeEventListener("timeupdate",s)}))}function Fi(t,e){De(t,["seeking","seeked"],(()=>e(t.seeking)))}function Vi(t,e,i=e){var r=e();De(t,["play","pause","canplay"],(()=>{r!==t.paused&&i(r=t.paused)}),null==r),ie((()=>{(r=!!e())!==t.paused&&(r?t.pause():t.play().catch((()=>{i(r=!0)})))}))}function Ui(t,e,i=e){var r=()=>{i(t.muted)};null==e()&&r(),De(t,["volumechange"],r,!1),ne((()=>{var i=!!e();t.muted!==i&&(t.muted=i)}))}function Bi(t,e){return t===e||(null==t?void 0:t[f])===e}function qi(t={},e,i,r){return ie((()=>{var r,n;return ne((()=>{r=n,n=[],Gt((()=>{t!==i(...n)&&(e(t,...n),r&&Bi(i(...r),t)&&e(null,...r))}))})),()=>{z((()=>{n&&Bi(i(...n),t)&&e(null,...n)}))}})),t}function Wi(t,e,i,r,n){var s=()=>{r(i[t])};i.addEventListener(e,s),s(),i!==document.body&&i!==window&&i!==document||te((()=>{i.removeEventListener(e,s)}))}function Xi(t=!1){const e=we,i=e.l.u;if(!i)return;let r=()=>Zt(e.s);if(t){let t=0,i={};const n=K((()=>{let r=!1;const n=e.s;for(const t in n)n[t]!==i[t]&&(i[t]=n[t],r=!0);return r&&t++,t}));r=()=>jt(n)}var n;i.b.length&&(n=()=>{ji(e,r),P(i.b)},Jt(),ne(n)),ee((()=>{const t=Gt((()=>i.m.map(L)));return()=>{for(const e of t)"function"==typeof e&&e()}})),i.a.length&&ee((()=>{ji(e,r),P(i.a)}))}function ji(t,e){if(t.l.s)for(const i of t.l.s)jt(i);e()}function Gi(t){var e,i;null===we&&ge(),U&&null!==we.l?(e=we,i=e.l,i.u??(i.u={a:[],b:[],m:[]})).m.push(t):ee((()=>{const e=Gt(t);if("function"==typeof e)return e}))}function Yi(t,e,i){if(null==t)return e(void 0),M;const r=Gt((()=>t.subscribe(e,i)));return r.unsubscribe?()=>r.unsubscribe():r}const Hi=[];function Zi(t,e=M){let i=null;const r=new Set;function n(e){if(F(t,e)&&(t=e,i)){const e=!Hi.length;for(const i of r)i[1](),Hi.push(i,t);if(e){for(let t=0;t<Hi.length;t+=2)Hi[t][0](Hi[t+1]);Hi.length=0}}}function s(e){n(e(t))}return{set:n,update:s,subscribe:function(o,a=M){const l=[o,a];return r.add(l),1===r.size&&(i=e(n,s)||M),o(t),()=>{r.delete(l),0===r.size&&i&&(i(),i=null)}}}}function Ki(t){let e;return Yi(t,(t=>e=t))(),e}let Ji=!1,Qi=Symbol();function tr(t,e,i){const r=i[e]??(i[e]={store:null,source:G(void 0),unsubscribe:M});if(r.store!==t&&!(Qi in i))if(r.unsubscribe(),r.store=t??null,null==t)r.source.v=void 0,r.unsubscribe=M;else{var n=!0;r.unsubscribe=Yi(t,(t=>{n?r.source.v=t:Y(r.source,t)})),n=!1}return t&&Qi in i?Ki(t):jt(r.source)}function er(t,e,i){let r=i[e];return r&&r.store!==t&&(r.unsubscribe(),r.unsubscribe=M),t}function ir(){const t={};return[t,function(){te((()=>{for(var e in t){t[e].unsubscribe()}T(t,Qi,{enumerable:!1,value:!0})}))}]}const rr={get(t,e){let i=t.props.length;for(;i--;){let r=t.props[i];if(I(r)&&(r=r()),"object"==typeof r&&null!==r&&e in r)return r[e]}},set(t,e,i){let r=t.props.length;for(;r--;){let n=t.props[r];I(n)&&(n=n());const s=_(n,e);if(s&&s.set)return s.set(i),!0}return!1},getOwnPropertyDescriptor(t,e){let i=t.props.length;for(;i--;){let r=t.props[i];if(I(r)&&(r=r()),"object"==typeof r&&null!==r&&e in r){const t=_(r,e);return t&&!t.configurable&&(t.configurable=!0),t}}},has(t,e){if(e===f||e===g)return!1;for(let i of t.props)if(I(i)&&(i=i()),null!=i&&e in i)return!0;return!1},ownKeys(t){const e=[];for(let i of t.props){I(i)&&(i=i());for(const t in i)e.includes(t)||e.push(t)}return e}};function nr(...t){return new Proxy({props:t},rr)}function sr(t){var e;return(null==(e=t.ctx)?void 0:e.d)??!1}function or(t,e,i,r){var n,s,o=!!(1&i),a=!U||!!(2&i),l=!!(8&i),c=!!(16&i),u=!1;l?[s,u]=function(t){var e=Ji;try{return Ji=!1,[t(),Ji]}finally{Ji=e}}((()=>t[e])):s=t[e];var d,h=f in t||g in t,m=l&&((null==(n=_(t,e))?void 0:n.set)??(h&&e in t&&(i=>t[e]=i)))||void 0,v=r,p=!0,w=!1,b=()=>(w=!0,p&&(p=!1,v=c?Gt(r):r),v);if(void 0===s&&void 0!==r&&(m&&a&&function(){throw new Error("https://svelte.dev/e/props_invalid_value")}(),s=b(),m&&m(s)),a)d=()=>{var i=t[e];return void 0===i?b():(p=!0,w=!1,i)};else{var y=(o?K:Q)((()=>t[e]));y.f|=131072,d=()=>{var t=jt(y);return void 0!==t&&(v=void 0),void 0===t?v:t}}if(!(4&i))return d;if(m){var k=t.$$legacy;return function(t,e){return arguments.length>0?(a&&e&&!k&&!u||m(e?d():t),t):d()}}var T=!1,x=G(s),E=K((()=>{var t=d(),e=jt(x);return T?(T=!1,e):x.v=t}));return l&&jt(E),o||(E.equals=V),function(t,e){if(arguments.length>0){const i=e?jt(E):a&&l?B(t):t;if(!E.equals(i)){if(T=!0,Y(x,i),w&&void 0!==v&&(v=i),sr(E))return t;Gt((()=>jt(E)))}return t}return sr(E)?E.v:jt(E)}}const ar=(t,e)=>Math.sqrt(t*t+e*e),lr=(t,e=1)=>(t%e+e)%e,cr=()=>ur()+ur()+"-"+ur()+"-"+ur()+"-"+ur()+"-"+ur()+ur()+ur(),ur=()=>Math.floor(65536*(1+Math.random())).toString(16).substring(1),dr=t=>new Promise((e=>t?setTimeout(e,t):e())),hr=navigator.userAgent,mr={iOS:/ipad|iphone|ipod/i.test(hr),firefox:/firefox/i.test(hr),OSX:/macintosh/i.test(hr)&&/os\ x/i.test(hr),hasTouch:"TouchEvent"in self,safari:!1};function vr(t,e,i={}){for(let r in t)t[r]&&null!=t[r].constructor&&"Object"==t[r].constructor.name?(e[r]&&"object"==typeof e[r]||(e[r]={}),vr(t[r],e[r],i)):i.mergeArrays&&e[r]instanceof Array&&t[r]instanceof Array?e[r].push(...t[r]):i.noOverwrite&&r in e||(e[r]=t[r]);return e}mr.safari=(mr.OSX||mr.iOS)&&(/safari/i.test(hr)||/instagram/i.test(hr))&&!/chrome/i.test(hr),mr.OSX&&mr.safari&&"TouchEvent"in self&&(mr.iOS=!0,mr.OSX=!1);const pr=t=>{if(void 0===t)return t;t=(t=t.replace(/^\s+|\s+$/g,"")).toLowerCase();const e="àáäâèéëêìíïîòóöôùúüûñç·/_,:;";for(var i=0;i<28;i++)t=t.replace(new RegExp(e.charAt(i),"g"),"aaaaeeeeiiiioooouuuunc------".charAt(i));return t=t.replace(/[^a-z0-9 -]/g,"").replace(/\s+/g,"-").replace(/-+/g,"-")},fr=[],gr=(t,e,i)=>new Promise(((r,n)=>{if(i||fr.indexOf(t)>=0)return r();const s=document.createElement("script"),o=()=>{fr.push(t),r()};e?self[e]=o:s.onload=o,s.onerror=()=>n&&n(),s.async=!0,s.defer=!0,self.crossOriginIsolated&&(s.crossOrigin="anonymous"),s.src=t,document.head.appendChild(s)}));function wr(t){const e=t<0;e&&(t*=-1);let i=[0,0,Math.ceil(t)];for(let r of[0,1])for(;i[2-r]>=60&&(i[2-r]-=60,++i[1-r]););return(e?"-":"")+i.filter(((t,e)=>e>0||t)).map(((t,e)=>(t<10&&e?"0":"")+t)).join(":")}const br=(t,e={})=>new Promise((i=>{let r,n=!0;r=t.subscribe((t=>{n&&e.allowUndefined&&void 0===t||(n=!1,(void 0!==e.targetValue?t===e.targetValue:e.allowUndefined||void 0!==t)&&(r?r():Xt().then((()=>r())),i(t)))}))})),yr=new Map,kr=new Map,Tr=async(t,e)=>{if(!e&&yr.has(t))return yr.get(t);if(kr.has(t))return kr.get(t);const i=fetch(t+(e?"?"+Math.random():"")).then((async t=>{if(200==t.status)return t.json();throw await t.text()})).then((i=>(e||yr.set(t,i),kr.delete(t),i))).catch((e=>{kr.delete(t)}));return kr.set(t,i),i},_r=t=>"MICRIO_DATA"in self?(null==self?void 0:self.MICRIO_DATA).find((e=>e[0]==t)):void 0,xr=(t,e,i)=>{var r;const n=null==(r=_r(t))?void 0:r[1];return n?Promise.resolve(n):Tr(`${e??"https://i.micr.io/"}${t}/info.json`,i).then((t=>(t&&("Height"in t&&(t.height=t.Height,t.version=1,t.tileSize=512),"Width"in t&&(t.width=t.Width)),Ar(t),t)))},Er={"micrio-cdn.azureedge.net":"micrio.vangoghmuseum.nl/micrio","micrio-cdn.vangoghmuseum.nl":"micrio.vangoghmuseum.nl/micrio","rijks-micrio.azureedge.net":"micrio.rijksmuseum.nl"},$r=t=>{if(t instanceof Object&&"fileUrl"in t&&!t.src&&(t.src=t.fileUrl),null==t?void 0:t.src)for(let e in Er)t.src.includes(e)&&(t.src=t.src.replace(e,Er[e]))},Ar=t=>{var e,i,r,n,s,o,a,l;t&&($r(null==(e=t.organisation)?void 0:e.logo),$r(null==(r=null==(i=t.settings)?void 0:i._markers)?void 0:r.markerIcon),null==(o=null==(s=null==(n=t.settings)?void 0:n._markers)?void 0:s.customIcons)||o.forEach($r),$r(null==(l=null==(a=t.settings)?void 0:a._360)?void 0:l.video))},Sr=t=>{var e;$r(t.image),null==(e=t.children)||e.forEach(Sr)},Ir=(t,e,i)=>{var r,n,s,o;t.data||(t.data={}),t.id||(t.id=cr()),t.tags||(t.tags=[]),"type"in t||(t.type="default"),t.popupType||(t.popupType="popup"),"string"==typeof t.data.icon&&(t.data.icon={title:"",size:0,uploaded:0,width:-1,height:-1,src:t.data.icon}),null==(r=t.images)||r.forEach($r),$r(t.positionalAudio),$r(null==(n=t.data)?void 0:n.icon),Object.values(t.i18n??{}).forEach((t=>$r(t.audio)));const a="embedImages"in t?t.embedImages:void 0;a&&a.forEach((t=>$r(t)));const l=null==(o=null==(s=t.data)?void 0:s._meta)?void 0:o.secondary;l&&(t.data.micrioSplitLink=l),i&&"class"in t&&t.tags.push(...t.class.split(" ").map((t=>t.trim())).filter((e=>!!e&&!t.tags.includes(e)))),t.tags.includes("default")&&(t.type="default"),e&&t.view&&t.view[2]<t.view[0]&&t.view[2]++};async function Mr(t,e,i,r){if(!("steps"in e)||e.stepInfo)return;let n=e.steps.map((t=>t.split(",")[1])).filter((e=>!!e&&e!=t.id));n=n.filter(((t,e)=>n.indexOf(t)==e));const s=await Promise.all(n.map((e=>Tr((e=>t.dataPath+(t.isV5?e+"/data/pub.json":e+"/data."+i+".json"))(e)))));s.forEach((e=>{var i;return null==(i=null==e?void 0:e.markers)?void 0:i.forEach((e=>Ir(e,t.is360,!t.isV5)))})),$r(e.image);let o=-1;const a=[];e.stepInfo=e.steps.map(((e,l)=>{var c,u,d,h,m,v,p,f,g,w;const[b,y]=e.split(","),k=s[n.indexOf(y)]??r,T=null==(c=null==k?void 0:k.markers)?void 0:c.find((t=>t.id==b)),_=(null==(u=null==T?void 0:T.i18n)?void 0:u[i])??T;(null==_?void 0:_.title)&&(o=l);const x=(null==T?void 0:T.videoTour)?"timeline"in T.videoTour?T:(null==(d=T.videoTour.i18n)?void 0:d[i])??void 0:void 0;return $r(null==x?void 0:x.audio),$r(null==x?void 0:x.subtitle),T?($r(null==_?void 0:_.audio),{markerId:b,marker:T,micrioId:y||t.id,duration:Number((null==x?void 0:x.duration)||(null==(h=null==_?void 0:_.audio)?void 0:h.duration)||0),startView:(null==(m=null==x?void 0:x.timeline)?void 0:m.length)?x.timeline[0].rect:null==T?void 0:T.view,imageHasOtherMarkers:!!y&&!!(null==(v=null==k?void 0:k.markers)?void 0:v.find((t=>t.id!=b&&!t.noMarker))),gridView:!(!(null==(f=null==(p=T.data)?void 0:p._meta)?void 0:f.gridView)&&!(null==(w=null==(g=T.data)?void 0:g._meta)?void 0:w.gridAction)),chapter:o,hasSubtitle:!!(null==x?void 0:x.subtitle)}):(console.warn(`[Micrio] Warning: tour step ${l+1} with id [${b}] not found! Removing it from the tour`),void a.push(l))})).filter((t=>"object"==typeof t)),a.reverse().forEach((t=>e.steps.splice(t,1))),e.initialStep=0,e.duration=e.stepInfo.reduce(((t,e)=>t+(e.duration||0)),0)}const Lr=t=>{let e=t.charCodeAt(0),i=e<91;return(e-=i?65:97)-(e>7?1:0)+(i?24:e>10?-1:0)},Pr=t=>6==t.length||7==t.length;function Cr(t,e){var i,r,n,s;const o=t.$current;if(!o)return;const a=null==(i=t.spaceData)?void 0:i.images.find((t=>t.id==o.id)),l=null==(r=t.spaceData)?void 0:r.images.find((t=>t.id==e));if(!a||!l)return;const c=[(l.x??.5)-(a.x??.5),(a.y??.5)-(l.y??.5),(l.z??.5)-(a.z??.5)];let u=c[0]*c[0]+c[1]*c[1]+c[2]*c[2];u>0&&(u=1/Math.sqrt(u));const d=[c[0]*u,c[1]*u,c[2]*u],h=.5-((null==(s=null==(n=o.$settings)?void 0:n._360)?void 0:s.trueNorth)??.5),m=lr(Math.atan2(-d[0],d[2])/Math.PI/2);return{v:c,vN:d,directionX:m,vector:{direction:m%1-h,distanceX:Math.max(0,Math.min(.4,Math.sqrt(d[0]*d[0]+d[2]*d[2]))),distanceY:-c[1]}}}const Dr=t=>{const e=t??document.createElement("video");return!(!e.canPlayType("application/vnd.apple.mpegurl")&&!e.canPlayType("application/x-mpegURL"))},Rr=t=>t;function zr(t){const e=t-1;return e*e*e+1}function Or(t){const e="string"==typeof t&&t.match(/^\s*(-?[\d.]+)([^\s]*)\s*$/);return e?[parseFloat(e[1]),e[2]||"px"]:[t,"px"]}function Nr(t,{delay:e=0,duration:i=400,easing:r=Rr}={}){const n=+getComputedStyle(t).opacity;return{delay:e,duration:i,easing:r,css:t=>"opacity: "+t*n}}function Fr(t,{delay:e=0,duration:i=400,easing:r=zr,x:n=0,y:s=0,opacity:o=0}={}){const a=getComputedStyle(t),l=+a.opacity,c="none"===a.transform?"":a.transform,u=l*(1-o),[d,h]=Or(n),[m,v]=Or(s);return{delay:e,duration:i,easing:r,css:(t,e)=>`\n\t\t\ttransform: ${c} translate(${(1-t)*d}${h}, ${(1-t)*m}${v});\n\t\t\topacity: ${l-u*e}`}}var Vr=We('<a rel="noopener" href="https://micr.io/" title="Powered by Micrio" aria-label="Micrio homepage"></a>');function Ur(t,e){Te(e,!0);const[i,r]=ir(),n=ye("micrio"),{tour:s,marker:o}=n.state,a=/micr\.io/.test(location.origin)&&self.parent==self?void 0:"_blank";let l,c=j(!1);Gi((()=>n.loading.subscribe((t=>{clearTimeout(l),t?jt(c)||(l=setTimeout((()=>Y(c,!0)),750)):Y(c,!1)}))));let u=J((()=>!!tr(s,"$tour",i)||!!tr(o,"$marker",i)));var d=Ge(),h=ut(d),m=t=>{var e=Vr();let i;xi(e,"target",a),se((t=>i=fi(e,1,"micrio-logo",null,i,t)),[()=>({loading:jt(c)})]),zi(3,e,(()=>Nr),(()=>({duration:200}))),Ye(t,e)};ei(h,(t=>{jt(u)||t(m)})),Ye(t,d),_e(),r()}var Br=We('<a rel="noopener" target="_blank" class="micrio-logo-org"><img alt="Logo" class="micrio-logo-org"></a>');function qr(t,e){Te(e,!0);const[i,r]=ir(),n=ye("micrio"),{tour:s,marker:o,popover:a}=n.state;let l=J((()=>!!tr(s,"$tour",i)||!!tr(o,"$marker",i)||!!tr(a,"$popover",i)));var c=Ge(),u=ut(c),d=t=>{var i=Br(),r=ct(i);se((t=>{xi(i,"href",e.organisation.href??"#"),xi(i,"title",e.organisation.name),xi(i,"aria-label",`${e.organisation.name??""} homepage`),xi(r,"src",t)}),[()=>function(t){if("string"==typeof t)return t;let e=0,i=Math.max(t.width,t.height);for(;i>1024;)e++,i/=2;return t.micrioId&&t.width>1024?"https://r2.micr.io/"+t.micrioId+"/"+e+"/0-0."+(t.isPng?"png":t.isWebP?"webp":"jpg"):t.src}(e.organisation.logo)]),zi(3,i,(()=>Nr),(()=>({duration:200}))),Ye(t,i)};ei(u,(t=>{!jt(l)&&e.organisation.logo&&t(d)})),Ye(t,c),_e(),r()}const Wr={en:{close:"Close",zoomIn:"Zoom in",zoomOut:"Zoom out",fullscreenToggle:"Toggle fullscreen",switchLanguage:"Switch language",share:"Share",audioMute:"Mute audio",audioUnmute:"Unmute audio",closeMarker:"Close this marker",tourStepNext:"Next step",tourStepPrev:"Previous step",tourStop:"Stop this tour",minimize:"Minimize",play:"Play",pause:"Pause",stop:"Stop",subtitlesToggle:"Toggle subtitles",galleryPrev:"Previous image",galleryNext:"Next image",menuToggle:"Toggle menu",waypointFollow:"Go this way"},nl:{close:"Sluit",zoomIn:"Zoom in",zoomOut:"Zoom uit",fullscreenToggle:"Volledig scherm aan / uit",switchLanguage:"Kies taal",share:"Deel",audioMute:"Geluid uit",audioUnmute:"Geluid aan",closeMarker:"Sluit deze marker",tourStepNext:"Volgende stap",tourStepPrev:"Vorige stap",tourStop:"Stop deze tour",minimize:"Minimaliseer",play:"Start",pause:"Pauzeer",stop:"Stop",subtitlesToggle:"Ondertitels aan / uit",galleryPrev:"Vorige afbeelding",galleryNext:"Volgende afbeelding",menuToggle:"Menu openen / sluiten",waypointFollow:"Ga deze richting"}},Xr=Zi(Wr.en),jr={prefix:"fas",iconName:"bars",icon:[448,512,["navicon"],"f0c9","M0 96C0 78.3 14.3 64 32 64l384 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L32 128C14.3 128 0 113.7 0 96zM0 256c0-17.7 14.3-32 32-32l384 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L32 288c-17.7 0-32-14.3-32-32zM448 416c0 17.7-14.3 32-32 32L32 448c-17.7 0-32-14.3-32-32s14.3-32 32-32l384 0c17.7 0 32 14.3 32 32z"]},Gr={prefix:"fas",iconName:"circle-exclamation",icon:[512,512,["exclamation-circle"],"f06a","M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zm0-384c13.3 0 24 10.7 24 24l0 112c0 13.3-10.7 24-24 24s-24-10.7-24-24l0-112c0-13.3 10.7-24 24-24zM224 352a32 32 0 1 1 64 0 32 32 0 1 1 -64 0z"]},Yr={prefix:"fas",iconName:"compress",icon:[448,512,[],"f066","M160 64c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 64-64 0c-17.7 0-32 14.3-32 32s14.3 32 32 32l96 0c17.7 0 32-14.3 32-32l0-96zM32 320c-17.7 0-32 14.3-32 32s14.3 32 32 32l64 0 0 64c0 17.7 14.3 32 32 32s32-14.3 32-32l0-96c0-17.7-14.3-32-32-32l-96 0zM352 64c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 96c0 17.7 14.3 32 32 32l96 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-64 0 0-64zM320 320c-17.7 0-32 14.3-32 32l0 96c0 17.7 14.3 32 32 32s32-14.3 32-32l0-64 64 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-96 0z"]},Hr={prefix:"fas",iconName:"globe",icon:[512,512,[127760],"f0ac","M352 256c0 22.2-1.2 43.6-3.3 64l-185.3 0c-2.2-20.4-3.3-41.8-3.3-64s1.2-43.6 3.3-64l185.3 0c2.2 20.4 3.3 41.8 3.3 64zm28.8-64l123.1 0c5.3 20.5 8.1 41.9 8.1 64s-2.8 43.5-8.1 64l-123.1 0c2.1-20.6 3.2-42 3.2-64s-1.1-43.4-3.2-64zm112.6-32l-116.7 0c-10-63.9-29.8-117.4-55.3-151.6c78.3 20.7 142 77.5 171.9 151.6zm-149.1 0l-176.6 0c6.1-36.4 15.5-68.6 27-94.7c10.5-23.6 22.2-40.7 33.5-51.5C239.4 3.2 248.7 0 256 0s16.6 3.2 27.8 13.8c11.3 10.8 23 27.9 33.5 51.5c11.6 26 20.9 58.2 27 94.7zm-209 0L18.6 160C48.6 85.9 112.2 29.1 190.6 8.4C165.1 42.6 145.3 96.1 135.3 160zM8.1 192l123.1 0c-2.1 20.6-3.2 42-3.2 64s1.1 43.4 3.2 64L8.1 320C2.8 299.5 0 278.1 0 256s2.8-43.5 8.1-64zM194.7 446.6c-11.6-26-20.9-58.2-27-94.6l176.6 0c-6.1 36.4-15.5 68.6-27 94.6c-10.5 23.6-22.2 40.7-33.5 51.5C272.6 508.8 263.3 512 256 512s-16.6-3.2-27.8-13.8c-11.3-10.8-23-27.9-33.5-51.5zM135.3 352c10 63.9 29.8 117.4 55.3 151.6C112.2 482.9 48.6 426.1 18.6 352l116.7 0zm358.1 0c-30 74.1-93.6 130.9-171.9 151.6c25.5-34.2 45.2-87.7 55.3-151.6l116.7 0z"]},Zr={prefix:"fas",iconName:"image",icon:[512,512,[],"f03e","M0 96C0 60.7 28.7 32 64 32l384 0c35.3 0 64 28.7 64 64l0 320c0 35.3-28.7 64-64 64L64 480c-35.3 0-64-28.7-64-64L0 96zM323.8 202.5c-4.5-6.6-11.9-10.5-19.8-10.5s-15.4 3.9-19.8 10.5l-87 127.6L170.7 297c-4.6-5.7-11.5-9-18.7-9s-14.2 3.3-18.7 9l-64 80c-5.8 7.2-6.9 17.1-2.9 25.4s12.4 13.6 21.6 13.6l96 0 32 0 208 0c8.9 0 17.1-4.9 21.2-12.8s3.6-17.4-1.4-24.7l-120-176zM112 192a48 48 0 1 0 0-96 48 48 0 1 0 0 96z"]},Kr={prefix:"fas",iconName:"circle-play",icon:[512,512,[61469,"play-circle"],"f144","M0 256a256 256 0 1 1 512 0A256 256 0 1 1 0 256zM188.3 147.1c-7.6 4.2-12.3 12.3-12.3 20.9l0 176c0 8.7 4.7 16.7 12.3 20.9s16.8 4.1 24.3-.5l144-88c7.1-4.4 11.5-12.1 11.5-20.5s-4.4-16.1-11.5-20.5l-144-88c-7.4-4.5-16.7-4.7-24.3-.5z"]},Jr={prefix:"fas",iconName:"pause",icon:[320,512,[9208],"f04c","M48 64C21.5 64 0 85.5 0 112L0 400c0 26.5 21.5 48 48 48l32 0c26.5 0 48-21.5 48-48l0-288c0-26.5-21.5-48-48-48L48 64zm192 0c-26.5 0-48 21.5-48 48l0 288c0 26.5 21.5 48 48 48l32 0c26.5 0 48-21.5 48-48l0-288c0-26.5-21.5-48-48-48l-32 0z"]},Qr={prefix:"fas",iconName:"layer-group",icon:[576,512,[],"f5fd","M264.5 5.2c14.9-6.9 32.1-6.9 47 0l218.6 101c8.5 3.9 13.9 12.4 13.9 21.8s-5.4 17.9-13.9 21.8l-218.6 101c-14.9 6.9-32.1 6.9-47 0L45.9 149.8C37.4 145.8 32 137.3 32 128s5.4-17.9 13.9-21.8L264.5 5.2zM476.9 209.6l53.2 24.6c8.5 3.9 13.9 12.4 13.9 21.8s-5.4 17.9-13.9 21.8l-218.6 101c-14.9 6.9-32.1 6.9-47 0L45.9 277.8C37.4 273.8 32 265.3 32 256s5.4-17.9 13.9-21.8l53.2-24.6 152 70.2c23.4 10.8 50.4 10.8 73.8 0l152-70.2zm-152 198.2l152-70.2 53.2 24.6c8.5 3.9 13.9 12.4 13.9 21.8s-5.4 17.9-13.9 21.8l-218.6 101c-14.9 6.9-32.1 6.9-47 0L45.9 405.8C37.4 401.8 32 393.3 32 384s5.4-17.9 13.9-21.8l53.2-24.6 152 70.2c23.4 10.8 50.4 10.8 73.8 0z"]},tn={prefix:"fas",iconName:"arrow-up-right-from-square",icon:[512,512,["external-link"],"f08e","M320 0c-17.7 0-32 14.3-32 32s14.3 32 32 32l82.7 0L201.4 265.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L448 109.3l0 82.7c0 17.7 14.3 32 32 32s32-14.3 32-32l0-160c0-17.7-14.3-32-32-32L320 0zM80 32C35.8 32 0 67.8 0 112L0 432c0 44.2 35.8 80 80 80l320 0c44.2 0 80-35.8 80-80l0-112c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 112c0 8.8-7.2 16-16 16L80 448c-8.8 0-16-7.2-16-16l0-320c0-8.8 7.2-16 16-16l112 0c17.7 0 32-14.3 32-32s-14.3-32-32-32L80 32z"]},en={prefix:"fas",iconName:"arrow-right",icon:[448,512,[8594],"f061","M438.6 278.6c12.5-12.5 12.5-32.8 0-45.3l-160-160c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L338.8 224 32 224c-17.7 0-32 14.3-32 32s14.3 32 32 32l306.7 0L233.4 393.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0l160-160z"]},rn={prefix:"fas",iconName:"volume-high",icon:[640,512,[128266,"volume-up"],"f028","M533.6 32.5C598.5 85.2 640 165.8 640 256s-41.5 170.7-106.4 223.5c-10.3 8.4-25.4 6.8-33.8-3.5s-6.8-25.4 3.5-33.8C557.5 398.2 592 331.2 592 256s-34.5-142.2-88.7-186.3c-10.3-8.4-11.8-23.5-3.5-33.8s23.5-11.8 33.8-3.5zM473.1 107c43.2 35.2 70.9 88.9 70.9 149s-27.7 113.8-70.9 149c-10.3 8.4-25.4 6.8-33.8-3.5s-6.8-25.4 3.5-33.8C475.3 341.3 496 301.1 496 256s-20.7-85.3-53.2-111.8c-10.3-8.4-11.8-23.5-3.5-33.8s23.5-11.8 33.8-3.5zm-60.5 74.5C434.1 199.1 448 225.9 448 256s-13.9 56.9-35.4 74.5c-10.3 8.4-25.4 6.8-33.8-3.5s-6.8-25.4 3.5-33.8C393.1 284.4 400 271 400 256s-6.9-28.4-17.7-37.3c-10.3-8.4-11.8-23.5-3.5-33.8s23.5-11.8 33.8-3.5zM301.1 34.8C312.6 40 320 51.4 320 64l0 384c0 12.6-7.4 24-18.9 29.2s-25 3.1-34.4-5.3L131.8 352 64 352c-35.3 0-64-28.7-64-64l0-64c0-35.3 28.7-64 64-64l67.8 0L266.7 40.1c9.4-8.4 22.9-10.4 34.4-5.3z"]},nn={prefix:"fas",iconName:"arrow-left",icon:[448,512,[8592],"f060","M9.4 233.4c-12.5 12.5-12.5 32.8 0 45.3l160 160c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L109.2 288 416 288c17.7 0 32-14.3 32-32s-14.3-32-32-32l-306.7 0L214.6 118.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-160 160z"]},sn={prefix:"fas",iconName:"minus",icon:[448,512,[8211,8722,10134,"subtract"],"f068","M432 256c0 17.7-14.3 32-32 32L48 288c-17.7 0-32-14.3-32-32s14.3-32 32-32l352 0c17.7 0 32 14.3 32 32z"]},on={prefix:"fas",iconName:"ellipsis-vertical",icon:[128,512,["ellipsis-v"],"f142","M64 360a56 56 0 1 0 0 112 56 56 0 1 0 0-112zm0-160a56 56 0 1 0 0 112 56 56 0 1 0 0-112zM120 96A56 56 0 1 0 8 96a56 56 0 1 0 112 0z"]},an={prefix:"fas",iconName:"closed-captioning",icon:[576,512,[],"f20a","M0 96C0 60.7 28.7 32 64 32l448 0c35.3 0 64 28.7 64 64l0 320c0 35.3-28.7 64-64 64L64 480c-35.3 0-64-28.7-64-64L0 96zM200 208c14.2 0 27 6.1 35.8 16c8.8 9.9 24 10.7 33.9 1.9s10.7-24 1.9-33.9c-17.5-19.6-43.1-32-71.5-32c-53 0-96 43-96 96s43 96 96 96c28.4 0 54-12.4 71.5-32c8.8-9.9 8-25-1.9-33.9s-25-8-33.9 1.9c-8.8 9.9-21.6 16-35.8 16c-26.5 0-48-21.5-48-48s21.5-48 48-48zm144 48c0-26.5 21.5-48 48-48c14.2 0 27 6.1 35.8 16c8.8 9.9 24 10.7 33.9 1.9s10.7-24 1.9-33.9c-17.5-19.6-43.1-32-71.5-32c-53 0-96 43-96 96s43 96 96 96c28.4 0 54-12.4 71.5-32c8.8-9.9 8-25-1.9-33.9s-25-8-33.9 1.9c-8.8 9.9-21.6 16-35.8 16c-26.5 0-48-21.5-48-48z"]},ln={prefix:"fas",iconName:"arrow-down",icon:[384,512,[8595],"f063","M169.4 470.6c12.5 12.5 32.8 12.5 45.3 0l160-160c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L224 370.8 224 64c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 306.7L54.6 265.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l160 160z"]},cn={prefix:"fas",iconName:"link",icon:[640,512,[128279,"chain"],"f0c1","M579.8 267.7c56.5-56.5 56.5-148 0-204.5c-50-50-128.8-56.5-186.3-15.4l-1.6 1.1c-14.4 10.3-17.7 30.3-7.4 44.6s30.3 17.7 44.6 7.4l1.6-1.1c32.1-22.9 76-19.3 103.8 8.6c31.5 31.5 31.5 82.5 0 114L422.3 334.8c-31.5 31.5-82.5 31.5-114 0c-27.9-27.9-31.5-71.8-8.6-103.8l1.1-1.6c10.3-14.4 6.9-34.4-7.4-44.6s-34.4-6.9-44.6 7.4l-1.1 1.6C206.5 251.2 213 330 263 380c56.5 56.5 148 56.5 204.5 0L579.8 267.7zM60.2 244.3c-56.5 56.5-56.5 148 0 204.5c50 50 128.8 56.5 186.3 15.4l1.6-1.1c14.4-10.3 17.7-30.3 7.4-44.6s-30.3-17.7-44.6-7.4l-1.6 1.1c-32.1 22.9-76 19.3-103.8-8.6C74 372 74 321 105.5 289.5L217.7 177.2c31.5-31.5 82.5-31.5 114 0c27.9 27.9 31.5 71.8 8.6 103.9l-1.1 1.6c-10.3 14.4-6.9 34.4 7.4 44.6s34.4 6.9 44.6-7.4l1.1-1.6C433.5 260.8 427 182 377 132c-56.5-56.5-148-56.5-204.5 0L60.2 244.3z"]},un={prefix:"fas",iconName:"play",icon:[384,512,[9654],"f04b","M73 39c-14.8-9.1-33.4-9.4-48.5-.9S0 62.6 0 80L0 432c0 17.4 9.4 33.4 24.5 41.9s33.7 8.1 48.5-.9L361 297c14.3-8.7 23-24.2 23-41s-8.7-32.2-23-41L73 39z"]},dn={prefix:"fas",iconName:"chevron-down",icon:[512,512,[],"f078","M233.4 406.6c12.5 12.5 32.8 12.5 45.3 0l192-192c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L256 338.7 86.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l192 192z"]},hn={prefix:"fas",iconName:"arrow-up",icon:[384,512,[8593],"f062","M214.6 41.4c-12.5-12.5-32.8-12.5-45.3 0l-160 160c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L160 141.2 160 448c0 17.7 14.3 32 32 32s32-14.3 32-32l0-306.7L329.4 246.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3l-160-160z"]},mn={prefix:"fas",iconName:"volume-xmark",icon:[576,512,["volume-mute","volume-times"],"f6a9","M301.1 34.8C312.6 40 320 51.4 320 64l0 384c0 12.6-7.4 24-18.9 29.2s-25 3.1-34.4-5.3L131.8 352 64 352c-35.3 0-64-28.7-64-64l0-64c0-35.3 28.7-64 64-64l67.8 0L266.7 40.1c9.4-8.4 22.9-10.4 34.4-5.3zM425 167l55 55 55-55c9.4-9.4 24.6-9.4 33.9 0s9.4 24.6 0 33.9l-55 55 55 55c9.4 9.4 9.4 24.6 0 33.9s-24.6 9.4-33.9 0l-55-55-55 55c-9.4 9.4-24.6 9.4-33.9 0s-9.4-24.6 0-33.9l55-55-55-55c-9.4-9.4-9.4-24.6 0-33.9s24.6-9.4 33.9 0z"]},vn={prefix:"fas",iconName:"plus",icon:[448,512,[10133,61543,"add"],"2b","M256 80c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 144L48 224c-17.7 0-32 14.3-32 32s14.3 32 32 32l144 0 0 144c0 17.7 14.3 32 32 32s32-14.3 32-32l0-144 144 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-144 0 0-144z"]},pn={prefix:"fas",iconName:"expand",icon:[448,512,[],"f065","M32 32C14.3 32 0 46.3 0 64l0 96c0 17.7 14.3 32 32 32s32-14.3 32-32l0-64 64 0c17.7 0 32-14.3 32-32s-14.3-32-32-32L32 32zM64 352c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 96c0 17.7 14.3 32 32 32l96 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-64 0 0-64zM320 32c-17.7 0-32 14.3-32 32s14.3 32 32 32l64 0 0 64c0 17.7 14.3 32 32 32s32-14.3 32-32l0-96c0-17.7-14.3-32-32-32l-96 0zM448 352c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 64-64 0c-17.7 0-32 14.3-32 32s14.3 32 32 32l96 0c17.7 0 32-14.3 32-32l0-96z"]},fn={prefix:"fas",iconName:"xmark",icon:[384,512,[128473,10005,10006,10060,215,"close","multiply","remove","times"],"f00d","M342.6 150.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192 210.7 86.6 105.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L146.7 256 41.4 361.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L192 301.3 297.4 406.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L237.3 256 342.6 150.6z"]},gn={prefix:"fas",iconName:"share",icon:[512,512,["mail-forward"],"f064","M307 34.8c-11.5 5.1-19 16.6-19 29.2l0 64-112 0C78.8 128 0 206.8 0 304C0 417.3 81.5 467.9 100.2 478.1c2.5 1.4 5.3 1.9 8.1 1.9c10.9 0 19.7-8.9 19.7-19.7c0-7.5-4.3-14.4-9.8-19.5C108.8 431.9 96 414.4 96 384c0-53 43-96 96-96l96 0 0 64c0 12.6 7.4 24.1 19 29.2s25 3 34.4-5.4l160-144c6.7-6.1 10.6-14.7 10.6-23.8s-3.8-17.7-10.6-23.8l-160-144c-9.4-8.5-22.9-10.6-34.4-5.4z"]},wn={prefix:"fas",iconName:"video",icon:[576,512,["video-camera"],"f03d","M0 128C0 92.7 28.7 64 64 64l256 0c35.3 0 64 28.7 64 64l0 256c0 35.3-28.7 64-64 64L64 448c-35.3 0-64-28.7-64-64L0 128zM559.1 99.8c10.4 5.6 16.9 16.4 16.9 28.2l0 256c0 11.8-6.5 22.6-16.9 28.2s-23 5-32.9-1.6l-96-64L416 337.1l0-17.1 0-128 0-17.1 14.2-9.5 96-64c9.8-6.5 22.4-7.2 32.9-1.6z"]};function bn(t,e){t.style.fontSize=e&&"lg"!==e&&"sm"!==e&&"xs"!==e?e.replace("x","em"):""}U=!0;var yn=Xe('<title class="micrio-fa"> </title>'),kn=Xe('<path class="micrio-fa"></path>'),Tn=Xe('<path class="micrio-fa"></path><path class="micrio-fa"></path>',1),_n=Xe('<svg aria-hidden="true" role="img" xmlns="http://www.w3.org/2000/svg"><!><g class="micrio-fa"><g class="micrio-fa"><!></g></g></svg>');function xn(t,e){Te(e,!1);const i=G(),r=G();let n=or(e,"class",24,(()=>{})),s=or(e,"id",24,(()=>{})),o=or(e,"style",24,(()=>{})),a=or(e,"icon",8),c=or(e,"title",24,(()=>{})),d=or(e,"size",24,(()=>{})),h=or(e,"color",24,(()=>{})),m=or(e,"fw",8,!1),v=or(e,"pull",24,(()=>{})),p=or(e,"scale",8,1),f=or(e,"translateX",8,0),g=or(e,"translateY",8,0),w=or(e,"rotate",24,(()=>{})),b=or(e,"flip",24,(()=>{})),y=or(e,"spin",8,!1),k=or(e,"pulse",8,!1),T=or(e,"primaryColor",8,""),_=or(e,"secondaryColor",8,""),x=or(e,"primaryOpacity",8,1),E=or(e,"secondaryOpacity",8,.4),$=or(e,"swapOpacity",8,!1),A=G();var S;re((()=>(jt(A),Zt(d()),bn)),(()=>{jt(A)&&d()&&bn(jt(A),d())})),re((()=>Zt(a())),(()=>{Y(i,a()&&a().icon||[0,0,"",[],""])})),re((()=>(Zt(p()),Zt(f()),Zt(g()),Zt(w()),Zt(b()))),(()=>{Y(r,function(t,e,i,r,n,s=1,o="",a=""){let l=1,c=1;n&&("horizontal"==n?l=-1:"vertical"==n?c=-1:l=c=-1),"string"==typeof t&&(t=parseFloat(t)),"string"==typeof e&&(e=parseFloat(e)),"string"==typeof i&&(i=parseFloat(i));let u=`translate(${e*s}${o},${i*s}${o}) scale(${l*t},${c*t})`;return r&&(u+=` rotate(${r}${a})`),u}(p(),f(),g(),w(),b(),512))})),S=we,ne((()=>{if(jt(S.l.r2)){for(var t of S.l.r1){var e=t.effect;e.f&l&&Ht(e,u),Ct(e)&&Ft(e),t.ran=!1}S.l.r2.v=!1}})),Xi();var I=Ge(),M=ut(I),L=t=>{var e=_n();let a;var l=ct(e),u=t=>{var e=yn(),i=ct(e);se((()=>Ke(i,c()))),Ye(t,e)};ei(l,(t=>{c()&&t(u)}));var p=dt(l),f=ct(p),g=ct(f),w=t=>{var e=kn();se((()=>{xi(e,"d",jt(i)[4]),xi(e,"fill",h()||T()||"currentColor"),xi(e,"transform",`translate(${jt(i)[0]/-2} ${jt(i)[1]/-2})`)})),Ye(t,e)},b=t=>{var e=Tn(),r=ut(e),n=dt(r);se((()=>{xi(r,"d",jt(i)[4][0]),xi(r,"fill",_()||h()||"currentColor"),xi(r,"fill-opacity",0!=$()?x():E()),xi(r,"transform",`translate(${jt(i)[0]/-2} ${jt(i)[1]/-2})`),xi(n,"d",jt(i)[4][1]),xi(n,"fill",T()||h()||"currentColor"),xi(n,"fill-opacity",0!=$()?E():x()),xi(n,"transform",`translate(${jt(i)[0]/-2} ${jt(i)[1]/-2})`)})),Ye(t,e)};ei(g,(t=>{"string"==typeof jt(i)[4]?t(w):t(b,!1)})),qi(e,(t=>Y(A,t)),(()=>jt(A))),se((t=>{xi(e,"id",s()),a=fi(e,0,`svelte-fa svelte-fa-base ${n()??""}`,"micrio-fa",a,t),wi(e,o()),xi(e,"viewBox",`0 0 ${jt(i)[0]??""} ${jt(i)[1]??""}`),xi(p,"transform",`translate(${jt(i)[0]/2} ${jt(i)[1]/2})`),xi(p,"transform-origin",jt(i)[0]/4+" 0"),xi(f,"transform",jt(r))}),[()=>({pulse:k(),"svelte-fa-size-lg":"lg"===d(),"svelte-fa-size-sm":"sm"===d(),"svelte-fa-size-xs":"xs"===d(),"svelte-fa-fw":m(),"svelte-fa-pull-left":"left"===v(),"svelte-fa-pull-right":"right"===v(),spin:y()})],Q),Ye(t,e)};ei(M,(t=>{jt(i)[4]&&t(L)})),Ye(t,I),_e()}function En(t,e){var i,r;Te(e,!0);let n=or(e,"style",3,void 0);const s=ye("micrio"),o="chevron-down"==e.name||"link-ext"==e.name,a=null==(r=null==(i=s.defaultSettings)?void 0:i.ui)?void 0:r.icons;let l=J((()=>a&&("zoom-in"==e.name?a.zoomIn:"zoom-out"==e.name?a.zoomOut:"maximize"==e.name?a.fullscreenEnter:"minimize"==e.name?a.fullscreenLeave:"close"==e.name?a.close:"arrow-right"==e.name?a.next:"arrow-left"==e.name?a.prev:"arrow-up"==e.name?a.up:"arrow-down"==e.name?a.down:"play"==e.name?a.play:"pause"==e.name?a.pause:"subtitles"==e.name?a.subtitles:"subtitles-off"==e.name?a.subtitlesOff:"volume-off"==e.name?a.muted:"volume-up"==e.name?a.unmuted:null)));const c=new Map([["play",un],["pause",Jr],["close",fn],["play-filled",Kr],["a11y",Hr],["menu",jr],["zoom-in",vn],["zoom-out",sn],["maximize",pn],["minimize",Yr],["volume-off",mn],["volume-up",rn],["subtitles",an],["subtitles-off",an],["arrow-left",nn],["arrow-up",hn],["arrow-right",en],["arrow-down",ln],["video",wn],["audio",rn],["image",Zr],["share",gn],["error",Gr],["chevron-down",dn],["link",cn],["link-ext",tn],["ellipsis-vertical",on]]);let u=J((()=>c.get(e.name)));var d=Ge(),h=ut(d),m=t=>{var e=Ge();li(ut(e),(()=>jt(l))),Ye(t,e)},v=(t,e)=>{var i=t=>{xn(t,{get icon(){return jt(u)},size:o?"xs":"sm",get style(){return n()}})};ei(t,(t=>{jt(u)&&t(i)}),e)};ei(h,(t=>{jt(l)?t(m):t(v,!1)})),Ye(t,d),_e()}const $n=Zi(void 0),An=()=>$n.set(void 0);let Sn=!1;$n.subscribe((t=>{t?Sn||window.addEventListener("click",An):Sn&&window.removeEventListener("click",An),Sn=!!t}));var In=We('<a class="micrio-menu-action micrio-menu"><strong class="micrio-menu"> <!></strong></a>'),Mn=We('<button class="micrio-menu-action micrio-menu" type="button"><!> <strong class="micrio-menu"> <!></strong></button>'),Ln=We('<div class="items micrio-menu"></div>'),Pn=We("<menu><!> <!></menu>");function Cn(t,e){Te(e,!0);const[i,r]=ir(),n=()=>tr($n,"$opened",i);let s=or(e,"menu",15),o=or(e,"originalId",3,null);const a=ye("micrio"),{events:l,state:c,_lang:u}=a;let d=j(void 0);let h=J((()=>{return t=s(),e=tr(u,"$_lang",i),(null==(r=t.i18n)?void 0:r[e])??t;var t,e,r}));function m(t){var i;s().link||t.preventDefault(),s().action&&s().action();const r=!!(jt(p)||s().action||s().link);$n.set(r?void 0:s()),r&&(null==(i=e.onclose)||i.call(e))}Gi((()=>{var t,e,i,r;(null==(t=jt(h))?void 0:t.title)||1!=(null==(e=s().children)?void 0:e.length)||s(s().children[0]),s().action||(s().markerId?s(s().action=()=>{var t,e;o()&&(null==(t=a.$current)?void 0:t.id)!=o()&&a.open(o()),null==(e=a.$current)||e.state.marker.set(s().markerId)},!0):((null==(i=jt(h))?void 0:i.content)||(null==(r=jt(h))?void 0:r.embed)||s().image)&&s(s().action=()=>{l.dispatch("page-open",s()),c.popover.set({contentPage:s()})},!0)),s(s()._button=jt(d),!0)}));const v=t=>{var e;return t==n()||!!(null==(e=t.children)?void 0:e.some(v))};let p=J((()=>n()&&v(s())));var f=Pn();let g;var w=ct(f),b=t=>{var e=In();e.__click=m;var i=ct(e),r=ct(i),n=dt(r);const o=J((()=>s().linkTargetBlank?"link-ext":"link"));En(n,{style:"opacity:.75",get name(){return jt(o)}}),se((()=>{var t;xi(e,"href",s().link),xi(e,"target",s().linkTargetBlank?"_blank":void 0),Ke(r,`${(null==(t=jt(h))?void 0:t.title)??"(Unknown)"} `)})),Ye(t,e)},y=t=>{var e=Mn();e.__click=m;var i=ct(e),r=t=>{xn(t,{get icon(){return s().icon},style:"margin-right:10px;"})};ei(i,(t=>{s().icon&&t(r)}));var n=ct(dt(i,2)),o=dt(n),a=t=>{En(t,{name:"chevron-down"})};ei(o,(t=>{s().children&&s().children.length&&t(a)})),qi(e,(t=>Y(d,t)),(()=>jt(d))),se((()=>{var t;return Ke(n,`${(null==(t=jt(h))?void 0:t.title)??"(Unknown)"} `)})),Ye(t,e)};ei(w,(t=>{s().link?t(b):t(y,!1)}));var k=dt(w,2),T=t=>{var e=Ln();ri(e,23,(()=>s().children),((t,e)=>e+t.id),((t,e)=>{Cn(t,{get menu(){return jt(e)},get originalId(){return o()},onclose:An})})),Ye(t,e)};ei(k,(t=>{s().children&&s().children.length&&t(T)})),se(((t,e)=>{xi(f,"data-title",t),g=fi(f,1,"micrio-menu",null,g,e)}),[()=>{var t,e;return null==(e=null==(t=jt(h))?void 0:t.title)?void 0:e.toLowerCase()},()=>({opened:jt(p)})]),Ye(t,f),_e(),r()}Ve(["click"]);var Dn=We('<img alt="Icon" class="micrio-button">'),Rn=We("<!><!>",1);function zn(t,e){Te(e,!0);let i=or(e,"type",3,void 0),r=or(e,"icon",3,void 0),n=or(e,"title",3,null),s=or(e,"disabled",3,!1),o=or(e,"active",3,!1),a=or(e,"className",3,""),l=or(e,"href",3,void 0),c=or(e,"blankTarget",3,!1),u=or(e,"noClick",3,!1);var d=Ge();ui(ut(d),(()=>l()?"a":"button"),0,((t,d)=>{var h=t=>{var i;return null==(i=e.onclick)?void 0:i.call(e,t)},m=t=>{var i;return null==(i=e.onfocus)?void 0:i.call(e,t)},v=t=>{var i;return null==(i=e.onpointerdown)?void 0:i.call(e,t)};let p;se((e=>p=$i(t,p,{href:l(),target:c()?"_blank":void 0,disabled:!!s()||void 0,title:n(),"aria-label":n(),role:l()?void 0:"button",tabindex:l()?void 0:0,class:`micrio-button ${i()??""} ${a()??""}`,onclick:h,onfocus:m,onpointerdown:v,[bi]:e},"micrio-button")),[()=>({active:o(),"no-click":u()})]);var f=Rn(),g=ut(f),w=t=>{En(t,{get name(){return i()}})},b=(t,e)=>{var i=t=>{var e=Dn();se((()=>xi(e,"src",r().src))),Ye(t,e)};ei(t,(t=>{r()&&t(i)}),e)};ei(g,(t=>{i()?t(w):t(b,!1)})),ci(dt(g),(()=>e.children??M)),Ye(d,f)})),Ye(t,d),_e()}var On=We("<menu><!> <!> <!></menu> <!>",1);function Nn(t,e){Te(e,!0);const[i,r]=ir(),n=()=>tr(c,"$current",i),s=()=>tr(u,"$_lang",i);let o=j(void 0);const a=ye("micrio"),{state:l,current:c,_lang:u,spaceData:d}=a,{tour:h,marker:m,popover:v}=l;let p=j(!1),f=j(!1);const g=n().id;let w=j(void 0),b=j(window.innerWidth<=500);const y=()=>Y(b,window.innerWidth<=500),k=()=>{jt(b)&&Y(p,!1)};let T=J((()=>!!tr(h,"$tour",i)||!!tr(m,"$marker",i)||!!tr(v,"$popover",i))),_=J((()=>{var t;return((null==(t=jt(o))?void 0:t.markerTours)??[]).concat((null==d?void 0:d.markerTours)??[])})),x=J((()=>{var t;return(null==(t=jt(_))?void 0:t.length)>0})),E=J((()=>{var t,e,i;return(null==(t=jt(o))?void 0:t.tours)&&(null==(i=null==(e=jt(o))?void 0:e.tours)?void 0:i.length)>0})),$=J((()=>jt(x)&&jt(E))),A=J((()=>{var t;return!((null==(t=jt(w))?void 0:t.length)||jt(x)||jt(E))}));const S=[],I=(t,e)=>{var i,r;return("title"in t?t.title:null==(r=null==(i=t.i18n)?void 0:i[e])?void 0:r.title)??"(Untitled)"};Gi((()=>{const t=a.current.subscribe((t=>{var e;if(t){for(;S.length;)null==(e=S.shift())||e();br(t.info).then((()=>Y(f,!t.$settings.noLogo))),S.push(t.data.subscribe((t=>{Y(o,t,!0),Xt().then((()=>{var e,i,r;if(!(null==t?void 0:t.pages))return;jt(w)||Y(w,null==(e=t.pages)?void 0:e.filter((t=>{var e;return!(null==(e=t.id)?void 0:e.startsWith("_"))})),!0);const n=null==(i=t.pages)?void 0:i.filter((t=>{var e;return null==(e=t.id)?void 0:e.startsWith("_")}));n.length&&Y(w,[...(null==(r=jt(w))?void 0:r.filter((t=>{var e;return!(null==(e=t.id)?void 0:e.startsWith("_"))})))??[],...n],!0)}))})))}}));return window.addEventListener("resize",y),()=>{var e;for(window.removeEventListener("resize",y);S.length;)null==(e=S.shift())||e();t()}}));var M=Ge(),L=ut(M),P=t=>{var e=On(),r=ut(e);let l;var c=ct(r),u=t=>{var e=Ge();ri(ut(e),17,(()=>jt(w)),(t=>t.id),((t,e)=>{Cn(t,{get menu(){return jt(e)},originalId:g,onclose:k})})),Ye(t,e)};ei(c,(t=>{jt(w)&&t(u)}));var d=dt(c,2),m=t=>{const e=J((()=>({id:cr(),i18n:{[s()]:{title:jt($)?"Marker tours":"Tours"}},children:jt(_).map((t=>({id:cr(),i18n:{[s()]:{title:I(t,s())}},action:()=>{t.initialStep=0,h.set(t)}})))})));Cn(t,{onclose:k,get menu(){return jt(e)}})};ei(d,(t=>{jt(x)&&t(m)}));var v=dt(d,2),y=t=>{const e=J((()=>({id:cr(),i18n:{[s()]:{title:jt($)?"Video tours":"Tours"}},children:jt(o)&&jt(o).tours?jt(o).tours.map((t=>({id:cr(),i18n:{[s()]:{title:I(t,s())}},action:()=>{n()&&n().id!=g&&a.open(g),h.set(t)}}))):[]})));Cn(t,{onclose:k,get menu(){return jt(e)}})};ei(v,(t=>{jt(E)&&t(y)}));var A=dt(r,2),S=t=>{const e=J((()=>jt(p)?"close":"ellipsis-vertical")),r=J((()=>"toggle transparent"+(jt(f)?" indent":"")));zn(t,{get title(){return tr(Xr,"$i18n",i).menuToggle},get type(){return jt(e)},get className(){return jt(r)},onclick:()=>Y(p,!jt(p))})};ei(A,(t=>{jt(b)&&t(S)})),se((t=>l=fi(r,1,"micrio-toolbar micrio-toolbar",null,l,t)),[()=>({shown:!jt(T)&&jt(p),indent:jt(f)})]),zi(3,r,(()=>Nr),(()=>({duration:200}))),Ye(t,e)};ei(L,(t=>{jt(A)||jt(T)||t(P)})),Ye(t,M),_e(),r()}var Fn=We("<canvas></canvas>");function Vn(t,e){Te(e,!0);const[i,r]=ir(),n=ye("micrio"),{current:s}=n,o=n.canvas.viewport,a=e.image.$info,l=e.image.camera,c=e.image.$settings,u=c.minimapWidth??200,d=c.minimapHeight??160,h=!c.alwaysShowMinimap,m=!!c.noControls,v=a.width/a.height,p=u/v>d?Math.round(d*v):u,f=u/v<=d?Math.round(u/v):d;let g,w=j(void 0),b=j(!1),y=j(B(!a.is360&&l.isZoomedOut()));function k(t){if(t&&g){if(S(),g.clearRect(0,0,p,f),e.image.thumbSrc?(g.globalCompositeOperation="source-over",g.fillStyle="rgba(0,0,0,.5)",g.fillRect(0,0,p,f),g.globalAlpha=1,g.globalCompositeOperation="destination-out"):(g.fillStyle="rgba(0,0,0,.5)",g.fillRect(0,0,p,f)),g.beginPath(),g.fillStyle="white",a.is360){const t=function(){const t=[],e=o.width*o.ratio,i=o.height*o.ratio,r=l.getCoo(e/2,i/2).slice(0),n=[];for(let s=0;s<8;s++)n.push(s/8*e,0);for(let s=0;s<8;s++)n.push(e,s/8*i);for(let s=0;s<8;s++)n.push((1-s/8)*e,i);for(let s=0;s<8;s++)n.push(0,(1-s/8)*i);for(let s=0;s<n.length;s+=2){const e=l.getCoo(n[s],n[s+1]);(s>40||s<8)&&e[0]>r[0]?e[0]-=1:s>8&&s<40&&e[0]<r[0]&&(e[0]+=1),t.push(e[0],e[1])}return t}();g.moveTo(t[0]*p,t[1]*f);for(let e=2;e<t.length;e+=2)g.lineTo(t[e]*p,t[e+1]*f);g.closePath()}else Y(y,l.isZoomedOut(),!0),g.rect(Math.floor(t[0]*p),Math.floor(t[1]*f),Math.ceil((t[2]-t[0])*p),Math.ceil((t[3]-t[1])*f));e.image.thumbSrc&&(g.fill(),g.globalCompositeOperation="source-over"),g.stroke()}}const T=-1!=navigator.userAgent.indexOf("Firefox");let _,x,E=j(!1);function $(t){if(_){const e=Math.max(0,Math.min(1,(t.clientX-_.left)/_.width)),i=Math.max(0,Math.min(1,(t.clientY-_.top)/_.height));l.setCoo(e,i)}}function A(){window.removeEventListener("mousemove",$),window.removeEventListener("mouseup",A),Y(E,!1)}function S(){Y(b,!1),clearTimeout(x),x=setTimeout((()=>Y(b,!0)),2500)}const I=.5-e.image.camera.trueNorth,M=self.crossOriginIsolated;let L=j(B(M?void 0:e.image.thumbSrc));const P={passive:!0};let C=j(!1);Gi((()=>{let t;g=jt(w).getContext("2d"),g&&(g.lineWidth=1,g.strokeStyle="white"),M&&e.image.thumbSrc&&fetch(e.image.thumbSrc).then((t=>t.blob())).then((e=>Y(L,t=URL.createObjectURL(e),!0))),n.canvas.element.addEventListener("mousemove",S,P);const i=e.image.state.view.subscribe(k);return setTimeout((()=>Y(C,!0)),10),()=>{t&&URL.revokeObjectURL(t),n.canvas.element.removeEventListener("mousemove",S,P),A(),i()}}));let D=J((()=>jt(L)?`background-image: url('${jt(L)}')`+(0!=I?`;background-position-x:${p*I}px`:""):null));var R=Fn();let z;xi(R,"width",p),xi(R,"height",f),R.__mousedown=function(t){0==t.button&&(window.addEventListener("mousemove",$),window.addEventListener("mouseup",A),_=jt(w).getClientRects()[0],$(t),Y(E,!0))},qi(R,(t=>Y(w,t)),(()=>jt(w))),se((t=>{wi(R,jt(D)),z=fi(R,1,"micrio-minimap",null,z,t)}),[()=>({hidden:!jt(C)||tr(s,"$current",i)!=e.image||h&&(jt(y)||jt(b)),dragging:jt(E),controls:!m})]),Fe("wheel",R,(function(t){l.zoom(t.deltaY*(T?50:1))})),Ye(t,R),_e(),r()}Ve(["mousedown"]);const Un=(null==navigator?void 0:navigator.language)??"en-EN",Bn="Intl"in self&&Intl.DisplayNames?new Intl.DisplayNames([Un],{type:"language"}):void 0,qn=["ar","ar-AE","ar-BH","ar-DJ","ar-DZ","ar-EG","ar-IQ","ar-JO","ar-KW","ar-LB","ar-LY","ar-MA","ar-OM","ar-QA","ar-SA","ar-SD","ar-SY","ar-TN","ar-YE","dv","dv-MV","fa","fa-AF","fa-IR","he","he-IL","iw","iw-PS","kd","ku","ku-IQ","ku-IR","ku-SY","ku-TR","pk-PK","ps","ps-AF","sd","sd-PK","syr-SY","ug","ug-CN","ur","ur-IN","ur-PK","yi","yi-IL","yi-US"];var Wn=We("<div><!></div>");function Xn(t,e){let i=or(e,"className",3,"");var r=Wn();ci(ct(r),(()=>e.children??M)),se((()=>fi(r,1,hi(i()),"micrio-button-group"))),Ye(t,r)}function jn(t,e){Te(e,!0);const[i,r]=ir(),n="requestFullscreen"in e.el,s="webkitRequestFullscreen"in e.el,o=ye("micrio"),a=()=>n?document.fullscreenElement:document.webkitFullscreenElement??null;let l=j(a()===e.el);const c=n||s&&!a(),u=()=>new Promise((t=>setTimeout(t,500)));let d;function h(){jt(l)?async function(){n?(await document.exitFullscreen().then(u),d&&d instanceof HTMLElement&&d.requestFullscreen(),d=void 0):"webkitExitFullscreen"in document&&document.webkitExitFullscreen()}():async function(){n?(d=a(),mr.safari&&d&&await document.exitFullscreen().then(u),e.el.requestFullscreen()):"webkitRequestFullscreen"in e.el&&e.el.webkitRequestFullscreen()}()}const m=e.el==o&&!o.events.scrollHooked,v=()=>{Y(l,a()===e.el),m&&(jt(l)?o.events.hookScroll():o.events.unhookScroll())};c&&Gi((()=>{const t=n?"fullscreenchange":"webkitfullscreenchange";return document.addEventListener(t,v),()=>document.removeEventListener(t,v)}));var p=Ge(),f=ut(p),g=t=>{const e=J((()=>jt(l)?"minimize":"maximize"));zn(t,{get type(){return jt(e)},get title(){return tr(Xr,"$i18n",i).fullscreenToggle},onclick:h})};ei(f,(t=>{c&&t(g)})),Ye(t,p),_e(),r()}var Gn=We("<!> <!>",1);function Yn(t,e){Te(e,!0);const[i,r]=ir(),n=()=>tr(Xr,"$i18n",i);let s=or(e,"image",15,void 0);const o=ye("micrio");let a=j(!1),l=j(!1),c=j(!1);const u=()=>{o.events.clicked=!0},d=()=>{var t;u(),null==(t=s())||t.camera.zoomIn().then((()=>o.events.clicked=!1))},h=()=>{var t;u(),null==(t=s())||t.camera.zoomOut().then((()=>o.events.clicked=!1))};function m(){var t,e;Y(a,(null==(t=s())?void 0:t.camera.isZoomedIn())??!0,!0),Y(l,(null==(e=s())?void 0:e.camera.isZoomedOut(!0))??!0,!0)}let v,p;Gi((()=>(s()?v=s().state.view.subscribe(m):p=o.current.subscribe((t=>{v&&(v(),v=void 0),Y(c,!0),s(t)?br(t.info).then((()=>{s()&&(v=s().state.view.subscribe(m)),Y(c,!1)})):Y(c,!1)})),()=>{p&&p(),v&&v()})));var f=Ge(),g=ut(f),w=t=>{var e=Gn(),i=ut(e);const r=J((()=>jt(c)||jt(a)));zn(i,{type:"zoom-in",get title(){return n().zoomIn},get disabled(){return jt(r)},onclick:d});var s=dt(i,2);const o=J((()=>jt(c)||jt(l)));zn(s,{type:"zoom-out",get title(){return n().zoomOut},get disabled(){return jt(o)},onclick:h}),Ye(t,e)};ei(g,(t=>{jt(a)&&jt(l)||t(w)})),Ye(t,f),_e(),r()}var Hn=We('<menu class="popout micrio-controls"><!> <!></menu>'),Zn=We("<!> <!>",1),Kn=We("<aside><!></aside>"),Jn=We('<aside class="micrio-controls"><!> <!> <!> <!></aside> <!>',1);function Qn(t,e){Te(e,!0);const[i,r]=ir(),n=()=>tr(m,"$current",i),s=()=>tr(jt(k),"$info",i),o=()=>tr(f,"$_lang",i),a=()=>tr(g,"$tour",i),l=()=>tr(b,"$zoom",i),c=()=>tr(p,"$isMuted",i),u=()=>tr(Xr,"$i18n",i);let d=or(e,"hasAudio",3,!1);const h=B(ye("micrio")),{current:m,state:v,isMuted:p,_lang:f}=h,g=v.tour,{controls:w,zoom:b,hidden:y}=h.state.ui;let k=J((()=>{var t;return null==(t=n())?void 0:t.info})),T=J((()=>{var t;return s()&&n()?n().isV5?Object.keys(s().revision??{[o()]:0}):(null==(t="cultures"in s()?s().cultures:"")?void 0:t.split(","))??[]:[]})),_=J((()=>a()&&"steps"in a()&&a().isSerialTour));function x(){var t,e,i;if(navigator.share&&(null==(t=n())?void 0:t.$info)){const t=n().$data?(null==(e=n().$data)?void 0:e.i18n)?n().$data.i18n[o()]:n().$data:void 0;navigator.share({title:null==(i=n().$info)?void 0:i.title,text:(null==t?void 0:t.description)||`${n().$info.width} x ${n().$info.height} | Micrio`,url:location.href})}}let E=j(null),$=j(!1);function A(t){const e=t.detail;Y($,h.canvas.viewport.portrait,!0),e.opts.isPassive||Y(E,e,!0)}function S(){Y(E,null)}let I=j(!1),M=j(!1),L=j(!1);function P(t){var e,i;b.set(!t.noZoom),w.set(!t.noControls),Y(I,!!(null==(i=null==(e=t.ui)?void 0:e.controls)?void 0:i.cultureSwitch)),Y(M,!!t.social),Y(L,!!t.fullscreen)}n()&&P(n().$settings),Gi((()=>{let t;h.addEventListener("splitscreen-start",A),h.addEventListener("splitscreen-stop",S);const e=h.current.subscribe((e=>{e&&br(e.info).then((i=>{!i||a()&&"steps"in a()||(null==t||t(),t=e.settings.subscribe(P))}))}));return()=>{h.removeEventListener("splitscreen-start",A),h.removeEventListener("splitscreen-stop",S),null==t||t(),e()}}));let C=J((()=>"micrioAudioContext"in window||d())),D=J((()=>jt(I)&&jt(T).length>1)),R=J((()=>jt(M)&&"share"in navigator)),z=J((()=>jt(L)&&!jt(_))),O=J((()=>tr(w,"$controls",i)&&!tr(y,"$hidden",i)&&(jt(C)||jt(D)||jt(R)||l()||jt(z))));var N=Ge(),F=ut(N),V=t=>{var e=Jn(),i=ut(e),r=ct(i),n=t=>{const e=J((()=>c()?"volume-off":"volume-up")),i=J((()=>c()?u().audioUnmute:u().audioMute));zn(t,{get type(){return jt(e)},get title(){return jt(i)},onclick:()=>p.set(!c())})};ei(r,(t=>{jt(C)&&t(n)}));var s=dt(r,2),a=t=>{var e=Hn(),i=ct(e);zn(i,{get title(){return u().switchLanguage},type:"a11y"}),ri(dt(i,2),17,(()=>jt(T)),ii,((t,e)=>{const i=J((()=>(null==Bn?void 0:Bn.of(jt(e)))??jt(e))),r=J((()=>jt(e)==o()));zn(t,{onclick:()=>h.lang=jt(e),get title(){return jt(i)},get active(){return jt(r)},children:(t,i)=>{var r=je();se((t=>Ke(r,t)),[()=>jt(e).toUpperCase()]),Ye(t,r)},$$slots:{default:!0}})})),Ye(t,e)};ei(s,(t=>{jt(D)&&t(a)}));var d=dt(s,2),m=t=>{zn(t,{type:"share",get title(){return u().share},onclick:x})};ei(d,(t=>{jt(R)&&t(m)})),Xn(dt(d,2),{children:(t,e)=>{var i=Zn(),r=ut(i),n=t=>{var e=Ge(),i=ut(e),r=t=>{Yn(t,{get image(){return jt(E)}})},n=t=>{Yn(t,{})};ei(i,(t=>{jt(E)?t(r):t(n,!1)})),Ye(t,e)};ei(r,(t=>{l()&&t(n)}));var s=dt(r,2),o=t=>{jn(t,{get el(){return h}})};ei(s,(t=>{jt(z)&&t(o)})),Ye(t,i)},$$slots:{default:!0}});var v=dt(i,2),f=t=>{var e=Kn();let i;Xn(ct(e),{children:(t,e)=>{Yn(t,{})},$$slots:{default:!0}}),se((t=>i=fi(e,1,"primary micrio-controls",null,i,t)),[()=>({portrait:jt($)})]),zi(3,e,(()=>Nr)),Ye(t,e)};ei(v,(t=>{l()&&jt(E)&&t(f)})),Ye(t,e)};ei(F,(t=>{jt(O)&&t(V)})),Ye(t,N),_e(),r()}class ts{constructor(t,e){var i;this.image=t,this.data=e,this.timeline=[],this._paused=!0,this.playing=!1,this.wasPaused=!1,this.unhookEvents=!1,this.micrio=t.wasm.micrio,this.initialView=t.camera.getView();const r="timeline"in e?e:(null==(i=e.i18n)?void 0:i[Ki(this.micrio._lang)])??void 0;if(!r)throw new Error("No valid content for video tour!");this.content=r,this.unhookEvents=!e.keepInteraction&&this.micrio.events.$enabled,e.instance=this,this.read(),this.micrio.events.dispatch("videotour-start",this.data)}destroy(){this.unhookEvents&&this.micrio.events.enabled.set(!0),this.playing&&(this.image.camera.stop(),this.micrio.removeAttribute("data-videotour-playing"),this.micrio.events.dispatch("videotour-stop",this.data),this.playing=!1,delete this.startedAt,delete this.data.instance,this.startAt=void 0,clearTimeout(this._to))}read(){const t=!!this.data.i18n?1:this.content.duration,e=this.content.timeline;this.timeline.length=0;for(let i=0;i<e.length;i++){const r=e[i],n=e[i-1],s=n?n.end*t:0;this.timeline.push({view:r.rect,start:1e3*s,duration:1e3*(r.start*t-s),pauseDuration:(r.end-r.start)*t*1e3})}this.startedAt&&!this.playing&&(this.progress=this.currentTime)}get duration(){return Number(this.content.duration)}set duration(t){this.content.duration=t}get paused(){return this._paused}get ended(){return this.currentTime>=this.duration}get currentTime(){return(this.pausedAt?this.pausedAt:this.startedAt?Date.now()-this.startedAt:0)/1e3}set currentTime(t){this.setProgress(t/this.content.duration)}get progress(){return this.currentTime/this.content.duration}set progress(t){this.setProgress(t)}play(){this.startedPlaying(),this.wasPaused=!1,this.pausedAt?(this.startedAt=Date.now()-this.pausedAt,this._paused=!1,this.gotoTime(this.pausedAt),this.pausedAt=void 0):this.playing||(this.startedAt=Date.now(),void 0===this.startAt?this.gotoStep(0,0):this.gotoTime(this.duration*this.startAt*1e3),this.startAt=void 0),this._paused=!1,this.playing=!0}pause(){this._paused||null==this.currentIndex||null==this.startedAt||(this._paused=!0,this.stoppedPlaying(),clearTimeout(this._to),this.currentIndex>=0&&this.image.camera.stop(),this.ended?this.reset():this.pausedAt=Date.now()-this.startedAt)}reset(){this.stoppedPlaying(),this.pausedAt=void 0,this.playing=!1,this.read()}gotoStep(t,e){if(null==this.startedAt)return;if(clearTimeout(this._to),!this.timeline[t]){if(!this.paused||!this.wasPaused){const t=Math.max(0,Math.round(1e3*this.duration-(Date.now()-this.startedAt)));this._to=setTimeout((()=>this.pause()),t)}return}const i=this.timeline[t],r=Math.round(i.start-(Date.now()-this.startedAt));this.currentIndex=t,this.image.camera.stop(),r>0?this._paused||(this._to=setTimeout((()=>this.startAni(e)),r)):this.startAni(e)}nextStep(){null!=this.currentIndex&&this.gotoStep(this.currentIndex+1)}getView(t){const e=this.timeline[t];return null==e?this.initialView??this.image.camera.getView():e.view}startAni(t=0){var e;if(null==this.currentIndex||isNaN(t))return;const i=this.timeline[this.currentIndex];if(null==i)return;const r=i.view,n=this.getView(this.currentIndex-1),s=null==(e=this.image.opts)?void 0:e.area;if(this.wasPaused&&n){const e=this.micrio.wasm.e.ease(t);this.image.camera.setView([n[0]*(1-e)+r[0]*e,n[1]*(1-e)+r[1]*e,n[2]*(1-e)+r[2]*e,n[3]*(1-e)+r[3]*e],{noLimit:!0,area:s}),this.nextStep()}else this.image.camera.flyToView(r,{duration:i.duration,progress:t,prevView:n,area:s}).then((()=>{null!=this.currentIndex&&i==this.timeline[this.currentIndex]&&this.nextStep()})).catch((()=>{}))}startedPlaying(){this.micrio.setAttribute("data-videotour-playing",""),this.micrio.events.dispatch("videotour-play"),this.unhookEvents&&this.micrio.events.enabled.set(!1)}stoppedPlaying(){this.micrio.removeAttribute("data-videotour-playing"),this.micrio.events.dispatch("videotour-pause"),this.unhookEvents&&this.micrio.events.enabled.set(!0)}setProgress(t){t=Math.max(0,Math.min(1,t)),this.wasPaused=!!this.paused||!this.playing,this.pause(),this.wasPaused||(this._paused=!1,this.startedPlaying());const e=this.duration*t*1e3;this.pausedAt=e,this.gotoTime(e),this.wasPaused?this.pause():(this.pausedAt=void 0,this._paused=!1)}gotoTime(t){let e=null,i=0;for(;i<this.timeline.length&&!(this.timeline[i].start>t);i++)e=this.timeline[i];if(i--,e||!(i>0))if(e){this.image.camera.stop();const r=e.duration>0?(t-e.start)/e.duration:0;this.startedAt=Date.now()-e.start-e.duration*r,isNaN(this.startedAt)&&(this.startedAt=Date.now()-t),r>1?(this.gotoStep(i+1),null!=e.view&&this.image.camera.setView(e.view,{noLimit:!0})):(i>0&&this.image.camera.setView(this.timeline[i-1].view,{noLimit:!0}),this.gotoStep(i,r))}else this.timeline.length&&this.image.camera.stop(),this.paused||this.gotoStep(0)}}window.MicrioVideoTour=ts;var es=(t=>(t[t.None=0]="None",t[t.IFrame=1]="IFrame",t[t.Video=2]="Video",t[t.Audio=3]="Audio",t[t.VideoTour=4]="VideoTour",t[t.Micrio=5]="Micrio",t))(es||{}),is=(t=>(t[t.YouTube=1]="YouTube",t[t.Vimeo=2]="Vimeo",t))(is||{});const rs="micrio-captions-disable",ns=Zi("1"!=localStorage.getItem(rs));ns.subscribe((t=>{t?localStorage.removeItem(rs):localStorage.setItem(rs,"1")}));var ss=We('<div><p class="micrio-subtitles"> </p></div>');function os(t,e){Te(e,!0);const[i,r]=ir();let n=or(e,"raised",3,!1);const s=[];fetch(e.src).then((t=>t.text())).then((t=>{const e=t.split("\n");for(let i=0;i<e.length;i++)if(/-->/.test(e[i])){let t=i+1;const r=[];for(;!e[t]&&t<e.length;)t++;for(;e[t]&&e[t].trim();)r.push(e[t++]);const[n,o]=e[i].split(" --\x3e ").map((t=>t.trim().replace(",",".").split(":").map(Number))).map((t=>3600*t[0]+60*t[1]+t[2]));s.push({start:n,end:o,data:r.join("\n")}),i+=r.length+1}}));const o=ye("micrio");let a=j(0);const l=t=>Y(a,t.detail,!0);Gi((()=>(o.addEventListener("timeupdate",l),()=>o.removeEventListener("timeupdate",l))));let c=J((()=>s.filter((t=>t.start<=jt(a)&&t.end>=jt(a)))));var u=Ge(),d=ut(u),h=t=>{var e=Ge();ri(ut(e),16,(()=>jt(c)),(t=>t),((t,e)=>{var i=ss();let r;var s=ct(i),o=ct(s);se((t=>{r=fi(i,1,"micrio-subtitles",null,r,t),Ke(o,e.data)}),[()=>({raised:n()})]),zi(3,i,(()=>Nr)),Ye(t,i)})),Ye(t,e)};ei(d,(t=>{tr(ns,"$captionsEnabled",i)&&t(h)})),Ye(t,u),_e(),r()}var as=t=>t.stopPropagation(),ls=t=>t.stopPropagation(),cs=We('<div class="container micrio-progress-bar"><div class="bars micrio-progress-bar"><!></div> <div class="time micrio-progress-bar"> </div></div>');function us(t,e){Te(e,!0);let i=or(e,"ended",11,!1);var r=cs();r.__click=[as],r.__keydown=[ls];var n=ct(r);ci(ct(n),(()=>e.children??M));var s=ct(dt(n,2));se(((t,e)=>{wi(r,t),Ke(s,e)}),[()=>`--progress: ${Math.round((e.currentTime??0)/e.duration*1e4)/100}%;--time: '${wr(e.currentTime??0)}';`,()=>wr(i()||!e.currentTime||e.currentTime<=0?e.duration:(e.currentTime??0)-e.duration)]),Ye(t,r),_e()}Ve(["click","keydown"]);var ds=t=>t.stopPropagation(),hs=t=>t.stopPropagation(),ms=Xe('<svg height="42" width="42" class="micrio-media-controls"><circle r="19" cx="21" cy="21" class="micrio-media-controls"></circle></svg>'),vs=We("<!> <!> <!>",1),ps=We('<div class="bar active"></div>'),fs=We('<aside class="micrio-media-controls"><!> <!></aside> <!>',1);function gs(t,e){Te(e,!0);let i=or(e,"currentTime",11,0);const r=ye("micrio");e.events.forEach((t=>{t.start=Number(t.start||0),t.end=Math.min(Number(t.end||0),e.duration)}));const n=t=>e.events.forEach((e=>{const i=e.start<=t&&e.end>=t;i!=!!e.active&&(e.active=i,r.events.dispatch("tour-event",{...e}))}));var s;ee((()=>{n(i())})),s=()=>n(1/0),null===we&&ge(),Gi((()=>()=>Gt(s))),_e()}Ve(["click","keydown","mousedown"]);const ws=new Audio;var bs=(t,e,i)=>{t.target==jt(e)&&i(t)},ys=We("<iframe></iframe>"),ks=We('<source type="video/mp4;codecs=hvc1">'),Ts=We("<!> <source>",1),_s=We('<video playsinline="" class="micrio-media"><!></video>',2),xs=We("<audio></audio>"),Es=We("<micr-io></micr-io>",2),$s=We("<aside><!></aside>"),As=We('<figcaption class="micrio-media"><!></figcaption>'),Ss=We('<div class="show-play micrio-media"><!></div>'),Is=We("<figure><div><!> <!> <!></div> <!></figure> <!>",1);function Ms(t,e){var i,r,n,s,o,a,l;Te(e,!0);const[c,u]=ir(),d=()=>tr(X,"$_lang",c),h=ye("micrio");let m=or(e,"src",15,void 0),v=or(e,"volume",15,1),p=or(e,"width",3,640),f=or(e,"height",3,380),g=or(e,"frameScale",3,1),w=or(e,"autoplay",15,!1),b=or(e,"loop",3,!1),y=or(e,"loopDelay",3,void 0),k=or(e,"controls",15,!1),T=or(e,"title",3,void 0),_=or(e,"figcaption",3,null),x=or(e,"paused",15,!0),E=or(e,"forcePause",3,void 0),$=or(e,"seeking",15,!0),A=or(e,"duration",31,(()=>-1)),S=or(e,"currentTime",15),I=or(e,"muted",31,(()=>0==v())),M=or(e,"is360",3,!1),L=or(e,"tour",3,null),P=or(e,"secondary",3,!1),C=or(e,"fullscreen",3,void 0),D=or(e,"className",3,null),R=or(e,"hasTransparentH265",3,!1),z=or(e,"noPlayOverlay",3,!1),O=or(e,"uuid",15,""),N=or(e,"image",19,(()=>Ki(h.current))),F=or(e,"_media",15,void 0);const V=I();O(O()+(m()??(null==(i=L())?void 0:i.id)));const U=N().$info,{events:q,state:W,_lang:X}=h,G=ye("volume"),H=0==tr(G,"$mainVolume",c),Z=ye("srt");let K;const Q=W.mediaState.get(O());Q&&(S(Q.currentTime),w(!x(Q.paused))),W.mediaState.set(O(),{get currentTime(){return S()??0},set currentTime(t){Rt(t)},get paused(){return x()},set paused(t){t?Dt():Ct()}}),m()&&/<iframe /.test(m())&&m(m().replace(/^.* src="([^"]+)".*$/,"$1")),(null==(r=m())?void 0:r.startsWith("video://"))&&m(m().replace("video:","https:"));const tt="https://www.youtube-nocookie.com";let et=j(B(m()));const it=m()&&m().startsWith("cfvid://"),rt=m()&&m().toLowerCase(),nt=rt?rt.endsWith("mp3")?es.Audio:rt.endsWith(".mp4")||rt.endsWith(".webm")||it?es.Video:rt.startsWith("micrio://")?es.Micrio:rt.startsWith("http")?es.IFrame:es.None:L()?es.VideoTour:es.None,st=nt==es.Micrio?null==(n=m())?void 0:n.slice(9).split(","):null;let ot,at,lt,ht;st&&x(!1);let mt=-1,vt=j(!1);const pt=nt==es.Audio&&mr.iOS;let ft=j(void 0);const gt=h.hasAttribute("data-native-frame"),wt=m()&&/((?:https?:)?\/\/)?((?:www|m)\.)?((?:youtube\.com|youtu.be|youtube-nocookie\.com))(\/(?:[\w\-]+\?v=|embed\/|v\/)?)([\w\-]+)(\S+)?/.exec(m()),bt=/^.*t=(\d+).*$/;if(m()&&!gt&&wt&&wt[5])if("playlist"==wt[5]){const t=/list=([^&]+)/.exec(m());(null==t?void 0:t[1])&&Y(et,`${tt}/embed/videoseries?list=${t[1]}`)}else{ot=is.YouTube;const t=Math.round((bt.test(m())?Number(m().replace(bt,"$1")):S())??0);Y(et,`${tt}/embed/${wt[5]}?autoplay=0&enablejsapi=1&controls=0&start=${t}`),Y(vt,!0)}if(!gt&&m()&&/vimeo\.com/.test(m())){const t=m().match(/\/(\d+)/);if(t&&t[1]){const e=m().slice(m().indexOf(t[1])+t[1].length+1).replace(/\?.*$/,"");ot=is.Vimeo,Y(et,`https://player.vimeo.com/video/${t[1]}?${e?`h=${e}&`:""}title=0&portrait=0&sidedock=0&byline=0&controls=0#t=`+Math.round(S()??0)+"s"),Y(vt,!0)}}let yt;it&&m()&&(yt=`https://videodelivery.net/${m().slice(8)}/manifest/video.m3u8`,Y(et,void 0));let kt=j(void 0);if(L()){const t=new ts(N(),L());null!=S()&&S()>0&&(t.currentTime=S()),nt==es.VideoTour&&(A("duration"in L()?Number(L().duration):(null==(o=null==(s=L().i18n)?void 0:s[d()])?void 0:o.duration)??0),v(NaN)),Y(kt,t,!0)}(nt==es.Micrio||nt==es.IFrame&&!ot)&&k(!1);const Tt=L()&&!("steps"in L())?"subtitle"in L()?L().subtitle:null==(l=null==(a=L().i18n)?void 0:a[h.lang])?void 0:l.subtitle:void 0,_t=Tt&&("fileUrl"in Tt?Tt.fileUrl:Tt.src);function xt(){$(!1),M()&&N()&&!N()._video&&N().video.set(F())}let Et=j(!1);function $t(){Y(Et,!1),x(!1),jt(kt)&&F()&&(jt(kt).duration=F().duration,jt(kt).currentTime=F().currentTime,jt(kt).play())}function At(t){t&&"button"in t&&0!=t.button||(x()?Ct():Dt())}const St=async()=>F()?F().paused:jt(kt)?x():at?[-1,0,2].indexOf(at.getPlayerState())>=0:ot==is.YouTube?x():!!lt&&await lt.getPaused();let It=j(!1),Mt=!1;const Lt=ye("mediaPaused");let Pt;async function Ct(t){var i,r,n,s;if(!(t&&t instanceof PointerEvent&&0!=t.button)&&(!Mt||await St())){switch(Y(Nt,!1),A()>0&&null!=S()&&S()>=A()&&S(0),!P()&&_t&&Z.set(_t),nt){case es.VideoTour:x($(!1)),null==(i=jt(kt))||i.play(),Vt();break;case es.Audio:case es.Video:null==(r=F())||r.addEventListener("play",$t,{once:!0}),null==(n=F())||n.play().catch((t=>{var i;z()?x(!0):/pause\(\)/.test(t.toString())||(Y(Et,!0),h.events.dispatch("media-blocked"),null==(i=e.onblocked)||i.call(e))}));break;case es.IFrame:switch(ot){case is.YouTube:at&&at.playVideo();break;case is.Vimeo:lt&&lt.play()}break;default:return}Mt=!0,q.dispatch("media-play"),Lt.set(!1),null==(s=e.onplay)||s.call(e),M()||H||jt(kt)&&!F()||G.set(N().$settings.mutedVolume||0)}}function Dt(){q.dispatch("media-pause"),Lt.set(!0),F()?(F().pause(),pt&&x(!0)):jt(kt)?(jt(kt).pause(),x(!0),Ut()):(null==at?void 0:at.pauseVideo)&&!jt(Xt)?at.pauseVideo():(null==lt?void 0:lt.pause)&&lt.pause()}function Rt(t){$(!0),F()?F(F().currentTime=t,!0):jt(kt)?(S(jt(kt).currentTime=t),$(!1)):(null==at?void 0:at.seekTo)?at.seekTo(t):(null==lt?void 0:lt.setCurrentTime)&&lt.setCurrentTime(t)}function zt(){jt(kt)?(S(jt(kt).currentTime),jt(kt).ended&&Ft()):(null==at?void 0:at.getCurrentTime)&&S(at.getCurrentTime()),Ot()}function Ot(){P()||q.dispatch("timeupdate",S())}let Nt=j(!1);function Ft(){var t;jt(Nt)||(jt(kt)?Dt():(x(!0),Ut()),Y(Nt,!0),q.dispatch("media-ended"),null==(t=e.onended)||t.call(e),Wt())}function Vt(){mt>=0||(mt=setInterval(zt,250),zt())}function Ut(){clearInterval(mt),mt=-1}async function Bt(){if(it&&!Dr(F()))return gr("https://i.micr.io/hls-1.5.17.min.js",void 0,"Hls"in window?{}:void 0).then((()=>{ht=new window.Hls,ht.loadSource(yt),F()&&ht.attachMedia(F())}));if(nt==es.IFrame){if(ot==is.YouTube)return async function(){if(!at){if(window.YT||await gr("https://i.micr.io/youtube.js","onYouTubeIframeAPIReady"),window.YT)return $(!0),new Promise(((t,e)=>{at=new window.YT.Player(jt(ft),{host:tt,width:jt(ie).toString(),height:jt(re).toString(),playerVars:{controls:0},events:{onError:e,onReady:()=>{jt(Xt)?e():(I(at.isMuted()),A(at.getDuration()),$(!1),t())},onStateChange:t=>{switch(t.data){case-1:Y(It,x(!0),!0),Ut();break;case 0:Ft();break;case 1:Vt(),Y(It,x($(!1)),!0);break;case 2:x(!0),Ut();break;case 3:zt(),$(!0),Ut()}}}})}));Y(vt,!1)}}();if(ot==is.Vimeo)return async function(){if(!lt){if(window.Vimeo||await gr("https://i.micr.io/vimeo.min.js"),window.Vimeo)return $(!0),new Promise(((t,e)=>{const i=lt=new window.Vimeo.Player(jt(ft),{width:jt(ie).toString(),height:jt(re).toString(),title:!1,autoplay:!1});i.on("error",e),i.on("loaded",(()=>i.getVolume().then((i=>{jt(Xt)?e():(I(0==v(i)),t())})))),i.on("play",(()=>x($(!1)))),i.on("bufferstart",(()=>$(!0))),i.on("seeked",(()=>{$(!1)})),i.on("pause",(()=>x(!0))),i.on("volumechange",(t=>{t&&I(0==v(t.volume))})),i.on("timeupdate",(t=>{t&&(A(t.duration),S(t.seconds))})),i.on("ended",Ft)}));Y(vt,!1)}}()}else F()&&(it&&Y(et,yt,!0),function(){if(!F())return;F(F().ontimeupdate=Ot,!0),jt(kt)&&(F(F().onpause=()=>jt(kt).pause(),!0),F(F().onseeked=()=>{F()&&!F().ended&&(jt(kt).currentTime=F().currentTime,qt&&(F().pause(),qt=!1))},!0));null!=S()&&S()>0&&(F().duration>0?F(F().currentTime=S(),!0):F(F().oncanplay=()=>{F()&&(F(F().oncanplay=null,!0),w()||(F().play(),qt=!0),F(F().currentTime=K,!0))},!0));const t=b()&&void 0!==y()?y():-1;F(F().onended=t>=0?()=>{clearTimeout(Pt),Pt=setTimeout((()=>{var t;E()||null==(t=F())||t.play()}),1e3*t)}:Ft,!0)}())}let qt=!1;function Wt(){H||G.set(1)}let Xt=j(!1);const Gt=()=>{var t;return S((null==(t=F())?void 0:t.currentTime)??0)};const Yt=nt==es.Video;let Ht=j(B(Yt&&it&&1!=g()&&mr.iOS));Gi((()=>{var t,i;null==(t=e.onid)||t.call(e,O()),m()&&pt&&(F(ws),F(F().controls=!1,!0),F(F().onloadedmetadata=()=>{var t;return A((null==(t=F())?void 0:t.duration)??0)},!0),F(F().src=m(),!0),F(F().oncanplay=xt,!0),F(F().onended=Ft,!0),F().addEventListener("timeupdate",Gt),F(F().onseeking=()=>$(!0),!0),F(F().onseeked=()=>$(!1),!0)),K=S()||0,Y(vt,ot==is.YouTube||ot==is.Vimeo,!0),Bt().then((()=>{w()&&Ct()})).catch((()=>{})),jt(Ht)&&(null==(i=F())||i.addEventListener("playing",(()=>Y(Ht,!1)),{once:!0}));const r=h.isMuted.subscribe((t=>function(t){V||(I(t),F()?F(F().muted=t,!0):(null==at?void 0:at.mute)?(t?at.mute():at.unMute(),setTimeout((()=>{at&&I(at.isMuted())}),50)):lt&&lt.setVolume(t?0:1))}(t)));return()=>{!function(){if(!jt(Xt)){if(Y(Xt,!0),M()&&N()&&N().video.set(void 0),W.mediaState.delete(O()),Ut(),Dt(),Wt(),_t&&Z.set(void 0),F()&&(F(F().onended=null,!0),pt&&(F(F().onloadedmetadata=F(F().onplay=F(F().onseeking=F(F().onseeked=null,!0),!0),!0),!0),F().removeEventListener("timeupdate",Gt)),F(F().ontimeupdate=F(F().onpause=F(F().onseeked=F(F().oncanplay=null,!0),!0),!0),!0)),jt(kt))jt(kt).destroy();else if(lt)for(let t of["error","loaded","play","bufferstart","seeked","pause","volumechange","timeupdate","ended"])lt.off(t);ht?ht.destroy():at?at.destroy():lt&&lt.destroy()}}(),r(),pt&&F(void 0),ht?ht.destroy():at?at.destroy():lt&&lt.destroy()}})),ee((()=>{F()&&nt==es.Video&&!I()&&F(F().muted=0==v(),!0)})),ee((()=>{void 0!==E()&&x(E())})),ee((()=>{b()&&void 0!==y()&&clearTimeout(Pt)}));let Zt=J((()=>{var t,e;return jt(kt)&&L()?"events"in L()?L().events:(null==(e=null==(t=L().i18n)?void 0:t[d()])?void 0:e.events)??void 0:void 0})),Kt=j(void 0),Jt=j(void 0);const Qt=U.is360?Math.PI/2:1;let te=J((()=>Yt?g()*Qt:nt==es.IFrame?Math.max(g(),Math.min(p()/512,f()/512)):1)),ie=J((()=>Yt?p():Math.round(p()/jt(te)*Qt))),re=J((()=>Yt?f():Math.round(f()/jt(te)*Qt)));var ne=Ge(),oe=ut(ne),ae=t=>{var e=Is(),i=ut(e);let r;wi(i,null);var n=ct(i);let s;n.__pointerup=[bs,Jt,At];var o=ct(n),a=t=>{var e=ys();let i;qi(e,(t=>Y(ft,t)),(()=>jt(ft))),se(((t,r)=>i=$i(e,i,{...t,title:T(),src:jt(et),width:jt(ie),height:jt(re),frameborder:"0",allow:"fullscreen *;autoplay *;encrypted-media *",[bi]:r},"micrio-media")),[()=>({credentialless:!0}),()=>({hooked:jt(vt)&&!jt(It)})]),Ye(t,e)},l=(t,e)=>{var i=t=>{var e=_s();e.controls=!1;var i=ct(e),r=t=>{var e=Ts(),i=ut(e),r=t=>{var e=ks();se((t=>xi(e,"src",t)),[()=>jt(et).replace(".webm",".mp4")]),Ye(t,e)};ei(i,(t=>{R()&&jt(et).endsWith(".webm")&&t(r)}));var n=dt(i,2);xi(n,"type",it?"application/x-mpegURL":void 0),se((()=>xi(n,"src",jt(et)))),Ye(t,e)};ei(i,(t=>{jt(et)&&t(r)})),qi(e,(t=>F(t)),(()=>F())),se((()=>{e.loop=b()&&(null==y()||y()<=0),xi(e,"width",p()),xi(e,"height",f()),wi(e,jt(Ht)?"opacity: 0":void 0),e.autoplay=!!w()})),Fe("canplay",e,xt),Fe("ended",e,Ft),Wi("duration","durationchange",e,A),Ui(e,I),Ni(e,S),Fi(e,$),Vi(e,x),Ye(t,e)},r=(t,e)=>{var i=t=>{var e=xs();e.controls=!1,qi(e,(t=>F(t)),(()=>F())),se((()=>xi(e,"src",jt(et)))),Fe("canplay",e,(()=>$(!1))),Fe("ended",e,Ft),Wi("duration","durationchange",e,A),Ui(e,I),Ni(e,S),Fi(e,$),Vi(e,x),Ye(t,e)},r=(t,e)=>{var i=t=>{var e=Es();Ei(e,"data-logo","false"),se((()=>Ei(e,"id",st[0]))),se((()=>Ei(e,"width",st[1]))),se((()=>Ei(e,"height",st[2]))),se((()=>Ei(e,"lang",st[3]))),se((()=>Ei(e,"data-path",U.path))),Ye(t,e)};ei(t,(t=>{nt==es.Micrio&&st&&t(i)}),e)};ei(t,(t=>{nt!=es.Audio||pt?t(r,!1):t(i)}),e)};ei(t,(t=>{nt==es.Video?t(i):t(r,!1)}),e)};ei(o,(t=>{nt==es.IFrame?t(a):t(l,!1)}));var u=dt(o,2),d=t=>{gs(0,{get events(){return jt(Zt)},get currentTime(){return S()},set currentTime(t){S(t)},get duration(){return A()},set duration(t){A(t)}})};ei(u,(t=>{var e;(null==(e=jt(Zt))?void 0:e.length)&&A()>0&&!jt(Xt)&&t(d)}));var m=dt(u,2),g=t=>{var e=$s();let i;var r=ct(e);const n=J((()=>M()||nt!=es.IFrame&&nt!=es.Video?C():jt(Kt)));!function(t,e){Te(e,!0);const[i,r]=ir(),n=()=>tr(Xr,"$i18n",i),s=()=>tr(ns,"$captionsEnabled",i);let o=or(e,"currentTime",15),a=or(e,"duration",11,0),l=or(e,"seeking",11,!0),c=or(e,"muted",11,!1),u=or(e,"minimal",3,!1),d=or(e,"ended",15),h=or(e,"fullscreen",3,void 0),m=or(e,"subtitles",3,!1),v=J((()=>!isNaN(e.volume))),p=j(void 0);function f(t){0==t.button&&(window.addEventListener("mousemove",g),window.addEventListener("mouseup",w),g(t))}function g(t){var i;const r=jt(p).getClientRects()[0],n=Math.min(1,Math.max(0,(t.clientX-r.left)/r.width));null==(i=e.onseek)||i.call(e,n*a())}function w(){window.removeEventListener("mousemove",g),window.removeEventListener("mouseup",w)}var b=fs(),y=ut(b);y.__click=[ds],y.__keydown=[hs];var k=ct(y);const T=J((()=>e.paused?"play":"pause")),_=J((()=>e.paused?n().play:n().pause));zn(k,{get type(){return jt(T)},get title(){return jt(_)},get onclick(){return e.onplaypause},children:(t,e)=>{var i=Ge(),r=ut(i),n=t=>{var e=ms(),i=ct(e);se((()=>xi(i,"stroke-dashoffset",119.4*(1-o()/a())))),Ye(t,e)};ei(r,(t=>{u()&&void 0!==o()&&o()>0&&t(n)})),Ye(t,i)},$$slots:{default:!0}});var x=dt(k,2),E=t=>{var i=vs(),r=ut(i),o=t=>{const i=J((()=>c()?"volume-off":"volume-up")),r=J((()=>c()?n().audioUnmute:n().audioMute));zn(t,{get disabled(){return l()},get type(){return jt(i)},get title(){return jt(r)},get onclick(){return e.onmute}})};ei(r,(t=>{jt(v)&&t(o)}));var a=dt(r,2),u=t=>{const e=J((()=>s()?"subtitles":"subtitles-off"));zn(t,{get type(){return jt(e)},get active(){return s()},get title(){return n().subtitlesToggle},onclick:()=>ns.set(!s())})};ei(a,(t=>{m()&&t(u)}));var d=dt(a,2),p=t=>{jn(t,{get el(){return h()}})};ei(d,(t=>{h()&&t(p)})),Ye(t,i)};ei(x,(t=>{u()||t(E)}));var $=dt(y,2),A=t=>{us(t,{get duration(){return a()},get currentTime(){return o()},set currentTime(t){o(t)},get ended(){return d()},set ended(t){d(t)},children:(t,e)=>{var i=ps();i.__mousedown=f,qi(i,(t=>Y(p,t)),(()=>jt(p))),se((()=>wi(i,`--progress:${(o()??0)/a()*100}%;`))),Ye(t,i)},$$slots:{default:!0}})};ei($,(t=>{u()||t(A)})),Ye(t,b),_e(),r()}(r,{subtitles:!!_t,get fullscreen(){return jt(n)},onplaypause:At,onmute:()=>h.isMuted.set(!I()),onseek:t=>Rt(t),get paused(){return x()},set paused(t){x(t)},get seeking(){return $()},set seeking(t){$(t)},get duration(){return A()},set duration(t){A(t)},get currentTime(){return S()},set currentTime(t){S(t)},get muted(){return I()},set muted(t){I(t)},get volume(){return v()},set volume(t){v(t)},get ended(){return jt(Nt)},set ended(t){Y(Nt,t,!0)}}),se((t=>i=fi(e,1,"micrio-media",null,i,t)),[()=>({inside:"inside"==k()})]),Ye(t,e)};ei(m,(t=>{k()&&t(g)})),qi(n,(t=>Y(Jt,t)),(()=>jt(Jt)));var E=dt(n,2),L=t=>{var e=As();li(ct(e),_),Ye(t,e)};ei(E,(t=>{_()&&t(L)})),qi(i,(t=>Y(Kt,t)),(()=>jt(Kt)));var P=dt(i,2),z=t=>{var e=Ss();e.__pointerup=Ct,zn(ct(e),{get title(){return tr(Xr,"$i18n",c).play},type:"play"}),Ye(t,e)};ei(P,(t=>{jt(Et)&&t(z)})),se(((t,e)=>{r=fi(i,1,hi(D()),"micrio-media",r,t),wi(n,1==jt(te)||nt!=es.Video&&U.is360?"":`transform:scale(${jt(te)})`),s=fi(n,1,"micrio-media",null,s,e)}),[()=>({paused:x(),is360:M(),"media-video":nt==es.IFrame||nt==es.Video,"media-micrio":nt==es.Micrio}),()=>({videotour:!!jt(kt)})]),Ye(t,e)};ei(oe,(t=>{N().$settings.noUI||t(ae)})),Ye(t,ne),_e(),u()}Ve(["pointerup"]);var Ls=t=>t.stopPropagation(),Ps=We("<article><!></article>");function Cs(t,e){Te(e,!0);let i=or(e,"cn",3,null);function r(t){var e;t.target&&t.target instanceof HTMLAnchorElement&&!(null==(e=t.target.getAttribute("href"))?void 0:e.startsWith("#"))&&(t.target.target="_blank")}var n=Ps();n.__click=[Ls],n.__keydown=r,n.__pointerdown=r,ci(ct(n),(()=>e.children??M)),se((()=>fi(n,1,hi(i()),"micrio-article"))),Ye(t,n),_e()}Ve(["click","keydown","pointerdown"]);var Ds=We('<h1 class="micrio-marker-content"> </h1>'),Rs=We('<figcaption class="micrio-marker-content"> </figcaption>'),zs=We('<button class="micrio-marker-content"><figure class="micrio-marker-content"><img class="micrio-marker-content"> <!></figure></button>'),Os=We('<section class="micrio-marker-content"></section>'),Ns=We("<!> <!>",1),Fs=We("<main><!> <!> <!> <!> <!> <!> <!></main>");function Vs(t,e){var i,r,n;Te(e,!0);const[s,o]=ir(),a=()=>tr(f,"$tour",s),l=()=>tr(p,"$lang",s);let c=or(e,"noEmbed",3,!1),u=or(e,"noImages",3,!1),d=or(e,"noGallery",3,!1),h=or(e,"_content",15),m=or(e,"_title",15);const v=ye("micrio"),p=v._lang,f=v.state.tour,g=a()&&"steps"in a()&&a().isSerialTour,w=ye("markerImages").get(e.marker.id),b=w.$settings._markers??{},y=!b.preventAutoPlay,k=!(null==(i=e.marker.data)?void 0:i.preventImageOpen)&&!d(),T=1==(null==(r=e.marker.images)?void 0:r.length);let _=J((()=>e.marker.i18n?e.marker.i18n[l()]:e.marker)),x=J((()=>{var t,i,r,n,s;return!((null==(t=jt(_))?void 0:t.title)||(null==(i=jt(_))?void 0:i.audio)||e.marker.images&&e.marker.images.length||(null==(r=jt(_))?void 0:r.embedUrl)||e.marker.videoTour||(null==(n=jt(_))?void 0:n.body)||(null==(s=jt(_))?void 0:s.bodySecondary))}));const E=()=>{var t;a()&&"steps"in a()&&(a().isSerialTour||b.tourAutoProgress)&&(null==(t=e.onclose)||t.call(e))};const $=J((()=>{var t;return!y||!(null==(t=e.marker)?void 0:t.audioAutoPlay)})),A=J((()=>{var t,i,r;return!1===(null==(t=e.marker)?void 0:t.embedAutoPlay)||!y||!(!(null==(i=jt(_))?void 0:i.audio)||!(null==(r=e.marker)?void 0:r.audioAutoPlay))})),S=null==(n=w.tileBase)?void 0:n.includes("micrio.dev"),I=t=>{var e,i;return null==(i=null==(e=t.i18n)?void 0:e[l()])?void 0:i.title};let M=J((()=>{var t,i,r,n;return(null==(r=null==(i=null==(t=e.marker.videoTour)?void 0:t.i18n)?void 0:i[l()])?void 0:r.audio)??(null==(n=jt(_))?void 0:n.audio)})),L=J((()=>jt(M)?"fileUrl"in jt(M)?jt(M).fileUrl:jt(M).src:void 0)),P=J((()=>{var t,i,r,n;return T&&(null==(n=null==(r=null==(i=null==(t=e.marker.images)?void 0:t[0])?void 0:i.i18n)?void 0:r[l()])?void 0:n.description)}));var C=Ge(),D=ut(C),R=t=>{var i=Fs();let r;var n=ct(i),s=t=>{var e=Ds(),i=ct(e);qi(e,(t=>m(t)),(()=>m())),se((()=>Ke(i,jt(_).title))),Ye(t,e)};ei(n,(t=>{jt(_).title&&t(s)}));var o=dt(n,2),a=t=>{Cs(t,{children:(t,e)=>{var i=Ge();li(ut(i),(()=>jt(_).body)),Ye(t,i)},$$slots:{default:!0}})};ei(o,(t=>{jt(_).body&&b.primaryBodyFirst&&t(a)}));var l=dt(o,2),d=t=>{const i=J((()=>e.marker.audioAutoPlay||!jt(_).audio&&!!e.marker.videoTour)),r=J((()=>!e.marker.videoTour||!jt(_)||!jt(_).embedUrl));Ms(t,{get src(){return jt(L)},noPlayOverlay:!0,image:w,get uuid(){return e.marker.id},get tour(){return e.marker.videoTour},get autoplay(){return jt(i)},get controls(){return jt(r)},onended:E,get paused(){return jt($)}})};ei(l,(t=>{!g&&((!jt(_)||!jt(_).embedUrl)&&e.marker.videoTour||jt(_)&&jt(_).audio)&&t(d)}));var p=dt(l,2),f=t=>{var i=Os();ri(i,21,(()=>e.marker.images),(t=>t.id??t.src),((t,i)=>{var r=zs();r.__click=function(...t){var r;null==(r=k?()=>{return t=jt(i).micrioId,void(k&&v.state.popover.set({gallery:e.marker.images,galleryStart:t,image:w}));var t}:void 0)||r.apply(this,t)},r.disabled=!k;var n=ct(r),s=ct(n),o=dt(s,2),a=t=>{var e=Rs(),i=ct(e);se((()=>Ke(i,jt(P)))),Ye(t,e)};ei(o,(t=>{jt(P)&&t(a)})),se(((t,e,i)=>{xi(r,"title",t),xi(s,"alt",e),xi(s,"src",i)}),[()=>I(jt(i)),()=>I(jt(i)),()=>jt(i).micrioId?`https://iiif.${S?"micrio.dev":"micr.io"}/${jt(i).micrioId}/full/${T?"^"+Math.min(jt(i).width,640)+",":"^,320"}/0/default.webp`:jt(i).src]),Ye(t,r)})),Ye(t,i)};ei(p,(t=>{var i;!u()&&(null==(i=e.marker.images)?void 0:i.length)&&t(f)}));var M=dt(p,2),C=t=>{var i=Ns(),r=ut(i),n=t=>{Ms(t,{image:w,className:"hidden",get uuid(){return e.marker.id},get tour(){return e.marker.videoTour},autoplay:y,secondary:!0})};ei(r,(t=>{!jt(_).audio&&e.marker.videoTour&&t(n)}));var s=dt(r,2);const o=J((()=>!jt(A)));Ms(s,{image:w,get src(){return jt(_).embedUrl},get uuid(){return e.marker.id},width:400,height:240,controls:!0,get title(){return jt(_).embedTitle},get figcaption(){return jt(_).embedDescription},get autoplay(){return jt(o)},onended:E,get paused(){return jt(A)}}),Ye(t,i)};ei(M,(t=>{jt(_).embedUrl&&!c()&&t(C)}));var D=dt(M,2),R=t=>{Cs(t,{children:(t,e)=>{var i=Ge();li(ut(i),(()=>jt(_).body)),Ye(t,i)},$$slots:{default:!0}})};ei(D,(t=>{jt(_).body&&!b.primaryBodyFirst&&t(R)}));var z=dt(D,2),O=t=>{Cs(t,{cn:"secondary",children:(t,e)=>{var i=Ge();li(ut(i),(()=>jt(_).bodySecondary)),Ye(t,i)},$$slots:{default:!0}})};ei(z,(t=>{jt(_).bodySecondary&&t(O)})),qi(i,(t=>h(t)),(()=>h())),se((t=>r=fi(i,1,"micrio-marker-content",null,r,t)),[()=>({empty:jt(x)})]),Ye(t,i)};ei(D,(t=>{jt(_)&&t(R)})),Ye(t,C),_e(),o()}Ve(["click"]);var Us=We('<button class="micrio-button tour-step micrio-marker-popup" disabled> </button>'),Bs=We("<!> <!> <!>",1),qs=We('<progress class="progress micrio-marker-popup"></progress> <!>',1),Ws=We('<div><aside class="micrio-marker-popup"><!> <!> <!></aside> <!></div>');function Xs(t,e){Te(e,!0);const[i,r]=ir(),n=()=>tr(c,"$tour",i),s=()=>tr(l,"$current",i),o=()=>tr(Xr,"$i18n",i),a=ye("micrio"),{current:l}=a,c=a.state.tour,u=ye("markerImages").get(e.marker.id),d=u.$settings._markers??{},h=e.marker.data||{},m=d.canMinimizePopup;let v=j(void 0);function p(t){var e,i,r;n()&&jt(f)&&"steps"in n()?t instanceof Event&&jt(b)?c.set(void 0):null==(i=(e=n()).next)||i.call(e):s()&&!u.opts.secondaryTo&&s().id!=u.id&&(null==(r=h.micrioLink)?void 0:r.id)==s().id?(a.open(u.id),u.state.marker.set(void 0),a.state.popup.set(void 0)):u.state.marker.set(void 0)}let f=J((()=>n()&&"steps"in n()&&n().steps.findIndex((t=>t.startsWith(e.marker.id)))>=0)),g=J((()=>n()&&"steps"in n()&&jt(f)&&!n().isSerialTour&&d.tourControlsInPopup)),w=J((()=>(n()&&"steps"in n()?n().currentStep:void 0)??-1)),b=J((()=>jt(g)||n()&&"steps"in n()&&n().currentStep==n().steps.length-1)),y=j(!1);const k=()=>{var t,e;n()&&"steps"in n()&&(null==(e=(t=n()).prev)||e.call(t),Y(y,!0),setTimeout((()=>Y(y,!1)),200))},T=()=>{var t,e;n()&&"steps"in n()&&(null==(e=(t=n()).next)||e.call(t),Y(y,!0),setTimeout((()=>Y(y,!1)),200))};let _=j(!1),x=j(void 0),E=j(void 0);const $=new WeakMap,A=()=>{if(Y(_,!jt(_)),jt(x))for(let t=0;t<jt(x).children.length;t++){const e=jt(x).children[t];e instanceof HTMLElement&&e!=jt(E)&&($.has(e)||($.set(e,e.offsetHeight),e.style.height=e.offsetHeight+"px"),setTimeout((()=>{e.style.height=jt(_)?"0px":$.get(e)+"px"}),100))}};let S=j(!1);Gi((()=>{var t;e.marker.tags.forEach((t=>{var e;return null==(e=jt(v))?void 0:e.classList.add(t)})),setTimeout((()=>{var t,e;return null==(e=null==(t=jt(v))?void 0:t.querySelector("button"))?void 0:e.focus()}),500);const i="embedImages"in e.marker?e.marker.embedImages:void 0;i&&(null==(t=a.$current)||t.data.update((t=>(t||(t={embeds:[]}),t.embeds=[...t.embeds??[],...i],t))));const r=a.state.popup.subscribe((t=>Y(S,!t||t!=e.marker,!0)));return()=>{var t;r(),i&&(null==(t=a.$current)||t.data.update((t=>(null==t?void 0:t.embeds)?(t.embeds=t.embeds.filter((t=>!i.find((e=>e.id==t.id)))),t):t)))}}));var I=Ws();let M;var L=ct(I),P=ct(L),C=t=>{const e=J((()=>!jt(f)||jt(b)?"close":"arrow-right")),i=J((()=>!jt(f)||jt(b)?o().closeMarker:o().tourStepNext));zn(t,{get type(){return jt(e)},get title(){return jt(i)},get disabled(){return jt(y)},onclick:p})};ei(P,(t=>{h.alwaysOpen||t(C)}));var D=dt(P,2),R=t=>{const e=J((()=>jt(_)?"arrow-up":"arrow-down"));zn(t,{get type(){return jt(e)},get title(){return o().minimize},onclick:A})};ei(D,(t=>{m&&t(R)}));var z=dt(D,2),O=t=>{var e=qs(),i=ut(e);xi(i,"aria-hidden",!0),Xn(dt(i,2),{className:"micrio-tour-controls",children:(t,e)=>{var i=Bs(),r=ut(i);const s=J((()=>jt(y)||0==jt(w)));zn(r,{type:"arrow-left",get disabled(){return jt(s)},get title(){return o().tourStepPrev},onclick:k});var a=dt(r,2),l=t=>{var e=Us(),i=ct(e);se((()=>Ke(i,`${jt(w)+1} / ${n().steps.length??""}`))),Ye(t,e)};ei(a,(t=>{d.tourStepCounterInPopup&&t(l)}));var c=dt(a,2);const u=J((()=>jt(y)||jt(w)+1==n().steps.length));zn(c,{type:"arrow-right",get disabled(){return jt(u)},get title(){return o().tourStepNext},onclick:T}),Ye(t,i)},$$slots:{default:!0}}),se((()=>{return t=i,e=(jt(w)+1)/n().steps.length,void((r=Ai(t)).value!==(r.value=e??void 0)&&(t.value!==e||0===e&&"PROGRESS"===t.nodeName)&&(t.value=e??""));var t,e,r})),Ye(t,e)};ei(z,(t=>{jt(g)&&n()&&"steps"in n()&&t(O)})),Vs(dt(L,2),{get marker(){return e.marker},onclose:p,get _content(){return jt(x)},set _content(t){Y(x,t,!0)},get _title(){return jt(E)},set _title(t){Y(E,t,!0)}}),qi(I,(t=>Y(v,t)),(()=>jt(v))),se((t=>M=fi(I,1,"micrio-marker-popup",null,M,t)),[()=>({destroying:jt(S),minimized:jt(_)})]),zi(3,I,(()=>Fr),(()=>d.popupAnimation)),Ye(t,I),_e(),r()}var js=We('<li><button class="micrio-serial-tour"> </button></li>'),Gs=We('<ol class="micrio-serial-tour"></ol>'),Ys=We("<!> <!> <!> <!>",1),Hs=We('<div role="progressbar"></div>'),Zs=We('<!> <aside class="micrio-media-controls micrio-serial-tour"><!> <!></aside> <!>',1);function Ks(t,e){var i,r;Te(e,!0);const[n,s]=ir(),o=()=>tr(d,"$lang",n),a=()=>tr(Xr,"$i18n",n),l=()=>tr(ns,"$captionsEnabled",n),c=e.tour.stepInfo,u=ye("micrio"),d=u._lang,h=u.$current,m=u.state.marker,v=h.$settings,p=!!(null==(r=null==(i=null==v?void 0:v.ui)?void 0:i.controls)?void 0:r.serialTourNoTimeScrub),f=c.reduce(((t,e)=>t+e.duration),0)??0,g="controls"in e.tour?!1!==e.tour.controls:!e.tour.noControls;let w=j(!1),b=j(!1),y=j(B(Ki(u.isMuted))),k=j(void 0),T=j(void 0),_=j(0),x=j("");function E(){const t=u.state.mediaState.get(jt(x));t&&(t.paused=Y(w,!t.paused)),jt(w)?(u.events.dispatch("serialtour-pause",e.tour),u.events.enabled.set(!0)):(u.events.dispatch("serialtour-play",e.tour),u.events.enabled.set(!1))}function $(t,i){var r;if(!e.tour.goto)return;const n=t==e.tour.currentStep;if(p&&n)return;n||e.tour.goto(t);const s=!p&&i?i.offsetX/i.target.offsetWidth:0;c.forEach(((e,r)=>e.ended=!i&&r<t)),I();const o=c[t];o.currentTime=s*o.duration,n&&(null==(r=jt(k))?void 0:r.instance)&&(jt(k).instance.currentTime=o.currentTime),L(t)}function A(){u.isMuted.set(Y(y,!jt(y)))}function S(){var t;const i=jt(T);i&&(i.ended=!0),null!=e.tour.currentStep&&e.tour.currentStep<e.tour.steps.length-1&&e.tour.next?e.tour.next():(Y(w,Y(b,!0),!0),null==(t=e.onended)||t.call(e)),Xt().then((()=>{I(),i&&(i.ended=!1)}))}function I(){var t;null==(t=e.tour.stepInfo)||t.forEach((t=>t.currentTime=0))}const M=Zi([]);function L(t=e.tour.currentStep??0){const i=c.map(((e,i)=>i<t||e.ended||jt(b)?100:i==t?Math.round((e.currentTime||0)/e.duration*1e4)/100:0));Y(_,i.reduce(((t,e,i)=>t+e/100*c[i].duration),0),!0),M.set(i)}function P(t){const i=t&&!!e.tour.steps.find((e=>e.startsWith(t.id)));Y(k,void 0),i&&t.videoTour&&setTimeout((()=>{const i=c[e.tour.currentStep??0];i.markerId==t.id&&(i.ended=!1,Y(T,i,!0),Y(k,t.videoTour,!0),L())}),10)}const C=t=>{var e;return t.i18n?null==(e=t.i18n[o()])?void 0:e.title:t.title};Gi((()=>{const t=()=>L();u.addEventListener("timeupdate",t);const e=m.subscribe(P);return()=>{e(),u.removeEventListener("timeupdate",t),I()}}));let D=J((()=>{var t,e;return jt(k)?"audio"in jt(k)?jt(k).audio:null==(e=null==(t=jt(k).i18n)?void 0:t[o()])?void 0:e.audio:void 0})),R=J((()=>jt(D)?"fileUrl"in jt(D)?jt(D).fileUrl:jt(D).src:void 0)),z=J((()=>{var t;return!!(null==(t=jt(T))?void 0:t.hasSubtitle)})),O=J((()=>c.some((t=>t.hasSubtitle))));var N=Zs(),F=ut(N),V=t=>{var e=Gs();ri(e,21,(()=>c),ii,((t,e,i)=>{var r=Ge(),n=ut(r),s=t=>{var r=js();let n;var s=ct(r);s.__click=()=>$(i);var o=ct(s);se(((t,e)=>{n=fi(r,1,"micrio-serial-tour",null,n,t),Ke(o,e)}),[()=>({active:jt(T)&&jt(T).chapter==i,enriched:jt(e).imageHasOtherMarkers}),()=>C(jt(e).marker)]),Ye(t,r)};ei(n,(t=>{C(jt(e).marker)&&t(s)})),Ye(t,r)})),Ye(t,e)};ei(F,(t=>{e.tour.printChapters&&t(V)}));var U=dt(F,2),q=ct(U),W=t=>{const e=J((()=>!jt(w)));Ms(t,{get tour(){return jt(k)},get src(){return jt(R)},get autoplay(){return jt(e)},onid:t=>Y(x,t,!0),onended:S,onplay:()=>Y(w,!1),onblocked:()=>Y(w,!0),get muted(){return jt(y)},set muted(t){Y(y,t,!0)},get currentTime(){return jt(T).currentTime},set currentTime(t){jt(T).currentTime=t}})};ei(q,(t=>{jt(k)&&jt(T)&&t(W)}));var X=dt(q,2),G=t=>{var e=Ys(),i=ut(e);const r=J((()=>jt(w)?"play":"pause")),n=J((()=>jt(w)?a().play:a().pause));zn(i,{get type(){return jt(r)},get title(){return jt(n)},onclick:E});var s=dt(i,2);const o=J((()=>jt(y)?"volume-off":"volume-up")),c=J((()=>jt(y)?a().audioUnmute:a().audioMute));zn(s,{get type(){return jt(o)},get title(){return jt(c)},onclick:A});var d=dt(s,2),h=t=>{const e=J((()=>!jt(z))),i=J((()=>l()?"subtitles":"subtitles-off"));zn(t,{get disabled(){return jt(e)},get type(){return jt(i)},get active(){return l()},get title(){return a().subtitlesToggle},onclick:()=>ns.set(!l())})};ei(d,(t=>{jt(O)&&t(h)})),jn(dt(d,2),{el:u}),Ye(t,e)};ei(X,(t=>{g&&t(G)}));var H=dt(U,2),Z=t=>{us(t,{duration:f,get currentTime(){return jt(_)},set currentTime(t){Y(_,t,!0)},get ended(){return jt(b)},set ended(t){Y(b,t,!0)},children:(t,i)=>{var r=Ge();ri(ut(r),17,(()=>c),ii,((t,i,r)=>{var s=Ge(),o=ut(s),a=t=>{var s=Hs();let o;s.__click=t=>$(r,t),se(((t,e)=>{o=fi(s,1,"bar",null,o,t),xi(s,"title",e),wi(s,`width:${jt(i).duration/f*100}%; --progress: ${tr(M,"$times",n)[r]||0}%`)}),[()=>({active:r==e.tour.currentStep}),()=>C(jt(i).marker)]),Fe("keypress",s,(t=>{"Enter"===t.key&&$(r)})),Ye(t,s)};ei(o,(t=>{jt(i).duration>0&&t(a)})),Ye(t,s)})),Ye(t,r)},$$slots:{default:!0}})};ei(H,(t=>{g&&t(Z)})),Ye(t,N),_e(),s()}Ve(["click"]);var Js=We('<article class="scroll-tour micrio-tour"></article> <!>',1),Qs=We("<!> <!> <!>",1),to=We("<div><!> <!></div>");function eo(t,e){var i,r;Te(e,!0);const[n,s]=ir(),o=()=>tr(m,"$_lang",n),a=()=>tr(Xr,"$i18n",n);let l=or(e,"tour",15),c=or(e,"noHTML",3,!1);const u=ye("micrio"),{events:d,state:h,_lang:m}=u,v=u.$current,p=v.$data,f=v.$settings,g=u.canvases[0].grid,w=v.state.marker,b="steps"in l()&&l().isSerialTour,y=!("steps"in l()),k="scrollable"in l()&&l().scrollable,T="steps"in l()&&("controls"in l()?!1!==l().controls:!l().noControls),_=!(!b&&"steps"in l()&&(null==(i=f._markers)?void 0:i.tourControlsInPopup)),x=_&&(y||b),E=!!(null==(r=f._markers)?void 0:r.keepPopupsDuringTourTransitions),$=()=>M(jt(R)-1),A=()=>M(jt(R)+1),S=()=>d.enabled.set(!0);let I;function M(t){var e,i,r,n;if(!("steps"in l())||!l().stepInfo)return;const s=l().stepInfo[t];if(s&&s.markerId==(null==(e=u.state.$marker)?void 0:e.id))return L(s);const o=null==(r=null==(i=l().stepInfo[jt(R)])?void 0:i.micrioImage)?void 0:r.state;o&&o.marker.set(void 0),null==(n=u.$current)||n.state.marker.set(void 0),E||u.state.popup.set(void 0),u.removeEventListener("marker-opened",S),w.set(void 0),s&&(I=setTimeout(P,200,s))}async function L(t){var e,i,r,n,s,o,a;let c=v,d=!1;if(g&&!t.gridView&&g.images.find((e=>e.id==t.micrioId))){const s=!!("steps"in l()&&l().stepInfo&&t)&&(null==(e=l().stepInfo)?void 0:e.indexOf(t))<jt(R),o=(null==(i=t.marker.data)?void 0:i.gridTourTransition)??(null==(n=null==(r=t.marker.data)?void 0:r._meta)?void 0:n.gridTourTransition),a=(null==o?void 0:o.startsWith("slide"))?"slide":"swipe";await Xt().then((()=>{const e=g.focus(c=g.images.find((e=>e.id==t.micrioId)),{view:t.startView,transition:o==a||o==`${a}-horiz`?s?`${a}-left`:`${a}-right`:o==`${a}-vert`?s?`${a}-up`:`${a}-down`:"behind"==o?s?"behind-left":"behind-right":o}).catch((()=>d=!0));return u.events.enabled.set(!1),e}))}else if((null==(s=u.$current)?void 0:s.id)!=t.micrioId){if(t.gridView&&(null==(a=null==(o=t.marker.data)?void 0:o._meta)?void 0:a.gridAction)&&g){t.micrioImage||(t.micrioImage=g.images.find((e=>e.id==t.micrioId))),c=t.micrioImage;const e=t.marker.data._meta.gridAction.split("|");g.action(e.shift(),e.join("|"))}else"steps"in l()&&l().stepInfo&&Y(R,l().stepInfo.indexOf(t),!0),c=u.open(t.micrioId,{gridView:t.gridView,startView:t.startView});await Xt()}else c=u.$current;return[c,d]}async function P(t){let e=v,i=!1;t.micrioId&&([e,i]=await L(t)),i||(t.micrioImage||(t.micrioImage=e),d.enabled.set(!1),e.state.marker.set(t.markerId),u.addEventListener("marker-opened",S,{once:!0}),await Xt(),d.dispatch("tour-step",l()))}function C(){h.tour.set(void 0)}function D(){d.dispatch("tour-ended",l()),l().closeOnFinish&&C()}let R=j(-1),z=j(!1);const O=v.camera.getView(),N=f._markers;"steps"in l()&&(l(l().prev=$,!0),l(l().next=A,!0),l(l().goto=M,!0),ee((()=>{l(l().currentStep=jt(R),!0)})));const F=Zi(!1);let V;function U(){F.set(!1),clearTimeout(V),V=setTimeout((()=>F.set(!0)),5e3)}F.subscribe((t=>d.dispatch("tour-minimize",t)));let B,q=j(void 0);function W(t){var e,i;if(!("steps"in l())||!jt(q))return;const r=l().steps,n=t.filter((t=>t.isIntersecting)).map((t=>t.target))[0];if(n)for(let s=0;s<jt(q).children.length;s++)if(jt(q).children[s]==n){const t=null==(e=p.markers)?void 0:e.find((t=>t.id==r[s].split(",")[0]));return void(t&&(null==(i=u.$current)||i.camera.flyToView(t.view).catch((()=>{}))))}}let X=[];Gi((()=>("steps"in l()&&Mr(v,l(),o(),v.$data).then((()=>function(t){var e;if(k||(null==(e=u.$current)?void 0:e.state.$marker)||void 0!==t.initialStep&&M(t.initialStep),k&&jt(q)){B=new IntersectionObserver(W,{root:jt(q),threshold:1});for(let t=0;t<jt(q).children.length;t++)B.observe(jt(q).children[t])}X.push(u.state.marker.subscribe((e=>{if(!e)return void Y(z,!1);const i="string"==typeof e?e:e.id,r=t.steps.findIndex((t=>t.startsWith(i)));if(r>=0&&t.stepInfo){const e=t.stepInfo[Y(R,r,!0)];e&&!e.micrioImage&&(e.micrioImage=u.canvases.find((t=>t.id==e.micrioId))??(null==g?void 0:g.images.find((t=>t.id==e.micrioId)))??u.$current)}Y(z,r<0)})))}(l()))),T||X.push(F.subscribe((t=>{var i;return null==(i=e.onminimize)?void 0:i.call(e,t)}))),c()||"steps"in l()&&!b||!1===l().minimize||(u.addEventListener("pointermove",U),u.addEventListener("touchstart",U),U()),x&&u.setAttribute("data-tour-active",""),()=>{var t,e;for(clearTimeout(V),clearTimeout(I);X.length;)null==(t=X.shift())||t();u.removeEventListener("pointermove",U),u.removeEventListener("touchstart",U),u.removeEventListener("marker-opened",S),x&&u.removeAttribute("data-tour-active"),S(),B&&B.disconnect();const i=u.state.$marker;if("steps"in l()&&l().stepInfo&&null!=l().currentStep){const t=l().stepInfo[l().currentStep];delete l().goto,delete l().next,delete l().prev,i&&(null==t?void 0:t.markerId)==i.id&&(null==(e=t.micrioImage)||e.state.marker.set(void 0),u.state.marker.set(void 0))}v.camera.aniDone=void 0,g||"steps"in l()&&l().keepLastStep||u.$current==v||u.open(v.id),Xt().then((()=>{d.dispatch("tour-stop",l()),"steps"in l()&&delete l().currentStep,!("steps"in l())&&(null==N?void 0:N.zoomOutAfterClose)&&!i&&O&&v.camera.flyToView(O,{speed:null==N?void 0:N.zoomOutAfterCloseSpeed,noTrueNorth:!0})}))}))),d.dispatch("tour-start",l());let G=j(0),H=j(!1),Z=J((()=>"steps"in l()?void 0:l())),K=J((()=>{var t,e;return jt(Z)?"audio"in l()?l().audio:null==(e=null==(t=jt(Z).i18n)?void 0:t[o()])?void 0:e.audio:void 0})),Q=J((()=>jt(K)?"fileUrl"in jt(K)?jt(K).fileUrl:jt(K).src:void 0));var tt=Ge(),et=ut(tt),it=t=>{var e=Ge(),i=ut(e),r=t=>{var e=Js(),i=ut(e);ri(i,21,(()=>l().steps.map((t=>p.markers&&p.markers.find((e=>e.id==t.split(",")[0]))))),ii,((t,e)=>{var i=Ge(),r=ut(i),n=t=>{Xs(t,{get marker(){return jt(e)}})};ei(r,(t=>{jt(e)&&t(n)})),Ye(t,i)})),qi(i,(t=>Y(q,t)),(()=>jt(q)));var r=dt(i,2),n=t=>{zn(t,{type:"close",get title(){return a().tourStop},className:"scroll-tour-end",onclick:C})};ei(r,(t=>{l().cannotClose||t(n)})),Ye(t,e)},s=(t,e)=>{var i=t=>{var e=to();let i;var r=ct(e),s=t=>{var e=Ge(),i=ut(e),r=t=>{Ks(t,{get tour(){return l()},onended:D})},n=t=>{var e=Qs(),i=ut(e);const r=J((()=>0==jt(R)));zn(i,{type:"arrow-left",get title(){return a().tourStepPrev},get disabled(){return jt(r)},onclick:$});var n=dt(i,2);zn(n,{noClick:!0,children:(t,e)=>{var i=je();se((()=>Ke(i,`${jt(R)+1} / ${l().steps.length??""}`))),Ye(t,i)},$$slots:{default:!0}});var s=dt(n,2);const o=J((()=>jt(R)==l().steps.length-1));zn(s,{type:"arrow-right",get title(){return a().tourStepNext},get disabled(){return jt(o)},onclick:A}),Ye(t,e)};ei(i,(t=>{b?t(r):t(n,!1)})),Ye(t,e)},o=t=>{Ms(t,{get tour(){return l()},get src(){return jt(Q)},fullscreen:u,controls:!0,autoplay:!0,onended:D,get paused(){return jt(H)},set paused(t){Y(H,t,!0)},get currentTime(){return jt(G)},set currentTime(t){Y(G,t,!0)}})};ei(r,(t=>{"steps"in l()?t(s):t(o,!1)}));var c=dt(r,2),d=t=>{zn(t,{type:"close",get title(){return a().close},onclick:C})};ei(c,(t=>{l().cannotClose||t(d)})),se((t=>i=fi(e,1,"micrio-tour",null,i,t)),[()=>({left:b,"serial-tour":b,"video-tour":y,"no-controls":T,minimized:!jt(H)&&(tr(F,"$minimized",n)||jt(z))})]),zi(1,e,(()=>Nr),(()=>({duration:200}))),Ye(t,e)},r=(t,e)=>{var i=t=>{Ms(t,{get tour(){return jt(Z)},get src(){return jt(Q)},autoplay:!0,onended:D,get currentTime(){return jt(G)},set currentTime(t){Y(G,t,!0)}})};ei(t,(t=>{jt(Z)&&t(i)}),e)};ei(t,(t=>{_?t(i):t(r,!1)}),e)};ei(i,(t=>{k&&"steps"in l()?t(r):t(s,!1)})),Ye(t,e)},rt=(t,e)=>{var i=t=>{Ms(t,{get tour(){return jt(Z)},get src(){return jt(Q)},autoplay:!0,onended:D,get currentTime(){return jt(G)},set currentTime(t){Y(G,t,!0)}})};ei(t,(t=>{jt(Z)&&t(i)}),e)};ei(et,(t=>{c()?t(rt,!1):t(it)})),Ye(t,tt),_e(),s()}class io{constructor(t,e,i,r={}){this.micrio=t,this.length=e,this.goto=i,this.opts=r,this.hitTresh=!1,this.snapTo=[],this.pointers=new Map,this.isFullWidth=!1,this.startedWithShift=!1,this.isDragging=()=>2==this.pointers.size||(this.isFullWidth||this.startedWithShift)&&1==this.pointers.size,r.sensitivity||(r.sensitivity=Number(t.getAttribute("data-swipe-sensitivity")??1));const n=t.getAttribute("data-swipe-snap");n&&(this.snapTo=n.split(",").map(Number)),this.micrio.setAttribute("data-hooked",""),this.dStart=this.dStart.bind(this),this.dMove=this.dMove.bind(this),this.dStop=this.dStop.bind(this),this.mouseleave=this.mouseleave.bind(this),this.image=t.$current,this.image.state.view.subscribe((t=>this.isFullWidth=r.coverLimit?this.image.camera.isZoomedOut():!t||Math.round(1e3*(t[2]-t[0]))/1e3>=1));const s=t.wasm.getPtr();t.wasm.e.setNoPinchPan(s,!0),t.wasm.e.setIsSwipe(s,!0),this.micrio.canvas.element.addEventListener("pointerdown",this.dStart)}get currentIndex(){return this.micrio.wasm.e._getActiveImageIdx(this.image.ptr)}destroy(){this.micrio.canvas.element.removeEventListener("pointerdown",this.dStart),this.mouseleave()}dStart(t){this.startedWithShift=t.shiftKey;const e=!this.isDragging();this.pointers.set(t.pointerId,!0),this.pointers.size>2&&this.mouseleave(),e&&(this.hitTresh=!1,this.micrio.setAttribute("data-panning",""),this.startIndex=this.currentIndex,this.startX=t.clientX,this.firstTouchId=t.pointerId,this.micrio.addEventListener("pointermove",this.dMove),this.micrio.addEventListener("pointerup",this.dStop),this.micrio.setPointerCapture(t.pointerId))}dMove(t){if(!this.isDragging()||t.pointerId!=this.firstTouchId||void 0===this.startX||void 0===this.startIndex)return;if(!this.hitTresh&&void 0!==this.startX&&(this.hitTresh=2!=this.pointers.size||Math.abs(t.clientX-this.startX)>(this.micrio.events.pinchFactor&&this.micrio.events.pinchFactor>1.25?.3:.15)*this.micrio.offsetWidth)&&(this.startX=t.clientX),!this.hitTresh)return;const e=this.micrio.$current.camera,i=this.opts.continuous?Math.max(.1,(e.getXY(1,.5)[0]-e.getXY(0,.5)[0])/this.micrio.offsetWidth):1,r=Math.round((t.clientX-this.startX)/(this.micrio.offsetWidth*i)*this.length*(this.opts.sensitivity??1));let n=this.startIndex-r;if(this.opts.continuous){for(;n<0;)n+=this.length;for(;n>this.length-1;)n-=this.length}n=Math.max(0,Math.min(this.length-1,n)),n!=this.currentIndex&&this.goto(n)}dStop(t){this.pointers.delete(t.pointerId),t.pointerId==this.firstTouchId&&(this.micrio.releasePointerCapture(this.firstTouchId),this.firstTouchId=void 0),this.pointers.size||this.swipeEnd()}mouseleave(){this.pointers.clear(),this.swipeEnd()}swipeEnd(){if(this.micrio.removeAttribute("data-panning"),this.micrio.removeEventListener("pointermove",this.dMove),this.micrio.removeEventListener("pointerup",this.dStop),this.hitTresh=!1,this.snapTo.length){const t=this.snapTo[this.snapTo.map(((t,e)=>[e,Math.abs(t-this.currentIndex)])).sort(((t,e)=>t[1]>e[1]?1:t[1]<e[1]?-1:0))[0][0]];t!=this.currentIndex&&this.animateTo(t)}}animateTo(t){this.raf&&cancelAnimationFrame(this.raf);const e=performance.now(),i=this.currentIndex,r=i-t,n=t=>{const s=Math.min(1,(t-e)/250);s<1&&(this.raf=requestAnimationFrame(n));const o=i-Math.round(this.micrio.wasm.e.ease(s)*r);o!=this.currentIndex&&this.goto(o)};this.raf=requestAnimationFrame(n)}}var ro=We('<span class="micrio-dial"> </span>'),no=We('<div data-scroll-through="" class="micrio-dial"><!></div>');function so(t,e,i,r){jt(e)||Y(i,r(t)[1],!0)}var oo=We("<button>&#10021;</button>"),ao=We('<li><button class="bullet micrio-gallery">&bull;</button></li>'),lo=We('<div><!> <ul class="micrio-gallery"><!> <button aria-label="drag handle"></button></ul> <!></div>');function co(t,e){var i,r,n,s,o,a;Te(e,!0);const[l,c]=ir(),u=()=>tr(_,"$settings",l),d=()=>tr(T,"$layer",l),h=()=>tr(Xr,"$i18n",l);let m=or(e,"images",19,(()=>[])),v=or(e,"omni",3,null);const p=ye("micrio"),{wasm:f,current:g,events:w,_lang:b}=p,y=tr(g,"$current",l),k=y.$info,T=y.state.layer,_=y.settings,x=y.camera;if(v())for(let j=0;j<v().frames;j++)m().push({id:k.id+"/"+j,image:y,visible:Zi(!1),frame:j,opts:{area:[0,0,1,1]},ptr:-1,baseTileIdx:-1,thumbSrc:y.getTileSrc(y.levels,0,0,j)});const E=u().gallery,$="omni"==E.type,A=$||"swipe-full"==E.type,S=A||"switch"==E.type,I=$,M=!!E.isSpreads,L=E.coverPages??0,P=u().omni,C=$&&!!(null==P?void 0:P.twoAxes),D=E.startId||p.getAttribute("data-gallery-start-id"),R=E.archive,z=!!u().limitToCoverScale,O=!!u().noUI,N=(null==P?void 0:P.frontIndex)??0,F=(null==(i=null==P?void 0:P.layers)?void 0:i.length)??1,V=p.hasAttribute("data-gallery-start")?Number(p.getAttribute("data-gallery-start")):null==(n=null==(r=u())?void 0:r.omni)?void 0:n.startIndex;let U=null==V||isNaN(V)?D?m().findIndex((t=>t.id==D)):0:V;U<0&&(U=0);const B=[],q=[];if(m())for(let j=0;j<m().length;j++){let t=null==(s=m()[j].opts)?void 0:s.area;if(!t)continue;const e=t.slice(0);if(q.push([j]),M&&j-L>=0&&(j-L)%2==0&&m()[j+1]){if(t=null==(o=m()[++j].opts)?void 0:o.area,!t)continue;q[q.length-1].push(j),e[2]=t[2],e[3]=t[3]}B.push(e)}const W=B.length/F,X=(null==(a=null==P?void 0:P.layers)?void 0:a.map((t=>({i18n:Object.fromEntries(Object.entries(t.i18n).map((([t,e],i)=>[t,{title:e??"Layer "+(i+1)}])))}))))??[];Object.keys(k.revision??{[(()=>tr(b,"$_lang",l))()]:0}).forEach((t=>X.forEach(((e,i)=>{e.i18n[t]||(e.i18n[t]={title:"Layer "+(i+1)})}))));let G=j(-1),H=S,Z=j(!0),K=j(!1),Q=j(!0),tt=!1,et=j(0);function rt(t,e=!1,i=150,r=!1){if(I){for(;t<0;)t+=W;t%=W}const n=t=Math.round(Math.max(0,Math.min(W-1,t))),s=r||n!=jt(G);if(Y(G,n,!0),s&&nt(),S)s&&(f.setActiveImage(y.ptr,q[jt(G)][0],q[jt(G)].length-1),$?f.render():(x.flyToView(B[jt(G)],{duration:i,speed:2}).then((()=>ht(B[jt(G)],!0))).catch((()=>{})),Ut()));else{const r=x.getView(),n=B[t],o=tt&&(H&&!jt(K)||s||r[0]<n[0]!=r[2]>n[2]);Y(K,!1),o?x.flyToView(n,{duration:i,speed:1,progress:e?.5:0}).then((()=>ht(n,!0))).catch((()=>{})):(n&&0==i&&x.setView(n),ht(n,!0))}y.album.hooked=tt=!0}function nt(t){if(Ft&&t){if(Ft.currentIndex==jt(G))return;Y(G,Ft.currentIndex,!0)}lt(jt(G)),w.dispatch("gallery-show",jt(G)),$&&Y(et,(jt(G)-N)/W*360)}const st="requestIdleCallback"in self?$?Math.max(36,2*Math.floor(m().length/8)):100:50,ot=new Map,at=self.requestIdleCallback??self.requestAnimationFrame;function lt(t){const e=[];X.length&&(t+=d()*Math.floor(m().length/X.length)),M&&t>=L&&(t=2*t-L);const i=Math.floor(t/Pt);for(let r=-st;r<=st;r++)if(r){let n=t+r;if(C){const t=Math.floor(n/Pt);t<i&&(n+=Pt),t>i&&(n-=Pt)}if(I){for(;n<0;)n+=m().length;for(;n>=m().length;)n-=m().length}e.push(n)}if(C)for(let r=-st;r<=st;r++)r&&e.push(t+r*Pt);e.filter(((t,i)=>t>=0&&t<m().length&&e.indexOf(t)==i)).map((t=>m()[t])).filter((t=>!!t&&!ot.has(t.id))).forEach((t=>ot.set(t.id,at((()=>f.getTexture(t.baseTileIdx,t.thumbSrc,!1,{force:!!R}))))))}function ht(t,e){H=x.isZoomedOut(),x.setLimit(!e&&H?[-1,t[1],2,t[3]]:t)}function mt(t){var e;const i=null==(e=jt(pt))?void 0:e.childNodes[t];return i?-2+i.offsetLeft+i.offsetWidth/2:0}let vt,pt=j(void 0),ft=j(0),gt=J((()=>!jt(pt)||jt(Z)?jt(ft):mt(jt(G)))),wt=!1;function bt(t){t.preventDefault(),t.stopPropagation(),jt(Z)||(wt="button"in t)&&0!=t.button||!jt(pt)||(vt=jt(pt).getClientRects()[0],p.keepRendering=Y(Z,!0),Y(xt,-1),window.addEventListener(wt?"pointermove":"touchmove",kt),window.addEventListener(wt?"pointerup":"touchend",Et),kt(t))}function yt(t){const e=vt??jt(pt).getClientRects()[0],i="button"in t?t.clientX:t.touches[0].clientX,r=Math.min(1,Math.max(0,(i-e.left-14)/(e.width-32)));return[r,Math.max(0,Math.min(W-1,Math.floor(r*W)))]}function kt(t){const[e,i]=yt(t);Y(ft,16+e*(vt.width-32)),i!=jt(G)&&rt(i,!0)}let Tt,_t,xt=j(-1);function Et(){window.removeEventListener(wt?"pointermove":"touchmove",kt),window.removeEventListener(wt?"pointerup":"touchend",Et),Y(Z,p.keepRendering=!1,!0),rt(jt(G))}function $t(){H&&(_t=Tt=jt(G),Y(K,H,!0),ht(B[jt(G)],!1))}function At(t){const e=t.detail;"panend"!=t.type||e?rt(_t!=jt(G)?_t:jt(G)+(Tt==jt(G)&&jt(K)&&e?Math.round(Math.min(1,Math.max(-1,-e.movedX/e.duration))):0)):Y(K,!1)}function St(t){if(!t)return;const e=t[0]+(t[2]-t[0])/2,i=B.map(((i,r)=>(1-Math.min(Math.abs(e-i[0]),Math.abs(e-i[2])))*Math.max(0,(Math.min(t[2],i[2])-Math.max(t[0],i[0]))/(i[2]-i[0]))*(1-.1*Math.abs(jt(G)-r))));f.setFocus(y.ptr,B[_t=i.every((t=>!t))?jt(G):i.indexOf(Math.max(...i))],jt(K)),H=x.isZoomedOut()}let It=0,Mt=[0,0,0,0];function Lt(t){t.stopPropagation(),t.preventDefault(),0==t.button&&(Y(Z,!0),Mt=[t.clientX,t.clientY,jt(G),It],window.addEventListener("pointermove",Dt),window.addEventListener("pointerup",Rt))}const Pt=m().length,Ct=1;function Dt(t){It=Math.max(0,Math.min(Ct-1,Mt[3]+Math.round((Mt[1]-t.clientY)/360*Ct)));let e=(Mt[2]+Math.round((Mt[0]-t.clientX)/360*Pt))%Pt;for(;e<0;)e+=Pt;rt(It*Pt+e)}function Rt(){removeEventListener("pointermove",Dt),removeEventListener("pointerup",Rt),Y(Z,!1)}let zt=-1;const Ot=()=>{X.length&&y.data.update((t=>{t||(t={}),t.pages||(t.pages=[]);const e={id:"_omni-layers",i18n:X[d()].i18n,icon:Qr,children:X.map(((t,e)=>({id:"omni-layer-"+e,i18n:t.i18n,action:()=>{T.set(e),lt(jt(G))}}))).filter((t=>t.id!="omni-layer-"+d()))};return zt>=0&&zt<t.pages.length?t.pages.splice(zt,1,e):t.pages.push(e),zt=t.pages.length-1,t}))};let Nt,Ft,Vt=p.state.ui.hidden;function Ut(){Vt.set(!1),clearTimeout(Nt),Nt=setTimeout((()=>Vt.set(!0)),2e3)}y.album={numPages:B.length,get currentIndex(){return jt(G)},info:y.$settings.album,prev:()=>rt(jt(G)-1),next:()=>rt(jt(G)+1),goto:rt},Gi((()=>{Promise.all(m().map((t=>("state"in t&&!("image"in t)&&(t.camera=y.camera),f.addEmbed(t,y,{opacity:0,asImage:"camera"in t}))))).then((()=>{f.setActiveImage(y.ptr,U),rt(U,!1,0),Y(Z,!1)})),$&&F>1&&Ot(),Y(Q,!1),p.goto=rt;const t=[],e=[];return $&&t.push(y.state.layer.subscribe(Ot)),A&&(Ft=y.swiper=new io(p,W,rt,{continuous:I,coverLimit:z})),e.push((()=>{p.canvas.element.removeEventListener("pointermove",Ut),p.canvas.element.removeEventListener("pointerdown",Ut)})),$||C||A||(p.canvas.element.addEventListener("pointermove",Ut),p.canvas.element.addEventListener("pointerdown",Ut),Ut()),S&&t.push(y.state.view.subscribe((()=>{H=x.isZoomedOut()}))),S||A||m().length<=1||(C||Y(ft,mt(U),!0),t.push(y.state.view.subscribe(St)),p.addEventListener("panstart",$t),p.addEventListener("panend",At),p.addEventListener("pinchend",At),e.push((()=>{p.removeEventListener("panstart",$t),p.removeEventListener("panend",At),p.removeEventListener("pinchend",At)}))),$&&p.addEventListener("move",nt),()=>{var i,r;for(Ft&&Ft.destroy();t.length;)null==(i=t.shift())||i();for(;e.length;)null==(r=e.shift())||r();$&&p.removeEventListener("move",nt)}}));var Bt=Ge();Fe("keydown",it,(function(t){var e;if(!(null==(e=u().omni)?void 0:e.noKeys)){switch(t.key){case"PageUp":case"ArrowLeft":rt(jt(G)-($?-1:1),!0);break;case"PageDown":case"ArrowRight":rt(jt(G)+($?-1:1),!0);break;case"ArrowUp":C&&rt(jt(G)+Pt);break;case"ArrowDown":C&&rt(jt(G)-Pt);break;case"Home":rt(0);break;case"End":rt(W);break;default:return}Ut()}}));var qt=ut(Bt),Wt=t=>{var e=Ge(),i=ut(e),r=t=>{var e=oo();let i;se((t=>i=fi(e,1,"angular micrio-gallery",null,i,t)),[()=>({dragging:jt(Z)})]),Fe("pointerdown",e,Lt,!0),Ye(t,e)},n=(t,e)=>{var i=t=>{const e=J((()=>{var t;return null==(t=u().omni)?void 0:t.showDegrees}));!function(t,e){Te(e,!0);const i=ye("micrio"),r=i.$current.camera;let n,s=j(void 0),o=0,a=0;function l(t){var n;const l=Math.max(1,(r.getXY(1,.5)[0]-r.getXY(0,.5)[0])/i.offsetWidth),c=(a/360+(o-t.clientX)/(jt(s).offsetWidth*l))*e.frames;null==(n=e.onturn)||n.call(e,c)}function c(){n&&i.releasePointerCapture(n),i.removeAttribute("data-panning"),i.removeEventListener("pointermove",l),i.removeEventListener("pointerup",c)}let u=J((()=>{var t;return-e.currentRotation/360*((null==(t=jt(s))?void 0:t.offsetWidth)??0)}));var d=no(),h=ct(d),m=t=>{var i=ro(),r=ct(i);se((t=>Ke(r,`${t??""}º`)),[()=>Math.round(10*e.currentRotation)/10]),Ye(t,i)};ei(h,(t=>{e.degrees&&t(m)})),qi(d,(t=>Y(s,t)),(()=>jt(s))),se((()=>wi(d,`--micrio-dial-offset:${jt(u)??""}px;`))),Fe("pointerdown",d,(function(t){t.stopPropagation(),t.preventDefault(),0==t.button&&(i.addEventListener("pointermove",l),i.addEventListener("pointerup",c),i.setAttribute("data-panning",""),i.setPointerCapture(n=t.pointerId),a=e.currentRotation,o=t.clientX)}),!0),Ye(t,d),_e()}(t,{get currentRotation(){return jt(et)},frames:W,get degrees(){return jt(e)},onturn:t=>rt(t)})},r=(t,e)=>{var i=t=>{var e=lo();let i;var r=ct(e);const n=J((()=>0==jt(G)));zn(r,{type:"arrow-left",get title(){return h().galleryPrev},className:"gallery-btn",onpointerdown:()=>rt(jt(G)-1),get disabled(){return jt(n)}});var s=dt(r,2);s.__pointermove=[so,Z,xt,yt];var o=ct(s);ri(o,17,(()=>B),ii,((t,e,i)=>{var r=ao();let n;var s=ct(r);s.__click=()=>rt(i,!0),se((t=>n=fi(r,1,"micrio-gallery",null,n,t)),[()=>({active:i==jt(G),hover:i==jt(xt)})]),Fe("keypress",s,(t=>{"Enter"===t.key&&rt(i,!0)})),Ye(t,r)}));var a=dt(o,2);let c;qi(s,(t=>Y(pt,t)),(()=>jt(pt)));var u=dt(s,2);const d=J((()=>jt(G)==m().length-1));zn(u,{type:"arrow-right",get title(){return h().galleryNext},className:"gallery-btn",onpointerdown:()=>rt(jt(G)+1),get disabled(){return jt(d)}}),se(((t,r)=>{i=fi(e,1,"micrio-gallery",null,i,t),wi(a,`left: ${jt(gt)}px`),c=fi(a,1,"micrio-gallery",null,c,r)}),[()=>({hidden:jt(Q)||tr(Vt,"$hidden",l)&&!jt(Z)&&!jt(K)}),()=>({dragging:jt(Z)})]),Fe("pointerleave",s,(()=>Y(xt,-1))),Fe("pointerdown",a,bt,!0),Fe("touchstart",a,bt,!0,!0),Ye(t,e)};ei(t,(t=>{!A&&m().length>1&&t(i)}),e)};ei(t,(t=>{P&&!P.noDial&&$?t(i):t(r,!1)}),e)};ei(i,(t=>{C?t(r):t(n,!1)})),Ye(t,e)};ei(qt,(t=>{O||t(Wt)})),Ye(t,Bt),_e(),c()}let uo;Ve(["pointermove","click"]);const ho={},mo=Zi();let vo,po;const fo=Zi(!1);function go(t,e,i){po&&(po.setPosition?po.setPosition(t,e,i):"positionX"in po&&(po.positionX.value=t,po.positionY.value=e,po.positionZ.value=i))}function wo(t,e,i){po&&(po.setOrientation?po.setOrientation(t,e,i,0,1,0):"forwardX"in po&&(po.forwardX.value=t,po.forwardY.value=e,po.forwardZ.value=i))}function bo(t,e){Te(e,!0);const[i,r]=ir();let n=or(e,"volume",3,1);const{events:s,current:o}=ye("micrio"),a=tr(o,"$current",i),l=a.$info,c=l.height/l.width,u="AudioContext"in window||"webkitAudioContext"in window;const d=()=>fo.set(!0),h=new Audio("data:audio/mpeg;base64,/+MYxAAAAANIAUAAAASEEB/jwOFM/0MM/90b/+RhST//w4NFwOjf///PZu////9lns5GFDv//l9GlUIEEIAAAgIg8Ir/JGq3/+MYxDsLIj5QMYcoAP0dv9HIjUcH//yYSg+CIbkGP//8w0bLVjUP///3Z0x5QCAv/yLjwtGKTEFNRTMuOTeqqqqqqqqqqqqq/+MYxEkNmdJkUYc4AKqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq");h.volume=mr.iOS?0:1e-4,u&&Gi((()=>{let t,i;return i=fo.subscribe((r=>{var o;r&&(vo||(!function(t){if(!uo){if(vo||(vo="micrioAudioContext"in window?window.micrioAudioContext:"AudioContext"in window?new window.AudioContext:"webkitAudioContext"in window?new window.webkitAudioContext:null),!vo)return console.warn("[Micrio] Your browser does not support the Web Audio API");uo=vo.createGain(),uo.connect(vo.destination),uo.gain.value=t,mo.set(vo),po=vo.listener,"upX"in po&&(po.upX.value=0,po.upY.value=1,po.upZ.value=0)}}(n()),s.dispatch("audio-init")),vo&&(null==(o=e.data.markers)?void 0:o.filter((t=>!!t.positionalAudio)).length)&&(t=a.state.view.subscribe((t=>{if(!t)return;const i=t[2]-t[0],r=t[3]-t[1],n=Math.max(0,1.05-a.camera.getScale());!function(t,i,r){if(e.is360){t*=2*-Math.PI,i-=.5,i*=-Math.PI;const e=10*(1-r),n=Math.cos(i)*Math.sin(t)*e,s=Math.sin(i)*e,o=Math.cos(i)*Math.cos(t)*e;go(n,s,o);let a=n*n+s*s+o*o;a>0&&(a=1/Math.sqrt(a)),wo(n*a,s*a,o*a)}else go(2*(t-.5),2*(.5-i)*c,r),wo(0,0,-1)}(t[0]+i/2,t[1]+r/2,n*(e.is360?1:1.5))}))),i&&(i(),i=null))})),vo||h.play().then(d).catch((()=>{s.dispatch("autoplay-blocked"),addEventListener("pointerup",d,{once:!0})})),()=>{t&&t(),i&&i(),removeEventListener("pointerup",d)}})),ee((()=>{uo&&(uo.gain.value=n())}));var m=Ge(),v=ut(m),p=t=>{const i=J((()=>n()*(e.data.music.volume??1)));!function(t,e){Te(e,!0);let i=or(e,"loop",3,!0),r=or(e,"volume",3,1);const n=B(new Audio);n.preload="none",n.loop=!1,n.onended=o;let s=-1;function o(){if(!i()&&s+1==e.list.length)return;const t=e.list[++s%e.list.length];n.src="fileUrl"in t?t.fileUrl:t.src,n.play()}Gi((()=>(o(),()=>n.pause()))),ee((()=>{n.volume=r()})),_e()}(0,{get list(){return e.data.music.items},get loop(){return e.data.music.loop},get volume(){return jt(i)}})};ei(v,(t=>{var r;tr(fo,"$interacted",i)&&tr(mo,"$ctx",i)&&(null==(r=e.data.music)?void 0:r.items.length)&&t(p)})),Ye(t,m),_e(),r()}var yo=We('<cite class="micrio-details"> </cite>'),ko=We('<small class="micrio-details"> </small>'),To=We('<summary class="micrio-details"><!> <!></summary>'),_o=We('<p class="micrio-details"><a rel="noopener noreferrer" target="_blank"> </a></p>'),xo=We("<details><!> <!> <!> <!></details>");function Eo(t,e){Te(e,!0);const[i,r]=ir(),n=()=>tr(a,"$current",i),s=()=>tr(e.data,"$data",i),{_lang:o,current:a}=ye("micrio");let l=j(!1);function c(t){let e="cm";return t>=1e5?(e="km",t/=1e5):t>=100?(e="m",t/=100):t<1e-6?(e="nm",t*=1e7):t<.001?(e="µm",t*=1e4):t<1&&(e="mm",t*=10),t.toFixed(2)+" "+e}let u=J((()=>{var t;return null==(t=n())?void 0:t.$settings.cmWidth})),d=J((()=>{var t;return null==(t=n())?void 0:t.$settings.cmHeight})),h=J((()=>{var t;return s()?(null==(t=s())?void 0:t.i18n)?s().i18n[tr(o,"$_lang",i)]:s():void 0})),m=J((()=>{var t,r;return(null==(t=jt(h))?void 0:t.title)??(null==(r=tr(e.info,"$info",i))?void 0:r.title)??""})),v=J((()=>{var t;return null==(t=jt(h))?void 0:t.description})),p=J((()=>{var t;return null==(t=jt(h))?void 0:t.sourceUrl})),f=J((()=>{var t;return null==(t=jt(h))?void 0:t.copyright})),g=J((()=>jt(u)&&jt(d)?c(jt(u))+" x "+c(jt(d)):null)),w=j(void 0);Gi((()=>{jt(w).ontoggle=()=>{Y(l,jt(w).open,!0)}}));var b=Ge(),y=ut(b),k=t=>{var e=xo();let r;var n=ct(e),s=t=>{var e=To(),i=ct(e),r=t=>{var e=yo(),i=ct(e);se((()=>Ke(i,jt(m)))),Ye(t,e)};ei(i,(t=>{jt(m)&&t(r)}));var n=dt(i,2),s=t=>{var e=ko(),i=ct(e);se((()=>Ke(i,jt(g)))),Ye(t,e)};ei(n,(t=>{jt(g)&&t(s)})),Ye(t,e)};ei(n,(t=>{(jt(m)||jt(g))&&t(s)}));var o=dt(n,2),a=t=>{var e=Ge();li(ut(e),(()=>jt(v))),Ye(t,e)};ei(o,(t=>{jt(v)&&t(a)}));var c=dt(o,2),u=t=>{var e=_o(),i=ct(e),r=ct(i);se((()=>{xi(i,"href",jt(p)),Ke(r,jt(f)||jt(p))})),Ye(t,e)};ei(c,(t=>{jt(p)&&t(u)}));var d=dt(c,2),h=t=>{zn(t,{type:"close",get title(){return tr(Xr,"$i18n",i).close},onclick:()=>jt(w).open=!1})};ei(d,(t=>{jt(l)&&t(h)})),qi(e,(t=>Y(w,t)),(()=>jt(w))),se((t=>r=fi(e,1,"micrio-details",null,r,t)),[()=>({opened:jt(l)})]),zi(3,e,(()=>Nr),(()=>({duration:200}))),Ye(t,e)};ei(y,(t=>{(jt(m)||jt(v)||jt(p))&&t(k)})),Ye(t,b),_e(),r()}var $o=We('<div class="micrio-error"><!> </div>');var Ao=We("<figcaption><!></figcaption>"),So=We("<figure><micr-io></micr-io> <!></figure>",2);function Io(t,e){Te(e,!0);const[i,r]=ir(),n=()=>tr(l,"$current",i);let s=or(e,"startId",3,void 0);const o=ye("micrio"),{_lang:a,current:l}=o;let c=j(0);let u=J((()=>e.gallery[jt(c)])),d=J((()=>{var t,e,r;return(null==(r=null==(e=null==(t=jt(u))?void 0:t.i18n)?void 0:e[tr(a,"$_lang",i)])?void 0:r.description)??void 0}));var h=So(),m=ct(h);se((()=>Ei(m,"data-gallery",e.gallery.map((t=>{var e,i;return`${t.micrioId},${t.width},${t.height},${t.isDeepZoom?"d":""}${t.isWebP?",w":t.isPng||!(null==(e=n())?void 0:e.isV5)&&(null==(i=t.src)?void 0:i.endsWith(".png"))?",p":""}`})).join(";")))),se((()=>Ei(m,"data-start",s()))),se((()=>Ei(m,"data-path",n()&&n().$info&&n().$info.path))),Ei(m,"data-logo","false"),fi(m,1,"micrio-micrio-gallery");var v=dt(m,2),p=t=>{var e=Ao();li(ct(e),(()=>jt(d))),Ye(t,e)};ei(v,(t=>{jt(d)&&t(p)})),Fe("gallery-show",m,(t=>{Y(c,t.detail,!0)})),Ye(t,h),_e(),r()}var Mo=We("<!> <!>",1),Lo=We("<aside><!> <!></aside>"),Po=We("<!> <!>",1),Co=We('<menu class="micrio-popover"></menu>'),Do=We('<h2 class="micrio-popover"> </h2>'),Ro=We('<img alt="">'),zo=We("<!> <!> <!> <!>",1),Oo=We('<menu class="right micrio-popover"></menu>'),No=We("<!> <!> <!>",1),Fo=We("<dialog><!> <!></dialog>");function Vo(t,e){var i;Te(e,!0);const[r,n]=ir(),s=()=>tr(d,"$current",r),o=()=>tr(h,"$_lang",r),a=()=>tr(Xr,"$i18n",r),l=B(ye("micrio")),{events:c,state:u,current:d,_lang:h}=l,m=null==(i=s())?void 0:i.$data,v=Object.keys((null==m?void 0:m.revision)??{[o()]:0});function p(){var t;null==(t=jt(b))||t.close()}const f=Zi(!1);let g=j(!0),w=o(),b=j(void 0);Gi((()=>{jt(b).showModal(),Xt().then((()=>{const t=jt(b).querySelector("button.active")??jt(b).querySelector("button");null==t||t.focus()}));const t=h.subscribe((t=>{t&&t!=w&&(Y(g,!1),w=t,setTimeout((()=>Y(g,!0)),200))}));return()=>{t()}}));let y=J((()=>e.popover.marker)),k=J((()=>jt(y)?jt(y).i18n?jt(y).i18n[o()]:jt(y):void 0)),T=J((()=>e.popover.markerTour)),_=J((()=>e.popover.contentPage)),x=J((()=>{var t;return jt(_)?(null==(t=jt(_).i18n)?void 0:t[o()])??jt(_):void 0})),E=J((()=>{var t,e;return jt(_)&&jt(x)&&!(null==(e=null==(t=jt(_))?void 0:t.buttons)?void 0:e.length)?!(!jt(x).embed||jt(x).content&&!(jt(x).content.length<250)||jt(_).image):void 0})),$=J((()=>{var t;return(null==(t=jt(_))?void 0:t.image)?"string"==typeof jt(_).image?jt(_).image:jt(_).image.src:void 0})),A=J((()=>{var t;return!!(null==(t=jt(x))?void 0:t.embed)||!!jt($)})),S=J((()=>{var t,e;return!!(null==(e=null==(t=jt(_))?void 0:t.buttons)?void 0:e.find((t=>"close"==t.type)))})),I=J((()=>{var t;return!!(null==(t=e.popover.marker)?void 0:t.images)&&e.popover.marker.images.length>0})),M=J((()=>!(!jt(k)||!jt(k).body)||jt(I))),L=J((()=>{var t;return jt(k)&&jt(k).body||jt(I)&&(null==(t=jt(x))?void 0:t.embed)})),P=J((()=>!jt(S)||jt(T)&&null!=jt(T).currentStep));var C=Fo();let D;var R=ct(C),z=t=>{var e=Lo();let i;var r=ct(e),n=t=>{zn(t,{type:"close",get title(){return a().close},className:"close-popover",onclick:p})};ei(r,(t=>{jt(S)||t(n)}));var s=dt(r,2),o=t=>{var e=Mo(),i=ut(e),r=t=>{zn(t,{type:"arrow-left",get title(){return a().tourStepPrev},className:"prev-tour-step",onclick:()=>jt(T)&&jt(T).prev&&jt(T).prev()})};ei(i,(t=>{jt(T).currentStep>0&&t(r)}));var n=dt(i,2),s=t=>{zn(t,{type:"arrow-right",get title(){return a().tourStepNext},className:"next-tour-step",onclick:()=>jt(T)&&jt(T).next&&jt(T).next()})};ei(n,(t=>{jt(T).currentStep<jt(T).steps.length-1&&t(s)})),Ye(t,e)};ei(s,(t=>{jt(T)&&null!=jt(T).currentStep&&t(o)})),se((t=>i=fi(e,1,"micrio-popover",null,i,t)),[()=>{var t;return{inside:jt(_)?!jt(E):!jt(M)&&!(null==(t=jt(k))?void 0:t.embedUrl)}}]),Ye(t,e)};ei(R,(t=>{jt(P)&&t(z)}));var O=dt(R,2),N=t=>{var e=Po(),i=ut(e),r=t=>{Ms(t,{get src(){return jt(k).embedUrl},get uuid(){return jt(y).id},get figcaption(){return jt(k).embedDescription},controls:!0,get autoplay(){return jt(y).embedAutoPlay}})},n=(t,e)=>{var i=t=>{Io(t,{get gallery(){return jt(y).images}})};ei(t,(t=>{jt(y).images&&jt(y).images.length&&t(i)}),e)};ei(i,(t=>{jt(k)&&jt(k).embedUrl?t(r):t(n,!1)}));var s=dt(i,2),o=t=>{const e=J((()=>!jt(k)||!jt(k).embedUrl));Vs(t,{get marker(){return jt(y)},noEmbed:!0,noGallery:!0,get noImages(){return jt(e)},onclose:p})};ei(s,(t=>{jt(L)&&t(o)})),Ye(t,e)},F=(t,i)=>{var r=t=>{Io(t,{get gallery(){return e.popover.gallery},get startId(){return e.popover.galleryStart}})},n=(t,e)=>{var i=t=>{var e=No(),i=ut(e),r=t=>{var e=Co();ri(e,21,(()=>v),ii,((t,e)=>{const i=J((()=>(null==Bn?void 0:Bn.of(jt(e)))??jt(e))),r=J((()=>jt(e)==o()));zn(t,{onclick:()=>l.lang=jt(e),get title(){return jt(i)},get active(){return jt(r)},children:(t,i)=>{var r=je();se((t=>Ke(r,t)),[()=>jt(e).toUpperCase()]),Ye(t,r)},$$slots:{default:!0}})})),Ye(t,e)};ei(i,(t=>{v.length>1&&t(r)}));var n=dt(i,2),a=t=>{var e=Ge(),i=ut(e),r=t=>{Ms(t,{get src(){return jt(x).embed},get figcaption(){return jt(x).content},controls:!0,autoplay:!0})};ei(i,(t=>{jt(g)&&t(r)})),Ye(t,e)},c=t=>{Cs(t,{children:(t,e)=>{var i=zo(),r=ut(i),n=t=>{var e=Do(),i=ct(e);se((()=>Ke(i,jt(x).title))),Ye(t,e)};ei(r,(t=>{jt(x).title&&t(n)}));var s=dt(r,2),o=t=>{Ms(t,{get src(){return jt(x).embed},controls:!0})};ei(s,(t=>{jt(x).embed&&jt(g)&&t(o)}));var a=dt(s,2),l=t=>{var e=Ro();se((()=>xi(e,"src",jt($)))),Ye(t,e)};ei(a,(t=>{jt($)&&t(l)}));var c=dt(a,2),u=t=>{var e=Ge();li(ut(e),(()=>jt(x).content)),Ye(t,e)};ei(c,(t=>{jt(x).content&&t(u)})),Ye(t,i)},$$slots:{default:!0}})};ei(n,(t=>{jt(E)?t(a):t(c,!1)}));var u=dt(n,2),d=t=>{var e=Oo();ri(e,21,(()=>jt(_).buttons),ii,((t,e)=>{const i=J((()=>"link"==jt(e).type?jt(e).action:void 0));zn(t,{get href(){return jt(i)},get blankTarget(){return jt(e).blankTarget},onclick:()=>function(t){p(),"close"!=t.type&&setTimeout((()=>{var e,i,r;switch(t.type){case"marker":null==(e=s())||e.state.marker.set(t.action);break;case"mtour":l.state.tour.set(null==(i=null==m?void 0:m.markerTours)?void 0:i.find((e=>e.id==t.action)));break;case"vtour":l.state.tour.set(null==(r=null==m?void 0:m.tours)?void 0:r.find((e=>e.id==t.action)))}}),200)}(jt(e)),children:(t,i)=>{var r=je();se((()=>Ke(r,jt(e).i18nTitle[o()]))),Ye(t,r)},$$slots:{default:!0}})})),Ye(t,e)};ei(u,(t=>{jt(_).buttons&&jt(_).buttons.length&&t(d)})),Ye(t,e)};ei(t,(t=>{jt(_)&&jt(x)&&t(i)}),e)};ei(t,(t=>{e.popover.gallery?t(r):t(n,!1)}),i)};ei(O,(t=>{jt(y)?t(N):t(F,!1)})),qi(C,(t=>Y(b,t)),(()=>jt(b))),se((t=>D=fi(C,1,"micrio-popover",null,D,t)),[()=>({page:!!jt(_),article:!!jt(_)&&!jt(E),"has-media":jt(A)})]),Fe("close",C,(function(){var t;e.popover.contentPage?c.dispatch("page-closed"):jt(T)?u.tour.set(void 0):e.popover.marker&&(null==(t=e.popover.image)||t.state.marker.set(void 0)),u.popover.set(void 0)})),Fe("outrostart",C,(()=>f.set(!0))),Ye(t,C),_e(),n()}function Uo(t,e){Te(e,!0);let i=J((()=>e.marker.positionalAudio));const r=e.ctx.createGain();r.connect(uo);const n=ye("micrio"),s=n.$current.$info,o=s.width,a=s.height,l=e.ctx.createPanner();l.panningModel="equalpower",l.rolloffFactor=1,l.coneOuterGain=0;function c(){if(r.gain.value=jt(i).volume??1,e.is360){l.refDistance=2.75*jt(i).radius,l.maxDistance=jt(i).radius*(11/3);const t=e.marker.x*-Math.PI*2,r=(e.marker.y-.5)*-Math.PI,n=l.positionX.value=Math.cos(r)*Math.sin(t)*11,s=l.positionY.value=11*Math.sin(r),o=l.positionZ.value=Math.cos(r)*Math.cos(t)*11;let a=n*n+s*s+o*o;a>0&&(a=1/Math.sqrt(a)),l.orientationX.value=n*a,l.orientationY.value=s*a,l.orientationZ.value=o*a}else l.distanceModel="linear",l.positionX.value=2*(e.marker.x-.5),l.positionY.value=2*(.5-e.marker.y)*(a/o),l.positionZ.value=-.2,l.rolloffFactor=2,l.refDistance=jt(i).radius*jt(i).radius*10,l.maxDistance=5*jt(i).radius}let u,d;function h(){u&&u.disconnect(),u=e.ctx.createBufferSource(),jt(i).loop&&(jt(i).repeatAfter>0?u.onended=()=>{d=setTimeout(h,1e3*jt(i).repeatAfter)}:u.loop=!0),r.gain.value=jt(i).volume??1,u.buffer=ho[jt(i).src],u.connect(l),u.start()}let m=j(B(JSON.stringify(e.marker.positionalAudio)));ee((()=>{const t=JSON.stringify(jt(i));jt(m)!=t&&Y(m,t,!0)&&c()})),Gi((()=>(c(),l.connect(r),async function(){jt(i).src&&(ho[jt(i).src]||(ho[jt(i).src]=await fetch(jt(i).src).then((t=>t.arrayBuffer())).then((t=>e.ctx.decodeAudioData(t)))),jt(i).alwaysPlay&&jt(i).repeatAfter>0?d=setTimeout(h,1e3*jt(i).repeatAfter):h())}(),n.addEventListener("audio-update",c),()=>{n.removeEventListener("audio-update",c),u&&u.disconnect(),clearTimeout(d),l.disconnect(),r.disconnect()}))),_e()}function Bo(t,e,i,r,n,s,o){var a,l;if(e(),i().onclick)return i().onclick(i());if(!r.noMarkerActions)if("cluster"==i().type){if(i().view&&(null==(a=n())?void 0:a.$info)){const t=n().camera.getScale(),e=[20/n().$info.width*t,20/n().$info.height*t];o().camera.flyToView([i().view[0]-e[0],i().view[1]-e[1],i().view[2]+e[0],i().view[3]+e[1]],{area:null==(l=o().opts)?void 0:l.area,limitZoom:!0})}}else o().state.marker.set(i())}function qo(t,e,i){const r=t.detail;e(e().x=r.x,!0),e(e().y=r.y,!0),i()}var Wo=We('<img alt="" class="micrio-marker">'),Xo=We('<label data-scroll-through=""> </label>'),jo=We('<button data-scroll-through="" class="micrio-marker"><!> <!></button>'),Go=We("<div><!></div>"),Yo=We("<!> <!>",1);function Ho(t,e){var i,r,n,s,o,a,l,c,u,d,h,m;Te(e,!0);const[v,p]=ir(),f=()=>tr(_,"$current",v),g=()=>tr(C,"$tour",v),w=()=>tr(P,"$currentPopup",v),b=()=>tr($,"$_lang",v),y=()=>tr(S,"$isMobile",v),k=()=>tr(mo,"$ctx",v),T=ye("micrio"),{current:_,events:x,state:E,_lang:$,spaceData:A}=T,S=T.canvas.isMobile,I=E.markerHoverId,M=ye("inView"),L=ye("markerImages"),P=T.state.popup,C=E.tour;let D=or(e,"marker",15),R=or(e,"image",31,(()=>B(f()))),z=or(e,"forceHidden",3,!1),O=or(e,"coords",3,void 0),N=or(e,"overlapped",3,!1);D().tags||D(D().tags=[],!0);const F=L.has(D().id);!F&&R()&&L.set(D().id,R());const V=!(!R().isOmni||!(null==(i=R().$settings.omni)?void 0:i.sideLabels)||(null==(r=R().$settings._markers)?void 0:r.noTitles)),U=t=>t.steps.findIndex((t=>t.startsWith(D().id)))>=0,q=D().data??{},W=q._meta||{},X=R().$settings.omni;D().imageLayer&&D().imageLayer>((null==(n=null==X?void 0:X.layers)?void 0:n.length)??1)-1&&delete D().imageLayer,(null==(a=null==(o=null==(s=f())?void 0:s.$data)?void 0:o.markers)?void 0:a.find((t=>{var e,i;return(null==(i=null==(e=t.data)?void 0:e._micrioSplitLink)?void 0:i.markerId)==D().id&&"none"!=t.popupType})))&&(D(D().popupType="none",!0),D(D().noMarker=!0,!0)),"embedUrl"in D()&&D().embedUrl&&"embedInPopover"in D()&&D().embedInPopover&&D(D().popupType="popover",!0);const G=R().$settings._markers??{},H=!!R().$settings.doTourJumps,Z=D().tags.join(" "),K="cluster"==D().type,Q=!!G.noTitles||!!(null==X?void 0:X.sideLabels),tt=!!q.scales||!!R().$settings.markersScale,et=tt&&!!G.titlesNoScale,it=q._micrioSplitLink,rt=!!G.keepPopupsDuringTourTransitions,nt=/[?&]micrioNoTooltips/.test(location.search)||!!(null==X?void 0:X.sideLabels),st=W.gridAction,ot=(null==(c=null==(l=R().$settings)?void 0:l._markers)?void 0:c.autoStartTour)?T.wasm.images.map((t=>{var e,i;return"camera"in t?null==(i=null==(e=t.$data)?void 0:e.markerTours)?void 0:i.find(U):void 0})).filter((t=>!!t))[0]??(null==(u=null==A?void 0:A.markerTours)?void 0:u.find(U)):void 0,at=null==ot?void 0:ot.steps.findIndex((t=>t.startsWith(D().id))),lt=!!(null==(h=null==(d=R().$settings)?void 0:d._markers)?void 0:h.autoStartTourAtBeginning);let ht=!F&&(!!q.alwaysOpen||E.$marker==D())||(null==(m=E.$tour)?void 0:m.id)==(null==ot?void 0:ot.id)&&(null==ot?void 0:ot.currentStep)==(at??0);const mt=F&&R().state.$marker==D();let vt,pt,ft,gt=j(B(mt)),wt=j(B(mt)),bt=j(!1),yt=j(""),kt=j(0),Tt=j(0),_t=j(1),xt=!1;function Et(){var t,e;G.noMarkerActions||(null==(e=null==(t=jt(zt))?void 0:t.parentNode)||e.scrollTo(0,0),$t(),ft=setTimeout((()=>{const t=R().camera.getXY(D().x,D().y);!jt(gt)&&(t[0]<0||t[0]>=T.offsetWidth||t[1]<0||t[1]>=T.offsetHeight||R().is360&&t[3]>4)&&R().camera.flyToCoo([D().x,D().y],{speed:2,limit:!0}).catch((()=>{}))}),150))}function $t(){clearTimeout(ft)}const At=()=>I.set(D().id),St=()=>I.set(void 0);let It;async function Mt(){var t,e,i,r,n;if(K)return;if(R().state.$marker!=D())return R().state.marker.set(D());if(G.noMarkerActions)return;if(ot&&ot.id!=(null==(t=g())?void 0:t.id)){ot.initialStep=lt?0:at;const t=null==(e=ot.stepInfo)?void 0:e[0];if(lt&&t&&t.micrioId!=R().id){const e=null==(i=T.canvases[0])?void 0:i.grid;(null==e?void 0:e.images.find((e=>e.id==t.micrioId)))?T.current.set(e.image):T.open(t.micrioId)}if(C.set(ot),setTimeout((()=>W.gridAction=st),100),lt&&null!=at&&at>0)return void R().state.marker.set(void 0);await Xt()}ht=!1,Y(wt,!0),x.dispatch("marker-opened",D());const s=g()&&"steps"in g()&&g().isSerialTour&&g().printChapters&&g().steps.findIndex((t=>t.startsWith(D().id)))>=0&&D().videoTour;var o;s||(jt(Bt)?"popover"==D().popupType?(await Xt(),T.state.popover.set({marker:D(),image:R(),markerTour:g()&&"steps"in g()?g():void 0})):D().videoTour&&!g()&&(C.set(D().videoTour),(o=C,new Promise((t=>{let e;e=o.subscribe((i=>{null==i&&(e?e():Xt().then((()=>e())),t(i))}))}))).then((()=>R().state.marker.set(void 0)))):Xt().then((()=>P.set(D()))));const a=null==(r=q.micrioLink)?void 0:r.id;if(a&&Xt().then((()=>{R().camera.stop();const t=Cr(T,a);t&&(R(R().openedView=void 0,!0),R().state.marker.set(void 0)),T.open(a,{vector:null==t?void 0:t.vector})})),it&&!xt&&!R().opts.secondaryTo){const t=null==(n=T.canvases[0])?void 0:n.grid;(null==t?void 0:t.lastPromise)&&await t.lastPromise,It=setTimeout((()=>{it&&(pt=T.open(it.micrioId,{splitScreen:!0,splitTo:R(),isPassive:!(!it.follows||T.state.$tour),startView:it.view}),xt=!0)}),200)}}let Lt,Pt,Ct=j(!1);function Dt(){var t,e,i,r,n,s;if(R().is360&&tt)Y(yt,R().camera.getMatrix(D().x,D().y,1,1,0,0,0).join(","),!0);else{let o=jt(kt),a=jt(Tt);if(s=R().camera.getXYDirect(D().x,D().y,{radius:D().radius,rotation:D().rotation}),Y(kt,s[0],!0),Y(Tt,s[1],!0),Y(_t,s[2],!0),vt=s[3],R().is360)Y(bt,vt>0);else if(R().isOmni&&X){if(null!=jt(Wt)[0]&&null!=jt(Wt)[1]&&null!=D().rotation){const i=X.frames/((null==(t=X.layers)?void 0:t.length)??1);let r=((null==(e=R().swiper)?void 0:e.currentIndex)??0)-(jt(qt)??0);r>i/2&&(r-=i),r<-i/2&&(r+=i),Y(bt,r<=jt(Wt)[0]||r>=jt(Wt)[1],!0)}else X.distance&&Y(bt,vt<0);X.sideLabels&&!G.noTitles&&(null==(i=jt(Ft))?void 0:i.title)&&M&&(o!=jt(kt)||a!=jt(Tt))&&function(t,e){const i=T.canvas.element.offsetWidth,r=T.canvas.element.offsetHeight,n=!(t<0||t>i||e<0||e>r||jt(bt));(n||jt(Ct))&&M.update((r=>{const s=r.findIndex((([t])=>t==D()));return n?s>=0?r[s]=[D(),t/i,e]:r.push([D(),t/i,e]):s>=0&&r.splice(s,1),Y(Ct,n,!0),r}))}(jt(kt),jt(Tt))}R().$settings.clusterMarkers&&O()&&O().set(D().id,[jt(kt),jt(Tt),N()?Lt:Lt=null==(r=jt(Ot))?void 0:r.offsetWidth,N()?Pt:Pt=null==(n=jt(Ot))?void 0:n.offsetHeight])}}let Rt=j(void 0),zt=j(void 0),Ot=j(void 0);const Nt=ye("mediaPaused");Gi((()=>{var t,e;if(D().videoTour){const i="timeline"in D().videoTour?D().videoTour.timeline:null==(e=null==(t=D().videoTour.i18n)?void 0:t[b()])?void 0:e.timeline;(null==i?void 0:i.length)&&D(D().view=i[0].rect,!0)}const i=[R().state.marker.subscribe((t=>{"string"==typeof t&&t==D().id?R().state.marker.set(D()):t==D()?async function(){var t,e;if(jt(gt))return;if(Y(gt,!0),$t(),G.noMarkerActions)return;x.dispatch("marker-open",D()),!g()||"steps"in g()&&(U(g())||g().cannotClose)||(C.set(void 0),await Xt());const i=g()&&"steps"in g();jt(Bt)||i&&rt||(P.set(void 0),T.state.popover.set(void 0)),St(),(null==it?void 0:it.markerId)&&(pt||(pt=T.canvases.find((t=>t.id==it.micrioId))),pt&&(xt=Ki(pt.visible),xt&&(null==it?void 0:it.view)&&pt.camera.flyToView(it.view,{isJump:!0}).catch((()=>{})))),void 0!==D().imageLayer&&R().state.layer.set(D().imageLayer);const r=ot&&lt&&ot!=g()&&null!=at&&at>0;r&&delete W.gridAction,r||!D().view||q.noAnimate||D().videoTour||W.gridView?Mt():ht?(R().camera.setView(D().view,{area:null==(t=R().opts)?void 0:t.area}),Mt()):R().camera.flyToView(D().view,{omniIndex:jt(qt),noTrueNorth:!0,area:null==(e=R().opts)?void 0:e.area,isJump:!!q.doJump||H&&!!E.$tour}).then(Mt).catch((()=>{g()||R().state.marker.set(void 0)}))}():q.alwaysOpen||(jt(gt)&&function(){var t;if(clearTimeout(It),x.dispatch("marker-closed",D()),D().videoTour&&R().openedView?setTimeout((()=>R().camera.aniDoneAdd.push((()=>{var t;return null==(t=jt(Rt))?void 0:t.focus()}))),10):null==(t=jt(Rt))||t.focus(),T.state.popover.set(void 0),!jt(Bt)){const t=g()&&"steps"in g();w()!=D()||t&&rt||P.set(void 0);const e=T.canvases.find((t=>t!=R()&&t.state.$marker));e&&Xt().then((()=>{const t=e.state.$marker;t&&"popup"==t.popupType&&P.set(t)}))}it&&pt&&setTimeout((()=>{var t,e;const i=Ki(T.state.marker);pt&&it.micrioId!=(null==(e=null==(t=null==i?void 0:i.data)?void 0:t._micrioSplitLink)?void 0:e.micrioId)&&T.close(pt)}),210)}(),Y(gt,Y(wt,!1),!0))}))];return jt(Ut)||(i.push(R().camera.image.state.view.subscribe(Dt)),Dt()),z()||Xt().then((()=>{jt(gt)&&!D().noMarker&&w()&&w()!=D()&&!g()?R().state.marker.set(void 0):(ht||q.alwaysOpen)&&Mt()})),D().htmlElement&&jt(zt)&&jt(zt).appendChild(D().htmlElement),()=>{var t;for(clearTimeout(It);i.length;)null==(t=i.shift())||t()}}));let Ft=J((()=>D().i18n?D().i18n[b()]:D())),Vt=J((()=>{var t,e,i,r;return!((null==(t=jt(Ft))?void 0:t.title)||(null==(e=jt(Ft))?void 0:e.body)||(null==(i=jt(Ft))?void 0:i.bodySecondary)||(null==(r=jt(Ft))?void 0:r.embedUrl)||D().images&&D().images.length)})),Ut=J((()=>z()||D().noMarker)),Bt=J((()=>"popup"!=D().popupType||jt(Vt))),qt=J((()=>R().camera.getOmniFrame((D().rotation??0)+(D().backside?Math.PI:0)))),Wt=J((()=>D().visibleArc?[R().camera.getOmniFrame(D().visibleArc[0]),R().camera.getOmniFrame(D().visibleArc[1])]:[])),Gt=J((()=>g()&&(!("steps"in g())&&!g().keepMarkers||G.hideMarkersDuringTour&&!tr(Nt,"$tourPaused",v))&&!jt(gt)));ee((()=>{jt(Gt)&&jt(Ct)&&M.update((t=>{const e=t.findIndex((t=>t[0]==D()));return e>=0&&t.splice(e,1),t}))}));let Yt=J((()=>"default"==D().type?void 0:"link"==D().type?"link":"media"==D().type?"play":"cluster"==D().type?void 0:D().type??void 0)),Ht=J((()=>{var t,e,i,r,n;return(null!=(null==(t=D().data)?void 0:t.customIconIdx)?null==(r=null==(e=R().$settings._markers)?void 0:e.customIcons)?void 0:r[null==(i=D().data)?void 0:i.customIconIdx]:void 0)??(null==(n=D().data)?void 0:n.icon)??G.markerIcon??void 0})),Zt=J((()=>!!jt(Yt)||!!jt(Ht))),Kt=J((()=>!("class"in D()&&""===D().class||!jt(Zt)&&"default"!=D().type))),Jt=J((()=>jt(Ft)&&(!Q||y()&&V)&&(jt(Ft).label||jt(Ft).title)));var Qt=Yo(),te=ut(Qt),ie=t=>{var e=Go();let i;e.__change=[qo,D,Dt];var r=ct(e),n=t=>{var e=jo();e.__click=[Bo,$t,D,G,f,_,R];var i=ct(e),r=t=>{var e=Wo();se((()=>xi(e,"src",jt(Ht).src))),Ye(t,e)},n=(t,e)=>{var i=t=>{En(t,{get name(){return jt(Yt)}})};ei(t,(t=>{jt(Yt)&&t(i)}),e)};ei(i,(t=>{jt(Ht)?t(r):t(n,!1)}));var s=dt(i,2),o=t=>{var e=Xo();fi(e,1,"micrio-marker",null,{},{static:et});var i=ct(e);qi(e,(t=>Y(Ot,t)),(()=>jt(Ot))),se((()=>{xi(e,"for",D().id),Ke(i,jt(Ft).label||jt(Ft).title)})),Ye(t,e)};ei(s,(t=>{jt(Jt)&&t(o)})),qi(e,(t=>Y(Rt,t)),(()=>jt(Rt))),se((()=>{xi(e,"title",nt||K?null:jt(Ft)?jt(Ft).label||jt(Ft).title:null),xi(e,"id",D().id)})),Fe("focus",e,Et),Fe("blur",e,$t),Fe("mouseenter",e,At),Fe("mouseleave",e,St),Ye(t,e)};ei(r,(t=>{D().htmlElement||t(n)})),qi(e,(t=>Y(zt,t)),(()=>jt(zt))),se((t=>{xi(e,"id",`m-${D().id}`),i=fi(e,1,hi(Z),"micrio-marker",i,t),wi(e,jt(yt)?`--mat:matrix3d(${jt(yt)})`:jt(kt)?`--x:${jt(kt)}px;--y:${jt(Tt)}px${tt?`;--scale:${jt(_t)}`:""}`:null)}),[()=>({overlapped:N()&&!jt(gt),cluster:K,behind:jt(bt),hovered:tr(I,"$hovered",v)==D().id,default:jt(Kt),mat3d:!!jt(yt),opened:jt(gt),"micrio-link":!!q.micrioLink,"has-icon":jt(Zt),"has-custom-icon":!!jt(Ht)})]),Ye(t,e)};ei(te,(t=>{jt(Ut)||!R()||jt(Gt)||t(ie)}));var re=dt(te,2),ne=t=>{Uo(0,{get marker(){return D()},get ctx(){return k()},get is360(){return R().is360}})};ei(re,(t=>{D().positionalAudio&&k()&&(!D().positionalAudio.noMobile||y())&&(D().positionalAudio.alwaysPlay||jt(gt))&&t(ne)})),Ye(t,Qt),_e(),p()}Ve(["change","click"]);var Zo=We("<div><!></div>");function Ko(t,e){var i,r;Te(e,!0);const[n,s]=ir(),o=()=>tr(u,"$_lang",n);let a=or(e,"settings",31,(()=>B({i18n:{}}))),l=or(e,"image",15);const c=ye("micrio"),{_lang:u,spaceData:d}=c,h=l().$info,m=l().$settings,v=null==(i=_r(e.targetId))?void 0:i[2],p=Cr(c,e.targetId);p||console.error(`[Micrio Waypoint] Could not calculate vector for target ${e.targetId}`);const{directionX:f,v:g,vN:w,vector:b}=p;let y=j(void 0);const k=Math.abs(w[1])<.3,T=k?.65:.5+w[1]/10,_={x:f,y:T,baseScale:h.width/1024,scale:1,rotX:(1+(k?-(1-T):w[1]))*Math.PI/2,rotY:0,rotZ:0},x=(null==(r=a())?void 0:r.coords)??(E=_,JSON.parse(JSON.stringify(E)));var E;let $,A=x.custom,S=A?x:_;function I(){var t;(null==(t=m._markers)?void 0:t.noMarkerActions)||(jt(y).parentNode.scrollTo(0,0),clearTimeout($),$=setTimeout((()=>{const t=l().camera.getXY(S.x,S.y);!jt(C)&&(t[0]<0||t[0]>=c.offsetWidth||t[1]<0||t[1]>=c.offsetHeight||l().is360&&t[3]>4)&&l().camera.flyToCoo([S.x,S.y],{speed:2,limit:!0}).catch((()=>{}))}),150))}let M=j(""),L=a().customIconIdx;const P=()=>{z.deleted?Y(R,!0):(L!=z.settings.customIconIdx&&(a(a().customIconIdx=z.settings.customIconIdx,!0),L=a().customIconIdx),x.custom!=A&&(A=x.custom,S=A?x:_),Y(M,l().camera.getMatrix(S.x,S.y,S.baseScale*S.scale,1,S.rotX,S.rotY,S.rotZ).join(","),!0))};let C=j(!1);function D(){var t;(null==(t=m._markers)?void 0:t.noMarkerActions)||(Y(C,!0),l(l().openedView=void 0,!0),l().state.marker.set(void 0),c.open(e.targetId,{vector:b}))}let R=j(!1);const z={coords:x,settings:a()};P(),Gi((()=>{z.el=jt(y),jt(y)._iface=z,c.dispatchEvent(new CustomEvent("wp-print",{detail:z}));const t=l().state.view.subscribe(P);return()=>t()}));let O=J((()=>{var t,e,i,r;return(null==(e=null==(t=a().i18n)?void 0:t[o()])?void 0:e.title)||(null==(r=null==(i=null==v?void 0:v.i18n)?void 0:i[o()])?void 0:r.title)})),N=J((()=>{var t;return null==(t=null==d?void 0:d.icons)?void 0:t[a().customIconIdx??-1]}));var F=Ge(),V=ut(F),U=t=>{var i=Zo();let r;var s=ct(i);const o=J((()=>jt(N)?void 0:"arrow-up")),a=J((()=>jt(O)??tr(Xr,"$i18n",n).waypointFollow));zn(s,{get type(){return jt(o)},get icon(){return jt(N)},onclick:D,onfocus:I,get title(){return jt(a)}}),qi(i,(t=>Y(y,t)),(()=>jt(y))),se((t=>{wi(i,`--matrix: matrix3d(${jt(M)??""})`),xi(i,"id",`w-${e.targetId}`),r=fi(i,1,"micrio-waypoint",null,r,t)}),[()=>({clicked:jt(C),active:jt(C),"direction-up":g[1]<0,"direction-down":g[1]>0})]),zi(3,i,(()=>Nr)),Ye(t,i)};ei(V,(t=>{jt(R)||t(U)})),Ye(t,F),_e(),s()}var Jo=Xe("<line></line>"),Qo=We('<article class="micrio-markers"><label> </label></article>'),ta=We('<article class="micrio-markers"><label> </label></article>'),ea=We('<svg class="micrio-markers"></svg> <aside class="micrio-markers"><section class="micrio-markers"></section> <section class="micrio-markers"></section></aside>',1),ia=We("<!> <!>",1),ra=We("<div><!> <!></div>"),na=We("<!> <!> <!>",1);function sa(t,e){var i;Te(e,!0);const[r,n]=ir(),s=()=>tr(v,"$settings",r),o=()=>tr($,"$inView",r),a=()=>tr(E,"$hoveredId",r),l=()=>tr(g,"$switching",r),c=()=>tr(h,"$data",r),u=()=>tr(w,"$_lang",r);let d=or(e,"image",15);const{data:h,info:m,settings:v}=d(),p=d().state.marker,f=d().wasm.micrio,{switching:g,_lang:w,state:b}=f,y=f.canvas.isMobile,k=null==(i=f.canvases[0])?void 0:i.grid,T=null==k?void 0:k.focussed,_=null==k?void 0:k.markersShown,x=s().clusterMarkerRadius??16,E=b.markerHoverId,$=Zi([]);ke("inView",$);const A=s()._markers??{},S=s().omni,I=!(!!A.noTitles||!!(null==S?void 0:S.sideLabels))&&!!A.showTitles;function M(t){var e;t?"string"==typeof t||d().openedView||t.noMarker||!t.view||d(d().openedView=f.state.$tour||null==(e=d().state.$view)?void 0:e.slice(0),!0):d().openedView&&!f.state.$tour&&Xt().then((()=>{var t,e;jt(K)||d().camera.aniDone||!d().openedView||d().camera.flyToView((e=d().openedView,[Math.max(0,e[0]),Math.max(0,e[1]),Math.min(1,e[2]),Math.min(1,e[3])]),{speed:null==(t=s()._markers)?void 0:t.zoomOutAfterCloseSpeed,noTrueNorth:!0}).catch((()=>{})),d(d().openedView=void 0,!0)}))}b.tour.subscribe((t=>{t&&"steps"in t&&t.keepLastStep&&d(d().openedView=void 0,!0)}));const L=[];let P=j(""),C=j(!1),D=j(!1);const R=t=>(t=null==t?void 0:t.map((t=>Math.round(100*t)/100)))&&Y(P,[...L,t[0]?`left: ${t[0]}px`:null,t[1]?`top: ${t[1]}px`:null,`width: ${t[2]}px`,`height: ${t[3]}px`].filter((t=>!!t)).join(";")+";");let z=j(B([])),O=x,N=j(B([]));const F=new Map,V=([t,e,i=0,r=0],[n,s,o=0,a=0])=>{const l=Math.max(r/2,O),c=Math.max(a/2,O);return!(t+i+O<n-O||t-O>n+o+O||e+l<s-c||e-l>s+c)},U=()=>{var t;if(!jt(tt))return Y(z,[],!0),void Y(N,[],!0);const e=jt(tt),i=[],r=e.length;let n=0,s=0;for(Y(z,[],!0),n=0;n<r;n++)for(s=n+1;s<r;s++){if(null==(t=e[s].tags)?void 0:t.includes("no-cluster"))continue;const r=F.get(e[n].id),o=F.get(e[s].id);if(r&&o&&V(r,o)){jt(z).push(n,s);const t=i.find((t=>t.findIndex((t=>t==n||t==s))>-1));t?t.push(n,s):i.push([n,s])}}Y(N,i.map((t=>t.filter(((e,i)=>t.indexOf(e)==i)))).map(((t,i)=>({title:t.length+"",type:"cluster",view:i=[0,1,2,3].map((i=>(i<2?Math.min:Math.max)(...t.map((t=>{var r;return(null==(r=e[t].view)?void 0:r[i])??(i%2==0?e[t].x:e[t].y)}))))),x:i[0]+(i[2]-i[0])/2,y:i[1]+(i[3]-i[1])/2,id:""+t,data:{},popupType:"none",tags:[]}))),!0)},q=[];Gi((()=>{const t=[];return br(m).then((e=>{var i,r,n;if(!e)return;Y(C,!!e.is360);const o=s()._markers;if(!o)return;const a=Number(e.version)>=4.2;o.markerIcon&&L.push(`--micrio-marker-icon: url("${o.markerIcon}")`),o.markerColor&&o.markerColor!=(a?"#ffffff":"#ffbb00")&&L.push("--micrio-marker-color: "+o.markerColor),o.markerSize&&o.markerSize!=(a?"16":"25")&&L.push("--micrio-marker-size: "+(O=Number(o.markerSize))+"px"),t.push(d().viewport.subscribe(R)),s().clusterMarkers&&(t.push(d().state.view.subscribe(U)),t.push(d().data.subscribe((()=>Xt().then(U))))),!d().grid&&(null==(i=s()._markers)?void 0:i.zoomOutAfterClose)&&t.push(d().state.marker.subscribe(M));!(!d().isOmni||!(null==(r=s().omni)?void 0:r.sideLabels)||(null==(n=s()._markers)?void 0:n.noTitles))&&t.push(y.subscribe((t=>{t&&jt(D)?function(){for(var t;q.length;)null==(t=q.shift())||t()}():t||jt(D)||(q.push(d().state.view.subscribe(H)),q.push(E.subscribe(H)),q.push(p.subscribe(H))),Y(D,!t)})))})),()=>{for(var e;t.length;)null==(e=t.shift())||e()}}));const W=t=>!t.noMarker;let X=j(void 0),G=j(B([]));function H(){Xt().then((()=>{if(!jt(X))return;const t=f.canvas,e=t.element.offsetWidth,i=[];o().forEach((([r,n,s])=>{var o;const l=null==(o=jt(X).querySelector('label[for="'+r.id+'"]'))?void 0:o.getBoundingClientRect();(null==l?void 0:l.width)&&l.width>0&&i.push([n*e,s,(n>=.5?l.left:l.right)-t.viewport.left,l.top+l.height/2-t.viewport.top,a()==r.id])})),Y(G,i,!0)}))}const Z=(t,e)=>{var i;return t.i18n?null==(i=t.i18n[e])?void 0:i.title:t.title};let K=J((()=>k&&tr(T,"$focussed",r)!=d()&&_&&Ki(_).indexOf(d())<0)),Q=J((()=>!l()&&f.spaceData?f.spaceData.links.filter((t=>t[0]==d().id||t[1]==d().id)).map((t=>{var e;return{targetId:t[0]==d().id?t[1]:t[0],settings:null==(e=t[2])?void 0:e[d().id]}})):void 0)),tt=J((()=>{var t,e;return jt(K)?[]:null==(e=null==(t=c())?void 0:t.markers)?void 0:e.filter(W)})),et=J((()=>{var t,e,i;return jt(K)?null==(t=c())?void 0:t.markers:null==(i=null==(e=c())?void 0:e.markers)?void 0:i.filter((t=>!W(t)))})),it=J((()=>{var t,e;return!(!(null==(t=jt(tt))?void 0:t.length)&&!(null==(e=jt(Q))?void 0:e.length))})),rt=J((()=>o().sort((([,,t],[,,e])=>t>e?1:t<e?-1:0))));var nt=na(),st=ut(nt),ot=t=>{var e=ea(),i=ut(e);ri(i,21,(()=>jt(G)),ii,((t,e)=>{var i=Jo();let r;se((t=>{xi(i,"x1",jt(e)[0]),xi(i,"y1",jt(e)[1]),xi(i,"x2",jt(e)[2]),xi(i,"y2",jt(e)[3]),r=fi(i,0,"micrio-markers",null,r,t)}),[()=>({hovered:jt(e)[4]})]),Ye(t,i)}));var r=dt(i,2),n=ct(r);ri(n,21,(()=>jt(rt).filter((([,t])=>t<.5))),(t=>t[0].id),((t,e)=>{var i=Qo(),r=ct(i);let n;var s=ct(r);se(((t,i)=>{xi(r,"for",jt(e)[0].id),n=fi(r,1,"micrio-markers",null,n,t),Ke(s,i)}),[()=>({hover:a()==jt(e)[0].id}),()=>Z(jt(e)[0],u())]),Fe("mouseenter",r,(()=>E.set(jt(e)[0].id))),Fe("mouseleave",r,(()=>E.set(void 0))),Ye(t,i)})),ri(dt(n,2),21,(()=>jt(rt).filter((([,t])=>t>=.5))),(t=>t[0].id),((t,e)=>{var i=ta(),r=ct(i);let n;var s=ct(r);se(((t,i)=>{xi(r,"for",jt(e)[0].id),n=fi(r,1,"micrio-markers",null,n,t),Ke(s,i)}),[()=>({hover:a()==jt(e)[0].id}),()=>Z(jt(e)[0],u())]),Fe("mouseenter",r,(()=>E.set(jt(e)[0].id))),Fe("mouseleave",r,(()=>E.set(void 0))),Ye(t,i)})),qi(r,(t=>Y(X,t)),(()=>jt(X))),Ye(t,e)};ei(st,(t=>{jt(D)&&jt(rt).length&&!tr(p,"$currentMarker",r)&&t(ot)}));var at=dt(st,2),lt=t=>{var e=ra();let i;var r=ct(e),n=t=>{var e=Ge();ri(ut(e),17,(()=>jt(Q)),(t=>t.targetId),((t,e)=>{Ko(t,nr({get image(){return d()}},(()=>jt(e))))})),Ye(t,e)};ei(r,(t=>{jt(Q)&&jt(Q).length&&t(n)}));var s=dt(r,2),o=t=>{var e=ia(),i=ut(e);ri(i,19,(()=>jt(tt)),(t=>t.id),((t,e,i)=>{const r=J((()=>jt(z).includes(jt(i))));Ho(t,{get marker(){return jt(e)},get image(){return d()},coords:F,get overlapped(){return jt(r)}})})),ri(dt(i,2),17,(()=>jt(N)),(t=>t.id),((t,e)=>{Ho(t,{get marker(){return jt(e)},get image(){return d()}})})),Ye(t,e)};ei(s,(t=>{jt(tt)&&t(o)})),se((t=>{wi(e,jt(it)?jt(P):null),i=fi(e,1,"micrio-markers",null,i,t)}),[()=>({"show-titles":I,is360:jt(C),inactive:jt(K)||jt(C)&&l()})]),Ye(t,e)};ei(at,(t=>{jt(it)&&t(lt)}));var ht=dt(at,2),mt=t=>{var e=Ge();ri(ut(e),17,(()=>jt(et)),(t=>t.id),((t,e)=>{Ho(t,{get marker(){return jt(e)},get image(){return d()},forceHidden:!0})})),Ye(t,e)};ei(ht,(t=>{jt(et)&&t(mt)})),Ye(t,nt),_e(),n()}const oa="5.3.2",aa="https://b.micr.io/",la="https://r2.micr.io/",ca=["ttBWO","IicaE","KLTce","xjQrB","pfhXT","rNIPa","rdFIY","mvRXc"],ua={b64:_b,ugz:_u},da="micrio-muted",ha={id:"",version:Number(oa.replace(/(\d+)\.(\d+).*/,"$1.$2")),path:aa,width:0,height:0,tileSize:1024,lang:"en",settings:{camspeed:1,view:[0,0,1,1],restrict:[0,0,1,1],focus:[.5,.5],zoomLimit:1,fullscreen:!0,crossfadeDuration:.25,hookEvents:!0,hookScroll:!0,hookPinch:!0,hookDrag:!0,minimap:!0,doTourJumps:!0,audio:!0,startVolume:1,mutedVolume:0,_markers:{showTitles:!1,popupAnimation:{duration:200,x:-50},zoomOutAfterClose:!0},ui:{controls:{cultureSwitch:!0}},_360:{},_meta:{}}},ma={STRINGS:{id:{r:!0},lang:{r:!0},"data-thumb":{f:"thumbSrc"},"data-title":{r:!0},"data-format":{r:!0},"data-extension":{r:!0,f:"tileExtension"},"data-tiles":{r:!0,f:"tilesId"},"data-path":{r:!0},"data-sources":{r:!0},"data-inittype":{f:"initType"},"data-type":{},"data-start":{f:"gallery.startId"},"data-gallery":{f:"gallery.archive"},"data-gallery-sort":{f:"gallery.sort"},"data-iiif":{r:!0,f:"iiifManifest"},"data-grid":{r:!0},"data-gallery-type":{f:"gallery.type"}},BOOLEANS:{"data-static":{},muted:{f:"audio",n:!0},"data-png":{r:!0,f:"isPng"},"data-webp":{r:!0,f:"isWebP"},"data-dz":{r:!0,f:"isDeepZoom"},"data-is360":{r:!0},"data-no-externals":{f:"noExternals"},"data-skipmeta":{f:"skipMeta"},"data-force-data-refresh":{f:"forceDataRefresh"},"data-keeprendering":{f:"keepRendering"},"data-coverlimit":{f:"limitToCoverScale"},"data-events":{f:"hookEvents"},"data-keys":{f:"hookKeys"},"data-zooming":{f:"noZoom",n:!0},"data-scroll-zoom":{f:"hookScroll"},"data-pinch-zoom":{f:"hookPinch"},"data-dragging":{f:"hookDrag"},"data-two-finger-pan":{f:"twoFingerPan"},"data-control-zoom":{f:"controlZoom"},"data-ui":{f:"noUI",n:!0},"data-gtag":{f:"noGTag",n:!0},"data-controls":{f:"noControls",n:!0},"data-logo":{f:"noLogo",n:!0},"data-logo-org":{f:"noOrgLogo",n:!0},"data-toolbar":{f:"noToolbar",n:!0},"data-show-info":{f:"showInfo"},"data-social":{},"data-fullscreen":{},"data-minimap":{},"data-minimap-hide":{f:"alwaysShowMinimap",n:!0},"data-omni-y":{f:"OmniTwoAxes"},"data-normalize-dpr":{f:"zoomLimitDPRFix"},"data-grid-clickable":{f:"gridClickable"},"data-gallery-spreads":{f:"gallery.isSpreads"},"data-freemove":{f:"freeMove"},"data-force-path":{f:"forceInfoPath",r:!0}},NUMBERS:{"data-version":{r:!0},height:{r:!0},width:{r:!0},volume:{f:"startVolume"},"data-tilesize":{r:!0,f:"tileSize"},"data-camspeed":{},"data-zoomlimit":{f:"zoomLimit"},"data-minimap-height":{f:"minimapHeight"},"data-minimap-width":{f:"minimapWidth"},"data-mutedvolume":{f:"mutedVolume"},"data-width-cm":{f:"cmWidth"},"data-height-cm":{f:"cmHeight"},"data-gallery-cover-pages":{f:"gallery.coverPages"},lazyload:{dN:0},"data-elasticity":{f:"dragElasticity"},"data-skip-base-levels":{f:"skipBaseLevels"}},ARRAYS:{"data-focus":{},"data-view":{}}};var va,pa,fa,ga,wa,ba,ya;pa=va||(va={}),fa=pa.Grid||(pa.Grid={}),(ga=fa.GridActionType||(fa.GridActionType={}))[ga.focus=0]="focus",ga[ga.flyTo=1]="flyTo",ga[ga.focusWithTagged=2]="focusWithTagged",ga[ga.focusTagged=3]="focusTagged",ga[ga.reset=4]="reset",ga[ga.back=5]="back",ga[ga.switchToGrid=6]="switchToGrid",ga[ga.filterTourImages=7]="filterTourImages",ga[ga.nextFadeDuration=8]="nextFadeDuration",wa=pa.Camera||(pa.Camera={}),(ba=wa.TimingFunction||(wa.TimingFunction={}))[ba.ease=0]="ease",ba[ba["ease-in"]=1]="ease-in",ba[ba["ease-out"]=2]="ease-out",ba[ba.linear=3]="linear";class ka{constructor(t){var e;if(this.image=t,this.center=[0,0,1],this.trueNorth=.5,this.aniDoneAdd=[],this.cooToArea=(t,e,i)=>({x:i[0]+t*(i[2]-i[0]),y:i[1]+e*(i[3]-i[1])}),this.viewToArea=(t,e)=>[...Object.values(this.cooToArea(t[0],t[1],e)),...Object.values(this.cooToArea(t[2],t[3],e))],this.getView=()=>{var t;return null==(t=this._view)?void 0:t.slice(0)},this.getCoo=(t,e,i=!1,r=!1)=>this.getCooDirect(t,e,i,r).slice(0).map((t=>Math.round(1e6*t)/1e6)),this.getXY=(t,e,i=!1,r,n,s)=>this.getXYDirect(t,e,{abs:i,radius:r,rotation:n,noTrueNorth:s}).slice(0),this.getScale=()=>this.center[2]??1,this.setScale=t=>this.setCoo(this.center[0],this.center[1],t),this.getCoverScale=()=>{var t;return(null==(t=this.e)?void 0:t._getCoverScale(this.image.ptr))??1},this.getMinScale=()=>{var t;return(null==(t=this.e)?void 0:t._getMinScale(this.image.ptr))??.1},this.isZoomedIn=()=>{var t;return 1==(null==(t=this.e)?void 0:t._isZoomedIn(this.image.ptr))},this.isZoomedOut=(t=!1)=>{var e;return 1==(null==(e=this.e)?void 0:e._isZoomedOut(this.image.ptr,t))},this.getCoverLimit=()=>{var t;return!!(null==(t=this.e)?void 0:t._getCoverLimit(this.image.ptr))},this.flyToView=(t,e={})=>new Promise(((i,r)=>{var n,s;if(!this.e)return r(new Error("Wasm not ready"));if(e.area&&(t=this.viewToArea(t,e.area)),e.prevView){const t=e.prevView;this.e._setStartView(this.image.ptr,t[0],t[1],t[2],t[3])}if(null==(n=this.image.$settings.omni)?void 0:n.frames){const i=(null==(s=this.image.$settings.omni.layers)?void 0:s.length)??1,r=this.image.$settings.omni.frames/i;null==e.omniIndex&&void 0!==t[5]&&(e.omniIndex=Math.round(lr(t[5]/(2*Math.PI))*r)),null!=e.omniIndex&&(e.omniIndex=lr(e.omniIndex,r))}const o=this.e._flyTo(this.image.ptr,t[0],t[1],t[2],t[3],e.duration??-1,e.speed??-1,e.progress??0,!!e.isJump,!!e.limit,!!e.limitZoom,e.omniIndex??0,!!e.noTrueNorth,va.Camera.TimingFunction[e.timingFunction??"ease"],performance.now());this.image.wasm.render(),0==o?i():this.setAniPromises(i,r)})),this.flyToFullView=(t={})=>this.flyToCoo([.5,.5,this.getMinScale()],t),this.flyToCoverView=(t={})=>{const e=this.image.$settings.focus??[.5,.5];return e[2]=this.getCoverScale(),this.flyToCoo(e,t)},this.flyToCoo=(t,e={})=>new Promise(((i,r)=>{if(!this.e)return r(new Error("Wasm not ready"));e.duration=this.e._setCoo(this.image.ptr,t[0],t[1],t[2]||this.center[2],e.duration??-1,e.speed??-1,e.limit??!1,va.Camera.TimingFunction[e.timingFunction??"ease"],performance.now()),this.image.wasm.render(),0==e.duration?i():this.setAniPromises(i,r)})),this.zoom=(t,e=0,i=void 0,r=void 0,n=1,s=!1)=>new Promise(((o,a)=>{if(!this.e)return a(new Error("Wasm not ready"));const l=this.getXY(this.center[0],this.center[1]);if(null==i&&(i=l[0]),null==r&&(r=l[1]),this.image.album&&!this.image.album.hooked)return o();e=this.e._zoom(this.image.ptr,t,i,r,e,n,s,performance.now()),this.image.wasm.render(),0==e?o():this.setAniPromises(o,a)})),this.zoomIn=(t=1,e=250,i=1)=>this.zoom(200*-t,e,void 0,void 0,i).catch((()=>{})),this.zoomOut=(t=1,e=250,i=1)=>{const r=this.image.wasm.micrio.canvas.viewport,n=r.width/r.height,s=this.image.$info.width/this.image.$info.height;return this.zoom(t*(400/Math.max(1,n/s/2)),e,void 0,void 0,i).catch((()=>{}))},this.getDirection=()=>{var t;return(null==(t=this.e)?void 0:t._getYaw(this.image.ptr))??0},this.getPitch=()=>{var t;return(null==(t=this.e)?void 0:t._getPitch(this.image.ptr))??0},!t.is360){const i=t.state.$view;i&&(null==(e=t.$info)?void 0:e.width)&&Xt().then((()=>this.setView(i)))}}assign(t,e,i,r,n,s){this.e=t,this._view=e,this._xy=i,this._coo=r,this._mat=n,this._quad=s}viewChanged(){var t;const e=this._view,i=this.center.join(","),r=this.getCoo(0,0);this.center[0]=e[0]+(e[2]-e[0])/2,this.center[1]=e[1]+(e[3]-e[1])/2,this.center[2]=r[2],this.image.is360&&(this.center[3]=r[3],this.center[4]=r[4]),this.image.isOmni&&(this.center[5]=null==(t=this.image.swiper)?void 0:t.currentIndex),(this.center.join(",")!=i||this.image.wasm.micrio.canvas.resizing||this.image.wasm.e._areaAnimating(this.image.ptr))&&this.image.state.view.set(this._view)}getXYDirect(t,e,i={}){var r;const n=this.image.is360&&!i.noTrueNorth?.5-((null==(r=this.image.$settings._360)?void 0:r.trueNorth)??.5):0;return this.e._getXY(this.image.ptr,t-n,e,!0===i.abs,i.radius,i.rotation),this._xy}getCooDirect(t,e,i=!1,r=!1){if(i){const i=this.image.wasm.micrio.getBoundingClientRect();t-=i.left,e-=i.top}return this.e._getCoo(this.image.ptr,t,e,!0===i,!0===r),this._coo}setView(t,e={}){this.e&&(e.area&&(t=this.viewToArea(t,e.area)),this.e._setView(this.image.ptr,t[0],t[1],t[2],t[3],!!e.noLimit,!1,e.correctNorth),e.noRender||this.image.wasm.render())}setCoo(t,e,i=this.center[2]??1){this.e&&(this.e._setCoo(this.image.ptr,t,e,i,0,0),this.image.wasm.render())}getQuad(t,e,i,r,n=0,s=0,o=0,a=1,l=1){return this.e?(this.e._getQuad(this.image.ptr,t,e,i,r,a,l,n,s,o),this._quad):new Float32Array(16)}getMatrix(t,e,i,r,n,s,o,a,l,c){return this.e?(this.e._getMatrix(this.image.ptr,t,e,i,r,n||0,s||0,o||0,a||0,l??1,c??1),this._mat):new Float32Array(16)}setMinScale(t){var e;null==(e=this.e)||e._setMinScale(this.image.ptr,t)}setMinScreenSize(t){var e;this.image.album||null==(e=this.e)||e._setMinSize(this.image.ptr,Math.max(0,Math.min(1,t??1)))}setLimit(t){this.e&&(this.e._setLimit(this.image.ptr,t[0],t[1],t[2],t[3]),this.image.wasm.render())}setCoverLimit(t){this.e&&this.e._setCoverLimit(this.image.ptr,!!t)}set360RangeLimit(t=0,e=0){this.e&&(this.e._set360RangeLimit(this.image.ptr,t,e),this.image.wasm.render())}setAniPromises(t,e){this.aniDone=t,this.aniAbort=e}pan(t,e,i=0,r={}){this.e&&(this.e._pan(this.image.ptr,t,e,i,!!r.noLimit,performance.now()),r.render&&this.image.wasm.render())}stop(){this.e&&this.e._aniStop(this.image.ptr)}pause(){this.e&&this.e._aniPause(this.image.ptr,performance.now())}resume(){this.e&&(this.e._aniResume(this.image.ptr,performance.now()),this.image.wasm.render())}aniIsKinetic(){var t;return!!(null==(t=this.e)?void 0:t._isKinetic(this.image.ptr))}setDirection(t,e){if(!this.e)return;const i=this.image.wasm;i.e._setDirection(this.image.ptr,t,e),i.render()}setArea(t,e={}){if(!this.e)return;const i=this.image.wasm.e;this.image.opts.isEmbed?this.image.ptr>0&&(this.image.opts.area=t,i._setImageArea(this.image.ptr,t[0],t[1],t[2],t[3])):(this.image.opts.area=t,i._setArea(this.image.ptr,t[0],t[1],t[2],t[3],!!e.direct,!!e.noDispatch)),e.noRender||this.image.wasm.render()}setRotation(t=0,e=0,i=0){!this.image.opts.isEmbed||this.image.ptr<=0||!this.e||(this.image.wasm.e._setImageRotation(this.image.ptr,t,e,i),this.image.wasm.render())}getOmniRotation(){var t,e;const i=this.image.$settings.omni;return i&&this.e?((null==(t=this.image.swiper)?void 0:t.currentIndex)??0)/(((null==i?void 0:i.frames)??1)/((null==(e=null==i?void 0:i.layers)?void 0:e.length)??1))*Math.PI*2:0}getOmniFrame(t){var e;const i=this.image.$settings.omni;if(!i||null==t)return;const r=i.frames/((null==(e=i.layers)?void 0:e.length)??1);return Math.floor(t/(2*Math.PI)*r)}getOmniXY(t,e,i){return this.e?(this.e._getOmniXY(this.image.ptr,t,e,i),this._xy):new Float64Array(5)}setOmniSettings(){const t=this.image,e=t.$settings.omni;e&&this.e&&(t.wasm.e._setOmniSettings(t.ptr,-e.distance||0,e.fieldOfView??0,e.verticalAngle??0,e.offsetX??0),this.image.state.view.set(this._view))}}(t=>{t.Main=class{constructor(t){this.micrio=t,this.tour=Zi(),this.marker=Zi(),this.markerHoverId=Zi(),this.popup=Zi(),this.popover=Zi(),this.ui={controls:Zi(!0),zoom:Zi(!0),hidden:Zi(!1)},this.mediaState=new Map,this.tour.subscribe((t=>{"string"!=typeof t&&(this._tour=t)})),this.marker.subscribe((t=>{"string"!=typeof t&&(this._marker=t)}))}get $tour(){return this._tour}get $marker(){return this._marker}get(){if(this.micrio.$current)return this.value={id:this.micrio.$current.id,c:this.micrio.canvases.map((t=>t.state.get()))},this._tour&&(this.value.t=[this._tour.id],"instance"in this._tour&&this._tour.instance&&this.value.t.push(this._tour.instance.currentTime,this._tour.instance.paused?"p":void 0)),this.value}async set(t){var e,i,r;if(this.value=t){if(void 0!==(null==(e=t.t)?void 0:e[1])){const e=t.t[0],i=this.mediaState.get(e);i?(i.currentTime=t.t[1],i.paused="p"==t.t[2]):this.mediaState.set(e,{currentTime:t.t[1],paused:"p"==t.t[2]})}if(null==(i=t.c)||i.forEach((t=>{if(void 0!==t[6]&&void 0!==t[7]){const e=t[6],i=this.mediaState.get(e);i?(i.currentTime=t[7],i.paused="p"==t[8]):this.mediaState.set(e,{currentTime:t[7],paused:"p"==t[8]})}})),t.t&&await this.setTour(t.t[0]),(null==(r=this.micrio.$current)?void 0:r.id)!=t.id&&(this.micrio.open(t.id),this.micrio.$current&&await br(this.micrio.$current.data,{allowUndefined:!0})),this.micrio.canvases.forEach((e=>{e.state.set(t.c.find((t=>t[0]==e.id)))})),t.t)return this.setTour(t.t[0]);{const e=t.c.find((e=>e[0]==t.id));e&&!e[5]&&this.micrio.$current&&this.micrio.$current.camera.flyToView(e.slice(1,5),{speed:2}).catch((()=>{}))}}}async setTour(t){var e,i,r;if(!this.micrio.$current||(null==(e=this._tour)?void 0:e.id)==t)return;const n=await br(this.micrio.$current.data,{allowUndefined:!0});n&&this.tour.set((null==(i=n.markerTours)?void 0:i.find((e=>e.id==t)))||(null==(r=n.tours)?void 0:r.find((e=>e.id==t))))}};t.Image=class{constructor(t){this.image=t,this.view=Zi(void 0),this.marker=Zi(void 0),this.layer=Zi(0);const e=t.wasm.micrio;let i,r,n;this.view.subscribe((s=>{this._view=s;const o=null==s?void 0:s.toString();if(s&&o&&i!=o){const a={image:t,view:s};i=o;const l=s[2]-s[0],c=s[3]-s[1];(!r||!n||Math.abs(l-r+(c-n))>1e-5)&&(e.events.dispatch("zoom",a),r=l,n=c),e.events.dispatch("move",a)}})),this.marker.subscribe((t=>{const i=this._marker;this._marker=t&&"string"!=typeof t?t:void 0,this._marker?e.state.marker.set(this._marker):t||e.state.$marker!=i||e.state.marker.set(void 0)}))}get $view(){return this._view}get $marker(){return this._marker}hookOmni(){const t=this.image;this.layer.subscribe((e=>{t.ptr<0||!t.wasm.e||(t.wasm.setActiveLayer(t.ptr,e),t.wasm.render())}))}get(){const t=this._marker,e=t?Array.from(this.image.wasm.micrio.state.mediaState).reverse().find((e=>e[0].startsWith(t.id))):null;return[this.image.id,...this._view?[].slice.call(this._view):[0,0,1,1],...t?[t.id,...e?[e[0],e[1].currentTime,e[1].paused?"p":void 0]:[]]:[void 0]].filter((t=>void 0!==t))}set(t){var e;(null==t?void 0:t.length)&&(this.view.set([t[1],t[2],t[3],t[4]]),t[5]?(null==(e=this._marker)?void 0:e.id)!=t[5]&&this.marker.set(t[5]):this._marker&&this.marker.set(void 0))}}})(ya||(ya={}));const Ta=new class{constructor(){this.data=new Map,this.db=new Map,this.images=[],this.get=t=>new Promise(((e,i)=>{const r=this.db.get(t);if(!r||!this.data.has(r[0]))return i(new Error("Could not get blob: "+t));const n=new FileReader;n.onload=()=>e(JSON.parse(n.result)),n.readAsText(new Blob([new Uint8Array(this.data.get(r[0]),r[1],r[2])]))})),this.getImage=async t=>new Promise(((e,i)=>{const r=this.db.get(t);if(!r||!this.data.has(r[0]))return i(new Error("Could not get blob: "+t));const n=new Blob([new Uint8Array(this.data.get(r[0]),r[1],r[2])]);if("createImageBitmap"in self)e(self.createImageBitmap(n));else{let t=this.images.find((t=>!t.src));t||this.images.push(t=new Image),t.onload=()=>{t&&(e(t),requestAnimationFrame((()=>{t&&(URL.revokeObjectURL(t.src),t.src=null)})))},t.src=URL.createObjectURL(n)}}))}async load(t,e,i){if(this.data.has(e))return;const r=e.replace(/^.*\//,"").split(".")[0],n=/\/base$/.test(e),s=n||Pr(r),o=new XMLHttpRequest,a=await new Promise(((r,n)=>{let a=0;o.responseType="arraybuffer",o.onprogress=t=>{a||(a=Number(o.getResponseHeader("Content-Length"))),null==i||i(Math.min(1,t.loaded/a))},o.onload=()=>{4===o.readyState&&200===o.status?(null==i||i(1),r(o.response)):n()},o.onerror=n,o.open("GET",t+e+(s?".bin":".mdp")),o.send()}));if(!a)return;this.data.set(e,a);const l=n?e.split("/")[0]+"/":"";let c=0;for(;c<a.byteLength&&!(c+32>a.byteLength);){const i=this.parseHeader(new Uint8Array(a,c,32));if(i.name&&i.size>0)this.db.set(t+l+i.name.replace("./",""),[e,c+32,i.size]);else if(0===i.size&&!i.name)break;c+=32+i.size}}parseHeader(t){const e=(new TextDecoder).decode(t),i=t=>e.slice(r,r+=t).replace(/\x00/g,"").trim();let r=0;return{name:i(20),size:parseInt(i(12),8)}}},_a=[];class xa{constructor(t,e,i={}){this.wasm=t,this.attr=e,this.opts=i,this.uuid=cr(),this.__info=JSON.parse(JSON.stringify(ha)),this.settings=Zi({}),this.data=Zi(void 0),this.video=Zi(void 0),this.visible=Zi(!1),this.ptr=-1,this.baseTileIdx=-1,this.is360=!1,this.isVideo=!1,this.isOmni=!1,this.levels=1,this.dzLevels=0,this.noImage=!1,this.opacity=1,this.viewport=Zi(),this.embeds=[],this.isV5=!1,this._loadedData=!1,this.embedElements=new Map,this.state=new ya.Image(this),i.useParentCamera||(this.camera=new ka(this)),this.id=(e.id??"").replace("https://i.micr.io/",""),this.isV5=Pr(this.id.split("/")[0]),this.infoBasePath=e.path&&e.forceInfoPath?e.path:void 0,this.dataPath=e.path||this.__info.path,this.isV5&&!e.path&&(this.dataPath=la),i.secondaryTo?(this.opacity=0,i.area=this.wasm.micrio.canvas.viewport.portrait?[0,1,1,1]:[1,0,1,1],void 0===i.isPassive&&(i.isPassive=!0)):i.area||(i.area=[0,0,1,1]),this.preset=_r(this.id);let r=!1;this.info={subscribe:Zi(void 0,(t=>{r?t(this.__info):this.load().then(t),r=!0})).subscribe};const n=this.wasm.micrio,s=!!this.attr.revision;let o,a=Ki(this.visible);i.isEmbed&&!s||this.visible.subscribe((t=>{t!=a&&(a=t,t&&!this._loadedData&&(!s&&this.isV5?(this._loadedData=!0,this.data.set(void 0)):this.loadData()),i.secondaryTo&&(i.isPassive&&(o?(o(),o=null):t&&(o=i.secondaryTo.state.view.subscribe((t=>{t&&!this.camera.aniDone&&this.camera.setView(t,{noLimit:!0})})))),t?n.events.dispatch("splitscreen-start",this):n.events.dispatch("splitscreen-stop",this)),n.visible.update((e=>(t?e.push(this):e.splice(e.indexOf(this),1),e))),t&&n.$current==this&&n.switching.set(!1))})),this.video.subscribe((t=>this._video=t)),this.data.subscribe((t=>((t,e,i)=>{var r,n,s,o,a;t&&(t.revision&&(t.revision=Object.fromEntries(Object.entries(t.revision??{}).filter((t=>Number(t[1])>0)))),null==(r=t.embeds)||r.forEach((t=>{t.uuid||(t.uuid=(t.id??t.micrioId)+"-"+Math.random()),$r(t.video),$r(t)})),null==(n=t.markers)||n.forEach((t=>Ir(t,e,!i))),null==(o=null==(s=t.music)?void 0:s.items)||o.forEach($r),null==(a=t.pages)||a.forEach(Sr))})(t,this.is360,this.isV5)))}get $info(){return this.__info}get $settings(){return Ki(this.settings)}get $data(){return Ki(this.data)}setError(t,e){throw this.wasm.micrio.printError(this.error=e??(null==t?void 0:t.message)??(null==t?void 0:t.toString())??"An unknown error has occurred"),this.wasm.micrio.loading.set(!1),t}async load(){var t,e,i,r,n,s,o,a,l,c,u,d,h,m,v,p,f,g,w,b;let y=this.__info;const k=this.attr,T=this.wasm.micrio;k.id&&k.width&&(k.settings&&vr(ha.settings,k.settings,{noOverwrite:!0}),this.__info=y=k);let _=y.iiifManifest||k.iiifManifest;y.isIIIF=this.id.startsWith("http")||"iiif"==y.format;const x=!!(null==(t=k.settings)?void 0:t.forceDataRefresh);if(!this.id||k.width&&k.height&&!_)(null==(o=this.preset)?void 0:o[1])&&vr(this.preset[1],y);else{const t=t=>this.setError(t,'Image with id "'+this.id+'" not found, published, or embeddable.');vr((null==(e=this.preset)?void 0:e[1])||await(y.isIIIF?Tr(this.id):xr(this.id,this.infoBasePath,x)).catch(t),y),!_&&y.iiifManifest&&(_=y.iiifManifest),y.isIIIF||(y.isIIIF=!!_),_&&vr(await Tr(_).catch(t),y),(null==(r=null==(i=y.settings)?void 0:i._meta)?void 0:r.noLogo)&&(y.settings.noLogo=!0),(null==(s=null==(n=y.settings)?void 0:n._meta)?void 0:s.noSmoothing)&&(y.settings.noSmoothing=!0)}const E="https://iiif.micr.io/";if(y.id.startsWith(E)&&(y.id=y.id.slice(21)),7==(null==(a=this.id)?void 0:a.length)){const t=Lr(this.id[1+Lr(this.id)%6]);y.is360=!!(t>>4&1),y.isWebP=!(3&t),y.isPng=2==(3&t),t>>3&1&&Pr(y.tilesId??this.id)&&(y.format="dz"),y.path||(y.path=`https://${t>>2&1?"eu":"r2"}.micr.io/`)}const $=this.isV5&&this.id.startsWith("i")&&!this.id.includes("/");$&&!y.tilesId&&(y.tilesId=this.id.slice(1));const A=ca.indexOf(y.id)>=0||y.tilesId&&ca.indexOf(y.tilesId)>=0;vr(k,y);const S=$&&!(null==(l=y.tileBasePath)?void 0:l.includes("micr.io"));if(this.tileBase=S?y.tileBasePath??aa:A||$?aa:y.tileBasePath??y.path??(this.isV5?la:aa),(null==(c=y.organisation)?void 0:c.baseUrl)&&!k.path?(this.dataPath=y.path=y.organisation.baseUrl,$&&!A||(this.tileBase=this.dataPath)):"https://eu.micr.io/"==y.path&&(this.dataPath=y.path),(null==(u=y.settings)?void 0:u.omni)&&(this.isOmni=!0,y.version>=5&&(await Ta.load(this.tileBase??this.dataPath,(y.tilesId??y.id)+"/base",(t=>{var e,i;return null==(i=null==(e=T._ui)?void 0:e.setProps)?void 0:i.call(e,{loadingProgress:t})})).catch((t=>this.setError(t,"Could not find object base package."))),y.settings.gallery||(y.settings.gallery={}),y.settings.gallery.type="omni",y.settings.gallery.archive=y.id)),!(null==(d=y.organisation)?void 0:d.branding)||y.settings&&y.settings.noUI||this.loadStyle(this.dataPath+"style/"+y.organisation.slug+".css").then((()=>{var t;const e=null==(t=getComputedStyle(this.wasm.micrio).getPropertyValue("--micrio-font-family"))?void 0:t.replace(/^'([^']+)'.*$/,"$1");e&&document.fonts.ready.then((()=>{document.fonts.check("16px "+e)||this.loadStyle(`https://fonts.googleapis.com/css2?family=${e}:ital,wght@0,300;0,400;0,500;0,600;0,800;1,300;1,400;1,500;1,600;1,800&display=swap`)}))})),y.isIIIF)if(y.sequences&&y.sequences.length)this.parseIIIFSequence(y,!!_);else{const t=(_||("@id"in y?y["@id"]:y.id)).replace("/info.json","");y.path=t.replace(/\/[^/]*$/,""),y.id=t.replace(/^.*\/([^/]*)$/,"$1")}if(y.spacesId&&!T.spaceData&&(T.spaceData="MICRIO_SPACE_DATA"in self?self.MICRIO_SPACE_DATA:await Tr("https://i.micr.io/spaces/"+y.spacesId+".json")),null==(h=y.settings)?void 0:h._360){const t=(null==(v=null==(m=T.spaceData)?void 0:m.images.find((t=>t.id==this.id)))?void 0:v.rotationY)??0;y.settings._360.trueNorth=.5+t/Math.PI/2}this.noImage=this.noImage||this.isOmni||!y.id&&!y.tilesId,this.extension=y.tileExtension||y.isPng&&"png"||y.isWebP&&"webp"||"jpg","dz"==y.format&&(y.isDeepZoom=!0),this.is360=!!y.is360,this.isVideo=!!y.isVideo;let I=this.isV5?Ki(T._lang):("cultures"in y?void 0:k.lang)??void 0;if(this.isV5){if(y.revision){const t=Object.keys(y.revision);t.length&&t.indexOf(I)<0&&(T.lang=t[0])}}else if(!(null==(p=y.settings)?void 0:p.skipMeta)&&"cultures"in y){const t=(y.cultures||"").split(","),e=this.opts.isEmbed||!!this.opts.area,i=(null==(f=y.settings)?void 0:f.onlyPreferredLang)||e;I=y.lang&&t.indexOf(y.lang)>=0?y.lang:i?void 0:t[0],I&&!e&&(T.lang=I)}const M=y.settings;M&&!(null==M?void 0:M.noExternals)&&await Promise.all([M.css?this.loadStyle(M.css.href):null,M.js?this.loadScript(M.js.href,I):null].filter((t=>!!t)));for(let P=y.tileSize;P<Math.max(y.width,y.height);P*=2,this.levels++);let L=Math.max(y.width,y.height);do{this.dzLevels++}while((L/=2)>1);return(null==(g=null==M?void 0:M.gallery)?void 0:g.archive)&&(this.levels-=1-(M.gallery.archiveLayerOffset??0)),this.noImage||(this.thumbSrc=this.getTileSrc(this.levels,0,0)),T.events.dispatch("pre-info",y),this.isV5&&null!=y.revision&&!this.opts.isEmbed?await this.loadData():(null==(w=y.settings)?void 0:w.skipMeta)||this.opts.isEmbed||this.isV5||T._lang.subscribe((t=>{var e,i;t&&this.id&&(!("cultures"in this.__info)||(this.__info.cultures||"").split(",").indexOf(t)<0)&&(t=void 0),this.data.set(void 0),!t&&(null==(e=this.preset)?void 0:e[2])&&(t="preset"),t&&this.id&&((null==(i=this.preset)?void 0:i[2])?this.enrichData(this.preset[2]).then((t=>{var e;this.data.set(t),(null==(e=this.preset)?void 0:e[2])&&(this.preset[2]=void 0)})):Tr(this.dataPath+this.id+"/data."+t+".json").catch((()=>{})).then((t=>t&&this.enrichData(t).then((t=>this.data.update((e=>(vr(t,e||(e={}),{mergeArrays:!0}),e))))))))})),(null==(b=y.settings)?void 0:b.micrioSplitLink)&&!this.opts.secondaryTo&&T.open({id:y.settings.micrioSplitLink,settings:{hookEvents:!1!==y.settings.secondaryInteractive}},{splitScreen:!0,isPassive:!y.settings.noFollow}),y.settings&&this.settings.set(y.settings),delete y.settings,this.isOmni&&this.state.hookOmni(),y}async loadData(){var t,e,i,r;const n=(null==(t=this.$settings)?void 0:t.skipMeta)||(null==(e=this.__info.settings)?void 0:e.skipMeta);if(this._loadedData||n)return Promise.resolve();this._loadedData=!0;const s=(null==(i=this.preset)?void 0:i[2])??(this.isV5&&await Tr(this.dataPath+this.id+"/data/pub.json",null==(r=this.__info.settings)?void 0:r.forceDataRefresh).catch((()=>{})));s&&this.enrichData(s).then((t=>this.data.set(t)))}getTileSrc(t,e,i,r){var n,s,o;const a=this.__info;if(a){if(a.isDeepZoom&&(t=this.dzLevels-t),a.isIIIF){const r=a.tileSize,n=Math.pow(2,t)*r,s=Math.min(a.width,e*n),o=Math.min(a.height,i*n),l=Math.min(a.width-s,n),c=Math.min(a.height-o,n),u=Math.round(Math.min(r,l/n*r)),d=Math.round(Math.min(r,c/n*r));return`${a.path}/${a.id}/${[s,o,l,c].join(",")}/${[u,d].join(",")}/0/default.jpg`}if(null==(o=null==(s=null==(n=a.settings)?void 0:n._360)?void 0:s.video)?void 0:o.src)throw"Video thumb";return`${this.tileBase}${a.tilesId||a.id}/${void 0!==r?r+"/":""}${t}/${e}${a.isDeepZoom?"_":"-"}${i}.${this.extension}`}}loadScript(t,e=""){return new Promise((i=>{if(_a.indexOf(t)>=0||document.querySelector('script[src="'+t+'"]'))i();else{_a.push(t);const r=document.createElement("script");r.type="text/javascript",r.async=!0,r.defer=!0,r.micrioElement=this.wasm.micrio,r.src=t.replace("$lang",e),r.onload=i,document.head.appendChild(r)}}))}loadStyle(t){return new Promise((e=>{if(_a.indexOf(t)>=0||document.head.querySelector('link[href="'+t+'"]'))e();else{_a.push(t);const i=document.createElement("link");i.setAttribute("type","text/css"),i.setAttribute("rel","stylesheet"),i.setAttribute("href",t),i.onload=e,document.head.appendChild(i)}}))}async enrichData(t){var e,i,r,n,s;if(!t)return t;"error"in t&&(this.__info.error="403"==t.status?"Could not load image data. Are you logged in and do you have the right credentials?":t.error);const o=this.wasm.micrio.lang,a=[];null==(e=t.markers)||e.forEach((t=>{var e;if(Ir(t,this.is360,!this.isV5),null==(e=t.data)?void 0:e.micrioSplitLink){const e=t.data.micrioSplitLink.split(",").map((t=>t.trim())),i=t.data._micrioSplitLink={micrioId:e[0],markerId:e[1],follows:!!e[2]&&"false"!=e[2]};i.markerId&&a.push(i.micrioId)}})),(null==(i=t.markerTours)?void 0:i.length)&&a.push(...[].concat.apply([],t.markerTours.map((t=>t.steps))).map((t=>t.split(",")[1])).filter((t=>!!t&&t!=this.id)));const l=t=>"autostart"in t&&t.autostart,c=(null==(r=t.markerTours)?void 0:r.find(l))||(null==(n=t.tours)?void 0:n.find(l));c&&(this.$settings.start={type:"steps"in c?"markerTour":"tour",id:c.id});const u=a.filter(((t,e)=>a.indexOf(t)==e));Promise.all(u.map((t=>xr(t,this.infoBasePath))));const d=t=>this.dataPath+(this.isV5?t+"/data/pub.json":t+"/data."+o+".json"),h=await Promise.all(u.map((t=>Tr(d(t)))));h.forEach(((t,e)=>{var i;return null==(i=null==t?void 0:t.markers)?void 0:i.forEach((t=>Ir(t,this.is360,5==u[e].length)))}));const m=this.wasm.micrio.spaceData;return t.markerTours&&(await Promise.all(t.markerTours.map((e=>Mr(this,e,o,t)))),m&&(t.markerTours=t.markerTours.filter((t=>!t.steps.find((t=>t.includes(","))))))),(null==m?void 0:m.markerTours)&&await Promise.all(m.markerTours.filter((t=>!t.stepInfo)).map((e=>Mr(this,e,o,t)))),null==(s=t.markers)||s.forEach((t=>{var e,i,r,n,s;if(!(null==(e=t.data)?void 0:e._micrioSplitLink))return;const o=null==(r=null==(i=t.data)?void 0:i._micrioSplitLink)?void 0:r.markerId;if(o)for(let a=0;a<h.length;a++){const e=null==(s=null==(n=h[a])?void 0:n.markers)?void 0:s.find((t=>t.id==o));if(e)return void(t.data._micrioSplitLink.view=e.view)}})),this.wasm.micrio.events.dispatch("pre-data",{[this.id]:t,...Object.fromEntries(u.map(((t,e)=>[t,h[e]])))}),h.forEach(((t,e)=>{if(t){const r=this.wasm.images.find((t=>t.id==u[e]));r&&r instanceof xa&&!r.$data&&(i=d(r.id),!yr.has(i))&&r.data.set(t)}var i})),t}parseIIIFSequence(t,e=!1){var i;const r=null==(i=t.sequences)?void 0:i[0];if(!r)return;const n="top-to-bottom"==r.viewingDirection,s=r.canvases.map((t=>t.images[0])).map((t=>t.resource));this.noImage=!0,t.width=n?Math.max(...s.map((t=>t.width))):s.reduce(((t,e)=>t+e.width),0),t.height=n?s.reduce(((t,e)=>t+e.height),0):Math.max(...s.map((t=>t.height)));let o=0,a=this.embeds;t.settings||(t.settings={}),e&&s.length>10&&(a=t.gallery=[],t.settings.gallery||(t.settings.gallery={})),s.forEach((e=>{const i=[(1-e.width/t.width)/2,(1-e.height/t.height)/2];a.push(new xa(this.wasm,{id:e.service["@id"],width:e.width,height:e.height,isPng:"image/png"==e.format,settings:{}},{area:n?[i[0],o/t.height,1-i[0],(o+e.height)/t.height]:[o/t.width,i[1],(o+e.width)/t.width,1-i[1]]})),o+=n?e.height:e.width}))}addEmbed(t,e,i={}){const r=e.slice(0),n=new xa(this.wasm,t,{area:r,isEmbed:!0,useParentCamera:i.asImage});return n.camera||(n.camera=this.camera),this.embeds.push(n),void 0===i.opacity&&(i.opacity=1),br(n.info).then((t=>{if(t){if("cover"==i.fit||"contain"==i.fit){const e=this.is360?2:1,n="cover"==i.fit,s=r[2]-r[0],o=r[3]-r[1],a=r[0]+s/2,l=r[1]+o/2,c=s/o*e,u=t.width/t.height;if(n&&u<c||!n&&u>=c){const t=s/u*e;r[1]=l-t/2,r[3]=l+t/2}else{const t=o*u/e;r[0]=a-t/2,r[2]=a+t/2}}this.wasm.addEmbed(n,this,i),this.wasm.render()}})),n}setEmbedMediaElement(t,e){e?this.embedElements.set(t,e):this.embedElements.delete(t)}getEmbedMediaElement(t){return this.embedElements.get(t)}splitStart(){var t,e,i;const r=this.wasm.micrio.canvas.viewport.portrait;null==(t=this.opts.secondaryTo)||t.camera.setArea(r?[0,0,1,.5]:[0,0,.5,1],{noRender:!0}),this.camera.setArea(r?[0,.5,1,1]:[.5,0,1,1],{noRender:!0}),this.camera.setView((null==(i=null==(e=this.__info)?void 0:e.settings)?void 0:i.view)??[0,0,1,1]),this.wasm.render()}splitEnd(){var t,e;const i=this.opts.area;if(!i)return;const r=i[2]-i[0],n=i[3]-i[1];if(Math.round(1e3*r)/1e3==0||Math.round(1e3*n)/1e3==0)return;const s=r>n;this.camera.setArea(s?[0,1,1,1]:[1,0,1,1],{noRender:!0}),(null==(t=this.opts.secondaryTo)?void 0:t.grid)&&this.opts.secondaryTo.camera.aniDone||null==(e=this.opts.secondaryTo)||e.camera.setArea([0,0,1,1],{noRender:!0}),this.wasm.render()}fadeIn(t=!1){this.wasm.fadeImage(this.ptr,1,t),this.wasm.render()}fadeOut(t=!1){this.wasm.fadeImage(this.ptr,0,t),this.wasm.render()}}class Ea{constructor(t,e,i,r,n){var s,o,a;this.wasm=t,this.image=e,this.embed=i,this.paused=r,this.moved=n,this.ism3u=!1,this.hlsPlayer=void 0,this.usVid=void 0,this.vidRepeatTo=void 0,this.placeTo=void 0,this.autoplay=!0,this._vid=void 0,this.isMounted=!0,this.events={play:()=>this.setPlaying(!0),pause:()=>this.setPlaying(!1),playing:()=>{this.image._video||this.image.video.set(this._vid)},canplayEvt:mr.iOS?"loadedmetadata":"canplay",canplay:()=>{this._vid&&this.isMounted&&(this.autoplay&&!this.paused?(this._vid.play().catch((t=>console.warn("WebGL Embed video play() failed on canplay:",t))),this.moved()):this.embed.hideWhenPaused||(this.setPlaying(!0),Xt().then((()=>{this.setPlaying(!1),setTimeout((()=>{var t;return null==(t=this._vid)?void 0:t.remove()}),50)}))))}},this.ism3u=!!(null==(s=i.video)?void 0:s.streamId)&&!(null==(o=i.video)?void 0:o.transparent),this._vid=e._video,this.autoplay=(null==(a=i.video)?void 0:a.autoplay)??!0;let l=!0;this.usVid=this.image.visible.subscribe((t=>{clearTimeout(this.placeTo),this.placeTo=t?setTimeout((()=>{this.isMounted&&(this._vid?(this.hook(),this.autoplay&&!this.paused&&this._vid.play().catch((t=>console.warn("WebGL Embed video play() failed",t)))):this.load())}),l?0:100):setTimeout((()=>{var t;return null==(t=this._vid)?void 0:t.pause()}),0),l=!1}))}unmount(){var t,e;this.isMounted=!1,clearTimeout(this.placeTo),clearTimeout(this.vidRepeatTo),null==(t=this._vid)||t.pause(),this.unhook(),null==(e=this.usVid)||e.call(this)}setPlaying(t){this._vid&&(this.paused=!t,t?this._vid.dataset.playing="1":delete this._vid.dataset.playing,this.wasm.e._setImageVideoPlaying(this.image.ptr,t),this.embed.hideWhenPaused&&this.wasm.fadeImage(this.image.ptr,t?1:0),t&&this.wasm.render())}load(){if(!this.embed.video||this._vid)return;const t=this.ism3u?`https://videodelivery.net/${this.embed.video.streamId}/manifest/video.m3u8`:this.embed.video.src;t?(this._vid=document.createElement("video"),this._vid.crossOrigin="anonymous",this._vid.playsInline=!0,this._vid.width=.5*this.embed.width,this._vid.height=.5*this.embed.height,this._vid.muted=this.embed.video.muted,this.hook(),!this.ism3u||Dr(this._vid)?this._vid.src=t:gr("https://i.micr.io/hls-1.5.17.min.js",void 0,"Hls"in window?{}:void 0).then((()=>{this.hlsPlayer=new window.Hls,this.hlsPlayer.loadSource(t),this._vid&&this.hlsPlayer.attachMedia(this._vid)})).catch((t=>console.error("[Micrio GL Embed] Failed to load HLS.js:",t)))):console.error("[Micrio GL Embed] No video source found for embed:",this.embed.id)}hook(){if(!this.embed.video||!this._vid)return;const t=this.embed.video.loopAfter;this.embed.video.loop&&t?(this._vid.loop=!1,this._vid.onended=()=>{this.setPlaying(!1),this.vidRepeatTo=setTimeout((()=>{var t;return null==(t=this._vid)?void 0:t.play().catch((t=>console.warn("WebGL Embed video loop play() failed:",t)))}),1e3*t)},this._vid.onplay=()=>this.setPlaying(!0)):(this._vid.loop=this.embed.video.loop,this._vid.onended=null,this._vid.onplay=null),this._vid.parentNode||this.autoplay||this.ism3u||(this._vid.setAttribute("style","opacity:0;position:absolute;top:0;left:0;transform-origin:left top;transform:scale(0.1);pointer-events:none;"),document.body.appendChild(this._vid)),this._vid.addEventListener("play",this.events.play),this._vid.addEventListener("pause",this.events.pause),this._vid.addEventListener("playing",this.events.playing,{once:!0}),this._vid.addEventListener(this.events.canplayEvt,this.events.canplay,{once:!0})}unhook(){this._vid&&(this._vid.removeEventListener("play",this.events.play),this._vid.removeEventListener("pause",this.events.pause),this._vid.removeEventListener("playing",this.events.playing),this._vid.removeEventListener(this.events.canplayEvt,this.events.canplay),this._vid.onended=null,this._vid.onplay=null)}}var $a=We('<img alt="Embed" data-scroll-through="" class="micrio-embed">'),Aa=We('<button data-scroll-through="" aria-label="embed-button" class="micrio-embed"></button>');function Sa(t,e){var i,r;Te(e,!0);const[n,s]=ir(),o=()=>tr(l,"$current",n),a=ye("micrio"),{current:l,wasm:c,canvas:u}=a;let d=or(e,"embed",15);const h=o(),m=h.$info;d().uuid||d(d().uuid=cr(),!0);const v=d().uuid,p=h.is360,f=(null==(i=d().video)?void 0:i.autoplay)??!0;let g=h.embeds.find((t=>{var e;return t.uuid==v||(null==(e=t.$info)?void 0:e.title)==v}));const w=window.matchMedia("(dynamic-range: high)").matches||mr.OSX,b=d().area,y=null==(r=d().src)?void 0:r.toLowerCase().endsWith(".svg"),k=!(!d().width||!d().height)&&d().width*d().height<Math.pow(1024,2),T=/iPhone OS 14_/i.test(navigator.userAgent),_="data-embeds-inside-gl",x=a.getAttribute(_),E=!(y||T||!w&&!a.hasAttribute(_)||"false"==x||(!d().micrioId||k&&d().src)&&(!d().video||d().video.controls||d().video.transparent)),$=!d().clickAction&&!d().frameSrc,A="href"==d().clickAction?d().clickTarget:void 0,S=A&&d().clickTargetBlank;let I=b[2]-b[0],M=b[3]-b[1],L=b[0]+I/2,P=b[1]+M/2,C=d().scale||1,D=d().rotX??0,R=d().rotY??0,z=d().rotZ??0,O=d().scaleX??1,N=d().scaleY??1,F=j("");function V(){const t=d().area;p&&t[0]>t[2]&&t[0]--,I=t[2]-t[0],M=t[3]-t[1],L=t[0]+I/2,P=t[1]+M/2,C=d().scale||1,D=d().rotX??0,R=d().rotY??0,z=d().rotZ??0,O=d().scaleX??1,N=d().scaleY??1,Y(F,`--ratio:${I/M*m.width/m.height};--scale:${I*m.width/(d().width??100)/(E?1:C)*(p?Math.PI/2:1)};`),y&&Y(F,jt(F)+`height:${d().height}px`),E&&d().micrioId&&d().width&&Y(F,jt(F)+`width:${d().width}px`)}V();let U,B=J((()=>Math.round(I*m.width))),q=J((()=>Math.round(M*m.height))),W=j(!1),X=j(0),G=j(0),H=j(""),Z=j("");function K(){var t,e,i,r,n;if(h.camera.e&&(n=h.camera.getXYDirect(L,P),Y(X,n[0],!0),Y(G,n[1],!0),U=n[2],p&&Y(H,h.camera.getMatrix(L,P,C,1,D,R,z,void 0,O,N).join(","),!0),Y(Z,(p?`transform:matrix3d(${jt(H)});`:`--x:${jt(X)}px;--y:${jt(G)}px;--s:${U};`)+(void 0!==d().opacity&&1!==d().opacity?`--opacity:${d().opacity};`:"")),((null==(t=d().video)?void 0:t.pauseWhenSmallerThan)||(null==(e=d().video)?void 0:e.pauseWhenLargerThan))&&jt(B))){const t=jt(W);Y(W,function(){var t,e;if(!(null==(t=d().video)?void 0:t.pauseWhenSmallerThan)&&!(null==(e=d().video)?void 0:e.pauseWhenLargerThan))return!f;const i=U?Math.max(jt(B)*U/u.viewport.width,jt(q)*U/u.viewport.height):0;return!!(d().video.pauseWhenSmallerThan&&i<d().video.pauseWhenSmallerThan||d().video.pauseWhenLargerThan&&i>d().video.pauseWhenLargerThan)}(),!0),(null==(i=jt(rt))?void 0:i._vid)&&jt(W)!=t&&(jt(W)?jt(rt)._vid.pause():((null==(r=null==h?void 0:h.$settings)?void 0:r.embedRestartWhenShown)&&(jt(rt)._vid.currentTime=0),jt(rt)._vid.play()))}}function Q(){o()&&"markerId"==d().clickAction&&d().clickTarget&&o().state.marker.set(d().clickTarget)}function tt(t){if(t&&"detail"in t){const e=t.detail;for(const t in e)d(d()[t]=e[t],!0)}V(),K()}const et=Zi(!1);d().video&&(d().video.controls||d(d().video.muted=!0,!0));const it=E&&!!d().video;let rt=j(void 0);const nt=!E||!!d().clickAction;let st=j(void 0);ee((()=>{var t;d().video&&d().id&&o()&&o().setEmbedMediaElement(d().id,jt(st)??(null==(t=jt(rt))?void 0:t._vid))}));let ot=J((()=>d().video?Math.min(d().video.width,jt(B)):jt(B))),at=J((()=>d().video?Math.min(d().video.height,jt(q)):jt(q))),lt=J((()=>jt(B)/jt(ot)));Gi((()=>{var t,e;const i=[];return E&&function(){const t=d().hideWhenPaused?.01:d().opacity??1;g&&g.ptr>=0?(g.camera.setArea(d().area),g.camera.setRotation(d().rotX,d().rotY,d().rotZ),c.fadeImage(g.ptr,t)):g=h.addEmbed({id:d().video?d().id:d().micrioId,title:v,width:d().width,height:d().height,isPng:d().isPng,isWebP:d().isWebP,isDeepZoom:d().isDeepZoom,path:m.tileBasePath??m.path,isSingle:!!d().video,isVideo:!!d().video,settings:{_360:{rotX:D,rotY:R,rotZ:z}}},d().area,{opacity:t,asImage:!1}),it&&br(g.visible,{targetValue:!0}).then((()=>{Y(rt,new Ea(c,g,d(),jt(W),K),!0)})),c.render()}(),(nt||(null==(t=d().video)?void 0:t.pauseWhenSmallerThan)||(null==(e=d().video)?void 0:e.pauseWhenLargerThan))&&i.push(h.state.view.subscribe(K)),()=>{var t,e;for(null==(t=jt(rt))||t.unmount(),g&&g.ptr>=0&&(c.fadeImage(g.ptr,0),c.render()),d().video&&d().id&&o()&&o().setEmbedMediaElement(d().id);i.length;)null==(e=i.shift())||e()}}));var ct=Ge(),dt=ut(ct),ht=t=>{var e=Ge();ui(ut(e),(()=>A?"a":"div"),0,((t,e)=>{let i;se((()=>i=$i(t,i,{id:d().id?"e-"+d().id:void 0,style:jt(Z),role:A?void 0:"figure",onclick:Q,onkeypress:Q,onchange:tt,href:A,target:A&&S?"_blank":null,class:"",[bi]:{"embed-container":!0,embed3d:p,"no-events":$}},"micrio-embed")));var r=Ge(),n=ut(r),s=t=>{const e=J((()=>d().video.streamId&&!d().video.transparent?"cfvid://"+d().video.streamId:d().video.src)),i=J((()=>!jt(W)&&d().video.autoplay)),r=J((()=>d().video.transparent&&d().video.hasH265));Ms(t,{get forcePause(){return jt(W)},get src(){return jt(e)},get width(){return jt(ot)},get height(){return jt(at)},get frameScale(){return jt(lt)},get controls(){return d().video.controls},destroying:et,get loop(){return d().video.loop},get loopDelay(){return d().video.loopAfter},get muted(){return d().video.muted},get autoplay(){return jt(i)},get hasTransparentH265(){return jt(r)},get _media(){return jt(st)},set _media(t){Y(st,t,!0)}})},o=(t,e)=>{var i=t=>{Ms(t,{get src(){return d().frameSrc},get width(){return jt(B)},get height(){return jt(q)},get frameScale(){return d().scale},get autoplay(){return d().autoplayFrame},destroying:et})},r=(t,e)=>{var i=t=>{var e=$a();se((()=>{xi(e,"src",d().src),wi(e,jt(F)),xi(e,"width",y?d().width:void 0),xi(e,"height",y?d().height:void 0)})),Ye(t,e)},r=t=>{var e=Aa();se((()=>{wi(e,jt(F)),xi(e,"title",d().title)})),Ye(t,e)};ei(t,(t=>{!E&&d().src?t(i):t(r,!1)}),e)};ei(t,(t=>{d().frameSrc?t(i):t(r,!1)}),e)};ei(n,(t=>{d().video&&!E?t(s):t(o,!1)})),Ye(e,r)})),Ye(t,e)};ei(dt,(t=>{nt&&(jt(H)||jt(X)||jt(G))&&t(ht)})),Ye(t,ct),_e(),s()}var Ia=Xe('<svg width="100" height="100" class="micrio-progress-circle"><circle fill="transparent" stroke="#e0e0e0" stroke-width="8px" class="micrio-progress-circle"></circle><circle fill="transparent" stroke="#00d4ee" stroke-width="8px" class="micrio-progress-circle"></circle></svg>');var Ma=We("<!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!>",1);const La=!self.createImageBitmap,Pa=URL.createObjectURL(new Blob(["let controller = null, prevUri = null;\nself.addEventListener('message', e => {\n\t// Handle abort message\n\tif(e.data == 'abort') return controller && controller.abort();\n\t// Create new AbortController for this fetch\n\tcontroller = new AbortController();\n\t// Fetch the image blob\n\tfetch(e.data.src, { signal: controller.signal })\n\t\t.then(r => r.blob())"+(La?"\n\t\t// Fallback for older Safari: create Object URL\n\t\t.then(blob => {\n\t\t\t// Revoke previous Object URL to free memory\n\t\t\tURL.revokeObjectURL(prevUri);\n\t\t\t// Post Object URL back\n\t\t\tself.postMessage({src: (prevUri = URL.createObjectURL(blob, {type: e.data.type}))})\n\t\t})":"\n\t\t// If createImageBitmap is supported, use it (preferred)\n\t\t.then(blob => self.createImageBitmap(blob))\n\t\t// Post ImageBitmap back, transferring ownership\n\t\t.then(data => self.postMessage({data:data, src:e.data.src}, [data]))")+"\n\t\t// Handle fetch errors (including abort)\n\t\t.catch(err => self.postMessage({error: e.data.src+': '+err.message, type: err.name}))\n})"],{type:"text/javascript"})),Ca=Math.max(2,Math.min(6,(navigator.hardwareConcurrency||2)-1)),Da=[],Ra=new Map,za=new Map,Oa=[],Na=new Map;for(let ml=0;ml<Ca;ml++){const t=new Worker(Pa);t.onmessage=t=>Va(ml,t.data.src,t.data.data,t.data.error,t.data.type),Ra.set(ml,t),La&&za.set(ml,new Image)}const Fa=t=>new Promise(((e,i)=>{Oa.push([t,e,i]),function(){if(!Oa.length)return;let t=0;for(;t<Ca&&!(Da.indexOf(t)<0);t++);if(t>=Ca)return;Da.push(t);const e=Oa.shift();if(!e)return void Da.splice(Da.indexOf(t),1);Na.set(t,e);const i=Ra.get(t);if(!i)return console.error(`[Micrio Texture] Worker ${t} not found!`),e[2]("Internal error: Worker not found"),void Da.splice(Da.indexOf(t),1);i.postMessage({src:e[0],type:"image/"+e[0].split(".").pop()})}()}));function Va(t,e,i,r,n){const s=Na.get(t);if(null!=s)if(Na.delete(t),setTimeout((()=>{Da.splice(Da.indexOf(t),1)}),50),r)s[2](r),"AbortError"!=n&&console.error(`[Micrio Texture] Error loading ${s[0]}: ${n} - ${r}`);else if(i)s[1](i);else if(e&&La){const i=za.get(t);if(!i)return void s[2]("Internal error: Image element fallback not found");i.onload=()=>{s[1](i)},i.onerror=()=>{s[2](`Failed to load image from Object URL: ${e}`)},i.src=e}else s[2](`Worker ${t} sent invalid message.`),console.error(`[Micrio Texture] Worker ${t} sent invalid message for ${s[0]}`);else console.warn(`[Micrio Texture] Received message from worker ${t} but no matching promise found.`)}function Ua(){return Da.length}function Ba(t){const e=[...Na.entries()].find((e=>e[1][0]==t));if(null==e)return;const i=Ra.get(e[0]);i&&i.postMessage("abort")}const qa=ua.ugz?ua.ugz(ua.b64,!0):fetch("http://localhost:2000/build/optimized.wasm").then((t=>t.arrayBuffer())),Wa=class t{constructor(t){this.micrio=t,this.ready=!1,this.memory=new self.WebAssembly.Memory({initial:100,maximum:100}),this.b=this.memory.buffer,this.i=-1,this.c=-1,this.now=-1,this.raf=-1,this.drawing=!1,this.images=[],this.bareBone=!1,this.baseTiles=[],this.drawn=[],this.prevDrawn=[],this.toDelete={},this.textures={},this.requests=new Map,this.timeouts={},this.tileLoaded={},this.tileOpacity={},this.loadStates={},this.unsubscribe=[],this.cameras=new Map,this.preventDirectionSet=!1,this._pMatrices={},this.isGallery=!1,this.imports={env:{memory:this.memory,abort:console.error},main:{"console.log":console.log,"console.log2":console.log,"console.log3":console.log,"console.log4":console.log,drawTile:this.drawTile.bind(this),drawQuad:t=>this.micrio.webgl.drawTile(void 0,t),aniAbort:t=>{const e=this.cameras.get(t);e&&(e.aniAbort&&e.aniAbort(),e.aniDoneAdd.length=0,e.aniAbort=e.aniDone=void 0)},aniDone:t=>{var e;const i=this.cameras.get(t);if(i){for(i.aniDone&&i.aniDone();i.aniDoneAdd.length;)null==(e=i.aniDoneAdd.shift())||e();i.aniAbort=i.aniDone=void 0}},getTileOpacity:t=>this.tileOpacity[t],setTileOpacity:(t,e=!1,i=1)=>{const r=this.tileOpacity,n=this.tileLoaded;return(!r[t]||r[t]<1)&&(r[t]=e?1:n[t]>0?Math.min(1,(this.now-n[t])/250)*i:0),r[t]||0},setMatrix:t=>this.micrio.webgl.gl.uniformMatrix4fv(this.micrio.webgl.pmLoc,!1,this._pMatrices[t]),setViewport:(t,e,i,r)=>this.micrio.webgl.gl.viewport(Math.floor(t),Math.floor(e),Math.ceil(i),Math.ceil(r)),viewSet:t=>{var e;return null==(e=this.cameras.get(t))?void 0:e.viewChanged()},viewportSet:(t,e,i,r,n)=>{const s=this.images.find((e=>e.ptr==t));s&&"camera"in s&&s.viewport.set([e,i,r,n])},setVisible:(t,e)=>{var i;return null==(i=this.images.find((e=>e.ptr==t)))?void 0:i.visible.set(1===e)},setVisible2:(t,e)=>{var i;return null==(i=this.images.find((e=>e.ptr==t)))?void 0:i.visible.set(1===e)}}},this.addImage=async(t,e,i=!1,r=1)=>br(t.info).then((n=>{if(!n)return;this.images.push(t);const s=t.opts.area??[0,0,1,1],o=t.$settings._360??{};if(t.ptr=i?this.e._addImage(e.ptr,s[0],s[1],s[2],s[3],n.width,n.height,n.tileSize||1024,n.isSingle??!1,n.isVideo??!1,r,o.rotX??0,o.rotY??0,o.rotZ??0,o.scale??1,0):this.e._addChild(e.ptr,s[0],s[1],s[2],s[3],n.width,n.height),!i){this.bindCamera(t),t.$settings.focus&&this.e._setCoo(t.ptr,t.$settings.focus[0],t.$settings.focus[1],0,0,performance.now());const e=this.e._getPMatrix(t.ptr);this._pMatrices[e]=new Float32Array(this.b,e+32,16);const i=t.$info.view;i&&"0,0,1,1"!=i.toString()&&this.e._setView(t.ptr,i[0],i[1],i[2],i[3]),this.e._sendViewport(t.ptr)}this.tileOpacity[t.baseTileIdx=this.e.getNumTiles(this.i)-1]=1,this.baseTiles.push(t.baseTileIdx)})),this.addChild=(t,e)=>this.addImage(t,e),this.render=this.render.bind(this),this.draw=this.draw.bind(this),this.unsubscribe.push(t.current.subscribe(this.setCanvas.bind(this)))}static getTextureBuffer(t,e){const i=new Float32Array(12*t*e),r=1/t,n=1/e;for(let s=0,o=0;o<e;o++)for(let e=0;e<t;e++,s+=12)i[s+3]=i[s+7]=i[s+9]=(i[s+1]=i[s+5]=i[s+11]=o*n)+n,i[s+4]=i[s+8]=i[s+10]=(i[s+0]=i[s+2]=i[s+6]=e*r)+r;return i}async load(){if(this.i>=0)return;this.i=0;const e=await qa;if(!(e instanceof Uint8Array||e instanceof ArrayBuffer))throw"Wasm binary is no array buffer!";const i=await self.WebAssembly.instantiate(e,this.imports);this.e=i.instance.exports,this.i=this.e.constructor(),t.segsX=this.e.segsX.value,t.segsY=this.e.segsY.value,t._textureBuffer360=t.getTextureBuffer(t.segsX,t.segsY),this._vertexBuffer=new Float32Array(this.b,this.e.getVertexBuffer(this.i)+32,18),this._vertexBuffer360=new Float32Array(this.b,this.e.getVertexBuffer360(this.i)+32,18*t.segsX*t.segsY),this.unsubscribe.push(this.micrio.barebone.subscribe((t=>this.e.setBareBone(this.i,this.bareBone=t))))}unbind(){var t;for(this.stop();this.unsubscribe.length;)null==(t=this.unsubscribe.shift())||t();this.requests.forEach((t=>Ba(t))),this.requests.clear();for(let e in this.timeouts)clearTimeout(this.timeouts[e]);this.timeouts={},this.loadStates={},this.tileLoaded={},this.tileOpacity={};for(let e in this.tileLoaded)this.deleteTile(Number(e));this.i>0&&this.e.reset(this.i)}getPtr(){return this.i}addCanvas(t){var e,i,r,n,s,o,a,l,c,u,d;const h=t.$info;if(!h)return;if(t.error)return void this.micrio.loading.set(!1);if(!(t.noImage||h.width&&h.height))throw"Invalid Micrio image size";const m=t.$settings;this.isGallery=!!h.gallery||t.isOmni,(null==(e=m.gallery)?void 0:e.archive)&&this.e.setHasArchive(this.i,!0,m.gallery.archiveLayerOffset??0),h.version&&Number(h.version)<=3.1&&this.e.setNoUnderzoom(this.i,!0);const v=!!m.limitToCoverScale,p=v||"cover"==m.initType;t.noImage&&this.micrio.loading.set(!1);const f=[.5,.5],g=m.focus,w=!!h.spacesId;g&&(isNaN(g[0])||null===g[0]||(f[0]=g[0]),isNaN(g[1])||null===g[1]||(f[1]=g[1])),h.is360&&(t.camera.trueNorth=(null==(i=m._360)?void 0:i.trueNorth)??.5);const b=null==(r=m._360)?void 0:r.video,y=h.is360&&b&&(b.src||"video"in b&&b.video),k=!!this.isGallery&&("switch"==(null==(n=m.gallery)?void 0:n.type)||"omni"==(null==(s=m.gallery)?void 0:s.type)||"swipe-full"==(null==(o=m.gallery)?void 0:o.type)),T=(null==(l=null==(a=m.omni)?void 0:a.layers)?void 0:l.length)??1;m.omni&&(m.omni.layerStartIndex=Math.min(T-1,(null==(c=m.omni)?void 0:c.layerStartIndex)??0)),t.ptr=this.e._constructor(this.i,h.width,h.height,h.tileSize??1024,h.is360??!1,t.noImage,!(!h.isSingle&&!y),t.opacity,m.freeMove??!1,v,p,(m.zoomLimit||1)*(!1!==m.zoomLimitDPRFix?this.micrio.canvas.getRatio(t.$settings):1),m.camspeed??1,t.camera.trueNorth,k,!!(null==(u=m.gallery)?void 0:u.isSpreads)&&"swipe"==m.gallery.type,t.isOmni,m.pinchZoomOutLimit??!1,T,(null==(d=m.omni)?void 0:d.layerStartIndex)??0),this.bindCamera(t),t.opts.area&&t.camera.setArea(t.opts.area,{direct:!0,noDispatch:!0,noRender:!0}),(null==m?void 0:m.crossfadeDuration)&&this.e.setCrossfadeDuration(this.i,m.crossfadeDuration),(null==m?void 0:m.embedFadeDuration)&&this.e.setEmbedFadeDuration(this.i,m.embedFadeDuration),void 0!==(null==m?void 0:m.dragElasticity)&&this.e.setDragElasticity(this.i,m.dragElasticity),(null==m?void 0:m.skipBaseLevels)&&this.e.setSkipBaseLevels(this.i,m.skipBaseLevels),(null==m?void 0:m.omni)&&t.camera.setOmniSettings(),this.micrio.hasAttribute("data-limited")&&this.e._setLimited(t.ptr,!0),this.images.push(t),this.e._sendViewport(t.ptr);const _=this.e.getNumTiles(this.i);_>0&&(this.tileOpacity[_-1]=1,this.baseTiles.push(_-1));const x=this.e._getPMatrix(t.ptr);this._pMatrices[x]=new Float32Array(this.b,x+32,16);const E=Ki(t.state.view)||m.view;E&&"0,0,1,1"!=E.toString()?this.e._setView(t.ptr,E[0],E[1],E[2],E[3],!1,!1,!1):!w&&h.is360||!f||"0.5,0.5"==f.toString()||(this.e._setCoo(t.ptr,f[0],f[1],0,0,performance.now()),m.focus=void 0),t.video.subscribe((t=>t&&t.addEventListener("play",this.render))),t.noImage&&t.visible.set(!0),this.setCanvas(t)}bindCamera(t){this.cameras.set(t.ptr,t.camera),t.camera.assign(this.e,new Float64Array(this.b,this.e._getView(t.ptr)+32,4),new Float64Array(this.b,this.e._getXY(t.ptr,0,0)+32,5),new Float64Array(this.b,this.e._getCoo(t.ptr,0,0)+32,5),new Float32Array(this.b,this.e._getMatrix(t.ptr)+32,16),new Float32Array(this.b,this.e._getQuad(t.ptr,0,0,0,0,0,0)+32,16))}setCanvas(t){var e;if(t&&!(t.ptr>0&&t.ptr==this.c))if(t.ptr<0)br(t.info).then((e=>{e&&this.micrio.$current&&(e.isIIIF||t.opts.secondaryTo||e.id==this.micrio.$current.id)&&(this.addCanvas(t),t.embeds.length&&t.embeds.forEach((e=>this.addEmbed(e,t))))}));else if(this.c!=t.ptr){const i=t.is360&&this.c>=0?this.e._getYaw(this.c):0,r=t.is360&&this.c>=0?this.e._getPitch(this.c):0;this.c=t.ptr,t.is360&&!this.preventDirectionSet&&i&&r&&this.e._setDirection(this.c,i,r,!0),0==this.e._getTargetOpacity(t.ptr)&&this.e._fadeIn(t.ptr),(null==(e=t.$settings.omni)?void 0:e.layerStartIndex)&&t.state.layer.set(t.$settings.omni.layerStartIndex),this.preventDirectionSet=!1,this.ready=!0,this.render()}}removeCanvas(t){if(t.ptr<0)throw"Canvas is not placed yet";this.e._remove(t.ptr),this.render()}render(){this.raf<0&&(this.raf=this.micrio.webgl.display.requestAnimationFrame(this.draw))}draw(t=performance.now()){var e,i;this.micrio.isConnected&&(this.raf=-1,this.drawing=!1,this.now=t,(1==this.e.shouldDraw(this.i,t)||this.micrio.keepRendering||this.micrio.events.isNavigating||!1===(null==(i=null==(e=this.micrio._current)?void 0:e._video)?void 0:i.paused))&&this.render(),this.isGallery&&this.drawStart(),this.drawn.length=0,this.e.draw(this.i),this.micrio.events.dispatch("draw"),this.cleanup(),this.micrio.webgl.drawEnd())}stop(){this.raf<0||(this.micrio.webgl.display.cancelAnimationFrame(this.raf),this.raf=-1)}drawTile(t,e,i,r,n,s,o,a){this.drawn.push(e),e in this.toDelete&&delete this.toDelete[e];const l=Ua(),c=this.images[t],u="camera"in c&&c.isVideo,d="camera"in c&&c.is360,h="camera"in c?c:c.image,m="frame"in c?c.frame:void 0;if(!this.loadStates[e]&&l<Ca){if(this.bareBone?l>2&&o:a&&o&&l>0)return!1;if(u&&!d)this.loadStates[e]=2,this.textures[e]=this.micrio.webgl.getTexture();else{this.loadStates[e]=1;const t=h.getTileSrc(i,r,n,m);if(!t)return this.loadStates[e]=0,!1;this.getTexture(e,t,o,{noSmoothing:"$info"in c&&c.$settings.noSmoothing})}}else if(this.loadStates[e]>=2){this.drawing||this.drawStart();const t=this.textures[e];if(null!=t){if(u){if(!h._video||!h._video.dataset.playing)return!1;this.micrio.webgl.updateTexture(t,h._video)}this.micrio.webgl.drawTile(t,s,d)}return 2==this.loadStates[e]&&(this.loadStates[e]=3,this.tileLoaded[e]=this.now),!0}return!1}drawStart(){this.drawing||(this.micrio.webgl.drawStart(),this.drawing=!0)}getTexture(t,e,i,r={}){if(this.textures[t]||this.requests.has(t)||!r.force&&Ua()>=Ca)return;const n=Ta.db.has(e);n||this.micrio.loading.set(!0),this.requests.set(t,e),(n?Ta.getImage(e):Fa(e)).then((e=>this.gotTexture(t,e,i,r.noSmoothing))).catch((()=>this.deleteRequest(t)))}gotTexture(t,e,i,r){this.textures[t]=this.micrio.webgl.getTexture(e,this.textures[t],r),null!=self.ImageBitmap&&e instanceof ImageBitmap&&e.close instanceof Function&&e.close(),this.loadStates[t]=2,this.timeouts[t]=setTimeout((()=>{this.deleteRequest(t)}),i?150:50)}deleteRequest(t){this.requests.delete(t),clearTimeout(this.timeouts[t]),delete this.timeouts[t],this.requests.size||this.micrio.loading.set(!1)}deleteTile(t){this.micrio.webgl.gl.deleteTexture(this.textures[t]),delete this.textures[t],delete this.toDelete[t],delete this.loadStates[t],delete this.tileOpacity[t],delete this.tileLoaded[t],clearTimeout(this.timeouts[t]),delete this.timeouts[t]}cleanup(){const t=this.prevDrawn.filter((t=>this.drawn.indexOf(t)<0&&this.loadStates[t]>0&&this.baseTiles.indexOf(t)<0)),e=performance.now();for(let r=0;r<t.length;r++){const i=t[r];switch(this.tileOpacity[r]=0,this.loadStates[i]){case 1:const t=this.requests.get(i);t&&Ba(t),delete this.loadStates[i];break;case 2:this.requests.has(i)&&this.deleteRequest(i),delete this.loadStates[i],this.deleteTile(i);break;case 3:i in this.toDelete||(this.toDelete[i]=e)}}this.prevDrawn=this.drawn.slice(0);const i=mr.iOS?5:30;for(let r in this.toDelete)(e-this.toDelete[r])/1e3>i&&this.deleteTile(Number(r))}resize(t){this.e.resize(this.i,t.width,t.height,t.left,t.top,t.ratio,t.scale,t.portrait),this.ready&&(this.stop(),this.draw())}addEmbed(t,e,i={}){if("camera"in t&&i.asImage)return this.addImage(t,e,!0,i.opacity??1);{const r="$info"in t?t.$info:e.$info;if(!r)return;this.images.push(t);const n=t.opts.area??[0,0,1,1],s=t instanceof xa?t.$settings._360??{}:{};t.ptr=this.e._addImage(e.ptr,n[0],n[1],n[2],n[3],r.width,r.height,r.tileSize||1024,r.isSingle??!1,r.isVideo??!1,i.opacity??1,s.rotX??0,s.rotY??0,s.rotZ??0,s.scale??1,i.fromScale??0),this.tileOpacity[t.baseTileIdx=this.e.getNumTiles(this.i)-1]=1,this.baseTiles.push(t.baseTileIdx)}}setActiveImage(t,e,i){this.e._setActiveImage(t,e,i??0)}setActiveLayer(t,e){this.e._setActiveLayer(t,e)}fadeImage(t,e,i=!1){this.cameras.has(t)?this.e._fadeTo(t,e,i):this.e._fadeImage(t,e,i),this.render()}setFocus(t,e,i=!1){this.e._setFocus(t,e[0],e[1],e[2],e[3],i)}};Wa._textureBuffer=Wa.getTextureBuffer(1,1);let Xa=Wa;const ja=new Float32Array([-1,-1,0,0,1,-1,1,0,-1,1,0,1,1,1,1,1]);class Ga{constructor(t,e,i){if(this.gl=t,this.program=t.createProgram(),e.webgl.getShader(this.program,t.VERTEX_SHADER,"\nattribute vec2 a_position; // Vertex position (-1 to 1)\nattribute vec2 a_texCoord; // Texture coordinate (0 to 1)\n\nvarying vec2 v_texCoord; // Pass texCoord to fragment shader\n\nvoid main() {\n\tv_texCoord = a_texCoord; // Pass through texture coordinate\n\tgl_Position = vec4(a_position, 0.0, 1.0); // Set clip space position\n}"),e.webgl.getShader(this.program,t.FRAGMENT_SHADER,i),t.linkProgram(this.program),t.getProgramParameter(this.program,t.LINK_STATUS)||console.error("Postprocess shader link error:",t.getProgramInfoLog(this.program)),t.useProgram(this.program),this.ppPositionLoc=t.getAttribLocation(this.program,"a_position"),this.ppTexCoordLoc=t.getAttribLocation(this.program,"a_texCoord"),this.ppTimeLoc=t.getUniformLocation(this.program,"u_time"),this.texture=t.createTexture(),t.bindTexture(t.TEXTURE_2D,this.texture),t.texImage2D(t.TEXTURE_2D,0,t.RGBA,this.gl.drawingBufferWidth,this.gl.drawingBufferHeight,0,t.RGBA,t.UNSIGNED_BYTE,null),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MIN_FILTER,t.LINEAR),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MAG_FILTER,t.LINEAR),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_S,t.CLAMP_TO_EDGE),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_T,t.CLAMP_TO_EDGE),this.frameBuffer=t.createFramebuffer(),t.bindFramebuffer(t.FRAMEBUFFER,this.frameBuffer),t.framebufferTexture2D(t.FRAMEBUFFER,t.COLOR_ATTACHMENT0,t.TEXTURE_2D,this.texture,0),t.checkFramebufferStatus(t.FRAMEBUFFER)!==t.FRAMEBUFFER_COMPLETE)throw new Error("Framebuffer not complete");t.bindFramebuffer(t.FRAMEBUFFER,null),this.quad=t.createBuffer(),t.bindBuffer(t.ARRAY_BUFFER,this.quad),t.bufferData(t.ARRAY_BUFFER,ja,t.STATIC_DRAW)}render(){const t=this.gl;t.bindFramebuffer(t.FRAMEBUFFER,null),t.useProgram(this.program),t.bindBuffer(t.ARRAY_BUFFER,this.quad),t.enableVertexAttribArray(this.ppPositionLoc),t.vertexAttribPointer(this.ppPositionLoc,2,t.FLOAT,!1,4*Float32Array.BYTES_PER_ELEMENT,0),t.enableVertexAttribArray(this.ppTexCoordLoc),t.vertexAttribPointer(this.ppTexCoordLoc,2,t.FLOAT,!1,4*Float32Array.BYTES_PER_ELEMENT,2*Float32Array.BYTES_PER_ELEMENT),t.activeTexture(t.TEXTURE0),t.bindTexture(t.TEXTURE_2D,this.texture),t.uniform1f(this.ppTimeLoc,performance.now()/1e3),t.drawArrays(t.TRIANGLE_STRIP,0,4)}resize(){const t=this.gl;t.bindTexture(t.TEXTURE_2D,this.texture),t.texImage2D(t.TEXTURE_2D,0,t.RGBA,this.gl.drawingBufferWidth,this.gl.drawingBufferHeight,0,t.RGBA,t.UNSIGNED_BYTE,null),t.bindTexture(t.TEXTURE_2D,null)}}const Ya=/firefox/i.test(navigator.userAgent),Ha=`\nprecision mediump float; // Use medium precision for fragment calculations\n\nvarying highp vec2 vTextureCoord; // Received texture coordinate from vertex shader\n\nuniform sampler2D uSampler; // The tile texture\nuniform float opacity; // Tile opacity (for fading)\nuniform int noTexture; // Flag indicating if texture is missing/not loaded\n\nvoid main() {\n\tif(noTexture==1) { // If texture is missing\n\t\tgl_FragColor = vec4(.1,.1,.1,.1); // Draw a placeholder color (dark semi-transparent gray)\n\t} else {\n\t${Ya?"\n\t\t// Firefox premultiplied alpha workaround\n\t\tvec4 textureColor = texture2D(uSampler, vTextureCoord);\n\t\t// Manually apply opacity to RGB based on new alpha\n\t\tfloat newAlpha = min(1., textureColor.a * opacity);\n\t\tgl_FragColor = vec4(textureColor.rgb * newAlpha, newAlpha);":"\n\t\t// Standard alpha blending (premultiplied alpha assumed in blendFunc)\n\t\tgl_FragColor = texture2D(uSampler, vTextureCoord) * opacity;"}\n\t\t// Debug: Draw red instead of texture\n\t\t//gl_FragColor = vec4(1.,0.,0.,1.);\n\t}\n}`;class Za{constructor(t){this.micrio=t,this.display=self,this.txtAttr=-1,this.posAttr=-1,this.was360=!1}init(){var t;const e="WebGL2RenderingContext"in window,i=this.micrio.canvas.element.getContext(e?"webgl2":"webgl",{alpha:!0,preserveDrawingBuffer:this.micrio.hasAttribute("data-preserve-drawing-buffer"),stencil:!1,antialias:!1,depth:!1,desynchronized:!1,powerPreference:"high-performance"});if(e?!(i instanceof window.WebGL2RenderingContext):!(i instanceof window.WebGLRenderingContext))throw"Error creating WebGL context. Does your browser support WebGL?";this.gl=i;const r=null==(t=this.micrio.$current)?void 0:t.$settings.postProcessingFragmentShader;r&&(this.postpocessor=new Ga(i,this.micrio,r),this.micrio.keepRendering=!0);const n=i.createProgram();if(!(n instanceof WebGLProgram))throw"Could not create shader program";this.program=n,this.getShader(this.program,i.VERTEX_SHADER,"\nuniform mat4 GLMatrix; // Combined ModelViewProjection matrix from Wasm\n\nattribute vec3 pos; // Vertex position (from Wasm buffer)\nattribute vec2 aTextureCoord; // Texture coordinate (from static buffer)\n\nvarying highp vec2 vTextureCoord; // Pass texture coordinate to fragment shader\n\nvoid main()\n{\n\tgl_Position = GLMatrix * vec4(pos, 1.0); // Calculate clip space position\n\tvTextureCoord = aTextureCoord; // Pass through texture coordinate\n}"),this.getShader(this.program,i.FRAGMENT_SHADER,Ha),i.linkProgram(this.program),i.getProgramParameter(this.program,i.LINK_STATUS)||console.error("Main shader link error:",i.getProgramInfoLog(this.program)),i.useProgram(this.program),i.blendFunc(i.ONE,i.ONE_MINUS_SRC_ALPHA),i.enable(i.BLEND),i.disable(i.DEPTH_TEST),i.clearColor(0,0,0,0);const s=i.getUniformLocation(this.program,"opacity");if(!s)throw"Could not create opacity WebGL binding!";this.opaLoc=s;const o=i.getUniformLocation(this.program,"GLMatrix");if(!o)throw"Could not create matrix WebGL binding!";this.pmLoc=o;const a=i.getUniformLocation(this.program,"noTexture");if(!a)throw"Could not bind noTexture uniform";this.noTxtLoc=a,this.txtAttr=i.getAttribLocation(this.program,"aTextureCoord");const l=i.createBuffer();if(!l)throw"Could not connect texture buffer";this.txtBuffer=l,i.bindBuffer(i.ARRAY_BUFFER,this.txtBuffer),i.bufferData(i.ARRAY_BUFFER,Xa._textureBuffer,i.STATIC_DRAW);const c=i.createBuffer();if(!c)throw"Could not bind geometry buffer";this.geomBuffer=c,this.posAttr=i.getAttribLocation(this.program,"pos"),this.linkBuffers(),i.viewport(0,0,this.gl.drawingBufferWidth,this.gl.drawingBufferHeight)}linkBuffers(){const t=this.gl;t.bindBuffer(t.ARRAY_BUFFER,this.geomBuffer),t.bufferData(t.ARRAY_BUFFER,this.micrio.wasm._vertexBuffer,t.STATIC_DRAW),t.enableVertexAttribArray(this.txtAttr),t.bindBuffer(t.ARRAY_BUFFER,this.txtBuffer),t.vertexAttribPointer(this.txtAttr,2,t.FLOAT,!1,0,0),t.enableVertexAttribArray(this.posAttr),t.bindBuffer(t.ARRAY_BUFFER,this.geomBuffer),t.vertexAttribPointer(this.posAttr,3,t.FLOAT,!1,0,0)}dispose(t=!1){const e=this.gl;if(e){if(e.bindBuffer(e.ARRAY_BUFFER,null),e.bindTexture(e.TEXTURE_2D,null),e.deleteBuffer(this.txtBuffer),e.deleteBuffer(this.geomBuffer),t){const t=e.getExtension("WEBGL_lose_context");t instanceof Object&&t.loseContext instanceof Function&&t.loseContext()}this.gl=null}}getShader(t,e,i){const r=this.gl.createShader(e);if(!r)throw"Could not create shader!";if(this.gl.shaderSource(r,i),this.gl.compileShader(r),!this.gl.getShaderParameter(r,this.gl.COMPILE_STATUS))throw console.error("Error compiling shader",this.gl.getShaderInfoLog(r)),this.gl.deleteProgram(t),new Error(`Shader compilation failed: ${this.gl.getShaderInfoLog(r)}`);this.gl.attachShader(t,r),this.gl.deleteShader(r)}getTexture(t,e,i){const r=this.gl,n=e??r.createTexture();if(!n)throw"Could not create texture!";return r.bindTexture(r.TEXTURE_2D,n),t&&r.texImage2D(r.TEXTURE_2D,0,r.RGBA,r.RGBA,r.UNSIGNED_BYTE,t),r.texParameteri(r.TEXTURE_2D,r.TEXTURE_WRAP_S,r.CLAMP_TO_EDGE),r.texParameteri(r.TEXTURE_2D,r.TEXTURE_WRAP_T,r.CLAMP_TO_EDGE),r.texParameteri(r.TEXTURE_2D,r.TEXTURE_MIN_FILTER,r.LINEAR),r.texParameteri(r.TEXTURE_2D,r.TEXTURE_MAG_FILTER,i?r.NEAREST:r.LINEAR),n}updateTexture(t,e){const i=this.gl;i.bindTexture(i.TEXTURE_2D,t),i.texImage2D(i.TEXTURE_2D,0,i.RGBA,i.RGBA,i.UNSIGNED_BYTE,e),i.bindTexture(i.TEXTURE_2D,null)}drawStart(){const t=this.gl;this.postpocessor&&t.bindFramebuffer(t.FRAMEBUFFER,this.postpocessor.frameBuffer),this.gl.clear(this.gl.COLOR_BUFFER_BIT)}drawEnd(){this.postpocessor&&(this.postpocessor.render(),this.gl.useProgram(this.program),this.linkBuffers())}drawTile(t,e=1,i=!1){this.gl.uniform1i(this.noTxtLoc,t?0:1),this.gl.uniform1f(this.opaLoc,e),t&&(this.gl.activeTexture(this.gl.TEXTURE0),this.gl.bindTexture(this.gl.TEXTURE_2D,t));const r=i?6*Xa.segsX*Xa.segsY:6;i!=this.was360&&(this.gl.bindBuffer(this.gl.ARRAY_BUFFER,this.txtBuffer),this.gl.bufferData(this.gl.ARRAY_BUFFER,i?Xa._textureBuffer360:Xa._textureBuffer,this.gl.STATIC_DRAW),this.gl.bindBuffer(this.gl.ARRAY_BUFFER,this.geomBuffer),this.was360=i),this.gl.bufferData(this.gl.ARRAY_BUFFER,i?this.micrio.wasm._vertexBuffer360:this.micrio.wasm._vertexBuffer,this.gl.STATIC_DRAW),this.gl.drawArrays(this.gl.TRIANGLES,0,r)}}const Ka={passive:!0},Ja={passive:!0,capture:!0},Qa={passive:!1};function tl(t){t.stopPropagation(),t.preventDefault()}const el=["move","marker-open","marker-opened","marker-closed","tour-start","tour-step","tour-stop","tour-event","media-play","media-pause","splitscreen-start","splitscreen-stop"];class il{constructor(t){this.micrio=t,this.enabled=Zi(!1),this.hooked=!1,this.hookedDrag=!1,this.panning=!1,this.pinching=!1,this.clicked=!1,this.wheeling=!1,this.controlZoom=!1,this.twoFingerPan=!1,this.pScale=1,this.wheelEndTo=-1,this.hasTouch=mr.hasTouch&&"ontouchstart"in self,this.hasUsedCtrl=!1,this.vars={drag:{prev:void 0,start:[0,0,0]},dbltap:{lastTapped:0},pinch:{image:void 0,sDst:0,wasPanning:!1},updates:{to:-1,stack:[]}},this.scrollHooked=!1,this.el=t.canvas.element,this.dStart=this.dStart.bind(this),this.dMove=this.dMove.bind(this),this.dStop=this.dStop.bind(this),this.pStart=this.pStart.bind(this),this.pMove=this.pMove.bind(this),this.pStop=this.pStop.bind(this),this.gesture=this.gesture.bind(this),this.keydown=this.keydown.bind(this),this.wheel=this.wheel.bind(this),this.wheelEnd=this.wheelEnd.bind(this),this.dbltap=this.dbltap.bind(this),this.dblclick=this.dblclick.bind(this),this.updateEvent=this.updateEvent.bind(this),this.dispatchUpdate=this.dispatchUpdate.bind(this),this.enabled.subscribe((t=>{t?this.hook():this.unhook()})),t.visible.subscribe((t=>this.visible=t)),t.current.subscribe((t=>{t&&!this.settings&&br(t.info).then((e=>{e&&(this.settings=t.$settings,!t.error&&this.settings.hookEvents&&this.enabled.set(!0))}))}))}get $enabled(){return Ki(this.enabled)}get isNavigating(){return this.panning||this.pinching||this.wheeling||this.clicked}dispatch(t,e){this.micrio.dispatchEvent(new CustomEvent(t,void 0!==e?{detail:e}:void 0))}getImage(t){var e;if(!this.visible)return;const i=this.micrio.offsetWidth,r=this.micrio.offsetHeight,n=Math.max(0,Math.min(1,t.x/i)),s=Math.max(0,Math.min(1,t.y/r)),o=null==(e=this.visible)?void 0:e.find((t=>!!t.opts.secondaryTo)),a=1==this.visible.length?this.visible[0]:this.visible.find((({grid:t,opts:{area:e}})=>(!o||!t)&&(!!e&&(n>=e[0]&&n<=e[2]&&s>=e[1]&&s<=e[3]))));return a&&a.opts.secondaryTo&&a.opts.isPassive&&a.opts.area&&(t.x-=a.opts.area[0]*i,t.y-=a.opts.area[1]*r),!a||a.grid||a.opts.secondaryTo&&a.opts.isPassive?this.micrio.$current:a}hook(){if(this.hooked)return;this.hooked=!0;const t=this.settings;t&&(this.twoFingerPan=!!t.twoFingerPan,this.twoFingerPan?this.micrio.setAttribute("data-can-pan",""):this.micrio.removeAttribute("data-can-pan"),(null==t?void 0:t.hookKeys)&&this.hookKeys(),t.hookDrag&&this.hookDrag(),t.noZoom||this.hookZoom(),this.hookUpdate())}unhook(){this.hooked&&(this.hooked=!1,this.unhookDrag(),this.unhookZoom(),this.unhookKeys(),this.unhookUpdate())}hookKeys(){document.addEventListener("keydown",this.keydown)}unhookKeys(){document.removeEventListener("keydown",this.keydown)}hookZoom(){const t=this.settings;this.controlZoom=!!(null==t?void 0:t.controlZoom),t&&!t.hookPinch||this.hookPinch(),(!t||t.hookScroll||this.controlZoom)&&this.hookScroll(),this.micrio.canvas.$isMobile?this.el.addEventListener("touchstart",this.dbltap):this.el.addEventListener("dblclick",this.dblclick)}unhookZoom(){this.unhookPinch(),this.unhookScroll(),this.micrio.canvas.$isMobile?this.el.removeEventListener("touchstart",this.dbltap):this.el.removeEventListener("dblclick",this.dblclick)}hookScroll(){this.scrollHooked||(this.micrio.addEventListener("wheel",this.wheel,Qa),this.scrollHooked=!0)}unhookScroll(){this.micrio.removeEventListener("wheel",this.wheel,Qa),this.scrollHooked=!1}hookPinch(){this.hasTouch&&this.el.addEventListener("touchstart",this.pStart,Ka),mr.OSX&&(this.micrio.addEventListener("gesturestart",this.gesture,Qa),this.micrio.addEventListener("gesturechange",this.gesture,Qa),this.micrio.addEventListener("gestureend",this.gesture,Qa))}unhookPinch(){this.el.removeEventListener("touchstart",this.pStart,Ka),mr.OSX&&(this.micrio.removeEventListener("gesturestart",this.gesture,Qa),this.micrio.removeEventListener("gesturechange",this.gesture,Qa),this.micrio.removeEventListener("gestureend",this.gesture,Qa))}hookDrag(){this.hookedDrag||(this.hookedDrag=!0,this.micrio.addEventListener("dragstart",tl),this.micrio.addEventListener("pointerdown",this.dStart,Ka),this.micrio.setAttribute("data-hooked",""))}unhookDrag(){this.hookedDrag&&(this.hookedDrag=!1,this.micrio.removeEventListener("pointerdown",this.dStart,Ka),this.micrio.removeEventListener("dragstart",tl),this.micrio.removeAttribute("data-hooked"))}dStart(t,e=!1){var i;if(0!=t.button||"touch"==t.pointerType&&this.twoFingerPan)return;if(!e&&t.target!=this.el)return;if((null==(i=this.micrio.$current)?void 0:i.isOmni)&&t.shiftKey)return;if(this.panning)return void(t instanceof TouchEvent&&t.touches.length>1&&this.dStop());const r=this.getImage({x:t.clientX,y:t.clientY});r&&(this.panning=!0,this.vars.drag.start=[t.clientX,t.clientY,performance.now()],this.micrio.addEventListener("pointermove",this.dMove,Ka),this.micrio.addEventListener("pointerup",this.dStop,Ka),this.micrio.setAttribute("data-panning",""),this.micrio.wasm.e._panStart(r.ptr),this.micrio.wasm.render(),this.dispatch("panstart"))}dMove(t){var e;const i=t.clientX,r=t.clientY,n=ar(this.vars.drag.start[0]-t.clientX,this.vars.drag.start[1]-t.clientY);!this.capturedPointerId&&n>10&&this.micrio.setPointerCapture(this.capturedPointerId=t.pointerId),this.vars.drag.prev&&(null==(e=this.getImage({x:i,y:r}))||e.camera.pan(this.vars.drag.prev[0]-i,this.vars.drag.prev[1]-r)),this.vars.drag.prev=[i,r]}dStop(t,e=!1,i=!1){if(this.panning){if(this.panning=!1,this.vars.drag.prev=void 0,this.micrio.removeEventListener("pointermove",this.dMove,Ka),this.micrio.removeEventListener("pointerup",this.dStop,Ka),this.capturedPointerId&&this.micrio.releasePointerCapture(this.capturedPointerId),this.capturedPointerId=void 0,this.micrio.removeAttribute("data-panning"),t&&0==e){const e=this.getImage({x:t.clientX,y:t.clientY});e&&(this.micrio.wasm.e._panStop(e.ptr),this.micrio.wasm.render())}i||this.dispatch("panend",t?{duration:performance.now()-this.vars.drag.start[2],movedX:t.clientX-this.vars.drag.start[0],movedY:t.clientY-this.vars.drag.start[1]}:void 0)}}pStart(t){if(!(mr.hasTouch&&t instanceof TouchEvent))return;if(this.twoFingerPan&&t.touches.length<2)return;if(this.pinching||2!=t.touches.length)return void this.pStop(t);t.stopPropagation(),this.vars.pinch.wasPanning=this.panning,this.dStop(void 0,!1,!0);const e=t.touches;this.pinching=!0,self.addEventListener("touchmove",this.pMove,Ja),self.addEventListener("touchend",this.pStop,Ja),this.micrio.setAttribute("data-pinching",""),this.vars.pinch.image=this.getImage({x:e[0].clientX,y:e[0].clientY}),this.vars.pinch.sDst=ar(e[0].clientX-e[1].clientX,e[0].clientY-e[1].clientY),this.pinchFactor=void 0,this.vars.pinch.image&&this.micrio.wasm.e._pinchStart(this.vars.pinch.image.ptr),this.micrio.wasm.render(),this.dispatch("pinchstart"),this.twoFingerPan&&this.dispatch("panstart")}pMove(t){if(!(mr.hasTouch&&t instanceof TouchEvent))return;const e=t.touches;if((null==e?void 0:e.length)<2)return;const i={x:e[0].clientX,y:e[0].clientY},r={x:e[1].clientX,y:e[1].clientY},n=this.vars.pinch,s=n.image;if(s){if((null==s?void 0:s.opts.secondaryTo)&&s.opts.isPassive&&s.opts.area){const t=s.opts.area[0]*this.micrio.offsetWidth,e=s.opts.area[1]*this.micrio.offsetHeight;i.x-=t,r.x-=t,i.y-=e,r.y-=e}this.pinchFactor=ar(e[0].clientX-e[1].clientX,e[0].clientY-e[1].clientY)/n.sDst,this.micrio.wasm.e._pinch(s.ptr,i.x,i.y,r.x,r.y)}}pStop(t){if(!this.pinching)return;this.pinching=!1,self.removeEventListener("touchmove",this.pMove,Ja),self.removeEventListener("touchend",this.pStop,Ja),this.micrio.removeAttribute("data-pinching");const e=this.vars.pinch.image;e&&(this.micrio.wasm.e._pinchStop(e.ptr,performance.now()),this.micrio.wasm.render()),this.vars.pinch.image=void 0,this.pinchFactor=void 0,this.dispatch("pinchend"),this.twoFingerPan&&!this.vars.pinch.wasPanning&&this.dispatch("panend"),t instanceof TouchEvent&&1==t.touches.length&&this.dStart(t,!0)}gesture(t){var e;const i=t.scale;if(1==i)return;const r=this.pScale-i;if(this.pScale=i,t.stopPropagation(),t.preventDefault(),"gesturechange"==t.type){const i=t;null==(e=this.getImage({x:i.clientX,y:i.clientY}))||e.camera.zoom(r*this.micrio.canvas.viewport.height,0,i.clientX,i.clientY)}}wheel(t,e=!1,i=0){var r;if(!(t instanceof WheelEvent))return;if(this.controlZoom&&!t.ctrlKey)return;if(!e&&t.target instanceof Element&&t.target!=this.el&&!t.target.classList.contains("marker")&&!t.target.hasAttribute("data-scroll-through"))return;let n=t.deltaY;t.ctrlKey&&(this.hasUsedCtrl=!0);const s=this.controlZoom&&10*n%1==0,o=this.hasUsedCtrl&&!s,a=mr.firefox||t.ctrlKey||!o;if(this.twoFingerPan&&(null==(r=this.micrio.$current)?void 0:r.camera.isZoomedOut()))return;t.stopPropagation(),t.preventDefault(),(mr.OSX||o)&&t.ctrlKey&&(n*=10);const l={x:t.clientX,y:t.clientY},c=this.getImage(l);if(c){if(a){const t=this.micrio.canvas.viewport;let e=0;const r=this.micrio.getBoundingClientRect();c.camera.zoom(1*n/Math.sqrt(t.scale),0,l.x-i-r.left,l.y-r.top-e)}else c.camera.pan(t.deltaX,t.deltaY);this.wheeling=!0,clearTimeout(this.wheelEndTo),this.wheelEndTo=setTimeout(this.wheelEnd,50)}}wheelEnd(){this.wheeling=!1}dbltap(t){if(!(mr.hasTouch&&t instanceof TouchEvent))return;const e=performance.now();1==t.touches.length&&e-this.vars.dbltap.lastTapped<250&&(t.stopPropagation(),t.preventDefault(),this.dblclick(t)),this.vars.dbltap.lastTapped=e}dblclick(t){var e;const i=t instanceof TouchEvent?t.touches[0]:t,r=this.getImage({x:i.clientX,y:i.clientY});null==r||r.camera.zoom(-300,500,i.clientX,i.clientY,1,!(null==(e=this.micrio.$current)?void 0:e.album)).catch((()=>{}))}keydown(t){var e;if(this.panning||this.pinching||!(null==(e=this.micrio.$current)?void 0:e.camera))return;const i=this.micrio.$current.camera,r=this.micrio.offsetWidth/2,n=this.micrio.offsetHeight/2;let s=0,o=0;switch(t.key){case"ArrowUp":o-=n;break;case"ArrowDown":o+=n;break;case"ArrowLeft":s-=r;break;case"ArrowRight":s+=r;break;case"+":case"=":i.zoom(-200,150);break;case"-":case"_":i.zoom(200,150);break;default:return}t.preventDefault(),t.stopPropagation(),0==s&&0==o||i.pan(s,o,150)}hookUpdate(){el.forEach((t=>this.micrio.addEventListener(t,this.updateEvent)))}unhookUpdate(){el.forEach((t=>this.micrio.removeEventListener(t,this.updateEvent)))}updateEvent(t){if("move"==t.type&&!this.isNavigating)return;const e=this.vars.updates.stack;e[e.length-1]!=t.type&&e.push(t.type),clearTimeout(this.vars.updates.to),this.vars.updates.to<0&&(this.vars.updates.to=setTimeout(this.dispatchUpdate))}dispatchUpdate(){const t=this.vars.updates;clearTimeout(t.to),t.to=-1,t.stack.length&&(this.dispatch("update",t.stack),t.stack.length=0,t.to=setTimeout(this.dispatchUpdate,500))}}const rl=class t{constructor(t){this.micrio=t,this.isStatic=!1,this.loaded=!1,this.inited=!1,this.setting=!1,this.writeTitle=!1}hook(){this.isStatic="static"==this.micrio.getAttribute("data-router"),this.read=this.read.bind(this),this.write=this.write.bind(this),this.writeDeferred=this.writeDeferred.bind(this),br(this.micrio.current).then((()=>{this.loaded=!0,this.read()})),t.events.forEach((t=>this.micrio.addEventListener(t,this.write))),"i.micr.io"==location.hostname&&(this.writeTitle=!0),window.addEventListener(this.isStatic?"popstate":"hashchange",this.read)}unhook(){t.events.forEach((t=>this.micrio.removeEventListener(t,this.write))),window.removeEventListener(this.isStatic?"popstate":"hashchange",this.read)}findPage(t,e,i){var r,n;if(e)for(let s=0;s<e.length;s++){const o=(null==(n=null==(r=e[s])?void 0:r.i18n)?void 0:n[i])??e[s];let a=pr(o.title)==t?e[s]:this.findPage(t,e[s].children,i);if(a)return a}}read(){if(!this.loaded||this.setting)return;this.route=(this.isStatic?location.pathname:location.hash).slice(1);const[t,e,i,r,n]=this.route.split("/"),s=this.micrio.$current,o=t&&(null==s?void 0:s.id)!=t?this.micrio.open(t):void 0;s&&Promise.all([br(s.data,{allowUndefined:!0}),o?br(o.data,{allowUndefined:!0}):void 0]).then((t=>{var i,a;if(!t[0])return this.inited=!0;if(void 0===this.prevLang&&(this.prevLang=this.micrio.lang),!1===(null==o?void 0:o.$settings.routerMarkerTours))return;if((null==(i=t[0].pages)?void 0:i.length)&&r){const i=this.findPage(r.toLowerCase(),t[0].pages,e);if(i)return void this.micrio.state.popover.set({contentPage:i})}const l=r?n?t.map((t=>{var i;return null==(i=null==t?void 0:t.markerTours)?void 0:i.find((t=>{var i,n;return pr(null==(n=null==(i=t.i18n)?void 0:i[e])?void 0:n.slug)==r}))}))[0]:t.map((t=>{var i;return null==(i=null==t?void 0:t.tours)?void 0:i.find((t=>{var i,n;return pr(null==(n=null==(i=t.i18n)?void 0:i[e])?void 0:n.slug)==r}))}))[0]:void 0,c=n||!l&&r,u=c?null==(a=(t[1]??t[0]).markers)?void 0:a.find((t=>{var i,r,n;return((null==(r=null==(i=t.i18n)?void 0:i[e])?void 0:r.slug)??pr(t.title))==c||l&&"steps"in l&&(null==(n=l.stepInfo)?void 0:n.map((t=>t.marker)).find((t=>{var i,r;return(null==(r=null==(i=t.i18n)?void 0:i[e])?void 0:r.slug)==c})))})):void 0;u&&l&&"steps"in l?l.initialStep=l.steps.findIndex((t=>t.startsWith(u.id))):(u||this.micrio.state.popup.set(void 0),(o??s).state.marker.set(u)),this.micrio.state.tour.set(l),this.writeTitle&&this.setTitle(),this.inited=!0}))}setTitle(){var t,e,i,r,n,s,o,a,l,c;const u=Ki(this.micrio._lang),d=this.micrio.$current;if(!d)return;const h=[(null==(i=null==(e=null==(t=d.$data)?void 0:t.i18n)?void 0:e[u])?void 0:i.title)??(null==(r=null==d?void 0:d.$info)?void 0:r.title),null==(o=null==(s=null==(n=this.micrio.state.$tour)?void 0:n.i18n)?void 0:s[u])?void 0:o.title,null==(c=null==(l=null==(a=this.micrio.state.$marker)?void 0:a.i18n)?void 0:l[u])?void 0:c.title].filter((t=>!!t)).reverse();document.title=h.join(" - ")+" | Micrio"}write(t){if(this.micrio.$current&&this.loaded&&this.inited){if("marker-open"===t.type){const t=this.micrio.state.$marker;if(t&&t.data&&t.data.micrioLink)return}clearTimeout(this._to),this._to=setTimeout((()=>this.writeDeferred("load"==t.type)),50)}}writeDeferred(t){var e,i,r,n,s,o,a,l,c;const u=this.micrio.state.$tour;let d=this.micrio.$current,h=null==d?void 0:d.state.$marker;const m=this.micrio.lang;m!=this.prevLang&&(t=!0,this.prevLang=m);const v=(null==(r=null==(i=null==(e=null==d?void 0:d.$data)?void 0:e.i18n)?void 0:i[m])?void 0:r.title)??(null==(n=null==d?void 0:d.$info)?void 0:n.title)??"",p=!1===(null==d?void 0:d.$settings.routerMarkerTours),f=h&&"string"!=typeof h?(null==(s=h.i18n)?void 0:s[m])??h:void 0,g=null==(o=Ki(this.micrio.state.popover))?void 0:o.contentPage,w=g?(null==(a=g.i18n)?void 0:a[m])??g:void 0;let b=null==d?void 0:d.id;if(u&&"steps"in u&&u.steps.length&&u.stepInfo){const t=u.stepInfo.find((t=>t.markerId==u.steps.find((t=>!t.includes(",")))));t&&(b=t.micrioId,d=this.micrio.wasm.images.find((t=>t.id==b)),h||void 0===u.initialStep||(h=u.stepInfo[u.initialStep].marker))}const y=[b,m,pr(v)??"",...p?[]:w?[pr(w.title)]:[(null==(c=null==(l=null==u?void 0:u.i18n)?void 0:l[m])?void 0:c.slug)??null,(null==f?void 0:f.slug)??pr(null==f?void 0:f.title)??null]].filter((t=>!!t)).join("/");y!=this.route&&(this.setting=!0,this.isStatic?t?history.replaceState(null,"","/"+y+location.search):history.pushState(null,"","/"+y+location.search):location.hash=y,this.route=y,this.writeTitle&&this.setTitle(),setTimeout((()=>this.setting=!1),250))}};rl.events=["load","tour-start","tour-stop","marker-open","marker-closed","page-open","page-closed","lang-switch"];let nl=rl;const sl=class t{constructor(t){this.micrio=t,this.gtag="gtag"in window?window.gtag:void 0,this.hooked=!1,this.tag=this.tag.bind(this)}hook(){!this.hooked&&this.gtag&&(this.hooked=!0,this.tag(new CustomEvent("init")),t.events.forEach((t=>this.micrio.addEventListener(t,this.tag))))}unhook(){this.hooked&&(this.hooked=!1,this.tag(new CustomEvent("hide")),t.events.forEach((t=>this.micrio.removeEventListener(t,this.tag))))}tag(t){if(!this.gtag)return;const e=t.detail,i=this.micrio.$current,r={event_category:"Micrio",event_action:t.type};this.micrio.lang&&(r.culture=this.micrio.lang),"init"==t.type&&(r.micrio_version=oa),"load"==t.type&&(null==i?void 0:i.$info)&&(r.image_version=i.$info.version);const n=null!==e&&"object"==typeof e&&"currentStep"in e?e.currentStep:null;null!=n&&(r.event_value=n);const s=e&&e.title?e.title:i&&i.$info&&i.$info.title;r.event_label=this.micrio.id+(s?" - "+s:""),this.gtag("event",t.type,r)}};sl.events=["load","show","hide","marker-open","marker-opened","marker-closed","tour-start","tour-stop","tour-step","tour-ended"];let ol=sl;const al=t=>Math.round(1e5*t)/1e5,ll=class t{constructor(e,i){var r;this.micrio=e,this.image=i,this.images=[],this.current=[],this._grid=document.createElement("div"),this._buttons=new Map,this.clickable=!1,this.focussed=Zi(),this.markersShown=Zi([]),this.history=[],this.depth=Zi(0),this.aniDurationIn=1.5,this.aniDurationOut=.5,this.transitionDelay=.5,this.isHorizontal=!1,this.cellSizes=new Map,this.nextSize=new Map,this.timingFunction="ease",this.getString=(e,i={})=>{var r;return t.getString(e,{view:i.view,area:i.area,size:i.size??this.nextSize.get(e.id),cultures:null==(r="cultures"in e&&e.cultures?e.cultures:"")?void 0:r.replace(/,/g,"-")})},this.tourEvent=this.tourEvent.bind(this),this.updateGrid=this.updateGrid.bind(this);const n=i.$settings;this.clickable=!!n.gridClickable,void 0!==n.gridTransitionDuration&&(this.aniDurationIn=this.aniDurationOut=n.gridTransitionDuration),void 0!==n.gridTransitionDurationOut&&(this.aniDurationOut=n.gridTransitionDurationOut),this._grid.className="micrio-grid",this.set(null==(r=i.$info)?void 0:r.grid);const s=()=>Xt().then((()=>{this.hook(),e.events.dispatch("grid-load")}));i.isV5?s():e._lang.subscribe((t=>{t?Promise.all(this.images.filter((e=>{var i;return(e.$info&&"cultures"in e.$info&&(null==(i=e.$info)?void 0:i.cultures)||"").indexOf(t)>=0})).map((t=>br(t.data)))).then(s):s()})),e.events.dispatch("grid-init",this)}get $focussed(){return Ki(this.focussed)}hook(){if(this.micrio.state.marker.subscribe((t=>{var e,i;if(t&&"string"!=typeof t){const r=null==(e=t.data)?void 0:e._meta;if(null==r?void 0:r.gridSize){const e="number"==typeof r.gridSize?[r.gridSize,r.gridSize]:r.gridSize.split(",").map(Number),n=null==(i=this.images.find((e=>{var i,r;return null==(r=null==(i=e.$data)?void 0:i.markers)?void 0:r.find((e=>e==t))})))?void 0:i.id;n&&this.nextSize.set(n,e)}Xt().then((()=>{var t;const e=null==(t=null==r?void 0:r.gridAction)?void 0:t.split("|");(null==e?void 0:e.length)&&"string"==typeof e[0]&&this.action(e.shift(),e.join("|"))}))}})),this.clickable){this._grid.addEventListener("click",(t=>{const e=t.target.dataset.id;e&&this.focus(this.images.find((t=>t.id==e)))}));const t=t=>{t?this.removeGrid():this.placeGrid()};this.micrio.state.tour.subscribe(t),this.micrio.state.marker.subscribe(t),this.focussed.subscribe(t)}this.micrio.addEventListener("tour-event",this.tourEvent),this.micrio.addEventListener("serialtour-pause",(()=>this.images.forEach((t=>t.camera.pause())))),this.micrio.addEventListener("serialtour-play",(()=>this.images.forEach((t=>t.camera.resume()))))}clearTimeouts(){clearTimeout(this._to),clearTimeout(this._fadeTo)}set(t="",e={}){return this.lastPromise=new Promise(((i,r)=>{var n,s,o;null==(s=null==(n=this.image.$info)?void 0:n.settings)||delete s.focus,this.lastAction=void 0,!1===e.cover&&e.coverLimit&&(e.coverLimit=!1),e.coverLimit&&null==e.cover&&(e.cover=e.coverLimit),"string"!=typeof t&&(t=t.map((t=>t instanceof xa?{image:t}:t)).filter((t=>!!t.image.$info)).map((t=>this.getString(t.image.$info,t))).join(";"));const a=t.split(";").filter((t=>!!t)).map((t=>this.getImage(t))),l=this.$focussed,c=null==(o=e.transition)?void 0:o.endsWith("-delayed"),u="behind-delayed"==e.transition;switch(e.transition){case"crossfade":e.duration=0;break;case"behind":case"behind-delayed":const t=!0===e.coverLimit;e.forceAni=!0,e.coverLimit=t,e.forceAreaAni=!0;const i=c?1/a.length:1;let r=0;this.images.forEach((e=>{e.camera.setCoverLimit(t),a.find((t=>t.id==e.id))&&(e.camera.setArea([0,0,(null==l?void 0:l.id)==e.id?1:i,1],{noDispatch:!0,direct:!0}),e!=l&&e.camera.setView([0,0,1,1]),c&&this.micrio.wasm.e._setZIndex(e.ptr,a.length-r++))})),a.forEach((t=>t.view=[0,0,1,1]))}const d=this.image.ptr>=0,h=e.duration??(e.noHistory?this.aniDurationOut:this.aniDurationIn),m=this.nextCrossFadeDuration??this.image.$settings.crossfadeDuration??1,v=(h||this.aniDurationIn)/(u?2:1);if(this.nextCrossFadeDuration=void 0,d){const t=this.micrio.wasm.getPtr();this.micrio.wasm.e.setGridTransitionDuration(t,h),this.micrio.wasm.e.setCrossfadeDuration(t,v)}const p=!e.noBlur&&l;p&&this.blur(),!e.noHistory&&this.current.length&&this.depth.set(this.history.push({layout:this.current.map((t=>this.getString(t.$info,{view:t.state.$view,size:this.cellSizes.get(t.id)}))).join(";"),horizontal:this.isHorizontal,view:this.image.camera.getView()})),this.isHorizontal=!!e.horizontal,this.removeImages(this.images.filter((t=>!a.find((e=>e.id==t.id))))),this.printGrid(a,{horizontal:e.horizontal,keepGrid:e.keepGrid,scale:e.scale,columns:e.columns}),this.clearTimeouts();let f=!1;const g=()=>{this.clearTimeouts(),f||r()};d&&!e.noCamAni&&(e.view?this.image.camera.flyToView(e.view,{duration:1e3*h}).catch(g):this.image.camera.flyToFullView({duration:1e3*h}).catch(g)),this.nextSize.clear(),null==e.coverLimit&&(e.coverLimit=!0),e.coverLimit||a.forEach((t=>{var i;return null==(i=this.images.find((e=>e.id==t.id)))?void 0:i.camera.setCoverLimit(!!e.coverLimit)}));const w="appear-delayed"==e.transition,b=t=>t*this.transitionDelay+(t>0&&w?h:0);this.current=a.map(((t,i)=>this.placeImage(t,{duration:!e.forceAni&&p&&t.id!=(null==l?void 0:l.id)?0:h,delay:c?b(i):0,noCamAni:!!(w&&i>0)||!!e.noCamAni,forceAreaAni:!(w&&i>0)&&e.forceAreaAni,cover:e.cover}))),w&&this.current.slice(1).forEach((t=>this.micrio.wasm.e._fadeTo(t.ptr,.9999,!0)));const y=()=>this.current.forEach(((t,e)=>dr(c?1e3*(b(e)+(u?h/2:0)):0).then((()=>this.micrio.wasm.e._fadeIn(t.ptr))))),k=()=>{this.clearTimeouts(),requestAnimationFrame((()=>this.micrio.wasm.e.setCrossfadeDuration(this.micrio.wasm.getPtr(),m))),c&&this.images.forEach((t=>this.micrio.wasm.e._setZIndex(t.ptr,0))),e.coverLimit&&a.forEach((t=>{var i;return null==(i=this.images.find((e=>e.id==t.id)))?void 0:i.camera.setCoverLimit(!!e.coverLimit)})),this.clickable&&this.placeGrid(),this.lastAction=void 0,f=!0,i(this.current)};h||v?(e.noFade||(this._fadeTo=setTimeout(y,Math.max(0,h/2*1e3))),this._to=setTimeout(k,1e3*(Math.max(v,h)+(c?(a.length-1)*this.transitionDelay:0)))):(e.noFade||y(),k())}))}hasChanged(){return this.current.map((t=>t.id)).join(",")!=this.images.map((t=>t.id)).join(",")}getImage(t){var e,i;const r=t.split("|"),n=r[0].split(","),s=r[1]?r[1].split(",").map(Number):[1];let o=0,a=0;return{path:null==(e=this.image.$info)?void 0:e.path,id:n[0],width:o=Number(n[1])||o,height:a=Number(n[2])||a,isDeepZoom:"d"==n[3],isPng:"p"==n[4],isWebP:"w"==n[4],size:s,view:n[5]?n[5].split("/").map(Number):void 0,area:n[6]?n[6].split("/").map(Number):void 0,settings:vr(this.image.$settings||{},{focus:n[7]?n[7].split("-").map(Number):null}),cultures:(null==(i=n[8])?void 0:i.replace(/\-/g,","))||void 0}}getCols(t,e){let i=Math.ceil(e/Math.ceil(Math.sqrt(e)));if(t==e){const e=Math.floor(Math.sqrt(t)),r=[];for(let n=e;n<i+e;n++)t%n||r.push(n);r.length&&(i=r[Math.floor(r.length/2)])}return i}printGrid(t,e){var i;e.keepGrid||this.removeGrid();const r=t.reduce(((t,e)=>t+e.size.reduce(((t,e)=>e*t),1)),0),n=e.columns??(e.horizontal?t.length:this.getCols(t.length,r));this._grid.style.gridTemplateColumns=`repeat(${n}, auto)`,this._grid.textContent="",this._grid.style.removeProperty("--translate"),this._grid.style.removeProperty("--scale"),t.forEach((t=>{if(!t.id)return;this._buttons.has(t.id)||this._buttons.set(t.id,document.createElement("button"));const e=this._buttons.get(t.id);"1"!=t.size.toString()?(e.style.gridArea=`auto / auto / span ${t.size[1]} / span ${t.size[0]||t.size[1]}`,this.cellSizes.set(t.id,t.size)):(e.style.removeProperty("grid-area"),this.cellSizes.delete(t.id)),e.dataset.id=t.id,this._grid.appendChild(e)})),e.keepGrid&&this._grid.parentNode||this.micrio.insertBefore(this._grid,(null==(i=this.micrio.firstChild)?void 0:i.nextSibling)??null),this.micrio.events.dispatch("grid-layout-set",this);const s=this.micrio.offsetWidth,o=this.micrio.offsetHeight,a=Math.max(0,Math.min(1,1-(e.scale??1)));this._grid.style.transform="",this._grid.childNodes.forEach((e=>{if(!e)return;const i=e,r=i.dataset.id,n=i.getBoundingClientRect(),l=t.find((t=>t.id==r)),c=[a/2*n.width,a/2*n.height];l&&!l.area&&(l.area=[(n.x+c[0])/s,(n.y+c[1])/o,(n.x+n.width-c[0])/s,(n.y+n.height-c[1])/o])})),e.keepGrid||this._grid.remove()}placeGrid(){var t;!this.clickable||this.micrio.state.$tour||this.micrio.state.$marker||this._grid.parentNode||(this.micrio.insertBefore(this._grid,(null==(t=this.micrio.firstChild)?void 0:t.nextSibling)??null),this.viewUnsub=this.image.state.view.subscribe(this.updateGrid))}removeGrid(){this._grid.parentNode&&(this.viewUnsub&&this.viewUnsub(),this._grid.remove())}updateGrid(){const t=this.image.camera.getXY(0,0,!0);this._grid.style.setProperty("--translate",`translate3d(${t[0]}px, ${t[1]}px, 0)`),this._grid.style.setProperty("--scale",this.image.camera.getScale().toString()),this._grid.dispatchEvent(new CustomEvent("update"))}placeImage(t,e){let i=this.images.find((e=>e.id==t.id));i&&t.area?dr(1e3*e.delay).then((()=>{i.camera.setArea(t.area,{direct:0==e.duration||!e.forceAreaAni&&!Ki(i.visible)}),e.delay&&this.micrio.wasm.render()})):(t.lang=this.micrio.lang,this.micrio.wasm.addChild(i=new xa(this.micrio.wasm,t,{area:t.area}),this.image),this.images.push(i));const r={duration:1e3*e.duration,timingFunction:this.timingFunction,limit:!1};if(!e.noCamAni&&!i.camera.aniDone&&i.ptr>0){const n=!!e.cover||i.camera.getCoverLimit();if(t.view||!n)i.camera.flyToView(t.view??[0,0,1,1],r).catch((()=>{}));else if(t.area&&t.width&&t.height){const e=(t.area[2]-t.area[0])*this.micrio.offsetWidth/((t.area[3]-t.area[1])*this.micrio.offsetHeight);i.camera.flyToView(e<t.width/t.height?[.5,0,.5,1]:[0,.5,1,.5],r).catch((()=>{}))}else i.camera.flyToCoverView(r).catch((()=>{}))}return i}removeImages(t){t.forEach((t=>{t.ptr>=0&&this.micrio.wasm.e._fadeOut(t.ptr)})),this.micrio.wasm.render()}insideGrid(){const t=this.micrio.$current;return t==this.image||!!this.images.find((e=>e==t))}async reset(t,e,i){var r,n;const s=this.history[0];return this.images.forEach((t=>t.camera.stop())),this.image.camera.stop(),this.markersShown.set([]),await Xt(),i||e||!(null==(r=this.micrio.camera)?void 0:r.isZoomedOut())||this.micrio.state.$tour||this.$focussed||this.hasChanged()||(t=0),this.set((null==s?void 0:s.layout)||(null==(n=this.image.$info)?void 0:n.grid),{noHistory:!0,duration:t,noCamAni:e,forceAni:i,horizontal:!!s&&s.horizontal}).then((t=>(this.depth.set(this.history.length=0),this.micrio.current.set(this.image),t)))}switchToGrid(){const t=this.$focussed;if(!t)return;const e=t.camera.getView();e&&this.reset(0,!0).then((()=>{t.opts.area&&this.image.camera.setView(t.opts.area,{noLimit:!0}),t.camera.setView(e,{noLimit:!0}),this.micrio.current.set(this.image)}))}async flyToMarkers(t,e,i){const r=null==t?void 0:t.split("|").map((t=>t.trim())),n=(null==r?void 0:r[0])??"",s=n?this.images.filter((t=>{var e,i;return!!(null==(i=null==(e=t.$data)?void 0:e.markers)?void 0:i.find((t=>t.tags.includes(n))))})):this.images;return this.set(s.map((t=>{var e,r;const s=null==(r=null==(e=t.$data)?void 0:e.markers)?void 0:r.find((t=>t.tags.indexOf(n)>=0));return this.getString(t.$info,{view:i||null==s?void 0:s.view})})).join(";"),{duration:e,horizontal:"h"==(null==r?void 0:r[1])})}async back(t){const e=this.history.pop();if(!e)return;this.depth.set(this.history.length),this.micrio.current.set(this.image);this.$focussed&&this.blur(),await this.set(e.layout,{duration:t,noHistory:!0,horizontal:e.horizontal,view:e.view})}setTimingFunction(t){const e=this.micrio.wasm.getPtr();this.micrio.wasm.e.setGridTransitionTimingFunction(e,va.Camera.TimingFunction[this.timingFunction=t])}async focus(t,e={}){var i;if(!t)return this.back();e.coverLimit&&(e.cover=!0);const r=!e.view&&!e.cover,n=this.micrio;Ki(n.visible).find((t=>t==this.image))||n.current.set(this.image);const s=this.$focussed;if(s==t)return;!(null==(i=e.transition)?void 0:i.startsWith("slide-"))&&(0==e.duration||s&&!n.wasm.e._areaAnimating(s.ptr)&&!this.current.find((e=>e==t)))&&t.camera.setArea([0,0,1,1],{noDispatch:!0,direct:!0}),s&&this.blur(),t.camera.setCoverLimit(!!e.cover),this.setTimingFunction("ease");const o=await this.transition(t,s,this.getString(t.$info,{view:e.view}),e);return n.wasm.e._setZIndex(t.ptr,3),this.focussed.set(t),Ki(t.visible)||"crossfade"!=e.transition&&e.transition||(e.duration=0),this.set(o,{noBlur:!0,duration:e.duration,forceAreaAni:"crossfade"!=e.transition,cover:!!e.cover,coverLimit:!!e.coverLimit}).then((()=>{n.events.dispatch("grid-focus",t);const e=t.$info;this.removeGrid(),n.$current!=t&&n.current.set(t);const i=n.offsetWidth/n.offsetHeight,s=(1-e.width/e.height/i)/2;!t.camera.aniDone&&r&&t.camera.flyToFullView({duration:1e3*this.aniDurationIn}).catch((()=>{})),this.image.camera.setLimit([s,0,1-s,1])})).catch((()=>{}))}async transition(t,e,i,{duration:r,view:n,transition:s,noViewAni:o,exitView:a,blur:l,cover:c}){if(!s)return i;if("crossfade"==s&&(t.camera.setArea([0,0,1,1]),o=!0),n&&o&&t.camera.setView(n,{noRender:!0,noLimit:!0}),!e||"crossfade"==s)return i;const u=s.startsWith("slide")||s.startsWith("swipe"),d=s.startsWith("behind"),h=u?s.endsWith("-up")?0:s.endsWith("-down")?180:s.endsWith("-left")?270:90:void 0;if((u||d)&&this.micrio.wasm.e._fadeTo(t.ptr,.9999,!0),s.startsWith("slide"))t.camera.setArea(0==h?[0,-.5,1,0]:180==h?[0,1,1,1.5]:270==h?[-.5,0,0,1]:[1,0,1.5,1],{noDispatch:!0,direct:!0});else if(s.startsWith("swipe"))t.camera.setArea(0==h?[0,-1,1,0]:180==h?[0,1,1,2]:270==h?[-1,0,0,1]:[1,0,2,1],{noDispatch:!0,direct:!0}),i=[this.getString(e.$info,{view:a??e.camera.getView(),area:0==h?[0,1,1,2]:180==h?[0,-1,1,0]:270==h?[1,0,2,1]:[-1,0,0,1]}),this.getString(t.$info,{view:n,area:[0,0,1,1]})].join(";");else if(d){t.camera.setArea([0,0,1,1]),t.camera.setView([0,0,1,1]);const i=[this.getString(e.$info,{view:[0,0,1,1]}),this.getString(t.$info,{view:[0,0,1,1]})];"behind-left"==s&&i.reverse(),await this.set(i.join(";"),{noBlur:!0,horizontal:!0,coverLimit:c}).then((()=>dr(200)))}if(l&&!isNaN(l)&&l>0){const t=(r=r??this.nextCrossFadeDuration??this.aniDurationIn)/2,e=this.micrio.canvas.element.style;e.transition=`filter ${t}s ease`,e.filter=`blur(${l}px)`,setTimeout((()=>{e.filter="",setTimeout((()=>e.transform=""),1e3*t)}),1e3*t)}return i}blur(){const t=this.$focussed;t&&(this.micrio.wasm.e._setZIndex(t.ptr,2),this.micrio.events.dispatch("grid-blur"),this.focussed.set(void 0),this.image.camera.setLimit([0,0,1,1]),this.micrio.current.set(this.image))}tourEvent(t){var e;const i=t.detail;i&&(null==(e=i.action)?void 0:e.startsWith("grid:"))&&i.active&&this.action(i.action.slice(5),i.data,i.end-i.start)}action(t,e,i){"string"==typeof t&&(t=va.Grid.GridActionType[t]);const r=t+(e??"");if(this.lastAction!=r){switch(t){case va.Grid.GridActionType.focus:const t=null==e?void 0:e.split("|").map((t=>t.trim())),r=(null==t?void 0:t[0])??"",n=null==r?void 0:r.split(",").map((t=>this.images.find((e=>e.id==(null==t?void 0:t.trim()))))).filter((t=>void 0!==t));1==n.length?this.focus(n[0],{duration:i}):n.length>0&&this.set(n.map((t=>this.getString(t.$info))).join(";"),{duration:i,horizontal:"h"==(null==t?void 0:t[1])});break;case va.Grid.GridActionType.flyTo:const s=null==e?void 0:e.split(",").map((t=>this.current.find((e=>e.id==(null==t?void 0:t.trim())))));(null==s?void 0:s.length)?this.image.camera.flyToView([Math.min(...s.map((t=>{var e;return(null==(e=null==t?void 0:t.opts.area)?void 0:e[0])??0}))),Math.min(...s.map((t=>{var e;return(null==(e=null==t?void 0:t.opts.area)?void 0:e[1])??0}))),Math.max(...s.map((t=>{var e;return(null==(e=null==t?void 0:t.opts.area)?void 0:e[2])??1}))),Math.max(...s.map((t=>{var e;return(null==(e=null==t?void 0:t.opts.area)?void 0:e[3])??1})))],{duration:i?1e3*i:void 0}).catch((()=>{})):console.warn("Given image IDs gave no current displayed images",event);break;case va.Grid.GridActionType.focusTagged:this.flyToMarkers(e,i);break;case va.Grid.GridActionType.focusWithTagged:this.flyToMarkers(e,i,!0);break;case va.Grid.GridActionType.reset:this.reset(i);break;case va.Grid.GridActionType.back:this.back(i);break;case va.Grid.GridActionType.switchToGrid:this.switchToGrid();break;case va.Grid.GridActionType.nextFadeDuration:this.nextCrossFadeDuration=Number(e);break;case va.Grid.GridActionType.filterTourImages:br(this.micrio.state.tour).then((t=>{if(!t)return;if(!("steps"in t)||!t.stepInfo)return;const r=t.stepInfo.map((t=>t.micrioId)),n=r.filter(((t,e)=>r.indexOf(t)==e)).map((t=>this.images.find((e=>e.id==t)))).filter((t=>!!t)).map((t=>this.getString(t.$info))).join(";");n&&this.set(n,{duration:i,horizontal:"h"==e})}));break;default:console.warn("Warning: unknown grid tour event",event)}this.lastAction=r}}async enlarge(t,e,i=e){var r;return this.set(((null==(r=this.history[this.history.length-1])?void 0:r.layout)||this.image.$info.grid).split(";").map(((r,n)=>`${r}|${n==t?`${e},${i}`:1}`)).join(";"),{noHistory:!0,keepGrid:!0,duration:500})}getRelativeView(t,e){const i=t.opts.area??[0,0,1,1],r=i[2]-i[0],n=i[3]-i[1];return[i[0]+r*e[0],i[1]+n*e[1],i[0]+r*e[2],i[1]+n*e[3]]}};ll.getString=(t,e)=>{var i,r,n,s;return[t.id,t.width,t.height,t.isDeepZoom?"d":"",t.isPng?"p":t.isWebP?"w":"",null==(i=e.view)?void 0:i.map(al).join("/"),null==(r=e.area)?void 0:r.map(al).join("/"),null==(s=null==(n=t.settings)?void 0:n.focus)?void 0:s.map(al).join("-"),e.cultures].join(",").replace(/,+$/,"")+(e.size?`|${e.size.join(",")}`:"")};let cl=ll;class ul{constructor(t){this.micrio=t,this.element=document.createElement("canvas"),this.resizing=!1,this.hasPerspective=!1,this.viewport={width:0,height:0,left:0,top:0,ratio:0,scale:0,portrait:!1},this.isMobile=Zi(!1),this.getRatio=(t=(t=>null==(t=this.micrio.$current)?void 0:t.$settings)()??{})=>!mr.iOS&&!(null==t?void 0:t.noRetina)&&self.devicePixelRatio&&Math.max(1,Math.min(2,self.devicePixelRatio))||1,this.onresize=this.onresize.bind(this),self.ResizeObserver&&(this.resizeObserver=new self.ResizeObserver(this.onresize)),this.element.className="micrio"}get $isMobile(){return Ki(this.isMobile)}place(){if(this.element.parentNode)return;const t=this.micrio.querySelector("img.preview");this.micrio.insertBefore(this.element,t?t.nextSibling:this.micrio.firstChild)}hook(){this.onresize(),this.resizeObserver?this.resizeObserver.observe(this.element):window.addEventListener("resize",this.onresize)}unhook(){this.resizeObserver?this.resizeObserver.unobserve(this.element):window.removeEventListener("resize",this.onresize)}onresize(){var t,e,i;const r=this.element.getBoundingClientRect();(null==(t=this.micrio.$current)?void 0:t.is360)&&(this.hasPerspective=!0);let n=r.width,s=r.height;if(!n||!s)return;const o=self.getComputedStyle(this.element),a=parseFloat(o.width);isNaN(a)||(s=parseFloat(o.height)*n/Math.max(1,a));const l=this.micrio.hasAttribute("data-static")?1:Math.floor(n)/this.micrio.offsetWidth;n/=l,s/=l;const c=1!=l?1:this.getRatio(),u=this.viewport;u.width==n&&u.height==s&&u.ratio==c&&u.scale==l||(this.hasPerspective&&(this.micrio.style.perspective=s/2+"px"),u.width=n,u.height=s,u.ratio=c,u.scale=l,u.top=r.top,u.left=r.left,u.portrait=(null==(e=window.matchMedia("(orientation: portrait)"))?void 0:e.matches)??s>n,this.resizing=!0,this.element.width=n*c,this.element.height=s*c,this.micrio.webgl.gl.viewport(0,0,u.width*u.ratio,u.height*u.ratio),null==(i=this.micrio.webgl.postpocessor)||i.resize(),this.micrio.wasm.resize(u),this.resizing=!1,this.micrio.events.dispatch("resize",r),setTimeout((()=>this.isMobile.set(/mobile/i.test(navigator.userAgent))),10))}setMargins(t,e){this.micrio.wasm.e&&this.micrio.wasm.e.setArea(this.micrio.wasm.getPtr(),t,e)}}const dl=class t extends HTMLElement{constructor(){super(),this.printed=!1,this.canvases=[],this.current=Zi(),this.visible=Zi([]),this.canvas=new ul(this),this.events=new il(this),this.state=new ya.Main(this),this.analytics=new ol(this),this._router=new nl(this),this.barebone=Zi(!1),this.webgl=new Za(this),this.wasm=new Xa(this),this.defaultSettings=this.defaultSettings,this.loading=Zi(!0),this.switching=Zi(!1),this.isMuted=Zi("1"==localStorage.getItem(da)),this._lang=Zi(),this.keepRendering=!1,this.loadV5Album=(t,e)=>(t=>"MICRIO_ALBUM"in self?Promise.resolve(self.MICRIO_ALBUM):Tr(`https://i.micr.io/album/${t}.json`))(t).then((t=>{var i;if(!t)return;const r=t.id+"."+t.revision,n=e.path=(null==(i=t.organisation)?void 0:i.baseUrl)??la;return e.organisation=t.organisation,e.settings.album=t,e.settings.gallery={archive:r,sort:t.sort,type:t.type,startId:e.id,isSpreads:t.isSpreads,coverPages:t.coverPages,revisions:t.published},delete e.id,this.loadArchiveBin(n,r).then((()=>this.loadGallery(e,n,!0)))}),(t=>this.printError((null==t?void 0:t.message)||t))),this.getArchiveIndex=async(t,e=aa)=>Ta.get(`${e}${t}.json`).then((t=>(t.images.forEach((t=>yr.set(`${e}${t.id}/info.json`,t))),t))),this.current.subscribe((t=>this._current=t));let t=!1;br(this.loading,{targetValue:!1}).then((()=>{this.setAttribute("data-loaded",""),this.switching.subscribe((e=>{e?this.setAttribute("data-switching",""):(t||Xt().then((()=>this.events.dispatch("show",this))),t=!0,this.removeAttribute("data-switching"))}));const e=this.querySelector("img.preview");e&&setTimeout((()=>e.remove()),500)}))}static get observedAttributes(){return["id","muted","data-grid","data-limited","lang"]}get $current(){return this._current}get camera(){var t;return null==(t=this._current)?void 0:t.camera}attributeChangedCallback(t,e,i){var r,n,s,o;switch(t){case"id":if(!this.isConnected||!i)return;this.printed?this.open(i):this.print();break;case"muted":this.isMuted.set(null!==i);break;case"data-grid":this.printed?null==(n=null==(r=this.$current)?void 0:r.grid)||n.set(i):this.print();break;case"data-limited":(null==(s=this.wasm)?void 0:s._vertexBuffer)&&(null==(o=this.$current)?void 0:o.ptr)&&this.wasm.e._setLimited(this.$current.ptr,!!i);break;case"lang":{let t=Ki(this._lang);t!=i&&(this._lang.set(i),Xr.set(Wr[i]??Wr.en),i&&(qn.indexOf(i)>=0?this.setAttribute("dir","rtl"):this.removeAttribute("dir")),t&&this.events.dispatch("lang-switch",i));break}}}connectedCallback(){this.canvas.place(),(this.hasAttribute("data-router")||this.hasAttribute("data-space"))&&"false"!=this.getAttribute("data-router")&&this._router.hook(),!this.id&&!this.hasAttribute("data-gallery")||this.printed||this.print(),"muted"in this||(Object.defineProperty(this,"muted",{get(){return Ki(this.isMuted)},set(t){t?this.setAttribute("muted",""):this.removeAttribute("muted")}}),this.isMuted.subscribe((t=>{this.muted=t,t?(localStorage.setItem(da,"1"),this.events.dispatch("audio-mute")):(localStorage.removeItem(da),this.events.dispatch("audio-unmute"))})))}addEventListener(t,e,i){super.addEventListener(t,e,i)}removeEventListener(t,e,i){super.removeEventListener(t,e,i)}destroy(){this.current.set(void 0),this._router.unhook(),this.events.enabled.set(!1),this.canvas.unhook(),this.analytics.unhook(),this.wasm.unbind(),this._ui&&function(t,e){const i=ti.get(t);i?(ti.delete(t),i(e)):Promise.resolve()}(this._ui),delete this._ui,this.printed=!1}loadArchiveBin(t,e){return this.printUI(!0,!0),Ta.load(t,"g/"+e,(t=>{var e,i;return null==(i=null==(e=this._ui)?void 0:e.setProps)?void 0:i.call(e,{loadingProgress:t})}))}async print(){var t,e,i,r;if(this.printed)return;this.printed=!0,await Xt();const n=this.getOptions();if(n.settings||(n.settings={}),n.settings.noControls&&this.state.ui.controls.set(!1),null==(t=n.settings.gallery)?void 0:t.archive){const t=null==(e=n.settings.gallery)?void 0:e.archive,i=/\.\d+$/.test(t),r=n.path||(Pr(t.replace(/\.\d+$/,""))?la:aa);i&&await this.loadArchiveBin(r,t),n.settings.gallery.startId=n.id,n.grid?await this.setGrid(n,r):await this.loadGallery(n,r,i),i||delete n.settings.gallery.archive,n.path||(n.path=r),delete n.id}else(null==(i=n.id)?void 0:i.startsWith("album/"))?await this.loadV5Album(n.id.replace("album/",""),n):n.id&&Pr(n.id)&&!this.hasAttribute("width")&&!this.hasAttribute("height")&&await xr(n.id,n.forceInfoPath?n.path:void 0,null==(r=n.settings)?void 0:r.forceDataRefresh).then((t=>(null==t?void 0:t.albumId)?this.loadV5Album(t.albumId,n):void 0));this.keepRendering=!!n.settings.keepRendering;const s=n.id||n.gallery||n.grid;if(this.events.dispatch("print",n),void 0!==n.settings.lazyload&&"IntersectionObserver"in window){const t=new IntersectionObserver((e=>{e[0]&&e[0].isIntersecting&&(t.unobserve(this),s&&this.open(n))}),{rootMargin:100*n.settings.lazyload+"% 0px"});t.observe(this)}else s&&requestAnimationFrame((()=>this.open(n)))}printUI(e,i){var r,n;this._ui?null==(n=(r=this._ui).setProps)||n.call(r,{noHTML:e,noLogo:i}):this._ui=Je(t.Svelte,{target:this,props:{micrio:this,noHTML:e,noLogo:i}})}printError(t){var e,i;null==(i=null==(e=this._ui)?void 0:e.setProps)||i.call(e,{error:t??"An unknown error has occurred"})}open(t,e={}){var i,r,n,s;this.printed||this.print();const o="string"==typeof t,a=this.getOptions();let l=o?{...a,id:t}:t;if(l.settings||(l.settings={}),(null==(r=null==(i=a.settings)?void 0:i.gallery)?void 0:r.archive)&&(/\.\d+$/.test(a.settings.gallery.archive)||delete a.settings.gallery.archive),o||vr(a.settings,l.settings),this.defaultSettings&&vr(this.defaultSettings,l.settings),this.$current&&l.id==(null==(n=this.$current)?void 0:n.id))return this.$current;e.splitScreen||e.gridView||!this.$current||this.switching.set(!0),l.settings.noGTag||this.analytics.hook(),this.printed=!0,this.printUI(!!l.settings.noUI,!!l.settings.noLogo);let c=this.canvases.find((t=>l.id&&t.id==l.id)),u=!1;const d=null==(s=this.canvases[0])?void 0:s.grid;if(!c&&d){const t=l.id?d.images.find((t=>t.id==l.id)):void 0;u=!!t,c=l.id?t:this.canvases[0],u&&!d.insideGrid()&&this.current.set(this.canvases[0])}if(!c){if(this.canvases.length){const t=this.canvases[0];l.path=t.dataPath,l.lang=this.lang}this.canvases.push(c=new xa(this.wasm,l,e.splitScreen?{secondaryTo:e.splitTo??this._current,isPassive:e.isPassive}:void 0));const t=this.state.value&&this.state.value.c.find((t=>t[0]==l.id));t&&c.state.set(t)}e.startView&&(c.state.view.set(l.settings.view=e.startView),c.ptr&&c.camera.e&&c.camera.setView(l.settings.view,{noRender:!0})),this.lang||(this.lang="en");const h=()=>{var t,i,r,n;c&&(br(c.info).then((t=>{var i;if(t&&c){if(!this.webgl.gl)switch(this.webgl.init(),this.canvas.hook(),null==(i=t.settings)?void 0:i.theme){case"light":this.setAttribute("data-light-mode","");break;case"os":this.setAttribute("data-auto-scheme","")}t.grid&&!c.grid&&(c.grid=new cl(this,c)),Xt().then((()=>this.dispatchEvent(new CustomEvent("load",{detail:c})))),e.splitScreen&&Xt().then((()=>{c&&((null==d?void 0:d.image.camera.aniDoneAdd)&&d.image.camera.aniDoneAdd.length>0?d.image.camera.aniDoneAdd.push((()=>null==c?void 0:c.splitStart())):c.splitStart())}))}})),this.wasm.e.set360Orientation(this.wasm.getPtr(),(null==(t=e.vector)?void 0:t.direction)??0,(null==(i=e.vector)?void 0:i.distanceX)??0,(null==(r=e.vector)?void 0:r.distanceY)??0),this.wasm.preventDirectionSet=!e.vector,!u||e.gridView&&(null==d?void 0:d.current.find((t=>t.id==l.id)))?e.splitScreen?this.wasm.setCanvas(c):this.current.set(c):null==d||d.focus(c,{view:null==(n=l.settings)?void 0:n.view}).then((()=>this.current.set(c))))};return this.wasm.ready?h():this.wasm.load().then(h),c.noImage&&this.loading.set(!1),c}close(t){t.opts.secondaryTo?t.splitEnd():this.wasm.removeCanvas(t)}getOptions(){const t={gallery:{}},e={settings:t,id:this.id},i=(t,e,i)=>{const r=e.split(".");for(let n=0;n<r.length-1;n++)t=t[r[n]];t[r[r.length-1]]=i};for(const r in ma.STRINGS){const n=ma.STRINGS[r],s=this.getAttribute(r),o=n.f||r.replace("data-","");s&&i(n.r?e:t,o,s)}for(const r in ma.BOOLEANS){const n=ma.BOOLEANS[r],s=this.getAttribute(r),o=n.f||r.replace("data-",""),a=null!=s&&""==s||"true"==s;(a||"false"==s)&&i(n.r?e:t,o,n.n?!a:!!a)}for(const r in ma.NUMBERS){const n=ma.NUMBERS[r],s=n.f||r.replace("data-","");let o=this.getAttribute(r);void 0!==n.dN&&null==o&&(o=n.dN),null==o||isNaN(Number(o))||i(n.r?e:t,s,Number(o))}for(const r in ma.ARRAYS){const n=ma.ARRAYS[r],s=this.getAttribute(r),o=n.f||r.replace("data-","");null!=s&&i(n.r?e:t,o,s.split(",").map((t=>Number(t))))}return t.static&&(t.noUI=t.skipMeta=!0,t.hookEvents=!1),e.settings&&e.grid&&e.grid.indexOf(".")>0&&(e.settings.gallery.archive=e.grid),e}async loadGallery(t,e,i){var r;let n=null==(r=t.settings)?void 0:r.gallery,s=null==n?void 0:n.archive;if(!n||!s)return;const o=t.settings;if(i){const t=await this.getArchiveIndex(s.split(".")[0],e);n.archiveLayerOffset=t.delta,s=t.images.sort("name"==n.sort?(t,e)=>t.title&&e.title?t.title<e.title?-1:t.title>e.title?1:0:0:"-name"==n.sort?(t,e)=>t.title&&e.title?t.title<e.title?1:t.title>e.title?-1:0:0:"-created"==n.sort?(t,e)=>t.created&&e.created?t.created<e.created?1:t.created>e.created?-1:0:0:(t,e)=>t.created&&e.created?t.created<e.created?-1:t.created>e.created?1:0:0).map((t=>`${t.id},${t.width},${t.height},${t.isDeepZoom?"d":""},${t.isPng?"p":t.isWebP?"w":""},${t.tileSize||""}`.replace(/\,+$/,""))).join(";")}const a=s.split(";").map((t=>t.trim()));if(!i){const t=a.filter((t=>t.startsWith("http"))).map((t=>Tr(t)));t.length&&await Promise.all(t).then((t=>t.forEach(((t,e)=>{t&&(a[e]=`${t["@id"]},${t.width},${t.height}`)}))))}const l=a.map((t=>t.split(",").map((t=>isNaN(t)?t:Number(t)))));l.forEach(((t,e)=>{e>0&&!t[2]&&t.push(...l[e-1].slice(1))}));const c=t.height=Math.max(...l.map((t=>t[2])));n.type||(n.type="swipe");const u="switch"==n.type||"swipe-full"==n.type||"omni"==n.type,d=n.isSpreads,h=d&&!u?Math.round(l[0][1]/20):0,m=d?n.coverPages??0:0,v=t.width=u?Math.max(...l.map((t=>t[1]*(d?2:1)))):l.reduce(((t,e)=>t+e[1]+h),0);let p=0;t.gallery=l.map(((t,i)=>{var r;return new xa(this.wasm,{id:t[0],path:e,width:t[1],height:t[2],isDeepZoom:"d"==t[3],isPng:"p"==t[4],isWebP:"w"==t[4],tileSize:t[5]||1024,revision:null==(r=null==n?void 0:n.revisions)?void 0:r[t[0]],settings:{skipMeta:!0,gallery:n}},{isEmbed:u,useParentCamera:u,area:u?d?i-m<0||i==l.length-1&&(i-m)%2==0?[.25,0,.75,1]:(i-m)%2==0?[0,0,.5,1]:[.5,0,1,1]:[0,0,1,1]:[(p+=i>0&&(i<m||(i-m)%2==0)?h:0)/v,(c-t[2])/2/c,(p+=t[1])/v,((c-t[2])/2+t[2])/c]})})),o.pinchZoomOutLimit=!0,t.gallery.length&&(o.view=t.gallery[Math.max(0,t.gallery.findIndex((t=>t.id==n.startId)))].opts.area)}async setGrid(t,e){var i;t.settings&&t.grid&&((null==(i=t.settings.gallery)?void 0:i.archive)==t.grid&&(this.gridInfoData=await this.getArchiveIndex(t.grid.split(".")[0],e),t.grid=this.gridInfoData.images.map((t=>cl.getString(t,{cultures:"cultures"in t?t.cultures.join("-"):void 0}))).join(";")),t.width=this.offsetWidth*this.canvas.getRatio(),t.height=this.offsetHeight*this.canvas.getRatio(),t.settings.zoomLimit=15,t.settings.minimap=!1,t.settings.initType="cover",this.removeAttribute("data-grid"))}get lang(){return Ki(this._lang)}set lang(t){this.setAttribute("lang",t)}};dl.jsonCache=yr;let hl=dl;hl.Svelte=function(t,e){Te(e,!0);const[i,r]=ir(),n=()=>tr(jt(A),"$settings",i),s=()=>tr(jt(E),"$info",i),o=()=>tr(jt($),"$data",i),a=()=>tr(k,"$tour",i),l=()=>tr(P,"$volume",i),c=()=>tr(w,"$visible",i),u=()=>tr(_,"$markerPopup",i),d=()=>tr(x,"$popover",i);let h=or(e,"noHTML",15),m=or(e,"noLogo",23,h),v=or(e,"loadingProgress",7,1),p=or(e,"error",7,void 0);ke("micrio",e.micrio),ke("markerImages",new Map);const f="markers"==e.micrio.getAttribute("data-ui");f&&h(!0);const g="false"!=e.micrio.getAttribute("data-embeds"),{visible:w,state:b,isMuted:y}=e.micrio,{tour:k,marker:T,popup:_,popover:x}=b;let E=j(void 0),$=j(void 0),A=j(void 0);function S(t,e){if(e)for(let i,r=0;r<e.length;r++)if(e[r].id==t||(i=S(t,e[r].children)))return i??e[r]}let I=j(!1),M=j(void 0);const L=[];e.micrio.current.subscribe((t=>{t&&(er(Y(E,t.info,!0),"$info",i),er(Y(A,void 0),"$settings",i),jt(E)&&br(jt(E)).then((e=>{var r;e&&(Y(I,!0),er(Y(A,t.settings,!0),"$settings",i),!jt(M)&&(null==(r=e.organisation)?void 0:r.logo)&&Y(M,e.organisation,!0))})),er(Y($,t.data,!0),"$data",i)&&L.indexOf(t.id)<0&&br(jt($)).then((async i=>{var r,n;if(!i)return;if(L.push(t.id),await Xt().then(Xt),Ki(e.micrio.state.popover)||Ki(e.micrio.state.marker)||Ki(e.micrio.state.tour))return;const s=t.$settings.start;if(s)switch(s.type){case"marker":t.state.marker.set(s.id);break;case"markerTour":const o=null==(r=i.markerTours)?void 0:r.find((t=>t.id==s.id));o&&e.micrio.state.tour.set(o);break;case"tour":const a=null==(n=i.tours)?void 0:n.find((t=>t.id==s.id));a&&e.micrio.state.tour.set(a);break;case"page":const l=S(s.id,i.pages);l&&e.micrio.state.popover.set({contentPage:l,showLangSelect:!0})}})))}));const P=Zi(tr(y,"$isMuted",i)?0:1);ke("volume",P),y.subscribe((t=>P.set(t?0:1))),ke("mediaPaused",Zi(!1));let C=j(!1),D=j(B([]));ke("srt",Zi()).subscribe((t=>setTimeout((()=>{Y(D,t?[t]:[],!0)}),20)));let R=J((()=>{var t,e;return null==(e=null==(t=n())?void 0:t._360)?void 0:e.video})),z=J((()=>{var t;return null==(t=jt(R))?void 0:t.src})),O=J((()=>{var t;return null==(t=n())?void 0:t.omni})),N=J((()=>{var t;return null==(t=s())?void 0:t.gallery})),F=J((()=>{var t,e;return null==(e=null==(t=o())?void 0:t.markers)?void 0:e.filter((t=>!!t.positionalAudio))})),V=J((()=>{var t,e,i;return!!(null==(e=null==(t=o())?void 0:t.music)?void 0:e.items.length)||!!(null==(i=jt(F))?void 0:i.length)})),U=J((()=>a()||tr(T,"$marker",i))),q=J((()=>!h()||f)),W=J((()=>{var t;return!(m()||s()&&h()||(null==(t=n())?void 0:t.noLogo))})),X=J((()=>{var t;return h()||!jt(W)||(null==(t=n())?void 0:t.noOrgLogo)?void 0:jt(M)})),G=J((()=>{var t;return!(h()||jt(O)||e.micrio.spaceData||a()||(null==(t=s())?void 0:t.gallery))})),H=J((()=>!!jt(N)||!!jt(O))),Z=J((()=>!h()&&!!s())),K=J((()=>{var t;return!h()&&!jt(U)&&(null==(t=n())?void 0:t.showInfo)})),Q=J((()=>{var t;return!h()&&jt(I)&&!(null==(t=n())?void 0:t.noToolbar)}));var tt=Ma(),et=ut(tt),it=t=>{const e=J((()=>!!s().is360));bo(t,{get volume(){return l()},get data(){return o()},get is360(){return jt(e)}})};ei(et,(t=>{jt(V)&&o()&&s()&&t(it)}));var rt=dt(et,2),nt=t=>{Ms(t,nr({get src(){return jt(z)},get volume(){return l()},is360:!0,get width(){return s().width},get height(){return s().height}},(()=>jt(R))))};ei(rt,(t=>{jt(z)&&s()&&t(nt)}));var st=dt(rt,2),ot=t=>{var e=Ge();ri(ut(e),1,(()=>o().embeds),(t=>t.uuid),((t,e)=>{Sa(t,{get embed(){return jt(e)}})})),Ye(t,e)};ei(st,(t=>{g&&o()&&o().embeds&&t(ot)}));var at=dt(st,2),lt=t=>{Ur(t,{})};ei(at,(t=>{jt(W)&&t(lt)}));var ht=dt(at,2),mt=t=>{Nn(t,{})};ei(ht,(t=>{jt(Q)&&t(mt)}));var vt=dt(ht,2),pt=t=>{var e=Ge();ri(ut(e),1,c,(t=>t.uuid),((t,e)=>{sa(t,{get image(){return jt(e)}})})),Ye(t,e)};ei(vt,(t=>{jt(q)&&t(pt)}));var ft=dt(vt,2),gt=t=>{var e=Ge();ri(ut(e),1,(()=>c().filter((t=>t.$settings.minimap))),(t=>t.uuid),((t,e)=>{Vn(t,{get image(){return jt(e)}})})),Ye(t,e)};ei(ft,(t=>{jt(G)&&t(gt)}));var wt=dt(ft,2),bt=t=>{const e=J((()=>jt(V)||!(!jt(z)||!jt(R)||jt(R).muted)));Qn(t,{get hasAudio(){return jt(e)}})};ei(wt,(t=>{jt(Z)&&t(bt)}));var yt=dt(wt,2),kt=t=>{co(t,{get images(){return jt(N)},get omni(){return jt(O)}})};ei(yt,(t=>{jt(H)&&t(kt)}));var Tt=dt(yt,2),_t=t=>{qr(t,{get organisation(){return jt(X)}})};ei(Tt,(t=>{jt(X)&&t(_t)}));var xt=dt(Tt,2),Et=t=>{Eo(t,{get info(){return jt(E)},get data(){return jt($)}})};ei(xt,(t=>{jt(K)&&jt(E)&&jt($)&&t(Et)}));var $t=dt(xt,2),At=t=>{Xs(t,{get marker(){return u()}})};ei($t,(t=>{u()&&t(At)}));var St=dt($t,2),It=t=>{eo(t,{get tour(){return a()},get noHTML(){return h()},onminimize:t=>Y(C,!t)})};ei(St,(t=>{a()&&t(It)}));var Mt=dt(St,2),Lt=t=>{Vo(t,{get popover(){return d()}})};ei(Mt,(t=>{d()&&t(Lt)}));var Pt=dt(Mt,2);ri(Pt,16,(()=>jt(D)),(t=>t),((t,e)=>{os(t,{get src(){return e},get raised(){return jt(C)}})}));var Ct=dt(Pt,2),Dt=t=>{!function(t,e){var i=$o(),r=ct(i);En(r,{name:"error"});var n=dt(r);se((()=>Ke(n,` ${e.message??""}`))),Ye(t,i)}(t,{get message(){return p()}})};ei(Ct,(t=>{p()&&t(Dt)}));var Rt=dt(Ct,2),zt=t=>{!function(t,e){const i=2*Math.PI*40;let r=J((()=>i*(1-e.progress)));var n=Ia();xi(n,"viewBox","0 0 100 100");var s=ct(n);xi(s,"r",40),xi(s,"cx",50),xi(s,"cy",50);var o=dt(s);xi(o,"r",40),xi(o,"cx",50),xi(o,"cy",50),xi(o,"stroke-dasharray",`${i??""}px`),se((()=>xi(o,"stroke-dashoffset",`${jt(r)??""}px`))),zi(1,n,(()=>Nr),(()=>({delay:500}))),zi(2,n,(()=>Nr)),Ye(t,n)}(t,{get progress(){return v()}})};ei(Rt,(t=>{v()<1&&t(zt)})),Ye(t,tt);var Ot=_e({setProps:function(t){"error"in t&&p(t.error),void 0!==t.noHTML&&h(t.noHTML),void 0!==t.noLogo&&m(t.noLogo),void 0!==t.loadingProgress&&v(t.loadingProgress)}});return r(),Ot},hl.VERSION=oa,customElements.define("micr-io",hl),console.log("%c◈%c Micrio %cv5.3.2 - https://micr.io/","color: #00d4ee","color: #c5ff5b","color: inherit")}();
25
25
  })(`html{--micrio-color: #fff;--micrio-color-hover: #45A4E4;--micrio-border-radius: 4px;--micrio-background: rgba(41,41,41,.75);--micrio-background-filter: blur(8px);--micrio-popover-background: rgba(41,41,41,.75);--micrio-icon-size: 18px;--micrio-text-align: left;--micrio-line-height: 1.5em;--micrio-border-margin: 16px;--micrio-button-size: 48px;--micrio-button-shadow: 0 4px 8px rgba(0,0,0,.33);--micrio-marker-size: 16px;--micrio-marker-text-color: #fff;--micrio-marker-text-shadow: 0px 2px 4px rgba(0,0,0,.6);--micrio-marker-highlight: #00d4ee;--micrio-marker-color: #fff;--micrio-marker-border-radius: 100%;--micrio-marker-border-color: rgba(255,255,255,.2);--micrio-marker-border-size: 8px;--micrio-marker-icon: none;--micrio-marker-transition: background-color .25s ease, opacity .15s ease, border-width .15s ease, width .15s ease, height .15s ease;--micrio-popup-shadow: 0 8px 16px rgba(0,0,0,.33);--micrio-popup-padding: 16px;--micrio-progress-bar-background: rgba(255,255,255,.25);--micrio-progress-bar-height: 4px;--micrio-waypoint-size: 120px}micr-io[data-light-mode]{--micrio-color: #000;--micrio-color-hover: #196DA6;--micrio-background: rgba(255,255,255,.66);--micrio-progress-bar-background: rgba(0,0,0,.25);--micrio-popover-background: rgba(41,41,41,.75)}@media (prefers-color-scheme: light){micr-io[data-auto-scheme]{--micrio-color: #000;--micrio-color-hover: #196DA6;--micrio-background: rgba(255,255,255,.66);--micrio-progress-bar-background: rgba(0,0,0,.25)}}@media (max-width: 500px){html{--micrio-border-margin: 5px;--micrio-button-size: 48px}}micr-io{display:block;-webkit-user-select:none;user-select:none;-webkit-touch-callout:none;overflow:hidden;position:relative;width:100%;height:100%;min-height:200px;backface-visibility:hidden;-webkit-backface-visibility:hidden;background-repeat:no-repeat;background-position:center center;background-size:contain;container-type:size}micr-io,micr-io button{font-family:var(--micrio-font-family, inherit);font-size:var(--micrio-font-size, inherit);background-color:var(--micrio-background-color, transparent)}micr-io h3{font-weight:600}micr-io[dir=rtl]{--micrio-text-align: right}canvas.micrio{display:block;position:absolute;top:0;left:0;width:100%!important;height:100%!important;backface-visibility:hidden;user-select:none;-webkit-touch-callout:none;-webkit-user-select:none}micr-io:not([static]){overscroll-behavior:none}micr-io[data-hooked]:not([data-panning])>canvas.micrio{cursor:move;cursor:-webkit-grab;cursor:-moz-grab;cursor:-ms-grab;cursor:grab;-ms-content-zooming:none;-ms-touch-action:none;touch-action:none}micr-io[data-panning]{cursor:-webkit-grabbing;cursor:-moz-grabbing;cursor:-ms-grabbing;cursor:grabbing}micr-io[data-hooked][data-can-pan]>canvas.micrio{-ms-touch-action:pan-y;touch-action:pan-y;overscroll-behavior:initial}micr-io>.micrio-grid{position:absolute;top:0;left:0;width:100%;height:100%;display:grid;grid-auto-flow:row dense;grid-gap:0;will-change:transform;transform-origin:left top;--translate: none;--scale: 1;transform:var(--translate) scale3d(var(--scale),var(--scale),1)}micr-io>.micrio-grid>button{background:transparent;border:none;padding:0;margin:0;cursor:pointer;grid-area:auto / auto / span 1 / span 1}a.micrio-logo{position:absolute;top:calc(var(--micrio-border-margin) * 2);left:calc(var(--micrio-border-margin) * 2);z-index:2;width:22px;height:22px;transition:transform .25s ease;display:block;cursor:pointer}a.micrio-logo:hover{transform:rotate3d(0,0,1,-90deg)}a.micrio-logo:before,a.micrio-logo:after{display:block;content:"";position:absolute;transform:rotate3d(0,0,1,45deg);will-change:transform;box-sizing:unset}a.micrio-logo:before{border:3px solid #00d4ee;width:16px;height:16px}a.loading.micrio-logo:before{animation:micrio-logo-spin 1s infinite ease-out}a.micrio-logo:after{top:8px;left:8px;width:6px;height:6px;background:#c5ff5b;outline:1px solid #c5ff5b}a.loading.micrio-logo:after{animation:micrio-logo-spin .5s infinite ease-out}@keyframes micrio-logo-spin{0%{transform:rotate3d(0,0,1,45deg)}to{transform:rotate3d(0,0,1,135deg)}}a.micrio-logo-org{position:absolute;top:calc(var(--micrio-border-margin) * 2);right:calc(var(--micrio-border-margin) * 2);z-index:1;display:block}img.micrio-logo-org{max-height:64px;display:block}.svelte-fa-base{height:1em;overflow:visible;transform-origin:center;vertical-align:-.125em}.svelte-fa-fw{text-align:center;width:1.25em}.svelte-fa-pull-left.micrio-fa{float:left}.svelte-fa-pull-right.micrio-fa{float:right}.svelte-fa-size-lg.micrio-fa{font-size:1.33333em;line-height:.75em;vertical-align:-.225em}.svelte-fa-size-sm.micrio-fa{font-size:.875em}.svelte-fa-size-xs.micrio-fa{font-size:.75em}.spin.micrio-fa{animation:micrio-fa-spin 2s 0s infinite linear}.pulse.micrio-fa{animation:micrio-fa-spin 1s infinite steps(8)}@keyframes micrio-fa-spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.svelte-fa-layers.micrio-fa--layers{display:inline-block;position:relative}.svelte-fa-layers.micrio-fa--layers .svelte-fa{position:absolute;bottom:0;left:0;right:0;top:0;margin:auto;text-align:center}.svelte-fa-layers.micrio-fa--layers .svelte-fa-layers-text{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%)}.svelte-fa-layers.micrio-fa--layers .svelte-fa-layers-text span{display:inline-block}.svelte-fa-pull-left.micrio-fa--layers{float:left}.svelte-fa-pull-right.micrio-fa--layers{float:right}.svelte-fa-size-lg.micrio-fa--layers{font-size:1.33333em;line-height:.75em;vertical-align:-.225em}.svelte-fa-size-sm.micrio-fa--layers{font-size:.875em}.svelte-fa-size-xs.micrio-fa--layers{font-size:.75em}.container.micrio-fa--layers--text{display:inline-block;height:auto}.svelte-fa-size-lg.micrio-fa--layers--text{font-size:1.33333em;line-height:.75em;vertical-align:-.225em}.svelte-fa-size-sm.micrio-fa--layers--text{font-size:.875em}.svelte-fa-size-xs.micrio-fa--layers--text{font-size:.75em}menu.micrio-menu{padding:0;margin:0;transition:background .2s ease,box-shadow .2s ease}.micrio-menu-action.micrio-menu{font-family:inherit;background:transparent;display:block;border:none;padding:0 24px;font-size:.9em;cursor:pointer;text-decoration:none;border-radius:0;color:inherit;text-shadow:inherit;box-sizing:border-box;text-align:center}@media (max-width: 500px){menu.micrio-menu{font-size:1em}.micrio-menu-action.micrio-menu{width:100%;margin-bottom:10px;padding:6px 0}strong.micrio-menu>svg{display:none}.items>menu.micrio-menu>.micrio-menu-action:where(.micrio-menu){font-size:1em}menu.micrio-toolbar>menu.micrio-menu>.micrio-menu-action:where(.micrio-menu){font-size:1.5em;border-bottom:1px solid rgba(255,255,255,.5);margin-top:24px}}@media (min-width: 501px){div.items.micrio-menu{max-height:calc(100vh - 160px);overflow-y:auto;overflow-x:hidden}menu.micrio-toolbar>menu.micrio-menu{color:#fff;margin-right:var(--micrio-border-margin);border-radius:var(--micrio-border-radius);overflow:hidden}menu.micrio-toolbar>menu.micrio-menu:hover,menu.micrio-toolbar>menu.micrio-menu:focus-within{-webkit-backdrop-filter:var(--micrio-background-filter);backdrop-filter:var(--micrio-background-filter);background:var(--micrio-background);box-shadow:var(--micrio-button-shadow)}menu.micrio-toolbar>menu.micrio-menu>.micrio-menu-action:where(.micrio-menu){position:relative}menu.micrio-toolbar>menu.micrio-menu>.micrio-menu-action:where(.micrio-menu)>strong:where(.micrio-menu){padding:5px;margin:0 -5px}menu.micrio-toolbar>menu.micrio-menu:hover .micrio-menu-action:where(.micrio-menu),menu.micrio-toolbar>menu.micrio-menu:focus-within .micrio-menu-action:where(.micrio-menu){text-shadow:none;color:var(--micrio-color)}strong.micrio-menu>svg{margin-left:10px;line-height:2px}menu.micrio-menu{float:left;position:relative}menu.micrio-menu:not(:focus-within):not(:hover) .items:where(.micrio-menu){display:none}.micrio-menu-action.micrio-menu{height:var(--micrio-button-size);line-height:var(--micrio-button-size);width:100%;text-align:var(--micrio-text-align);white-space:pre;font-weight:600}.items menu.micrio-menu{float:none}.items .micrio-menu-action.micrio-menu{width:100%}.micrio-menu-action.micrio-menu:hover,.micrio-menu-action.micrio-menu:focus{text-shadow:none!important;color:var(--micrio-color-hover)!important}}.micrio-button{margin:0;padding:0 8px;cursor:pointer;box-sizing:border-box;display:inline-block;vertical-align:bottom;transition:opacity .25s ease;font:inherit;font-size:90%;position:relative;touch-action:none;color:var(--micrio-color);background:var(--micrio-button-background, var(--micrio-background, none)) var(--background, none) center center no-repeat;background-size:24px;min-width:var(--micrio-button-size);height:var(--micrio-button-size);line-height:var(--micrio-button-size);border:none;border-radius:var(--micrio-border-radius);box-shadow:var(--micrio-button-shadow);-webkit-backdrop-filter:var(--micrio-background-filter);backdrop-filter:var(--micrio-background-filter);text-decoration:none}.micrio-button:hover{outline:none}.micrio-button.transparent.micrio-button,.micrio-button.transparent.micrio-button:hover{background-color:transparent;-webkit-backdrop-filter:none;backdrop-filter:none}.micrio-button>*{transition:opacity .25s ease}.micrio-button:disabled{pointer-events:none;cursor:default}.micrio-button:disabled>*{opacity:.4}.micrio-button.no-click.micrio-button{pointer-events:none}img.micrio-button{display:block;margin:0 auto;pointer-events:none;max-width:100%;max-height:100%}.micrio-button>*{height:var(--micrio-icon-size)!important;width:var(--micrio-icon-size);font-size:var(--micrio-icon-size);fill:var(--micrio-color);display:block;margin:0 auto}.micrio-button.active.micrio-button{color:var(--micrio-color-hover)}.micrio-button.active.micrio-button svg{fill:var(--micrio-color-hover)}@media (hover: hover){.micrio-button:hover{background-color:var(--micrio-button-background-hover, var(--micrio-button-background, var(--micrio-background)));color:var(--micrio-color-hover)}.micrio-button:hover svg{fill:var(--micrio-color-hover);stroke:var(--micrio-color-hover)}.micrio-button:focus{outline:1px solid var(--micrio-color-hover)}}menu.micrio-toolbar{position:absolute;top:calc(var(--micrio-border-margin) - (var(--micrio-button-size) / 2 - 27px));left:var(--micrio-border-margin);margin:0;padding:0;color:#fff;text-shadow:1px 1px 2px #000;transition:transform .25s ease;z-index:1}@media (max-width: 500px){.micrio-button.toggle{position:absolute;top:var(--micrio-border-margin);left:0;height:34px;width:34px;box-shadow:none;z-index:2}.micrio-button.toggle.indent{left:35px}menu.micrio-toolbar{transform:translateZ(0);width:100%;height:100%;background:#000000bf;top:0;left:0;padding:32px 0;overflow-y:auto;overflow-x:hidden;box-sizing:border-box;-webkit-backdrop-filter:var(--micrio-background-filter);backdrop-filter:var(--micrio-background-filter);z-index:1}menu.micrio-toolbar:not(.shown){transform:translate3d(calc(-100% - var(--micrio-border-margin) * 2),0,0)}}@media (min-width: 501px){menu.indent.micrio-toolbar{margin-left:calc(var(--micrio-border-margin) * 2 + 25px)}menu.micrio-toolbar>.micrio-menu:not(:hover)>button.micrio-menu{margin-bottom:-15px}}canvas.micrio-minimap{position:absolute;bottom:var(--micrio-border-margin);right:5px;transform-origin:right bottom;display:block;background-size:100%;transition:opacity .2s ease;cursor:move;cursor:-webkit-grab;cursor:-moz-grab;cursor:-ms-grab;cursor:grab;-ms-content-zooming:none;-ms-touch-action:none;touch-action:none;border-radius:var(--micrio-border-radius)}canvas:not(:hover).hidden.micrio-minimap{opacity:0;pointer-events:none}canvas.dragging.micrio-minimap{cursor:-webkit-grabbing;cursor:-moz-grabbing;cursor:-ms-grabbing;cursor:grabbing}canvas.controls.micrio-minimap{right:calc(var(--micrio-border-margin) + var(--micrio-button-size) + 8px)}@media (max-width: 800px){canvas.micrio-minimap{transform:scale3d(.5,.5,1);pointer-events:none;right:65px}}div.micrio-button-group{box-shadow:var(--micrio-button-shadow);border-radius:var(--micrio-border-radius);-webkit-backdrop-filter:var(--micrio-background-filter);backdrop-filter:var(--micrio-background-filter);background:var(--micrio-button-background, var(--micrio-background, none))}div.micrio-button-group:empty{display:none}div.micrio-button-group>.micrio-button{display:block;box-shadow:none;--micrio-background-filter: none;--micrio-button-background: none}div.micrio-button-group .micrio-button{border-radius:0}div.micrio-button-group .micrio-button:first-child{border-radius:var(--micrio-border-radius) var(--micrio-border-radius) 0 0}div.micrio-button-group .micrio-button:last-child{border-radius:0 0 var(--micrio-border-radius) var(--micrio-border-radius)}@media (max-width: 500px){div.micrio-button-group>*{height:calc(var(--micrio-button-size) - 4px)}div.micrio-button-group .micrio-button:first-child{padding-top:0}div.micrio-button-group .micrio-button:last-child{padding-bottom:0}}aside.micrio-controls{position:absolute;right:var(--micrio-border-margin);bottom:var(--micrio-border-margin);padding:0;margin:0;transition:transform .5s ease,opacity .5s ease;direction:rtl}aside.primary.micrio-controls:not(.portrait){right:calc(50% + var(--micrio-border-margin))}aside.primary.portrait.micrio-controls{bottom:calc(50% + var(--micrio-border-margin))}micr-io[data-switching]>aside.micrio-controls,micr-io[data-tour-active]>aside.micrio-controls{opacity:0;pointer-events:none}aside.micrio-controls>menu,aside.micrio-controls>button{padding:0;margin:8px 0;display:block;width:var(--micrio-button-size)}menu.popout.micrio-controls{padding:0;width:var(--micrio-button-size);height:var(--micrio-button-size);white-space:pre;direction:rtl;pointer-events:none;box-shadow:var(--micrio-button-shadow);border-radius:var(--micrio-border-radius);-webkit-backdrop-filter:var(--micrio-background-filter);backdrop-filter:var(--micrio-background-filter)}menu.popout.micrio-controls:focus-within{pointer-events:all}menu.popout.micrio-controls button{pointer-events:all;transition:border-radius .2s ease,opacity .2s ease;--micrio-button-shadow: none;--micrio-background-filter: none}menu.popout.micrio-controls:hover>button:first-child{border-radius:0 var(--micrio-border-radius) var(--micrio-border-radius) 0}menu.popout.micrio-controls>*:not(:nth-child(1)){display:inline-block;padding:0;transition:opacity .2s ease;border-radius:0}menu.popout.micrio-controls>button:last-child{border-radius:var(--micrio-border-radius) 0 0 var(--micrio-border-radius)}menu.popout.micrio-controls:not(:focus-within)>*:not(:nth-child(1)){pointer-events:none;opacity:0}div.micrio-subtitles{position:absolute;bottom:50px;left:50vw;left:50cqw;transform:translate3d(-50%,0,0);text-align:center;color:#fff;width:100vw;width:100cqw;pointer-events:none;transition:transform .2s ease}div.raised.micrio-subtitles{transform:translate3d(-50%,calc(-1 * var(--micrio-button-size)),0)}div.micrio-subtitles p:where(.micrio-subtitles){margin:.5em 0;background-color:#0009;padding:0 14px;-webkit-box-decoration-break:clone;box-decoration-break:clone;white-space:pre-wrap;display:inline;text-shadow:2px 2px 1px #0005;font-size:2.5em;line-height:inherit}@media (max-width: 640px){div.micrio-subtitles{width:95vw;width:95cqw;font-size:.7em}}div.container.micrio-progress-bar{display:flex;width:auto;color:var(--micrio-color);background:var(--micrio-background);line-height:8px;flex:1;align-items:center;cursor:default}div.bars.micrio-progress-bar{flex:1;display:flex;height:var(--micrio-progress-bar-height);background:var(--micrio-progress-bar-background);position:relative}div.bars.micrio-progress-bar>*{height:100%;width:100%;display:block;box-sizing:border-box;position:relative;cursor:pointer;overflow:hidden}div.bars.micrio-progress-bar>*:before{display:block;position:absolute;content:" ";background:var(--micrio-color);height:100%;pointer-events:none;width:var(--progress, 0%);will-change:width}div.bars.micrio-progress-bar:after{content:"";position:absolute;display:block;width:16px;height:16px;left:var(--progress);top:50%;transform:translate3d(-50%,-50%,0);background-color:var(--micrio-color);pointer-events:none;border-radius:8px}div.time.micrio-progress-bar{display:block;font-size:90%;min-width:50px;text-align:center;padding:0 10px;font-variant-numeric:tabular-nums}aside.micrio-media-controls{cursor:default;position:relative;display:flex;align-items:center;margin:0;background:var(--micrio-background)}aside.micrio-media-controls>button{border-radius:0;margin:0;border:none}aside.micrio-media-controls>button:last-child{margin-right:16px}aside.micrio-media-controls>*{--micrio-button-background: none;--micrio-background-filter: none;--micrio-button-shadow: none}:fullscreen>aside.micrio-media-controls{position:absolute;bottom:5px;left:50%;transform:translate(-50%);width:430px;max-width:90vw;max-width:90cqw;border-radius:var(--micrio-border-radius)}svg.micrio-media-controls{pointer-events:none;position:absolute;left:-1px;top:-1px;width:42px;height:42px;transform:rotate(-90deg)}circle.micrio-media-controls{stroke-width:2;stroke:#fff;fill:transparent;stroke-dasharray:119.4 119.4;transition:stroke-dashoffset .25s linear;transform-origin:center center}figure.micrio-media{display:block;margin:0;width:100%;position:relative;overflow:hidden}figure.micrio-media div:where(.micrio-media){cursor:pointer}figure.micrio-media div.videotour:where(.micrio-media){display:flex}figure.micrio-media:fullscreen div:where(.micrio-media){width:100vw;height:100vh;display:flex;flex-direction:column}figure.micrio-media:fullscreen div:where(.micrio-media)>:first-child{flex:1}.marker-popup>figure.micrio-media>div:where(.micrio-media){width:100%}iframe.micrio-media,video.micrio-media{display:block;max-width:unset}figure.is360.micrio-media{position:absolute;bottom:5px;width:360px;left:50%;transform:translate(-50%)}figure.is360.micrio-media video:where(.micrio-media){display:none;width:200px;height:200px}iframe.hooked.micrio-media{pointer-events:none}figcaption.micrio-media{font-style:italic;margin:.5em 1em;text-align:center;font-size:90%;color:var(--micrio-color)}:not(.micrio-popover)>figure.micrio-media>figcaption:where(.micrio-media)>*{margin:0}.micrio-popover figure.micrio-media{margin:0}aside.micrio-media{width:100%;display:flex}aside.inside.micrio-media{position:absolute;transform:translateY(-100%)}div.show-play.micrio-media{position:fixed;top:0;left:0;width:100%;height:100%;cursor:pointer;background:#0008;display:flex;align-items:center;justify-content:center}div.show-play.micrio-media>button.micrio-button{transform:scale(2)}figure.micrio-media:not(.media-micrio) button.micrio-button{margin:0;border:none;border-radius:0;white-space:pre;--micrio-background-filter: none;--micrio-button-shadow: none}figure.media-micrio.micrio-media{text-align:var(--micrio-text-align)}article.micrio-article{text-align:var(--micrio-text-align);line-height:var(--micrio-line-height, 1.5em)}article.micrio-article>*:first-child{margin-top:0}article.micrio-article>*:last-child{margin-bottom:0}article.micrio-article p a{color:var(--micrio-color-hover, inherit);word-wrap:break-word}main.micrio-marker-content{position:relative;padding:var(--micrio-popup-padding);padding-bottom:0;overflow-y:auto;-webkit-user-select:text;user-select:text;color:var(--micrio-color);background:var(--micrio-background);-webkit-backdrop-filter:var(--micrio-background-filter);backdrop-filter:var(--micrio-background-filter);box-shadow:var(--micrio-popup-shadow);border-radius:var(--micrio-border-radius);box-sizing:border-box;text-align:var(--micrio-text-align)}main.micrio-marker-content>*{--micrio-button-background: none;--micrio-background-filter: none;--micrio-button-shadow: none}main.micrio-marker-content .micrio-progress-bar.container{background:transparent;-webkit-backdrop-filter:none;backdrop-filter:none}main.micrio-marker-content::-webkit-scrollbar{background-color:transparent;width:10px}main.micrio-marker-content::-webkit-scrollbar-thumb{background:var(--micrio-color);border-radius:var(--micrio-border-radius);margin-top:10px}main.empty.micrio-marker-content{width:auto}main.micrio-marker-content h1:where(.micrio-marker-content){font-size:1.5em;font-weight:600;margin:0 0 1.25em}main.micrio-marker-content>figure.micrio-media{margin:calc(-1 * var(--micrio-popup-padding));margin-bottom:0;width:auto;--micrio-background: transparent}main.micrio-marker-content>figure.micrio-media:not(.media-video):not(:last-child)>*:last-child:not(figcaption){margin-bottom:var(--micrio-popup-padding);background:var(--micrio-background);padding:0 var(--micrio-popup-padding)}main.micrio-marker-content>figure.micrio-media.media-video{margin-bottom:var(--micrio-popup-padding)}main.micrio-marker-content>figure.micrio-media>div>aside.micrio-media{--micrio-background: transparent}main.micrio-marker-content>article:last-child{margin-bottom:var(--micrio-popup-padding)}main.micrio-marker-content p{white-space:pre-line}main.micrio-marker-content figure.hidden{display:none}main.micrio-marker-content figure>div.micrio-media>*:first-child{width:100%}button.micrio-marker-content{padding:0;margin:0 calc(-1 * var(--micrio-popup-padding)) var(--micrio-popup-padding) calc(-1 * var(--micrio-popup-padding))}button.micrio-marker-content:disabled{cursor:default}figcaption.micrio-marker-content{padding:10px;font-style:italic;font-size:.9em;margin-bottom:var(--micrio-popup-padding);text-align:center}section.micrio-marker-content{display:grid;grid-template-columns:repeat(auto-fit,minmax(100px,1fr));column-gap:5px;row-gap:5px;justify-items:center;margin-bottom:var(--micrio-popup-padding)}section.micrio-marker-content button:where(.micrio-marker-content){color:inherit;border:none;display:block;width:100%;cursor:pointer;margin:0}section.micrio-marker-content figure:where(.micrio-marker-content){padding:0;margin:0}section.micrio-marker-content img:where(.micrio-marker-content){width:100%;display:block;object-fit:cover}div.micrio-marker-popup{display:block;cursor:auto;pointer-events:all;position:absolute;top:var(--micrio-border-margin);left:var(--micrio-border-margin)}div.destroying.micrio-marker-popup{pointer-events:none}div.micrio-marker-popup>main{max-height:80vh;max-height:80cqh}aside.micrio-marker-popup{padding:var(--micrio-border-margin)}aside.micrio-marker-popup progress:where(.micrio-marker-popup){display:none}@media (min-width: 501px){div.micrio-marker-popup{width:440px;min-width:20%}aside.micrio-marker-popup{position:absolute;left:100%;top:0;padding-top:0}aside.micrio-marker-popup>.micrio-button{padding:0;margin:0 0 8px;display:block}}@media (max-width: 500px){aside.micrio-marker-popup{position:relative;padding:0;display:flex;flex-direction:row-reverse;margin-bottom:var(--micrio-border-margin);align-items:center}aside.micrio-marker-popup progress:where(.micrio-marker-popup){display:block;flex:1;opacity:0;pointer-events:none}aside.micrio-marker-popup .micrio-tour-controls{margin-bottom:0!important;display:flex}aside.micrio-marker-popup .micrio-button{display:block!important;height:var(--micrio-button-size);padding:0!important;margin:0 0 0 8px}div.micrio-marker-popup{top:var(--micrio-border-margin);right:var(--micrio-border-margin);left:var(--micrio-border-margin);width:auto}div.micrio-marker-popup>main{max-height:calc(100vh - var(--micrio-button-size) - 3 * var(--micrio-border-margin));max-height:calc(100cqh - var(--micrio-button-size) - 3 * var(--micrio-border-margin));box-sizing:border-box}}div.micrio-marker-popup>main>*:not(h3){transition-property:margin-top,margin-bottom,height,opacity;transition-duration:.5s;transition-timing-function:ease;overflow:hidden}div.minimized.micrio-marker-popup>main>*:not(h3){margin-top:0;margin-bottom:0;opacity:0}button.tour-step.micrio-marker-popup{height:auto;line-height:normal;vertical-align:middle;cursor:default}ol.micrio-serial-tour{position:absolute;left:0;bottom:75px;color:var(--micrio-color);text-shadow:var(--micrio-marker-text-shadow);list-style-type:decimal-leading-zero;margin:0}ol.micrio-serial-tour>li:where(.micrio-serial-tour){height:1.5em;white-space:pre;transition:height .25s ease,opacity .25s .25s ease}ol.micrio-serial-tour li.active:where(.micrio-serial-tour){font-weight:700}.minimized>ol.micrio-serial-tour>li:where(.micrio-serial-tour):not(.active){height:0em;opacity:0;transition:height .25s .25s ease,opacity .25s ease}ol.micrio-serial-tour li:where(.micrio-serial-tour) button:where(.micrio-serial-tour){font:inherit;background:none;border:none;display:inline;color:inherit;text-shadow:inherit;cursor:pointer}ol.micrio-serial-tour li:where(.micrio-serial-tour) button:where(.micrio-serial-tour):hover{text-decoration:underline}aside.micrio-media-controls.micrio-serial-tour>figure.micrio-media{display:none}div.micrio-tour{position:absolute;bottom:var(--micrio-border-margin);left:50%;max-width:calc(100% - var(--micrio-border-margin) * 2);transform:translate(-50%);box-sizing:border-box;display:flex;border-radius:var(--micrio-border-radius);box-shadow:var(--micrio-button-shadow);-webkit-backdrop-filter:var(--micrio-background-filter);backdrop-filter:var(--micrio-background-filter);background-color:var(--micrio-button-background, var(--micrio-background, none));padding:0;transition:transform .2s ease}div:not(:hover).minimized.micrio-tour{transform:translate3d(-50%,calc(100% + var(--micrio-border-margin)),0);pointer-events:none}.serial-tour.micrio-tour>*{--micrio-background: none}.serial-tour.minimized.micrio-tour{transform:translate3d(0,calc(100% + var(--micrio-border-margin)),0)}.serial-tour.micrio-tour,.video-tour.micrio-tour{width:500px}div.micrio-tour>*{--micrio-button-background: none}div.micrio-tour button{margin:0;border:none;border-radius:0;white-space:pre;--micrio-background-filter: none;--micrio-button-shadow: none}article.scroll-tour.micrio-tour{position:absolute;top:0;left:0;width:100%;height:100%;overflow-x:hidden;overflow-y:scroll;scroll-snap-type:y mandatory}button.micrio-button.scroll-tour-end{position:absolute;top:5px;right:5px}article.micrio-tour>div.micrio-marker-popup{margin:20vh 50px 50vh;margin:20cqh 50px 50cqh;scroll-snap-align:center;position:relative!important}article.micrio-tour>div.micrio-marker-popup:nth-child(2n){margin-left:auto}article.micrio-tour>div.micrio-marker-popup>aside{display:none}div.micrio-dial{position:absolute;bottom:var(--micrio-border-margin);width:320px;max-width:calc(100vw - calc(2 * (var(--micrio-button-size) + 4 * var(--micrio-border-margin))));max-width:calc(100cqw - calc(2 * (var(--micrio-button-size) + 4 * var(--micrio-border-margin))));left:50%;transform:translate(-50%);height:calc(var(--micrio-button-size) * .6);touch-action:none;background-color:transparent;cursor:w-resize;overflow:hidden}div.micrio-dial:before,div.micrio-dial:after{content:"";display:block;width:100%;position:absolute;background-position:var(--micrio-dial-offset, 0px)}div.micrio-dial:before{height:50%;top:25%;background-image:repeating-linear-gradient(to right,#8888 0%,#8888 .5%,transparent 1%,transparent 2.5%)}div.micrio-dial:after{height:100%;background-image:repeating-linear-gradient(to right,#fff8 0%,#fff8 .5%,transparent 1%,transparent 20%)}span.micrio-dial{position:absolute;display:block;bottom:0;line-height:calc(var(--micrio-button-size) * .6);left:50%;transform:translate(calc(-50% + 5px));color:var(--micrio-color);opacity:.85;pointer-events:none;text-shadow:1px 1px 3px #000,-1px -1px 3px #000;font-size:smaller}ul.micrio-gallery{position:absolute;bottom:var(--micrio-border-margin);left:50%;transform:translate(-50%);display:flex;list-style-type:none;background:var(--micrio-background);border-radius:var(--micrio-border-radius);padding:0 16px;margin:0;color:var(--micrio-color);transition:opacity .25s ease;max-width:calc(100vw - 50px);max-width:calc(100cqw - 50px);width:520px;touch-action:none}@media (max-width: 500px){ul.micrio-gallery{left:5px;right:52px;width:auto;transform:none}div.hidden.micrio-gallery>ul:where(.micrio-gallery){transition-delay:.25s}}li.micrio-gallery{flex:1;transition:none;padding:0;line-height:var(--micrio-button-size);font-size:32px;text-align:center;width:0;transition:opacity .25s ease;opacity:.25;display:block;height:48px;position:relative}li.active.micrio-gallery{transition-duration:0s;opacity:1}li.micrio-gallery>button:where(.micrio-gallery){border:none;color:inherit;cursor:pointer;position:absolute;left:50%;transform:translate3d(-50%,0,0);height:48px;width:100%;min-width:48px;pointer-events:none;background:none;padding:0}li.hover.micrio-gallery>button:where(.micrio-gallery){pointer-events:all}@media (hover: hover){li.hover.micrio-gallery{transition-duration:0s;opacity:1}}button.micrio-gallery:not(.bullet){position:absolute;width:var(--micrio-button-size);height:var(--micrio-button-size);box-sizing:border-box;background:#eee3;border:none;border-radius:var(--micrio-border-radius);touch-action:none;transition:left .15s ease,background-color .2s ease;transform:translate(-50%)}ul.micrio-gallery>button:where(.micrio-gallery){top:0;left:0;cursor:ew-resize}button.angular.micrio-gallery{bottom:42px;left:50%;color:#444;font-size:32px;line-height:42px;padding:0;cursor:move}button.micrio-gallery:not(.bullet):hover{background:#eee8}button:not(.bullet).dragging.micrio-gallery{transition:none}div.micrio-gallery{display:contents;transition:opacity .5s ease}div.hidden.micrio-gallery:not(:hover)>*,div.micrio-gallery>button.gallery-btn:disabled{opacity:0;pointer-events:none}div.micrio-gallery>button.gallery-btn{position:absolute;top:50%;transform:translateY(-50%)}div.micrio-gallery>button.gallery-btn.arrow-left{left:var(--micrio-border-margin)}div.micrio-gallery>button.gallery-btn.arrow-right{right:var(--micrio-border-margin)}details.micrio-details{position:absolute;bottom:var(--micrio-border-margin);left:var(--micrio-border-margin);padding:var(--micrio-popup-padding);font-size:.9em;max-width:410px;-webkit-user-select:text;user-select:text;white-space:normal;transition:all .5s ease;box-sizing:border-box;color:var(--micrio-color);background:var(--micrio-background);-webkit-backdrop-filter:var(--micrio-background-filter);backdrop-filter:var(--micrio-background-filter);box-shadow:var(--micrio-popup-shadow);border-radius:var(--micrio-border-radius)}details.micrio-details summary:where(.micrio-details){cursor:pointer;list-style:none}details.micrio-details summary:where(.micrio-details)::-webkit-details-marker{display:none}details.micrio-details small:where(.micrio-details){display:block;font-style:italic;font-weight:400}details.micrio-details>:where(.micrio-details){margin:0;overflow:hidden;text-overflow:ellipsis}details.micrio-details a{color:var(--micrio-color-hover, inherit)}details.micrio-details button{position:absolute;top:0;left:calc(100% + 8px)}@media (max-width: 600px){details.micrio-details{max-width:calc(100% - 10px)}details.micrio-details:not([open]) cite:where(.micrio-details){display:none}details.micrio-details:not([open]) summary:where(.micrio-details)::marker,details.micrio-details:not([open]) summary:where(.micrio-details)::-webkit-details-marker{display:inline-block;content:"?";font-size:20px;font-weight:700;line-height:20px;margin-right:5px}details.micrio-details button{position:absolute;top:auto;left:auto;right:0;bottom:calc(100% + 8px)}}div.micrio-error{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);background:#000000bf;color:#fff;border:1px solid white;border-radius:5px;padding:10px;text-align:center;white-space:pre-wrap;-webkit-user-select:text;user-select:text;line-height:24px;z-index:10}div.micrio-error svg{vertical-align:middle;height:24px;width:24px;fill:var(--micrio-color);margin-right:10px}@media screen and (max-width: 520px){div.micrio-error{box-sizing:border-box;width:90%}}micr-io.micrio-micrio-gallery{background:#1118;display:block;width:100%;height:100%}micr-io.micrio-micrio-gallery ul.micrio-gallery{--micrio-border-margin: 16px}@media (min-width: 501px){micr-io.micrio-micrio-gallery:not(:fullscreen)>aside{position:fixed}}dialog.micrio-popover::backdrop{color:#fff;animation:micrio-popover-fadeInBg .2s forwards;-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px)}@keyframes micrio-popover-fadeInBg{0%{background:#0000}to{background:var(--micrio-popover-background)}}@keyframes micrio-popover-fadeIn{0%{opacity:0}to{opacity:1}}dialog.micrio-popover{animation:micrio-popover-fadeIn .5s forwards;background:transparent;border:none;overflow:visible;padding:0;pointer-events:all;max-width:90vw;max-height:90vh;max-width:90cqw;max-height:90cqh}dialog.micrio-popover div.micrio-media>*:first-child{border-radius:var(--micrio-border-radius);overflow:hidden}dialog.micrio-popover div.micrio-media>aside{--micrio-background: none;--micrio-button-background: none}dialog.page.article.micrio-popover figure.media-video iframe{width:100%}aside.micrio-popover{--micrio-background-filter: none;position:absolute;z-index:1}dialog.micrio-popover:not(.article){display:flex}dialog.micrio-popover:not(.article) figure>div.micrio-media{height:100%}@media (min-width: 640px){aside.micrio-popover{display:block;left:100%;margin-left:var(--micrio-border-margin);top:0}aside.inside.micrio-popover{right:0;left:auto;top:0;margin-left:0;margin-right:var(--micrio-border-margin)}aside.micrio-popover:not(.inside){z-index:2;position:absolute;top:0;left:100%}aside.micrio-popover>.micrio-button{padding:0;margin:0 0 8px;display:block}dialog.micrio-popover:not(.article){width:calc(85vw - 56px);height:47.8125vw;width:calc(85cqw - 56px);height:47.8125cqw}dialog.micrio-popover>main{width:25vw;width:25cqw;min-width:unset;max-width:320px}dialog.micrio-popover>main>h1{margin-right:55px}}@media (max-width: 639px){aside.micrio-popover{position:fixed;top:var(--micrio-border-margin);right:var(--micrio-border-margin)}aside.micrio-popover .micrio-button{display:inline-block!important;border-radius:var(--micrio-border-radius)!important;height:var(--micrio-button-size);box-shadow:var(--micrio-button-shadow);padding:0!important;margin-left:8px}dialog.micrio-popover:not(.article){width:100%;height:100%;flex-direction:column}dialog.micrio-popover:not(.article) figure.micrio-media{flex:1}}dialog.micrio-popover>figure{flex:1;position:relative;margin:0}dialog.micrio-popover>figure>figcaption{position:absolute;width:100%;bottom:100%;font-style:italic;text-align:center;font-size:90%;padding:0;margin:var(--micrio-border-margin);color:var(--micrio-color)}dialog.micrio-popover>figure>div.micrio-media>*:first-child{width:100%;height:calc(100% - var(--micrio-button-size))}dialog.micrio-popover>figure>div.micrio-media>micr-io{height:100%!important}@media (min-aspect-ratio: 16/9){dialog.micrio-popover:not(.article){height:75vh;width:calc(16 / 9 * 75vh);height:75cqh;width:calc(16 / 9 * 75cqh)}}@media (max-width: 639px){dialog.micrio-popover div.micrio-media>*:first-child{border-radius:0}dialog.micrio-popover:not(.article)>*:first-child{height:50vh;height:50cqh;flex-direction:column;justify-content:center}dialog.micrio-popover:not(.article)>figure:first-child{flex:none;display:flex;flex-direction:column}}dialog.article.micrio-popover>article{text-shadow:none;color:var(--micrio-color);background:var(--micrio-background);padding:20px;box-sizing:border-box;max-height:calc(90cqh - 48px);max-height:calc(90vh - 48px);overflow-x:hidden;overflow-y:auto;border-radius:var(--micrio-border-radius)}@media (min-width: 640px){dialog.article.micrio-popover{width:540px}}dialog.article.micrio-popover h2:where(.micrio-popover){text-align:center}dialog.article.micrio-popover article img{width:100%;height:auto}menu.micrio-popover{margin:10px 0;padding:0;list-style:none}menu.micrio-popover>.micrio-button{margin-right:10px}menu.right.micrio-popover{text-align:right}menu.right.micrio-popover>.micrio-button{margin:0 0 0 10px}div.micrio-marker{position:absolute;display:block;transform:translate3d(calc(var(--x, 0) - 50%),calc(var(--y, 0) - 50%),0) scale3d(var(--scale, 1),var(--scale, 1),1);top:0;left:0;will-change:transform}div.micrio-marker:not(.cluster):not(.no-fade){animation:micrio-marker-fadeIn .25s;animation-fill-mode:forwards}div.overlapped.micrio-marker{display:none}@keyframes micrio-marker-fadeIn{0%{opacity:0}to{opacity:1}}div.behind.micrio-marker{pointer-events:none;visibility:hidden}div.mat3d.micrio-marker{transform:var(--mat);top:50%;left:50%;transform-style:preserve-3d}div.mat3d.micrio-marker>button:where(.micrio-marker){position:absolute;transform:translate3d(-50%,-50%,0)}button.micrio-marker{display:block;width:var(--micrio-marker-size);height:var(--micrio-marker-size);color:var(--micrio-marker-text-color);position:relative;cursor:pointer;font:inherit;padding:0;margin:0;background:transparent none center center no-repeat;background-image:var(--micrio-marker-icon);background-size:contain;border:none}div.micrio-marker:not(.cluster) label:where(.micrio-marker){position:absolute;top:50%;left:100%;text-align:var(--micrio-text-align);cursor:pointer;transform:translateY(-50%);padding-left:10px;max-width:170px;width:max-content;white-space:pre-wrap;font-size:90%;font-weight:600;line-height:1em;text-shadow:var(--micrio-marker-text-shadow);opacity:0;pointer-events:none;transition:opacity .1s ease}div.micrio-marker:hover{z-index:2}.show-titles>div.micrio-marker label:where(.micrio-marker),div.micrio-marker:hover label:where(.micrio-marker){opacity:1}@media (max-width: 640px){div.micrio-marker:not(.cluster) label:where(.micrio-marker){font-size:12px}}.show-titles>div.micrio-marker label:where(.micrio-marker){pointer-events:all}label.static.micrio-marker{transform:translate(-50%,4px) scale3d(calc(1 / var(--scale, 1)),calc(1 / var(--scale, 1)),1)}div.default.micrio-marker button:where(.micrio-marker){box-sizing:content-box;background-clip:content-box;border-radius:var(--micrio-marker-border-radius);border:var(--micrio-marker-border-size) solid var(--micrio-marker-border-color);transition:var(--micrio-marker-transition);background-color:var(--micrio-marker-color)}div.default.micrio-marker:hover,div.default.hovered.micrio-marker,div.default.opened.micrio-marker{z-index:1}div.default.micrio-marker:hover button:where(.micrio-marker),div.default.hovered.micrio-marker button:where(.micrio-marker),div.default.opened.micrio-marker button:where(.micrio-marker){background-color:var(--micrio-marker-highlight);border-width:0;width:calc(var(--micrio-marker-size) + var(--micrio-marker-border-size) * 2);height:calc(var(--micrio-marker-size) + var(--micrio-marker-border-size) * 2)}div.has-icon.micrio-marker button:where(.micrio-marker){--micrio-marker-icon: none}div.default.has-icon.micrio-marker button:where(.micrio-marker){color:#fff;width:calc(var(--micrio-marker-size) + 24px);height:calc(var(--micrio-marker-size) + 24px);background-color:var(--micrio-marker-border-color);border:none}div.default.has-icon.micrio-marker button:where(.micrio-marker)>svg{margin:0 auto}div.default.has-icon.opened.micrio-marker button:where(.micrio-marker)>svg,div.default.has-icon.hovered.micrio-marker button:where(.micrio-marker)>svg,div.default.has-icon.micrio-marker:hover button:where(.micrio-marker)>svg{color:var(--micrio-marker-highlight)}div.default.has-custom-icon.micrio-marker button:where(.micrio-marker){background-color:var(--micrio-marker-color)}div.default.has-custom-icon.opened.micrio-marker button:where(.micrio-marker),div.default.has-custom-icon.hovered.micrio-marker button:where(.micrio-marker),div.default.has-custom-icon.micrio-marker:hover button:where(.micrio-marker){background-color:var(--micrio-marker-highlight, var(--micrio-marker-color))}div.cluster.micrio-marker button:where(.micrio-marker){border:2px solid var(--micrio-marker-color);background:var(--micrio-cluster-marker-background, #fff);color:var(--micrio-cluster-marker-color, #000);width:calc(var(--micrio-marker-size) + 12px);height:calc(var(--micrio-marker-size) + 12px);border-radius:100%;box-sizing:content-box}div.cluster.micrio-marker:hover button:where(.micrio-marker){background:var(--micrio-marker-highlight, #fff);border-color:var(--micrio-marker-highlight, #fff)}div.cluster.micrio-marker label:where(.micrio-marker){pointer-events:none;display:none}div.micrio-marker img:where(.micrio-marker){max-width:100%;max-height:100%;display:block;margin:auto}div.micrio-waypoint{display:block;position:absolute;transform-style:preserve-3d;transform:var(--matrix);width:0;height:0;top:50%;left:50%;--micrio-bb: var(--micrio-button-background);--micrio-bbh: var(--micrio-button-background-hover)}div.micrio-waypoint>button{--micrio-button-background: var(--micrio-waypoint-background, var(--micrio-bb));--micrio-button-background-hover: var(--micrio-waypoint-background-hover, var(--micrio-bbh));--micrio-button-size: var(--micrio-waypoint-size);--micrio-border-radius: var(--micrio-waypoint-border-radius, 100%);--micrio-icon-size: var(--micrio-waypoint-icon-size, calc(var(--micrio-button-size) - 50px));transform:translate3d(-50%,-50%,0) scale3d(.5,.5,1);pointer-events:all;transition:background-color .25s ease,opacity .25s ease,border-color .25s ease,transform .25s ease;border:var(--micrio-waypoint-border-size, var(--micrio-marker-border-size)) solid var(--micrio-waypoint-border-color, var(--micrio-marker-border-color));margin:0}div.micrio-waypoint>button>svg{pointer-events:none;margin:0 auto}div.micrio-waypoint:hover>button,div.active.micrio-waypoint>button{transition:background-color .25s ease,opacity .25s ease,transform .25s ease;transform:translate3d(-50%,-50%,0) scale3d(.6,.6,1)}div.clicked.micrio-waypoint>button{animation:micrio-waypoint-pulse .75s ease infinite alternate}@keyframes micrio-waypoint-pulse{0%{transform:translate3d(-50%,-50%,0) scale3d(.5,.5,1)}to{transform:translate3d(-50%,-50%,0) scale3d(.75,.75,1)}}div.micrio-markers{pointer-events:none;position:absolute;top:0;left:0;width:100%;height:100%;overflow:hidden;will-change:width,height,top,left,opacity;perspective:inherit}div.micrio-markers:empty{display:none}div.micrio-markers>*{pointer-events:all}div.inactive.micrio-markers>*{pointer-events:none}div.is360.micrio-markers{transition:opacity .25s}div.is360.inactive.micrio-markers{opacity:0}aside.micrio-markers{pointer-events:none}aside.micrio-markers section:where(.micrio-markers){position:absolute;top:0;bottom:0;width:10vw;width:10cqw;min-width:200px;font-size:1em;font-weight:500;line-height:1em;color:var(--micrio-marker-color);display:flex;flex-direction:column}aside.micrio-markers section:where(.micrio-markers):nth-child(1){left:10px;align-items:flex-end}aside.micrio-markers section:where(.micrio-markers):nth-child(2){right:10px;align-items:flex-start}aside.micrio-markers section:where(.micrio-markers) article:where(.micrio-markers){flex:1;padding:10px;max-height:30vh;max-height:30cqh;display:flex;align-items:center}aside.micrio-markers section:where(.micrio-markers) label:where(.micrio-markers){pointer-events:all;cursor:pointer;padding:10px;max-width:160px;opacity:.75;transition:opacity .25s ease,color .25s ease;text-shadow:var(--micrio-marker-text-shadow)}label.hover.micrio-markers{color:var(--micrio-marker-highlight);opacity:1}aside.micrio-markers section:where(.micrio-markers):nth-child(1) article:where(.micrio-markers){justify-content:right}aside.micrio-markers section:where(.micrio-markers):nth-child(1) label:where(.micrio-markers){text-align:right}svg.micrio-markers{width:100%;height:100%;pointer-events:none;position:absolute}svg.micrio-markers line:where(.micrio-markers){stroke:var(--micrio-marker-highlight);stroke-width:2}svg.micrio-markers line:where(.micrio-markers):not(.hovered){stroke:var(--micrio-marker-color);stroke-dasharray:10px;stroke-width:1;opacity:.75}.embed-container.micrio-embed{position:absolute;display:block;top:0;left:0;transform:translate3d(calc(var(--x, 0) - 50%),calc(var(--y, 0) - 50%),0) scale3d(var(--s),var(--s),1);opacity:var(--opacity, 1);direction:ltr;will-change:transform,opacity}.embed3d.micrio-embed{top:50%;left:50%}.embed-container.no-events.micrio-embed{pointer-events:none}.embed-container.micrio-embed>:where(.micrio-embed){cursor:pointer}.embed-container.micrio-embed>*{position:absolute;transform:translate3d(-50%,-50%,0) scale3d(var(--scale, 1),var(--scale, 1),1)}.embed-container.micrio-embed>*:not(button){width:auto!important}.embed-container.micrio-embed:not(.no-events)>*{pointer-events:all}.embed-container.micrio-embed>img:where(.micrio-embed){max-width:none}.embed-container.micrio-embed>button{--scale: 1;--ratio: 1;padding:0;margin:0;background:transparent;border:none;width:100px;aspect-ratio:var(--ratio)}svg.micrio-progress-circle{position:absolute;top:50%;left:50%;pointer-events:none;transform:translate(-50%,-50%) rotate(-90deg);z-index:10}circle.micrio-progress-circle{transition:stroke-dashoffset .25s ease}
26
26
  `,C,M))})();