Skip to content

Commit

Permalink
fix(SharingShortcutBadge): Improve fontSize and use Circle from cozy-ui
Browse files Browse the repository at this point in the history
  • Loading branch information
cballevre committed Aug 24, 2023
1 parent c56c9a9 commit 2e83623
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions src/drive/web/modules/filelist/cells/SharingShortcutBadge.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import cx from 'classnames'
import { isSharingShortcutNew } from 'cozy-client/dist/models/file'
import { useI18n } from 'cozy-ui/transpiled/react/I18n'
import { TableCell } from 'cozy-ui/transpiled/react/Table'
import Circle from 'cozy-ui/transpiled/react/Circle'

import styles from 'drive/styles/filelist.styl'

Expand All @@ -19,17 +20,14 @@ const SharingShortcutBadge = ({ file }) => {
)}
>
{isSharingShortcutNew(file) ? (
<div
className="u-w-1 u-h-1 u-bdrs-circle u-flex"
style={{ backgroundColor: 'var(--errorColor)' }}
>
<Circle size="xsmall" backgroundColor="var(--errorColor)">
<span
className="u-fw-bold u-fz-tiny u-white u-lh-tiny u-m-auto"
style={{ fontSize: '11px', lineHeight: '1rem' }}
aria-label={t('table.row_sharing_shortcut_aria_label')}
>
1
</span>
</div>
</Circle>
) : null}
</TableCell>
)
Expand Down

0 comments on commit 2e83623

Please sign in to comment.