@fe-free/core 1.4.19 → 1.4.20

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/CHANGELOG.md CHANGED
@@ -1,5 +1,12 @@
1
1
  # @fe-free/core
2
2
 
3
+ ## 1.4.20
4
+
5
+ ### Patch Changes
6
+
7
+ - feat: crud
8
+ - @fe-free/tool@1.4.20
9
+
3
10
  ## 1.4.19
4
11
 
5
12
  ### Patch Changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fe-free/core",
3
- "version": "1.4.19",
3
+ "version": "1.4.20",
4
4
  "description": "",
5
5
  "main": "./src/index.ts",
6
6
  "author": "",
@@ -36,7 +36,7 @@
36
36
  "react-syntax-highlighter": "^15.5.0",
37
37
  "vanilla-jsoneditor": "^0.23.1",
38
38
  "zustand": "^4.5.4",
39
- "@fe-free/tool": "1.4.19"
39
+ "@fe-free/tool": "1.4.20"
40
40
  },
41
41
  "peerDependencies": {
42
42
  "@ant-design/pro-components": "^2.8.7",
package/src/crud/crud.tsx CHANGED
@@ -1,5 +1,5 @@
1
1
  import type { ActionType } from '@ant-design/pro-components';
2
- import { Button, message, Space } from 'antd';
2
+ import { Button, message } from 'antd';
3
3
  import { isString } from 'lodash-es';
4
4
  import { forwardRef, useCallback, useImperativeHandle, useMemo, useRef } from 'react';
5
5
  import { Link } from 'react-router-dom';
@@ -176,11 +176,11 @@ function CRUDComponent<
176
176
  }
177
177
 
178
178
  return (
179
- <Space>
179
+ <div className="fec-crud-operate-column flex gap-2">
180
180
  {operateColumnProps?.moreOperator && operateColumnProps.moreOperator(record)}
181
181
  {btns}
182
182
  {operateColumnProps?.moreOperatorAfter && operateColumnProps.moreOperatorAfter(record)}
183
- </Space>
183
+ </div>
184
184
  );
185
185
  },
186
186
  };
@@ -259,7 +259,7 @@ function CRUDComponent<
259
259
  });
260
260
 
261
261
  return (
262
- <div className="crud-table">
262
+ <div className="fec-crud">
263
263
  <Table<DataSource>
264
264
  rowKey="id"
265
265
  {...tableProps}
@@ -172,8 +172,8 @@ function CRUDDetail(props: CRUDDetailProps) {
172
172
 
173
173
  return (
174
174
  <div
175
- className={classNames('crud-detail', `crud-detail-action-${action}`, {
176
- 'crud-detail-hide-extra': action === 'read',
175
+ className={classNames('fec-crud-detail', `fec-crud-detail-action-${action}`, {
176
+ 'fec-crud-detail-hide-extra': action === 'read',
177
177
  })}
178
178
  >
179
179
  {detailForm({ readonly: action === 'read' && !!id }, { action })}
@@ -89,7 +89,7 @@ function CRUDOfSimpleComponent(props: CRUDOfSimpleProps, ref: React.ForwardedRef
89
89
  }, [debouncedSearchValue, simpleSearchProps, tableProps.params]);
90
90
 
91
91
  return (
92
- <div className="crud-of-simple">
92
+ <div className="fec-crud-of-simple">
93
93
  <CRUD
94
94
  ref={ref}
95
95
  {...rest}
@@ -1,6 +1,6 @@
1
- .crud-detail {
1
+ .fec-crud-detail {
2
2
  // 查看情况下隐藏 FormItem 的 extra
3
- &.crud-detail-hide-extra {
3
+ &.fec-crud-detail-hide-extra {
4
4
  .ant-form-item {
5
5
  .ant-form-item-extra {
6
6
  display: none;
@@ -9,7 +9,7 @@
9
9
  }
10
10
  }
11
11
 
12
- .crud-of-simple {
12
+ .fec-crud-of-simple {
13
13
  .ant-pro-table-list-toolbar {
14
14
  border-bottom: 1px solid #f0f0f0;
15
15
  }