@pisell/materials 2.2.114 → 2.2.115
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 +144 -165
- package/build/lowcode/render/default/view.css +1 -1
- package/build/lowcode/render/default/view.js +31 -40
- package/build/lowcode/view.css +1 -1
- package/build/lowcode/view.js +36 -45
- package/es/components/batch-editor/index.d.ts +0 -1
- package/es/components/dataSourceComponents/dataSourceTable/hooks/useDataSourceKey.d.ts +2 -2
- package/es/components/dataSourceComponents/fields/Input.Subdomain/index.d.ts +1 -1
- package/es/components/dataSourceComponents/fields/index.d.ts +9 -9
- package/es/components/date-picker/index.d.ts +1 -0
- package/es/components/filter/index.d.ts +0 -1
- package/es/components/page/index.d.ts +1 -0
- package/es/components/pisellText/components/Editable/index.js +130 -0
- package/es/components/pisellText/components/Editable/index.less +40 -0
- package/es/components/pisellText/index.js +2 -0
- package/es/components/productCard/components/Packages/utils.d.ts +1 -1
- package/es/components/select/index.js +4 -2
- package/es/components/sortableList/index.js +2 -1
- package/es/components/table/Actions/component/ExportImport/components/ExportTable/function.js +9 -1
- package/es/components/table/Actions/component/ExportImport/index.js +55 -27
- package/es/components/table/Gallery/components/VirtualGrid/useGapSize.d.ts +2 -2
- package/es/components/table/Table/SelectField/index.d.ts +1 -0
- package/es/components/table/Table/fields/index.d.ts +3 -2
- package/es/components/table/Table/fields/select/filterUtil/index.d.ts +1 -1
- package/es/components/table/Table/fields/text/Show/index.d.ts +0 -1
- package/es/components/table/Table/fields/treeSelect/filterUtil/index.d.ts +1 -1
- package/es/components/table/serve.js +8 -0
- package/es/components/tabs/index.js +9 -0
- package/es/components/walletCard/index.js +51 -40
- package/es/locales/en-US.js +2 -2
- package/es/locales/zh-CN.js +1 -1
- package/es/locales/zh-TW.js +1 -1
- package/es/typings.d.ts +7 -1
- package/es/utils/index.d.ts +1 -1
- package/es/utils/platform.d.ts +1 -1
- package/lib/components/batch-editor/index.d.ts +0 -1
- package/lib/components/dataSourceComponents/dataSourceTable/hooks/useDataSourceKey.d.ts +2 -2
- package/lib/components/dataSourceComponents/fields/Input.Subdomain/index.d.ts +1 -1
- package/lib/components/dataSourceComponents/fields/index.d.ts +9 -9
- package/lib/components/date-picker/index.d.ts +1 -0
- package/lib/components/filter/index.d.ts +0 -1
- package/lib/components/page/index.d.ts +1 -0
- package/lib/components/pisellText/components/Editable/index.js +139 -0
- package/lib/components/pisellText/components/Editable/index.less +40 -0
- package/lib/components/pisellText/index.js +2 -0
- package/lib/components/productCard/components/Packages/utils.d.ts +1 -1
- package/lib/components/select/index.js +7 -2
- package/lib/components/sortableList/index.js +2 -2
- package/lib/components/table/Actions/component/ExportImport/components/ExportTable/function.js +7 -1
- package/lib/components/table/Actions/component/ExportImport/index.js +37 -25
- package/lib/components/table/Gallery/components/VirtualGrid/useGapSize.d.ts +2 -2
- package/lib/components/table/Table/SelectField/index.d.ts +1 -0
- package/lib/components/table/Table/fields/index.d.ts +3 -2
- package/lib/components/table/Table/fields/select/filterUtil/index.d.ts +1 -1
- package/lib/components/table/Table/fields/text/Show/index.d.ts +0 -1
- package/lib/components/table/Table/fields/treeSelect/filterUtil/index.d.ts +1 -1
- package/lib/components/table/serve.js +8 -0
- package/lib/components/tabs/index.js +5 -0
- package/lib/components/walletCard/index.js +47 -29
- package/lib/locales/en-US.js +2 -2
- package/lib/locales/zh-CN.js +1 -1
- package/lib/locales/zh-TW.js +1 -1
- package/lib/typings.d.ts +7 -1
- package/lib/utils/index.d.ts +1 -1
- package/lib/utils/platform.d.ts +1 -1
- package/lowcode/pisell-text.editable/meta.ts +115 -0
- package/lowcode/pisell-text.editable/snippets.ts +15 -0
- package/lowcode/sortable-list/meta.ts +1 -1
- package/lowcode/wallet-card/meta.ts +23 -3
- package/package.json +11 -11
- package/es/components/appVersionControl/index.d.ts +0 -4
- package/es/components/auto-resize-text/auto-text-size-standalone.d.ts +0 -20
- package/es/components/auto-resize-text/index.d.ts +0 -6
- package/es/components/cardPro/index.d.ts +0 -3
- package/es/components/dataSourceComponents/dataSourceForm/utils.d.ts +0 -56
- package/es/components/dataSourceComponents/dataSourceTable/BaseTable.d.ts +0 -8
- package/es/components/dataSourceComponents/dataSourceTable/filter/index.d.ts +0 -28
- package/es/components/dataSourceComponents/dataSourceTable/hooks/useDrawerState.d.ts +0 -38
- package/es/components/dataSourceComponents/dataSourceTable/hooks/useTableProps.d.ts +0 -100
- package/es/components/dataSourceComponents/dataSourceTable/hooks/useTableQuery.d.ts +0 -33
- package/es/components/dataSourceComponents/dataSourceTable/type.d.ts +0 -84
- package/es/components/dataSourceComponents/fields/Input.Mobile/WithMode.d.ts +0 -17
- package/es/components/dataSourceComponents/fields/Input.Mobile/serve.d.ts +0 -24
- package/es/components/dataSourceComponents/fields/Input.Phone/WithMode.d.ts +0 -16
- package/es/components/dataSourceComponents/fields/Input.Phone/serve.d.ts +0 -25
- package/es/components/dataSourceComponents/fields/Upload/BaseUpload.d.ts +0 -5
- package/es/components/dataSourceComponents/fields/Upload/CameraPopover.d.ts +0 -5
- package/es/components/dataSourceComponents/fields/Upload/index.d.ts +0 -3
- package/es/components/dataSourceComponents/fields/Upload/type.d.ts +0 -38
- package/es/components/dataSourceComponents/hooks/usePlatform.d.ts +0 -5
- package/es/components/drag-sort-tree/TreeItem/index.d.ts +0 -18
- package/es/components/drag-sort-tree/index.d.ts +0 -4
- package/es/components/filter/types.d.ts +0 -46
- package/es/components/iconfont/index.d.ts +0 -8
- package/es/components/keyboard/index.d.ts +0 -22
- package/es/components/login-and-register/index.d.ts +0 -82
- package/es/components/pisell-config-provider/context.d.ts +0 -22
- package/es/components/pisell-config-provider/index.d.ts +0 -13
- package/es/components/pisellAdjustPrice/index.d.ts +0 -4
- package/es/components/pisellAdjustPrice/status.d.ts +0 -32
- package/es/components/pisellAdjustPrice/type.d.ts +0 -22
- package/es/components/pisellCamera/index.d.ts +0 -4
- package/es/components/pisellCardList/index.d.ts +0 -103
- package/es/components/pisellCheckboxGroup/index.d.ts +0 -40
- package/es/components/pisellEmpty/index.d.ts +0 -19
- package/es/components/pisellText/components/Amount/index.d.ts +0 -20
- package/es/components/pisellText/index.d.ts +0 -8
- package/es/components/pisellToast/index.d.ts +0 -17
- package/es/components/pisellToast/squareToast/index.d.ts +0 -15
- package/es/components/pisellToast/squareToast/methods.d.ts +0 -13
- package/es/components/pisellToast/squareToast/renderImperatively.d.ts +0 -29
- package/es/components/pisellToast/squareToast/toast.d.ts +0 -25
- package/es/components/pisellWalletPassCard/index.d.ts +0 -136
- package/es/components/productCard/cartSkuCard/components/AmountFooter/index.d.ts +0 -3
- package/es/components/productCard/cartSkuCard/components/MultiDay/index.d.ts +0 -3
- package/es/components/productCard/cartSkuCard/components/MultiDay/utils.d.ts +0 -14
- package/es/components/productCard/cartSkuCard/components/Note/index.d.ts +0 -3
- package/es/components/productCard/cartSkuCard/components/basicInfo/index.d.ts +0 -27
- package/es/components/productCard/cartSkuCard/components/discountReason/index.d.ts +0 -2
- package/es/components/productCard/cartSkuCard/components/holders/index.d.ts +0 -3
- package/es/components/productCard/cartSkuCard/components/packages/index.d.ts +0 -10
- package/es/components/productCard/cartSkuCard/components/packages/utils.d.ts +0 -20
- package/es/components/productCard/cartSkuCard/components/resources/index.d.ts +0 -3
- package/es/components/productCard/cartSkuCard/components/sales/index.d.ts +0 -12
- package/es/components/productCard/cartSkuCard/components/specs/index.d.ts +0 -3
- package/es/components/productCard/cartSkuCard/components/swipeAction/index.d.ts +0 -46
- package/es/components/productCard/cartSkuCard/components/timeRange/index.d.ts +0 -6
- package/es/components/productCard/cartSkuCard/index.d.ts +0 -10
- package/es/components/productCard/cartSkuCard/locales.d.ts +0 -96
- package/es/components/productCard/components/Action/index.d.ts +0 -3
- package/es/components/productCard/components/Header/DeleteButton/index.d.ts +0 -3
- package/es/components/productCard/components/Header/index.d.ts +0 -3
- package/es/components/productCard/components/Sales/index.d.ts +0 -3
- package/es/components/productCard/components/Time/components/SelectHolder/index.d.ts +0 -3
- package/es/components/productCard/components/Time/components/SelectHolderModal/index.d.ts +0 -13
- package/es/components/productCard/components/Time/components/SelectResource/index.d.ts +0 -18
- package/es/components/productCard/components/Time/index.d.ts +0 -3
- package/es/components/productCard/locales.d.ts +0 -84
- package/es/components/select/index.d.ts +0 -9
- package/es/components/sortableList/index.d.ts +0 -11
- package/es/components/table/Actions/component/ExportImport/components/ExportTable/function.d.ts +0 -7
- package/es/components/table/Actions/component/ExportImport/index.d.ts +0 -7
- package/es/components/table/Actions/index.d.ts +0 -17
- package/es/components/table/Gallery/components/GalleryItem/index.d.ts +0 -14
- package/es/components/table/Gallery/index.d.ts +0 -5
- package/es/components/table/Table/AddFieldModal/index.d.ts +0 -4
- package/es/components/table/Table/index.d.ts +0 -4
- package/es/components/table/Table/utils.d.ts +0 -161
- package/es/components/table/hooks/useTableSetting.d.ts +0 -21
- package/es/components/table/hooks/useTransDataSource.d.ts +0 -11
- package/es/components/table/index.d.ts +0 -4
- package/es/components/table/serve.d.ts +0 -13
- package/es/components/table/types.d.ts +0 -268
- package/es/components/tabs/index.d.ts +0 -16
- package/es/components/translation/index.d.ts +0 -14
- package/es/components/versionModal/index.d.ts +0 -23
- package/es/components/virtual-keyboard/Amount/index.d.ts +0 -5
- 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/BaseNumberKeyboard/Presets.d.ts +0 -15
- package/es/components/virtual-keyboard/BaseNumberKeyboard/index.d.ts +0 -25
- package/es/components/virtual-keyboard/Keyboard/index.d.ts +0 -21
- package/es/components/virtual-keyboard/Number/index.d.ts +0 -5
- package/es/components/virtual-keyboard/Number/themeConfig.d.ts +0 -32
- package/es/components/virtual-keyboard/Number/types.d.ts +0 -26
- package/es/components/virtual-keyboard/VirtualKeyInput/index.d.ts +0 -13
- package/es/components/virtual-keyboard/index.d.ts +0 -25
- package/es/components/virtualInput/BaseVirtualInput/index.d.ts +0 -40
- package/es/components/virtualInput/index.d.ts +0 -24
- package/es/components/walletCard/index.d.ts +0 -71
- package/es/index.d.ts +0 -144
- package/es/locales/en-US.d.ts +0 -307
- package/es/locales/zh-CN.d.ts +0 -302
- package/es/locales/zh-TW.d.ts +0 -302
- package/lib/components/appVersionControl/index.d.ts +0 -4
- package/lib/components/auto-resize-text/auto-text-size-standalone.d.ts +0 -20
- package/lib/components/auto-resize-text/index.d.ts +0 -6
- package/lib/components/cardPro/index.d.ts +0 -3
- package/lib/components/dataSourceComponents/dataSourceForm/utils.d.ts +0 -56
- package/lib/components/dataSourceComponents/dataSourceTable/BaseTable.d.ts +0 -8
- package/lib/components/dataSourceComponents/dataSourceTable/filter/index.d.ts +0 -28
- package/lib/components/dataSourceComponents/dataSourceTable/hooks/useDrawerState.d.ts +0 -38
- package/lib/components/dataSourceComponents/dataSourceTable/hooks/useTableProps.d.ts +0 -100
- package/lib/components/dataSourceComponents/dataSourceTable/hooks/useTableQuery.d.ts +0 -33
- package/lib/components/dataSourceComponents/dataSourceTable/type.d.ts +0 -84
- package/lib/components/dataSourceComponents/fields/Input.Mobile/WithMode.d.ts +0 -17
- package/lib/components/dataSourceComponents/fields/Input.Mobile/serve.d.ts +0 -24
- package/lib/components/dataSourceComponents/fields/Input.Phone/WithMode.d.ts +0 -16
- package/lib/components/dataSourceComponents/fields/Input.Phone/serve.d.ts +0 -25
- package/lib/components/dataSourceComponents/fields/Upload/BaseUpload.d.ts +0 -5
- package/lib/components/dataSourceComponents/fields/Upload/CameraPopover.d.ts +0 -5
- package/lib/components/dataSourceComponents/fields/Upload/index.d.ts +0 -3
- package/lib/components/dataSourceComponents/fields/Upload/type.d.ts +0 -38
- package/lib/components/dataSourceComponents/hooks/usePlatform.d.ts +0 -5
- package/lib/components/drag-sort-tree/TreeItem/index.d.ts +0 -18
- package/lib/components/drag-sort-tree/index.d.ts +0 -4
- package/lib/components/filter/types.d.ts +0 -46
- package/lib/components/iconfont/index.d.ts +0 -8
- package/lib/components/keyboard/index.d.ts +0 -22
- package/lib/components/login-and-register/index.d.ts +0 -82
- package/lib/components/pisell-config-provider/context.d.ts +0 -22
- package/lib/components/pisell-config-provider/index.d.ts +0 -13
- package/lib/components/pisellAdjustPrice/index.d.ts +0 -4
- package/lib/components/pisellAdjustPrice/status.d.ts +0 -32
- package/lib/components/pisellAdjustPrice/type.d.ts +0 -22
- package/lib/components/pisellCamera/index.d.ts +0 -4
- package/lib/components/pisellCardList/index.d.ts +0 -103
- package/lib/components/pisellCheckboxGroup/index.d.ts +0 -40
- package/lib/components/pisellEmpty/index.d.ts +0 -19
- package/lib/components/pisellText/components/Amount/index.d.ts +0 -20
- package/lib/components/pisellText/index.d.ts +0 -8
- package/lib/components/pisellToast/index.d.ts +0 -17
- package/lib/components/pisellToast/squareToast/index.d.ts +0 -15
- package/lib/components/pisellToast/squareToast/methods.d.ts +0 -13
- package/lib/components/pisellToast/squareToast/renderImperatively.d.ts +0 -29
- package/lib/components/pisellToast/squareToast/toast.d.ts +0 -25
- package/lib/components/pisellWalletPassCard/index.d.ts +0 -136
- package/lib/components/productCard/cartSkuCard/components/AmountFooter/index.d.ts +0 -3
- package/lib/components/productCard/cartSkuCard/components/MultiDay/index.d.ts +0 -3
- package/lib/components/productCard/cartSkuCard/components/MultiDay/utils.d.ts +0 -14
- package/lib/components/productCard/cartSkuCard/components/Note/index.d.ts +0 -3
- package/lib/components/productCard/cartSkuCard/components/basicInfo/index.d.ts +0 -27
- package/lib/components/productCard/cartSkuCard/components/discountReason/index.d.ts +0 -2
- package/lib/components/productCard/cartSkuCard/components/holders/index.d.ts +0 -3
- package/lib/components/productCard/cartSkuCard/components/packages/index.d.ts +0 -10
- package/lib/components/productCard/cartSkuCard/components/packages/utils.d.ts +0 -20
- package/lib/components/productCard/cartSkuCard/components/resources/index.d.ts +0 -3
- package/lib/components/productCard/cartSkuCard/components/sales/index.d.ts +0 -12
- package/lib/components/productCard/cartSkuCard/components/specs/index.d.ts +0 -3
- package/lib/components/productCard/cartSkuCard/components/swipeAction/index.d.ts +0 -46
- package/lib/components/productCard/cartSkuCard/components/timeRange/index.d.ts +0 -6
- package/lib/components/productCard/cartSkuCard/index.d.ts +0 -10
- package/lib/components/productCard/cartSkuCard/locales.d.ts +0 -96
- package/lib/components/productCard/components/Action/index.d.ts +0 -3
- package/lib/components/productCard/components/Header/DeleteButton/index.d.ts +0 -3
- package/lib/components/productCard/components/Header/index.d.ts +0 -3
- package/lib/components/productCard/components/Sales/index.d.ts +0 -3
- package/lib/components/productCard/components/Time/components/SelectHolder/index.d.ts +0 -3
- package/lib/components/productCard/components/Time/components/SelectHolderModal/index.d.ts +0 -13
- package/lib/components/productCard/components/Time/components/SelectResource/index.d.ts +0 -18
- package/lib/components/productCard/components/Time/index.d.ts +0 -3
- package/lib/components/productCard/locales.d.ts +0 -84
- package/lib/components/select/index.d.ts +0 -9
- package/lib/components/sortableList/index.d.ts +0 -11
- package/lib/components/table/Actions/component/ExportImport/components/ExportTable/function.d.ts +0 -7
- package/lib/components/table/Actions/component/ExportImport/index.d.ts +0 -7
- package/lib/components/table/Actions/index.d.ts +0 -17
- package/lib/components/table/Gallery/components/GalleryItem/index.d.ts +0 -14
- package/lib/components/table/Gallery/index.d.ts +0 -5
- package/lib/components/table/Table/AddFieldModal/index.d.ts +0 -4
- package/lib/components/table/Table/index.d.ts +0 -4
- package/lib/components/table/Table/utils.d.ts +0 -161
- package/lib/components/table/hooks/useTableSetting.d.ts +0 -21
- package/lib/components/table/hooks/useTransDataSource.d.ts +0 -11
- package/lib/components/table/index.d.ts +0 -4
- package/lib/components/table/serve.d.ts +0 -13
- package/lib/components/table/types.d.ts +0 -268
- package/lib/components/tabs/index.d.ts +0 -16
- package/lib/components/translation/index.d.ts +0 -14
- package/lib/components/versionModal/index.d.ts +0 -23
- package/lib/components/virtual-keyboard/Amount/index.d.ts +0 -5
- 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/BaseNumberKeyboard/Presets.d.ts +0 -15
- package/lib/components/virtual-keyboard/BaseNumberKeyboard/index.d.ts +0 -25
- package/lib/components/virtual-keyboard/Keyboard/index.d.ts +0 -21
- package/lib/components/virtual-keyboard/Number/index.d.ts +0 -5
- package/lib/components/virtual-keyboard/Number/themeConfig.d.ts +0 -32
- package/lib/components/virtual-keyboard/Number/types.d.ts +0 -26
- package/lib/components/virtual-keyboard/VirtualKeyInput/index.d.ts +0 -13
- package/lib/components/virtual-keyboard/index.d.ts +0 -25
- package/lib/components/virtualInput/BaseVirtualInput/index.d.ts +0 -40
- package/lib/components/virtualInput/index.d.ts +0 -24
- package/lib/components/walletCard/index.d.ts +0 -71
- package/lib/index.d.ts +0 -144
- package/lib/locales/en-US.d.ts +0 -307
- package/lib/locales/zh-CN.d.ts +0 -302
- package/lib/locales/zh-TW.d.ts +0 -302
|
@@ -64,6 +64,7 @@ var ExportImport = ({ exportImport }) => {
|
|
|
64
64
|
const [type, setType] = (0, import_react.useState)(import_status.defaultOptions.exportType);
|
|
65
65
|
const [value, setValue] = (0, import_react.useState)("");
|
|
66
66
|
const [errorStatus, setErrorStatus] = (0, import_react.useState)();
|
|
67
|
+
const [loading, setLoading] = (0, import_react.useState)(false);
|
|
67
68
|
const { state } = (0, import_hooks.useSharedState)(import_model.Context);
|
|
68
69
|
const { originResultDataSource, currentDataSource } = state;
|
|
69
70
|
const context = (0, import_useEngineContext.default)();
|
|
@@ -143,33 +144,43 @@ var ExportImport = ({ exportImport }) => {
|
|
|
143
144
|
});
|
|
144
145
|
const onOk = async () => {
|
|
145
146
|
const { apiUrl, otherParams } = exportImport;
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
147
|
+
setLoading(true);
|
|
148
|
+
try {
|
|
149
|
+
if (value === import_status.defaultOptions.exportValue) {
|
|
150
|
+
const _params = {
|
|
151
|
+
type,
|
|
152
|
+
originDataSource: originResultDataSource,
|
|
153
|
+
currentDataSource
|
|
154
|
+
};
|
|
155
|
+
const result = await (0, import_function.batchExport)(_params, exportImport);
|
|
156
|
+
if (result) {
|
|
157
|
+
onCancel();
|
|
158
|
+
}
|
|
159
|
+
} else if (value === import_status.defaultOptions.importValue) {
|
|
160
|
+
const formData = new FormData();
|
|
161
|
+
formData.append("file", file);
|
|
162
|
+
const formId = otherParams == null ? void 0 : otherParams.form_id;
|
|
163
|
+
const formCode = otherParams == null ? void 0 : otherParams.code;
|
|
164
|
+
if (formId) {
|
|
165
|
+
formData.append("form_id", formId);
|
|
166
|
+
}
|
|
167
|
+
if (formCode) {
|
|
168
|
+
formData.append("code", formCode);
|
|
169
|
+
}
|
|
170
|
+
formData.append("url", (apiUrl == null ? void 0 : apiUrl.import) || "");
|
|
171
|
+
if (otherParams.import) {
|
|
172
|
+
Object.entries(otherParams.import).forEach(([key, value2]) => {
|
|
173
|
+
formData.append(key, value2);
|
|
174
|
+
});
|
|
175
|
+
}
|
|
176
|
+
if (formData) {
|
|
177
|
+
import_antd.message.loading({ content: "Loading...", key: value });
|
|
178
|
+
await _batchImport.run(formData);
|
|
179
|
+
}
|
|
171
180
|
}
|
|
181
|
+
} catch (error) {
|
|
172
182
|
}
|
|
183
|
+
setLoading(false);
|
|
173
184
|
};
|
|
174
185
|
return /* @__PURE__ */ import_react.default.createElement(import_react.default.Fragment, null, /* @__PURE__ */ import_react.default.createElement(
|
|
175
186
|
import_antd.Dropdown,
|
|
@@ -197,6 +208,7 @@ var ExportImport = ({ exportImport }) => {
|
|
|
197
208
|
onOk,
|
|
198
209
|
cancelText: (0, import_locales.getText)("table-action-export-import-cancel"),
|
|
199
210
|
okButtonProps: {
|
|
211
|
+
loading,
|
|
200
212
|
disabled: value === import_status.defaultOptions.importValue && (!file || !!errorStatus)
|
|
201
213
|
}
|
|
202
214
|
},
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
1
2
|
export declare const fieldMaps: {
|
|
2
3
|
text: {
|
|
3
4
|
field: {
|
|
@@ -197,12 +198,12 @@ export declare const fieldList: ({
|
|
|
197
198
|
field_icon: string;
|
|
198
199
|
field_name: string;
|
|
199
200
|
field_type: string;
|
|
200
|
-
default_value:
|
|
201
|
+
default_value: string;
|
|
201
202
|
} | {
|
|
202
203
|
field_icon: string;
|
|
203
204
|
field_name: string;
|
|
204
205
|
field_type: string;
|
|
205
|
-
default_value:
|
|
206
|
+
default_value: boolean;
|
|
206
207
|
} | {
|
|
207
208
|
field_icon: string;
|
|
208
209
|
field_name: string;
|
|
@@ -35,6 +35,14 @@ var defaultUrl = {
|
|
|
35
35
|
template: "/shop/form/data/download-template"
|
|
36
36
|
};
|
|
37
37
|
var formatApiParams = (params, type) => {
|
|
38
|
+
if (params instanceof FormData) {
|
|
39
|
+
let url = params.get("url");
|
|
40
|
+
params.delete("url");
|
|
41
|
+
return {
|
|
42
|
+
url: url || (defaultUrl == null ? void 0 : defaultUrl[type]),
|
|
43
|
+
params
|
|
44
|
+
};
|
|
45
|
+
}
|
|
38
46
|
const _url = (params == null ? void 0 : params.url) || (defaultUrl == null ? void 0 : defaultUrl[type]);
|
|
39
47
|
let _params = { ...params };
|
|
40
48
|
delete _params.url;
|
|
@@ -46,6 +46,11 @@ var Tabs = class extends import_react.Component {
|
|
|
46
46
|
componentDidMount() {
|
|
47
47
|
document.body.id = "body";
|
|
48
48
|
}
|
|
49
|
+
componentDidUpdate(prevProps) {
|
|
50
|
+
if (prevProps.activeKey !== this.props.activeKey) {
|
|
51
|
+
this.setState({ activeKey: this.props.activeKey });
|
|
52
|
+
}
|
|
53
|
+
}
|
|
49
54
|
_handleChange = (key) => {
|
|
50
55
|
this.setActiveKey(key);
|
|
51
56
|
};
|
|
@@ -53,7 +53,7 @@ var DEFAULT_PROPS = {
|
|
|
53
53
|
showWalletName: true,
|
|
54
54
|
shopName: "Store name",
|
|
55
55
|
showShopName: true,
|
|
56
|
-
cardNo: "
|
|
56
|
+
cardNo: "WL0000000001",
|
|
57
57
|
cardStyle: "normal",
|
|
58
58
|
codeType: "barCode",
|
|
59
59
|
platform: "pc",
|
|
@@ -64,24 +64,44 @@ var DEFAULT_PROPS = {
|
|
|
64
64
|
isLogin: true,
|
|
65
65
|
items: [
|
|
66
66
|
{
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
67
|
+
type: "rechargeable",
|
|
68
|
+
display: 1,
|
|
69
|
+
custom_title: {
|
|
70
|
+
original: "Balance",
|
|
71
|
+
"zh-CN": "充值卡",
|
|
72
|
+
"zh-HK": "充值卡",
|
|
73
|
+
en: "Balance"
|
|
74
|
+
}
|
|
70
75
|
},
|
|
71
76
|
{
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
77
|
+
type: "point",
|
|
78
|
+
display: 1,
|
|
79
|
+
custom_title: {
|
|
80
|
+
original: "Points",
|
|
81
|
+
"zh-CN": "积分卡",
|
|
82
|
+
"zh-HK": "積分卡",
|
|
83
|
+
en: "Points"
|
|
84
|
+
}
|
|
75
85
|
},
|
|
76
86
|
{
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
87
|
+
type: "voucher",
|
|
88
|
+
display: 1,
|
|
89
|
+
custom_title: {
|
|
90
|
+
original: "Voucher",
|
|
91
|
+
"zh-CN": "代金券",
|
|
92
|
+
"zh-HK": "代金券",
|
|
93
|
+
en: "Voucher"
|
|
94
|
+
}
|
|
80
95
|
},
|
|
81
96
|
{
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
97
|
+
type: "discount",
|
|
98
|
+
display: 1,
|
|
99
|
+
custom_title: {
|
|
100
|
+
original: "Discount",
|
|
101
|
+
"zh-CN": "折扣卡",
|
|
102
|
+
"zh-HK": "折扣卡",
|
|
103
|
+
en: "Discount"
|
|
104
|
+
}
|
|
85
105
|
}
|
|
86
106
|
]
|
|
87
107
|
};
|
|
@@ -101,7 +121,7 @@ var useCodeModal = (cardNo, onCodeClick, codeType) => {
|
|
|
101
121
|
e.stopPropagation();
|
|
102
122
|
if ((_b = (_a2 = interaction == null ? void 0 : interaction.utils) == null ? void 0 : _a2.isAppEnv) == null ? void 0 : _b.call(_a2)) {
|
|
103
123
|
const typeMap = {
|
|
104
|
-
|
|
124
|
+
qrCode: "qrCode",
|
|
105
125
|
barCode: "barCode"
|
|
106
126
|
};
|
|
107
127
|
(_d = (_c = interaction == null ? void 0 : interaction.utils) == null ? void 0 : _c.postMessageToApp) == null ? void 0 : _d.call(_c, {
|
|
@@ -188,8 +208,12 @@ var CardHeader = ({
|
|
|
188
208
|
)));
|
|
189
209
|
};
|
|
190
210
|
var CardItem = ({ item, symbol }) => {
|
|
191
|
-
|
|
192
|
-
|
|
211
|
+
var _a;
|
|
212
|
+
const { type, custom_title, value } = item;
|
|
213
|
+
const context = (0, import_useEngineContext.default)();
|
|
214
|
+
const utils = (_a = context == null ? void 0 : context.appHelper) == null ? void 0 : _a.utils;
|
|
215
|
+
const translationOriginal = (utils == null ? void 0 : utils.translationOriginal) || (utils == null ? void 0 : utils.translation);
|
|
216
|
+
return /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-wallet-card-item" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-wallet-card-item-label" }, translationOriginal(custom_title || "") || ""), /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-wallet-card-item-value" }, type === "rechargeable" ? /* @__PURE__ */ import_react.default.createElement(
|
|
193
217
|
import_Amount.default,
|
|
194
218
|
{
|
|
195
219
|
className: "pisell-card-amount-item-value",
|
|
@@ -199,27 +223,19 @@ var CardItem = ({ item, symbol }) => {
|
|
|
199
223
|
showCurrencySymbol: true,
|
|
200
224
|
value
|
|
201
225
|
}
|
|
202
|
-
) : value));
|
|
226
|
+
) : value || "0"));
|
|
203
227
|
};
|
|
204
228
|
var CardContent = ({ items, symbol }) => {
|
|
205
|
-
const
|
|
206
|
-
const sortedItems = (0, import_react.useMemo)(() => {
|
|
207
|
-
if (!(items == null ? void 0 : items.length)) return [];
|
|
208
|
-
return [...items].sort((a, b) => {
|
|
209
|
-
const indexA = expectedOrder.indexOf(a.key);
|
|
210
|
-
const indexB = expectedOrder.indexOf(b.key);
|
|
211
|
-
return indexA - indexB;
|
|
212
|
-
});
|
|
213
|
-
}, [items]);
|
|
229
|
+
const filteredItems = (items || []).filter((item) => item.display !== 0);
|
|
214
230
|
return /* @__PURE__ */ import_react.default.createElement(
|
|
215
231
|
"div",
|
|
216
232
|
{
|
|
217
233
|
className: "pisell-wallet-card-list",
|
|
218
234
|
style: {
|
|
219
|
-
justifyContent:
|
|
235
|
+
justifyContent: filteredItems.length > 1 ? "space-between" : "flex-start"
|
|
220
236
|
}
|
|
221
237
|
},
|
|
222
|
-
|
|
238
|
+
filteredItems.map((item, index) => /* @__PURE__ */ import_react.default.createElement(CardItem, { key: index, item, symbol }))
|
|
223
239
|
);
|
|
224
240
|
};
|
|
225
241
|
var CodeDisplay = ({ codeType, cardNo }) => {
|
|
@@ -336,7 +352,9 @@ var WalletCard = (props) => {
|
|
|
336
352
|
}
|
|
337
353
|
utils == null ? void 0 : utils.action({
|
|
338
354
|
type: "pisell1.goWallet",
|
|
339
|
-
data: {
|
|
355
|
+
data: {
|
|
356
|
+
id: props.id
|
|
357
|
+
},
|
|
340
358
|
callback: () => {
|
|
341
359
|
}
|
|
342
360
|
});
|
package/lib/locales/en-US.js
CHANGED
|
@@ -168,7 +168,7 @@ var en_US_default = {
|
|
|
168
168
|
"pisell-adjust-price-total-after-discount": "Total after discount: ",
|
|
169
169
|
"pisell-adjust-price-discount-can-be-maximum": "Discount can be maximum",
|
|
170
170
|
"pisell-discount-card-title": "Discount",
|
|
171
|
-
"pisell-discount-card-unit": "
|
|
171
|
+
"pisell-discount-card-unit": "OFF",
|
|
172
172
|
"pisell-discount-card-fixed-amount-prefix": "Save",
|
|
173
173
|
// 数据源表格
|
|
174
174
|
"pisell-data-source-table-add": "Add",
|
|
@@ -215,7 +215,7 @@ var en_US_default = {
|
|
|
215
215
|
"pisell-action-get-data": "Please get data first",
|
|
216
216
|
"pisell-action-delete-success": "Deleted successfully",
|
|
217
217
|
"pisell-action-delete-failed": "Delete failed, please try again",
|
|
218
|
-
"walletCard-
|
|
218
|
+
"walletCard-point": "Points",
|
|
219
219
|
"walletCard-rechargeable": "Balance",
|
|
220
220
|
"walletCard-voucher": "Voucher",
|
|
221
221
|
"walletCard-discount": "Discount",
|
package/lib/locales/zh-CN.js
CHANGED
|
@@ -214,7 +214,7 @@ var zh_CN_default = {
|
|
|
214
214
|
"pisell-action-get-data": "请先获取数据",
|
|
215
215
|
"pisell-action-delete-success": "删除成功",
|
|
216
216
|
"pisell-action-delete-failed": "删除失败,请重试",
|
|
217
|
-
"walletCard-
|
|
217
|
+
"walletCard-point": "积分",
|
|
218
218
|
"walletCard-rechargeable": "余额",
|
|
219
219
|
"walletCard-voucher": "代金券",
|
|
220
220
|
"walletCard-discount": "折扣卡",
|
package/lib/locales/zh-TW.js
CHANGED
|
@@ -214,7 +214,7 @@ var zh_TW_default = {
|
|
|
214
214
|
"pisell-action-get-data": "請先獲取數據",
|
|
215
215
|
"pisell-action-delete-success": "刪除成功",
|
|
216
216
|
"pisell-action-delete-failed": "刪除失敗,請重試",
|
|
217
|
-
"walletCard-
|
|
217
|
+
"walletCard-point": "積分",
|
|
218
218
|
"walletCard-rechargeable": "餘額",
|
|
219
219
|
"walletCard-voucher": "代金券",
|
|
220
220
|
"walletCard-discount": "折扣卡",
|
package/lib/typings.d.ts
CHANGED
package/lib/utils/index.d.ts
CHANGED
package/lib/utils/platform.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const isMobile: () =>
|
|
1
|
+
export declare const isMobile: () => any;
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
import snippets from './snippets';
|
|
2
|
+
|
|
3
|
+
export default {
|
|
4
|
+
snippets,
|
|
5
|
+
componentName: 'PisellText.Editable',
|
|
6
|
+
title: '可编辑文本',
|
|
7
|
+
category: '数据输入',
|
|
8
|
+
docUrl: '',
|
|
9
|
+
screenshot: '',
|
|
10
|
+
devMode: 'proCode',
|
|
11
|
+
npm: {
|
|
12
|
+
package: '@pisell/materials',
|
|
13
|
+
version: '1.0.1',
|
|
14
|
+
exportName: 'PisellText',
|
|
15
|
+
main: 'src/index.tsx',
|
|
16
|
+
destructuring: true,
|
|
17
|
+
subName: 'Editable',
|
|
18
|
+
},
|
|
19
|
+
props: [
|
|
20
|
+
{
|
|
21
|
+
name: 'value',
|
|
22
|
+
title: {
|
|
23
|
+
label: '文本内容',
|
|
24
|
+
tip: '文本内容,支持字符串或多语言对象'
|
|
25
|
+
},
|
|
26
|
+
propType: {
|
|
27
|
+
type: 'oneOfType',
|
|
28
|
+
value: ['string', 'object']
|
|
29
|
+
},
|
|
30
|
+
setter: {
|
|
31
|
+
componentName: 'MixedSetter',
|
|
32
|
+
props: {
|
|
33
|
+
setters: [
|
|
34
|
+
'StringSetter',
|
|
35
|
+
'JsonSetter'
|
|
36
|
+
]
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
name: 'editable',
|
|
42
|
+
title: {
|
|
43
|
+
label: '启用编辑',
|
|
44
|
+
tip: '启用编辑功能,支持布尔值或详细配置对象',
|
|
45
|
+
},
|
|
46
|
+
propType: {
|
|
47
|
+
type: 'oneOfType',
|
|
48
|
+
value: ['bool', 'object']
|
|
49
|
+
},
|
|
50
|
+
setter: {
|
|
51
|
+
componentName: 'MixedSetter',
|
|
52
|
+
props: {
|
|
53
|
+
setters: [
|
|
54
|
+
'BoolSetter',
|
|
55
|
+
{
|
|
56
|
+
componentName: 'ObjectSetter',
|
|
57
|
+
props: {
|
|
58
|
+
config: {
|
|
59
|
+
items: [
|
|
60
|
+
{
|
|
61
|
+
name: 'disabled',
|
|
62
|
+
title: { label: '禁用编辑', tip: '是否禁用编辑功能' },
|
|
63
|
+
propType: 'bool',
|
|
64
|
+
setter: 'BoolSetter',
|
|
65
|
+
defaultValue: false,
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
name: 'maxLength',
|
|
69
|
+
title: { label: '最大长度', tip: '编辑时的最大字符长度' },
|
|
70
|
+
propType: 'number',
|
|
71
|
+
setter: 'NumberSetter',
|
|
72
|
+
}
|
|
73
|
+
]
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
]
|
|
78
|
+
}
|
|
79
|
+
},
|
|
80
|
+
defaultValue: false,
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
name: 'size',
|
|
84
|
+
title: { label: '尺寸', tip: '输入框尺寸' },
|
|
85
|
+
propType: { type: 'oneOf', value: ['large', 'middle', 'small'] },
|
|
86
|
+
setter: [
|
|
87
|
+
{
|
|
88
|
+
componentName: 'RadioGroupSetter',
|
|
89
|
+
props: {
|
|
90
|
+
options: [
|
|
91
|
+
{ title: 'Large', value: 'large' },
|
|
92
|
+
{ title: 'Middle', value: 'middle' },
|
|
93
|
+
{ title: 'Small', value: 'small' },
|
|
94
|
+
]
|
|
95
|
+
}
|
|
96
|
+
},
|
|
97
|
+
'VariableSetter'
|
|
98
|
+
],
|
|
99
|
+
defaultValue: 'middle',
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
name: 'className',
|
|
103
|
+
title: { label: '类名', tip: '自定义CSS类名' },
|
|
104
|
+
propType: 'string',
|
|
105
|
+
setter: 'StringSetter',
|
|
106
|
+
},
|
|
107
|
+
],
|
|
108
|
+
configure: {
|
|
109
|
+
supports: {
|
|
110
|
+
style: true,
|
|
111
|
+
className: true,
|
|
112
|
+
events: ['onChange'],
|
|
113
|
+
}
|
|
114
|
+
},
|
|
115
|
+
};
|
|
@@ -220,8 +220,8 @@ export default {
|
|
|
220
220
|
'zh-CN': '是否显示二维码/条形码图标。类型: boolean',
|
|
221
221
|
},
|
|
222
222
|
},
|
|
223
|
-
setter:
|
|
224
|
-
defaultValue: true
|
|
223
|
+
setter: "BoolSetter",
|
|
224
|
+
defaultValue: true
|
|
225
225
|
},
|
|
226
226
|
{
|
|
227
227
|
name: 'showViewPin',
|
|
@@ -241,7 +241,27 @@ export default {
|
|
|
241
241
|
setter: 'BoolSetter',
|
|
242
242
|
defaultValue: false,
|
|
243
243
|
},
|
|
244
|
-
|
|
244
|
+
{
|
|
245
|
+
name: "codeType",
|
|
246
|
+
title: {
|
|
247
|
+
label: {
|
|
248
|
+
type: 'i18n',
|
|
249
|
+
'en-US': 'Code Type',
|
|
250
|
+
'zh-CN': '条码类型'
|
|
251
|
+
},
|
|
252
|
+
},
|
|
253
|
+
setter: {
|
|
254
|
+
componentName: 'RadioGroupSetter',
|
|
255
|
+
props: {
|
|
256
|
+
options: [
|
|
257
|
+
{ title: '条形码', value: 'barCode' },
|
|
258
|
+
{ title: '二维码', value: 'qrCode' },
|
|
259
|
+
],
|
|
260
|
+
},
|
|
261
|
+
},
|
|
262
|
+
defaultValue: 'qrCode',
|
|
263
|
+
}
|
|
264
|
+
]
|
|
245
265
|
},
|
|
246
266
|
{
|
|
247
267
|
name: 'guest',
|
package/package.json
CHANGED
|
@@ -1,12 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pisell/materials",
|
|
3
|
-
"version": "2.2.
|
|
4
|
-
"scripts": {
|
|
5
|
-
"dev": "father dev",
|
|
6
|
-
"build": "father build",
|
|
7
|
-
"lowcode:dev": "build-scripts start --config ./build.lowcode.js",
|
|
8
|
-
"lowcode:build": " build-scripts build --config ./build.lowcode.js"
|
|
9
|
-
},
|
|
3
|
+
"version": "2.2.115",
|
|
10
4
|
"main": "./lib/index.js",
|
|
11
5
|
"module": "./es/index.js",
|
|
12
6
|
"types": "./lib/index.d.ts",
|
|
@@ -61,9 +55,6 @@
|
|
|
61
55
|
"@dnd-kit/modifiers": "^6.0.1",
|
|
62
56
|
"@dnd-kit/sortable": "^7.0.2",
|
|
63
57
|
"@dnd-kit/utilities": "^3.2.1",
|
|
64
|
-
"@pisell/date-picker": "workspace:*",
|
|
65
|
-
"@pisell/icon": "workspace:*",
|
|
66
|
-
"@pisell/utils": "workspace:*",
|
|
67
58
|
"@react-spring/web": "^9.6.1",
|
|
68
59
|
"@use-gesture/react": "^10.3.1",
|
|
69
60
|
"@zxing/library": "0.21.2",
|
|
@@ -83,7 +74,10 @@
|
|
|
83
74
|
"swiper": "^8.4.7",
|
|
84
75
|
"antd-mobile": "^5.38.1",
|
|
85
76
|
"vod-js-sdk-v6": "^1.4.11",
|
|
86
|
-
"react-camera-pro": "1.4.0"
|
|
77
|
+
"react-camera-pro": "1.4.0",
|
|
78
|
+
"@pisell/date-picker": "1.0.102",
|
|
79
|
+
"@pisell/icon": "0.0.11",
|
|
80
|
+
"@pisell/utils": "2.0.2"
|
|
87
81
|
},
|
|
88
82
|
"peerDependencies": {
|
|
89
83
|
"react": "^18.0.0",
|
|
@@ -91,5 +85,11 @@
|
|
|
91
85
|
},
|
|
92
86
|
"componentConfig": {
|
|
93
87
|
"materialSchema": "https://unpkg.com/@pisell/materials@1.0.1/build/lowcode/assets-prod.json"
|
|
88
|
+
},
|
|
89
|
+
"scripts": {
|
|
90
|
+
"dev": "father dev",
|
|
91
|
+
"build": "father build",
|
|
92
|
+
"lowcode:dev": "build-scripts start --config ./build.lowcode.js",
|
|
93
|
+
"lowcode:build": " build-scripts build --config ./build.lowcode.js"
|
|
94
94
|
}
|
|
95
95
|
}
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
export declare type Options = {
|
|
2
|
-
mode?: 'oneline' | 'multiline' | 'box' | 'boxoneline' | undefined;
|
|
3
|
-
minFontSizePx?: number | undefined;
|
|
4
|
-
maxFontSizePx?: number | undefined;
|
|
5
|
-
fontSizePrecisionPx?: number | undefined;
|
|
6
|
-
scrollToEnd?: boolean | undefined;
|
|
7
|
-
};
|
|
8
|
-
export declare function updateTextSize({ innerEl, containerEl, mode, minFontSizePx, maxFontSizePx, fontSizePrecisionPx, scrollToEnd, }: Options & {
|
|
9
|
-
innerEl: HTMLElement;
|
|
10
|
-
containerEl: HTMLElement;
|
|
11
|
-
}): void;
|
|
12
|
-
declare type DisconnectableFunction = {
|
|
13
|
-
(): void;
|
|
14
|
-
disconnect: () => void;
|
|
15
|
-
};
|
|
16
|
-
export declare function autoTextSize({ innerEl, containerEl, mode, minFontSizePx, maxFontSizePx, fontSizePrecisionPx, scrollToEnd, }: Options & {
|
|
17
|
-
innerEl: HTMLElement;
|
|
18
|
-
containerEl: HTMLElement;
|
|
19
|
-
}): DisconnectableFunction;
|
|
20
|
-
export {};
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import React, { DetailedHTMLProps, HTMLAttributes, ReactElement, ReactHTML } from 'react';
|
|
2
|
-
import { Options } from './auto-text-size-standalone';
|
|
3
|
-
export default function AutoResizeText({ mode, minFontSizePx, maxFontSizePx, fontSizePrecisionPx, scrollToEnd, as: Comp, children, ...rest }: Options & {
|
|
4
|
-
as?: keyof ReactHTML | React.ComponentType<any>;
|
|
5
|
-
children?: React.ReactNode;
|
|
6
|
-
} & DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>): ReactElement;
|