1"use strict";(self.webpackChunkcaptur3d=self.webpackChunkcaptur3d||[]).push([[216],{27216:function(U,N,g){g.r(N),g.d(N,{AudioMuteSource:function(){return n.x4},AudioSource:function(){return n.uC},AudioTourPlayer:function(){return Q},AudioTourPlayerEvents:function(){return n.zC},AudioTourState:function(){return n.Kc},Track:function(){return h},Zone:function(){return m},isAudioMattertag:function(){return D},isRichAudio:function(){return P},log:function(){return E},toDecimal:function(){return I},toPercent:function(){return M},toSdkMediaType:function(){return A}});var n=g(30065),O=g(9772),C=g(86709);const l=window.location.href.indexOf("audio_tour_debugging")!==-1;function M(c){return c*100}function I(c){return c/100}function E(...c){if(!l)return;const r=["[AUDIO_TOUR]"];console.log.apply(console,r.concat(c))}const b=["soundcloud.com","spotify.com","rdio.com","npr.org","radioreddit.com"],P=c=>{try{if(!c)return!1;const r=new URL(c),i=t(r);return b.includes(i)}catch(r){return!1}},D=(c,r,i)=>r===c.Mattertag.MediaType.VIDEO?!0:r===c.Mattertag.MediaType.RICH?P(i):!1,A=(c,r)=>{switch(r){case C.zu.VIDEO:return c.Mattertag.MediaType.VIDEO;case C.zu.RICH:return c.Mattertag.MediaType.RICH;case C.zu.PHOTO:return c.Mattertag.MediaType.PHOTO;default:return c.Mattertag.MediaType.NONE}},e=c=>{const r=c.hostname;let i;return r.match(new RegExp(/\.[a-z]{2,3}\.[a-z]{2}$/i))?i=r.replace(new RegExp(/\.[a-z]{2,3}\.[a-z]{2}$/i),""):r.match(new RegExp(/\.[a-z]{2,4}$/i))&&(i=r.replace(new RegExp(/\.[a-z]{2,4}$/i),"")),!!i.match(new RegExp(/\./g))?i.split(".")[0]:""},t=c=>{const r=e(c);return c.hostname.split(".").filter(d=>d!==r).join(".")};var s=g(94196);const o=800;let u={};class h{constructor(r){this.finished=!1,this.file=r,this.registerTrack()}play(r=null){const i=r||this.file.volume;if(this.finished){E(`Track ${this.file.fileName} is finished, not starting again`);return}E(`Playing ${this.file.fileName} track at ${i}`),this.id?this.fade(10,i).once("fade",()=>{this.track.play(this.id)}):this.track.play()}reset(){this.finished=!1}volume(r=null){const i=r||this.file.volume;this.id?this.track.volume(I(i),this.id):this.track.volume(I(i))}pause(){E(`Pausing ${this.file.fileName} track`),this.id?this.fade(this.file.volume,0).once("fade",()=>{this.track.pause(this.id)}):this.track.pause()}mute(r){E(`${r?"Mute":"Unmute"} ${this.file.fileName} track`),this.track.mute(r)}fade(r,i){return E(`Fading out ${this.file.fileName} track from ${r} to ${i}`),this.track.fade(I(r),I(i),o,this.id),this.track}registerTrack(){const r=this.file;if(u[r.fileName]){E(`Track ${r.fileName} already registered`),this.track=u[r.fileName].track;return}E(`Registering track for file ${this.file.fileName}`),this.track=new s.Howl({src:[r.audioUrl],loop:r.loop,volume:I(r.volume),html5:r.html5,onplay:i=>{this.id=i}}),u[r.fileName]=this,r.loop||this.track.on("end",()=>{this.finished=!0})}}class m{constructor(r,i,d){this.sweeps=r,this.file=i,this.name=d,this.registerTrack()}withSweep(r){return this.sweeps.some(i=>i.id===this.toNewSweepId(r))}findSweep(r){return this.sweeps.find(i=>i.id===this.toNewSweepId(r))}registerTrack(){const r=this.file;E(`Registering track for Zone ${this.name}`),this.track=new h(r)}toNewSweepId(r){var i,d;return((d=(i=window.MP.sweepIdAdapter)==null?void 0:i.toNewSweepId(r))==null?void 0:d.id)||r}}var p=g(41517);const v=[n.uC.NONE,n.uC.BACKGROUND,n.uC.ZONE,n.uC.SCENE_MEDIA,n.uC.MATTERTAG];class k{constructor(r){this.hasOnlyMediaSource=()=>Boolean(this.sourcesAvailable.media&&!this.sourcesAvailable.background&&!this.sourcesAvailable.zones),this.updateCurrentSourcePlaying=i=>{if(i.from&&i.to){console.error("You must specify one or the other");return}if(i.from)if(this.currentAudioSource===i.from)this.currentAudioSource=this.lowerPriorityAudioSource({after:i.from});else return;else if(i.to)if(this.isHigherPriorityThanCurrent(i.to))this.currentAudioSource=i.to;else return;switch(this.currentAudioSource){case n.uC.MATTERTAG:this.handleMattertagAudioSource();break;case n.uC.SCENE_MEDIA:this.handleSceneMediaAudioSource();break;case n.uC.ZONE:this.handleZoneAudioSource();break;
1case n.uC.BACKGROUND:this.handleBackgroundAudioSource();break;case n.uC.NONE:break}},this.updateAvailableSources=()=>{this.sourcesAvailable=this.setSourcesAvailable()},this.lowerPriorityAudioSource=i=>{const d=v.findIndex(R=>R===i.after);return d===0?v[d]:v[d-1]},this.isHigherPriorityThanCurrent=i=>{const d=v.findIndex(a=>a===i),R=v.findIndex(a=>a===this.currentAudioSource);return d>=R},this.handleMattertagAudioSource=()=>{const{currentZone:i}=this.player;i==null||i.track.pause(),this.fadeOutAmbientTrack(10),this.mediaPlayers().forEach(d=>{var R,a;(a=(R=d.inputs)==null?void 0:R.spatialAudio)!=null&&a.active||d.pause()})},this.handleSceneMediaAudioSource=()=>{const{currentZone:i}=this.player;this.mediaPlaying()?(i==null||i.track.pause(),this.fadeOutAmbientTrack(10)):this.updateCurrentSourcePlaying({from:n.uC.SCENE_MEDIA})},this.handleZoneAudioSource=()=>{const{currentZone:i}=this.player;this.mediaPlaying()||(i?(!i.track.track.playing()&&i.track.play(),this.fadeOutAmbientTrack(10)):this.updateCurrentSourcePlaying({from:n.uC.ZONE}))},this.handleBackgroundAudioSource=()=>{const{ambientTrack:i}=this.player;i?this.fadeOutAmbientTrack(100):this.updateCurrentSourcePlaying({from:n.uC.BACKGROUND})},this.fadeOutAmbientTrack=i=>{const{ambientTrack:d}=this.player;!d||d.fade(M(d.track.volume()),i)},this.setSourcesAvailable=()=>{const{sceneMedia:i,zones:d,ambientTrack:R}=this.player;return{media:i.length>0,background:Boolean(R),zones:d.length>0}},this.mediaPlaying=()=>this.mediaPlayers().some(i=>{var d,R,a;return Boolean(((d=i.inputs)==null?void 0:d.playAudio)&&i.state===p.PLAYER_STATES.PLAYING&&!((a=(R=i.inputs)==null?void 0:R.spatialAudio)!=null&&a.active))}),this.mediaPlayers=()=>this.player.sceneMedia.map(i=>{var d;return(d=i.inputs)==null?void 0:d.player}),this.player=r,this.currentAudioSource=n.uC.NONE,this.sourcesAvailable=this.setSourcesAvailable()}}var w=g(85306),_=g(9247),H=g(1814),V=g(76730),$=g(37787),x=Object.defineProperty,j=Object.defineProperties,z=Object.getOwnPropertyDescriptors,G=Object.getOwnPropertySymbols,F=Object.prototype.hasOwnProperty,Y=Object.prototype.propertyIsEnumerable,W=(c,r,i)=>r in c?x(c,r,{enumerable:!0,configurable:!0,writable:!0,value:i}):c[r]=i,B=(c,r)=>{for(var i in r||(r={}))F.call(r,i)&&W(c,i,r[i]);if(G)for(var i of G(r))Y.call(r,i)&&W(c,i,r[i]);return c},X=(c,r)=>j(c,z(r)),Z=(c,r,i)=>new Promise((d,R)=>{var a=S=>{try{T(i.next(S))}catch(L){R(L)}},f=S=>{try{T(i.throw(S))}catch(L){R(L)}},T=S=>S.done?d(S.value):Promise.resolve(S.value).then(a,f);T((i=i.apply(c,r)).next())});const y=new w.k("AudioTourPlayer");class Q{constructor(r,i,d,R){this.ambientTrack=null,this.currentZone=null,this.zones=[],this.mattertags=[],this.sdkListeners=[],this.start=(a=!0)=>{this.play(),this.muteAudio(!a),this.setupSdkEvents()},this.play=()=>{this.ambientTrack&&(E("Start playing ambient track"),this.ambientTrack.play()),this.startMediaAutoplay(),this.state=n.Kc.STARTED},this.stop=()=>{this.ambientTrack&&(E("Mute ambient track"),this.ambientTrack.track.mute(!0)),this.zones.map(a=>a.track.track.mute(!0)),this.sceneMedia.forEach(a=>{var f,T;return(T=(f=a.inputs)==null?void 0:f.player)==null?void 0:T.mute(!0)}),this.state=n.Kc.STOPPED,this.cleanupEventListeners()},this.muteAudio=(a,f=n.x4.EVENT)=>{this.mutedBy[f]=a,this.ambientTrack&&this.ambientTrack.mute(a),this.zones.map(T=>T.track.mute(a)),this.sceneMedia.forEach(T=>{var S,L;return(L=(S=T.inputs)==null?void 0:S.player)==null?void 0:L.mute(a)}),this.audioMuted=a,this.state=a?n.Kc.MUTED:n.Kc.STARTED,this.broadcastEvent(n.zC.AUDIO_MUTED)},this.hasAudio=()=>Boolean(this.ambientTrack||this.zones.length>0||this.sceneMedia.length>0),this.findTag=a=>{var f;if(this.fetchTags)return this.fetchTags(a);const T=this.mattertags.find(S=>S.sid===a);return T?{sid:T.sid,mediaType:A(this.sdk,T.mediaType),mediaUrl:(f=T.mediaUrl)!=null?f:void 0}:null},this.isAudioTag=a=>{const f=this.findTag(a);return f?D(this.sdk,f.mediaType,f.mediaUrl):!1},this.handleCustomTagClosed=()=>{this.audioSourceController.updateCurrentSourcePlaying({from:n.uC.MATTERTAG})},this.updateSdkAndScene=(a,f)=>{this.cleanupEventListeners(),this.scene=f,this.sdk=a,this.tagHelper=(0,V.T)(this.sdk,(0,_.Z)().new_tags_enabled),this.setupSdkEvents(),this.registerSceneMedia(),this.registerMattertags(),this.startMediaAutoplay(),this.audioSourceController.updateAvailableSources()},this.startMediaAutoplay=()=>
1{this.sceneMediaWithAutoplay().forEach(a=>{var f;(f=a.inputs)==null||f.player.play()})},this.setupSdkEvents=()=>{const a=this.sdk;this.subscriptions.push(a.App.state.subscribe(f=>{f.phase===a.App.Phase.PLAYING&&(this.subscriptions.push(a.Sweep.current.subscribe(T=>{this.handleSweepEntered(this.toNewSweepId(T.id))})),this.tagHelper.onClick(this.handleMattertagClicked))}))},this.cleanupEventListeners=()=>{for(const[a,f]of this.sdkListeners)this.sdk.off(a,f);this.sdkListeners=[],this.subscriptions.forEach(a=>a.cancel()),this.subscriptions=[]},this.handleMattertagClicked=a=>{this.mutedBy[n.x4.CONTROLLER]||!this.isAudioTag(a)||this.audioSourceController.updateCurrentSourcePlaying({to:n.uC.MATTERTAG})},this.handleSweepEntered=a=>{var f;if(!a||this.state===n.Kc.INIT||a===""||this.currentSweepId===a)return;this.currentSweepId=a;const T=this.zones.find(S=>S.withSweep(a));if(T){const S=T.findSweep(a);if(!S)throw"Unable to find sweep in zone";this.handleZoneEntered(T,S)}else(f=this.currentZone)==null||f.track.pause(),this.currentZone=null,this.audioSourceController.updateCurrentSourcePlaying({from:n.uC.ZONE})},this.handleZoneEntered=(a,f)=>{if(this.state===n.Kc.INIT)return;const T=this.currentZone;a===T?(E(`Still on ${a.name}`),a.track.volume(f.volume)):(T?(E(`Transitioning from ${T.name} to ${a.name}`),this.handleZoneTransition(a,f)):(E(`Transitioning from <No Zone> to ${a.name}`),this.currentZone=a,a.track.reset(),a.track.play(f.volume)),this.audioSourceController.updateCurrentSourcePlaying({to:n.uC.ZONE}),this.broadcastEvent(n.zC.AUDIO_ZONE_CHANGED))},this.handleZoneTransition=(a,f)=>{var T;this.state!==n.Kc.INIT&&((T=this.currentZone)==null||T.track.pause(),a.track.reset(),a.track.play(f.volume),E(`Sets new current zone: ${a.name}`),this.currentZone=a)},this.registerMattertags=()=>Z(this,null,function*(){try{this.mattertags=yield this.tagHelper.getData()}catch(a){$.Cp(a),this.mattertags=[]}}),this.registerSceneMedia=()=>Z(this,null,function*(){!this.scene||(this.sceneMedia=this.scene.components.filter(O.hasVideoWithAudio),this.sceneMedia.forEach(a=>{var f,T,S;const L=(f=a.inputs)==null?void 0:f.player;if(y.log("media & player: ",a,L),!this.scene)throw"Scene loader removed while registering scene media";const J=(T=this.scene)==null?void 0:T.spyOnComponentEvent(a,H.ComponentInteractionType.AUDIO_PLAY,K=>{y.log("Audio play"),this.audioSourceController.updateCurrentSourcePlaying({to:n.uC.SCENE_MEDIA})}),q=(S=this.scene)==null?void 0:S.spyOnComponentEvent(a,H.ComponentInteractionType.AUDIO_PAUSE,K=>{y.log("Audio pause"),this.audioSourceController.updateCurrentSourcePlaying({from:n.uC.SCENE_MEDIA})});this.subscriptions.push(J,q)}))}),this.audioTour=i,this.sdk=r,this.currentZone=null,this.state=n.Kc.INIT,this.audioMuted=!0,this.scene=d,this.currentSweepId=null,this.subscriptions=[],this.sceneMedia=[],this.mutedBy={[n.x4.CONTROLLER]:!1,[n.x4.EVENT]:!1},this.fetchTags=R||null,this.tagHelper=(0,V.T)(this.sdk,(0,_.Z)().new_tags_enabled),this.registerAmbient(),this.registerZones(),this.registerMattertags(),this.registerSceneMedia(),this.audioSourceController=new k(this)}broadcastEvent(r,i={}){window.dispatchEvent(new CustomEvent(r,i))}registerAmbient(){var r;const i=(r=this.audioTour)==null?void 0:r.ambientTrack;i?this.ambientTrack=new h(i):(E("Ambient does not exist"),this.ambientTrack=null)}registerZones(){var r;this.zones=(((r=this.audioTour)==null?void 0:r.zones)||[]).map(i=>new m(i.sweeps.map(d=>X(B({},d),{id:this.toNewSweepId(d.id)||d.id})),i.audioTrack,i.name))}sceneMediaWithAutoplay(){return this.sceneMedia.filter(r=>{var i;return((i=r.inputs)==null?void 0:i.autoPlay)===p.AutoplayOption.ON_START})}toNewSweepId(r){var i,d;if(!!r)return((d=(i=window.MP.sweepIdAdapter)==null?void 0:i.toNewSweepId(r))==null?void 0:d.id)||r}}},85306:function(U,N,g){g.d(N,{k:function(){return n}});class n{constructor(C){if(this.debug=(...l)=>{!this.isEnabled()||console.debug(`[${this.loggerTag}]`,...l)},this.log=(...l)=>{!this.isEnabled()||console.log(`[${this.loggerTag}]`,...l)},this.info=(...l)=>{!this.isEnabled()||console.info(`[${this.loggerTag}]`,...l)},this.warn=(...l)=>{!this.isEnabled()||console.warn(`[${this.loggerTag}]`,...l)},this.error=(...l)=>{!this.isEnabled()||console.error(`[${this.loggerTag}]`,...l)},this.time=l=>{!this.isEnabled()||console.time(`[${this.loggerTag}] ${l}`)},this.timeEnd=l=>{!this.isEnabled()||console.timeEnd(`[${this.loggerTag}] ${l}`)},this.isEnabled=()=>{const l=window.debugLogger,M=l[this.loggerTag]||l.all;return M||M&&this.enabledViaUrl},this.setupWindow=()=>{const l=window;l.debugLogger||(l.debugLogger={}),l.debugLogger[this.loggerTag]=this.enabledViaUrl},this.isEnabledViaUrl=()=>{var l;const I=((l=new URL(window.location.href).searchParams.get("debugLogger"))==null?void 0:l.split(","))||[];return I.includes("all")||I.includes(this.loggerTag)},C==="all")throw new Error("'all' is reserved tag for enabling all loggers");this.loggerTag=C,this.enabledViaUrl=this.isEnabledViaUrl(),this.setupWindow()}}},76730:function(U,N,g){g.d(N,{T:function(){return D}});var n=g(86709),O=(A,e,t)=>new Promise((s,o)=>{var u=p=>{try{m(t.next(p))}catch(v){o(v)}},h=p=>{try{m(t.throw(p))}catch(v){o(v)}},m=p=>p.done?s(p.value):Promise.resolve(p.value).then(u,h);m((t=t.apply(A,e)).next())});class C{constructor(e){this.buildMattertagData=t=>O(this,null,function*(){const{sid:s,anchorPosition:o,color:u,description:h,enabled:m,floorInfo:p,label:v,media:k,stemVector:w,stemVisible:_}=t;return{sid:s,anchorPosition:o,color:u,description:h,enabled:m,floorInfo:p,label:v,mediaType:this.convertMatterportMediaType(k.type),mediaUrl:k.src,roomId:null,stemVector:w,stemVisible:_}}),this.convertMatterportMediaType=t=>{switch(t){case"mattertag.media.photo":return n.zu.PHOTO;case"mattertag.media.rich":return n.zu.RICH;case"mattertag.media.video":return n.zu.VIDEO;default:return n.zu.NONE}},this.sdk=e}getData(){return O(this,null,function*(){const e=yield this.sdk.Mattertag.getData();return Promise.all(e.map(t=>this.buildMattertagData(t)))})}allowActions(e,t){const{navigating:s,opening:o}=t,u={navigating:!s,opening:!o,sharing:!1};return this.sdk.Mattertag.preventAction(e,u)}registerIcon(e,t){return this.sdk.Mattertag.registerIcon(e,t)}updateIcon(e,t){return this.sdk.Mattertag.editIcon(e,t)}resetIcon(e){return this.sdk.Mattertag.resetIcon(e)}subscribe(e){this.sdk.Mattertag.data.subscribe({onAdded:(t,s,o)=>O(this,null,function*(){var u;const h=yield this.buildMattertagData(s);(u=e.onAdded)==null||u.call(e,h)}),onRemoved:(t,s,o)=>O(this,null,function*(){var u;const h=yield this.buildMattertagData(s);(u=e.onRemoved)==null||u.call(e,h)}
1),onUpdated:(t,s,o)=>O(this,null,function*(){var u;const h=yield this.buildMattertagData(s);(u=e.onUpdated)==null||u.call(e,h)}),onCollectionUpdated:e.onCollectionUpdated})}editPosition(e,t){const{anchorPosition:s,floorIndex:o,stemVector:u}=t;return Promise.resolve(this.sdk.Mattertag.editPosition(e,{anchorPosition:s,floorIndex:o,stemVector:u}))}editColor(e,t){return this.sdk.Mattertag.editColor(e,t)}removeTag(e){return this.sdk.Mattertag.remove(e)}addTag(e){return this.sdk.Mattertag.add(e)}editOpacity(e,t){return this.sdk.Mattertag.editOpacity(e,t)}navigateToTag(e){return this.sdk.Mattertag.navigateToTag(e,this.sdk.Mattertag.Transition.FLY)}editBillboard(e,t){return this.sdk.Mattertag.editBillboard(e,t)}onClick(e){this.sdk.on(this.sdk.Mattertag.Event.CLICK,e)}onHover(e){this.sdk.on(this.sdk.Mattertag.Event.HOVER,e)}}var l=Object.getOwnPropertySymbols,M=Object.prototype.hasOwnProperty,I=Object.prototype.propertyIsEnumerable,E=(A,e)=>{var t={};for(var s in A)M.call(A,s)&&e.indexOf(s)<0&&(t[s]=A[s]);if(A!=null&&l)for(var s of l(A))e.indexOf(s)<0&&I.call(A,s)&&(t[s]=A[s]);return t},b=(A,e,t)=>new Promise((s,o)=>{var u=p=>{try{m(t.next(p))}catch(v){o(v)}},h=p=>{try{m(t.throw(p))}catch(v){o(v)}},m=p=>p.done?s(p.value):Promise.resolve(p.value).then(u,h);m((t=t.apply(A,e)).next())});class P{constructor(e){this.attachments={},this.attachmentsLoaded=!1,this.matchesDescriptor=(t,s)=>{if((t.label||"")!==(s.label||"")||!s.anchorPosition)return!1;const o=.01,{x:u,y:h,z:m}=s.anchorPosition;return Math.abs(t.anchorPosition.x-u)<o&&Math.abs(t.anchorPosition.y-h)<o&&Math.abs(t.anchorPosition.z-m)<o},this.buildMattertagData=t=>b(this,null,function*(){const{id:s,label:o,description:u,anchorPosition:h,stemVector:m,color:p,roomId:v,stemVisible:k}=t,w=t.attachments[0],_=yield this.fetchAttachment(w);return{sid:s,anchorPosition:h,color:p,description:u,enabled:!0,floorInfo:null,label:o,mediaType:(_==null?void 0:_.type)||n.zu.NONE,mediaUrl:_==null?void 0:_.src,roomId:v,stemVector:m,stemVisible:k}}),this.fetchAttachment=t=>b(this,null,function*(){let o=0;for(;t&&!this.attachmentsLoaded&&o++<100;)yield new Promise(h=>setTimeout(h,100));const u=this.attachments[t];return{src:u==null?void 0:u.src,type:this.convertMatterportMediaType(u==null?void 0:u.type)}}),this.convertMatterportMediaType=t=>{switch(t){case"tag.attachment.image":return n.zu.PHOTO;case"tag.attachment.rich":return n.zu.RICH;case"tag.attachment.video":return n.zu.VIDEO;default:return n.zu.NONE}},this.sdk=e,this.loadAttachments()}getData(){return b(this,null,function*(){const e=yield this.sdk.Tag.data.waitUntil(()=>!0),s=Array.from(e).map(o=>o[1]);return Promise.all(s.map(o=>this.buildMattertagData(o)))})}allowActions(e,t){return this.sdk.Tag.allowAction(e,t)}registerIcon(e,t){return this.sdk.Asset.registerTexture(e,t)}updateIcon(e,t){return this.sdk.Tag.editIcon(e,t)}resetIcon(e){return this.sdk.Tag.resetIcon(e)}subscribe(e){this.sdk.Tag.data.subscribe({onAdded:(t,s,o)=>b(this,null,function*(){var u;const h=yield this.buildMattertagData(s);(u=e.onAdded)==null||u.call(e,h)}),onRemoved:(t,s,o)=>b(this,null,function*(){var u;const h=yield this.buildMattertagData(s);(u=e.onRemoved)==null||u.call(e,h)}),onUpdated:(t,s,o)=>b(this,null,function*(){var u;const h=yield this.buildMattertagData(s);(u=e.onUpdated)==null||u.call(e,h)}),onCollectionUpdated:e.onCollectionUpdated})}editPosition(e,t){const s=t,{anchorPosition:o,roomId:u,stemVector:h}=s,m=E(s,["anchorPosition","roomId","stemVector"]);return Promise.resolve(this.sdk.Tag.editPosition(e,{anchorPosition:o,roomId:u,stemVector:h}))}editColor(e,t){return this.sdk.Tag.editColor(e,t)}removeTag(e){return this.sdk.Tag.remove(e)}addTag(e){let o=!1;const u=new Promise((h,m)=>{const p=Date.now(),v=()=>b(this,null,function*(){var k;if(!o){try{const w=yield this.sdk.Tag.data.waitUntil(()=>!0),H=Array.from(w).map(V=>V[1]).find(V=>this.matchesDescriptor(V,e));if(H){h([H.id]);return}}catch(w){}if(Date.now()-p>15e3){m(new Error(`Tag.add: timed out waiting for tag "${(k=e.label)!=null?k:""}" to appear`));return}setTimeout(v,500)}});v()});return Promise.race([Promise.resolve(this.sdk.Tag.add(e)),u]).finally(()=>{o=!0})}editOpacity(e,t){return this.sdk.Tag.editOpacity(e,t)}navigateToTag(e){return this.sdk.Mattertag.navigateToTag(e,this.sdk.Mattertag.Transition.FLY)}editBillboard(e,t){const{label:s,description:o}=t;return this.sdk.Tag.editBillboard(e,{label:s,description:o})}onClick(e){let t=new Set;this.sdk.Tag.openTags.subscribe(s=>{s.selected.forEach(o=>{t.has(o)||e(o)}),t=new Set(s.selected)})}onHover(e){let t=null;this.sdk.Tag.openTags.subscribe(s=>{const{hovered:o}=s;o!==t&&(t&&e(t,!1),o&&e(o,!0),t=o)})}loadAttachments(){this.sdk.Tag.attachments.subscribe({onAdded:(e,t,s)=>{this.attachments[t.id]=t,this.attachmentsLoaded=!0}})}}const D=(A,e)=>e?new P(A):new C(A)},86709:function(U,N,g){g.d(N,{zu:function(){return n}});var n=(O=>(O.NONE="no_media",O.PHOTO="photo",O.VIDEO="video",O.RICH="rich",O.WEBSITE="website",O))(n||{})},1814:function(U,N,g){g.r(N),g.d(N,{ComponentErrorTypes:function(){return C},ComponentInteractionType:function(){return O},KeyState:function(){return P},Keys:function(){return D},MP_COMPONENTS:function(){return A},PointerButton:function(){return I},PointerButtonMask:function(){return E},PointerDevice:function(){return b},SceneComponent:function(){return n},TransformControlsMode:function(){return e}});
1class n{}var O=(t=>(t.CLICK="INTERACTION.CLICK",t.HOVER="INTERACTION.HOVER",t.DRAG="INTERACTION.DRAG",t.DRAG_BEGIN="INTERACTION.DRAG_BEGIN",t.DRAG_END="INTERACTION.DRAG_END",t.POINTER_MOVE="INTERACTION.POINTER_MOVE",t.POINTER_BUTTON="INTERACTION.POINTER_BUTTON",t.SCROLL="INTERACTION.SCROLL",t.KEY="INTERACTION.KEY",t.LONG_PRESS_START="INTERACTION.LONG_PRESS_START",t.LONG_PRESS_END="INTERACTION.LONG_PRESS_END",t.MULTI_SWIPE="INTERACTION.MULTI_SWIPE",t.MULTI_SWIPE_END="INTERACTION.MULTI_SWIPE_END",t.PINCH="INTERACTION.PINCH",t.PINCH_END="INTERACTION.PINCH_END",t.ROTATE="INTERACTION.ROTATE",t.ROTATE_END="INTERACTION.ROTATE_END",t.RIGHT_CLICK="CUSTOM.RIGHT_CLICK",t.IN_RANGE="CUSTOM.IN_RANGE",t.IN_VIEW="CUSTOM.IN_VIEW",t.MOVING_VIA_TRANSFORM_CONTROLS="CUSTOM.MOVING_VIA_TRANSFORM_CONTROLS",t.MOVED_VIA_TRANSFORM_CONTROLS="CUSTOM.MOVED_VIA_TRANSFORM_CONTROLS",t.VIDEO_READY="CUSTOM.VIDEO_READY",t.AUDIO_PLAY="CUSTOM.AUDIO_PLAY",t.AUDIO_PAUSE="CUSTOM.AUDIO_PAUSE",t.COMPONENT_ERROR="CUSTOM.COMPONENT_ERROR",t))(O||{}),C=(t=>(t.ASSET_INVALID="ASSET INVALID",t))(C||{});class l{constructor(){this.objectRoot=null,this.collider=null}}class M extends null{}var I=(t=>(t[t.PRIMARY=0]="PRIMARY",t[t.MIDDLE=1]="MIDDLE",t[t.SECONDARY=2]="SECONDARY",t[t.BACK=3]="BACK",t[t.FORWARD=4]="FORWARD",t[t.COUNT=5]="COUNT",t))(I||{}),E=(t=>(t[t.NONE=0]="NONE",t[t.PRIMARY=1]="PRIMARY",t[t.SECONDARY=4]="SECONDARY",t[t.MIDDLE=2]="MIDDLE",t[t.BACK=8]="BACK",t[t.FORWARD=16]="FORWARD",t[t.ALL=31]="ALL",t))(E||{}),b=(t=>(t.MOUSE="mouse",t.TOUCH="touch",t.PEN="pen",t.GAMEPAD="gamepad",t))(b||{}),P=(t=>(t[t.DOWN=0]="DOWN",t[t.PRESSED=1]="PRESSED",t[t.UP=2]="UP",t))(P||{}),D=(t=>(t[t.ESCAPE=27]="ESCAPE",t[t.ZERO=48]="ZERO",t[t.ONE=49]="ONE",t[t.TWO=50]="TWO",t[t.THREE=51]="THREE",t[t.FOUR=52]="FOUR",t[t.FIVE=53]="FIVE",t[t.SIX=54]="SIX",t[t.SEVEN=55]="SEVEN",t[t.EIGHT=56]="EIGHT",t[t.NINE=57]="NINE",t[t.LEFTARROW=37]="LEFTARROW",t[t.UPARROW=38]="UPARROW",t[t.RIGHTARROW=39]="RIGHTARROW",t[t.DOWNARROW=40]="DOWNARROW",t[t.TAB=9]="TAB",t[t.A=65]="A",t[t.B=66]="B",t[t.C=67]="
1C",t[t.D=68]="D",t[t.E=69]="E",t[t.F=70]="F",t[t.G=71]="G",t[t.H=72]="H",t[t.I=73]="I",t[t.J=74]="J",t[t.K=75]="K",t[t.L=76]="L",t[t.M=77]="M",t[t.N=78]="N",t[t.O=79]="O",t[t.P=80]="P",t[t.Q=81]="Q",t[t.R=82]="R",t[t.S=83]="S",t[t.T=84]="T",t[t.U=85]="U",t[t.V=86]="V",t[t.W=87]="W",t[t.X=88]="X",t[t.Y=89]="Y",t[t.Z=90]="Z",t[t.SPACE=32]="SPACE",t[t.RETURN=13]="RETURN",t[t.DELETE=46]="DELETE",t[t.BACKSPACE=8]="BACKSPACE",t[t.SEMICOLON=186]="SEMICOLON",t[t.PLUSEQUALS=187]="PLUSEQUALS",t[t.DASHUNDERSCORE=189]="DASHUNDERSCORE",t[t.OPENBRACKET=219]="OPENBRACKET",t[t.SHIFT=16]="SHIFT",t[t.ALT=18]="ALT",t[t.CONTROL=17]="CONTROL",t))(D||{}),A=(t=>(t.TRANSFORM_CONTROLS="mp.transformControls",t))(A||{}),e=(t=>(t.TRANSLATE="translate",t.ROTATE="rotate",t.SCALE="scale",t))(e||{})},9772:function(U,N,g){g.r(N),g.d(N,{hasVideo:function(){return E},hasVideoWithAudio:function(){return b},isAssetComponent:function(){return C},isComponentMedia:function(){return M},isOutdoorAssetComponent:function(){return l},isPointAreaComponent:function(){return O},isSketchfabModel:function(){return I},updateComponentVisibility:function(){return D},updateComponentsShadowVisibility:function(){return A},updateComponentsVisibility:function(){return P}});var n=g(25767);const O=e=>Boolean(e.objectType()===n.VTStagingAdapterTypes.ObjectType.AUDIO_CUSTOM_AREA),C=e=>Boolean(e.objectType()===n.VTStagingAdapterTypes.ObjectType.ASSET),l=e=>Boolean(e.objectType()===n.VTStagingAdapterTypes.ObjectType.OUTDOOR_ASSET),M=e=>Boolean(e.objectType()===n.VTStagingAdapterTypes.ObjectType.VIDEO||e.objectType()===n.VTStagingAdapterTypes.ObjectType.IMAGE||e.objectType()===n.VTStagingAdapterTypes.ObjectType.IFRAME),I=e=>{var t,s;return Boolean(e.objectType()===n.VTStagingAdapterTypes.ObjectType.ASSET&&((s=(t=e.inputs)==null?void 0:t.meta)==null?void 0:s.source)==="sketchfab")},E=e=>Boolean(e.objectType()===n.VTStagingAdapterTypes.ObjectType.VIDEO),b=e=>{var t;return Boolean(E(e)&&((t=e.inputs)==null?void 0:t.playAudio))},P=(e,t)=>{e.forEach(s=>D(s,t))},D=(e,t)=>{var s,o,u;const{visible:h,force:m}=t;(s=e.inputs)!=null&&s.toBeRemoved||(e.inputs.visible=m?h:Boolean(e.alwaysVisible)||h,(u=(o=e.inputs)==null?void 0:o.shadow)==null||u.setShadowVisibility(h))},A=(e,t)=>{e.forEach(s=>{var o;!((o=s.inputs)!=null&&o.shadow)||s.inputs.shadow.setShadowVisibility(t)})}},41517:function(U,N,g){g.r(N),g.d(N,{AutoplayOption:function(){return O},PLAYER_STATES:function(){return n},spatialAudioDefault:function(){return C}});var n=(l=>(l.NOT_STARTED="not_started",l.PLAYING="playing",l.PAUSED="paused",l))(n||{}),O=(l=>(l.OFF="off",l.ON_VIEW="onView",l.ON_START="onStart",l))(O||{});const C={active:!1,opts:{refDistance:1,rolloffFactor:1,distanceModel:"exponential"}}}}]); 2 3//# sourceMappingURL=216-3568a30fc9a0ef45d279.js.map
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.