Skip to content

Commit

Permalink
feat(Viewer): Hide the qualification in the panel if not supported
Browse files Browse the repository at this point in the history
  • Loading branch information
JF-Cozy committed Jan 7, 2025
1 parent 31fa49a commit e0c7c5a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/cozy-viewer/src/Panel/Qualification.jsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import PropTypes from 'prop-types'
import React, { Fragment, useRef, useState, createRef, useEffect } from 'react'

import { hasSupportedQualification } from 'cozy-client/dist/models/document/qualification'
import { hasQualifications } from 'cozy-client/dist/models/file'
import {
isExpiringSoon,
Expand Down Expand Up @@ -71,7 +72,7 @@ const Qualification = ({ file, isReadOnly }) => {
{isExpiringSoon(file) && !isExpirationAlertHidden(file) && (
<ExpirationAlert file={file} />
)}
{hasQualifications(file) ? (
{hasSupportedQualification(file) ? (
<QualificationListItemQualification
file={file}
isReadOnly={isReadOnly}
Expand Down

0 comments on commit e0c7c5a

Please sign in to comment.