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 issues #3694

Closed
wants to merge 14 commits into from
Closed

Conversation

5e-Cleric
Copy link
Member

@5e-Cleric 5e-Cleric commented Aug 30, 2024

Changes flow of brewRenderer and splitpane, adds classes to splitpanes, left pane is named editorPane, and right pane is named previewPane. Grid is used in the pane to establish a defined height for brewRenderer and toolbar.

This way, the toolbar can be positioned statically, and the scrollbar does not hide behind it.

Also changed some margins and paddings to make spaces match at the beggining and end of a brew preview.

To anyone reviewing, this PR doesn't make any prominent visual change, other than the scrollbar not going behind the element.

@5e-Cleric 5e-Cleric added cleanup Cleaning up code for legibility, style, ease-of-use, etc. UI/UX User Interface, user experience labels Aug 30, 2024
@5e-Cleric 5e-Cleric self-assigned this Aug 30, 2024
Copy link
Collaborator

@Gazook89 Gazook89 left a comment

Choose a reason for hiding this comment

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

I did this review before cloning the branch to my local machine, so maybe some of the questions are bad, but they are the first things I would check anyway.

Before I left on my trip I was thinking that we were having issues with the toolbar disappearing behind the navbar because of extra re-renders between the toolbar and Brew Renderer components. This PR seems to "take care of it", but doesn't really solve that problem (if it is indeed a problem). And I don't mean to minimize the improvements in this PR-- the absolute positioning is a problem that also needed to be fixed.

I'll check it out tomorrow and see if i can poke it harder

client/homebrew/brewRenderer/brewRenderer.less Outdated Show resolved Hide resolved
client/homebrew/brewRenderer/brewRenderer.jsx Show resolved Hide resolved
@@ -3,16 +3,19 @@
.brewRenderer {
overflow-y : scroll;
will-change : transform;
padding-top : 30px;
padding-block : 30px;
Copy link
Collaborator

Choose a reason for hiding this comment

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

I haven't opened this up locally yet, so maybe this is a stupid question, but if the toolbar is no longer absolutely positioned and overlapping the brewRenderer, we don't need 30px of padding on top at all, right? We only had that extra padding because we wanted to be sure nothing was hidden under the toolbar.

Copy link
Member Author

Choose a reason for hiding this comment

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

Because of changes in flow, this padding is all the vertical space between the brew and the top of its parent, whenever you can check out the PR, you will see this space is there for a reason, I changed it for the weird combination of margins in pages and paddings from outside that caused that chaos.

@5e-Cleric
Copy link
Member Author

Yes, I don't know for sure what causes the extra renderings, but I can take a look, and I should fix this, if I shall find it.

@5e-Cleric 5e-Cleric added the 🔍 R3 - Reviewed - Awaiting Fixes 🔧 PR is okayed but needs fixes before merging label Sep 6, 2024
@5e-Cleric 5e-Cleric added the blocked Waiting on a dependency, other feature, etc., first label Sep 6, 2024
@5e-Cleric
Copy link
Member Author

Cleaned rendering of brewRenderer, cleaned unused CSS from toolbar, blocked on #3682 because page count depends right now on a faulty calculation function.

@5e-Cleric 5e-Cleric added 🔍 R4 - Reviewed - Fixed! Awaiting final review⭐ PR review comments addressed and removed 🔍 R3 - Reviewed - Awaiting Fixes 🔧 PR is okayed but needs fixes before merging labels Sep 6, 2024
@5e-Cleric 5e-Cleric linked an issue Sep 6, 2024 that may be closed by this pull request
@Gazook89
Copy link
Collaborator

Gazook89 commented Sep 6, 2024

I pulled this onto my local branch and the changes seem fine. I don't really think it is 'blocked' by 3682-- the changes here really don't have anything to do with that, unless I'm misunderstanding something. This is mostly just some light CSS and structure changes, and that one is changing how pages are calculated.

@5e-Cleric 5e-Cleric removed the blocked Waiting on a dependency, other feature, etc., first label Sep 7, 2024
@5e-Cleric
Copy link
Member Author

5e-Cleric commented Sep 7, 2024

This PR is causing a bug on deployment and local for me, but not for @Gazook89, this small bug requires a bit of testing, to see if it is only on my machine.

Check the page number

Grabacion.2024-09-06.223843.mp4

Other than that this PR is absolutely ready

@@ -139,7 +139,7 @@ const SplitPane = createClass({

render : function(){
return <div className='splitPane' onPointerMove={this.handleMove} onPointerUp={this.handleUp}>
<Pane
<Pane className="editorPane"
Copy link
Member

@calculuschild calculuschild Sep 9, 2024

Choose a reason for hiding this comment

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

Should these be named more generic leftPane and rightPane, since they are now being used for /vault, not just editors?

Copy link
Member Author

Choose a reason for hiding this comment

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

probably

Copy link
Member

@calculuschild calculuschild left a comment

Choose a reason for hiding this comment

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

I like the cleanup here. Thanks!

This PR is causing a bug on deployment and local for me, but not for @Gazook89, this small bug requires a bit of testing, to see if it is only on my machine.

I see this on my end too. Will that be resolved by #3682 or do you need to dig in more deeply here?

@5e-Cleric
Copy link
Member Author

I like the cleanup here. Thanks!

This PR is causing a bug on deployment and local for me, but not for @Gazook89, this small bug requires a bit of testing, to see if it is only on my machine.

I see this on my end too. Will that be resolved by #3682 or do you need to dig in more deeply here?

I can't be sure without testing. It makes sense that the error derives from where we calculate the current page, but i need to test that as fix.

@5e-Cleric 5e-Cleric temporarily deployed to homebrewery-pr-3694 September 16, 2024 06:53 Inactive
@5e-Cleric
Copy link
Member Author

5e-Cleric commented Sep 16, 2024

with #3705 merged, this PR is obsolete, closing

@5e-Cleric 5e-Cleric closed this Sep 16, 2024
@calculuschild
Copy link
Member

Are these fixes still useful for when the toolbar is currently visisble?

@5e-Cleric
Copy link
Member Author

Are these fixes still useful for when the toolbar is currently visisble?

Not really.

@5e-Cleric 5e-Cleric deleted the fix-toolbar-issues branch October 22, 2024 19:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cleanup Cleaning up code for legibility, style, ease-of-use, etc. 🔍 R3 - Reviewed - Awaiting Fixes 🔧 PR is okayed but needs fixes before merging UI/UX User Interface, user experience
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

brewrenderer cleanup
3 participants