-
Notifications
You must be signed in to change notification settings - Fork 167
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
Feat: Implement grid with 4 columns on medium #5352
Conversation
looks great to me. questions around naming:
|
Implementation for sharing the There are a couple of placeholder/variable naming choices that were temporary that I'll revisit, and I'll make a general pass for completion as well. |
0fec522
to
34ca250
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Couple naming suggestions in inline comments. But the overall approach is solid I think, thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A couple high-level comments:
- If it weren't for the code sample for the new 4-column variant, I would find the documentation/guidance on grids now quite confusing. I'm wondering if there's some way to more clearly indicate that there are essentially 2 top-level grids now, and that the 4-column variant is newer and recommended? It almost makes me think we should consider adding a deprecation notice to the old grid...
- There's only one example using the new 4-column variant - it might be nice to include some more examples in the docs themselves.
3b1cb00
to
8d35691
Compare
I have updated the structure table to show the difference in the two different grid classes, maybe this helps some: In terms of stating that the 4-column variant is newer and recommended, I will end up using your "New" label from #5353 for sure. Also, we won't really be "deprecating" Maybe we could add some language there along the lines of "4 columns on medium will become the default behavior of
Not sure if I understand you fully here - I have made 6 examples that use the 4-column variant. See the PR description. Do you mean that we should embed more of them in the docs page? |
As discussed in standup, let's document it as a new default. This means:
(I'm not sure if we need to do it all in one PR, but I guess would be good to make them part of the same release) |
4278834
to
d62221f
Compare
@bartaz I've updated the PR as requested, have a look and let me know what you think. |
Now that we made the new But I can't see a very good alternative:
|
<td rowspan="2">1.5rem</td> | ||
</tr> | ||
<tr> | ||
<td>4 (using <code>.row--4-cols-medium</code> - see <a href="#4-column-grid-on-medium-screens">docs</a>).</td> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If that's the new default we should list it first. And maybe add deprecated
red status label to the cell listing .row
This afternoon I did some exploration of updating the common grid patterns to use 4 cols on medium, as discussed in review today. Attempting to change the behavior of the common grid patterns (grid shorthands) to use 4 columns on medium is proving to be much more difficult than I thought it would be. Updating the base case (no nested grid) is trivial, but handling grid nesting inside these shorthands is difficult to do as a shorthand needs to be able to handle the existing Essentially this creates a case where I suspect it may be easier (if messier) to introduce separate I have updated this PR to change the class of the 4 col grid to |
I'm getting to the point where I feel we should not do it in current codebase. If this issue would be to go through out new triaging process it would not land in v4 due to high effort and compatibility issues. Having these 2 grids working side by side would be extremely confusing and problematic for devs. I see 2 options:
There is another possible approach: not create new class names for 4 col grid, but allow setting it on higher level:
|
Ditto @bartaz. All plausible solutions we've considered create both confusing code and naming, which really reduce the overall value of this feature. If it's an absolute necessity for v4, concur with @bartaz, the existing grid should be modified to become 4-column and all uses of it should be fixed. If it's not an absolute necessity, I think it makes a lot more sense to thorough spec out the new grid for v5, ensure it hits all needed requirements, and build it at that time. |
To summarise recent decisions made:
|
Closing as not needed - the new grid will be built from scratch, using the decisions summarized here. Targeting two days for implementation. |
Done
Implements the 4-column grid on medium, with
.row--4-cols
..row--4-cols
is a grid row that shares most of the behavior of.row
, but has 4 columns on medium screens, instead of 6.Fixes WD-14972
QA
Check if PR is ready for release
If this PR contains Vanilla SCSS code changes, it should contain the following changes to make sure it's ready for the release:
Feature 🎁
,Breaking Change 💣
,Bug 🐛
,Documentation 📝
,Maintenance 🔨
.package.json
should be updated relative to the most recent release, following semver convention:Screenshots