feedback fixes

This commit is contained in:
ronronscelestes 2022-07-05 16:14:51 +02:00
parent 9b6785a697
commit f383fbb6a7

View File

@ -7,22 +7,13 @@ const getSelectStyles = (theme, error) => {
lineHeight: 'normal', lineHeight: 'normal',
}), }),
control: (base, state) => { control: (base, state) => {
let border; let border = `1px solid ${theme.colors.neutral200} !important`;
let borderBottom;
let backgroundColor; let backgroundColor;
if (state.isFocused) { if (state.isFocused) {
border = `1px solid ${theme.colors.primary600} !important`; border = `1px solid ${theme.colors.primary200} !important`;
} else if (error) { } else if (error) {
border = `1px solid ${theme.colors.danger600} !important`; border = `1px solid ${theme.colors.danger600} !important`;
} else if (state.isDisabled) {
border = `1px solid ${theme.colors.neutral200} !important`;
} else {
border = `1px solid ${theme.colors.neutral200} !important`;
}
if (state.menuIsOpen === true) {
borderBottom = `1px solid ${theme.colors.primary600} !important`;
} }
if (state.isDisabled) { if (state.isDisabled) {
@ -37,7 +28,6 @@ const getSelectStyles = (theme, error) => {
outline: 0, outline: 0,
boxShadow: 0, boxShadow: 0,
borderRadius: '2px !important', borderRadius: '2px !important',
borderBottom,
backgroundColor, backgroundColor,
borderTopLeftRadius: '4px !important', borderTopLeftRadius: '4px !important',
borderTopRightRadius: '4px !important', borderTopRightRadius: '4px !important',
@ -93,12 +83,10 @@ const getSelectStyles = (theme, error) => {
}, },
placeholder: base => ({ ...base, marginLeft: 0 }), placeholder: base => ({ ...base, marginLeft: 0 }),
singleValue: (base, state) => { singleValue: (base, state) => {
let color; let color = theme.colors.neutral800;
if (state.isDisabled) { if (state.isDisabled) {
color = theme.colors.neutral600; color = theme.colors.neutral600;
} else {
color = theme.colors.neutral800;
} }
return { ...base, marginLeft: 0, color }; return { ...base, marginLeft: 0, color };