@pisell/private-materials 6.5.15 → 6.5.16

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 (205) 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/meta.js +1 -1
  5. package/build/lowcode/render/default/view.js +1 -1
  6. package/build/lowcode/view.js +1 -1
  7. package/es/components/ticketBooking/components/ticketBooking/index.js +1 -0
  8. package/lib/components/ticketBooking/components/ticketBooking/index.js +1 -0
  9. package/package.json +1 -1
  10. package/es/components/booking/components/actionButtons/index.d.ts +0 -31
  11. package/es/components/booking/components/footer/amount.d.ts +0 -36
  12. package/es/components/booking/components/footer/index.d.ts +0 -11
  13. package/es/components/booking/components/footer/utils.d.ts +0 -41
  14. package/es/components/booking/components/voucher/index.d.ts +0 -3
  15. package/es/components/booking/forms/footer.d.ts +0 -6
  16. package/es/components/booking/info2/cartClientCard/index.d.ts +0 -6
  17. package/es/components/checkout/PaymentModal.d.ts +0 -31
  18. package/es/components/checkout/components/CashPaymentModule/index.d.ts +0 -24
  19. package/es/components/checkout/components/ScrollableList/index.d.ts +0 -5
  20. package/es/components/checkout/hooks/useWalletPass.d.ts +0 -40
  21. package/es/components/list/List.d.ts +0 -5
  22. package/es/components/list/ResponsiveWrapper.d.ts +0 -16
  23. package/es/components/list/TestResponsiveWrapper.d.ts +0 -8
  24. package/es/components/list/components/EmptyState/EmptyState.d.ts +0 -20
  25. package/es/components/list/components/EmptyState/index.d.ts +0 -2
  26. package/es/components/list/components/ListItemSkeleton/ListItemSkeleton.d.ts +0 -13
  27. package/es/components/list/components/ListItemSkeleton/index.d.ts +0 -2
  28. package/es/components/list/components/Pagination/Pagination.d.ts +0 -30
  29. package/es/components/list/components/Pagination/index.d.ts +0 -1
  30. package/es/components/list/components/ScrollLoader/ScrollLoader.d.ts +0 -18
  31. package/es/components/list/components/ScrollLoader/index.d.ts +0 -2
  32. package/es/components/list/components/Tab/Tab.d.ts +0 -5
  33. package/es/components/list/components/Tab/index.d.ts +0 -2
  34. package/es/components/list/components/Tab/types.d.ts +0 -14
  35. package/es/components/list/components/TabSkeleton/TabSkeleton.d.ts +0 -11
  36. package/es/components/list/components/TabSkeleton/index.d.ts +0 -2
  37. package/es/components/list/components/WaterfallList/WaterfallList.d.ts +0 -33
  38. package/es/components/list/components/WaterfallList/index.d.ts +0 -2
  39. package/es/components/list/examples/GroupedListExample.d.ts +0 -3
  40. package/es/components/list/hooks/index.d.ts +0 -5
  41. package/es/components/list/hooks/useDevice.d.ts +0 -24
  42. package/es/components/list/hooks/useListState.d.ts +0 -43
  43. package/es/components/list/hooks/useWaterfall.d.ts +0 -34
  44. package/es/components/list/index.d.ts +0 -10
  45. package/es/components/list/locales.d.ts +0 -66
  46. package/es/components/list/types.d.ts +0 -177
  47. package/es/components/list/utils/getText.d.ts +0 -53
  48. package/es/components/list/utils/index.d.ts +0 -4
  49. package/es/components/pay/toB/components/MX51/index.d.ts +0 -3
  50. package/es/components/pay/toB/store/hooks.d.ts +0 -15
  51. package/es/components/pay/toB/types/index.d.ts +0 -72
  52. package/es/components/ticketBooking/components/ProductDisplayAdapter/ProductDisplayAdapter.d.ts +0 -27
  53. package/es/components/ticketBooking/components/ProductDisplayAdapter/index.d.ts +0 -7
  54. package/es/components/ticketBooking/components/ProductDisplayAdapter/types.d.ts +0 -115
  55. package/es/components/ticketBooking/components/ProductDisplayAdapter/utils.d.ts +0 -50
  56. package/es/components/ticketBooking/components/addServiceVariant/addService.d.ts +0 -31
  57. package/es/components/ticketBooking/components/addServiceVariant/index.d.ts +0 -10
  58. package/es/components/ticketBooking/components/menuBar/index.d.ts +0 -7
  59. package/es/components/ticketBooking/context/IsActiveContext.d.ts +0 -26
  60. package/es/components/ticketBooking/context/OsKeyContext.d.ts +0 -26
  61. package/es/components/ticketBooking/context/index.d.ts +0 -2
  62. package/es/components/ticketBooking/hooks/pisellos/bookingTicket.d.ts +0 -6
  63. package/es/components/ticketBooking/hooks/pisellos/index.d.ts +0 -4
  64. package/es/components/ticketBooking/hooks/pisellos/useActiveExecute.d.ts +0 -21
  65. package/es/components/ticketBooking/hooks/pisellos/useCustomer.d.ts +0 -25
  66. package/es/components/ticketBooking/hooks/pisellos/useProducts.d.ts +0 -16
  67. package/es/components/ticketBooking/hooks/pisellos/useScanCustomer.d.ts +0 -5
  68. package/es/components/ticketBooking/hooks/pisellos/useScanGlobal.d.ts +0 -5
  69. package/es/components/ticketBooking/hooks/pisellos/useShopDiscountModule.d.ts +0 -6
  70. package/es/components/ticketBooking/index.d.ts +0 -15
  71. package/es/components/ticketBooking/utils/index.d.ts +0 -90
  72. package/es/components/ticketBooking/utils/productCache.d.ts +0 -75
  73. package/es/hooks/printer.d.ts +0 -4
  74. package/es/index.d.ts +0 -65
  75. package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA1/index.d.ts +0 -4
  76. package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA2/index.d.ts +0 -4
  77. package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA5/index.d.ts +0 -4
  78. package/es/plus/productSelect/ProductCard/SkuCard/SkuCardA9/index.d.ts +0 -4
  79. package/es/plus/productSelect/ProductCard/SkuCard/SkuCardCustom/index.d.ts +0 -4
  80. package/es/plus/productSelect/ProductCard/SkuCard/components/Action/index.d.ts +0 -7
  81. package/es/plus/productSelect/ProductCard/SkuCard/components/Capacity/index.d.ts +0 -6
  82. package/es/plus/productSelect/ProductCard/SkuCard/components/CardCom/index.d.ts +0 -8
  83. package/es/plus/productSelect/ProductCard/SkuCard/components/CardMask/index.d.ts +0 -7
  84. package/es/plus/productSelect/ProductCard/SkuCard/components/CardMoreText/index.d.ts +0 -3
  85. package/es/plus/productSelect/ProductCard/SkuCard/components/CardWrapper/index.d.ts +0 -4
  86. package/es/plus/productSelect/ProductCard/SkuCard/components/Countdown/index.d.ts +0 -7
  87. package/es/plus/productSelect/ProductCard/SkuCard/components/Cover/index.d.ts +0 -7
  88. package/es/plus/productSelect/ProductCard/SkuCard/components/Duration/index.d.ts +0 -6
  89. package/es/plus/productSelect/ProductCard/SkuCard/components/Favorite/index.d.ts +0 -6
  90. package/es/plus/productSelect/ProductCard/SkuCard/components/MemberPrice/index.d.ts +0 -7
  91. package/es/plus/productSelect/ProductCard/SkuCard/components/Price/index.d.ts +0 -7
  92. package/es/plus/productSelect/ProductCard/SkuCard/components/Promotions/index.d.ts +0 -6
  93. package/es/plus/productSelect/ProductCard/SkuCard/components/Resource/index.d.ts +0 -6
  94. package/es/plus/productSelect/ProductCard/SkuCard/components/Stock/index.d.ts +0 -6
  95. package/es/plus/productSelect/ProductCard/SkuCard/components/SubTitle/index.d.ts +0 -7
  96. package/es/plus/productSelect/ProductCard/SkuCard/components/Tags/index.d.ts +0 -6
  97. package/es/plus/productSelect/ProductCard/SkuCard/components/Time/index.d.ts +0 -6
  98. package/es/plus/productSelect/ProductCard/SkuCard/components/Title/index.d.ts +0 -7
  99. package/es/plus/productSelect/ProductCard/SkuCard/components/TooltipTags/index.d.ts +0 -7
  100. package/es/plus/productSelect/ProductCard/SkuCard/components/WarningLists/index.d.ts +0 -4
  101. package/es/plus/productSelect/ProductCard/SkuCard/hooks/useDynamicComponents.d.ts +0 -6
  102. package/es/plus/productSelect/ProductCard/SkuCard/index.d.ts +0 -9
  103. package/es/plus/productSelect/ProductCard/SkuCard/locales.d.ts +0 -42
  104. package/es/plus/productSelect/ProductCard/SkuCard/status.d.ts +0 -162
  105. package/es/plus/productSelect/ProductCard/SkuCard/type.d.ts +0 -298
  106. package/es/plus/productSelect/ProductCard/SkuCard/utils.d.ts +0 -9
  107. package/es/plus/productSelect/components/pisellPriceText/index.d.ts +0 -14
  108. package/lib/components/booking/components/actionButtons/index.d.ts +0 -31
  109. package/lib/components/booking/components/footer/amount.d.ts +0 -36
  110. package/lib/components/booking/components/footer/index.d.ts +0 -11
  111. package/lib/components/booking/components/footer/utils.d.ts +0 -41
  112. package/lib/components/booking/components/voucher/index.d.ts +0 -3
  113. package/lib/components/booking/forms/footer.d.ts +0 -6
  114. package/lib/components/booking/info2/cartClientCard/index.d.ts +0 -6
  115. package/lib/components/checkout/PaymentModal.d.ts +0 -31
  116. package/lib/components/checkout/components/CashPaymentModule/index.d.ts +0 -24
  117. package/lib/components/checkout/components/ScrollableList/index.d.ts +0 -5
  118. package/lib/components/checkout/hooks/useWalletPass.d.ts +0 -40
  119. package/lib/components/list/List.d.ts +0 -5
  120. package/lib/components/list/ResponsiveWrapper.d.ts +0 -16
  121. package/lib/components/list/TestResponsiveWrapper.d.ts +0 -8
  122. package/lib/components/list/components/EmptyState/EmptyState.d.ts +0 -20
  123. package/lib/components/list/components/EmptyState/index.d.ts +0 -2
  124. package/lib/components/list/components/ListItemSkeleton/ListItemSkeleton.d.ts +0 -13
  125. package/lib/components/list/components/ListItemSkeleton/index.d.ts +0 -2
  126. package/lib/components/list/components/Pagination/Pagination.d.ts +0 -30
  127. package/lib/components/list/components/Pagination/index.d.ts +0 -1
  128. package/lib/components/list/components/ScrollLoader/ScrollLoader.d.ts +0 -18
  129. package/lib/components/list/components/ScrollLoader/index.d.ts +0 -2
  130. package/lib/components/list/components/Tab/Tab.d.ts +0 -5
  131. package/lib/components/list/components/Tab/index.d.ts +0 -2
  132. package/lib/components/list/components/Tab/types.d.ts +0 -14
  133. package/lib/components/list/components/TabSkeleton/TabSkeleton.d.ts +0 -11
  134. package/lib/components/list/components/TabSkeleton/index.d.ts +0 -2
  135. package/lib/components/list/components/WaterfallList/WaterfallList.d.ts +0 -33
  136. package/lib/components/list/components/WaterfallList/index.d.ts +0 -2
  137. package/lib/components/list/examples/GroupedListExample.d.ts +0 -3
  138. package/lib/components/list/hooks/index.d.ts +0 -5
  139. package/lib/components/list/hooks/useDevice.d.ts +0 -24
  140. package/lib/components/list/hooks/useListState.d.ts +0 -43
  141. package/lib/components/list/hooks/useWaterfall.d.ts +0 -34
  142. package/lib/components/list/index.d.ts +0 -10
  143. package/lib/components/list/locales.d.ts +0 -66
  144. package/lib/components/list/types.d.ts +0 -177
  145. package/lib/components/list/utils/getText.d.ts +0 -53
  146. package/lib/components/list/utils/index.d.ts +0 -4
  147. package/lib/components/pay/toB/components/MX51/index.d.ts +0 -3
  148. package/lib/components/pay/toB/store/hooks.d.ts +0 -15
  149. package/lib/components/pay/toB/types/index.d.ts +0 -72
  150. package/lib/components/ticketBooking/components/ProductDisplayAdapter/ProductDisplayAdapter.d.ts +0 -27
  151. package/lib/components/ticketBooking/components/ProductDisplayAdapter/index.d.ts +0 -7
  152. package/lib/components/ticketBooking/components/ProductDisplayAdapter/types.d.ts +0 -115
  153. package/lib/components/ticketBooking/components/ProductDisplayAdapter/utils.d.ts +0 -50
  154. package/lib/components/ticketBooking/components/addServiceVariant/addService.d.ts +0 -31
  155. package/lib/components/ticketBooking/components/addServiceVariant/index.d.ts +0 -10
  156. package/lib/components/ticketBooking/components/menuBar/index.d.ts +0 -7
  157. package/lib/components/ticketBooking/context/IsActiveContext.d.ts +0 -26
  158. package/lib/components/ticketBooking/context/OsKeyContext.d.ts +0 -26
  159. package/lib/components/ticketBooking/context/index.d.ts +0 -2
  160. package/lib/components/ticketBooking/hooks/pisellos/bookingTicket.d.ts +0 -6
  161. package/lib/components/ticketBooking/hooks/pisellos/index.d.ts +0 -4
  162. package/lib/components/ticketBooking/hooks/pisellos/useActiveExecute.d.ts +0 -21
  163. package/lib/components/ticketBooking/hooks/pisellos/useCustomer.d.ts +0 -25
  164. package/lib/components/ticketBooking/hooks/pisellos/useProducts.d.ts +0 -16
  165. package/lib/components/ticketBooking/hooks/pisellos/useScanCustomer.d.ts +0 -5
  166. package/lib/components/ticketBooking/hooks/pisellos/useScanGlobal.d.ts +0 -5
  167. package/lib/components/ticketBooking/hooks/pisellos/useShopDiscountModule.d.ts +0 -6
  168. package/lib/components/ticketBooking/index.d.ts +0 -15
  169. package/lib/components/ticketBooking/utils/index.d.ts +0 -90
  170. package/lib/components/ticketBooking/utils/productCache.d.ts +0 -75
  171. package/lib/hooks/printer.d.ts +0 -4
  172. package/lib/index.d.ts +0 -65
  173. package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA1/index.d.ts +0 -4
  174. package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA2/index.d.ts +0 -4
  175. package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA5/index.d.ts +0 -4
  176. package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardA9/index.d.ts +0 -4
  177. package/lib/plus/productSelect/ProductCard/SkuCard/SkuCardCustom/index.d.ts +0 -4
  178. package/lib/plus/productSelect/ProductCard/SkuCard/components/Action/index.d.ts +0 -7
  179. package/lib/plus/productSelect/ProductCard/SkuCard/components/Capacity/index.d.ts +0 -6
  180. package/lib/plus/productSelect/ProductCard/SkuCard/components/CardCom/index.d.ts +0 -8
  181. package/lib/plus/productSelect/ProductCard/SkuCard/components/CardMask/index.d.ts +0 -7
  182. package/lib/plus/productSelect/ProductCard/SkuCard/components/CardMoreText/index.d.ts +0 -3
  183. package/lib/plus/productSelect/ProductCard/SkuCard/components/CardWrapper/index.d.ts +0 -4
  184. package/lib/plus/productSelect/ProductCard/SkuCard/components/Countdown/index.d.ts +0 -7
  185. package/lib/plus/productSelect/ProductCard/SkuCard/components/Cover/index.d.ts +0 -7
  186. package/lib/plus/productSelect/ProductCard/SkuCard/components/Duration/index.d.ts +0 -6
  187. package/lib/plus/productSelect/ProductCard/SkuCard/components/Favorite/index.d.ts +0 -6
  188. package/lib/plus/productSelect/ProductCard/SkuCard/components/MemberPrice/index.d.ts +0 -7
  189. package/lib/plus/productSelect/ProductCard/SkuCard/components/Price/index.d.ts +0 -7
  190. package/lib/plus/productSelect/ProductCard/SkuCard/components/Promotions/index.d.ts +0 -6
  191. package/lib/plus/productSelect/ProductCard/SkuCard/components/Resource/index.d.ts +0 -6
  192. package/lib/plus/productSelect/ProductCard/SkuCard/components/Stock/index.d.ts +0 -6
  193. package/lib/plus/productSelect/ProductCard/SkuCard/components/SubTitle/index.d.ts +0 -7
  194. package/lib/plus/productSelect/ProductCard/SkuCard/components/Tags/index.d.ts +0 -6
  195. package/lib/plus/productSelect/ProductCard/SkuCard/components/Time/index.d.ts +0 -6
  196. package/lib/plus/productSelect/ProductCard/SkuCard/components/Title/index.d.ts +0 -7
  197. package/lib/plus/productSelect/ProductCard/SkuCard/components/TooltipTags/index.d.ts +0 -7
  198. package/lib/plus/productSelect/ProductCard/SkuCard/components/WarningLists/index.d.ts +0 -4
  199. package/lib/plus/productSelect/ProductCard/SkuCard/hooks/useDynamicComponents.d.ts +0 -6
  200. package/lib/plus/productSelect/ProductCard/SkuCard/index.d.ts +0 -9
  201. package/lib/plus/productSelect/ProductCard/SkuCard/locales.d.ts +0 -42
  202. package/lib/plus/productSelect/ProductCard/SkuCard/status.d.ts +0 -162
  203. package/lib/plus/productSelect/ProductCard/SkuCard/type.d.ts +0 -298
  204. package/lib/plus/productSelect/ProductCard/SkuCard/utils.d.ts +0 -9
  205. package/lib/plus/productSelect/components/pisellPriceText/index.d.ts +0 -14
@@ -1,53 +0,0 @@
1
- /**
2
- * 国际化文案获取工具函数
3
- * 参考 AmountSummary 组件的实现方式,使用 useEngineContext 获取语言设置
4
- *
5
- * @example
6
- * ```typescript
7
- * import { useGetText } from './utils';
8
- * import locales from './locales';
9
- *
10
- * const MyComponent = () => {
11
- * const { getText, getTextFunc } = useGetText(locales);
12
- *
13
- * // 获取字符串文案
14
- * const title = getText('component.title', 'Default Title');
15
- *
16
- * // 获取函数类型文案
17
- * const formatFunc = getTextFunc('component.format');
18
- * const formattedText = typeof formatFunc === 'function'
19
- * ? formatFunc(arg1, arg2)
20
- * : 'Default Text';
21
- *
22
- * return <div>{title}</div>;
23
- * };
24
- * ```
25
- */
26
- export declare type SupportedLanguage = 'en' | 'zh-CN' | 'zh-HK';
27
- export interface LocalesObject {
28
- [key: string]: {
29
- [key: string]: string | ((...args: any[]) => string);
30
- };
31
- }
32
- export interface GetTextFunctions {
33
- getText: (key: string, fallback?: string) => string;
34
- getTextFunc: (key: string) => any;
35
- getCurrentLanguage: () => string;
36
- }
37
- /**
38
- * 使用 useEngineContext 创建本地化文案获取函数的 Hook
39
- * @param locales - 本地化文案对象
40
- * @returns getText 和 getTextFunc 函数
41
- */
42
- export declare const useGetText: (locales: LocalesObject) => GetTextFunctions;
43
- /**
44
- * 创建本地化文案获取函数(非 Hook 版本,保持向后兼容)
45
- * @param locales - 本地化文案对象
46
- * @returns getText 和 getTextFunc 函数
47
- * @deprecated 推荐使用 useGetText Hook 版本
48
- */
49
- export declare const createGetText: (locales: LocalesObject) => GetTextFunctions;
50
- /**
51
- * 默认导出:直接创建一个通用的 getText 函数工厂
52
- */
53
- export default createGetText;
@@ -1,4 +0,0 @@
1
- /**
2
- * List 组件工具函数导出
3
- */
4
- export { useGetText, createGetText, default as createGetTextDefault, type SupportedLanguage, type LocalesObject, type GetTextFunctions } from './getText';
@@ -1,3 +0,0 @@
1
- import React from 'react';
2
- declare const _default: React.ForwardRefExoticComponent<Omit<any, "ref"> & React.RefAttributes<unknown>>;
3
- export default _default;
@@ -1,15 +0,0 @@
1
- import { ToBPayContextType } from '../types';
2
- /**
3
- * 使用商家端支付的Hook
4
- * @throws {Error} 如果在ToBPayProvider外部使用会抛出错误
5
- * @returns {ToBPayContextType} 商家端支付上下文
6
- */
7
- export declare const useToBPay: () => ToBPayContextType;
8
- export declare const useOSPayment: () => any;
9
- /**
10
- * 使用OS支付的Hook
11
- */
12
- export declare const useOSPaymentEffect: () => {
13
- osPaymentEffectOn: () => void;
14
- osPaymentEffectOff: () => void;
15
- };
@@ -1,72 +0,0 @@
1
- export * from './storeTypes';
2
- export interface ToBPayParams {
3
- source?: 'normal' | 'restore';
4
- data: {
5
- type?: string;
6
- payMethod: {
7
- id: string;
8
- code: string;
9
- type: string;
10
- name: string;
11
- };
12
- params: {
13
- orderId: string | number;
14
- symbol?: string;
15
- amount: string;
16
- surcharge?: string;
17
- };
18
- mode: 'pay' | 'refund';
19
- };
20
- callback: ToBPayCallback;
21
- }
22
- export declare type ToBPayCallback = (res: {
23
- status: string;
24
- data: {
25
- amount: number;
26
- surPercentRate?: number;
27
- surMoney?: number;
28
- surcharge?: number;
29
- uniquePaymentNumber?: string;
30
- };
31
- msg?: string;
32
- }) => void;
33
- /**
34
- * @title: 支付打开参数
35
- */
36
- export interface PayOpenParams extends Omit<ToBPayParams, 'callback'> {
37
- payCallback: (res: EftposPayResult | MX51PayResult) => void;
38
- }
39
- /**
40
- * @title: eftpos支付结果
41
- */
42
- export interface EftposPayResult {
43
- status: 'success' | 'fail';
44
- params: {
45
- amount: number;
46
- surPercentRate: number;
47
- surMoney: number;
48
- uniquePaymentNumber: string;
49
- };
50
- }
51
- /**
52
- * @title: MX51支付结果
53
- */
54
- export interface MX51PayResult {
55
- result: boolean;
56
- msg?: string;
57
- amount: number;
58
- surcharge: number;
59
- uniquePaymentNumber: string;
60
- }
61
- /**
62
- * @title 原生MX51支付结果
63
- */
64
- export interface NativeMX51PayResult {
65
- code: string;
66
- msg?: string;
67
- data: {
68
- amount: number;
69
- surcharge: number;
70
- };
71
- uuid: string;
72
- }
@@ -1,27 +0,0 @@
1
- import React from 'react';
2
- import { ProductDisplayConfig } from './types';
3
- import './index.less';
4
- interface ProductDisplayAdapterProps {
5
- /** 展示配置 */
6
- config: ProductDisplayConfig;
7
- /** 数据源 */
8
- dataSource: any[];
9
- /** 加载状态 */
10
- loading?: boolean;
11
- /** 当前选中的产品ID */
12
- currentProductId?: number;
13
- /** 选择产品回调 */
14
- onSelectProduct: (item: any, type?: 'select' | 'detail') => void;
15
- /** 空状态描述 */
16
- emptyDescription?: string;
17
- /** 自定义样式 */
18
- style?: React.CSSProperties;
19
- /** 自定义类名 */
20
- className?: string;
21
- }
22
- /**
23
- * 产品展示适配器组件
24
- * 统一管理 ProductSelect 和 SkuList 两种展示模式
25
- */
26
- declare const ProductDisplayAdapter: React.FC<ProductDisplayAdapterProps>;
27
- export default ProductDisplayAdapter;
@@ -1,7 +0,0 @@
1
- /**
2
- * ProductDisplayAdapter 产品展示适配器
3
- * 支持通过配置化方式在 ProductSelect 和 SkuList 两种展示模式之间切换
4
- */
5
- export { default } from './ProductDisplayAdapter';
6
- export type { ProductDisplayConfig, ProductDisplayPresetKey, ProductSelectConfig, ProductSelectLayout, ProductListSetting, SkuListConfig, SkuCardDisplayMode, ListConfig, ListLayoutType, DisplayMode, } from './types';
7
- export { ProductDisplayPresets, LegacyProductDisplayPresets, resolveProductDisplayConfig, } from './types';
@@ -1,115 +0,0 @@
1
- /**
2
- * 产品展示配置类型定义
3
- */
4
- import type { ProductCardConfig } from '../../../../plus/productSelect/ProductCard/SkuCard/type';
5
- /** 预设配置的字符串键 */
6
- export declare type ProductDisplayPresetKey = 'product-select' | 'sku-list-a1' | 'sku-list-a2' | 'sku-list-a5' | 'default';
7
- /** ProductSelect 布局配置 */
8
- export interface ProductSelectLayout {
9
- grid: boolean;
10
- config: string;
11
- }
12
- export declare type NumberBoolean = 0 | 1;
13
- /** ProductSelect 列表设置 */
14
- export interface ProductListSetting {
15
- /** 是否显示产品封面 */
16
- isProductCover?: NumberBoolean;
17
- /** 是否显示标题 */
18
- isTitle?: NumberBoolean;
19
- /** 是否显示副标题 */
20
- isSubtitle?: NumberBoolean;
21
- /** 是否显示价格 */
22
- isPrice?: NumberBoolean;
23
- /** 是否显示原价 */
24
- isOriginPrice?: NumberBoolean;
25
- /** 是否显示库存 */
26
- isStock?: NumberBoolean;
27
- }
28
- /** ProductSelect 模式配置 */
29
- export interface ProductSelectConfig {
30
- /** 是否显示搜索框 */
31
- showSearch?: boolean;
32
- /** 是否显示分类Tab */
33
- showTab?: boolean;
34
- /** 布局配置 */
35
- layout?: ProductSelectLayout;
36
- /** 产品列表设置 */
37
- productListSetting?: ProductListSetting;
38
- }
39
- /** SkuCard 显示模式 */
40
- export declare type SkuCardDisplayMode = 'display_a1' | 'display_a2' | 'display_a5' | 'display_a9' | 'display_custom';
41
- /**
42
- * SkuCard 配置
43
- * 直接使用 ProductCardConfig 类型,保持类型同步
44
- *
45
- * @see packages/private-materials/src/plus/productSelect/ProductCard/SkuCard/type.ts ProductCardConfig
46
- */
47
- export declare type SkuCardAllConfig = ProductCardConfig;
48
- /** List 布局类型 */
49
- export declare type ListLayoutType = 'grid' | 'list';
50
- /** Tab 样式类型 */
51
- export declare type TabStyleType = 'switch' | 'anchor' | 'none';
52
- /** List 组件配置 */
53
- export interface ListConfig {
54
- /** 布局类型 */
55
- layout?: ListLayoutType;
56
- /** 列数 */
57
- columns?: number;
58
- /** 是否显示分页 */
59
- showPagination?: boolean;
60
- /** 是否显示Tab */
61
- showTab?: boolean;
62
- /** Tab 样式类型:switch-切换模式,anchor-锚点模式,none-不显示 */
63
- tabStyle?: TabStyleType;
64
- /** Tab 是否吸顶 */
65
- stickyTop?: boolean;
66
- /** Tab配置 */
67
- tabConfig?: any;
68
- /** 分页配置 */
69
- paginationConfig?: any;
70
- [key: string]: any;
71
- }
72
- /** SkuList 模式配置 */
73
- export interface SkuListConfig {
74
- /** List 组件配置 */
75
- listConfig?: ListConfig;
76
- /** SkuCard 配置 */
77
- skuCardAllConfig?: SkuCardAllConfig;
78
- }
79
- /** 展示模式类型 */
80
- export declare type DisplayMode = 'product-select' | 'sku-list';
81
- /**
82
- * 产品展示配置
83
- * 用于配置化控制产品展示的方式
84
- */
85
- export interface ProductDisplayConfig {
86
- /** 展示模式 */
87
- displayMode: DisplayMode;
88
- /** ProductSelect 模式配置 */
89
- productSelectConfig?: ProductSelectConfig;
90
- /** SkuList 模式配置 */
91
- skuListConfig?: SkuListConfig;
92
- }
93
- /**
94
- * 产品展示配置预设
95
- * 支持通过字符串键或直接使用配置对象
96
- */
97
- export declare const ProductDisplayPresets: Record<ProductDisplayPresetKey, ProductDisplayConfig>;
98
- /**
99
- * 兼容性:保持原有的导出方式
100
- * @deprecated 建议使用 ProductDisplayPresets['product-select'] 或字符串键访问
101
- */
102
- export declare const LegacyProductDisplayPresets: {
103
- /** @deprecated 使用 ProductDisplayPresets['product-select'] */
104
- DEFAULT_PRODUCT_SELECT: ProductDisplayConfig;
105
- /** @deprecated 使用 ProductDisplayPresets['sku-list-a1'] */
106
- DEFAULT_SKU_LIST_A1: ProductDisplayConfig;
107
- /** @deprecated 使用 ProductDisplayPresets['sku-list-a2'] */
108
- DEFAULT_SKU_LIST_A2: ProductDisplayConfig;
109
- /** @deprecated 使用 ProductDisplayPresets['sku-list-a5'] */
110
- DEFAULT_SKU_LIST_A5: ProductDisplayConfig;
111
- };
112
- /**
113
- * 工具函数:将字符串键或配置对象解析为配置对象
114
- */
115
- export declare function resolveProductDisplayConfig(config?: ProductDisplayPresetKey | ProductDisplayConfig): ProductDisplayConfig;
@@ -1,50 +0,0 @@
1
- /**
2
- * 格式化 SKU 数据源,适配 SkuCard 组件
3
- */
4
- export declare const formatSkuDataSource: (dataSource: any) => {
5
- id: any;
6
- title: any;
7
- subtitle: any;
8
- cover: any;
9
- price: any;
10
- original_price: any;
11
- stock: any;
12
- sortKeys: string[];
13
- };
14
- /**
15
- * Tab 项接口定义(与 List 组件保持一致)
16
- */
17
- export interface TabItem {
18
- key: string;
19
- label: string;
20
- group?: string;
21
- }
22
- /**
23
- * 产品分类信息接口
24
- */
25
- interface ProductCategory {
26
- id: number;
27
- name: string;
28
- icon?: string;
29
- slug?: string;
30
- sort?: number;
31
- }
32
- /**
33
- * 产品项接口
34
- */
35
- interface Product {
36
- id: number;
37
- title: string;
38
- category?: ProductCategory[];
39
- [key: string]: any;
40
- }
41
- /**
42
- * 根据产品数据生成分类 Tabs(Switch 模式)
43
- * 参考 TestResponsiveWrapper 的 generateSimpleTabItems 函数
44
- *
45
- * @param products 产品列表
46
- * @param tabStyle tab 样式类型
47
- * @returns TabItem 数组
48
- */
49
- export declare const generateProductTabs: (products: Product[], tabStyle?: 'switch' | 'anchor') => TabItem[];
50
- export {};
@@ -1,31 +0,0 @@
1
- import { ProductDisplayConfig, ProductDisplayPresetKey } from '../ProductDisplayAdapter';
2
- import './index.less';
3
- interface AddServiceProps {
4
- onEdit?: any;
5
- dispatch?: any;
6
- state?: any;
7
- renderMode?: 'current' | 'drawer';
8
- onPrerenderComplete?: () => void;
9
- onGetProductsReady?: (getProducts: any) => void;
10
- /**
11
- * 产品展示配置
12
- *
13
- * 支持两种方式:
14
- * 1. 简易模式:传入预设字符串,如 'product-select', 'sku-list-a1', 'sku-list-a2', 'sku-list-a5'
15
- * 2. 完整配置模式:传入完整的配置对象
16
- *
17
- * @example
18
- * // 简易模式
19
- * <AddService productDisplayConfig="sku-list-a1" />
20
- *
21
- * @example
22
- * // 完整配置模式
23
- * <AddService productDisplayConfig={{
24
- * displayMode: 'sku-list',
25
- * skuListConfig: { ... }
26
- * }} />
27
- */
28
- productDisplayConfig?: ProductDisplayPresetKey | ProductDisplayConfig;
29
- }
30
- declare const AddSerivce: (props: AddServiceProps) => JSX.Element | null;
31
- export default AddSerivce;
@@ -1,10 +0,0 @@
1
- import { ProductDisplayConfig, ProductDisplayPresetKey } from '../ProductDisplayAdapter/types';
2
- interface AddServiceVariantProps {
3
- globalState: any;
4
- setGlobalState: any;
5
- onPrerenderComplete?: () => void;
6
- onGetProductsReady?: (getProducts: any) => void;
7
- productDisplayConfig?: ProductDisplayPresetKey | ProductDisplayConfig;
8
- }
9
- declare const AddServiceVariant: (props: AddServiceVariantProps) => JSX.Element;
10
- export default AddServiceVariant;
@@ -1,7 +0,0 @@
1
- import './index.less';
2
- interface MenuBarProps {
3
- activeNavKey?: string;
4
- onNavChange?: (key: string) => void;
5
- }
6
- declare const index: (props: MenuBarProps) => JSX.Element;
7
- export default index;
@@ -1,26 +0,0 @@
1
- import React from 'react';
2
- /**
3
- * IsActive Context
4
- * 用于在 TicketBooking 组件树中提供 isActive 状态
5
- * isActive 用于标识当前组件是否处于激活状态
6
- */
7
- interface IsActiveContextType {
8
- /** 是否激活 */
9
- isActive: boolean;
10
- }
11
- declare const IsActiveContext: React.Context<IsActiveContextType>;
12
- interface IsActiveProviderProps {
13
- isActive: boolean;
14
- children: React.ReactNode;
15
- }
16
- /**
17
- * IsActive Provider
18
- * 提供 isActive 给子组件使用
19
- */
20
- export declare const IsActiveProvider: React.FC<IsActiveProviderProps>;
21
- /**
22
- * useIsActive Hook
23
- * 在子组件中使用此 hook 获取 isActive 状态
24
- */
25
- export declare const useIsActive: () => boolean;
26
- export default IsActiveContext;
@@ -1,26 +0,0 @@
1
- import React from 'react';
2
- /**
3
- * OsKey Context
4
- * 用于在 TicketBooking 组件树中提供 pisellos 的 osKey
5
- * osKey 用于区分不同页面使用同一个组件时的模块标识
6
- */
7
- interface OsKeyContextType {
8
- /** pisellos 模块的唯一标识 */
9
- osKey: string | undefined;
10
- }
11
- declare const OsKeyContext: React.Context<OsKeyContextType>;
12
- interface OsKeyProviderProps {
13
- osKey: string | undefined;
14
- children: React.ReactNode;
15
- }
16
- /**
17
- * OsKey Provider
18
- * 提供 osKey 给子组件使用
19
- */
20
- export declare const OsKeyProvider: React.FC<OsKeyProviderProps>;
21
- /**
22
- * useOsKey Hook
23
- * 在子组件中使用此 hook 获取 osKey
24
- */
25
- export declare const useOsKey: () => string;
26
- export default OsKeyContext;
@@ -1,2 +0,0 @@
1
- export { OsKeyProvider, useOsKey } from './OsKeyContext';
2
- export { default as OsKeyContext } from './OsKeyContext';
@@ -1,6 +0,0 @@
1
- /**
2
- * useBookingTicket Hook
3
- * 获取当前 TicketBooking 实例对应的 BookingTicket 模块
4
- * 通过 osKey 区分不同页面的模块实例
5
- */
6
- export declare const useBookingTicket: () => any;
@@ -1,4 +0,0 @@
1
- export * from './bookingTicket';
2
- export * from './useProducts';
3
- export * from './useCustomer';
4
- export * from './useActiveExecute';
@@ -1,21 +0,0 @@
1
- /**
2
- * useActiveExecute Hook
3
- * 返回一个函数,该函数接收一个回调函数,并返回一个包装后的函数
4
- * 包装后的函数只在 isActive 为 true 时执行原始回调
5
- *
6
- * @example
7
- * ```tsx
8
- * const { executeIfActive } = useActiveExecute();
9
- *
10
- * // 创建一个包装函数用于事件监听
11
- * const handleChange = (data) => {
12
- * console.log('data:', data);
13
- * };
14
- *
15
- * // 返回的函数会在被调用时检查 isActive
16
- * pisellos.effects.on('event', executeIfActive(handleChange));
17
- * ```
18
- */
19
- export declare const useActiveExecute: () => {
20
- executeIfActive: <T extends (...args: any[]) => any>(fn: T) => T;
21
- };
@@ -1,25 +0,0 @@
1
- import { ClientData } from '../../../booking/info2/cartClientCard/types';
2
- export declare const useCustomer: (props: {
3
- changeCustomerToGlobalState?: ((value: ClientData) => void) | undefined;
4
- }) => {
5
- customers: never[];
6
- selectedCustomer: ClientData | null;
7
- loading: boolean;
8
- error: null;
9
- pagination: {
10
- page: number;
11
- pageSize: number;
12
- total: number;
13
- };
14
- loadCustomers: (params?: {
15
- skip?: number;
16
- num?: number;
17
- search?: string;
18
- }) => Promise<void>;
19
- changePage: (page: number, pageSize: number) => Promise<void>;
20
- selectCustomer: (customer: ClientData | null) => void;
21
- addCustomerToFirst: (customer: ClientData) => void;
22
- initLoad: (this: any, keyword?: any) => Promise<void>;
23
- hasMore: boolean;
24
- loadMore: () => Promise<void>;
25
- };
@@ -1,16 +0,0 @@
1
- interface IGetProductsParams {
2
- schedule_date?: string;
3
- customer_id?: number;
4
- menu_list_ids?: number[];
5
- schedule_datetime?: string;
6
- }
7
- interface IGetScheduleTimePointsParams {
8
- menu_list_ids?: number[];
9
- }
10
- export declare const useProducts: () => {
11
- getScheduleTimePoints: (params?: IGetScheduleTimePointsParams) => Promise<void>;
12
- getProducts: (params?: IGetProductsParams) => Promise<void>;
13
- products: any[];
14
- loading: boolean;
15
- };
16
- export {};
@@ -1,5 +0,0 @@
1
- declare const useScanCustomer: () => {
2
- openScan: (callback: (data: any) => void) => void;
3
- closeScan: () => void;
4
- };
5
- export default useScanCustomer;
@@ -1,5 +0,0 @@
1
- declare const useScanGlobal: () => {
2
- openScan: (callback: (data: any) => void) => void;
3
- closeScan: () => void;
4
- };
5
- export default useScanGlobal;
@@ -1,6 +0,0 @@
1
- /**
2
- * useShopDiscountModule Hook
3
- * 获取当前 ShopDiscount 模块
4
- * 通过 osKey 区分不同页面的模块实例
5
- */
6
- export declare const useShopDiscountModule: () => any;
@@ -1,15 +0,0 @@
1
- import { ProductDisplayConfig, ProductDisplayPresetKey } from './components/ProductDisplayAdapter/types';
2
- import './index.less';
3
- interface TicketBookingProps {
4
- productExtensionType: string[];
5
- bookingConfigParams: Record<string, any>;
6
- isShowMenuBar?: boolean;
7
- onPrerenderComplete?: () => void;
8
- isShowTimeBar?: boolean;
9
- isShowFloatButtons?: boolean;
10
- productDisplayConfig?: ProductDisplayPresetKey | ProductDisplayConfig;
11
- isActive?: boolean;
12
- rulesHooks?: any;
13
- }
14
- declare const _default: (props: TicketBookingProps) => JSX.Element;
15
- export default _default;
@@ -1,90 +0,0 @@
1
- import type { Dayjs } from 'dayjs';
2
- /** dayjs对象格式化为字符串时间 */
3
- export declare const formatDateToStr: (date: Dayjs[]) => string | string[];
4
- export declare const getDefaultStartParam: () => string | string[];
5
- export declare const formatBookingList: (bookingList: any[]) => any[];
6
- export declare const getNextTimeSlice: (sliceMinutes: number) => Dayjs;
7
- export declare const getDisabledEdit: ({ shop_discount, bookings, payment_status }: any) => boolean;
8
- export declare const formatOptions: (detail: any) => any;
9
- export declare const formatHolder: (detail: any) => any;
10
- export declare const restoreProductOtherData: (data: any) => {
11
- product_id: any;
12
- option: any;
13
- bundle: any;
14
- product_variant_id: any;
15
- quantity: number;
16
- } | undefined;
17
- export declare const isSameProduct: (a: any, b: any) => boolean;
18
- export declare const addService: (list: any[], addItem: any, state: any) => {
19
- list: any[];
20
- quantity: any;
21
- };
22
- export declare const addServiceScroll: (rowKey: string, cacheItem: any) => void;
23
- export declare const getCartProductOverlay: (state: any) => any;
24
- export declare const getIsOverlayProduct: (item: any, state: any) => any;
25
- export declare const getIsShowNumber: (item: any, state: any) => any;
26
- export declare const genServiceKey: (item: any) => string;
27
- export declare const getIsParallelResourcesBooking: (record: any) => boolean;
28
- declare type ScanData = {
29
- type: string;
30
- status: 'success' | 'failed';
31
- scanType: 'nfc' | 'scanner';
32
- scanCode: string;
33
- result: {
34
- searchType: 'customer' | 'wallet' | 'walletPass' | 'product' | 'local_product';
35
- response: {
36
- status: boolean;
37
- code: number;
38
- message: string;
39
- data: any;
40
- };
41
- };
42
- };
43
- export declare const formatScanCustomer: (data: ScanData) => {
44
- searchType: "product" | "customer" | "wallet" | "walletPass" | "local_product";
45
- data: any;
46
- scanCode: string;
47
- } | null;
48
- export declare const formatScanGlobal: (data: ScanData) => {
49
- searchType: "wallet";
50
- data: any;
51
- scanCode: string;
52
- } | {
53
- searchType: "walletPass";
54
- data: any;
55
- scanCode: string;
56
- } | {
57
- searchType: "product" | "local_product";
58
- data: any;
59
- scanCode: string;
60
- } | null | undefined;
61
- export declare const createSimpleCacheItem: (item: any, e: any, state: any) => any;
62
- export declare const getBookingTicketKey: (osKey: string) => string;
63
- export declare const getShopDiscountKey: (osKey: string) => string;
64
- export declare const rulesHooks: {
65
- getProduct(product: Record<string, any>): {
66
- booking_id: any;
67
- id: any;
68
- _id: any;
69
- price: any;
70
- total: any;
71
- discount_list: any;
72
- origin_total: any;
73
- num: any;
74
- quantity: any;
75
- vouchersApplicable: any;
76
- };
77
- setProduct(product: Record<string, any>, values: {
78
- total: number;
79
- discount_list: any[];
80
- price: number;
81
- quantity: number;
82
- _id?: string;
83
- }): {
84
- _id: any;
85
- discount_list: any[];
86
- _extend: any;
87
- };
88
- };
89
- export { getCache, setCache, clearCache, clearAllCache, clearAllCacheByOsKey, getProductCache, setProductCache, clearProductCache, clearAllProductCache, getBoardConfigCache, setBoardConfigCache, clearBoardConfigCache, } from './productCache';
90
- export type { CacheType } from './productCache';