Code inside a sentence: mono a step smaller than the words around it, on a muted chip with a hairline. Long tokens break instead of pushing the line out.
The component itself, ready to drop into your project. Switch between React, Vue and plain HTML; every version uses the same Tailwind classes on Ochre's tokens.
Keys with the service_role scope skip row-level security, so keep them on the server. Set NORTHWIND_KEY in your environment and never in next.config.ts.
components/ochre/inline-code.tsx
import * as React from "react";import { cx } from "@/components/ochre/utils";// Code inside a sentence: mono at a step under the text around it, on a muted chip with a hairline.// It never wraps inside a token, and long ones break rather than push the line out.export function InlineCode({ className, ...rest }: React.HTMLAttributes<HTMLElement>) { return ( <code {...rest} className={cx( "rounded-6 border border-border-subtle bg-surface-muted px-[0.4em] py-[0.1em] font-mono text-[0.875em] font-medium text-text-strong [overflow-wrap:anywhere] [box-decoration-break:clone]", className, )} /> );}
With the @ochre registry set up, one command adds the component and what it imports (utils). Or copy the code above into components/ochre/inline-code.tsx.
import { Field } from "@/components/ochre/field";import { Input } from "@/components/ochre/input";import { InlineCode } from "@/components/ochre/inline-code";export default function InlineCodeHint() { return ( <div className="w-full max-w-[320px]"> <Field label="Webhook secret" hint={<>Sent as <InlineCode>X-Northwind-Signature</InlineCode> on every call.</>}> <Input placeholder="whsec_…" /> </Field> </div> );}