@jetlinks-web/components 3.3.11 → 3.3.13

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 (53) hide show
  1. package/es/CardSelect/style/index.js +3 -3
  2. package/es/CheckButton/style/index.js +9 -9
  3. package/es/DragModal/style/index.js +6 -6
  4. package/es/EditTable/FormItem.js +18 -15
  5. package/es/EditTable/components/Search/sort.js +15 -1
  6. package/es/EditTable/style/body.js +8 -6
  7. package/es/EditTable/style/group.js +3 -3
  8. package/es/EditTable/style/header.js +3 -3
  9. package/es/EditTable/style/menu.js +3 -3
  10. package/es/EditTable/style/table.js +3 -3
  11. package/es/FullPage/FullPage.js +15 -5
  12. package/es/ProLayout/SiderMenu/style.js +105 -26
  13. package/es/ProLayout/TopHeader/style.js +55 -11
  14. package/es/ProTable/ProTable.js +2 -4
  15. package/es/ProTable/style/index.js +11 -8
  16. package/es/RadioButton/style/index.js +3 -2
  17. package/es/Scrollbar/style/index.js +9 -9
  18. package/es/Search/Item.js +25 -19
  19. package/es/Search/style/search.js +5 -5
  20. package/es/Skeleton/components/Page.js +18 -5
  21. package/es/Skeleton/style/index.js +12 -6
  22. package/es/Title/style/index.js +2 -2
  23. package/es/VirtualTable/style/index.js +7 -4
  24. package/es/style/scrollbar.js +24 -0
  25. package/es/style/styleRegister.js +45 -11
  26. package/es/style/variable.js +1 -4
  27. package/lib/CardSelect/style/index.js +3 -3
  28. package/lib/CheckButton/style/index.js +9 -9
  29. package/lib/DragModal/style/index.js +6 -6
  30. package/lib/EditTable/FormItem.js +18 -15
  31. package/lib/EditTable/components/Search/sort.js +15 -1
  32. package/lib/EditTable/style/body.js +8 -6
  33. package/lib/EditTable/style/group.js +3 -3
  34. package/lib/EditTable/style/header.js +3 -3
  35. package/lib/EditTable/style/menu.js +3 -3
  36. package/lib/EditTable/style/table.js +3 -3
  37. package/lib/FullPage/FullPage.js +15 -5
  38. package/lib/ProLayout/SiderMenu/style.js +104 -25
  39. package/lib/ProLayout/TopHeader/style.js +55 -11
  40. package/lib/ProTable/ProTable.js +2 -4
  41. package/lib/ProTable/style/index.js +10 -7
  42. package/lib/RadioButton/style/index.js +3 -2
  43. package/lib/Scrollbar/style/index.js +8 -8
  44. package/lib/Search/Item.js +25 -19
  45. package/lib/Search/style/search.js +5 -5
  46. package/lib/Skeleton/components/Page.js +18 -5
  47. package/lib/Skeleton/style/index.js +12 -6
  48. package/lib/Title/style/index.js +2 -2
  49. package/lib/VirtualTable/style/index.js +6 -3
  50. package/lib/style/scrollbar.js +30 -0
  51. package/lib/style/styleRegister.js +44 -10
  52. package/lib/style/variable.js +1 -4
  53. package/package.json +1 -1
@@ -4,12 +4,17 @@
4
4
  "loading": "props",
5
5
  "List": "setup-const",
6
6
  "Detail": "setup-const",
7
- "props": "setup-reactive-const"
7
+ "computed": "setup-const",
8
+ "theme": "setup-maybe-ref",
9
+ "props": "setup-reactive-const",
10
+ "token": "setup-maybe-ref",
11
+ "pageStyle": "setup-ref"
8
12
  } */
9
- import { renderSlot as _renderSlot, withCtx as _withCtx, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, createElementBlock as _createElementBlock } from "vue";
10
- const _hoisted_1 = { style: { "padding": "24px", "background-color": "#ffffff", "height": "100%" } };
13
+ import { renderSlot as _renderSlot, withCtx as _withCtx, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, normalizeStyle as _normalizeStyle, createElementBlock as _createElementBlock } from "vue";
11
14
  import List from "./List.js";
12
15
  import Detail from "./Detail.js";
16
+ import { computed } from "vue";
17
+ import { theme } from "ant-design-vue";
13
18
  const __sfc_main__ = Object.assign({
14
19
  name: 'JSkeletonPage'
15
20
  }, {
@@ -29,8 +34,16 @@ const __sfc_main__ = Object.assign({
29
34
  },
30
35
  setup(__props) {
31
36
  const props = __props;
37
+ const { token } = theme.useToken();
38
+ const pageStyle = computed(() => ({
39
+ padding: '24px',
40
+ backgroundColor: token.value.colorBgContainer,
41
+ height: '100%',
42
+ }));
32
43
  return (_ctx, _cache) => {
33
- return (_openBlock(), _createElementBlock("div", _hoisted_1, [
44
+ return (_openBlock(), _createElementBlock("div", {
45
+ style: _normalizeStyle(pageStyle.value)
46
+ }, [
34
47
  (__props.type === 'list')
35
48
  ? (_openBlock(), _createBlock(List, {
36
49
  key: 0,
@@ -55,7 +68,7 @@ const __sfc_main__ = Object.assign({
55
68
  _: 3 /* FORWARDED */
56
69
  }, 8 /* PROPS */, ["loading"]))
57
70
  : _renderSlot(_ctx.$slots, "default", { key: 2 })
58
- ]));
71
+ ], 4 /* STYLE */));
59
72
  };
60
73
  }
61
74
  });
@@ -13,9 +13,6 @@ var JSkeletonSizeLg = '36px';
13
13
  var JSkeletonSizeSm = '16px';
14
14
  var JSkeletonSize = '24px';
15
15
  var JSkeletonBorderRadius = '8px';
16
- var JSkeletonBg = '#f0f2f5';
17
- var JSkeletonBg1 = '#e6e8eb';
18
- var JSkeletonBorder = "4px solid ".concat(JSkeletonBg);
19
16
  var JSkeletonFlex = {
20
17
  display: 'flex',
21
18
  gap: '24px',
@@ -34,6 +31,10 @@ var genSkeletonStyle = function genSkeletonStyle(config) {
34
31
  var _$concat6;
35
32
  var componentCls = config.componentCls,
36
33
  token = config.token;
34
+ var JSkeletonBg = token.colorFillQuaternary;
35
+ var JSkeletonBg1 = token.colorFillSecondary;
36
+ var JSkeletonBorder = "".concat(token.lineWidth * 4, "px solid ").concat(JSkeletonBg);
37
+ var JSkeletonCardBorder = "".concat(token.lineWidth * 2, "px solid ").concat(token.colorBorderSecondary);
37
38
  return (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)({}, "".concat(componentCls, "-flex"), JSkeletonFlex), "".concat(componentCls, "-flex-between"), (0, _objectSpread2.default)((0, _objectSpread2.default)({}, JSkeletonFlex), {}, {
38
39
  background: JSkeletonBg,
39
40
  height: JSkeletonSize,
@@ -41,7 +42,12 @@ var genSkeletonStyle = function genSkeletonStyle(config) {
41
42
  })), "".concat(componentCls, "-flex-column"), (0, _objectSpread2.default)((0, _objectSpread2.default)({}, JSkeletonFlex), {}, {
42
43
  justifyContent: 'space-between'
43
44
  })), "".concat(componentCls), (_$concat6 = {
44
- height: '100%'
45
+ height: '100%',
46
+ '--j-skeleton-bg': JSkeletonBg,
47
+ '--j-skeleton-bg-active': JSkeletonBg1,
48
+ '--j-skeleton-border': JSkeletonBorder,
49
+ '--j-skeleton-card-border': JSkeletonCardBorder,
50
+ '--j-skeleton-table-header-bg': token.colorFillTertiary
45
51
  }, (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(_$concat6, "".concat(componentCls, "-item"), {
46
52
  background: "linear-gradient(90deg, ".concat(JSkeletonBg, " 25%, ").concat(JSkeletonBg1, " 50%, ").concat(JSkeletonBg, " 75%)"),
47
53
  backgroundSize: '400% 100%',
@@ -90,7 +96,7 @@ var genSkeletonStyle = function genSkeletonStyle(config) {
90
96
  padding: '12px 6px',
91
97
  borderRadius: '8px'
92
98
  }), "".concat(componentCls, "-table-header"), {
93
- backgroundColor: 'lightgrey'
99
+ backgroundColor: token.colorFillTertiary
94
100
  }), (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(_$concat6, "".concat(componentCls, "-table-action"), {
95
101
  width: '200px',
96
102
  display: 'grid',
@@ -103,7 +109,7 @@ var genSkeletonStyle = function genSkeletonStyle(config) {
103
109
  }), "".concat(componentCls, "-card"), (0, _defineProperty2.default)((0, _defineProperty2.default)({}, "".concat(componentCls, "-card-content"), (0, _defineProperty2.default)((0, _defineProperty2.default)({
104
110
  display: 'flex',
105
111
  gap: '16px',
106
- border: '2px solid #f0f2f5',
112
+ border: JSkeletonCardBorder,
107
113
  borderRadius: '8px',
108
114
  padding: '24px',
109
115
  marginBottom: '16px'
@@ -18,7 +18,7 @@ var genTitleStyle = function genTitleStyle(config) {
18
18
  }, "".concat(componentCls, "-content"), {
19
19
  position: 'relative',
20
20
  paddingLeft: '10px',
21
- color: 'rgba(0, 0, 0, 0.8)',
21
+ color: token.colorTextHeading,
22
22
  fontWeight: 600,
23
23
  lineHeight: 1,
24
24
  '&::before': {
@@ -27,7 +27,7 @@ var genTitleStyle = function genTitleStyle(config) {
27
27
  left: 0,
28
28
  width: 4,
29
29
  height: '100%',
30
- background: '#1890ff',
30
+ background: token.colorPrimary,
31
31
  borderRadius: '0 3px 3px 0',
32
32
  content: '""'
33
33
  }
@@ -5,8 +5,11 @@ Object.defineProperty(exports, "__esModule", {
5
5
  value: true
6
6
  });
7
7
  exports.default = void 0;
8
+ var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/objectSpread2"));
8
9
  var _styleRegister = _interopRequireDefault(require("../../style/styleRegister"));
9
- var genVirtualTableStyle = function genVirtualTableStyle() {
10
+ var _scrollbar = require("../../style/scrollbar");
11
+ var genVirtualTableStyle = function genVirtualTableStyle(config) {
12
+ var token = config.token;
10
13
  return {
11
14
  '.virtual-table-wrapper': {
12
15
  display: 'flex',
@@ -24,11 +27,11 @@ var genVirtualTableStyle = function genVirtualTableStyle() {
24
27
  }
25
28
  }
26
29
  },
27
- '.virtual-table-body': {
30
+ '.virtual-table-body': (0, _objectSpread2.default)({
28
31
  'overflow-y': 'auto',
29
32
  position: 'relative',
30
33
  'min-height': '100px'
31
- },
34
+ }, (0, _scrollbar.genTokenScrollbarStyle)(token)),
32
35
  '.virtual-table-header-fixed': {
33
36
  // 位移的容器,提升位移动画性能
34
37
  'will-change': 'transform'
@@ -0,0 +1,30 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.genTokenScrollbarStyle = void 0;
7
+ var genTokenScrollbarStyle = exports.genTokenScrollbarStyle = function genTokenScrollbarStyle(token) {
8
+ return {
9
+ scrollbarWidth: 'thin',
10
+ scrollbarColor: "".concat(token.colorFillSecondary, " ").concat(token.colorFillQuaternary),
11
+ '&::-webkit-scrollbar': {
12
+ width: 10,
13
+ height: 10
14
+ },
15
+ '&::-webkit-scrollbar-track': {
16
+ backgroundColor: token.colorFillQuaternary
17
+ },
18
+ '&::-webkit-scrollbar-thumb': {
19
+ backgroundColor: token.colorFillSecondary,
20
+ borderRadius: token.borderRadiusLG,
21
+ border: "".concat(token.lineWidth * 2, "px solid ").concat(token.colorFillQuaternary)
22
+ },
23
+ '&::-webkit-scrollbar-thumb:hover': {
24
+ backgroundColor: token.colorFill
25
+ },
26
+ '&::-webkit-scrollbar-corner': {
27
+ backgroundColor: token.colorFillQuaternary
28
+ }
29
+ };
30
+ };
@@ -7,18 +7,52 @@ Object.defineProperty(exports, "__esModule", {
7
7
  exports.default = void 0;
8
8
  var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray"));
9
9
  var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/objectSpread2"));
10
+ var _vue = require("vue");
11
+ var _antDesignVue = require("ant-design-vue");
10
12
  var _internal = require("ant-design-vue/es/theme/internal");
13
+ var _context = require("ant-design-vue/es/config-provider/context");
14
+ var _style = require("ant-design-vue/es/style");
11
15
  var _variable = _interopRequireDefault(require("./variable"));
12
16
  var genCompoentStyle = function genCompoentStyle(styleFn) {
13
- return (0, _internal.genComponentStyleHook)('jetlinks-components', function (_token, info) {
14
- var componentToken = {
15
- token: (0, _objectSpread2.default)((0, _objectSpread2.default)({}, _token), _variable.default),
16
- hashId: info.hashId,
17
- componentCls: ".".concat(_token.prefixCls)
18
- };
19
- return (0, _toConsumableArray2.default)(styleFn.map(function (item) {
20
- return item(componentToken);
21
- }));
22
- });
17
+ return function (_prefixCls) {
18
+ var prefixCls = (0, _vue.computed)(function () {
19
+ return (0, _vue.unref)(_prefixCls);
20
+ });
21
+ var _theme$useToken = _antDesignVue.theme.useToken(),
22
+ themeRef = _theme$useToken.theme,
23
+ token = _theme$useToken.token,
24
+ hashId = _theme$useToken.hashId;
25
+ var _useConfigContextInje = (0, _context.useConfigContextInject)(),
26
+ getPrefixCls = _useConfigContextInje.getPrefixCls,
27
+ iconPrefixCls = _useConfigContextInje.iconPrefixCls;
28
+ var rootPrefixCls = (0, _vue.computed)(function () {
29
+ return getPrefixCls();
30
+ });
31
+ var componentInfo = (0, _vue.computed)(function () {
32
+ return {
33
+ theme: themeRef.value,
34
+ token: token.value,
35
+ hashId: hashId.value,
36
+ path: ['jetlinks-components', prefixCls.value, rootPrefixCls.value, iconPrefixCls.value]
37
+ };
38
+ });
39
+ var wrapSSR = (0, _internal.useStyleRegister)(componentInfo, function () {
40
+ var componentCls = ".".concat(prefixCls.value);
41
+ var componentToken = {
42
+ token: (0, _objectSpread2.default)((0, _objectSpread2.default)((0, _objectSpread2.default)({}, token.value), _variable.default), {}, {
43
+ componentCls: componentCls,
44
+ prefixCls: prefixCls.value,
45
+ iconCls: ".".concat(iconPrefixCls.value),
46
+ antCls: ".".concat(rootPrefixCls.value)
47
+ }),
48
+ hashId: hashId.value,
49
+ componentCls: componentCls
50
+ };
51
+ return [(0, _style.genCommonStyle)(token.value, prefixCls.value)].concat((0, _toConsumableArray2.default)(styleFn.map(function (item) {
52
+ return item(componentToken);
53
+ })));
54
+ });
55
+ return [wrapSSR, hashId];
56
+ };
23
57
  };
24
58
  var _default = exports.default = genCompoentStyle;
@@ -4,7 +4,4 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
- var _default = exports.default = {
8
- textColorTitle: '#000',
9
- textColorSubtitle: '#263237'
10
- };
7
+ var _default = exports.default = {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jetlinks-web/components",
3
- "version": "3.3.11",
3
+ "version": "3.3.13",
4
4
  "description": "",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",