Skip to main content

atoms

Hanko

The brand mark, an inlined SVG in a span whose colour and size come from the caller's classes.

Specimens

Default Sample artwork stands in for the brand SVG that the site inlines from Sanity.
{{ Hanko.render({
  svg: '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><circle cx="12" cy="12" r="10"/><path d="M8 8h8v8H8z" fill="#000"/></svg>'
}) }}
Sized and coloured
{{ Hanko.render({
  classes: "inline-block w-24 text-primary-400",
  svg: '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><circle cx="12" cy="12" r="10"/><path d="M8 8h8v8H8z" fill="#000"/></svg>'
}) }}

Params

ParamTypeDescription
svgstringInlined SVG markup, output with safe.
classesstringApplied as-is to the wrapper <span>. Defaults to inline-block w-12 text-secondary-700. No classes filter.
attrsstringRaw attributes added to the wrapper <span>. Defaults to empty.