Skip to content
ProLifetime access for $199, paid once, every future release included
Truffle UI

Compliance Badge

ProNew

Badges for SOC 2, ISO 27001, HIPAA, GDPR, PCI DSS, FedRAMP and more, as a seal, a card with the audit date, or an inline pill. Original marks, with an in-progress state that cannot be mistaken for done.

Installation

pnpm dlx shadcn@latest add @viewport/compliance-badge

First time? Add the @viewport registry to components.json. Setup takes one minute.

Usage

The code behind the preview above comes with Truffle Pro.

Props

PropTypeDefault
framework*keyof typeof frameworks

The standard. Each has its own outline, so a row of badges can be told apart by shape.

—
detailstring

A qualifier set under the code, e.g. "Type II" or "Level 1".

—
status"achieved" | "in-progress"

`achieved` is the default. `in-progress` draws a dashed outline and says so; never show a badge as achieved before it is.

"achieved"
datestring

When it was last audited or certified, or when it is expected, already formatted.

—
auditorstring

Who examined it.

—
variant"seal" | "card" | "inline"

`seal` is the mark alone; `card` sets it beside the name, status and date; `inline` is a small pill for footers and tables.

"seal"
sizekeyof typeof sizes"md"
hrefstring

Makes the badge a link, e.g. to the report request or the certificate.

—
classNamestring—

Accessibility

  • Named with the standard, its qualifier, its status and the date.
  • Status is a word and an icon as well as a color; in-progress has a dashed outline.
  • Each standard has its own outline shape.
  • Server component with no client JavaScript.