@pisell/private-materials 6.5.4 → 6.5.6

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 (249) hide show
  1. package/build/lowcode/assets-daily.json +11 -11
  2. package/build/lowcode/assets-dev.json +2 -2
  3. package/build/lowcode/assets-prod.json +11 -11
  4. package/build/lowcode/index.js +1 -1
  5. package/build/lowcode/meta.js +1 -1
  6. package/build/lowcode/preview.js +160 -146
  7. package/build/lowcode/render/default/view.css +1 -1
  8. package/build/lowcode/render/default/view.js +9 -9
  9. package/build/lowcode/view.css +1 -1
  10. package/build/lowcode/view.js +9 -9
  11. package/es/components/booking/addons/model.d.ts +1 -10
  12. package/es/components/booking/components/actionButtons/index.js +37 -42
  13. package/es/components/booking/components/actionButtons/index.less +0 -28
  14. package/es/components/booking/components/footer/amount.d.ts +3 -3
  15. package/es/components/booking/components/footer/amount.js +51 -31
  16. package/es/components/booking/components/footer/index.js +177 -68
  17. package/es/components/booking/components/footer/utils.js +62 -33
  18. package/es/components/booking/forms/model.d.ts +1 -10
  19. package/es/components/booking/info/model.d.ts +1 -10
  20. package/es/components/booking/info/model.js +5 -0
  21. package/es/components/booking/info/service/addService/index.js +2 -1
  22. package/es/components/booking/info/service/addService/utils.d.ts +1 -1
  23. package/es/components/booking/info/service2/utils.d.ts +1 -1
  24. package/es/components/booking/info2/index.js +42 -2
  25. package/es/components/booking/info2/service/addService/index.js +2 -1
  26. package/es/components/booking/info2/service/addService/utils.d.ts +1 -1
  27. package/es/components/booking/info2/service/editService/index.js +12 -4
  28. package/es/components/booking/model.d.ts +1 -9
  29. package/es/components/booking/notes/model.d.ts +1 -10
  30. package/es/components/booking/payments/model.d.ts +1 -10
  31. package/es/components/booking/utils.js +10 -5
  32. package/es/components/checkout/PaymentModal.d.ts +2 -0
  33. package/es/components/checkout/PaymentModal.js +462 -263
  34. package/es/components/checkout/components/AdditionalModule/index.less +1 -1
  35. package/es/components/checkout/components/AmountSummary/index.js +176 -65
  36. package/es/components/checkout/components/AmountSummary/index.less +13 -0
  37. package/es/components/checkout/components/CashPaymentModule/index.d.ts +5 -3
  38. package/es/components/checkout/components/CashPaymentModule/index.js +110 -132
  39. package/es/components/checkout/components/CashPaymentModule/index.less +200 -176
  40. package/es/components/checkout/components/PaymentDetailModal/index.js +2 -2
  41. package/es/components/checkout/components/PaymentOptionsModule/PaymentMethodItem.d.ts +29 -0
  42. package/es/components/checkout/components/PaymentOptionsModule/PaymentMethodItem.js +214 -0
  43. package/es/components/checkout/components/PaymentOptionsModule/index.d.ts +2 -4
  44. package/es/components/checkout/components/PaymentOptionsModule/index.js +12 -114
  45. package/es/components/checkout/components/PaymentOptionsModule/index.less +23 -0
  46. package/es/components/checkout/components/PaymentResultToast/index.js +38 -8
  47. package/es/components/checkout/components/PaymentResultToast/types.d.ts +2 -0
  48. package/es/components/checkout/components/SavePayLaterHandler/index.js +1 -1
  49. package/es/components/checkout/components/SearchAndClientModule/index.js +40 -39
  50. package/es/components/checkout/components/WalletPassModule/index.js +4 -3
  51. package/es/components/checkout/components/WalletPassModule/utils.js +10 -4
  52. package/es/components/checkout/hooks/useWalletPass.js +11 -4
  53. package/es/components/checkout/index.less +1 -1
  54. package/es/components/checkout/locales.d.ts +36 -0
  55. package/es/components/checkout/locales.js +43 -4
  56. package/es/components/checkout/types.d.ts +1 -0
  57. package/es/components/eftposPay/amount.d.ts +1 -1
  58. package/es/components/eftposPay/device.d.ts +1 -1
  59. package/es/components/eftposPay/hooks.d.ts +1 -1
  60. package/es/components/eftposPay/store/index.d.ts +3 -3
  61. package/es/components/pay/toC/model.d.ts +1 -9
  62. package/es/components/schedules/model.d.ts +1 -9
  63. package/es/components/shoppingCart/components/Cart/Product.js +143 -71
  64. package/es/components/shoppingCart/components/Cart/index.js +1 -1
  65. package/es/components/shoppingCart/components/Cart/index.less +31 -0
  66. package/es/components/shoppingCart/locales.d.ts +3 -0
  67. package/es/components/shoppingCart/locales.js +12 -3
  68. package/es/components/ticketBooking/components/addServiceVariant/addService.d.ts +0 -1
  69. package/es/components/ticketBooking/components/addServiceVariant/addService.js +9 -12
  70. package/es/components/ticketBooking/components/addServiceVariant/index.d.ts +0 -1
  71. package/es/components/ticketBooking/components/menuBar/index.js +3 -1
  72. package/es/components/ticketBooking/components/menuBar/index.less +7 -0
  73. package/es/components/ticketBooking/components/ticketBooking/index.d.ts +0 -1
  74. package/es/components/ticketBooking/hooks/pisellos/useCustomer.js +7 -7
  75. package/es/components/ticketBooking/index.d.ts +0 -1
  76. package/es/components/ticketBooking/utils/index.d.ts +1 -1
  77. package/es/components/ticketBooking/utils/index.js +2 -1
  78. package/es/components/wallet/Detail/model.d.ts +1 -13
  79. package/es/components/wallet/DiscountCard/model.d.ts +1 -14
  80. package/es/components/wallet/PointCard/model.d.ts +1 -13
  81. package/es/components/wallet/RechargeableCard/model.d.ts +1 -29
  82. package/es/components/wallet/Voucher/model.d.ts +1 -13
  83. package/es/components/wallet/model.d.ts +1 -9
  84. package/es/pro/pisellPriceKeyboardPopover/PisellPriceKeyboardPopover.js +1 -1
  85. package/es/pro/pisellSimplePriceKeyboardPopover/PisellPriceKeyboardPopover.d.ts +5 -0
  86. package/es/pro/pisellSimplePriceKeyboardPopover/PisellPriceKeyboardPopover.js +148 -0
  87. package/es/pro/pisellSimplePriceKeyboardPopover/PisellPriceKeyboardPopover.less +23 -0
  88. package/es/pro/pisellSimplePriceKeyboardPopover/index.d.ts +2 -0
  89. package/es/pro/pisellSimplePriceKeyboardPopover/index.js +1 -0
  90. package/es/pro/pisellSimplePriceKeyboardPopover/types.d.ts +33 -0
  91. package/es/pro/pisellSimplePriceKeyboardPopover/types.js +1 -0
  92. package/es/pro/priceKeyboard/components/cashKeyboard/CashKeyboardIntact.d.ts +5 -0
  93. package/es/pro/priceKeyboard/components/cashKeyboard/CashKeyboardIntact.js +331 -0
  94. package/es/pro/priceKeyboard/components/cashKeyboard/CashKeyboardSimple.d.ts +13 -0
  95. package/es/pro/priceKeyboard/components/cashKeyboard/CashKeyboardSimple.js +349 -0
  96. package/es/pro/priceKeyboard/components/cashKeyboard/index.d.ts +12 -0
  97. package/es/pro/priceKeyboard/components/cashKeyboard/index.js +49 -0
  98. package/es/pro/priceKeyboard/components/cashKeyboard/index.less +103 -0
  99. package/es/pro/priceKeyboard/components/cashKeyboard/locales.d.ts +39 -0
  100. package/es/pro/priceKeyboard/components/cashKeyboard/locales.js +41 -0
  101. package/es/pro/priceKeyboard/components/cashKeyboard/types.d.ts +97 -0
  102. package/es/pro/priceKeyboard/components/cashKeyboard/types.js +1 -0
  103. package/es/pro/priceKeyboard/components/discountKeyboard/index.d.ts +22 -0
  104. package/es/pro/priceKeyboard/components/discountKeyboard/index.js +465 -0
  105. package/es/pro/priceKeyboard/components/discountKeyboard/index.less +47 -0
  106. package/es/pro/priceKeyboard/components/discountKeyboard/locales.d.ts +42 -0
  107. package/es/pro/priceKeyboard/components/discountKeyboard/locales.js +44 -0
  108. package/es/pro/priceKeyboard/components/discountKeyboard/types.d.ts +17 -0
  109. package/es/pro/priceKeyboard/components/discountKeyboard/types.js +1 -0
  110. package/es/pro/priceKeyboard/components/paymentKeyboard/index.d.ts +12 -0
  111. package/es/pro/priceKeyboard/components/paymentKeyboard/index.js +444 -0
  112. package/es/pro/priceKeyboard/components/paymentKeyboard/index.less +64 -0
  113. package/es/pro/priceKeyboard/components/paymentKeyboard/locales.d.ts +45 -0
  114. package/es/pro/priceKeyboard/components/paymentKeyboard/locales.js +47 -0
  115. package/es/pro/priceKeyboard/components/paymentKeyboard/types.d.ts +39 -0
  116. package/es/pro/priceKeyboard/components/paymentKeyboard/types.js +1 -0
  117. package/es/pro/priceKeyboard/components/shortcuts/index.d.ts +17 -0
  118. package/es/pro/priceKeyboard/components/shortcuts/index.js +47 -0
  119. package/es/pro/priceKeyboard/components/shortcuts/index.less +39 -0
  120. package/es/pro/priceKeyboard/hooks/keyActions.d.ts +28 -0
  121. package/es/pro/priceKeyboard/hooks/keyActions.js +252 -0
  122. package/es/pro/priceKeyboard/hooks/rightItems.d.ts +28 -0
  123. package/es/pro/priceKeyboard/hooks/rightItems.js +50 -0
  124. package/es/pro/priceKeyboard/index.d.ts +3 -0
  125. package/es/pro/priceKeyboard/index.js +3 -0
  126. package/es/pro/priceKeyboard/index.less +215 -0
  127. package/es/pro/priceKeyboard/utils.d.ts +31 -0
  128. package/es/pro/priceKeyboard/utils.js +51 -0
  129. package/es/pro/skuDetailModal/index.js +19 -16
  130. package/lib/components/booking/addons/model.d.ts +1 -10
  131. package/lib/components/booking/components/actionButtons/index.js +31 -28
  132. package/lib/components/booking/components/actionButtons/index.less +0 -28
  133. package/lib/components/booking/components/footer/amount.d.ts +3 -3
  134. package/lib/components/booking/components/footer/amount.js +49 -34
  135. package/lib/components/booking/components/footer/index.js +114 -40
  136. package/lib/components/booking/components/footer/utils.js +35 -7
  137. package/lib/components/booking/forms/model.d.ts +1 -10
  138. package/lib/components/booking/info/model.d.ts +1 -10
  139. package/lib/components/booking/info/model.js +3 -0
  140. package/lib/components/booking/info/service/addService/index.js +2 -1
  141. package/lib/components/booking/info/service/addService/utils.d.ts +1 -1
  142. package/lib/components/booking/info/service2/utils.d.ts +1 -1
  143. package/lib/components/booking/info2/index.js +18 -1
  144. package/lib/components/booking/info2/service/addService/index.js +2 -1
  145. package/lib/components/booking/info2/service/addService/utils.d.ts +1 -1
  146. package/lib/components/booking/info2/service/editService/index.js +12 -4
  147. package/lib/components/booking/model.d.ts +1 -9
  148. package/lib/components/booking/notes/model.d.ts +1 -10
  149. package/lib/components/booking/payments/model.d.ts +1 -10
  150. package/lib/components/booking/utils.js +10 -5
  151. package/lib/components/checkout/PaymentModal.d.ts +2 -0
  152. package/lib/components/checkout/PaymentModal.js +208 -91
  153. package/lib/components/checkout/components/AdditionalModule/index.less +1 -1
  154. package/lib/components/checkout/components/AmountSummary/index.js +120 -50
  155. package/lib/components/checkout/components/AmountSummary/index.less +13 -0
  156. package/lib/components/checkout/components/CashPaymentModule/index.d.ts +5 -3
  157. package/lib/components/checkout/components/CashPaymentModule/index.js +101 -134
  158. package/lib/components/checkout/components/CashPaymentModule/index.less +200 -176
  159. package/lib/components/checkout/components/PaymentDetailModal/index.js +2 -2
  160. package/lib/components/checkout/components/PaymentOptionsModule/PaymentMethodItem.d.ts +29 -0
  161. package/lib/components/checkout/components/PaymentOptionsModule/PaymentMethodItem.js +163 -0
  162. package/lib/components/checkout/components/PaymentOptionsModule/index.d.ts +2 -4
  163. package/lib/components/checkout/components/PaymentOptionsModule/index.js +11 -123
  164. package/lib/components/checkout/components/PaymentOptionsModule/index.less +23 -0
  165. package/lib/components/checkout/components/PaymentResultToast/index.js +26 -1
  166. package/lib/components/checkout/components/PaymentResultToast/types.d.ts +2 -0
  167. package/lib/components/checkout/components/SavePayLaterHandler/index.js +1 -1
  168. package/lib/components/checkout/components/SearchAndClientModule/index.js +3 -29
  169. package/lib/components/checkout/components/WalletPassModule/index.js +4 -3
  170. package/lib/components/checkout/components/WalletPassModule/utils.js +8 -4
  171. package/lib/components/checkout/hooks/useWalletPass.js +11 -6
  172. package/lib/components/checkout/index.less +1 -1
  173. package/lib/components/checkout/locales.d.ts +36 -0
  174. package/lib/components/checkout/locales.js +43 -4
  175. package/lib/components/checkout/types.d.ts +1 -0
  176. package/lib/components/eftposPay/amount.d.ts +1 -1
  177. package/lib/components/eftposPay/device.d.ts +1 -1
  178. package/lib/components/eftposPay/hooks.d.ts +1 -1
  179. package/lib/components/eftposPay/store/index.d.ts +3 -3
  180. package/lib/components/pay/toC/model.d.ts +1 -9
  181. package/lib/components/schedules/model.d.ts +1 -9
  182. package/lib/components/shoppingCart/components/Cart/Product.js +111 -51
  183. package/lib/components/shoppingCart/components/Cart/index.js +1 -1
  184. package/lib/components/shoppingCart/components/Cart/index.less +31 -0
  185. package/lib/components/shoppingCart/locales.d.ts +3 -0
  186. package/lib/components/shoppingCart/locales.js +6 -3
  187. package/lib/components/ticketBooking/components/addServiceVariant/addService.d.ts +0 -1
  188. package/lib/components/ticketBooking/components/addServiceVariant/addService.js +1 -4
  189. package/lib/components/ticketBooking/components/addServiceVariant/index.d.ts +0 -1
  190. package/lib/components/ticketBooking/components/menuBar/index.js +1 -1
  191. package/lib/components/ticketBooking/components/menuBar/index.less +7 -0
  192. package/lib/components/ticketBooking/components/ticketBooking/index.d.ts +0 -1
  193. package/lib/components/ticketBooking/hooks/pisellos/useCustomer.js +7 -7
  194. package/lib/components/ticketBooking/index.d.ts +0 -1
  195. package/lib/components/ticketBooking/utils/index.d.ts +1 -1
  196. package/lib/components/ticketBooking/utils/index.js +2 -1
  197. package/lib/components/wallet/Detail/model.d.ts +1 -13
  198. package/lib/components/wallet/DiscountCard/model.d.ts +1 -14
  199. package/lib/components/wallet/PointCard/model.d.ts +1 -13
  200. package/lib/components/wallet/RechargeableCard/model.d.ts +1 -29
  201. package/lib/components/wallet/Voucher/model.d.ts +1 -13
  202. package/lib/components/wallet/model.d.ts +1 -9
  203. package/lib/pro/pisellPriceKeyboardPopover/PisellPriceKeyboardPopover.js +2 -2
  204. package/lib/pro/pisellSimplePriceKeyboardPopover/PisellPriceKeyboardPopover.d.ts +5 -0
  205. package/lib/pro/pisellSimplePriceKeyboardPopover/PisellPriceKeyboardPopover.js +144 -0
  206. package/lib/pro/pisellSimplePriceKeyboardPopover/PisellPriceKeyboardPopover.less +23 -0
  207. package/lib/pro/pisellSimplePriceKeyboardPopover/index.d.ts +2 -0
  208. package/lib/pro/pisellSimplePriceKeyboardPopover/index.js +35 -0
  209. package/lib/pro/pisellSimplePriceKeyboardPopover/types.d.ts +33 -0
  210. package/lib/pro/pisellSimplePriceKeyboardPopover/types.js +17 -0
  211. package/lib/pro/priceKeyboard/components/cashKeyboard/CashKeyboardIntact.d.ts +5 -0
  212. package/lib/pro/priceKeyboard/components/cashKeyboard/CashKeyboardIntact.js +360 -0
  213. package/lib/pro/priceKeyboard/components/cashKeyboard/CashKeyboardSimple.d.ts +13 -0
  214. package/lib/pro/priceKeyboard/components/cashKeyboard/CashKeyboardSimple.js +399 -0
  215. package/lib/pro/priceKeyboard/components/cashKeyboard/index.d.ts +12 -0
  216. package/lib/pro/priceKeyboard/components/cashKeyboard/index.js +76 -0
  217. package/lib/pro/priceKeyboard/components/cashKeyboard/index.less +103 -0
  218. package/lib/pro/priceKeyboard/components/cashKeyboard/locales.d.ts +39 -0
  219. package/lib/pro/priceKeyboard/components/cashKeyboard/locales.js +65 -0
  220. package/lib/pro/priceKeyboard/components/cashKeyboard/types.d.ts +97 -0
  221. package/lib/pro/priceKeyboard/components/cashKeyboard/types.js +17 -0
  222. package/lib/pro/priceKeyboard/components/discountKeyboard/index.d.ts +22 -0
  223. package/lib/pro/priceKeyboard/components/discountKeyboard/index.js +504 -0
  224. package/lib/pro/priceKeyboard/components/discountKeyboard/index.less +47 -0
  225. package/lib/pro/priceKeyboard/components/discountKeyboard/locales.d.ts +42 -0
  226. package/lib/pro/priceKeyboard/components/discountKeyboard/locales.js +68 -0
  227. package/lib/pro/priceKeyboard/components/discountKeyboard/types.d.ts +17 -0
  228. package/lib/pro/priceKeyboard/components/discountKeyboard/types.js +17 -0
  229. package/lib/pro/priceKeyboard/components/paymentKeyboard/index.d.ts +12 -0
  230. package/lib/pro/priceKeyboard/components/paymentKeyboard/index.js +488 -0
  231. package/lib/pro/priceKeyboard/components/paymentKeyboard/index.less +64 -0
  232. package/lib/pro/priceKeyboard/components/paymentKeyboard/locales.d.ts +45 -0
  233. package/lib/pro/priceKeyboard/components/paymentKeyboard/locales.js +71 -0
  234. package/lib/pro/priceKeyboard/components/paymentKeyboard/types.d.ts +39 -0
  235. package/lib/pro/priceKeyboard/components/paymentKeyboard/types.js +17 -0
  236. package/lib/pro/priceKeyboard/components/shortcuts/index.d.ts +17 -0
  237. package/lib/pro/priceKeyboard/components/shortcuts/index.js +79 -0
  238. package/lib/pro/priceKeyboard/components/shortcuts/index.less +39 -0
  239. package/lib/pro/priceKeyboard/hooks/keyActions.d.ts +28 -0
  240. package/lib/pro/priceKeyboard/hooks/keyActions.js +176 -0
  241. package/lib/pro/priceKeyboard/hooks/rightItems.d.ts +28 -0
  242. package/lib/pro/priceKeyboard/hooks/rightItems.js +81 -0
  243. package/lib/pro/priceKeyboard/index.d.ts +3 -0
  244. package/lib/pro/priceKeyboard/index.js +45 -0
  245. package/lib/pro/priceKeyboard/index.less +215 -0
  246. package/lib/pro/priceKeyboard/utils.d.ts +31 -0
  247. package/lib/pro/priceKeyboard/utils.js +75 -0
  248. package/lib/pro/skuDetailModal/index.js +18 -22
  249. package/package.json +12 -12
@@ -116,7 +116,7 @@ var index = () => {
116
116
  "stroke-linejoin": "round"
117
117
  }
118
118
  )
119
- )))), /* @__PURE__ */ import_react.default.createElement("div", null, /* @__PURE__ */ import_react.default.createElement(
119
+ )))), /* @__PURE__ */ import_react.default.createElement("div", { className: "menu-wrapper" }, /* @__PURE__ */ import_react.default.createElement(
120
120
  import_materials.ConfigProvider,
121
121
  {
122
122
  theme: {
@@ -88,4 +88,11 @@
88
88
  background: #3f9e4d;
89
89
  }
90
90
  }
91
+
92
+ .menu-wrapper {
93
+ position: fixed;
94
+ bottom: 44px;
95
+ left: 6px;
96
+ z-index: 99999;
97
+ }
91
98
  }
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  export declare const _formatBookingDetail: (data: any, modalState: any) => any;
4
3
  interface TicketBookingProps {
@@ -46,7 +46,7 @@ var useCustomer = (props) => {
46
46
  if (!pisellos) {
47
47
  return;
48
48
  }
49
- pisellos.effects.on("customer:onUpdate", (state) => {
49
+ const unlisten1 = pisellos.effects.on("customer:onUpdate", (state) => {
50
50
  setCustomers(state.customerList);
51
51
  setHasMore(state.hasMore);
52
52
  setPagination((prev) => ({
@@ -56,23 +56,23 @@ var useCustomer = (props) => {
56
56
  pageSize: state.pageSize
57
57
  }));
58
58
  });
59
- pisellos.effects.on("customer:onSelected", (customer) => {
59
+ const unlisten2 = pisellos.effects.on("customer:onSelected", (customer) => {
60
60
  var _a;
61
61
  setSelectedCustomer(customer);
62
62
  (_a = props.changeCustomerToGlobalState) == null ? void 0 : _a.call(props, customer);
63
63
  });
64
- pisellos.effects.on(
64
+ const unlisten3 = pisellos.effects.on(
65
65
  "customer:onPaginationChange",
66
66
  (paginationInfo) => {
67
67
  setPagination(paginationInfo);
68
68
  }
69
69
  );
70
70
  return () => {
71
- pisellos.effects.off("customer:onUpdate");
72
- pisellos.effects.off("customer:onSelected");
73
- pisellos.effects.off("customer:onPaginationChange");
71
+ unlisten1();
72
+ unlisten2();
73
+ unlisten3();
74
74
  };
75
- }, [bookingTicket]);
75
+ }, []);
76
76
  const loadCustomers = (0, import_ahooks.useMemoizedFn)(
77
77
  async (params) => {
78
78
  try {
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  interface TicketBookingProps {
4
3
  productExtensionType: string[];
@@ -41,7 +41,7 @@ declare type ScanData = {
41
41
  };
42
42
  };
43
43
  export declare const formatScanCustomer: (data: ScanData) => {
44
- searchType: "customer" | "product" | "wallet" | "walletPass" | "local_product";
44
+ searchType: "product" | "customer" | "wallet" | "walletPass" | "local_product";
45
45
  data: any;
46
46
  scanCode: string;
47
47
  } | null;
@@ -166,7 +166,8 @@ var addService = (list, addItem, state) => {
166
166
  value = list.map((item) => {
167
167
  var _a, _b, _c;
168
168
  const isGoodPassDiscountProduct = (item.discount_list || []).some((item2) => item2.type === "good_pass");
169
- if (isSameProduct(item, addItem) && !isSetCount && !isGoodPassDiscountProduct) {
169
+ const isEdit = item == null ? void 0 : item.edit;
170
+ if (isSameProduct(item, addItem) && !isSetCount && !isGoodPassDiscountProduct && !isEdit) {
170
171
  isNotSame = false;
171
172
  const quantity = (((_a = item == null ? void 0 : item._extend) == null ? void 0 : _a.quantity) || 1) + (((_b = addItem == null ? void 0 : addItem._extend) == null ? void 0 : _b.quantity) || 1);
172
173
  count = quantity;
@@ -1,13 +1 @@
1
- /// <reference types="react" />
2
- interface RechargeState {
3
- addWalletCard: any;
4
- }
5
- export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
6
- walletDetailState: RechargeState;
7
- } & {
8
- dispatch: (params: {
9
- type: string;
10
- payload: any;
11
- }) => void;
12
- }>;
13
- export {};
1
+ export declare const Provider: any, Context: any;
@@ -1,14 +1 @@
1
- /// <reference types="react" />
2
- interface RechargeState {
3
- total: number;
4
- setup?: 'menu' | 'list' | 'detail' | string;
5
- }
6
- export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
7
- state: RechargeState;
8
- } & {
9
- dispatch: (params: {
10
- type: string;
11
- payload: any;
12
- }) => void;
13
- }>;
14
- export {};
1
+ export declare const Provider: any, Context: any;
@@ -1,13 +1 @@
1
- /// <reference types="react" />
2
- interface RechargeState {
3
- total: number;
4
- }
5
- export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
6
- state: RechargeState;
7
- } & {
8
- dispatch: (params: {
9
- type: string;
10
- payload: any;
11
- }) => void;
12
- }>;
13
- export {};
1
+ export declare const Provider: any, Context: any;
@@ -1,29 +1 @@
1
- /// <reference types="react" />
2
- interface RechargeState {
3
- selectedGiftOptionId: string | null;
4
- cardList: Array<{
5
- id: string;
6
- name: string;
7
- price: number;
8
- }>;
9
- selectedItem: {
10
- id?: string;
11
- gift_price?: number;
12
- price?: number;
13
- name?: string;
14
- variant_id?: string;
15
- };
16
- productId?: string;
17
- detailId?: string;
18
- total: string | number;
19
- rechargeModalOpen: boolean;
20
- }
21
- export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
22
- state: RechargeState;
23
- } & {
24
- dispatch: (params: {
25
- type: string;
26
- payload: any;
27
- }) => void;
28
- }>;
29
- export {};
1
+ export declare const Provider: any, Context: any;
@@ -1,13 +1 @@
1
- /// <reference types="react" />
2
- interface RechargeState {
3
- total: 0;
4
- }
5
- export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
6
- state: RechargeState;
7
- } & {
8
- dispatch: (params: {
9
- type: string;
10
- payload: any;
11
- }) => void;
12
- }>;
13
- export {};
1
+ export declare const Provider: any, Context: any;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { IWalletListItemProps } from './serve';
3
2
  export interface WalletCardItemProps {
4
3
  id: string;
@@ -27,11 +26,4 @@ export interface WalletListProps {
27
26
  currentSearchListItemCode?: string;
28
27
  [key: string]: any;
29
28
  }
30
- export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
31
- global_wallet: WalletListProps;
32
- } & {
33
- dispatch: (params: {
34
- type: string;
35
- payload: any;
36
- }) => void;
37
- }>;
29
+ export declare const Provider: any, Context: any;
@@ -34,7 +34,7 @@ __export(PisellPriceKeyboardPopover_exports, {
34
34
  module.exports = __toCommonJS(PisellPriceKeyboardPopover_exports);
35
35
  var import_react = __toESM(require("react"));
36
36
  var import_antd = require("antd");
37
- var import_materials = require("@pisell/materials");
37
+ var import_pisellAdjustPrice = __toESM(require("@pisell/materials/src/components/pisellAdjustPrice/index"));
38
38
  var import_utils = require("@pisell/utils");
39
39
  var import_PisellPriceKeyboardPopover = require("./PisellPriceKeyboardPopover.less");
40
40
  var PisellPriceKeyboardPopover = (0, import_react.forwardRef)(
@@ -105,7 +105,7 @@ var PisellPriceKeyboardPopover = (0, import_react.forwardRef)(
105
105
  onCancel == null ? void 0 : onCancel();
106
106
  };
107
107
  const keyboardContent = /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-price-keyboard-popover-content" }, /* @__PURE__ */ import_react.default.createElement(
108
- import_materials.PisellPriceKeyboard,
108
+ import_pisellAdjustPrice.default,
109
109
  {
110
110
  value: tempValue,
111
111
  onChange: handlePriceChange,
@@ -0,0 +1,5 @@
1
+ import React from 'react';
2
+ import './PisellPriceKeyboardPopover.less';
3
+ import { PisellPriceKeyboardPopoverProps, PisellPriceKeyboardPopoverRef } from './types';
4
+ declare const PisellPriceKeyboardPopover: React.ForwardRefExoticComponent<PisellPriceKeyboardPopoverProps & React.RefAttributes<PisellPriceKeyboardPopoverRef>>;
5
+ export default PisellPriceKeyboardPopover;
@@ -0,0 +1,144 @@
1
+ var __create = Object.create;
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __getProtoOf = Object.getPrototypeOf;
6
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
7
+ var __export = (target, all) => {
8
+ for (var name in all)
9
+ __defProp(target, name, { get: all[name], enumerable: true });
10
+ };
11
+ var __copyProps = (to, from, except, desc) => {
12
+ if (from && typeof from === "object" || typeof from === "function") {
13
+ for (let key of __getOwnPropNames(from))
14
+ if (!__hasOwnProp.call(to, key) && key !== except)
15
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
+ }
17
+ return to;
18
+ };
19
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
+ // If the importer is in node compatibility mode or this is not an ESM
21
+ // file that has been converted to a CommonJS file using a Babel-
22
+ // compatible transform (i.e. "__esModule" has not been set), then set
23
+ // "default" to the CommonJS "module.exports" for node compatibility.
24
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
25
+ mod
26
+ ));
27
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
+
29
+ // src/pro/pisellSimplePriceKeyboardPopover/PisellPriceKeyboardPopover.tsx
30
+ var PisellPriceKeyboardPopover_exports = {};
31
+ __export(PisellPriceKeyboardPopover_exports, {
32
+ default: () => PisellPriceKeyboardPopover_default
33
+ });
34
+ module.exports = __toCommonJS(PisellPriceKeyboardPopover_exports);
35
+ var import_react = __toESM(require("react"));
36
+ var import_antd = require("antd");
37
+ var import_materials = require("@pisell/materials");
38
+ var import_utils = require("@pisell/utils");
39
+ var import_PisellPriceKeyboardPopover = require("./PisellPriceKeyboardPopover.less");
40
+ var PisellPriceKeyboardPopover = (0, import_react.forwardRef)(
41
+ ({
42
+ children,
43
+ value = "",
44
+ onChange,
45
+ onConfirm,
46
+ onCancel,
47
+ showCurrencySymbol = true,
48
+ useThousandsSeparator = false,
49
+ selectType = "dark",
50
+ disabled = false,
51
+ overlayClassName = "",
52
+ style
53
+ }, ref) => {
54
+ const [open, setOpen] = (0, import_react.useState)(false);
55
+ const [tempValue, setTempValue] = (0, import_react.useState)("");
56
+ const [isFirstInput, setIsFirstInput] = (0, import_react.useState)(true);
57
+ (0, import_react.useImperativeHandle)(ref, () => ({
58
+ open: () => {
59
+ setOpen(true);
60
+ setTempValue(value);
61
+ setIsFirstInput(true);
62
+ },
63
+ close: () => setOpen(false),
64
+ isOpen: () => open
65
+ }));
66
+ const handleOpenChange = (visible) => {
67
+ if (disabled) return;
68
+ setOpen(visible);
69
+ if (visible) {
70
+ setTempValue(value);
71
+ setIsFirstInput(true);
72
+ } else {
73
+ onCancel == null ? void 0 : onCancel();
74
+ }
75
+ };
76
+ const handlePriceChange = (val) => {
77
+ if ((val === "" || val === 0 || val === "0") && !isFirstInput) {
78
+ setIsFirstInput(true);
79
+ setTempValue(val);
80
+ onChange == null ? void 0 : onChange(val);
81
+ return;
82
+ }
83
+ if (isFirstInput && val !== "" && val !== 0 && val !== "0") {
84
+ setIsFirstInput(false);
85
+ const currentValueStr = String(tempValue || "").replace(/[^\d.]/g, "");
86
+ const newValueStr = String(val).replace(/[^\d.]/g, "");
87
+ if (currentValueStr && currentValueStr !== "0" && newValueStr.length > currentValueStr.length && newValueStr.startsWith(currentValueStr)) {
88
+ const newInput = newValueStr.slice(currentValueStr.length);
89
+ if (newInput) {
90
+ setTempValue(newInput);
91
+ onChange == null ? void 0 : onChange(newInput);
92
+ return;
93
+ }
94
+ }
95
+ }
96
+ setTempValue(val);
97
+ onChange == null ? void 0 : onChange(val);
98
+ };
99
+ const handleConfirm = (val) => {
100
+ onConfirm == null ? void 0 : onConfirm(val);
101
+ setOpen(false);
102
+ };
103
+ const handleCancel = () => {
104
+ setOpen(false);
105
+ onCancel == null ? void 0 : onCancel();
106
+ };
107
+ const keyboardContent = /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-price-keyboard-popover-content" }, /* @__PURE__ */ import_react.default.createElement(
108
+ import_materials.PisellPriceKeyboard,
109
+ {
110
+ value: tempValue,
111
+ onChange: handlePriceChange,
112
+ onEnter: handleConfirm,
113
+ doneText: import_utils.locales.getText("pisell2.customise-item.save"),
114
+ resetText: import_utils.locales.getText("pisell2.booking.info.text.clear"),
115
+ amountProps: {
116
+ showCurrencySymbol,
117
+ useThousandsSeparator
118
+ },
119
+ selectType,
120
+ backgroundColor: "transparent"
121
+ }
122
+ ));
123
+ return /* @__PURE__ */ import_react.default.createElement(
124
+ import_antd.Popover,
125
+ {
126
+ open,
127
+ content: keyboardContent,
128
+ trigger: disabled ? [] : ["click"],
129
+ overlayInnerStyle: { padding: 0 },
130
+ destroyTooltipOnHide: true,
131
+ arrow: false,
132
+ align: {
133
+ offset: [0, 0]
134
+ },
135
+ overlayClassName: `pisell-price-keyboard-popover ${overlayClassName}`,
136
+ onOpenChange: handleOpenChange,
137
+ overlayStyle: style
138
+ },
139
+ children
140
+ );
141
+ }
142
+ );
143
+ PisellPriceKeyboardPopover.displayName = "PisellPriceKeyboardPopover";
144
+ var PisellPriceKeyboardPopover_default = PisellPriceKeyboardPopover;
@@ -0,0 +1,23 @@
1
+ .pisell-price-keyboard-popover {
2
+ &.ant-popover {
3
+ z-index: 1050;
4
+
5
+ .ant-popover-inner {
6
+ border-radius: 12px;
7
+ box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
8
+ background: transparent;
9
+ }
10
+
11
+ .ant-popover-inner-content {
12
+ padding: 0;
13
+ background: transparent;
14
+ }
15
+ }
16
+
17
+ .pisell-price-keyboard-popover-content {
18
+ background: rgba(29, 41, 57, 0.8) !important;
19
+ border-radius: 10px;
20
+ overflow: hidden;
21
+ padding: 10px;
22
+ }
23
+ }
@@ -0,0 +1,2 @@
1
+ export { default } from './PisellPriceKeyboardPopover';
2
+ export type { PisellPriceKeyboardPopoverProps, PisellPriceKeyboardPopoverRef } from './types';
@@ -0,0 +1,35 @@
1
+ var __create = Object.create;
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __getProtoOf = Object.getPrototypeOf;
6
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
7
+ var __export = (target, all) => {
8
+ for (var name in all)
9
+ __defProp(target, name, { get: all[name], enumerable: true });
10
+ };
11
+ var __copyProps = (to, from, except, desc) => {
12
+ if (from && typeof from === "object" || typeof from === "function") {
13
+ for (let key of __getOwnPropNames(from))
14
+ if (!__hasOwnProp.call(to, key) && key !== except)
15
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
+ }
17
+ return to;
18
+ };
19
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
+ // If the importer is in node compatibility mode or this is not an ESM
21
+ // file that has been converted to a CommonJS file using a Babel-
22
+ // compatible transform (i.e. "__esModule" has not been set), then set
23
+ // "default" to the CommonJS "module.exports" for node compatibility.
24
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
25
+ mod
26
+ ));
27
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
+
29
+ // src/pro/pisellSimplePriceKeyboardPopover/index.tsx
30
+ var pisellSimplePriceKeyboardPopover_exports = {};
31
+ __export(pisellSimplePriceKeyboardPopover_exports, {
32
+ default: () => import_PisellPriceKeyboardPopover.default
33
+ });
34
+ module.exports = __toCommonJS(pisellSimplePriceKeyboardPopover_exports);
35
+ var import_PisellPriceKeyboardPopover = __toESM(require("./PisellPriceKeyboardPopover"));
@@ -0,0 +1,33 @@
1
+ /// <reference types="react" />
2
+ export interface PisellPriceKeyboardPopoverProps {
3
+ /** 触发元素 */
4
+ children: React.ReactNode;
5
+ /** 当前价格值 */
6
+ value?: string | number;
7
+ /** 价格变化回调(合并了 onChange 和 onEnter) */
8
+ onChange?: (value: string | number) => void;
9
+ /** 确认回调 */
10
+ onConfirm?: (value: string | number) => void;
11
+ /** 取消回调 */
12
+ onCancel?: () => void;
13
+ /** 货币符号显示 */
14
+ showCurrencySymbol?: boolean;
15
+ /** 是否使用千分位分隔符 */
16
+ useThousandsSeparator?: boolean;
17
+ /** 键盘主题 */
18
+ selectType?: 'light' | 'dark';
19
+ /** 是否禁用 */
20
+ disabled?: boolean;
21
+ /** Popover 额外的类名 */
22
+ overlayClassName?: string;
23
+ /** 自定义样式 */
24
+ style?: React.CSSProperties;
25
+ }
26
+ export interface PisellPriceKeyboardPopoverRef {
27
+ /** 打开键盘 */
28
+ open: () => void;
29
+ /** 关闭键盘 */
30
+ close: () => void;
31
+ /** 获取当前是否打开 */
32
+ isOpen: () => boolean;
33
+ }
@@ -0,0 +1,17 @@
1
+ var __defProp = Object.defineProperty;
2
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
+ var __getOwnPropNames = Object.getOwnPropertyNames;
4
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
5
+ var __copyProps = (to, from, except, desc) => {
6
+ if (from && typeof from === "object" || typeof from === "function") {
7
+ for (let key of __getOwnPropNames(from))
8
+ if (!__hasOwnProp.call(to, key) && key !== except)
9
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
10
+ }
11
+ return to;
12
+ };
13
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
14
+
15
+ // src/pro/pisellSimplePriceKeyboardPopover/types.ts
16
+ var types_exports = {};
17
+ module.exports = __toCommonJS(types_exports);
@@ -0,0 +1,5 @@
1
+ /// <reference types="react" />
2
+ import { CashKeyboardBaseProps } from './types';
3
+ import './index.less';
4
+ declare const CashKeyboardIntact: (props: CashKeyboardBaseProps) => JSX.Element;
5
+ export default CashKeyboardIntact;