@pisell/materials 6.2.36 → 6.3.2
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 +3 -3
- package/build/lowcode/preview.js +164 -148
- package/build/lowcode/render/default/view.css +1 -1
- package/build/lowcode/render/default/view.js +39 -25
- package/build/lowcode/view.css +1 -1
- package/build/lowcode/view.js +39 -25
- package/es/components/batch-editor/index.d.ts +1 -0
- package/es/components/dataSourceComponents/dataSourceShow/dataSourceImage/index.d.ts +1 -0
- package/es/components/dataSourceComponents/dataSourceShow/dataSourceQRCode/index.d.ts +1 -0
- package/es/components/dataSourceComponents/dataSourceTable/filter/index.d.ts +1 -0
- package/es/components/dataSourceComponents/dataSourceTable/hooks/useDrawerState.d.ts +2 -2
- package/es/components/dataSourceComponents/dataSourceWrapper/index.d.ts +1 -0
- package/es/components/dataSourceComponents/fields/Input.Subdomain/index.d.ts +1 -1
- package/es/components/dataSourceComponents/fields/Select/index.d.ts +1 -0
- package/es/components/dataSourceComponents/fields/index.d.ts +11 -10
- package/es/components/date-picker/index.d.ts +1 -0
- package/es/components/filter/index.d.ts +1 -0
- package/es/components/iconfont/index.js +1 -1
- package/es/components/page/index.d.ts +1 -0
- package/es/components/pisellAdjustPrice/PisellAdjustPriceInputNumber.d.ts +1 -0
- package/es/components/pisellCardList/index.js +3 -1
- package/es/components/pisellCheckboxGroup/index.d.ts +1 -0
- package/es/components/pisellCheckboxGroup/index.js +15 -1
- package/es/components/pisellGoodPassCard/index.d.ts +0 -1
- package/es/components/pisellGoodPassCard/index.js +5 -17
- package/es/components/pisellInput/index.d.ts +1 -0
- package/es/components/pisellModal/components/IpadModal/index.d.ts +1 -0
- package/es/components/pisellModal/components/MobileModal/index.d.ts +1 -0
- package/es/components/pisellModal/components/index.d.ts +1 -0
- package/es/components/pisellToast/index.js +0 -3
- package/es/components/pisellWalletPassCard/index.d.ts +1 -0
- package/es/components/productCard/components/Action/index.js +1 -14
- package/es/components/productCard/components/Action/index.less +0 -3
- package/es/components/productCard/components/Header/index.js +8 -23
- package/es/components/productCard/components/Header/index.less +1 -16
- package/es/components/productCard/components/MultiDay/index.d.ts +1 -0
- package/es/components/productCard/components/Packages/components/collapsibleList/utils.d.ts +1 -0
- package/es/components/productCard/components/Packages/components/options/index.d.ts +1 -0
- package/es/components/productCard/components/Sales/index.js +2 -2
- package/es/components/productCard/components/Time/components/SelectHolderModal/index.js +1 -3
- package/es/components/productCard/components/Time/components/SelectHolderModal/index.less +0 -3
- package/es/components/productCard/index.d.ts +1 -3
- package/es/components/productCard/index.js +2 -5
- package/es/components/productCard/index.less +0 -6
- package/es/components/productCard/locales.js +0 -3
- package/es/components/table/Actions/component/ColumnsSetting/index.d.ts +1 -0
- package/es/components/table/Actions/component/GallerySetting/index.d.ts +1 -0
- package/es/components/table/Actions/component/Group/index.d.ts +1 -0
- package/es/components/table/Actions/index.d.ts +1 -0
- package/es/components/table/Gallery/components/GalleryItem/components/Cover/index.d.ts +1 -0
- package/es/components/table/Gallery/components/GalleryItem/components/Title/index.d.ts +1 -0
- package/es/components/table/Table/SelectField/index.d.ts +1 -0
- package/es/components/table/Table/fields/date/index.d.ts +1 -0
- package/es/components/table/Table/fields/image/Show/index.d.ts +1 -0
- package/es/components/table/Table/fields/image/index.d.ts +1 -0
- package/es/components/table/Table/fields/index.d.ts +3 -2
- package/es/components/table/Table/fields/link/index.d.ts +1 -0
- package/es/components/table/Table/fields/number/Show/index.d.ts +1 -0
- package/es/components/table/Table/fields/number/index.d.ts +1 -0
- package/es/components/table/Table/fields/numberRange/Show/index.d.ts +1 -0
- package/es/components/table/Table/fields/numberRange/index.d.ts +1 -0
- package/es/components/table/Table/fields/oldRangePicker/index.d.ts +1 -0
- package/es/components/table/Table/fields/pSwitch/Show/index.d.ts +1 -0
- package/es/components/table/Table/fields/pSwitch/index.d.ts +1 -0
- package/es/components/table/Table/fields/rangePicker/index.d.ts +1 -0
- package/es/components/table/Table/fields/search/Show/index.d.ts +1 -0
- package/es/components/table/Table/fields/search/index.d.ts +1 -0
- package/es/components/table/Table/fields/text/Show/index.d.ts +1 -0
- package/es/components/table/Table/fields/text/index.d.ts +1 -0
- package/es/components/table/Table/utils.d.ts +1 -1
- package/es/components/table/View/index.d.ts +1 -0
- package/es/components/versionSelect/index.d.ts +1 -0
- package/es/components/virtual-keyboard/index.d.ts +0 -11
- package/es/components/virtual-keyboard/index.js +3 -88
- package/es/components/virtual-keyboard/index.less +1 -33
- package/es/components/walletCard/Guide/index.js +12 -1
- package/lib/components/batch-editor/index.d.ts +1 -0
- package/lib/components/dataSourceComponents/dataSourceShow/dataSourceImage/index.d.ts +1 -0
- package/lib/components/dataSourceComponents/dataSourceShow/dataSourceQRCode/index.d.ts +1 -0
- package/lib/components/dataSourceComponents/dataSourceTable/filter/index.d.ts +1 -0
- package/lib/components/dataSourceComponents/dataSourceTable/hooks/useDrawerState.d.ts +2 -2
- package/lib/components/dataSourceComponents/dataSourceWrapper/index.d.ts +1 -0
- package/lib/components/dataSourceComponents/fields/Input.Subdomain/index.d.ts +1 -1
- package/lib/components/dataSourceComponents/fields/Select/index.d.ts +1 -0
- package/lib/components/dataSourceComponents/fields/index.d.ts +11 -10
- package/lib/components/date-picker/index.d.ts +1 -0
- package/lib/components/filter/index.d.ts +1 -0
- package/lib/components/iconfont/index.js +1 -1
- package/lib/components/page/index.d.ts +1 -0
- package/lib/components/pisellAdjustPrice/PisellAdjustPriceInputNumber.d.ts +1 -0
- package/lib/components/pisellCardList/index.js +3 -1
- package/lib/components/pisellCheckboxGroup/index.d.ts +1 -0
- package/lib/components/pisellCheckboxGroup/index.js +16 -0
- package/lib/components/pisellGoodPassCard/index.d.ts +0 -1
- package/lib/components/pisellGoodPassCard/index.js +4 -31
- package/lib/components/pisellInput/index.d.ts +1 -0
- package/lib/components/pisellModal/components/IpadModal/index.d.ts +1 -0
- package/lib/components/pisellModal/components/MobileModal/index.d.ts +1 -0
- package/lib/components/pisellModal/components/index.d.ts +1 -0
- package/lib/components/pisellToast/index.js +0 -3
- package/lib/components/pisellWalletPassCard/index.d.ts +1 -0
- package/lib/components/productCard/components/Action/index.js +0 -9
- package/lib/components/productCard/components/Action/index.less +0 -3
- package/lib/components/productCard/components/Header/index.js +11 -21
- package/lib/components/productCard/components/Header/index.less +1 -16
- package/lib/components/productCard/components/MultiDay/index.d.ts +1 -0
- package/lib/components/productCard/components/Packages/components/collapsibleList/utils.d.ts +1 -0
- package/lib/components/productCard/components/Packages/components/options/index.d.ts +1 -0
- 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 +0 -3
- package/lib/components/productCard/index.d.ts +1 -3
- package/lib/components/productCard/index.js +2 -6
- package/lib/components/productCard/index.less +0 -6
- package/lib/components/productCard/locales.js +3 -12
- package/lib/components/table/Actions/component/ColumnsSetting/index.d.ts +1 -0
- package/lib/components/table/Actions/component/GallerySetting/index.d.ts +1 -0
- package/lib/components/table/Actions/component/Group/index.d.ts +1 -0
- package/lib/components/table/Actions/index.d.ts +1 -0
- package/lib/components/table/Gallery/components/GalleryItem/components/Cover/index.d.ts +1 -0
- package/lib/components/table/Gallery/components/GalleryItem/components/Title/index.d.ts +1 -0
- package/lib/components/table/Table/SelectField/index.d.ts +1 -0
- package/lib/components/table/Table/fields/date/index.d.ts +1 -0
- package/lib/components/table/Table/fields/image/Show/index.d.ts +1 -0
- package/lib/components/table/Table/fields/image/index.d.ts +1 -0
- package/lib/components/table/Table/fields/index.d.ts +3 -2
- package/lib/components/table/Table/fields/link/index.d.ts +1 -0
- package/lib/components/table/Table/fields/number/Show/index.d.ts +1 -0
- package/lib/components/table/Table/fields/number/index.d.ts +1 -0
- package/lib/components/table/Table/fields/numberRange/Show/index.d.ts +1 -0
- package/lib/components/table/Table/fields/numberRange/index.d.ts +1 -0
- package/lib/components/table/Table/fields/oldRangePicker/index.d.ts +1 -0
- package/lib/components/table/Table/fields/pSwitch/Show/index.d.ts +1 -0
- package/lib/components/table/Table/fields/pSwitch/index.d.ts +1 -0
- package/lib/components/table/Table/fields/rangePicker/index.d.ts +1 -0
- package/lib/components/table/Table/fields/search/Show/index.d.ts +1 -0
- package/lib/components/table/Table/fields/search/index.d.ts +1 -0
- package/lib/components/table/Table/fields/text/Show/index.d.ts +1 -0
- package/lib/components/table/Table/fields/text/index.d.ts +1 -0
- package/lib/components/table/Table/utils.d.ts +1 -1
- package/lib/components/table/View/index.d.ts +1 -0
- package/lib/components/versionSelect/index.d.ts +1 -0
- package/lib/components/virtual-keyboard/index.d.ts +0 -11
- package/lib/components/virtual-keyboard/index.js +2 -60
- package/lib/components/virtual-keyboard/index.less +1 -33
- package/lib/components/walletCard/Guide/index.js +11 -1
- package/lowcode/_setters/antd-icon-setter/index.tsx +2 -3
- package/lowcode/virtual-keyboard/meta.ts +0 -131
- package/package.json +4 -6
- package/dist/umd/materials.min.css +0 -1
- package/dist/umd/materials.min.js +0 -1
- package/dist/umd/static/DotsSix.57d66266.svg +0 -1
- package/dist/umd/static/arrow-left.e542294f.svg +0 -1
- package/dist/umd/static/arrow-right.763f03e0.svg +0 -1
- package/dist/umd/static/filter-lines.04a54ae9.svg +0 -1
- package/dist/umd/static/help-circle.31c9be40.svg +0 -1
- package/dist/umd/static/switch-vertical-01.7ebe3ba8.svg +0 -1
- package/es/components/pisellAdjustPrice/status.d.ts +0 -32
- package/es/components/pisellAdjustPrice/type.d.ts +0 -20
- package/es/components/productCard/cartSkuCard/components/AmountFooter/index.d.ts +0 -3
- package/es/components/productCard/cartSkuCard/components/AmountFooter/index.js +0 -76
- package/es/components/productCard/cartSkuCard/components/AmountFooter/index.less +0 -75
- package/es/components/productCard/cartSkuCard/components/MultiDay/index.d.ts +0 -3
- package/es/components/productCard/cartSkuCard/components/MultiDay/index.js +0 -82
- package/es/components/productCard/cartSkuCard/components/MultiDay/index.less +0 -31
- package/es/components/productCard/cartSkuCard/components/MultiDay/utils.d.ts +0 -14
- package/es/components/productCard/cartSkuCard/components/MultiDay/utils.js +0 -56
- package/es/components/productCard/cartSkuCard/components/Note/index.d.ts +0 -3
- package/es/components/productCard/cartSkuCard/components/Note/index.js +0 -29
- package/es/components/productCard/cartSkuCard/components/Note/index.less +0 -27
- package/es/components/productCard/cartSkuCard/components/basicInfo/index.d.ts +0 -27
- package/es/components/productCard/cartSkuCard/components/basicInfo/index.js +0 -93
- package/es/components/productCard/cartSkuCard/components/basicInfo/index.less +0 -117
- package/es/components/productCard/cartSkuCard/components/discountReason/index.d.ts +0 -2
- package/es/components/productCard/cartSkuCard/components/discountReason/index.js +0 -51
- package/es/components/productCard/cartSkuCard/components/holders/index.d.ts +0 -3
- package/es/components/productCard/cartSkuCard/components/holders/index.js +0 -32
- package/es/components/productCard/cartSkuCard/components/holders/index.less +0 -32
- package/es/components/productCard/cartSkuCard/components/packages/index.d.ts +0 -10
- package/es/components/productCard/cartSkuCard/components/packages/index.js +0 -52
- package/es/components/productCard/cartSkuCard/components/packages/index.less +0 -22
- package/es/components/productCard/cartSkuCard/components/packages/utils.d.ts +0 -20
- package/es/components/productCard/cartSkuCard/components/packages/utils.js +0 -40
- package/es/components/productCard/cartSkuCard/components/resources/index.d.ts +0 -3
- package/es/components/productCard/cartSkuCard/components/resources/index.js +0 -39
- package/es/components/productCard/cartSkuCard/components/resources/index.less +0 -19
- package/es/components/productCard/cartSkuCard/components/sales/index.d.ts +0 -12
- package/es/components/productCard/cartSkuCard/components/sales/index.js +0 -57
- package/es/components/productCard/cartSkuCard/components/sales/index.less +0 -22
- package/es/components/productCard/cartSkuCard/components/specs/index.d.ts +0 -3
- package/es/components/productCard/cartSkuCard/components/specs/index.js +0 -44
- package/es/components/productCard/cartSkuCard/components/specs/index.less +0 -34
- package/es/components/productCard/cartSkuCard/components/swipeAction/index.d.ts +0 -45
- package/es/components/productCard/cartSkuCard/components/swipeAction/index.js +0 -292
- package/es/components/productCard/cartSkuCard/components/swipeAction/index.less +0 -35
- package/es/components/productCard/cartSkuCard/components/timeRange/index.d.ts +0 -6
- package/es/components/productCard/cartSkuCard/components/timeRange/index.js +0 -54
- package/es/components/productCard/cartSkuCard/components/timeRange/index.less +0 -38
- package/es/components/productCard/cartSkuCard/index.d.ts +0 -10
- package/es/components/productCard/cartSkuCard/index.js +0 -203
- package/es/components/productCard/cartSkuCard/index.less +0 -33
- package/es/components/productCard/cartSkuCard/locales.d.ts +0 -96
- package/es/components/productCard/cartSkuCard/locales.js +0 -30
- package/es/components/virtual-keyboard/Amount/themeConfig.d.ts +0 -32
- package/es/components/virtual-keyboard/Amount/types.d.ts +0 -44
- package/es/components/virtual-keyboard/Keyboard/index.d.ts +0 -21
- package/es/components/virtual-keyboard/Number/themeConfig.d.ts +0 -32
- package/es/components/virtual-keyboard/Number/types.d.ts +0 -25
- package/es/components/virtual-keyboard/VirtualKeyInput/index.d.ts +0 -13
- package/es/components/walletCard/Guide/index.d.ts +0 -3
- package/lib/components/pisellAdjustPrice/status.d.ts +0 -32
- package/lib/components/pisellAdjustPrice/type.d.ts +0 -20
- package/lib/components/productCard/cartSkuCard/components/AmountFooter/index.d.ts +0 -3
- package/lib/components/productCard/cartSkuCard/components/AmountFooter/index.js +0 -80
- package/lib/components/productCard/cartSkuCard/components/AmountFooter/index.less +0 -75
- package/lib/components/productCard/cartSkuCard/components/MultiDay/index.d.ts +0 -3
- package/lib/components/productCard/cartSkuCard/components/MultiDay/index.js +0 -71
- package/lib/components/productCard/cartSkuCard/components/MultiDay/index.less +0 -31
- package/lib/components/productCard/cartSkuCard/components/MultiDay/utils.d.ts +0 -14
- package/lib/components/productCard/cartSkuCard/components/MultiDay/utils.js +0 -77
- package/lib/components/productCard/cartSkuCard/components/Note/index.d.ts +0 -3
- package/lib/components/productCard/cartSkuCard/components/Note/index.js +0 -56
- package/lib/components/productCard/cartSkuCard/components/Note/index.less +0 -27
- package/lib/components/productCard/cartSkuCard/components/basicInfo/index.d.ts +0 -27
- package/lib/components/productCard/cartSkuCard/components/basicInfo/index.js +0 -82
- package/lib/components/productCard/cartSkuCard/components/basicInfo/index.less +0 -117
- package/lib/components/productCard/cartSkuCard/components/discountReason/index.d.ts +0 -2
- package/lib/components/productCard/cartSkuCard/components/discountReason/index.js +0 -70
- package/lib/components/productCard/cartSkuCard/components/holders/index.d.ts +0 -3
- package/lib/components/productCard/cartSkuCard/components/holders/index.js +0 -52
- package/lib/components/productCard/cartSkuCard/components/holders/index.less +0 -32
- package/lib/components/productCard/cartSkuCard/components/packages/index.d.ts +0 -10
- package/lib/components/productCard/cartSkuCard/components/packages/index.js +0 -73
- package/lib/components/productCard/cartSkuCard/components/packages/index.less +0 -22
- package/lib/components/productCard/cartSkuCard/components/packages/utils.d.ts +0 -20
- package/lib/components/productCard/cartSkuCard/components/packages/utils.js +0 -44
- package/lib/components/productCard/cartSkuCard/components/resources/index.d.ts +0 -3
- package/lib/components/productCard/cartSkuCard/components/resources/index.js +0 -71
- package/lib/components/productCard/cartSkuCard/components/resources/index.less +0 -19
- package/lib/components/productCard/cartSkuCard/components/sales/index.d.ts +0 -12
- package/lib/components/productCard/cartSkuCard/components/sales/index.js +0 -77
- package/lib/components/productCard/cartSkuCard/components/sales/index.less +0 -22
- package/lib/components/productCard/cartSkuCard/components/specs/index.d.ts +0 -3
- package/lib/components/productCard/cartSkuCard/components/specs/index.js +0 -66
- package/lib/components/productCard/cartSkuCard/components/specs/index.less +0 -34
- package/lib/components/productCard/cartSkuCard/components/swipeAction/index.d.ts +0 -45
- package/lib/components/productCard/cartSkuCard/components/swipeAction/index.js +0 -339
- package/lib/components/productCard/cartSkuCard/components/swipeAction/index.less +0 -35
- package/lib/components/productCard/cartSkuCard/components/timeRange/index.d.ts +0 -6
- package/lib/components/productCard/cartSkuCard/components/timeRange/index.js +0 -68
- package/lib/components/productCard/cartSkuCard/components/timeRange/index.less +0 -38
- package/lib/components/productCard/cartSkuCard/index.d.ts +0 -10
- package/lib/components/productCard/cartSkuCard/index.js +0 -239
- package/lib/components/productCard/cartSkuCard/index.less +0 -33
- package/lib/components/productCard/cartSkuCard/locales.d.ts +0 -96
- package/lib/components/productCard/cartSkuCard/locales.js +0 -61
- package/lib/components/virtual-keyboard/Amount/themeConfig.d.ts +0 -32
- package/lib/components/virtual-keyboard/Amount/types.d.ts +0 -44
- package/lib/components/virtual-keyboard/Keyboard/index.d.ts +0 -21
- package/lib/components/virtual-keyboard/Number/themeConfig.d.ts +0 -32
- package/lib/components/virtual-keyboard/Number/types.d.ts +0 -25
- package/lib/components/virtual-keyboard/VirtualKeyInput/index.d.ts +0 -13
- package/lib/components/walletCard/Guide/index.d.ts +0 -3
|
@@ -1,70 +0,0 @@
|
|
|
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/productCard/cartSkuCard/components/discountReason/index.tsx
|
|
30
|
-
var discountReason_exports = {};
|
|
31
|
-
__export(discountReason_exports, {
|
|
32
|
-
default: () => discountReason_default
|
|
33
|
-
});
|
|
34
|
-
module.exports = __toCommonJS(discountReason_exports);
|
|
35
|
-
var import_react = __toESM(require("react"));
|
|
36
|
-
var import_antd = require("antd");
|
|
37
|
-
var import_utils = require("@pisell/utils");
|
|
38
|
-
var import__ = require("../../index");
|
|
39
|
-
var DiscountReason = (props) => {
|
|
40
|
-
const { dataSource = {}, hideDivider } = props;
|
|
41
|
-
const { total, origin_total, symbol, tip, num, discount_reason } = dataSource;
|
|
42
|
-
const isDiscount = (0, import_react.useMemo)(() => {
|
|
43
|
-
if (!origin_total) return false;
|
|
44
|
-
return Number(total) != Number(origin_total);
|
|
45
|
-
}, [total, origin_total]);
|
|
46
|
-
const renderDivider = () => {
|
|
47
|
-
return isDiscount && discount_reason && !hideDivider ? /* @__PURE__ */ import_react.default.createElement(import_antd.Divider, { style: { margin: "4px 0" } }) : null;
|
|
48
|
-
};
|
|
49
|
-
const renderDiscountReason = () => {
|
|
50
|
-
if (isDiscount && discount_reason) {
|
|
51
|
-
if (Array.isArray(discount_reason)) {
|
|
52
|
-
return /* @__PURE__ */ import_react.default.createElement(
|
|
53
|
-
"div",
|
|
54
|
-
{
|
|
55
|
-
className: `${import__.PREFIX}_discount-reason`,
|
|
56
|
-
style: { display: "flex", flexWrap: "wrap", gap: "4px" }
|
|
57
|
-
},
|
|
58
|
-
discount_reason.map((reason, index) => {
|
|
59
|
-
return /* @__PURE__ */ import_react.default.createElement(import_antd.Tag, { key: index, color: "red" }, reason);
|
|
60
|
-
})
|
|
61
|
-
);
|
|
62
|
-
}
|
|
63
|
-
return /* @__PURE__ */ import_react.default.createElement("div", { className: `${import__.PREFIX}_discount-reason` }, /* @__PURE__ */ import_react.default.createElement("span", null, `${import_utils.locales.getText(
|
|
64
|
-
"pisell2.product.card.discount.reason"
|
|
65
|
-
)}: ${discount_reason}`));
|
|
66
|
-
}
|
|
67
|
-
};
|
|
68
|
-
return /* @__PURE__ */ import_react.default.createElement(import_react.default.Fragment, null, renderDivider(), renderDiscountReason());
|
|
69
|
-
};
|
|
70
|
-
var discountReason_default = DiscountReason;
|
|
@@ -1,52 +0,0 @@
|
|
|
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/productCard/cartSkuCard/components/holders/index.tsx
|
|
30
|
-
var holders_exports = {};
|
|
31
|
-
__export(holders_exports, {
|
|
32
|
-
default: () => holders_default
|
|
33
|
-
});
|
|
34
|
-
module.exports = __toCommonJS(holders_exports);
|
|
35
|
-
var import_react = __toESM(require("react"));
|
|
36
|
-
var import_iconfont = __toESM(require("../../../../iconfont"));
|
|
37
|
-
var import__ = require("../../index");
|
|
38
|
-
var import_index = require("./index.less");
|
|
39
|
-
var Holders = (props) => {
|
|
40
|
-
const { dataSource = {} } = props;
|
|
41
|
-
const { holders, holder_id } = dataSource;
|
|
42
|
-
if (!holder_id) return null;
|
|
43
|
-
const renderHolder = (id) => {
|
|
44
|
-
if (!id) return null;
|
|
45
|
-
const holder = holders.find((item) => item.id === id);
|
|
46
|
-
return /* @__PURE__ */ import_react.default.createElement("div", { className: "holder-item", key: id }, /* @__PURE__ */ import_react.default.createElement(import_iconfont.default, { className: "holder-icon", type: "pisell2-user-check-01" }), /* @__PURE__ */ import_react.default.createElement("span", { className: "holder-label" }, (holder == null ? void 0 : holder.label) || id));
|
|
47
|
-
};
|
|
48
|
-
return /* @__PURE__ */ import_react.default.createElement("div", { className: `${import__.PREFIX}__holders` }, Array.isArray(holder_id) ? holder_id == null ? void 0 : holder_id.map((id) => {
|
|
49
|
-
return renderHolder(id);
|
|
50
|
-
}) : renderHolder(holder_id));
|
|
51
|
-
};
|
|
52
|
-
var holders_default = Holders;
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
.pisell-cart-sku-card__holders {
|
|
2
|
-
user-select: none;
|
|
3
|
-
|
|
4
|
-
display: flex;
|
|
5
|
-
gap: 16px;
|
|
6
|
-
overflow: hidden;
|
|
7
|
-
|
|
8
|
-
.holder-item {
|
|
9
|
-
overflow: hidden;
|
|
10
|
-
white-space: nowrap;
|
|
11
|
-
display: flex;
|
|
12
|
-
align-items: center;
|
|
13
|
-
min-width: 30px;
|
|
14
|
-
|
|
15
|
-
.holder-icon {
|
|
16
|
-
font-size: 16px;
|
|
17
|
-
color: #7f56da;
|
|
18
|
-
margin-right: 2;
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
.holder-label {
|
|
22
|
-
color: #667085;
|
|
23
|
-
font-size: 14px;
|
|
24
|
-
font-weight: 500;
|
|
25
|
-
line-height: 20px;
|
|
26
|
-
display: inline-block;
|
|
27
|
-
overflow: hidden;
|
|
28
|
-
text-overflow: ellipsis;
|
|
29
|
-
white-space: nowrap;
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
}
|
|
@@ -1,73 +0,0 @@
|
|
|
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/productCard/cartSkuCard/components/packages/index.tsx
|
|
30
|
-
var packages_exports = {};
|
|
31
|
-
__export(packages_exports, {
|
|
32
|
-
default: () => packages_default
|
|
33
|
-
});
|
|
34
|
-
module.exports = __toCommonJS(packages_exports);
|
|
35
|
-
var import_react = __toESM(require("react"));
|
|
36
|
-
var import_antd = require("antd");
|
|
37
|
-
var import_utils = require("@pisell/utils");
|
|
38
|
-
var import_collapsibleList = __toESM(require("../../../components/Packages/components/collapsibleList"));
|
|
39
|
-
var import_basicInfo = __toESM(require("../basicInfo"));
|
|
40
|
-
var import__ = require("../../index");
|
|
41
|
-
var import_index = require("./index.less");
|
|
42
|
-
var Packages = ({ isShowImage, dataSource = {} }) => {
|
|
43
|
-
const { bundle = [], symbol = "$" } = dataSource;
|
|
44
|
-
return (bundle == null ? void 0 : bundle.length) > 0 ? /* @__PURE__ */ import_react.default.createElement(import_react.default.Fragment, null, /* @__PURE__ */ import_react.default.createElement(import_antd.Divider, { style: { margin: 0 } }), /* @__PURE__ */ import_react.default.createElement("div", { className: `${import__.PREFIX}__packages-wrap` }, /* @__PURE__ */ import_react.default.createElement("div", { className: `packages-title` }, import_utils.locales.getText("pisell2.cart.sku-card.packages.title")), /* @__PURE__ */ import_react.default.createElement(
|
|
45
|
-
import_collapsibleList.default,
|
|
46
|
-
{
|
|
47
|
-
style: {
|
|
48
|
-
marginTop: 4
|
|
49
|
-
},
|
|
50
|
-
list: bundle || [],
|
|
51
|
-
renderItem: (item) => {
|
|
52
|
-
return /* @__PURE__ */ import_react.default.createElement(
|
|
53
|
-
import_basicInfo.default,
|
|
54
|
-
{
|
|
55
|
-
isShowImage,
|
|
56
|
-
dataSource: {
|
|
57
|
-
...item,
|
|
58
|
-
name: item.title,
|
|
59
|
-
image: item.cover,
|
|
60
|
-
symbol
|
|
61
|
-
},
|
|
62
|
-
style: {
|
|
63
|
-
border: "1px solid #D0D5DD",
|
|
64
|
-
borderRadius: 4,
|
|
65
|
-
padding: 4
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
|
-
);
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
))) : null;
|
|
72
|
-
};
|
|
73
|
-
var packages_default = Packages;
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
.pisell-cart-sku-card__packages-wrap {
|
|
2
|
-
padding: 0 4px;
|
|
3
|
-
|
|
4
|
-
.packages-title {
|
|
5
|
-
color: #101828;
|
|
6
|
-
font-size: 12px;
|
|
7
|
-
font-weight: 600;
|
|
8
|
-
line-height: 18px;
|
|
9
|
-
word-wrap: break-word;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
.pisell2-collapsible-list {
|
|
13
|
-
gap: 4px;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.product-info {
|
|
17
|
-
.product-name,
|
|
18
|
-
.product-price {
|
|
19
|
-
color: #667085;
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
}
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @title: 金额是否是负
|
|
3
|
-
* @description:
|
|
4
|
-
* @param {string} type
|
|
5
|
-
* @return {*}
|
|
6
|
-
* @Author: WangHan
|
|
7
|
-
* @Date: 2024-11-22 10:01
|
|
8
|
-
*/
|
|
9
|
-
export declare const minusSign: (item: any, type?: string) => "" | "-";
|
|
10
|
-
/**
|
|
11
|
-
* @title: 金额格式化
|
|
12
|
-
* @description:
|
|
13
|
-
* @param {number} price
|
|
14
|
-
* @param {string} amountSymbol
|
|
15
|
-
* @param {number} digit
|
|
16
|
-
* @return {*}
|
|
17
|
-
* @Author: WangHan
|
|
18
|
-
* @Date: 2024-11-22 10:58
|
|
19
|
-
*/
|
|
20
|
-
export declare const _formatAmount: (price?: number, amountSymbol?: string, digit?: number) => any;
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
-
var __export = (target, all) => {
|
|
6
|
-
for (var name in all)
|
|
7
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
-
};
|
|
9
|
-
var __copyProps = (to, from, except, desc) => {
|
|
10
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
-
for (let key of __getOwnPropNames(from))
|
|
12
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
-
}
|
|
15
|
-
return to;
|
|
16
|
-
};
|
|
17
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
-
|
|
19
|
-
// src/components/productCard/cartSkuCard/components/packages/utils.ts
|
|
20
|
-
var utils_exports = {};
|
|
21
|
-
__export(utils_exports, {
|
|
22
|
-
_formatAmount: () => _formatAmount,
|
|
23
|
-
minusSign: () => minusSign
|
|
24
|
-
});
|
|
25
|
-
module.exports = __toCommonJS(utils_exports);
|
|
26
|
-
var import_utils = require("@pisell/utils");
|
|
27
|
-
var minusSign = (item, type) => {
|
|
28
|
-
if (type === "total") {
|
|
29
|
-
const _price2 = (item == null ? void 0 : item.bundle_sum_price) || 0;
|
|
30
|
-
const isMarkdown2 = (item == null ? void 0 : item.bundle_sum_type) === "markdown";
|
|
31
|
-
return _price2 > 0 && isMarkdown2 ? "-" : "";
|
|
32
|
-
}
|
|
33
|
-
const _price = (item == null ? void 0 : item.price) || 0;
|
|
34
|
-
const isMarkdown = (item == null ? void 0 : item.price_type) === "markdown";
|
|
35
|
-
return _price > 0 && isMarkdown ? "-" : "";
|
|
36
|
-
};
|
|
37
|
-
var _formatAmount = (price = 0, amountSymbol, digit) => {
|
|
38
|
-
return (0, import_utils.formatAmount)(price, digit, amountSymbol);
|
|
39
|
-
};
|
|
40
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
41
|
-
0 && (module.exports = {
|
|
42
|
-
_formatAmount,
|
|
43
|
-
minusSign
|
|
44
|
-
});
|
|
@@ -1,71 +0,0 @@
|
|
|
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/productCard/cartSkuCard/components/resources/index.tsx
|
|
30
|
-
var resources_exports = {};
|
|
31
|
-
__export(resources_exports, {
|
|
32
|
-
default: () => resources_default
|
|
33
|
-
});
|
|
34
|
-
module.exports = __toCommonJS(resources_exports);
|
|
35
|
-
var import_react = __toESM(require("react"));
|
|
36
|
-
var import_antd = require("antd");
|
|
37
|
-
var import_index = require("./index.less");
|
|
38
|
-
var import__ = require("../../index");
|
|
39
|
-
var colors = [
|
|
40
|
-
"magenta",
|
|
41
|
-
"volcano",
|
|
42
|
-
"orange",
|
|
43
|
-
"gold",
|
|
44
|
-
"green",
|
|
45
|
-
"cyan",
|
|
46
|
-
"blue",
|
|
47
|
-
"geekblue",
|
|
48
|
-
"purple"
|
|
49
|
-
];
|
|
50
|
-
function getColor(n) {
|
|
51
|
-
return colors[n * 31 % colors.length];
|
|
52
|
-
}
|
|
53
|
-
var Resources = (props) => {
|
|
54
|
-
const { dataSource = {} } = props;
|
|
55
|
-
const { multiResources, isMultipleResource } = dataSource;
|
|
56
|
-
const renderResourceItem = (item, index) => {
|
|
57
|
-
const { id: ids, lists, _id } = item;
|
|
58
|
-
return Array.isArray(ids) ? ids.map((id) => {
|
|
59
|
-
const targetRes = lists.find((l) => l.id === id);
|
|
60
|
-
if (targetRes == null ? void 0 : targetRes.label) {
|
|
61
|
-
return /* @__PURE__ */ import_react.default.createElement(import_antd.Tag, { color: getColor(_id), className: "resource-tag" }, targetRes.label);
|
|
62
|
-
}
|
|
63
|
-
return null;
|
|
64
|
-
}) : null;
|
|
65
|
-
};
|
|
66
|
-
if (isMultipleResource && (multiResources == null ? void 0 : multiResources.length) > 0) {
|
|
67
|
-
return /* @__PURE__ */ import_react.default.createElement("div", { className: `${import__.PREFIX}__resources` }, multiResources.map(renderResourceItem));
|
|
68
|
-
}
|
|
69
|
-
return null;
|
|
70
|
-
};
|
|
71
|
-
var resources_default = Resources;
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
.pisell-cart-sku-card__resources {
|
|
2
|
-
display: flex;
|
|
3
|
-
flex-wrap: wrap;
|
|
4
|
-
gap: 4px;
|
|
5
|
-
|
|
6
|
-
.resource-item {
|
|
7
|
-
min-width: calc(50% - 2px);
|
|
8
|
-
display: flex;
|
|
9
|
-
flex-wrap: wrap;
|
|
10
|
-
gap: 4px;
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
.resource-tag {
|
|
14
|
-
max-width: 120px;
|
|
15
|
-
overflow: hidden;
|
|
16
|
-
text-overflow: ellipsis;
|
|
17
|
-
margin: 0;
|
|
18
|
-
}
|
|
19
|
-
}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import './index.less';
|
|
2
|
-
interface IProps {
|
|
3
|
-
hideDivider?: boolean;
|
|
4
|
-
dataSource: {
|
|
5
|
-
symbol?: string;
|
|
6
|
-
relation_products?: any[];
|
|
7
|
-
bundle?: any[];
|
|
8
|
-
};
|
|
9
|
-
isShowImage?: boolean;
|
|
10
|
-
}
|
|
11
|
-
declare const Sales: ({ hideDivider, dataSource, isShowImage }: IProps) => JSX.Element | null;
|
|
12
|
-
export default Sales;
|
|
@@ -1,77 +0,0 @@
|
|
|
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/productCard/cartSkuCard/components/sales/index.tsx
|
|
30
|
-
var sales_exports = {};
|
|
31
|
-
__export(sales_exports, {
|
|
32
|
-
default: () => sales_default
|
|
33
|
-
});
|
|
34
|
-
module.exports = __toCommonJS(sales_exports);
|
|
35
|
-
var import_react = __toESM(require("react"));
|
|
36
|
-
var import_antd = require("antd");
|
|
37
|
-
var import_collapsibleList = __toESM(require("../../../components/Packages/components/collapsibleList"));
|
|
38
|
-
var import_basicInfo = __toESM(require("../basicInfo"));
|
|
39
|
-
var import_utils = require("@pisell/utils");
|
|
40
|
-
var import__ = require("../../index");
|
|
41
|
-
var import_index = require("./index.less");
|
|
42
|
-
var Sales = ({ hideDivider, dataSource, isShowImage }) => {
|
|
43
|
-
const { relation_products = [], symbol = "$" } = dataSource || {};
|
|
44
|
-
let other_products = relation_products.map((p) => {
|
|
45
|
-
return {
|
|
46
|
-
...p,
|
|
47
|
-
name: p == null ? void 0 : p.product_title,
|
|
48
|
-
price: p == null ? void 0 : p.payment_price,
|
|
49
|
-
symbol,
|
|
50
|
-
num: p == null ? void 0 : p.product_quantity,
|
|
51
|
-
total: p == null ? void 0 : p.payment_price
|
|
52
|
-
};
|
|
53
|
-
});
|
|
54
|
-
return (other_products == null ? void 0 : other_products.length) > 0 ? /* @__PURE__ */ import_react.default.createElement(import_react.default.Fragment, null, hideDivider ? null : /* @__PURE__ */ import_react.default.createElement(import_antd.Divider, { style: { margin: 0 } }), /* @__PURE__ */ import_react.default.createElement("div", { className: `${import__.PREFIX}_sales-wrap` }, /* @__PURE__ */ import_react.default.createElement("div", { className: `sales-title` }, import_utils.locales.getText("pisell2.cart.sku-card.sales.title")), /* @__PURE__ */ import_react.default.createElement(
|
|
55
|
-
import_collapsibleList.default,
|
|
56
|
-
{
|
|
57
|
-
list: other_products || [],
|
|
58
|
-
renderItem: (item) => {
|
|
59
|
-
return /* @__PURE__ */ import_react.default.createElement(
|
|
60
|
-
import_basicInfo.default,
|
|
61
|
-
{
|
|
62
|
-
isShowImage,
|
|
63
|
-
style: {
|
|
64
|
-
border: "1px solid #D0D5DD",
|
|
65
|
-
borderRadius: 4,
|
|
66
|
-
padding: 4
|
|
67
|
-
},
|
|
68
|
-
dataSource: {
|
|
69
|
-
...item
|
|
70
|
-
}
|
|
71
|
-
}
|
|
72
|
-
);
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
))) : null;
|
|
76
|
-
};
|
|
77
|
-
var sales_default = Sales;
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
.pisell-cart-sku-_sales-wrap {
|
|
2
|
-
padding: 0 4px;
|
|
3
|
-
|
|
4
|
-
._sales-title {
|
|
5
|
-
color: #101828;
|
|
6
|
-
font-size: 12px;
|
|
7
|
-
font-weight: 600;
|
|
8
|
-
line-height: 18px;
|
|
9
|
-
word-wrap: break-word;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
.pisell2-collapsible-list {
|
|
13
|
-
gap: 4px;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.product-info {
|
|
17
|
-
.product-name,
|
|
18
|
-
.product-price {
|
|
19
|
-
color: #667085;
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
}
|
|
@@ -1,66 +0,0 @@
|
|
|
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/productCard/cartSkuCard/components/specs/index.tsx
|
|
30
|
-
var specs_exports = {};
|
|
31
|
-
__export(specs_exports, {
|
|
32
|
-
default: () => specs_default
|
|
33
|
-
});
|
|
34
|
-
module.exports = __toCommonJS(specs_exports);
|
|
35
|
-
var import_react = __toESM(require("react"));
|
|
36
|
-
var import_utils = require("@pisell/utils");
|
|
37
|
-
var import_index = require("./index.less");
|
|
38
|
-
var import__ = require("../../index");
|
|
39
|
-
var Specs = (props) => {
|
|
40
|
-
const { dataSource = {} } = props;
|
|
41
|
-
const { bundle, options, product_option_string, symbol } = dataSource;
|
|
42
|
-
const more = /* @__PURE__ */ import_react.default.createElement(
|
|
43
|
-
"div",
|
|
44
|
-
{
|
|
45
|
-
style: {
|
|
46
|
-
color: "#667085",
|
|
47
|
-
fontSize: 10,
|
|
48
|
-
lineHeight: "10px"
|
|
49
|
-
}
|
|
50
|
-
},
|
|
51
|
-
import_utils.locales.getText("pisell2.cart.sku-card.more")
|
|
52
|
-
);
|
|
53
|
-
if (Array.isArray(bundle) && (bundle == null ? void 0 : bundle.length) > 0) {
|
|
54
|
-
const first = bundle[0];
|
|
55
|
-
return /* @__PURE__ */ import_react.default.createElement("div", { className: `${import__.PREFIX}__specs` }, /* @__PURE__ */ import_react.default.createElement("div", null, first.title), bundle.length > 1 ? more : null);
|
|
56
|
-
}
|
|
57
|
-
if (product_option_string) {
|
|
58
|
-
return /* @__PURE__ */ import_react.default.createElement("div", { className: `${import__.PREFIX}__specs` }, /* @__PURE__ */ import_react.default.createElement("div", null, product_option_string), options.length > 1 ? more : null);
|
|
59
|
-
}
|
|
60
|
-
if (options.length > 0) {
|
|
61
|
-
const first = options[0];
|
|
62
|
-
return /* @__PURE__ */ import_react.default.createElement("div", { className: `${import__.PREFIX}__specs` }, /* @__PURE__ */ import_react.default.createElement("div", { className: "spec-item" }, /* @__PURE__ */ import_react.default.createElement("span", { className: "spec-name" }, first.name), /* @__PURE__ */ import_react.default.createElement("span", { className: "spec-num" }, /* @__PURE__ */ import_react.default.createElement("span", null, symbol, first.price), /* @__PURE__ */ import_react.default.createElement("span", null), "x", /* @__PURE__ */ import_react.default.createElement("span", null, first.num))), options.length > 1 ? more : null);
|
|
63
|
-
}
|
|
64
|
-
return null;
|
|
65
|
-
};
|
|
66
|
-
var specs_default = Specs;
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
.pisell-cart-sku-card__specs {
|
|
2
|
-
user-select: none;
|
|
3
|
-
|
|
4
|
-
color: #667085;
|
|
5
|
-
font-size: 14px;
|
|
6
|
-
font-weight: 400;
|
|
7
|
-
line-height: 20px;
|
|
8
|
-
word-wrap: break-word;
|
|
9
|
-
overflow: hidden;
|
|
10
|
-
|
|
11
|
-
> div {
|
|
12
|
-
overflow: hidden;
|
|
13
|
-
text-overflow: ellipsis;
|
|
14
|
-
white-space: nowrap;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
.spec-item {
|
|
18
|
-
display: flex;
|
|
19
|
-
|
|
20
|
-
.spec-name {
|
|
21
|
-
display: inline-block;
|
|
22
|
-
overflow: hidden;
|
|
23
|
-
text-overflow: ellipsis;
|
|
24
|
-
white-space: nowrap;
|
|
25
|
-
margin-right: 8px;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
.spec-num {
|
|
29
|
-
display: flex;
|
|
30
|
-
gap: 4px;
|
|
31
|
-
align-items: center;
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
}
|