Skip to content

Commit

Permalink
chore(Editor): adjust position of toolbar in Editor.tsx
Browse files Browse the repository at this point in the history
  • Loading branch information
beberiche committed Aug 20, 2024
1 parent cd6cc30 commit 97727e7
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions frontend/src/components/editor/Editor.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -73,12 +73,13 @@ function Editor() {
checkAndAddFormat("`", FormatType.CODE);
checkAndAddFormat("~~", FormatType.STRIKETHROUGH);

// TODO: If the size of FormatBar changes, adjust the position accordingly.
setToolBarState((prev) => ({
...prev,
show: true,
position: {
top: coords.top - 8,
left: coords.left + 30,
top: coords.top - 5,
left: coords.left,
},
selectedFormats: formats,
}));
Expand Down

0 comments on commit 97727e7

Please sign in to comment.