Make WordPress Core

Opened 9 days ago

Last modified 9 days ago

#61954 new defect (bug)

Twenty Twenty-One: Remove the use of empty rulesets

Reported by: viralsampat's profile viralsampat Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version:
Component: Bundled Theme Keywords: needs-testing dev-feedback has-patch has-testing-info 2nd-opinion
Focuses: Cc:

Description

Hello Team,

I have reviewed "Twenty Twenty-one" theme and found that lint error like "Do not use empty rulesets" into the SCSS file.

I think that it should be remove from the file.

Thanks,

Attachments (3)

61954.patch (579 bytes) - added by viralsampat 9 days ago.
I have checked above mentioned issue and founds few files. Here, I have added its patch.
theme-check-before.png (34.9 KB) - added by sabernhardt 9 days ago.
Theme Check results before applying patch
theme-check-with-patch.png (34.9 KB) - added by sabernhardt 9 days ago.
Theme Check results with the patch

Download all attachments as: .zip

Change History (6)

@viralsampat
9 days ago

I have checked above mentioned issue and founds few files. Here, I have added its patch.

#1 @narenin
9 days ago

Hi,

Test Report

Patch tested: https://core.trac.wordpress.org/attachment/ticket/61954/61954.patch

Environment:

OS: Windows
PHP: 8.2.12
WordPress: 6.6.1
Browser: Chrome
Theme: Twenty Twenty-One (Version: 2.3)
Plugins: None activated

Actual Results:

✅ Patch working well as desired solution.

Last edited 9 days ago by narenin (previous) (diff)

#2 @narenin
9 days ago

  • Keywords has-testing-info added

#3 @sabernhardt
9 days ago

  • Keywords 2nd-opinion added
  • Summary changed from Twenty Twenty-one Theme: Remove the use of empty rulesets to Twenty Twenty-One: Remove the use of empty rulesets

PR 64 purposely kept those lines and added a comment because the Theme Check plugin had required the .sticky class.

I ran the plugin tests before and after applying the patch. Both times, it only recommended—not required—the .sticky class.

RECOMMENDED .sticky css class is recommended in your theme css.

Compiling the patch SCSS does not affect the CSS files, but it does change the .map files.

Last edited 9 days ago by sabernhardt (previous) (diff)

@sabernhardt
9 days ago

Theme Check results before applying patch

@sabernhardt
9 days ago

Theme Check results with the patch

Note: See TracTickets for help on using tickets.