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

Fix declaration-block-no-redundant-longhand-properties autofix for grid-template with repeat() #7230

Merged
merged 2 commits into from Oct 16, 2023

Conversation

mattxwang
Copy link
Member

Which issue, if any, is this issue related to?

Closes #7228.

Is there anything in the PR that needs further explanation?

Added the test case from the issue + the swapped version with rows instead of columns.

Are we interested in making a repeat parser? I could add it to my personal backlog (though this would probably be after the ESM migration, etc.). I'm also not sure what existing tooling is here (maybe there's some existing csstools/postcss/other parser that we can use)?

@changeset-bot
Copy link

changeset-bot bot commented Oct 13, 2023

🦋 Changeset detected

Latest commit: 8902506

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
stylelint Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@stylelint stylelint deleted a comment from mattxwang Oct 13, 2023
@Mouvedia
Copy link
Contributor

Mouvedia commented Oct 14, 2023

Are we interested in making a repeat parser?

As part of an existing package dependency or as an internal util?

Copy link
Member

@ybiquitous ybiquitous left a comment

Choose a reason for hiding this comment

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

@mattxwang Thanks for the pull request. This is almost good to me. 👍🏼

Are we interested in making a repeat parser?

Such a parser may be present, but I think this PR's simple string check is enough for now (the parser seems over-engineering to me for now).

…ndex.js

Co-authored-by: Masafumi Koba <473530+ybiquitous@users.noreply.github.com>
Copy link
Member

@ybiquitous ybiquitous left a comment

Choose a reason for hiding this comment

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

Thanks. LGTM 👍🏼

@mattxwang mattxwang merged commit f1d3228 into main Oct 16, 2023
18 checks passed
@mattxwang mattxwang deleted the fix-decl-lnghnd-props-grid-template-repeat branch October 16, 2023 00:27
@ybiquitous
Copy link
Member

ybiquitous commented Oct 16, 2023

As part of an existing package dependency or as an internal util?

FYI. Note this is not required. Maybe @csstools/css-tokenizer might achieve that:
https://github.com/csstools/postcss-plugins/tree/HEAD/packages/css-tokenizer#readme
see also

"@csstools/css-tokenizer": "^2.2.0",

cc @romainmenke

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Fix declaration-block-no-redundant-longhand-properties autofix for grid-template with repeat()
3 participants