Web:Components:Selector: fix role and selectedItems

This commit is contained in:
TimofeyBoyko 2022-09-02 13:14:51 +03:00
parent 502225f87b
commit bbb0049bfe
2 changed files with 6 additions and 2 deletions

View File

@ -317,6 +317,8 @@ Selector.defaultProps = {
withSelectAll: false,
withAccessRights: false,
withCancelButton: false,
selectedItems: [],
};
export default Selector;

View File

@ -79,7 +79,9 @@ const Item = React.memo(({ index, style, data }) => {
const item = items[index];
const { label, avatar, icon, isSelected } = item;
const { label, avatar, icon, role, isSelected } = item;
const currentRole = role ? role : "user";
const isLogo = !!icon;
@ -102,7 +104,7 @@ const Item = React.memo(({ index, style, data }) => {
<Avatar
className="user-avatar"
source={avatar}
role={"user"}
role={currentRole}
size={"min"}
/>
) : (