@pisell/materials 2.0.0 → 2.0.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.
@@ -5,7 +5,7 @@ export declare const paginationConfig: {
5
5
  className: string;
6
6
  defaultCurrent: number;
7
7
  showTotal: (total: number, range: [number, number]) => string;
8
- itemRender: (page: number, type: "page" | "next" | "prev" | "jump-prev" | "jump-next", element: React.ReactNode) => React.ReactNode;
8
+ itemRender: (page: number, type: "next" | "page" | "prev" | "jump-prev" | "jump-next", element: React.ReactNode) => React.ReactNode;
9
9
  responsive: boolean;
10
10
  size: string;
11
11
  };
@@ -63,7 +63,7 @@ var BasicTable = function BasicTable(props) {
63
63
  useEffect(function () {
64
64
  // 默认100条每页
65
65
  var _size = formPagination.size || 100;
66
- showSizeChange(formPagination === null || formPagination === void 0 ? void 0 : formPagination.page, _size);
66
+ showSizeChange && showSizeChange(formPagination === null || formPagination === void 0 ? void 0 : formPagination.page, _size);
67
67
  }, [formPagination === null || formPagination === void 0 ? void 0 : formPagination.page, formPagination === null || formPagination === void 0 ? void 0 : formPagination.size]);
68
68
 
69
69
  // 分割数据源
@@ -5,7 +5,7 @@ export declare const paginationConfig: {
5
5
  className: string;
6
6
  defaultCurrent: number;
7
7
  showTotal: (total: number, range: [number, number]) => string;
8
- itemRender: (page: number, type: "page" | "next" | "prev" | "jump-prev" | "jump-next", element: React.ReactNode) => React.ReactNode;
8
+ itemRender: (page: number, type: "next" | "page" | "prev" | "jump-prev" | "jump-next", element: React.ReactNode) => React.ReactNode;
9
9
  responsive: boolean;
10
10
  size: string;
11
11
  };
@@ -65,7 +65,7 @@ var BasicTable = (props) => {
65
65
  );
66
66
  (0, import_react.useEffect)(() => {
67
67
  let _size = formPagination.size || 100;
68
- showSizeChange(formPagination == null ? void 0 : formPagination.page, _size);
68
+ showSizeChange && showSizeChange(formPagination == null ? void 0 : formPagination.page, _size);
69
69
  }, [formPagination == null ? void 0 : formPagination.page, formPagination == null ? void 0 : formPagination.size]);
70
70
  const _dataSource = (0, import_react.useMemo)(() => {
71
71
  let _page = formPagination.page;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pisell/materials",
3
- "version": "2.0.0",
3
+ "version": "2.0.2",
4
4
  "main": "./lib/index.js",
5
5
  "module": "./es/index.js",
6
6
  "types": "./lib/index.d.ts",
@@ -1,9 +0,0 @@
1
- /**
2
- * @title: 格式化导出导入接口地址
3
- * @description:
4
- * @param {string} url
5
- * @return {*}
6
- * @Author: WangHan
7
- * @Date: 2024-09-05 11:39
8
- */
9
- export declare const formatApiUrl: (url: string) => string;
@@ -1,11 +0,0 @@
1
- /**
2
- * @title: 格式化导出导入接口地址
3
- * @description:
4
- * @param {string} url
5
- * @return {*}
6
- * @Author: WangHan
7
- * @Date: 2024-09-05 11:39
8
- */
9
- export var formatApiUrl = function formatApiUrl(url) {
10
- return url || '/shop/form/data';
11
- };
@@ -1,9 +0,0 @@
1
- /**
2
- * @title: 格式化导出导入接口地址
3
- * @description:
4
- * @param {string} url
5
- * @return {*}
6
- * @Author: WangHan
7
- * @Date: 2024-09-05 11:39
8
- */
9
- export declare const formatApiUrl: (url: string) => string;
@@ -1,31 +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/table/Actions/component/ExportImport/utils/index.ts
20
- var utils_exports = {};
21
- __export(utils_exports, {
22
- formatApiUrl: () => formatApiUrl
23
- });
24
- module.exports = __toCommonJS(utils_exports);
25
- var formatApiUrl = (url) => {
26
- return url || "/shop/form/data";
27
- };
28
- // Annotate the CommonJS export names for ESM import in node:
29
- 0 && (module.exports = {
30
- formatApiUrl
31
- });