@oceanbase/design 0.4.16 → 1.0.0-alpha.1

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 (46) hide show
  1. package/dist/design.min.js +1 -1
  2. package/es/_util/genStyle.d.ts +0 -2
  3. package/es/_util/genStyle.js +0 -77
  4. package/es/badge/style/index.js +0 -1
  5. package/es/button/style/index.js +1 -30
  6. package/es/card/style/index.js +4 -2
  7. package/es/config-provider/index.js +1 -5
  8. package/es/empty/style/index.js +2 -7
  9. package/es/form/FormItem.d.ts +1 -0
  10. package/es/form/FormItem.js +1 -0
  11. package/es/index.d.ts +0 -1
  12. package/es/index.js +1 -2
  13. package/es/result/style/index.js +2 -5
  14. package/es/table/style/index.js +8 -31
  15. package/es/tabs/index.d.ts +8 -6
  16. package/es/tabs/index.js +10 -7
  17. package/es/tabs/style/index.js +2 -3
  18. package/es/theme/default.js +88 -72
  19. package/es/theme/style/aliyun.less +210 -210
  20. package/es/theme/style/compact.less +231 -231
  21. package/es/theme/style/dark.less +234 -234
  22. package/es/theme/style/default.less +231 -231
  23. package/es/typography/style/index.js +2 -6
  24. package/lib/_util/genStyle.d.ts +0 -2
  25. package/lib/_util/genStyle.js +2 -118
  26. package/lib/badge/style/index.js +0 -1
  27. package/lib/button/style/index.js +1 -37
  28. package/lib/card/style/index.js +9 -1
  29. package/lib/config-provider/index.js +1 -8
  30. package/lib/empty/style/index.js +0 -5
  31. package/lib/form/FormItem.d.ts +1 -0
  32. package/lib/form/FormItem.js +6 -0
  33. package/lib/index.d.ts +0 -1
  34. package/lib/index.js +0 -3
  35. package/lib/result/style/index.js +0 -4
  36. package/lib/table/style/index.js +1 -58
  37. package/lib/tabs/index.d.ts +8 -6
  38. package/lib/tabs/index.js +68 -62
  39. package/lib/tabs/style/index.js +6 -4
  40. package/lib/theme/default.js +86 -71
  41. package/lib/theme/style/aliyun.less +210 -210
  42. package/lib/theme/style/compact.less +231 -231
  43. package/lib/theme/style/dark.less +234 -234
  44. package/lib/theme/style/default.less +231 -231
  45. package/lib/typography/style/index.js +2 -9
  46. package/package.json +6 -6
@@ -24,134 +24,149 @@ __export(default_exports, {
24
24
  });
25
25
  module.exports = __toCommonJS(default_exports);
26
26
  var import_format = require("./util/format");
27
+ var colorPrimary = "#0D6CF2";
28
+ var colorPrimarySecondary = "#598CF3";
29
+ var colorText = "#132039";
30
+ var colorTextSecondary = "#5C6B8A";
31
+ var colorTextTertiary = "#8592AD";
32
+ var colorTextQuaternary = "#C1CBE0";
33
+ var colorFill = "#CDD5E4";
34
+ var colorFillSecondary = "#E2E8F3";
35
+ var colorFillTertiary = "#F3F6FC";
36
+ var colorFillQuaternary = "#F8FAFE";
37
+ var colorBorderSecondary = colorFillSecondary;
27
38
  var tagColorBorder = "#cdd5e466";
28
39
  var fontFamilyEn = `Inter, 'Noto sans', sans-serif, Roboto, 'Open Sans', 'Segoe UI', 'Helvetica Neue', 'Helvetica, Arial', 'Apple Color Emoji'`;
29
40
  var defaultTheme = {
30
41
  token: {
31
42
  fontFamily: `-apple-system, 'Noto Sans', BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji'`,
32
43
  fontFamilyCode: `Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace`,
33
- colorPrimaryBg: "#EAF1FF",
34
- colorPrimary: "#006AFF",
35
- colorPrimaryBgHover: "#EAF1FF",
36
- colorPrimaryBorder: "#b3ccff",
37
- colorPrimaryBorderHover: "#5189FB",
38
- colorPrimaryHover: "#5189fb",
39
- colorPrimaryActive: "#004CE6",
40
- colorPrimaryTextHover: "#5189FB",
41
- colorPrimaryText: "#006AFF",
42
- colorPrimaryTextActive: "#004CE6",
43
- colorSuccess: "#0ac185",
44
- colorSuccessBg: "#EEF8F5",
45
- colorSuccessBgHover: "#dbf0e9",
46
- colorSuccessBorder: "#B3E6D5",
47
- colorSuccessBorderHover: "#4DCCA2",
48
- colorSuccessHover: "#4DCCA2",
49
- colorSuccessActive: "#00B378",
50
- colorSuccessTextHover: "#4DCCA2",
51
- colorSuccessText: "#0AC185",
52
- colorSuccessTextActive: "#00B378",
53
- colorWarning: "#FFA21A",
54
- colorWarningBg: "#FFF5E5",
55
- colorWarningBgHover: "#ffe7c2",
56
- colorWarningBorder: "#FFD699",
57
- colorWarningBorderHover: "#FFC166",
58
- colorWarningHover: "#FFC166",
59
- colorWarningActive: "#FF9700",
60
- colorWarningTextHover: "#FFC166",
61
- colorWarningText: "#FFA21A",
62
- colorWarningTextActive: "#FF9700",
63
- colorErrorBg: "#ffebeb",
64
- colorErrorBgHover: "#ffd6d6",
65
- colorErrorBorder: "#FFB3B3",
66
- colorErrorBorderHover: "#ff7575",
67
- colorErrorHover: "#ff7575",
68
- colorErrorActive: "#CC0000",
69
- colorErrorTextHover: "#ff7575",
70
- colorErrorText: "#ff1a1a",
71
- colorErrorTextActive: "#CC0000",
72
- colorError: "#F93939",
73
- colorInfo: "#006AFF",
44
+ borderRadius: 4,
45
+ borderRadiusLG: 6,
46
+ borderRadiusSM: 2,
47
+ fontSize: 13,
48
+ fontSizeSM: 12,
49
+ colorPrimary,
50
+ colorInfo: colorPrimary,
51
+ colorInfoBorder: "#598CF3",
74
52
  colorInfoBg: "#EAF1FF",
75
- colorInfoBgHover: "#EAF1FF",
76
- colorInfoBorder: "#B3CCFF",
77
- colorInfoBorderHover: "#5189FB",
78
- colorInfoHover: "#5189FB",
79
- colorInfoActive: "#004CE6",
80
- colorInfoTextHover: "#5189FB",
81
- colorInfoText: "#006AFF",
82
- colorInfoTextActive: "#004CE6",
53
+ colorInfoText: "#083E8B",
54
+ colorSuccess: "#14B781",
55
+ colorSuccessBorder: "#7ED7BA",
56
+ colorSuccessBg: "#E8F8F3",
57
+ colorSuccessText: "#096547",
58
+ colorWarning: "#F49F25",
59
+ colorWarningBorder: "#F9CB87",
60
+ colorWarningBg: "#FEF6E9",
61
+ colorWarningText: "#5B3600",
62
+ colorError: "#EF4343",
63
+ colorErrorBorder: "#F69898",
64
+ colorErrorBg: "#FDECEC",
65
+ colorErrorText: "#8A1B1B",
83
66
  colorTextBase: "#000000",
84
- colorText: "#132039",
85
- colorTextSecondary: "#5c6b8a",
86
- colorTextQuaternary: "#c1cbe0",
87
- colorTextTertiary: "#8592AD",
67
+ colorText,
68
+ colorTextSecondary,
69
+ colorTextTertiary,
70
+ colorTextQuaternary,
71
+ colorIcon: colorTextSecondary,
88
72
  colorBgBase: "#ffffff",
89
73
  colorBgContainer: "#ffffff",
90
- colorBgLayout: "#f3f6fc",
91
- colorBorder: "#CDD5E4",
92
- colorBorderSecondary: "#E2E8F3",
93
- colorFillQuaternary: "#F8FAFE",
94
- colorFillTertiary: "#f3f6fc",
95
- colorFillSecondary: "#e2e8f3",
96
- colorFill: "#cdd5e4",
74
+ colorBgLayout: colorFillQuaternary,
75
+ colorBorder: colorFill,
76
+ colorBorderSecondary,
77
+ colorFill,
78
+ colorFillSecondary,
79
+ colorFillTertiary,
80
+ colorFillQuaternary,
97
81
  colorBgMask: "rgba(19, 32, 57, 0.45)",
98
82
  colorBgElevated: "#ffffff",
99
83
  colorBgSpotlight: "#ffffff",
100
84
  boxShadow: "0 6px 16px 0 rgba(54, 69, 99, 0.08), 0 3px 6px -4px rgba(54, 69, 99, 0.12), 0 9px 28px 8px rgba(54, 69, 99, 0.05)",
101
85
  boxShadowSecondary: "0 6px 16px 0 rgba(54, 69, 99, 0.08), 0 3px 6px -4px rgba(54, 69, 99, 0.12), 0 9px 28px 8px rgba(54, 69, 99, 0.05)",
102
86
  boxShadowTertiary: "0 1px 2px 0 rgba(54, 69, 99, 0.03), 0 1px 6px -1px rgba(54, 69, 99, 0.02), 0 2px 4px 0 rgba(54, 69, 99, 0.02)",
103
- borderRadius: 6,
104
87
  wireframe: false,
105
88
  // Remove focus outline
106
89
  lineWidthFocus: 0
107
90
  },
108
91
  components: {
92
+ Badge: {
93
+ colorInfo: colorPrimarySecondary
94
+ },
109
95
  Breadcrumb: {
110
96
  fontSize: 12,
111
97
  // @ts-ignore
112
98
  // fontHeight is internal token
113
99
  fontHeight: 20,
114
- lastItemColor: "#5c6b8a"
100
+ lastItemColor: colorTextSecondary
101
+ },
102
+ Card: {
103
+ headerFontSize: 16,
104
+ borderRadiusLG: 8
115
105
  },
116
106
  Collapse: {
117
- colorBorder: "#E2E8F3"
107
+ colorBorder: colorBorderSecondary
118
108
  },
119
109
  InputNumber: {
120
110
  handleVisible: true
121
111
  },
112
+ Progress: {
113
+ defaultColor: colorPrimarySecondary
114
+ },
122
115
  Radio: {
123
116
  // temporarily fix style for checked disabled Radio.Button
124
- controlItemBgActiveDisabled: "#e2e8f3"
117
+ controlItemBgActiveDisabled: colorFillSecondary
125
118
  },
126
119
  Select: {
127
120
  // work for all multiple select component, including Select, TreeSelect and Cascader and so on
128
- multipleItemBg: "#F8FAFE",
121
+ multipleItemBg: colorFillQuaternary,
129
122
  multipleItemBorderColor: tagColorBorder,
130
123
  multipleItemBorderColorDisabled: tagColorBorder
131
124
  },
132
125
  Slider: {
133
- trackBg: "#006AFF",
126
+ trackBg: colorPrimary,
134
127
  trackHoverBg: "#5189fb",
135
128
  trackBgDisabled: "#b3ccff",
136
- handleColor: "#006AFF",
129
+ handleColor: colorPrimary,
137
130
  handleActiveColor: "#5189fb",
138
131
  handleColorDisabled: "#b3ccff"
139
132
  },
140
133
  Tabs: {
141
- horizontalItemGutter: 24
134
+ horizontalItemGutter: 24,
135
+ itemActiveColor: colorText,
136
+ itemSelectedColor: colorText,
137
+ itemHoverColor: colorText
142
138
  },
143
139
  Tag: {
144
- defaultColor: "#5c6b8a",
140
+ defaultColor: colorTextSecondary,
145
141
  colorBorder: tagColorBorder
146
142
  },
147
143
  Table: {
144
+ cellFontSize: 12,
145
+ headerSplitColor: "transparent",
148
146
  cellPaddingBlock: 12,
147
+ cellPaddingInline: 16,
149
148
  cellPaddingBlockMD: 8,
150
- cellPaddingBlockSM: 4
149
+ cellPaddingBlockSM: 4,
150
+ rowHoverBg: colorFillQuaternary,
151
+ rowSelectedBg: colorFillQuaternary,
152
+ rowSelectedHoverBg: colorFillTertiary
151
153
  },
152
154
  Tooltip: {
153
155
  colorBgSpotlight: "#ffffff",
154
- colorTextLightSolid: "#132039"
156
+ colorTextLightSolid: colorText
157
+ },
158
+ Menu: {
159
+ paddingContentVertical: 0,
160
+ itemHeight: 30,
161
+ itemBorderRadius: 4,
162
+ // 80 means 50% opacity
163
+ itemHoverBg: colorFillSecondary + "80",
164
+ itemActiveBg: colorFillSecondary + "80",
165
+ itemSelectedBg: colorFillSecondary + "80",
166
+ itemColor: "#36496F",
167
+ itemSelectedColor: colorText,
168
+ itemMarginBlock: 6,
169
+ groupTitleFontSize: 11
155
170
  }
156
171
  }
157
172
  };