mirror of
https://github.com/hcengineering/platform.git
synced 2025-06-06 07:46:32 +00:00
Bugfix for wrong toggle buttons behavior in Issues (#2299)
Signed-off-by: muhtimur <timur.mukhamedishin@xored.com>
This commit is contained in:
parent
507b155441
commit
3d4045c7c6
@ -12,17 +12,19 @@
|
|||||||
<div class="antiCard">
|
<div class="antiCard">
|
||||||
<div class="antiCard-group grid">
|
<div class="antiCard-group grid">
|
||||||
{#each config as model}
|
{#each config as model}
|
||||||
{@const value = viewOptions[model.key]}
|
|
||||||
<span class="label"><Label label={model.label} /></span>
|
<span class="label"><Label label={model.label} /></span>
|
||||||
<div class="value">
|
<div class="value">
|
||||||
{#if isToggleType(model)}
|
{#if isToggleType(model)}
|
||||||
<MiniToggle on={value} on:change={() => dispatch('update', { key: model.key, value: !value })} />
|
<MiniToggle
|
||||||
|
on={viewOptions[model.key]}
|
||||||
|
on:change={() => dispatch('update', { key: model.key, value: !viewOptions[model.key] })}
|
||||||
|
/>
|
||||||
{:else if isDropdownType(model)}
|
{:else if isDropdownType(model)}
|
||||||
{@const items = model.values.filter(({ hidden }) => !hidden?.(viewOptions))}
|
{@const items = model.values.filter(({ hidden }) => !hidden?.(viewOptions))}
|
||||||
<DropdownLabelsIntl
|
<DropdownLabelsIntl
|
||||||
label={model.label}
|
label={model.label}
|
||||||
{items}
|
{items}
|
||||||
selected={value}
|
selected={viewOptions[model.key]}
|
||||||
width="10rem"
|
width="10rem"
|
||||||
justify="left"
|
justify="left"
|
||||||
on:selected={(e) => dispatch('update', { key: model.key, value: e.detail })}
|
on:selected={(e) => dispatch('update', { key: model.key, value: e.detail })}
|
||||||
|
Loading…
Reference in New Issue
Block a user