@01.software/sdk 0.56.1 → 0.65.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.
Files changed (63) hide show
  1. package/CHANGELOG.md +186 -0
  2. package/README.md +174 -91
  3. package/dist/client.cjs +136 -7
  4. package/dist/client.cjs.map +1 -1
  5. package/dist/client.d.cts +6 -6
  6. package/dist/client.d.ts +6 -6
  7. package/dist/client.js +136 -7
  8. package/dist/client.js.map +1 -1
  9. package/dist/{collection-client-DxuBDso_.d.cts → collection-client-B7rsTtVj.d.cts} +6 -6
  10. package/dist/{collection-client-Bmr53saa.d.ts → collection-client-C2sMvfme.d.ts} +6 -6
  11. package/dist/{const-Cv1DCsp6.d.cts → const-CRxPTDGt.d.ts} +2 -2
  12. package/dist/{const-BKUqg96Q.d.ts → const-D6ZRQLxI.d.cts} +2 -2
  13. package/dist/{index-DFHLLqYu.d.ts → index-1auUEYrl.d.ts} +3 -3
  14. package/dist/{index-CGsT4AQ8.d.cts → index-Bbpf5t-l.d.cts} +3 -3
  15. package/dist/index.cjs +139 -205
  16. package/dist/index.cjs.map +1 -1
  17. package/dist/index.d.cts +15 -9
  18. package/dist/index.d.ts +15 -9
  19. package/dist/index.js +139 -205
  20. package/dist/index.js.map +1 -1
  21. package/dist/{payload-types-Bk-duc5k.d.cts → payload-types-BnIET0xU.d.cts} +262 -328
  22. package/dist/{payload-types-Bk-duc5k.d.ts → payload-types-BnIET0xU.d.ts} +262 -328
  23. package/dist/query.cjs +48 -2
  24. package/dist/query.cjs.map +1 -1
  25. package/dist/query.d.cts +5 -5
  26. package/dist/query.d.ts +5 -5
  27. package/dist/query.js +48 -2
  28. package/dist/query.js.map +1 -1
  29. package/dist/realtime.d.cts +2 -2
  30. package/dist/realtime.d.ts +2 -2
  31. package/dist/server.cjs +459 -7
  32. package/dist/server.cjs.map +1 -1
  33. package/dist/server.d.cts +13 -8
  34. package/dist/server.d.ts +13 -8
  35. package/dist/server.js +459 -7
  36. package/dist/server.js.map +1 -1
  37. package/dist/{types-D4mjGFj4.d.ts → types-D1y4TgQm.d.ts} +2 -2
  38. package/dist/{types-CEK8uTvU.d.ts → types-DnRC3nLG.d.ts} +256 -9
  39. package/dist/{types-CNdpj2fI.d.cts → types-Dp1oYpD3.d.cts} +2 -2
  40. package/dist/{types-Dhk5NX7Z.d.cts → types-Dzn0LD2N.d.cts} +256 -9
  41. package/dist/ui/form.d.cts +1 -1
  42. package/dist/ui/form.d.ts +1 -1
  43. package/dist/ui/video.cjs +4 -2
  44. package/dist/ui/video.cjs.map +1 -1
  45. package/dist/ui/video.d.cts +4 -2
  46. package/dist/ui/video.d.ts +4 -2
  47. package/dist/ui/video.js +4 -2
  48. package/dist/ui/video.js.map +1 -1
  49. package/dist/webhook.d.cts +5 -5
  50. package/dist/webhook.d.ts +5 -5
  51. package/package.json +8 -28
  52. package/dist/analytics/react.cjs +0 -344
  53. package/dist/analytics/react.cjs.map +0 -1
  54. package/dist/analytics/react.d.cts +0 -24
  55. package/dist/analytics/react.d.ts +0 -24
  56. package/dist/analytics/react.js +0 -319
  57. package/dist/analytics/react.js.map +0 -1
  58. package/dist/analytics.cjs +0 -238
  59. package/dist/analytics.cjs.map +0 -1
  60. package/dist/analytics.d.cts +0 -39
  61. package/dist/analytics.d.ts +0 -39
  62. package/dist/analytics.js +0 -215
  63. package/dist/analytics.js.map +0 -1
@@ -1,6 +1,7 @@
1
- import { P as PublicCollection, C as Collection, S as ServerCollection } from './const-Cv1DCsp6.cjs';
2
- import { C as CollectionType, a as PublicProduct, P as PublicMarket } from './types-CNdpj2fI.cjs';
3
- import { O as Order, k as Transaction, l as Fulfillment, R as Return } from './payload-types-Bk-duc5k.cjs';
1
+ import { P as PublicCollection, C as Collection, S as ServerCollection } from './const-D6ZRQLxI.cjs';
2
+ import { C as CollectionType, a as PublicProduct, P as PublicMarket } from './types-Dp1oYpD3.cjs';
3
+ import { O as Order, k as Transaction, l as Fulfillment, R as Return } from './payload-types-BnIET0xU.cjs';
4
+ import { SDKError } from './errors.cjs';
4
5
 
5
6
  declare const operationBrand: unique symbol;
6
7
  type HttpOperation = {
@@ -476,6 +477,12 @@ type UpdateItemParams = {
476
477
  cartItemId: string;
477
478
  quantity: number;
478
479
  };
480
+ type ServerAddItemParams = AddItemParams & {
481
+ customerToken?: string;
482
+ };
483
+ type ServerUpdateItemParams = UpdateItemParams & {
484
+ customerToken?: string;
485
+ };
479
486
  type RemoveItemParams = {
480
487
  cartToken: string;
481
488
  expectedRevision: number;
@@ -600,9 +607,9 @@ declare class CartApi extends CustomerScopedApi {
600
607
  retrieve(params: RetrieveCartParams): Promise<PublicCart>;
601
608
  mine(params?: CartMineParams | ServerCartMineParams): Promise<CartMineResult>;
602
609
  merge(params: CartMergeParams | ServerCartMergeParams): Promise<CartMergeResult>;
603
- addItem(params: AddItemParams): Promise<CartMutationResult>;
610
+ addItem(params: AddItemParams | ServerAddItemParams): Promise<CartMutationResult>;
604
611
  private mutate;
605
- updateItem(params: UpdateItemParams): Promise<CartMutationResult>;
612
+ updateItem(params: UpdateItemParams | ServerUpdateItemParams): Promise<CartMutationResult>;
606
613
  removeItem(params: RemoveItemParams): Promise<CartMutationResult>;
607
614
  clear(params: ClearCartParams): Promise<CartMutationResult>;
608
615
  updateDiscountCodes(params: UpdateDiscountCodesParams): Promise<CartMutationResult>;
@@ -1070,6 +1077,10 @@ interface CustomerAuthOptions {
1070
1077
  /** Optional hosted OAuth helper configuration */
1071
1078
  oauth?: CustomerOAuthConfig;
1072
1079
  }
1080
+ /** Server timestamp of a completed customer self withdrawal. */
1081
+ interface CustomerWithdrawalResult {
1082
+ withdrawnAt: string;
1083
+ }
1073
1084
 
1074
1085
  type CustomerOrderListOptions = {
1075
1086
  page?: number;
@@ -1194,9 +1205,18 @@ declare class CustomerAuth {
1194
1205
  private rotateWithCanonicalState;
1195
1206
  private _doRefreshToken;
1196
1207
  /**
1197
- * Clear the stored token
1208
+ * Clear local credentials synchronously. This compatibility API cannot
1209
+ * revoke the server-side refresh family; use logoutAsync() for that.
1210
+ * @deprecated Use logoutAsync() to end the direct server session.
1198
1211
  */
1199
1212
  logout(): void;
1213
+ /**
1214
+ * End the current direct refresh family and clear local credentials even if
1215
+ * revocation fails. A legacy access-only session has no refresh family here.
1216
+ */
1217
+ logoutAsync(): Promise<void>;
1218
+ /** Archive the current password account and clear this client's credentials on success. */
1219
+ withdraw(currentPassword: string): Promise<CustomerWithdrawalResult>;
1200
1220
  /**
1201
1221
  * Get the current authenticated customer's profile
1202
1222
  */
@@ -2396,6 +2416,7 @@ type CreateCheckoutParams = {
2396
2416
  idempotencyKey: string;
2397
2417
  };
2398
2418
  type CreateServerCheckoutParams = CreateCheckoutParams & {
2419
+ customerToken?: string;
2399
2420
  clientReferenceId?: string;
2400
2421
  integrationMetadata?: Record<string, string>;
2401
2422
  };
@@ -2453,6 +2474,9 @@ type CreatePaymentSessionParams = {
2453
2474
  profile: 'widget_v2';
2454
2475
  };
2455
2476
  };
2477
+ type CreateServerPaymentSessionParams = CreatePaymentSessionParams & {
2478
+ customerToken?: string;
2479
+ };
2456
2480
  type CreatePortOnePaymentSessionParams = {
2457
2481
  checkoutToken: string;
2458
2482
  idempotencyKey: string;
@@ -2465,6 +2489,9 @@ type CreatePortOnePaymentSessionParams = {
2465
2489
  paymentMethod: PortOneStandardPaymentMethod;
2466
2490
  };
2467
2491
  };
2492
+ type CreateServerPortOnePaymentSessionParams = CreatePortOnePaymentSessionParams & {
2493
+ customerToken?: string;
2494
+ };
2468
2495
  type RetrieveBrowserPaymentSessionParams = {
2469
2496
  paymentSessionId: string;
2470
2497
  checkoutToken: string;
@@ -2501,6 +2528,7 @@ type CreateCustomPaymentSessionParams = {
2501
2528
  provider: string;
2502
2529
  checkoutToken: string;
2503
2530
  idempotencyKey: string;
2531
+ customerToken?: string;
2504
2532
  };
2505
2533
  type CustomPaymentSession = {
2506
2534
  id: string;
@@ -2791,8 +2819,8 @@ declare class PaymentSessionApi extends CustomerScopedApi {
2791
2819
  constructor(options: PaymentSessionApiOptions);
2792
2820
  private post;
2793
2821
  private paymentSession;
2794
- create(params: CreatePaymentSessionParams): Promise<PublicPaymentSession>;
2795
- createPortOne(params: CreatePortOnePaymentSessionParams): Promise<PortOnePublicPaymentSession>;
2822
+ create(params: CreatePaymentSessionParams | CreateServerPaymentSessionParams): Promise<PublicPaymentSession>;
2823
+ createPortOne(params: CreatePortOnePaymentSessionParams | CreateServerPortOnePaymentSessionParams): Promise<PortOnePublicPaymentSession>;
2796
2824
  retrieve(params: RetrieveBrowserPaymentSessionParams | RetrieveServerPaymentSessionParams): Promise<PublicPaymentSession>;
2797
2825
  retrievePortOne(params: RetrieveBrowserPaymentSessionParams | RetrieveServerPaymentSessionParams): Promise<PortOnePublicPaymentSession>;
2798
2826
  cancel(params: CancelBrowserPaymentSessionParams | CancelServerPaymentSessionParams): Promise<PublicPaymentSession>;
@@ -2916,7 +2944,14 @@ type StorefrontGalleryItem = {
2916
2944
  createdAt?: string | null;
2917
2945
  updatedAt?: string | null;
2918
2946
  gallery?: StorefrontContentReference | string | null;
2947
+ /** Missing on older responses; treat it as image. */
2948
+ mediaType?: 'image' | 'video';
2919
2949
  image?: PublicMediaAsset | null;
2950
+ video?: {
2951
+ id?: string | number | null;
2952
+ thumbnail?: PublicMediaAsset | null;
2953
+ availability: 'ready' | 'processing' | 'unavailable';
2954
+ };
2920
2955
  };
2921
2956
  type StorefrontLinksSort = 'createdAt' | '-createdAt' | 'updatedAt' | '-updatedAt' | 'publishedAt' | '-publishedAt' | 'title' | '-title' | 'isFeatured' | '-isFeatured';
2922
2957
  type StorefrontGalleryItemsSort = 'manual' | 'createdAt' | '-createdAt' | 'updatedAt' | '-updatedAt' | 'title' | '-title';
@@ -3238,6 +3273,22 @@ declare class EventsClient {
3238
3273
  private execute;
3239
3274
  }
3240
3275
 
3276
+ interface VideoPlaybackResponse {
3277
+ /** Absolute HLS URL. Free playback always uses the metered gateway. */
3278
+ streamUrl: string;
3279
+ mode: 'gateway' | 'public';
3280
+ }
3281
+ declare class VideoPlaybackClient {
3282
+ private readonly options;
3283
+ constructor(options: {
3284
+ publishableKey: string;
3285
+ secretKey: string;
3286
+ apiUrl?: string;
3287
+ onRequestId?: (id: string | null) => void;
3288
+ });
3289
+ playback(videoId: string): Promise<VideoPlaybackResponse>;
3290
+ }
3291
+
3241
3292
  /**
3242
3293
  * Client-safe market discovery shape (Shopify-like). Structural copy of the
3243
3294
  * private contracts package's `PublicMarketDTO` — the public SDK must not import
@@ -3485,6 +3536,161 @@ declare class CustomerGroupApi extends BaseApi {
3485
3536
  revokeMember(params: RevokeCustomerGroupMemberParams): Promise<CustomerGroupMemberCommandResponse>;
3486
3537
  }
3487
3538
 
3539
+ /** A digest of a provider-safe locator; never send a raw coupon or token. */
3540
+ type ExternalEffectLocator = {
3541
+ kind: 'idempotency_key' | 'lookup_correlation';
3542
+ sha256: string;
3543
+ };
3544
+ type ExternalEffectClaimState = 'pre_dispatch_claimed' | 'armed_unknown' | 'reported_effect' | 'reported_no_effect' | 'reconciliation_required' | 'reconciled_effect' | 'reconciled_no_effect' | 'unresolved_closed';
3545
+ type ExternalEffectClaimErrorReason = 'invalid_evidence' | 'denied' | 'conflict' | 'lease_lost' | 'unknown' | 'quota_exceeded' | 'forbidden' | 'authority_unavailable' | 'internal_error';
3546
+ /** Returns a contract reason from a failed shaped claim operation. */
3547
+ declare function getExternalEffectClaimErrorReason(error: SDKError): ExternalEffectClaimErrorReason | undefined;
3548
+ /** Redacted platform bookkeeping, not proof that a provider performed an effect. */
3549
+ type ExternalEffectClaimSnapshot = {
3550
+ id: string;
3551
+ state: ExternalEffectClaimState;
3552
+ armedAt: string | null;
3553
+ firstReportOutcome: 'effect' | 'no_effect' | null;
3554
+ reportAuthority: 'tenant_supplied_unverified';
3555
+ leaseGranted: boolean;
3556
+ leaseToken: string | null;
3557
+ leaseGeneration: number;
3558
+ };
3559
+ type ClaimExternalEffectParams = {
3560
+ integrationId: string;
3561
+ effectKind: string;
3562
+ logicalKeySha256: string;
3563
+ requestFingerprintSha256: string;
3564
+ locator: ExternalEffectLocator | null;
3565
+ leaseMs: number;
3566
+ };
3567
+ type GetExternalEffectClaimParams = {
3568
+ integrationId: string;
3569
+ claimId: string;
3570
+ };
3571
+ type ExternalEffectLeaseParams = GetExternalEffectClaimParams & {
3572
+ leaseToken: string;
3573
+ leaseGeneration: number;
3574
+ };
3575
+ type ReportExternalEffectParams = GetExternalEffectClaimParams & {
3576
+ outcome: 'effect' | 'no_effect';
3577
+ locator: ExternalEffectLocator | null;
3578
+ providerOperationSha256: string | null;
3579
+ source: 'provider_response' | 'provider_lookup';
3580
+ referenceSha256: string;
3581
+ observedAt: string;
3582
+ };
3583
+ type RecordExternalEffectRecoveryParams = GetExternalEffectClaimParams & {
3584
+ mode: 'safe_replay' | 'lookup';
3585
+ locator: ExternalEffectLocator;
3586
+ requestFingerprintSha256: string;
3587
+ observedAt: string;
3588
+ };
3589
+ /** Server credential required; provider I/O and verification remain in your server. */
3590
+ declare class ExternalEffectClaimsApi extends BaseApi {
3591
+ constructor(options: ServerApiOptions);
3592
+ claim(params: ClaimExternalEffectParams): Promise<ExternalEffectClaimSnapshot>;
3593
+ get(params: GetExternalEffectClaimParams): Promise<ExternalEffectClaimSnapshot>;
3594
+ arm(params: ExternalEffectLeaseParams): Promise<ExternalEffectClaimSnapshot>;
3595
+ release(params: ExternalEffectLeaseParams): Promise<void>;
3596
+ report(params: ReportExternalEffectParams): Promise<ExternalEffectClaimSnapshot>;
3597
+ recovery(params: RecordExternalEffectRecoveryParams): Promise<void>;
3598
+ }
3599
+
3600
+ type InstallationCredentialSnapshot = {
3601
+ installationId: string;
3602
+ providerNamespace: string;
3603
+ providerAccountId: string;
3604
+ version: number;
3605
+ /** Opaque tenant-encrypted value. Decryption and provider use stay in your server. */
3606
+ ciphertext: string;
3607
+ };
3608
+ type InstallationCredentialIdentity = {
3609
+ installationId: string;
3610
+ };
3611
+ type CreateInstallationCredentialParams = {
3612
+ installationId: string;
3613
+ ciphertext: string;
3614
+ };
3615
+ type ReplaceInstallationCredentialParams = {
3616
+ installationId: string;
3617
+ ciphertext: string;
3618
+ expectedVersion: number;
3619
+ };
3620
+ type DisposeInstallationCredentialParams = {
3621
+ installationId: string;
3622
+ expectedVersion: number;
3623
+ };
3624
+ /** Bound server key only. This client never performs provider OAuth or refresh. */
3625
+ declare class InstallationCredentialsApi extends BaseApi {
3626
+ constructor(options: ServerApiOptions);
3627
+ create(params: CreateInstallationCredentialParams): Promise<InstallationCredentialSnapshot>;
3628
+ get(params: InstallationCredentialIdentity): Promise<InstallationCredentialSnapshot>;
3629
+ replace(params: ReplaceInstallationCredentialParams): Promise<InstallationCredentialSnapshot>;
3630
+ dispose(params: DisposeInstallationCredentialParams): Promise<{
3631
+ installationId: string;
3632
+ version: number;
3633
+ state: 'disposed';
3634
+ }>;
3635
+ }
3636
+
3637
+ type ExternalCustomerPreviousState = Record<string, string | number | boolean | null>;
3638
+ type ExternalCustomerLink = {
3639
+ id: string;
3640
+ customerId: string;
3641
+ namespace: string;
3642
+ accountScope: string;
3643
+ externalCustomerId: string | null;
3644
+ state: 'active' | 'released' | 'erased';
3645
+ connectedAt: string;
3646
+ releasedAt: string | null;
3647
+ version: number;
3648
+ previousState: ExternalCustomerPreviousState | null;
3649
+ };
3650
+ type ConnectExternalCustomerLinkParams = {
3651
+ integrationId: string;
3652
+ customerId: string;
3653
+ requestId: string;
3654
+ accountScope: string;
3655
+ externalCustomerId: string;
3656
+ };
3657
+ type GetExternalCustomerLinkParams = {
3658
+ integrationId: string;
3659
+ customerId: string;
3660
+ linkId: string;
3661
+ };
3662
+ type ListExternalCustomerLinksParams = {
3663
+ integrationId: string;
3664
+ customerId?: string;
3665
+ accountScope?: string;
3666
+ externalCustomerId?: string;
3667
+ state?: ExternalCustomerLink['state'];
3668
+ limit?: number;
3669
+ afterId?: string;
3670
+ };
3671
+ type MutateExternalCustomerLinkParams = GetExternalCustomerLinkParams & {
3672
+ requestId: string;
3673
+ expectedVersion: number;
3674
+ };
3675
+ type CaptureExternalCustomerPreviousStateParams = MutateExternalCustomerLinkParams & {
3676
+ previousState: ExternalCustomerPreviousState;
3677
+ };
3678
+ type ExternalCustomerLinkListResponse = {
3679
+ links: ExternalCustomerLink[];
3680
+ nextCursor: string | null;
3681
+ };
3682
+ /** Server-only Customer links. Provider access and changes remain in your server. */
3683
+ declare class ExternalCustomerLinksApi extends BaseApi {
3684
+ constructor(options: ServerApiOptions);
3685
+ private command;
3686
+ connect(params: ConnectExternalCustomerLinkParams): Promise<ExternalCustomerLink>;
3687
+ get(params: GetExternalCustomerLinkParams): Promise<ExternalCustomerLink>;
3688
+ list(params: ListExternalCustomerLinksParams): Promise<ExternalCustomerLinkListResponse>;
3689
+ unlink(params: MutateExternalCustomerLinkParams): Promise<ExternalCustomerLink>;
3690
+ capturePreviousState(params: CaptureExternalCustomerPreviousStateParams): Promise<ExternalCustomerLink>;
3691
+ clearPreviousState(params: MutateExternalCustomerLinkParams): Promise<ExternalCustomerLink>;
3692
+ }
3693
+
3488
3694
  /**
3489
3695
  * SDK-local hand-declarations of the membership wire contract types.
3490
3696
  *
@@ -3543,6 +3749,41 @@ type CancelMembershipParams = {
3543
3749
  type CancelMembershipResponse = {
3544
3750
  status: MembershipStatus;
3545
3751
  };
3752
+ type BillingCustodyWireRequest = {
3753
+ kind: 'billing-custody.v1';
3754
+ membershipId: string;
3755
+ generation: string;
3756
+ action: 'read';
3757
+ } | {
3758
+ kind: 'billing-custody.v1';
3759
+ membershipId: string;
3760
+ generation: string;
3761
+ action: 'put';
3762
+ expectedVersion: number;
3763
+ ciphertext: string;
3764
+ } | {
3765
+ kind: 'billing-custody.v1';
3766
+ membershipId: string;
3767
+ generation: string;
3768
+ action: 'dispose';
3769
+ expectedVersion: number;
3770
+ };
3771
+ /** Server-only delegated billing connection proof is required in addition to sk01_. */
3772
+ type WithoutKind<T> = T extends unknown ? Omit<T, 'kind'> : never;
3773
+ type BillingCustodyParams = WithoutKind<BillingCustodyWireRequest> & {
3774
+ webhookSecret: string;
3775
+ };
3776
+ type BillingCustodyResponse = {
3777
+ action: 'read';
3778
+ version: number;
3779
+ ciphertext: string;
3780
+ } | {
3781
+ action: 'put';
3782
+ version: number;
3783
+ } | {
3784
+ action: 'dispose';
3785
+ version: number;
3786
+ };
3546
3787
  /**
3547
3788
  * The customer's own subscription view. Never includes a payment token or
3548
3789
  * subscribeIntentKey.
@@ -3781,10 +4022,16 @@ interface RootServerClient {
3781
4022
  memberships: {
3782
4023
  subscribe: (params: SubscribeMembershipParams) => Promise<SubscribeMembershipResponse>;
3783
4024
  cancel: (params: CancelMembershipParams) => Promise<CancelMembershipResponse>;
4025
+ billingCustody: (params: BillingCustodyParams) => Promise<BillingCustodyResponse>;
3784
4026
  };
3785
4027
  customerGroups: CustomerGroupApi;
4028
+ externalEffectClaims: ExternalEffectClaimsApi;
4029
+ installationCredentials: InstallationCredentialsApi;
4030
+ externalCustomerLinks: ExternalCustomerLinksApi;
3786
4031
  /** Set on {@link createServerClient} return values; optional for structural mocks. */
3787
4032
  events?: EventsClient;
4033
+ /** Quota-aware VOD admission. */
4034
+ video?: VideoPlaybackClient;
3788
4035
  community: CommunityClient & {
3789
4036
  moderation: {
3790
4037
  banCustomer: (p: BanCustomerParams) => Promise<CommunityBan>;
@@ -3811,4 +4058,4 @@ type DeepPartial<T> = {
3811
4058
  };
3812
4059
  type ExtractArrayType<T> = T extends (infer U)[] ? U : never;
3813
4060
 
3814
- export { type PublicAttribute as $, type AddItemParams as A, type CreatePaymentSessionParams as B, CommerceClient as C, type CreatePortOnePaymentSessionParams as D, EventsClient as E, type CustomerSnapshot as F, type DebugConfig as G, type DeepPartial as H, type ExtractArrayType as I, type MembershipStatus as J, type Money as K, type PayloadMutationResponse as L, MarketDiscovery as M, type PaymentFailureReason as N, type OpenCheckoutPaymentState as O, type PayloadFindResponse as P, type PaymentNextAction as Q, type PaymentProviderStatus as R, type PaymentReconciliationReason as S, type PaymentSessionRole as T, type PortOneHostedPaymentMethod as U, type PortOnePaymentNextAction as V, type PortOnePublicPaymentSession as W, type ProductUpsertInput as X, type ProductUpsertParams as Y, type ProductUpsertResponse as Z, type ProductUpsertVariantInput as _, CommunityClient as a, type CollectionFieldSchema as a$, type PublicCaptureEvidence as a0, type PublicCart as a1, type PublicCartItem as a2, type PublicCartItemAdmission as a3, type PublicCartMarket as a4, type PublicCartReference as a5, type PublicCheckout as a6, type PublicCheckoutItem as a7, type PublicMediaAsset as a8, type PublicMediaSize as a9, type UpdateDiscountCodesParams as aA, type UpdateItemParams as aB, type VariantInput as aC, type Where as aD, RawBaseApi as aE, type ServerApiOptions as aF, ServerCommerceClient as aG, type TenantIntrospectionClient as aH, type SubscribeMembershipParams as aI, type SubscribeMembershipResponse as aJ, CustomerGroupApi as aK, type BanCustomerParams as aL, type CommunityBan as aM, type UnbanCustomerParams as aN, type ClientServerConfig as aO, type RootServerClientWithEvents as aP, type CancelServerPaymentSessionParams as aQ, CartApi as aR, type CartApiOptions as aS, CheckoutApi as aT, type CheckoutApiOptions as aU, type CheckoutListItem as aV, type CheckoutQueryParams as aW, type CheckoutQueryResult as aX, type CheckoutStatus as aY, type CollectionCustomFieldDefinition as aZ, type CollectionCustomFields as a_, type PublicOrder as aa, type PublicOrderAmounts as ab, type PublicOrderItem as ac, type PublicOrderReference as ad, type PublicPaymentSession as ae, type ReconciliationRequired as af, type RemoveItemParams as ag, type RetrieveBrowserPaymentSessionParams as ah, type RetrieveCartParams as ai, type RetrieveCheckoutParams as aj, type RetryConfig as ak, type RootClient as al, type RootCollectionClient as am, type RootReadOnlyQueryBuilder as an, type ShippingLine as ao, type Sort as ap, type SpentCheckoutPaymentState as aq, type StorefrontContentListOptions as ar, type StorefrontContentReference as as, type StorefrontGalleryItem as at, type StorefrontGalleryItemsListOptions as au, type StorefrontGalleryItemsSort as av, type StorefrontLink as aw, type StorefrontLinksListOptions as ax, type StorefrontLinksSort as ay, type UpdateCartAttributesParams as az, ContentClient as b, TENANT_CONTEXT_PATH as b$, type CollectionSchemaResponse as b0, type ConfirmCustomPaymentSessionOptions as b1, type ConfirmCustomPaymentSessionParams as b2, type ConfirmCustomPaymentSessionResponse as b3, type ConfirmTossPaymentSessionParams as b4, type CreateCustomPaymentSessionParams as b5, type CreateServerCheckoutParams as b6, type CreateServerCheckoutResult as b7, type CustomPaymentSession as b8, type CustomPaymentSessionProof as b9, type EventsRangeOccurrence as bA, type EventsRangeParams as bB, type EventsRangeResponse as bC, type EventsTaxonomyItem as bD, type FindPortOnePaymentParams as bE, type FindPortOnePaymentResult as bF, type GrantCustomerGroupMemberParams as bG, type ListCustomerGroupMembersParams as bH, type ListCustomerGroupMembersResponse as bI, ModerationApi as bJ, PaymentSessionApi as bK, type PaymentSessionApiOptions as bL, type PortOnePaymentCurrentState as bM, PortOnePaymentReconciliationApi as bN, type PortOnePaymentSelector as bO, type PortOneReconciliationDisposition as bP, type ReconcilePortOnePaymentParams as bQ, type ReconcilePortOnePaymentResult as bR, type RetrieveCustomPaymentSessionParams as bS, type RetrieveServerCheckoutParams as bT, type RetrieveServerPaymentSessionParams as bU, type RetrievedCustomPaymentSession as bV, type RevokeCustomerGroupMemberParams as bW, type RootServerClient as bX, type ServerCartMergeParams as bY, type ServerCartMineParams as bZ, type ServerCheckout as b_, type CustomerGroupApiOptions as ba, type CustomerGroupManualSource as bb, type CustomerGroupMember as bc, type CustomerGroupMemberCommandResponse as bd, type CustomerGroupMemberSource as be, type CustomerGroupMembershipSource as bf, type CustomerGroupMembershipState as bg, type EventAdmissionAvailabilityParams as bh, type EventAdmissionAvailabilityResponse as bi, type EventAdmissionAvailabilityType as bj, type EventAdmissionPricePresentment as bk, type EventGuestCancelParams as bl, type EventGuestRegistration as bm, type EventGuestRegistrationResponse as bn, type EventRegistrationAnswerInput as bo, type EventRegistrationAttendeeInput as bp, type EventRegistrationPublic as bq, type EventRegistrationRegisterParams as br, type EventRegistrationRegisterResponse as bs, type EventsCalendarItem as bt, type EventsClientOptions as bu, type EventsDateParam as bv, type EventsExternalSource as bw, type EventsLocation as bx, type EventsOccurrenceLocation as by, type EventsRangeEvent as bz, CustomerNamespace as c, type CreateReturnParams as c$, type TenantContextInput as c0, type TenantContextResponse as c1, type TenantCustomFieldType as c2, type TenantFeatureProgressEvidenceValue as c3, type TenantFeatureProgressFeature as c4, type TenantFeatureProgressGroup as c5, type TenantFeatureProgressInput as c6, type TenantFeatureProgressItem as c7, type TenantFeatureProgressItemState as c8, type TenantFeatureProgressResponse as c9, type ProductDetailCatalog as cA, type StockSnapshotResponse as cB, type RootClientWithEvents as cC, type BulkImportFulfillmentsParams as cD, type BulkImportFulfillmentsResponse as cE, type CalculateShippingParams as cF, type CalculateShippingResult as cG, type CancelOrderParams as cH, type CancelOrderResponse as cI, type CancelReasonCode as cJ, type CartDiscountCode as cK, type CartWarning as cL, type CartWarningCode as cM, type Comment as cN, type CommerceClientOptions as cO, type CommunityClientOptions as cP, type CommunityComment as cQ, type CommunityCommentListSort as cR, type CommunityPost as cS, type CommunityPostCategory as cT, type CommunityPostListSort as cU, type CommunityPostTag as cV, type CommunityPublicAuthorSnapshot as cW, type CommunityPublicMediaAsset as cX, type CommunityPublicReference as cY, type CompatibilityProductSelectionParamEvent as cZ, type CreateFulfillmentParams as c_, type TenantFeatureProgressSeverity as ca, type TenantFeatureProgressStatus as cb, type TenantFieldConfigState as cc, TenantIntrospectionApi as cd, type TenantIntrospectionApiOptions as ce, type ApiDeleteOptions as cf, type PublicReadQueryOptions as cg, CustomerAuth as ch, type CustomerProfile as ci, type CustomerAuthResponse as cj, type CustomerLoginData as ck, type CustomerRegisterResponse as cl, type CustomerRegisterData as cm, type CustomerRefreshResponse as cn, type UpdateProfileData as co, type ProductListingPageParams as cp, type ProductListingPageBaseParams as cq, type ProductDetailParams as cr, type ProductDetailCatalogResult as cs, type ProductListingPageCatalogParams as ct, type ProductListingPageResult as cu, type ProductListingGroupsCatalogItem as cv, type ProductListingPageFullParams as cw, type ProductListingGroupsItem as cx, BaseApi as cy, type ProductDetail as cz, type CustomerMembershipView as d, type ProductListingGroupsCatalogResponse as d$, type CustomerAuthOptions as d0, type CustomerAuthorizationUrlInput as d1, type CustomerAuthorizationUrlResult as d2, CustomerOAuth as d3, type CustomerOAuthCallbackResult as d4, type CustomerOAuthConfig as d5, type CustomerOAuthTokenSet as d6, type CustomerOrderListOptions as d7, DiscountApi as d8, type DiscountApiOptions as d9, type ProductDetailImage as dA, type ProductDetailImageMedia as dB, type ProductDetailMedia as dC, type ProductDetailOption as dD, type ProductDetailOptionValue as dE, type ProductDetailResult as dF, type ProductDetailTag as dG, type ProductDetailUnavailableReason as dH, type ProductDetailVariant as dI, type ProductDetailVariantOptionValue as dJ, type ProductDetailVideo as dK, type ProductDisplayMediaSource as dL, type ProductFallbackLocaleOption as dM, type ProductHrefGroup as dN, type ProductHrefOptions as dO, type ProductHrefProduct as dP, type ProductListingCard as dQ, type ProductListingCardOptions as dR, type ProductListingCardPriceRange as dS, type ProductListingCardRepresentativeVariant as dT, type ProductListingGroup as dU, type ProductListingGroupCatalogSummary as dV, type ProductListingGroupCatalogVariant as dW, type ProductListingGroupProjection as dX, type ProductListingGroupSummary as dY, type ProductListingGroupVariant as dZ, type ProductListingGroupsCatalogProduct as d_, type DiscountErrorReasonCode as da, type FeaturedImagePointerInput as db, type GetOrderByPaymentIdParams as dc, type LegacyProductSelectionParamEvent as dd, type ListingGroupsParams as de, MAX_CART_LINE_ADMISSIONS as df, type ManagedPaymentNextAction as dg, type ManagedPublicPaymentSession as dh, type MarketDTO as di, type MediaValue as dj, type NormalizedOptionSwatch as dk, type NormalizedProductSelection as dl, OrderApi as dm, type OrderApiOptions as dn, type OrderByPaymentResult as dp, PRODUCT_PLP_FIND_OPTIONS as dq, PRODUCT_UPSERT_READONLY_FIELD_REASON as dr, PRODUCT_UPSERT_UNKNOWN_FIELD_REASON as ds, type PrepareFulfillmentOrderParams as dt, type PrepareFulfillmentOrderResponse as du, ProductApi as dv, type ProductApiOptions as dw, type ProductDetailBrand as dx, type ProductDetailCatalogVariant as dy, type ProductDetailCategory as dz, type CancelMembershipParams as e, type UpdateReturnParams as e$, type ProductListingGroupsProduct as e0, type ProductListingGroupsResponse as e1, type ProductListingPageFilters as e2, type ProductListingPageSort as e3, type ProductListingProductShape as e4, type ProductListingSwatch as e5, type ProductLocaleOption as e6, type ProductLocaleReadParams as e7, type ProductLocalizedText as e8, type ProductLocalizedValue as e9, type ProductVariantShape as eA, type PublicCheckoutBase as eB, type RequestOptions as eC, type ResolveCancelRefundFailedResponse as eD, type ResolveCancelRefundOutcome as eE, type ResolveCancelRefundParams as eF, type ResolveCancelRefundResponse as eG, type ResolveCancelRefundSucceededResponse as eH, type ResolveProductDisplayMediaInput as eI, type ResolveProductDisplayMediaResult as eJ, type ResolveProductSelectionMediaInput as eK, type ResolveProductSelectionMediaResult as eL, type ResolvedCatalogPrice as eM, type ReturnCancellationReasonCode as eN, type ReturnItem as eO, type ReturnReason as eP, type ReturnWithRefundItem as eQ, type ReturnWithRefundParams as eR, ShippingApi as eS, type ShippingApiOptions as eT, type StockCheckParams as eU, type StockCheckResponse as eV, type StockCheckResult as eW, type StockSnapshotItem as eX, type StockSnapshotParams as eY, type UpdateFulfillmentParams as eZ, type UpdateOrderParams as e_, type ProductMediaResolutionSource as ea, type ProductMoneyRange as eb, type ProductOptionMatrix as ec, type ProductOptionMatrixOption as ed, type ProductOptionMatrixValue as ee, type ProductOptionMatrixVariant as ef, type ProductOptionShape as eg, type ProductOptionValueShape as eh, type ProductOptionValueSwatch as ei, type ProductOptionValueSwatchInput as ej, type ProductPriceRange as ek, type ProductSelectionAvailableSwatch as el, type ProductSelectionAvailableValue as em, type ProductSelectionByOptionValue as en, ProductSelectionCodecError as eo, type ProductSelectionCodecOptions as ep, type ProductSelectionInput as eq, type ProductSelectionMediaPointer as er, type ProductSelectionMediaSource as es, type ProductSelectionOptionValue as et, type ProductSelectionResolution as eu, type ProductSelectionResolutionContext as ev, type ProductSelectionUrlEmit as ew, type ProductSelectionVariant$1 as ex, type ProductUpsertFieldValidationErrorBody as ey, type ProductUpsertFieldValidationErrorReason as ez, type CancelMembershipResponse as f, type ValidateDiscountParams as f0, type ValidateDiscountResult as f1, type WithIdempotencyKey as f2, buildProductHref as f3, buildProductListingCard as f4, buildProductListingGroupProjection as f5, buildProductListingGroupsByOption as f6, buildProductOptionMatrix as f7, buildProductOptionMatrixFromDetail as f8, createProductSelectionCodec as f9, getAvailableOptionValues as fa, getProductSelectionImages as fb, getSelectedValueByOptionId as fc, getVariantAvailableForSale as fd, getVariantAvailableStock as fe, isProductUpsertFieldValidationErrorBody as ff, normalizeProductSelection as fg, normalizeProductSelectionFromMatrix as fh, normalizeSelectedValueIds as fi, parseProductSelection as fj, projectProductToListingShape as fk, resolveFeaturedImagePointer as fl, resolveProductDisplayMedia as fm, resolveProductSelection as fn, resolveProductSelectionFromMatrix as fo, resolveProductSelectionMedia as fp, resolveVariantForSelection as fq, selectNext as fr, selectedSwatchMediaItemId as fs, stringifyProductSelection as ft, toShopifyPriceRangeV2 as fu, type ClientState as g, type ClientConfig as h, type ApiQueryOptions as i, type CancelBrowserPaymentSessionParams as j, type CartMergeParams as k, type CartMergeResult as l, type CartMineResult as m, type CartMutationResult as n, type CheckoutAbandonedReason as o, type CheckoutAmounts as p, type CheckoutOrderReference as q, type CheckoutPaymentSessionRef as r, type CheckoutShippingAddress as s, type ClearCartParams as t, type ClientMetadata as u, type ContentClientOptions as v, type CreateCartParams as w, type CreateCartResult as x, type CreateCheckoutParams as y, type CreateCheckoutResult as z };
4061
+ export { type PublicAttribute as $, type AddItemParams as A, type CreatePaymentSessionParams as B, CommerceClient as C, type CreatePortOnePaymentSessionParams as D, EventsClient as E, type CustomerSnapshot as F, type DebugConfig as G, type DeepPartial as H, type ExtractArrayType as I, type MembershipStatus as J, type Money as K, type PayloadMutationResponse as L, MarketDiscovery as M, type PaymentFailureReason as N, type OpenCheckoutPaymentState as O, type PayloadFindResponse as P, type PaymentNextAction as Q, type PaymentProviderStatus as R, type PaymentReconciliationReason as S, type PaymentSessionRole as T, type PortOneHostedPaymentMethod as U, type PortOnePaymentNextAction as V, type PortOnePublicPaymentSession as W, type ProductUpsertInput as X, type ProductUpsertParams as Y, type ProductUpsertResponse as Z, type ProductUpsertVariantInput as _, CommunityClient as a, type CheckoutApiOptions as a$, type PublicCaptureEvidence as a0, type PublicCart as a1, type PublicCartItem as a2, type PublicCartItemAdmission as a3, type PublicCartMarket as a4, type PublicCartReference as a5, type PublicCheckout as a6, type PublicCheckoutItem as a7, type PublicMediaAsset as a8, type PublicMediaSize as a9, type UpdateDiscountCodesParams as aA, type UpdateItemParams as aB, type VariantInput as aC, type Where as aD, RawBaseApi as aE, type ServerApiOptions as aF, ServerCommerceClient as aG, type TenantIntrospectionClient as aH, type SubscribeMembershipParams as aI, type SubscribeMembershipResponse as aJ, type BillingCustodyParams as aK, type BillingCustodyResponse as aL, CustomerGroupApi as aM, ExternalEffectClaimsApi as aN, InstallationCredentialsApi as aO, ExternalCustomerLinksApi as aP, VideoPlaybackClient as aQ, type BanCustomerParams as aR, type CommunityBan as aS, type UnbanCustomerParams as aT, type ClientServerConfig as aU, type RootServerClientWithEvents as aV, type CancelServerPaymentSessionParams as aW, type CaptureExternalCustomerPreviousStateParams as aX, CartApi as aY, type CartApiOptions as aZ, CheckoutApi as a_, type PublicOrder as aa, type PublicOrderAmounts as ab, type PublicOrderItem as ac, type PublicOrderReference as ad, type PublicPaymentSession as ae, type ReconciliationRequired as af, type RemoveItemParams as ag, type RetrieveBrowserPaymentSessionParams as ah, type RetrieveCartParams as ai, type RetrieveCheckoutParams as aj, type RetryConfig as ak, type RootClient as al, type RootCollectionClient as am, type RootReadOnlyQueryBuilder as an, type ShippingLine as ao, type Sort as ap, type SpentCheckoutPaymentState as aq, type StorefrontContentListOptions as ar, type StorefrontContentReference as as, type StorefrontGalleryItem as at, type StorefrontGalleryItemsListOptions as au, type StorefrontGalleryItemsSort as av, type StorefrontLink as aw, type StorefrontLinksListOptions as ax, type StorefrontLinksSort as ay, type UpdateCartAttributesParams as az, ContentClient as b, type GetExternalCustomerLinkParams as b$, type CheckoutListItem as b0, type CheckoutQueryParams as b1, type CheckoutQueryResult as b2, type CheckoutStatus as b3, type ClaimExternalEffectParams as b4, type CollectionCustomFieldDefinition as b5, type CollectionCustomFields as b6, type CollectionFieldSchema as b7, type CollectionSchemaResponse as b8, type ConfirmCustomPaymentSessionOptions as b9, type EventGuestRegistrationResponse as bA, type EventRegistrationAnswerInput as bB, type EventRegistrationAttendeeInput as bC, type EventRegistrationPublic as bD, type EventRegistrationRegisterParams as bE, type EventRegistrationRegisterResponse as bF, type EventsCalendarItem as bG, type EventsClientOptions as bH, type EventsDateParam as bI, type EventsExternalSource as bJ, type EventsLocation as bK, type EventsOccurrenceLocation as bL, type EventsRangeEvent as bM, type EventsRangeOccurrence as bN, type EventsRangeParams as bO, type EventsRangeResponse as bP, type EventsTaxonomyItem as bQ, type ExternalCustomerLink as bR, type ExternalCustomerLinkListResponse as bS, type ExternalCustomerPreviousState as bT, type ExternalEffectClaimErrorReason as bU, type ExternalEffectClaimSnapshot as bV, type ExternalEffectClaimState as bW, type ExternalEffectLeaseParams as bX, type ExternalEffectLocator as bY, type FindPortOnePaymentParams as bZ, type FindPortOnePaymentResult as b_, type ConfirmCustomPaymentSessionParams as ba, type ConfirmCustomPaymentSessionResponse as bb, type ConfirmTossPaymentSessionParams as bc, type ConnectExternalCustomerLinkParams as bd, type CreateCustomPaymentSessionParams as be, type CreateInstallationCredentialParams as bf, type CreateServerCheckoutParams as bg, type CreateServerCheckoutResult as bh, type CreateServerPaymentSessionParams as bi, type CreateServerPortOnePaymentSessionParams as bj, type CustomPaymentSession as bk, type CustomPaymentSessionProof as bl, type CustomerGroupApiOptions as bm, type CustomerGroupManualSource as bn, type CustomerGroupMember as bo, type CustomerGroupMemberCommandResponse as bp, type CustomerGroupMemberSource as bq, type CustomerGroupMembershipSource as br, type CustomerGroupMembershipState as bs, type DisposeInstallationCredentialParams as bt, type EventAdmissionAvailabilityParams as bu, type EventAdmissionAvailabilityResponse as bv, type EventAdmissionAvailabilityType as bw, type EventAdmissionPricePresentment as bx, type EventGuestCancelParams as by, type EventGuestRegistration as bz, CustomerNamespace as c, type ProductListingPageResult as c$, type GetExternalEffectClaimParams as c0, type GrantCustomerGroupMemberParams as c1, type InstallationCredentialIdentity as c2, type InstallationCredentialSnapshot as c3, type ListCustomerGroupMembersParams as c4, type ListCustomerGroupMembersResponse as c5, type ListExternalCustomerLinksParams as c6, ModerationApi as c7, type MutateExternalCustomerLinkParams as c8, PaymentSessionApi as c9, type TenantFeatureProgressFeature as cA, type TenantFeatureProgressGroup as cB, type TenantFeatureProgressInput as cC, type TenantFeatureProgressItem as cD, type TenantFeatureProgressItemState as cE, type TenantFeatureProgressResponse as cF, type TenantFeatureProgressSeverity as cG, type TenantFeatureProgressStatus as cH, type TenantFieldConfigState as cI, TenantIntrospectionApi as cJ, type TenantIntrospectionApiOptions as cK, getExternalEffectClaimErrorReason as cL, type ApiDeleteOptions as cM, type PublicReadQueryOptions as cN, CustomerAuth as cO, type CustomerProfile as cP, type CustomerAuthResponse as cQ, type CustomerLoginData as cR, type CustomerRegisterResponse as cS, type CustomerRegisterData as cT, type CustomerRefreshResponse as cU, type UpdateProfileData as cV, type ProductListingPageParams as cW, type ProductListingPageBaseParams as cX, type ProductDetailParams as cY, type ProductDetailCatalogResult as cZ, type ProductListingPageCatalogParams as c_, type PaymentSessionApiOptions as ca, type PortOnePaymentCurrentState as cb, PortOnePaymentReconciliationApi as cc, type PortOnePaymentSelector as cd, type PortOneReconciliationDisposition as ce, type ReconcilePortOnePaymentParams as cf, type ReconcilePortOnePaymentResult as cg, type RecordExternalEffectRecoveryParams as ch, type ReplaceInstallationCredentialParams as ci, type ReportExternalEffectParams as cj, type RetrieveCustomPaymentSessionParams as ck, type RetrieveServerCheckoutParams as cl, type RetrieveServerPaymentSessionParams as cm, type RetrievedCustomPaymentSession as cn, type RevokeCustomerGroupMemberParams as co, type RootServerClient as cp, type ServerAddItemParams as cq, type ServerCartMergeParams as cr, type ServerCartMineParams as cs, type ServerCheckout as ct, type ServerUpdateItemParams as cu, TENANT_CONTEXT_PATH as cv, type TenantContextInput as cw, type TenantContextResponse as cx, type TenantCustomFieldType as cy, type TenantFeatureProgressEvidenceValue as cz, type CustomerMembershipView as d, PRODUCT_UPSERT_UNKNOWN_FIELD_REASON as d$, type ProductListingGroupsCatalogItem as d0, type ProductListingPageFullParams as d1, type ProductListingGroupsItem as d2, BaseApi as d3, type ProductDetail as d4, type ProductDetailCatalog as d5, type StockSnapshotResponse as d6, type RootClientWithEvents as d7, type BillingCustodyWireRequest as d8, type BulkImportFulfillmentsParams as d9, type CustomerAuthorizationUrlInput as dA, type CustomerAuthorizationUrlResult as dB, CustomerOAuth as dC, type CustomerOAuthCallbackResult as dD, type CustomerOAuthConfig as dE, type CustomerOAuthTokenSet as dF, type CustomerOrderListOptions as dG, type CustomerWithdrawalResult as dH, DiscountApi as dI, type DiscountApiOptions as dJ, type DiscountErrorReasonCode as dK, type FeaturedImagePointerInput as dL, type GetOrderByPaymentIdParams as dM, type LegacyProductSelectionParamEvent as dN, type ListingGroupsParams as dO, MAX_CART_LINE_ADMISSIONS as dP, type ManagedPaymentNextAction as dQ, type ManagedPublicPaymentSession as dR, type MarketDTO as dS, type MediaValue as dT, type NormalizedOptionSwatch as dU, type NormalizedProductSelection as dV, OrderApi as dW, type OrderApiOptions as dX, type OrderByPaymentResult as dY, PRODUCT_PLP_FIND_OPTIONS as dZ, PRODUCT_UPSERT_READONLY_FIELD_REASON as d_, type BulkImportFulfillmentsResponse as da, type CalculateShippingParams as db, type CalculateShippingResult as dc, type CancelOrderParams as dd, type CancelOrderResponse as de, type CancelReasonCode as df, type CartDiscountCode as dg, type CartWarning as dh, type CartWarningCode as di, type Comment as dj, type CommerceClientOptions as dk, type CommunityClientOptions as dl, type CommunityComment as dm, type CommunityCommentListSort as dn, type CommunityPost as dp, type CommunityPostCategory as dq, type CommunityPostListSort as dr, type CommunityPostTag as ds, type CommunityPublicAuthorSnapshot as dt, type CommunityPublicMediaAsset as du, type CommunityPublicReference as dv, type CompatibilityProductSelectionParamEvent as dw, type CreateFulfillmentParams as dx, type CreateReturnParams as dy, type CustomerAuthOptions as dz, type CancelMembershipParams as e, type ProductSelectionMediaSource as e$, type PrepareFulfillmentOrderParams as e0, type PrepareFulfillmentOrderResponse as e1, ProductApi as e2, type ProductApiOptions as e3, type ProductDetailBrand as e4, type ProductDetailCatalogVariant as e5, type ProductDetailCategory as e6, type ProductDetailImage as e7, type ProductDetailImageMedia as e8, type ProductDetailMedia as e9, type ProductListingGroupsResponse as eA, type ProductListingPageFilters as eB, type ProductListingPageSort as eC, type ProductListingProductShape as eD, type ProductListingSwatch as eE, type ProductLocaleOption as eF, type ProductLocaleReadParams as eG, type ProductLocalizedText as eH, type ProductLocalizedValue as eI, type ProductMediaResolutionSource as eJ, type ProductMoneyRange as eK, type ProductOptionMatrix as eL, type ProductOptionMatrixOption as eM, type ProductOptionMatrixValue as eN, type ProductOptionMatrixVariant as eO, type ProductOptionShape as eP, type ProductOptionValueShape as eQ, type ProductOptionValueSwatch as eR, type ProductOptionValueSwatchInput as eS, type ProductPriceRange as eT, type ProductSelectionAvailableSwatch as eU, type ProductSelectionAvailableValue as eV, type ProductSelectionByOptionValue as eW, ProductSelectionCodecError as eX, type ProductSelectionCodecOptions as eY, type ProductSelectionInput as eZ, type ProductSelectionMediaPointer as e_, type ProductDetailOption as ea, type ProductDetailOptionValue as eb, type ProductDetailResult as ec, type ProductDetailTag as ed, type ProductDetailUnavailableReason as ee, type ProductDetailVariant as ef, type ProductDetailVariantOptionValue as eg, type ProductDetailVideo as eh, type ProductDisplayMediaSource as ei, type ProductFallbackLocaleOption as ej, type ProductHrefGroup as ek, type ProductHrefOptions as el, type ProductHrefProduct as em, type ProductListingCard as en, type ProductListingCardOptions as eo, type ProductListingCardPriceRange as ep, type ProductListingCardRepresentativeVariant as eq, type ProductListingGroup as er, type ProductListingGroupCatalogSummary as es, type ProductListingGroupCatalogVariant as et, type ProductListingGroupProjection as eu, type ProductListingGroupSummary as ev, type ProductListingGroupVariant as ew, type ProductListingGroupsCatalogProduct as ex, type ProductListingGroupsCatalogResponse as ey, type ProductListingGroupsProduct as ez, type CancelMembershipResponse as f, selectNext as f$, type ProductSelectionOptionValue as f0, type ProductSelectionResolution as f1, type ProductSelectionResolutionContext as f2, type ProductSelectionUrlEmit as f3, type ProductSelectionVariant$1 as f4, type ProductUpsertFieldValidationErrorBody as f5, type ProductUpsertFieldValidationErrorReason as f6, type ProductVariantShape as f7, type PublicCheckoutBase as f8, type RequestOptions as f9, type ValidateDiscountResult as fA, type VideoPlaybackResponse as fB, type WithIdempotencyKey as fC, buildProductHref as fD, buildProductListingCard as fE, buildProductListingGroupProjection as fF, buildProductListingGroupsByOption as fG, buildProductOptionMatrix as fH, buildProductOptionMatrixFromDetail as fI, createProductSelectionCodec as fJ, getAvailableOptionValues as fK, getProductSelectionImages as fL, getSelectedValueByOptionId as fM, getVariantAvailableForSale as fN, getVariantAvailableStock as fO, isProductUpsertFieldValidationErrorBody as fP, normalizeProductSelection as fQ, normalizeProductSelectionFromMatrix as fR, normalizeSelectedValueIds as fS, parseProductSelection as fT, projectProductToListingShape as fU, resolveFeaturedImagePointer as fV, resolveProductDisplayMedia as fW, resolveProductSelection as fX, resolveProductSelectionFromMatrix as fY, resolveProductSelectionMedia as fZ, resolveVariantForSelection as f_, type ResolveCancelRefundFailedResponse as fa, type ResolveCancelRefundOutcome as fb, type ResolveCancelRefundParams as fc, type ResolveCancelRefundResponse as fd, type ResolveCancelRefundSucceededResponse as fe, type ResolveProductDisplayMediaInput as ff, type ResolveProductDisplayMediaResult as fg, type ResolveProductSelectionMediaInput as fh, type ResolveProductSelectionMediaResult as fi, type ResolvedCatalogPrice as fj, type ReturnCancellationReasonCode as fk, type ReturnItem as fl, type ReturnReason as fm, type ReturnWithRefundItem as fn, type ReturnWithRefundParams as fo, ShippingApi as fp, type ShippingApiOptions as fq, type StockCheckParams as fr, type StockCheckResponse as fs, type StockCheckResult as ft, type StockSnapshotItem as fu, type StockSnapshotParams as fv, type UpdateFulfillmentParams as fw, type UpdateOrderParams as fx, type UpdateReturnParams as fy, type ValidateDiscountParams as fz, type ClientState as g, selectedSwatchMediaItemId as g0, stringifyProductSelection as g1, toShopifyPriceRangeV2 as g2, type ClientConfig as h, type ApiQueryOptions as i, type CancelBrowserPaymentSessionParams as j, type CartMergeParams as k, type CartMergeResult as l, type CartMineResult as m, type CartMutationResult as n, type CheckoutAbandonedReason as o, type CheckoutAmounts as p, type CheckoutOrderReference as q, type CheckoutPaymentSessionRef as r, type CheckoutShippingAddress as s, type ClearCartParams as t, type ClientMetadata as u, type ContentClientOptions as v, type CreateCartParams as w, type CreateCartResult as x, type CreateCheckoutParams as y, type CreateCheckoutResult as z };
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { F as Form } from '../payload-types-Bk-duc5k.cjs';
2
+ import { F as Form } from '../payload-types-BnIET0xU.cjs';
3
3
  import { RichTextData } from './rich-text.cjs';
4
4
  import '@payloadcms/richtext-lexical';
5
5
  import '@payloadcms/richtext-lexical/lexical';
package/dist/ui/form.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { F as Form } from '../payload-types-Bk-duc5k.js';
2
+ import { F as Form } from '../payload-types-BnIET0xU.js';
3
3
  import { RichTextData } from './rich-text.js';
4
4
  import '@payloadcms/richtext-lexical';
5
5
  import '@payloadcms/richtext-lexical/lexical';
package/dist/ui/video.cjs CHANGED
@@ -93,6 +93,7 @@ function resolvePoster(props) {
93
93
  if (url) return url;
94
94
  }
95
95
  }
96
+ if (props.streamUrl) return void 0;
96
97
  const playbackId = resolvePlaybackId(props.video);
97
98
  if (!playbackId) return void 0;
98
99
  return getVideoThumbnail(playbackId, {
@@ -112,6 +113,7 @@ var VideoPlayer = (0, import_react.forwardRef)(
112
113
  function VideoPlayer2(props, ref) {
113
114
  const {
114
115
  video,
116
+ streamUrl,
115
117
  accentColor,
116
118
  primaryColor,
117
119
  secondaryColor,
@@ -142,7 +144,7 @@ var VideoPlayer = (0, import_react.forwardRef)(
142
144
  const poster = resolvePoster(props);
143
145
  const aspectRatio = resolveAspectRatio(video);
144
146
  const status = resolveStatus(video);
145
- if (!playbackId || typeof video !== "string" && status !== "ready") {
147
+ if (!streamUrl && !playbackId || typeof video !== "string" && status !== "ready") {
146
148
  return /* @__PURE__ */ import_react.default.createElement(
147
149
  "div",
148
150
  {
@@ -166,7 +168,7 @@ var VideoPlayer = (0, import_react.forwardRef)(
166
168
  import_mux_player_react.default,
167
169
  {
168
170
  ref,
169
- playbackId,
171
+ ...streamUrl ? { src: streamUrl } : { playbackId },
170
172
  streamType,
171
173
  accentColor,
172
174
  primaryColor,
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/ui/Video/index.tsx","../../src/utils/video.ts"],"sourcesContent":["'use client'\n\nimport React, { forwardRef, type CSSProperties } from 'react'\nimport MuxPlayer from '@mux/mux-player-react'\nimport type {\n MuxPlayerRefAttributes,\n MuxPlayerProps,\n} from '@mux/mux-player-react'\nimport type { Video, Image } from '../../payload-types'\nimport { getVideoThumbnail } from '../../utils/video'\n\n// Re-export video utilities for convenience\nexport {\n getVideoThumbnail,\n getVideoGif,\n getVideoStreamUrl,\n getVideoMp4Url,\n getVideoStoryboard,\n type VideoThumbnailOptions,\n type VideoGifOptions,\n} from '../../utils/video'\n\n// ── CSS custom properties ──\n\nexport interface VideoPlayerCSSProperties extends CSSProperties {\n [key: `--${string}`]: string | undefined\n}\n\n// ── Props ──\n\nexport interface VideoPlayerProps {\n /** Video document or playbackId string */\n video: Video | string\n\n // ── Theming ──\n /** Theme accent color */\n accentColor?: string\n /** Theme primary color (controls) */\n primaryColor?: string\n /** Theme secondary color (time display, etc.) */\n secondaryColor?: string\n\n // ── Playback ──\n /** Title overlay (auto-resolved from Video.title if omitted) */\n title?: string\n /** Autoplay behavior */\n autoPlay?: boolean | 'muted' | 'any'\n /** Loop playback */\n loop?: boolean\n /** Muted by default */\n muted?: boolean\n /** Preload strategy (default: 'metadata') */\n preload?: 'auto' | 'metadata' | 'none'\n /** Start time in seconds */\n startTime?: number\n /** Stream type (default: 'on-demand') */\n streamType?: 'on-demand' | 'live' | 'll-live'\n /** Audio-only mode */\n audio?: boolean\n /** Disable keyboard shortcuts */\n noHotKeys?: boolean\n /** Max resolution cap */\n maxResolution?: '720p' | '1080p' | '1440p' | '2160p'\n\n // ── Poster ──\n /** Thumbnail time for auto-generated poster (default: 0) */\n thumbnailTime?: number\n /** Custom poster URL (overrides auto-generated thumbnail) */\n poster?: string\n\n // ── Placeholder (when video not ready) ──\n /** Placeholder text when video is not ready */\n placeholder?: string\n /** CSS class for the placeholder */\n placeholderClassName?: string\n /** Inline styles for the placeholder */\n placeholderStyle?: CSSProperties\n\n // ── Styling ──\n /** CSS class */\n className?: string\n /** Inline styles (supports --mux CSS custom properties) */\n style?: VideoPlayerCSSProperties\n\n // ── Events ──\n onPlay?: () => void\n onPause?: () => void\n onEnded?: () => void\n onTimeUpdate?: () => void\n onLoadedData?: () => void\n onError?: () => void\n\n // ── Escape hatch ──\n /** Extra props forwarded directly to MuxPlayer */\n playerProps?: Omit<\n MuxPlayerProps,\n | 'playbackId'\n | 'streamType'\n | 'accentColor'\n | 'primaryColor'\n | 'secondaryColor'\n | 'title'\n | 'autoPlay'\n | 'loop'\n | 'muted'\n | 'preload'\n | 'startTime'\n | 'poster'\n | 'audio'\n | 'nohotkeys'\n | 'maxResolution'\n | 'className'\n | 'style'\n >\n}\n\n// ── Helpers ──\n\nfunction resolvePlaybackId(video: Video | string): string | null {\n if (typeof video === 'string') return video\n return video.muxPlaybackId ?? null\n}\n\nfunction resolveTitle(props: VideoPlayerProps): string | undefined {\n if (props.title !== undefined) return props.title\n if (typeof props.video !== 'string') return props.video.title ?? undefined\n return undefined\n}\n\nfunction resolvePoster(props: VideoPlayerProps): string | undefined {\n // 1. Explicit poster URL (highest priority)\n if (props.poster) return props.poster\n\n // 2. Video.thumbnail uploaded image\n if (typeof props.video !== 'string' && props.video.thumbnail) {\n const thumb = props.video.thumbnail\n if (typeof thumb === 'object' && thumb !== null && 'url' in thumb) {\n const url = (thumb as Image).url\n if (url) return url\n }\n }\n\n // 3. Auto-generate from Mux image API\n const playbackId = resolvePlaybackId(props.video)\n if (!playbackId) return undefined\n return getVideoThumbnail(playbackId, {\n width: 1280,\n time: props.thumbnailTime ?? 0,\n })\n}\n\nfunction resolveAspectRatio(video: Video | string): string | undefined {\n if (typeof video === 'string') return undefined\n return video.aspectRatio ?? undefined\n}\n\nfunction resolveStatus(video: Video | string): string {\n if (typeof video === 'string') return 'ready'\n return video.muxStatus ?? 'waiting'\n}\n\n// ── Component ──\n\n/**\n * Mux video player component.\n * Requires `@mux/mux-player-react` (optional peer dependency).\n *\n * @example Basic usage\n * ```tsx\n * import { VideoPlayer } from '@01.software/sdk/ui/video'\n *\n * <VideoPlayer video={videoDoc} />\n * ```\n *\n * @example With playback ID string\n * ```tsx\n * <VideoPlayer video=\"abc123def\" autoPlay=\"muted\" loop />\n * ```\n *\n * @example Custom theming with CSS custom properties\n * ```tsx\n * <VideoPlayer\n * video={videoDoc}\n * accentColor=\"#f43f5e\"\n * primaryColor=\"#fff\"\n * className=\"rounded-lg overflow-hidden\"\n * style={{ '--controls-backdrop-color': 'rgba(0,0,0,0.6)' }}\n * />\n * ```\n *\n * @example Audio-only mode\n * ```tsx\n * <VideoPlayer video={videoDoc} audio />\n * ```\n */\nexport const VideoPlayer: React.ForwardRefExoticComponent<\n VideoPlayerProps & React.RefAttributes<MuxPlayerRefAttributes>\n> = forwardRef<MuxPlayerRefAttributes, VideoPlayerProps>(\n function VideoPlayer(props, ref) {\n const {\n video,\n accentColor,\n primaryColor,\n secondaryColor,\n autoPlay,\n loop,\n muted,\n preload = 'metadata',\n startTime,\n streamType = 'on-demand',\n audio,\n noHotKeys,\n maxResolution,\n placeholder,\n placeholderClassName,\n placeholderStyle,\n className,\n style,\n onPlay,\n onPause,\n onEnded,\n onTimeUpdate,\n onLoadedData,\n onError,\n playerProps,\n } = props\n\n const playbackId = resolvePlaybackId(video)\n const title = resolveTitle(props)\n const poster = resolvePoster(props)\n const aspectRatio = resolveAspectRatio(video)\n const status = resolveStatus(video)\n\n // Show placeholder when no playbackId or video not ready\n if (!playbackId || (typeof video !== 'string' && status !== 'ready')) {\n return (\n <div\n className={placeholderClassName ?? className}\n style={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n aspectRatio: aspectRatio ?? '16/9',\n backgroundColor: '#000',\n color: '#888',\n fontSize: 14,\n width: '100%',\n ...placeholderStyle,\n }}\n >\n {placeholder ??\n (status === 'preparing'\n ? 'Video is processing...'\n : status === 'errored'\n ? 'Video processing failed'\n : 'Video not available')}\n </div>\n )\n }\n\n return (\n <MuxPlayer\n ref={ref}\n playbackId={playbackId}\n streamType={streamType}\n accentColor={accentColor}\n primaryColor={primaryColor}\n secondaryColor={secondaryColor}\n title={title}\n autoPlay={autoPlay}\n loop={loop}\n muted={muted}\n preload={preload}\n startTime={startTime}\n poster={poster}\n audio={audio}\n nohotkeys={noHotKeys}\n maxResolution={maxResolution}\n className={className}\n style={{\n aspectRatio: aspectRatio ?? '16/9',\n width: '100%',\n ...style,\n }}\n onPlay={onPlay}\n onPause={onPause}\n onEnded={onEnded}\n onTimeUpdate={onTimeUpdate}\n onLoadedData={onLoadedData}\n onError={onError}\n {...playerProps}\n />\n )\n },\n)\n\n// ── Type Exports ──\n\nexport type { MuxPlayerRefAttributes as VideoPlayerRef } from '@mux/mux-player-react'\nexport type { Video as VideoData } from '../../payload-types'\n","const MUX_IMAGE_BASE = 'https://image.mux.com'\nconst MUX_STREAM_BASE = 'https://stream.mux.com'\n\n// ── Thumbnail ──\n\nexport interface VideoThumbnailOptions {\n /** Width in pixels (default: 640) */\n width?: number\n /** Height in pixels (auto if omitted) */\n height?: number\n /** Time offset in seconds (default: 0) */\n time?: number\n /** Fit mode (default: 'smartcrop') */\n fitMode?: 'preserve' | 'stretch' | 'crop' | 'smartcrop' | 'pad'\n /** Flip horizontally */\n flipH?: boolean\n /** Flip vertically */\n flipV?: boolean\n /** Rotation in degrees (90, 180, 270) */\n rotate?: 90 | 180 | 270\n}\n\n/**\n * Returns a Mux thumbnail URL for a video.\n *\n * @example\n * ```ts\n * getVideoThumbnail('abc123')\n * // => 'https://image.mux.com/abc123/thumbnail.jpg?width=640'\n *\n * getVideoThumbnail('abc123', { width: 320, time: 5 })\n * // => 'https://image.mux.com/abc123/thumbnail.jpg?width=320&time=5'\n * ```\n */\nexport function getVideoThumbnail(\n playbackId: string,\n options?: VideoThumbnailOptions,\n): string {\n const params = new URLSearchParams()\n params.set('width', String(options?.width ?? 640))\n if (options?.height) params.set('height', String(options.height))\n if (options?.time != null) params.set('time', String(options.time))\n if (options?.fitMode) params.set('fit_mode', options.fitMode)\n if (options?.flipH) params.set('flip_h', 'true')\n if (options?.flipV) params.set('flip_v', 'true')\n if (options?.rotate) params.set('rotate', String(options.rotate))\n return `${MUX_IMAGE_BASE}/${playbackId}/thumbnail.jpg?${params}`\n}\n\n// ── Animated GIF ──\n\nexport interface VideoGifOptions {\n /** Width in pixels (default: 320) */\n width?: number\n /** Start time in seconds (default: 0) */\n start?: number\n /** End time in seconds (default: start + 5) */\n end?: number\n /** Frames per second (default: 15) */\n fps?: number\n}\n\n/**\n * Returns a Mux animated GIF URL for a video.\n *\n * @example\n * ```ts\n * getVideoGif('abc123')\n * // => 'https://image.mux.com/abc123/animated.gif?width=320'\n *\n * getVideoGif('abc123', { width: 240, start: 2, end: 6 })\n * // => 'https://image.mux.com/abc123/animated.gif?width=240&start=2&end=6'\n * ```\n */\nexport function getVideoGif(\n playbackId: string,\n options?: VideoGifOptions,\n): string {\n const params = new URLSearchParams()\n params.set('width', String(options?.width ?? 320))\n if (options?.start != null) params.set('start', String(options.start))\n if (options?.end != null) params.set('end', String(options.end))\n if (options?.fps) params.set('fps', String(options.fps))\n return `${MUX_IMAGE_BASE}/${playbackId}/animated.gif?${params}`\n}\n\n// ── Storyboard ──\n\n/**\n * Returns a Mux storyboard VTT URL for timeline hover previews.\n *\n * @example\n * ```ts\n * getVideoStoryboard('abc123')\n * // => 'https://image.mux.com/abc123/storyboard.vtt'\n * ```\n */\nexport function getVideoStoryboard(playbackId: string): string {\n return `${MUX_IMAGE_BASE}/${playbackId}/storyboard.vtt`\n}\n\n// ── Stream / Playback URLs ──\n\n/**\n * Returns the HLS stream URL for a video.\n *\n * @example\n * ```ts\n * getVideoStreamUrl('abc123')\n * // => 'https://stream.mux.com/abc123.m3u8'\n * ```\n */\nexport function getVideoStreamUrl(playbackId: string): string {\n return `${MUX_STREAM_BASE}/${playbackId}.m3u8`\n}\n\n/**\n * Returns a Mux MP4 download URL for a video.\n * Only available if the asset was created with `mp4_support` enabled.\n *\n * @example\n * ```ts\n * getVideoMp4Url('abc123', 'high')\n * // => 'https://stream.mux.com/abc123/high.mp4'\n * ```\n */\nexport function getVideoMp4Url(\n playbackId: string,\n resolution: 'high' | 'medium' | 'low' = 'high',\n): string {\n return `${MUX_STREAM_BASE}/${playbackId}/${resolution}.mp4`\n}\n"],"mappings":"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","names":["VideoPlayer","React","MuxPlayer"]}
1
+ {"version":3,"sources":["../../src/ui/Video/index.tsx","../../src/utils/video.ts"],"sourcesContent":["'use client'\n\nimport React, { forwardRef, type CSSProperties } from 'react'\nimport MuxPlayer from '@mux/mux-player-react'\nimport type {\n MuxPlayerRefAttributes,\n MuxPlayerProps,\n} from '@mux/mux-player-react'\nimport type { Video, Image } from '../../payload-types'\nimport { getVideoThumbnail } from '../../utils/video'\n\n// Re-export video utilities for convenience\nexport {\n getVideoThumbnail,\n getVideoGif,\n getVideoStreamUrl,\n getVideoMp4Url,\n getVideoStoryboard,\n type VideoThumbnailOptions,\n type VideoGifOptions,\n} from '../../utils/video'\n\n// ── CSS custom properties ──\n\nexport interface VideoPlayerCSSProperties extends CSSProperties {\n [key: `--${string}`]: string | undefined\n}\n\n// ── Props ──\n\nexport interface VideoPlayerProps {\n /** Video document or playbackId string */\n video: Video | string\n /** HLS URL from client.video.playback(video.id); required for gated Free VOD. */\n streamUrl?: string\n\n // ── Theming ──\n /** Theme accent color */\n accentColor?: string\n /** Theme primary color (controls) */\n primaryColor?: string\n /** Theme secondary color (time display, etc.) */\n secondaryColor?: string\n\n // ── Playback ──\n /** Title overlay (auto-resolved from Video.title if omitted) */\n title?: string\n /** Autoplay behavior */\n autoPlay?: boolean | 'muted' | 'any'\n /** Loop playback */\n loop?: boolean\n /** Muted by default */\n muted?: boolean\n /** Preload strategy (default: 'metadata') */\n preload?: 'auto' | 'metadata' | 'none'\n /** Start time in seconds */\n startTime?: number\n /** Stream type (default: 'on-demand') */\n streamType?: 'on-demand' | 'live' | 'll-live'\n /** Audio-only mode */\n audio?: boolean\n /** Disable keyboard shortcuts */\n noHotKeys?: boolean\n /** Max resolution cap */\n maxResolution?: '720p' | '1080p' | '1440p' | '2160p'\n\n // ── Poster ──\n /** Thumbnail time for auto-generated poster (default: 0) */\n thumbnailTime?: number\n /** Custom poster URL (overrides auto-generated thumbnail) */\n poster?: string\n\n // ── Placeholder (when video not ready) ──\n /** Placeholder text when video is not ready */\n placeholder?: string\n /** CSS class for the placeholder */\n placeholderClassName?: string\n /** Inline styles for the placeholder */\n placeholderStyle?: CSSProperties\n\n // ── Styling ──\n /** CSS class */\n className?: string\n /** Inline styles (supports --mux CSS custom properties) */\n style?: VideoPlayerCSSProperties\n\n // ── Events ──\n onPlay?: () => void\n onPause?: () => void\n onEnded?: () => void\n onTimeUpdate?: () => void\n onLoadedData?: () => void\n onError?: () => void\n\n // ── Escape hatch ──\n /** Extra props forwarded directly to MuxPlayer */\n playerProps?: Omit<\n MuxPlayerProps,\n | 'playbackId'\n | 'src'\n | 'streamType'\n | 'accentColor'\n | 'primaryColor'\n | 'secondaryColor'\n | 'title'\n | 'autoPlay'\n | 'loop'\n | 'muted'\n | 'preload'\n | 'startTime'\n | 'poster'\n | 'audio'\n | 'nohotkeys'\n | 'maxResolution'\n | 'className'\n | 'style'\n >\n}\n\n// ── Helpers ──\n\nfunction resolvePlaybackId(video: Video | string): string | null {\n if (typeof video === 'string') return video\n return video.muxPlaybackId ?? null\n}\n\nfunction resolveTitle(props: VideoPlayerProps): string | undefined {\n if (props.title !== undefined) return props.title\n if (typeof props.video !== 'string') return props.video.title ?? undefined\n return undefined\n}\n\nfunction resolvePoster(props: VideoPlayerProps): string | undefined {\n // 1. Explicit poster URL (highest priority)\n if (props.poster) return props.poster\n\n // 2. Video.thumbnail uploaded image\n if (typeof props.video !== 'string' && props.video.thumbnail) {\n const thumb = props.video.thumbnail\n if (typeof thumb === 'object' && thumb !== null && 'url' in thumb) {\n const url = (thumb as Image).url\n if (url) return url\n }\n }\n\n // 3. Auto-generate from Mux image API\n if (props.streamUrl) return undefined\n const playbackId = resolvePlaybackId(props.video)\n if (!playbackId) return undefined\n return getVideoThumbnail(playbackId, {\n width: 1280,\n time: props.thumbnailTime ?? 0,\n })\n}\n\nfunction resolveAspectRatio(video: Video | string): string | undefined {\n if (typeof video === 'string') return undefined\n return video.aspectRatio ?? undefined\n}\n\nfunction resolveStatus(video: Video | string): string {\n if (typeof video === 'string') return 'ready'\n return video.muxStatus ?? 'waiting'\n}\n\n// ── Component ──\n\n/**\n * Mux video player component.\n * Requires `@mux/mux-player-react` (optional peer dependency).\n *\n * @example Basic usage\n * ```tsx\n * import { VideoPlayer } from '@01.software/sdk/ui/video'\n *\n * <VideoPlayer video={videoDoc} />\n * ```\n *\n * @example With playback ID string\n * ```tsx\n * <VideoPlayer video=\"abc123def\" autoPlay=\"muted\" loop />\n * ```\n *\n * @example Custom theming with CSS custom properties\n * ```tsx\n * <VideoPlayer\n * video={videoDoc}\n * accentColor=\"#f43f5e\"\n * primaryColor=\"#fff\"\n * className=\"rounded-lg overflow-hidden\"\n * style={{ '--controls-backdrop-color': 'rgba(0,0,0,0.6)' }}\n * />\n * ```\n *\n * @example Audio-only mode\n * ```tsx\n * <VideoPlayer video={videoDoc} audio />\n * ```\n */\nexport const VideoPlayer: React.ForwardRefExoticComponent<\n VideoPlayerProps & React.RefAttributes<MuxPlayerRefAttributes>\n> = forwardRef<MuxPlayerRefAttributes, VideoPlayerProps>(\n function VideoPlayer(props, ref) {\n const {\n video,\n streamUrl,\n accentColor,\n primaryColor,\n secondaryColor,\n autoPlay,\n loop,\n muted,\n preload = 'metadata',\n startTime,\n streamType = 'on-demand',\n audio,\n noHotKeys,\n maxResolution,\n placeholder,\n placeholderClassName,\n placeholderStyle,\n className,\n style,\n onPlay,\n onPause,\n onEnded,\n onTimeUpdate,\n onLoadedData,\n onError,\n playerProps,\n } = props\n\n const playbackId = resolvePlaybackId(video)\n const title = resolveTitle(props)\n const poster = resolvePoster(props)\n const aspectRatio = resolveAspectRatio(video)\n const status = resolveStatus(video)\n\n // Show placeholder when no playbackId or video not ready\n if (\n (!streamUrl && !playbackId) ||\n (typeof video !== 'string' && status !== 'ready')\n ) {\n return (\n <div\n className={placeholderClassName ?? className}\n style={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n aspectRatio: aspectRatio ?? '16/9',\n backgroundColor: '#000',\n color: '#888',\n fontSize: 14,\n width: '100%',\n ...placeholderStyle,\n }}\n >\n {placeholder ??\n (status === 'preparing'\n ? 'Video is processing...'\n : status === 'errored'\n ? 'Video processing failed'\n : 'Video not available')}\n </div>\n )\n }\n\n return (\n <MuxPlayer\n ref={ref}\n {...(streamUrl ? { src: streamUrl } : { playbackId: playbackId! })}\n streamType={streamType}\n accentColor={accentColor}\n primaryColor={primaryColor}\n secondaryColor={secondaryColor}\n title={title}\n autoPlay={autoPlay}\n loop={loop}\n muted={muted}\n preload={preload}\n startTime={startTime}\n poster={poster}\n audio={audio}\n nohotkeys={noHotKeys}\n maxResolution={maxResolution}\n className={className}\n style={{\n aspectRatio: aspectRatio ?? '16/9',\n width: '100%',\n ...style,\n }}\n onPlay={onPlay}\n onPause={onPause}\n onEnded={onEnded}\n onTimeUpdate={onTimeUpdate}\n onLoadedData={onLoadedData}\n onError={onError}\n {...playerProps}\n />\n )\n },\n)\n\n// ── Type Exports ──\n\nexport type { MuxPlayerRefAttributes as VideoPlayerRef } from '@mux/mux-player-react'\nexport type { Video as VideoData } from '../../payload-types'\n","const MUX_IMAGE_BASE = 'https://image.mux.com'\nconst MUX_STREAM_BASE = 'https://stream.mux.com'\n\n// ── Thumbnail ──\n\nexport interface VideoThumbnailOptions {\n /** Width in pixels (default: 640) */\n width?: number\n /** Height in pixels (auto if omitted) */\n height?: number\n /** Time offset in seconds (default: 0) */\n time?: number\n /** Fit mode (default: 'smartcrop') */\n fitMode?: 'preserve' | 'stretch' | 'crop' | 'smartcrop' | 'pad'\n /** Flip horizontally */\n flipH?: boolean\n /** Flip vertically */\n flipV?: boolean\n /** Rotation in degrees (90, 180, 270) */\n rotate?: 90 | 180 | 270\n}\n\n/**\n * Returns a Mux thumbnail URL for a video.\n *\n * @example\n * ```ts\n * getVideoThumbnail('abc123')\n * // => 'https://image.mux.com/abc123/thumbnail.jpg?width=640'\n *\n * getVideoThumbnail('abc123', { width: 320, time: 5 })\n * // => 'https://image.mux.com/abc123/thumbnail.jpg?width=320&time=5'\n * ```\n */\nexport function getVideoThumbnail(\n playbackId: string,\n options?: VideoThumbnailOptions,\n): string {\n const params = new URLSearchParams()\n params.set('width', String(options?.width ?? 640))\n if (options?.height) params.set('height', String(options.height))\n if (options?.time != null) params.set('time', String(options.time))\n if (options?.fitMode) params.set('fit_mode', options.fitMode)\n if (options?.flipH) params.set('flip_h', 'true')\n if (options?.flipV) params.set('flip_v', 'true')\n if (options?.rotate) params.set('rotate', String(options.rotate))\n return `${MUX_IMAGE_BASE}/${playbackId}/thumbnail.jpg?${params}`\n}\n\n// ── Animated GIF ──\n\nexport interface VideoGifOptions {\n /** Width in pixels (default: 320) */\n width?: number\n /** Start time in seconds (default: 0) */\n start?: number\n /** End time in seconds (default: start + 5) */\n end?: number\n /** Frames per second (default: 15) */\n fps?: number\n}\n\n/**\n * Returns a Mux animated GIF URL for a video.\n *\n * @example\n * ```ts\n * getVideoGif('abc123')\n * // => 'https://image.mux.com/abc123/animated.gif?width=320'\n *\n * getVideoGif('abc123', { width: 240, start: 2, end: 6 })\n * // => 'https://image.mux.com/abc123/animated.gif?width=240&start=2&end=6'\n * ```\n */\nexport function getVideoGif(\n playbackId: string,\n options?: VideoGifOptions,\n): string {\n const params = new URLSearchParams()\n params.set('width', String(options?.width ?? 320))\n if (options?.start != null) params.set('start', String(options.start))\n if (options?.end != null) params.set('end', String(options.end))\n if (options?.fps) params.set('fps', String(options.fps))\n return `${MUX_IMAGE_BASE}/${playbackId}/animated.gif?${params}`\n}\n\n// ── Storyboard ──\n\n/**\n * Returns a Mux storyboard VTT URL for timeline hover previews.\n *\n * @example\n * ```ts\n * getVideoStoryboard('abc123')\n * // => 'https://image.mux.com/abc123/storyboard.vtt'\n * ```\n */\nexport function getVideoStoryboard(playbackId: string): string {\n return `${MUX_IMAGE_BASE}/${playbackId}/storyboard.vtt`\n}\n\n// ── Stream / Playback URLs ──\n\n/**\n * Returns the HLS stream URL for a video.\n *\n * @example\n * ```ts\n * getVideoStreamUrl('abc123')\n * // => 'https://stream.mux.com/abc123.m3u8'\n * ```\n */\nexport function getVideoStreamUrl(playbackId: string): string {\n return `${MUX_STREAM_BASE}/${playbackId}.m3u8`\n}\n\n/**\n * Returns a Mux MP4 download URL for a video.\n * Only available if the asset was created with `mp4_support` enabled.\n *\n * @example\n * ```ts\n * getVideoMp4Url('abc123', 'high')\n * // => 'https://stream.mux.com/abc123/high.mp4'\n * ```\n */\nexport function getVideoMp4Url(\n playbackId: string,\n resolution: 'high' | 'medium' | 'low' = 'high',\n): string {\n return `${MUX_STREAM_BASE}/${playbackId}/${resolution}.mp4`\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAEA,mBAAsD;AACtD,8BAAsB;;;ACHtB,IAAM,iBAAiB;AACvB,IAAM,kBAAkB;AAiCjB,SAAS,kBACd,YACA,SACQ;AACR,QAAM,SAAS,IAAI,gBAAgB;AACnC,SAAO,IAAI,SAAS,OAAO,SAAS,SAAS,GAAG,CAAC;AACjD,MAAI,SAAS,OAAQ,QAAO,IAAI,UAAU,OAAO,QAAQ,MAAM,CAAC;AAChE,MAAI,SAAS,QAAQ,KAAM,QAAO,IAAI,QAAQ,OAAO,QAAQ,IAAI,CAAC;AAClE,MAAI,SAAS,QAAS,QAAO,IAAI,YAAY,QAAQ,OAAO;AAC5D,MAAI,SAAS,MAAO,QAAO,IAAI,UAAU,MAAM;AAC/C,MAAI,SAAS,MAAO,QAAO,IAAI,UAAU,MAAM;AAC/C,MAAI,SAAS,OAAQ,QAAO,IAAI,UAAU,OAAO,QAAQ,MAAM,CAAC;AAChE,SAAO,GAAG,cAAc,IAAI,UAAU,kBAAkB,MAAM;AAChE;AA2BO,SAAS,YACd,YACA,SACQ;AACR,QAAM,SAAS,IAAI,gBAAgB;AACnC,SAAO,IAAI,SAAS,OAAO,SAAS,SAAS,GAAG,CAAC;AACjD,MAAI,SAAS,SAAS,KAAM,QAAO,IAAI,SAAS,OAAO,QAAQ,KAAK,CAAC;AACrE,MAAI,SAAS,OAAO,KAAM,QAAO,IAAI,OAAO,OAAO,QAAQ,GAAG,CAAC;AAC/D,MAAI,SAAS,IAAK,QAAO,IAAI,OAAO,OAAO,QAAQ,GAAG,CAAC;AACvD,SAAO,GAAG,cAAc,IAAI,UAAU,iBAAiB,MAAM;AAC/D;AAaO,SAAS,mBAAmB,YAA4B;AAC7D,SAAO,GAAG,cAAc,IAAI,UAAU;AACxC;AAaO,SAAS,kBAAkB,YAA4B;AAC5D,SAAO,GAAG,eAAe,IAAI,UAAU;AACzC;AAYO,SAAS,eACd,YACA,aAAwC,QAChC;AACR,SAAO,GAAG,eAAe,IAAI,UAAU,IAAI,UAAU;AACvD;;;ADVA,SAAS,kBAAkB,OAAsC;AAC/D,MAAI,OAAO,UAAU,SAAU,QAAO;AACtC,SAAO,MAAM,iBAAiB;AAChC;AAEA,SAAS,aAAa,OAA6C;AACjE,MAAI,MAAM,UAAU,OAAW,QAAO,MAAM;AAC5C,MAAI,OAAO,MAAM,UAAU,SAAU,QAAO,MAAM,MAAM,SAAS;AACjE,SAAO;AACT;AAEA,SAAS,cAAc,OAA6C;AAElE,MAAI,MAAM,OAAQ,QAAO,MAAM;AAG/B,MAAI,OAAO,MAAM,UAAU,YAAY,MAAM,MAAM,WAAW;AAC5D,UAAM,QAAQ,MAAM,MAAM;AAC1B,QAAI,OAAO,UAAU,YAAY,UAAU,QAAQ,SAAS,OAAO;AACjE,YAAM,MAAO,MAAgB;AAC7B,UAAI,IAAK,QAAO;AAAA,IAClB;AAAA,EACF;AAGA,MAAI,MAAM,UAAW,QAAO;AAC5B,QAAM,aAAa,kBAAkB,MAAM,KAAK;AAChD,MAAI,CAAC,WAAY,QAAO;AACxB,SAAO,kBAAkB,YAAY;AAAA,IACnC,OAAO;AAAA,IACP,MAAM,MAAM,iBAAiB;AAAA,EAC/B,CAAC;AACH;AAEA,SAAS,mBAAmB,OAA2C;AACrE,MAAI,OAAO,UAAU,SAAU,QAAO;AACtC,SAAO,MAAM,eAAe;AAC9B;AAEA,SAAS,cAAc,OAA+B;AACpD,MAAI,OAAO,UAAU,SAAU,QAAO;AACtC,SAAO,MAAM,aAAa;AAC5B;AAoCO,IAAM,kBAET;AAAA,EACF,SAASA,aAAY,OAAO,KAAK;AAC/B,UAAM;AAAA,MACJ;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA,UAAU;AAAA,MACV;AAAA,MACA,aAAa;AAAA,MACb;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,IACF,IAAI;AAEJ,UAAM,aAAa,kBAAkB,KAAK;AAC1C,UAAM,QAAQ,aAAa,KAAK;AAChC,UAAM,SAAS,cAAc,KAAK;AAClC,UAAM,cAAc,mBAAmB,KAAK;AAC5C,UAAM,SAAS,cAAc,KAAK;AAGlC,QACG,CAAC,aAAa,CAAC,cACf,OAAO,UAAU,YAAY,WAAW,SACzC;AACA,aACE,6BAAAC,QAAA;AAAA,QAAC;AAAA;AAAA,UACC,WAAW,wBAAwB;AAAA,UACnC,OAAO;AAAA,YACL,SAAS;AAAA,YACT,YAAY;AAAA,YACZ,gBAAgB;AAAA,YAChB,aAAa,eAAe;AAAA,YAC5B,iBAAiB;AAAA,YACjB,OAAO;AAAA,YACP,UAAU;AAAA,YACV,OAAO;AAAA,YACP,GAAG;AAAA,UACL;AAAA;AAAA,QAEC,gBACE,WAAW,cACR,2BACA,WAAW,YACT,4BACA;AAAA,MACV;AAAA,IAEJ;AAEA,WACE,6BAAAA,QAAA;AAAA,MAAC,wBAAAC;AAAA,MAAA;AAAA,QACC;AAAA,QACC,GAAI,YAAY,EAAE,KAAK,UAAU,IAAI,EAAE,WAAwB;AAAA,QAChE;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA,WAAW;AAAA,QACX;AAAA,QACA;AAAA,QACA,OAAO;AAAA,UACL,aAAa,eAAe;AAAA,UAC5B,OAAO;AAAA,UACP,GAAG;AAAA,QACL;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACC,GAAG;AAAA;AAAA,IACN;AAAA,EAEJ;AACF;","names":["VideoPlayer","React","MuxPlayer"]}
@@ -1,7 +1,7 @@
1
1
  import React, { CSSProperties } from 'react';
2
2
  import { MuxPlayerProps, MuxPlayerRefAttributes } from '@mux/mux-player-react';
3
3
  export { MuxPlayerRefAttributes as VideoPlayerRef } from '@mux/mux-player-react';
4
- import { V as Video } from '../payload-types-Bk-duc5k.cjs';
4
+ import { V as Video } from '../payload-types-BnIET0xU.cjs';
5
5
  export { V as VideoGifOptions, a as VideoThumbnailOptions, g as getVideoGif, b as getVideoMp4Url, c as getVideoStoryboard, d as getVideoStreamUrl, e as getVideoThumbnail } from '../video-WR_TFO9a.cjs';
6
6
 
7
7
  interface VideoPlayerCSSProperties extends CSSProperties {
@@ -10,6 +10,8 @@ interface VideoPlayerCSSProperties extends CSSProperties {
10
10
  interface VideoPlayerProps {
11
11
  /** Video document or playbackId string */
12
12
  video: Video | string;
13
+ /** HLS URL from client.video.playback(video.id); required for gated Free VOD. */
14
+ streamUrl?: string;
13
15
  /** Theme accent color */
14
16
  accentColor?: string;
15
17
  /** Theme primary color (controls) */
@@ -57,7 +59,7 @@ interface VideoPlayerProps {
57
59
  onLoadedData?: () => void;
58
60
  onError?: () => void;
59
61
  /** Extra props forwarded directly to MuxPlayer */
60
- playerProps?: Omit<MuxPlayerProps, 'playbackId' | 'streamType' | 'accentColor' | 'primaryColor' | 'secondaryColor' | 'title' | 'autoPlay' | 'loop' | 'muted' | 'preload' | 'startTime' | 'poster' | 'audio' | 'nohotkeys' | 'maxResolution' | 'className' | 'style'>;
62
+ playerProps?: Omit<MuxPlayerProps, 'playbackId' | 'src' | 'streamType' | 'accentColor' | 'primaryColor' | 'secondaryColor' | 'title' | 'autoPlay' | 'loop' | 'muted' | 'preload' | 'startTime' | 'poster' | 'audio' | 'nohotkeys' | 'maxResolution' | 'className' | 'style'>;
61
63
  }
62
64
  /**
63
65
  * Mux video player component.
@@ -1,7 +1,7 @@
1
1
  import React, { CSSProperties } from 'react';
2
2
  import { MuxPlayerProps, MuxPlayerRefAttributes } from '@mux/mux-player-react';
3
3
  export { MuxPlayerRefAttributes as VideoPlayerRef } from '@mux/mux-player-react';
4
- import { V as Video } from '../payload-types-Bk-duc5k.js';
4
+ import { V as Video } from '../payload-types-BnIET0xU.js';
5
5
  export { V as VideoGifOptions, a as VideoThumbnailOptions, g as getVideoGif, b as getVideoMp4Url, c as getVideoStoryboard, d as getVideoStreamUrl, e as getVideoThumbnail } from '../video-WR_TFO9a.js';
6
6
 
7
7
  interface VideoPlayerCSSProperties extends CSSProperties {
@@ -10,6 +10,8 @@ interface VideoPlayerCSSProperties extends CSSProperties {
10
10
  interface VideoPlayerProps {
11
11
  /** Video document or playbackId string */
12
12
  video: Video | string;
13
+ /** HLS URL from client.video.playback(video.id); required for gated Free VOD. */
14
+ streamUrl?: string;
13
15
  /** Theme accent color */
14
16
  accentColor?: string;
15
17
  /** Theme primary color (controls) */
@@ -57,7 +59,7 @@ interface VideoPlayerProps {
57
59
  onLoadedData?: () => void;
58
60
  onError?: () => void;
59
61
  /** Extra props forwarded directly to MuxPlayer */
60
- playerProps?: Omit<MuxPlayerProps, 'playbackId' | 'streamType' | 'accentColor' | 'primaryColor' | 'secondaryColor' | 'title' | 'autoPlay' | 'loop' | 'muted' | 'preload' | 'startTime' | 'poster' | 'audio' | 'nohotkeys' | 'maxResolution' | 'className' | 'style'>;
62
+ playerProps?: Omit<MuxPlayerProps, 'playbackId' | 'src' | 'streamType' | 'accentColor' | 'primaryColor' | 'secondaryColor' | 'title' | 'autoPlay' | 'loop' | 'muted' | 'preload' | 'startTime' | 'poster' | 'audio' | 'nohotkeys' | 'maxResolution' | 'className' | 'style'>;
61
63
  }
62
64
  /**
63
65
  * Mux video player component.