ConceptPortal-public/rsconcept/frontend/src/components/Common/LabeledText.tsx

27 lines
466 B
TypeScript
Raw Normal View History

2023-07-18 14:55:40 +03:00
interface LabeledTextProps {
id?: string
label: string
text: any
tooltip?: string
}
function LabeledText({id, label, text, tooltip}: LabeledTextProps) {
return (
2023-07-21 00:09:05 +03:00
<div className='flex justify-between gap-4'>
2023-07-18 14:55:40 +03:00
<label
className='font-semibold'
title={tooltip}
htmlFor={id}
>
{label}
</label>
<span
id={id}
>
{text}
</span>
</div>
);
}
export default LabeledText;