devpage 0.2.2

Live documents from a repository: sites, docs and slides from Markdown, and UI designs drawn from code — with comments, link checking and PDF
1
2
3
4
5
6
7
8
// Keys as keycaps, inline: <Keys>⌘ P</Keys>.
export default function Keys({ source }: { source: string }) {
  return (
    <span className="keys">
      {source.trim().split(/\s+/).map((key) => <kbd>{key}</kbd>)}
    </span>
  );
}