@picked/client 0.0.1-dev.1777594341273 → 0.0.1-dev.1777601813342

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.
Files changed (77) hide show
  1. package/dist/{api-DWa-ZqA4.cjs → api-BAOO2VZv.cjs} +1 -1
  2. package/dist/{api-DtOVNMSX.js → api-CiR56vZg.js} +1 -1
  3. package/dist/cjs/form/index.js +1 -1
  4. package/dist/cjs/index.js +2 -2
  5. package/dist/cjs/plugins/dynamic-experiences/index.js +1 -1
  6. package/dist/cjs/plugins/experience-browser-storage/index.js +1 -1
  7. package/dist/cjs/plugins/history-browser-storage/index.js +1 -1
  8. package/dist/cjs/plugins/responses-browser-storage/index.js +1 -1
  9. package/dist/cjs/plugins/responses-indexeddb/index.js +1 -1
  10. package/dist/cjs/plugins/single-page-app/index.js +1 -1
  11. package/dist/cjs/plugins/web-components/index.js +1 -1
  12. package/dist/cjs/plugins/window-object/index.js +1 -1
  13. package/dist/cjs/server/index.js +1 -1
  14. package/dist/docs/{actions.md → actions.mdx} +7 -0
  15. package/dist/docs/{api-keys.md → api-keys.mdx} +7 -0
  16. package/dist/docs/{conditions.md → conditions.mdx} +7 -0
  17. package/dist/docs/{experiences.md → experiences.mdx} +7 -0
  18. package/dist/docs/{features.md → features.mdx} +7 -0
  19. package/dist/docs/{fields.md → fields.mdx} +7 -0
  20. package/dist/docs/flow-builder/{overview.md → overview.mdx} +7 -0
  21. package/dist/docs/pickedql/data-sources.md +49 -2
  22. package/dist/docs/pickedql/dimensions.md +40 -0
  23. package/dist/docs/pickedql/examples.md +41 -1
  24. package/dist/docs/pickedql/filtering.md +22 -0
  25. package/dist/docs/pickedql/index.md +2 -1
  26. package/dist/docs/pickedql/schema.md +34 -1
  27. package/dist/docs/pickedql/virtual-functions.md +67 -11
  28. package/dist/docs/{projects.md → projects.mdx} +7 -0
  29. package/dist/docs/{reports.md → reports.mdx} +7 -0
  30. package/dist/docs/{steps.md → steps.mdx} +7 -0
  31. package/dist/docs/{workspaces.md → workspaces.mdx} +8 -0
  32. package/dist/esm/form/index.js +21 -6
  33. package/dist/esm/index.js +174 -174
  34. package/dist/esm/plugins/dynamic-experiences/index.js +1 -1
  35. package/dist/esm/plugins/experience-browser-storage/index.js +20 -18
  36. package/dist/esm/plugins/history-browser-storage/index.js +17 -15
  37. package/dist/esm/plugins/responses-browser-storage/index.js +21 -19
  38. package/dist/esm/plugins/responses-indexeddb/index.js +37 -35
  39. package/dist/esm/plugins/single-page-app/index.js +88 -42
  40. package/dist/esm/plugins/web-components/index.js +2 -2
  41. package/dist/esm/plugins/window-object/index.js +1 -1
  42. package/dist/esm/server/index.js +1 -1
  43. package/dist/{experience-CNIhapU2.js → experience-CR19HpPg.js} +2 -2
  44. package/dist/{experience-CTEBY-it.cjs → experience-DOWnsvA1.cjs} +1 -1
  45. package/dist/experience-instance-C2jZU8ho.cjs +1 -0
  46. package/dist/{experience-instance-B0tFPMAU.js → experience-instance-CGLdwg--.js} +12 -8
  47. package/dist/{nodes-2fst8XKi.js → nodes-Bmzx3TP_.js} +7 -7
  48. package/dist/{nodes-DBK4N9YY.cjs → nodes-Dx9bxj35.cjs} +1 -1
  49. package/dist/{rules-logic-D7dL30U1.js → rules-logic-CvILqbhz.js} +8 -5
  50. package/dist/{rules-logic-DJhGFqhC.cjs → rules-logic-DV5SUr5M.cjs} +1 -1
  51. package/dist/supports-DFDQ6eJO.cjs +1 -0
  52. package/dist/{supports-B_trw6lj.js → supports-DUJbucFW.js} +18 -9
  53. package/dist/types/entities/action/action.d.ts +30 -4
  54. package/dist/types/entities/action/action.d.ts.map +1 -1
  55. package/dist/types/entities/experience-instance/experience-instance.d.ts +4 -2
  56. package/dist/types/entities/experience-instance/experience-instance.d.ts.map +1 -1
  57. package/dist/types/entities/framework/framework.d.ts +12 -2
  58. package/dist/types/entities/framework/framework.d.ts.map +1 -1
  59. package/dist/types/entities/response/response-validation.d.ts +17 -17
  60. package/dist/types/entities/response/response-validation.d.ts.map +1 -1
  61. package/dist/types/form/create-field-evaluator.d.ts.map +1 -1
  62. package/dist/types/form/create-submit-pipeline.d.ts.map +1 -1
  63. package/dist/types/picked.d.ts +3 -1
  64. package/dist/types/picked.d.ts.map +1 -1
  65. package/dist/types/plugins/experience-browser-storage/plugin.d.ts.map +1 -1
  66. package/dist/types/plugins/history-browser-storage/plugin.d.ts.map +1 -1
  67. package/dist/types/plugins/responses-browser-storage/plugin.d.ts.map +1 -1
  68. package/dist/types/plugins/responses-indexeddb/plugin.d.ts.map +1 -1
  69. package/dist/types/plugins/single-page-app/plugin.d.ts +64 -12
  70. package/dist/types/plugins/single-page-app/plugin.d.ts.map +1 -1
  71. package/dist/types/utils/global-obj.d.ts +5 -0
  72. package/dist/types/utils/global-obj.d.ts.map +1 -1
  73. package/dist/types/utils/supports.d.ts +113 -0
  74. package/dist/types/utils/supports.d.ts.map +1 -1
  75. package/package.json +1 -1
  76. package/dist/experience-instance-BN0RZG1b.cjs +0 -1
  77. package/dist/supports-CKSVYpQx.cjs +0 -1
@@ -1 +1 @@
1
- function e(e){return typeof e==`number`&&!isNaN(e)}function t(e){return typeof e==`string`}function n(e){return Array.isArray(e)}function r(e){return e instanceof Promise}function i(e){return typeof e==`object`&&!!e&&!Array.isArray(e)&&Object.keys(e).length===1}function a(t){if(e(t))return t;let n=parseFloat(`${t}`);return isNaN(n)?0:n}function o(e){return`${e}`}var s={"==":(e,t)=>e==t,"===":(e,t)=>e===t,"!=":(e,t)=>e!=t,"!==":(e,t)=>e!==t,">":(e,t)=>a(e)>a(t),">=":(e,t)=>a(e)>=a(t),"<":(e,t,n)=>{let r=a(e),i=a(t);if(n===void 0)return r<i;let o=a(n);return r<i&&i<o},"<=":(e,t,n)=>{let r=a(e),i=a(t);if(n===void 0)return r<=i;let o=a(n);return r<=i&&i<=o},"!!":async e=>await l(e),"!":async e=>!await l(e),"%":(e,t)=>a(e)%a(t),log:e=>(console.log(e),e),in:(e,r)=>r?t(r)?r.indexOf(o(e))!==-1:n(r)?r.includes(e):!1:!1,cat:(...e)=>e.map(o).join(``),substr:(e,t,n)=>{let r=o(e),i=a(t);if(n===void 0)return r.substr(i);let s=a(n);if(s<0){let e=r.substr(i);return e.substr(0,e.length+s)}return r.substr(i,s)},"+":(...e)=>e.reduce((e,t)=>a(e)+a(t),0),"*":(...e)=>e.reduce((e,t)=>a(e)*a(t),1),"-":(e,t)=>{let n=a(e);return t===void 0?-n:n-a(t)},"/":(e,t)=>a(e)/a(t),min:(...e)=>Math.min(...e.map(a)),max:(...e)=>Math.max(...e.map(a)),merge:(...e)=>e.reduce((e,t)=>n(t)?e.concat(t):e.concat([t]),[]),var(e,t){let n=arguments.length>1?t:null;if(e===``||e===`.`||e==null)return this;if(typeof e==`number`&&Array.isArray(this))return e>=0&&e<this.length?this[e]:n;let r=o(e);if(r===``||r===`.`)return this;let i=r.split(`.`),a=this;for(let e of i){if(a==null)return n;if(Array.isArray(a)){let t=parseInt(e,10);a=isNaN(t)?a[e]:a[t]}else a=a[e]}return a===void 0?n:a},async missing(...e){let t=n(e[0])?e[0]:e,r=[];for(let e of t){let t=await c({var:e},this);(t===null||t===``)&&r.push(`${e}`)}return r},async missing_some(e,r){let i=await c({missing:r},this);if(!n(i)||!n(r))return[];let o=i.filter(t);return r.filter(t).length-o.length>=a(e)?[]:o},invoke(...e){let[t,...n]=e;return typeof t==`function`?Reflect.apply(t,null,n):null},startsWith:(e,n)=>t(e)&&t(n)&&e.startsWith(n),endsWith:(e,n)=>t(e)&&t(n)&&e.endsWith(n),regexp_matches(e,r){let i=e,a=``;if(n(e)){let[t,n]=e;i=t,a=n}return!t(i)||!t(a)?!1:new RegExp(i,a).test(o(r))},throw(e){throw Error(o(e))}};async function c(e,t){if(!e)return e;if(r(e))return c(await e,t);if(n(e))return Promise.all(e.map(e=>c(e,t)));if(!i(e))return e;let a=u(e),o=a?e[a]??[]:[];switch(n(o)||(o=[o]),a){case`if`:case`?:`:for(let e=0;e<o.length-1;e+=2)if(await l(await c(o[e],t)))return c(o[e+1],t);return o.length%2==1?c(o[o.length-1],t):null;case`and`:{let e=null;for(let n of o)if(e=await c(n,t),!await l(e))return e;return e}case`or`:{let e=null;for(let n of o)if(e=await c(n,t),await l(e))return e;return e}case`map`:{let e=await c(o[0],t);return n(e)?await Promise.all(e.map(e=>c(o[1],e))):[]}case`filter`:{let e=await c(o[0],t);return n(e)?(await Promise.all(e.map(async e=>({item:e,shouldInclude:await l(await c(o[1],e))})))).filter(({shouldInclude:e})=>e).map(({item:e})=>e):[]}case`reduce`:{let e=await c(o[0],t);if(!n(e))return o.length>2?await c(o[2],t):null;let r=o[1],i=o.length>2?await c(o[2],t):null;for(let t of e)i=await c(r,{current:t,accumulator:i});return i}case`all`:{let e=await c(o[0],t);if(!n(e)||e.length===0)return!1;for(let t of e)if(!await l(await c(o[1],t)))return!1;return!0}case`some`:{let e=await c(o[0],t);if(!n(e))return!1;for(let t of e)if(await l(await c(o[1],t)))return!0;return!1}case`none`:{let e=await c(o[0],t);if(!n(e))return!0;for(let t of e)if(await l(await c(o[1],t)))return!1;return!0}case`catch`:try{return await c(o[0],t)}catch(e){return i(e)?await c(e,t):o[1]?await c(o[1],e):e instanceof Error?e.message:e}}let d=await Promise.all(o.map(e=>c(e,t))),f=a?s[a]:void 0;if(!f)throw Error(`Unrecognized operation ${a}`);return f.apply(t,d)}async function l(e){return r(e)?l(await e):!(Array.isArray(e)&&e.length===0)&&!!e}function u(e){return Object.keys(e)[0]}function d(e,t,n){if(!(t in e))return;let r=e[t];if(typeof r!=`function`)throw Error(`Expected '${String(t)}' to be a function`);let i=n(r);p(i,r),e[t]=i}function f(e,t,n){Object.defineProperty(e,t,{enumerable:!1,value:n,writable:!0,configurable:!0})}function p(e,t){let n=t.prototype||{};t.prototype=n,e.prototype=n,f(e,`__picked_original`,t)}function m(e){return e===void 0||typeof e==`object`&&!!e&&e.constructor===Object&&Object.keys(e).length===0}function h(e){return!m(e)}async function g(e,t,n){let r=e.getStateSnapshot(),i=e.predicates.listStore.getState().reduce((e,t)=>({...e,[t.name]:(...e)=>t.predicate({...r,args:e})}),{}),a=e.actions.listStore.getState().reduce((e,t)=>({...e,[t.key]:(...e)=>t.action({...r,args:e})}),{}),o=e.features.listStore.getState().reduce((e,t)=>({...e,[t.id]:async()=>{let{bucket:e}=await t.getBucket();return e}}),{});return await c(t,{responses:e.responses.getAllStore.getState(),location:typeof r.location==`object`?{hash:r.location.hash,host:r.location.host,hostname:r.location.hostname,href:r.location.href,origin:r.location.origin,pathname:r.location.pathname,port:r.location.port,protocol:r.location.protocol,search:r.location.search}:void 0,predicates:i,actions:a,features:o,...n})}Object.defineProperty(exports,`i`,{enumerable:!0,get:function(){return d}}),Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return h}}),Object.defineProperty(exports,`r`,{enumerable:!0,get:function(){return m}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return g}});
1
+ function e(e){return typeof e==`number`&&!isNaN(e)}function t(e){return typeof e==`string`}function n(e){return Array.isArray(e)}function r(e){return e instanceof Promise}function i(e){return typeof e==`object`&&!!e&&!Array.isArray(e)&&Object.keys(e).length===1}function a(t){if(e(t))return t;let n=parseFloat(`${t}`);return isNaN(n)?0:n}function o(e){return`${e}`}var s={"==":(e,t)=>e==t,"===":(e,t)=>e===t,"!=":(e,t)=>e!=t,"!==":(e,t)=>e!==t,">":(e,t)=>a(e)>a(t),">=":(e,t)=>a(e)>=a(t),"<":(e,t,n)=>{let r=a(e),i=a(t);if(n===void 0)return r<i;let o=a(n);return r<i&&i<o},"<=":(e,t,n)=>{let r=a(e),i=a(t);if(n===void 0)return r<=i;let o=a(n);return r<=i&&i<=o},"!!":async e=>await l(e),"!":async e=>!await l(e),"%":(e,t)=>a(e)%a(t),log:e=>(console.log(e),e),in:(e,r)=>r?t(r)?r.indexOf(o(e))!==-1:n(r)?r.includes(e):!1:!1,cat:(...e)=>e.map(o).join(``),substr:(e,t,n)=>{let r=o(e),i=a(t);if(n===void 0)return r.substr(i);let s=a(n);if(s<0){let e=r.substr(i);return e.substr(0,e.length+s)}return r.substr(i,s)},"+":(...e)=>e.reduce((e,t)=>a(e)+a(t),0),"*":(...e)=>e.reduce((e,t)=>a(e)*a(t),1),"-":(e,t)=>{let n=a(e);return t===void 0?-n:n-a(t)},"/":(e,t)=>a(e)/a(t),min:(...e)=>Math.min(...e.map(a)),max:(...e)=>Math.max(...e.map(a)),merge:(...e)=>e.reduce((e,t)=>n(t)?e.concat(t):e.concat([t]),[]),var(e,t){let n=arguments.length>1?t:null;if(e===``||e===`.`||e==null)return this;if(typeof e==`number`&&Array.isArray(this))return e>=0&&e<this.length?this[e]:n;let r=o(e);if(r===``||r===`.`)return this;let i=r.split(`.`),a=this;for(let e of i){if(a==null)return n;if(Array.isArray(a)){let t=parseInt(e,10);a=isNaN(t)?a[e]:a[t]}else a=a[e]}return a===void 0?n:a},async missing(...e){let t=n(e[0])?e[0]:e,r=[];for(let e of t){let t=await c({var:e},this);(t===null||t===``)&&r.push(`${e}`)}return r},async missing_some(e,r){let i=await c({missing:r},this);if(!n(i)||!n(r))return[];let o=i.filter(t);return r.filter(t).length-o.length>=a(e)?[]:o},invoke(...e){let[t,...n]=e;return typeof t==`function`?Reflect.apply(t,null,n):null},startsWith:(e,n)=>t(e)&&t(n)&&e.startsWith(n),endsWith:(e,n)=>t(e)&&t(n)&&e.endsWith(n),regexp_matches(e,r){let i=e,a=``;if(n(e)){let[t,n]=e;i=t,a=n}return!t(i)||!t(a)?!1:new RegExp(i,a).test(o(r))},throw(e){throw Error(o(e))}};async function c(e,t){if(!e)return e;if(r(e))return c(await e,t);if(n(e))return Promise.all(e.map(e=>c(e,t)));if(!i(e))return e;let a=u(e),o=a?e[a]??[]:[];switch(n(o)||(o=[o]),a){case`if`:case`?:`:for(let e=0;e<o.length-1;e+=2)if(await l(await c(o[e],t)))return c(o[e+1],t);return o.length%2==1?c(o[o.length-1],t):null;case`and`:{let e=null;for(let n of o)if(e=await c(n,t),!await l(e))return e;return e}case`or`:{let e=null;for(let n of o)if(e=await c(n,t),await l(e))return e;return e}case`map`:{let e=await c(o[0],t);return n(e)?await Promise.all(e.map(e=>c(o[1],e))):[]}case`filter`:{let e=await c(o[0],t);return n(e)?(await Promise.all(e.map(async e=>({item:e,shouldInclude:await l(await c(o[1],e))})))).filter(({shouldInclude:e})=>e).map(({item:e})=>e):[]}case`reduce`:{let e=await c(o[0],t);if(!n(e))return o.length>2?await c(o[2],t):null;let r=o[1],i=o.length>2?await c(o[2],t):null;for(let t of e)i=await c(r,{current:t,accumulator:i});return i}case`all`:{let e=await c(o[0],t);if(!n(e)||e.length===0)return!1;for(let t of e)if(!await l(await c(o[1],t)))return!1;return!0}case`some`:{let e=await c(o[0],t);if(!n(e))return!1;for(let t of e)if(await l(await c(o[1],t)))return!0;return!1}case`none`:{let e=await c(o[0],t);if(!n(e))return!0;for(let t of e)if(await l(await c(o[1],t)))return!1;return!0}case`catch`:try{return await c(o[0],t)}catch(e){return i(e)?await c(e,t):o[1]?await c(o[1],e):e instanceof Error?e.message:e}}let d=await Promise.all(o.map(e=>c(e,t))),f=a?s[a]:void 0;if(!f)throw Error(`Unrecognized operation ${a}`);return f.apply(t,d)}async function l(e){return r(e)?l(await e):!(Array.isArray(e)&&e.length===0)&&!!e}function u(e){return Object.keys(e)[0]}function d(e,t,n){if(!(t in e))return;let r=e[t];if(typeof r!=`function`)throw Error(`Expected '${String(t)}' to be a function`);let i=n(r);p(i,r),e[t]=i}function f(e,t,n){Object.defineProperty(e,t,{enumerable:!1,value:n,writable:!0,configurable:!0})}function p(e,t){let n=t.prototype||{};t.prototype=n,e.prototype=n,f(e,`__picked_original`,t)}function m(e){return typeof e==`function`&&`__picked_original`in e}function h(e){return e===void 0||typeof e==`object`&&!!e&&e.constructor===Object&&Object.keys(e).length===0}function g(e){return!h(e)}async function _(e,t,n){let r=e.getStateSnapshot(),i=e.predicates.listStore.getState().reduce((e,t)=>({...e,[t.name]:(...e)=>t.predicate({...r,args:e})}),{}),a=e.actions.listStore.getState().reduce((e,t)=>({...e,[t.key]:(...e)=>t.action({...r,args:e},null)}),{}),o=e.features.listStore.getState().reduce((e,t)=>({...e,[t.id]:async()=>{let{bucket:e}=await t.getBucket();return e}}),{});return await c(t,{responses:e.responses.getAllStore.getState(),location:typeof r.location==`object`?{hash:r.location.hash,host:r.location.host,hostname:r.location.hostname,href:r.location.href,origin:r.location.origin,pathname:r.location.pathname,port:r.location.port,protocol:r.location.protocol,search:r.location.search}:void 0,predicates:i,actions:a,features:o,...n})}Object.defineProperty(exports,`a`,{enumerable:!0,get:function(){return d}}),Object.defineProperty(exports,`i`,{enumerable:!0,get:function(){return m}}),Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return g}}),Object.defineProperty(exports,`r`,{enumerable:!0,get:function(){return h}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return _}});
@@ -0,0 +1 @@
1
+ var e=Symbol(`Picked`),t=globalThis,n=n=>{t[e]=n};function r(){try{return`location`in t&&!!t.location}catch{return!1}}function i(){try{return`history`in t&&!!t.history}catch{return!1}}function a(){try{if(!(`navigation`in t))return!1;let e=t.navigation;return!!e&&typeof e?.addEventListener==`function`}catch{return!1}}function o(){try{return`localStorage`in t&&!!t.localStorage}catch{return!1}}function s(){try{return`sessionStorage`in t&&!!t.sessionStorage}catch{return!1}}function c(){try{return`document`in t&&`cookie`in t.document}catch{return!1}}function l(){try{return`document`in t&&`createElement`in t.document&&`attachShadow`in t.document.createElement(`div`)}catch{return!1}}function u(){try{return`window`in t}catch{return!1}}function d(){try{return`document`in t}catch{return!1}}function f(){try{return`IntersectionObserver`in t}catch{return!1}}function p(){try{return`customElements`in t&&!!t.customElements}catch{return!1}}function m(){try{return`crypto`in t&&`randomUUID`in t.crypto}catch{return!1}}Object.defineProperty(exports,`a`,{enumerable:!0,get:function(){return f}}),Object.defineProperty(exports,`c`,{enumerable:!0,get:function(){return a}}),Object.defineProperty(exports,`d`,{enumerable:!0,get:function(){return p}}),Object.defineProperty(exports,`f`,{enumerable:!0,get:function(){return u}}),Object.defineProperty(exports,`i`,{enumerable:!0,get:function(){return i}}),Object.defineProperty(exports,`l`,{enumerable:!0,get:function(){return s}}),Object.defineProperty(exports,`m`,{enumerable:!0,get:function(){return n}}),Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return m}}),Object.defineProperty(exports,`o`,{enumerable:!0,get:function(){return o}}),Object.defineProperty(exports,`p`,{enumerable:!0,get:function(){return t}}),Object.defineProperty(exports,`r`,{enumerable:!0,get:function(){return d}}),Object.defineProperty(exports,`s`,{enumerable:!0,get:function(){return r}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return c}}),Object.defineProperty(exports,`u`,{enumerable:!0,get:function(){return l}});
@@ -20,61 +20,70 @@ function i() {
20
20
  }
21
21
  function a() {
22
22
  try {
23
- return "localStorage" in t && !!t.localStorage;
23
+ if (!("navigation" in t)) return !1;
24
+ let e = t.navigation;
25
+ return !!e && typeof e?.addEventListener == "function";
24
26
  } catch {
25
27
  return !1;
26
28
  }
27
29
  }
28
30
  function o() {
29
31
  try {
30
- return "sessionStorage" in t && !!t.sessionStorage;
32
+ return "localStorage" in t && !!t.localStorage;
31
33
  } catch {
32
34
  return !1;
33
35
  }
34
36
  }
35
37
  function s() {
36
38
  try {
37
- return "document" in t && "cookie" in t.document;
39
+ return "sessionStorage" in t && !!t.sessionStorage;
38
40
  } catch {
39
41
  return !1;
40
42
  }
41
43
  }
42
44
  function c() {
43
45
  try {
44
- return "document" in t && "createElement" in t.document && "attachShadow" in t.document.createElement("div");
46
+ return "document" in t && "cookie" in t.document;
45
47
  } catch {
46
48
  return !1;
47
49
  }
48
50
  }
49
51
  function l() {
50
52
  try {
51
- return "window" in t;
53
+ return "document" in t && "createElement" in t.document && "attachShadow" in t.document.createElement("div");
52
54
  } catch {
53
55
  return !1;
54
56
  }
55
57
  }
56
58
  function u() {
57
59
  try {
58
- return "document" in t;
60
+ return "window" in t;
59
61
  } catch {
60
62
  return !1;
61
63
  }
62
64
  }
63
65
  function d() {
64
66
  try {
65
- return "IntersectionObserver" in t;
67
+ return "document" in t;
66
68
  } catch {
67
69
  return !1;
68
70
  }
69
71
  }
70
72
  function f() {
71
73
  try {
72
- return "customElements" in t && !!t.customElements;
74
+ return "IntersectionObserver" in t;
73
75
  } catch {
74
76
  return !1;
75
77
  }
76
78
  }
77
79
  function p() {
80
+ try {
81
+ return "customElements" in t && !!t.customElements;
82
+ } catch {
83
+ return !1;
84
+ }
85
+ }
86
+ function m() {
78
87
  try {
79
88
  return "crypto" in t && "randomUUID" in t.crypto;
80
89
  } catch {
@@ -82,4 +91,4 @@ function p() {
82
91
  }
83
92
  }
84
93
  //#endregion
85
- export { d as a, o as c, l as d, t as f, i, c as l, p as n, a as o, n as p, u as r, r as s, s as t, f as u };
94
+ export { f as a, a as c, p as d, u as f, i, s as l, n as m, m as n, o, t as p, d as r, r as s, c as t, l as u };
@@ -1,13 +1,37 @@
1
1
  import { Store } from 'effector';
2
2
  import { StateSnapshot } from '../../utils/state-snaphot';
3
3
  import { Picked } from '../../picked';
4
+ import { ExperienceInstance } from '../experience-instance/experience-instance';
4
5
  /**
5
- * A named callable function that receives a state snapshot and optional arguments.
6
- * Actions can return values (boolean, string, string[]) or execute side effects (void).
6
+ * Context supplied by the experience-flow runtime when an ActionNode triggers the action.
7
+ * `null` for every other invocation path (see {@link Action}).
8
+ */
9
+ export interface ActionContext {
10
+ /** The experience instance whose ActionNode triggered this action. */
11
+ experience: ExperienceInstance;
12
+ }
13
+ /**
14
+ * A named callable function that receives a state snapshot, action args, and a context.
15
+ *
16
+ * `context` is an {@link ActionContext} only when the action is executed as an
17
+ * ActionNode in an experience flow. It is `null` for every other invocation path,
18
+ * including `getEvokableAction` and actions referenced from rule logic (condition
19
+ * rules, `initializeOpenLogic`, launch decisions, feature gates, field
20
+ * validation/visibility). Rule-logic paths evaluate the action against a snapshot
21
+ * only and have no triggering instance.
22
+ *
23
+ * Re-entrancy: do not synchronously call navigation events (`goToNextStep`,
24
+ * `goToPreviousStep`, `goToStepById`) or open-state events (`open`, `close`,
25
+ * `toggleOpen`, `setOpen`) on `context.experience` before the handler's returned
26
+ * promise resolves. Those writes race the flow runtime's post-action history
27
+ * push and produce non-deterministic ordering. Perform control flow after your
28
+ * side effect resolves.
29
+ *
30
+ * Returns a value (boolean, string, string[]) or runs a side effect (void).
7
31
  */
8
32
  export type Action = (snapshot: StateSnapshot & {
9
33
  args: unknown[];
10
- }) => boolean | Promise<boolean> | string | Promise<string> | string[] | Promise<string[]> | void | Promise<void> | undefined;
34
+ }, context: ActionContext | null) => boolean | Promise<boolean> | string | Promise<string> | string[] | Promise<string[]> | void | Promise<void> | undefined;
11
35
  export type ActionsStore = ReturnType<typeof createActionIndexFactory>;
12
36
  export interface ActionIndexItem {
13
37
  key: string;
@@ -19,7 +43,9 @@ declare const createActionIndexFactory: ({ client }: {
19
43
  register: (key: string, action: Action) => void;
20
44
  getByKey: (key: string) => Store<Action | undefined>;
21
45
  listStore: Store<ActionIndexItem[]>;
22
- getEvokableAction: (actionKey: string) => Store<() => ReturnType<Action>>;
46
+ getEvokableAction: (actionKey: string, options?: {
47
+ experience: ExperienceInstance;
48
+ }) => Store<() => ReturnType<Action>>;
23
49
  };
24
50
  /**
25
51
  * Creates an action index with lifecycle stores and registration logic.
@@ -1 +1 @@
1
- {"version":3,"file":"action.d.ts","sourceRoot":"","sources":["../../../../src/entities/action/action.ts"],"names":[],"mappings":"AAAA,uFAAuF;AACvF,OAAO,EAA8D,KAAK,KAAK,EAAE,MAAM,UAAU,CAAA;AAGjG,OAAO,EAAuB,KAAK,aAAa,EAAE,MAAM,2BAA2B,CAAA;AACnF,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AAE1C;;;GAGG;AACH,MAAM,MAAM,MAAM,GAAG,CACnB,QAAQ,EAAE,aAAa,GAAG;IAAE,IAAI,EAAE,OAAO,EAAE,CAAA;CAAE,KAE3C,OAAO,GACP,OAA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,kBAAkB,CAAA;CAC/B;AAED;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,MAAM,MAAM,GAAG,CACnB,QAAQ,EAAE,aAAa,GAAG;IAAE,IAAI,EAAE,OAAO,EAAE,CAAA;CAAE,EAC7C,OAAO,EAAE,aAAa,GAAG,IAAI,KAE3B,OAAO,GACP,OAAO,CAAC,OAAO,CAAC,GAChB,MAAM,GACN,OAAO,CAAC,MAAM,CAAC,GACf,MAAM,EAAE,GACR,OAAO,CAAC,MAAM,EAAE,CAAC,GACjB,IAAI,GACJ,OAAO,CAAC,IAAI,CAAC,GACb,SAAS,CAAA;AAEb,MAAM,MAAM,YAAY,GAAG,UAAU,CAAC,OAAO,wBAAwB,CAAC,CAAA;AAEtE,MAAM,WAAW,eAAe;IAC9B,GAAG,EAAE,MAAM,CAAA;IACX,MAAM,EAAE,MAAM,CAAA;CACf;AAKD,QAAA,MAAM,wBAAwB,eAA8B;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE;oBA+BrD,MAAM,UAAU,MAAM,KAAG,IAAI;oBA2B7B,MAAM;;mCA2BhB,MAAM,YACP;QAAE,UAAU,EAAE,kBAAkB,CAAA;KAAE,KAC3C,KAAK,CAAC,MAAM,UAAU,CAAC,MAAM,CAAC,CAAC;CAyClC,CAAA;AAEF;;;;;;;;;;GAUG;AACH,wBAAgB,iBAAiB,CAAC,CAAC,SAAS,UAAU,CAAC,OAAO,wBAAwB,CAAC,CAAC,CAAC,CAAC,EACxF,MAAM,EAAE,CAAC,GACR,UAAU,CAAC,OAAO,wBAAwB,CAAC,CAE7C;AAED;;;;;;;;;;GAUG;AACH,eAAO,MAAM,WAAW,GAAI,KAAK,MAAM,EAAE,QAAQ,MAAM,EAAE,SAAS,YAAY,KAAG,IAEhF,CAAA"}
@@ -42,7 +42,8 @@ declare const createExperienceInstanceFactory: ({ client, experience, target, op
42
42
  /**
43
43
  * Creates an experience instance with lifecycle stores and navigation logic.
44
44
  *
45
- * @param params - Factory parameters including the client and experience store.
45
+ * @param {Parameters<typeof createExperienceInstanceFactory>[0]} params - Factory parameters including the client and experience store.
46
+ * @returns {ExperienceInstance} The created experience instance.
46
47
  * @example
47
48
  * ```typescript
48
49
  * const instance = createExperienceInstance({ client, experience })
@@ -60,7 +61,8 @@ declare const createExperienceInstanceIndexFactory: ({ client }: {
60
61
  /**
61
62
  * Creates an index that tracks all experience instances keyed by experience ID.
62
63
  *
63
- * @param params - Factory parameters including the client.
64
+ * @param {Parameters<typeof createExperienceInstanceIndexFactory>[0]} params - Factory parameters including the client.
65
+ * @returns {ExperienceInstanceIndex} The created experience-instance index.
64
66
  * @example
65
67
  * ```typescript
66
68
  * const index = createExperienceInstanceIndex({ client })
@@ -1 +1 @@
1
- {"version":3,"file":"experience-instance.d.ts","sourceRoot":"","sources":["../../../../src/entities/experience-instance/experience-instance.ts"],"names":[],"mappings":"AAAA,yFAAyF;AACzF,OAAO,EAOL,KAAK,aAAa,EAGlB,KAAK,KAAK,EACX,MAAM,UAAU,CAAA;AAEjB,OAAO,KAAK,EACV,UAAU,EACV,cAAc,EACd,eAAe,EACf,gBAAgB,EAChB,uBAAuB,EACxB,MAAM,0BAA0B,CAAA;AACjC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAA;AAClD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AAiB1C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAA;AAItD,MAAM,WAAW,kBAAkB;IACjC,EAAE,EAAE,MAAM,CAAA;IACV,aAAa,EAAE,UAAU,CAAC,KAAK,CAAC,CAAA;IAChC,YAAY,EAAE,UAAU,CAAC,IAAI,CAAC,CAAA;IAC9B,WAAW,EAAE,eAAe,CAAC,aAAa,CAAC,CAAA;IAC3C,MAAM,EAAE,WAAW,GAAG,SAAS,CAAA;IAC/B,cAAc,EAAE,eAAe,CAAC,gBAAgB,CAAC,CAAA;IACjD,UAAU,EAAE,KAAK,CAAC,eAAe,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uBAAuB,CAAA;CAClC,iCAgdF,CAAA;AAED;;;;;;;;GAQG;AACH,wBAAgB,wBAAwB,CACtC,CAAC,SAAS,UAAU,CAAC,OAAO,+BAA+B,CAAC,CAAC,CAAC,CAAC,EAC/D,MAAM,EAAE,CAAC,GAAG,UAAU,CAAC,OAAO,+BAA+B,CAAC,CAE/D;AAED,QAAA,MAAM,oCAAoC,eAA8B;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE;wBAoL1E,eAAe,UACnB,WAAW,YACT,uBAAuB;8BAkBF,UAAU,CAAC,KAAK,CAAC;4BAgBnB,UAAU,CAAC,IAAI,CAAC;;CAU/C,CAAA;AAEF;;;;;;;;GAQG;AACH,wBAAgB,6BAA6B,CAC3C,CAAC,SAAS,UAAU,CAAC,OAAO,oCAAoC,CAAC,CAAC,CAAC,CAAC,EACpE,MAAM,EAAE,CAAC,GAAG,UAAU,CAAC,OAAO,oCAAoC,CAAC,CAEpE"}
1
+ {"version":3,"file":"experience-instance.d.ts","sourceRoot":"","sources":["../../../../src/entities/experience-instance/experience-instance.ts"],"names":[],"mappings":"AAAA,yFAAyF;AACzF,OAAO,EAOL,KAAK,aAAa,EAGlB,KAAK,KAAK,EACX,MAAM,UAAU,CAAA;AAEjB,OAAO,KAAK,EACV,UAAU,EACV,cAAc,EACd,eAAe,EACf,gBAAgB,EAChB,uBAAuB,EACxB,MAAM,0BAA0B,CAAA;AACjC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAA;AAClD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AAiB1C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAA;AAItD,MAAM,WAAW,kBAAkB;IACjC,EAAE,EAAE,MAAM,CAAA;IACV,aAAa,EAAE,UAAU,CAAC,KAAK,CAAC,CAAA;IAChC,YAAY,EAAE,UAAU,CAAC,IAAI,CAAC,CAAA;IAC9B,WAAW,EAAE,eAAe,CAAC,aAAa,CAAC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M,+BAA+B,6CAMhC;IACD,MAAM,EAAE,MAAM,CAAA;IACd,UAAU,EAAE,eAAe,CAAA;IAC3B,MAAM,CAAC,EAAE,WAAW,CAAA;IACpB,OAAO,CAAC,EAAE,uBAAuB,CAAA;CAClC,iCAgdF,CAAA;AAED;;;;;;;;;GASG;AACH,wBAAgB,wBAAwB,CACtC,CAAC,SAAS,UAAU,CAAC,OAAO,+BAA+B,CAAC,CAAC,CAAC,CAAC,EAC/D,MAAM,EAAE,CAAC,GAAG,UAAU,CAAC,OAAO,+BAA+B,CAAC,CAE/D;AAED,QAAA,MAAM,oCAAoC,eAA8B;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE;wBA2L1E,eAAe,UACnB,WAAW,YACT,uBAAuB;8BAmBF,UAAU,CAAC,KAAK,CAAC;4BAiBnB,UAAU,CAAC,IAAI,CAAC;;CAU/C,CAAA;AAEF;;;;;;;;;GASG;AACH,wBAAgB,6BAA6B,CAC3C,CAAC,SAAS,UAAU,CAAC,OAAO,oCAAoC,CAAC,CAAC,CAAC,CAAC,EACpE,MAAM,EAAE,CAAC,GAAG,UAAU,CAAC,OAAO,oCAAoC,CAAC,CAEpE"}
@@ -5,7 +5,7 @@ export type FrameworksStore = ReturnType<typeof createFrameworkIndex>;
5
5
  export interface Framework {
6
6
  name: string;
7
7
  render: FrameworkRender;
8
- unRender?: FrameworkUnRender;
8
+ unRender: FrameworkUnRender;
9
9
  }
10
10
  declare const createFrameworkIndexFactory: ({ client }: {
11
11
  client: Picked;
@@ -14,9 +14,19 @@ declare const createFrameworkIndexFactory: ({ client }: {
14
14
  getByName: (name: string) => import('effector').Store<Framework | undefined>;
15
15
  listStore: import('effector').Store<Framework[]>;
16
16
  };
17
+ /**
18
+ * Creates the framework registry store and its register/getByName API for the
19
+ * given Picked client.
20
+ *
21
+ * @template T
22
+ * @param {T} params - Factory parameters; carries the parent Picked client.
23
+ * @returns {ReturnType<typeof createFrameworkIndexFactory>} The framework index store and its API.
24
+ * @example
25
+ * const frameworks = createFrameworkIndex({ client })
26
+ */
17
27
  export declare function createFrameworkIndex<T extends Parameters<typeof createFrameworkIndexFactory>[0]>(params: T): ReturnType<typeof createFrameworkIndexFactory>;
18
28
  export type FrameworkRender = (shadowRoot: ShadowRoot, component: AdaptedComponent, client: Picked, experience: ExperienceInstance) => void;
19
- export type FrameworkUnRender = (shadowRoot: ShadowRoot) => void;
29
+ export type FrameworkUnRender = (shadowRoot: ShadowRoot) => void | Promise<void>;
20
30
  export declare const setupFramework: (framework: Framework, frameworks: FrameworksStore) => void;
21
31
  export {};
22
32
  //# sourceMappingURL=framework.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"framework.d.ts","sourceRoot":"","sources":["../../../../src/entities/framework/framework.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AAC1C,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAA;AAC9D,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,4CAA4C,CAAA;AAEpF,MAAM,MAAM,eAAe,GAAG,UAAU,CAAC,OAAO,oBAAoB,CAAC,CAAA;AAIrE,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,MAAM,CAAA;IACZ,MAAM,EAAE,eAAe,CAAA;IACvB,QAAQ,CAAC,EAAE,iBAAiB,CAAA;CAC7B;AAGD,QAAA,MAAM,2BAA2B,eAA8B;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE;qBAcvD,MAAM,aAAa,SAAS,KAAG,IAAI;sBAiBlC,MAAM;;CAS/B,CAAA;AAEF,wBAAgB,oBAAoB,CAAC,CAAC,SAAS,UAAU,CAAC,OAAO,2BAA2B,CAAC,CAAC,CAAC,CAAC,EAC9F,MAAM,EAAE,CAAC,GACR,UAAU,CAAC,OAAO,2BAA2B,CAAC,CAEhD;AAED,MAAM,MAAM,eAAe,GAAG,CAC5B,UAAU,EAAE,UAAU,EACtB,SAAS,EAAE,gBAAg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IAAI,CAAC,CAAA;AAEhF,eAAO,MAAM,cAAc,GAAI,WAAW,SAAS,EAAE,YAAY,eAAe,KAAG,IAElF,CAAA"}
@@ -11,9 +11,9 @@ type RuleEvaluator = (logic: LogicRule, context?: LogicObject) => Promise<unknow
11
11
  /**
12
12
  * Resolves a field from an array by id or key.
13
13
  *
14
- * @param inputKey - The field id or key to look up.
15
- * @param allFields - All registered fields.
16
- * @returns The matching field, or null if not found.
14
+ * @param {string} inputKey - The field id or key to look up.
15
+ * @param {Field[]} allFields - All registered fields.
16
+ * @returns {Field | null} The matching field, or null if not found.
17
17
  * @example
18
18
  * ```typescript
19
19
  * resolveField('email', allFields) // Field | null
@@ -23,9 +23,9 @@ export declare function resolveField(inputKey: string, allFields: Field[]): Fiel
23
23
  /**
24
24
  * Coerces a scalar value into a single-element array when the field expects multiple values.
25
25
  *
26
- * @param field - The field definition.
27
- * @param value - The response value to coerce.
28
- * @returns The original or coerced value.
26
+ * @param {Field} field - The field definition.
27
+ * @param {FieldValue} value - The response value to coerce.
28
+ * @returns {FieldValue} The original or coerced value.
29
29
  * @example
30
30
  * ```typescript
31
31
  * coerceToArray(multipleField, 'hello') // ['hello']
@@ -35,9 +35,9 @@ export declare function coerceToArray(field: Field, value: FieldValue): FieldVal
35
35
  /**
36
36
  * Validates that an object field value has the correct shape and is JSON-serializable.
37
37
  *
38
- * @param field - The field definition.
39
- * @param value - The response value to validate.
40
- * @returns A validation error if the value is invalid, or null if valid.
38
+ * @param {Field} field - The field definition.
39
+ * @param {FieldValue} value - The response value to validate.
40
+ * @returns {ValidationError | null} A validation error if the value is invalid, or null if valid.
41
41
  * @example
42
42
  * ```typescript
43
43
  * getObjectValueError(objectField, { key: 'val' }) // null
@@ -47,9 +47,9 @@ export declare function getObjectValueError(field: Field, value: FieldValue): Va
47
47
  /**
48
48
  * Validates that a response value matches one of the field's allowed options.
49
49
  *
50
- * @param field - The field definition with options.
51
- * @param value - The response value to validate.
52
- * @returns A validation error if the value is not a valid option, or null if valid.
50
+ * @param {Field} field - The field definition with options.
51
+ * @param {FieldValue} value - The response value to validate.
52
+ * @returns {ValidationError | null} A validation error if the value is not a valid option, or null if valid.
53
53
  * @example
54
54
  * ```typescript
55
55
  * getOptionsError(fieldWithOptions, 'valid-option') // null
@@ -59,11 +59,11 @@ export declare function getOptionsError(field: Field, value: FieldValue): Valida
59
59
  /**
60
60
  * Runs field-level validation including rule-based validation, required checks, and multiplicity checks.
61
61
  *
62
- * @param evaluateRule - Callback to evaluate rule-based validation logic.
63
- * @param field - The field definition.
64
- * @param value - The response value to validate.
65
- * @param responses - All current responses for cross-field validation.
66
- * @returns A validation error if the field fails validation, or null if valid.
62
+ * @param {RuleEvaluator} evaluateRule - Callback to evaluate rule-based validation logic.
63
+ * @param {Field} field - The field definition.
64
+ * @param {FieldValue} value - The response value to validate.
65
+ * @param {Record<string, FieldValue>} [responses] - All current responses for cross-field validation.
66
+ * @returns {Promise<ValidationError | null>} A validation error if the field fails validation, or null if valid.
67
67
  * @example
68
68
  * ```typescript
69
69
  * await getFieldValidationError(evaluate, field, 'hello') // null
@@ -1 +1 @@
1
- {"version":3,"file":"response-validation.d.ts","sourceRoot":"","sources":["../../../../src/entities/response/response-validation.ts"],"names":[],"mappings":"AAAA,0GAA0G;AAC1G,OAAO,KAAK,EAAE,KAAK,EAAE,UAAU,EAAuB,MAAM,gBAAgB,CAAA;AAC5E,OAAO,KAAK,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAA;AAGhE,MAAM,WAAW,eAAe;IAC9B,QAAQ,EAAE,KAAK,CAAC,KAAK,CAAC,CAAA;IACtB,WAAW,EAAE,MAAM,CAAA;IACnB,aAAa,EAAE,MAAM,CAAA;IACrB,KAAK,EAAE,UAAU,CAAA;CAClB;AAED,qEAAqE;AACrE,KAAK,aAAa,GAAG,CAAC,KAAK,EAAE,SAAS,EAAE,OAAO,CAAC,EAAE,WAAW,KAAK,OAAO,CAAC,OAAO,CAAC,CAAA;AAmFlF;;;;;;;;;;GAUG;AACH,wBAAgB,YAAY,CAAC,QAAQ,EAAE,MAAM,EAAE,SAAS,EAAE,KAAK,EAAE,GAAG,KAAK,GAAG,IAAI,CAE/E;AAED;;;;;;;;;;GAUG;AAEH,wBAAgB,aAAa,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,UAAU,GAAG,UAAU,CASzE;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,UAAU,GAAG,eAAe,GAAG,IAAI,CAgE3F;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,eAAe,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,UAAU,GAAG,eAAe,GAAG,IAAI,CAsCvF;AAED;;;;;;;;;;;;GAYG;AACH,wBAAsB,uBAAuB,CAC3C,YAAY,EAAE,aAAa,EAC3B,KAAK,EAAE,KAAK,EACZ,KAAK,EAAE,UAAU,EACjB,SAAS,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,UAAU,CAAC,GACrC,OAAO,CAAC,eAAe,GAAG,IAAI,CAAC,CAsCjC"}
1
+ {"version":3,"file":"response-validation.d.ts","sourceRoot":"","sources":["../../../../src/entities/response/response-validation.ts"],"names":[],"mappings":"AAAA,0GAA0G;AAC1G,OAAO,KAAK,EAAE,KAAK,EAAE,UAAU,EAAuB,MAAM,gBAAgB,CAAA;AAC5E,OAAO,KAAK,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAA;AAGhE,MAAM,WAAW,eAAe;IAC9B,QAAQ,EAAE,KAAK,CAAC,KAAK,CAAC,CAAA;IACtB,WAAW,EAAE,MAAM,CAAA;IACnB,aAAa,EAAE,MAAM,CAAA;IACrB,KAAK,EAAE,UAAU,CAAA;CAClB;AAED,qEAAqE;AACrE,KAAK,aAAa,GAAG,CAAC,KAAK,EAAE,SAAS,EAAE,OAAO,CAAC,EAAE,WAAW,KAAK,OAAO,CAAC,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E,UAAU,CAAC,CAAC,GAC3D;IAAE,WAAW,EAAE,KAAK,CAAC,KAAK,EAAE,CAAC,CAAA;CAAE,CAwCjC"}
1
+ {"version":3,"file":"create-field-evaluator.d.ts","sourceRoot":"","sources":["../../../src/form/create-field-evaluator.ts"],"names":[],"mappings":"AAAA,8GAA8G;AAC9G,OAAO,EAA6C,KAAK,KAAK,EAAE,KAAK,aAAa,EAAE,MAAM,UAAU,CAAA;AACpG,OAAO,KAAK,EAAE,KAAK,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAA;AAChE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAGvC;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,oBAAoB,CAClC,MAAM,EAAE,MAAM,EACd,SAAS,EAAE,KAAK,CAAC,MAAM,EAAE,CAAC,EAC1B,iBAAiB,EAAE,aAAa,CAAC,MAAM,CAAC,MAAM,EAAE,UAAU,CAAC,CAAC,GAC3D;IAAE,WAAW,EAAE,KAAK,CAAC,KAAK,EAAE,CAAC,CAAA;CAAE,CA8CjC"}
@@ -1 +1 @@
1
- {"version":3,"file":"create-submit-pipeline.d.ts","sourceRoot":"","sources":["../../../src/form/create-submit-pipeline.ts"],"names":[],"mappings":"AAAA,gGAAgG;AAChG,OAAO,EAOL,KAAK,KAAK,EACV,KAAK,aAAa,EAClB,KAAK,KAAK,EACX,MAAM,UAAU,CAAA;AACjB,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,qDAAqD,CAAA;AAC7F,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAA;AAC3D,OAAO,KAAK,EAAE,KAAK,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAA;AAChE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,+BAA+B,CAAA;AACpE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAGvC,MAAM,MAAM,4BAA4B,GAAG,WAAW,GAAG;IACvD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;;;GAyBG;AACH,wBAAgB,oBAAoB,CAAC,EACnC,MAAM,EACN,kBAAkB,EAClB,MAAM,EACN,KAAK,EACL,SAAS,EACT,WAAW,EACX,YAAY,GACb,EAAE,oBAAoB,GAAG,cAAc,CA8MvC"}
@@ -241,7 +241,9 @@ export declare class Picked {
241
241
  register: (key: string, action: Action) => void;
242
242
  getByKey: (key: string) => import('effector').Store<Action | undefined>;
243
243
  listStore: import('effector').Store<import('.').ActionIndexItem[]>;
244
- getEvokableAction: (actionKey: string) => import('effector').Store<() => ReturnType<Action>>;
244
+ getEvokableAction: (actionKey: string, options?: {
245
+ experience: import('.').ExperienceInstance;
246
+ }) => import('effector').Store<() => ReturnType<Action>>;
245
247
  };
246
248
  constructor(options: CreateClientOptions);
247
249
  start: () => void;
@@ -1 +1 @@
1
- {"version":3,"file":"picked.d.ts","sourceRoot":"","sources":["../../src/picked.ts"],"names":[],"mappings":"AAEA,OAAO,EAEL,KAAK,UAAU,EAEf,KAAK,uBAAuB,EAC7B,MAAM,kCAAkC,CAAA;AACzC,OAAO,EAAE,KAAK,MAAM,EAAE,KAAK,iBAAiB,EAAe,MAAM,0BAA0B,CAAA;AAC3F,OAAO,EAAE,KAAK,mBAAmB,EAAE,MAAM,UAAU,CAAA;AACnD,OAAO,EACL,KAAK,gBAAgB,EAGtB,MAAM,gCAAgC,CAAA;AACvC,OAAO,EAEL,KAAK,SAAS,EAEf,MAAM,gCAAgC,CAAA;AAGvC,OAAO,EAAuB,KAAK,aAAa,EAAE,MAAM,uBAAuB,CAAA;AAC/E,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gCAAgC,CAAA;AAE/D,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAA;AAKzD,OAAO,EAAsB,KAAK,eAAe,EAAE,KAAK,iBAAiB,EAAE,MAAM,gBAAgB,CAAA;AACjG,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,wBAAwB,CAAA;AAEnD,OAAO,KAAK,EAAE,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,YAAY,UAAU,KAAG,IAAI,CAMlD;IAED,gBAAgB,QAAO,aAAa,CAEnC;IAED;;;;;;;;;OASG;IAEH,oBAAoB,GAClB,cAAc,MAAM,EACpB,UAAU,uBAAuB,KAChC,OAAO,CAAC,IAAI,CAAC,CAEf;IACD;;;;;;;;;OASG;IAEH,qBAAqB,GACnB,eAAe,MAAM,EACrB,UAAU,uBAAuB,KAChC,OAAO,CAAC,IAAI,CAAC,CAEf;IAED;;;;;;;;OAQG;IAEH,kBAAkB,GAAU,cAAc,MAAM,KAAG,OAAO,CAAC,IAAI,CAAC,CAE/D;IAED;;;;;;;;OAQG;IAEH,mBAAmB,GAAU,eAAe,MAAM,KAAG,OAAO,CAAC,IAAI,CAAC,CAEjE;YAEa,mBAAmB;YAMnB,YAAY;IAc1B,OAAO,CAAC,YAAY;IA6BpB,OAAO,CAAC,aAAa;IA8CrB,OAAO,CAAC,eAAe;IAgBvB,OAAO,CAAC,YAAY;IAgBpB,OAAO,CAAC,eAAe;IAWvB,eAAe,GAAI,YAAY,MAAM,KAAG,iBAAiB,CAAC,MAAM,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAE1F;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAsCG;IACH,YAAY,GAAI,UAAU,MAAM,EAAE,UAAU,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,KAAG,MAAM,CAY3E;CACF"}
@@ -1 +1 @@
1
- {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../src/plugins/experience-browser-storage/plugin.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,8BAA8B,CAAA;AAK1D,UAAU,8BAA8B;IACtC,OAAO,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;CAC9B;AAED,eAAO,MAAM,8BAA8B,GAAI,eAE5C,8BAAmC,KAAG,MA6CxC,CAAA"}
1
+ {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../src/plugins/experience-browser-storage/plugin.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,8BAA8B,CAAA;AAM1D,UAAU,8BAA8B;IACtC,OAAO,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;CAC9B;AAED,eAAO,MAAM,8BAA8B,GAAI,eAE5C,8BAAmC,KAAG,MA+CxC,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../src/plugins/history-browser-storage/plugin.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,8BAA8B,CAAA;AAK1D,cAAc;AACd,MAAM,WAAW,2BAA2B;IAC1C,OAAO,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;CAC9B;AAED,eAAO,MAAM,2BAA2B,GAAI,eAEzC,2BAAgC,KAAG,MA4BrC,CAAA"}
1
+ {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../src/plugins/history-browser-storage/plugin.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,8BAA8B,CAAA;AAM1D,cAAc;AACd,MAAM,WAAW,2BAA2B;IAC1C,OAAO,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;CAC9B;AAED,eAAO,MAAM,2BAA2B,GAAI,eAEzC,2BAAgC,KAAG,MA8BrC,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../src/plugins/responses-browser-storage/plugin.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,8BAA8B,CAAA;AAK1D,UAAU,6BAA6B;IACrC,OAAO,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;CAC9B;AAiCD,eAAO,MAAM,6BAA6B,GAAI,eAE3C,6BAAkC,KAAG,MAqCvC,CAAA"}
1
+ {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../src/plugins/responses-browser-storage/plugin.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,8BAA8B,CAAA;AAM1D,UAAU,6BAA6B;IACrC,OAAO,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;CAC9B;AAiCD,eAAO,MAAM,6BAA6B,GAAI,eAE3C,6BAAkC,KAAG,MAuCvC,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../src/plugins/responses-indexeddb/plugin.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,8BAA8B,CAAA;AAM1D,eAAO,MAAM,wBAAwB,QAAO,MAqE3C,CAAA"}
1
+ {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../src/plugins/responses-indexeddb/plugin.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,8BAA8B,CAAA;AAO1D,eAAO,MAAM,wBAAwB,QAAO,MAuE3C,CAAA"}
@@ -2,21 +2,48 @@ import { Plugin } from '../../entities/plugin/plugin';
2
2
  import { Picked } from '../../picked';
3
3
  interface SinglePageAppPluginOptions {
4
4
  /**
5
- * Enables monitoring of browser history events (pushState, replaceState, popstate)
6
- * to automatically restart the client when navigating in single-page applications.
7
- * Only `true` is supported at this time.
5
+ * When `true`, the plugin falls back to wrapping `pushState`, `replaceState`, and
6
+ * `popstate` on platforms without the Navigation API. Set to `false` to skip the
7
+ * fallback and rely on {@link notifyNavigation} from the host router instead.
8
+ *
9
+ * @default true
8
10
  */
9
- instrumentHistory: true;
11
+ instrumentHistory?: boolean;
12
+ /**
13
+ * Hard upper bound (ms) on how long a reconcile window observes DOM mutations.
14
+ * Increase for SSR-hydrating apps whose target tree takes longer than the default
15
+ * to settle.
16
+ *
17
+ * @default 1000
18
+ */
19
+ maxWindowMs?: number;
20
+ /**
21
+ * Idle threshold (ms) — when no DOM mutation arrives for this long, the
22
+ * reconcile window disconnects early. Smaller values cut work sooner on
23
+ * quiet pages.
24
+ *
25
+ * @default 150
26
+ */
27
+ idleDebounceMs?: number;
10
28
  }
11
29
  /**
12
30
  * Enables compatibility with Single Page Applications (SPAs).
13
- * This plugin monitors browser history events and reconciles experiences with the
14
- * new route's DOM: after a route change it re-runs the per-experience spawn pass
15
- * (`initialiseExperiences`) immediately and again on each DOM mutation batch until
16
- * the DOM settles, so widgets re-appear when their target elements are (re)rendered
17
- * by the host framework.
31
+ * This plugin subscribes to browser route changes and reconciles experiences with
32
+ * the new route's DOM: after a route change it re-runs the per-experience spawn
33
+ * pass (`initialiseExperiences`) immediately and again on each DOM mutation batch
34
+ * until the DOM settles, so widgets re-appear when their target elements are
35
+ * (re)rendered by the host framework. Prefers the Navigation API
36
+ * (`window.navigation.addEventListener('navigatesuccess', …)`) when available
37
+ * and falls back to instrumenting `pushState` / `replaceState` / `popstate`
38
+ * otherwise.
39
+ *
40
+ * Note: route changes drive `initialiseExperiences` only — the broader side
41
+ * effects of `client.start()` (precondition/condition gate re-evaluation,
42
+ * `runPluginStartHooks`, `ping`, and `initialize`/`ready`/`session` events)
43
+ * are intentionally not re-run per navigation. Consumers that need per-route
44
+ * gate re-evaluation should call `client.start()` from their router themselves.
18
45
  *
19
- * @param {SinglePageAppPluginOptions} _options - Configuration options for the SPA plugin.
46
+ * @param {SinglePageAppPluginOptions} options - Configuration options for the SPA plugin.
20
47
  * @returns {Plugin} The plugin.
21
48
  * @example
22
49
  * ```typescript
@@ -29,7 +56,7 @@ interface SinglePageAppPluginOptions {
29
56
  * })
30
57
  * ```
31
58
  */
32
- export declare const singlePageAppPlugin: (_options: SinglePageAppPluginOptions) => Plugin;
59
+ export declare const singlePageAppPlugin: (options?: SinglePageAppPluginOptions) => Plugin;
33
60
  /**
34
61
  * Triggers experience reconciliation for the next ~1 second of DOM mutations.
35
62
  * Use from a router lifecycle hook when the SPA plugin's history instrumentation
@@ -38,7 +65,9 @@ export declare const singlePageAppPlugin: (_options: SinglePageAppPluginOptions)
38
65
  * `pushState` at all.
39
66
  *
40
67
  * Safe to call any number of times — successive calls cancel and replace the
41
- * prior reconcile window for the given client.
68
+ * prior reconcile window for the given client. No-ops outside browser
69
+ * environments and on partial-DOM runtimes that lack `MutationObserver`,
70
+ * `requestAnimationFrame`, or `document.body`.
42
71
  *
43
72
  * @param {Picked} client - The Picked client instance to reconcile.
44
73
  * @example
@@ -49,10 +78,33 @@ export declare const singlePageAppPlugin: (_options: SinglePageAppPluginOptions)
49
78
  * afterNavigate(() => notifyNavigation(picked))
50
79
  */
51
80
  export declare function notifyNavigation(client: Picked): void;
81
+ interface SubscribeOptions {
82
+ fallbackToHistory: boolean;
83
+ }
84
+ /**
85
+ * Subscribes to browser route changes and invokes `callback` once per URL
86
+ * change. Prefers the Navigation API
87
+ * (`window.navigation.addEventListener('navigatesuccess', …)`) when available
88
+ * because it captures every same-document navigation regardless of the host
89
+ * router's mechanism and survives third-party scripts that wrap
90
+ * `pushState` / `replaceState`. Falls back to {@link instrumentHistory} on
91
+ * platforms without the Navigation API.
92
+ *
93
+ * @param {() => void} callback - Invoked once per URL change.
94
+ * @param {SubscribeOptions} [options] - Whether to fall back to history instrumentation when the Navigation API is unavailable.
95
+ * @example
96
+ * subscribeToRouteChanges(() => reconcile())
97
+ */
98
+ export declare function subscribeToRouteChanges(callback: () => void, options?: SubscribeOptions): void;
52
99
  /**
53
100
  * Instruments browser history so the callback fires whenever the navigation
54
101
  * URL changes via `popstate`, `pushState`, or `replaceState`. Same-URL events
55
102
  * are ignored so repeated replaces of the current location don't re-trigger.
103
+ * Used as the fallback for environments without the Navigation API.
104
+ *
105
+ * Idempotent: if `pushState`/`replaceState` are already wrapped (i.e. Carry
106
+ * the `__picked_original` marker), the wrap is skipped so HMR or repeat client
107
+ * setup does not stack listeners..
56
108
  *
57
109
  * @param {() => void} callback - Invoked once per URL change.
58
110
  * @example
@@ -1 +1 @@
1
- {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../src/plugins/single-page-app/plugin.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,8BAA8B,CAAA;AAC1D,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AAc1C,UAAU,0BAA0B;IAClC;;;;OAIG;IACH,iBAAiB,EAAE,IAAI,CAAA;CACxB;AAED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,eAAO,MAAM,mBAAmB,GAAI,UAAU,0BAA0B,KAAG,MAW1E,CAAA;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,CAMrD;AAwED;;;;;;;;GAQG;AACH,wBAAgB,iBAAiB,CAAC,QAAQ,EAAE,MAAM,IAAI,GAAG,IAAI,CAgE5D"}
1
+ {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../../src/plugins/single-page-app/plugin.ts"],"names":[],"mappings":"AAYA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,8BAA8B,CAAA;AAC1D,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AAa1C,UAAU,0BAA0B;IAClC;;;;;;OAMG;IACH,iBAAiB,CAAC,EAAE,OAAO,CAAA;IAC3B;;;;;;OAMG;IACH,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB;;;;;;OAMG;IACH,cAAc,CAAC,EAAE,MAAM,CAAA;CACxB;AAOD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH,eAAO,MAAM,mBAAmB,GAAI,UAAS,0BAA+B,KAAG,MAoB9E,CAAA;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,CASrD;AA+LD,UAAU,gBAAgB;IACxB,iBAAiB,EAAE,OAAO,CAAA;CAC3B;AAED;;;;;;;;;;;;;GAaG;AACH,wBAAgB,uBAAuB,CACrC,QAAQ,EAAE,MAAM,IAAI,EACpB,OAAO,GAAE,gBAA8C,GACtD,IAAI,CAuBN;AAED;;;;;;;;;;;;;GAaG;AACH,wBAAgB,iBAAiB,CAAC,QAAQ,EAAE,MAAM,IAAI,GAAG,IAAI,CA0D5D"}
@@ -3,6 +3,11 @@ declare const globalObjKey: unique symbol;
3
3
  interface InternalGlobal {
4
4
  [globalObjKey]?: Picked;
5
5
  Picked?: Picked;
6
+ navigation?: NavigationEventTarget;
7
+ }
8
+ interface NavigationEventTarget {
9
+ addEventListener: (type: 'navigatesuccess', listener: () => void, options?: AddEventListenerOptions) => void;
10
+ removeEventListener: (type: 'navigatesuccess', listener: () => void, options?: EventListenerOptions) => void;
6
11
  }
7
12
  export declare const GLOBAL_OBJ: typeof globalThis & InternalGlobal;
8
13
  export declare const bindClient: (client: Picked) => void;
@@ -1 +1 @@
1
- {"version":3,"file":"global-obj.d.ts","sourceRoot":"","sources":["../../../src/utils/global-obj.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAEvC,QAAA,MAAM,YAAY,eAAmB,CAAA;AAErC,UAAU,cAAc;IACtB,CAAC,YAAY,CAAC,CAAC,EAAE,MAAM,CAAA;IACvB,MAAM,CAAC,EAAE,MAAM,CAAA;CAChB;AAGD,eAAO,MAAM,UAAU,EAAiB,OAAO,UAAU,GAAG,cAAc,CAAA;AAE1E,eAAO,MAAM,UAAU,GAAI,QAAQ,MAAM,SAExC,CAAA"}
1
+ {"version":3,"file":"global-obj.d.ts","sourceRoot":"","sources":["../../../src/utils/global-obj.ts"],"names":[],"mappings":"AAAA,uFAAuF;AACvF,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAEvC,QAAA,MAAM,YAAY,eAAmB,CAAA;AAErC,UAAU,cAAc;IACtB,CAAC,YAAY,CAAC,CAAC,EAAE,MAAM,CAAA;IACvB,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,UAAU,CAAC,EAAE,qBAAqB,CAAA;CACnC;AAED,UAAU,qBAAqB;IAC7B,gBAAgB,EAAE,CAChB,IAAI,EAAE,iBAAiB,EACvB,QAAQ,EAAE,MAAM,IAAI,EACpB,OAAO,CAAC,EAAE,uBAAuB,KAC9B,IAAI,CAAA;IACT,mBAAmB,EAAE,CACnB,IAAI,EAAE,iBAAiB,EACvB,QAAQ,EAAE,MAAM,IAAI,EACpB,OAAO,CAAC,EAAE,oBAAoB,KAC3B,IAAI,CAAA;CACV;AAGD,eAAO,MAAM,UAAU,EAAiB,OAAO,UAAU,GAAG,cAAc,CAAA;AAE1E,eAAO,MAAM,UAAU,GAAI,QAAQ,MAAM,SAExC,CAAA"}