import { Broadcast } from "@phosphor-icons/react/dist/ssr/Broadcast"; import { Skeleton } from "@pythnetwork/component-library/Skeleton"; import clsx from "clsx"; import type { ComponentProps, ReactNode } from "react"; import styles from "./index.module.scss"; import { omitKeys } from "../../omit-keys"; import { PublisherKey } from "../PublisherKey"; type Props = ComponentProps<"div"> & { compact?: boolean | undefined } & ( | { isLoading: true } | ({ isLoading?: false; publisherKey: string; } & ( | { name: string; icon: ReactNode } | { name?: undefined; icon?: undefined } )) ); export const PublisherTag = ({ className, ...props }: Props) => (
{props.isLoading ? ( ) : (
{props.icon ?? }
)}
); const UndisclosedIcon = ({ className, ...props }: ComponentProps<"div">) => (
); const Contents = (props: Props) => { if (props.isLoading) { return ; } else if (props.compact) { return props.name ? (
{props.name}
) : ( ); } else if (props.name) { return (
{props.name}
); } else { return ; } };