refactor: remove absolute classes

This commit is contained in:
liyasthomas
2021-08-17 12:56:36 +05:30
parent 3534e133af
commit 956ca44ef0
55 changed files with 269 additions and 404 deletions

View File

@@ -6,7 +6,6 @@
class="
font-bold
py-2
transition
inline-flex
items-center
justify-center
@@ -15,8 +14,8 @@
"
:class="[
color
? `text-${color}-800 bg-${color}-200 hover:(text-${color}-900 bg-${color}-300) focus:(text-${color}-900 bg-${color}-300)`
: `text-accentContrast bg-accent hover:bg-accentDark focus:bg-accentDark`,
? `text-${color}-800 bg-${color}-200 hover:(text-${color}-900 bg-${color}-300) focus-visible:(text-${color}-900 bg-${color}-300)`
: `text-accentContrast bg-accent hover:bg-accentDark focus-visible:bg-accentDark`,
label ? 'px-4' : 'px-2',
rounded ? 'rounded-full' : 'rounded',
{ 'opacity-75 cursor-not-allowed': disabled },
@@ -28,7 +27,7 @@
gradient,
},
{
'border border-accent hover:border-accentDark focus:border-accentDark':
'border border-accent hover:border-accentDark focus-visible:border-accentDark':
outline,
},
]"

View File

@@ -6,7 +6,6 @@
class="
font-medium
py-2
transition
inline-flex
items-center
justify-center
@@ -18,14 +17,14 @@
:class="[
color
? `text-${color}-500 hover:(text-${color}-600 text-${color}-600)`
: 'text-secondary hover:text-secondaryDark focus:text-secondaryDark',
: 'text-secondary hover:text-secondaryDark focus-visible:text-secondaryDark',
label ? 'rounded px-4' : 'px-2',
{ 'rounded-full': rounded },
{ 'opacity-75 cursor-not-allowed': disabled },
{ 'flex-row-reverse': reverse },
{ 'px-6 py-4 text-lg': large },
{
'border border-divider hover:border-dividerDark focus:border-dividerDark':
'border border-divider hover:border-dividerDark focus-visible:border-dividerDark':
outline,
},
]"