diff --git a/src/routes/calc/path.tsx b/src/routes/calc/path.tsx index 71ffdf0..4ba4803 100644 --- a/src/routes/calc/path.tsx +++ b/src/routes/calc/path.tsx @@ -36,6 +36,27 @@ function CopyFormattedButton(props: { path: PathStep[] }) { navigator.clipboard.writeText(text).catch(() => alert("Failed to copy :(")); } + function copyFormattedCompact() { + function connTypeToSymbol(connType: ConnType) { + switch (connType) { + case "npc_gate": + return "G"; + case "smart_gate": + return "S"; + case "jump": + return "J"; + } + } + const text = props.path + .map( + (p) => + `${connTypeToSymbol(p.conn_type)}→ ${p.to.name.substring(0, 4)}`, + ) + .join(" -"); + + navigator.clipboard.writeText(text).catch(() => alert("Failed to copy :(")); + } + return ( <> + (If you paste with EVE-Links into an in-game notepad, you get clickable links)