Problem/Motivation
This is part of the CSS modernization initiative. This is intended to be a straightforward second issue.
The first issue was regarding the container-inline stylesheet.
Steps to reproduce
The stylesheet at https://git.drupalcode.org/project/drupal/-/blob/10.0.x/core/themes/claro/css/components/container-inline.pcss.css needs to be refactored to make use of modern CSS and Drupal core's PostCSS tooling.
Proposed resolution
Use CSS Logical Properties where appropriate
Use CSS nesting where appropriate
Remaining tasks
We need two patches. One for Drupal 9.5.x and one for Drupal 10.0.x
We need a followup issue to refactor this component in Drupal 10.0.x to make use of component-level CSS custom properties.
User interface changes
None. There should be no visual differences.
| Comment | File | Size | Author |
|---|---|---|---|
| #28 | 3293998-28.patch | 1.21 KB | gauravvvv |
| #27 | 3293998-27.patch | 578.33 KB | stanzin |
| #23 | interdiff_21-23.txt | 622 bytes | Ratan Priya |
| #23 | 3293998-23.patch | 1.27 KB | Ratan Priya |
| #21 | 3293998-10.0.x.patch | 1.45 KB | aditya4478 |
Issue fork drupal-3293998
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
aditya4478 commentedComment #3
sasanikolic commentedLet's leave this out of the nesting for now.
For the Drupal 10 patch, we can then use CSS logical properties. See https://css-tricks.com/css-logical-properties/ for examples and comments in Styling for Right-To-Left Languages
Comment #4
aditya4478 commentedInstructions noted & changes done as per comment #3
No Blocks of IE are there. Ready for review
Comment #5
aditya4478 commentedI will post new patch to make test pass for version 10
Comment #6
aditya4478 commentedComment #7
sasanikolic commentedSomething's wrong here, we should not have & in the compiled css and nesting.
Comment #8
aditya4478 commentedignore this patch
Comment #9
aditya4478 commentedComment #10
aditya4478 commentedignore this
Comment #11
aditya4478 commentedComment #12
aditya4478 commentedConsider #9 & #11 Patches
Comment #13
sasanikolic commentedNit: let's use :: for pseudo-elements like before and after.
Comment #14
aditya4478 commentedIgnore this patch, I have made mistake in git commands while making this patch
Comment #15
aditya4478 commentedConsider this patch. #13 comment remembered & improved.
Comment #16
sasanikolic commentedThis is not correct. This nested selector should just be .form-type-radio.
Comment #17
aditya4478 commentedNoted
Comment #18
sasanikolic commentedWe also need the patch for Drupal 10 updated. :)
Comment #19
aditya4478 commentedComment #20
sasanikolic commentedThis should be margin-inline-start.
Once that is fixed, should be ready to go.
Comment #21
aditya4478 commentedComment #22
alexpottThe patch for 10.x needs to have "yarn run build:css" run again then the resulting patch uploaded. We needed to land #3312481: Update core's browserlist before this patch was really possible.
I don't think we should be changing 9.5.x - can't really see the value.
Why not change this to:
Then the indentation in the resulting css wouldn't be borked. I'm not sure I understand what's better with the & format.
Comment #23
Ratan Priya commented@alexpott,
Made changes as per comment #22.
Needs review.
Comment #24
ckrinaComment #25
ckrinaComment #26
smustgrave commentedBelieve this is postponed via our conversation a few weeks ago @ckrina. For the followup and a path forward
Comment #27
stanzin commentedI think this patch would work.
Comment #28
gauravvvv commentedPatch #23, does not apply anymore and patch #27 includes so many files which are out of scope. I have added patch for 11.x-dev. please review
Comment #29
aditya4478 commentedLGTM !
I will remind @stanzin about the patch out of scope. 👍
Comment #31
gauravvvv commentedRandom failure, restoring status
Comment #33
gauravvvv commentedComment #34
ahmad smhan commentedComment #37
lauriiiCommitted fa8db8e and pushed to 11.x. Thanks!