Skip to content

Commit

Permalink
Cleanup custom properties (#2771)
Browse files Browse the repository at this point in the history
* prefix custom properties with tw-

* prefix custom properties with tw- in tests

* prefix gradient values in the defaultConfig

* inline gradient-via-color

* simplify --tw-tailwind-empty to --tw-empty

* replace the long --tw-font-variant-numeric-... to the way shorter --tw-fvn-...

* Rename --tw-box-shadow to --tw-shadow

To match class name.

* Rename font-variant-numeric variables

* Remove 'transform' from transform variables

* Shorten gradient variables

* Fix style

Co-authored-by: Adam Wathan <[email protected]>
  • Loading branch information
RobinMalfait and adamwathan authored Nov 16, 2020
1 parent f57fbb6 commit b86bdbc
Show file tree
Hide file tree
Showing 38 changed files with 136,158 additions and 142,205 deletions.
8 changes: 4 additions & 4 deletions __tests__/applyAtRule.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -634,8 +634,8 @@ test('adjacent rules are collapsed after being applied', () => {
`
const expected = `
.foo:hover {
--bg-opacity: 1;
background-color: rgba(255, 255, 255, var(--bg-opacity));
--tw-bg-opacity: 1;
background-color: rgba(255, 255, 255, var(--tw-bg-opacity));
opacity: 0.5;
}
.foo {
Expand Down Expand Up @@ -1055,8 +1055,8 @@ test('you can apply classes in a nested rule', () => {
const expected = `
.selector {
&:hover {
--text-opacity: 1;
color: rgba(255, 255, 255, var(--text-opacity));
--tw-text-opacity: 1;
color: rgba(255, 255, 255, var(--tw-text-opacity));
}
}
`
Expand Down
Loading

0 comments on commit b86bdbc

Please sign in to comment.