@appfunnel-dev/sdk 2.0.0-canary.10 → 2.0.0-canary.12
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/dist/{chunk-Y4YNJ2EX.cjs → chunk-7HDZVHIT.cjs} +43 -2
- package/dist/chunk-7HDZVHIT.cjs.map +1 -0
- package/dist/{chunk-VW2HVPR4.js → chunk-UAQV22UK.js} +43 -3
- package/dist/chunk-UAQV22UK.js.map +1 -0
- package/dist/index.cjs +349 -288
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +18 -3
- package/dist/index.d.ts +18 -3
- package/dist/index.js +128 -89
- package/dist/index.js.map +1 -1
- package/dist/{manifest-B3Tdab0M.d.cts → manifest-CTt2LlUV.d.cts} +89 -2
- package/dist/{manifest-B3Tdab0M.d.ts → manifest-CTt2LlUV.d.ts} +89 -2
- package/dist/manifest-entry.cjs +20 -20
- package/dist/manifest-entry.d.cts +2 -2
- package/dist/manifest-entry.d.ts +2 -2
- package/dist/manifest-entry.js +1 -1
- package/package.json +1 -1
- package/dist/chunk-VW2HVPR4.js.map +0 -1
- package/dist/chunk-Y4YNJ2EX.cjs.map +0 -1
package/dist/index.d.cts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import { ReactNode, ComponentType, ButtonHTMLAttributes } from 'react';
|
|
3
|
-
import { V as VariableValue, a as VariableConfig, A as Acquisition, O as Offering, D as Direction, F as FunnelContext, R as RuntimeExperiment, b as FunnelSnapshot, c as FunnelDefinition, d as buildContext, e as OfferingInput, P as PageMeta, f as PageContext } from './manifest-
|
|
4
|
-
export { B as BrowserContext, g as BuildContextOptions, C as ClickIdContext, h as CompileInput, i as Condition, j as ConditionOp, k as DeviceContext, E as EdgeCondition, l as ExperimentArm, m as ExperimentResolution, n as FlowPage, o as FunnelLocales, p as FunnelManifest,
|
|
3
|
+
import { V as VariableValue, a as VariableConfig, A as Acquisition, O as Offering, D as Direction, F as FunnelContext, R as RuntimeExperiment, b as FunnelSnapshot, c as FunnelDefinition, d as buildContext, e as OfferingInput, P as PageMeta, f as PageContext, G as GroupProgress } from './manifest-CTt2LlUV.cjs';
|
|
4
|
+
export { B as BrowserContext, g as BuildContextOptions, C as ClickIdContext, h as CompileInput, i as Condition, j as ConditionOp, k as DeviceContext, E as EdgeCondition, l as ExperimentArm, m as ExperimentResolution, n as FlowPage, o as FunnelLocales, p as FunnelManifest, q as Gate, I as IdentityContext, r as Interval, L as LocaleContext, M as ManifestEdge, s as ManifestPage, t as ManifestValidation, u as Money, v as OsContext, w as PageComponent, x as PageGroup, y as PageType, z as Predicate, H as ResolvedOffering, J as Route, S as SessionContext, K as SystemContext, U as UtmContext, N as assignVariant, Q as bucketingSeed, T as buildAcquisition, W as buildCatalog, X as compileManifest, Y as currencyExponent, Z as defineFunnel, _ as definePage, $ as entryGuard, a0 as evaluateCondition, a1 as evaluateGate, a2 as expectedPathLength, a3 as fnv1a, a4 as formatMoney, a5 as formatOffering, a6 as groupProgress, a7 as hashToUnit, a8 as isRtl, a9 as isVariantKey, aa as nextPage, ab as outgoingKeys, ac as pageMeta, ad as parseSlotKey, ae as pickByWeight, af as resolveExperiments, ag as resolveLocale, ah as resolveOffering, ai as resolveRoute } from './manifest-CTt2LlUV.cjs';
|
|
5
5
|
import { NavSnapshot } from './protocol.cjs';
|
|
6
6
|
import { a as CheckoutDriver, C as CheckoutDriverContext } from './checkout-DBp4bCpC.cjs';
|
|
7
7
|
export { b as Checkout, c as CheckoutCallbacks, d as CheckoutHandle, e as CheckoutProps, f as CheckoutRequest, g as CheckoutResult, h as CheckoutResume, i as CheckoutStatus, F as FailureModalProps, j as FailureRoute, M as MockDriverOptions, O as OnFailedMap, U as Upsell, k as UpsellProps, l as UseCheckoutOptions, m as createMockDriver, n as driverWithEmail, u as useCheckout } from './checkout-DBp4bCpC.cjs';
|
|
@@ -618,6 +618,21 @@ declare function FunnelView({ pages, initialKey, trustInitialKey, layout, fallba
|
|
|
618
618
|
declare function useNavigation(): NavigationState;
|
|
619
619
|
/** `usePage()` — the current page's read-only context, reactive to navigation. */
|
|
620
620
|
declare function usePage(): PageContext;
|
|
621
|
+
/**
|
|
622
|
+
* `useGroupProgress()` — the visitor-routed, branch-aware grouped-progress structure
|
|
623
|
+
* for a grouped `<ProgressBar>`: ordered {@link PageGroup} segments (from `meta.group`),
|
|
624
|
+
* the `activeIndex` of the current group (`-1` when the current page is ungrouped), and
|
|
625
|
+
* the active group's within-group `activeFraction` (0–1). Counts only the pages THIS
|
|
626
|
+
* visitor will actually visit given their answers (see {@link groupProgress}). A funnel
|
|
627
|
+
* with no `group` keys yields `{ groups: [], activeIndex: -1, activeFraction: 0 }`.
|
|
628
|
+
* Must be used inside `<FunnelView>`.
|
|
629
|
+
*
|
|
630
|
+
* Each segment's `key` is the **slug identifier** from {@link PageMeta.group}, NOT a
|
|
631
|
+
* display string — resolve it to a label in your funnel code, e.g.
|
|
632
|
+
* `const GROUP_LABELS = { profile: 'My Profile' }; GROUP_LABELS[group.key]` or
|
|
633
|
+
* `t(`groups.${group.key}`)`. This keeps grouping stable across copy and locale changes.
|
|
634
|
+
*/
|
|
635
|
+
declare function useGroupProgress(): GroupProgress;
|
|
621
636
|
|
|
622
637
|
/**
|
|
623
638
|
* Funnel asset map: logical name (e.g. `logo.svg`) → content-addressed CDN URL,
|
|
@@ -1094,4 +1109,4 @@ interface ScriptProps {
|
|
|
1094
1109
|
*/
|
|
1095
1110
|
declare function Script({ src, strategy, id, async, defer, nonce, attributes, onLoad, onError, }: ScriptProps): null;
|
|
1096
1111
|
|
|
1097
|
-
export { Acquisition, type AppfunnelBusApi, AssetsContext, AssetsProvider, Back, type BackProps, type BusAccessors, type BusEvent, type CatalogEvent, CheckoutDriver, CheckoutDriverContext, Choice, type ChoiceOption, type ChoiceProps, type CreateFunnelTreeInput, Direction, EVENT_CATALOG, type EventMeta, type EventSource, type Formatters, type Funnel, type FunnelBus, FunnelContext, FunnelDefinition, type FunnelEventDataMap, FunnelProvider, type FunnelProviderProps, FunnelSnapshot, FunnelToaster, FunnelView, type KnownFunnelEvent, type MessageCatalog, Modal, type ModalHandler, type ModalHocProps, type ModalProps, type ModalState, type MountModule, type MountOpts, Namespace, type NavigationState, Next, type NextProps, Offering, OfferingInput, PageContext, PageMeta, type PageModule, type PlatformTrackingConfig, type PluralCategory, RuntimeExperiment, type RuntimePage, Script, type ScriptProps, Sheet, type SheetProps, type SheetSide, type TFunction, type Tracker, type Translation, VariableStore, attachBus, buildContext, createBus, createConsoleTracker, createFunnelStore, createFunnelTree, createPlatformTracker, defineModal, hideModal, integrationEvents, isIntegrationEvent, isTrackableEvent, newEventId, registerModal, removeModal, showModal, unregisterModal, useActiveLocale, useAsset, useAssets, useClickIds, useContextValue, useData, useDevice, useExperiment, useField, useFunnel, useLocale, useModal, useNavigation, useOffering, useOfferings, usePage, useResponse, useSystem, useTracker, useTranslation, useUserAttribute, useUtm, withBus };
|
|
1112
|
+
export { Acquisition, type AppfunnelBusApi, AssetsContext, AssetsProvider, Back, type BackProps, type BusAccessors, type BusEvent, type CatalogEvent, CheckoutDriver, CheckoutDriverContext, Choice, type ChoiceOption, type ChoiceProps, type CreateFunnelTreeInput, Direction, EVENT_CATALOG, type EventMeta, type EventSource, type Formatters, type Funnel, type FunnelBus, FunnelContext, FunnelDefinition, type FunnelEventDataMap, FunnelProvider, type FunnelProviderProps, FunnelSnapshot, FunnelToaster, FunnelView, GroupProgress, type KnownFunnelEvent, type MessageCatalog, Modal, type ModalHandler, type ModalHocProps, type ModalProps, type ModalState, type MountModule, type MountOpts, Namespace, type NavigationState, Next, type NextProps, Offering, OfferingInput, PageContext, PageMeta, type PageModule, type PlatformTrackingConfig, type PluralCategory, RuntimeExperiment, type RuntimePage, Script, type ScriptProps, Sheet, type SheetProps, type SheetSide, type TFunction, type Tracker, type Translation, VariableStore, attachBus, buildContext, createBus, createConsoleTracker, createFunnelStore, createFunnelTree, createPlatformTracker, defineModal, hideModal, integrationEvents, isIntegrationEvent, isTrackableEvent, newEventId, registerModal, removeModal, showModal, unregisterModal, useActiveLocale, useAsset, useAssets, useClickIds, useContextValue, useData, useDevice, useExperiment, useField, useFunnel, useGroupProgress, useLocale, useModal, useNavigation, useOffering, useOfferings, usePage, useResponse, useSystem, useTracker, useTranslation, useUserAttribute, useUtm, withBus };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import { ReactNode, ComponentType, ButtonHTMLAttributes } from 'react';
|
|
3
|
-
import { V as VariableValue, a as VariableConfig, A as Acquisition, O as Offering, D as Direction, F as FunnelContext, R as RuntimeExperiment, b as FunnelSnapshot, c as FunnelDefinition, d as buildContext, e as OfferingInput, P as PageMeta, f as PageContext } from './manifest-
|
|
4
|
-
export { B as BrowserContext, g as BuildContextOptions, C as ClickIdContext, h as CompileInput, i as Condition, j as ConditionOp, k as DeviceContext, E as EdgeCondition, l as ExperimentArm, m as ExperimentResolution, n as FlowPage, o as FunnelLocales, p as FunnelManifest,
|
|
3
|
+
import { V as VariableValue, a as VariableConfig, A as Acquisition, O as Offering, D as Direction, F as FunnelContext, R as RuntimeExperiment, b as FunnelSnapshot, c as FunnelDefinition, d as buildContext, e as OfferingInput, P as PageMeta, f as PageContext, G as GroupProgress } from './manifest-CTt2LlUV.js';
|
|
4
|
+
export { B as BrowserContext, g as BuildContextOptions, C as ClickIdContext, h as CompileInput, i as Condition, j as ConditionOp, k as DeviceContext, E as EdgeCondition, l as ExperimentArm, m as ExperimentResolution, n as FlowPage, o as FunnelLocales, p as FunnelManifest, q as Gate, I as IdentityContext, r as Interval, L as LocaleContext, M as ManifestEdge, s as ManifestPage, t as ManifestValidation, u as Money, v as OsContext, w as PageComponent, x as PageGroup, y as PageType, z as Predicate, H as ResolvedOffering, J as Route, S as SessionContext, K as SystemContext, U as UtmContext, N as assignVariant, Q as bucketingSeed, T as buildAcquisition, W as buildCatalog, X as compileManifest, Y as currencyExponent, Z as defineFunnel, _ as definePage, $ as entryGuard, a0 as evaluateCondition, a1 as evaluateGate, a2 as expectedPathLength, a3 as fnv1a, a4 as formatMoney, a5 as formatOffering, a6 as groupProgress, a7 as hashToUnit, a8 as isRtl, a9 as isVariantKey, aa as nextPage, ab as outgoingKeys, ac as pageMeta, ad as parseSlotKey, ae as pickByWeight, af as resolveExperiments, ag as resolveLocale, ah as resolveOffering, ai as resolveRoute } from './manifest-CTt2LlUV.js';
|
|
5
5
|
import { NavSnapshot } from './protocol.js';
|
|
6
6
|
import { a as CheckoutDriver, C as CheckoutDriverContext } from './checkout-ClaO5IYV.js';
|
|
7
7
|
export { b as Checkout, c as CheckoutCallbacks, d as CheckoutHandle, e as CheckoutProps, f as CheckoutRequest, g as CheckoutResult, h as CheckoutResume, i as CheckoutStatus, F as FailureModalProps, j as FailureRoute, M as MockDriverOptions, O as OnFailedMap, U as Upsell, k as UpsellProps, l as UseCheckoutOptions, m as createMockDriver, n as driverWithEmail, u as useCheckout } from './checkout-ClaO5IYV.js';
|
|
@@ -618,6 +618,21 @@ declare function FunnelView({ pages, initialKey, trustInitialKey, layout, fallba
|
|
|
618
618
|
declare function useNavigation(): NavigationState;
|
|
619
619
|
/** `usePage()` — the current page's read-only context, reactive to navigation. */
|
|
620
620
|
declare function usePage(): PageContext;
|
|
621
|
+
/**
|
|
622
|
+
* `useGroupProgress()` — the visitor-routed, branch-aware grouped-progress structure
|
|
623
|
+
* for a grouped `<ProgressBar>`: ordered {@link PageGroup} segments (from `meta.group`),
|
|
624
|
+
* the `activeIndex` of the current group (`-1` when the current page is ungrouped), and
|
|
625
|
+
* the active group's within-group `activeFraction` (0–1). Counts only the pages THIS
|
|
626
|
+
* visitor will actually visit given their answers (see {@link groupProgress}). A funnel
|
|
627
|
+
* with no `group` keys yields `{ groups: [], activeIndex: -1, activeFraction: 0 }`.
|
|
628
|
+
* Must be used inside `<FunnelView>`.
|
|
629
|
+
*
|
|
630
|
+
* Each segment's `key` is the **slug identifier** from {@link PageMeta.group}, NOT a
|
|
631
|
+
* display string — resolve it to a label in your funnel code, e.g.
|
|
632
|
+
* `const GROUP_LABELS = { profile: 'My Profile' }; GROUP_LABELS[group.key]` or
|
|
633
|
+
* `t(`groups.${group.key}`)`. This keeps grouping stable across copy and locale changes.
|
|
634
|
+
*/
|
|
635
|
+
declare function useGroupProgress(): GroupProgress;
|
|
621
636
|
|
|
622
637
|
/**
|
|
623
638
|
* Funnel asset map: logical name (e.g. `logo.svg`) → content-addressed CDN URL,
|
|
@@ -1094,4 +1109,4 @@ interface ScriptProps {
|
|
|
1094
1109
|
*/
|
|
1095
1110
|
declare function Script({ src, strategy, id, async, defer, nonce, attributes, onLoad, onError, }: ScriptProps): null;
|
|
1096
1111
|
|
|
1097
|
-
export { Acquisition, type AppfunnelBusApi, AssetsContext, AssetsProvider, Back, type BackProps, type BusAccessors, type BusEvent, type CatalogEvent, CheckoutDriver, CheckoutDriverContext, Choice, type ChoiceOption, type ChoiceProps, type CreateFunnelTreeInput, Direction, EVENT_CATALOG, type EventMeta, type EventSource, type Formatters, type Funnel, type FunnelBus, FunnelContext, FunnelDefinition, type FunnelEventDataMap, FunnelProvider, type FunnelProviderProps, FunnelSnapshot, FunnelToaster, FunnelView, type KnownFunnelEvent, type MessageCatalog, Modal, type ModalHandler, type ModalHocProps, type ModalProps, type ModalState, type MountModule, type MountOpts, Namespace, type NavigationState, Next, type NextProps, Offering, OfferingInput, PageContext, PageMeta, type PageModule, type PlatformTrackingConfig, type PluralCategory, RuntimeExperiment, type RuntimePage, Script, type ScriptProps, Sheet, type SheetProps, type SheetSide, type TFunction, type Tracker, type Translation, VariableStore, attachBus, buildContext, createBus, createConsoleTracker, createFunnelStore, createFunnelTree, createPlatformTracker, defineModal, hideModal, integrationEvents, isIntegrationEvent, isTrackableEvent, newEventId, registerModal, removeModal, showModal, unregisterModal, useActiveLocale, useAsset, useAssets, useClickIds, useContextValue, useData, useDevice, useExperiment, useField, useFunnel, useLocale, useModal, useNavigation, useOffering, useOfferings, usePage, useResponse, useSystem, useTracker, useTranslation, useUserAttribute, useUtm, withBus };
|
|
1112
|
+
export { Acquisition, type AppfunnelBusApi, AssetsContext, AssetsProvider, Back, type BackProps, type BusAccessors, type BusEvent, type CatalogEvent, CheckoutDriver, CheckoutDriverContext, Choice, type ChoiceOption, type ChoiceProps, type CreateFunnelTreeInput, Direction, EVENT_CATALOG, type EventMeta, type EventSource, type Formatters, type Funnel, type FunnelBus, FunnelContext, FunnelDefinition, type FunnelEventDataMap, FunnelProvider, type FunnelProviderProps, FunnelSnapshot, FunnelToaster, FunnelView, GroupProgress, type KnownFunnelEvent, type MessageCatalog, Modal, type ModalHandler, type ModalHocProps, type ModalProps, type ModalState, type MountModule, type MountOpts, Namespace, type NavigationState, Next, type NextProps, Offering, OfferingInput, PageContext, PageMeta, type PageModule, type PlatformTrackingConfig, type PluralCategory, RuntimeExperiment, type RuntimePage, Script, type ScriptProps, Sheet, type SheetProps, type SheetSide, type TFunction, type Tracker, type Translation, VariableStore, attachBus, buildContext, createBus, createConsoleTracker, createFunnelStore, createFunnelTree, createPlatformTracker, defineModal, hideModal, integrationEvents, isIntegrationEvent, isTrackableEvent, newEventId, registerModal, removeModal, showModal, unregisterModal, useActiveLocale, useAsset, useAssets, useClickIds, useContextValue, useData, useDevice, useExperiment, useField, useFunnel, useGroupProgress, useLocale, useModal, useNavigation, useOffering, useOfferings, usePage, useResponse, useSystem, useTracker, useTranslation, useUserAttribute, useUtm, withBus };
|