@hsu-react/ui 2.2.2 → 2.2.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.
@@ -66,8 +66,11 @@
66
66
  }
67
67
  }
68
68
 
69
+ // 悬浮态用 --vita-hover,不要用 --vita-border-weak:后者是**边框**色,
70
+ // 消费方换配色时会连着边框一起调,没法单独把悬浮底改暖/改冷。默认值也不合适
71
+ // ——它比 --vita-hover 更实,压在自定义底色上会显出一块异色方块。
69
72
  &:hover {
70
- background: var(--vita-border-weak);
73
+ background: var(--vita-hover);
71
74
  }
72
75
 
73
76
  &:global(.ant-tabs-tab-active) {
@@ -117,7 +117,12 @@ export var toAntdTheme = function toAntdTheme(options) {
117
117
  colorBgContainer: t.surface,
118
118
  colorBgElevated: t.surface,
119
119
  colorBgLayout: t.background,
120
- colorBgSpotlight: t.muted,
120
+ // `colorBgSpotlight` 故意不接管。它只服务 Tooltip,而 antd 把 Tooltip 的文字色写死成
121
+ // `colorTextLightSolid`(白),底色必须是深色才读得出来——把它指到 `muted` 这种浅色
122
+ // 中性面,亮色下就成了白字打在近白底上,整条提示语看不见。
123
+ // antd 两套算法给的默认值本来就是深的(亮色 rgba(0,0,0,.85)、暗色抬亮的深灰),
124
+ // 交回给它。
125
+
121
126
  // antd paints table headers / filled controls from the Fill ramp; pointing the top of it at
122
127
  // `muted` is what keeps those surfaces on the zinc scale instead of antd's default greys.
123
128
  colorFillAlter: t.muted,
@@ -66,8 +66,11 @@
66
66
  }
67
67
  }
68
68
 
69
+ // 悬浮态用 --vita-hover,不要用 --vita-border-weak:后者是**边框**色,
70
+ // 消费方换配色时会连着边框一起调,没法单独把悬浮底改暖/改冷。默认值也不合适
71
+ // ——它比 --vita-hover 更实,压在自定义底色上会显出一块异色方块。
69
72
  &:hover {
70
- background: var(--vita-border-weak);
73
+ background: var(--vita-hover);
71
74
  }
72
75
 
73
76
  &:global(.ant-tabs-tab-active) {
@@ -102,7 +102,12 @@ const toAntdTheme = options => {
102
102
  colorBgContainer: t.surface,
103
103
  colorBgElevated: t.surface,
104
104
  colorBgLayout: t.background,
105
- colorBgSpotlight: t.muted,
105
+ // `colorBgSpotlight` 故意不接管。它只服务 Tooltip,而 antd 把 Tooltip 的文字色写死成
106
+ // `colorTextLightSolid`(白),底色必须是深色才读得出来——把它指到 `muted` 这种浅色
107
+ // 中性面,亮色下就成了白字打在近白底上,整条提示语看不见。
108
+ // antd 两套算法给的默认值本来就是深的(亮色 rgba(0,0,0,.85)、暗色抬亮的深灰),
109
+ // 交回给它。
110
+
106
111
  // antd paints table headers / filled controls from the Fill ramp; pointing the top of it at
107
112
  // `muted` is what keeps those surfaces on the zinc scale instead of antd's default greys.
108
113
  colorFillAlter: t.muted,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hsu-react/ui",
3
- "version": "2.2.2",
3
+ "version": "2.2.3",
4
4
  "description": "一套基于 React + Ant Design 的中后台业务组件库",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -66,8 +66,11 @@
66
66
  }
67
67
  }
68
68
 
69
+ // 悬浮态用 --vita-hover,不要用 --vita-border-weak:后者是**边框**色,
70
+ // 消费方换配色时会连着边框一起调,没法单独把悬浮底改暖/改冷。默认值也不合适
71
+ // ——它比 --vita-hover 更实,压在自定义底色上会显出一块异色方块。
69
72
  &:hover {
70
- background: var(--vita-border-weak);
73
+ background: var(--vita-hover);
71
74
  }
72
75
 
73
76
  &:global(.ant-tabs-tab-active) {
@@ -149,7 +149,12 @@ export const toAntdTheme = (options?: {
149
149
  colorBgContainer: t.surface,
150
150
  colorBgElevated: t.surface,
151
151
  colorBgLayout: t.background,
152
- colorBgSpotlight: t.muted,
152
+
153
+ // `colorBgSpotlight` 故意不接管。它只服务 Tooltip,而 antd 把 Tooltip 的文字色写死成
154
+ // `colorTextLightSolid`(白),底色必须是深色才读得出来——把它指到 `muted` 这种浅色
155
+ // 中性面,亮色下就成了白字打在近白底上,整条提示语看不见。
156
+ // antd 两套算法给的默认值本来就是深的(亮色 rgba(0,0,0,.85)、暗色抬亮的深灰),
157
+ // 交回给它。
153
158
 
154
159
  // antd paints table headers / filled controls from the Fill ramp; pointing the top of it at
155
160
  // `muted` is what keeps those surfaces on the zinc scale instead of antd's default greys.