Graph

Caption drawn on the top edge as [ TITLE ]. Uppercase, 1–2 words.

Import

svelte
import { Graph } from 'markgraphy';

Basic usage

svelte
<Graph
  title="example"
  corner={'+'}
  dash={'token'}
/>
[ example ]

Props

PropTypeDefaultDescription
title?stringCaption drawn on the top edge as [ TITLE ]. Uppercase, 1–2 words.
corner?string'+'Character at each corner of the frame. Default ”+“.
dash?GraphDash'token'Dash rhythm. Default ‘token’ (follows --graph-framer).
motion?GraphMotion'none'Frame motion. Every loop is off under prefers-reduced-motion. Default ‘none’.
speed?numberSeconds per motion cycle — for draw, the hover duration.
Defaults per motion (draw 0.3, march 0.7, pulse 2, scan 3).
easing?EasingCurve the motion runs on — an EASINGS name or a raw timing function.
pauseOnHover?booleanfalsePause the loop while hovered. Default false.
cornerBlink?booleanfalseBlink the corner glyphs. Default false.
pad?GraphPad'none'Inner padding. Default ‘none’.
ink?stringFrame colour override. Defaults to --text-primary.
accent?stringCorner + title colour override. Defaults to --graph-accent.
class?string''
children?Snippet

Exported types

  • GraphDash
  • GraphMotion
  • GraphPad