@hi-ui/hiui 2.15.11 → 2.15.12
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/es/_util/SwitchVersion.js +40 -0
- package/es/_util/depreactedPropsCompat.js +58 -0
- package/es/_util/index.js +31 -0
- package/es/_util/warning.js +2 -2
- package/es/alert/Alert.js +126 -0
- package/es/alert/__tests__/index.test.js +84 -0
- package/es/alert/index.js +6 -147
- package/es/alert/style/index.css +1 -1
- package/es/badge/Badge.js +82 -0
- package/es/badge/__tests__/index.test.js +82 -0
- package/es/badge/index.js +9 -87
- package/es/badge/style/index.css +1 -1
- package/es/badge/style/index.js +0 -0
- package/es/breadcrumb/__tests__/index.test.js +61 -0
- package/es/breadcrumb/index.js +85 -0
- package/es/breadcrumb/style/index.css +1 -0
- package/es/button/Button.js +62 -60
- package/es/button/ButtonGroup.js +24 -40
- package/es/button/IconLoading.js +6 -6
- package/es/button/__tests__/index.test.js +221 -0
- package/es/button/index.js +3 -2
- package/es/button/style/index.css +1 -1
- package/es/card/__tests__/index.test.js +179 -0
- package/es/card/index.js +61 -57
- package/es/card/style/index.css +1 -1
- package/es/carousel/__tests__/index.test.js +104 -0
- package/es/carousel/index.js +219 -0
- package/es/carousel/style/index.css +1 -0
- package/es/carousel/style/index.js +3 -0
- package/es/cascader/Cascader.js +190 -133
- package/es/cascader/Menu.js +168 -0
- package/es/cascader/__tests__/index.test.js +392 -0
- package/es/cascader/index.js +5 -2
- package/es/cascader/style/cascader.css +1 -1
- package/es/cascader/style/menu.css +1 -1
- package/es/checkbox/Checkbox.js +136 -0
- package/es/checkbox/Group.js +194 -0
- package/es/checkbox/__tests__/index.test.js +226 -0
- package/es/checkbox/checkbox-legacy/Base.js +212 -0
- package/es/checkbox/checkbox-legacy/CheckBox.js +157 -0
- package/es/checkbox/checkbox-legacy/index.js +15 -0
- package/es/checkbox/checkbox-legacy/style/index.css +1 -0
- package/es/checkbox/checkbox-legacy/style/index.js +3 -0
- package/es/checkbox/index.js +13 -4
- package/es/checkbox/style/index.css +1 -1
- package/es/collapse/__tests__/index.test.js +111 -0
- package/es/collapse/index.js +88 -110
- package/es/collapse/style/index.css +1 -1
- package/es/confirm/index.js +39 -60
- package/es/context/index.js +45 -51
- package/es/counter/Counter.js +339 -0
- package/es/counter/__tests__/index.test.js +134 -0
- package/es/counter/counter-legacy/index.js +267 -0
- package/es/counter/index.js +6 -270
- package/es/counter/style/index.css +1 -1
- package/es/date-picker/BasePicker.js +380 -302
- package/es/date-picker/Calender.js +326 -98
- package/es/date-picker/DatePanel.js +194 -213
- package/es/date-picker/DatePicker.js +143 -47
- package/es/date-picker/DateRangePanel.js +272 -208
- package/es/date-picker/Modal.js +18 -32
- package/es/date-picker/Time.js +231 -345
- package/es/date-picker/TimeList.js +246 -0
- package/es/date-picker/TimePanel.js +28 -41
- package/es/date-picker/TimePeriodPanel.js +27 -46
- package/es/date-picker/TimePicker.js +44 -46
- package/es/date-picker/TimeRangePanel.js +33 -51
- package/es/date-picker/Type.js +5 -1
- package/es/date-picker/WeekRangePanel.js +254 -175
- package/es/date-picker/YMRangePanel.js +364 -0
- package/es/date-picker/__tests__/index.test.js +956 -0
- package/es/date-picker/constants.js +14 -28
- package/es/date-picker/dateUtil.js +221 -52
- package/es/date-picker/datepicker-legacy/BasePicker.js +511 -0
- package/es/date-picker/datepicker-legacy/Calender.js +422 -0
- package/es/date-picker/datepicker-legacy/DatePanel.js +455 -0
- package/es/date-picker/datepicker-legacy/DatePicker.js +103 -0
- package/es/date-picker/datepicker-legacy/DateRangePanel.js +488 -0
- package/es/date-picker/datepicker-legacy/Modal.js +67 -0
- package/es/date-picker/datepicker-legacy/Time.js +405 -0
- package/es/date-picker/datepicker-legacy/TimePanel.js +85 -0
- package/es/date-picker/datepicker-legacy/TimePeriodPanel.js +118 -0
- package/es/date-picker/datepicker-legacy/TimePicker.js +78 -0
- package/es/date-picker/datepicker-legacy/TimeRangePanel.js +90 -0
- package/es/date-picker/datepicker-legacy/Type.js +31 -0
- package/es/date-picker/datepicker-legacy/WeekRangePanel.js +337 -0
- package/es/date-picker/datepicker-legacy/constants.js +79 -0
- package/es/date-picker/datepicker-legacy/dateUtil.js +258 -0
- package/es/date-picker/datepicker-legacy/index.js +15 -0
- package/es/date-picker/datepicker-legacy/local.js +11 -0
- package/es/date-picker/datepicker-legacy/style/index.css +1 -0
- package/es/date-picker/datepicker-legacy/style/index.js +3 -0
- package/es/date-picker/datepicker-legacy/style/timepicker.css +1 -0
- package/es/date-picker/datepicker-legacy/util.js +60 -0
- package/es/date-picker/index.js +5 -2
- package/es/date-picker/style/index.css +1 -1
- package/es/date-picker/toLunar.js +172 -0
- package/es/date-picker/util.js +101 -8
- package/es/dropdown/Dropdown.js +191 -203
- package/es/dropdown/DropdownButton.js +102 -0
- package/es/dropdown/DropdownMenu.js +107 -0
- package/es/dropdown/DropdownMenuItem.js +172 -0
- package/es/dropdown/__tests__/index.test.js +313 -0
- package/es/dropdown/index.js +69 -4
- package/es/dropdown/style/index.css +1 -1
- package/es/dropdown/style/index.js +0 -2
- package/es/dropdown/{__test__ → tests}/index.test.js +7 -7
- package/es/dropdown/utils.js +35 -0
- package/es/ficon/index.js +16 -30
- package/es/form/Form.js +176 -0
- package/es/form/{item.js → Item.js} +52 -60
- package/es/form/__tests__/index.test.js +571 -0
- package/es/form/index.js +6 -171
- package/es/form/style/index.css +1 -1
- package/es/grid/__tests__/index.test.js +100 -0
- package/es/grid/index.js +36 -56
- package/es/icon/index.js +23 -38
- package/es/index.js +61 -9
- package/es/input/Input.js +400 -0
- package/es/input/__tests__/index.test.js +376 -0
- package/es/input/index.js +26 -347
- package/es/input/input-legacy/index.js +341 -0
- package/es/input/input-legacy/util.js +176 -0
- package/es/input/style/index.css +1 -1
- package/es/input/util.js +26 -18
- package/es/lib/withDragDropContext.js +2 -2
- package/es/loading/Loading.js +173 -0
- package/es/loading/__tests__/index.test.js +110 -0
- package/es/loading/index.js +5 -129
- package/es/loading/style/index.css +0 -0
- package/es/loading/style/index.js +0 -0
- package/es/locales/en-US.js +45 -9
- package/es/locales/index.js +16 -2
- package/es/locales/zh-CN.js +46 -10
- package/es/locales/zh-Hant-HK.js +123 -0
- package/es/locales/zh-Hant-TW.js +125 -0
- package/es/menu/Item.js +34 -51
- package/es/menu/Menu.js +414 -0
- package/es/menu/SubMenu.js +63 -90
- package/es/menu/Title.js +37 -51
- package/es/menu/__tests__/index.test.js +274 -0
- package/es/menu/index.js +12 -419
- package/es/menu/style/index.css +1 -1
- package/es/message/__tests__/index.test.js +71 -0
- package/es/message/index.js +58 -0
- package/es/message/style/index.css +1 -0
- package/es/message/style/index.js +5 -0
- package/es/modal/__tests__/index.test.js +178 -0
- package/es/modal/index.js +85 -77
- package/es/modal/style/index.css +1 -1
- package/es/nav-menu/NavMenu.js +44 -61
- package/es/nav-menu/__test__/index.test.js +8 -8
- package/es/nav-menu/__tests__/index.test.js +23 -0
- package/es/nav-menu/index.js +2 -2
- package/es/notice/Notice.js +136 -0
- package/es/notice/NoticeContainer.js +107 -0
- package/es/notice/__tests__/index.test.js +174 -0
- package/es/notice/index.js +66 -0
- package/es/notice/style/index.css +1 -0
- package/es/notice/style/index.js +5 -0
- package/es/notification/HandleNotification/index.js +216 -0
- package/es/notification/HandleNotification/style/index.css +1 -0
- package/es/notification/HandleNotification/style/index.js +5 -0
- package/es/notification/__tests__/index.test.js +114 -0
- package/es/notification/index.js +68 -231
- package/es/notification/style/index.css +1 -1
- package/es/notification/style/index.js +0 -0
- package/es/pagination/Pager.js +7 -9
- package/es/pagination/Pagination.js +134 -133
- package/es/pagination/__tests__/index.test.js +244 -0
- package/es/pagination/index.js +9 -8
- package/es/pagination/style/index.css +1 -1
- package/es/panel/index.js +28 -46
- package/es/popover/__test__/index.test.js +10 -10
- package/es/popover/__tests__/index.test.js +152 -0
- package/es/popover/index.js +77 -83
- package/es/popper/index.js +68 -64
- package/es/popper/style/index.css +1 -1
- package/es/preview/index.js +529 -0
- package/es/preview/style/index.css +1 -0
- package/es/preview/style/index.js +3 -0
- package/es/progress/BarProgress.js +107 -43
- package/es/progress/CircleProgress.js +13 -14
- package/es/progress/DashboardProgress.js +11 -13
- package/es/progress/Progress.js +102 -0
- package/es/progress/__tests__/index.test.js +131 -0
- package/es/progress/index.js +8 -100
- package/es/progress/style/index.css +1 -1
- package/es/radio/Group.js +199 -0
- package/es/radio/Radio.js +147 -0
- package/es/radio/__tests__/index.test.js +127 -0
- package/es/radio/index.js +10 -216
- package/es/radio/{__test__ → radio-legacy/__test__}/index.test.js +13 -13
- package/es/radio/radio-legacy/index.js +214 -0
- package/es/radio/radio-legacy/style/index.css +1 -0
- package/es/radio/radio-legacy/style/index.js +3 -0
- package/es/radio/style/index.css +1 -1
- package/es/rate/Icons.js +70 -70
- package/es/rate/Rate.js +75 -108
- package/es/rate/__tests__/index.test.js +124 -0
- package/es/rate/index.js +5 -2
- package/es/rate/style/index.css +1 -1
- package/es/select/Select.js +330 -265
- package/es/select/SelectDropdown.js +223 -79
- package/es/select/SelectInput.js +120 -91
- package/es/select/__tests__/index.test.js +505 -0
- package/es/select/index.js +6 -4
- package/es/select/select-legacy/Option.js +78 -0
- package/es/select/select-legacy/Select.js +702 -0
- package/es/select/select-legacy/SelectDropdown.js +157 -0
- package/es/select/select-legacy/SelectInput.js +308 -0
- package/es/select/select-legacy/common.js +19 -0
- package/es/select/select-legacy/index.js +16 -0
- package/es/select/style/select-dropdown.css +1 -1
- package/es/select/style/select-input.css +1 -1
- package/es/stepper/Stepper.js +147 -0
- package/es/stepper/__tests__/index.test.js +161 -0
- package/es/stepper/index.js +21 -127
- package/es/stepper/style/index.css +1 -1
- package/es/style/icon/diyIcon.css +1 -1
- package/es/style/icon/index.css +1 -1
- package/es/switch/__tests__/index.test.js +68 -0
- package/es/switch/index.js +26 -46
- package/es/switch/style/index.css +1 -1
- package/es/table/Body.js +294 -0
- package/es/table/ClickOuterside.js +95 -0
- package/es/table/Footer.js +171 -0
- package/es/table/Header.js +320 -0
- package/es/table/TableContent.js +101 -0
- package/es/table/__tests__/index.test.js +129 -0
- package/es/table/checkbox/index.js +36 -47
- package/es/table/checkbox/style/index.css +1 -0
- package/es/table/checkbox/style/index.js +3 -0
- package/es/table/index.js +269 -314
- package/es/table/menu/index.js +34 -44
- package/es/table/prefix.js +2 -2
- package/es/table/style/Table.css +1 -1
- package/es/table/style/index.css +1 -1
- package/es/tabs/ItemDropdown.js +45 -65
- package/es/tabs/TabPane.js +26 -44
- package/es/tabs/Tabs.js +110 -111
- package/es/tabs/__tests__/index.test.js +329 -0
- package/es/tabs/index.js +9 -3
- package/es/tabs/style/index.css +1 -1
- package/es/tabs/tabs-legacy/ItemDropdown.js +162 -0
- package/es/tabs/tabs-legacy/TabPane.js +70 -0
- package/es/tabs/tabs-legacy/Tabs.js +291 -0
- package/es/tabs/tabs-legacy/index.js +18 -0
- package/es/tabs/tabs-legacy/style/index.css +1 -0
- package/es/tabs/tabs-legacy/style/index.js +3 -0
- package/es/tag/__tests__/index.test.js +46 -0
- package/es/tag/index.js +86 -0
- package/es/tag/style/index.css +1 -0
- package/es/tag/style/index.js +3 -0
- package/es/timeline/__tests__/index.test.js +198 -0
- package/es/timeline/index.js +206 -136
- package/es/timeline/style/index.css +1 -1
- package/es/tooltip/__tests__/index.test.js +166 -0
- package/es/tooltip/index.js +93 -52
- package/es/tooltip/style/index.css +1 -1
- package/es/transfer/Item.js +73 -71
- package/es/transfer/Transfer.js +558 -0
- package/es/transfer/__tests__/index.test.js +210 -0
- package/es/transfer/index.js +4 -443
- package/es/transfer/style/index.css +1 -1
- package/es/tree/IconLoading.js +38 -0
- package/es/tree/Tree.js +94 -111
- package/es/tree/TreeDivider.js +6 -6
- package/es/tree/TreeItem.js +217 -123
- package/es/tree/TreeNode.js +472 -333
- package/es/tree/__tests__/index.test.js +599 -0
- package/es/tree/index.js +9 -2
- package/es/tree/style/index.css +1 -1
- package/es/tree/tree-legacy/Tree.js +330 -0
- package/es/tree/tree-legacy/TreeDivider.js +25 -0
- package/es/tree/tree-legacy/TreeItem.js +326 -0
- package/es/tree/tree-legacy/TreeNode.js +711 -0
- package/es/tree/tree-legacy/index.js +13 -0
- package/es/tree/tree-legacy/style/index.css +1 -0
- package/es/tree/tree-legacy/style/index.js +3 -0
- package/es/tree/tree-legacy/util.js +434 -0
- package/es/tree/util.js +8 -256
- package/es/upload/Upload.js +292 -200
- package/es/upload/UploadAvatar.js +61 -79
- package/es/upload/UploadClick.js +62 -60
- package/es/upload/UploadDrag.js +63 -66
- package/es/upload/UploadPhoto.js +86 -75
- package/es/upload/UploadPictureCard.js +53 -60
- package/es/upload/__tests__/index.test.js +760 -0
- package/es/upload/index.js +8 -71
- package/es/upload/main.js +83 -0
- package/es/upload/style/index.css +1 -1
- package/es/upload/tool.js +0 -1
- package/es/upload/{Preview.js → upload-legacy/Preview.js} +48 -62
- package/es/upload/upload-legacy/Upload.js +431 -0
- package/es/upload/upload-legacy/UploadAvatar.js +318 -0
- package/es/upload/upload-legacy/UploadClick.js +121 -0
- package/es/upload/upload-legacy/UploadDrag.js +176 -0
- package/es/upload/upload-legacy/UploadPhoto.js +179 -0
- package/es/upload/upload-legacy/UploadPictureCard.js +122 -0
- package/es/upload/upload-legacy/index.js +67 -0
- package/es/upload/upload-legacy/style/index.css +1 -0
- package/es/upload/upload-legacy/style/index.js +5 -0
- package/es/upload/upload-legacy/tool.js +84 -0
- package/es/watermark/index.js +97 -0
- package/es/watermark/watermark.js +263 -0
- package/package.json +1 -1
- package/es/alert/__test__/index.test.js +0 -67
- package/es/button/__test__/index.test.js +0 -29
- package/es/cascader/__test__/index.test.js +0 -283
- package/es/cascader/menu.js +0 -155
- package/es/checkbox/Base.js +0 -205
- package/es/checkbox/CheckBox.js +0 -185
- package/es/collapse/__test__/index.test.js +0 -58
- package/es/counter/__test__/index.test.js +0 -52
- package/es/menu/ItemGroup.js +0 -81
- package/es/modal/__test__/index.test.js +0 -123
- package/es/notification/__test__/index.test.js +0 -56
- package/es/pagination/__test__/index.test.js +0 -140
- package/es/rate/__test__/index.test.js +0 -54
- package/es/select/Option.js +0 -93
- package/es/select/__test__/index.test.js +0 -429
- package/es/style/color/colors.css +0 -0
- package/es/style/index.css +0 -0
- package/es/style/mixins/colors.css +0 -0
- package/es/style/mixins/index.css +0 -0
- package/es/style/theme/dark.css +0 -0
- package/es/style/theme/default.css +0 -0
- package/es/switch/__test__/index.test.js +0 -39
- package/es/table/__test__/index.test.js +0 -73
- package/es/table/body.js +0 -318
- package/es/table/clickOuterside.js +0 -115
- package/es/table/footer.js +0 -196
- package/es/table/header.js +0 -337
- package/es/table/pover.js +0 -154
- package/es/table/tableContent.js +0 -120
- package/es/timeline/__test__/index.test.js +0 -49
- package/es/timeline/foldingItem.js +0 -82
- package/es/tooltip/__test__/index.test.js +0 -67
- package/es/transfer/__test__/index.test.js +0 -11
- /package/es/{style → breadcrumb/style}/index.js +0 -0
- /package/es/checkbox/{common.js → checkbox-legacy/common.js} +0 -0
- /package/es/upload/{style → upload-legacy/style}/preview.css +0 -0
- /package/es/upload/{style → upload-legacy/style}/preview.js +0 -0
package/es/table/menu/index.js
CHANGED
|
@@ -1,59 +1,44 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
+
var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard");
|
|
4
|
+
|
|
5
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
6
|
+
|
|
3
7
|
Object.defineProperty(exports, "__esModule", {
|
|
4
8
|
value: true
|
|
5
9
|
});
|
|
6
10
|
exports["default"] = void 0;
|
|
7
11
|
|
|
8
|
-
var
|
|
9
|
-
|
|
10
|
-
var _reactDom = _interopRequireDefault(require("react-dom"));
|
|
11
|
-
|
|
12
|
-
var _prefix = _interopRequireDefault(require("../prefix"));
|
|
13
|
-
|
|
14
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
15
|
-
|
|
16
|
-
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
|
|
17
|
-
|
|
18
|
-
function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
12
|
+
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
19
13
|
|
|
20
|
-
|
|
14
|
+
var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
|
|
21
15
|
|
|
22
|
-
|
|
16
|
+
var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
|
|
23
17
|
|
|
24
|
-
|
|
18
|
+
var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));
|
|
25
19
|
|
|
26
|
-
|
|
20
|
+
var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));
|
|
27
21
|
|
|
28
|
-
|
|
22
|
+
var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits"));
|
|
29
23
|
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
33
|
-
|
|
34
|
-
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
35
|
-
|
|
36
|
-
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
37
|
-
|
|
38
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
24
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
39
25
|
|
|
40
|
-
|
|
26
|
+
var _reactDom = _interopRequireDefault(require("react-dom"));
|
|
41
27
|
|
|
42
|
-
|
|
28
|
+
var _prefix = _interopRequireDefault(require("../prefix"));
|
|
43
29
|
|
|
44
30
|
// import {scrollTop, scrollLeft} from '../tool'
|
|
45
|
-
var HeaderMenu =
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
31
|
+
var HeaderMenu =
|
|
32
|
+
/*#__PURE__*/
|
|
33
|
+
function (_Component) {
|
|
34
|
+
(0, _inherits2["default"])(HeaderMenu, _Component);
|
|
49
35
|
|
|
50
36
|
function HeaderMenu() {
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
return _super.apply(this, arguments);
|
|
37
|
+
(0, _classCallCheck2["default"])(this, HeaderMenu);
|
|
38
|
+
return (0, _possibleConstructorReturn2["default"])(this, (0, _getPrototypeOf2["default"])(HeaderMenu).apply(this, arguments));
|
|
54
39
|
}
|
|
55
40
|
|
|
56
|
-
|
|
41
|
+
(0, _createClass2["default"])(HeaderMenu, [{
|
|
57
42
|
key: "render",
|
|
58
43
|
value: function render() {
|
|
59
44
|
var _this$props = this.props,
|
|
@@ -61,25 +46,26 @@ var HeaderMenu = /*#__PURE__*/function (_Component) {
|
|
|
61
46
|
freezeCol = _this$props.freezeCol,
|
|
62
47
|
hideCol = _this$props.hideCol,
|
|
63
48
|
index = _this$props.index,
|
|
64
|
-
freeze = _this$props.freeze
|
|
65
|
-
|
|
49
|
+
freeze = _this$props.freeze,
|
|
50
|
+
canHideCol = _this$props.canHideCol,
|
|
51
|
+
localeDatas = _this$props.localeDatas;
|
|
52
|
+
return _react["default"].createElement("div", {
|
|
66
53
|
className: (0, _prefix["default"])('table-header-menu')
|
|
67
|
-
},
|
|
54
|
+
}, _react["default"].createElement("p", {
|
|
68
55
|
onClick: function onClick(e) {
|
|
69
56
|
return highlighCol(index);
|
|
70
57
|
}
|
|
71
|
-
},
|
|
58
|
+
}, localeDatas.table.highlight), freeze && _react["default"].createElement("p", {
|
|
72
59
|
onClick: function onClick(e) {
|
|
73
60
|
return freezeCol(index);
|
|
74
61
|
}
|
|
75
|
-
},
|
|
62
|
+
}, localeDatas.table.freeze), canHideCol && _react["default"].createElement("p", {
|
|
76
63
|
onClick: function onClick(e) {
|
|
77
64
|
return hideCol(index);
|
|
78
65
|
}
|
|
79
|
-
},
|
|
66
|
+
}, localeDatas.table.hide));
|
|
80
67
|
}
|
|
81
68
|
}]);
|
|
82
|
-
|
|
83
69
|
return HeaderMenu;
|
|
84
70
|
}(_react.Component);
|
|
85
71
|
|
|
@@ -100,14 +86,18 @@ document.addEventListener('click', function () {
|
|
|
100
86
|
var _default = {
|
|
101
87
|
show: function show(e, cbs, key, freeze) {
|
|
102
88
|
var size = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : 'normal';
|
|
89
|
+
var canHideCol = arguments.length > 5 ? arguments[5] : undefined;
|
|
90
|
+
var localeDatas = arguments.length > 6 ? arguments[6] : undefined;
|
|
103
91
|
div && hide();
|
|
104
92
|
div = document.createElement('div');
|
|
105
93
|
div.className = 'hi-table-header-menu-' + size;
|
|
106
94
|
div.style.zIndex = '99999';
|
|
107
95
|
|
|
108
|
-
_reactDom["default"].render(
|
|
96
|
+
_reactDom["default"].render(_react["default"].createElement(HeaderMenu, (0, _extends2["default"])({}, cbs, {
|
|
97
|
+
canHideCol: canHideCol,
|
|
109
98
|
index: key,
|
|
110
|
-
freeze: freeze
|
|
99
|
+
freeze: freeze,
|
|
100
|
+
localeDatas: localeDatas
|
|
111
101
|
})), div);
|
|
112
102
|
|
|
113
103
|
div.style.position = 'absolute';
|
package/es/table/prefix.js
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
|
|
3
5
|
Object.defineProperty(exports, "__esModule", {
|
|
4
6
|
value: true
|
|
5
7
|
});
|
|
@@ -7,8 +9,6 @@ exports["default"] = _default;
|
|
|
7
9
|
|
|
8
10
|
var _classnames = _interopRequireDefault(require("classnames"));
|
|
9
11
|
|
|
10
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
11
|
-
|
|
12
12
|
var name = 'hi';
|
|
13
13
|
|
|
14
14
|
function _default() {
|
package/es/table/style/Table.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.hi-table-header-menu-small .hi-table-header-menu p{height:44px}.hi-table-header-menu-mini .hi-table-header-menu p{height:32px}.hi-table td,.hi-table th{-webkit-box-sizing:border-box;box-sizing:border-box}.hi-table-container{position:relative}.hi-table-pre-header{height:52px;line-height:52px;border-top:1px solid #e6e7e8;padding-left:8px;padding-right:16px}.hi-table-pre-footer{height:52px;line-height:52px;border-bottom:1px solid #e6e7e8;padding-left:8px;padding-right:16px;background:#f7fafe}.hi-table.striped table tr:nth-child(2n){background:#f7fafe}.hi-table.bordered .hi-table-pre-header{border-left:1px solid #e6e7e8;border-right:1px solid #e6e7e8}.hi-table.bordered .hi-table-pre-footer{border-left:1px solid #e6e7e8;border-right:1px solid #e6e7e8}.hi-table.bordered table{border-top:1px solid #e6e7e8}.hi-table.bordered table tr td,.hi-table.bordered table tr th{border-left:1px solid #e6e7e8}.hi-table.bordered table tr td:last-child,.hi-table.bordered table tr th:last-child{border-right:1px solid #e6e7e8}.hi-table.large-pre-header{height:64px;line-height:64px}.hi-table.large-pre-footer{height:64px;line-height:64px}.hi-table.large table tr{height:64px;font-size:14px}.hi-table.large .hi-table-header-menu>p{height:44px !important;font-size:14px}.hi-table.large .hi-table-setting-menu>div{height:44px}.hi-table.small-pre-header{height:44px;line-height:44px}.hi-table.small-pre-footer{height:44px;line-height:44px}.hi-table.small table tr{height:44px;font-size:14px}.hi-table.small .hi-table-header-menu>p{height:44px !important;font-size:14px}.hi-table.small .hi-table-setting-menu>div{height:44px}.hi-table.mini-pre-header{height:32px;line-height:32px}.hi-table.mini-pre-footer{height:32px;line-height:32px}.hi-table.mini table tr{height:32px;font-size:14px}.hi-table.mini .hi-table-header-menu>p{height:32px !important;font-size:32px}.hi-table.mini .hi-table-setting-menu>div{height:32px}.hi-table-header-menu{z-index:999999;background:#fff;border:1px solid #e6e7e8;-webkit-box-shadow:0 2px 8px 0 rgba(56,62,71,0.1);box-shadow:0 2px 8px 0 rgba(56,62,71,0.1);border-radius:2px;width:140px}.hi-table-header-menu p{color:#383e47;text-align:left;margin:0;height:52px;text-indent:16px;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;cursor:pointer}.hi-table-header-menu p:hover{background:#f7fafe;color:#4284f5}.hi-table-setting-menu{z-index:999999;background:#fff;border-radius:2px;width:140px}.hi-table-setting-menu>div{color:#383e47;text-align:left;margin:0;padding-left:16px;padding-right:16px;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;cursor:pointer;height:52px}.hi-table-setting-menu>div:hover{background:#f7fafe;color:#4284f5}.hi-table-setting-menu>div>p:first-child{width:140px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.hi-table-setting-menu .active{background:rgba(66,133,244,0.15)}.hi-table-setting-menu.column-menu{position:absolute;right:30px;top:40px;width:220px;max-height:240px;overflow-y:auto}.hi-table-container table{width:100%;border-collapse:separate;background:#fff;margin:0;-webkit-box-sizing:border-box;box-sizing:border-box;display:table;border-spacing:0}.hi-table-container table col{display:table-column}.hi-table-container table td,.hi-table-container table th{white-space:nowrap;padding-left:8px;padding-right:16px;border-bottom:1px solid #e6e7e8;text-align:left;-webkit-box-sizing:border-box;box-sizing:border-box}.hi-table-container table th{background-color:#f7fafe;color:#83868c;position:relative}.hi-table-container table th i:hover{color:#4284f5}.hi-table-container table td{color:#3b4148;word-break:break-word}.hi-table-container table td.picked{background:#f7fafe}.hi-table-container table tr{-webkit-transition:0.2s;transition:0.2s;height:52px;font-size:14px;padding:0;-webkit-box-sizing:border-box;box-sizing:border-box;cursor:pointer}.hi-table-container table tr.picked td{background:#f7fafe}.hi-table-container table tr.expanded{background:#f7fafe}.hi-table-container table tr:hover{background:#f7fafe}.hi-table-body-inner{height:100%}.hi-table-fixed-header>.hi-table-content>.hi-table-scroll>.hi-table-body{position:relative}.hi-table-fixed-header .hi-table-body-inner{overflow:scroll}.hi-table-fixed-header .hi-table-scroll .hi-table-header{overflow:scroll;padding-bottom:20px;margin-bottom:-20px}.hi-table-fixed-left,.hi-table-fixed-right{position:absolute;top:0;overflow:hidden;-webkit-transition:-webkit-box-shadow 0.3s ease;transition:-webkit-box-shadow 0.3s ease;transition:box-shadow 0.3s ease;transition:box-shadow 0.3s ease, -webkit-box-shadow 0.3s ease;border-radius:0}.hi-table-fixed-left table,.hi-table-fixed-right table{width:auto}.hi-table-fixed-header .hi-table-fixed-left .hi-table-body-outer .hi-table-fixed,.hi-table-fixed-header .hi-table-fixed-right .hi-table-body-outer .hi-table-fixed{border-radius:0}.hi-table-fixed-left{left:0;-webkit-box-shadow:6px 0 6px -4px rgba(0,0,0,0.15);box-shadow:6px 0 6px -4px rgba(0,0,0,0.15)}.hi-table-fixed-left .hi-table-header{overflow-y:hidden}.hi-table-fixed-left .hi-table-body-inner{margin-right:-20px;padding-right:20px}.hi-table-fixed-header .hi-table-fixed-left .hi-table-body-inner{padding-right:0}.hi-table-fixed-left,.hi-table-fixed-left table{border-radius:4px 0 0 0}.hi-table-fixed-right{right:0;-webkit-box-shadow:-6px 0 6px -4px rgba(0,0,0,0.15);box-shadow:-6px 0 6px -4px rgba(0,0,0,0.15)}.hi-table-fixed-right,.hi-table-fixed-right table{border-radius:0 4px 0 0}.hi-table-fixed-right .hi-table-expanded-row{color:transparent}.hi-table.hi-table-scroll-position-left .hi-table-fixed-left{-webkit-box-shadow:none;box-shadow:none}.hi-table.hi-table-scroll-position-right .hi-table-fixed-right{-webkit-box-shadow:none;box-shadow:none}.hi-table-thead>tr>th.hi-table-selection-column-custom{padding-left:16px;padding-right:0}.hi-table-thead>tr>th.hi-table-selection-column,.hi-table-tbody>tr>td.hi-table-selection-column{text-align:center;width:62px;min-width:62px}.hi-table-thead>tr>th.hi-table-selection-column .hi-radio-wrapper,.hi-table-tbody>tr>td.hi-table-selection-column .hi-radio-wrapper{margin-right:0}.hi-table-placeholder{position:relative;padding:16px;background:#fff;border-bottom:1px solid #e6e7e8;text-align:center;z-index:1}.hi-table-setting{position:absolute;right:10px;top:0;cursor:pointer;width:50px;text-align:center;-webkit-box-sizing:border-box;box-sizing:border-box}
|
|
1
|
+
.hi-table-header-menu-small .hi-table-header-menu p{height:44px}.hi-table-header-menu-mini .hi-table-header-menu p{height:32px}.hi-table td,.hi-table th{-webkit-box-sizing:border-box;box-sizing:border-box}.hi-table-container{position:relative}.hi-table .hi-icon.icon-menu{color:#4284f5}.hi-table-pre-header{height:52px;line-height:52px;border-top:1px solid #e6e7e8;padding-left:8px;padding-right:16px}.hi-table-pre-footer{height:52px;line-height:52px;border-bottom:1px solid #e6e7e8;padding-left:8px;padding-right:16px;background:#f7fafe}.hi-table.striped table tr:nth-child(2n){background:#f7fafe}.hi-table.bordered .hi-table-pre-header{border-left:1px solid #e6e7e8;border-right:1px solid #e6e7e8}.hi-table.bordered .hi-table-pre-footer{border-left:1px solid #e6e7e8;border-right:1px solid #e6e7e8}.hi-table.bordered table{border-top:1px solid #e6e7e8}.hi-table.bordered table tr td,.hi-table.bordered table tr th{border-left:1px solid #e6e7e8}.hi-table.bordered table tr td:last-child,.hi-table.bordered table tr th:last-child{border-right:1px solid #e6e7e8}.hi-table.large-pre-header{height:64px;line-height:64px}.hi-table.large-pre-footer{height:64px;line-height:64px}.hi-table.large table tr{height:64px;font-size:14px}.hi-table.large .hi-table-header-menu>p{height:44px !important;font-size:14px}.hi-table.large .hi-table-setting-menu>div{height:44px}.hi-table.small-pre-header{height:44px;line-height:44px}.hi-table.small-pre-footer{height:44px;line-height:44px}.hi-table.small table tr{height:44px;font-size:14px}.hi-table.small .hi-table-header-menu>p{height:44px !important;font-size:14px}.hi-table.small .hi-table-setting-menu>div{height:44px}.hi-table.mini-pre-header{height:32px;line-height:32px}.hi-table.mini-pre-footer{height:32px;line-height:32px}.hi-table.mini table tr{height:32px;font-size:14px}.hi-table.mini .hi-table-header-menu>p{height:32px !important;font-size:32px}.hi-table.mini .hi-table-setting-menu>div{height:32px}.hi-table-header-menu{z-index:999999;background:#fff;border:1px solid #e6e7e8;-webkit-box-shadow:0 2px 8px 0 rgba(56,62,71,0.1);box-shadow:0 2px 8px 0 rgba(56,62,71,0.1);border-radius:2px;width:140px}.hi-table-header-menu p{color:#383e47;text-align:left;margin:0;height:52px;text-indent:16px;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;cursor:pointer}.hi-table-header-menu p:hover{background:#f7fafe;color:#4284f5}.hi-table-setting-menu{z-index:999999;background:#fff;border-radius:2px;width:140px}.hi-table-setting-menu>div{color:#383e47;text-align:left;margin:0;padding-left:16px;padding-right:16px;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;cursor:pointer;height:52px}.hi-table-setting-menu>div:hover{background:#f7fafe;color:#4284f5}.hi-table-setting-menu>div>p:first-child{width:140px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.hi-table-setting-menu .active{background:rgba(66,133,244,0.15)}.hi-table-setting-menu.column-menu{position:absolute;right:30px;top:40px;width:220px;max-height:240px;overflow-y:auto}.hi-table-container table{width:100%;border-collapse:separate;background:#fff;margin:0;-webkit-box-sizing:border-box;box-sizing:border-box;display:table;border-spacing:0}.hi-table-container table col{display:table-column}.hi-table-container table td,.hi-table-container table th{white-space:nowrap;padding-left:8px;padding-right:16px;border-bottom:1px solid #e6e7e8;text-align:left;-webkit-box-sizing:border-box;box-sizing:border-box}.hi-table-container table th{background-color:#f7fafe;color:#83868c;position:relative}.hi-table-container table th i:hover{color:#4284f5}.hi-table-container table td{color:#3b4148;word-break:break-word}.hi-table-container table td.picked{background:#f7fafe}.hi-table-container table tr{-webkit-transition:0.2s;transition:0.2s;height:52px;font-size:14px;padding:0;-webkit-box-sizing:border-box;box-sizing:border-box;cursor:pointer}.hi-table-container table tr.picked td{background:#f7fafe}.hi-table-container table tr.expanded{background:#f7fafe}.hi-table-container table tr:hover{background:#f7fafe}.hi-table-body-inner{height:100%}.hi-table-fixed-header>.hi-table-content>.hi-table-scroll>.hi-table-body{position:relative}.hi-table-fixed-header .hi-table-body-inner{overflow:scroll}.hi-table-fixed-header .hi-table-scroll .hi-table-header{overflow:scroll;padding-bottom:20px;margin-bottom:-20px}.hi-table-fixed-left,.hi-table-fixed-right{position:absolute;top:0;overflow:hidden;-webkit-transition:-webkit-box-shadow 0.3s ease;transition:-webkit-box-shadow 0.3s ease;transition:box-shadow 0.3s ease;transition:box-shadow 0.3s ease, -webkit-box-shadow 0.3s ease;border-radius:0}.hi-table-fixed-left table,.hi-table-fixed-right table{width:auto}.hi-table-fixed-header .hi-table-fixed-left .hi-table-body-outer .hi-table-fixed,.hi-table-fixed-header .hi-table-fixed-right .hi-table-body-outer .hi-table-fixed{border-radius:0}.hi-table-fixed-left{left:0;-webkit-box-shadow:6px 0 6px -4px rgba(0,0,0,0.15);box-shadow:6px 0 6px -4px rgba(0,0,0,0.15)}.hi-table-fixed-left .hi-table-header{overflow-y:hidden}.hi-table-fixed-left .hi-table-body-inner{margin-right:-20px;padding-right:20px}.hi-table-fixed-header .hi-table-fixed-left .hi-table-body-inner{padding-right:0}.hi-table-fixed-left,.hi-table-fixed-left table{border-radius:4px 0 0 0}.hi-table-fixed-right{right:0;-webkit-box-shadow:-6px 0 6px -4px rgba(0,0,0,0.15);box-shadow:-6px 0 6px -4px rgba(0,0,0,0.15)}.hi-table-fixed-right,.hi-table-fixed-right table{border-radius:0 4px 0 0}.hi-table-fixed-right .hi-table-expanded-row{color:transparent}.hi-table.hi-table-scroll-position-left .hi-table-fixed-left{-webkit-box-shadow:none;box-shadow:none}.hi-table.hi-table-scroll-position-right .hi-table-fixed-right{-webkit-box-shadow:none;box-shadow:none}.hi-table-thead>tr>th.hi-table-selection-column-custom{padding-left:16px;padding-right:0}.hi-table-thead>tr>th.hi-table-selection-column,.hi-table-tbody>tr>td.hi-table-selection-column{text-align:center;width:62px;min-width:62px}.hi-table-thead>tr>th.hi-table-selection-column .hi-radio-wrapper,.hi-table-tbody>tr>td.hi-table-selection-column .hi-radio-wrapper{margin-right:0}.hi-table-placeholder{position:relative;padding:16px;background:#fff;border-bottom:1px solid #e6e7e8;text-align:center;z-index:1}.hi-table-setting{position:absolute;right:10px;top:0;cursor:pointer;width:50px;text-align:center;-webkit-box-sizing:border-box;box-sizing:border-box}.theme__orange.hi-table .hi-table-container table th{background-color:rgba(255,102,51,0.1);color:#83868c}.theme__orange.hi-table .hi-table-container table tr{background-color:#fff;color:#83868c}.theme__orange.hi-table .hi-table-container table .hi-table-thead tr:hover{background-color:#fff}.theme__orange.hi-table .hi-table-container table th i:hover{color:#f63}.theme__orange.hi-table .hi-icon.icon-menu{color:#f63}.theme__orange.hi-table .hi-table-container table tr:hover{background-color:rgba(255,102,51,0.1)}.theme__orange.hi-table a{color:#f63}.theme__orange.hi-table .hi-table-setting-menu>div:hover{background-color:rgba(255,102,51,0.15);color:#f63}.theme__orange.hi-table.striped table tr:nth-child(2n){background:rgba(255,102,51,0.1)}.theme__orange.hi-table .hi-pagination .hi-icon{color:#666}.theme__orange.hi-table .hi-pagination .hi-icon:hover{color:#f63}.theme__orange.hi-table .hi-pagination:hover>span .hi-icon{color:#f63}.theme__cyan.hi-table .hi-table-container table th{background-color:rgba(70,188,153,0.1);color:#83868c}.theme__cyan.hi-table .hi-table-container table tr{background-color:#fff;color:#83868c}.theme__cyan.hi-table .hi-table-container table .hi-table-thead tr:hover{background-color:#fff}.theme__cyan.hi-table .hi-table-container table th i:hover{color:#46bc99}.theme__cyan.hi-table .hi-icon.icon-menu{color:#46bc99}.theme__cyan.hi-table .hi-table-container table tr:hover{background-color:rgba(70,188,153,0.1)}.theme__cyan.hi-table a{color:#46bc99}.theme__cyan.hi-table .hi-table-setting-menu>div:hover{background-color:rgba(70,188,153,0.15);color:#46bc99}.theme__cyan.hi-table.striped table tr:nth-child(2n){background:rgba(70,188,153,0.1)}.theme__cyan.hi-table .hi-pagination .hi-icon{color:#666}.theme__cyan.hi-table .hi-pagination .hi-icon:hover{color:#46bc99}.theme__cyan.hi-table .hi-pagination:hover>span .hi-icon{color:#46bc99}.theme__magenta.hi-table .hi-table-container table th{background-color:rgba(255,89,117,0.1);color:#83868c}.theme__magenta.hi-table .hi-table-container table tr{background-color:#fff;color:#83868c}.theme__magenta.hi-table .hi-table-container table .hi-table-thead tr:hover{background-color:#fff}.theme__magenta.hi-table .hi-table-container table th i:hover{color:#ff5975}.theme__magenta.hi-table .hi-icon.icon-menu{color:#ff5975}.theme__magenta.hi-table .hi-table-container table tr:hover{background-color:rgba(255,89,117,0.1)}.theme__magenta.hi-table a{color:#ff5975}.theme__magenta.hi-table .hi-table-setting-menu>div:hover{background-color:rgba(255,89,117,0.15);color:#ff5975}.theme__magenta.hi-table.striped table tr:nth-child(2n){background:rgba(255,89,117,0.1)}.theme__magenta.hi-table .hi-pagination .hi-icon{color:#666}.theme__magenta.hi-table .hi-pagination .hi-icon:hover{color:#ff5975}.theme__magenta.hi-table .hi-pagination:hover>span .hi-icon{color:#ff5975}.theme__lavender.hi-table .hi-table-container table th{background-color:rgba(180,80,222,0.1);color:#83868c}.theme__lavender.hi-table .hi-table-container table tr{background-color:#fff;color:#83868c}.theme__lavender.hi-table .hi-table-container table .hi-table-thead tr:hover{background-color:#fff}.theme__lavender.hi-table .hi-table-container table th i:hover{color:#b450de}.theme__lavender.hi-table .hi-icon.icon-menu{color:#b450de}.theme__lavender.hi-table .hi-table-container table tr:hover{background-color:rgba(180,80,222,0.1)}.theme__lavender.hi-table a{color:#b450de}.theme__lavender.hi-table .hi-table-setting-menu>div:hover{background-color:rgba(180,80,222,0.15);color:#b450de}.theme__lavender.hi-table.striped table tr:nth-child(2n){background:rgba(180,80,222,0.1)}.theme__lavender.hi-table .hi-pagination .hi-icon{color:#666}.theme__lavender.hi-table .hi-pagination .hi-icon:hover{color:#b450de}.theme__lavender.hi-table .hi-pagination:hover>span .hi-icon{color:#b450de}.theme__blue.hi-table .hi-table-container table th{background-color:rgba(61,168,245,0.1);color:#83868c}.theme__blue.hi-table .hi-table-container table tr{background-color:#fff;color:#83868c}.theme__blue.hi-table .hi-table-container table .hi-table-thead tr:hover{background-color:#fff}.theme__blue.hi-table .hi-table-container table th i:hover{color:#3da8f5}.theme__blue.hi-table .hi-icon.icon-menu{color:#3da8f5}.theme__blue.hi-table .hi-table-container table tr:hover{background-color:rgba(61,168,245,0.1)}.theme__blue.hi-table a{color:#3da8f5}.theme__blue.hi-table .hi-table-setting-menu>div:hover{background-color:rgba(61,168,245,0.15);color:#3da8f5}.theme__blue.hi-table.striped table tr:nth-child(2n){background:rgba(61,168,245,0.1)}.theme__blue.hi-table .hi-pagination .hi-icon{color:#666}.theme__blue.hi-table .hi-pagination .hi-icon:hover{color:#3da8f5}.theme__blue.hi-table .hi-pagination:hover>span .hi-icon{color:#3da8f5}.theme__purple.hi-table .hi-table-container table th{background-color:rgba(138,138,203,0.1);color:#83868c}.theme__purple.hi-table .hi-table-container table tr{background-color:#fff;color:#83868c}.theme__purple.hi-table .hi-table-container table .hi-table-thead tr:hover{background-color:#fff}.theme__purple.hi-table .hi-table-container table th i:hover{color:#8a8acb}.theme__purple.hi-table .hi-icon.icon-menu{color:#8a8acb}.theme__purple.hi-table .hi-table-container table tr:hover{background-color:rgba(138,138,203,0.1)}.theme__purple.hi-table a{color:#8a8acb}.theme__purple.hi-table .hi-table-setting-menu>div:hover{background-color:rgba(138,138,203,0.15);color:#8a8acb}.theme__purple.hi-table.striped table tr:nth-child(2n){background:rgba(138,138,203,0.1)}.theme__purple.hi-table .hi-pagination .hi-icon{color:#666}.theme__purple.hi-table .hi-pagination .hi-icon:hover{color:#8a8acb}.theme__purple.hi-table .hi-pagination:hover>span .hi-icon{color:#8a8acb}
|
package/es/table/style/index.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.hi-table-header-menu-small .hi-table-header-menu p{height:44px}.hi-table-header-menu-mini .hi-table-header-menu p{height:32px}.hi-table td,.hi-table th{-webkit-box-sizing:border-box;box-sizing:border-box}.hi-table-container{position:relative}.hi-table-pre-header{height:52px;line-height:52px;border-top:1px solid #e6e7e8;padding-left:8px;padding-right:16px}.hi-table-pre-footer{height:52px;line-height:52px;border-bottom:1px solid #e6e7e8;padding-left:8px;padding-right:16px;background:#f7fafe}.hi-table.striped table tr:nth-child(2n){background:#f7fafe}.hi-table.bordered .hi-table-pre-header{border-left:1px solid #e6e7e8;border-right:1px solid #e6e7e8}.hi-table.bordered .hi-table-pre-footer{border-left:1px solid #e6e7e8;border-right:1px solid #e6e7e8}.hi-table.bordered table{border-top:1px solid #e6e7e8}.hi-table.bordered table tr td,.hi-table.bordered table tr th{border-left:1px solid #e6e7e8}.hi-table.bordered table tr td:last-child,.hi-table.bordered table tr th:last-child{border-right:1px solid #e6e7e8}.hi-table.large-pre-header{height:64px;line-height:64px}.hi-table.large-pre-footer{height:64px;line-height:64px}.hi-table.large table tr{height:64px;font-size:14px}.hi-table.large .hi-table-header-menu>p{height:44px !important;font-size:14px}.hi-table.large .hi-table-setting-menu>div{height:44px}.hi-table.small-pre-header{height:44px;line-height:44px}.hi-table.small-pre-footer{height:44px;line-height:44px}.hi-table.small table tr{height:44px;font-size:14px}.hi-table.small .hi-table-header-menu>p{height:44px !important;font-size:14px}.hi-table.small .hi-table-setting-menu>div{height:44px}.hi-table.mini-pre-header{height:32px;line-height:32px}.hi-table.mini-pre-footer{height:32px;line-height:32px}.hi-table.mini table tr{height:32px;font-size:14px}.hi-table.mini .hi-table-header-menu>p{height:32px !important;font-size:32px}.hi-table.mini .hi-table-setting-menu>div{height:32px}.hi-table-header-menu{z-index:999999;background:#fff;border:1px solid #e6e7e8;-webkit-box-shadow:0 2px 8px 0 rgba(56,62,71,0.1);box-shadow:0 2px 8px 0 rgba(56,62,71,0.1);border-radius:2px;width:140px}.hi-table-header-menu p{color:#383e47;text-align:left;margin:0;height:52px;text-indent:16px;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;cursor:pointer}.hi-table-header-menu p:hover{background:#f7fafe;color:#4284f5}.hi-table-setting-menu{z-index:999999;background:#fff;border-radius:2px;width:140px}.hi-table-setting-menu>div{color:#383e47;text-align:left;margin:0;padding-left:16px;padding-right:16px;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;cursor:pointer;height:52px}.hi-table-setting-menu>div:hover{background:#f7fafe;color:#4284f5}.hi-table-setting-menu>div>p:first-child{width:140px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.hi-table-setting-menu .active{background:rgba(66,133,244,0.15)}.hi-table-setting-menu.column-menu{position:absolute;right:30px;top:40px;width:220px;max-height:240px;overflow-y:auto}.hi-table-container table{width:100%;border-collapse:separate;background:#fff;margin:0;-webkit-box-sizing:border-box;box-sizing:border-box;display:table;border-spacing:0}.hi-table-container table col{display:table-column}.hi-table-container table td,.hi-table-container table th{white-space:nowrap;padding-left:8px;padding-right:16px;border-bottom:1px solid #e6e7e8;text-align:left;-webkit-box-sizing:border-box;box-sizing:border-box}.hi-table-container table th{background-color:#f7fafe;color:#83868c;position:relative}.hi-table-container table th i:hover{color:#4284f5}.hi-table-container table td{color:#3b4148;word-break:break-word}.hi-table-container table td.picked{background:#f7fafe}.hi-table-container table tr{-webkit-transition:0.2s;transition:0.2s;height:52px;font-size:14px;padding:0;-webkit-box-sizing:border-box;box-sizing:border-box;cursor:pointer}.hi-table-container table tr.picked td{background:#f7fafe}.hi-table-container table tr.expanded{background:#f7fafe}.hi-table-container table tr:hover{background:#f7fafe}.hi-table-body-inner{height:100%}.hi-table-fixed-header>.hi-table-content>.hi-table-scroll>.hi-table-body{position:relative}.hi-table-fixed-header .hi-table-body-inner{overflow:scroll}.hi-table-fixed-header .hi-table-scroll .hi-table-header{overflow:scroll;padding-bottom:20px;margin-bottom:-20px}.hi-table-fixed-left,.hi-table-fixed-right{position:absolute;top:0;overflow:hidden;-webkit-transition:-webkit-box-shadow 0.3s ease;transition:-webkit-box-shadow 0.3s ease;transition:box-shadow 0.3s ease;transition:box-shadow 0.3s ease, -webkit-box-shadow 0.3s ease;border-radius:0}.hi-table-fixed-left table,.hi-table-fixed-right table{width:auto}.hi-table-fixed-header .hi-table-fixed-left .hi-table-body-outer .hi-table-fixed,.hi-table-fixed-header .hi-table-fixed-right .hi-table-body-outer .hi-table-fixed{border-radius:0}.hi-table-fixed-left{left:0;-webkit-box-shadow:6px 0 6px -4px rgba(0,0,0,0.15);box-shadow:6px 0 6px -4px rgba(0,0,0,0.15)}.hi-table-fixed-left .hi-table-header{overflow-y:hidden}.hi-table-fixed-left .hi-table-body-inner{margin-right:-20px;padding-right:20px}.hi-table-fixed-header .hi-table-fixed-left .hi-table-body-inner{padding-right:0}.hi-table-fixed-left,.hi-table-fixed-left table{border-radius:4px 0 0 0}.hi-table-fixed-right{right:0;-webkit-box-shadow:-6px 0 6px -4px rgba(0,0,0,0.15);box-shadow:-6px 0 6px -4px rgba(0,0,0,0.15)}.hi-table-fixed-right,.hi-table-fixed-right table{border-radius:0 4px 0 0}.hi-table-fixed-right .hi-table-expanded-row{color:transparent}.hi-table.hi-table-scroll-position-left .hi-table-fixed-left{-webkit-box-shadow:none;box-shadow:none}.hi-table.hi-table-scroll-position-right .hi-table-fixed-right{-webkit-box-shadow:none;box-shadow:none}.hi-table-thead>tr>th.hi-table-selection-column-custom{padding-left:16px;padding-right:0}.hi-table-thead>tr>th.hi-table-selection-column,.hi-table-tbody>tr>td.hi-table-selection-column{text-align:center;width:62px;min-width:62px}.hi-table-thead>tr>th.hi-table-selection-column .hi-radio-wrapper,.hi-table-tbody>tr>td.hi-table-selection-column .hi-radio-wrapper{margin-right:0}.hi-table-placeholder{position:relative;padding:16px;background:#fff;border-bottom:1px solid #e6e7e8;text-align:center;z-index:1}.hi-table-setting{position:absolute;right:10px;top:0;cursor:pointer;width:50px;text-align:center;-webkit-box-sizing:border-box;box-sizing:border-box}
|
|
1
|
+
.hi-table-header-menu-small .hi-table-header-menu p{height:44px}.hi-table-header-menu-mini .hi-table-header-menu p{height:32px}.hi-table td,.hi-table th{-webkit-box-sizing:border-box;box-sizing:border-box}.hi-table-container{position:relative}.hi-table .hi-icon.icon-menu{color:#4284f5}.hi-table-pre-header{height:52px;line-height:52px;border-top:1px solid #e6e7e8;padding-left:8px;padding-right:16px}.hi-table-pre-footer{height:52px;line-height:52px;border-bottom:1px solid #e6e7e8;padding-left:8px;padding-right:16px;background:#f7fafe}.hi-table.striped table tr:nth-child(2n){background:#f7fafe}.hi-table.bordered .hi-table-pre-header{border-left:1px solid #e6e7e8;border-right:1px solid #e6e7e8}.hi-table.bordered .hi-table-pre-footer{border-left:1px solid #e6e7e8;border-right:1px solid #e6e7e8}.hi-table.bordered table{border-top:1px solid #e6e7e8}.hi-table.bordered table tr td,.hi-table.bordered table tr th{border-left:1px solid #e6e7e8}.hi-table.bordered table tr td:last-child,.hi-table.bordered table tr th:last-child{border-right:1px solid #e6e7e8}.hi-table.large-pre-header{height:64px;line-height:64px}.hi-table.large-pre-footer{height:64px;line-height:64px}.hi-table.large table tr{height:64px;font-size:14px}.hi-table.large .hi-table-header-menu>p{height:44px !important;font-size:14px}.hi-table.large .hi-table-setting-menu>div{height:44px}.hi-table.small-pre-header{height:44px;line-height:44px}.hi-table.small-pre-footer{height:44px;line-height:44px}.hi-table.small table tr{height:44px;font-size:14px}.hi-table.small .hi-table-header-menu>p{height:44px !important;font-size:14px}.hi-table.small .hi-table-setting-menu>div{height:44px}.hi-table.mini-pre-header{height:32px;line-height:32px}.hi-table.mini-pre-footer{height:32px;line-height:32px}.hi-table.mini table tr{height:32px;font-size:14px}.hi-table.mini .hi-table-header-menu>p{height:32px !important;font-size:32px}.hi-table.mini .hi-table-setting-menu>div{height:32px}.hi-table-header-menu{z-index:999999;background:#fff;border:1px solid #e6e7e8;-webkit-box-shadow:0 2px 8px 0 rgba(56,62,71,0.1);box-shadow:0 2px 8px 0 rgba(56,62,71,0.1);border-radius:2px;width:140px}.hi-table-header-menu p{color:#383e47;text-align:left;margin:0;height:52px;text-indent:16px;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;cursor:pointer}.hi-table-header-menu p:hover{background:#f7fafe;color:#4284f5}.hi-table-setting-menu{z-index:999999;background:#fff;border-radius:2px;width:140px}.hi-table-setting-menu>div{color:#383e47;text-align:left;margin:0;padding-left:16px;padding-right:16px;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;cursor:pointer;height:52px}.hi-table-setting-menu>div:hover{background:#f7fafe;color:#4284f5}.hi-table-setting-menu>div>p:first-child{width:140px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.hi-table-setting-menu .active{background:rgba(66,133,244,0.15)}.hi-table-setting-menu.column-menu{position:absolute;right:30px;top:40px;width:220px;max-height:240px;overflow-y:auto}.hi-table-container table{width:100%;border-collapse:separate;background:#fff;margin:0;-webkit-box-sizing:border-box;box-sizing:border-box;display:table;border-spacing:0}.hi-table-container table col{display:table-column}.hi-table-container table td,.hi-table-container table th{white-space:nowrap;padding-left:8px;padding-right:16px;border-bottom:1px solid #e6e7e8;text-align:left;-webkit-box-sizing:border-box;box-sizing:border-box}.hi-table-container table th{background-color:#f7fafe;color:#83868c;position:relative}.hi-table-container table th i:hover{color:#4284f5}.hi-table-container table td{color:#3b4148;word-break:break-word}.hi-table-container table td.picked{background:#f7fafe}.hi-table-container table tr{-webkit-transition:0.2s;transition:0.2s;height:52px;font-size:14px;padding:0;-webkit-box-sizing:border-box;box-sizing:border-box;cursor:pointer}.hi-table-container table tr.picked td{background:#f7fafe}.hi-table-container table tr.expanded{background:#f7fafe}.hi-table-container table tr:hover{background:#f7fafe}.hi-table-body-inner{height:100%}.hi-table-fixed-header>.hi-table-content>.hi-table-scroll>.hi-table-body{position:relative}.hi-table-fixed-header .hi-table-body-inner{overflow:scroll}.hi-table-fixed-header .hi-table-scroll .hi-table-header{overflow:scroll;padding-bottom:20px;margin-bottom:-20px}.hi-table-fixed-left,.hi-table-fixed-right{position:absolute;top:0;overflow:hidden;-webkit-transition:-webkit-box-shadow 0.3s ease;transition:-webkit-box-shadow 0.3s ease;transition:box-shadow 0.3s ease;transition:box-shadow 0.3s ease, -webkit-box-shadow 0.3s ease;border-radius:0}.hi-table-fixed-left table,.hi-table-fixed-right table{width:auto}.hi-table-fixed-header .hi-table-fixed-left .hi-table-body-outer .hi-table-fixed,.hi-table-fixed-header .hi-table-fixed-right .hi-table-body-outer .hi-table-fixed{border-radius:0}.hi-table-fixed-left{left:0;-webkit-box-shadow:6px 0 6px -4px rgba(0,0,0,0.15);box-shadow:6px 0 6px -4px rgba(0,0,0,0.15)}.hi-table-fixed-left .hi-table-header{overflow-y:hidden}.hi-table-fixed-left .hi-table-body-inner{margin-right:-20px;padding-right:20px}.hi-table-fixed-header .hi-table-fixed-left .hi-table-body-inner{padding-right:0}.hi-table-fixed-left,.hi-table-fixed-left table{border-radius:4px 0 0 0}.hi-table-fixed-right{right:0;-webkit-box-shadow:-6px 0 6px -4px rgba(0,0,0,0.15);box-shadow:-6px 0 6px -4px rgba(0,0,0,0.15)}.hi-table-fixed-right,.hi-table-fixed-right table{border-radius:0 4px 0 0}.hi-table-fixed-right .hi-table-expanded-row{color:transparent}.hi-table.hi-table-scroll-position-left .hi-table-fixed-left{-webkit-box-shadow:none;box-shadow:none}.hi-table.hi-table-scroll-position-right .hi-table-fixed-right{-webkit-box-shadow:none;box-shadow:none}.hi-table-thead>tr>th.hi-table-selection-column-custom{padding-left:16px;padding-right:0}.hi-table-thead>tr>th.hi-table-selection-column,.hi-table-tbody>tr>td.hi-table-selection-column{text-align:center;width:62px;min-width:62px}.hi-table-thead>tr>th.hi-table-selection-column .hi-radio-wrapper,.hi-table-tbody>tr>td.hi-table-selection-column .hi-radio-wrapper{margin-right:0}.hi-table-placeholder{position:relative;padding:16px;background:#fff;border-bottom:1px solid #e6e7e8;text-align:center;z-index:1}.hi-table-setting{position:absolute;right:10px;top:0;cursor:pointer;width:50px;text-align:center;-webkit-box-sizing:border-box;box-sizing:border-box}.theme__orange.hi-table .hi-table-container table th{background-color:rgba(255,102,51,0.1);color:#83868c}.theme__orange.hi-table .hi-table-container table tr{background-color:#fff;color:#83868c}.theme__orange.hi-table .hi-table-container table .hi-table-thead tr:hover{background-color:#fff}.theme__orange.hi-table .hi-table-container table th i:hover{color:#f63}.theme__orange.hi-table .hi-icon.icon-menu{color:#f63}.theme__orange.hi-table .hi-table-container table tr:hover{background-color:rgba(255,102,51,0.1)}.theme__orange.hi-table a{color:#f63}.theme__orange.hi-table .hi-table-setting-menu>div:hover{background-color:rgba(255,102,51,0.15);color:#f63}.theme__orange.hi-table.striped table tr:nth-child(2n){background:rgba(255,102,51,0.1)}.theme__orange.hi-table .hi-pagination .hi-icon{color:#666}.theme__orange.hi-table .hi-pagination .hi-icon:hover{color:#f63}.theme__orange.hi-table .hi-pagination:hover>span .hi-icon{color:#f63}.theme__cyan.hi-table .hi-table-container table th{background-color:rgba(70,188,153,0.1);color:#83868c}.theme__cyan.hi-table .hi-table-container table tr{background-color:#fff;color:#83868c}.theme__cyan.hi-table .hi-table-container table .hi-table-thead tr:hover{background-color:#fff}.theme__cyan.hi-table .hi-table-container table th i:hover{color:#46bc99}.theme__cyan.hi-table .hi-icon.icon-menu{color:#46bc99}.theme__cyan.hi-table .hi-table-container table tr:hover{background-color:rgba(70,188,153,0.1)}.theme__cyan.hi-table a{color:#46bc99}.theme__cyan.hi-table .hi-table-setting-menu>div:hover{background-color:rgba(70,188,153,0.15);color:#46bc99}.theme__cyan.hi-table.striped table tr:nth-child(2n){background:rgba(70,188,153,0.1)}.theme__cyan.hi-table .hi-pagination .hi-icon{color:#666}.theme__cyan.hi-table .hi-pagination .hi-icon:hover{color:#46bc99}.theme__cyan.hi-table .hi-pagination:hover>span .hi-icon{color:#46bc99}.theme__magenta.hi-table .hi-table-container table th{background-color:rgba(255,89,117,0.1);color:#83868c}.theme__magenta.hi-table .hi-table-container table tr{background-color:#fff;color:#83868c}.theme__magenta.hi-table .hi-table-container table .hi-table-thead tr:hover{background-color:#fff}.theme__magenta.hi-table .hi-table-container table th i:hover{color:#ff5975}.theme__magenta.hi-table .hi-icon.icon-menu{color:#ff5975}.theme__magenta.hi-table .hi-table-container table tr:hover{background-color:rgba(255,89,117,0.1)}.theme__magenta.hi-table a{color:#ff5975}.theme__magenta.hi-table .hi-table-setting-menu>div:hover{background-color:rgba(255,89,117,0.15);color:#ff5975}.theme__magenta.hi-table.striped table tr:nth-child(2n){background:rgba(255,89,117,0.1)}.theme__magenta.hi-table .hi-pagination .hi-icon{color:#666}.theme__magenta.hi-table .hi-pagination .hi-icon:hover{color:#ff5975}.theme__magenta.hi-table .hi-pagination:hover>span .hi-icon{color:#ff5975}.theme__lavender.hi-table .hi-table-container table th{background-color:rgba(180,80,222,0.1);color:#83868c}.theme__lavender.hi-table .hi-table-container table tr{background-color:#fff;color:#83868c}.theme__lavender.hi-table .hi-table-container table .hi-table-thead tr:hover{background-color:#fff}.theme__lavender.hi-table .hi-table-container table th i:hover{color:#b450de}.theme__lavender.hi-table .hi-icon.icon-menu{color:#b450de}.theme__lavender.hi-table .hi-table-container table tr:hover{background-color:rgba(180,80,222,0.1)}.theme__lavender.hi-table a{color:#b450de}.theme__lavender.hi-table .hi-table-setting-menu>div:hover{background-color:rgba(180,80,222,0.15);color:#b450de}.theme__lavender.hi-table.striped table tr:nth-child(2n){background:rgba(180,80,222,0.1)}.theme__lavender.hi-table .hi-pagination .hi-icon{color:#666}.theme__lavender.hi-table .hi-pagination .hi-icon:hover{color:#b450de}.theme__lavender.hi-table .hi-pagination:hover>span .hi-icon{color:#b450de}.theme__blue.hi-table .hi-table-container table th{background-color:rgba(61,168,245,0.1);color:#83868c}.theme__blue.hi-table .hi-table-container table tr{background-color:#fff;color:#83868c}.theme__blue.hi-table .hi-table-container table .hi-table-thead tr:hover{background-color:#fff}.theme__blue.hi-table .hi-table-container table th i:hover{color:#3da8f5}.theme__blue.hi-table .hi-icon.icon-menu{color:#3da8f5}.theme__blue.hi-table .hi-table-container table tr:hover{background-color:rgba(61,168,245,0.1)}.theme__blue.hi-table a{color:#3da8f5}.theme__blue.hi-table .hi-table-setting-menu>div:hover{background-color:rgba(61,168,245,0.15);color:#3da8f5}.theme__blue.hi-table.striped table tr:nth-child(2n){background:rgba(61,168,245,0.1)}.theme__blue.hi-table .hi-pagination .hi-icon{color:#666}.theme__blue.hi-table .hi-pagination .hi-icon:hover{color:#3da8f5}.theme__blue.hi-table .hi-pagination:hover>span .hi-icon{color:#3da8f5}.theme__purple.hi-table .hi-table-container table th{background-color:rgba(138,138,203,0.1);color:#83868c}.theme__purple.hi-table .hi-table-container table tr{background-color:#fff;color:#83868c}.theme__purple.hi-table .hi-table-container table .hi-table-thead tr:hover{background-color:#fff}.theme__purple.hi-table .hi-table-container table th i:hover{color:#8a8acb}.theme__purple.hi-table .hi-icon.icon-menu{color:#8a8acb}.theme__purple.hi-table .hi-table-container table tr:hover{background-color:rgba(138,138,203,0.1)}.theme__purple.hi-table a{color:#8a8acb}.theme__purple.hi-table .hi-table-setting-menu>div:hover{background-color:rgba(138,138,203,0.15);color:#8a8acb}.theme__purple.hi-table.striped table tr:nth-child(2n){background:rgba(138,138,203,0.1)}.theme__purple.hi-table .hi-pagination .hi-icon{color:#666}.theme__purple.hi-table .hi-pagination .hi-icon:hover{color:#8a8acb}.theme__purple.hi-table .hi-pagination:hover>span .hi-icon{color:#8a8acb}
|
package/es/tabs/ItemDropdown.js
CHANGED
|
@@ -1,72 +1,57 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
+
var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard");
|
|
4
|
+
|
|
5
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
6
|
+
|
|
3
7
|
Object.defineProperty(exports, "__esModule", {
|
|
4
8
|
value: true
|
|
5
9
|
});
|
|
6
10
|
exports["default"] = void 0;
|
|
7
11
|
|
|
8
|
-
var
|
|
9
|
-
|
|
10
|
-
var _reactDom = _interopRequireDefault(require("react-dom"));
|
|
11
|
-
|
|
12
|
-
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
13
|
-
|
|
14
|
-
var _classnames = _interopRequireDefault(require("classnames"));
|
|
15
|
-
|
|
16
|
-
var _context = _interopRequireDefault(require("../context"));
|
|
17
|
-
|
|
18
|
-
var _popper = _interopRequireDefault(require("../popper"));
|
|
19
|
-
|
|
20
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
21
|
-
|
|
22
|
-
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function _getRequireWildcardCache() { return cache; }; return cache; }
|
|
12
|
+
var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
|
|
23
13
|
|
|
24
|
-
|
|
14
|
+
var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
|
|
25
15
|
|
|
26
|
-
|
|
16
|
+
var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));
|
|
27
17
|
|
|
28
|
-
|
|
18
|
+
var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));
|
|
29
19
|
|
|
30
|
-
|
|
20
|
+
var _assertThisInitialized2 = _interopRequireDefault(require("@babel/runtime/helpers/assertThisInitialized"));
|
|
31
21
|
|
|
32
|
-
|
|
22
|
+
var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits"));
|
|
33
23
|
|
|
34
|
-
|
|
24
|
+
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
35
25
|
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
39
|
-
|
|
40
|
-
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
|
|
41
|
-
|
|
42
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
26
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
43
27
|
|
|
44
|
-
|
|
28
|
+
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
45
29
|
|
|
46
|
-
|
|
30
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
|
47
31
|
|
|
48
|
-
|
|
32
|
+
var _context = _interopRequireDefault(require("../context"));
|
|
49
33
|
|
|
50
|
-
var
|
|
51
|
-
_inherits(ItemDropdown, _Component);
|
|
34
|
+
var _popper = _interopRequireDefault(require("../popper"));
|
|
52
35
|
|
|
53
|
-
|
|
36
|
+
var ItemDropdown =
|
|
37
|
+
/*#__PURE__*/
|
|
38
|
+
function (_Component) {
|
|
39
|
+
(0, _inherits2["default"])(ItemDropdown, _Component);
|
|
54
40
|
|
|
55
41
|
function ItemDropdown(props) {
|
|
56
42
|
var _this;
|
|
57
43
|
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
_this = _super.call(this, props);
|
|
44
|
+
(0, _classCallCheck2["default"])(this, ItemDropdown);
|
|
45
|
+
_this = (0, _possibleConstructorReturn2["default"])(this, (0, _getPrototypeOf2["default"])(ItemDropdown).call(this, props));
|
|
61
46
|
_this.state = {
|
|
62
47
|
visible: false,
|
|
63
48
|
activeIndex: -1
|
|
64
49
|
};
|
|
65
|
-
_this.clickOutsideHandle = _this.clickOutside.bind(
|
|
50
|
+
_this.clickOutsideHandle = _this.clickOutside.bind((0, _assertThisInitialized2["default"])(_this));
|
|
66
51
|
return _this;
|
|
67
52
|
}
|
|
68
53
|
|
|
69
|
-
|
|
54
|
+
(0, _createClass2["default"])(ItemDropdown, [{
|
|
70
55
|
key: "componentWillReceiveProps",
|
|
71
56
|
value: function componentWillReceiveProps(nextProps) {
|
|
72
57
|
if (!nextProps.active) {
|
|
@@ -88,10 +73,6 @@ var ItemDropdown = /*#__PURE__*/function (_Component) {
|
|
|
88
73
|
}, {
|
|
89
74
|
key: "clickOutside",
|
|
90
75
|
value: function clickOutside(e) {
|
|
91
|
-
if (_reactDom["default"].findDOMNode(this.toggleRef) && _reactDom["default"].findDOMNode(this.toggleRef).contains(e.target)) {
|
|
92
|
-
return;
|
|
93
|
-
}
|
|
94
|
-
|
|
95
76
|
this.toggle(true);
|
|
96
77
|
}
|
|
97
78
|
}, {
|
|
@@ -110,15 +91,19 @@ var ItemDropdown = /*#__PURE__*/function (_Component) {
|
|
|
110
91
|
var _this$props = this.props,
|
|
111
92
|
items = _this$props.items,
|
|
112
93
|
onChoose = _this$props.onChoose,
|
|
113
|
-
localeDatas = _this$props.localeDatas
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
94
|
+
localeDatas = _this$props.localeDatas,
|
|
95
|
+
activeId = _this$props.activeId,
|
|
96
|
+
theme = _this$props.theme;
|
|
97
|
+
var visible = this.state.visible;
|
|
98
|
+
var activeIndex = -1;
|
|
99
|
+
items.map(function (item, index) {
|
|
100
|
+
if (item.tabId === activeId) activeIndex = index;
|
|
101
|
+
});
|
|
102
|
+
return _react["default"].createElement("div", {
|
|
103
|
+
className: (0, _classnames["default"])('hi-tabs-dropdown', "theme__".concat(theme), {
|
|
119
104
|
'hi-tabs-dropdown--active': !!items[activeIndex]
|
|
120
105
|
})
|
|
121
|
-
},
|
|
106
|
+
}, _react["default"].createElement("div", {
|
|
122
107
|
className: "hi-tabs-dropdown__toggle",
|
|
123
108
|
ref: function ref(node) {
|
|
124
109
|
_this2.toggleRef = node;
|
|
@@ -128,11 +113,11 @@ var ItemDropdown = /*#__PURE__*/function (_Component) {
|
|
|
128
113
|
|
|
129
114
|
_this2.toggle();
|
|
130
115
|
}
|
|
131
|
-
},
|
|
116
|
+
}, _react["default"].createElement("span", {
|
|
132
117
|
className: "hi-tabs-dropdown__toggle-title"
|
|
133
|
-
}, items[activeIndex] && items[activeIndex].
|
|
118
|
+
}, items[activeIndex] && items[activeIndex].tabTitle || localeDatas.tabs.more), _react["default"].createElement("i", {
|
|
134
119
|
className: "hi-icon icon-down"
|
|
135
|
-
})),
|
|
120
|
+
})), _react["default"].createElement(_popper["default"], {
|
|
136
121
|
className: "hi-tabs-dropdown__popper",
|
|
137
122
|
show: visible,
|
|
138
123
|
attachEle: this.toggleRef,
|
|
@@ -140,32 +125,27 @@ var ItemDropdown = /*#__PURE__*/function (_Component) {
|
|
|
140
125
|
width: "auto",
|
|
141
126
|
leftGap: -18,
|
|
142
127
|
topGap: 3
|
|
143
|
-
},
|
|
144
|
-
className: (0, _classnames["default"])('hi-tabs-dropdown__items')
|
|
128
|
+
}, _react["default"].createElement("div", {
|
|
129
|
+
className: (0, _classnames["default"])('hi-tabs-dropdown__items', "theme__".concat(theme))
|
|
145
130
|
}, items.map(function (item, index) {
|
|
146
|
-
return
|
|
131
|
+
return _react["default"].createElement("div", {
|
|
147
132
|
className: (0, _classnames["default"])('hi-tabs-dropdown__item', {
|
|
148
133
|
'hi-tabs-dropdown__item--active': index === activeIndex
|
|
149
134
|
}),
|
|
150
135
|
onClick: function onClick(e) {
|
|
151
|
-
_this2.
|
|
152
|
-
activeIndex: index
|
|
153
|
-
}, function () {
|
|
154
|
-
_this2.toggle();
|
|
136
|
+
_this2.toggle();
|
|
155
137
|
|
|
156
|
-
|
|
157
|
-
});
|
|
138
|
+
onChoose(item, e);
|
|
158
139
|
},
|
|
159
140
|
key: index
|
|
160
|
-
}, item.
|
|
141
|
+
}, item.tabTitle);
|
|
161
142
|
}))));
|
|
162
143
|
}
|
|
163
144
|
}]);
|
|
164
|
-
|
|
165
145
|
return ItemDropdown;
|
|
166
146
|
}(_react.Component);
|
|
167
147
|
|
|
168
|
-
|
|
148
|
+
(0, _defineProperty2["default"])(ItemDropdown, "propTypes", {
|
|
169
149
|
items: _propTypes["default"].array,
|
|
170
150
|
onChoose: _propTypes["default"].func,
|
|
171
151
|
active: _propTypes["default"].bool
|
package/es/tabs/TabPane.js
CHANGED
|
@@ -1,56 +1,41 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
+
var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard");
|
|
4
|
+
|
|
5
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
6
|
+
|
|
3
7
|
Object.defineProperty(exports, "__esModule", {
|
|
4
8
|
value: true
|
|
5
9
|
});
|
|
6
10
|
exports["default"] = void 0;
|
|
7
11
|
|
|
8
|
-
var
|
|
9
|
-
|
|
10
|
-
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
11
|
-
|
|
12
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
13
|
-
|
|
14
|
-
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function _getRequireWildcardCache() { return cache; }; return cache; }
|
|
15
|
-
|
|
16
|
-
function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
17
|
-
|
|
18
|
-
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
|
|
19
|
-
|
|
20
|
-
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
12
|
+
var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
|
|
21
13
|
|
|
22
|
-
|
|
14
|
+
var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
|
|
23
15
|
|
|
24
|
-
|
|
16
|
+
var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));
|
|
25
17
|
|
|
26
|
-
|
|
18
|
+
var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));
|
|
27
19
|
|
|
28
|
-
|
|
20
|
+
var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits"));
|
|
29
21
|
|
|
30
|
-
|
|
22
|
+
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
31
23
|
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
35
|
-
|
|
36
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }
|
|
37
|
-
|
|
38
|
-
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
39
|
-
|
|
40
|
-
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; }
|
|
24
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
41
25
|
|
|
42
|
-
var
|
|
43
|
-
_inherits(TabPane, _Component);
|
|
26
|
+
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
44
27
|
|
|
45
|
-
|
|
28
|
+
var TabPane =
|
|
29
|
+
/*#__PURE__*/
|
|
30
|
+
function (_Component) {
|
|
31
|
+
(0, _inherits2["default"])(TabPane, _Component);
|
|
46
32
|
|
|
47
33
|
function TabPane() {
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
return _super.apply(this, arguments);
|
|
34
|
+
(0, _classCallCheck2["default"])(this, TabPane);
|
|
35
|
+
return (0, _possibleConstructorReturn2["default"])(this, (0, _getPrototypeOf2["default"])(TabPane).apply(this, arguments));
|
|
51
36
|
}
|
|
52
37
|
|
|
53
|
-
|
|
38
|
+
(0, _createClass2["default"])(TabPane, [{
|
|
54
39
|
key: "render",
|
|
55
40
|
value: function render() {
|
|
56
41
|
var _this$props = this.props,
|
|
@@ -60,29 +45,26 @@ var TabPane = /*#__PURE__*/function (_Component) {
|
|
|
60
45
|
var style = show ? {} : {
|
|
61
46
|
display: 'none'
|
|
62
47
|
};
|
|
63
|
-
return
|
|
48
|
+
return _react["default"].createElement("div", {
|
|
64
49
|
className: "".concat(prefixCls),
|
|
65
50
|
style: style
|
|
66
51
|
}, children);
|
|
67
52
|
}
|
|
68
53
|
}]);
|
|
69
|
-
|
|
70
54
|
return TabPane;
|
|
71
55
|
}(_react.Component);
|
|
72
56
|
|
|
73
|
-
|
|
57
|
+
(0, _defineProperty2["default"])(TabPane, "defaultProps", {
|
|
74
58
|
prefixCls: 'hi-tabs-pane',
|
|
75
59
|
disabled: false,
|
|
76
|
-
|
|
60
|
+
closeable: true
|
|
77
61
|
});
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
tabName: _propTypes["default"].oneOfType([_propTypes["default"].string, _propTypes["default"].node]),
|
|
62
|
+
(0, _defineProperty2["default"])(TabPane, "propTypes", {
|
|
63
|
+
tabTitle: _propTypes["default"].oneOfType([_propTypes["default"].string, _propTypes["default"].node]),
|
|
81
64
|
tabDesc: _propTypes["default"].oneOfType([_propTypes["default"].string, _propTypes["default"].node]),
|
|
82
|
-
|
|
83
|
-
|
|
65
|
+
tabId: _propTypes["default"].oneOfType([_propTypes["default"].string, _propTypes["default"].number]),
|
|
66
|
+
closeable: _propTypes["default"].bool,
|
|
84
67
|
disabled: _propTypes["default"].bool
|
|
85
68
|
});
|
|
86
|
-
|
|
87
69
|
var _default = TabPane;
|
|
88
70
|
exports["default"] = _default;
|