tntd 1.4.0 → 1.4.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (40) hide show
  1. package/babel.config.js +1 -1
  2. package/components/Ellipsis/index.js +4 -4
  3. package/components/Select/index.js +3 -4
  4. package/dist/stats.json +4925 -4925
  5. package/dist/tntd.js +1 -1
  6. package/es/ArrayInput/index.js +8 -8
  7. package/es/Columns/index.js +4 -4
  8. package/es/DevelopmentLogin/LoginModal.js +8 -8
  9. package/es/Ellipsis/index.js +7 -7
  10. package/es/Handle/index.js +6 -6
  11. package/es/Layout/AppList.js +10 -10
  12. package/es/Layout/Application.js +2 -2
  13. package/es/Layout/Avatar.js +4 -4
  14. package/es/Layout/CompatibleLanguage.js +2 -2
  15. package/es/Layout/EnterpriseLayout/Avatar.js +6 -6
  16. package/es/Layout/EnterpriseLayout/Theme.js +2 -2
  17. package/es/Layout/HeaderActions.js +2 -2
  18. package/es/Layout/Layout.js +2 -2
  19. package/es/Layout/OrgAppList.js +6 -6
  20. package/es/Layout/SideMenu.js +2 -2
  21. package/es/Layout/Theme.js +2 -2
  22. package/es/Layout/paaslayout/index.js +2 -2
  23. package/es/LoadingButton/index.js +2 -2
  24. package/es/Modal/index.js +2 -2
  25. package/es/Page/Box.js +2 -2
  26. package/es/QueryForm/Field/Checkbox.js +2 -2
  27. package/es/QueryForm/Field/Select.js +2 -2
  28. package/es/QueryForm/Field/SelectInput.js +4 -4
  29. package/es/QueryForm/Field/fieldsMap.js +6 -6
  30. package/es/QueryForm/Field/index.js +2 -2
  31. package/es/QueryForm/index.js +8 -8
  32. package/es/QueryListScene/List.js +2 -2
  33. package/es/Select/index.js +6 -8
  34. package/es/Table/ResizableTable/index.js +2 -2
  35. package/es/Table/index.js +2 -2
  36. package/lib/Ellipsis/index.js +3 -3
  37. package/lib/Layout/EnterpriseLayout/Header.js +113 -0
  38. package/lib/Layout/EnterpriseLayout/HeaderActions.js +104 -0
  39. package/lib/Select/index.js +2 -4
  40. package/package.json +1 -1
@@ -0,0 +1,104 @@
1
+ "use strict";
2
+
3
+ function _typeof(obj) { 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); }
4
+
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
7
+ });
8
+ exports["default"] = void 0;
9
+
10
+ require("antd/lib/divider/style");
11
+
12
+ var _divider = _interopRequireDefault(require("antd/lib/divider"));
13
+
14
+ var _styledComponents = _interopRequireWildcard(require("styled-components"));
15
+
16
+ var _GlobalNavigation = _interopRequireDefault(require("../GlobalNavigation"));
17
+
18
+ var _Application = _interopRequireDefault(require("../Application"));
19
+
20
+ var _Avatar = _interopRequireDefault(require("./Avatar"));
21
+
22
+ function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function _getRequireWildcardCache() { return cache; }; return cache; }
23
+
24
+ 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; }
25
+
26
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
27
+
28
+ function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
29
+
30
+ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
31
+
32
+ function _templateObject() {
33
+ var data = _taggedTemplateLiteral(["\n list-style: none;\n display: inline-block;\n line-height: ", ";\n margin: 0 0 0 20px;\n .hasHeaderTabs & {\n margin: 0;\n }\n padding: 0;\n white-space: nowrap;\n\n .isInIframe & {\n display: none;\n }\n\n & > li {\n height: 100%;\n display: inline-block;\n vertical-align: top;\n cursor: pointer;\n font-size: 20px;\n margin: 0 7.5px;\n color: ", ";\n .large-size & {\n margin: 0 10px;\n }\n .tnt-themeS1 & {\n /* color: rgba(255,255,255,.85); */\n }\n &:last-of-type {\n margin-right: 0;\n }\n .hasHeaderTabs:not(.tnt-themeS1) & {\n color: rgba(255,255,255,.8);\n }\n }\n"]);
34
+
35
+ _templateObject = function _templateObject() {
36
+ return data;
37
+ };
38
+
39
+ return data;
40
+ }
41
+
42
+ function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
43
+
44
+ var Actions = _styledComponents["default"].ul(_templateObject(), function (props) {
45
+ return "".concat(props.theme.headerHeight, "px");
46
+ }, function (props) {
47
+ return "".concat(props.theme.headerActionsColor);
48
+ });
49
+
50
+ var _default = (0, _styledComponents.withTheme)(function (props) {
51
+ var _props$config = props.config;
52
+ _props$config = _props$config === void 0 ? {} : _props$config;
53
+
54
+ var _props$config$theme = _props$config.theme,
55
+ theme = _props$config$theme === void 0 ? true : _props$config$theme,
56
+ _props$config$avatar = _props$config.avatar,
57
+ avatar = _props$config$avatar === void 0 ? true : _props$config$avatar,
58
+ _props$config$languag = _props$config.language,
59
+ language = _props$config$languag === void 0 ? true : _props$config$languag,
60
+ _props$config$applica = _props$config.application,
61
+ application = _props$config$applica === void 0 ? false : _props$config$applica,
62
+ _props$config$globalN = _props$config.globalNavigation,
63
+ globalNavigation = _props$config$globalN === void 0 ? false : _props$config$globalN,
64
+ compatible = props.theme.compatible,
65
+ _props$userInfo = props.userInfo,
66
+ userInfo = _props$userInfo === void 0 ? {} : _props$userInfo,
67
+ menus = props.menus,
68
+ apps = props.apps,
69
+ extraActions = props.extraActions,
70
+ headerRef = props.headerRef,
71
+ onLanguageChange = props.onLanguageChange,
72
+ onThemeChange = props.onThemeChange,
73
+ onApplicationChange = props.onApplicationChange,
74
+ onAppChange = props.onAppChange,
75
+ onCollapseChange = props.onCollapseChange,
76
+ onPersonalSetting = props.onPersonalSetting,
77
+ onChangePassword = props.onChangePassword,
78
+ onLogout = props.onLogout,
79
+ onLogoClick = props.onLogoClick,
80
+ rest = _objectWithoutProperties(props, ["config", "theme", "userInfo", "menus", "apps", "extraActions", "headerRef", "onLanguageChange", "onThemeChange", "onApplicationChange", "onAppChange", "onCollapseChange", "onPersonalSetting", "onChangePassword", "onLogout", "onLogoClick"]);
81
+
82
+ return React.createElement(Actions, rest, extraActions, globalNavigation && React.createElement(_GlobalNavigation["default"], {
83
+ headerRef: headerRef,
84
+ menus: menus
85
+ }), application && React.createElement(_Application["default"], {
86
+ language: userInfo.lang,
87
+ apps: apps,
88
+ onChange: onApplicationChange
89
+ }), avatar && React.createElement(React.Fragment, null, React.createElement(_divider["default"], {
90
+ type: "vertical"
91
+ }), React.createElement(_Avatar["default"], {
92
+ userInfo: userInfo,
93
+ onThemeChange: onThemeChange,
94
+ onPersonalSetting: onPersonalSetting,
95
+ onChangePassword: onChangePassword,
96
+ onLogout: onLogout,
97
+ config: {
98
+ theme: theme,
99
+ language: language
100
+ }
101
+ })));
102
+ });
103
+
104
+ exports["default"] = _default;
@@ -503,11 +503,9 @@ function (_PureComponent) {
503
503
  _this2.addEvent();
504
504
  }, 500);
505
505
  var arr = this.props.children;
506
- var children = this.turnChildren(arr);
506
+ var children = this.turnChildren(arr); // if (children && children.length > 0) {
507
507
 
508
- if (children && children.length > 0) {
509
- this.formulaWidth();
510
- }
508
+ this.formulaWidth(); // }
511
509
  }
512
510
  }, {
513
511
  key: "componentDidUpdate",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tntd",
3
- "version": "1.4.0",
3
+ "version": "1.4.3",
4
4
  "description": "ued tnt design",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",