mirror of
https://github.com/billsonnn/nitro-react.git
synced 2024-11-27 08:00:51 +01:00
fix bug in group creator
This commit is contained in:
parent
b5ef9abac8
commit
ccd2344443
@ -27,7 +27,7 @@ export const GroupSharedTabColorsView: FC<{}> = props =>
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
}, [ groupColors, groupColorsA, groupColorsB ]);
|
}, [dispatchGroupsState, groupColors, groupColorsA, groupColorsB]);
|
||||||
|
|
||||||
const getGroupColor = useCallback((colorIndex: number) =>
|
const getGroupColor = useCallback((colorIndex: number) =>
|
||||||
{
|
{
|
||||||
@ -63,7 +63,7 @@ export const GroupSharedTabColorsView: FC<{}> = props =>
|
|||||||
<div className="fw-bold">{ LocalizeText('group.edit.color.primary.color') }</div>
|
<div className="fw-bold">{ LocalizeText('group.edit.color.primary.color') }</div>
|
||||||
<div className="d-flex align-items-center gap-2">
|
<div className="d-flex align-items-center gap-2">
|
||||||
<div className="row row-cols-18 g-0 gap-1 w-100 h-100 overflow-auto">
|
<div className="row row-cols-18 g-0 gap-1 w-100 h-100 overflow-auto">
|
||||||
{ groupColorsA && groupColorsA.map((item, index) =>
|
{ groupColors && groupColorsA && groupColorsA.map((item, index) =>
|
||||||
{
|
{
|
||||||
return <div key={ index } className={ 'color-swatch cursor-pointer' + classNames({ ' active': groupColors[selectingColorIndex] === item.id }) } style={{ backgroundColor: '#' + item.color }} onClick={ () => selectColor(item.id) }></div>
|
return <div key={ index } className={ 'color-swatch cursor-pointer' + classNames({ ' active': groupColors[selectingColorIndex] === item.id }) } style={{ backgroundColor: '#' + item.color }} onClick={ () => selectColor(item.id) }></div>
|
||||||
}) }
|
}) }
|
||||||
|
Loading…
Reference in New Issue
Block a user