@aloudata/aloudata-design 0.2.0-beta.1 → 0.2.0-beta.4

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 (243) hide show
  1. package/es/Dropdown/index.d.ts +1 -0
  2. package/es/Icon/iconfont/demo_index.html +49 -3
  3. package/es/Icon/iconfont/iconfont.css +11 -3
  4. package/es/Icon/iconfont/iconfont.js +5 -5
  5. package/es/Icon/iconfont/iconfont.json +14 -0
  6. package/es/Icon/iconfont/iconfont.ttf +0 -0
  7. package/es/Icon/iconfont/iconfont.woff +0 -0
  8. package/es/Icon/iconfont/iconfont.woff2 +0 -0
  9. package/es/Icon/index.less +2 -2
  10. package/es/Input/components/Group/index.d.ts +3 -1
  11. package/es/Input/components/Password/index.d.ts +4 -2
  12. package/es/Input/components/Password/index.js +1 -1
  13. package/es/Input/index.d.ts +1 -1
  14. package/es/Menu/Divider.d.ts +1 -0
  15. package/es/Menu/MenuItem.d.ts +7 -0
  16. package/es/Menu/index.d.ts +1 -0
  17. package/es/Navigator/style/index.less +13 -9
  18. package/es/Table/index.d.ts +1 -1
  19. package/es/Table/index.js +183 -48
  20. package/es/Table/interface.d.ts +26 -6
  21. package/es/Table/react-table-config.d.ts +122 -0
  22. package/es/Table/style/index.less +39 -9
  23. package/es/Tabs/index.d.ts +1 -0
  24. package/es/index.d.ts +10 -0
  25. package/lib/Dropdown/index.d.ts +1 -0
  26. package/lib/Icon/iconfont/demo_index.html +49 -3
  27. package/lib/Icon/iconfont/iconfont.css +11 -3
  28. package/lib/Icon/iconfont/iconfont.js +5 -5
  29. package/lib/Icon/iconfont/iconfont.json +14 -0
  30. package/lib/Icon/iconfont/iconfont.ttf +0 -0
  31. package/lib/Icon/iconfont/iconfont.woff +0 -0
  32. package/lib/Icon/iconfont/iconfont.woff2 +0 -0
  33. package/lib/Icon/index.less +2 -2
  34. package/lib/Input/components/Group/index.d.ts +3 -1
  35. package/lib/Input/components/Password/index.d.ts +4 -2
  36. package/lib/Input/components/Password/index.js +2 -2
  37. package/lib/Input/index.d.ts +1 -1
  38. package/lib/Menu/Divider.d.ts +1 -0
  39. package/lib/Menu/MenuItem.d.ts +7 -0
  40. package/lib/Menu/index.d.ts +1 -0
  41. package/lib/Navigator/style/index.less +13 -9
  42. package/lib/Table/index.d.ts +1 -1
  43. package/lib/Table/index.js +191 -54
  44. package/lib/Table/interface.d.ts +26 -6
  45. package/lib/Table/react-table-config.d.ts +122 -0
  46. package/lib/Table/style/index.less +39 -9
  47. package/lib/Tabs/index.d.ts +1 -0
  48. package/lib/index.d.ts +10 -0
  49. package/package.json +1 -1
  50. package/es/Button/demo/Icon/index.d.ts +0 -3
  51. package/es/Button/demo/Icon/index.js +0 -67
  52. package/es/Button/demo/Icon/index.less +0 -6
  53. package/es/Button/demo/basic/index.d.ts +0 -4
  54. package/es/Button/demo/basic/index.js +0 -57
  55. package/es/Button/demo/basic/index.less +0 -6
  56. package/es/Button/demo/disable/index.d.ts +0 -3
  57. package/es/Button/demo/disable/index.js +0 -23
  58. package/es/Button/demo/disable/index.less +0 -0
  59. package/es/Button/demo/href/index.d.ts +0 -2
  60. package/es/Button/demo/href/index.js +0 -17
  61. package/es/Button/demo/loading/index.d.ts +0 -3
  62. package/es/Button/demo/loading/index.js +0 -37
  63. package/es/Button/demo/loading/index.less +0 -6
  64. package/es/Dropdown/demo/basic/index.d.ts +0 -4
  65. package/es/Dropdown/demo/basic/index.js +0 -18
  66. package/es/Dropdown/demo/button/index.d.ts +0 -3
  67. package/es/Dropdown/demo/button/index.js +0 -159
  68. package/es/Dropdown/demo/button/index.less +0 -9
  69. package/es/Dropdown/demo/placement/index.d.ts +0 -2
  70. package/es/Dropdown/demo/placement/index.js +0 -40
  71. package/es/Dropdown/demo/subMenu/index.d.ts +0 -2
  72. package/es/Dropdown/demo/subMenu/index.js +0 -42
  73. package/es/Dropdown/demo/trigger/index.d.ts +0 -2
  74. package/es/Dropdown/demo/trigger/index.js +0 -17
  75. package/es/Input/demo/allowClear/index.d.ts +0 -3
  76. package/es/Input/demo/allowClear/index.js +0 -11
  77. package/es/Input/demo/allowClear/index.less +0 -0
  78. package/es/Input/demo/basic/index.d.ts +0 -4
  79. package/es/Input/demo/basic/index.js +0 -65
  80. package/es/Input/demo/basic/index.less +0 -6
  81. package/es/Input/demo/gourp/index.d.ts +0 -2
  82. package/es/Input/demo/gourp/index.js +0 -67
  83. package/es/Input/demo/password/index.d.ts +0 -3
  84. package/es/Input/demo/password/index.js +0 -21
  85. package/es/Input/demo/password/index.less +0 -0
  86. package/es/Input/demo/prefix/index.d.ts +0 -3
  87. package/es/Input/demo/prefix/index.js +0 -17
  88. package/es/Input/demo/prefix/index.less +0 -0
  89. package/es/Input/demo/showCount/index.d.ts +0 -3
  90. package/es/Input/demo/showCount/index.js +0 -17
  91. package/es/Input/demo/showCount/index.less +0 -0
  92. package/es/Input/demo/textArea/autoSize.d.ts +0 -2
  93. package/es/Input/demo/textArea/autoSize.js +0 -50
  94. package/es/Navigator/demo/basic/index.d.ts +0 -4
  95. package/es/Navigator/demo/basic/index.js +0 -45
  96. package/es/Navigator/demo/basic/index.less +0 -3
  97. package/es/Navigator/demo/example/index.d.ts +0 -4
  98. package/es/Navigator/demo/example/index.js +0 -153
  99. package/es/Navigator/demo/example/index.less +0 -10
  100. package/es/Navigator/demo/logo.png +0 -0
  101. package/es/Navigator/demo/menuWithFooter/index.d.ts +0 -4
  102. package/es/Navigator/demo/menuWithFooter/index.js +0 -73
  103. package/es/Navigator/demo/menuWithFooter/index.less +0 -3
  104. package/es/Navigator/demo/subMenu/index.d.ts +0 -4
  105. package/es/Navigator/demo/subMenu/index.js +0 -71
  106. package/es/Navigator/demo/subMenu/index.less +0 -3
  107. package/es/Select/demo/disabled/index.d.ts +0 -2
  108. package/es/Select/demo/disabled/index.js +0 -50
  109. package/es/Select/demo/multiple/index.d.ts +0 -2
  110. package/es/Select/demo/multiple/index.js +0 -140
  111. package/es/Select/demo/options/index.d.ts +0 -2
  112. package/es/Select/demo/options/index.js +0 -55
  113. package/es/Select/demo/single/index.d.ts +0 -3
  114. package/es/Select/demo/single/index.js +0 -89
  115. package/es/Select/demo/single/index.less +0 -5
  116. package/es/Table/demo/basic/createData.d.ts +0 -9
  117. package/es/Table/demo/basic/createData.js +0 -18
  118. package/es/Table/demo/basic/index.d.ts +0 -2
  119. package/es/Table/demo/basic/index.js +0 -64
  120. package/es/Table/demo/editCell/index.d.ts +0 -2
  121. package/es/Table/demo/editCell/index.js +0 -39
  122. package/es/Table/demo/renderHeaderRight/index.d.ts +0 -2
  123. package/es/Table/demo/renderHeaderRight/index.js +0 -37
  124. package/es/Table/demo/rowSelect/index.d.ts +0 -2
  125. package/es/Table/demo/rowSelect/index.js +0 -40
  126. package/es/Table/demo/virtualList/index.d.ts +0 -2
  127. package/es/Table/demo/virtualList/index.js +0 -88
  128. package/es/Tabs/demo/adaptHeight/index.d.ts +0 -3
  129. package/es/Tabs/demo/adaptHeight/index.js +0 -19
  130. package/es/Tabs/demo/adaptHeight/index.less +0 -3
  131. package/es/Tabs/demo/basic/index.d.ts +0 -4
  132. package/es/Tabs/demo/basic/index.js +0 -44
  133. package/es/Tabs/demo/basic/index.less +0 -5
  134. package/es/Tabs/demo/horizontalScroll/index.d.ts +0 -3
  135. package/es/Tabs/demo/horizontalScroll/index.js +0 -30
  136. package/es/Tabs/demo/horizontalScroll/index.less +0 -3
  137. package/es/Tooltip/demo/basic/index.d.ts +0 -2
  138. package/es/Tooltip/demo/basic/index.js +0 -7
  139. package/es/Tooltip/demo/overflow/index.d.ts +0 -2
  140. package/es/Tooltip/demo/overflow/index.js +0 -7
  141. package/es/Tooltip/demo/placement/index.d.ts +0 -6
  142. package/es/Tooltip/demo/placement/index.js +0 -70
  143. package/es/Tooltip/demo/placement/index.less +0 -7
  144. package/es/Tooltip/demo/trigger/index.d.ts +0 -3
  145. package/es/Tooltip/demo/trigger/index.js +0 -20
  146. package/es/Tooltip/demo/trigger/index.less +0 -5
  147. package/lib/Button/demo/Icon/index.d.ts +0 -3
  148. package/lib/Button/demo/Icon/index.js +0 -82
  149. package/lib/Button/demo/Icon/index.less +0 -6
  150. package/lib/Button/demo/basic/index.d.ts +0 -4
  151. package/lib/Button/demo/basic/index.js +0 -73
  152. package/lib/Button/demo/basic/index.less +0 -6
  153. package/lib/Button/demo/disable/index.d.ts +0 -3
  154. package/lib/Button/demo/disable/index.js +0 -37
  155. package/lib/Button/demo/disable/index.less +0 -0
  156. package/lib/Button/demo/href/index.d.ts +0 -2
  157. package/lib/Button/demo/href/index.js +0 -30
  158. package/lib/Button/demo/loading/index.d.ts +0 -3
  159. package/lib/Button/demo/loading/index.js +0 -51
  160. package/lib/Button/demo/loading/index.less +0 -6
  161. package/lib/Dropdown/demo/basic/index.d.ts +0 -4
  162. package/lib/Dropdown/demo/basic/index.js +0 -35
  163. package/lib/Dropdown/demo/button/index.d.ts +0 -3
  164. package/lib/Dropdown/demo/button/index.js +0 -182
  165. package/lib/Dropdown/demo/button/index.less +0 -9
  166. package/lib/Dropdown/demo/placement/index.d.ts +0 -2
  167. package/lib/Dropdown/demo/placement/index.js +0 -56
  168. package/lib/Dropdown/demo/subMenu/index.d.ts +0 -2
  169. package/lib/Dropdown/demo/subMenu/index.js +0 -59
  170. package/lib/Dropdown/demo/trigger/index.d.ts +0 -2
  171. package/lib/Dropdown/demo/trigger/index.js +0 -32
  172. package/lib/Input/demo/allowClear/index.d.ts +0 -3
  173. package/lib/Input/demo/allowClear/index.js +0 -25
  174. package/lib/Input/demo/allowClear/index.less +0 -0
  175. package/lib/Input/demo/basic/index.d.ts +0 -4
  176. package/lib/Input/demo/basic/index.js +0 -80
  177. package/lib/Input/demo/basic/index.less +0 -6
  178. package/lib/Input/demo/gourp/index.d.ts +0 -2
  179. package/lib/Input/demo/gourp/index.js +0 -81
  180. package/lib/Input/demo/password/index.d.ts +0 -3
  181. package/lib/Input/demo/password/index.js +0 -35
  182. package/lib/Input/demo/password/index.less +0 -0
  183. package/lib/Input/demo/prefix/index.d.ts +0 -3
  184. package/lib/Input/demo/prefix/index.js +0 -32
  185. package/lib/Input/demo/prefix/index.less +0 -0
  186. package/lib/Input/demo/showCount/index.d.ts +0 -3
  187. package/lib/Input/demo/showCount/index.js +0 -31
  188. package/lib/Input/demo/showCount/index.less +0 -0
  189. package/lib/Input/demo/textArea/autoSize.d.ts +0 -2
  190. package/lib/Input/demo/textArea/autoSize.js +0 -63
  191. package/lib/Navigator/demo/basic/index.d.ts +0 -4
  192. package/lib/Navigator/demo/basic/index.js +0 -62
  193. package/lib/Navigator/demo/basic/index.less +0 -3
  194. package/lib/Navigator/demo/example/index.d.ts +0 -4
  195. package/lib/Navigator/demo/example/index.js +0 -179
  196. package/lib/Navigator/demo/example/index.less +0 -10
  197. package/lib/Navigator/demo/logo.png +0 -0
  198. package/lib/Navigator/demo/menuWithFooter/index.d.ts +0 -4
  199. package/lib/Navigator/demo/menuWithFooter/index.js +0 -92
  200. package/lib/Navigator/demo/menuWithFooter/index.less +0 -3
  201. package/lib/Navigator/demo/subMenu/index.d.ts +0 -4
  202. package/lib/Navigator/demo/subMenu/index.js +0 -88
  203. package/lib/Navigator/demo/subMenu/index.less +0 -3
  204. package/lib/Select/demo/disabled/index.d.ts +0 -2
  205. package/lib/Select/demo/disabled/index.js +0 -64
  206. package/lib/Select/demo/multiple/index.d.ts +0 -2
  207. package/lib/Select/demo/multiple/index.js +0 -154
  208. package/lib/Select/demo/options/index.d.ts +0 -2
  209. package/lib/Select/demo/options/index.js +0 -69
  210. package/lib/Select/demo/single/index.d.ts +0 -3
  211. package/lib/Select/demo/single/index.js +0 -103
  212. package/lib/Select/demo/single/index.less +0 -5
  213. package/lib/Table/demo/basic/createData.d.ts +0 -9
  214. package/lib/Table/demo/basic/createData.js +0 -23
  215. package/lib/Table/demo/basic/index.d.ts +0 -2
  216. package/lib/Table/demo/basic/index.js +0 -80
  217. package/lib/Table/demo/editCell/index.d.ts +0 -2
  218. package/lib/Table/demo/editCell/index.js +0 -54
  219. package/lib/Table/demo/renderHeaderRight/index.d.ts +0 -2
  220. package/lib/Table/demo/renderHeaderRight/index.js +0 -52
  221. package/lib/Table/demo/rowSelect/index.d.ts +0 -2
  222. package/lib/Table/demo/rowSelect/index.js +0 -55
  223. package/lib/Table/demo/virtualList/index.d.ts +0 -2
  224. package/lib/Table/demo/virtualList/index.js +0 -103
  225. package/lib/Tabs/demo/adaptHeight/index.d.ts +0 -3
  226. package/lib/Tabs/demo/adaptHeight/index.js +0 -34
  227. package/lib/Tabs/demo/adaptHeight/index.less +0 -3
  228. package/lib/Tabs/demo/basic/index.d.ts +0 -4
  229. package/lib/Tabs/demo/basic/index.js +0 -67
  230. package/lib/Tabs/demo/basic/index.less +0 -5
  231. package/lib/Tabs/demo/horizontalScroll/index.d.ts +0 -3
  232. package/lib/Tabs/demo/horizontalScroll/index.js +0 -45
  233. package/lib/Tabs/demo/horizontalScroll/index.less +0 -3
  234. package/lib/Tooltip/demo/basic/index.d.ts +0 -2
  235. package/lib/Tooltip/demo/basic/index.js +0 -20
  236. package/lib/Tooltip/demo/overflow/index.d.ts +0 -2
  237. package/lib/Tooltip/demo/overflow/index.js +0 -20
  238. package/lib/Tooltip/demo/placement/index.d.ts +0 -6
  239. package/lib/Tooltip/demo/placement/index.js +0 -86
  240. package/lib/Tooltip/demo/placement/index.less +0 -7
  241. package/lib/Tooltip/demo/trigger/index.d.ts +0 -3
  242. package/lib/Tooltip/demo/trigger/index.js +0 -34
  243. package/lib/Tooltip/demo/trigger/index.less +0 -5
@@ -1,65 +0,0 @@
1
- function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
2
-
3
- function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
4
-
5
- function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
6
-
7
- function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
8
-
9
- function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
10
-
11
- function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
12
-
13
- import React from 'react';
14
- import { Input } from '@aloudata/aloudata-design';
15
- import '../../style';
16
- import './index.less';
17
- export default (function () {
18
- var _React$useState = React.useState(''),
19
- _React$useState2 = _slicedToArray(_React$useState, 2),
20
- value = _React$useState2[0],
21
- setValue = _React$useState2[1];
22
-
23
- var onChange = function onChange(e) {
24
- setValue(e.target.value);
25
- };
26
-
27
- return /*#__PURE__*/React.createElement("div", {
28
- className: 'ald-input-demo'
29
- }, /*#__PURE__*/React.createElement(Input, {
30
- style: {
31
- width: 240
32
- },
33
- className: "ald-input",
34
- size: "small",
35
- placeholder: "small"
36
- }), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement(Input, {
37
- style: {
38
- width: 240
39
- },
40
- className: "ald-input",
41
- placeholder: "default"
42
- }), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement(Input, {
43
- value: value,
44
- style: {
45
- width: 240
46
- },
47
- className: "ald-input",
48
- size: "large",
49
- onChange: onChange,
50
- placeholder: "large"
51
- }), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement(Input, {
52
- style: {
53
- width: 240
54
- },
55
- size: "large",
56
- className: "ald-input",
57
- defaultValue: 'Input large size with value'
58
- }), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement(Input, {
59
- style: {
60
- width: 240
61
- },
62
- disabled: true,
63
- value: "disabled"
64
- }));
65
- });
@@ -1,6 +0,0 @@
1
- .ald-input-demo {
2
- .ald-input {
3
- margin-bottom: 12px;
4
- margin-right: 8px;
5
- }
6
- }
@@ -1,2 +0,0 @@
1
- declare const _default: () => JSX.Element;
2
- export default _default;
@@ -1,67 +0,0 @@
1
- import "antd/es/radio/style";
2
- import _Radio from "antd/es/radio";
3
-
4
- function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
5
-
6
- function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
7
-
8
- function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
9
-
10
- function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
11
-
12
- function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
13
-
14
- function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
15
-
16
- import React from 'react';
17
- import { Input } from '@aloudata/aloudata-design';
18
- export default (function () {
19
- var _React$useState = React.useState('large'),
20
- _React$useState2 = _slicedToArray(_React$useState, 2),
21
- size = _React$useState2[0],
22
- setSize = _React$useState2[1];
23
-
24
- var _React$useState3 = React.useState(false),
25
- _React$useState4 = _slicedToArray(_React$useState3, 2),
26
- compact = _React$useState4[0],
27
- setCompact = _React$useState4[1];
28
-
29
- var handleSizeChange = function handleSizeChange(e) {
30
- setSize(e.target.value);
31
- };
32
-
33
- var handleCompactChange = function handleCompactChange(e) {
34
- setCompact(e.target.value);
35
- };
36
-
37
- return /*#__PURE__*/React.createElement("div", {
38
- className: "ald-input-demo"
39
- }, /*#__PURE__*/React.createElement(_Radio.Group, {
40
- value: size,
41
- onChange: handleSizeChange
42
- }, /*#__PURE__*/React.createElement(_Radio.Button, {
43
- value: "large"
44
- }, "Large"), /*#__PURE__*/React.createElement(_Radio.Button, null, "Default"), /*#__PURE__*/React.createElement(_Radio.Button, {
45
- value: "small"
46
- }, "Small")), /*#__PURE__*/React.createElement(_Radio.Group, {
47
- value: compact,
48
- onChange: handleCompactChange
49
- }, /*#__PURE__*/React.createElement(_Radio.Button, {
50
- value: true
51
- }, "compact\u7D27\u51D1\u6A21\u5F0F"), /*#__PURE__*/React.createElement(_Radio.Button, {
52
- value: false
53
- }, "\u6B63\u5E38\u6A21\u5F0F")), /*#__PURE__*/React.createElement(Input.Group, {
54
- size: size,
55
- compact: compact
56
- }, /*#__PURE__*/React.createElement(Input, {
57
- style: {
58
- width: '10%'
59
- },
60
- defaultValue: "+80"
61
- }), /*#__PURE__*/React.createElement(Input, {
62
- style: {
63
- width: '40%'
64
- },
65
- defaultValue: "13389898989"
66
- })));
67
- });
@@ -1,3 +0,0 @@
1
- import './index.less';
2
- declare const _default: () => JSX.Element;
3
- export default _default;
@@ -1,21 +0,0 @@
1
- import React from 'react';
2
- import { Input } from '@aloudata/aloudata-design';
3
- import './index.less';
4
- export default (function () {
5
- return /*#__PURE__*/React.createElement("div", {
6
- className: "ald-input-demo"
7
- }, /*#__PURE__*/React.createElement(Input.Password, {
8
- className: "ald-input",
9
- style: {
10
- width: 240
11
- },
12
- size: "small",
13
- placeholder: "123"
14
- }), /*#__PURE__*/React.createElement(Input.Password, {
15
- style: {
16
- width: 240
17
- },
18
- size: "large",
19
- placeholder: "123"
20
- }));
21
- });
File without changes
@@ -1,3 +0,0 @@
1
- import './index.less';
2
- declare const _default: () => JSX.Element;
3
- export default _default;
@@ -1,17 +0,0 @@
1
- import React from 'react';
2
- import { Input } from '@aloudata/aloudata-design';
3
- import './index.less';
4
- import Icon from '../../../Icon';
5
- export default (function () {
6
- return /*#__PURE__*/React.createElement("div", {
7
- className: "ald-input-demo"
8
- }, /*#__PURE__*/React.createElement(Input, {
9
- prefix: /*#__PURE__*/React.createElement("span", null, "prefix"),
10
- placeholder: "placeholder"
11
- }), /*#__PURE__*/React.createElement(Input, {
12
- prefix: /*#__PURE__*/React.createElement(Icon, {
13
- type: "Groupby_flash_on_line"
14
- }),
15
- placeholder: "placeholder"
16
- }));
17
- });
File without changes
@@ -1,3 +0,0 @@
1
- import './index.less';
2
- declare const _default: () => JSX.Element;
3
- export default _default;
@@ -1,17 +0,0 @@
1
- import React from 'react';
2
- import { Input } from '@aloudata/aloudata-design';
3
- import './index.less';
4
- export default (function () {
5
- return /*#__PURE__*/React.createElement("div", {
6
- className: "ald-input-demo"
7
- }, /*#__PURE__*/React.createElement(Input, {
8
- showCount: {
9
- formatter: function formatter(info) {
10
- var count = info.count,
11
- maxLength = info.maxLength;
12
- return "\u5F53\u524D\u957F\u5EA6\u4E3A\uFF1A".concat(count, ",\u6700\u5927\u957F\u5EA6\u4E3A\uFF1A").concat(maxLength);
13
- }
14
- },
15
- maxLength: 10
16
- }));
17
- });
File without changes
@@ -1,2 +0,0 @@
1
- declare const _default: () => JSX.Element;
2
- export default _default;
@@ -1,50 +0,0 @@
1
- function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
2
-
3
- function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
4
-
5
- function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
6
-
7
- function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
8
-
9
- function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
10
-
11
- function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
12
-
13
- import React from 'react';
14
- import { Input, Button } from '@aloudata/aloudata-design';
15
- export default (function () {
16
- var _React$useState = React.useState(1),
17
- _React$useState2 = _slicedToArray(_React$useState, 2),
18
- maxRow = _React$useState2[0],
19
- setMaxRow = _React$useState2[1];
20
-
21
- var onClick = function onClick() {
22
- setMaxRow(maxRow + 1);
23
- };
24
-
25
- var showCount = function showCount(args) {
26
- var count = args.count,
27
- maxLength = args.maxLength;
28
- return "\u5F53\u524D\u957F\u5EA6\u4E3A\uFF1A".concat(count, ",\u6700\u5927\u957F\u5EA6\u4E3A\uFF1A").concat(maxLength);
29
- };
30
-
31
- return /*#__PURE__*/React.createElement("div", {
32
- className: "ald-input-demo"
33
- }, /*#__PURE__*/React.createElement("span", null, "autoSize\u5C5E\u6027\u81EA\u52A8\u8C03\u6574\u9AD8\u5EA6\uFF0C\u4E0D\u53EF\u62D6\u62FD\u8C03\u9AD8\uFF0C\u5F53\u524D\u6700\u9AD8", maxRow, "\u884C"), /*#__PURE__*/React.createElement(Button, {
34
- size: "small",
35
- onClick: onClick
36
- }, "\u589E\u52A0\u6700\u5927\u884C\u6570"), /*#__PURE__*/React.createElement(Input.TextArea, {
37
- id: "ald-input-textArea",
38
- maxLength: 20,
39
- autoSize: {
40
- minRows: 1,
41
- maxRows: maxRow
42
- }
43
- }), /*#__PURE__*/React.createElement("span", null, "\u5E26\u5C55\u793A\u5B57\u6570\u63D0\u793A"), /*#__PURE__*/React.createElement(Input.TextArea, {
44
- id: "ald-input-textArea",
45
- showCount: {
46
- formatter: showCount
47
- },
48
- maxLength: 20
49
- }));
50
- });
@@ -1,4 +0,0 @@
1
- import '../../style/index.less';
2
- import './index.less';
3
- declare const _default: () => JSX.Element;
4
- export default _default;
@@ -1,45 +0,0 @@
1
- import React from 'react';
2
- import { Navigator } from '@aloudata/aloudata-design';
3
- import logoSrc from '../logo.png';
4
- import Icon from '../../../Icon'; // import { IMenuItem } from '@aloudata/aloudata-design/lib/Navigator';
5
-
6
- import '../../style/index.less';
7
- import './index.less';
8
- export default (function () {
9
- var mockData = [{
10
- title: '查询',
11
- icon: /*#__PURE__*/React.createElement(Icon, {
12
- type: 'add'
13
- }),
14
- key: 'query',
15
- path: '/query'
16
- }, {
17
- title: '数据',
18
- icon: /*#__PURE__*/React.createElement(Icon, {
19
- type: 'add'
20
- }),
21
- key: 'data',
22
- path: '/data'
23
- }, {
24
- title: '计算',
25
- icon: /*#__PURE__*/React.createElement(Icon, {
26
- type: 'add'
27
- }),
28
- key: 'calculate',
29
- path: '/calculate'
30
- }, {
31
- title: '测试',
32
- icon: /*#__PURE__*/React.createElement(Icon, {
33
- type: 'add'
34
- }),
35
- key: 'test',
36
- path: '/calculate'
37
- }];
38
- return /*#__PURE__*/React.createElement("div", {
39
- className: 'ald-nav-demo'
40
- }, /*#__PURE__*/React.createElement(Navigator, {
41
- menuList: mockData,
42
- defaultSelectedKey: "dataSpace",
43
- logoSrc: logoSrc
44
- }));
45
- });
@@ -1,3 +0,0 @@
1
- .ald-nav-demo {
2
- height: 300px;
3
- }
@@ -1,4 +0,0 @@
1
- import '../../style/index.less';
2
- import './index.less';
3
- declare const _default: () => JSX.Element;
4
- export default _default;
@@ -1,153 +0,0 @@
1
- function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
2
-
3
- function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
4
-
5
- function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
6
-
7
- function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
8
-
9
- function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
10
-
11
- function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
12
-
13
- function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
14
-
15
- function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
16
-
17
- function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
18
-
19
- import React, { useState, useMemo } from 'react';
20
- import { Navigator, Button } from '@aloudata/aloudata-design';
21
- import Icon from '../../../Icon';
22
- import logoSrc from '../logo.png';
23
- import { useLocation } from 'umi';
24
- import _ from 'lodash';
25
- import '../../style/index.less';
26
- import './index.less';
27
- var mockData = [{
28
- title: '查询',
29
- icon: /*#__PURE__*/React.createElement(Icon, {
30
- type: 'add'
31
- }),
32
- key: 'query',
33
- path: '/navigator#search'
34
- }, {
35
- title: '数据',
36
- icon: /*#__PURE__*/React.createElement(Icon, {
37
- type: 'add'
38
- }),
39
- key: 'data',
40
- path: '/navigator#data',
41
- children: [{
42
- title: '数据空间',
43
- key: 'dataSpace',
44
- path: '/navigator#dataSpace'
45
- }, {
46
- title: '数据源',
47
- key: 'datasource',
48
- path: '/navigator#datasource'
49
- }]
50
- }, {
51
- title: '计算',
52
- icon: /*#__PURE__*/React.createElement(Icon, {
53
- type: 'add'
54
- }),
55
- key: 'calculate',
56
- path: '/navigator#calculate',
57
- children: [{
58
- title: '任务记录',
59
- key: 'job',
60
- path: '/navigator#job'
61
- }, {
62
- title: '查询引擎',
63
- key: 'queryEngine',
64
- path: '/navigator#queryEngine'
65
- }]
66
- }, {
67
- title: '测试',
68
- key: 'test',
69
- icon: /*#__PURE__*/React.createElement(Icon, {
70
- type: 'add'
71
- }),
72
- path: '/navigator#calculate',
73
- children: [{
74
- title: '测试菜单1',
75
- key: 'hello',
76
- path: '/navigator#hello'
77
- }, {
78
- title: '测试菜单2',
79
- key: 'hello2',
80
- path: '/navigator#hello2'
81
- }]
82
- }];
83
- export default (function () {
84
- // 根据路由信息去匹配菜单信息
85
- var _useLocation = useLocation(),
86
- pathname = _useLocation.pathname;
87
-
88
- var flattenMenuByMenuPath = useMemo(function () {
89
- return getFlattenMenuByPath(mockData);
90
- }, []);
91
-
92
- var menuInfo = _.get(flattenMenuByMenuPath, pathname, {
93
- path: '',
94
- key: ''
95
- });
96
-
97
- var _useState = useState(menuInfo.key || ''),
98
- _useState2 = _slicedToArray(_useState, 2),
99
- selectedKey = _useState2[0],
100
- setSelectedKey = _useState2[1];
101
-
102
- var onMenuSelect = function onMenuSelect(menuInfo) {
103
- console.log('menuInfo', menuInfo);
104
- var path = menuInfo.path; // 进行路由跳转
105
- };
106
-
107
- var mockBtnClick = function mockBtnClick(key) {
108
- setSelectedKey(key);
109
- };
110
-
111
- return /*#__PURE__*/React.createElement("div", {
112
- className: 'ald-nav-demo-example'
113
- }, /*#__PURE__*/React.createElement(Navigator, {
114
- menuList: mockData,
115
- selectedKey: selectedKey,
116
- footer: /*#__PURE__*/React.createElement("div", null, "Footer Wrap"),
117
- logoSrc: logoSrc,
118
- onMenuSelect: onMenuSelect
119
- }), /*#__PURE__*/React.createElement("div", {
120
- className: 'ald-nav-content'
121
- }, /*#__PURE__*/React.createElement("p", null, "\u5F53\u524D\u83DC\u5355\uFF1A", selectedKey), /*#__PURE__*/React.createElement(Button, {
122
- onClick: function onClick() {
123
- return mockBtnClick('query');
124
- }
125
- }, "\u6A21\u62DF\u67E5\u8BE2\u9875\u9762\u5237\u65B0"), /*#__PURE__*/React.createElement(Button, {
126
- onClick: function onClick() {
127
- return mockBtnClick('dataSpace');
128
- }
129
- }, "\u6A21\u62DF\u6570\u636E\u7A7A\u95F4\u5237\u65B0"), /*#__PURE__*/React.createElement(Button, {
130
- onClick: function onClick() {
131
- return mockBtnClick('job');
132
- }
133
- }, "\u6A21\u62DF\u4EFB\u52A1\u8BB0\u5F55\u5237\u65B0")));
134
- });
135
-
136
- function getFlattenMenuByPath(menuList) {
137
- var flattenMenuByMenuPath = {};
138
- menuList.forEach(function (item) {
139
- if (!item.path) {
140
- console.error('path is required');
141
- }
142
-
143
- if (item.children) {
144
- flattenMenuByMenuPath[item.path] = _objectSpread({}, item);
145
- item.children.forEach(function (childItem) {
146
- flattenMenuByMenuPath[childItem.path] = _objectSpread({}, childItem);
147
- });
148
- } else {
149
- flattenMenuByMenuPath[item.path] = _objectSpread({}, item);
150
- }
151
- });
152
- return flattenMenuByMenuPath;
153
- }
@@ -1,10 +0,0 @@
1
- .ald-nav-demo-example {
2
- border: 1px solid #ccc;
3
- width: 800px;
4
- height: 600px;
5
- display: flex;
6
-
7
- .ald-nav-content {
8
- padding: 24px;
9
- }
10
- }
Binary file
@@ -1,4 +0,0 @@
1
- import '../../style/index.less';
2
- import './index.less';
3
- declare const _default: () => JSX.Element;
4
- export default _default;
@@ -1,73 +0,0 @@
1
- import React from 'react';
2
- import { Navigator } from '@aloudata/aloudata-design';
3
- import logoSrc from '../logo.png';
4
- import Icon from '../../../Icon';
5
- import '../../style/index.less';
6
- import './index.less';
7
- export default (function () {
8
- var mockData = [{
9
- title: '查询',
10
- icon: /*#__PURE__*/React.createElement(Icon, {
11
- type: 'add'
12
- }),
13
- key: 'query',
14
- path: '/query'
15
- }, {
16
- title: '数据',
17
- icon: /*#__PURE__*/React.createElement(Icon, {
18
- type: 'add'
19
- }),
20
- key: 'data',
21
- path: '/data',
22
- children: [{
23
- title: '数据空间',
24
- key: 'dataSpace',
25
- path: '/data/dataSpace'
26
- }, {
27
- title: '数据源',
28
- key: 'datasource',
29
- path: '/data/datasource'
30
- }]
31
- }, {
32
- title: '计算',
33
- icon: /*#__PURE__*/React.createElement(Icon, {
34
- type: 'add'
35
- }),
36
- key: 'calculate',
37
- path: '/calculate',
38
- children: [{
39
- title: '任务记录',
40
- key: 'job',
41
- path: '/calculate/job'
42
- }, {
43
- title: '查询引擎',
44
- key: 'queryEngine',
45
- path: '/calculate/'
46
- }]
47
- }, {
48
- title: '测试',
49
- icon: /*#__PURE__*/React.createElement(Icon, {
50
- type: 'add'
51
- }),
52
- key: 'test',
53
- path: '/calculate',
54
- children: [{
55
- title: '测试菜单1',
56
- key: 'hello',
57
- path: '/calculate/job'
58
- }, {
59
- title: '测试菜单2',
60
- key: 'hello2',
61
- path: '/calculate/'
62
- }]
63
- }];
64
- var footer = /*#__PURE__*/React.createElement("div", null, "Footer Wrap");
65
- return /*#__PURE__*/React.createElement("div", {
66
- className: 'ald-nav-demo'
67
- }, /*#__PURE__*/React.createElement(Navigator, {
68
- menuList: mockData,
69
- defaultSelectedKey: "dataSpace",
70
- footer: footer,
71
- logoSrc: logoSrc
72
- }));
73
- });
@@ -1,3 +0,0 @@
1
- .ald-nav-demo {
2
- height: 600px;
3
- }
@@ -1,4 +0,0 @@
1
- import '../../style/index.less';
2
- import './index.less';
3
- declare const _default: () => JSX.Element;
4
- export default _default;