@pisell/materials 1.0.935 → 1.0.937

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 (238) 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 +7 -7
  6. package/build/lowcode/preview.js +148 -164
  7. package/build/lowcode/render/default/view.css +1 -1
  8. package/build/lowcode/render/default/view.js +15 -30
  9. package/build/lowcode/view.css +1 -1
  10. package/build/lowcode/view.js +26 -41
  11. package/es/components/pisellWalletPassCard/index.js +4 -2
  12. package/es/components/productCard/components/Packages/utils.d.ts +1 -1
  13. package/es/components/virtualInput/BaseVirtualInput/index.less +0 -1
  14. package/es/components/walletCard/index.js +47 -36
  15. package/es/index.js +2 -1
  16. package/es/locales/en-US.js +1 -1
  17. package/es/locales/zh-CN.js +1 -1
  18. package/es/locales/zh-TW.js +1 -1
  19. package/es/utils/platform.d.ts +1 -1
  20. package/lib/components/pisellWalletPassCard/index.js +5 -1
  21. package/lib/components/productCard/components/Packages/utils.d.ts +1 -1
  22. package/lib/components/virtualInput/BaseVirtualInput/index.less +0 -1
  23. package/lib/components/walletCard/index.js +43 -27
  24. package/lib/index.js +3 -0
  25. package/lib/locales/en-US.js +1 -1
  26. package/lib/locales/zh-CN.js +1 -1
  27. package/lib/locales/zh-TW.js +1 -1
  28. package/lib/utils/platform.d.ts +1 -1
  29. package/lowcode/auto-resize-text/meta.ts +9431 -0
  30. package/package.json +3 -3
  31. package/es/components/appVersionControl/index.d.ts +0 -4
  32. package/es/components/auto-resize-text/auto-text-size-standalone.d.ts +0 -20
  33. package/es/components/auto-resize-text/index.d.ts +0 -6
  34. package/es/components/cardPro/index.d.ts +0 -3
  35. package/es/components/dataSourceComponents/dataSourceForm/utils.d.ts +0 -56
  36. package/es/components/dataSourceComponents/dataSourceTable/BaseTable.d.ts +0 -8
  37. package/es/components/dataSourceComponents/dataSourceTable/filter/index.d.ts +0 -27
  38. package/es/components/dataSourceComponents/dataSourceTable/hooks/useDrawerState.d.ts +0 -39
  39. package/es/components/dataSourceComponents/dataSourceTable/hooks/useTableProps.d.ts +0 -98
  40. package/es/components/dataSourceComponents/dataSourceTable/hooks/useTableQuery.d.ts +0 -33
  41. package/es/components/dataSourceComponents/dataSourceTable/type.d.ts +0 -85
  42. package/es/components/dataSourceComponents/fields/Input.Mobile/WithMode.d.ts +0 -16
  43. package/es/components/dataSourceComponents/fields/Input.Phone/WithMode.d.ts +0 -16
  44. package/es/components/dataSourceComponents/fields/Input.Phone/serve.d.ts +0 -25
  45. package/es/components/dataSourceComponents/fields/Upload/BaseUpload.d.ts +0 -5
  46. package/es/components/dataSourceComponents/fields/Upload/CameraPopover.d.ts +0 -5
  47. package/es/components/dataSourceComponents/fields/Upload/type.d.ts +0 -38
  48. package/es/components/drag-sort-tree/TreeItem/index.d.ts +0 -18
  49. package/es/components/drag-sort-tree/index.d.ts +0 -3
  50. package/es/components/filter/types.d.ts +0 -45
  51. package/es/components/hardwareErrorTip/demo.d.ts +0 -3
  52. package/es/components/hardwareErrorTip/errorCard/index.d.ts +0 -28
  53. package/es/components/hardwareErrorTip/errorTipStatistics/index.d.ts +0 -12
  54. package/es/components/hardwareErrorTip/index.d.ts +0 -19
  55. package/es/components/hardwareErrorTip/logCard/index.d.ts +0 -27
  56. package/es/components/hardwareErrorTip/types.d.ts +0 -28
  57. package/es/components/iconfont/index.d.ts +0 -8
  58. package/es/components/keyboard/index.d.ts +0 -22
  59. package/es/components/login-and-register/index.d.ts +0 -82
  60. package/es/components/pisell-config-provider/context.d.ts +0 -22
  61. package/es/components/pisell-config-provider/index.d.ts +0 -13
  62. package/es/components/pisellAdjustPrice/index.d.ts +0 -4
  63. package/es/components/pisellAdjustPrice/status.d.ts +0 -32
  64. package/es/components/pisellAdjustPrice/type.d.ts +0 -22
  65. package/es/components/pisellCamera/index.d.ts +0 -4
  66. package/es/components/pisellCardList/index.d.ts +0 -107
  67. package/es/components/pisellCheckboxGroup/index.d.ts +0 -40
  68. package/es/components/pisellEmpty/index.d.ts +0 -19
  69. package/es/components/pisellGoodPassCard/index.d.ts +0 -50
  70. package/es/components/pisellText/components/Amount/index.d.ts +0 -20
  71. package/es/components/pisellToast/index.d.ts +0 -17
  72. package/es/components/pisellToast/squareToast/index.d.ts +0 -15
  73. package/es/components/pisellToast/squareToast/methods.d.ts +0 -13
  74. package/es/components/pisellToast/squareToast/renderImperatively.d.ts +0 -29
  75. package/es/components/pisellToast/squareToast/toast.d.ts +0 -25
  76. package/es/components/pisellWalletPassCard/index.d.ts +0 -140
  77. package/es/components/pisellWalletPassCard/utils.d.ts +0 -44
  78. package/es/components/productCard/cartSkuCard/components/AmountFooter/index.d.ts +0 -3
  79. package/es/components/productCard/cartSkuCard/components/MultiDay/index.d.ts +0 -3
  80. package/es/components/productCard/cartSkuCard/components/MultiDay/utils.d.ts +0 -14
  81. package/es/components/productCard/cartSkuCard/components/Note/index.d.ts +0 -3
  82. package/es/components/productCard/cartSkuCard/components/basicInfo/index.d.ts +0 -27
  83. package/es/components/productCard/cartSkuCard/components/discountReason/index.d.ts +0 -2
  84. package/es/components/productCard/cartSkuCard/components/holders/index.d.ts +0 -3
  85. package/es/components/productCard/cartSkuCard/components/packages/index.d.ts +0 -10
  86. package/es/components/productCard/cartSkuCard/components/packages/utils.d.ts +0 -20
  87. package/es/components/productCard/cartSkuCard/components/resources/index.d.ts +0 -3
  88. package/es/components/productCard/cartSkuCard/components/sales/index.d.ts +0 -12
  89. package/es/components/productCard/cartSkuCard/components/specs/index.d.ts +0 -3
  90. package/es/components/productCard/cartSkuCard/components/swipeAction/index.d.ts +0 -46
  91. package/es/components/productCard/cartSkuCard/components/timeRange/index.d.ts +0 -6
  92. package/es/components/productCard/cartSkuCard/index.d.ts +0 -10
  93. package/es/components/productCard/cartSkuCard/locales.d.ts +0 -96
  94. package/es/components/productCard/components/Action/index.d.ts +0 -3
  95. package/es/components/productCard/components/Header/Actions/index.d.ts +0 -3
  96. package/es/components/productCard/components/Header/DeleteButton/index.d.ts +0 -3
  97. package/es/components/productCard/components/Header/index.d.ts +0 -3
  98. package/es/components/productCard/components/Sales/index.d.ts +0 -3
  99. package/es/components/productCard/components/Time/components/SelectHolder/index.d.ts +0 -3
  100. package/es/components/productCard/components/Time/components/SelectHolderModal/index.d.ts +0 -13
  101. package/es/components/productCard/components/Time/components/SelectResource/index.d.ts +0 -18
  102. package/es/components/productCard/components/Time/index.d.ts +0 -3
  103. package/es/components/productCard/index.d.ts +0 -7
  104. package/es/components/productCard/locales.d.ts +0 -84
  105. package/es/components/table/Actions/component/ExportImport/index.d.ts +0 -7
  106. package/es/components/table/Gallery/components/GalleryItem/index.d.ts +0 -14
  107. package/es/components/table/Gallery/index.d.ts +0 -5
  108. package/es/components/table/Table/AddFieldModal/index.d.ts +0 -4
  109. package/es/components/table/Table/index.d.ts +0 -4
  110. package/es/components/table/Table/utils.d.ts +0 -167
  111. package/es/components/table/hooks/useTableSetting.d.ts +0 -21
  112. package/es/components/table/hooks/useTransDataSource.d.ts +0 -12
  113. package/es/components/table/index.d.ts +0 -4
  114. package/es/components/table/types.d.ts +0 -270
  115. package/es/components/translation/index.d.ts +0 -15
  116. package/es/components/versionModal/index.d.ts +0 -24
  117. package/es/components/virtual-keyboard/Amount/index.d.ts +0 -5
  118. package/es/components/virtual-keyboard/Amount/themeConfig.d.ts +0 -32
  119. package/es/components/virtual-keyboard/Amount/types.d.ts +0 -44
  120. package/es/components/virtual-keyboard/BaseNumberKeyboard/Presets.d.ts +0 -15
  121. package/es/components/virtual-keyboard/BaseNumberKeyboard/index.d.ts +0 -25
  122. package/es/components/virtual-keyboard/Keyboard/index.d.ts +0 -21
  123. package/es/components/virtual-keyboard/Number/index.d.ts +0 -5
  124. package/es/components/virtual-keyboard/Number/themeConfig.d.ts +0 -32
  125. package/es/components/virtual-keyboard/Number/types.d.ts +0 -26
  126. package/es/components/virtual-keyboard/VirtualKeyInput/index.d.ts +0 -13
  127. package/es/components/virtual-keyboard/index.d.ts +0 -25
  128. package/es/components/virtualInput/BaseVirtualInput/index.d.ts +0 -40
  129. package/es/components/virtualInput/index.d.ts +0 -24
  130. package/es/components/walletCard/index.d.ts +0 -71
  131. package/es/index.d.ts +0 -145
  132. package/es/locales/en-US.d.ts +0 -342
  133. package/es/locales/zh-CN.d.ts +0 -337
  134. package/es/locales/zh-TW.d.ts +0 -337
  135. package/lib/components/appVersionControl/index.d.ts +0 -4
  136. package/lib/components/auto-resize-text/auto-text-size-standalone.d.ts +0 -20
  137. package/lib/components/auto-resize-text/index.d.ts +0 -6
  138. package/lib/components/cardPro/index.d.ts +0 -3
  139. package/lib/components/dataSourceComponents/dataSourceForm/utils.d.ts +0 -56
  140. package/lib/components/dataSourceComponents/dataSourceTable/BaseTable.d.ts +0 -8
  141. package/lib/components/dataSourceComponents/dataSourceTable/filter/index.d.ts +0 -27
  142. package/lib/components/dataSourceComponents/dataSourceTable/hooks/useDrawerState.d.ts +0 -39
  143. package/lib/components/dataSourceComponents/dataSourceTable/hooks/useTableProps.d.ts +0 -98
  144. package/lib/components/dataSourceComponents/dataSourceTable/hooks/useTableQuery.d.ts +0 -33
  145. package/lib/components/dataSourceComponents/dataSourceTable/type.d.ts +0 -85
  146. package/lib/components/dataSourceComponents/fields/Input.Mobile/WithMode.d.ts +0 -16
  147. package/lib/components/dataSourceComponents/fields/Input.Phone/WithMode.d.ts +0 -16
  148. package/lib/components/dataSourceComponents/fields/Input.Phone/serve.d.ts +0 -25
  149. package/lib/components/dataSourceComponents/fields/Upload/BaseUpload.d.ts +0 -5
  150. package/lib/components/dataSourceComponents/fields/Upload/CameraPopover.d.ts +0 -5
  151. package/lib/components/dataSourceComponents/fields/Upload/type.d.ts +0 -38
  152. package/lib/components/drag-sort-tree/TreeItem/index.d.ts +0 -18
  153. package/lib/components/drag-sort-tree/index.d.ts +0 -3
  154. package/lib/components/filter/types.d.ts +0 -45
  155. package/lib/components/hardwareErrorTip/demo.d.ts +0 -3
  156. package/lib/components/hardwareErrorTip/errorCard/index.d.ts +0 -28
  157. package/lib/components/hardwareErrorTip/errorTipStatistics/index.d.ts +0 -12
  158. package/lib/components/hardwareErrorTip/index.d.ts +0 -19
  159. package/lib/components/hardwareErrorTip/logCard/index.d.ts +0 -27
  160. package/lib/components/hardwareErrorTip/types.d.ts +0 -28
  161. package/lib/components/iconfont/index.d.ts +0 -8
  162. package/lib/components/keyboard/index.d.ts +0 -22
  163. package/lib/components/login-and-register/index.d.ts +0 -82
  164. package/lib/components/pisell-config-provider/context.d.ts +0 -22
  165. package/lib/components/pisell-config-provider/index.d.ts +0 -13
  166. package/lib/components/pisellAdjustPrice/index.d.ts +0 -4
  167. package/lib/components/pisellAdjustPrice/status.d.ts +0 -32
  168. package/lib/components/pisellAdjustPrice/type.d.ts +0 -22
  169. package/lib/components/pisellCamera/index.d.ts +0 -4
  170. package/lib/components/pisellCardList/index.d.ts +0 -107
  171. package/lib/components/pisellCheckboxGroup/index.d.ts +0 -40
  172. package/lib/components/pisellEmpty/index.d.ts +0 -19
  173. package/lib/components/pisellGoodPassCard/index.d.ts +0 -50
  174. package/lib/components/pisellText/components/Amount/index.d.ts +0 -20
  175. package/lib/components/pisellToast/index.d.ts +0 -17
  176. package/lib/components/pisellToast/squareToast/index.d.ts +0 -15
  177. package/lib/components/pisellToast/squareToast/methods.d.ts +0 -13
  178. package/lib/components/pisellToast/squareToast/renderImperatively.d.ts +0 -29
  179. package/lib/components/pisellToast/squareToast/toast.d.ts +0 -25
  180. package/lib/components/pisellWalletPassCard/index.d.ts +0 -140
  181. package/lib/components/pisellWalletPassCard/utils.d.ts +0 -44
  182. package/lib/components/productCard/cartSkuCard/components/AmountFooter/index.d.ts +0 -3
  183. package/lib/components/productCard/cartSkuCard/components/MultiDay/index.d.ts +0 -3
  184. package/lib/components/productCard/cartSkuCard/components/MultiDay/utils.d.ts +0 -14
  185. package/lib/components/productCard/cartSkuCard/components/Note/index.d.ts +0 -3
  186. package/lib/components/productCard/cartSkuCard/components/basicInfo/index.d.ts +0 -27
  187. package/lib/components/productCard/cartSkuCard/components/discountReason/index.d.ts +0 -2
  188. package/lib/components/productCard/cartSkuCard/components/holders/index.d.ts +0 -3
  189. package/lib/components/productCard/cartSkuCard/components/packages/index.d.ts +0 -10
  190. package/lib/components/productCard/cartSkuCard/components/packages/utils.d.ts +0 -20
  191. package/lib/components/productCard/cartSkuCard/components/resources/index.d.ts +0 -3
  192. package/lib/components/productCard/cartSkuCard/components/sales/index.d.ts +0 -12
  193. package/lib/components/productCard/cartSkuCard/components/specs/index.d.ts +0 -3
  194. package/lib/components/productCard/cartSkuCard/components/swipeAction/index.d.ts +0 -46
  195. package/lib/components/productCard/cartSkuCard/components/timeRange/index.d.ts +0 -6
  196. package/lib/components/productCard/cartSkuCard/index.d.ts +0 -10
  197. package/lib/components/productCard/cartSkuCard/locales.d.ts +0 -96
  198. package/lib/components/productCard/components/Action/index.d.ts +0 -3
  199. package/lib/components/productCard/components/Header/Actions/index.d.ts +0 -3
  200. package/lib/components/productCard/components/Header/DeleteButton/index.d.ts +0 -3
  201. package/lib/components/productCard/components/Header/index.d.ts +0 -3
  202. package/lib/components/productCard/components/Sales/index.d.ts +0 -3
  203. package/lib/components/productCard/components/Time/components/SelectHolder/index.d.ts +0 -3
  204. package/lib/components/productCard/components/Time/components/SelectHolderModal/index.d.ts +0 -13
  205. package/lib/components/productCard/components/Time/components/SelectResource/index.d.ts +0 -18
  206. package/lib/components/productCard/components/Time/index.d.ts +0 -3
  207. package/lib/components/productCard/index.d.ts +0 -7
  208. package/lib/components/productCard/locales.d.ts +0 -84
  209. package/lib/components/table/Actions/component/ExportImport/index.d.ts +0 -7
  210. package/lib/components/table/Gallery/components/GalleryItem/index.d.ts +0 -14
  211. package/lib/components/table/Gallery/index.d.ts +0 -5
  212. package/lib/components/table/Table/AddFieldModal/index.d.ts +0 -4
  213. package/lib/components/table/Table/index.d.ts +0 -4
  214. package/lib/components/table/Table/utils.d.ts +0 -167
  215. package/lib/components/table/hooks/useTableSetting.d.ts +0 -21
  216. package/lib/components/table/hooks/useTransDataSource.d.ts +0 -12
  217. package/lib/components/table/index.d.ts +0 -4
  218. package/lib/components/table/types.d.ts +0 -270
  219. package/lib/components/translation/index.d.ts +0 -15
  220. package/lib/components/versionModal/index.d.ts +0 -24
  221. package/lib/components/virtual-keyboard/Amount/index.d.ts +0 -5
  222. package/lib/components/virtual-keyboard/Amount/themeConfig.d.ts +0 -32
  223. package/lib/components/virtual-keyboard/Amount/types.d.ts +0 -44
  224. package/lib/components/virtual-keyboard/BaseNumberKeyboard/Presets.d.ts +0 -15
  225. package/lib/components/virtual-keyboard/BaseNumberKeyboard/index.d.ts +0 -25
  226. package/lib/components/virtual-keyboard/Keyboard/index.d.ts +0 -21
  227. package/lib/components/virtual-keyboard/Number/index.d.ts +0 -5
  228. package/lib/components/virtual-keyboard/Number/themeConfig.d.ts +0 -32
  229. package/lib/components/virtual-keyboard/Number/types.d.ts +0 -26
  230. package/lib/components/virtual-keyboard/VirtualKeyInput/index.d.ts +0 -13
  231. package/lib/components/virtual-keyboard/index.d.ts +0 -25
  232. package/lib/components/virtualInput/BaseVirtualInput/index.d.ts +0 -40
  233. package/lib/components/virtualInput/index.d.ts +0 -24
  234. package/lib/components/walletCard/index.d.ts +0 -71
  235. package/lib/index.d.ts +0 -145
  236. package/lib/locales/en-US.d.ts +0 -342
  237. package/lib/locales/zh-CN.d.ts +0 -337
  238. package/lib/locales/zh-TW.d.ts +0 -337
@@ -399,10 +399,12 @@ var PisellWalletPassCard = function PisellWalletPassCard(props) {
399
399
  }, showStatus && cardStatus && /*#__PURE__*/React.createElement("div", {
400
400
  className: "pisell-card-status-icon"
401
401
  }, /*#__PURE__*/React.createElement(PisellTag, {
402
- style: {
402
+ style: _objectSpread({
403
403
  borderRadius: '6px',
404
404
  padding: '2px 8px'
405
- },
405
+ }, cardStatus === 'lastPayment' && {
406
+ fontSize: '12px'
407
+ }),
406
408
  type: "pill_color",
407
409
  color: cardStatusMap[cardStatus]
408
410
  }, getText("pisell-wallet-pass-card-status-".concat(cardStatus)))), (actions === null || actions === void 0 ? void 0 : actions.detail) && (actions === null || actions === void 0 || (_actions$detail3 = actions.detail) === null || _actions$detail3 === void 0 ? void 0 : _actions$detail3.visible) && /*#__PURE__*/React.createElement("div", {
@@ -17,4 +17,4 @@ export declare const minusSign: (item: any, type?: string) => "" | "-";
17
17
  * @Author: WangHan
18
18
  * @Date: 2024-11-22 10:58
19
19
  */
20
- export declare const _formatAmount: (price?: number, amountSymbol?: string, digit?: number) => string | number;
20
+ export declare const _formatAmount: (price?: number, amountSymbol?: string, digit?: number) => any;
@@ -32,7 +32,6 @@
32
32
  }
33
33
 
34
34
  .pisell-base-virtual-input-value {
35
- color: #101828;
36
35
  font-weight: 600;
37
36
  white-space: nowrap;
38
37
  flex-shrink: 0;
@@ -4,10 +4,6 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
4
4
  function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
5
5
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
6
6
  function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
7
- function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
8
- function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
9
- function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
10
- function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
11
7
  function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
12
8
  function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
13
9
  function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
@@ -41,7 +37,7 @@ var DEFAULT_PROPS = {
41
37
  showWalletName: true,
42
38
  shopName: 'Store name',
43
39
  showShopName: true,
44
- cardNo: 'Wallet number',
40
+ cardNo: 'WL0000000001',
45
41
  cardStyle: 'normal',
46
42
  codeType: 'barCode',
47
43
  platform: 'pc',
@@ -51,21 +47,41 @@ var DEFAULT_PROPS = {
51
47
  walletName: 'Level',
52
48
  isLogin: true,
53
49
  items: [{
54
- key: 'rechargeable',
55
- label: 'rechargeable',
56
- value: 0
50
+ type: 'rechargeable',
51
+ display: 1,
52
+ custom_title: {
53
+ original: 'Balance',
54
+ 'zh-CN': '充值卡',
55
+ 'zh-HK': '充值卡',
56
+ en: 'Balance'
57
+ }
57
58
  }, {
58
- key: 'piont',
59
- label: 'piont',
60
- value: 10
59
+ type: 'point',
60
+ display: 1,
61
+ custom_title: {
62
+ original: 'Points',
63
+ 'zh-CN': '积分卡',
64
+ 'zh-HK': '積分卡',
65
+ en: 'Points'
66
+ }
61
67
  }, {
62
- key: 'voucher',
63
- label: 'Discount cardvoucher',
64
- value: 0
68
+ type: 'voucher',
69
+ display: 1,
70
+ custom_title: {
71
+ original: 'Voucher',
72
+ 'zh-CN': '代金券',
73
+ 'zh-HK': '代金券',
74
+ en: 'Voucher'
75
+ }
65
76
  }, {
66
- key: 'discount',
67
- label: 'discount',
68
- value: 0
77
+ type: 'discount',
78
+ display: 1,
79
+ custom_title: {
80
+ original: 'Discount',
81
+ 'zh-CN': '折扣卡',
82
+ 'zh-HK': '折扣卡',
83
+ en: 'Discount'
84
+ }
69
85
  }]
70
86
  };
71
87
 
@@ -198,49 +214,44 @@ var CardHeader = function CardHeader(_ref2) {
198
214
 
199
215
  // 子组件:卡片内容项
200
216
  var CardItem = function CardItem(_ref3) {
217
+ var _context$appHelper2;
201
218
  var item = _ref3.item,
202
219
  symbol = _ref3.symbol;
203
- var key = item.key,
204
- label = item.label,
220
+ var type = item.type,
221
+ custom_title = item.custom_title,
205
222
  value = item.value;
223
+ var context = useEngineContext();
224
+ var utils = context === null || context === void 0 || (_context$appHelper2 = context.appHelper) === null || _context$appHelper2 === void 0 ? void 0 : _context$appHelper2.utils;
225
+ var translationOriginal = (utils === null || utils === void 0 ? void 0 : utils.translationOriginal) || (utils === null || utils === void 0 ? void 0 : utils.translation);
206
226
  return /*#__PURE__*/React.createElement("div", {
207
227
  className: "pisell-wallet-card-item"
208
228
  }, /*#__PURE__*/React.createElement("div", {
209
229
  className: "pisell-wallet-card-item-label"
210
- }, getText("walletCard-".concat(label)) || ''), /*#__PURE__*/React.createElement("div", {
230
+ }, translationOriginal(custom_title || '') || ''), /*#__PURE__*/React.createElement("div", {
211
231
  className: "pisell-wallet-card-item-value"
212
- }, key === 'rechargeable' ? /*#__PURE__*/React.createElement(Amount, {
232
+ }, type === 'rechargeable' ? /*#__PURE__*/React.createElement(Amount, {
213
233
  className: "pisell-card-amount-item-value",
214
234
  platform: "h5",
215
235
  symbol: symbol,
216
236
  useThousandsSeparator: true,
217
237
  showCurrencySymbol: true,
218
238
  value: value
219
- }) : value));
239
+ }) : value || '0'));
220
240
  };
221
241
 
222
242
  // 子组件:卡片内容
223
243
  var CardContent = function CardContent(_ref4) {
224
244
  var items = _ref4.items,
225
245
  symbol = _ref4.symbol;
226
- // 定义期望的顺序
227
- var expectedOrder = ['piont', 'balance', 'discount', 'voucher'];
228
-
229
- // 对 items 进行排序
230
- var sortedItems = useMemo(function () {
231
- if (!(items !== null && items !== void 0 && items.length)) return [];
232
- return _toConsumableArray(items).sort(function (a, b) {
233
- var indexA = expectedOrder.indexOf(a.key);
234
- var indexB = expectedOrder.indexOf(b.key);
235
- return indexA - indexB;
236
- });
237
- }, [items]);
246
+ var filteredItems = (items || []).filter(function (item) {
247
+ return item.display !== 0;
248
+ });
238
249
  return /*#__PURE__*/React.createElement("div", {
239
250
  className: "pisell-wallet-card-list",
240
251
  style: {
241
- justifyContent: (sortedItems || []).length > 1 ? 'space-between' : 'flex-start'
252
+ justifyContent: filteredItems.length > 1 ? 'space-between' : 'flex-start'
242
253
  }
243
- }, (sortedItems || []).map(function (item, index) {
254
+ }, filteredItems.map(function (item, index) {
244
255
  return /*#__PURE__*/React.createElement(CardItem, {
245
256
  key: index,
246
257
  item: item,
package/es/index.js CHANGED
@@ -141,4 +141,5 @@ export { default as BaseTranslation } from "./components/dataSourceComponents/fi
141
141
  export { default as PisellGoodPassCard } from "./components/pisellGoodPassCard";
142
142
  export { default as HardwareErrorTip } from "./components/hardwareErrorTip";
143
143
  export { default as Keyboard } from "./components/keyboard";
144
- export { default as VirtualInput } from "./components/virtualInput";
144
+ export { default as VirtualInput } from "./components/virtualInput";
145
+ export { default as AutoResizeText } from "./components/auto-resize-text";
@@ -226,7 +226,7 @@ export default {
226
226
  'pisell-action-get-data': 'Please get data first',
227
227
  'pisell-action-delete-success': 'Deleted successfully',
228
228
  'pisell-action-delete-failed': 'Delete failed, please try again',
229
- 'walletCard-piont': 'Points',
229
+ 'walletCard-point': 'Points',
230
230
  'walletCard-rechargeable': 'Balance',
231
231
  'walletCard-voucher': 'Voucher',
232
232
  'walletCard-discount': 'Discount',
@@ -225,7 +225,7 @@ export default {
225
225
  'pisell-action-get-data': '请先获取数据',
226
226
  'pisell-action-delete-success': '删除成功',
227
227
  'pisell-action-delete-failed': '删除失败,请重试',
228
- 'walletCard-piont': '积分',
228
+ 'walletCard-point': '积分',
229
229
  'walletCard-rechargeable': '余额',
230
230
  'walletCard-voucher': '代金券',
231
231
  'walletCard-discount': '折扣卡',
@@ -225,7 +225,7 @@ export default {
225
225
  'pisell-action-get-data': '請先獲取數據',
226
226
  'pisell-action-delete-success': '刪除成功',
227
227
  'pisell-action-delete-failed': '刪除失敗,請重試',
228
- 'walletCard-piont': '積分',
228
+ 'walletCard-point': '積分',
229
229
  'walletCard-rechargeable': '餘額',
230
230
  'walletCard-voucher': '代金券',
231
231
  'walletCard-discount': '折扣卡',
@@ -1 +1 @@
1
- export declare const isMobile: () => boolean;
1
+ export declare const isMobile: () => any;
@@ -330,7 +330,11 @@ var PisellWalletPassCard = (props) => {
330
330
  return /* @__PURE__ */ import_react.default.createElement("div", { className: "actions-btn-wrapper", ref: actionsWrapperRef }, showStatus && cardStatus && /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-card-status-icon" }, /* @__PURE__ */ import_react.default.createElement(
331
331
  import_pisellTags.default,
332
332
  {
333
- style: { borderRadius: "6px", padding: "2px 8px" },
333
+ style: {
334
+ borderRadius: "6px",
335
+ padding: "2px 8px",
336
+ ...cardStatus === "lastPayment" && { fontSize: "12px" }
337
+ },
334
338
  type: "pill_color",
335
339
  color: cardStatusMap[cardStatus]
336
340
  },
@@ -17,4 +17,4 @@ export declare const minusSign: (item: any, type?: string) => "" | "-";
17
17
  * @Author: WangHan
18
18
  * @Date: 2024-11-22 10:58
19
19
  */
20
- export declare const _formatAmount: (price?: number, amountSymbol?: string, digit?: number) => string | number;
20
+ export declare const _formatAmount: (price?: number, amountSymbol?: string, digit?: number) => any;
@@ -32,7 +32,6 @@
32
32
  }
33
33
 
34
34
  .pisell-base-virtual-input-value {
35
- color: #101828;
36
35
  font-weight: 600;
37
36
  white-space: nowrap;
38
37
  flex-shrink: 0;
@@ -53,7 +53,7 @@ var DEFAULT_PROPS = {
53
53
  showWalletName: true,
54
54
  shopName: "Store name",
55
55
  showShopName: true,
56
- cardNo: "Wallet number",
56
+ cardNo: "WL0000000001",
57
57
  cardStyle: "normal",
58
58
  codeType: "barCode",
59
59
  platform: "pc",
@@ -64,24 +64,44 @@ var DEFAULT_PROPS = {
64
64
  isLogin: true,
65
65
  items: [
66
66
  {
67
- key: "rechargeable",
68
- label: "rechargeable",
69
- value: 0
67
+ type: "rechargeable",
68
+ display: 1,
69
+ custom_title: {
70
+ original: "Balance",
71
+ "zh-CN": "充值卡",
72
+ "zh-HK": "充值卡",
73
+ en: "Balance"
74
+ }
70
75
  },
71
76
  {
72
- key: "piont",
73
- label: "piont",
74
- value: 10
77
+ type: "point",
78
+ display: 1,
79
+ custom_title: {
80
+ original: "Points",
81
+ "zh-CN": "积分卡",
82
+ "zh-HK": "積分卡",
83
+ en: "Points"
84
+ }
75
85
  },
76
86
  {
77
- key: "voucher",
78
- label: "Discount cardvoucher",
79
- value: 0
87
+ type: "voucher",
88
+ display: 1,
89
+ custom_title: {
90
+ original: "Voucher",
91
+ "zh-CN": "代金券",
92
+ "zh-HK": "代金券",
93
+ en: "Voucher"
94
+ }
80
95
  },
81
96
  {
82
- key: "discount",
83
- label: "discount",
84
- value: 0
97
+ type: "discount",
98
+ display: 1,
99
+ custom_title: {
100
+ original: "Discount",
101
+ "zh-CN": "折扣卡",
102
+ "zh-HK": "折扣卡",
103
+ en: "Discount"
104
+ }
85
105
  }
86
106
  ]
87
107
  };
@@ -188,8 +208,12 @@ var CardHeader = ({
188
208
  )));
189
209
  };
190
210
  var CardItem = ({ item, symbol }) => {
191
- const { key, label, value } = item;
192
- return /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-wallet-card-item" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-wallet-card-item-label" }, (0, import_locales.getText)(`walletCard-${label}`) || ""), /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-wallet-card-item-value" }, key === "rechargeable" ? /* @__PURE__ */ import_react.default.createElement(
211
+ var _a;
212
+ const { type, custom_title, value } = item;
213
+ const context = (0, import_useEngineContext.default)();
214
+ const utils = (_a = context == null ? void 0 : context.appHelper) == null ? void 0 : _a.utils;
215
+ const translationOriginal = (utils == null ? void 0 : utils.translationOriginal) || (utils == null ? void 0 : utils.translation);
216
+ return /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-wallet-card-item" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-wallet-card-item-label" }, translationOriginal(custom_title || "") || ""), /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-wallet-card-item-value" }, type === "rechargeable" ? /* @__PURE__ */ import_react.default.createElement(
193
217
  import_Amount.default,
194
218
  {
195
219
  className: "pisell-card-amount-item-value",
@@ -199,27 +223,19 @@ var CardItem = ({ item, symbol }) => {
199
223
  showCurrencySymbol: true,
200
224
  value
201
225
  }
202
- ) : value));
226
+ ) : value || "0"));
203
227
  };
204
228
  var CardContent = ({ items, symbol }) => {
205
- const expectedOrder = ["piont", "balance", "discount", "voucher"];
206
- const sortedItems = (0, import_react.useMemo)(() => {
207
- if (!(items == null ? void 0 : items.length)) return [];
208
- return [...items].sort((a, b) => {
209
- const indexA = expectedOrder.indexOf(a.key);
210
- const indexB = expectedOrder.indexOf(b.key);
211
- return indexA - indexB;
212
- });
213
- }, [items]);
229
+ const filteredItems = (items || []).filter((item) => item.display !== 0);
214
230
  return /* @__PURE__ */ import_react.default.createElement(
215
231
  "div",
216
232
  {
217
233
  className: "pisell-wallet-card-list",
218
234
  style: {
219
- justifyContent: (sortedItems || []).length > 1 ? "space-between" : "flex-start"
235
+ justifyContent: filteredItems.length > 1 ? "space-between" : "flex-start"
220
236
  }
221
237
  },
222
- (sortedItems || []).map((item, index) => /* @__PURE__ */ import_react.default.createElement(CardItem, { key: index, item, symbol }))
238
+ filteredItems.map((item, index) => /* @__PURE__ */ import_react.default.createElement(CardItem, { key: index, item, symbol }))
223
239
  );
224
240
  };
225
241
  var CodeDisplay = ({ codeType, cardNo }) => {
package/lib/index.js CHANGED
@@ -35,6 +35,7 @@ __export(src_exports, {
35
35
  AppVersionControl: () => import_appVersionControl.default,
36
36
  AutoComplete: () => import_auto_complete.default,
37
37
  AutoCompleteNumber: () => import_auto_complete_number.default,
38
+ AutoResizeText: () => import_auto_resize_text.default,
38
39
  Avatar: () => import_antd.Avatar,
39
40
  Badge: () => import_badge.default,
40
41
  BaseTranslation: () => import_BaseTranslation.default,
@@ -350,6 +351,7 @@ var import_pisellGoodPassCard = __toESM(require("./components/pisellGoodPassCard
350
351
  var import_hardwareErrorTip = __toESM(require("./components/hardwareErrorTip"));
351
352
  var import_keyboard = __toESM(require("./components/keyboard"));
352
353
  var import_virtualInput = __toESM(require("./components/virtualInput"));
354
+ var import_auto_resize_text = __toESM(require("./components/auto-resize-text"));
353
355
  // Annotate the CommonJS export names for ESM import in node:
354
356
  0 && (module.exports = {
355
357
  Affix,
@@ -358,6 +360,7 @@ var import_virtualInput = __toESM(require("./components/virtualInput"));
358
360
  AppVersionControl,
359
361
  AutoComplete,
360
362
  AutoCompleteNumber,
363
+ AutoResizeText,
361
364
  Avatar,
362
365
  Badge,
363
366
  BaseTranslation,
@@ -216,7 +216,7 @@ var en_US_default = {
216
216
  "pisell-action-get-data": "Please get data first",
217
217
  "pisell-action-delete-success": "Deleted successfully",
218
218
  "pisell-action-delete-failed": "Delete failed, please try again",
219
- "walletCard-piont": "Points",
219
+ "walletCard-point": "Points",
220
220
  "walletCard-rechargeable": "Balance",
221
221
  "walletCard-voucher": "Voucher",
222
222
  "walletCard-discount": "Discount",
@@ -215,7 +215,7 @@ var zh_CN_default = {
215
215
  "pisell-action-get-data": "请先获取数据",
216
216
  "pisell-action-delete-success": "删除成功",
217
217
  "pisell-action-delete-failed": "删除失败,请重试",
218
- "walletCard-piont": "积分",
218
+ "walletCard-point": "积分",
219
219
  "walletCard-rechargeable": "余额",
220
220
  "walletCard-voucher": "代金券",
221
221
  "walletCard-discount": "折扣卡",
@@ -215,7 +215,7 @@ var zh_TW_default = {
215
215
  "pisell-action-get-data": "請先獲取數據",
216
216
  "pisell-action-delete-success": "刪除成功",
217
217
  "pisell-action-delete-failed": "刪除失敗,請重試",
218
- "walletCard-piont": "積分",
218
+ "walletCard-point": "積分",
219
219
  "walletCard-rechargeable": "餘額",
220
220
  "walletCard-voucher": "代金券",
221
221
  "walletCard-discount": "折扣卡",
@@ -1 +1 @@
1
- export declare const isMobile: () => boolean;
1
+ export declare const isMobile: () => any;