linkmore-design 1.0.3

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 (239) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +81 -0
  3. package/dist/40b22ad7b4ea2a7e.jpg +0 -0
  4. package/dist/566891e3103ae07a.png +0 -0
  5. package/dist/9f788f660abc173c.png +0 -0
  6. package/dist/f8940d62d6a40f71.png +0 -0
  7. package/dist/index.umd.css +2167 -0
  8. package/dist/index.umd.js +69587 -0
  9. package/dist/index.umd.min.css +1 -0
  10. package/dist/index.umd.min.js +31 -0
  11. package/es/ButtonTags/ButtonTags.js +59 -0
  12. package/es/ButtonTags/index.js +13 -0
  13. package/es/ButtonTags/style/index.js +3 -0
  14. package/es/ButtonTags/style/style.css +221 -0
  15. package/es/CkFilter/baseFilter/filterMenu.js +177 -0
  16. package/es/CkFilter/baseFilter/index.js +91 -0
  17. package/es/CkFilter/baseFilter/moreFilters.js +198 -0
  18. package/es/CkFilter/complexFilter/drawer.js +337 -0
  19. package/es/CkFilter/complexFilter/index.js +69 -0
  20. package/es/CkFilter/components/filterTypes.js +530 -0
  21. package/es/CkFilter/components/modal.js +275 -0
  22. package/es/CkFilter/context.js +152 -0
  23. package/es/CkFilter/customFilter/drawer.js +364 -0
  24. package/es/CkFilter/customFilter/index.js +130 -0
  25. package/es/CkFilter/customFilter/radioGroup.js +65 -0
  26. package/es/CkFilter/filter.js +115 -0
  27. package/es/CkFilter/index.js +13 -0
  28. package/es/CkFilter/style/index.js +3 -0
  29. package/es/CkFilter/style/style.css +586 -0
  30. package/es/CkFilter/utils.js +65 -0
  31. package/es/CustomerService/assets/question01.png +0 -0
  32. package/es/CustomerService/assets/send.png +0 -0
  33. package/es/CustomerService/assets/service.png +0 -0
  34. package/es/CustomerService/assets/shuoming01.png +0 -0
  35. package/es/CustomerService/assets/shuoming02.png +0 -0
  36. package/es/CustomerService/components/question.js +120 -0
  37. package/es/CustomerService/index.js +291 -0
  38. package/es/CustomerService/style/index.js +3 -0
  39. package/es/CustomerService/style/style.css +402 -0
  40. package/es/EditTable/EditTable.js +489 -0
  41. package/es/EditTable/index.js +13 -0
  42. package/es/EditTable/style/index.js +3 -0
  43. package/es/EditTable/style/style.css +165 -0
  44. package/es/EnlargeImg/index.js +109 -0
  45. package/es/EnlargeImg/style/index.js +3 -0
  46. package/es/EnlargeImg/style/style.css +4 -0
  47. package/es/Filter/Popover.js +199 -0
  48. package/es/Filter/baseFilter/Popover.js +214 -0
  49. package/es/Filter/baseFilter/ToggleFilter.js +112 -0
  50. package/es/Filter/baseFilter/index.js +100 -0
  51. package/es/Filter/complex/ComplexFilter.js +149 -0
  52. package/es/Filter/complex/ComplexItem.js +157 -0
  53. package/es/Filter/components/Checkbox.js +94 -0
  54. package/es/Filter/components/Date.js +87 -0
  55. package/es/Filter/components/Input.js +63 -0
  56. package/es/Filter/components/Select.js +89 -0
  57. package/es/Filter/components/Tree.js +64 -0
  58. package/es/Filter/components/header.js +60 -0
  59. package/es/Filter/components/index.js +47 -0
  60. package/es/Filter/context.js +15 -0
  61. package/es/Filter/edit/editFilter.js +277 -0
  62. package/es/Filter/index.js +174 -0
  63. package/es/Filter/popContext.js +15 -0
  64. package/es/Filter/remember.js +137 -0
  65. package/es/Filter/style/index.js +3 -0
  66. package/es/Filter/style/style.css +420 -0
  67. package/es/Icon/index.js +20 -0
  68. package/es/Icon/style/index.js +1 -0
  69. package/es/Icon/style/style.css +0 -0
  70. package/es/IconFont/index.js +15 -0
  71. package/es/IconFont/style/index.js +1 -0
  72. package/es/IconFont/style/style.css +0 -0
  73. package/es/LeftTable/assets/imgTest.jpg +0 -0
  74. package/es/LeftTable/index.js +116 -0
  75. package/es/LeftTable/style/index.js +3 -0
  76. package/es/LeftTable/style/style.css +231 -0
  77. package/es/LoadingPage/index.js +33 -0
  78. package/es/LoadingPage/style/index.js +1 -0
  79. package/es/LoadingPage/style/style.css +0 -0
  80. package/es/Modal/add.js +68 -0
  81. package/es/Modal/confirm.js +88 -0
  82. package/es/Modal/edit.js +44 -0
  83. package/es/Modal/exportModal.js +300 -0
  84. package/es/Modal/index.js +24 -0
  85. package/es/Modal/style/index.js +3 -0
  86. package/es/Modal/style/style.css +119 -0
  87. package/es/PopTable/BseTable.js +113 -0
  88. package/es/PopTable/index.js +151 -0
  89. package/es/PopTable/style/index.js +3 -0
  90. package/es/PopTable/style/style.css +363 -0
  91. package/es/ProTable/ImgList/body.js +111 -0
  92. package/es/ProTable/ImgList/cardCell.js +179 -0
  93. package/es/ProTable/ImgList/context.js +12 -0
  94. package/es/ProTable/ImgList/empty.js +24 -0
  95. package/es/ProTable/ImgList/footer.js +59 -0
  96. package/es/ProTable/ImgList/imgCell.js +181 -0
  97. package/es/ProTable/ImgList/imgTable.js +110 -0
  98. package/es/ProTable/ImgList/index.js +13 -0
  99. package/es/ProTable/Table.js +321 -0
  100. package/es/ProTable/VList.js +594 -0
  101. package/es/ProTable/context.js +12 -0
  102. package/es/ProTable/index.js +16 -0
  103. package/es/ProTable/resetConfig.js +39 -0
  104. package/es/ProTable/style/index.js +3 -0
  105. package/es/ProTable/style/style.css +693 -0
  106. package/es/TableRender/index.js +15 -0
  107. package/es/TableRender/state.js +72 -0
  108. package/es/TableRender/style/index.js +3 -0
  109. package/es/TableRender/style/style.css +0 -0
  110. package/es/UploadOss/index.js +18 -0
  111. package/es/UploadOss/style/index.js +3 -0
  112. package/es/UploadOss/style/style.css +121 -0
  113. package/es/UploadOss/uploadBtn.js +141 -0
  114. package/es/UploadOss/uploadImg.js +282 -0
  115. package/es/VirtualList/index.js +84 -0
  116. package/es/VirtualList/style/index.js +3 -0
  117. package/es/VirtualList/style/style.css +0 -0
  118. package/es/index.js +135 -0
  119. package/es/services/newRequest.js +201 -0
  120. package/es/services/utils.js +72 -0
  121. package/es/styles/icon.css +15 -0
  122. package/es/styles/main.css +149 -0
  123. package/es/styles/resetAntd.css +62 -0
  124. package/es/styles/them.css +0 -0
  125. package/lib/ButtonTags/ButtonTags.js +59 -0
  126. package/lib/ButtonTags/index.js +13 -0
  127. package/lib/ButtonTags/style/index.js +3 -0
  128. package/lib/ButtonTags/style/style.css +221 -0
  129. package/lib/CkFilter/baseFilter/filterMenu.js +177 -0
  130. package/lib/CkFilter/baseFilter/index.js +91 -0
  131. package/lib/CkFilter/baseFilter/moreFilters.js +198 -0
  132. package/lib/CkFilter/complexFilter/drawer.js +337 -0
  133. package/lib/CkFilter/complexFilter/index.js +69 -0
  134. package/lib/CkFilter/components/filterTypes.js +530 -0
  135. package/lib/CkFilter/components/modal.js +275 -0
  136. package/lib/CkFilter/context.js +152 -0
  137. package/lib/CkFilter/customFilter/drawer.js +364 -0
  138. package/lib/CkFilter/customFilter/index.js +130 -0
  139. package/lib/CkFilter/customFilter/radioGroup.js +65 -0
  140. package/lib/CkFilter/filter.js +115 -0
  141. package/lib/CkFilter/index.js +13 -0
  142. package/lib/CkFilter/style/index.js +3 -0
  143. package/lib/CkFilter/style/style.css +586 -0
  144. package/lib/CkFilter/utils.js +65 -0
  145. package/lib/CustomerService/assets/question01.png +0 -0
  146. package/lib/CustomerService/assets/send.png +0 -0
  147. package/lib/CustomerService/assets/service.png +0 -0
  148. package/lib/CustomerService/assets/shuoming01.png +0 -0
  149. package/lib/CustomerService/assets/shuoming02.png +0 -0
  150. package/lib/CustomerService/components/question.js +120 -0
  151. package/lib/CustomerService/index.js +291 -0
  152. package/lib/CustomerService/style/index.js +3 -0
  153. package/lib/CustomerService/style/style.css +402 -0
  154. package/lib/EditTable/EditTable.js +489 -0
  155. package/lib/EditTable/index.js +13 -0
  156. package/lib/EditTable/style/index.js +3 -0
  157. package/lib/EditTable/style/style.css +165 -0
  158. package/lib/EnlargeImg/index.js +109 -0
  159. package/lib/EnlargeImg/style/index.js +3 -0
  160. package/lib/EnlargeImg/style/style.css +4 -0
  161. package/lib/Filter/Popover.js +199 -0
  162. package/lib/Filter/baseFilter/Popover.js +214 -0
  163. package/lib/Filter/baseFilter/ToggleFilter.js +112 -0
  164. package/lib/Filter/baseFilter/index.js +100 -0
  165. package/lib/Filter/complex/ComplexFilter.js +149 -0
  166. package/lib/Filter/complex/ComplexItem.js +157 -0
  167. package/lib/Filter/components/Checkbox.js +94 -0
  168. package/lib/Filter/components/Date.js +87 -0
  169. package/lib/Filter/components/Input.js +63 -0
  170. package/lib/Filter/components/Select.js +89 -0
  171. package/lib/Filter/components/Tree.js +64 -0
  172. package/lib/Filter/components/header.js +60 -0
  173. package/lib/Filter/components/index.js +47 -0
  174. package/lib/Filter/context.js +15 -0
  175. package/lib/Filter/edit/editFilter.js +277 -0
  176. package/lib/Filter/index.js +174 -0
  177. package/lib/Filter/popContext.js +15 -0
  178. package/lib/Filter/remember.js +137 -0
  179. package/lib/Filter/style/index.js +3 -0
  180. package/lib/Filter/style/style.css +420 -0
  181. package/lib/Icon/index.js +20 -0
  182. package/lib/Icon/style/index.js +1 -0
  183. package/lib/Icon/style/style.css +0 -0
  184. package/lib/IconFont/index.js +15 -0
  185. package/lib/IconFont/style/index.js +1 -0
  186. package/lib/IconFont/style/style.css +0 -0
  187. package/lib/LeftTable/assets/imgTest.jpg +0 -0
  188. package/lib/LeftTable/index.js +116 -0
  189. package/lib/LeftTable/style/index.js +3 -0
  190. package/lib/LeftTable/style/style.css +231 -0
  191. package/lib/LoadingPage/index.js +33 -0
  192. package/lib/LoadingPage/style/index.js +1 -0
  193. package/lib/LoadingPage/style/style.css +0 -0
  194. package/lib/Modal/add.js +68 -0
  195. package/lib/Modal/confirm.js +88 -0
  196. package/lib/Modal/edit.js +44 -0
  197. package/lib/Modal/exportModal.js +300 -0
  198. package/lib/Modal/index.js +24 -0
  199. package/lib/Modal/style/index.js +3 -0
  200. package/lib/Modal/style/style.css +119 -0
  201. package/lib/PopTable/BseTable.js +113 -0
  202. package/lib/PopTable/index.js +151 -0
  203. package/lib/PopTable/style/index.js +3 -0
  204. package/lib/PopTable/style/style.css +363 -0
  205. package/lib/ProTable/ImgList/body.js +111 -0
  206. package/lib/ProTable/ImgList/cardCell.js +179 -0
  207. package/lib/ProTable/ImgList/context.js +12 -0
  208. package/lib/ProTable/ImgList/empty.js +24 -0
  209. package/lib/ProTable/ImgList/footer.js +59 -0
  210. package/lib/ProTable/ImgList/imgCell.js +181 -0
  211. package/lib/ProTable/ImgList/imgTable.js +110 -0
  212. package/lib/ProTable/ImgList/index.js +13 -0
  213. package/lib/ProTable/Table.js +321 -0
  214. package/lib/ProTable/VList.js +594 -0
  215. package/lib/ProTable/context.js +12 -0
  216. package/lib/ProTable/index.js +16 -0
  217. package/lib/ProTable/resetConfig.js +39 -0
  218. package/lib/ProTable/style/index.js +3 -0
  219. package/lib/ProTable/style/style.css +693 -0
  220. package/lib/TableRender/index.js +15 -0
  221. package/lib/TableRender/state.js +72 -0
  222. package/lib/TableRender/style/index.js +3 -0
  223. package/lib/TableRender/style/style.css +0 -0
  224. package/lib/UploadOss/index.js +18 -0
  225. package/lib/UploadOss/style/index.js +3 -0
  226. package/lib/UploadOss/style/style.css +121 -0
  227. package/lib/UploadOss/uploadBtn.js +141 -0
  228. package/lib/UploadOss/uploadImg.js +282 -0
  229. package/lib/VirtualList/index.js +84 -0
  230. package/lib/VirtualList/style/index.js +3 -0
  231. package/lib/VirtualList/style/style.css +0 -0
  232. package/lib/index.js +135 -0
  233. package/lib/services/newRequest.js +201 -0
  234. package/lib/services/utils.js +72 -0
  235. package/lib/styles/icon.css +15 -0
  236. package/lib/styles/main.css +149 -0
  237. package/lib/styles/resetAntd.css +62 -0
  238. package/lib/styles/them.css +0 -0
  239. package/package.json +102 -0
@@ -0,0 +1,151 @@
1
+ "use strict";
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+
5
+ var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard");
6
+
7
+ Object.defineProperty(exports, "__esModule", {
8
+ value: true
9
+ });
10
+ exports.default = void 0;
11
+
12
+ var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
13
+
14
+ require("antd/es/button/style");
15
+
16
+ var _button = _interopRequireDefault(require("antd/es/button"));
17
+
18
+ require("antd/es/space/style");
19
+
20
+ var _space = _interopRequireDefault(require("antd/es/space"));
21
+
22
+ require("antd/es/input/style");
23
+
24
+ var _input = _interopRequireDefault(require("antd/es/input"));
25
+
26
+ var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/objectSpread2"));
27
+
28
+ var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
29
+
30
+ var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
31
+
32
+ var _react = _interopRequireWildcard(require("react"));
33
+
34
+ var _icons = require("@ant-design/icons");
35
+
36
+ var _BseTable = _interopRequireDefault(require("./BseTable"));
37
+
38
+ var _excluded = ["columns", "data", "total", "rowSelection", "onChange", "getCheckboxRecords"];
39
+
40
+ var Demo = function Demo(props) {
41
+ var inputRef = _react.default.useRef();
42
+
43
+ var tableRef = _react.default.useRef();
44
+
45
+ var _useState = (0, _react.useState)([]),
46
+ _useState2 = (0, _slicedToArray2.default)(_useState, 2),
47
+ checkRow = _useState2[0],
48
+ setCheckRow = _useState2[1];
49
+
50
+ var columns = props.columns,
51
+ data = props.data,
52
+ total = props.total,
53
+ _props$rowSelection = props.rowSelection,
54
+ rowSelection = _props$rowSelection === void 0 ? true : _props$rowSelection,
55
+ onChange = props.onChange,
56
+ getCheckboxRecords = props.getCheckboxRecords,
57
+ resetProps = (0, _objectWithoutProperties2.default)(props, _excluded);
58
+
59
+ var _useState3 = (0, _react.useState)('base'),
60
+ _useState4 = (0, _slicedToArray2.default)(_useState3, 2),
61
+ activeKey = _useState4[0],
62
+ setActiveKey = _useState4[1]; // 表格分页、筛选、排序改变事件
63
+
64
+
65
+ var onTableChange = function onTableChange(params) {
66
+ var search = inputRef.current.input.value;
67
+ var nValue = (0, _objectSpread2.default)((0, _objectSpread2.default)({}, params), {}, {
68
+ search: search
69
+ });
70
+ onChange === null || onChange === void 0 ? void 0 : onChange(nValue);
71
+ }; // 搜索事件
72
+
73
+
74
+ var onSearch = function onSearch(e) {
75
+ if (e.keyCode === 13) {
76
+ var search = inputRef.current.input.value;
77
+ setActiveKey(Date.now());
78
+ onChange === null || onChange === void 0 ? void 0 : onChange({
79
+ search: search
80
+ });
81
+ }
82
+ }; // 选中的行数据
83
+
84
+
85
+ var onClick = function onClick() {
86
+ var nValue = tableRef.current.getCheckboxRecords();
87
+
88
+ if (!rowSelection) {
89
+ nValue = checkRow;
90
+ }
91
+
92
+ getCheckboxRecords === null || getCheckboxRecords === void 0 ? void 0 : getCheckboxRecords(nValue);
93
+ };
94
+
95
+ var onTableClick = function onTableClick(row) {
96
+ if (!rowSelection) {
97
+ setCheckRow([row]);
98
+ }
99
+ };
100
+
101
+ var onDoubleClick = function onDoubleClick(row) {
102
+ getCheckboxRecords === null || getCheckboxRecords === void 0 ? void 0 : getCheckboxRecords([row]);
103
+ };
104
+
105
+ _react.default.useEffect(function () {
106
+ onChange === null || onChange === void 0 ? void 0 : onChange({});
107
+ }, []);
108
+
109
+ return /*#__PURE__*/_react.default.createElement("div", {
110
+ className: "lm_popover_table"
111
+ }, /*#__PURE__*/_react.default.createElement("div", {
112
+ className: "z_flex",
113
+ style: {
114
+ maxWidth: 485
115
+ }
116
+ }, /*#__PURE__*/_react.default.createElement("div", {
117
+ className: "lm_operate"
118
+ }, /*#__PURE__*/_react.default.createElement(_space.default, {
119
+ className: "operate_left"
120
+ }, /*#__PURE__*/_react.default.createElement(_input.default, {
121
+ ref: inputRef,
122
+ placeholder: "\u8BF7\u8F93\u5165\u5173\u952E\u8BCD\u641C\u7D22",
123
+ onKeyDown: onSearch
124
+ })), /*#__PURE__*/_react.default.createElement(_space.default, {
125
+ className: "operate_right"
126
+ }, /*#__PURE__*/_react.default.createElement(_button.default, {
127
+ type: "primary",
128
+ icon: /*#__PURE__*/_react.default.createElement(_icons.SaveOutlined, null),
129
+ size: "small",
130
+ onClick: onClick
131
+ }, "\u786E\u8BA4"))), /*#__PURE__*/_react.default.createElement("div", {
132
+ className: "lm_grid"
133
+ }, /*#__PURE__*/_react.default.createElement(_BseTable.default, (0, _extends2.default)({
134
+ key: activeKey,
135
+ ref: tableRef,
136
+ columns: columns,
137
+ total: total,
138
+ dataSource: data,
139
+ onClick: onTableClick,
140
+ onChange: onTableChange,
141
+ onDoubleClick: onDoubleClick,
142
+ rowSelection: rowSelection,
143
+ scroll: {
144
+ x: '100%',
145
+ y: 200
146
+ }
147
+ }, resetProps)))));
148
+ };
149
+
150
+ var _default = Demo;
151
+ exports.default = _default;
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+
3
+ require("./style.css");
@@ -0,0 +1,363 @@
1
+ .ant-layout-sider {
2
+ min-height: 100vh;
3
+ background-color: #022766;
4
+ }
5
+ .ant-menu-dark .ant-menu-inline.ant-menu-sub {
6
+ box-shadow: none;
7
+ }
8
+ .ant-menu-submenu-placement-rightTop {
9
+ display: none;
10
+ }
11
+ .ant-table .row-active .ant-table-cell {
12
+ background-color: #FEFFD3 !important;
13
+ }
14
+ .ant-dropdown-menu-item {
15
+ font-size: 12px;
16
+ height: 32px;
17
+ }
18
+ .ant-tabs .ant-tabs-nav .ant-tabs-tab {
19
+ font-size: 14px;
20
+ }
21
+ .ant-tabs.auto_tabs {
22
+ display: flex;
23
+ flex-flow: column;
24
+ height: 100%;
25
+ }
26
+ .ant-tabs.auto_tabs .ant-tabs-nav {
27
+ height: 48px;
28
+ }
29
+ .ant-tabs.auto_tabs .ant-tabs-content-holder {
30
+ flex: 1;
31
+ overflow: auto;
32
+ }
33
+ .ant-drawer.drawer_wrapper .ant-drawer-header {
34
+ padding: 0 24px;
35
+ }
36
+ .ant-drawer.drawer_wrapper .ant-drawer-body {
37
+ position: relative;
38
+ flex: 1;
39
+ padding: 0 24px;
40
+ }
41
+ .ant-modal-wrap.plugin_modal {
42
+ display: flex;
43
+ flex-flow: column;
44
+ justify-content: flex-end;
45
+ }
46
+ .ant-modal-wrap.plugin_modal .ant-modal {
47
+ left: 56px;
48
+ top: 0;
49
+ margin: 0 0 8px 8px;
50
+ padding: 0;
51
+ }
52
+ .ant-modal-wrap.lm_modal_confirm .anticon {
53
+ margin-top: -1px;
54
+ margin-right: 8px;
55
+ }
56
+ .ant-modal-wrap.lm_modal_confirm .ant-modal-body {
57
+ padding: 16px 24px;
58
+ }
59
+ .ant-popover.pop_img .ant-popover-inner-content {
60
+ line-height: 1;
61
+ padding: var(--gap);
62
+ }
63
+ @font-face {
64
+ font-family: 'iconfont';
65
+ /* Project id 2966019 */
66
+ src: url('//at.alicdn.com/t/font_2966019_i3eb1wwkoo.woff2?t=1641546077924') format('woff2'), url('//at.alicdn.com/t/font_2966019_i3eb1wwkoo.woff?t=1641546077924') format('woff'), url('//at.alicdn.com/t/font_2966019_i3eb1wwkoo.ttf?t=1641546077924') format('truetype');
67
+ }
68
+ .icon_ {
69
+ font-family: 'iconfont';
70
+ font-size: 14px;
71
+ }
72
+ .iconfont {
73
+ font-size: 12px;
74
+ }
75
+ .icon_home::before {
76
+ content: '\e7fc';
77
+ }
78
+ :root {
79
+ --them-color: #1890fc;
80
+ --main-color: #1890fc;
81
+ --primary-color: #1890fc;
82
+ --primary2-color: rgba(24, 144, 252, 0.08);
83
+ --success-color: #56C22D;
84
+ --warning-color: #FD9727;
85
+ --error-color: #FA4F53;
86
+ --aside-bg-color: #022766;
87
+ --font-color: rgba(0, 0, 0, 0.85);
88
+ --font2-color: rgba(0, 0, 0, 0.65);
89
+ --text-color: rgba(0, 0, 0, 0.45);
90
+ --box-shadow-color: rgba(0, 0, 0, 0.15);
91
+ --background-color: rgba(0, 0, 0, 0.04);
92
+ --background-color-hover: rgba(0, 0, 0, 0.08);
93
+ --border-color: #f0f0f0;
94
+ --stripe-color: #f5f5f5;
95
+ --border-hover-color: #f2f5f7;
96
+ --gap: 8px;
97
+ --basic-height: 24px;
98
+ }
99
+ .ant-input,
100
+ .ant-select {
101
+ font-size: 12px;
102
+ }
103
+ .ant-select-dropdown .ant-select-item {
104
+ font-size: 12px;
105
+ align-items: center;
106
+ }
107
+ .react-resizable {
108
+ position: relative;
109
+ background-clip: padding-box;
110
+ }
111
+ .react-resizable-handle {
112
+ position: absolute;
113
+ right: 0;
114
+ top: 0;
115
+ z-index: 1;
116
+ width: 3px;
117
+ height: 40px;
118
+ cursor: col-resize;
119
+ }
120
+ .react-resizable-handle:hover {
121
+ background-color: var(--primary-color);
122
+ }
123
+ .react-resizable-handle:active {
124
+ background-color: var(--primary-color);
125
+ }
126
+ .yf_resizable_bar {
127
+ position: absolute;
128
+ left: 0;
129
+ top: 0;
130
+ z-index: 2;
131
+ height: 0;
132
+ }
133
+ .resizable_line {
134
+ position: absolute;
135
+ left: 0;
136
+ top: 0;
137
+ height: 100%;
138
+ width: 1px;
139
+ background-color: var(--primary-color);
140
+ z-index: 1;
141
+ }
142
+ .handle_resizable {
143
+ position: absolute;
144
+ right: 0;
145
+ top: 0;
146
+ height: 100%;
147
+ width: 5px;
148
+ z-index: 2;
149
+ }
150
+ .lm_popover_table .btn-dashed {
151
+ font-size: 12px;
152
+ color: #ccc;
153
+ border-color: #ccc;
154
+ }
155
+ .lm_popover_table .z_flex {
156
+ display: flex;
157
+ flex-flow: column;
158
+ flex: 1;
159
+ height: 100%;
160
+ }
161
+ .lm_popover_table .lm_operate {
162
+ display: flex;
163
+ align-items: center;
164
+ justify-content: space-between;
165
+ }
166
+ .lm_popover_table .lm_operate .ant-space-item,
167
+ .lm_popover_table .lm_operate .ant-space-item > *,
168
+ .lm_popover_table .lm_operate .ant-btn,
169
+ .lm_popover_table .lm_operate .ant-input {
170
+ font-size: 12px;
171
+ }
172
+ .lm_popover_table .lm_operate .ant-btn {
173
+ display: inline-flex;
174
+ align-items: center;
175
+ justify-content: center;
176
+ }
177
+ .lm_popover_table .lm_operate .ant-btn > .anticon:not(.anticon-down) {
178
+ font-size: 14px;
179
+ }
180
+ .lm_popover_table .lm_operate .anticon + span,
181
+ .lm_popover_table .lm_operate span + .anticon {
182
+ margin-left: calc(var(--gap) / 2);
183
+ }
184
+ .lm_popover_table .lm_operate .operate_left,
185
+ .lm_popover_table .lm_operate .operate_right {
186
+ display: flex;
187
+ padding-bottom: calc(var(--gap) * 2);
188
+ }
189
+ .lm_popover_table .lm_operate .operate_left:empty,
190
+ .lm_popover_table .lm_operate .operate_right:empty {
191
+ padding-bottom: 0;
192
+ }
193
+ .lm_popover_table .lm_operate .ant-input-group {
194
+ font-size: 12px;
195
+ line-height: 1.5;
196
+ }
197
+ .lm_popover_table .lm_operate .ant-input-sm {
198
+ width: 180px;
199
+ font-size: 12px;
200
+ height: var(--basic-height);
201
+ padding: 0 10px;
202
+ }
203
+ .lm_popover_table .lm_operate .ant-select.ant-select-single .ant-select-selector {
204
+ font-size: 12px;
205
+ width: 160px;
206
+ }
207
+ .lm_popover_table .lm_operate .ant-picker {
208
+ font-size: 12px;
209
+ }
210
+ .lm_popover_table .lm_operate .ant-picker .ant-picker-input > input {
211
+ font-size: 12px;
212
+ }
213
+ .lm_popover_table .lm_operate .line {
214
+ display: block;
215
+ height: var(--basic-height);
216
+ border-right: 1px solid #eee;
217
+ }
218
+ .lm_popover_table .lm_grid {
219
+ position: relative;
220
+ flex: 1;
221
+ overflow: hidden;
222
+ }
223
+ .lm_popover_table .lm_grid > div {
224
+ height: 100%;
225
+ }
226
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table.ant-table-small {
227
+ font-size: 12px;
228
+ }
229
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-thead {
230
+ height: 40px;
231
+ }
232
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-thead .text-overflow,
233
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-thead .text-overflow .ant-table-column-title {
234
+ overflow: hidden;
235
+ text-overflow: ellipsis;
236
+ white-space: nowrap;
237
+ }
238
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-tbody .ant-table-cell {
239
+ padding: 8px;
240
+ }
241
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-tbody .ant-table-cell.number {
242
+ border-left: 1px solid #eee;
243
+ border-right: 1px solid #eee;
244
+ }
245
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-tbody .ant-table-cell.money {
246
+ border-left: 1px solid #eee;
247
+ border-right: 1px solid #eee;
248
+ color: var(--error-color);
249
+ }
250
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-tbody .ant-table-cell.money-color {
251
+ color: var(--error-color);
252
+ }
253
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-tbody .ant-typography {
254
+ margin: 0;
255
+ }
256
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-tbody .ant-typography .ant-typography-copy {
257
+ color: var(--text-color);
258
+ }
259
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-tbody .ant-typography .ant-typography-copy-success {
260
+ color: var(--success-color);
261
+ }
262
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-tbody .ant-typography.ant-typography-ellipsis .ant-typography-edit {
263
+ opacity: 0;
264
+ color: var(--primary-color);
265
+ transition: 0.3s;
266
+ }
267
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-tbody .ant-typography.ant-typography-ellipsis:hover .ant-typography-edit {
268
+ opacity: 1;
269
+ }
270
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-summary {
271
+ height: 48px;
272
+ }
273
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-summary td {
274
+ text-align: right;
275
+ background-color: var(--table-background-color);
276
+ padding: 0 8px;
277
+ }
278
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-summary td:first-of-type {
279
+ text-align: left;
280
+ padding: 0 0 0 8px;
281
+ }
282
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-summary td.number {
283
+ border-left: 1px solid #eee;
284
+ border-right: 1px solid #eee;
285
+ }
286
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-summary td.money {
287
+ border-left: 1px solid #eee;
288
+ border-right: 1px solid #eee;
289
+ color: var(--error-color);
290
+ }
291
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-summary td.money-color {
292
+ color: var(--error-color);
293
+ }
294
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-summary td > div {
295
+ white-space: nowrap;
296
+ overflow: hidden;
297
+ text-overflow: ellipsis;
298
+ }
299
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-summary td > div:last-of-type {
300
+ font-weight: bold;
301
+ }
302
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-summary .total_title {
303
+ position: relative;
304
+ white-space: nowrap;
305
+ }
306
+ .lm_popover_table .lm_grid .ant-pro-table .ant-pro-table-list-toolbar-container {
307
+ padding: 0;
308
+ }
309
+ .lm_popover_table .lm_grid .ant-pro-table .ant-pro-table-list-toolbar-container .ant-pro-table-list-toolbar-right {
310
+ position: absolute;
311
+ right: 1px;
312
+ top: 1px;
313
+ z-index: 4;
314
+ font-size: 16px;
315
+ width: 48px;
316
+ height: 38px;
317
+ justify-content: center;
318
+ background-color: #fafafa;
319
+ }
320
+ .lm_popover_table .lm_grid .ant-pro-table .ant-pro-table-list-toolbar-container .ant-pro-table-list-toolbar-right::after {
321
+ content: '';
322
+ position: absolute;
323
+ left: 0;
324
+ top: 50%;
325
+ transform: translateY(-50%);
326
+ height: 1.6em;
327
+ width: 1px;
328
+ background-color: rgba(0, 0, 0, 0.06);
329
+ }
330
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-row {
331
+ position: relative;
332
+ }
333
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-row .operate_fixed_right .operate_btn {
334
+ font-size: 12px;
335
+ color: var(--primary-color);
336
+ }
337
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-row .operate_fixed_right .operate_btn .ant-space-item {
338
+ cursor: pointer;
339
+ }
340
+ .lm_popover_table .lm_grid .ant-pro-table .ant-table-row .operate_fixed_right .ant-btn {
341
+ font-size: 12px;
342
+ }
343
+ .lm_popover_table .lm_grid .ant-pagination {
344
+ font-size: 12px;
345
+ padding-top: 12px;
346
+ margin: 0;
347
+ }
348
+ .lm_popover_table .lm_grid .ant-pagination .ant-select {
349
+ font-size: inherit;
350
+ }
351
+ .z-popover-table .ant-popover-inner-content {
352
+ padding: 16px;
353
+ }
354
+ .z-popover-table .ant-card-body {
355
+ padding: 0;
356
+ }
357
+ .z-popover-table .ant-empty-normal {
358
+ font-size: 12px;
359
+ margin: 8px 0 0;
360
+ }
361
+ .z-popover-table .ant-empty-normal .ant-empty-image {
362
+ font: 36px;
363
+ }
@@ -0,0 +1,111 @@
1
+ "use strict";
2
+
3
+ var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard");
4
+
5
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
6
+
7
+ Object.defineProperty(exports, "__esModule", {
8
+ value: true
9
+ });
10
+ exports.default = void 0;
11
+
12
+ var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
13
+
14
+ var _react = _interopRequireWildcard(require("react"));
15
+
16
+ var _reactVirtualizedAutoSizer = _interopRequireDefault(require("react-virtualized-auto-sizer"));
17
+
18
+ var _reactWindow = require("react-window");
19
+
20
+ var _context = _interopRequireDefault(require("./context"));
21
+
22
+ var _imgCell = _interopRequireDefault(require("./imgCell"));
23
+
24
+ var _cardCell = _interopRequireDefault(require("./cardCell"));
25
+
26
+ var _empty = _interopRequireDefault(require("./empty"));
27
+
28
+ var ImgList = function ImgList(props) {
29
+ var widthCount = props.width,
30
+ heightCount = props.height;
31
+
32
+ var _useContext = (0, _react.useContext)(_context.default),
33
+ data = _useContext.data,
34
+ _useContext$heightCel = _useContext.heightCell,
35
+ heightCell = _useContext$heightCel === void 0 ? 375 : _useContext$heightCel,
36
+ _useContext$rowKey = _useContext.rowKey,
37
+ rowKey = _useContext$rowKey === void 0 ? 'id' : _useContext$rowKey,
38
+ _useContext$cell = _useContext.cell,
39
+ cell = _useContext$cell === void 0 ? 'img' : _useContext$cell; // 响应式列数量控制
40
+
41
+
42
+ var columnCount = (0, _react.useMemo)(function () {
43
+ return widthCount > 1800 ? 5 : widthCount > 1500 ? 4 : 3;
44
+ }, [widthCount]);
45
+ var widthCell = (0, _react.useMemo)(function () {
46
+ return (widthCount - 8) / columnCount;
47
+ }, [widthCount]);
48
+ var rowCount = (0, _react.useMemo)(function () {
49
+ var rs = Math.ceil(data.length / columnCount);
50
+ return rs;
51
+ }, [data, widthCount]);
52
+
53
+ var Cell = _react.default.useCallback(function (_ref) {
54
+ var columnIndex = _ref.columnIndex,
55
+ rowIndex = _ref.rowIndex,
56
+ style = _ref.style;
57
+ var idx = rowIndex * columnCount + columnIndex;
58
+ var config = {
59
+ item: data[idx],
60
+ index: idx,
61
+ style: style
62
+ };
63
+ var r = rowIndex === 0 ? 'first_row' : rowIndex === rowCount - 1 ? 'last_row' : '';
64
+ var c = columnIndex === 0 ? 'first_column' : columnIndex + 1 === columnCount ? 'last_column' : '';
65
+ var classN = "".concat(r, " ").concat(c);
66
+ return data[idx] ? cell === 'img' ? /*#__PURE__*/_react.default.createElement(_imgCell.default, (0, _extends2.default)({
67
+ key: rowKey,
68
+ className: classN
69
+ }, config)) : /*#__PURE__*/_react.default.createElement(_cardCell.default, (0, _extends2.default)({
70
+ key: rowKey,
71
+ className: classN
72
+ }, config)) : '';
73
+ }, [data, widthCount]);
74
+
75
+ var Gd = _react.default.useCallback(function () {
76
+ return /*#__PURE__*/_react.default.createElement(_reactWindow.VariableSizeGrid, {
77
+ className: "virtual-grid lm_imgList",
78
+ columnCount: columnCount,
79
+ columnWidth: function columnWidth() {
80
+ return widthCell;
81
+ },
82
+ height: heightCount,
83
+ rowCount: rowCount,
84
+ rowHeight: function rowHeight() {
85
+ return heightCell;
86
+ },
87
+ width: widthCount
88
+ }, Cell);
89
+ }, [data, widthCount, heightCount]);
90
+
91
+ return data.length > 0 ? /*#__PURE__*/_react.default.createElement(Gd, null) : /*#__PURE__*/_react.default.createElement(_empty.default, null);
92
+ }; // 监听大小
93
+
94
+
95
+ var ResizeSize = function ResizeSize(props) {
96
+ return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_reactVirtualizedAutoSizer.default, {
97
+ style: {
98
+ width: '100%'
99
+ }
100
+ }, function (_ref2) {
101
+ var height = _ref2.height,
102
+ width = _ref2.width;
103
+ return /*#__PURE__*/_react.default.createElement(ImgList, (0, _extends2.default)({}, props, {
104
+ width: width,
105
+ height: height
106
+ }));
107
+ }));
108
+ };
109
+
110
+ var _default = ResizeSize;
111
+ exports.default = _default;