Skip to content

Commit

Permalink
OpenConceptLab/ocl_issues#1776 | Entity tooltips to show skeleton whe…
Browse files Browse the repository at this point in the history
…n loading summary
  • Loading branch information
snyaggarwal committed Oct 15, 2024
1 parent 00b4f86 commit efc1287
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/components/orgs/OrgTooltip.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -63,15 +63,15 @@ const TooltipTitle = ({ org }) => {
<UserIcon sx={{marginRight: '4px', fontSize: '14px'}} size='small' />
<span style={{marginTop: '2px'}}>{entity.members} {t('org.members').toLowerCase()}</span>
</span> :
<Skeleton variant="text" sx={{ fontSize: '1rem' }} />
<Skeleton variant="text" sx={{ fontSize: '1rem', width: '33%' }} />
}
{
entity?.public_sources >= 0 ?
<span style={{fontSize: '12px', display: 'flex', alignItems: 'center', marginLeft: entity.members >= 0 ? '8px' : 0}} className='ellipsis-text-3'>
<RepoIcon sx={{marginRight: '4px', fontSize: '14px'}} size='small' noTooltip />
<span style={{marginTop: '2px'}}>{entity.public_sources + entity.public_collections} {t('repo.repos').toLowerCase()}</span>
</span> :
<Skeleton variant="text" sx={{ fontSize: '1rem' }} />
<Skeleton variant="text" sx={{ fontSize: '1rem', width: '33%', marginLeft: '8px' }} />
}
</div>
</React.Fragment>
Expand Down
4 changes: 2 additions & 2 deletions src/components/users/UserTooltip.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -60,14 +60,14 @@ const TooltipTitle = ({ user }) => {
<span style={{fontSize: '12px', display: 'flex', alignItems: 'center'}} className='ellipsis-text-3'>
<OrgIcon noLink strict sx={{marginRight: '4px', fontSize: '14px'}} size='small' noTooltip /> {entity.orgs} {t('org.orgs').toLowerCase()}
</span> :
<Skeleton variant="text" sx={{ fontSize: '1rem' }} />
<Skeleton variant="text" sx={{ fontSize: '1rem', width: '33%' }} />
}
{
entity?.public_sources >= 0 ?
<span style={{fontSize: '12px', display: 'flex', alignItems: 'center', marginLeft: entity.orgs >= 0 ? '8px' : 0}} className='ellipsis-text-3'>
<RepoIcon sx={{marginRight: '4px', fontSize: '14px'}} size='small' noTooltip /> {entity.public_sources + entity.public_collections} {t('repo.repos').toLowerCase()}
</span> :
<Skeleton variant="text" sx={{ fontSize: '1rem' }} />
<Skeleton variant="text" sx={{ fontSize: '1rem', width: '33%', marginLeft: '8px' }} />
}
</div>
</React.Fragment>
Expand Down

0 comments on commit efc1287

Please sign in to comment.