@oceanbase/ui 0.2.37 → 0.3.0
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/dist/ui.min.css +1 -1
- package/dist/ui.min.js +1 -1
- package/es/Action/Group.js +2 -2
- package/es/Action/Item.js +2 -2
- package/es/BackgroundTaskManager/index.js +2 -2
- package/es/BasicLayout/Header.js +2 -2
- package/es/BasicLayout/index.js +4 -5
- package/es/BasicLayout/style/Header.js +17 -18
- package/es/BasicLayout/style/index.js +57 -58
- package/es/BatchOperationBar/index.js +6 -7
- package/es/Boundary/Components/Exception.js +2 -2
- package/es/Boundary/utils.js +0 -1
- package/es/ContentWithIcon/index.js +3 -4
- package/es/ContentWithQuestion/index.js +3 -4
- package/es/ContentWithQuestion/style/index.js +8 -9
- package/es/Dialog/Anchor.js +2 -2
- package/es/Dialog/index.js +2 -2
- package/es/DocDialog/index.js +2 -2
- package/es/FooterToolbar/index.js +6 -23
- package/es/FooterToolbar/style/index.d.ts +1 -0
- package/es/FooterToolbar/style/index.js +82 -8
- package/es/FullscreenBox/index.js +2 -2
- package/es/Highlight/DiffView/DiffCells.js +4 -4
- package/es/Highlight/DiffView/index.js +2 -2
- package/es/Highlight/JsonView.js +2 -2
- package/es/Highlight/index.d.ts +1 -1
- package/es/Highlight/index.js +2 -2
- package/es/IconFont/index.js +2 -2
- package/es/LocaleDropdown/index.js +2 -2
- package/es/Login/ActivateForm.js +2 -2
- package/es/Login/LoginForm.js +2 -2
- package/es/Login/RegisterForm.js +2 -2
- package/es/Login/index.js +3 -4
- package/es/PageContainer/index.js +10 -40
- package/es/PageContainer/style/index.js +15 -16
- package/es/PageLoading/index.d.ts +7 -0
- package/es/PageLoading/index.js +40 -0
- package/es/Password/index.js +2 -2
- package/es/Password/locale/en-US.js +2 -2
- package/es/Ranger/QuickPicker.js +2 -2
- package/es/Ranger/Ranger.js +2 -2
- package/es/Ranger/constant/index.js +2 -2
- package/es/Ranger/index.less +2 -2
- package/es/SideTip/Dragger.js +3 -4
- package/es/SideTip/IconLoading.js +2 -2
- package/es/SideTip/index.js +5 -6
- package/es/TagSelect/Item.js +3 -4
- package/es/TagSelect/style/index.js +17 -17
- package/es/TaskGraph/Graph.js +2 -2
- package/es/TaskGraph/index.js +2 -2
- package/es/TaskGraph/register.js +2 -2
- package/es/TreeSearch/index.js +0 -1
- package/es/TreeSearch/util.js +2 -2
- package/es/Welcome/index.js +2 -2
- package/es/_util/genComponentStyleHook.js +2 -2
- package/es/_util/useNavigate.d.ts +1 -1
- package/es/index.d.ts +2 -0
- package/es/index.js +1 -0
- package/es/locale/LocaleWrapper.js +2 -2
- package/es/locale/en-US.js +2 -2
- package/es/locale/zh-CN.js +2 -2
- package/es/locale/zh-TW.js +2 -2
- package/lib/FooterToolbar/index.js +1 -14
- package/lib/FooterToolbar/style/index.d.ts +1 -0
- package/lib/FooterToolbar/style/index.js +120 -6
- package/lib/Highlight/index.d.ts +1 -1
- package/lib/PageContainer/index.js +4 -28
- package/lib/PageLoading/index.d.ts +7 -0
- package/lib/PageLoading/index.js +72 -0
- package/lib/Password/locale/en-US.js +2 -2
- package/lib/Ranger/index.less +2 -2
- package/lib/_util/useNavigate.d.ts +1 -1
- package/lib/index.d.ts +2 -0
- package/lib/index.js +3 -0
- package/package.json +8 -8
package/es/Action/Group.js
CHANGED
|
@@ -2,8 +2,8 @@ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" ==
|
|
|
2
2
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
3
3
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
4
4
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
5
|
-
function _toPropertyKey(
|
|
6
|
-
function _toPrimitive(
|
|
5
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
6
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
7
7
|
import { Button, Dropdown, Menu, Space, Tooltip, Typography } from '@oceanbase/design';
|
|
8
8
|
import { EllipsisOutlined, LoadingOutlined } from '@oceanbase/icons';
|
|
9
9
|
import { isBoolean, max, omit } from 'lodash';
|
package/es/Action/Item.js
CHANGED
|
@@ -10,8 +10,8 @@ function _assertThisInitialized(self) { if (self === void 0) { throw new Referen
|
|
|
10
10
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
11
11
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
12
12
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
13
|
-
function _toPropertyKey(
|
|
14
|
-
function _toPrimitive(
|
|
13
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
14
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
15
15
|
import { LoadingOutlined } from '@oceanbase/icons';
|
|
16
16
|
import { Button, Tooltip, Typography } from '@oceanbase/design';
|
|
17
17
|
import React from 'react';
|
|
@@ -2,8 +2,8 @@ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" ==
|
|
|
2
2
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
3
3
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
4
4
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
5
|
-
function _toPropertyKey(
|
|
6
|
-
function _toPrimitive(
|
|
5
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
6
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
7
7
|
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
8
8
|
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."); }
|
|
9
9
|
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); }
|
package/es/BasicLayout/Header.js
CHANGED
|
@@ -3,8 +3,8 @@ var _excluded = ["prefixCls", "showLabel", "title", "extra", "pathname", "welcom
|
|
|
3
3
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
4
4
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
5
5
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
6
|
-
function _toPropertyKey(
|
|
7
|
-
function _toPrimitive(
|
|
6
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
7
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
8
8
|
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
9
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
10
|
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); }
|
package/es/BasicLayout/index.js
CHANGED
|
@@ -3,8 +3,8 @@ var _excluded = ["children", "location", "banner", "iconUrl", "logoUrl", "simple
|
|
|
3
3
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
4
4
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
5
5
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
6
|
-
function _toPropertyKey(
|
|
7
|
-
function _toPrimitive(
|
|
6
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
7
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
8
8
|
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
|
|
9
9
|
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
10
10
|
function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
@@ -40,7 +40,6 @@ var Content = Layout.Content,
|
|
|
40
40
|
var SubMenu = Menu.SubMenu,
|
|
41
41
|
Item = Menu.Item;
|
|
42
42
|
var BasicLayout = function BasicLayout(_ref) {
|
|
43
|
-
var _classNames, _classNames2;
|
|
44
43
|
var children = _ref.children,
|
|
45
44
|
_ref$location = _ref.location,
|
|
46
45
|
_ref$location2 = _ref$location === void 0 ? {} : _ref$location,
|
|
@@ -282,7 +281,7 @@ var BasicLayout = function BasicLayout(_ref) {
|
|
|
282
281
|
className: "".concat(prefixCls, "-banner-wrapper"),
|
|
283
282
|
children: banner
|
|
284
283
|
}), /*#__PURE__*/_jsx(Layout, _objectSpread(_objectSpread({
|
|
285
|
-
className: classNames(prefixCls, (
|
|
284
|
+
className: classNames(prefixCls, _defineProperty(_defineProperty({}, "".concat(prefixCls, "-with-banner"), banner), "".concat(prefixCls, "-sider-").concat(siderWidth), true), className)
|
|
286
285
|
}, restProps), {}, {
|
|
287
286
|
children: /*#__PURE__*/_jsxs(React.Fragment, {
|
|
288
287
|
children: [/*#__PURE__*/_jsx(Header, _objectSpread({
|
|
@@ -300,7 +299,7 @@ var BasicLayout = function BasicLayout(_ref) {
|
|
|
300
299
|
children: [(subSideMenus || menus) && /*#__PURE__*/_jsx(Sider, {
|
|
301
300
|
theme: "light",
|
|
302
301
|
width: siderWidth,
|
|
303
|
-
className: classNames("".concat(prefixCls, "-sider"), (
|
|
302
|
+
className: classNames("".concat(prefixCls, "-sider"), _defineProperty(_defineProperty({}, "".concat(prefixCls, "-sider-collapsed"), collapsed), "".concat(prefixCls, "-sider-has-sub-sider"), subSideMenus)),
|
|
304
303
|
children: /*#__PURE__*/_jsxs("div", {
|
|
305
304
|
className: "".concat(prefixCls, "-sider-wrapper"),
|
|
306
305
|
children: [subSideMenus && /*#__PURE__*/_jsx("div", {
|
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
2
2
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
3
|
-
function _toPropertyKey(
|
|
4
|
-
function _toPrimitive(
|
|
3
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
4
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
5
5
|
import { genComponentStyleHook } from "../../_util/genComponentStyleHook";
|
|
6
6
|
export var genHeaderStyle = function genHeaderStyle(token) {
|
|
7
|
-
var _$concat2, _$concat5, _$concat7, _ref;
|
|
8
7
|
var componentCls = token.componentCls;
|
|
9
|
-
return
|
|
8
|
+
return _defineProperty(_defineProperty({}, "".concat(componentCls), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({
|
|
10
9
|
position: 'fixed',
|
|
11
10
|
zIndex: 10,
|
|
12
11
|
width: '100%',
|
|
@@ -15,17 +14,17 @@ export var genHeaderStyle = function genHeaderStyle(token) {
|
|
|
15
14
|
lineHeight: '48px',
|
|
16
15
|
backgroundColor: token.colorBgLayout,
|
|
17
16
|
boxShadow: "inset 0 -1px 0 0 ".concat(token.colorBorderSecondary)
|
|
18
|
-
},
|
|
17
|
+
}, "".concat(componentCls, "-content"), {
|
|
19
18
|
display: 'flex',
|
|
20
19
|
alignItems: 'center',
|
|
21
20
|
justifyContent: 'space-between',
|
|
22
21
|
maxWidth: token.maxWidth,
|
|
23
22
|
height: '100%',
|
|
24
23
|
margin: '0 auto'
|
|
25
|
-
}),
|
|
24
|
+
}), "".concat(componentCls, "-logo"), {
|
|
26
25
|
height: 24,
|
|
27
26
|
cursor: 'pointer'
|
|
28
|
-
}),
|
|
27
|
+
}), "".concat(componentCls, "-icon"), {
|
|
29
28
|
width: 52,
|
|
30
29
|
height: 48,
|
|
31
30
|
lineHeight: '48px',
|
|
@@ -37,29 +36,29 @@ export var genHeaderStyle = function genHeaderStyle(token) {
|
|
|
37
36
|
height: 32,
|
|
38
37
|
marginTop: 8
|
|
39
38
|
}
|
|
40
|
-
}),
|
|
39
|
+
}), "".concat(componentCls, "-title"), {
|
|
41
40
|
/* 占据剩余的全部空间 */
|
|
42
41
|
flex: 1,
|
|
43
42
|
margin: '0 16px'
|
|
44
|
-
}),
|
|
43
|
+
}), "".concat(componentCls, "-extra"), _defineProperty({
|
|
45
44
|
display: 'flex',
|
|
46
45
|
alignItems: 'center',
|
|
47
46
|
justifyContent: 'space-between'
|
|
48
|
-
}, "".concat(componentCls, "-extra-item"), (
|
|
47
|
+
}, "".concat(componentCls, "-extra-item"), _defineProperty(_defineProperty({
|
|
49
48
|
display: 'inline-flex',
|
|
50
49
|
fontSize: 12,
|
|
51
50
|
cursor: 'pointer',
|
|
52
51
|
'&:not(:last-child)': {
|
|
53
52
|
marginRight: 24
|
|
54
53
|
}
|
|
55
|
-
},
|
|
54
|
+
}, "".concat(componentCls, "-extra-icon-wrapper"), {
|
|
56
55
|
width: 28,
|
|
57
56
|
height: 28,
|
|
58
57
|
lineHeight: '28px',
|
|
59
58
|
textAlign: 'center',
|
|
60
59
|
border: '0.88px solid #ced4e1',
|
|
61
60
|
borderRadius: 14
|
|
62
|
-
}),
|
|
61
|
+
}), "".concat(componentCls, "-extra-user-wrapper"), _defineProperty({
|
|
63
62
|
height: 28,
|
|
64
63
|
padding: '0 10px',
|
|
65
64
|
lineHeight: '28px',
|
|
@@ -67,24 +66,24 @@ export var genHeaderStyle = function genHeaderStyle(token) {
|
|
|
67
66
|
borderRadius: 14
|
|
68
67
|
}, "".concat(componentCls, "-extra-user-icon"), {
|
|
69
68
|
marginRight: 6
|
|
70
|
-
}))
|
|
69
|
+
})))), "".concat(componentCls, "-extra-with-label"), _defineProperty({}, "".concat(componentCls, "-extra-item"), {
|
|
71
70
|
'&:not(:last-child)': {
|
|
72
71
|
marginRight: '24px !important'
|
|
73
72
|
}
|
|
74
|
-
}))
|
|
73
|
+
}))), "".concat(componentCls, "-about-wrapper"), _defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(componentCls, "-about"), {
|
|
75
74
|
marginTop: 12
|
|
76
|
-
}),
|
|
75
|
+
}), "".concat(componentCls, "-logo"), {
|
|
77
76
|
height: 72
|
|
78
|
-
}),
|
|
77
|
+
}), "".concat(componentCls, "-release-info"), _defineProperty({
|
|
79
78
|
marginTop: 20,
|
|
80
79
|
marginBottom: 50
|
|
81
80
|
}, "".concat(componentCls, "-date"), {
|
|
82
81
|
fontSize: 12,
|
|
83
82
|
color: token.colorTextTertiary
|
|
84
|
-
})),
|
|
83
|
+
})), "".concat(componentCls, "-copyright"), {
|
|
85
84
|
fontSize: 12,
|
|
86
85
|
color: token.colorTextTertiary
|
|
87
|
-
})
|
|
86
|
+
}));
|
|
88
87
|
};
|
|
89
88
|
export default (function (prefixCls) {
|
|
90
89
|
var useStyle = genComponentStyleHook('Header', function (token) {
|
|
@@ -2,11 +2,10 @@ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" ==
|
|
|
2
2
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
3
3
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
4
4
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
5
|
-
function _toPropertyKey(
|
|
6
|
-
function _toPrimitive(
|
|
5
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
6
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
7
7
|
import { genComponentStyleHook } from "../../_util/genComponentStyleHook";
|
|
8
8
|
export var genBasicLayoutStyle = function genBasicLayoutStyle(token) {
|
|
9
|
-
var _objectSpread2, _$concat2, _$concat5, _$concat8, _$concat$concat$conca2, _$concat9, _$concat12, _$concat13, _$concat14, _$concat16, _$concat17, _$concat18, _$concat19, _mediaMinWidth$, _$concat22, _objectSpread3;
|
|
10
9
|
var antCls = token.antCls,
|
|
11
10
|
iconCls = token.iconCls,
|
|
12
11
|
componentCls = token.componentCls,
|
|
@@ -27,31 +26,31 @@ export var genBasicLayoutStyle = function genBasicLayoutStyle(token) {
|
|
|
27
26
|
transition: "width ".concat(motionDurationSlow)
|
|
28
27
|
});
|
|
29
28
|
});
|
|
30
|
-
return _objectSpread(_objectSpread((
|
|
29
|
+
return _objectSpread(_objectSpread(_defineProperty(_defineProperty({}, "".concat(componentCls, "-banner-wrapper"), {
|
|
31
30
|
position: 'fixed',
|
|
32
31
|
top: 0,
|
|
33
32
|
zIndex: 20,
|
|
34
33
|
width: '100%'
|
|
35
|
-
}),
|
|
34
|
+
}), "".concat(componentCls, "-with-banner"), {
|
|
36
35
|
marginTop: '38px'
|
|
37
|
-
}),
|
|
36
|
+
}), footerBarStyle), {}, _defineProperty(_defineProperty(_defineProperty({}, "".concat(componentCls), _defineProperty(_defineProperty({
|
|
38
37
|
height: '100%',
|
|
39
38
|
backgroundColor: colorBgLayout,
|
|
40
39
|
transition: 'all 0.1s'
|
|
41
|
-
},
|
|
40
|
+
}, "".concat(proComponentsCls, "-page-container"), {
|
|
42
41
|
// 48px is the height of BasicLayout header
|
|
43
42
|
minHeight: 'calc(100vh - 48px)'
|
|
44
|
-
}),
|
|
43
|
+
}), "".concat(componentCls, "-content-layout"), _defineProperty(_defineProperty(_defineProperty(_defineProperty({
|
|
45
44
|
maxWidth: maxWidth,
|
|
46
45
|
// 居中对齐
|
|
47
46
|
margin: '0 auto'
|
|
48
|
-
},
|
|
47
|
+
}, "".concat(componentCls, "-sider"), _defineProperty(_defineProperty({
|
|
49
48
|
position: 'fixed',
|
|
50
49
|
zIndex: 10,
|
|
51
50
|
padding: '16px 0 16px 16px',
|
|
52
51
|
backgroundColor: colorBgLayout,
|
|
53
52
|
transition: 'all 0.3s'
|
|
54
|
-
},
|
|
53
|
+
}, "".concat(componentCls, "-sider-border"), _defineProperty(_defineProperty(_defineProperty({
|
|
55
54
|
position: 'relative',
|
|
56
55
|
top: '-16px',
|
|
57
56
|
width: 1,
|
|
@@ -59,21 +58,21 @@ export var genBasicLayoutStyle = function genBasicLayoutStyle(token) {
|
|
|
59
58
|
backgroundColor: '#e2e8f3',
|
|
60
59
|
cursor: 'pointer',
|
|
61
60
|
opacity: 0
|
|
62
|
-
},
|
|
61
|
+
}, '&::after', {
|
|
63
62
|
position: 'absolute',
|
|
64
63
|
top: 0,
|
|
65
64
|
right: '-10px',
|
|
66
65
|
bottom: 0,
|
|
67
66
|
left: '-10px',
|
|
68
67
|
content: '""'
|
|
69
|
-
}),
|
|
68
|
+
}), '&:hover', _defineProperty({
|
|
70
69
|
opacity: 1,
|
|
71
70
|
// 仅在 hover 时增加过渡动画,避免展开/收起时 border 和 collapse 没有及时消失、影响整体效果
|
|
72
71
|
transition: 'opacity 0.3s'
|
|
73
72
|
}, "".concat(componentCls, "-sider-collapse"), {
|
|
74
73
|
opacity: 1,
|
|
75
74
|
transition: 'opacity 0.3s'
|
|
76
|
-
})),
|
|
75
|
+
})), "".concat(componentCls, "-sider-collapse"), _defineProperty({
|
|
77
76
|
position: 'relative',
|
|
78
77
|
top: '245px',
|
|
79
78
|
right: 10,
|
|
@@ -92,13 +91,13 @@ export var genBasicLayoutStyle = function genBasicLayoutStyle(token) {
|
|
|
92
91
|
fontSize: 'px',
|
|
93
92
|
display: 'block',
|
|
94
93
|
lineHeight: '42px'
|
|
95
|
-
}))
|
|
94
|
+
}))), "".concat(componentCls, "-sider-wrapper"), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({
|
|
96
95
|
display: 'flex',
|
|
97
96
|
height: 'calc(100vh - 48px)'
|
|
98
|
-
},
|
|
97
|
+
}, "".concat(antCls, "-menu"), _defineProperty(_defineProperty(_defineProperty({
|
|
99
98
|
backgroundColor: 'transparent',
|
|
100
99
|
borderRight: 'none'
|
|
101
|
-
},
|
|
100
|
+
}, "".concat(antCls, "-menu-item"), _defineProperty({
|
|
102
101
|
width: '100%',
|
|
103
102
|
marginTop: 0,
|
|
104
103
|
marginRight: 'auto',
|
|
@@ -110,7 +109,7 @@ export var genBasicLayoutStyle = function genBasicLayoutStyle(token) {
|
|
|
110
109
|
width: '18px',
|
|
111
110
|
height: '18px',
|
|
112
111
|
fontSize: '18px'
|
|
113
|
-
})),
|
|
112
|
+
})), "".concat(antCls, "-menu-submenu"), _defineProperty({
|
|
114
113
|
width: '100%',
|
|
115
114
|
marginTop: 0,
|
|
116
115
|
marginRight: 'auto',
|
|
@@ -122,32 +121,32 @@ export var genBasicLayoutStyle = function genBasicLayoutStyle(token) {
|
|
|
122
121
|
width: '18px',
|
|
123
122
|
height: '18px',
|
|
124
123
|
fontSize: '18px'
|
|
125
|
-
})),
|
|
124
|
+
})), "".concat(antCls, "-menu-submenu > ").concat(antCls, "-menu-submenu-title"), {
|
|
126
125
|
width: '100%',
|
|
127
126
|
marginBottom: '4px !important',
|
|
128
127
|
marginInline: 0,
|
|
129
128
|
marginBlock: 0
|
|
130
|
-
})
|
|
129
|
+
})), "".concat(antCls, "-menu-inline"), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(antCls, "-menu-item, ").concat(antCls, "-menu-submenu"), {
|
|
131
130
|
'&:not(:last-child)': {
|
|
132
131
|
marginBottom: '16px',
|
|
133
132
|
// 子菜单展开时 marginBottom 会变小,为了避免效果突兀,增加过渡效果
|
|
134
133
|
transition: 'marginBottom 0.2s'
|
|
135
134
|
}
|
|
136
|
-
}),
|
|
135
|
+
}), "".concat(antCls, "-menu-submenu-open"), {
|
|
137
136
|
'&:not(:last-childantCls)': {
|
|
138
137
|
// 子菜单展开时,减小 marginBottom
|
|
139
138
|
marginBottom: 4
|
|
140
139
|
}
|
|
141
|
-
}),
|
|
140
|
+
}), "".concat(antCls, "-menu-submenu"), _defineProperty({}, "".concat(antCls, "-menu-item:not(:last-child)"), {
|
|
142
141
|
marginBottom: 4
|
|
143
|
-
})),
|
|
142
|
+
})), "".concat(antCls, "-menu-item, ").concat(antCls, "-menu-submenu > ").concat(antCls, "-menu-submenu-title"), _defineProperty({
|
|
144
143
|
paddingLeft: '16px !important'
|
|
145
144
|
}, "".concat(antCls, "-menu-title-content"), {
|
|
146
145
|
width: '108px'
|
|
147
|
-
})),
|
|
146
|
+
})), "".concat(antCls, "-menu-sub"), _defineProperty({}, "".concat(antCls, "-menu-item"), {
|
|
148
147
|
marginLeft: '16px',
|
|
149
148
|
paddingLeft: '28px !important'
|
|
150
|
-
})),
|
|
149
|
+
})), "".concat(antCls, "-menu-item-active, ").concat(antCls, "-menu-submenu-active > ").concat(antCls, "-menu-submenu-title"), {
|
|
151
150
|
color: "".concat(colorText, " !important"),
|
|
152
151
|
fontWeight: 600,
|
|
153
152
|
animation: 'activeGradientAnimation 0.1s',
|
|
@@ -158,7 +157,7 @@ export var genBasicLayoutStyle = function genBasicLayoutStyle(token) {
|
|
|
158
157
|
border: '.5px solid transparent',
|
|
159
158
|
borderRadius: '8px 0 0 8px',
|
|
160
159
|
transition: 'border-width .3s'
|
|
161
|
-
}),
|
|
160
|
+
}), "".concat(antCls, "-menu-item-selected"), {
|
|
162
161
|
color: "".concat(colorPrimary, " !important"),
|
|
163
162
|
fontWeight: 600,
|
|
164
163
|
animation: 'selectedGradientAnimation 0.5s',
|
|
@@ -174,47 +173,47 @@ export var genBasicLayoutStyle = function genBasicLayoutStyle(token) {
|
|
|
174
173
|
// 去掉菜单项的选中标记
|
|
175
174
|
display: 'none'
|
|
176
175
|
}
|
|
177
|
-
}),
|
|
176
|
+
}), "".concat(antCls, "-menu-submenu-selected > ").concat(antCls, "-menu-submenu-title"), {
|
|
178
177
|
color: "".concat(colorPrimary, " !important")
|
|
179
|
-
}),
|
|
178
|
+
}), "".concat(antCls, "-divider"), {
|
|
180
179
|
margin: '0 0 16px 0'
|
|
181
|
-
})
|
|
180
|
+
})), "".concat(antCls, "-menu-vertical"), _defineProperty(_defineProperty(_defineProperty(_defineProperty({
|
|
182
181
|
overflowX: 'hidden',
|
|
183
182
|
overflowY: 'auto',
|
|
184
183
|
borderRight: 'none'
|
|
185
|
-
},
|
|
184
|
+
}, "".concat(antCls, "-menu-item, ").concat(antCls, "-menu-submenu"), {
|
|
186
185
|
'&:not(:last-child)': {
|
|
187
186
|
marginBottom: 4
|
|
188
187
|
}
|
|
189
|
-
}),
|
|
188
|
+
}), "".concat(antCls, "-menu-item, ").concat(antCls, "-menu-submenu > ").concat(antCls, "-menu-submenu-title"), _defineProperty(_defineProperty({
|
|
190
189
|
width: '52px',
|
|
191
190
|
height: '52px',
|
|
192
191
|
padding: 0,
|
|
193
192
|
lineHeight: '52px',
|
|
194
193
|
textAlign: 'center'
|
|
195
|
-
},
|
|
194
|
+
}, "".concat(antCls, "-menu-title-content"), {
|
|
196
195
|
display: 'inline-block',
|
|
197
196
|
width: '40px',
|
|
198
197
|
height: '40px',
|
|
199
198
|
lineHeight: '40px',
|
|
200
199
|
borderRadius: '8px'
|
|
201
|
-
}),
|
|
200
|
+
}), "".concat(antCls, "-menu-submenu-arrow"), {
|
|
202
201
|
display: 'none'
|
|
203
|
-
})
|
|
202
|
+
})), "".concat(antCls, "-menu-item-active, ").concat(antCls, "-menu-submenu-active > ").concat(antCls, "-menu-submenu-title"), _defineProperty({}, "".concat(antCls, "-menu-title-content"), {
|
|
204
203
|
backgroundColor: '#e9edf6',
|
|
205
204
|
border: '0.5px solid #c6cdd9'
|
|
206
|
-
})),
|
|
205
|
+
})), "".concat(antCls, "-menu-item-selected, ").concat(antCls, "-menu-submenu-selected > ").concat(antCls, "-menu-submenu-title"), _defineProperty({}, "".concat(antCls, "-menu-title-content"), {
|
|
207
206
|
backgroundColor: '#e5eeff',
|
|
208
207
|
border: "0.5px solid ".concat(colorPrimaryBorder)
|
|
209
|
-
}))
|
|
208
|
+
}))), "".concat(componentCls, "-sub-sider"), _defineProperty({
|
|
210
209
|
borderRight: '1px solid #e2e8f3'
|
|
211
210
|
}, "".concat(antCls, "-divider"), {
|
|
212
211
|
margin: '0 0 4px 0'
|
|
213
|
-
})),
|
|
212
|
+
})), "".concat(componentCls, "-sub-sider, ").concat(componentCls, "-menu-collapsed"), _defineProperty({
|
|
214
213
|
width: '52px'
|
|
215
214
|
}, "".concat(antCls, "-divider"), {
|
|
216
215
|
margin: '0 0 4px 0'
|
|
217
|
-
})),
|
|
216
|
+
})), "".concat(componentCls, "-sider-content"), _defineProperty(_defineProperty({
|
|
218
217
|
display: 'flex',
|
|
219
218
|
flex: 1,
|
|
220
219
|
// 纵向排列
|
|
@@ -222,9 +221,9 @@ export var genBasicLayoutStyle = function genBasicLayoutStyle(token) {
|
|
|
222
221
|
// 纵向两端对齐
|
|
223
222
|
justifyContent: 'space-between',
|
|
224
223
|
height: '100%'
|
|
225
|
-
},
|
|
224
|
+
}, "".concat(componentCls, "-sider-header"), {
|
|
226
225
|
paddingTop: '16px'
|
|
227
|
-
}),
|
|
226
|
+
}), "".concat(componentCls, "-menu-wrapper"), _defineProperty({
|
|
228
227
|
display: 'flex',
|
|
229
228
|
flexDirection: 'column',
|
|
230
229
|
// 保证垂直方向超出高度出现滚动
|
|
@@ -236,41 +235,41 @@ export var genBasicLayoutStyle = function genBasicLayoutStyle(token) {
|
|
|
236
235
|
backgroundColor: 'transparent',
|
|
237
236
|
borderRight: 'none',
|
|
238
237
|
marginBottom: '32px'
|
|
239
|
-
}))
|
|
238
|
+
}))))), "".concat(componentCls, "-sider-collapsed"), {
|
|
240
239
|
paddingLeft: 0
|
|
241
|
-
}),
|
|
240
|
+
}), "".concat(componentCls, "-sider-has-sub-sider"), _defineProperty(_defineProperty(_defineProperty(_defineProperty({
|
|
242
241
|
padding: 0
|
|
243
|
-
},
|
|
242
|
+
}, "".concat(componentCls, "-sider-border"), _defineProperty({
|
|
244
243
|
display: 'none'
|
|
245
244
|
}, "".concat(componentCls, "-sider-collapse"), {
|
|
246
245
|
display: 'none'
|
|
247
|
-
})),
|
|
246
|
+
})), "".concat(antCls, "-menu-inline"), _defineProperty(_defineProperty({
|
|
248
247
|
paddingTop: '16px'
|
|
249
|
-
},
|
|
248
|
+
}, "".concat(antCls, "-menu-item, ").concat(antCls, "-menu-submenu"), {
|
|
250
249
|
'&:not(:last-child)': {
|
|
251
250
|
marginBottom: '16px !important'
|
|
252
251
|
}
|
|
253
|
-
}),
|
|
252
|
+
}), "".concat(antCls, "-divider"), {
|
|
254
253
|
width: '60%',
|
|
255
254
|
minWidth: '60%',
|
|
256
255
|
margin: '-8px 0 8px 16px !important'
|
|
257
|
-
})
|
|
256
|
+
})), "".concat(antCls, "-menu-vertical"), {
|
|
258
257
|
paddingTop: '10px'
|
|
259
|
-
}),
|
|
258
|
+
}), "".concat(componentCls, "-sider-content"), {
|
|
260
259
|
paddingLeft: '6px'
|
|
261
|
-
})
|
|
260
|
+
})), "".concat(componentCls, "-content"), {
|
|
262
261
|
backgroundColor: colorBgLayout,
|
|
263
262
|
transition: 'all 0.3s'
|
|
264
|
-
})
|
|
263
|
+
}))), "@media (min-width: ".concat(maxWidth, ")"), _defineProperty(_defineProperty({}, "".concat(componentCls), _defineProperty({}, "".concat(componentCls, "-content-layout"), _defineProperty({}, "".concat(componentCls, "-sider"), {
|
|
265
264
|
paddingLeft: 0
|
|
266
|
-
}))),
|
|
265
|
+
}))), "".concat(proComponentsCls, "-footer-bar"), {
|
|
267
266
|
right: "calc((100% - ".concat(maxWidth, ") / 2 + 24px)"),
|
|
268
267
|
width: "calc(".concat(maxWidth, " - 192px - 24px - 24px)"),
|
|
269
268
|
maxWidth: "calc(".concat(maxWidth, " - 192px - 24px - 24px)")
|
|
270
|
-
})
|
|
269
|
+
})), "".concat(antCls, "-menu-submenu-popup"), _defineProperty({}, "".concat(antCls, "-menu"), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({
|
|
271
270
|
paddingLeft: '6px !important',
|
|
272
271
|
backgroundColor: "".concat(colorBgLayout, " !important")
|
|
273
|
-
},
|
|
272
|
+
}, "".concat(antCls, "-menu-item"), {
|
|
274
273
|
width: '100%',
|
|
275
274
|
backgroundColor: 'transparent',
|
|
276
275
|
border: 'none',
|
|
@@ -278,7 +277,7 @@ export var genBasicLayoutStyle = function genBasicLayoutStyle(token) {
|
|
|
278
277
|
'&:not(:last-child):': {
|
|
279
278
|
marginBottom: '8px !important'
|
|
280
279
|
}
|
|
281
|
-
}),
|
|
280
|
+
}), "".concat(antCls, "-menu-submenu"), {
|
|
282
281
|
width: '100%',
|
|
283
282
|
backgroundColor: 'transparent',
|
|
284
283
|
border: 'none',
|
|
@@ -286,7 +285,7 @@ export var genBasicLayoutStyle = function genBasicLayoutStyle(token) {
|
|
|
286
285
|
'&:not(:last-child):': {
|
|
287
286
|
marginBottom: '8px !important'
|
|
288
287
|
}
|
|
289
|
-
}),
|
|
288
|
+
}), "".concat(antCls, "-menu-item-active"), {
|
|
290
289
|
color: 'colorText !important',
|
|
291
290
|
fontWeight: 600,
|
|
292
291
|
animation: 'activeGradientAnimation 0.1s',
|
|
@@ -297,7 +296,7 @@ export var genBasicLayoutStyle = function genBasicLayoutStyle(token) {
|
|
|
297
296
|
border: '.5px solid transparent',
|
|
298
297
|
borderRadius: '8px 0 0 8px',
|
|
299
298
|
transition: 'border-width .3s'
|
|
300
|
-
}),
|
|
299
|
+
}), "".concat(antCls, "-menu-submenu-active > & ").concat(antCls, "-menu-submenu-title"), {
|
|
301
300
|
color: 'colorText !important',
|
|
302
301
|
fontWeight: 600,
|
|
303
302
|
animation: 'activeGradientAnimation 0.1s',
|
|
@@ -308,7 +307,7 @@ export var genBasicLayoutStyle = function genBasicLayoutStyle(token) {
|
|
|
308
307
|
border: '.5px solid transparent',
|
|
309
308
|
borderRadius: '8px 0 0 8px',
|
|
310
309
|
transition: 'border-width .3s'
|
|
311
|
-
}),
|
|
310
|
+
}), "".concat(antCls, "-menu-item-selected"), {
|
|
312
311
|
color: "".concat(colorPrimary, " !important"),
|
|
313
312
|
fontWeight: 600,
|
|
314
313
|
animation: 'selectedGradientAnimation 0.1s',
|
|
@@ -319,11 +318,11 @@ export var genBasicLayoutStyle = function genBasicLayoutStyle(token) {
|
|
|
319
318
|
border: '.5px solid transparent',
|
|
320
319
|
borderRadius: '8px 0 0 8px',
|
|
321
320
|
transition: 'border-width .3s'
|
|
322
|
-
}),
|
|
321
|
+
}), "".concat(antCls, "-divider"), {
|
|
323
322
|
width: "'60%'",
|
|
324
323
|
minWidth: '60%',
|
|
325
324
|
margin: '0 0 8px 16px !important'
|
|
326
|
-
})
|
|
325
|
+
}))));
|
|
327
326
|
};
|
|
328
327
|
export default (function (prefixCls) {
|
|
329
328
|
var useStyle = genComponentStyleHook('BasicLayout', function (token) {
|
|
@@ -2,8 +2,8 @@ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" ==
|
|
|
2
2
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
3
3
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
4
4
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
5
|
-
function _toPropertyKey(
|
|
6
|
-
function _toPrimitive(
|
|
5
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
6
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
7
7
|
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
8
8
|
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."); }
|
|
9
9
|
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); }
|
|
@@ -22,7 +22,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
22
22
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
23
23
|
var prefix = 'ob-batch-operation-bar';
|
|
24
24
|
var BatchOperationBar = function BatchOperationBar(props) {
|
|
25
|
-
var
|
|
25
|
+
var _locale$alertText, _locale$alertText$rep;
|
|
26
26
|
var locale = props === null || props === void 0 ? void 0 : props.locale;
|
|
27
27
|
var title = props.title,
|
|
28
28
|
_props$open = props.open,
|
|
@@ -84,10 +84,9 @@ var BatchOperationBar = function BatchOperationBar(props) {
|
|
|
84
84
|
setSelectedData(rows);
|
|
85
85
|
};
|
|
86
86
|
var disPlayBtnRender = function disPlayBtnRender() {
|
|
87
|
-
var _classnames;
|
|
88
87
|
if (!showOpenBtn) return null;
|
|
89
88
|
return /*#__PURE__*/_jsxs("div", {
|
|
90
|
-
className: classnames((
|
|
89
|
+
className: classnames(_defineProperty(_defineProperty(_defineProperty({}, "".concat(prefix, "-open-btn"), isOpen), "".concat(prefix, "-close-btn"), !isOpen), "".concat(prefix, "-display-btn"), true)),
|
|
91
90
|
onClick: function onClick() {
|
|
92
91
|
return setIsOpen(!isOpen);
|
|
93
92
|
},
|
|
@@ -101,7 +100,7 @@ var BatchOperationBar = function BatchOperationBar(props) {
|
|
|
101
100
|
if (isEmpty(selectedRows) || !selectedRows) setSelectedData([]);else setSelectedData(selectedRows);
|
|
102
101
|
}, [selectedRows]);
|
|
103
102
|
return /*#__PURE__*/_jsxs("div", {
|
|
104
|
-
className: classnames((
|
|
103
|
+
className: classnames(_defineProperty(_defineProperty({}, className, !!className), prefix, true)),
|
|
105
104
|
style: style,
|
|
106
105
|
children: [/*#__PURE__*/_jsxs("div", {
|
|
107
106
|
className: "".concat(prefix, "-header"),
|
|
@@ -128,7 +127,7 @@ var BatchOperationBar = function BatchOperationBar(props) {
|
|
|
128
127
|
})
|
|
129
128
|
})]
|
|
130
129
|
}), /*#__PURE__*/_jsx("div", {
|
|
131
|
-
className: classnames((
|
|
130
|
+
className: classnames(_defineProperty(_defineProperty(_defineProperty({}, "".concat(prefix, "-content"), true), "".concat(prefix, "-content-active"), !!isOpen), "".concat(prefix, "-content-hidden"), !isOpen)),
|
|
132
131
|
children: typeof content === 'function' ? content === null || content === void 0 ? void 0 : content({
|
|
133
132
|
selectedRows: selectedData,
|
|
134
133
|
setSelectedRows: setSelectedRows,
|
|
@@ -10,8 +10,8 @@ function _assertThisInitialized(self) { if (self === void 0) { throw new Referen
|
|
|
10
10
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
11
11
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
12
12
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
13
|
-
function _toPropertyKey(
|
|
14
|
-
function _toPrimitive(
|
|
13
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
14
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
15
15
|
import { Alert, Button } from '@oceanbase/design';
|
|
16
16
|
import React from 'react';
|
|
17
17
|
import LocaleWrapper from "../../locale/LocaleWrapper";
|