1
0
mirror of https://github.com/laurent22/joplin.git synced 2024-12-18 09:35:20 +02:00
joplin/packages/app-desktop/gui/Sidebar/listItemComponents/NoteCount.tsx

16 lines
407 B
TypeScript

import * as React from 'react';
import { _n } from '@joplin/lib/locale';
interface Props {
count: number;
}
const NoteCount: React.FC<Props> = props => {
const count = props.count;
const title = _n('Contains %d note', 'Contains %d notes', count, count);
return count ? <div role='note' aria-label={title} title={title} className="note-count-label">{count}</div> : null;
};
export default NoteCount;