Skip to content
This repository has been archived by the owner on Oct 16, 2024. It is now read-only.

Fix pattern preview heights when on a row by themselves #176

Merged
merged 3 commits into from
May 22, 2023

Conversation

johnstonphilip
Copy link
Contributor

@johnstonphilip johnstonphilip commented May 17, 2023

Tasks

Summary of changes

When a pattern preview is by itself, it takes up 100% of the height available. This PR makes it so that it shrinks down to 300px, while still allowing a longer pattern to show its full height.

Before:

Screenshot 2023-05-17 at 2 47 19 PM

After:

Screenshot 2023-05-17 at 3 05 02 PM

Note: this also affects how short patterns show beside long patterns:

Before:

Screenshot 2023-05-17 at 2 47 51 PM

After:

Screenshot 2023-05-17 at 2 50 57 PM

I spoke with Kam about this and confirmed that while a masonry layout might be preferable, we can iterate to that later if needed.

How to test

  1. On main, using the Frost theme, preview your patterns.
  2. Click on the "Portfolio" category, where there's only 1 pattern
  3. Notice the height of the preview fill all of the available space
  4. Change this this branch
  5. Refresh and notice the height maxes-out at 300px high, like other previews.
  6. Go back to view all patterns, and notice that patterns higher than 300px still show their full height, but shorter pattern beside max-out at 300px, leaving some empty space beneath them.

Copy link
Contributor

@dreamwhisper dreamwhisper left a comment

Choose a reason for hiding this comment

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

LGTM! We may still want to go the route of masonry, but this is fine in the interim.

Just minor spacing nitpicks.

johnstonphilip and others added 2 commits May 22, 2023 10:24
Co-authored-by: Jen Baumann <1271053+dreamwhisper@users.noreply.github.com>
Co-authored-by: Jen Baumann <1271053+dreamwhisper@users.noreply.github.com>
@johnstonphilip johnstonphilip merged commit 03f5ce6 into main May 22, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants