mirror of
https://github.com/open-webui/open-webui.git
synced 2026-09-12 23:02:35 +00:00
fix: stop the browser back button creating extra notes (#29645)
This commit is contained in:
parent
bd0b3875ba
commit
b49db6f287
3 changed files with 3 additions and 3 deletions
|
|
@ -534,7 +534,7 @@
|
|||
{
|
||||
label: $i18n.t('Create a new note'),
|
||||
onClick: async () => {
|
||||
await goto(`/notes?content=${query}`);
|
||||
await goto(`/notes/new?content=${encodeURIComponent(query)}`);
|
||||
show = false;
|
||||
onClose();
|
||||
},
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@
|
|||
const res = await createNoteHandler(title, content);
|
||||
|
||||
if (res) {
|
||||
goto(`/notes/${res.id}`);
|
||||
goto(`/notes/${res.id}`, { replaceState: true });
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@
|
|||
const res = await createNoteHandler(title, content);
|
||||
|
||||
if (res) {
|
||||
goto(`/notes/${res.id}`);
|
||||
goto(`/notes/${res.id}`, { replaceState: true });
|
||||
}
|
||||
});
|
||||
</script>
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue