@pisell/materials 1.0.357 → 1.0.359

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.
@@ -138,7 +138,7 @@ var BasicTable = function BasicTable(props) {
138
138
  expandable: {
139
139
  defaultExpandAllRows: true
140
140
  }
141
- })), total > ((pagination === null || pagination === void 0 ? void 0 : pagination.pageSize) || (pagination === null || pagination === void 0 ? void 0 : (_pagination$pageSizeO = pagination.pageSizeOptions) === null || _pagination$pageSizeO === void 0 ? void 0 : _pagination$pageSizeO[0]) || 10) ? /*#__PURE__*/React.createElement(Form.Item, {
141
+ })), total > ((pagination === null || pagination === void 0 ? void 0 : pagination.pageSize) || (pagination === null || pagination === void 0 ? void 0 : (_pagination$pageSizeO = pagination.pageSizeOptions) === null || _pagination$pageSizeO === void 0 ? void 0 : _pagination$pageSizeO[0]) || 10) || pagination !== null && pagination !== void 0 && pagination.showPagination && total > 10 ? /*#__PURE__*/React.createElement(Form.Item, {
142
142
  name: "pagination"
143
143
  }, /*#__PURE__*/React.createElement(FormPagination, _extends({}, pagination, {
144
144
  showTotal: _showTotal,
@@ -167,7 +167,7 @@ export declare const getSettingKeyArrByMode: ({ filter, columnSetting, dataSourc
167
167
  sort?: SortType | undefined;
168
168
  mode: "" | "localStorage" | "remote";
169
169
  currentViewMode: ModeType;
170
- }) => ("filter_setting" | "column_setting" | "gallery_setting" | "view_mode" | "group_by" | "order_by")[];
170
+ }) => ("view_mode" | "column_setting" | "order_by" | "group_by" | "gallery_setting" | "filter_setting")[];
171
171
  export declare const omit: (obj: Record<string, any>, keys: string[]) => Record<string, any>;
172
172
  export declare const stringify: (obj: Record<string, any>) => string;
173
173
  export {};
@@ -45,7 +45,10 @@ var BasicTable = (props) => {
45
45
  const [filter, setFilter] = (0, import_react.useState)();
46
46
  const [sort, setSort] = (0, import_react.useState)();
47
47
  const form = import_antd.Form.useFormInstance();
48
- const formPagination = import_antd.Form.useWatch("pagination", { form, preserve: true }) || {
48
+ const formPagination = import_antd.Form.useWatch("pagination", {
49
+ form,
50
+ preserve: true
51
+ }) || {
49
52
  page: 1,
50
53
  size: 10
51
54
  };
@@ -144,7 +147,7 @@ var BasicTable = (props) => {
144
147
  defaultExpandAllRows: true
145
148
  }
146
149
  }
147
- ), total > ((pagination == null ? void 0 : pagination.pageSize) || ((_a = pagination == null ? void 0 : pagination.pageSizeOptions) == null ? void 0 : _a[0]) || 10) ? /* @__PURE__ */ import_react.default.createElement(import_antd.Form.Item, { name: "pagination" }, /* @__PURE__ */ import_react.default.createElement(
150
+ ), total > ((pagination == null ? void 0 : pagination.pageSize) || ((_a = pagination == null ? void 0 : pagination.pageSizeOptions) == null ? void 0 : _a[0]) || 10) || (pagination == null ? void 0 : pagination.showPagination) && total > 10 ? /* @__PURE__ */ import_react.default.createElement(import_antd.Form.Item, { name: "pagination" }, /* @__PURE__ */ import_react.default.createElement(
148
151
  import_Pagination.FormPagination,
149
152
  {
150
153
  ...pagination,
@@ -167,7 +167,7 @@ export declare const getSettingKeyArrByMode: ({ filter, columnSetting, dataSourc
167
167
  sort?: SortType | undefined;
168
168
  mode: "" | "localStorage" | "remote";
169
169
  currentViewMode: ModeType;
170
- }) => ("filter_setting" | "column_setting" | "gallery_setting" | "view_mode" | "group_by" | "order_by")[];
170
+ }) => ("view_mode" | "column_setting" | "order_by" | "group_by" | "gallery_setting" | "filter_setting")[];
171
171
  export declare const omit: (obj: Record<string, any>, keys: string[]) => Record<string, any>;
172
172
  export declare const stringify: (obj: Record<string, any>) => string;
173
173
  export {};
@@ -932,6 +932,20 @@ export default {
932
932
  value: 'target => !!target.getProps().getPropValue("pagination")',
933
933
  },
934
934
  },
935
+ {
936
+ name: "pagination.showPagination",
937
+ title: {
938
+ label: "始终显示分页",
939
+ tip: "pagination.showPagination | 当前数据总数大于10 则始终显示分页器",
940
+ },
941
+ propType: "bool",
942
+ setter: "BoolSetter",
943
+ defaultValue: false,
944
+ condition: {
945
+ type: "JSFunction",
946
+ value: 'target => !!target.getProps().getPropValue("pagination")',
947
+ },
948
+ },
935
949
  {
936
950
  name: "pagination.showTotal",
937
951
  title: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pisell/materials",
3
- "version": "1.0.357",
3
+ "version": "1.0.359",
4
4
  "main": "./lib/index.js",
5
5
  "module": "./es/index.js",
6
6
  "types": "./lib/index.d.ts",