bitsnap-react 1.18.1 → 1.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.
Files changed (153) hide show
  1. package/AGENTS.md +21 -0
  2. package/README.md +45 -0
  3. package/dist/BitsnapCart-LHJ6KOTV.css +2 -0
  4. package/dist/BitsnapCart-LHJ6KOTV.css.map +1 -0
  5. package/dist/BitsnapCart-V4S4EXYV.js +2 -0
  6. package/dist/BitsnapCart-V4S4EXYV.js.map +1 -0
  7. package/dist/BitsnapCart-Z6JFYNH2.mjs +2 -0
  8. package/dist/CartProvider-5NP4WACK.js +2 -0
  9. package/dist/CartProvider-5NP4WACK.js.map +1 -0
  10. package/dist/CartProvider-G7FQUPXL.mjs +2 -0
  11. package/dist/PanelModelFiles-EKQRLF46.js.map +1 -1
  12. package/dist/analytics.js +1 -1
  13. package/dist/analytics.js.map +1 -1
  14. package/dist/analytics.mjs +1 -1
  15. package/dist/catalog.js +1 -1
  16. package/dist/catalog.js.map +1 -1
  17. package/dist/catalog.mjs +1 -1
  18. package/dist/chat.css +2 -0
  19. package/dist/chat.css.map +1 -0
  20. package/dist/chat.d.mts +173 -0
  21. package/dist/chat.d.ts +173 -0
  22. package/dist/chat.js +2 -0
  23. package/dist/chat.js.map +1 -0
  24. package/dist/chat.mjs +2 -0
  25. package/dist/chat.mjs.map +1 -0
  26. package/dist/chunk-2G46TAUX.mjs +2 -0
  27. package/dist/chunk-2G46TAUX.mjs.map +1 -0
  28. package/dist/{chunk-N3B25GTY.js → chunk-4Y233NII.js} +2 -2
  29. package/dist/chunk-4Y233NII.js.map +1 -0
  30. package/dist/chunk-5M3OUOMU.mjs +5 -0
  31. package/dist/chunk-5M3OUOMU.mjs.map +1 -0
  32. package/dist/chunk-6Q3VGPSF.js.map +1 -1
  33. package/dist/chunk-A2ZDFN3J.mjs +2 -0
  34. package/dist/{chunk-ZM5T4TQW.mjs.map → chunk-A2ZDFN3J.mjs.map} +1 -1
  35. package/dist/{chunk-DR7WYI37.js → chunk-AQYHQY2Y.js} +2 -2
  36. package/dist/chunk-AQYHQY2Y.js.map +1 -0
  37. package/dist/{chunk-62WDFH7K.mjs → chunk-BTERIY6N.mjs} +2 -2
  38. package/dist/chunk-C736F727.js +2 -0
  39. package/dist/chunk-C736F727.js.map +1 -0
  40. package/dist/chunk-EFN4OW2C.js +2 -0
  41. package/dist/chunk-EFN4OW2C.js.map +1 -0
  42. package/dist/chunk-EMR4YXNY.mjs +2 -0
  43. package/dist/chunk-EMR4YXNY.mjs.map +1 -0
  44. package/dist/chunk-GHBRR665.js +2 -0
  45. package/dist/chunk-GHBRR665.js.map +1 -0
  46. package/dist/chunk-HKRH6FI6.mjs +2 -0
  47. package/dist/chunk-HKRH6FI6.mjs.map +1 -0
  48. package/dist/chunk-HP3I6D2R.js +2 -0
  49. package/dist/chunk-HP3I6D2R.js.map +1 -0
  50. package/dist/{chunk-G4SEOVLD.js → chunk-IRZJIPUF.js} +2 -2
  51. package/dist/chunk-IRZJIPUF.js.map +1 -0
  52. package/dist/chunk-IXQCN7MR.mjs +2 -0
  53. package/dist/chunk-IXQCN7MR.mjs.map +1 -0
  54. package/dist/chunk-IXX6SUMB.mjs +2 -0
  55. package/dist/chunk-IXX6SUMB.mjs.map +1 -0
  56. package/dist/chunk-JSDGZ4NY.js.map +1 -1
  57. package/dist/chunk-KDL35KEI.js +2 -0
  58. package/dist/chunk-KDL35KEI.js.map +1 -0
  59. package/dist/chunk-KO7ZERN5.mjs +2 -0
  60. package/dist/chunk-KO7ZERN5.mjs.map +1 -0
  61. package/dist/chunk-KOYBZORL.js.map +1 -1
  62. package/dist/chunk-KZWCVKLU.js +5 -0
  63. package/dist/chunk-KZWCVKLU.js.map +1 -0
  64. package/dist/chunk-LHNTSQYO.mjs +2 -0
  65. package/dist/chunk-LHNTSQYO.mjs.map +1 -0
  66. package/dist/chunk-LHQEM3CU.mjs +2 -0
  67. package/dist/chunk-LHQEM3CU.mjs.map +1 -0
  68. package/dist/chunk-MDAFPGPA.js +2 -0
  69. package/dist/chunk-MDAFPGPA.js.map +1 -0
  70. package/dist/chunk-Q337IQNA.js.map +1 -1
  71. package/dist/chunk-RJPQMDIQ.js +2 -0
  72. package/dist/chunk-RJPQMDIQ.js.map +1 -0
  73. package/dist/{chunk-GKJURMDO.mjs → chunk-TW25G7XX.mjs} +2 -2
  74. package/dist/{chunk-GKJURMDO.mjs.map → chunk-TW25G7XX.mjs.map} +1 -1
  75. package/dist/{chunk-UTUPPMLK.mjs → chunk-URQBHNJK.mjs} +2 -2
  76. package/dist/chunk-W3RGQYPD.js.map +1 -1
  77. package/dist/chunk-XEXPQFKN.mjs +2 -0
  78. package/dist/chunk-XEXPQFKN.mjs.map +1 -0
  79. package/dist/chunk-YPA6MMGJ.js +2 -0
  80. package/dist/chunk-YPA6MMGJ.js.map +1 -0
  81. package/dist/chunk-Z3YOJ6NZ.js +2 -0
  82. package/dist/chunk-Z3YOJ6NZ.js.map +1 -0
  83. package/dist/consent.js.map +1 -1
  84. package/dist/course.d.mts +2 -14
  85. package/dist/course.d.ts +2 -14
  86. package/dist/course.js +1 -1
  87. package/dist/course.js.map +1 -1
  88. package/dist/course.mjs +1 -1
  89. package/dist/course.mjs.map +1 -1
  90. package/dist/embed/analytics.js +1 -1
  91. package/dist/errors.js.map +1 -1
  92. package/dist/index.css +1 -1
  93. package/dist/index.css.map +1 -1
  94. package/dist/index.d.mts +50 -33
  95. package/dist/index.d.ts +50 -33
  96. package/dist/index.js +1 -1
  97. package/dist/index.js.map +1 -1
  98. package/dist/index.mjs +1 -1
  99. package/dist/index.mjs.map +1 -1
  100. package/dist/internal.js.map +1 -1
  101. package/dist/methods-33CWGKNA.mjs +2 -0
  102. package/dist/methods-33CWGKNA.mjs.map +1 -0
  103. package/dist/methods-4GB652MQ.js +2 -0
  104. package/dist/methods-4GB652MQ.js.map +1 -0
  105. package/dist/model-files-client-P4PORZJ6.js.map +1 -1
  106. package/dist/models.js.map +1 -1
  107. package/dist/returns.js +1 -1
  108. package/dist/returns.js.map +1 -1
  109. package/dist/returns.mjs +1 -1
  110. package/dist/texts-9kfgClsA.d.mts +14 -0
  111. package/dist/texts-9kfgClsA.d.ts +14 -0
  112. package/dist/{types-D6LsoycW.d.mts → types-CjWyHunk.d.mts} +9 -1
  113. package/dist/{types-ClFCVzk_.d.ts → types-DfqzDP9k.d.ts} +9 -1
  114. package/dist/viewer3d.js.map +1 -1
  115. package/dist/viewer3d.mjs +2 -2
  116. package/dist/viewer3d.mjs.map +1 -1
  117. package/dist/widgets-Bsojw94g.d.ts +556 -0
  118. package/dist/widgets-u7xMJbsY.d.mts +556 -0
  119. package/package.json +16 -2
  120. package/dist/CartProvider-CC6YIZVS.js +0 -2
  121. package/dist/CartProvider-CC6YIZVS.js.map +0 -1
  122. package/dist/CartProvider-ZL65WZN6.mjs +0 -2
  123. package/dist/chunk-2XSLIZ27.js +0 -2
  124. package/dist/chunk-2XSLIZ27.js.map +0 -1
  125. package/dist/chunk-5OCGXVLC.js +0 -2
  126. package/dist/chunk-5OCGXVLC.js.map +0 -1
  127. package/dist/chunk-5YN752OV.mjs +0 -2
  128. package/dist/chunk-5YN752OV.mjs.map +0 -1
  129. package/dist/chunk-7BG22YBF.js +0 -5
  130. package/dist/chunk-7BG22YBF.js.map +0 -1
  131. package/dist/chunk-AHISXVEE.js +0 -2
  132. package/dist/chunk-AHISXVEE.js.map +0 -1
  133. package/dist/chunk-DR7WYI37.js.map +0 -1
  134. package/dist/chunk-EOFJAQPT.js +0 -2
  135. package/dist/chunk-EOFJAQPT.js.map +0 -1
  136. package/dist/chunk-G4SEOVLD.js.map +0 -1
  137. package/dist/chunk-IGQZP4YR.mjs +0 -2
  138. package/dist/chunk-IGQZP4YR.mjs.map +0 -1
  139. package/dist/chunk-N3B25GTY.js.map +0 -1
  140. package/dist/chunk-VWA3ZCNI.mjs +0 -2
  141. package/dist/chunk-VWA3ZCNI.mjs.map +0 -1
  142. package/dist/chunk-YGE2223J.mjs +0 -5
  143. package/dist/chunk-YGE2223J.mjs.map +0 -1
  144. package/dist/chunk-ZKT4N553.mjs +0 -2
  145. package/dist/chunk-ZKT4N553.mjs.map +0 -1
  146. package/dist/chunk-ZM5T4TQW.mjs +0 -2
  147. package/dist/methods-7DWKFCPK.js +0 -2
  148. package/dist/methods-7DWKFCPK.js.map +0 -1
  149. package/dist/methods-DQTADIN4.mjs +0 -2
  150. /package/dist/{CartProvider-ZL65WZN6.mjs.map → BitsnapCart-Z6JFYNH2.mjs.map} +0 -0
  151. /package/dist/{methods-DQTADIN4.mjs.map → CartProvider-G7FQUPXL.mjs.map} +0 -0
  152. /package/dist/{chunk-62WDFH7K.mjs.map → chunk-BTERIY6N.mjs.map} +0 -0
  153. /package/dist/{chunk-UTUPPMLK.mjs.map → chunk-URQBHNJK.mjs.map} +0 -0
package/dist/index.d.mts CHANGED
@@ -6,11 +6,14 @@ export { BitsnapReturns, BitsnapReturnsProps, BitsnapReturnsProvider, BitsnapRet
6
6
  export { b as RETURNS_SLOT_NAMES, R as ReturnsAppearance, c as ReturnsAppearanceElements, d as ReturnsAppearanceTokens, e as ReturnsSlotAppearance, f as ReturnsSlotName, h as ReturnsTextKey, a as ReturnsTexts, g as ReturnsTheme } from './texts-LGhuQfA9.mjs';
7
7
  import { CSSProperties, ReactNode } from 'react';
8
8
  import z__default from 'zod';
9
- import { P as PanelLoginProps, a as PanelProps, G as GetThemeOutput } from './types-D6LsoycW.mjs';
10
- export { b as PanelScreen, c as PanelSearchParamsType } from './types-D6LsoycW.mjs';
9
+ import { P as PanelLoginProps, a as PanelProps, G as GetThemeOutput } from './types-CjWyHunk.mjs';
10
+ export { b as PanelScreen, c as PanelSearchParamsType } from './types-CjWyHunk.mjs';
11
+ import { e as ChatThreadProps, c as ChannelProps } from './widgets-u7xMJbsY.mjs';
12
+ export { d as ChatBuyRequest, C as ChatTexts, f as ChatWidgetBaseProps } from './widgets-u7xMJbsY.mjs';
11
13
  import './models.mjs';
12
14
  import '@bufbuild/protobuf/wkt';
13
15
  import '@bufbuild/protobuf';
16
+ import './texts-9kfgClsA.mjs';
14
17
 
15
18
  type AppleButtonType = "plain" | "add-money" | "book" | "buy" | "check-out" | "continue" | "contribute" | "donate" | "order" | "pay" | "reload" | "rent" | "set-up" | "subscribe" | "support" | "tip" | "top-up";
16
19
  type ColorType = "black" | "white" | "white-outline";
@@ -719,36 +722,6 @@ type Err = {
719
722
  };
720
723
  declare function Err(message: string, type?: ErrTypes, data?: unknown): Err;
721
724
 
722
- /**
723
- * The buyer's choice between paying online, paying the seller by hand (bank
724
- * transfer or "BLIK przelew na telefon") and paying the courier on delivery,
725
- * offered when the seller turned on "show at checkout" for the manual payment
726
- * gateway or offers cash on delivery.
727
- *
728
- * `POST /public-commerce/payment-methods` takes the body of `/buy` and answers
729
- * `{ success: true, choice: null }` (nothing to choose) or
730
- * `{ success: true, choice: { methods, manualAccountTypes } }`. The pick goes
731
- * to `/buy` as `paymentMethod`. Anything else (an old backend, an error, a
732
- * timeout) counts as "nothing to choose", so the cart buys as before.
733
- */
734
-
735
- /** `cod` is cash on delivery: the buyer pays the courier (Poland only, shipped carts). */
736
- type PaymentMethod = "online" | "manual" | "cod";
737
- type ManualAccountType = "bankTransfer" | "blik";
738
- type PaymentMethodChoice = {
739
- /** In the seller's order (cash on delivery last); the first one is selected by default. */
740
- methods: PaymentMethod[];
741
- /** How the manual option is paid; decides its label. */
742
- manualAccountTypes: ManualAccountType[];
743
- };
744
-
745
- declare function setLocale(locale?: string): void;
746
- declare function getLocale(): string;
747
-
748
- declare function setProjectID$1(projectID: string): void;
749
-
750
- declare function setCustomHost(host: string): void;
751
-
752
725
  declare enum BillingPeriod {
753
726
  DAILY = "daily",
754
727
  WEEKLY = "weekly",
@@ -799,6 +772,7 @@ declare const linkRequestSchema: z__default.ZodObject<{
799
772
  id: z__default.ZodString;
800
773
  quantity: z__default.ZodNumber;
801
774
  priceVersion: z__default.ZodOptional<z__default.ZodString>;
775
+ amount: z__default.ZodOptional<z__default.ZodNumber>;
802
776
  name: z__default.ZodOptional<z__default.ZodString>;
803
777
  description: z__default.ZodOptional<z__default.ZodString>;
804
778
  imageURL: z__default.ZodOptional<z__default.ZodString>;
@@ -838,6 +812,36 @@ declare const linkRequestSchema: z__default.ZodObject<{
838
812
  }, z__default.core.$strip>>;
839
813
  }, z__default.core.$strip>;
840
814
 
815
+ /**
816
+ * The buyer's choice between paying online, paying the seller by hand (bank
817
+ * transfer or "BLIK przelew na telefon") and paying the courier on delivery,
818
+ * offered when the seller turned on "show at checkout" for the manual payment
819
+ * gateway or offers cash on delivery.
820
+ *
821
+ * `POST /public-commerce/payment-methods` takes the body of `/buy` and answers
822
+ * `{ success: true, choice: null }` (nothing to choose) or
823
+ * `{ success: true, choice: { methods, manualAccountTypes } }`. The pick goes
824
+ * to `/buy` as `paymentMethod`. Anything else (an old backend, an error, a
825
+ * timeout) counts as "nothing to choose", so the cart buys as before.
826
+ */
827
+
828
+ /** `cod` is cash on delivery: the buyer pays the courier (Poland only, shipped carts). */
829
+ type PaymentMethod = "online" | "manual" | "cod";
830
+ type ManualAccountType = "bankTransfer" | "blik";
831
+ type PaymentMethodChoice = {
832
+ /** In the seller's order (cash on delivery last); the first one is selected by default. */
833
+ methods: PaymentMethod[];
834
+ /** How the manual option is paid; decides its label. */
835
+ manualAccountTypes: ManualAccountType[];
836
+ };
837
+
838
+ declare function setLocale(locale?: string): void;
839
+ declare function getLocale(): string;
840
+
841
+ declare function setProjectID$1(projectID: string): void;
842
+
843
+ declare function setCustomHost(host: string): void;
844
+
841
845
  declare namespace Bitsnap {
842
846
  /**
843
847
  * Adds a product or variant to the cart. Returns an `Err` instead of adding
@@ -854,6 +858,8 @@ declare namespace Bitsnap {
854
858
  name?: string;
855
859
  price?: number;
856
860
  currency?: string;
861
+ /** Buyer chosen pay-what-you-want amount, in minor units. */
862
+ amount?: number;
857
863
  /** Where `add_to_cart` is reported. Defaults to the mounted `<BitsnapCheckout>`. */
858
864
  analytics?: Instrument;
859
865
  }): Promise<Err | undefined>;
@@ -967,4 +973,15 @@ declare function persistReturnURL(returnURL: string | null): void;
967
973
  declare function readPersistedReturnURL(): string | null;
968
974
  declare function buildAccessTokenRedirect(returnURL: string, accessToken: string): string;
969
975
 
970
- export { AnalyticsOption, Wrapper$2 as ApplePayButton, type Props$3 as ApplePayButtonProps, Bitsnap, type BitsnapCartProps, BitsnapCart as BitsnapCheckout, type BuyErrorData, CHECKOUT_SLOT_NAMES, type CheckoutAppearance, type CheckoutAppearanceElements, type CheckoutAppearanceTokens, type CheckoutSlotAppearance, type CheckoutSlotName, type CheckoutTexts, type CheckoutTheme, type ComponentClassNames, type CreateCheckoutResult, type CustomizationTexts, type ExpressItem, GetThemeOutput, Wrapper$1 as GooglePayButton, type Props$2 as GooglePayButtonProps, ITEM_IDS_NOT_FOUND, InPostPayButton, type InPostPayButtonProps, type LinkRequest, type NotificationGroup, Wrapper as NotificationsComponent, type Props$1 as NotificationsComponentProps, type NotificationsComponentPublicProps, PanelPage as Panel, type PanelConfig, PanelLogin, PanelLoginProps, PanelProps, PanelProvider, type PublicNotificationGroup, PublicOrderPage, RevolutPayButton, type RevolutPayButtonProps, type RevolutPaymentOutcome, buildAccessTokenRedirect, createCheckout, createPaymentURL, getAllowedReturnOrigins, getLocale, getPanelConfig, getPaymentMethodChoice, getReferenceIfPossible, getReturnURLFromSearch, injectReferenceToRequestIfNeeded, persistReturnURL, readPersistedReturnURL, setAllowedReturnOrigins, setCustomHost, setHost, setLocale, setLoginURL, setPanelConfig, setProjectID as setPanelProjectID, setProjectID$1 as setProjectID, setTheme, usePanelConfig };
976
+ /**
977
+ * A buyer's pack thread for one service product. Loads the chat on demand;
978
+ * the same component is exported eagerly from `bitsnap-react/chat`.
979
+ */
980
+ declare function ChatThread(props: ChatThreadProps): react_jsx_runtime.JSX.Element;
981
+ /**
982
+ * A community channel. Loads the chat on demand; the same component is
983
+ * exported eagerly from `bitsnap-react/chat`.
984
+ */
985
+ declare function Channel(props: ChannelProps): react_jsx_runtime.JSX.Element;
986
+
987
+ export { AnalyticsOption, Wrapper$2 as ApplePayButton, type Props$3 as ApplePayButtonProps, Bitsnap, type BitsnapCartProps, BitsnapCart as BitsnapCheckout, type BuyErrorData, CHECKOUT_SLOT_NAMES, Channel, ChannelProps, ChatThread, ChatThreadProps, type CheckoutAppearance, type CheckoutAppearanceElements, type CheckoutAppearanceTokens, type CheckoutSlotAppearance, type CheckoutSlotName, type CheckoutTexts, type CheckoutTheme, type ComponentClassNames, type CreateCheckoutResult, type CustomizationTexts, type ExpressItem, GetThemeOutput, Wrapper$1 as GooglePayButton, type Props$2 as GooglePayButtonProps, ITEM_IDS_NOT_FOUND, InPostPayButton, type InPostPayButtonProps, type LinkRequest, type NotificationGroup, Wrapper as NotificationsComponent, type Props$1 as NotificationsComponentProps, type NotificationsComponentPublicProps, PanelPage as Panel, type PanelConfig, PanelLogin, PanelLoginProps, PanelProps, PanelProvider, type PublicNotificationGroup, PublicOrderPage, RevolutPayButton, type RevolutPayButtonProps, type RevolutPaymentOutcome, buildAccessTokenRedirect, createCheckout, createPaymentURL, getAllowedReturnOrigins, getLocale, getPanelConfig, getPaymentMethodChoice, getReferenceIfPossible, getReturnURLFromSearch, injectReferenceToRequestIfNeeded, persistReturnURL, readPersistedReturnURL, setAllowedReturnOrigins, setCustomHost, setHost, setLocale, setLoginURL, setPanelConfig, setProjectID as setPanelProjectID, setProjectID$1 as setProjectID, setTheme, usePanelConfig };
package/dist/index.d.ts CHANGED
@@ -6,11 +6,14 @@ export { BitsnapReturns, BitsnapReturnsProps, BitsnapReturnsProvider, BitsnapRet
6
6
  export { b as RETURNS_SLOT_NAMES, R as ReturnsAppearance, c as ReturnsAppearanceElements, d as ReturnsAppearanceTokens, e as ReturnsSlotAppearance, f as ReturnsSlotName, h as ReturnsTextKey, a as ReturnsTexts, g as ReturnsTheme } from './texts-m6XQGZ6w.js';
7
7
  import { CSSProperties, ReactNode } from 'react';
8
8
  import z__default from 'zod';
9
- import { P as PanelLoginProps, a as PanelProps, G as GetThemeOutput } from './types-ClFCVzk_.js';
10
- export { b as PanelScreen, c as PanelSearchParamsType } from './types-ClFCVzk_.js';
9
+ import { P as PanelLoginProps, a as PanelProps, G as GetThemeOutput } from './types-DfqzDP9k.js';
10
+ export { b as PanelScreen, c as PanelSearchParamsType } from './types-DfqzDP9k.js';
11
+ import { e as ChatThreadProps, c as ChannelProps } from './widgets-Bsojw94g.js';
12
+ export { d as ChatBuyRequest, C as ChatTexts, f as ChatWidgetBaseProps } from './widgets-Bsojw94g.js';
11
13
  import './models.js';
12
14
  import '@bufbuild/protobuf/wkt';
13
15
  import '@bufbuild/protobuf';
16
+ import './texts-9kfgClsA.js';
14
17
 
15
18
  type AppleButtonType = "plain" | "add-money" | "book" | "buy" | "check-out" | "continue" | "contribute" | "donate" | "order" | "pay" | "reload" | "rent" | "set-up" | "subscribe" | "support" | "tip" | "top-up";
16
19
  type ColorType = "black" | "white" | "white-outline";
@@ -719,36 +722,6 @@ type Err = {
719
722
  };
720
723
  declare function Err(message: string, type?: ErrTypes, data?: unknown): Err;
721
724
 
722
- /**
723
- * The buyer's choice between paying online, paying the seller by hand (bank
724
- * transfer or "BLIK przelew na telefon") and paying the courier on delivery,
725
- * offered when the seller turned on "show at checkout" for the manual payment
726
- * gateway or offers cash on delivery.
727
- *
728
- * `POST /public-commerce/payment-methods` takes the body of `/buy` and answers
729
- * `{ success: true, choice: null }` (nothing to choose) or
730
- * `{ success: true, choice: { methods, manualAccountTypes } }`. The pick goes
731
- * to `/buy` as `paymentMethod`. Anything else (an old backend, an error, a
732
- * timeout) counts as "nothing to choose", so the cart buys as before.
733
- */
734
-
735
- /** `cod` is cash on delivery: the buyer pays the courier (Poland only, shipped carts). */
736
- type PaymentMethod = "online" | "manual" | "cod";
737
- type ManualAccountType = "bankTransfer" | "blik";
738
- type PaymentMethodChoice = {
739
- /** In the seller's order (cash on delivery last); the first one is selected by default. */
740
- methods: PaymentMethod[];
741
- /** How the manual option is paid; decides its label. */
742
- manualAccountTypes: ManualAccountType[];
743
- };
744
-
745
- declare function setLocale(locale?: string): void;
746
- declare function getLocale(): string;
747
-
748
- declare function setProjectID$1(projectID: string): void;
749
-
750
- declare function setCustomHost(host: string): void;
751
-
752
725
  declare enum BillingPeriod {
753
726
  DAILY = "daily",
754
727
  WEEKLY = "weekly",
@@ -799,6 +772,7 @@ declare const linkRequestSchema: z__default.ZodObject<{
799
772
  id: z__default.ZodString;
800
773
  quantity: z__default.ZodNumber;
801
774
  priceVersion: z__default.ZodOptional<z__default.ZodString>;
775
+ amount: z__default.ZodOptional<z__default.ZodNumber>;
802
776
  name: z__default.ZodOptional<z__default.ZodString>;
803
777
  description: z__default.ZodOptional<z__default.ZodString>;
804
778
  imageURL: z__default.ZodOptional<z__default.ZodString>;
@@ -838,6 +812,36 @@ declare const linkRequestSchema: z__default.ZodObject<{
838
812
  }, z__default.core.$strip>>;
839
813
  }, z__default.core.$strip>;
840
814
 
815
+ /**
816
+ * The buyer's choice between paying online, paying the seller by hand (bank
817
+ * transfer or "BLIK przelew na telefon") and paying the courier on delivery,
818
+ * offered when the seller turned on "show at checkout" for the manual payment
819
+ * gateway or offers cash on delivery.
820
+ *
821
+ * `POST /public-commerce/payment-methods` takes the body of `/buy` and answers
822
+ * `{ success: true, choice: null }` (nothing to choose) or
823
+ * `{ success: true, choice: { methods, manualAccountTypes } }`. The pick goes
824
+ * to `/buy` as `paymentMethod`. Anything else (an old backend, an error, a
825
+ * timeout) counts as "nothing to choose", so the cart buys as before.
826
+ */
827
+
828
+ /** `cod` is cash on delivery: the buyer pays the courier (Poland only, shipped carts). */
829
+ type PaymentMethod = "online" | "manual" | "cod";
830
+ type ManualAccountType = "bankTransfer" | "blik";
831
+ type PaymentMethodChoice = {
832
+ /** In the seller's order (cash on delivery last); the first one is selected by default. */
833
+ methods: PaymentMethod[];
834
+ /** How the manual option is paid; decides its label. */
835
+ manualAccountTypes: ManualAccountType[];
836
+ };
837
+
838
+ declare function setLocale(locale?: string): void;
839
+ declare function getLocale(): string;
840
+
841
+ declare function setProjectID$1(projectID: string): void;
842
+
843
+ declare function setCustomHost(host: string): void;
844
+
841
845
  declare namespace Bitsnap {
842
846
  /**
843
847
  * Adds a product or variant to the cart. Returns an `Err` instead of adding
@@ -854,6 +858,8 @@ declare namespace Bitsnap {
854
858
  name?: string;
855
859
  price?: number;
856
860
  currency?: string;
861
+ /** Buyer chosen pay-what-you-want amount, in minor units. */
862
+ amount?: number;
857
863
  /** Where `add_to_cart` is reported. Defaults to the mounted `<BitsnapCheckout>`. */
858
864
  analytics?: Instrument;
859
865
  }): Promise<Err | undefined>;
@@ -967,4 +973,15 @@ declare function persistReturnURL(returnURL: string | null): void;
967
973
  declare function readPersistedReturnURL(): string | null;
968
974
  declare function buildAccessTokenRedirect(returnURL: string, accessToken: string): string;
969
975
 
970
- export { AnalyticsOption, Wrapper$2 as ApplePayButton, type Props$3 as ApplePayButtonProps, Bitsnap, type BitsnapCartProps, BitsnapCart as BitsnapCheckout, type BuyErrorData, CHECKOUT_SLOT_NAMES, type CheckoutAppearance, type CheckoutAppearanceElements, type CheckoutAppearanceTokens, type CheckoutSlotAppearance, type CheckoutSlotName, type CheckoutTexts, type CheckoutTheme, type ComponentClassNames, type CreateCheckoutResult, type CustomizationTexts, type ExpressItem, GetThemeOutput, Wrapper$1 as GooglePayButton, type Props$2 as GooglePayButtonProps, ITEM_IDS_NOT_FOUND, InPostPayButton, type InPostPayButtonProps, type LinkRequest, type NotificationGroup, Wrapper as NotificationsComponent, type Props$1 as NotificationsComponentProps, type NotificationsComponentPublicProps, PanelPage as Panel, type PanelConfig, PanelLogin, PanelLoginProps, PanelProps, PanelProvider, type PublicNotificationGroup, PublicOrderPage, RevolutPayButton, type RevolutPayButtonProps, type RevolutPaymentOutcome, buildAccessTokenRedirect, createCheckout, createPaymentURL, getAllowedReturnOrigins, getLocale, getPanelConfig, getPaymentMethodChoice, getReferenceIfPossible, getReturnURLFromSearch, injectReferenceToRequestIfNeeded, persistReturnURL, readPersistedReturnURL, setAllowedReturnOrigins, setCustomHost, setHost, setLocale, setLoginURL, setPanelConfig, setProjectID as setPanelProjectID, setProjectID$1 as setProjectID, setTheme, usePanelConfig };
976
+ /**
977
+ * A buyer's pack thread for one service product. Loads the chat on demand;
978
+ * the same component is exported eagerly from `bitsnap-react/chat`.
979
+ */
980
+ declare function ChatThread(props: ChatThreadProps): react_jsx_runtime.JSX.Element;
981
+ /**
982
+ * A community channel. Loads the chat on demand; the same component is
983
+ * exported eagerly from `bitsnap-react/chat`.
984
+ */
985
+ declare function Channel(props: ChannelProps): react_jsx_runtime.JSX.Element;
986
+
987
+ export { AnalyticsOption, Wrapper$2 as ApplePayButton, type Props$3 as ApplePayButtonProps, Bitsnap, type BitsnapCartProps, BitsnapCart as BitsnapCheckout, type BuyErrorData, CHECKOUT_SLOT_NAMES, Channel, ChannelProps, ChatThread, ChatThreadProps, type CheckoutAppearance, type CheckoutAppearanceElements, type CheckoutAppearanceTokens, type CheckoutSlotAppearance, type CheckoutSlotName, type CheckoutTexts, type CheckoutTheme, type ComponentClassNames, type CreateCheckoutResult, type CustomizationTexts, type ExpressItem, GetThemeOutput, Wrapper$1 as GooglePayButton, type Props$2 as GooglePayButtonProps, ITEM_IDS_NOT_FOUND, InPostPayButton, type InPostPayButtonProps, type LinkRequest, type NotificationGroup, Wrapper as NotificationsComponent, type Props$1 as NotificationsComponentProps, type NotificationsComponentPublicProps, PanelPage as Panel, type PanelConfig, PanelLogin, PanelLoginProps, PanelProps, PanelProvider, type PublicNotificationGroup, PublicOrderPage, RevolutPayButton, type RevolutPayButtonProps, type RevolutPaymentOutcome, buildAccessTokenRedirect, createCheckout, createPaymentURL, getAllowedReturnOrigins, getLocale, getPanelConfig, getPaymentMethodChoice, getReferenceIfPossible, getReturnURLFromSearch, injectReferenceToRequestIfNeeded, persistReturnURL, readPersistedReturnURL, setAllowedReturnOrigins, setCustomHost, setHost, setLocale, setLoginURL, setPanelConfig, setProjectID as setPanelProjectID, setProjectID$1 as setProjectID, setTheme, usePanelConfig };