Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion src/components/concepts/ConceptCard.jsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import React from 'react';
import { useTranslation } from 'react-i18next';
import Card from '@mui/material/Card';
import Checkbox from '@mui/material/Checkbox';
import Button from '@mui/material/Button'
Expand All @@ -10,6 +11,7 @@ import ConceptListItem from './ConceptListItem'
import AddToCollectionDialog from '../common/AddToCollectionDialog'

const ConceptCard = ({ concept, onSelect, isSelected, onCardClick, bgColor, isShown, firstChild }) => {
const { t } = useTranslation()
const id = concept.version_url || concept.url || concept.id
const isChecked = isSelected(id)
const isSelectedToShow = isShown(id)
Expand Down Expand Up @@ -65,7 +67,7 @@ const ConceptCard = ({ concept, onSelect, isSelected, onCardClick, bgColor, isSh
sx={{textTransform: 'none', whiteSpace: 'nowrap', flexShrink: 0}}
onClick={event => { event.stopPropagation(); setAddToCollectionOpen(true) }}
>
Add to Collection
{t('addToCollection.add_to_collection')}
</Button>
)}
</div>
Expand Down
4 changes: 2 additions & 2 deletions src/components/concepts/ConceptHeader.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ const ConceptHeader = ({concept, repo, onClose, repoURL, onEdit, onRetire, onCre
!loading &&
<div className='col-xs-12 padding-0' style={{display: 'flex', alignItems: 'center', justifyContent: 'space-between'}}>
<span style={{display: 'flex', alignItems: 'center'}}>
{hasAccess && (
{isLoggedIn() && (
<Button
startIcon={<AddIcon fontSize='inherit' />}
variant='text'
Expand All @@ -137,7 +137,7 @@ const ConceptHeader = ({concept, repo, onClose, repoURL, onEdit, onRetire, onCre
sx={{textTransform: 'none'}}
onClick={() => setAddToCollectionOpen(true)}
>
Add to Collection
{t('addToCollection.add_to_collection')}
</Button>
)}
{hasAccess && isSource && (
Expand Down
Loading