@pisell/private-materials 6.4.73 → 6.4.74

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 (95) 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 +4 -4
  7. package/build/lowcode/render/default/view.css +1 -1
  8. package/build/lowcode/render/default/view.js +5 -5
  9. package/build/lowcode/view.css +1 -1
  10. package/build/lowcode/view.js +5 -5
  11. package/es/components/booking/components/footer/index.js +62 -53
  12. package/es/components/booking/info/service2/utils.d.ts +1 -1
  13. package/es/components/booking/utils.d.ts +2 -2
  14. package/es/components/checkout/PaymentModal.js +178 -108
  15. package/es/components/checkout/components/AdditionalModule/index.d.ts +3 -1
  16. package/es/components/checkout/components/AdditionalModule/index.js +44 -12
  17. package/es/components/checkout/components/AmountSummary/index.js +9 -76
  18. package/es/components/checkout/components/AmountSummary/index.less +1 -1
  19. package/es/components/checkout/components/CashPaymentModule/index.d.ts +3 -1
  20. package/es/components/checkout/components/CashPaymentModule/index.js +5 -2
  21. package/es/components/checkout/components/PaymentOptionsModule/PaymentMethodItem.d.ts +2 -0
  22. package/es/components/checkout/components/PaymentOptionsModule/PaymentMethodItem.js +6 -1
  23. package/es/components/checkout/components/PaymentOptionsModule/index.d.ts +1 -0
  24. package/es/components/checkout/components/PaymentOptionsModule/index.js +2 -1
  25. package/es/components/checkout/components/PaymentOptionsModule/index.less +4 -0
  26. package/es/components/checkout/components/PaymentResultToast/PaymentResultToastProvider.d.ts +4 -0
  27. package/es/components/checkout/components/PaymentResultToast/PaymentResultToastProvider.js +31 -8
  28. package/es/components/checkout/components/PaymentResultToast/index.js +6 -6
  29. package/es/components/checkout/components/PaymentResultToast/index.less +94 -33
  30. package/es/components/checkout/hooks/useWalletPass.d.ts +1 -1
  31. package/es/components/checkout/index.less +1 -1
  32. package/es/components/checkout/locales.d.ts +3 -0
  33. package/es/components/checkout/locales.js +3 -0
  34. package/es/components/checkout/utils/PaymentResultToastUtils.js +11 -1
  35. package/es/components/eftposPay/amount.d.ts +1 -1
  36. package/es/components/eftposPay/device.d.ts +1 -1
  37. package/es/components/eftposPay/hooks.d.ts +1 -1
  38. package/es/components/eftposPay/store/index.d.ts +2 -2
  39. package/es/components/ticketBooking/components/timeBar/index.js +112 -7
  40. package/es/components/ticketBooking/components/timeBar/index.less +59 -0
  41. package/es/components/ticketBooking/locales.d.ts +6 -0
  42. package/es/components/ticketBooking/locales.js +9 -3
  43. package/es/components/ticketBooking/utils/index.d.ts +1 -1
  44. package/es/pro/priceKeyboard/components/cashKeyboard/CashKeyboardIntact.js +11 -7
  45. package/es/pro/priceKeyboard/components/cashKeyboard/index.d.ts +1 -0
  46. package/es/pro/priceKeyboard/components/cashKeyboard/index.js +4 -2
  47. package/es/pro/priceKeyboard/components/cashKeyboard/types.d.ts +1 -0
  48. package/es/pro/priceKeyboard/components/discountKeyboard/index.js +10 -1
  49. package/es/pro/priceKeyboard/components/discountKeyboard/index.less +14 -0
  50. package/es/pro/priceKeyboard/components/shortcuts/index.d.ts +1 -0
  51. package/es/pro/priceKeyboard/components/shortcuts/index.js +5 -2
  52. package/es/pro/priceKeyboard/components/shortcuts/index.less +4 -0
  53. package/lib/components/booking/components/footer/index.js +15 -8
  54. package/lib/components/booking/info/service2/utils.d.ts +1 -1
  55. package/lib/components/booking/utils.d.ts +2 -2
  56. package/lib/components/checkout/PaymentModal.js +73 -11
  57. package/lib/components/checkout/components/AdditionalModule/index.d.ts +3 -1
  58. package/lib/components/checkout/components/AdditionalModule/index.js +44 -11
  59. package/lib/components/checkout/components/AmountSummary/index.js +5 -46
  60. package/lib/components/checkout/components/AmountSummary/index.less +1 -1
  61. package/lib/components/checkout/components/CashPaymentModule/index.d.ts +3 -1
  62. package/lib/components/checkout/components/CashPaymentModule/index.js +5 -2
  63. package/lib/components/checkout/components/PaymentOptionsModule/PaymentMethodItem.d.ts +2 -0
  64. package/lib/components/checkout/components/PaymentOptionsModule/PaymentMethodItem.js +5 -1
  65. package/lib/components/checkout/components/PaymentOptionsModule/index.d.ts +1 -0
  66. package/lib/components/checkout/components/PaymentOptionsModule/index.js +6 -0
  67. package/lib/components/checkout/components/PaymentOptionsModule/index.less +4 -0
  68. package/lib/components/checkout/components/PaymentResultToast/PaymentResultToastProvider.d.ts +4 -0
  69. package/lib/components/checkout/components/PaymentResultToast/PaymentResultToastProvider.js +23 -5
  70. package/lib/components/checkout/components/PaymentResultToast/index.js +4 -4
  71. package/lib/components/checkout/components/PaymentResultToast/index.less +94 -33
  72. package/lib/components/checkout/hooks/useWalletPass.d.ts +1 -1
  73. package/lib/components/checkout/index.less +1 -1
  74. package/lib/components/checkout/locales.d.ts +3 -0
  75. package/lib/components/checkout/locales.js +3 -0
  76. package/lib/components/checkout/utils/PaymentResultToastUtils.js +11 -1
  77. package/lib/components/eftposPay/amount.d.ts +1 -1
  78. package/lib/components/eftposPay/device.d.ts +1 -1
  79. package/lib/components/eftposPay/hooks.d.ts +1 -1
  80. package/lib/components/eftposPay/store/index.d.ts +2 -2
  81. package/lib/components/ticketBooking/components/timeBar/index.js +105 -4
  82. package/lib/components/ticketBooking/components/timeBar/index.less +59 -0
  83. package/lib/components/ticketBooking/locales.d.ts +6 -0
  84. package/lib/components/ticketBooking/locales.js +9 -3
  85. package/lib/components/ticketBooking/utils/index.d.ts +1 -1
  86. package/lib/pro/priceKeyboard/components/cashKeyboard/CashKeyboardIntact.js +9 -5
  87. package/lib/pro/priceKeyboard/components/cashKeyboard/index.d.ts +1 -0
  88. package/lib/pro/priceKeyboard/components/cashKeyboard/index.js +3 -2
  89. package/lib/pro/priceKeyboard/components/cashKeyboard/types.d.ts +1 -0
  90. package/lib/pro/priceKeyboard/components/discountKeyboard/index.js +8 -1
  91. package/lib/pro/priceKeyboard/components/discountKeyboard/index.less +14 -0
  92. package/lib/pro/priceKeyboard/components/shortcuts/index.d.ts +1 -0
  93. package/lib/pro/priceKeyboard/components/shortcuts/index.js +3 -2
  94. package/lib/pro/priceKeyboard/components/shortcuts/index.less +4 -0
  95. package/package.json +1 -1
@@ -59,7 +59,8 @@ var CashKeyboardIntact = (props) => {
59
59
  doneText,
60
60
  resetText,
61
61
  disabled,
62
- hiddenChangeDue
62
+ hiddenChangeDue,
63
+ shortcutsSize
63
64
  } = props;
64
65
  const [internalValue, setInternalValue] = (0, import_ahooks.useControllableValue)(props);
65
66
  const [isShowModal, setIsShowModal] = (0, import_react.useState)(false);
@@ -129,7 +130,8 @@ var CashKeyboardIntact = (props) => {
129
130
  value: "pay",
130
131
  style: {
131
132
  color: "white",
132
- backgroundColor: "#7F56DA"
133
+ backgroundColor: "#7F56DA",
134
+ gridColumn: "span 2"
133
135
  },
134
136
  onClick: () => {
135
137
  var _a2;
@@ -138,7 +140,7 @@ var CashKeyboardIntact = (props) => {
138
140
  }
139
141
  ];
140
142
  const userPresets = presets || [];
141
- const maxUserPresets = 8 - defaultEndPresets.length;
143
+ const maxUserPresets = 7 - defaultEndPresets.length;
142
144
  const limitedUserPresets = userPresets.slice(0, maxUserPresets);
143
145
  return [...limitedUserPresets, ...defaultEndPresets];
144
146
  };
@@ -273,10 +275,11 @@ var CashKeyboardIntact = (props) => {
273
275
  padding: "6px 16px",
274
276
  borderRadius: "8px",
275
277
  backgroundColor: "white",
276
- boxShadow: "0px 1px 2px rgba(16, 24, 40, 0.06)",
278
+ boxShadow: "inset 0 2px 4px rgba(16, 24, 40, 0.08), inset 0 -2px 4px rgba(16, 24, 40, 0.08), inset 2px 0 4px rgba(16, 24, 40, 0.08), inset -2px 0 4px rgba(16, 24, 40, 0.08)",
277
279
  overflow: "hidden",
278
280
  maxWidth: 188,
279
- cursor: "pointer"
281
+ cursor: "pointer",
282
+ border: "1px solid #7f56da"
280
283
  },
281
284
  onClick: () => {
282
285
  setIsShowModal(true);
@@ -365,6 +368,7 @@ var CashKeyboardIntact = (props) => {
365
368
  )), /* @__PURE__ */ import_react.default.createElement(
366
369
  import_shortcuts.default,
367
370
  {
371
+ size: shortcutsSize || "default",
368
372
  presets: getDefaultPresets(),
369
373
  onChange: setInternalValue,
370
374
  disabled
@@ -6,6 +6,7 @@ export interface CashKeyboardProps extends CashKeyboardBaseProps {
6
6
  [key: string]: any;
7
7
  };
8
8
  variant?: 'intact' | 'simple';
9
+ shortcutsSize?: 'default' | 'large';
9
10
  }
10
11
  declare const CashKeyboard: (props: CashKeyboardProps) => JSX.Element;
11
12
  export default CashKeyboard;
@@ -48,7 +48,7 @@ var CashKeyboard = (props) => {
48
48
  );
49
49
  const { getData } = context.appHelper.utils;
50
50
  const amountSymbol = props.amountSymbol || (getData == null ? void 0 : getData("shop_symbol")) || "$";
51
- const { variant = "intact", value, onChange, ...otherProps } = props;
51
+ const { variant = "intact", value, onChange, shortcutsSize, ...otherProps } = props;
52
52
  const [internalValue, setInternalValue] = (0, import_ahooks.useControllableValue)(props);
53
53
  if (variant === "intact") {
54
54
  return /* @__PURE__ */ import_react.default.createElement(
@@ -58,7 +58,8 @@ var CashKeyboard = (props) => {
58
58
  amountSymbol,
59
59
  value: internalValue,
60
60
  placeholder: `${amountSymbol}0`,
61
- onChange: setInternalValue
61
+ onChange: setInternalValue,
62
+ shortcutsSize
62
63
  }
63
64
  );
64
65
  }
@@ -94,4 +94,5 @@ export interface CashKeyboardBaseProps {
94
94
  keyboardButtonBackgroundColor?: string;
95
95
  keyboardButtonTextColor?: string;
96
96
  keyboardButtonHoverColor?: string;
97
+ shortcutsSize?: 'default' | 'large';
97
98
  }
@@ -55,6 +55,7 @@ var DiscountKeyboardBase = (props) => {
55
55
  defaultValue,
56
56
  originalValue,
57
57
  selectType = "light",
58
+ tips,
58
59
  resetText,
59
60
  doneText,
60
61
  onEnter,
@@ -344,7 +345,13 @@ var DiscountKeyboardBase = (props) => {
344
345
  )
345
346
  );
346
347
  };
347
- return /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-pro-price-keyboard-discount" }, /* @__PURE__ */ import_react.default.createElement(
348
+ const renderTipsContent = () => {
349
+ if (tips) {
350
+ return /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-pro-price-keyboard-tips" }, tips);
351
+ }
352
+ return null;
353
+ };
354
+ return /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-pro-price-keyboard-discount" }, renderTipsContent(), /* @__PURE__ */ import_react.default.createElement(
348
355
  import_antd.Segmented,
349
356
  {
350
357
  size: "large",
@@ -7,6 +7,20 @@
7
7
  gap: 10px;
8
8
  background-color: var(--pisell-pro-price-keyboard-bg-color, #ffffff);
9
9
 
10
+ .pisell-pro-price-keyboard-tips {
11
+ background-color: var(
12
+ --pisell-pro-price-keyboard-bg-color-gray-200,
13
+ #eaecf0
14
+ );
15
+ color: #ffffff;
16
+ font-size: 14px;
17
+ font-weight: 600;
18
+ height: 36px;
19
+ line-height: 36px;
20
+ text-align: center;
21
+ border-radius: 8px;
22
+ }
23
+
10
24
  .ellipsis {
11
25
  overflow: hidden;
12
26
  text-overflow: ellipsis;
@@ -12,6 +12,7 @@ export interface ShortcutsProps {
12
12
  presets?: ShortcutsItem[];
13
13
  onChange?: (val: string) => void;
14
14
  disabled?: boolean;
15
+ size?: 'default' | 'large';
15
16
  }
16
17
  declare const _default: React.MemoExoticComponent<React.ForwardRefExoticComponent<ShortcutsProps & React.RefAttributes<HTMLDivElement>>>;
17
18
  export default _default;
@@ -36,7 +36,7 @@ var import_react = __toESM(require("react"));
36
36
  var import_classnames = __toESM(require("classnames"));
37
37
  var import_index = require("./index.less");
38
38
  var Shortcuts = (0, import_react.forwardRef)((props, ref) => {
39
- const { presets, onChange, disabled } = props;
39
+ const { presets, onChange, disabled, size = "default" } = props;
40
40
  const handleItemClick = (item) => {
41
41
  if (disabled || item.disabled) {
42
42
  return;
@@ -65,7 +65,8 @@ var Shortcuts = (0, import_react.forwardRef)((props, ref) => {
65
65
  const itemProps = {
66
66
  key: index,
67
67
  className: (0, import_classnames.default)("pisell-virtual-keyboard-shortcut", {
68
- disabled: item.disabled
68
+ disabled: item.disabled,
69
+ large: size === "large"
69
70
  }),
70
71
  style: item.style,
71
72
  onClick: () => handleItemClick(item)
@@ -28,6 +28,10 @@
28
28
  cursor: pointer;
29
29
  position: relative;
30
30
 
31
+ &.large {
32
+ height: 54px;
33
+ }
34
+
31
35
  &.disabled {
32
36
  cursor: not-allowed;
33
37
  pointer-events: none;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pisell/private-materials",
3
- "version": "6.4.73",
3
+ "version": "6.4.74",
4
4
  "main": "./lib/index.js",
5
5
  "module": "./es/index.js",
6
6
  "types": "./lib/index.d.ts",