@hsu-react/ui 2.2.0 → 2.2.2
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/es/layout/Header/index.js +1 -4
- package/es/layout/Header/index.module.scss +6 -0
- package/es/layout/NavTabBar/index.module.scss +6 -2
- package/lib/layout/Header/index.js +1 -4
- package/lib/layout/Header/index.module.scss +6 -0
- package/lib/layout/NavTabBar/index.module.scss +6 -2
- package/package.json +1 -1
- package/src/layout/Header/index.module.scss +6 -0
- package/src/layout/Header/index.tsx +3 -1
- package/src/layout/NavTabBar/index.md +2 -0
- package/src/layout/NavTabBar/index.module.scss +6 -2
|
@@ -153,10 +153,7 @@ var Header = observer(function (props) {
|
|
|
153
153
|
children: /*#__PURE__*/_jsxs(Space, {
|
|
154
154
|
className: styles.user,
|
|
155
155
|
children: [/*#__PURE__*/_jsx(Avatar, {
|
|
156
|
-
|
|
157
|
-
backgroundColor: "#1677ff",
|
|
158
|
-
verticalAlign: "middle"
|
|
159
|
-
},
|
|
156
|
+
className: styles.avatar,
|
|
160
157
|
icon: nickname ? undefined : /*#__PURE__*/_jsx(UserOutlined, {}),
|
|
161
158
|
children: nickname === null || nickname === void 0 || (_nickname$ = nickname[0]) === null || _nickname$ === void 0 ? void 0 : _nickname$.toUpperCase()
|
|
162
159
|
}), nickname]
|
|
@@ -35,7 +35,10 @@
|
|
|
35
35
|
margin: 0px;
|
|
36
36
|
|
|
37
37
|
border: none;
|
|
38
|
-
|
|
38
|
+
// 只圆上面两角:页签是「贴在内容区上沿」的,下沿要与内容区接平,
|
|
39
|
+
// 四角全圆会让它看起来像一颗浮在栏里的胶囊、和下方内容脱开。
|
|
40
|
+
// 与拖拽时的浮层(.dragOverlay)保持同一形状。
|
|
41
|
+
border-radius: 8px 8px 0 0;
|
|
39
42
|
background: transparent;
|
|
40
43
|
|
|
41
44
|
transition: background 0.2s;
|
|
@@ -166,7 +169,8 @@
|
|
|
166
169
|
padding: 6px 16px;
|
|
167
170
|
|
|
168
171
|
background: var(--vita-surface);
|
|
169
|
-
|
|
172
|
+
// 与页签同一形状(上圆下方、同一半径),拖起来才像是把那颗页签拎了起来
|
|
173
|
+
border-radius: 8px 8px 0 0;
|
|
170
174
|
border: 1px solid var(--vita-border);
|
|
171
175
|
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
|
|
172
176
|
|
|
@@ -158,10 +158,7 @@ const Header = (0, _mobxReactLite.observer)(props => {
|
|
|
158
158
|
children: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_antd.Space, {
|
|
159
159
|
className: _indexModule.default.user,
|
|
160
160
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_antd.Avatar, {
|
|
161
|
-
|
|
162
|
-
backgroundColor: "#1677ff",
|
|
163
|
-
verticalAlign: "middle"
|
|
164
|
-
},
|
|
161
|
+
className: _indexModule.default.avatar,
|
|
165
162
|
icon: nickname ? undefined : /*#__PURE__*/(0, _jsxRuntime.jsx)(_icons.UserOutlined, {}),
|
|
166
163
|
children: nickname?.[0]?.toUpperCase()
|
|
167
164
|
}), nickname]
|
|
@@ -35,7 +35,10 @@
|
|
|
35
35
|
margin: 0px;
|
|
36
36
|
|
|
37
37
|
border: none;
|
|
38
|
-
|
|
38
|
+
// 只圆上面两角:页签是「贴在内容区上沿」的,下沿要与内容区接平,
|
|
39
|
+
// 四角全圆会让它看起来像一颗浮在栏里的胶囊、和下方内容脱开。
|
|
40
|
+
// 与拖拽时的浮层(.dragOverlay)保持同一形状。
|
|
41
|
+
border-radius: 8px 8px 0 0;
|
|
39
42
|
background: transparent;
|
|
40
43
|
|
|
41
44
|
transition: background 0.2s;
|
|
@@ -166,7 +169,8 @@
|
|
|
166
169
|
padding: 6px 16px;
|
|
167
170
|
|
|
168
171
|
background: var(--vita-surface);
|
|
169
|
-
|
|
172
|
+
// 与页签同一形状(上圆下方、同一半径),拖起来才像是把那颗页签拎了起来
|
|
173
|
+
border-radius: 8px 8px 0 0;
|
|
170
174
|
border: 1px solid var(--vita-border);
|
|
171
175
|
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
|
|
172
176
|
|
package/package.json
CHANGED
|
@@ -192,8 +192,10 @@ const Header: React.FC<HeaderProps> = observer((props) => {
|
|
|
192
192
|
}
|
|
193
193
|
>
|
|
194
194
|
<Space className={styles.user}>
|
|
195
|
+
{/* 底色跟随主色。从前这里写死 antd 蓝 #1677ff,而且是**行内样式**——
|
|
196
|
+
换过品牌色的项目连用 CSS 都盖不住,一颗蓝点钉在整套配色里 */}
|
|
195
197
|
<Avatar
|
|
196
|
-
|
|
198
|
+
className={styles.avatar}
|
|
197
199
|
icon={nickname ? undefined : <UserOutlined />}
|
|
198
200
|
>
|
|
199
201
|
{nickname?.[0]?.toUpperCase()}
|
|
@@ -35,7 +35,10 @@
|
|
|
35
35
|
margin: 0px;
|
|
36
36
|
|
|
37
37
|
border: none;
|
|
38
|
-
|
|
38
|
+
// 只圆上面两角:页签是「贴在内容区上沿」的,下沿要与内容区接平,
|
|
39
|
+
// 四角全圆会让它看起来像一颗浮在栏里的胶囊、和下方内容脱开。
|
|
40
|
+
// 与拖拽时的浮层(.dragOverlay)保持同一形状。
|
|
41
|
+
border-radius: 8px 8px 0 0;
|
|
39
42
|
background: transparent;
|
|
40
43
|
|
|
41
44
|
transition: background 0.2s;
|
|
@@ -166,7 +169,8 @@
|
|
|
166
169
|
padding: 6px 16px;
|
|
167
170
|
|
|
168
171
|
background: var(--vita-surface);
|
|
169
|
-
|
|
172
|
+
// 与页签同一形状(上圆下方、同一半径),拖起来才像是把那颗页签拎了起来
|
|
173
|
+
border-radius: 8px 8px 0 0;
|
|
170
174
|
border: 1px solid var(--vita-border);
|
|
171
175
|
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
|
|
172
176
|
|