修正清楚数据按钮

This commit is contained in:
sijinhui 2024-02-16 17:47:28 +08:00
parent cf65082789
commit c7e346872e
2 changed files with 11 additions and 10 deletions

View File

@ -347,4 +347,5 @@
border-radius: 0;
padding: 0;
height: 20px;
margin-top: 15px;
}

View File

@ -230,6 +230,16 @@ export function SideBar(props: { className?: string }) {
<IconButton icon={<SettingsIcon />} shadow />
</Link>
</div>
<IconButton
text={Locale.Settings.Danger.Clear.Title}
onClick={async () => {
if (await showConfirm(Locale.Settings.Danger.Clear.Confirm)) {
chatStore.clearAllData();
}
}}
type="danger"
className={styles["custom-sidebar-clear-button"]}
/>
</div>
<div>
<IconButton
@ -247,16 +257,6 @@ export function SideBar(props: { className?: string }) {
/>
</div>
</div>
<IconButton
text={Locale.Settings.Danger.Clear.Title}
onClick={async () => {
if (await showConfirm(Locale.Settings.Danger.Clear.Confirm)) {
chatStore.clearAllData();
}
}}
type="danger"
className={styles["custom-sidebar-clear-button"]}
/>
<div
className={styles["sidebar-drag"]}