Replace theme specific styles in Toggle
This commit is contained in:
@@ -281,24 +281,20 @@ export function createSharedToggleStyles({
|
|||||||
|
|
||||||
if (selected) {
|
if (selected) {
|
||||||
base.push({
|
base.push({
|
||||||
backgroundColor:
|
backgroundColor: t.palette.primary_25,
|
||||||
t.name === 'light' ? t.palette.primary_25 : t.palette.primary_900,
|
|
||||||
borderColor: t.palette.primary_500,
|
borderColor: t.palette.primary_500,
|
||||||
})
|
})
|
||||||
|
|
||||||
if (hovered) {
|
if (hovered) {
|
||||||
baseHover.push({
|
baseHover.push({
|
||||||
backgroundColor:
|
backgroundColor: t.palette.primary_100,
|
||||||
t.name === 'light' ? t.palette.primary_100 : t.palette.primary_800,
|
borderColor: t.palette.primary_600,
|
||||||
borderColor:
|
|
||||||
t.name === 'light' ? t.palette.primary_600 : t.palette.primary_400,
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (hovered) {
|
if (hovered) {
|
||||||
baseHover.push({
|
baseHover.push({
|
||||||
backgroundColor:
|
backgroundColor: t.palette.contrast_50,
|
||||||
t.name === 'light' ? t.palette.contrast_50 : t.palette.contrast_100,
|
|
||||||
borderColor: t.palette.contrast_500,
|
borderColor: t.palette.contrast_500,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@@ -306,16 +302,13 @@ export function createSharedToggleStyles({
|
|||||||
|
|
||||||
if (isInvalid) {
|
if (isInvalid) {
|
||||||
base.push({
|
base.push({
|
||||||
backgroundColor:
|
backgroundColor: t.palette.negative_25,
|
||||||
t.name === 'light' ? t.palette.negative_25 : t.palette.negative_975,
|
borderColor: t.palette.negative_300,
|
||||||
borderColor:
|
|
||||||
t.name === 'light' ? t.palette.negative_300 : t.palette.negative_800,
|
|
||||||
})
|
})
|
||||||
|
|
||||||
if (hovered) {
|
if (hovered) {
|
||||||
baseHover.push({
|
baseHover.push({
|
||||||
backgroundColor:
|
backgroundColor: t.palette.negative_25,
|
||||||
t.name === 'light' ? t.palette.negative_25 : t.palette.negative_900,
|
|
||||||
borderColor: t.palette.negative_600,
|
borderColor: t.palette.negative_600,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user