Network map

A hub joined to its nodes; done nodes fill in and their links go solid, the rest stay hollow and dashed.

HubDoneNextLater

Features

  • A hub and its nodes in SVG; done nodes fill and their links go solid.
  • Labelled, every node is a link that says whether it is done; bare, it is a decorative glyph.
  • Strokes keep their width at any size.

Use it for

  • Progress through a site or a course.
  • A small network diagram.

On this site

Installation

  1. Get runets.
    git clone https://github.com/ziyam-khan/runets
  2. Copy these files into your project, keeping their folders.
  3. Install what they use.
    pnpm add react
  4. Load the styles once. Bring your own base tokens, or use runets’ default theme.
    import 'runets/styles/theme.css'
    import 'runets/styles/kit.css'

API

PropTypeWhat it does
hub / nodes{ id, label, href?, at, done?, labelAt? }at and labelAt are in view-box units.
labelledbooleanLabels and links.
viewBoxstringThe drawing's frame.

Accessibility

Source

The code is in src/kit/network-map.tsx in runets, MIT licensed.