Spaces:
Sleeping
Sleeping
File size: 916 Bytes
13555f3 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | // Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.
import React from 'react'
import {useIntl} from 'react-intl'
import Button from '../../widgets/buttons/button'
import './hiddenCardCount.scss'
type Props = {
hiddenCardsCount: number
showHiddenCardNotification: (show: boolean) => void
}
const HiddenCardCount = (props: Props): JSX.Element => {
const intl = useIntl()
const onClickHandler = () => {
props.showHiddenCardNotification(true)
}
return (
<div
className='HiddenCardCount'
onClick={onClickHandler}
>
<div className='hidden-card-title'>{intl.formatMessage({id: 'limitedCard.title', defaultMessage: 'Cards hidden'})}</div>
<Button title='hidden-card-count'>{props.hiddenCardsCount}</Button>
</div>
)
}
export default HiddenCardCount
|