Migrates consumer projects to the new Entur typography (`@entur/typography/beta`) and layout beta spacing scale. Covers renamed spacing values, text components, CSS overrides, and removal of old components.
Ships in entur-linje. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description, though model invocation is off: only you can start it.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
The new typography is Heading, Text, Link, Label, TextContainer and the lists from @entur/typography/beta. It shares the spacing scale 2xs | xs | s | m | lg | xl | 2xl … with Flex and Grid in @entur/layout/beta.
Find what the project uses. Set SRC to the folders with source code (in a monorepo, every package), and keep the globs quoted:
SRC="src"
CODE=(--include='*.tsx' --include='*.ts' --include='*.jsx' --include='*.js' --exclude-dir=node_modules)
grep -rnE "@entur/typography/beta['\"]" "${CODE[@]}" $SRC
grep -rnE "from ['\"]@entur/typography['\"]" "${CODE[@]}" $SRC
grep -rnE "@entur/layout/beta['\"]" "${CODE[@]}" $SRC
grep -rnE "eds-(text|heading|paragraph|h[1-6]|lead-paragraph|sub-paragraph|small-text|label|sub-label|link|code-text|preformatted-text|strong-text|emphasized-text|blockquote|list-item|unordered-list|numbered-list)\b|var\(--(2xs|xs|s|s-m|m|m-l|l|[0-9]*xl)\)" --include='*.css' --include='*.scss' --include='*.less' "${CODE[@]}" $SRC
Report: files using the beta typography, files using the old components, files using layout beta Flex/Grid spacing, and CSS that targets typography classes or the old spacing variables. Note aliased imports (Link as LinkText, ListItem as LI), since later greps on component names miss them.
Done when: each of the four groups is listed with a count. Skip the steps for groups that are empty.
Upgrade @entur/typography, @entur/layout and @entur/tokens to the latest versions in one command, together with any other @entur/* package that depends on them. Import @entur/typography/beta/styles next to @entur/typography/styles, where the app imports its other styles.
Done when: the packages are on the latest version, the project installs and the beta styles are imported.
Load references/spacing.md, sections "Rename". Rename spacing on typography components, gap/rowGap/columnGap on Flex and Grid imported from @entur/layout/beta, and the spacing CSS variables. Leave gap on other libraries' components alone. If the project already has new values (3xl and up, --spacing-*, spacing={{ top }}), it is partly migrated: rename only the code that still has old values, and ask the user where you can't tell.
Some names exist both before and after but mean a different size, so rename in one pass, highest value first. Never search-and-replace one value at a time.
Done when: no old value is left (xs2, sm, md, *-top, *-bottom, s-m, m-l, l, --m …) and every lg/xl and larger has been checked against the table.
Load references/beta-changes.md and work through each section that applies: removed margin, renamed variants, variant="link", Blockquote, new HTML elements and Label, weight, size, lists and CSS class names.
Done when: every pattern in beta-changes.md has been searched for and resolved, and the type-check passes.
Text components no longer have margins. Load references/spacing.md, section "No default spacing", and go through every place that relied on the old margins:
<TextContainer>. The rhythm only reaches direct children, so wrap the element whose children are the text blocks.spacing="none", which is now the default. Where two texts relied on the old margin (a title and a description), use Flex with gap, or spacing on one of them.padding-top: 0, a none token), the text now touches the edge. Move the space to the container's padding. Check the visible edge too: a background or border that doesn't start at the container's edge (an absolutely positioned background without top: 0) was hidden by the old margin and now cuts through the text. Step 1 doesn't find this CSS, since it doesn't target typography.Done when: every text component without spacing has been classified, and the uncertain ones are listed.
Only if the user wants it, or the project already mixes old and new: load references/legacy-components.md and replace Heading1–Heading6, Paragraph, CodeText and the rest. Step 5 applies to the replaced components too, since the old ones had margins.
Done when: no imports of the old components remain from @entur/typography, or the user chose to keep them.
For each override from step 1, check it against "CSS class names" in references/beta-changes.md, and against the old class names in references/legacy-components.md if step 6 was done. Selectors for old classes stop matching without any error.
Margin resets (margin: 0), line-height fixes on ListItem, custom code text: remove.
Margins that add space (margin-top: 3rem on a heading): move to spacing on the component, or to gap on its layout.
Inline style with margin: move to spacing. With fontWeight: move to weight on Text. Headings are already bold, so remove fontWeight: 600 on Heading and ask the user about 500, which is not a heading style. Remove it on Link and Label, which follow their own style.
Colours and the rest: rename the selector.
Global element rules and resets, also ones that never targeted typography: they now win over the new components (see "CSS class names" in beta-changes.md). Find them, including CSS-in-JS globals (createGlobalStyle, Global):
grep -rnE "^(\*|a|p|h[1-6]|ul|ol|li|blockquote|code|pre|label|figure|figcaption)(\s*[,{]|:[a-z]|\s*$)" --include='*.css' --include='*.scss' --include='*.less' "${CODE[@]}" $SRC
It only finds rules at the start of a line. Rules nested in a class in SCSS (.header { a { … } }) are scoped and fine. Remove what the components now cover. Move the rest: resets into @layer core.reset, element styles into @layer core.base, with the layer order lines first in the app's first stylesheet. The recipe is in the CSS layers guide, section "The beta typography and your global CSS".
Done when: every override has been kept, renamed or removed, with a reason, and no unlayered global rule hits *, a, p, headings, lists, figure or code.
Run the project's own type check, build and tests: the scripts in package.json, with the project's package manager (look for yarn.lock, pnpm-lock.yaml or package-lock.json). If there is no type-check script but typescript is installed, run npx --no tsc --noEmit. --no stops npx from downloading anything when the compiler is missing.
Then search for leftovers:
grep -rnE "variant=['\"](code-text|preformatted-text|link)['\"]|spacing=['\"](xs2|sm|md|[a-z0-9]+-(top|bottom))['\"]" "${CODE[@]}" $SRC
# No margin or external on the new components. Skip matches on old components from @entur/typography, which still take them
grep -rnE "<(Heading|Text|Link)\b[^>]*margin=|<Link\b[^>]*\bexternal\b" "${CODE[@]}" $SRC
Then look at the pages with the most text and the most UI text in the browser, in each data-view-mode the project uses. No space between texts in a TextContainer, a double underline on links or headings that ignore variant mean a global rule from step 7 still wins. In development the console then shows a warning starting with @entur/typography: global CSS in your app that names the rules.
Check the page language too. Long words in text and headings only break with a hyphen when the page has a Norwegian lang. Find where the app sets it (index.html, the root layout or the framework's HTML attributes):
grep -rnE "<html[^>]*lang=|htmlAttributes|setHtmlAttributes|documentElement\.lang" "${CODE[@]}" --include='*.html' .
nb, nn or no: nothing to do.lang only if they want it. Ask which language the site is in, never assume Norwegian, and leave a site in another language alone. Mention that WCAG 2.1 success criterion 3.1.1 Language of Page (level A) requires the page language in the code, so screen readers pronounce the text correctly.Done when: build, type-check and tests pass, the grep finds nothing, the user has seen the key pages and has decided on the page language.
Tell the user:
size now always overriding variant;TextContainer, Label, trim, NumberedList variant="steps".Done when: the user has the list.
What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
6 skills in this plugin
/entur-accessibilityBuild accessible Entur web applications that comply with WCAG 2.1 and Norwegian universell utforming (UU) requirements. Use when the user is working on accessibility, asking about WCAG, universell utforming, screen readers, keyboard navigation, focus management, color contrast, aria attributes, semantic HTML, or Norwegian IKT accessibility regulation. Also trigger when building @entur/* applications that need to meet legal compliance requirements — all Entur digital products must comply with WCAG 2.1. Use even if the user just says "make this accessible" or "is this accessible" without mentioning WCAG by name./entur-brand-designApply Entur's visual identity correctly in designs, presentations, data visualizations, and web UI. Use when the user asks about Entur colors, Entur branding, Entur typography, Entur data visualization, creating charts or graphs for Entur, making a presentation that looks like Entur, building a branded web page or document for Entur, or anything that should follow Entur's visual identity. Trigger even if the user doesn't say "design system" — if they mention Entur and are making something visual, this skill applies./entur-linjeEntur Linje design system — use when building anything with @entur/* React components, Entur branding, Entur tokens, Entur colors, Entur typography, Entur data visualization, Entur accessibility, or universell utforming (UU). Trigger for any question or task involving the Entur design system, Entur's visual identity, Entur transport UI, or compliance with Norwegian accessibility law (WCAG). Use this skill whenever the user mentions Entur in a design, development, or content context — even if they don't specifically say "design system."/entur-web-developmentBuild React applications with Entur Linje @entur/* component packages. Use when the user is installing, importing, or using any @entur/* package, asking about Entur React components, Entur tokens, Entur CSS variables, Entur design system in a development context, or building web UI that should follow Entur's component library. Trigger for any code task involving @entur/button, @entur/form, @entur/tokens, @entur/typography, @entur/travel, or any other @entur/* package — even if the user just describes wanting to build something that fits Entur's look and feel in React./migrate-react-18Upgrade a consumer project from @entur/* versions that still accept React 16 or 17 to the majors that require React 18. Covers breaking changes (ESM exports, modal, tabs, expand, layout, utils) and verifies the project meets the React 18 minimum. Use when a project on the pre-React 18 @entur/* versions upgrades. For later breaking changes, use the migration guide in entur-web-development./entur-linje:migrate-typographyfrom entur-linje
entur-linje@entur is listed by entur/ai — review the source before installing
npx claudepluginhub entur/ai --plugin entur-linje