Skip to content

Data display

Inline code

A code in running text, in the mono face: a refusal's code, an identifier.

Refused: TENANT_MEMBER_CHANGE_NOT_ALLOWED (409). Nothing changed.

Installation

Terminal
pnpm add @elsikora/keystone-ui-kit

Usage

Import
import { InlineCode } from "@elsikora/keystone-ui-kit";
docs/inline-code/default.example.tsx
import { InlineCode } from "@elsikora/keystone-ui-kit";
export default function InlineCodeDefaultExample() {  return (    <p className="max-w-56">      Refused: <InlineCode>TENANT_MEMBER_CHANGE_NOT_ALLOWED</InlineCode> (409). Nothing changed.    </p>  );}

Examples

Default

In a narrow column the code breaks only after an underscore, never inside a word.

Refused: TENANT_MEMBER_CHANGE_NOT_ALLOWED (409). Nothing changed.

API reference

InlineCode

PropTypeDefaultDescription
childrenstring-The code.

Notes

  • For a code in a sentence; a block of code to read or copy is a code block.
  • Its text is the code as the platform answers it; the sentence beside it says what it means.