@fanfare-io/fanfare-sdk-react 0.19.0 → 0.20.0

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/index.d.ts CHANGED
@@ -48,8 +48,8 @@ export { GrantedPanel } from './components/compositions/granted-panel';
48
48
  export type { GrantedPanelProps } from './components/compositions/granted-panel';
49
49
  export { OutcomePanel } from './components/compositions/outcome-panel';
50
50
  export type { OutcomePanelProps } from './components/compositions/outcome-panel';
51
- export { ProductSelector, SelectionSummary } from './components/widgets/internal/selection';
52
- export type { ProductSelectorHandle, ProductSelectorProps, SelectionLockedReason, SelectionSummaryProps, } from './components/widgets/internal/selection';
51
+ export { ProductSelector, SelectionSummary } from './components/widgets/internal';
52
+ export type { ProductSelectorHandle, ProductSelectorProps, SelectionLockedReason, SelectionSummaryProps, } from './components/widgets/internal';
53
53
  export { ExperienceWidget, type AccessCodeSlotProps, type AuthSlotProps, type ChallengeSlotProps, type CheckoutProcessingSlotProps, type EndedSlotProps, type EnterableSlotProps, type ErrorSlotProps, type ExperienceRenderProps, type ExperienceWidgetProps, type ExperienceWidgetSlots, type ExpiredSlotProps, type GrantedSlotProps, type LoadingSlotProps, type ParticipatingSlotProps, type PaymentCollectionSlotProps, type ReceiptSlotProps, type SlotProps, type StartSlotProps, type UpcomingSlotProps, type WaitlistSlotProps, } from './components/widgets/experience-widget';
54
54
  export { CheckoutProcessingPanel, PaymentCollectionPanel, ReceiptPanel } from './components/checkout';
55
55
  export { LoadingView, StartView, UpcomingModule, WaitlistView } from './components/widgets/internal';
@@ -59,3 +59,4 @@ export type { AppointmentModuleProps, AuctionModuleProps, DrawModuleProps, Queue
59
59
  export type { SelectionCheckoutDetails } from './lib/selection-display';
60
60
  export { ShadowDOMPreview } from './components/shadow-dom-preview';
61
61
  export type { ShadowDOMPreviewProps } from './components/shadow-dom-preview';
62
+ export type { EnterableSlotSequence } from './components/widgets/experience-widget';
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use client";
2
- import { A as s, b as o, c as n, e as r, f as t, B as u, C as i, h as l, i as d, j as c, k as P, l as C, m, n as p, o as S, D as E, E as T, p as h, q as F, r as M, s as f, F as w, t as y, G as A, I as x, v as L, w as V, L as g, O as R, x as v, P as I, y as O, z as k, H as B, J as D, K as J, Q as H, R as _, M as b, N as G, T as W, U as z, V as N, W as Q, X as U, Y as j, Z as q, _ as K, $ as X, a0 as Y, a1 as Z, a2 as $, a3 as aa, a4 as ea, a5 as sa, a6 as oa, a7 as na, u as ra } from "./index-jbm-DC1W.js";
2
+ import { A as s, b as o, c as n, e as r, f as t, B as u, C as i, h as l, i as d, j as c, k as P, l as C, m, n as p, o as S, D as E, E as T, p as h, q as F, r as M, s as f, F as w, t as y, G as A, I as x, v as L, w as V, L as g, O as R, x as v, P as I, y as O, z as k, H as B, J as D, K as J, Q as H, R as _, M as b, N as G, T as W, U as z, V as N, W as Q, X as U, Y as j, Z as q, _ as K, $ as X, a0 as Y, a1 as Z, a2 as $, a3 as aa, a4 as ea, a5 as sa, a6 as oa, a7 as na, u as ra } from "./index-DOeKTtWT.js";
3
3
  import { RTL_LOCALES as ua, isRTLLocale as ia } from "@fanfare-io/fanfare-sdk-i18n";
4
4
  export {
5
5
  s as AccessCodeForm,
@@ -13,9 +13,10 @@ export declare function selectionDisplayFromOptions(options: SelectionOptions |
13
13
  /**
14
14
  * The pick a checkout is for, as the adapter loaded it.
15
15
  *
16
- * Carries the catalogue objects rather than ids alone so a host can map the pick onto its own
17
- * catalogue — by handle, by SKU, by option values — without a second request for a payload the
18
- * adapter already holds.
16
+ * Carries the loaded catalogue objects, including optional external references for checkout.
17
+ * Hosts should use supported external references for commerce identity, not presentation fields
18
+ * such as handles, SKUs, or option labels. A default variant can have no option values and still
19
+ * carry an external reference.
19
20
  */
20
21
  export interface SelectionCheckoutDetails {
21
22
  selection: SelectionChoice;
@@ -1,18 +1,8 @@
1
- /**
2
- * Copy keys for selection refusals the widget recovers in place.
3
- *
4
- * The server states one refusal code; the consumer-facing sentence depends on what the
5
- * consumer was doing when it arrived, which only the client knows. A pick refused once
6
- * checkout has started reads differently from the same refusal during bidding, and the
7
- * wire carries no way to tell them apart.
8
- *
9
- * A code with no row here is not a selection failure the surface can recover: it belongs
10
- * to the widget's ordinary error sink, which decides between a reroute and a panel.
11
- */
1
+ import { TranslationKey } from '@fanfare-io/fanfare-sdk-i18n';
12
2
  /** What the consumer was doing when the refusal arrived. */
13
3
  export type SelectionActionTrigger = "checkout" | "bid" | "select";
14
4
  /**
15
5
  * The already-registered i18n key for a selection refusal, or null when the code is not
16
6
  * one a selection surface renders inline.
17
7
  */
18
- export declare function selectionErrorKey(code: string, trigger: SelectionActionTrigger): string | null;
8
+ export declare function selectionErrorKey(code: string, trigger: SelectionActionTrigger): TranslationKey | null;
@@ -2,7 +2,7 @@
2
2
  import { jsxs as E, Fragment as F, jsx as g } from "react/jsx-runtime";
3
3
  import * as r from "react";
4
4
  import { createPortal as M } from "react-dom";
5
- import { u as B, a as D, d as N, S as I, B as O, g as _ } from "./index-jbm-DC1W.js";
5
+ import { u as B, a as D, d as N, S as I, B as O, g as _ } from "./index-DOeKTtWT.js";
6
6
  const j = [
7
7
  "--ff-color-foreground",
8
8
  "--ff-font-sans",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fanfare-io/fanfare-sdk-react",
3
- "version": "0.19.0",
3
+ "version": "0.20.0",
4
4
  "description": "React adapter for Fanfare SDK",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org",
@@ -43,8 +43,8 @@
43
43
  "nanostores": "^1.1.0",
44
44
  "tailwind-merge": "^2.6.0",
45
45
  "valibot": "^1.1.0",
46
- "@fanfare-io/fanfare-sdk-core": "0.19.0",
47
- "@fanfare-io/fanfare-sdk-i18n": "0.19.0"
46
+ "@fanfare-io/fanfare-sdk-core": "0.20.0",
47
+ "@fanfare-io/fanfare-sdk-i18n": "0.20.0"
48
48
  },
49
49
  "devDependencies": {
50
50
  "@iconify-json/heroicons": "^1.2.3",
@@ -91,8 +91,8 @@
91
91
  "vite-plugin-dts": "^4.5.4",
92
92
  "vite-tsconfig-paths": "^5.1.4",
93
93
  "vitest": "^5.0.0",
94
- "@fanfare-io/fanfare-sdk-core": "0.19.0",
95
- "@fanfare-io/fanfare-sdk-solid": "0.19.0"
94
+ "@fanfare-io/fanfare-sdk-core": "0.20.0",
95
+ "@fanfare-io/fanfare-sdk-solid": "0.20.0"
96
96
  },
97
97
  "sideEffects": [
98
98
  "**/*.css"