diff --git a/apps/meteor/client/hooks/useRoomIcon.spec.tsx b/apps/meteor/client/hooks/useRoomIcon.spec.tsx index 785ded7d19215..8345d850074ab 100644 --- a/apps/meteor/client/hooks/useRoomIcon.spec.tsx +++ b/apps/meteor/client/hooks/useRoomIcon.spec.tsx @@ -6,59 +6,45 @@ const mockRooms = { t: 'c', name: 'public', teamMain: false, - // @ts-expect-error TODO: Implement ABAC attributes in rooms - abacAttributes: false, }), private: createFakeRoom({ t: 'p', name: 'private', teamMain: false, - // @ts-expect-error TODO: Implement ABAC attributes in rooms - abacAttributes: false, }), team: createFakeRoom({ t: 'c', name: 'team', teamMain: true, - // @ts-expect-error TODO: Implement ABAC attributes in rooms - abacAttributes: false, }), direct: createFakeRoom({ t: 'd', name: 'direct', teamMain: false, - // @ts-expect-error TODO: Implement ABAC attributes in rooms - abacAttributes: false, }), directMultiple: createFakeRoom({ t: 'd', name: 'direct-multiple', teamMain: false, - // @ts-expect-error TODO: Implement ABAC attributes in rooms - abacAttributes: false, uids: ['user1', 'user2', 'user3'], }), federated: createFakeRoom({ t: 'c', name: 'federated', teamMain: false, - // @ts-expect-error TODO: Implement ABAC attributes in rooms - abacAttributes: false, federated: true, }), abacRoom: createFakeRoom({ t: 'c', name: 'abac-room', teamMain: false, - // @ts-expect-error TODO: Implement ABAC attributes in rooms - abacAttributes: true, + abacAttributes: [{ key: 'department', values: ['engineering'] }], }), abacTeamRoom: createFakeRoom({ t: 'c', name: 'abac-team-room', teamMain: true, - // @ts-expect-error TODO: Implement ABAC attributes in rooms - abacAttributes: true, + abacAttributes: [{ key: 'team', values: ['core'] }], }), }; diff --git a/apps/meteor/client/hooks/useRoomIcon.tsx b/apps/meteor/client/hooks/useRoomIcon.tsx index 54a9b7982e147..6d090d7d8f66c 100644 --- a/apps/meteor/client/hooks/useRoomIcon.tsx +++ b/apps/meteor/client/hooks/useRoomIcon.tsx @@ -6,9 +6,8 @@ import type { ComponentProps, ReactElement } from 'react'; import { ReactiveUserStatus } from '../components/UserStatus'; export const useRoomIcon = ( - room: Pick, + room: Pick, ): ComponentProps | ReactElement | null => { - // @ts-expect-error TODO: Implement ABAC attributes in rooms if (room.abacAttributes) { if (room.teamMain) { return { name: 'team-shield' };