fan-standard-comp 3.1.0 → 3.1.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.
Files changed (126) hide show
  1. package/dist/fan-standard-comp.umd.js +293 -285
  2. package/es/ButtonGroup/ButtonList.js +18 -36
  3. package/es/ButtonGroup/ButtonMenu.js +14 -27
  4. package/es/ButtonGroup/PopConfirmTitle.js +5 -16
  5. package/es/ButtonGroup/index.js +76 -107
  6. package/es/DragContent/DragBar.js +6 -18
  7. package/es/DragContent/index.js +12 -30
  8. package/es/FormComp/ChunkUploader/api.js +8 -21
  9. package/es/FormComp/ChunkUploader/index.js +27 -46
  10. package/es/FormComp/ChunkUploader/lib.js +9 -26
  11. package/es/FormComp/ChunkUploader/upload-queue.class.js +5 -12
  12. package/es/FormComp/ChunkUploader/worker.js +2 -7
  13. package/es/FormComp/EditButton/index.js +16 -35
  14. package/es/FormComp/FieldComponent/ReUpload.js +18 -38
  15. package/es/FormComp/FieldComponent/RefactorTreeSelect.js +26 -49
  16. package/es/FormComp/FieldComponent/TitleNode.js +3 -13
  17. package/es/FormComp/FieldComponent/index.js +87 -131
  18. package/es/FormComp/FieldComponent/setReadonlyValues.js +34 -61
  19. package/es/FormComp/RenderItemGroup/index.js +34 -56
  20. package/es/FormComp/Uploader/index.js +38 -64
  21. package/es/FormComp/Uploader/util.js +2 -11
  22. package/es/FormComp/VarTemplate/index.js +31 -44
  23. package/es/FormComp/index.js +1 -15
  24. package/es/NavLeafScroll/index.js +35 -53
  25. package/es/RefactorTree/index.js +29 -52
  26. package/es/RefactorTree/indexTreeNode.js +31 -54
  27. package/es/RefactorTree/style/index.js +1 -3
  28. package/es/RefactorTree/util.js +10 -18
  29. package/es/SpecIcon/fonts/iconfont.js +0 -2
  30. package/es/SpecIcon/index.js +17 -30
  31. package/es/SplitterLayout/Pane.js +5 -17
  32. package/es/SplitterLayout/index.js +13 -24
  33. package/es/StandardContent/SplitterLayout/Pane.js +13 -25
  34. package/es/StandardContent/SplitterLayout/index.js +30 -43
  35. package/es/StandardContent/SubfieldContent.js +13 -28
  36. package/es/StandardContent/WrapperContent.js +10 -24
  37. package/es/StandardDragModal/index.d.ts +11 -0
  38. package/es/StandardDragModal/index.js +30 -0
  39. package/es/StandardFilter/index.js +27 -46
  40. package/es/StandardForm/ActionList.js +8 -21
  41. package/es/StandardForm/StepForm.js +40 -68
  42. package/es/StandardForm/TabForm.js +26 -52
  43. package/es/StandardForm/index.js +28 -55
  44. package/es/StandardModal/UpdateFormRef.js +4 -18
  45. package/es/StandardModal/index.d.ts +3 -0
  46. package/es/StandardModal/index.js +118 -119
  47. package/es/StandardPanel/index.js +32 -53
  48. package/es/StandardTable/index.js +17 -44
  49. package/es/StandardTable/style/index.js +1 -3
  50. package/es/components/IconNode/index.js +6 -17
  51. package/es/components/index.js +2 -15
  52. package/es/data/func.code.js +2 -9
  53. package/es/data/general.config.js +2 -9
  54. package/es/data/index.js +3 -23
  55. package/es/index.d.ts +0 -1
  56. package/es/index.js +24 -238
  57. package/es/utils/ValueFormat.js +1 -9
  58. package/es/utils/filterPermission.js +4 -20
  59. package/es/utils/getParentNodes.js +1 -12
  60. package/es/utils/index.js +3 -35
  61. package/lib/ButtonGroup/ButtonList.js +9 -9
  62. package/lib/ButtonGroup/ButtonMenu.js +11 -11
  63. package/lib/ButtonGroup/PopConfirmTitle.js +5 -5
  64. package/lib/ButtonGroup/index.js +47 -47
  65. package/lib/DragContent/DragBar.js +5 -5
  66. package/lib/DragContent/index.js +7 -7
  67. package/lib/FormComp/ChunkUploader/api.js +4 -4
  68. package/lib/FormComp/ChunkUploader/index.js +10 -10
  69. package/lib/FormComp/ChunkUploader/lib.js +2 -2
  70. package/lib/FormComp/ChunkUploader/upload-queue.class.js +2 -2
  71. package/lib/FormComp/ChunkUploader/worker.js +2 -2
  72. package/lib/FormComp/EditButton/index.js +10 -10
  73. package/lib/FormComp/FieldComponent/ReUpload.js +9 -9
  74. package/lib/FormComp/FieldComponent/RefactorTreeSelect.js +16 -16
  75. package/lib/FormComp/FieldComponent/TitleNode.js +4 -4
  76. package/lib/FormComp/FieldComponent/index.js +47 -47
  77. package/lib/FormComp/FieldComponent/setReadonlyValues.js +23 -23
  78. package/lib/FormComp/RenderItemGroup/index.js +20 -21
  79. package/lib/FormComp/Uploader/index.js +16 -16
  80. package/lib/FormComp/VarTemplate/index.js +25 -23
  81. package/lib/FormComp/index.js +2 -2
  82. package/lib/NavLeafScroll/index.js +28 -28
  83. package/lib/RefactorTree/index.js +14 -14
  84. package/lib/RefactorTree/indexTreeNode.js +19 -19
  85. package/lib/SpecIcon/index.js +13 -13
  86. package/lib/SplitterLayout/Pane.js +4 -4
  87. package/lib/SplitterLayout/index.js +10 -10
  88. package/lib/StandardContent/SplitterLayout/Pane.js +11 -11
  89. package/lib/StandardContent/SplitterLayout/index.js +27 -27
  90. package/lib/StandardContent/SubfieldContent.js +9 -9
  91. package/lib/StandardContent/WrapperContent.js +7 -7
  92. package/lib/StandardDragModal/index.d.ts +11 -0
  93. package/lib/StandardDragModal/index.js +43 -0
  94. package/lib/StandardFilter/index.js +18 -18
  95. package/lib/StandardForm/ActionList.js +6 -6
  96. package/lib/StandardForm/StepForm.js +26 -26
  97. package/lib/StandardForm/TabForm.js +13 -13
  98. package/lib/StandardForm/index.js +14 -14
  99. package/lib/StandardModal/UpdateFormRef.js +4 -4
  100. package/lib/StandardModal/index.d.ts +3 -0
  101. package/lib/StandardModal/index.js +99 -70
  102. package/lib/StandardPanel/index.js +23 -23
  103. package/lib/StandardTable/index.js +9 -19
  104. package/lib/components/IconNode/index.js +6 -6
  105. package/lib/components/index.js +2 -2
  106. package/lib/data/func.code.js +2 -2
  107. package/lib/data/general.config.js +2 -2
  108. package/lib/data/index.js +3 -3
  109. package/lib/index.d.ts +0 -1
  110. package/lib/index.js +23 -32
  111. package/lib/utils/ValueFormat.js +2 -2
  112. package/lib/utils/filterPermission.js +2 -2
  113. package/lib/utils/index.js +2 -2
  114. package/package.json +4 -3
  115. package/es/ConfigContext/index.d.ts +0 -7
  116. package/es/ConfigContext/index.js +0 -12
  117. package/es/locale/index.d.ts +0 -12
  118. package/es/locale/index.js +0 -5
  119. package/es/locale/zh_CN.d.ts +0 -4
  120. package/es/locale/zh_CN.js +0 -34
  121. package/lib/ConfigContext/index.d.ts +0 -7
  122. package/lib/ConfigContext/index.js +0 -12
  123. package/lib/locale/index.d.ts +0 -12
  124. package/lib/locale/index.js +0 -5
  125. package/lib/locale/zh_CN.d.ts +0 -4
  126. package/lib/locale/zh_CN.js +0 -34
package/lib/index.js CHANGED
@@ -24,139 +24,132 @@ var _exportNames = {
24
24
  WrapperContent: true,
25
25
  DragContent: true,
26
26
  SplitterLayout: true,
27
- NavLeafScroll: true,
28
- FanLocaleContext: true
27
+ NavLeafScroll: true
29
28
  };
30
29
  Object.defineProperty(exports, "SpecIcon", {
31
30
  enumerable: true,
32
31
  get: function get() {
33
- return _SpecIcon["default"];
32
+ return _SpecIcon.default;
34
33
  }
35
34
  });
36
35
  Object.defineProperty(exports, "ButtonGroup", {
37
36
  enumerable: true,
38
37
  get: function get() {
39
- return _ButtonGroup["default"];
38
+ return _ButtonGroup.default;
40
39
  }
41
40
  });
42
41
  Object.defineProperty(exports, "RefactorTree", {
43
42
  enumerable: true,
44
43
  get: function get() {
45
- return _RefactorTree["default"];
44
+ return _RefactorTree.default;
46
45
  }
47
46
  });
48
47
  Object.defineProperty(exports, "StandardPanel", {
49
48
  enumerable: true,
50
49
  get: function get() {
51
- return _StandardPanel["default"];
50
+ return _StandardPanel.default;
52
51
  }
53
52
  });
54
53
  Object.defineProperty(exports, "StandardTable", {
55
54
  enumerable: true,
56
55
  get: function get() {
57
- return _StandardTable["default"];
56
+ return _StandardTable.default;
58
57
  }
59
58
  });
60
59
  Object.defineProperty(exports, "StandardForm", {
61
60
  enumerable: true,
62
61
  get: function get() {
63
- return _StandardForm["default"];
62
+ return _StandardForm.default;
64
63
  }
65
64
  });
66
65
  Object.defineProperty(exports, "StepForm", {
67
66
  enumerable: true,
68
67
  get: function get() {
69
- return _StepForm["default"];
68
+ return _StepForm.default;
70
69
  }
71
70
  });
72
71
  Object.defineProperty(exports, "TabForm", {
73
72
  enumerable: true,
74
73
  get: function get() {
75
- return _TabForm["default"];
74
+ return _TabForm.default;
76
75
  }
77
76
  });
78
77
  Object.defineProperty(exports, "StandardFilter", {
79
78
  enumerable: true,
80
79
  get: function get() {
81
- return _StandardFilter["default"];
80
+ return _StandardFilter.default;
82
81
  }
83
82
  });
84
83
  Object.defineProperty(exports, "StandardModal", {
85
84
  enumerable: true,
86
85
  get: function get() {
87
- return _StandardModal["default"];
86
+ return _StandardModal.default;
88
87
  }
89
88
  });
90
89
  Object.defineProperty(exports, "Uploader", {
91
90
  enumerable: true,
92
91
  get: function get() {
93
- return _Uploader["default"];
92
+ return _Uploader.default;
94
93
  }
95
94
  });
96
95
  Object.defineProperty(exports, "EditButton", {
97
96
  enumerable: true,
98
97
  get: function get() {
99
- return _EditButton["default"];
98
+ return _EditButton.default;
100
99
  }
101
100
  });
102
101
  Object.defineProperty(exports, "FieldComponent", {
103
102
  enumerable: true,
104
103
  get: function get() {
105
- return _FieldComponent["default"];
104
+ return _FieldComponent.default;
106
105
  }
107
106
  });
108
107
  Object.defineProperty(exports, "Field", {
109
108
  enumerable: true,
110
109
  get: function get() {
111
- return _FieldComponent["default"];
110
+ return _FieldComponent.default;
112
111
  }
113
112
  });
114
113
  Object.defineProperty(exports, "RenderItemGroup", {
115
114
  enumerable: true,
116
115
  get: function get() {
117
- return _RenderItemGroup["default"];
116
+ return _RenderItemGroup.default;
118
117
  }
119
118
  });
120
119
  Object.defineProperty(exports, "ItemGroup", {
121
120
  enumerable: true,
122
121
  get: function get() {
123
- return _RenderItemGroup["default"];
122
+ return _RenderItemGroup.default;
124
123
  }
125
124
  });
126
125
  Object.defineProperty(exports, "SubfieldContent", {
127
126
  enumerable: true,
128
127
  get: function get() {
129
- return _SubfieldContent["default"];
128
+ return _SubfieldContent.default;
130
129
  }
131
130
  });
132
131
  Object.defineProperty(exports, "WrapperContent", {
133
132
  enumerable: true,
134
133
  get: function get() {
135
- return _WrapperContent["default"];
134
+ return _WrapperContent.default;
136
135
  }
137
136
  });
138
137
  Object.defineProperty(exports, "DragContent", {
139
138
  enumerable: true,
140
139
  get: function get() {
141
- return _DragContent["default"];
140
+ return _DragContent.default;
142
141
  }
143
142
  });
144
143
  Object.defineProperty(exports, "SplitterLayout", {
145
144
  enumerable: true,
146
145
  get: function get() {
147
- return _SplitterLayout["default"];
146
+ return _SplitterLayout.default;
148
147
  }
149
148
  });
150
149
  Object.defineProperty(exports, "NavLeafScroll", {
151
150
  enumerable: true,
152
151
  get: function get() {
153
- return _NavLeafScroll["default"];
154
- }
155
- });
156
- Object.defineProperty(exports, "FanLocaleContext", {
157
- enumerable: true,
158
- get: function get() {
159
- return _ConfigContext["default"];
152
+ return _NavLeafScroll.default;
160
153
  }
161
154
  });
162
155
 
@@ -240,6 +233,4 @@ Object.keys(_data).forEach(function (key) {
240
233
  });
241
234
  });
242
235
 
243
- var _ConfigContext = _interopRequireDefault(require("./ConfigContext"));
244
-
245
- function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
236
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
@@ -3,7 +3,7 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports["default"] = void 0;
6
+ exports.default = void 0;
7
7
 
8
8
  /*
9
9
  * 工具类: 表单组控件值格式转换工具
@@ -55,4 +55,4 @@ var UtilValueFormat = function UtilValueFormat(fieldsValue, formItemGroup) {
55
55
  };
56
56
 
57
57
  var _default = UtilValueFormat;
58
- exports["default"] = _default;
58
+ exports.default = _default;
@@ -7,7 +7,7 @@ exports.btnClickFunc = exports.btnIsDisabled = exports.btnIsHide = exports.remov
7
7
 
8
8
  var _lodash = _interopRequireDefault(require("lodash"));
9
9
 
10
- function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
10
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
11
11
 
12
12
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
13
13
 
@@ -106,7 +106,7 @@ var removeNoPermission = function removeNoPermission(array, permissionCodes, cod
106
106
  // 与codes进行对比,相应的 code匹配以对应的name,icon,code返回
107
107
  // 如果有配置code,则使用func.code.js里面配置的名称
108
108
  if (codes && resultItem.code) {
109
- var matchIndex = _lodash["default"].findIndex(codes, function (btnItem) {
109
+ var matchIndex = _lodash.default.findIndex(codes, function (btnItem) {
110
110
  return btnItem.code === resultItem.code;
111
111
  });
112
112
 
@@ -6,7 +6,7 @@ Object.defineProperty(exports, "__esModule", {
6
6
  Object.defineProperty(exports, "UtilValueFormat", {
7
7
  enumerable: true,
8
8
  get: function get() {
9
- return _ValueFormat["default"];
9
+ return _ValueFormat.default;
10
10
  }
11
11
  });
12
12
  Object.defineProperty(exports, "getParentNodes", {
@@ -32,4 +32,4 @@ var _ValueFormat = _interopRequireDefault(require("./ValueFormat"));
32
32
 
33
33
  var _getParentNodes = require("./getParentNodes");
34
34
 
35
- function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
35
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fan-standard-comp",
3
- "version": "3.1.0",
3
+ "version": "3.1.2",
4
4
  "description": "FZ standard-comp,basic of antd4.0 and custom component.",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",
@@ -26,7 +26,7 @@
26
26
  "devDependencies": {
27
27
  "@ant-design/icons": "^4.3.0",
28
28
  "@types/classnames": "^2.2.11",
29
- "antd": "4.22.8",
29
+ "antd": "4.24.7",
30
30
  "babel-loader": "^8.2.2",
31
31
  "babel-plugin-import": "^1.13.3",
32
32
  "classnames": "^2.2.6",
@@ -42,6 +42,7 @@
42
42
  "file-loader": "6.2.0",
43
43
  "less-loader": "5.0.0",
44
44
  "style-loader": "1.3.0",
45
- "webpack": "4.44.1"
45
+ "webpack": "4.44.1",
46
+ "ant-design-draggable-modal": "^1.0.0"
46
47
  }
47
48
  }
@@ -1,7 +0,0 @@
1
- /// <reference types="react" />
2
- import type { Locale } from '../locale';
3
- export declare type LocaleContextProps = Partial<Locale> & {
4
- exist?: boolean;
5
- };
6
- declare const FanLocaleContext: import("react").Context<LocaleContextProps>;
7
- export default FanLocaleContext;
@@ -1,12 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports["default"] = void 0;
7
-
8
- var _react = require("react");
9
-
10
- var FanLocaleContext = /*#__PURE__*/(0, _react.createContext)(undefined);
11
- var _default = FanLocaleContext;
12
- exports["default"] = _default;
@@ -1,12 +0,0 @@
1
- export interface StandardTableLocale {
2
- title?: string;
3
- orderRowTitle?: string;
4
- actionRowTitle?: string;
5
- filterConfirm?: string;
6
- [k: string]: any;
7
- }
8
- export interface Locale {
9
- locale?: string;
10
- StandardTable?: StandardTableLocale;
11
- [k: string]: any;
12
- }
@@ -1,5 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
@@ -1,4 +0,0 @@
1
- import type { Locale } from './index';
2
- export declare type localeValuesProps = Partial<Locale>;
3
- declare const localeValues: localeValuesProps;
4
- export default localeValues;
@@ -1,34 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports["default"] = void 0;
7
- var localeValues = {
8
- locale: 'zh-cn',
9
- global: {
10
- placeholder: '请选择'
11
- },
12
- StandardTable: {
13
- orderRowTitle: '序号',
14
- actionRowTitle: '操作',
15
- filterConfirm: '确定',
16
- filterReset: '重置',
17
- emptyText: '暂无数据' // filterEmptyText: '无筛选项',
18
- // filterCheckall: '全选',
19
- // filterSearchPlaceholder: '在筛选项中搜索',
20
- // selectAll: '全选当页',
21
- // selectInvert: '反选当页',
22
- // selectNone: '清空所有',
23
- // selectionAll: '全选所有',
24
- // sortTitle: '排序',
25
- // expand: '展开行',
26
- // collapse: '关闭行',
27
- // triggerDesc: '点击降序',
28
- // triggerAsc: '点击升序',
29
- // cancelSort: '取消排序',
30
-
31
- }
32
- };
33
- var _default = localeValues;
34
- exports["default"] = _default;
@@ -1,7 +0,0 @@
1
- /// <reference types="react" />
2
- import type { Locale } from '../locale';
3
- export declare type LocaleContextProps = Partial<Locale> & {
4
- exist?: boolean;
5
- };
6
- declare const FanLocaleContext: import("react").Context<LocaleContextProps>;
7
- export default FanLocaleContext;
@@ -1,12 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports["default"] = void 0;
7
-
8
- var _react = require("react");
9
-
10
- var FanLocaleContext = /*#__PURE__*/(0, _react.createContext)(undefined);
11
- var _default = FanLocaleContext;
12
- exports["default"] = _default;
@@ -1,12 +0,0 @@
1
- export interface StandardTableLocale {
2
- title?: string;
3
- orderRowTitle?: string;
4
- actionRowTitle?: string;
5
- filterConfirm?: string;
6
- [k: string]: any;
7
- }
8
- export interface Locale {
9
- locale?: string;
10
- StandardTable?: StandardTableLocale;
11
- [k: string]: any;
12
- }
@@ -1,5 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
@@ -1,4 +0,0 @@
1
- import type { Locale } from './index';
2
- export declare type localeValuesProps = Partial<Locale>;
3
- declare const localeValues: localeValuesProps;
4
- export default localeValues;
@@ -1,34 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports["default"] = void 0;
7
- var localeValues = {
8
- locale: 'zh-cn',
9
- global: {
10
- placeholder: '请选择'
11
- },
12
- StandardTable: {
13
- orderRowTitle: '序号',
14
- actionRowTitle: '操作',
15
- filterConfirm: '确定',
16
- filterReset: '重置',
17
- emptyText: '暂无数据' // filterEmptyText: '无筛选项',
18
- // filterCheckall: '全选',
19
- // filterSearchPlaceholder: '在筛选项中搜索',
20
- // selectAll: '全选当页',
21
- // selectInvert: '反选当页',
22
- // selectNone: '清空所有',
23
- // selectionAll: '全选所有',
24
- // sortTitle: '排序',
25
- // expand: '展开行',
26
- // collapse: '关闭行',
27
- // triggerDesc: '点击降序',
28
- // triggerAsc: '点击升序',
29
- // cancelSort: '取消排序',
30
-
31
- }
32
- };
33
- var _default = localeValues;
34
- exports["default"] = _default;