Records
Render product-owned DNS requirements as a readable table with observation evidence or as a copyable and downloadable zone file.
The records namespace presents product-owned DNS requirements and optional observation evidence. It does not read DNS or decide whether the product is ready.
import { Records } from "@domainkit/react";
export function DnsRecords() {
return (
<>
<Records.ZoneFile domain="mail.example.com" records={records} />
<Records.Table evidence={evidence} records={records} />
</>
);
}Installation
Install the packaged React components:
npm install @domainkit/react domainkit effect @effect/atom-react react react-dompnpm add @domainkit/react domainkit effect @effect/atom-react react react-domyarn add @domainkit/react domainkit effect @effect/atom-react react react-dombun add @domainkit/react domainkit effect @effect/atom-react react react-domFor model-free, copied presentation components, install the matching registry items:
npx shadcn@latest add https://domain-kit.dev/r/dns-table.json https://domain-kit.dev/r/copy-value.json https://domain-kit.dev/r/dns-status.jsonpnpm dlx shadcn@latest add https://domain-kit.dev/r/dns-table.json https://domain-kit.dev/r/copy-value.json https://domain-kit.dev/r/dns-status.jsonyarn dlx shadcn@latest add https://domain-kit.dev/r/dns-table.json https://domain-kit.dev/r/copy-value.json https://domain-kit.dev/r/dns-status.jsonbunx shadcn@latest add https://domain-kit.dev/r/dns-table.json https://domain-kit.dev/r/copy-value.json https://domain-kit.dev/r/dns-status.jsonThe registry components accept plain props and do not include DomainKit transport, planning, or observation models.
Table
Records.Table renders type, name, value, priority, and—when supplied—matching evidence. Evidence
is grouped by recordId; provider and public-DNS observations can therefore be shown without
collapsing them into one readiness boolean.
<Records.Table records={records} evidence={observation.publicDns} />
Zone file
Records.ZoneFile serializes the same records for clipboard and download actions. Browser-only
clipboard and download behavior runs from user interaction, so the component can still render on
the server.
<Records.ZoneFile domain={domain} records={records} />
Accessibility
Copy and download controls have action-specific accessible labels. Preserve those labels when supplying custom icons. Keep the table header cells and visible status text when composing lower level record parts.
API reference
Records.Table
copiedIcon?ReactNode
Optional icon shown after a value has been copied.
ReactNodecopyIcon?ReactNode
Optional icon shown for a copy action.
ReactNodeevidence?ReadonlyArray<Transport.ObservationEvidence>
Optional provider or public-DNS evidence grouped by record ID.
ReadonlyArray<Transport.ObservationEvidence>recordsReadonlyArray<Transport.DnsRecord>
DNS records to render as table rows.
ReadonlyArray<Transport.DnsRecord>Records.ZoneFile
copiedIcon?ReactNode
Optional icon shown after the zone file has been copied.
ReactNodecopiedLabel?string
Accessible label shown after copying the zone file.
string"Copied"copyIcon?ReactNode
Optional icon shown for the copy action.
ReactNodecopyLabel?string
Visible and accessible label for copying the zone file.
string"Copy zone"domainstring
Domain used to name the downloaded zone file.
stringdownloadIcon?ReactNode
Optional icon shown for the download action.
ReactNodedownloadLabel?string
Visible and accessible label for downloading the zone file.
string"Download"recordsReadonlyArray<Transport.DnsRecord>
DNS records serialized into the zone file.
ReadonlyArray<Transport.DnsRecord>Records.CopyValue
copiedIcon?ReactNode
Optional icon shown after the value has been copied.
ReactNodecopiedLabel?string
Accessible action label shown after copying.
string"Copied"copyIcon?ReactNode
Optional icon shown for the copy action.
ReactNodecopyLabel?string
Accessible action label shown before copying.
string"Copy"valuestring
Text displayed and copied after the user activates the action.
stringRead Observe DNS for the difference between provider readback and public DNS propagation.