feat: 前台页头加明暗切换,刷新图标换成闪电
- settings.site.actions 新增 theme(默认开),后台「操作工具」可关 - 前台页头:月亮/太阳按钮,点击写回 site.theme,前后台同步; 未登录时不显示(设置接口需要会话) - 刷新图标 refresh_3_line -> lightning_line,刷新期间仍旋转
This commit is contained in:
@@ -1935,6 +1935,16 @@ function HeaderPanel({
|
||||
<Text size="sm" strong>
|
||||
操作工具
|
||||
</Text>
|
||||
<div className="sidebar-toggle-row">
|
||||
<Text>明暗切换</Text>
|
||||
<Switch
|
||||
checked={site.actions.theme}
|
||||
onChange={(next) =>
|
||||
onChangeSite({ ...site, actions: { ...site.actions, theme: next } })
|
||||
}
|
||||
label="页头显示明暗切换按钮"
|
||||
/>
|
||||
</div>
|
||||
<div className="sidebar-toggle-row">
|
||||
<Text>刷新</Text>
|
||||
<Switch
|
||||
|
||||
Reference in New Issue
Block a user