CSS Element State Button Fix
This commit is contained in:
parent
d648844c3d
commit
c31b5a6f19
|
@ -28,6 +28,7 @@
|
||||||
onChange(val)
|
onChange(val)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
const checkSelected = val =>
|
const checkSelected = val =>
|
||||||
isMultiSelect ? value.includes(val) : value === val
|
isMultiSelect ? value.includes(val) : value === val
|
||||||
|
|
||||||
|
@ -37,7 +38,7 @@
|
||||||
{#each buttonProps as props}
|
{#each buttonProps as props}
|
||||||
<div class="button-container">
|
<div class="button-container">
|
||||||
<FlatButton
|
<FlatButton
|
||||||
selected={checkSelected(props.value)}
|
selected={isMultiSelect ? value.includes(props.value) : value === props.value}
|
||||||
onClick={onButtonClicked}
|
onClick={onButtonClicked}
|
||||||
{...props} />
|
{...props} />
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in New Issue