import CreatedAgoBadge from '@components/badges/created-ago-badge' import ExpirationBadge from '@components/badges/expiration-badge' import VisibilityBadge from '@components/badges/visibility-badge' import Skeleton from '@components/skeleton' import styles from './title.module.css' type TitleProps = { title: string loading?: boolean displayName?: string visibility?: string createdAt?: Date expiresAt?: Date } export const PostTitle = ({ title, displayName, visibility, createdAt, expiresAt, loading }: TitleProps) => { return (

{title}{" "} by {displayName || "anonymous"}

{!loading && ( {visibility && } {createdAt && } {expiresAt && } )} {loading && ( )}
) }