@tinkerlandai/longplay-sdk 0.10.71 → 0.10.72
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/CHANGELOG.md +4 -0
- package/dist/check-response-FTYRCENP.js +1 -0
- package/dist/{chunk-LQ2XY26R.js → chunk-2DAYQCEC.js} +1 -1
- package/dist/{chunk-YV4HA2DV.js → chunk-2UB5RFXZ.js} +1 -1
- package/dist/{chunk-Q5DB34R4.js → chunk-2WINZC4O.js} +1 -1
- package/dist/{chunk-QIV2YOVB.js → chunk-2WMBBFPQ.js} +1 -1
- package/dist/{chunk-3KIATB75.js → chunk-3DW3Q6RU.js} +1 -1
- package/dist/{chunk-UR2PWRLG.js → chunk-3TKVWOFW.js} +1 -1
- package/dist/{chunk-ZVVDPXHC.js → chunk-4MGLQ6UP.js} +1 -1
- package/dist/{chunk-UWHTCMMF.js → chunk-5HDJT7E5.js} +1 -1
- package/dist/{chunk-TNWZWEEY.js → chunk-5MX7OICH.js} +1 -1
- package/dist/{chunk-F46VXI3Q.js → chunk-64TKCCJF.js} +1 -1
- package/dist/{chunk-IYVJOUO7.js → chunk-6DE2YAGZ.js} +1 -1
- package/dist/{chunk-TDMXEI2U.js → chunk-6OXRK7PK.js} +1 -1
- package/dist/{chunk-EPQUD3S5.js → chunk-6TX2UFWN.js} +1 -1
- package/dist/{chunk-5M2IIZB6.js → chunk-ANNZWFFN.js} +1 -1
- package/dist/chunk-C57G3LX4.js +1 -0
- package/dist/{chunk-G7JQNJM4.js → chunk-DRY3ZZCD.js} +1 -1
- package/dist/{chunk-4C4L3JER.js → chunk-EHWMZCNT.js} +1 -1
- package/dist/{chunk-IUX4CJZM.js → chunk-EU4XNTEE.js} +1 -1
- package/dist/{chunk-UOJSZMKN.js → chunk-FU4XNGGP.js} +1 -1
- package/dist/{chunk-BZRDECZJ.js → chunk-FXKZJP4T.js} +1 -1
- package/dist/{chunk-RZ7WFYWY.js → chunk-FXRBRAJR.js} +1 -1
- package/dist/{chunk-4HMPCJOG.js → chunk-FZSVLHCH.js} +2 -2
- package/dist/{chunk-LHUZRVAC.js → chunk-G7QLMLCR.js} +1 -1
- package/dist/{chunk-IXYVLURA.js → chunk-GACCPVPU.js} +1 -1
- package/dist/{chunk-ZJXQTMBW.js → chunk-HATZIRVQ.js} +1 -1
- package/dist/{chunk-MUW3SOTB.js → chunk-JLDKGCU2.js} +1 -1
- package/dist/{chunk-24Z5QET3.js → chunk-JR56NRGI.js} +1 -1
- package/dist/chunk-JT5RMCS6.js +1 -0
- package/dist/{chunk-VCUJMMEM.js → chunk-K3GKANLZ.js} +1 -1
- package/dist/{chunk-44SX4C3G.js → chunk-K55XWFEI.js} +1 -1
- package/dist/{chunk-NCMKY7D6.js → chunk-L5IBJODQ.js} +1 -1
- package/dist/{chunk-DGMRFL7K.js → chunk-MYYLRNLZ.js} +1 -1
- package/dist/{chunk-TYIAPLQP.js → chunk-NSNEBNOM.js} +1 -1
- package/dist/{chunk-EU4NTVRT.js → chunk-QPCIIQ6Q.js} +1 -1
- package/dist/{chunk-TLQUUC3G.js → chunk-RHARJTIX.js} +1 -1
- package/dist/{chunk-ZFNSXRQY.js → chunk-RPN7SE4S.js} +1 -1
- package/dist/{chunk-6A4NV4ET.js → chunk-TQM2JVHJ.js} +1 -1
- package/dist/{chunk-AFQHUBKJ.js → chunk-UFEILUGE.js} +1 -1
- package/dist/{chunk-ULJJTIL5.js → chunk-UZAJOV75.js} +1 -1
- package/dist/{chunk-PYM47Z55.js → chunk-V6RXIFHI.js} +1 -1
- package/dist/{chunk-ONYG4VQI.js → chunk-WO6BLOJI.js} +1 -1
- package/dist/{chunk-5XMHY7QX.js → chunk-WWEHYERC.js} +1 -1
- package/dist/{chunk-6ZUJCHBI.js → chunk-X3VCEYMU.js} +1 -1
- package/dist/{chunk-4XDMBMDA.js → chunk-X6IKITFV.js} +1 -1
- package/dist/{chunk-DJTMSBQN.js → chunk-XHJ33SCP.js} +1 -1
- package/dist/{chunk-IR6ELT3D.js → chunk-Y7CKOODV.js} +1 -1
- package/dist/{chunk-MAKRT62V.js → chunk-ZQZFQHV4.js} +1 -1
- package/dist/{content-F3LHKR2S.js → content-KUCHBKX6.js} +1 -1
- package/dist/{funnel-host-purchase-WJ2GKXKT.js → funnel-host-purchase-WMAKTI2H.js} +1 -1
- package/dist/{funnel-host-recovery-paywall-OANZILW3.js → funnel-host-recovery-paywall-YMOYXK4D.js} +1 -1
- package/dist/{funnel-paywall-copies-ZI6BLXH7.js → funnel-paywall-copies-WAX7Q2N4.js} +1 -1
- package/dist/funnel-paywall-prerender-U5BVF7QG.js +1 -0
- package/dist/funnel-route-prediction-EKSGU3ZG.js +1 -0
- package/dist/funnel-route-source-AV45OI6M.js +1 -0
- package/dist/funnel-runtime-host-SCBNV4VB.js +1 -0
- package/dist/index.js +1 -1
- package/dist/merchant-bridge-contracts-LPMJFG7V.js +1 -0
- package/dist/native-shell.js +1 -1
- package/dist/openrouter.js +1 -1
- package/dist/operation-contracts-YFZHNHKS.js +1 -0
- package/dist/page.js +1 -1
- package/dist/paywall-BHPQH2ZJ.js +1 -0
- package/dist/paywall-content-WAUQRLBP.js +1 -0
- package/dist/paywall-session-I2YT3WUZ.js +1 -0
- package/dist/popup.js +1 -1
- package/dist/react-native.js +1 -1
- package/dist/screen-renderer-4X5MLXGZ.js +1 -0
- package/dist/server.js +1 -1
- package/dist/visual.js +1 -1
- package/package.json +1 -1
- package/dist/check-response-3EFQG3PL.js +0 -1
- package/dist/chunk-KNZ3WTQ5.js +0 -1
- package/dist/chunk-TFGIDUGW.js +0 -1
- package/dist/funnel-paywall-prerender-36ER2LYV.js +0 -1
- package/dist/funnel-route-prediction-IO6TEHFN.js +0 -1
- package/dist/funnel-route-source-VQQIKYXL.js +0 -1
- package/dist/funnel-runtime-host-LXIT2QY7.js +0 -1
- package/dist/merchant-bridge-contracts-CJY7TX6J.js +0 -1
- package/dist/operation-contracts-FAW24KGA.js +0 -1
- package/dist/paywall-TVYLGNDU.js +0 -1
- package/dist/paywall-content-NLEGSOUT.js +0 -1
- package/dist/paywall-session-ADXZWQPU.js +0 -1
- package/dist/screen-renderer-EWRXGDWQ.js +0 -1
- /package/dist/{chunk-4HMPCJOG.js.LEGAL.txt → chunk-FZSVLHCH.js.LEGAL.txt} +0 -0
- /package/dist/{chunk-CTCK5BUY.js → chunk-RTKI4V2J.js} +0 -0
package/dist/openrouter.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./chunk-
|
|
1
|
+
import"./chunk-DRY3ZZCD.js";import"./chunk-NSNEBNOM.js";import"./chunk-6OXRK7PK.js";import"./chunk-XHJ33SCP.js";import{a as i}from"./chunk-EHWMZCNT.js";import"./chunk-6DE2YAGZ.js";import"./chunk-TQM2JVHJ.js";import"./chunk-5MRSFLQA.js";import{b as A}from"./chunk-RTKI4V2J.js";import"./chunk-WOT6VMZA.js";var c=A.number().int().min(0).max(1e9);function R(e,o){let a=c.parse(e.promptTokens),p=c.parse(e.completionTokens),s=c.parse(e.promptTokensDetails?.cachedTokens??0),t=c.parse(e.promptTokensDetails?.cacheWriteTokens??0),r=c.parse(e.promptTokensDetails?.audioTokens??0),l=c.parse(e.completionTokensDetails?.audioTokens??0),n=c.parse(e.completionTokensDetails?.reasoningTokens??0);if(c.parse(e.totalTokens)!==a+p||s+t+r>a||n+l>p||(e.promptTokensDetails?.videoTokens??0)>0)throw new i("AI_USAGE_UNAVAILABLE","Token pools must conserve usage; video needs an explicit token mapper");return{input:a-s-t-r,output:p-l-(o==="separate"?n:0),cache_read:s,cache_write:t,input_audio:r,output_audio:l,reasoning:o==="separate"?n:0}}function I(e){if(!Number.isFinite(e)||e<0)throw new i("AI_USAGE_UNAVAILABLE","Provider cost must be a nonnegative USD amount");let o=String(e),a=o.includes("e")?e.toFixed(18).replace(/0+$/,"").replace(/\.$/,""):o;if(!/^(0|[1-9]\d{0,11})(\.\d{1,18})?$/.test(a)||Number(a)!==e)throw new i("AI_USAGE_UNAVAILABLE","Provider cost exceeds the supported precision");return a}async function f(e){if(typeof window<"u")throw new i("SERVER_ONLY","OpenRouter accounting requires your backend");if(!["output","separate"].includes(e.reasoning)||!e.modelId||!e.generationId)throw new i("INVALID_REQUEST","Actual model, generation ID and reasoning pricing are required");let o={context:e.context,generationId:e.generationId,modelId:`openrouter/${e.modelId}`,usage:e.usage,tokens:null,quote:null,receipt:null,phase:"captured"};await e.persist(o);let a=e.mapTokens?e.mapTokens(e.usage):R(e.usage,e.reasoning),p=e.usage.cost==null?void 0:I(e.usage.cost),s=e.quote??await e.pricing.quoteTokens({modelId:o.modelId,tokens:a});if(s.pricing.modelId!==o.modelId||Object.keys(a).some(l=>a[l]!==s.tokens[l]))throw new i("INVALID_REQUEST","Saved quote must match the provider model and token pools");await e.persist({...o,tokens:a,quote:s,phase:"quoted"});let t=await e.pricing.trackTokens(e.client,{...e.context,quote:s,providerCostUsd:p,generationId:e.generationId});if(!t.receipt.accepted)throw new i("AI_BALANCE_REJECTED","OpenRouter usage was saved but the balance request was rejected");let r={...o,tokens:a,quote:s,receipt:t,phase:"settled"};return await e.persist(r),r}function T(e){if(typeof window<"u")throw new i("SERVER_ONLY","OpenRouter accounting requires your backend");if(!["output","separate"].includes(e.reasoning))throw new i("INVALID_REQUEST","Reasoning pricing is required");let o=e.openRouter.chat;async function a(t){if(!t.usage||!t.modelId||!t.generationId)throw new i("AI_USAGE_UNAVAILABLE","OpenRouter did not return final usage and the actual model");await f({...e,context:t.context,generationId:t.generationId,modelId:t.modelId.slice(11),usage:t.usage})}let p=async(t,r)=>{let n={context:await e.context(),generationId:null,modelId:null,usage:null,tokens:null,quote:null,receipt:null,phase:"incomplete"},d;try{d=await o.send(t,r)}catch(g){throw await e.persist(n),g}if(!(d instanceof ReadableStream)){if(n={...n,generationId:d.id,modelId:d.model?`openrouter/${d.model}`:null,usage:d.usage??null},!n.usage||!n.modelId)throw await e.persist(n),new i("AI_USAGE_UNAVAILABLE","OpenRouter omitted final accounting");return await a(n),d}let w=d.getReader(),m=!1;return new ReadableStream({async pull(g){try{let{value:u,done:k}=await w.read();if(k){if(m=!0,!n.usage||!n.modelId)throw await e.persist(n),new i("AI_USAGE_UNAVAILABLE","OpenRouter stream ended without final accounting");await a(n),g.close();return}if(u.error)throw new i("AI_PROVIDER_ERROR",u.error.message);u.usage&&(n={...n,generationId:u.id,modelId:u.model?`openrouter/${u.model}`:null,usage:u.usage}),g.enqueue(u)}catch(u){m||(m=!0,await e.persist(n)),await w.cancel(u),g.error(u)}},async cancel(g){m||(m=!0,await e.persist(n)),await w.cancel(g)}})},s=new Proxy(o,{get(t,r){return r==="send"?p:Reflect.get(t,r,t)}});return new Proxy(e.openRouter,{get(t,r){return r==="chat"?s:Reflect.get(t,r,t)}})}export{T as createOpenRouterUsageClient,f as trackOpenRouterUsage};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{e as o}from"./chunk-X3VCEYMU.js";import"./chunk-L5IBJODQ.js";import"./chunk-RPN7SE4S.js";import"./chunk-6TX2UFWN.js";import"./chunk-V6RXIFHI.js";import"./chunk-K55XWFEI.js";import"./chunk-JLDKGCU2.js";import"./chunk-WO6BLOJI.js";import"./chunk-G7QLMLCR.js";import"./chunk-UFEILUGE.js";import"./chunk-VILB5M4X.js";import"./chunk-NSNEBNOM.js";import"./chunk-XHJ33SCP.js";import"./chunk-5MX7OICH.js";import"./chunk-2UB5RFXZ.js";import"./chunk-5HDJT7E5.js";import"./chunk-MYYLRNLZ.js";import"./chunk-RHARJTIX.js";import"./chunk-6DE2YAGZ.js";import"./chunk-RTKI4V2J.js";import"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";export{o as apiOperations};
|
package/dist/page.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as o,e as r,f as e,g as f}from"./chunk-
|
|
1
|
+
import{d as o,e as r,f as e,g as f}from"./chunk-FZSVLHCH.js";import"./chunk-MB2U2GWJ.js";import"./chunk-3VUPVXAV.js";import"./chunk-TQM2JVHJ.js";import"./chunk-5MRSFLQA.js";import"./chunk-DSPLGTQI.js";import"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";export{f as createPageExperiments,o as mergeQueryStrings,r as pageAttributes,e as readPayload};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a}from"./chunk-X6IKITFV.js";import"./chunk-2DAYQCEC.js";import"./chunk-W32FI2A2.js";import"./chunk-3TKVWOFW.js";import"./chunk-QPCIIQ6Q.js";import"./chunk-FXRBRAJR.js";import"./chunk-JLDKGCU2.js";import"./chunk-WO6BLOJI.js";import"./chunk-G7QLMLCR.js";import"./chunk-VILB5M4X.js";import"./chunk-6OXRK7PK.js";import"./chunk-XHJ33SCP.js";import"./chunk-5MX7OICH.js";import"./chunk-2UB5RFXZ.js";import"./chunk-5HDJT7E5.js";import"./chunk-MYYLRNLZ.js";import"./chunk-RHARJTIX.js";import"./chunk-EHWMZCNT.js";import"./chunk-6DE2YAGZ.js";import"./chunk-TQM2JVHJ.js";import"./chunk-5MRSFLQA.js";import"./chunk-RTKI4V2J.js";import"./chunk-DSPLGTQI.js";import"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";export{a as showPaywall};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{b as a}from"./chunk-UZAJOV75.js";import"./chunk-6TX2UFWN.js";import"./chunk-V6RXIFHI.js";import"./chunk-K55XWFEI.js";import"./chunk-JLDKGCU2.js";import"./chunk-WO6BLOJI.js";import"./chunk-G7QLMLCR.js";import"./chunk-UFEILUGE.js";import"./chunk-VILB5M4X.js";import"./chunk-6OXRK7PK.js";import"./chunk-XHJ33SCP.js";import"./chunk-5MX7OICH.js";import"./chunk-2UB5RFXZ.js";import"./chunk-5HDJT7E5.js";import"./chunk-MYYLRNLZ.js";import"./chunk-RHARJTIX.js";import"./chunk-EHWMZCNT.js";import"./chunk-6DE2YAGZ.js";import"./chunk-3VUPVXAV.js";import"./chunk-TQM2JVHJ.js";import"./chunk-5MRSFLQA.js";import"./chunk-RTKI4V2J.js";import"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";export{a as readPaywallContent};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a}from"./chunk-GACCPVPU.js";import"./chunk-X3VCEYMU.js";import"./chunk-L5IBJODQ.js";import"./chunk-64TKCCJF.js";import"./chunk-QPCIIQ6Q.js";import"./chunk-FXRBRAJR.js";import"./chunk-RPN7SE4S.js";import"./chunk-ZQZFQHV4.js";import"./chunk-UZAJOV75.js";import"./chunk-6TX2UFWN.js";import"./chunk-V6RXIFHI.js";import"./chunk-K55XWFEI.js";import"./chunk-JLDKGCU2.js";import"./chunk-WO6BLOJI.js";import"./chunk-G7QLMLCR.js";import"./chunk-UFEILUGE.js";import"./chunk-VILB5M4X.js";import"./chunk-NSNEBNOM.js";import"./chunk-6OXRK7PK.js";import"./chunk-XHJ33SCP.js";import"./chunk-5MX7OICH.js";import"./chunk-2UB5RFXZ.js";import"./chunk-5HDJT7E5.js";import"./chunk-MYYLRNLZ.js";import"./chunk-RHARJTIX.js";import"./chunk-EHWMZCNT.js";import"./chunk-6DE2YAGZ.js";import"./chunk-3VUPVXAV.js";import"./chunk-TQM2JVHJ.js";import"./chunk-5MRSFLQA.js";import"./chunk-RTKI4V2J.js";import"./chunk-DSPLGTQI.js";import"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";export{a as createPaywallSession};
|
package/dist/popup.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as _,b as z,c as M,d as U,e as W,f as q,g as V,h as j,i as S}from"./chunk-
|
|
1
|
+
import{a as _,b as z,c as M,d as U,e as W,f as q,g as V,h as j,i as S}from"./chunk-FXKZJP4T.js";import{a as H,b as x,d as y,f as C,g as A,m as E}from"./chunk-3TKVWOFW.js";import"./chunk-5MX7OICH.js";import{D as b}from"./chunk-2UB5RFXZ.js";import"./chunk-5HDJT7E5.js";import"./chunk-MYYLRNLZ.js";import"./chunk-RHARJTIX.js";import"./chunk-EHWMZCNT.js";import"./chunk-6DE2YAGZ.js";import"./chunk-RTKI4V2J.js";import{a as p}from"./chunk-DSPLGTQI.js";import"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";function O(m,r,n){let d=m.ownerDocument,s=d.defaultView;if(!s)throw new Error("Preview container has no browser window");let l=!1,u=!1,f=0,c,i=d.createElement("div");i.style.cssText="width:100%;min-width:0";let v=(e,F)=>{c=S(e,{mode:"live",rendererUrl:n.rendererUrl,title:n.title??r.name,onPageChange:n.onPageChange,onAction:(R,I)=>p(n.onAction,R,I),onError:n.onError,...F}),c.update(r,n.locale,{capabilities:n.capabilities,customerData:n.customerData})},h=r.presentation;if(h.type==="inline")return m.append(i),v(i,{onContentHeight(e){f=e,p(n.onContentHeight,e,m.clientHeight)}}),{presentation:"inline",inspect:()=>c?.inspect?.()??Promise.resolve(null),destroy(){l||(l=!0,c?.destroy(),i.remove())}};let t=d.createElement("dialog");t.lang=n.locale,t.dir=b(n.locale)?"rtl":"ltr",t.setAttribute("aria-label",r.name),t.style.cssText=H(n.host,h,r.theme);let a=d.createElement("button");a.type="button",a.textContent="×",a.setAttribute("aria-label",n.closeLabel),A(a,r.theme);let g=e=>{u&&!l&&p(n.onDismiss,e)};a.addEventListener("click",()=>g("close_button"));let D=()=>c?.resizeViewport(s.innerHeight||800,s.innerWidth||1024),o;if(n.host==="funnel"){let e=d.createElement("section");e.style.cssText="min-width:0;display:flex;flex-direction:column;min-height:100%",i.style.cssText+=";flex:1 0 auto;display:flex;flex-direction:column;justify-content:center",e.append(i),t.append(a,e),o=y(t,r,D)}else i.setAttribute("aria-label",r.name),o=y(t,r,D),t.append(i),t.prepend(a);let L=n.host==="content"&&o.responsive?x(t,()=>g("close_button"),()=>!0,n.closeLabel):void 0;t.addEventListener("cancel",e=>{e.preventDefault(),g("escape")});let w=e=>s.requestAnimationFrame?s.requestAnimationFrame(e):s.setTimeout(e,0),P=()=>{u&&!l&&p(n.onContentHeight,f,t.clientHeight)},T=E(t);return m.append(t),v(i,{viewportHeight:o.responsive?s.innerHeight||800:void 0,...o.responsive?{viewportWidth:s.innerWidth||1024,hostPresentation:()=>o.type}:{},...n.host!=="content"?{closeActions:n.closeActions??r.actions.filter(e=>e.close).map(e=>e.id),onAuthoredClose(e){a.hidden=e}}:{},onResize(e){o.responsive&&(i.style.height=`${e}px`,i.style.overflow="clip",o.setContentHeight(e)),w(P)},onContentHeight(e){f=e},onRendered(e){e&&t.setAttribute("aria-label",e),!(u||l)&&(u=!0,T(),o.latch(),t.showModal(),o.responsive&&t.focus({preventScroll:!0}),C(t,o.type,o.responsive),w(P))},onEscape:()=>g("escape")}),{get presentation(){return o.type},inspect:()=>c?.inspect?.()??Promise.resolve(null),destroy(){l||(l=!0,c?.destroy(),L?.(),o.destroy(),t.open&&t.close(),t.remove())}}}export{q as formatCustomerDecimal,z as hostedRendererScript,_ as hostedRendererShell,U as inspectCustomHtml,O as mountDialogPreview,S as mountScreenPreview,j as preparePopup,W as prepareScreen,M as sanitizeCustomHtml,V as showPopup};
|
package/dist/react-native.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as S,c as E,d as T}from"./chunk-
|
|
1
|
+
import{b as S,c as E,d as T}from"./chunk-K3GKANLZ.js";import"./chunk-EU4XNTEE.js";import{a as A}from"./chunk-GACCPVPU.js";import{e as P}from"./chunk-X3VCEYMU.js";import"./chunk-L5IBJODQ.js";import{h as b,i as x,k as L}from"./chunk-Y7CKOODV.js";import{E as C}from"./chunk-FU4XNGGP.js";import"./chunk-HATZIRVQ.js";import"./chunk-64TKCCJF.js";import"./chunk-QPCIIQ6Q.js";import"./chunk-FXRBRAJR.js";import"./chunk-RPN7SE4S.js";import"./chunk-ZQZFQHV4.js";import"./chunk-UZAJOV75.js";import"./chunk-6TX2UFWN.js";import"./chunk-V6RXIFHI.js";import"./chunk-K55XWFEI.js";import"./chunk-JLDKGCU2.js";import"./chunk-WO6BLOJI.js";import"./chunk-G7QLMLCR.js";import"./chunk-ANNZWFFN.js";import"./chunk-UFEILUGE.js";import"./chunk-VILB5M4X.js";import"./chunk-NSNEBNOM.js";import"./chunk-6OXRK7PK.js";import"./chunk-XHJ33SCP.js";import"./chunk-5MX7OICH.js";import"./chunk-2UB5RFXZ.js";import"./chunk-5HDJT7E5.js";import"./chunk-MYYLRNLZ.js";import"./chunk-RHARJTIX.js";import{a as r}from"./chunk-EHWMZCNT.js";import{h as R}from"./chunk-6DE2YAGZ.js";import"./chunk-3VUPVXAV.js";import"./chunk-TQM2JVHJ.js";import"./chunk-5MRSFLQA.js";import"./chunk-RTKI4V2J.js";import"./chunk-DSPLGTQI.js";import"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";function k(t,d){let n,a=0,m=-1,l,i=!1,y=()=>{if(i)throw new r("CLOSED","Native host was destroyed");if(!t.nativeModule)throw new r("CAPABILITY_UNAVAILABLE","Link IndianaBridge and supply nativeModule");return t.nativeModule},o=()=>new r("IDENTITY_CHANGED","Customer identity changed during the native operation"),h=d.subscribeIdentity(()=>{a++,m=-1;let e=a;n&&t.nativeModule&&n.then(c=>t.nativeModule.reset(c,e)).catch(()=>{})}),I=t.nativeEvents?.(e=>{!n||!t.nativeModule||typeof e?.requestId!="string"||(async()=>{let c=await n;if(e.instanceId!==c)return;if(e.kind==="credential"){let w=a,f=null;try{if(!i&&e.revision===w){let N=await d.access();!i&&a===w&&(f=N)}}finally{await t.nativeModule.provideCredential(c,e.requestId,f)}return}let s=!1,u=a;try{if(i||e.revision!==u||!t.onNativeAction)throw o();await t.onNativeAction(e.action),s=!i&&a===u}finally{await t.nativeModule.acknowledge(c,e.requestId,s)}})().catch(()=>{})});async function p(e,c={}){let s=y();if(d.snapshot()&&!t.nativeEvents)throw new r("CAPABILITY_UNAVAILABLE","Supply nativeEvents to share credential refresh with the native host");let u=a,w=await d.access();if(i||a!==u)throw o();if(!n){let v=s.create(JSON.stringify({baseUrl:t.baseUrl??"https://api.longplayai.com",scope:t.scope,timeout:(t.timeoutMs??15e3)/1e3,credentialEvents:!!t.nativeEvents}));n=v,v.catch(()=>{n===v&&(n=void 0)})}let f=await n;if(i||a!==u)throw o();if(m!==u){if(!l||l.epoch!==u){let O=(async()=>{if(await s.identify(f,JSON.stringify({revision:u,credentials:w})),i||a!==u)throw await s.reset(f,u),o();m=u})();l={epoch:u,task:O}}let v=l;try{await v.task}finally{l===v&&(l=void 0)}}let N=await s.invoke(f,e,JSON.stringify(c));if(i||a!==u)throw o();try{return JSON.parse(N)}catch{throw new r("INVALID_RESPONSE","Native host returned invalid JSON")}}async function g(e,c){let s=await p(e,c);if(!s||typeof s!="object"||Array.isArray(s)||s.status!=="complete"&&s.status!=="dismissed")throw new r("INVALID_RESPONSE","Native presentation returned an invalid result");return s}return{showFunnel(e){return g("showFunnel",{runToken:e})},showPaywall(e){return g("showPaywall",e)},showContent(e){return g("showContent",e)},purchaseSubscription(e,c){return p("purchaseSubscription",{operationId:e,accepted:c})},switchSubscription(e,c){return p("switchSubscription",{operationId:e,accepted:c})},restorePurchases(){return p("restorePurchases")},manageSubscriptions(e){return p("manageSubscriptions",e?{productId:e}:{})},async dismiss(){a++,m=-1,n&&await y().reset(await n,a)},async destroy(){i||(i=!0,a++,h(),I?.(),n&&t.nativeModule&&await t.nativeModule.destroy(await n))}}}var M=P.trackUsage.request.shape.command,U=P.trackUsage.response;function F(t){let d=R.parse(t.scope),n=S({...t,scope:d}),a={...t,scope:d,session:n.session},m=k(t,n.session),l=0,i=!1;n.subscribeIdentity(()=>{l++});let y=()=>{if(i)throw new r("CLOSED","SDK client was destroyed");let o=n.session.peek();if(!o)throw new r("UNAUTHENTICATED","Identify the Customer first");return o};return{...n,native:m,async destroy(){i||(i=!0,l++,n.destroy(),await m.destroy())},funnel(){return E({...a,customerToken:y()})},resumeFunnel(o){return y(),C({...a,runToken:o})},paywall(o){return A(a,{...o,customerToken:y()})},async trackUsage(o){if(y(),!t.usageReporter)throw new r("INVALID_REQUEST","Configure your authenticated backend usageReporter");let h=M.parse(o),I=l,p;try{p=await t.usageReporter(h)}catch(e){throw I!==l?new r("IDENTITY_CHANGED","Customer identity changed during usage reporting"):e}if(I!==l)throw new r("IDENTITY_CHANGED","Customer identity changed during usage reporting");let g=U.parse(p);if(g.scope.projectId!==d.projectId||g.scope.environment!==d.environment)throw new r("INVALID_RESPONSE","Usage response scope differs");return g}}}export{r as LongplayError,x as createConfigurationSync,b as createFeatureClient,T as createFunnelProcess,L as createLocalFunnelClient,F as createLongplayReactNative};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a,b,c,d,e,f,g,h,i}from"./chunk-FXKZJP4T.js";import"./chunk-3TKVWOFW.js";import"./chunk-5MX7OICH.js";import"./chunk-2UB5RFXZ.js";import"./chunk-5HDJT7E5.js";import"./chunk-MYYLRNLZ.js";import"./chunk-RHARJTIX.js";import"./chunk-EHWMZCNT.js";import"./chunk-6DE2YAGZ.js";import"./chunk-RTKI4V2J.js";import"./chunk-DSPLGTQI.js";import"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";export{f as formatCustomerDecimal,b as hostedRendererScript,a as hostedRendererShell,d as inspectCustomHtml,i as mountScreenPreview,h as preparePopup,e as prepareScreen,c as sanitizeCustomHtml,g as showPopup};
|
package/dist/server.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as pn}from"./chunk-
|
|
1
|
+
import{a as pn}from"./chunk-JT5RMCS6.js";import{a as I}from"./chunk-3DW3Q6RU.js";import{a as fn,b as hn,c as gn,d as yn}from"./chunk-DRY3ZZCD.js";import{a as xt}from"./chunk-GACCPVPU.js";import{a as Ue,b as Ve,c as qe,d as He,e as m}from"./chunk-X3VCEYMU.js";import"./chunk-L5IBJODQ.js";import{a as Te,b as ae,c as yt,d as It,e as wt,f as xe,g as vt,h as Me,i as dn,j as ln,k as mn}from"./chunk-Y7CKOODV.js";import{B as V,C as N,d as ft,e as ht,k as gt,l as z,m as St,p as Ct,q as Rt,r as bt,s as At,t as Ot,y as pe,z as Tt}from"./chunk-FU4XNGGP.js";import"./chunk-HATZIRVQ.js";import{c as h}from"./chunk-64TKCCJF.js";import"./chunk-QPCIIQ6Q.js";import"./chunk-FXRBRAJR.js";import"./chunk-RPN7SE4S.js";import{a as Et,b as _e}from"./chunk-ZQZFQHV4.js";import"./chunk-UZAJOV75.js";import"./chunk-6TX2UFWN.js";import{e as at}from"./chunk-V6RXIFHI.js";import{B as pt,C as de,D as Z,E as lt,J as mt,a as et,e as q,j as Re,k as st,l as ct,q as ut,r as dt,s as be,t as Ae}from"./chunk-K55XWFEI.js";import"./chunk-JLDKGCU2.js";import"./chunk-WO6BLOJI.js";import{A as W,B as oe,C as tt,D as Se,E as ie,G as se,H as Ce,M as j,O as ce,P as nt,R as Ee,S as rt,T as ot,f as Ge,g as je,j as we,r as ze,s as Ke,u as an,v as sn,y as cn,z as X}from"./chunk-G7QLMLCR.js";import{b as Oe}from"./chunk-ANNZWFFN.js";import{e as ve,i as Ze,l as it}from"./chunk-UFEILUGE.js";import"./chunk-VILB5M4X.js";import"./chunk-NSNEBNOM.js";import"./chunk-6OXRK7PK.js";import{a as Ne,b as Le}from"./chunk-XHJ33SCP.js";import{o as ue}from"./chunk-5MX7OICH.js";import"./chunk-2UB5RFXZ.js";import{i as un,k as $e,l as Qe,m as Je}from"./chunk-5HDJT7E5.js";import{c as Ie}from"./chunk-MYYLRNLZ.js";import{e as Xe,h as We}from"./chunk-RHARJTIX.js";import{a as c}from"./chunk-EHWMZCNT.js";import{h as Y}from"./chunk-6DE2YAGZ.js";import"./chunk-3VUPVXAV.js";import"./chunk-TQM2JVHJ.js";import"./chunk-5MRSFLQA.js";import{b as u}from"./chunk-RTKI4V2J.js";import"./chunk-DSPLGTQI.js";import{a as Ye}from"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";var _t=4,Mt=[...tt,"requirement_checks","native_offers","preparations","benefit_claims","authorizations","business_results","checkout_termination"],In=u.enum(Mt),ee=(e,n)=>u.array(e).max(n).refine(t=>new Set(t).size===t.length,"Declarations must be unique"),ke=u.strictObject({...se.shape,bridgeVersion:u.literal(_t),capabilities:ee(In,Mt.length),checkKinds:ee(u.enum(["access","metered","credit"]),3),preparationActions:ee(u.enum(["purchase","subscription_change","refund"]),3),authorizationKinds:ee(u.enum(["auto_topup"]),1),nextActionTypes:ee(u.enum(["redirect","authenticate"]),2),resultEvents:ee(u.enum(["benefit.claimed","authorization.updated"]),2)}).superRefine((e,n)=>{e.capabilities.includes("catalog")!==(e.catalog!=="none")&&n.addIssue({code:"custom",path:["catalog"],message:"Catalog declaration differs from its capability"}),(e.capabilities.includes("billing_records")!==e.billingEvents.length>0||new Set(e.billingEvents).size!==e.billingEvents.length)&&n.addIssue({code:"custom",path:["billingEvents"],message:"Declare unique supported billing events"});let t=r=>e.capabilities.includes(r),o=(r,a)=>n.addIssue({code:"custom",path:[r],message:a});t("requirement_checks")!==e.checkKinds.length>0&&o("checkKinds","Declare the supported Check kinds"),t("preparations")!==e.preparationActions.length>0&&o("preparationActions","Declare the supported preparation actions"),t("authorizations")!==e.authorizationKinds.length>0&&o("authorizationKinds","Declare the supported authorization kinds"),t("business_results")!==e.resultEvents.length>0&&o("resultEvents","Declare the supported non-financial results");for(let[r,a,s]of[["purchases","purchase","purchase.completed"],["subscription_changes","subscription_change","subscription.change.completed"],["refunds","refund","refund.updated"]])t(r)&&(!t("operation_status")||!t("billing_records")||!t("preparations")||!e.preparationActions.includes(a)||!e.billingEvents.includes(s))&&o("capabilities",`${r} requires preparation, original lookup and its billing result`);t("purchases")&&!e.billingEvents.includes("purchase.closed")&&o("billingEvents","Purchase execution requires its terminal closure result"),t("checkout_termination")&&(!t("operation_status")||!t("billing_records")||!e.billingEvents.includes("purchase.closed"))&&o("capabilities","Checkout termination requires original lookup and purchase.closed"),t("subscription_changes")&&!e.billingEvents.includes("subscription.change.closed")&&o("billingEvents","Subscription change execution requires its terminal closure result");for(let[r,a]of[["benefit_claims","benefit.claimed"],["authorizations","authorization.updated"]])t(r)&&(!t("operation_status")||!t("business_results")||!e.resultEvents.includes(a))&&o("capabilities",`${r} requires original lookup and its non-financial result`)}),K={"bridge.ping":u.strictObject({challenge:u.uuid()}),"bridge.describe":u.strictObject({}),"requirement.check":$e,"operation.prepare":ze,"benefit.claim":Ue,"operation.read":qe,"purchase.terminate":j},wn={"bridge.ping":u.strictObject({challenge:u.uuid()}),"bridge.describe":ke,"requirement.check":Qe,"operation.prepare":Ke,"benefit.claim":Ve,"operation.read":He,"purchase.terminate":j.extend({outcome:u.enum(["requested","already_paid"])})},Gn=u.enum(["bridge.ping","bridge.describe","requirement.check","operation.prepare","benefit.claim","operation.read","purchase.terminate"]);function $(e,n){return u.strictObject({bridgeVersion:u.literal(_t),requestId:u.uuid(),scope:Ce,command:u.literal(e),data:n})}var kt=u.discriminatedUnion("command",[$("bridge.ping",K["bridge.ping"]),$("bridge.describe",K["bridge.describe"]),$("requirement.check",K["requirement.check"]),$("operation.prepare",K["operation.prepare"]),$("benefit.claim",K["benefit.claim"]),$("operation.read",K["operation.read"]),$("purchase.terminate",K["purchase.terminate"])]),Be=u.strictObject({code:u.string().regex(/^MERCHANT_BRIDGE_[A-Z_]+$/),message:u.string().min(1).max(500),retryable:u.boolean(),recovery:u.string().min(1).max(80),effect:u.enum(["none","unknown"])}).refine(e=>e.effect!=="unknown"||!e.retryable&&e.recovery==="recover_operation","Unknown effects require original-operation recovery");function Bt(e){let n={bridgeVersion:u.literal(4),requestId:u.uuid(),scope:Ce,command:u.literal(e)};return u.union([u.strictObject({...n,data:wn[e]}),u.strictObject({...n,error:Be})])}var Pt="X-Indiana-Bridge-Signature",Q="X-Indiana-Bridge-Key-Id";function vn(e){return new TextEncoder().encode(e)}function Dt(e){return Uint8Array.from(atob(e.replaceAll("-","+").replaceAll("_","/")),n=>n.charCodeAt(0))}function Ft(e,n,t,o){return vn(`indiana-merchant-bridge:${o}
|
|
2
2
|
${n}
|
|
3
3
|
POST
|
|
4
4
|
${W}
|
package/dist/visual.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as pe,c as fe}from"./chunk-OJM6ORHE.js";import{b as le}from"./chunk-J6KIN4RH.js";import{a as Ve,b as ce,c as de,d as ue}from"./chunk-SLUA7ABW.js";import{a as J,b as F,c as ge,e as me}from"./chunk-
|
|
1
|
+
import{a as pe,c as fe}from"./chunk-OJM6ORHE.js";import{b as le}from"./chunk-J6KIN4RH.js";import{a as Ve,b as ce,c as de,d as ue}from"./chunk-SLUA7ABW.js";import{a as J,b as F,c as ge,e as me}from"./chunk-FZSVLHCH.js";import{a as re,b as ae,c as se,d as oe}from"./chunk-MB2U2GWJ.js";import"./chunk-3VUPVXAV.js";import"./chunk-TQM2JVHJ.js";import"./chunk-5MRSFLQA.js";import{b as o}from"./chunk-RTKI4V2J.js";import"./chunk-DSPLGTQI.js";import{c as te,e as ie,g as M}from"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";var K="indiana-visual-diagnostics-v1",Ae=o.strictObject({environmentId:o.string().uuid(),release:o.string().regex(/^[a-f0-9]{64}$/).nullable(),generation:o.string().regex(/^[a-f0-9]{64}$/).nullable(),publishedGeneration:o.string().regex(/^[a-f0-9]{64}$/).nullable(),checkedAt:o.string().datetime(),origin:o.string().url(),pathname:o.string().max(2048),urlMatches:o.boolean(),stopped:o.boolean(),rows:o.array(o.strictObject({changeId:o.string().regex(/^[a-f0-9]{64}$/),experimentKey:o.string().max(256),variationKey:o.string().max(256),inExperiment:o.boolean(),fingerprint:o.string().regex(/^[a-f0-9]{64}$/),status:o.enum(["inactive","waiting","partial","applied","mismatch","no_changes","unavailable","error"]),total:o.number().int().min(0).max(600),applied:o.number().int().min(0).max(600)})).max(100)});function ye(e){let l=n=>Array.isArray(n)?"["+n.map(l).join(",")+"]":n&&typeof n=="object"?"{"+Object.entries(n).filter(([,c])=>c!==void 0).sort(([c],[y])=>c.localeCompare(y)).map(([c,y])=>JSON.stringify(c)+":"+l(y)).join(",")+"}":JSON.stringify(n);return l({css:e.css,js:e.js,domMutations:e.domMutations,...e.renderGuard?{renderGuard:e.renderGuard}:{}})}function he(e){let l=new URL(e.baseUrl),n=l.origin==="https://api.longplayai.com"||l.origin==="https://api.dev.longplayai.com"?l.hostname.slice(4):void 0,c=e.origins??(n?[`https://console.${n}`]:[]),y=new Set(c.filter(t=>{try{let i=new URL(t);return i.origin===t&&(i.protocol==="https:"||i.protocol==="http:"&&["localhost","127.0.0.1","[::1]"].includes(i.hostname))}catch{return!1}})),v=!1,I=!1,k=0,T=async t=>{if(v||I||!t.source||!y.has(t.origin)||!t.data||typeof t.data!="object")return;let i=t.data;if(!(i.channel!==K||i.type!=="inspect"||i.environmentId!==e.environmentId||typeof i.nonce!="string"||!/^[a-f0-9-]{36}$/i.test(i.nonce)||typeof i.changeId!="string"||!/^[a-f0-9]{64}$/.test(i.changeId)||typeof i.url!="string"||i.url.length>2048||Date.now()-k<250)){try{if(new URL(i.url).origin!==location.origin)return}catch{return}I=!0,k=Date.now();try{let x=await e.inspect(i.changeId,i.url);!v&&x.rows.some(S=>S.changeId===i.changeId)&&t.source.postMessage({channel:K,type:"result",nonce:i.nonce,snapshot:x},t.origin)}finally{I=!1}}},u=t=>{T(t).catch(()=>{})};return window.addEventListener("message",u),()=>{v=!0,window.removeEventListener("message",u)}}var R=e=>!!e&&typeof e=="object"&&!Array.isArray(e),E=(e,l)=>typeof e=="string"&&e.length<=l,Ee=e=>typeof e=="string"&&(["html","class","style","position","href","src","alt","title","id","role","hidden"].includes(e)||/^(aria|data)-[a-z0-9_-]+$/.test(e));function ke(e){if(!R(e)||!E(e.css??"",1e5)||!E(e.js??"",1e5)||!Array.isArray(e.domMutations??[])||Array.isArray(e.domMutations)&&e.domMutations.length>200)throw new Error("Invalid visual variation");let l=e.domMutations??[];for(let n of l)if(!R(n)||!E(n.selector,2048)||!n.selector||!Ee(n.attribute)||!["set","append","remove"].includes(String(n.action))||n.value!==void 0&&!E(n.value,5e4)||n.parentSelector!==void 0&&!E(n.parentSelector,2048)||n.insertBeforeSelector!==void 0&&!E(n.insertBeforeSelector,2048))throw new Error("Invalid visual mutation");return{css:e.css??"",js:e.js??"",domMutations:l,...e.renderGuard===void 0?{}:{renderGuard:le(e.renderGuard)}}}function q(e){if(!R(e)||typeof e.environmentId!="string"||typeof e.trackExposures!="boolean"||!/^[-a-f0-9]{36}$/i.test(e.environmentId)||typeof e.generation!="string"||!/^[a-f0-9]{64}$/.test(e.generation)||!Array.isArray(e.experiments)||e.experiments.length>100||!R(e.savedGroups))throw new Error("Invalid visual experiment payload");let l=e.experiments.map(n=>{if(!R(n)||!["key","changeId"].every(c=>typeof n[c]=="string"&&n[c])||!/^[a-f0-9]{64}$/.test(String(n.changeId))||["namespace","status","groups","url"].some(c=>Object.hasOwn(n,c))||n.hashVersion!==void 0&&n.hashVersion!==2||!Array.isArray(n.variations)||n.variations.length<2||n.variations.length>20||n.urlPatterns!==void 0&&!Array.isArray(n.urlPatterns))throw new Error("Invalid visual experiment");return{...n,variations:n.variations.map(ke)}});return{...e,experiments:l}}var ve=6e4;function qe(e){let l=se(e.baseUrl);if(e.appManifestRelease!==void 0&&!/^[a-f0-9]{64}$/.test(e.appManifestRelease))throw new Error("Invalid IAM manifest digest");if(!/^[0-9a-f-]{36}$/i.test(e.environmentId))throw new Error("Invalid App environment ID");let n=e.fetch??globalThis.fetch.bind(globalThis),c=F(n),y=F(n),v=`${l}/api/v1/visual-experiments/${e.environmentId}`,I=e.appManifestRelease?`${v}?iam=${e.appManifestRelease}`:v,k=re(e.deviceIdCookie??"indiana_did"),T=ae(),u=null,t=!1,i=!1,x="",S={...e.attributes??{}},G,B,D=0,H=-1/0,$,m=new Map,O=new Map,C=new Set,z=ge({endpoint:`${v}/events`,fetch:n,log:e.log,label:"Visual exposure"}),P=z.flush,W,b;function j(){clearTimeout(W),b?.remove(),b=void 0}function Y(s,d){let f=M(s,d);C.has(f)||e.trackExposures===!1||u?.trackExposures===!1||t||(C.add(f),z.push({eventUuid:crypto.randomUUID(),timestamp:new Date().toISOString(),deviceId:k,...T?{sessionId:T}:{},url:location.href,pageTitle:document.title.slice(0,512),experimentKey:s.key,variationKey:d.key}))}function we(s){if(!u||t)return;let d=new Set,f={onExperimentViewed:(r,p)=>{d.add(M(r,p))},url:location.href,attributes:{...me(k,location),...S,indianaAppManifestRelease:e.appManifestRelease??null},savedGroups:te(u.savedGroups),log:e.log},h=new Set;for(let r of u.experiments){if(de(`${e.environmentId}:${r.key}`))continue;let p=r;try{let a=ie(p,f);if(O.set(r.changeId,a),!a.inExperiment)continue;h.add(r.changeId);let w=JSON.stringify([a.key,a.value]),U=m.get(r.changeId);if(U?.signature===w){d.has(M(p,a))&&s.push(()=>{U.applied()&&Y(p,a)});continue}m.get(r.changeId)?.revert(),m.delete(r.changeId);let A=fe(a.value,{requireUniqueTargets:!!e.appManifestRelease&&Array.isArray(r.condition?.$and)&&r.condition.$and.some(g=>g!==null&&typeof g=="object"&&!Array.isArray(g)&&g.indianaAppManifestRelease===e.appManifestRelease),boundVariations:r.variations,allowJs:e.disableJsInjection===!1,nonce:e.nonce,onApplied:()=>{d.has(M(p,a))&&Y(p,a)},onError:g=>e.log?.("Visual experiment stopped",{experiment:r.key,changeId:r.changeId,variation:a.key,error:String(g)}),onTargetStatus:e.log?g=>e.log?.("Visual target status changed",{experiment:r.key,changeId:r.changeId,variation:a.key,...g}):void 0});m.set(r.changeId,{signature:w,revert:A.revert,applied:()=>A.applied,inspect:()=>A.inspect()})}catch(a){e.log?.("Skipping visual experiment",{experiment:r.key,error:String(a)})}}for(let[r,p]of m)h.has(r)||(p.revert(),m.delete(r));j()}let V=()=>{let s=[];pe(()=>we(s));for(let d of s)d()};async function _(){let s=++D,d;try{d=await c.read(I,J)}catch(h){if(t||s!==D)return!1;throw h}let f=q(d);if(f.environmentId.toLowerCase()!==e.environmentId.toLowerCase())throw new Error("Visual payload scope changed");return t||s!==D?!1:(u=f,H=performance.now(),!0)}async function Q(){!await _()||t||(N(),V())}function L(){clearTimeout($),$=setTimeout(()=>{if(document.visibilityState==="hidden")return L();Q().catch(s=>e.log?.("Visual payload refresh failed",{error:String(s)})).finally(()=>{t||L()})},ve)}let X=()=>{t||document.visibilityState==="hidden"||performance.now()-H<ve||(clearTimeout($),Q().catch(s=>e.log?.("Visual payload refresh failed",{error:String(s)})).finally(()=>{t||L()}))},Ie=()=>{x!==location.href&&(x=location.href,V())},Z=()=>{P(!0)},N=()=>{G||t||(G=oe(Ie),addEventListener("pagehide",Z),x=location.href)};async function ee(s,d){let f=location.href,h=u,r=[],p=null;if(!t)try{let a=q(await y.read(I,J));a.environmentId===e.environmentId&&(p=a.generation)}catch{}for(let a of h?.experiments??[]){if(s&&a.changeId!==s)continue;let w=O.get(a.changeId);if(!w)continue;let U=new TextEncoder().encode(ye(w.value)),A=[...new Uint8Array(await crypto.subtle.digest("SHA-256",U))].map(be=>be.toString(16).padStart(2,"0")).join(""),g=m.get(a.changeId)?.inspect()??{status:"inactive",total:0,applied:0};r.push({changeId:a.changeId,experimentKey:a.key,variationKey:w.key,inExperiment:w.inExperiment,fingerprint:A,...g})}return{environmentId:e.environmentId,release:e.appManifestRelease??null,generation:h?.generation??null,publishedGeneration:p,checkedAt:new Date().toISOString(),origin:location.origin,pathname:location.pathname,urlMatches:location.href===f&&(!d||d===f)&&h===u,stopped:t,rows:r}}let ne,xe=ue(()=>{i&&!t&&V()});return{async start(){if(!(i||t)){i=!0,e.appManifestRelease&&(B=ce(e.appManifestRelease)),e.antiFlicker&&(b=document.createElement("style"),e.nonce&&(b.nonce=e.nonce),b.textContent="body { visibility: hidden !important }",document.head.append(b),W=setTimeout(j,Math.min(3e3,Math.max(0,e.antiFlickerTimeout??1e3))));try{if(!await _()||t)return;N(),V()}finally{j(),t||(L(),document.addEventListener("visibilitychange",X),ne=he({environmentId:e.environmentId,baseUrl:l,origins:e.diagnosticsOrigins,inspect:ee}))}}},async refresh(){t||await _()&&(i&&N(),V())},setAttributes(s){S={...s},V()},flush:()=>P(),getDiagnostics:ee,getResults(){return new Map(O)},get generation(){return u?.generation??null},destroy(){t=!0,clearTimeout($),document.removeEventListener("visibilitychange",X),xe(),ne?.(),D++,c.destroy(),y.destroy(),G?.(),B?.destroy(),removeEventListener("pagehide",Z),j();for(let s of m.values())s.revert();m.clear(),P(!0),u=null,O.clear(),C.clear(),S={}}}}export{qe as createVisualExperiments,Ve as loadAppManifestRelease};
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a,b}from"./chunk-MAKRT62V.js";import"./chunk-UWHTCMMF.js";import"./chunk-DGMRFL7K.js";import"./chunk-4C4L3JER.js";import"./chunk-IYVJOUO7.js";import"./chunk-CTCK5BUY.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";export{a as validateEntitlementCheck,b as validateResourceCheck};
|
package/dist/chunk-KNZ3WTQ5.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{b as Pn}from"./chunk-QIV2YOVB.js";import{a as bn}from"./chunk-24Z5QET3.js";import{a as Gn,b as jn,c as In,d as Cn,e as Be,f as Yn,h as Xn,i as Zn,j as Kn,k as et}from"./chunk-LQ2XY26R.js";import{a as nt}from"./chunk-45PGU2HW.js";import{a as $n}from"./chunk-W32FI2A2.js";import{a as xn,d as Bn,f as Jn,g as zn,j as Qn,k as _e,l as sn,m as Wn,n as an}from"./chunk-UR2PWRLG.js";import{b as Un}from"./chunk-ZJXQTMBW.js";import{a as vn,d as Mn}from"./chunk-EU4NTVRT.js";import{C as Vn}from"./chunk-YV4HA2DV.js";import{a as ee}from"./chunk-4C4L3JER.js";import{a as ke}from"./chunk-DSPLGTQI.js";function tt(i){let E=new Set,q=new Set,n=null;async function u(o,p){let A=!1;for(;!i.stopped&&i.key===o&&i.client.pendingCommand?.requestId===p;){if(!i.client.settle)throw new ee("COMMAND_PENDING","The original display acknowledgement is still pending");await i.client.settle(p),A=!0,i.client.pendingCommand?.requestId===p&&await new Promise(v=>setTimeout(v,1500))}i.stopped||i.key!==o||(A&&await i.client.get(),!(i.stopped||i.key!==o)&&E.add(o))}function y(o,p){n=p;let A=()=>{n===p&&(n=null),q.delete(o)};return p.then(A,v=>{A(),i.busy||i.fail(v)}),p}function j(o){if(i.reviewing||E.has(o)||q.has(o)||i.stopped)return;q.add(o);let p=async()=>{if(i.reviewing||i.stopped||i.key!==o||E.has(o)){q.delete(o);return}if(i.busy||i.client.pendingCommand){setTimeout(()=>{p()},250);return}let A=(async()=>{if(i.staleRead){if(await i.staleRead,i.stopped||i.key!==o)return;if(i.client.pendingCommand){setTimeout(()=>{p()},250);return}}let v=i.client.view,de=i.expected(),O=de.requestId;try{await i.client.submit({operation:"shown",...de})}catch(k){if(!(k instanceof ee)||k.code!=="CONFLICT"||k.status!==409||i.client.pendingCommand)throw k;await i.client.get();let c=i.client.view;if(i.stopped||i.reviewing||i.key!==o||!c||!v||c.id!==v.id||c.source.versionId!==v.source.versionId||c.nodeId!==de.nodeId||c.visit!==de.visit||c.revision<=de.revision||c.stopped||!c.screen&&(!c.paywall||c.paywall.receiptId!==v.paywall?.receiptId)||!["running","waiting"].includes(c.status)||i.client.pendingCommand)throw k;let _=i.expected();O=_.requestId,await i.client.submit({operation:"shown",..._})}await u(o,O)})();y(o,A)};p()}function R(){if(n)return n;let o=i.client.pendingCommand;if(o?.operation!=="shown")return null;let p=i.key;return q.add(p),y(p,(async()=>{await i.client.retry(),await u(p,o.requestId)})())}return{report:j,settled:R,get inFlight(){return n}}}function it(i){let E={},q=new Map;async function n(u){let y=i.client.view,j=y?.screen,R=j?.customerData.nodes[u.nodeId];if(i.stopped||i.busy||!y||!j||!R)return;if(!["refresh","next","previous","filter","sources_next","sources_previous"].includes(u.action)){let k=i.document,c=k?Vn(k,u.nodeId):null,_=c?.type==="customer_data"?c.data.outputs?.[u.action]:void 0;_&&j.outputs.includes(_)?await i.perform(()=>i.client.submit({operation:"submit",...i.expected(),input:{type:"screen",output:_,answers:i.answers,selection:u.value?{[u.nodeId]:u.value}:{}}})):await i.onIntent?.(u,y);return}let p=u.action.startsWith("sources_")?R.resources.find(k=>k.key===u.value):null;if(u.action.startsWith("sources_")&&!p)throw new ee("INVALID_REQUEST","Choose a current resource");let A=`${y.visit}:${u.nodeId}:${p?.key??""}`,v=q.get(A)??[null],O=E[u.nodeId]??{page:1,after:null,filter:"all",...p?{resourceKey:p.key}:{}};if(u.action==="filter"){let k=u.value;if(!k||!(R.source==="offer_history"?["all","issued","reserved","redeemed","expired","revoked"]:["all","purchase","refund","source","usage","debt","settlement"]).includes(k))throw new ee("INVALID_REQUEST","Unknown data filter");O={page:1,after:null,filter:k},v.splice(0,v.length,null)}else if(u.action==="next"||u.action==="sources_next"){let k=p?.sources.at(-1),c=p?k?{kind:"ledger",cursor:{at:k.detail[0],id:k.id,type:"source"}}:null:j.dataCursors[u.nodeId];if(!c||!p&&!R.hasNext)return;v[O.page]=c,O={...O,page:O.page+1,after:c}}else if(u.action==="previous"||u.action==="sources_previous"){if(O.page<=1)return;O={...O,page:O.page-1,after:v[O.page-2]??null}}q.set(A,v),E={...E,[u.nodeId]:O},await i.perform(()=>i.client.get({nodeId:y.nodeId,visit:y.visit,revision:y.revision,components:E}))}return{get queries(){return E},intent:n,reset(){E={},q.clear()}}}function rt(i){let{doc:E,holder:q,reviewHolder:n,mountScreenPreview:u}=i,y=!1,j,R=0,o=null,p="",A,v=new Map,de=c=>c?`${c.id}:${c.nodeId}:${c.visit}:${c.revision}:${c.paywall?.quote?.operationId??""}`:"";async function O(c){if(i.stopped||!i.client.review||y&&c===j&&A?.active)return;let _=!y||c!==j;y||(p=de(i.client.view),v.set(p,structuredClone(i.answers))),y=!0,j=c,q.hidden=!0,i.suspend(!0),n.hidden=!1;let ve=++R;_&&(A?.finish("dismissed"),o?.destroy(),o=null,n.replaceChildren(),A=sn(n,i.loadingOptions,"funnel",()=>{k()}));let g=_?A:void 0;try{if(g?.start(!1,i.client.view?.locale),ve!==R||i.stopped)return;let Ie=i.client.review(c),V=await(g?.wait(Ie,_e)??Ie);if(i.stopped||ve!==R||!y)return;if(!V.review)throw new ee("INVALID_RESPONSE","Historical projection is missing");o?.destroy(),o=null,g||n.replaceChildren();let l=E.createElement("div"),x=g?an(l,n):()=>{};n.append(l);let F=V.run.locale.startsWith("zh"),ne=i.chrome;l.style.cssText=ne.history;let te=E.createElement("p");te.textContent=F?"只读回看":"Read-only history",te.style.cssText=ne.historyTitle,l.append(te);let me=E.createElement("p");me.style.cssText=ne.historyNote,me.textContent=V.review.pages.length?F?"选择一页查看当时的内容,回看不会改动任何信息。":"Choose a page to see it as it was. Nothing here can be changed.":F?"还没有可回看的页面。":"There are no earlier pages yet.",l.append(me);let Y=V.review.page?.receiptId,B=E.createElement("div");B.style.cssText=ne.historyPages;for(let[w,U]of V.review.pages.entries()){let J=E.createElement("button");J.type="button",J.textContent=F?`第 ${w+1} 页`:`Page ${w+1}`;let ce=Y!==void 0&&U.receiptId===Y;J.style.cssText=ce?ne.primary:ne.secondary,ce&&J.setAttribute("aria-current","page"),Be(J,()=>i.chrome.focus),J.onclick=()=>{O(U.receiptId)},B.append(J)}if(B.childElementCount&&l.append(B),V.review.page){let w=V.review.page,U=E.createElement("div");U.inert=!0,U.style.cssText=ne.historyPage,l.append(U),o=u(U,{mode:"live",rendererUrl:i.client.webViewUrl,title:w.document.name,onAction:()=>{},onAnswers:()=>{},onCustomerDataIntent:()=>{},onRendered:()=>{ve===R&&!i.stopped&&g?.present(x)},onError:ce=>{if(ve!==R||i.stopped)return;let G=new Error(ce);g?.finish("error",G),o?.destroy(),o=null,l.remove(),i.fail(G)},onEscape:()=>{k()}});let J=o;if(J.update(w.document,V.run.locale,{serverInput:{bindings:w.inputs,answers:w.answers,values:w.values}}),await J.ready,i.stopped||ve!==R||!y)return}let T=F?{issued:"已领取",reserved:"已预留",redeemed:"已使用",expired:"已过期",revoked:"已撤销",unknown:"状态待确认"}:{issued:"Issued",reserved:"Reserved",redeemed:"Used",expired:"Expired",revoked:"Revoked",unknown:"Status unconfirmed"},X=E.createElement("div");X.style.cssText=ne.historyRecords;for(let w of[...V.review.coupons.map((U,J)=>`${F?"优惠券":"Coupon"} ${J+1}: ${T[U.status]}`),...V.review.purchases.map((U,J)=>`${F?"购买":"Purchase"} ${J+1}: ${et(U.status,F)}`)]){let U=E.createElement("p");U.textContent=w,U.style.margin="0",X.append(U)}X.childElementCount&&l.append(X),V.review.page||g?.present(x),i.client.view&&await i.enqueue(i.client.view)}catch(Ie){if(ve!==R||i.stopped)return;g?.finish("error",Ie),o?.destroy(),o=null,n.replaceChildren(),i.fail(Ie)}}async function k(){if(!y||i.stopped||!i.client.review)return;let c=++R;A?.finish("dismissed");try{if(await i.client.review(),i.stopped||c!==R)return;y=!1,R++,A?.finish("dismissed"),o?.destroy(),o=null,n.replaceChildren(),n.hidden=!0,q.hidden=!1;let _=i.client.view;de(_)!==p?(v.set(p,structuredClone(i.answers)),i.resetScreen()):(v.delete(p),i.suspend(!1)),_&&await i.enqueue(_)}catch(_){if(c!==R||i.stopped)return;o?.destroy(),o=null,n.replaceChildren(),i.fail(_)}}return{get active(){return y},get receipt(){return j},open:O,exit:k,get drafts(){return new Map([...v].map(([c,_])=>[c,structuredClone(_)]))},stop(){y=!1,R++,A?.finish("dismissed"),o?.destroy(),o=null,n.replaceChildren(),n.hidden=!0,q.hidden=!1}}}var Rn=5e3,ut="position:absolute;width:1px;height:1px;margin:-1px;padding:0;border:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap";async function ct(i,E,q){let n=E,u=n.prepared,y=u&&Pn(u),j=()=>{},R,o;function p(e){for(let t of R?.copies.values()??[])t!==e&&t.destroy();R=void 0}let A;function v(){u&&u.state!=="adopted"&&y?.release()}let de=()=>u?.state==="shown"&&!!y?.modal,O=n.client.identitySignal,k;try{k=await Promise.all([import("./screen-renderer-EWRXGDWQ.js"),import("./paywall-TVYLGNDU.js")]),n.signal?.throwIfAborted(),O?.throwIfAborted()}catch(e){throw v(),e}let[{mountScreenPreview:c},{showPaywall:_}]=k,ve=(typeof INDIANA_NATIVE_SHELL_BUILD>"u"||!INDIANA_NATIVE_SHELL_BUILD)&&n.appManifestRelease?nt({client:n.client,appManifestRelease:n.appManifestRelease,onError:n.onError}):void 0;ve?.start();let g=i.ownerDocument,Ie=Qn(g),V=!1,l=g.createElement("section"),x=g.createElement("div"),F=g.createElement("div"),ne=g.createElement("div"),te=g.createElement("button");ne.hidden=!0,te.type="button";let me=g.createElement("p"),Y=g.createElement("p"),B=g.createElement("button"),T=g.createElement("button"),X=g.createElement("button"),w=g.createElement("dialog"),U,J=!1;l.dataset.indianaFunnel="",l.dataset.longplayCloseOwner="sdk",l.setAttribute("aria-busy","false"),me.setAttribute("role","status"),Y.setAttribute("role","alert"),Y.hidden=!0,B.type=T.type=X.type="button",F.append(B,te,me,Y,X,T),l.append(x,ne,F),i.append(l);let ce=jn,G=In(ce),ln="",we=(g.documentElement.lang||"").startsWith("zh"),ie,dn="",Je,En=!1;for(let e of[B,te,X,T])Be(e,()=>G.focus);function kn(){let e=we?"关闭":"Close";T.parentElement===w?(T.textContent="×",T.setAttribute("aria-label",e),zn(T,ce)):(T.textContent=e,T.removeAttribute("aria-label"),T.style.cssText=G.link+";margin-inline-start:auto")}function ze(e){let t=e?.screen?.content.document.theme??ce,r=JSON.stringify([t.primary,t.background,t.text,t.radius,t.font,T.parentElement===w]);if(r===ln)return;ln=r,ce=t;let C=T.parentElement===w;G=In(ce,C),l.style.cssText=G.root+";min-width:0"+(C?";display:flex;flex-direction:column;min-height:100%":""),F.style.cssText=G.bar+(C?";margin-top:auto":""),F.hidden&&(F.style.display="none"),B.style.cssText=te.style.cssText=G.secondary,X.style.cssText=G.primary,me.style.cssText=G.status,Y.style.cssText=G.alert,kn(),Cn(B)}function Fe(){let e=T.parentElement===w,t=B.hidden&&te.hidden&&X.hidden&&Y.hidden&&(T.hidden||T.parentElement!==F),r=e&&En&&t;F.hidden=t&&!me.textContent,F.style.cssText=G.bar+(e?";margin-top:auto":"")+(r?`;${ut}`:""),F.style.display=F.hidden?"none":"flex",ie?.responsive&&Je!==void 0&&ie.setContentHeight(Je+(r?0:F.getBoundingClientRect().height))}ze();let pe=null,b=null,re=null,Ce="",K="",De=!1,Ge="",un="",Qe="",s=!1,Q=0,We=!1,Fn="",cn=null,pn=Promise.resolve(),Dn=!n.client.view,Ve,fn=!1,D=q,je=n.hostPaywallTarget,Ne,Ue,Ye="",Xe,oe=!1,Te=null,ye=!1,Ze=()=>n.client.pendingCommand?.operation==="close",se=null,H=null,mn=$n({document:g,run:async()=>{(!b?.observing||n.client.pendingCommand)&&await yn()},delay:()=>{if(!ae.pending&&!(s||!re||!["running","waiting"].includes(re.status)&&!n.client.pendingCommand)&&!(b?.observing&&!n.client.pendingCommand))return re.pendingRequest||n.client.pendingCommand?1500:Rn},hiddenDelay:()=>!s&&!ae.pending&&n.client.pendingCommand?15e3:void 0}),M=null;function wn(){return H&&n.client.hasDurableJournal===!0&&M?.acknowledged===!0&&M.operationId===H.operationId&&n.client.view?.id===M.runId&&n.client.view?.status==="closed"&&n.client.view.revision===M.revision+1&&!(n.client.pendingCommands?.length??(n.client.pendingCommand?1:0))&&!n.client.pendingPurchase?H:null}function Tn(e){let t=e.run.paywall;if(M&&e.settlement?.requestId===M.requestId&&e.settlement.state==="settled"&&e.settlement.operationId===null&&e.run.id===M.runId&&e.run.status==="closed"&&!e.run.pendingRequest&&e.run.revision===M.revision+1&&e.run.nodeId===M.nodeId&&e.run.visit===M.visit&&t?.receiptId===M.receiptId&&t.selectionGeneration===M.selectionGeneration&&(t.quote?.operationId??null)===M.operationId&&(t.operation?.operationId??t.quote?.operationId??null)===M.operationId){let r=M.operationId===null&&t.selectionGeneration===0&&!t.quote&&!t.operation&&!t.purchaseRequestId,C=vn({quote:t.quote,operation:t.operation,requestId:t.purchaseRequestId,pending:!1,destroyed:!1,canReselect:t.canReselect});(r||t.canReselect===!0&&C.type==="native")&&(M.acknowledged=!0)}}let Ae=null,Me=new Set,ge={},qe=!1,Z=(e,t=null)=>{s||(e instanceof ee&&e.status===409&&e.reason==="STATE_CHANGED"&&e.recovery==="recover_operation"&&mn.destroy(),Ae=t,qe=!1,Y.textContent=Yn(e,we),Y.hidden=!1,X.hidden=n.client.pendingCommand===null,Fe(),ke(n.onError,e))},ae=Un({client:n.client,document:g,conceal(){s||(he(),D?.finish("dismissed"),l.hidden=!0,V||(V=!0,Ie()))},async receive(e){s||await ue(n.client.view??e.run)},failed(e){if(!s){if(!ae.pending){ye=!1;let t=n.client.view;t&&ue(t).then(()=>Z(e),Z);return}tn(),l.parentElement!==i&&i.append(l),l.hidden=!1,B.hidden=te.hidden=T.hidden=!0,me.textContent="",ze(),Z(e,n.client.pendingCommand?.requestId??null)}}}),An=()=>{s||(Ae=null,Y.textContent=Zn(we),Y.hidden=!1,X.hidden=!0,Fe())};function Se(){let e=n.client.view;if(!e)throw new ee("INVALID_REQUEST","No current Run is available");return{requestId:crypto.randomUUID(),nodeId:e.nodeId,visit:e.visit,revision:e.revision}}let h=rt({client:n.client,doc:g,holder:x,reviewHolder:ne,mountScreenPreview:c,loadingOptions:n,get chrome(){return G},get stopped(){return s},get answers(){return ge},suspend(e){b?.setSuspended(e)},resetScreen(){Ce="",K="",Ge=""},enqueue:ue,fail:Z}),$e=tt({client:n.client,expected:Se,fail:Z,get stopped(){return s},get reviewing(){return h.active},get key(){return Ce},get busy(){return Q},get staleRead(){return cn}}),Ke=it({client:n.client,expected:Se,perform:He,onIntent:n.onCustomerDataIntent,get stopped(){return s},get busy(){return Q},get document(){return pe?.document},get answers(){return ge}}),en=e=>`${e.id}:${e.nodeId}:${e.visit}`,Oe=e=>e&&(e.screen||e.paywall)?en(e):"";function be(){let e=n.client.view;B.disabled=!h.active&&(Q>0||!!n.client.pendingCommand||!e?.canBack||e.stopped||!["running","waiting"].includes(e.status)||!Oe(e)||K!==Oe(e)),B.hidden=!h.active&&!e?.canBack,Cn(B);let t=!!b&&!h.active;T.hidden=t&&!D?.active||J&&!h.active,te.hidden=!n.client.review||!h.active&&!e?.canBack;let r=e?.locale.startsWith("zh");En=!t&&(Q>0||!!e?.pendingRequest),me.textContent=t?"":Q>0||e?.pendingRequest?r?"正在处理":"Processing":e?.instruction?.type==="wait"?r?"等待中":"Waiting":"",Fe()}async function Sn(e){if(!e)return;let t=n.client.view;await e;let r=n.client.view;if(!t||!r||r.id!==t.id||r.nodeId!==t.nodeId||r.visit!==t.visit||r.stopped||!["running","waiting"].includes(r.status))throw new ee("PRECONDITION_FAILED","The screen changed while its display was acknowledged")}async function He(e,t=!1,r){if(!((Q||ye||se||H)&&!t||s||h.active&&!t)){Q++,l.setAttribute("aria-busy","true"),Y.hidden=!0,Ae=null,qe=!1,be();try{if(t||await Sn($e.inFlight),s)return;let C=await e();s||await ue(n.client.view??C.run)}catch(C){r?.(C)&&n.client.pendingCommand===null?An():ae.pending||Z(C,n.client.pendingCommand?.requestId??null)}finally{Q=Math.max(0,Q-1),l.setAttribute("aria-busy",String(Q>0)),s||(X.hidden=n.client.pendingCommand===null,be())}}}function Le(){mn.schedule()}async function yn(){if(!(s||We||Q)&&!ae.pending){if(h.active){await h.open(h.receipt);return}We=!0;try{let e=n.client.pendingCommand;e&&n.client.settle&&await n.client.settle(e.requestId);let t=n.client.view,r=Ke.queries,C=await n.client.get(t?.screen&&Object.keys(r).length?{nodeId:t.nodeId,visit:t.visit,revision:t.revision,components:r}:void 0);qe&&!s&&(qe=!1,Y.hidden=!0,Fe()),!s&&r===Ke.queries&&await ue(n.client.view??C.run)}catch(e){Z(e),qe=!s}finally{We=!1}}}function nn(e,t,r){if(D?.active){let le=D;return le.setDismissHandler(()=>On(le)),le}let C=sn(i,n,"funnel",()=>On(C),Gn);return D=C,C.start(e,t,r),C}function On(e){s||oe||(oe=!0,e.finish("dismissed"),he(),l.hidden=!0,n.client.view?Pe().finally(z):z())}function gn(){clearTimeout(Xe?.timeout),Xe=void 0}function he(e){J=!1,gn(),Ne?.abort(),Ne=void 0,pe?.destroy(),pe=null,b?.destroy(),b=null,Ve=void 0,Ue?.(),Ue=void 0,w.open&&w.close();for(let t of Array.from(x.children))(!e||!t.contains(e))&&t.remove();x.style.cssText="",Je=void 0,Ce="",K="",De=!1,Ge="",Qe=""}function Nn(){let e=g.defaultView;ie?.responsive&&e&&pe?.resizeViewport?.(e.innerHeight,e.innerWidth)}function tn(){ie?.destroy(),ie=void 0,dn=""}function rn(e){let t=e.screen?.presentation;if(!t||t.type==="inline"){w.open&&w.close(),tn(),T.parentElement!==F&&F.append(T),l.parentElement!==i&&i.append(l);for(let le of["flex","display","flex-direction","justify-content"])x.style.removeProperty(le);ze(e),Fe();return}l.parentElement!==w&&(w.append(T,l),i.append(w)),x.style.flex="1 0 auto",x.style.display="flex",x.style.flexDirection="column",x.style.justifyContent="center",ze(e);let r=e.screen.content.document,C=JSON.stringify([t,ln]);C!==dn&&(tn(),dn=C,w.style.cssText=xn("funnel",t,ce),ie=Bn(w,{presentation:t,theme:r.theme,pages:r.pages},Nn),ie.latch()),Fe(),w.setAttribute("aria-label",(U?.screen===e.screen?.content.document.name?U?.label:void 0)??pe?.document?.name??e.screen?.content.document.name??"Funnel")}async function ot(e){if(s||oe)return;if(ae.observe(),ae.pending){re=e;return}if(ye&&(Ze()||["running","waiting"].includes(e.status))||(re=e,Ae&&n.client.pendingCommand?.requestId!==Ae&&(Y.hidden=!0,Ae=null),we=e.locale.startsWith("zh"),te.textContent=we?"回看":"History",B.textContent=h.active?we?"返回当前":"Return to current":we?"返回":"Back",kn(),X.textContent=we?"重试":"Retry",X.hidden=n.client.pendingCommand===null,be(),Fn!==`${e.revision}:${e.visit}:${e.status}:${e.stopped}`&&(Fn=`${e.revision}:${e.visit}:${e.status}:${e.stopped}`,ke(n.onState,structuredClone(e))),s||oe))return;if((!e.pendingRequest||ye&&e.status==="closed")&&["closed","ineligible","failed"].includes(e.status)){z();return}if(e.stopped&&de()){z();return}if(e.stopped||n.client.configurationReady===!1){h.stop(),v(),he(),D?.finish("skipped"),l.hidden=!0,Le();return}if(l.hidden=!1,h.active){Le();return}if(e.status==="completed"&&b?.subscriptionUpgradeActive){Le();return}let t=Oe(e),r=n.client.view;if(r&&r.revision>e.revision&&Oe(r)!==t)return;let C=!e.instruction&&!e.pendingRequest&&e.nodeType==="screen"&&["running","waiting"].includes(e.status);t!==Ce&&(Ce&&D?.finish("dismissed"),he(),Ce=t,ge={...e.answers},Ke.reset());let le=en(e);if(Ye===le){l.hidden=!0;return}if(C&&!t){l.hidden=!0;let P=u?.state==="shown"?null:nn(!0,e.locale);!s&&!oe&&Xe?.key!==le&&(gn(),Xe={key:le,timeout:setTimeout(()=>{let a=n.client.view;if(s||!P?.active&&u?.state!=="shown"||!a||en(a)!==le)return;Ye=le;let S=new Error("Funnel screen preparation timed out");P?.finish("error",S),v(),he(),Z(S)},_e)}),Le();return}gn();let $=P=>{let a=n.client.view;return!s&&!oe&&!Te&&!P.aborted&&n.client.configurationReady!==!1&&!!a&&!a.stopped&&!["closed","ineligible","failed"].includes(a.status)&&(Oe(a)===t||a.status==="completed"&&b?.subscriptionUpgradeActive===!0)},Ee=(P,a)=>{$(a)&&(Ye=t,D?.finish("error",P),he(),l.hidden=!0,Z(P))};if(t||((e.instruction&&e.instruction.type!=="evaluate_segment"||!["running","waiting"].includes(e.status))&&v(),rn(e),e.instruction?.type!=="event"&&e.instruction?.type!=="open_url"&&D?.finish("skipped")),e.screen){if(fn=!0,je=void 0,v(),n.prepareNextPaywall&&R?.key!==t){p();let L=new Map;for(let[I,N]of Object.entries(e.screen.nextPaywalls??{})){if(!e.screen.outputs.includes(I))continue;let f=n.prepareNextPaywall({run:e,paywallVersionId:N.paywallVersionId});f&&L.set(I,f)}R={key:t,copies:L}}let P=e.screen.content;if(!pe){let L=e.screen.presentation.type!=="inline",I=nn(L,e.locale);if(s||oe)return;let N=(Ne=new AbortController).signal;rn(e),Ue=L?Wn(w):an(l,i),pe=c(x,{mode:"live",closeActions:Array.from(new Set([...n.closeActions??[],...P.document.actions.filter(f=>f.type==="event"&&f.close).map(f=>f.id)])),onAuthoredClose(f){$(N)&&(J=f,be())},rendererUrl:n.client.webViewUrl,title:P.document.name,...L?{hostPresentation:()=>ie?.type??e.screen.presentation.type}:{},onResize:f=>{Je=f,ie?.responsive&&ie.setContentHeight(f+F.getBoundingClientRect().height)},onAction(f,d={},fe={}){if(h.active||!$(N)||K!==t)return;ge={...ge,...fe};let hn=e.screen?.inputs??[],_n=Object.fromEntries(hn.filter(({variable:Re})=>Object.hasOwn(ge,Re)).map(({variable:Re})=>[Re,ge[Re]]));if(Kn(hn,_n).length){An();return}let xe=!Q&&R?.key===t?R.copies.get(f):void 0;xe?.state==="ready"&&xe.open()==="shown"&&(p(xe),v(),j(),u=xe,y=Pn(xe),j=y?.onClose(Hn)??(()=>{}),o=t),He(()=>n.client.submit({operation:"submit",...Se(),input:{type:"screen",output:f,answers:_n,selection:d}}),!1,Re=>Xn(Re,hn)).finally(()=>{let Re=n.client.view;o===t&&(!Re||Oe(Re)===t)&&(o=void 0,v())})},onAnswers:f=>{h.active||!$(N)||K!==t||(ge={...ge,...f})},onCustomerDataIntent:f=>{h.active||!$(N)||K!==t||Ke.intent(f).catch(Z)},onEscape:()=>{!$(N)||K!==t||h.active||se||H||Pe()},onError:f=>{let d=new Error(f);K===t?Z(d):Ee(d,N)},onRendered:f=>{if(!(!$(N)||K===t))try{I.present(d=>{Ue?.(),Ue=void 0,f&&(U={screen:P.document.name,label:f},w.setAttribute("aria-label",f)),L&&(w.showModal(),V=!1,ie?.responsive&&w.focus({preventScroll:!0}),!d&&n.loading!=="host"&&Jn(w,ie?.type??e.screen.presentation.type,ie?.responsive)),K=t,De=L,be()}),$(N)&&$e.report(t)}catch(d){Ee(d,N)}}}),Nn()}let a={capabilities:e.screen.capabilities,customerData:e.screen.customerData,parameters:e.parameters,serverInput:{bindings:e.screen.inputs,answers:ge,values:e.screen.values}},S=JSON.stringify([P,e.locale,a.parameters,e.screen.inputs,e.screen.values]);if(S!==Ge)pe.update(P.document,e.locale,a),Ge=S,un=JSON.stringify(a.capabilities),Qe=JSON.stringify(a.customerData);else{let L=JSON.stringify(a.capabilities);L!==un&&(pe.updateCapabilities(a.capabilities),un=L),JSON.stringify(a.customerData)!==Qe&&(pe.updateCustomerData(a.customerData),Qe=JSON.stringify(a.customerData))}let W=pe;if(W)try{await(D?.wait(W.ready)??W.ready)}catch(L){Ne&&Ee(L,Ne.signal)}}else if(e.paywall&&!b){fn=!0,p();let P=e.paywall.resolution,a="document"in P?P.document:null,S=y,W=n.mountPaywallControls,L=null,I=(Ne=new AbortController).signal,N={loading:"host",signal:I,...W&&{mountControls:d=>W(d,e)},canInteract:()=>$(I)&&!h.active&&!se&&!H,beforeAction:async()=>{Q++;try{await Sn($e.settled()),Y.hidden=!0,Ae=null,qe=!1,Fe()}finally{Q=Math.max(0,Q-1)}},start:async()=>{let d=await bn(n.client),fe=A;return A=void 0,d.view&&fe?.(d.view),d},onObservationChange:Le,onPurchase:n.onPurchase,onCheckoutUrl:n.onCheckoutUrl,resumeCheckout:n.resumeCheckout,allowNewPurchase:n.allowNewPurchase,checkoutNavigation:n.checkoutNavigation,terminateCheckout:n.terminateCheckout,beforeCheckoutReplacement:n.beforeCheckoutReplacement,purchaseConfirmation:n.purchaseConfirmation,confirmOnHostedCheckout:n.confirmOnHostedCheckout,resolveOfferId:n.resolveOfferId,prepareSubscriptionChange:n.prepareSubscriptionChange,resolveSubscriptionChange:n.resolveSubscriptionChange,claimCoupon:n.claimCoupon,onEvent:n.onEvent,onOpenUrl:d=>n.onOpenUrl?n.onOpenUrl({receiptId:e.paywall.receiptId,url:d,openIn:"same_window"}):g.defaultView?.location.assign(d),onAction:async d=>{if(h.active)return;let fe=await n.client.submit({operation:"submit",requestId:crypto.randomUUID(),nodeId:e.nodeId,visit:e.visit,revision:n.client.view?.revision??e.revision,input:{type:"screen",output:d,answers:{}}});await ue(n.client.view??fe.run)},onError:d=>{K===t?Z(d):Ee(d,I)}},f={quoteError:d=>ke(n.onError,d),present(d){$(I)&&(L?.present(fe=>{d(fe),K=t,De=f.retainedDialog?.dialog.open??!!x.querySelector("dialog[open]"),De&&(V=!1),be()}),$(I)&&$e.report(t))},async closeAction(d){s||h.active||await ae.submit({operation:"submit",requestId:crypto.randomUUID(),nodeId:e.nodeId,visit:e.visit,revision:n.client.view?.revision??e.revision,input:{type:"screen",output:d,answers:{}}})},async dismiss(){if(s||I.aborted||h.active||se||H||!ye&&!$(I))return;ye=!0;let d=n.client.view;if(d?.status==="completed"&&b?.subscriptionUpgradeActive){Me.add(`complete:${d.id}`),ke(n.onComplete,structuredClone(d)),z();return}if((n.resumeCheckout||n.terminateCheckout)&&dt()){re=n.client.view,z();return}await Pe()}};if(S&&W)v();else if(S){let d=await S.adopt(e,{options:N,handoff:f,start:()=>bn(n.client)});o=void 0,d&&$(I)&&!s?(rn(e),b=d,Ve={runId:e.id,receiptId:e.paywall.receiptId},D?.active&&D.present(()=>{}),K=t,De=S.modal,De&&(V=!1),be(),$e.report(t),h.active&&b.setSuspended(!0)):(d?.destroy(),v(),A=fe=>y?.remember(fe))}if(s||oe)return;if(!b){if(L=nn(!0,e.locale,a),s||oe)return;(typeof INDIANA_NATIVE_SHELL_BUILD>"u"||!INDIANA_NATIVE_SHELL_BUILD)&&n.loading==="host"&&je?.ownerDocument===g&&(f.hostPaywallTarget=je),je=void 0,rn(e);let d=await _(x,N,f).catch(fe=>(Ee(fe,I),null));!$(I)&&!(ye&&!s&&!I.aborted)?d?.host?.destroy():d&&(b=d.host,b&&(Ve={runId:e.id,receiptId:e.paywall.receiptId}),b?.setSuspended(h.active))}}if(s||oe)return;be();let m=e.instruction;if(m&&(m.type==="open_url"||m.type==="event")&&!Me.has(m.receiptId)){let P=g.createElement("button");P.type="button",P.style.cssText=G.primary,Be(P,()=>G.focus),x.style.cssText=G.stage,P.textContent=m.type==="open_url"?`${we?"前往":"Continue to"} ${new URL(m.url).host}`:we?"继续":"Continue",P.onclick=()=>{let a=Se(),S=m.type==="open_url"&&!n.onOpenUrl&&m.openIn==="new_window"?st(m.url):null;He(async()=>{let W="success";if(m.type==="open_url")if(n.onOpenUrl)try{W=await n.onOpenUrl({receiptId:m.receiptId,url:m.url,openIn:m.openIn})===!1?"failed":"opened"}catch(I){ke(n.onError,I),W="failed"}else W=m.openIn==="new_window"&&!S?"failed":"opened";if(m.type==="event"){if(!n.onEvent)throw new ee("EVENT_HANDLER_REQUIRED","Provide the event handler");await n.onEvent(m.event)}if(s||n.client.view?.nodeId!==a.nodeId||n.client.view.visit!==a.visit)throw new ee("PRECONDITION_FAILED","The client action visit changed");let L=await n.client.submit({operation:"submit",...a,input:{type:"client_action",receiptId:m.receiptId,outcome:W}});return Me.add(m.receiptId),m.type==="open_url"&&!n.onOpenUrl&&m.openIn==="same_window"&&g.defaultView?.location.assign(m.url),L})},D?.active?D.present(()=>x.replaceChildren(P)):x.replaceChildren(P)}!e.pendingRequest&&e.status==="completed"&&!Me.has(`complete:${e.id}`)&&(Me.add(`complete:${e.id}`),ke(n.onComplete,structuredClone(e))),Le()}function st(e){let t=g.defaultView?.open(e,"_blank")??null;return t&&(t.opener=null),t}function ue(e){return be(),pn=pn.catch(()=>{}).then(async()=>{try{await ot(e)}catch(t){throw D?.active&&(Ye=en(e),D.finish("error",t),he(),l.hidden=!0),t}}),pn}let at=n.client.subscribe(e=>{if(!Dn){if(e.stopped&&(De||de())&&!ye){re=e,z();return}!ye&&(e.stopped||n.client.configurationReady===!1||Ce&&K!==Ce&&(Oe(e)!==Ce||["closed","ineligible","failed"].includes(e.status)))&&(he(),D?.finish("dismissed"),l.hidden=!0),ue(e).catch(Z)}}),lt=n.client.subscribeError?.(e=>{ae.pending||Z(e)});function dt(){let e=n.client.view,t=e?.paywall;return!!t?.operation&&!!e&&["running","waiting"].includes(e.status)&&Mn(vn({quote:t.quote,operation:t.operation,requestId:t.purchaseRequestId,pending:!1,destroyed:!1,canReselect:t.canReselect}))}function Pe(e){if(Te)return Te;if(s||!e&&(se||H))return Promise.resolve();let t=!e&&Ze();return!t&&n.client.view&&!["running","waiting"].includes(n.client.view.status)?(re=n.client.view,z(),Promise.resolve()):(Te=He(async()=>{let r=t?await n.client.retry():await(e?n.client.submit.bind(n.client):ae.submit)({operation:"close",...e??Se()});return e&&Tn(r),r},!0).then(()=>{let r=n.client.view;r?.status==="closed"&&!Ze()&&(re=r,z())}).finally(()=>{Te=null}),Te)}function z(){qn()}function qn(e){ve?.destroy(),!s&&(s=!0,ae.destroy(),j(),p(),!fn&&(re?.status==="ineligible"||re?.status==="completed")&&y?.withhold(),v(),n.signal?.removeEventListener("abort",z),O?.removeEventListener("abort",z),D?.finish("dismissed"),mn.destroy(),at(),lt?.(),he(e),tn(),h.stop(),w.remove(),!e||!l.contains(e)?l.remove():(F.remove(),ne.remove()),!e&&!V&&Ie(),ke(n.onDismiss,re?structuredClone(re):null))}B.onclick=()=>{if(!B.disabled){if(h.active){h.exit();return}He(()=>n.client.submit({operation:"back",...Se()}))}},te.onclick=()=>{h.open()},T.onclick=()=>{D?.active?D.dismiss():se||Pe()},X.onclick=()=>{ae.pending?ae.retry().catch(()=>{}):Ze()?Pe():He(()=>n.client.retry())},w.addEventListener("cancel",e=>{e.preventDefault(),D?.active?D.dismiss():se||Pe()}),n.signal?.addEventListener("abort",z,{once:!0}),O?.addEventListener("abort",z,{once:!0});let on=!1;function Hn(){s||oe||(oe=!0,D?.finish("dismissed"),he(),l.hidden=!0,n.client.view?Pe().finally(z):on=!0)}y&&(j=y.onClose(Hn));let Ln={destroy:z,refresh:yn,get recoveryPaywall(){if(b&&Ve)return{...Ve,view:b.currentResolution}},setPurchaseRecovery(e,t){return b?.setPurchaseRecovery(e,t),b!==null},retainPurchaseDialog(){let e=b?.retainPurchaseDialog();if(e)return b=null,qn(e.dialog),{dialog:e.dialog,release(){e.release(),l.remove(),V||Ie()}}},get recovery(){let e=wn();if(e)return e;if(!s&&!Q&&!ye&&!se&&b){let t=b.recovery;if(t.type!=="native")return t}return{type:"recover",operationId:n.client.pendingPurchase?.operationId??n.client.view?.paywall?.quote?.operationId??H?.operationId??null,requestId:n.client.pendingCommand?.requestId??null}},prepareFallback(){if(se)return se;let e=wn();if(e)return Promise.resolve(e);let t=n.client.pendingPurchase?.operationId??n.client.view?.paywall?.quote?.operationId??H?.operationId??null,r=()=>({type:"recover",operationId:t,requestId:n.client.pendingCommand?.requestId??null});if(n.client.hasDurableJournal!==!0){let m=b?.recovery;return Promise.resolve(m&&m.type!=="native"&&m.type!=="cancel"?m:r())}let C=(n.client.pendingCommands??(n.client.pendingCommand?[n.client.pendingCommand]:[])).some(m=>m.operation==="close");if(s&&!(C||H&&n.client.view?.status==="closed")||Q||We||Te||h.active||!b&&!H&&!C)return Promise.resolve(r());let le=b,$=(async()=>{try{if(!H&&C){let a=await n.client.retry();return await ue(n.client.view??a.run),r()}if(!H){let a=await le.prepareFallback();if(a.type!=="native")return a;if(n.client.hasDurableJournal!==!0)return r();H=a}let m=n.client.pendingCommands??(n.client.pendingCommand?[n.client.pendingCommand]:[]);if(m.length){let a=m.find(W=>W.operation==="close");if(!a||!M||a.requestId!==M.requestId)return r();let S=await n.client.retry();Tn(S),await ue(n.client.view??S.run)}else{let a=n.client.view,S=a?.paywall;if(!a||!S||S.selectionGeneration===void 0||(S.quote?.operationId??null)!==H.operationId||H.operationId!==null&&S.canReselect!==!0)return r();let W=S.selectionGeneration,L=await n.client.get();await ue(n.client.view??L.run);let I=n.client.view,N=I?.paywall;if(!I||!N||!["running","waiting"].includes(I.status)||I.stopped||I.id!==a.id||I.nodeId!==a.nodeId||I.visit!==a.visit||N.receiptId!==S.receiptId||N.selectionGeneration!==W||(N.quote?.operationId??null)!==H.operationId||H.operationId!==null&&N.canReselect!==!0||n.client.pendingPurchase||(n.client.pendingCommands?.length??(n.client.pendingCommand?1:0)))return r();let f=Se();M={runId:I.id,operationId:H.operationId,revision:f.revision,requestId:f.requestId,nodeId:I.nodeId,visit:I.visit,receiptId:N.receiptId,selectionGeneration:W,acknowledged:!1},await Pe(f)}let P=wn();return P?(z(),P):r()}catch(m){return Z(m),r()}})();se=$;let Ee=()=>{se===$&&(se=null)};return $.then(Ee,Ee),$},review:h.open,exitReview:h.exit,get unappliedDrafts(){return h.drafts}};try{let e=n.client.view;if(e)((n.client.viewAgeMs??Rn)>=Rn||e.instruction?.type==="evaluate_segment")&&(cn=yn().finally(()=>{cn=null})),await ue(e);else{if(l.hidden=!0,s)throw new DOMException("Presentation cancelled","AbortError");let t=on||u?.state==="shown"?null:nn(n.client.view?.screen?.presentation.type!=="inline",n.client.view?.locale);if(s||oe&&!on)throw new DOMException("Presentation cancelled","AbortError");let r=n.client.get(),C=await(t?t.wait(r,_e):pt(r,_e));if(Dn=!1,on)return s||await Pe().finally(z),Ln;await ue(n.client.view??C.run)}}catch(e){throw D?.finish("error",e),z(),e}return Ln}function pt(i,E){let q;return Promise.race([i,new Promise((n,u)=>{q=setTimeout(()=>u(new Error("Presentation data timed out")),E)})]).finally(()=>clearTimeout(q))}function xt(i,E,q){return ct(i,E,q)}export{ct as a,xt as b};
|
package/dist/chunk-TFGIDUGW.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{o as n,r as t}from"./chunk-UOJSZMKN.js";function u(o,e,a){return n(o,e,a,t)}export{u as a};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a,b,c,d}from"./chunk-QIV2YOVB.js";import"./chunk-Q5DB34R4.js";import"./chunk-ZVVDPXHC.js";import"./chunk-RZ7WFYWY.js";import"./chunk-ONYG4VQI.js";import"./chunk-LHUZRVAC.js";import"./chunk-5M2IIZB6.js";import"./chunk-AFQHUBKJ.js";import"./chunk-VILB5M4X.js";import"./chunk-DJTMSBQN.js";import"./chunk-YV4HA2DV.js";import"./chunk-UWHTCMMF.js";import"./chunk-DGMRFL7K.js";import"./chunk-TLQUUC3G.js";import"./chunk-4C4L3JER.js";import"./chunk-IYVJOUO7.js";import"./chunk-CTCK5BUY.js";import"./chunk-DSPLGTQI.js";import"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";export{a as PRERENDER_MAX_AGE_MS,b as preparedInternals,c as prerenderFunnelPurchase,d as prerenderRunPaywall};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a,b,c}from"./chunk-Q5DB34R4.js";import"./chunk-ZVVDPXHC.js";import"./chunk-5M2IIZB6.js";import"./chunk-AFQHUBKJ.js";import"./chunk-VILB5M4X.js";import"./chunk-TLQUUC3G.js";import"./chunk-CTCK5BUY.js";import"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";export{a as predictFunnelStart,c as predictedPaywallLoadingDocument,b as predictionRefusal};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as e,b as o,c as n}from"./chunk-ZVVDPXHC.js";import"./chunk-5M2IIZB6.js";import"./chunk-AFQHUBKJ.js";import"./chunk-VILB5M4X.js";import"./chunk-TLQUUC3G.js";import"./chunk-CTCK5BUY.js";import"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";export{e as FUNNEL_ROUTE_LIMITS,o as funnelRouteSchema,n as projectFunnelRoute};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a,b}from"./chunk-KNZ3WTQ5.js";import"./chunk-QIV2YOVB.js";import"./chunk-24Z5QET3.js";import"./chunk-LQ2XY26R.js";import"./chunk-Q5DB34R4.js";import"./chunk-ZVVDPXHC.js";import"./chunk-45PGU2HW.js";import"./chunk-AEQUKR4O.js";import"./chunk-W32FI2A2.js";import"./chunk-UR2PWRLG.js";import"./chunk-ZJXQTMBW.js";import"./chunk-EU4NTVRT.js";import"./chunk-RZ7WFYWY.js";import"./chunk-44SX4C3G.js";import"./chunk-MUW3SOTB.js";import"./chunk-ONYG4VQI.js";import"./chunk-LHUZRVAC.js";import"./chunk-5M2IIZB6.js";import"./chunk-AFQHUBKJ.js";import"./chunk-VILB5M4X.js";import"./chunk-TDMXEI2U.js";import"./chunk-DJTMSBQN.js";import"./chunk-TNWZWEEY.js";import"./chunk-YV4HA2DV.js";import"./chunk-UWHTCMMF.js";import"./chunk-DGMRFL7K.js";import"./chunk-TLQUUC3G.js";import"./chunk-4C4L3JER.js";import"./chunk-IYVJOUO7.js";import"./chunk-SLUA7ABW.js";import"./chunk-MB2U2GWJ.js";import"./chunk-6A4NV4ET.js";import"./chunk-5MRSFLQA.js";import"./chunk-CTCK5BUY.js";import"./chunk-DSPLGTQI.js";import"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";export{a as showFunnelRun,b as showObservedFunnelRun};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{P as r,Q as m,j as e}from"./chunk-LHUZRVAC.js";import"./chunk-DJTMSBQN.js";import"./chunk-DGMRFL7K.js";import"./chunk-IYVJOUO7.js";import"./chunk-CTCK5BUY.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";export{m as merchantBridgeCommerceSchema,r as merchantBridgeOperationSchema,e as merchantOperationLookupSchema};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{e as o}from"./chunk-6ZUJCHBI.js";import"./chunk-NCMKY7D6.js";import"./chunk-ZFNSXRQY.js";import"./chunk-EPQUD3S5.js";import"./chunk-PYM47Z55.js";import"./chunk-44SX4C3G.js";import"./chunk-MUW3SOTB.js";import"./chunk-ONYG4VQI.js";import"./chunk-LHUZRVAC.js";import"./chunk-AFQHUBKJ.js";import"./chunk-VILB5M4X.js";import"./chunk-TYIAPLQP.js";import"./chunk-DJTMSBQN.js";import"./chunk-TNWZWEEY.js";import"./chunk-YV4HA2DV.js";import"./chunk-UWHTCMMF.js";import"./chunk-DGMRFL7K.js";import"./chunk-TLQUUC3G.js";import"./chunk-IYVJOUO7.js";import"./chunk-CTCK5BUY.js";import"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";export{o as apiOperations};
|
package/dist/paywall-TVYLGNDU.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a}from"./chunk-4XDMBMDA.js";import"./chunk-LQ2XY26R.js";import"./chunk-W32FI2A2.js";import"./chunk-UR2PWRLG.js";import"./chunk-EU4NTVRT.js";import"./chunk-RZ7WFYWY.js";import"./chunk-MUW3SOTB.js";import"./chunk-ONYG4VQI.js";import"./chunk-LHUZRVAC.js";import"./chunk-VILB5M4X.js";import"./chunk-TDMXEI2U.js";import"./chunk-DJTMSBQN.js";import"./chunk-TNWZWEEY.js";import"./chunk-YV4HA2DV.js";import"./chunk-UWHTCMMF.js";import"./chunk-DGMRFL7K.js";import"./chunk-TLQUUC3G.js";import"./chunk-4C4L3JER.js";import"./chunk-IYVJOUO7.js";import"./chunk-6A4NV4ET.js";import"./chunk-5MRSFLQA.js";import"./chunk-CTCK5BUY.js";import"./chunk-DSPLGTQI.js";import"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";export{a as showPaywall};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{b as a}from"./chunk-ULJJTIL5.js";import"./chunk-EPQUD3S5.js";import"./chunk-PYM47Z55.js";import"./chunk-44SX4C3G.js";import"./chunk-MUW3SOTB.js";import"./chunk-ONYG4VQI.js";import"./chunk-LHUZRVAC.js";import"./chunk-AFQHUBKJ.js";import"./chunk-VILB5M4X.js";import"./chunk-TDMXEI2U.js";import"./chunk-DJTMSBQN.js";import"./chunk-TNWZWEEY.js";import"./chunk-YV4HA2DV.js";import"./chunk-UWHTCMMF.js";import"./chunk-DGMRFL7K.js";import"./chunk-TLQUUC3G.js";import"./chunk-4C4L3JER.js";import"./chunk-IYVJOUO7.js";import"./chunk-3VUPVXAV.js";import"./chunk-6A4NV4ET.js";import"./chunk-5MRSFLQA.js";import"./chunk-CTCK5BUY.js";import"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";export{a as readPaywallContent};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a}from"./chunk-IXYVLURA.js";import"./chunk-6ZUJCHBI.js";import"./chunk-NCMKY7D6.js";import"./chunk-F46VXI3Q.js";import"./chunk-EU4NTVRT.js";import"./chunk-RZ7WFYWY.js";import"./chunk-ZFNSXRQY.js";import"./chunk-MAKRT62V.js";import"./chunk-ULJJTIL5.js";import"./chunk-EPQUD3S5.js";import"./chunk-PYM47Z55.js";import"./chunk-44SX4C3G.js";import"./chunk-MUW3SOTB.js";import"./chunk-ONYG4VQI.js";import"./chunk-LHUZRVAC.js";import"./chunk-AFQHUBKJ.js";import"./chunk-VILB5M4X.js";import"./chunk-TYIAPLQP.js";import"./chunk-TDMXEI2U.js";import"./chunk-DJTMSBQN.js";import"./chunk-TNWZWEEY.js";import"./chunk-YV4HA2DV.js";import"./chunk-UWHTCMMF.js";import"./chunk-DGMRFL7K.js";import"./chunk-TLQUUC3G.js";import"./chunk-4C4L3JER.js";import"./chunk-IYVJOUO7.js";import"./chunk-3VUPVXAV.js";import"./chunk-6A4NV4ET.js";import"./chunk-5MRSFLQA.js";import"./chunk-CTCK5BUY.js";import"./chunk-DSPLGTQI.js";import"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";export{a as createPaywallSession};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a,b,c,d,e,f,g,h,i}from"./chunk-BZRDECZJ.js";import"./chunk-UR2PWRLG.js";import"./chunk-TNWZWEEY.js";import"./chunk-YV4HA2DV.js";import"./chunk-UWHTCMMF.js";import"./chunk-DGMRFL7K.js";import"./chunk-TLQUUC3G.js";import"./chunk-4C4L3JER.js";import"./chunk-IYVJOUO7.js";import"./chunk-CTCK5BUY.js";import"./chunk-DSPLGTQI.js";import"./chunk-VPT5MFDG.js";import"./chunk-CILM5XMH.js";import"./chunk-WOT6VMZA.js";export{f as formatCustomerDecimal,b as hostedRendererScript,a as hostedRendererShell,d as inspectCustomHtml,i as mountScreenPreview,h as preparePopup,e as prepareScreen,c as sanitizeCustomHtml,g as showPopup};
|
|
File without changes
|
|
File without changes
|