feat(fs.shared): Added comment popout
This commit is contained in:
parent
cbc9571b8d
commit
c0af5c37d3
2 changed files with 10 additions and 3 deletions
|
@ -1,4 +1,5 @@
|
|||
const colors = {
|
||||
comment: 'secondary',
|
||||
note: 'primary',
|
||||
tip: 'accent',
|
||||
warning: 'error',
|
||||
|
@ -33,11 +34,16 @@ const Popout = (props) => {
|
|||
return (
|
||||
<div className={`relative my-8 bg-${color} bg-opacity-5`}>
|
||||
<div className={`
|
||||
border-y-4 sm:border-0 sm:border-l-4 px-6 sm:px-8 py-4 sm:py-2 shadow border-${color}`}>
|
||||
<div className={`font-bold uppercase text-${color}`}>
|
||||
{type}
|
||||
border-y-4 sm:border-0 sm:border-l-4 px-6 sm:px-8 py-4 sm:py-2 shadow text-base border-${color}`}>
|
||||
<div className={`font-bold flex flex-row gap-1 items-end` }>
|
||||
<span className={`font-bold uppercase text-${color}`}>{type}</span>
|
||||
<span className={`font-normal text-base text-${color}`}>
|
||||
{type === 'comment' && <> by <b>{props.by}</b></>}</span>
|
||||
</div>
|
||||
<div className="py-1 first:mt-0 popout-content">{props.children}</div>
|
||||
{type === 'comment' && (
|
||||
<div className={`font-bold italic text-${color}`}>{props.by}</div>
|
||||
)}
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue