BlockDex

Components

Registries

Free blocks

Method

BlockDex

Components

Registries

Free blocks

Method

Open API

BlockDex

Components

Registries

Free blocks

Method

Open API

Components/inferencesh/pretext-md

pretext-md

inferencesh/pretext-md
FreeBlock

Measured markdown renderer powered by pretext. DOM-free text measurement, plugin architecture, virtualizable.

Install it

npx shadcn@latest add https://ui.inference.sh/r/pretext-md.json

Source

lib/pretext-md/react/context.tsxui.inference.sh/r/pretext-md.json
1'use client'
2
3import { createContext, useContext } from 'react'
4import type { FontConfig, LineHeightConfig } from '../core/types'
5
6export type PretextMdConfig = {
7 fonts: FontConfig
8 lineHeights: LineHeightConfig
9}
10
11// Font strings use rem matching the app theme scale (--text-sm: 0.9rem, etc.).
12// The inline layout engine resolves rem→px before passing to canvas measureText.
13const defaultFonts: FontConfig = {
14 body: '0.9rem "Mona Sans", sans-serif',
15 bold: 'bold 0.9rem "Mona Sans", sans-serif',
16 italic: 'italic 0.9rem "Mona Sans", sans-serif',
17 boldItalic: 'bold italic 0.9rem "Mona Sans", sans-serif',
18 code: '0.8rem "DM Mono", "Fira Code", monospace',
19 h1: '1.8rem "Sentient", serif',
20 h2: '1.5rem "Sentient", serif',
21 h3: '1.15rem "Sentient", serif',
22 h4: '0.9rem "Sentient", serif',
23 h5: '0.8rem "Sentient", serif',
24 h6: '0.8rem "Sentient", serif',
25}
26
27const defaultLineHeights: LineHeightConfig = {
28 body: 20,
29 code: 18,
30 h1: 32,
31 h2: 28,
32 h3: 24,
33 h4: 20,
34 h5: 20,
35 h6: 18,
36}
37
38export const defaultConfig: PretextMdConfig = {
39 fonts: defaultFonts,
40 lineHeights: defaultLineHeights,
41}
42
43export const PretextMdContext = createContext<PretextMdConfig>(defaultConfig)
44
45export function usePretextMdConfig(): PretextMdConfig {
46 return useContext(PretextMdContext)
47}

What it pulls in

npm packages

  • @chenglou/pretext
  • unified
  • remark-parse
  • remark-gfm

Other registry items

  • https://inference.sh/ui/r/code-block.json
  • https://inference.sh/ui/r/youtube-embed.json
  • https://inference.sh/ui/r/zoomable-image.json

Facts

Registry
inferencesh
Type
registry:block
Access
Free
Files written
0
Licence
the repository states none
In the index
at or before 2026-08-13
Last confirmed
today

Go to the source

ui.inference.sh Raw registry item This item as JSON

More from inferencesh

All 14 items
Same registry, same kind — the ones you would have found next
ComponentRegistryKindAccessInstallsCommand
Agent ChatagentinferenceshBlocksFree1 dep
Chat UI PrimitiveschatinferenceshBlocksFree1 dep
Code Blockcode-blockinferenceshBlocksFreeno deps
Markdown Renderer (legacy)markdowninferenceshBlocksFree2 deps
Sidebar Lightsidebar-lightinferenceshBlocksFreeno deps
StepsstepsinferenceshBlocksFreeno deps
Table of Contentstable-of-contentsinferenceshBlocksFreeno deps
TasktaskinferenceshBlocksFree1 dep

Also from Kynth Studios

Built for the same person as BlockDex

SkillWorks

Claude Code skills and plugins, scored

skillworks.kynth.studio

RuleStack

AGENTS.md gallery and agent-config comparison

rulestack.kynth.studio

ToolDrift

What the AI coding tools changed last night

tooldrift.kynth.studio

The studio list

One product, taken apart, once a month

Kynth Studios pulls one shipped product open every month — what it does, what it cost to build, what the pipeline behind it looks like, and what the numbers did. One email a month, nothing in between.

Double opt-in — we send one confirmation link and nothing else until you click it.

BlockDex

Built by

Kynth Studios

the studio behind SkillWorks, RuleStack and ToolDrift

part of Toolproof, the measurement layer for AI agent tooling

Index

Components
Registries
Method
Open API

Guides

shadcn component libraries
Best shadcn registries
Free shadcn blocks

Reference

Corpus counts
Crawl health
hello@kynth.studio
Privacy
Terms

© 2026 BlockDex. A Kynth Studios product. Changelog

BlockDex

The studio list

One product, taken apart, once a month

Kynth Studios pulls one shipped product open every month — what it does, what it cost to build, what the pipeline behind it looks like, and what the numbers did. One email a month, nothing in between.

Double opt-in — we send one confirmation link and nothing else until you click it.

BlockDex

Built by

Kynth Studios

the studio behind SkillWorks, RuleStack and ToolDrift

part of Toolproof, the measurement layer for AI agent tooling

Index

Components
Registries
Method
Open API

Guides

shadcn component libraries
Best shadcn registries
Free shadcn blocks

Reference

Corpus counts
Crawl health
hello@kynth.studio
Privacy
Terms

© 2026 BlockDex. A Kynth Studios product. Changelog

BlockDex

The studio list

One product, taken apart, once a month

Kynth Studios pulls one shipped product open every month — what it does, what it cost to build, what the pipeline behind it looks like, and what the numbers did. One email a month, nothing in between.

Double opt-in — we send one confirmation link and nothing else until you click it.

BlockDex

Built by

Kynth Studios

the studio behind SkillWorks, RuleStack and ToolDrift

part of Toolproof, the measurement layer for AI agent tooling

Index

Components
Registries
Method
Open API

Guides

shadcn component libraries
Best shadcn registries
Free shadcn blocks

Reference

Corpus counts
Crawl health
hello@kynth.studio
Privacy
Terms

© 2026 BlockDex. A Kynth Studios product. Changelog

BlockDex