Skip to content
Merged
Show file tree
Hide file tree
Changes from 4 commits
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
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Fixed

- Only generate positive `grid-cols-*` and `grid-rows-*` utilities ([#16020](https://github.com/tailwindlabs/tailwindcss/pull/16020))
- Refactor gradient implementation to work around [prettier/prettier#17058](https://github.com/prettier/prettier/issues/17058) ([#16072](https://github.com/tailwindlabs/tailwindcss/pull/16072))

## [4.0.1] - 2025-01-29

Expand Down
16 changes: 8 additions & 8 deletions packages/tailwindcss/src/compat/legacy-utilities.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,42 +22,42 @@ test('bg-gradient-*', async () => {
),
).toMatchInlineSnapshot(`
".bg-gradient-to-b {
--tw-gradient-position: to bottom in oklab, ;
--tw-gradient-position: to bottom in oklab;
background-image: linear-gradient(var(--tw-gradient-stops));
}

.bg-gradient-to-bl {
--tw-gradient-position: to bottom left in oklab, ;
--tw-gradient-position: to bottom left in oklab;
background-image: linear-gradient(var(--tw-gradient-stops));
}

.bg-gradient-to-br {
--tw-gradient-position: to bottom right in oklab, ;
--tw-gradient-position: to bottom right in oklab;
background-image: linear-gradient(var(--tw-gradient-stops));
}

.bg-gradient-to-l {
--tw-gradient-position: to left in oklab, ;
--tw-gradient-position: to left in oklab;
background-image: linear-gradient(var(--tw-gradient-stops));
}

.bg-gradient-to-r {
--tw-gradient-position: to right in oklab, ;
--tw-gradient-position: to right in oklab;
background-image: linear-gradient(var(--tw-gradient-stops));
}

.bg-gradient-to-t {
--tw-gradient-position: to top in oklab, ;
--tw-gradient-position: to top in oklab;
background-image: linear-gradient(var(--tw-gradient-stops));
}

.bg-gradient-to-tl {
--tw-gradient-position: to top left in oklab, ;
--tw-gradient-position: to top left in oklab;
background-image: linear-gradient(var(--tw-gradient-stops));
}

.bg-gradient-to-tr {
--tw-gradient-position: to top right in oklab, ;
--tw-gradient-position: to top right in oklab;
background-image: linear-gradient(var(--tw-gradient-stops));
}"
`)
Expand Down
2 changes: 1 addition & 1 deletion packages/tailwindcss/src/compat/legacy-utilities.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ export function registerLegacyUtilities(designSystem: DesignSystem) {
['tl', 'top left'],
]) {
designSystem.utilities.static(`bg-gradient-to-${value}`, () => [
decl('--tw-gradient-position', `to ${direction} in oklab,`),
decl('--tw-gradient-position', `to ${direction} in oklab`),
decl('background-image', `linear-gradient(var(--tw-gradient-stops))`),
])
}
Expand Down
Loading