import { CaretUp } from "@phosphor-icons/react/dist/ssr/CaretUp"; import { Skeleton } from "@pythnetwork/component-library/Skeleton"; import clsx from "clsx"; import type { ComponentProps } from "react"; import styles from "./index.module.scss"; const SKELETON_WIDTH = 15; type OwnProps = | { isLoading: true; skeletonWidth?: number | undefined } | { isLoading?: false; direction: "up" | "down" | "flat"; }; type Props = Omit, keyof OwnProps> & OwnProps; export const ChangeValue = ({ className, children, ...props }: Props) => { // eslint-disable-next-line @typescript-eslint/no-unused-vars const { isLoading, ...propsWithoutIsLoading } = props; return ( {children} ); }; const Contents = (props: Props) => { if (props.isLoading) { return ; } else if (props.direction === "flat") { return "-"; } else { return ( <> {props.children} ); } };