@pisell/materials 6.3.17 → 6.3.18
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.
- package/build/lowcode/assets-daily.json +11 -11
- package/build/lowcode/assets-dev.json +2 -2
- package/build/lowcode/assets-prod.json +11 -11
- package/build/lowcode/index.js +1 -1
- package/build/lowcode/meta.js +5 -5
- package/build/lowcode/preview.js +144 -144
- package/build/lowcode/render/default/view.css +1 -1
- package/build/lowcode/render/default/view.js +23 -23
- package/build/lowcode/view.css +1 -1
- package/build/lowcode/view.js +23 -23
- package/es/components/TimeResourceSelector/index.d.ts +21 -0
- package/es/components/auto-resize-text/auto-text-size-standalone.d.ts +20 -0
- package/es/components/auto-resize-text/auto-text-size-standalone.js +258 -0
- package/es/components/auto-resize-text/index.d.ts +6 -0
- package/es/components/auto-resize-text/index.js +40 -0
- package/es/components/cardPro/index.js +10 -3
- package/es/components/dataSourceComponents/fields/Upload/utils.d.ts +1 -1
- package/es/components/dataSourceComponents/fields/index.d.ts +16 -16
- package/es/components/iconfont/index.js +1 -1
- package/es/components/keyboard/index.d.ts +22 -0
- package/es/components/keyboard/index.js +159 -0
- package/es/components/keyboard/index.less +44 -0
- package/es/components/page/index.js +5 -2
- package/es/components/pisell-config-provider/context.d.ts +2 -0
- package/es/components/pisell-config-provider/index.d.ts +1 -0
- package/es/components/pisellAdjustPrice/index.js +5 -1
- package/es/components/pisellAdjustPrice/type.d.ts +2 -0
- package/es/components/pisellCardList/index.d.ts +32 -2
- package/es/components/pisellCardList/index.js +39 -2
- package/es/components/pisellCardList/index.less +9 -1
- package/es/components/pisellCheckboxGroup/index.d.ts +3 -0
- package/es/components/pisellCheckboxGroup/index.js +9 -4
- package/es/components/pisellCheckboxGroup/index.less +28 -1
- package/es/components/pisellCustomCheckboxGroup/index.d.ts +16 -0
- package/es/components/pisellGoodPassCard/index.d.ts +1 -0
- package/es/components/pisellGoodPassCard/index.js +17 -5
- package/es/components/pisellText/components/Amount/index.js +2 -1
- package/es/components/pisellToast/index.d.ts +1 -0
- package/es/components/pisellToast/index.js +4 -0
- package/es/components/pisellToast/squareToast/index.d.ts +15 -0
- package/es/components/pisellToast/squareToast/index.js +28 -0
- package/es/components/pisellToast/squareToast/index.less +60 -0
- package/es/components/pisellToast/squareToast/methods.d.ts +13 -0
- package/es/components/pisellToast/squareToast/methods.js +136 -0
- package/es/components/pisellToast/squareToast/renderImperatively.d.ts +28 -0
- package/es/components/pisellToast/squareToast/renderImperatively.js +190 -0
- package/es/components/pisellToast/squareToast/toast.d.ts +25 -0
- package/es/components/pisellToast/squareToast/toast.js +60 -0
- package/es/components/pisellWalletPassCard/index.d.ts +53 -1
- package/es/components/pisellWalletPassCard/index.js +333 -73
- package/es/components/pisellWalletPassCard/index.less +47 -9
- package/es/components/productCard/cartSkuCard/components/AmountFooter/index.d.ts +3 -0
- package/es/components/productCard/cartSkuCard/components/AmountFooter/index.js +80 -0
- package/es/components/productCard/cartSkuCard/components/AmountFooter/index.less +75 -0
- package/es/components/productCard/cartSkuCard/components/MultiDay/index.d.ts +3 -0
- package/es/components/productCard/cartSkuCard/components/MultiDay/index.js +82 -0
- package/es/components/productCard/cartSkuCard/components/MultiDay/index.less +31 -0
- package/es/components/productCard/cartSkuCard/components/MultiDay/utils.d.ts +14 -0
- package/es/components/productCard/cartSkuCard/components/MultiDay/utils.js +56 -0
- package/es/components/productCard/cartSkuCard/components/Note/index.d.ts +3 -0
- package/es/components/productCard/cartSkuCard/components/Note/index.js +29 -0
- package/es/components/productCard/cartSkuCard/components/Note/index.less +27 -0
- package/es/components/productCard/cartSkuCard/components/basicInfo/index.d.ts +28 -0
- package/es/components/productCard/cartSkuCard/components/basicInfo/index.js +94 -0
- package/es/components/productCard/cartSkuCard/components/basicInfo/index.less +117 -0
- package/es/components/productCard/cartSkuCard/components/discountReason/index.d.ts +2 -0
- package/es/components/productCard/cartSkuCard/components/discountReason/index.js +51 -0
- package/es/components/productCard/cartSkuCard/components/holders/index.d.ts +3 -0
- package/es/components/productCard/cartSkuCard/components/holders/index.js +49 -0
- package/es/components/productCard/cartSkuCard/components/holders/index.less +47 -0
- package/es/components/productCard/cartSkuCard/components/packages/index.d.ts +10 -0
- package/es/components/productCard/cartSkuCard/components/packages/index.js +52 -0
- package/es/components/productCard/cartSkuCard/components/packages/index.less +22 -0
- package/es/components/productCard/cartSkuCard/components/packages/utils.d.ts +20 -0
- package/es/components/productCard/cartSkuCard/components/packages/utils.js +40 -0
- package/es/components/productCard/cartSkuCard/components/resources/index.d.ts +3 -0
- package/es/components/productCard/cartSkuCard/components/resources/index.js +39 -0
- package/es/components/productCard/cartSkuCard/components/resources/index.less +19 -0
- package/es/components/productCard/cartSkuCard/components/sales/index.d.ts +12 -0
- package/es/components/productCard/cartSkuCard/components/sales/index.js +57 -0
- package/es/components/productCard/cartSkuCard/components/sales/index.less +22 -0
- package/es/components/productCard/cartSkuCard/components/specs/index.d.ts +3 -0
- package/es/components/productCard/cartSkuCard/components/specs/index.js +44 -0
- package/es/components/productCard/cartSkuCard/components/specs/index.less +34 -0
- package/es/components/productCard/cartSkuCard/components/swipeAction/index.d.ts +46 -0
- package/es/components/productCard/cartSkuCard/components/swipeAction/index.js +360 -0
- package/es/components/productCard/cartSkuCard/components/swipeAction/index.less +74 -0
- package/es/components/productCard/cartSkuCard/components/timeRange/index.d.ts +6 -0
- package/es/components/productCard/cartSkuCard/components/timeRange/index.js +54 -0
- package/es/components/productCard/cartSkuCard/components/timeRange/index.less +38 -0
- package/es/components/productCard/cartSkuCard/index.d.ts +10 -0
- package/es/components/productCard/cartSkuCard/index.js +194 -0
- package/es/components/productCard/cartSkuCard/index.less +33 -0
- package/es/components/productCard/cartSkuCard/locales.d.ts +99 -0
- package/es/components/productCard/cartSkuCard/locales.js +33 -0
- package/es/components/productCard/components/Action/index.js +14 -1
- package/es/components/productCard/components/Action/index.less +3 -0
- package/es/components/productCard/components/Header/index.js +23 -8
- package/es/components/productCard/components/Header/index.less +16 -1
- package/es/components/productCard/components/Sales/index.js +2 -2
- package/es/components/productCard/components/Time/components/SelectHolderModal/index.js +3 -1
- package/es/components/productCard/components/Time/components/SelectHolderModal/index.less +3 -0
- package/es/components/productCard/index.d.ts +3 -1
- package/es/components/productCard/index.js +7 -2
- package/es/components/productCard/index.less +6 -0
- package/es/components/productCard/locales.js +3 -0
- package/es/components/productCard/status.js +1 -0
- package/es/components/productCard/types.d.ts +1 -0
- package/es/components/productCard/utils.js +8 -1
- package/es/components/select-time/index.d.ts +14 -0
- package/es/components/table/Table/AddFieldModal/index.d.ts +1 -0
- package/es/components/table/Table/AddFieldModal/index.js +13 -13
- package/es/components/table/Table/AddFieldModal/index.less +11 -11
- package/es/components/table/Table/utils.d.ts +1 -1
- package/es/components/virtual-keyboard/BaseNumberKeyboard/Presets.d.ts +5 -1
- package/es/components/virtual-keyboard/BaseNumberKeyboard/Presets.js +21 -7
- package/es/components/virtual-keyboard/BaseNumberKeyboard/Presets.less +9 -5
- package/es/components/virtual-keyboard/BaseNumberKeyboard/index.d.ts +4 -0
- package/es/components/virtual-keyboard/BaseNumberKeyboard/index.js +44 -25
- package/es/components/virtual-keyboard/Number/index.js +4 -1
- package/es/components/virtual-keyboard/Number/types.d.ts +1 -0
- package/es/components/virtual-keyboard/index.d.ts +11 -0
- package/es/components/virtual-keyboard/index.js +88 -3
- package/es/components/virtual-keyboard/index.less +33 -1
- package/es/components/virtualInput/BaseVirtualInput/index.d.ts +40 -0
- package/es/components/virtualInput/BaseVirtualInput/index.js +163 -0
- package/es/components/virtualInput/BaseVirtualInput/index.less +77 -0
- package/es/components/virtualInput/index.d.ts +24 -0
- package/es/components/virtualInput/index.js +60 -0
- package/es/components/virtualInput/index.less +42 -0
- package/es/index.d.ts +5 -1
- package/es/index.js +5 -2
- package/es/locales/en-US.d.ts +19 -2
- package/es/locales/en-US.js +29 -6
- package/es/locales/zh-CN.d.ts +19 -2
- package/es/locales/zh-CN.js +29 -6
- package/es/locales/zh-TW.d.ts +19 -2
- package/es/locales/zh-TW.js +28 -6
- package/lib/components/TimeResourceSelector/index.d.ts +21 -0
- package/lib/components/auto-resize-text/auto-text-size-standalone.d.ts +20 -0
- package/lib/components/auto-resize-text/auto-text-size-standalone.js +273 -0
- package/lib/components/auto-resize-text/index.d.ts +6 -0
- package/lib/components/auto-resize-text/index.js +71 -0
- package/lib/components/cardPro/index.js +3 -2
- package/lib/components/dataSourceComponents/fields/Upload/utils.d.ts +1 -1
- package/lib/components/dataSourceComponents/fields/index.d.ts +16 -16
- package/lib/components/iconfont/index.js +1 -1
- package/lib/components/keyboard/index.d.ts +22 -0
- package/lib/components/keyboard/index.js +223 -0
- package/lib/components/keyboard/index.less +44 -0
- package/lib/components/page/index.js +3 -2
- package/lib/components/pisell-config-provider/context.d.ts +2 -0
- package/lib/components/pisell-config-provider/index.d.ts +1 -0
- package/lib/components/pisellAdjustPrice/index.js +4 -0
- package/lib/components/pisellAdjustPrice/type.d.ts +2 -0
- package/lib/components/pisellCardList/index.d.ts +32 -2
- package/lib/components/pisellCardList/index.js +39 -2
- package/lib/components/pisellCardList/index.less +9 -1
- package/lib/components/pisellCheckboxGroup/index.d.ts +3 -0
- package/lib/components/pisellCheckboxGroup/index.js +6 -1
- package/lib/components/pisellCheckboxGroup/index.less +28 -1
- package/lib/components/pisellCustomCheckboxGroup/index.d.ts +16 -0
- package/lib/components/pisellGoodPassCard/index.d.ts +1 -0
- package/lib/components/pisellGoodPassCard/index.js +31 -4
- package/lib/components/pisellText/components/Amount/index.js +2 -1
- package/lib/components/pisellToast/index.d.ts +1 -0
- package/lib/components/pisellToast/index.js +10 -1
- package/lib/components/pisellToast/squareToast/index.d.ts +15 -0
- package/lib/components/pisellToast/squareToast/index.js +58 -0
- package/lib/components/pisellToast/squareToast/index.less +60 -0
- package/lib/components/pisellToast/squareToast/methods.d.ts +13 -0
- package/lib/components/pisellToast/squareToast/methods.js +150 -0
- package/lib/components/pisellToast/squareToast/renderImperatively.d.ts +28 -0
- package/lib/components/pisellToast/squareToast/renderImperatively.js +162 -0
- package/lib/components/pisellToast/squareToast/toast.d.ts +25 -0
- package/lib/components/pisellToast/squareToast/toast.js +88 -0
- package/lib/components/pisellWalletPassCard/index.d.ts +53 -1
- package/lib/components/pisellWalletPassCard/index.js +257 -59
- package/lib/components/pisellWalletPassCard/index.less +47 -9
- package/lib/components/productCard/cartSkuCard/components/AmountFooter/index.d.ts +3 -0
- package/lib/components/productCard/cartSkuCard/components/AmountFooter/index.js +80 -0
- package/lib/components/productCard/cartSkuCard/components/AmountFooter/index.less +75 -0
- package/lib/components/productCard/cartSkuCard/components/MultiDay/index.d.ts +3 -0
- package/lib/components/productCard/cartSkuCard/components/MultiDay/index.js +71 -0
- package/lib/components/productCard/cartSkuCard/components/MultiDay/index.less +31 -0
- package/lib/components/productCard/cartSkuCard/components/MultiDay/utils.d.ts +14 -0
- package/lib/components/productCard/cartSkuCard/components/MultiDay/utils.js +77 -0
- package/lib/components/productCard/cartSkuCard/components/Note/index.d.ts +3 -0
- package/lib/components/productCard/cartSkuCard/components/Note/index.js +56 -0
- package/lib/components/productCard/cartSkuCard/components/Note/index.less +27 -0
- package/lib/components/productCard/cartSkuCard/components/basicInfo/index.d.ts +28 -0
- package/lib/components/productCard/cartSkuCard/components/basicInfo/index.js +83 -0
- package/lib/components/productCard/cartSkuCard/components/basicInfo/index.less +117 -0
- package/lib/components/productCard/cartSkuCard/components/discountReason/index.d.ts +2 -0
- package/lib/components/productCard/cartSkuCard/components/discountReason/index.js +70 -0
- package/lib/components/productCard/cartSkuCard/components/holders/index.d.ts +3 -0
- package/lib/components/productCard/cartSkuCard/components/holders/index.js +64 -0
- package/lib/components/productCard/cartSkuCard/components/holders/index.less +47 -0
- package/lib/components/productCard/cartSkuCard/components/packages/index.d.ts +10 -0
- package/lib/components/productCard/cartSkuCard/components/packages/index.js +73 -0
- package/lib/components/productCard/cartSkuCard/components/packages/index.less +22 -0
- package/lib/components/productCard/cartSkuCard/components/packages/utils.d.ts +20 -0
- package/lib/components/productCard/cartSkuCard/components/packages/utils.js +44 -0
- package/lib/components/productCard/cartSkuCard/components/resources/index.d.ts +3 -0
- package/lib/components/productCard/cartSkuCard/components/resources/index.js +71 -0
- package/lib/components/productCard/cartSkuCard/components/resources/index.less +19 -0
- package/lib/components/productCard/cartSkuCard/components/sales/index.d.ts +12 -0
- package/lib/components/productCard/cartSkuCard/components/sales/index.js +77 -0
- package/lib/components/productCard/cartSkuCard/components/sales/index.less +22 -0
- package/lib/components/productCard/cartSkuCard/components/specs/index.d.ts +3 -0
- package/lib/components/productCard/cartSkuCard/components/specs/index.js +66 -0
- package/lib/components/productCard/cartSkuCard/components/specs/index.less +34 -0
- package/lib/components/productCard/cartSkuCard/components/swipeAction/index.d.ts +46 -0
- package/lib/components/productCard/cartSkuCard/components/swipeAction/index.js +373 -0
- package/lib/components/productCard/cartSkuCard/components/swipeAction/index.less +74 -0
- package/lib/components/productCard/cartSkuCard/components/timeRange/index.d.ts +6 -0
- package/lib/components/productCard/cartSkuCard/components/timeRange/index.js +68 -0
- package/lib/components/productCard/cartSkuCard/components/timeRange/index.less +38 -0
- package/lib/components/productCard/cartSkuCard/index.d.ts +10 -0
- package/lib/components/productCard/cartSkuCard/index.js +229 -0
- package/lib/components/productCard/cartSkuCard/index.less +33 -0
- package/lib/components/productCard/cartSkuCard/locales.d.ts +99 -0
- package/lib/components/productCard/cartSkuCard/locales.js +64 -0
- package/lib/components/productCard/components/Action/index.js +9 -0
- package/lib/components/productCard/components/Action/index.less +3 -0
- package/lib/components/productCard/components/Header/index.js +21 -11
- package/lib/components/productCard/components/Header/index.less +16 -1
- package/lib/components/productCard/components/Sales/index.js +2 -2
- package/lib/components/productCard/components/Time/components/SelectHolderModal/index.js +1 -1
- package/lib/components/productCard/components/Time/components/SelectHolderModal/index.less +3 -0
- package/lib/components/productCard/index.d.ts +3 -1
- package/lib/components/productCard/index.js +7 -2
- package/lib/components/productCard/index.less +6 -0
- package/lib/components/productCard/locales.js +12 -3
- package/lib/components/productCard/status.js +1 -0
- package/lib/components/productCard/types.d.ts +1 -0
- package/lib/components/productCard/utils.js +8 -1
- package/lib/components/select-time/index.d.ts +14 -0
- package/lib/components/table/Table/AddFieldModal/index.d.ts +1 -0
- package/lib/components/table/Table/AddFieldModal/index.js +9 -9
- package/lib/components/table/Table/AddFieldModal/index.less +11 -11
- package/lib/components/table/Table/utils.d.ts +1 -1
- package/lib/components/virtual-keyboard/BaseNumberKeyboard/Presets.d.ts +5 -1
- package/lib/components/virtual-keyboard/BaseNumberKeyboard/Presets.js +19 -2
- package/lib/components/virtual-keyboard/BaseNumberKeyboard/Presets.less +9 -5
- package/lib/components/virtual-keyboard/BaseNumberKeyboard/index.d.ts +4 -0
- package/lib/components/virtual-keyboard/BaseNumberKeyboard/index.js +45 -27
- package/lib/components/virtual-keyboard/Number/index.js +3 -0
- package/lib/components/virtual-keyboard/Number/types.d.ts +1 -0
- package/lib/components/virtual-keyboard/index.d.ts +11 -0
- package/lib/components/virtual-keyboard/index.js +60 -2
- package/lib/components/virtual-keyboard/index.less +33 -1
- package/lib/components/virtualInput/BaseVirtualInput/index.d.ts +40 -0
- package/lib/components/virtualInput/BaseVirtualInput/index.js +179 -0
- package/lib/components/virtualInput/BaseVirtualInput/index.less +77 -0
- package/lib/components/virtualInput/index.d.ts +24 -0
- package/lib/components/virtualInput/index.js +102 -0
- package/lib/components/virtualInput/index.less +42 -0
- package/lib/index.d.ts +5 -1
- package/lib/index.js +11 -0
- package/lib/locales/en-US.d.ts +19 -2
- package/lib/locales/en-US.js +24 -5
- package/lib/locales/zh-CN.d.ts +19 -2
- package/lib/locales/zh-CN.js +24 -5
- package/lib/locales/zh-TW.d.ts +19 -2
- package/lib/locales/zh-TW.js +23 -5
- package/package.json +4 -4
- package/es/components/dataSourceComponents/provider/variables/VariablesContext.d.ts +0 -12
- package/lib/components/dataSourceComponents/provider/variables/VariablesContext.d.ts +0 -12
|
@@ -0,0 +1,223 @@
|
|
|
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/components/keyboard/index.tsx
|
|
30
|
+
var keyboard_exports = {};
|
|
31
|
+
__export(keyboard_exports, {
|
|
32
|
+
default: () => keyboard_default
|
|
33
|
+
});
|
|
34
|
+
module.exports = __toCommonJS(keyboard_exports);
|
|
35
|
+
var import_react = __toESM(require("react"));
|
|
36
|
+
var import_antd = require("antd");
|
|
37
|
+
var import_index = require("./index.less");
|
|
38
|
+
var import_classnames = __toESM(require("classnames"));
|
|
39
|
+
var import_ahooks = require("ahooks");
|
|
40
|
+
var list = ["1", "2", "3", "4", "5", "6", "7", "8", "9", "0", "+", "ok"];
|
|
41
|
+
var defaultArr = [
|
|
42
|
+
{
|
|
43
|
+
value: 1,
|
|
44
|
+
label: "1",
|
|
45
|
+
disabled: false,
|
|
46
|
+
type: "text"
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
value: 2,
|
|
50
|
+
label: "2",
|
|
51
|
+
disabled: false,
|
|
52
|
+
type: "text"
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
value: 3,
|
|
56
|
+
label: "3",
|
|
57
|
+
disabled: false,
|
|
58
|
+
type: "text"
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
value: 4,
|
|
62
|
+
label: "4",
|
|
63
|
+
disabled: false,
|
|
64
|
+
type: "text"
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
value: 5,
|
|
68
|
+
label: "5",
|
|
69
|
+
disabled: false,
|
|
70
|
+
type: "text"
|
|
71
|
+
},
|
|
72
|
+
{
|
|
73
|
+
value: 6,
|
|
74
|
+
label: "6",
|
|
75
|
+
disabled: false,
|
|
76
|
+
type: "text"
|
|
77
|
+
},
|
|
78
|
+
{
|
|
79
|
+
value: 7,
|
|
80
|
+
label: "7",
|
|
81
|
+
disabled: false,
|
|
82
|
+
type: "text"
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
value: 8,
|
|
86
|
+
label: "8",
|
|
87
|
+
disabled: false,
|
|
88
|
+
type: "text"
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
value: 9,
|
|
92
|
+
label: "9",
|
|
93
|
+
disabled: false,
|
|
94
|
+
type: "text"
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
value: "0",
|
|
98
|
+
label: "0",
|
|
99
|
+
disabled: false,
|
|
100
|
+
type: "text"
|
|
101
|
+
},
|
|
102
|
+
{
|
|
103
|
+
value: "00",
|
|
104
|
+
label: "00",
|
|
105
|
+
disabled: false,
|
|
106
|
+
type: "text"
|
|
107
|
+
},
|
|
108
|
+
{
|
|
109
|
+
value: ".",
|
|
110
|
+
label: ".",
|
|
111
|
+
disabled: false,
|
|
112
|
+
type: "text"
|
|
113
|
+
}
|
|
114
|
+
];
|
|
115
|
+
var Keyboard = (props) => {
|
|
116
|
+
const {
|
|
117
|
+
items = defaultArr,
|
|
118
|
+
className,
|
|
119
|
+
style,
|
|
120
|
+
onChange,
|
|
121
|
+
rightItems,
|
|
122
|
+
keydown = true
|
|
123
|
+
} = props;
|
|
124
|
+
const contentRef = (0, import_react.useRef)(null);
|
|
125
|
+
const size = (0, import_ahooks.useSize)(contentRef);
|
|
126
|
+
(0, import_ahooks.useEventListener)("keydown", (ev) => {
|
|
127
|
+
console.log("ev", ev);
|
|
128
|
+
if (!keydown) {
|
|
129
|
+
return;
|
|
130
|
+
}
|
|
131
|
+
let key = ev.key;
|
|
132
|
+
if (key === "Enter") {
|
|
133
|
+
key = "ok";
|
|
134
|
+
}
|
|
135
|
+
if (key === "keydown") {
|
|
136
|
+
key = "+";
|
|
137
|
+
}
|
|
138
|
+
if (list.includes(key)) {
|
|
139
|
+
onChange == null ? void 0 : onChange(key);
|
|
140
|
+
}
|
|
141
|
+
});
|
|
142
|
+
const getHeight = (0, import_ahooks.useMemoizedFn)((itemSize = 1) => {
|
|
143
|
+
return ((size == null ? void 0 : size.width) || 0) / 4 * itemSize + (itemSize - 1) * 7;
|
|
144
|
+
});
|
|
145
|
+
return /* @__PURE__ */ import_react.default.createElement(
|
|
146
|
+
"div",
|
|
147
|
+
{
|
|
148
|
+
id: props.id || "",
|
|
149
|
+
className: (0, import_classnames.default)("pisell-virtual-keyboard-wrap", className),
|
|
150
|
+
style
|
|
151
|
+
},
|
|
152
|
+
/* @__PURE__ */ import_react.default.createElement(
|
|
153
|
+
"div",
|
|
154
|
+
{
|
|
155
|
+
className: (0, import_classnames.default)("pisell-virtual-keyboard-content"),
|
|
156
|
+
ref: contentRef
|
|
157
|
+
},
|
|
158
|
+
items.map((item) => {
|
|
159
|
+
var _a;
|
|
160
|
+
return /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-virtual-keyboard-item", style: item.style }, /* @__PURE__ */ import_react.default.createElement(
|
|
161
|
+
import_antd.Button,
|
|
162
|
+
{
|
|
163
|
+
id: `pisell-virtual-keyboard-${item.value}`,
|
|
164
|
+
key: item.value,
|
|
165
|
+
type: item.type,
|
|
166
|
+
className: "pisell-virtual-keyboard-item-button",
|
|
167
|
+
style: {
|
|
168
|
+
color: item.type === "primary" ? "#fff" : ((_a = item.style) == null ? void 0 : _a.color) || void 0
|
|
169
|
+
},
|
|
170
|
+
disabled: item.disabled,
|
|
171
|
+
onClick: (e) => {
|
|
172
|
+
onChange == null ? void 0 : onChange(item.value);
|
|
173
|
+
}
|
|
174
|
+
},
|
|
175
|
+
item.label
|
|
176
|
+
));
|
|
177
|
+
})
|
|
178
|
+
),
|
|
179
|
+
rightItems && /* @__PURE__ */ import_react.default.createElement(
|
|
180
|
+
"div",
|
|
181
|
+
{
|
|
182
|
+
className: (0, import_classnames.default)(
|
|
183
|
+
"pisell-virtual-keyboard-content",
|
|
184
|
+
"pisell-virtual-keyboard-right"
|
|
185
|
+
),
|
|
186
|
+
style: { flex: `0 0 calc((100% - 21px) / 4 * 1)` }
|
|
187
|
+
},
|
|
188
|
+
rightItems == null ? void 0 : rightItems.map((item) => {
|
|
189
|
+
var _a, _b;
|
|
190
|
+
return /* @__PURE__ */ import_react.default.createElement(
|
|
191
|
+
"div",
|
|
192
|
+
{
|
|
193
|
+
className: "pisell-virtual-keyboard-item",
|
|
194
|
+
style: {
|
|
195
|
+
...item.style || {},
|
|
196
|
+
height: getHeight(item.size)
|
|
197
|
+
}
|
|
198
|
+
},
|
|
199
|
+
/* @__PURE__ */ import_react.default.createElement(
|
|
200
|
+
import_antd.Button,
|
|
201
|
+
{
|
|
202
|
+
id: `pisell-virtual-keyboard-${item.value}`,
|
|
203
|
+
key: item.value,
|
|
204
|
+
type: item.type,
|
|
205
|
+
className: "pisell-virtual-keyboard-item-button",
|
|
206
|
+
style: {
|
|
207
|
+
fontSize: ((_a = item.style) == null ? void 0 : _a.fontSize) || 25,
|
|
208
|
+
color: item.type === "primary" ? "#fff" : ((_b = item.style) == null ? void 0 : _b.color) || void 0,
|
|
209
|
+
...item.type === "primary" ? item.style || {} : {}
|
|
210
|
+
},
|
|
211
|
+
disabled: item.disabled,
|
|
212
|
+
onClick: (e) => {
|
|
213
|
+
onChange == null ? void 0 : onChange(item.value);
|
|
214
|
+
}
|
|
215
|
+
},
|
|
216
|
+
item.label
|
|
217
|
+
)
|
|
218
|
+
);
|
|
219
|
+
})
|
|
220
|
+
)
|
|
221
|
+
);
|
|
222
|
+
};
|
|
223
|
+
var keyboard_default = import_react.default.memo(Keyboard);
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
.pisell-virtual-keyboard-wrap {
|
|
2
|
+
display: flex;
|
|
3
|
+
gap: 7px;
|
|
4
|
+
.pisell-virtual-keyboard-content {
|
|
5
|
+
width: 100%;
|
|
6
|
+
display: flex;
|
|
7
|
+
flex-wrap: wrap;
|
|
8
|
+
align-items: center;
|
|
9
|
+
justify-content: flex-end;
|
|
10
|
+
gap: 7px;
|
|
11
|
+
|
|
12
|
+
.pisell-virtual-keyboard-item {
|
|
13
|
+
border-radius: 5px;
|
|
14
|
+
background: var(--Base-White, #fff);
|
|
15
|
+
box-shadow: 0px 1px 2px rgba(16, 24, 40, 0.06);;
|
|
16
|
+
overflow: hidden;
|
|
17
|
+
width: calc((100% - 14px) / 3 * 1);
|
|
18
|
+
padding-top: 25%;
|
|
19
|
+
position: relative;
|
|
20
|
+
|
|
21
|
+
.pisell-virtual-keyboard-item-button {
|
|
22
|
+
position: absolute;
|
|
23
|
+
left: 0;
|
|
24
|
+
top: 0;
|
|
25
|
+
width: 100%;
|
|
26
|
+
height: 100%;
|
|
27
|
+
border-radius: 5px;
|
|
28
|
+
color: var(--Base-Black, #000);
|
|
29
|
+
font-size: 25px;
|
|
30
|
+
font-style: normal;
|
|
31
|
+
font-weight: 400;
|
|
32
|
+
box-shadow: none;
|
|
33
|
+
padding: 0 !important;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
.pisell-virtual-keyboard-right {
|
|
38
|
+
flex-direction: column;
|
|
39
|
+
justify-content: start;
|
|
40
|
+
.pisell-virtual-keyboard-item{
|
|
41
|
+
width: 100%;
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
}
|
|
@@ -70,7 +70,7 @@ var localeDateMap = {
|
|
|
70
70
|
};
|
|
71
71
|
var Page = (props) => {
|
|
72
72
|
var _a, _b, _c, _d, _e, _f;
|
|
73
|
-
const { children, style, className, locale: propsLocale, ...others } = props;
|
|
73
|
+
const { children, style, className, locale: propsLocale, isRenderPisellConfigProvider = true, ...others } = props;
|
|
74
74
|
const context = (0, import_useEngineContext.default)();
|
|
75
75
|
const { platform, themeColor } = ((_a = context.appHelper) == null ? void 0 : _a.constants) || {};
|
|
76
76
|
const locale = propsLocale || ((_c = (_b = context == null ? void 0 : context.engine) == null ? void 0 : _b.props) == null ? void 0 : _c.locale) || "en";
|
|
@@ -215,6 +215,7 @@ var Page = (props) => {
|
|
|
215
215
|
}
|
|
216
216
|
});
|
|
217
217
|
}, [platform, themeColor]);
|
|
218
|
+
const PisellConfigProvid = isRenderPisellConfigProvider ? import_pisell_config_provider.default : import_react.default.Fragment;
|
|
218
219
|
return /* @__PURE__ */ import_react.default.createElement(
|
|
219
220
|
import_config_provider.default,
|
|
220
221
|
{
|
|
@@ -237,7 +238,7 @@ var Page = (props) => {
|
|
|
237
238
|
dateAdapter: import_AdapterDayjs.AdapterDayjs,
|
|
238
239
|
adapterLocale: ((_d = localeDateMap == null ? void 0 : localeDateMap[locale]) == null ? void 0 : _d.adapterLocale) || "en"
|
|
239
240
|
},
|
|
240
|
-
/* @__PURE__ */ import_react.default.createElement(import_date_picker.ThemeProvider, { theme: datePickerTheme }, /* @__PURE__ */ import_react.default.createElement(import_date_picker.LocaleProvider, { value: { locale } }, /* @__PURE__ */ import_react.default.createElement(
|
|
241
|
+
/* @__PURE__ */ import_react.default.createElement(import_date_picker.ThemeProvider, { theme: datePickerTheme }, /* @__PURE__ */ import_react.default.createElement(import_date_picker.LocaleProvider, { value: { locale } }, /* @__PURE__ */ import_react.default.createElement(PisellConfigProvid, { locale }, /* @__PURE__ */ import_react.default.createElement(
|
|
241
242
|
import_VariablesProvider.default,
|
|
242
243
|
{
|
|
243
244
|
variables: ((_f = (_e = context.engine) == null ? void 0 : _e.props) == null ? void 0 : _f.variables) || {}
|
|
@@ -49,6 +49,8 @@ var PisellAdjustPrice = (props) => {
|
|
|
49
49
|
defaultValue,
|
|
50
50
|
originValue,
|
|
51
51
|
selectType = "light",
|
|
52
|
+
resetText,
|
|
53
|
+
doneText,
|
|
52
54
|
...others
|
|
53
55
|
} = props;
|
|
54
56
|
const config = (0, import_usePisellConfig.default)();
|
|
@@ -180,6 +182,8 @@ var PisellAdjustPrice = (props) => {
|
|
|
180
182
|
onChange: handleChange,
|
|
181
183
|
onEnter: handleEnter,
|
|
182
184
|
placeholder: discountMode === "amount" ? "0" : "%",
|
|
185
|
+
resetText,
|
|
186
|
+
doneText,
|
|
183
187
|
rightItemsStyle: {
|
|
184
188
|
buttonBackgroundColor: configColor.buttonBackgroundColor,
|
|
185
189
|
textColor: configColor.textColor,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { PisellCheckboxGroupProps } from '../pisellCheckboxGroup';
|
|
3
3
|
import { PisellContextType } from '../pisell-config-provider/context';
|
|
4
|
-
import { PisellWalletPassCardProps } from '../pisellWalletPassCard';
|
|
4
|
+
import { PisellWalletPassCardProps, FormatOption } from '../pisellWalletPassCard';
|
|
5
5
|
import './index.less';
|
|
6
6
|
export interface PisellCardListProps extends Omit<PisellCheckboxGroupProps, 'options'> {
|
|
7
7
|
platform?: PisellContextType['platform'];
|
|
@@ -71,7 +71,37 @@ export interface PisellCardListProps extends Omit<PisellCheckboxGroupProps, 'opt
|
|
|
71
71
|
/** 编辑编辑按钮后,弹窗展示之前 */
|
|
72
72
|
beforeEdit?: (value: any, index: number) => Promise<any> | boolean | void;
|
|
73
73
|
/** 编辑弹窗点击提交 */
|
|
74
|
-
onConfirmEdit?: (value: any, index: number) => void;
|
|
74
|
+
onConfirmEdit?: (value: any, index: number, data: any) => void;
|
|
75
|
+
/** 是否展示状态标识 */
|
|
76
|
+
showStatus?: boolean;
|
|
77
|
+
/** 名称标题字号字重颜色配置 */
|
|
78
|
+
nameTitleStyle?: {
|
|
79
|
+
fontSize: number;
|
|
80
|
+
fontWeight: number;
|
|
81
|
+
color: string;
|
|
82
|
+
};
|
|
83
|
+
/** 开启编辑金额 */
|
|
84
|
+
enableEditAmount?: boolean;
|
|
85
|
+
/** 编辑金额事件 */
|
|
86
|
+
onConfirmEditAmount?: (value: number, index: number, data: any) => void;
|
|
87
|
+
/** 是否使用外部详情处理 */
|
|
88
|
+
useExternalDetail?: boolean;
|
|
89
|
+
/** 详情事件 */
|
|
90
|
+
onDetail?: (value: any, index: number) => void;
|
|
91
|
+
/** 自定义余额格式化函数,如果提供则优先使用 */
|
|
92
|
+
formatBalance?: (balance?: number, option?: FormatOption) => React.ReactNode;
|
|
93
|
+
/** 自定义余额标题格式化函数,如果提供则优先使用 */
|
|
94
|
+
formatBalanceTitle?: (balanceTitle?: string, option?: FormatOption) => React.ReactNode;
|
|
95
|
+
/** 自定义使用金额格式化函数,如果提供则优先使用 */
|
|
96
|
+
formatRedeem?: (redeem?: number, option?: FormatOption) => React.ReactNode;
|
|
97
|
+
/** 自定义使用金额标题格式化函数,如果提供则优先使用 */
|
|
98
|
+
formatRedeemTitle?: (redeemTitle?: string, option?: FormatOption) => React.ReactNode;
|
|
99
|
+
/** 编辑金额前事件 */
|
|
100
|
+
onBeforeEditAmount?: (value: any, index: number, data: any) => Promise<any> | boolean | void;
|
|
101
|
+
/** 选项点击事件 */
|
|
102
|
+
onItemClick?: (e: React.MouseEvent<HTMLDivElement>, option: any) => void;
|
|
103
|
+
/** 是否展示选中状态的背景色 */
|
|
104
|
+
showActiveBackground?: boolean;
|
|
75
105
|
}
|
|
76
106
|
declare const _default: React.NamedExoticComponent<PisellCardListProps>;
|
|
77
107
|
export default _default;
|
|
@@ -64,6 +64,18 @@ var PisellCardList = (props) => {
|
|
|
64
64
|
showEmpty,
|
|
65
65
|
showBalanceSymbol,
|
|
66
66
|
onChangeDebounce,
|
|
67
|
+
showStatus,
|
|
68
|
+
nameTitleStyle,
|
|
69
|
+
enableEditAmount,
|
|
70
|
+
useExternalDetail,
|
|
71
|
+
onDetail,
|
|
72
|
+
formatBalance,
|
|
73
|
+
formatBalanceTitle,
|
|
74
|
+
formatRedeem,
|
|
75
|
+
formatRedeemTitle,
|
|
76
|
+
onBeforeEditAmount,
|
|
77
|
+
onItemClick,
|
|
78
|
+
showActiveBackground,
|
|
67
79
|
validDateBySchedule,
|
|
68
80
|
scheduleList
|
|
69
81
|
} = props;
|
|
@@ -80,12 +92,19 @@ var PisellCardList = (props) => {
|
|
|
80
92
|
iconPosition: "hide",
|
|
81
93
|
fullWidth,
|
|
82
94
|
onChangeDebounce,
|
|
95
|
+
onItemClick,
|
|
96
|
+
showActiveBackground,
|
|
83
97
|
renderOption: (item, active, index) => {
|
|
84
98
|
return /* @__PURE__ */ import_react.default.createElement(
|
|
85
99
|
import_pisellWalletPassCard.default,
|
|
86
100
|
{
|
|
87
101
|
...item,
|
|
88
102
|
active,
|
|
103
|
+
mode,
|
|
104
|
+
showActiveIcon: true,
|
|
105
|
+
showStatus: showStatus || (item == null ? void 0 : item.showStatus),
|
|
106
|
+
cardStatus: item == null ? void 0 : item.cardStatus,
|
|
107
|
+
nameTitleStyle: nameTitleStyle || (item == null ? void 0 : item.nameTitleStyle),
|
|
89
108
|
showName: showName || (item == null ? void 0 : item.showName),
|
|
90
109
|
showBalance: showBalance || (item == null ? void 0 : item.showBalance),
|
|
91
110
|
showCode: showCode || (item == null ? void 0 : item.showCode),
|
|
@@ -98,18 +117,36 @@ var PisellCardList = (props) => {
|
|
|
98
117
|
showBalanceSymbol: showBalanceSymbol || (item == null ? void 0 : item.showBalanceSymbol),
|
|
99
118
|
showActions: props.showActions || (item == null ? void 0 : item.showActions),
|
|
100
119
|
actions: props.actions || (item == null ? void 0 : item.actions),
|
|
120
|
+
enableEditAmount: enableEditAmount || (item == null ? void 0 : item.enableEditAmount),
|
|
121
|
+
useExternalDetail: useExternalDetail || (item == null ? void 0 : item.useExternalDetail),
|
|
122
|
+
onDetail: (record) => {
|
|
123
|
+
var _a;
|
|
124
|
+
return (_a = props == null ? void 0 : props.onDetail) == null ? void 0 : _a.call(props, record, index);
|
|
125
|
+
},
|
|
101
126
|
validDateBySchedule: validDateBySchedule || (item == null ? void 0 : item.validDateBySchedule),
|
|
102
127
|
scheduleList: scheduleList || (item == null ? void 0 : item.scheduleList),
|
|
103
128
|
beforeEdit: (record) => {
|
|
104
129
|
var _a;
|
|
105
130
|
return (_a = props == null ? void 0 : props.beforeEdit) == null ? void 0 : _a.call(props, record, index);
|
|
106
131
|
},
|
|
132
|
+
onConfirmEditAmount: (value2) => {
|
|
133
|
+
var _a;
|
|
134
|
+
(_a = props.onConfirmEditAmount) == null ? void 0 : _a.call(props, value2, index, item);
|
|
135
|
+
},
|
|
107
136
|
onConfirmEdit: (newVal) => {
|
|
108
137
|
var _a;
|
|
109
|
-
(_a = props.onConfirmEdit) == null ? void 0 : _a.call(props, newVal, index);
|
|
138
|
+
(_a = props.onConfirmEdit) == null ? void 0 : _a.call(props, newVal, index, item);
|
|
110
139
|
},
|
|
140
|
+
formatBalance: formatBalance || (item == null ? void 0 : item.formatBalance),
|
|
141
|
+
formatBalanceTitle: formatBalanceTitle || (item == null ? void 0 : item.formatBalanceTitle),
|
|
111
142
|
type,
|
|
112
|
-
style: direction === "vertical" || direction === "horizontal" && fullWidth ? { width: "100%" } : {}
|
|
143
|
+
style: direction === "vertical" || direction === "horizontal" && fullWidth ? { width: "100%" } : {},
|
|
144
|
+
formatRedeem: formatRedeem || (item == null ? void 0 : item.formatRedeem),
|
|
145
|
+
formatRedeemTitle: formatRedeemTitle || (item == null ? void 0 : item.formatRedeemTitle),
|
|
146
|
+
onBeforeEditAmount: (record) => {
|
|
147
|
+
var _a;
|
|
148
|
+
return (_a = props == null ? void 0 : props.onBeforeEditAmount) == null ? void 0 : _a.call(props, record, index, item);
|
|
149
|
+
}
|
|
113
150
|
}
|
|
114
151
|
);
|
|
115
152
|
}
|
|
@@ -72,4 +72,12 @@
|
|
|
72
72
|
// .pisell-card-disabled {
|
|
73
73
|
// color: var(--Gray-500, #667085);
|
|
74
74
|
// padding-bottom: 36px;
|
|
75
|
-
// }
|
|
75
|
+
// }
|
|
76
|
+
|
|
77
|
+
.keyboard-modal-wrapper {
|
|
78
|
+
.pisell-amount-keyboard-wrap {
|
|
79
|
+
padding: 10px;
|
|
80
|
+
background: rgba(29, 41, 57, .8) !important;
|
|
81
|
+
border-radius: 10px;
|
|
82
|
+
}
|
|
83
|
+
}
|
|
@@ -5,6 +5,7 @@ export interface PisellCheckboxGroupOption {
|
|
|
5
5
|
label: string;
|
|
6
6
|
value: string;
|
|
7
7
|
disabled?: boolean;
|
|
8
|
+
error?: boolean;
|
|
8
9
|
[key: string]: any;
|
|
9
10
|
}
|
|
10
11
|
declare type PisellCheckboxGroupValue = string | string[] | any;
|
|
@@ -24,6 +25,8 @@ export interface PisellCheckboxGroupProps extends React.HTMLAttributes<HTMLDivEl
|
|
|
24
25
|
optionClassName?: string;
|
|
25
26
|
optionActiveClassName?: string;
|
|
26
27
|
onChangeDebounce?: boolean;
|
|
28
|
+
onItemClick?: (e: React.MouseEvent<HTMLDivElement>, option: PisellCheckboxGroupOption) => void;
|
|
29
|
+
showActiveBackground?: boolean;
|
|
27
30
|
}
|
|
28
31
|
/**
|
|
29
32
|
* @title: PisellCheckboxGroup
|
|
@@ -64,6 +64,8 @@ var PisellCheckboxGroup = (props) => {
|
|
|
64
64
|
optionClassName,
|
|
65
65
|
optionActiveClassName,
|
|
66
66
|
onChangeDebounce,
|
|
67
|
+
onItemClick,
|
|
68
|
+
showActiveBackground = false,
|
|
67
69
|
...rest
|
|
68
70
|
} = props;
|
|
69
71
|
const [_value, set_value] = (0, import_react2.useState)([]);
|
|
@@ -150,13 +152,16 @@ var PisellCheckboxGroup = (props) => {
|
|
|
150
152
|
optionClassName,
|
|
151
153
|
{
|
|
152
154
|
"pisell-checkbox-group-item-active": active,
|
|
153
|
-
|
|
155
|
+
"pisell-checkbox-group-item-with-background": active && showActiveBackground,
|
|
156
|
+
[optionActiveClassName]: active,
|
|
157
|
+
"pisell-checkbox-group-item-error": option.error
|
|
154
158
|
}
|
|
155
159
|
),
|
|
156
160
|
key: option[rowKey],
|
|
157
161
|
gap: 10,
|
|
158
162
|
style: rowStyle,
|
|
159
163
|
onClick: (e) => {
|
|
164
|
+
onItemClick == null ? void 0 : onItemClick(e, option);
|
|
160
165
|
if (option.disabled) return;
|
|
161
166
|
if (onChangeDebounce) {
|
|
162
167
|
run(option[rowKey], option);
|
|
@@ -24,10 +24,37 @@
|
|
|
24
24
|
|
|
25
25
|
&.pisell-checkbox-group-item-active {
|
|
26
26
|
&::before {
|
|
27
|
-
border-width:
|
|
27
|
+
border-width: 4px;
|
|
28
28
|
border-color: var(--theme-color);
|
|
29
|
+
z-index: 1;
|
|
30
|
+
box-sizing: border-box;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
// 可选的背景色样式,需要额外的类名才会应用
|
|
34
|
+
&.pisell-checkbox-group-item-with-background {
|
|
35
|
+
&::before {
|
|
36
|
+
background: var(--Primary-50, #F9F5FF);
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
.pisell-row-center {
|
|
40
|
+
.pisell-row {
|
|
41
|
+
position: relative;
|
|
42
|
+
z-index: 1;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
.pisell-row-right {
|
|
46
|
+
position: relative;
|
|
47
|
+
z-index: 1;
|
|
29
48
|
}
|
|
49
|
+
}
|
|
30
50
|
|
|
51
|
+
&.pisell-checkbox-group-item-error {
|
|
52
|
+
&::before {
|
|
53
|
+
border-color: var(--Error-500, #F04438);
|
|
54
|
+
border-width: 2px;
|
|
55
|
+
background: var(--Error-50, #FEF3F2);
|
|
56
|
+
z-index: 1;
|
|
57
|
+
}
|
|
31
58
|
}
|
|
32
59
|
}
|
|
33
60
|
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import './index.less';
|
|
3
|
+
export interface PisellCustomCheckboxGroupProps {
|
|
4
|
+
dataSource?: any[];
|
|
5
|
+
disabled?: boolean;
|
|
6
|
+
allowAdd?: boolean;
|
|
7
|
+
isMultiple?: boolean;
|
|
8
|
+
id?: string | string[];
|
|
9
|
+
onClick?: (value: any) => void;
|
|
10
|
+
onAdd?: () => void;
|
|
11
|
+
renderAddItem?: (item: any) => React.ReactNode;
|
|
12
|
+
[key: string]: any;
|
|
13
|
+
className?: string;
|
|
14
|
+
}
|
|
15
|
+
declare const PisellCustomCheckboxGroup: React.FC<PisellCustomCheckboxGroupProps>;
|
|
16
|
+
export default PisellCustomCheckboxGroup;
|
|
@@ -44,6 +44,7 @@ export interface PisellGoodPassCardProps {
|
|
|
44
44
|
style: React.CSSProperties;
|
|
45
45
|
/**快捷展示排序 */
|
|
46
46
|
mixedSort?: (val: Discount[]) => Discount[];
|
|
47
|
+
isInModal: boolean;
|
|
47
48
|
}
|
|
48
49
|
declare const index: (props: PisellGoodPassCardProps) => JSX.Element;
|
|
49
50
|
export default index;
|
|
@@ -86,7 +86,18 @@ var index = (props) => {
|
|
|
86
86
|
onCancel: () => setShowModal(false),
|
|
87
87
|
className: `${clsPrefix}-all-items-modal`
|
|
88
88
|
},
|
|
89
|
-
/* @__PURE__ */ import_react.default.createElement(
|
|
89
|
+
/* @__PURE__ */ import_react.default.createElement(
|
|
90
|
+
"div",
|
|
91
|
+
{
|
|
92
|
+
style: {
|
|
93
|
+
padding: "10px 0",
|
|
94
|
+
display: "flex",
|
|
95
|
+
flexDirection: "column",
|
|
96
|
+
gap: 12
|
|
97
|
+
}
|
|
98
|
+
},
|
|
99
|
+
dataSource.map(renderVoucherItem)
|
|
100
|
+
)
|
|
90
101
|
);
|
|
91
102
|
};
|
|
92
103
|
const renderMixedMode = () => {
|
|
@@ -94,7 +105,23 @@ var index = (props) => {
|
|
|
94
105
|
const list = sortList.length > 3 ? sortList.slice(0, 3) : sortList;
|
|
95
106
|
return /* @__PURE__ */ import_react.default.createElement(import_react.default.Fragment, null, /* @__PURE__ */ import_react.default.createElement("div", { className: `${clsPrefix}-header` }, /* @__PURE__ */ import_react.default.createElement("div", null, (0, import_locales.getText)("pisell2.text.goodpass.product-vouchers")), /* @__PURE__ */ import_react.default.createElement(import_antd.Typography.Text, { underline: true, onClick: () => setShowModal(true) }, (0, import_locales.getText)("pisell2.text.goodpass.view-more"))), /* @__PURE__ */ import_react.default.createElement(import_antd.Divider, { style: { margin: 4 } }), /* @__PURE__ */ import_react.default.createElement("div", { className: `${clsPrefix}-body` }, list.map(renderVoucherItem)));
|
|
96
107
|
};
|
|
97
|
-
|
|
108
|
+
const renderModalMode = () => {
|
|
109
|
+
const sortList = (mixedSort == null ? void 0 : mixedSort(dataSource)) || dataSource;
|
|
110
|
+
if (sortList.length === 0) return null;
|
|
111
|
+
return /* @__PURE__ */ import_react.default.createElement(
|
|
112
|
+
"div",
|
|
113
|
+
{
|
|
114
|
+
style: {
|
|
115
|
+
padding: "10px 0",
|
|
116
|
+
display: "flex",
|
|
117
|
+
flexDirection: "column",
|
|
118
|
+
gap: 12
|
|
119
|
+
}
|
|
120
|
+
},
|
|
121
|
+
sortList.map(renderVoucherItem)
|
|
122
|
+
);
|
|
123
|
+
};
|
|
124
|
+
return /* @__PURE__ */ import_react.default.createElement(import_react.default.Fragment, null, !props.isInModal ? renderModal() : null, dataSource.length > 0 ? /* @__PURE__ */ import_react.default.createElement(
|
|
98
125
|
import__.PisellCard,
|
|
99
126
|
{
|
|
100
127
|
padding: 8,
|
|
@@ -105,7 +132,7 @@ var index = (props) => {
|
|
|
105
132
|
},
|
|
106
133
|
className: clsPrefix
|
|
107
134
|
},
|
|
108
|
-
renderMixedMode()
|
|
109
|
-
));
|
|
135
|
+
props.isInModal ? renderModalMode() : renderMixedMode()
|
|
136
|
+
) : null);
|
|
110
137
|
};
|
|
111
138
|
var pisellGoodPassCard_default = index;
|
|
@@ -47,7 +47,8 @@ var Amount = (props) => {
|
|
|
47
47
|
} = props;
|
|
48
48
|
const config = (0, import_usePisellConfig.default)();
|
|
49
49
|
const amount = (0, import_react.useMemo)(() => {
|
|
50
|
-
|
|
50
|
+
var _a;
|
|
51
|
+
return (0, import_utils.formatAmountWithOptions)(value, symbol || (config == null ? void 0 : config.symbol) || ((_a = config == null ? void 0 : config.getSymbolic) == null ? void 0 : _a.call(config)) || "", {
|
|
51
52
|
precision,
|
|
52
53
|
showCurrencySymbol,
|
|
53
54
|
useThousandsSeparator,
|