Skip to content

Fix border-inline-start and border-inline-end not having any valid ordering #1756

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

Merged
merged 2 commits into from
Dec 11, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .changeset/unlucky-boxes-brake.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
'@compiled/eslint-plugin': patch
'@compiled/utils': patch
---

Fix border-inline-start and border-inline-end not having any valid ordering in the shorthand-property-sorting ESLint rule
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{

Check failure on line 1 in package.json

View workflow job for this annotation

GitHub Actions / build (14.x)

package.json is not sorted correctly

Check failure on line 1 in package.json

View workflow job for this annotation

GitHub Actions / build (16.x)

package.json is not sorted correctly

Check failure on line 1 in package.json

View workflow job for this annotation

GitHub Actions / build (18.x)

package.json is not sorted correctly
"name": "compiled",
"version": "0.0.0",
"private": true,
Expand Down Expand Up @@ -158,5 +158,6 @@
"react"
]
}
]
],
"packageManager": "yarn@1.22.21+sha256.dbed5b7e10c552ba0e1a545c948d5473bc6c5a28ce22a8fd27e493e3e5eb6370"
Copy link
Collaborator

Choose a reason for hiding this comment

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

What's this about?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

gahhh yarn keeps adding that

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

we're supposed to specify what version of yarn the repo should use through packageManager

i never got the chance to set this up properly, so it keeps trying to add it whenever i run yarn install

maybe i should just set it up 🤔 hold on

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

hmm looks a bit complicated, something for another day...

Copy link
Collaborator

Choose a reason for hiding this comment

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

Yeah no clue 🫡

}
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,23 @@ tester.run('shorthand-property-sorting', shorthandFirst, {
export const EmphasisText = ({ children, status }) => <span css={containerAppearance[status]}>{children}</span>;
`,
},

//
// has a valid sorting for borderInlineStart and borderInlineEnd
//

{
name: 'has a valid sorting for borderInlineStart and borderInlineEnd',
code: `
import { styled } from '@compiled/react';

const Bap = styled.div({
borderTop: 'none',
borderInlineStart: 'none',
borderInlineEnd: 'none',
});
`,
},
]),

invalid: includedImports.flatMap((imp) => [
Expand Down
6 changes: 0 additions & 6 deletions packages/utils/src/shorthand.ts
Original file line number Diff line number Diff line change
Expand Up @@ -232,9 +232,6 @@ export const shorthandFor: Record<ShorthandProperties, true | readonly string[]>
'border-inline-end-color',
'border-inline-end-style',
'border-inline-end-width',
'border-left-color',
'border-left-style',
'border-left-width',
'border-right-color',
'border-right-style',
'border-right-width',
Expand All @@ -246,9 +243,6 @@ export const shorthandFor: Record<ShorthandProperties, true | readonly string[]>
'border-left-color',
'border-left-style',
'border-left-width',
'border-right-color',
'border-right-style',
'border-right-width',
],
'border-left': [
'border-inline-start-color',
Expand Down
Loading