Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: toolbar position at most top #214

Merged
merged 2 commits into from
Jun 20, 2023

Conversation

zoli
Copy link
Contributor

@zoli zoli commented Jun 19, 2023

At most top toolbar position goes out of the screen. Added a condition to check and position it on the bottom of the line.

appflowy-editor-toolbar-before-2023-06-20_00.16.11.mp4
appflowy-editor-toolbar-2023-06-20_00.17.40.mp4

@@ -149,7 +149,9 @@ class _FloatingToolbarState extends State<FloatingToolbar>
}

final rect = _findSuitableRect(rects);
print(rect);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please remove the print function

final (top, left, right) = calculateToolbarOffset(rect);
print((top, left, right));
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same here

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for fixing them.

@codecov
Copy link

codecov bot commented Jun 20, 2023

Codecov Report

Merging #214 (44806f0) into main (b298ceb) will increase coverage by 0.02%.
The diff coverage is 80.00%.

@@            Coverage Diff             @@
##             main     #214      +/-   ##
==========================================
+ Coverage   63.25%   63.28%   +0.02%     
==========================================
  Files         228      228              
  Lines       10137    10139       +2     
==========================================
+ Hits         6412     6416       +4     
+ Misses       3725     3723       -2     
Impacted Files Coverage Δ
...b/src/editor/toolbar/desktop/floating_toolbar.dart 77.55% <80.00%> (+2.55%) ⬆️

@LucasXu0 LucasXu0 merged commit 86f2d24 into AppFlowy-IO:main Jun 20, 2023
@zoli zoli deleted the fix/toolbar-position branch July 16, 2023 15:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants