diff --git a/components/CopyButton.tsx b/components/CopyButton.tsx new file mode 100644 index 0000000..090d64b --- /dev/null +++ b/components/CopyButton.tsx @@ -0,0 +1,36 @@ +import React from "react"; + +type Props = { + text: string; +}; + +const CopyButton = ({ text }: Props) => { + return ( +
{name}
-{value}
++ {value < 1000 ? value : (value / 1000).toFixed(1) + "k"} +
++ {value} +
{link.name}
} + + {link.url && ( + <> +{t("link")}
+ +{t("collection")}
+ + +{link.collection.name}
+ + + + {link.tags[0] && ( + <> +{t("tags")}
+{t("notes")}
+ +{link.description}
++ {link.url ? t("preserved_formats") : t("file")} +
+ +{t("preservation_in_queue")}
+{t("check_back_later")}
+{t("there_are_more_formats")}
+{t("check_back_later")}
+{t("view_latest_snapshot")}
+ + + )} +- {t("description")} -
- -- {link.description ? ( - unescapeString(link.description) - ) : ( - - {t("no_description")} - - )} -
- {link.tags && link.tags[0] && ( - <> -- {t("tags")} -
- -- {t("description")} -
- -- {link.description ? ( - unescapeString(link.description) - ) : ( - - {t("no_description")} - - )} -
- {link.tags && link.tags[0] && ( - <> -- {t("tags")} -
- -{t("sharable_link_guide")}
-{name}
{unescapeString(link?.description)}
: undefined}