Skip to content

Commit

Permalink
Chore: rename new component
Browse files Browse the repository at this point in the history
  • Loading branch information
thomasheartman committed Sep 27, 2024
1 parent deb4e02 commit 0d45440
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ type Props = {
AvatarComponent?: typeof UserAvatar;
className?: string;
};
export const OwnerAvatarGroup: React.FC<Props> = ({ users, ...props }) => {
export const AvatarGroupFromOwners: React.FC<Props> = ({ users, ...props }) => {
const { uiConfig } = useUiConfig();

const mapOwners = (owner: ProjectSchemaOwners[number]) => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Grid, Typography, styled } from '@mui/material';
import { OwnerAvatarGroup } from 'component/common/OwnerAvatarGroup/OwnerAvatarGroup';
import { AvatarGroupFromOwners } from 'component/common/AvatarGroupFromOwners/AvatarGroupFromOwners';
import useProjects from 'hooks/api/getters/useProjects/useProjects';
import type { ProjectSchemaOwners } from 'openapi';
import { Link } from 'react-router-dom';
Expand Down Expand Up @@ -105,7 +105,7 @@ export const ContentGridNoProjects = () => {
</TitleContainer>
<div>
<p>Project owners in Unleash:</p>
<OwnerAvatarGroup
<AvatarGroupFromOwners
users={Object.values(owners)}
avatarLimit={9}
/>
Expand Down
4 changes: 2 additions & 2 deletions frontend/src/component/personalDashboard/RoleAndOwnerInfo.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { styled } from '@mui/material';
import { Badge } from 'component/common/Badge/Badge';
import { OwnerAvatarGroup } from 'component/common/OwnerAvatarGroup/OwnerAvatarGroup';
import { AvatarGroupFromOwners } from 'component/common/AvatarGroupFromOwners/AvatarGroupFromOwners';
import type { ProjectSchemaOwners } from 'openapi';

type Props = {
Expand Down Expand Up @@ -34,7 +34,7 @@ export const RoleAndOwnerInfo = ({ roles, owners }: Props) => {
</InfoSection>
<InfoSection>
<span>Project owner{owners.length > 1 ? 's' : ''}</span>
<OwnerAvatarGroup users={owners} avatarLimit={3} />
<AvatarGroupFromOwners users={owners} avatarLimit={3} />
</InfoSection>
</Wrapper>
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { styled } from '@mui/material';
import type { ProjectSchema, ProjectSchemaOwners } from 'openapi';
import { ConditionallyRender } from 'component/common/ConditionallyRender/ConditionallyRender';
import { AvatarComponent } from 'component/common/AvatarGroup/AvatarGroup';
import { OwnerAvatarGroup } from 'component/common/OwnerAvatarGroup/OwnerAvatarGroup';
import { AvatarGroupFromOwners } from 'component/common/AvatarGroupFromOwners/AvatarGroupFromOwners';

export interface IProjectOwnersProps {
owners?: ProjectSchema['owners'];
Expand Down Expand Up @@ -69,7 +69,7 @@ export const ProjectOwners: FC<IProjectOwnersProps> = ({ owners = [] }) => {
return (
<StyledWrapper data-testid='test'>
<StyledContainer data-loading>
<OwnerAvatarGroup
<AvatarGroupFromOwners
users={owners}
avatarLimit={6}
AvatarComponent={StyledAvatarComponent}
Expand Down

0 comments on commit 0d45440

Please sign in to comment.