Skip to content

Commit 9785f3c

Browse files
authored
[#69] Tailwind 4 upgrade (#81)
* [#69] Run `npx @tailwindcss/upgrade@next` * [#69] Add back default border color TW 4 changed the default border color to `currentColor` instead of gray-200 This change adds back gray-200 where it wasn't specified. * [#69] Port js config to app.css * [#69] Migrate to Tailwind's `max-*` media query format. * [#69] Fix issues with nested dark:text-red-300 * [#69] Resolve type errors with animation keyframes
1 parent 2e15ca6 commit 9785f3c

16 files changed

+624
-935
lines changed

config/tailwind/container.js

-21
This file was deleted.

config/tailwind/dialog.js

+17-17
Original file line numberDiff line numberDiff line change
@@ -23,23 +23,23 @@ export default plugin(({ addComponents }) => {
2323
'dialog-backdrop-out var(--dialog-transition-duration, 300ms) cubic-bezier(0.2, 0, 0.13, 1) forwards',
2424
},
2525
},
26-
// Animation Keyframes
27-
'@keyframes dialog-in': {
28-
'0%': { transform: 'translateY(2rem)', opacity: 0 },
29-
'100%': { transform: 'translateY(0px)', opacity: 1 },
30-
},
31-
'@keyframes dialog-out': {
32-
'0%': { transform: 'scale(1)', opacity: 1 },
33-
'100%': { transform: 'scale(0.9)', opacity: 0 },
34-
},
35-
'@keyframes dialog-backdrop-in': {
36-
'0%': { opacity: 0 },
37-
'100%': { opacity: 1 },
38-
},
39-
'@keyframes dialog-backdrop-out': {
40-
'0%': { opacity: 1 },
41-
'100%': { opacity: 0 },
42-
},
26+
},
27+
// Animation Keyframes
28+
'@keyframes dialog-in': {
29+
'0%': { transform: 'translateY(2rem)', opacity: '0' },
30+
'100%': { transform: 'translateY(0px)', opacity: '1' },
31+
},
32+
'@keyframes dialog-out': {
33+
'0%': { transform: 'scale(1)', opacity: '1' },
34+
'100%': { transform: 'scale(0.9)', opacity: '0' },
35+
},
36+
'@keyframes dialog-backdrop-in': {
37+
'0%': { opacity: '0' },
38+
'100%': { opacity: '1' },
39+
},
40+
'@keyframes dialog-backdrop-out': {
41+
'0%': { opacity: '1' },
42+
'100%': { opacity: '0' },
4343
},
4444
})
4545
})

config/tailwind/forms.js

+8-3
Original file line numberDiff line numberDiff line change
@@ -65,9 +65,14 @@ export default plugin(({ addComponents }) => {
6565
},
6666
},
6767
// required field styles
68-
'&[data-required] label .field-label::after': {
69-
'@apply content-["*"] text-red-600 align-super text-xs ml-2 font-medium dark:text-red-300':
70-
{},
68+
'&[data-required] label .field-label': {
69+
'&::after': {
70+
'@apply content-["*"] text-red-600 align-super text-xs ml-2 font-medium':
71+
{},
72+
},
73+
'.dark &::after': {
74+
'@apply text-red-300': {},
75+
},
7176
},
7277
'&[data-required="long"] label .field-label::after': {
7378
'@apply content-["*Required"]': {},

0 commit comments

Comments
 (0)