Design rule results

Supplied board-check violations with severity and status filters, object and location details, and host-confirmed selection and resolution actions.

Reported design rules

Synthetic check run 042

Severity
Result status

2 of 2 results

  • Copper clearance

    Result identifier
    clearance-1
    Severity
    Error
    Confirmed status
    Open
    Rule
    Supplied clearance rule
    Layer
    Front copper
    Net
    Supply
    Location
    X: 24.5, Y: 18; unit: mm
    Objects
    J1 pad 1, Track 17
  • Silkscreen overlap

    Result identifier
    label-2
    Severity
    Warning
    Confirmed status
    Excluded
    Rule
    Not supplied
    Layer
    Front silkscreen
    Net
    Not supplied
    Location
    X: 31, Y: 22.4; unit: mm
    Objects
    J1 reference, J1 outline

Review the board check

Example board / Check run 042

Reported design rules

Synthetic results, revision C

Severity
Result status

2 of 2 results

  • Copper clearance

    The supplied check marks these objects for review.
    Result identifier
    clearance-1
    Severity
    Error
    Confirmed status
    Open
    Rule
    Supplied clearance rule
    Layer
    Front copper
    Net
    Supply
    Location
    X: 24.5, Y: 18; unit: mm
    Objects
    J1 pad 1, Track 17
  • Silkscreen overlap

    Result identifier
    label-2
    Severity
    Warning
    Confirmed status
    Excluded
    Rule
    Supplied text clearance rule
    Layer
    Front silkscreen
    Net
    Not supplied
    Location
    X: 31, Y: 22.4; unit: mm
    Objects
    J1 reference, J1 outline

Select a result to identify the corresponding board objects.

Use it for

  • Reviewing a bounded set of results supplied by a board design-rule checker.
  • Supply unique result ids, the confirmed severity and status, and any available layer, net, object and location records. Null severity or status means unknown.
  • onSelect requests host selection; selectedId confirms it. onResolve requests resolution of an open result unless canResolve is false. Pending and disabled records cannot invoke actions.
  • Use filter and onFilterChange for host-owned filters; uncontrolled filters start from defaultFilter. Named filters submit as name.severity and name.status.

Not for

  • Treating an action click as a resolved board defect or treating an excluded result as resolved.
  • Inferring that an empty result array means a check ran or passed. The component does not run rules, edit the board or invent clearance limits.

Three ways in. They share one source, so the pixels match whichever you pick.

1. Import the package

npm install @noorddev/vlak-react

// once, next to your app's root
import "@noorddev/vlak-react/css";

import { DesignRuleResults } from "@noorddev/vlak-react";

Precompiled React and one stylesheet. No compiler to configure. Per-component imports work too: @noorddev/vlak-react/components/design-rule-results.

2. Vendor the source

npx @noorddev/vlak-cli add design-rule-results

The StyleX leaf lands in components/vlak/ with its dependencies, for your own compiler to own. See StyleX.

3. Through shadcn

npx shadcn add https://vlak.dev/r/design-rule-results.json

The same registry item, installed by shadcn's CLI.

CSS only

<link rel="stylesheet" href="node_modules/@noorddev/vlak/css/vlak.css" />

No React. Link vlak.css and use the markup and classes below.

import { DesignRuleResults } from "@noorddev/vlak-react";

<DesignRuleResults label="Reported design rules" runLabel="Synthetic check run 042" violations={[
  { id: "clearance-1", title: "Copper clearance", severity: "error", status: "open", rule: "Supplied clearance rule", layer: "Front copper", net: "Supply", location: { x: 24.5, y: 18, unit: "mm" }, objects: ["J1 pad 1", "Track 17"] },
  { id: "label-2", title: "Silkscreen overlap", severity: "warning", status: "excluded", layer: "Front silkscreen", objects: ["J1 reference", "J1 outline"] },
]} />

DesignRuleResults

Supplied rule-check outcomes with local or controlled filters and host-confirmed actions.

PropTypeDefaultDescription
labelrequiredReactNode
violationsrequiredreadonly DesignRuleViolation[]
filterDesignRuleFilter
defaultFilterDesignRuleFilterinitial
onFilterChange(filter: DesignRuleFilter) => void
selectedIdstring | null
onSelect(id: string) => voidRequests selection in the host board viewer; selectedId remains host-owned.
onResolve(id: string) => voidRequests resolution of an open result. Confirmed status never changes locally.
runLabelReactNode
descriptionReactNode

Also accepts Omit<FieldsetHTMLAttributes<HTMLFieldSetElement>, "onSelect">.

KeysDoes
TabMoves through the Vlak filter selectors and available action buttons.
Arrow keys, Home, EndNavigates a focused filter's choices.
Enter, SpaceChooses a filter or requests the focused selection or resolution action.
EscapeCloses an open filter selector.
<fieldset class="rs-design-rule-results"><legend class="rs-design-rule-results-legend">Reported design rules</legend><p class="rs-design-rule-results-note">Synthetic check run 042</p><ul class="rs-design-rule-results-list"><li class="rs-design-rule-results-item"><p class="rs-design-rule-results-title">Copper clearance</p><dl class="rs-design-rule-results-properties"><div><dt class="rs-design-rule-results-term">Severity</dt><dd class="rs-design-rule-results-detail">Error</dd></div><div><dt class="rs-design-rule-results-term">Confirmed status</dt><dd class="rs-design-rule-results-detail">Open</dd></div><div><dt class="rs-design-rule-results-term">Layer</dt><dd class="rs-design-rule-results-detail">Front copper</dd></div><div><dt class="rs-design-rule-results-term">Location</dt><dd class="rs-design-rule-results-detail">X: 24.5, Y: 18; unit: mm</dd></div></dl></li></ul></fieldset>
.rs-design-rule-results.rs-design-rule-results-legend.rs-design-rule-results-filters.rs-design-rule-results-label.rs-design-rule-results-control.rs-design-rule-results-list.rs-design-rule-results-item.rs-design-rule-results-selected.rs-design-rule-results-title.rs-design-rule-results-properties.rs-design-rule-results-term.rs-design-rule-results-detail.rs-design-rule-results-actions.rs-design-rule-results-action.rs-design-rule-results-note