Skip to content

Commit

Permalink
feat: scroll to top when editing
Browse files Browse the repository at this point in the history
Signed-off-by: Evan Song <[email protected]>
  • Loading branch information
ferothefox committed Oct 18, 2024
1 parent 46ce5ff commit 8ac1fc6
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions apps/frontend/src/pages/servers/manage/[id]/files.vue
Original file line number Diff line number Diff line change
Expand Up @@ -773,6 +773,8 @@ const editFile = async (item: { name: string; type: string; path: string }) => {
const path = `${currentPath.value}/${item.name}`.replace("//", "/");
const content = (await props.server.fs?.downloadFile(path)) as string;
window.scrollTo(0, 0);
fileContent.value = content;
editingFile.value = item;
isEditing.value = true;
Expand Down

0 comments on commit 8ac1fc6

Please sign in to comment.