@epigraph/solutions 1.2.2 → 1.2.3

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.
@@ -17477,7 +17477,7 @@ void main() {
17477
17477
  .model-viewer.hide {
17478
17478
  visibility: hidden;
17479
17479
  }
17480
- `]}firstUpdated(e){super.firstUpdated(e),this.__createAndPortalArModal()}__createAndPortalArModal(){this.arModalElem=document.createElement("epg-modal-ar"),this.arModalElem.id="arModal",this.arModalElem.setAttribute("powered-by-epigraph",""),this.arModalElem.setAttribute("powered-by-epigraph-href",this.appWcRef.epigraphWebsiteRedirectUrls.modal),this.arModalElem.isLoading=!0,this.arModalElem.addEventListener("epgOnLaunchArClicked",()=>this.presentAr()),this.arModalElem.addEventListener("epgOnModalHidden",()=>this.onArModalClose()),document.body.appendChild(this.arModalElem)}disconnectedCallback(){super.disconnectedCallback(),this.arModalElem?.remove()}__registerModelViewerWebComponent(){window.customElements.get("model-viewer")||window.customElements.define("model-viewer",QJ)}static setupWebComponent(){window.customElements.get(ag.webComponentName)||window.customElements.define(ag.webComponentName,ag)}get arLink(){return this.__arLink}showArModal(){this.arModalElem.showModal();const e=new aa(!0,aa.PANEL_TYPE.AR,aa.TRIGGER_SOURCE.BUTTON,[]);this.appWcRef.epigraphAnalytics.sendEvent(e)}showQr(){this.qrModalElem.showModal();const e=new aa(!0,aa.PANEL_TYPE.QR,aa.TRIGGER_SOURCE.BUTTON,[]);this.appWcRef.epigraphAnalytics.sendEvent(e)}async resolveSrcUrl(){if(this.glbSrc="",this.usdzSrc="",this.arModalElem.isLoading=!0,ix){const e=await this.appWcRef.getGlbUrlForAr();if(e===null){window.epigraph.logger.error({title:"Error getting the GLB for AR session",contextOverride:this._loggerContext});return}this.glbSrc=e}else vv&&(this.usdzSrc=await this.appWcRef.getUsdzUrlForAr(),this.glbSrc="https://asset.myepigraph.com/solutions-assets/__PIPELINE__/assets/3d-assets/proxyGeo/null-proxy.glb");this.arModalElem.isLoading=!1}getViewInYourSpaceUrl(){return yn.generateShareableUrl({baseUrl:this.appWcRef.baseUrlOverride,identifier:this.appWcRef.identifier,identifierType:this.appWcRef.identifierType,arCompatible:!0})}async getViewInYourSpaceQR(){const e=this.getViewInYourSpaceUrl();return this.appWcRef.qrCodeGenerator.generateQrCode({text:e.href})}async launchAR(){if(this.canLaunchAr()){const e=new hL([]);this.appWcRef.epigraphAnalytics.sendEvent(e),this.showArModal(),await this.resolveSrcUrl()}else{const e=await this.getViewInYourSpaceQR();this.qrModalElem.qrCodeImage=e,this.showQr()}return Promise.resolve(!0)}canLaunchAr(){return this.modelViewerElem.canActivateAR}async presentAr(){return this.modelViewerElem.activateAR()}isARSessionActive(){return this.modelViewerElem.getAttribute("ar-status")==="presenting"}getMinimumRequirementsString(){let e="";return qW&&(HD?e="iOS 16 and above":zD&&(e="Android 12 and above")),e}onArModalClose(){const e=new oa(!0,oa.PANEL_TYPE.AR,oa.TRIGGER_SOURCE.BUTTON,[]);this.appWcRef.epigraphAnalytics.sendEvent(e)}onQrModalClose(){const e=new oa(!0,oa.PANEL_TYPE.QR,oa.TRIGGER_SOURCE.BUTTON,[]);this.appWcRef.epigraphAnalytics.sendEvent(e)}__renderQrModal(){return re`<epg-modal-qr
17480
+ `]}firstUpdated(e){super.firstUpdated(e),this.__createAndPortalArModal()}__createAndPortalArModal(){this.arModalElem=document.createElement("epg-modal-ar"),this.arModalElem.id="arModal",this.arModalElem.setAttribute("powered-by-epigraph",""),this.arModalElem.setAttribute("powered-by-epigraph-href",this.appWcRef.epigraphWebsiteRedirectUrls.modal),this.arModalElem.isLoading=!0,this.arModalElem.addEventListener("epgOnLaunchArClicked",()=>void this.presentAr()),this.arModalElem.addEventListener("epgOnModalHidden",()=>this.onArModalClose()),document.body.appendChild(this.arModalElem)}disconnectedCallback(){super.disconnectedCallback(),this.arModalElem?.remove()}__registerModelViewerWebComponent(){window.customElements.get("model-viewer")||window.customElements.define("model-viewer",QJ)}static setupWebComponent(){window.customElements.get(ag.webComponentName)||window.customElements.define(ag.webComponentName,ag)}get arLink(){return this.__arLink}showArModal(){this.arModalElem.showModal();const e=new aa(!0,aa.PANEL_TYPE.AR,aa.TRIGGER_SOURCE.BUTTON,[]);this.appWcRef.epigraphAnalytics.sendEvent(e)}showQr(){this.qrModalElem.showModal();const e=new aa(!0,aa.PANEL_TYPE.QR,aa.TRIGGER_SOURCE.BUTTON,[]);this.appWcRef.epigraphAnalytics.sendEvent(e)}async resolveSrcUrl(){if(this.glbSrc="",this.usdzSrc="",this.arModalElem.isLoading=!0,ix){const e=await this.appWcRef.getGlbUrlForAr();if(e===null){window.epigraph.logger.error({title:"Error getting the GLB for AR session",contextOverride:this._loggerContext});return}this.glbSrc=e}else vv&&(this.usdzSrc=await this.appWcRef.getUsdzUrlForAr(),this.glbSrc="https://asset.myepigraph.com/solutions-assets/__PIPELINE__/assets/3d-assets/proxyGeo/null-proxy.glb");this.arModalElem.isLoading=!1}getViewInYourSpaceUrl(){return yn.generateShareableUrl({baseUrl:this.appWcRef.baseUrlOverride,identifier:this.appWcRef.identifier,identifierType:this.appWcRef.identifierType,arCompatible:!0})}async getViewInYourSpaceQR(){const e=this.getViewInYourSpaceUrl();return this.appWcRef.qrCodeGenerator.generateQrCode({text:e.href})}async launchAR(){if(this.canLaunchAr()){const e=new hL([]);this.appWcRef.epigraphAnalytics.sendEvent(e),this.showArModal(),setTimeout(()=>{this.resolveSrcUrl()},1e3)}else{const e=await this.getViewInYourSpaceQR();this.qrModalElem.qrCodeImage=e,this.showQr()}return Promise.resolve(!0)}canLaunchAr(){return this.modelViewerElem.canActivateAR}async presentAr(){return this.modelViewerElem.activateAR()}isARSessionActive(){return this.modelViewerElem.getAttribute("ar-status")==="presenting"}getMinimumRequirementsString(){let e="";return qW&&(HD?e="iOS 16 and above":zD&&(e="Android 12 and above")),e}onArModalClose(){const e=new oa(!0,oa.PANEL_TYPE.AR,oa.TRIGGER_SOURCE.BUTTON,[]);this.appWcRef.epigraphAnalytics.sendEvent(e)}onQrModalClose(){const e=new oa(!0,oa.PANEL_TYPE.QR,oa.TRIGGER_SOURCE.BUTTON,[]);this.appWcRef.epigraphAnalytics.sendEvent(e)}__renderQrModal(){return re`<epg-modal-qr
17481
17481
  id="qrModal"
17482
17482
  powered-by-epigraph
17483
17483
  powered-by-epigraph-href=${this.appWcRef.epigraphWebsiteRedirectUrls.modal}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@epigraph/solutions",
3
- "version": "1.2.2",
3
+ "version": "1.2.3",
4
4
  "type": "module",
5
5
  "main": "./dist/epigraph-solutions.js",
6
6
  "files": [