import { Ico, Icon } from "./Ico"; import { ToolTip } from "./ToolTip"; import { cJoin } from "helpers/className"; import { useAtomGetter } from "helpers/atoms"; import { atoms } from "contexts/atoms"; /* * ╭─────────────╮ * ───────────────────────────────────────╯ COMPONENT ╰─────────────────────────────────────────── */ interface Props { id: string; className?: string; } // ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ export const AnchorShare = ({ id, className }: Props): JSX.Element => { const langui = useAtomGetter(atoms.localData.langui); return ( { navigator.clipboard.writeText( `${process.env.NEXT_PUBLIC_URL_SELF + window.location.pathname}#${id}` ); }} /> ); };