En construcciónNumori se está construyendo en abierto. Todavía no hay nada en venta y la mayoría de las aplicaciones están sin terminar.Ver qué está listo

UiCodeBlock

A static, copyable code snippet.

Contenido

For code that documents itself rather than runs: install commands, config, imports. A copy button fades in on hover or keyboard focus and confirms with a tick. An optional label renders a filename or language caption across the top. The copy uses the async Clipboard API and fails silently where it is unavailable; the button labels are props, so no language is baked in.

Ejemplos

With a caption

An optional label names the file or language.

Terminal
npm install numori-ui
<UiCodeBlock label="Terminal" code="npm install numori-ui" />

Bare

Without a label, just the snippet and a copy button on hover.

import { UiButton } from 'numori-ui'
<UiCodeBlock code="import { UiButton } from 'numori-ui'" />

Props

NombreTipoPor defectoDescripción
codeobligatoriostringThe snippet text.
labelstring''Optional filename/language caption shown above the block.
copyLabelstring'Copy'Label for the copy button at rest.
copiedLabelstring'Copied'Label shown briefly after a successful copy.