TypeScale MCP
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@TypeScale MCP generate Arabic RTL design tokens for 360–1440px, export CSS and Flutter"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
TypeScale MCP
A reference system for type and space that adapts to the interface.
SPECIMEN 01 — The responsive scale
Type should carry the structure of a page. TypeScale calculates fluid font sizes, spacing, corner radii and target sizes, with support for English and Arabic typography. The output is intended for design systems, web CSS, and Flutter interfaces.
The default specimen
Role | At 360px | At 1440px |
Caption | 12.098 | 12.098 |
Small | 13.913 | 14.4 |
Body | 16 | 18 |
H6 | 18.4 | 22.5 |
H5 | 21.16 | 28.125 |
H4 | 24.334 | 35.156 |
H3 | 27.984 | 43.945 |
H2 | 32.182 | 54.932 |
H1 | 37.009 | 68.665 |
Values shown in CSS pixels using the default viewport range and 16px rem baseline. These are computed values, not measurements of drawn text in the specimen illustration.
System | Text | Space |
English & Arabic, LTR/RTL | Nine type roles; fluid CSS | Spacing, radii, control padding, touch targets |
Node.js 20+; MCP stdio | Font and line-height guidance | CSS, JSON, Flutter-friendly tokens |
Local by design. The two read-only tools perform deterministic numerical computation. They do not read project files, make network calls or execute commands. Setup requires installing dependencies.
01 / Installation
Requires Node.js 20 or newer.
git clone https://github.com/ahmedsaeed1-eng/typescale-mcp.git
cd typescale-mcp
npm ci
npm testThe npm install step obtains dependencies from the package registry; server requests themselves never use a network interface.
Related MCP server: Ensemble MCP
02 / Connect to Codex
From the repository directory run:
codex mcp add typescale -- node /absolute/path/to/typescale-mcp/src/server.jsUse the actual absolute path to your checkout. On Windows use the absolute Windows path in quotes if it contains spaces. Run codex mcp list to confirm registration.
Equivalent configuration in Codex's MCP settings:
[mcp_servers.typescale]
command = "node"
args = ["/absolute/path/to/typescale-mcp/src/server.js"]The command starts an MCP service communicating on stdin/stdout. It is not an interactive terminal prompt.
03 / Tool reference
Name | Purpose |
| Generate fluid typography, spacing, radii, target sizes and layout tokens |
| Return typography and direction guidance for an English or Arabic interface |
Example prompt for Codex:
Use TypeScale to generate Arabic RTL design tokens at 360–1440px viewport widths. Keep body text readable and controls comfortable. Show CSS variables and the Flutter mapping.
Example arguments for generate_design_tokens:
{"locale":"ar","baseMin":16,"baseMax":18,"ratioMin":1.15,"ratioMax":1.25,"viewportMin":360,"viewportMax":1440,"spacingUnit":4,"density":"comfortable","format":"all"}Parameter | Accepted range or value | Default |
baseMin / baseMax | 14–24 px; max >= min | 16 / 18 |
ratioMin / ratioMax | 1.01–1.333; max >= min | 1.15 / 1.25 |
viewportMin | 280–1440 px, integer | 360 |
viewportMax | 320–2560 px, integer, > min | 1440 |
spacingUnit | 2–8 px, integer | 4 |
density | compact, comfortable | comfortable |
locale | en, ar | en |
format | json, css, flutter, all | all |
All inputs are optional. The recommendation tool accepts locale only.
04 / Apply the scale
Use the returned CSS custom property definitions, then reference them in project styles:
body {
font-family: var(--font-family);
font-size: var(--type-body);
line-height: var(--line-height-body);
}
h1 {
font-size: var(--type-h1);
line-height: var(--line-height-heading);
}
button {
min-block-size: var(--touch-recommended);
padding-block: var(--control-padding-block);
padding-inline: var(--control-padding-inline);
}Set lang="ar" and dir="rtl" on the relevant Arabic document or subtree. The tool provides tokens only; this CSS does not apply itself.
05 / Design notes and limitations
Font sizes scale geometrically at both viewport bounds, then interpolate using CSS clamp(). The smallest caption is bounded at a 12px design size; scale roles may intentionally coincide in low-ratio designs. A user-configurable browser root font size changes the interpretation of rem units; do not override it to force the example baseline.
The Flutter mapping is JSON with min/max logical-pixel font sizes and line-height multipliers. Applications must apply responsive interpolation themselves and respect platform text scaling. No actual Flutter source is generated.
Targets of 44px and 48px are recommended design defaults, not guarantees of accessibility. Test the rendered interface for contrast, text zoom, hit areas, wrapping and multilingual glyphs. Font stacks are suggestions, not distributed font files. No browser, font or rendered layout measurement is performed.
06 / Development
npm testThe suite tests deterministic calculations, range validation, Arabic guidance, format outputs, target sizes, and both tools via the official MCP client and a real stdio connection. CI is configured for Node 20 and 22 across Linux, macOS and Windows.
Colophon
MIT. See LICENSE and THIRD_PARTY.md.
Available Tools
2 toolsgenerate_design_tokensBRead-onlyIdempotent
Generate fluid CSS typography, spacing, radius, touch-target and platform design tokens. All settings optional.
Inputs: format, locale, baseMax, baseMin, +6 more.
typography_recommendationsARead-onlyIdempotent
Get English or Arabic interface font fallback, RTL and typography guidance.
Inputs: locale.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 2 tools
The two tools have clearly distinct actions: one generates concrete design tokens, the other returns advisory font/typography guidance. An agent can easily tell which to call based on whether it needs output tokens or recommendations.
Both names use snake_case, but the patterns differ: generate_design_tokens is verb-led while typography_recommendations is a noun phrase. Readable, but not a predictable single convention.
Two tools is borderline thin for a design-token server; generation and guidance cover the basics, but the surface feels minimal. It is not extreme, just under-scoped.
Core generation and typography advice are present, but notable gaps exist: no token export/format conversion, no preview or validation, and no theme/update lifecycle. Agents must work around these for full design-system workflows.
Maintenance
Related MCP Connectors
Generate design systems: OKLCH colors, fluid type scales, spacing, shape, icon and motion tokens.
Build and manage your design system with AI: tokens, themes, components, icons, Figma and code.
Give your agent a real design system: tokens, measured WCAG contrast, and rules to follow.
Provides style context & tokens to design or restyle web UIs in any framework
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceProvides access to a universal design token system with 7 pre-built themes (colors, typography, spacing, motion) and multi-format export capabilities for Canva, Remotion, PPTX, CSS, and W3C JSON.1MIT
- AlicenseAqualityCmaintenanceEnables AI agents to generate complete, deterministic design systems from a single brand color — harmonious palettes, font pairings, type and spacing scales, elevation shadows, responsive grids, motion presets, dark-mode themes, and WCAG contrast audits — and export them as CSS, JSON, Tailwind, or SCSS through natural conversation.1060 npmMIT
- AlicenseBqualityBmaintenanceEnables AI coding agents to absorb UI references into perceptual design tokens, semantic responsive layout skeletons, motion physics parameters, and zero-dependency multi-framework components, while auditing WCAG contrast, touch targets, reduced-motion guardrails, and layout stability.6MIT
- AlicenseAqualityBmaintenanceTurns a short brief — a brand color and a style — into a complete, contrast-checked design system and emits it as CSS variables, a Tailwind v4 theme, SCSS, TypeScript, W3C design tokens and a DESIGN.md. Agents can create, update, audit and re-emit tokens deterministically so UI is built from tokens rather than hard-coded values.664 npmMIT