generate-type-scale

generate-type-scale is a skill for Claude Code from alvinindra/figma-mcp-rust. It costs 59 tokens per session (896 once invoked), scanned A, original, MIT.

A workflow for creating a set of related text sizes for a Figma design from a base font size and a mathematical ratio. This set covers roles such as display text, headings, body text, labels, captions, and optionally code.

In plain words
What is it for?
It helps calculate sizes and create Figma text styles from a chosen font, body size, and scale ratio, with optional display and monospace code styles.
Why use it?
It replaces ad-hoc font sizing with a consistent typography system across the design.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the figma-mcp-rust plugin — 13 skills, 1 MCP server shipped together

Good fit It helps calculate sizes and create Figma text styles from a chosen font, body size, and scale ratio, with optional display and monospace code styles.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/alvinindra/figma-mcp-rust/generate-type-scale
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add alvinindra/figma-mcp-rust --skill generate-type-scale
Clone the repo
git clone --depth 1 https://github.com/alvinindra/figma-mcp-rust

Made for: Claude Code.

Or install figma-mcp-rust, the plugin that ships this one along with the rest of its 13 skills, 1 MCP server.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for generate-type-scale

README.md
[![agentmods](https://agentmods.dev/badge/skills/alvinindra/figma-mcp-rust/generate-type-scale/github.svg)](https://agentmods.dev/skills/alvinindra/figma-mcp-rust/generate-type-scale)
Your own site
<a href="https://agentmods.dev/skills/alvinindra/figma-mcp-rust/generate-type-scale"><img src="https://agentmods.dev/badge/skills/alvinindra/figma-mcp-rust/generate-type-scale/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for generate-type-scale

Your own site · 80×15
<a href="https://agentmods.dev/skills/alvinindra/figma-mcp-rust/generate-type-scale"><img src="https://agentmods.dev/badge/skills/alvinindra/figma-mcp-rust/generate-type-scale.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 59 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 896 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00059 $0.00896
Opus 5 $0.00030 $0.00448
Sonnet 5 $0.00012 $0.00179
Haiku 4.5 $0.00006 $0.00090

Measured 9d ago against content hash 9e67706d28c9, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

generate-type-scale scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/generate-type-scale/SKILL.md · 62 lines

How it starts

The opening of the file, as written. The whole thing — 62 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Generate Type Scale

Given a base font family and body size, generate a full typographic scale as Figma text styles.

Input

Ask the user for:

  • Font family (e.g. "Inter"), required
  • Base body font size in px (e.g. 16), required
  • Scale ratio: "minor-third" (1.2), "major-third" (1.25), "perfect-fourth" (1.333), "golden" (1.618), default major-third
  • Include display sizes (above H1)? Default no
  • Include mono / code style? Default no

Scale Calculation

Using base size B and ratio R:

Style Name Size formula Weight Line Height Letter Spacing
Display/2XL B x R^7 (px) 700 1.1 -0.02em
Display/XL B x R^6 700 1.1 -0.02em
Heading/H1 B x R^5 700 1.2 -0.01em
Heading/H2 B x R^4 700 1.25 -0.01em
Heading/H3 B x R^3 600 1.3 0
Heading/H4 B x R^2 600 1.35 0
Body/XL B x R^1 400 1.6 0
Body/Base B 400 1.6 0
Body/SM B / R 400 1.5 0
Label/LG B x R^0.5 (px) 500 1.4 +0.01em
Label/Base B 500 1.4 +0.01em
Label/SM B / R 500 1.4 +0.02em
Caption/Base B / R^1.5 (px) 400 1.4 +0.02em
Code/Base B 400 1.6 0 (mono font)

Round all sizes to nearest integer. Minimum size: 10px.

Show the full table to the user for review before creating anything.

Creation Steps

  1. For each style row, call create_text_style() with:
    • name: e.g. "Heading/H1"
    • fontFamily: the chosen font
    • fontStyle: map weight to style name ("Regular"=400, "Medium"=500, "SemiBold"=600, "Bold"=700)
    • fontSize: calculated value
    • lineHeightValue + lineHeightUnit="PIXELS" (convert ratio x size to px)
    • letterSpacingValue + letterSpacingUnit="PERCENT" (convert em to %)

Read the full file on GitHub · 62 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 62 lines · 59 tokens per session scan A 9e67706d28c9

Subscribe to this mod's changes

generate-type-scale is a skill published in the GitHub repository alvinindra/figma-mcp-rust (34 stars, last pushed 4d ago), licensed MIT. It adds 59 tokens to every session and 896 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

clean-interface-design

Design clean, calm, uncluttered interfaces that don't read as templated AI output. Use when building or restyling any UI (web, iOS, Android, macOS) and it needs visual hierarchy, restraint, spacing discipline, one clear primary action, and a cohesive look. Covers accent color, whitespace, corner radius, type scale…

HalidSaglam/saglitzdesign-mcp · 95 tokens

landing-page-conversion

Build or improve landing pages and marketing sites that convert, not just look good. Use when writing a hero, structuring a page, choosing a CTA, adding social proof, or diagnosing why a page isn't converting. Covers positioning, copy-first workflow, the above-the-fold contract, page narrative, CTAs, trust, and…

HalidSaglam/saglitzdesign-mcp · 86 tokens

ship-quality-gate

Run the deterministic auditors over a real project before it ships — design drift, security headers, generated-default tells, SEO/GEO signals, delivery signals, Apple and Android project configuration — and read the results correctly, disclosure list included. Use when someone asks "audit this", "is this ready to…

HalidSaglam/saglitzdesign-mcp · 86 tokens

apple-platform-design

Design iOS, iPadOS, and macOS apps that feel native, in the Liquid Glass era. Use when building or reviewing Apple-platform UI — navigation, controls, sheets, materials, typography, haptics — or deciding what must change when porting from web/Android. Covers Apple's HIG, the Liquid Glass design language (iOS 26 /…

HalidSaglam/saglitzdesign-mcp · 95 tokens

design-system-audit

Find out whether a codebase actually has a design system or is re-deciding the basics on every screen — count the distinct colors, sizes, radii, shadows and spacings, collapse the near-duplicates, and migrate onto tokens. Use when inheriting a codebase, before a redesign, when a UI "feels inconsistent but I can't say…

HalidSaglam/saglitzdesign-mcp · 93 tokens

motion-and-animation

Add motion and animation that feels great, not like slop. Use when animating any UI — transitions, hovers, presses, sheets, drawers, modals, page transitions, gestures — or when an animation feels "off". Covers the easing rules agents get wrong (ease-out for enter, ease-in for exit), springs, interruptibility…

HalidSaglam/saglitzdesign-mcp · 104 tokens