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

Remove Legacy Admin Layout #2127

Merged
merged 7 commits into from
Aug 9, 2017
Merged

Conversation

graygilmore
Copy link
Contributor

@graygilmore graygilmore commented Jul 31, 2017

This removes the legacy admin layout and gives us half-decent responsiveness due to the nature of using Bootstrap classes. Previously, using .container our content would sit at a maximum width of 960px and shrink down to awkward sizes depending on the browser size.

This PR also finally removes the Skeleton Grid CSS from the admin. If stores are still relying on it in order to make overrides to their stores they can pull that CSS directly into their app.

Oooo, fancy!

responsive

Before at awkward breakpoint

screen shot 2017-07-31 at 3 37 10 pm

After

screen shot 2017-07-31 at 3 37 24 pm

We want to remove the legacy layout of the admin and this is one of the
few remaining pieces that relied on a specficically named element being
available.
This is a simplification of this admin interface in order to prepare to
switch the admin to a responsive layout.

This optimization had a weird side effect in that it fully replaced the
content on the page instead of loading the form in, say, a modal. This
would mean that hitting "Cancel" on the form would actually trigger a
page load instead of just removing the form from the page.
@graygilmore
Copy link
Contributor Author

Looks like the order page is borked. Will fix.

@graygilmore
Copy link
Contributor Author

Fixed the order page. The bug was from a few releases ago but it went unnoticed because none of the pages using the new layout also had a sidebar.

This commit removes the conditional in the admin layout to fallback to
the legacy layout. By moving all pages to the new layout we get
(relative) responsiveness for free.

Since we've transitioned all of the `col-X` classes to use Bootstrap we
should no longer have any fixed-width grid elements.
In a previous commit the `make-row()` mixin was removed from `.content`
causing the sidebar to not have enough room on the right side of the
screen. Now that we're moving to the new layout full-time we can just
add the necessary Bootstrap classes directly to the markup.

Special note: we're explicitly not using the `.container` class because
we don't want to use Bootstrap's built-in breakpoints.
If stores are still using these classnames they can import this file
directly into their project but we made the move to Bootstrap over a
year ago and it's time to remove the confusion of having two grid
systems.
Copy link
Contributor

@cbrunsdon cbrunsdon left a comment

Choose a reason for hiding this comment

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

LGTM, I haven't clicked through all the pages but if anything comes up we'll still have a fair chunk of time to fix it before next release

Fix the vertical position of the content sidebar for layouts having tabs and having none.
Copy link
Member

@tvdeyen tvdeyen left a comment

Choose a reason for hiding this comment

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

Thanks! Was about time

I added a fix for the vertical position of the sidebar. Sent you a PR @graygilmore

@tvdeyen tvdeyen added changelog:solidus_backend Changes to the solidus_backend gem UI labels Aug 1, 2017
@mtomov
Copy link
Contributor

mtomov commented Aug 2, 2017

That's great! Thank you!

Happy to see @admin_layout go.

Copy link
Member

@kennyadsl kennyadsl left a comment

Choose a reason for hiding this comment

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

Great stuff!

@tvdeyen tvdeyen merged commit 584f26f into solidusio:master Aug 9, 2017
@graygilmore graygilmore deleted the responsive-admin branch August 9, 2017 18:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog:solidus_backend Changes to the solidus_backend gem
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants