Alignment logo

Alignment

Community
Deibler
alignment

Use this skill whenever the design has more than one element on the page — every layout, every form, every table, every page header, every card. Trigger when designing a layout, picking a grid, fixing a UI that "looks off," debating left vs. center alignment for body text, or auditing why a design feels disorderly. Alignment is one of the most foundational principles in 'Universal Principles of Design' (Lidwell, Holden, Butler 2003) — every visible element's edge or center should fall on a shared axis with at least one other element. Misalignment by even a few pixels reads as disorder.

Overview

PublisherDeibler
Repositoryuniversal-design-principles
Skill namealignment
Stars
9
Forks
3
Bundled files
1
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 1 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by Deibler on GitHub. Read the source before you install it.

Installation

Install the Alignment AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/Deibler/universal-design-principles/tree/main/plugins/perception-and-hierarchy-principles/skills/alignment
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/Deibler/universal-design-principles.git /tmp/universal-design-principles
mkdir -p .claude/skills
cp -r /tmp/universal-design-principles/plugins/perception-and-hierarchy-principles/skills/alignment .claude/skills/alignment
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Alignment in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Alignment on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Alignment is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Alignment

Alignment is the placement of elements so that their edges or centers fall on shared axes — invisible vertical or horizontal lines that thread through the composition. Aligned elements feel ordered, professional, and easy to scan. Misaligned elements — even when the misalignment is small — read as accidental, sloppy, or unfinished. Of all the visual variables a designer manages, alignment is the cheapest to get right and the most expensive to get wrong.

Definition (in our own words)

When elements share an alignment axis, the eye can connect them as part of a system. A row of fields all sharing a left edge reads as a coherent column. A set of buttons all sharing a baseline reads as a related group. A hero headline sharing the page's center axis reads as a deliberate focal moment. When this discipline lapses — when a button is 4px off from its neighbors, when a label hangs out from the rest of the form — the eye registers the discrepancy preattentively. The user may not articulate it, but they sense the design is "off."

Origins and research lineage

  • Gutenberg's printing press (1450s) standardized typesetting, which is fundamentally about strict alignment. Lines of type aligned to baselines; columns aligned to gutters. The discipline predates digital design by centuries.
  • Tschichold and the New Typography (1920s–30s). Jan Tschichold's Die neue Typographie argued for asymmetric, strictly-aligned compositions over the ornamented symmetric layouts of the 19th century. Influential across modernist graphic design.
  • The Swiss style / International Typographic Style (1950s onward). Müller-Brockmann, Hofmann, Gerstner — the canonical formalization of grid-based design. Modernist corporate identity, much of which still defines visual standards, descends from this tradition.
  • Lidwell, Holden & Butler (2003) compactly stated: every element should be aligned with at least one other element. The book's iconic example is the Palm Beach County "butterfly ballot" of the 2000 US presidential election — alignment failures that may have decided the result.
  • Eye-tracking research on grid layouts consistently shows that users scan aligned columnar content faster and more accurately than misaligned layouts.

Why alignment matters

Alignment carries no information by itself — it doesn't tell the user what anything is. What it does is signal that the design was deliberate. A well-aligned composition reads as competent and trustworthy at a perceptual level the user doesn't consciously evaluate. Conversely, misalignment makes everything else feel suspect; if the designer couldn't get the column edges to line up, what else did they miss?

The cost of misalignment compounds:

  • Scanning slows. The eye traces shared axes; broken axes force re-orientation.
  • Trust erodes. Misaligned UIs feel amateur, even on otherwise polished products.
  • Hierarchy fails. Visual hierarchy depends on rhythm; misalignment disrupts the rhythm.
  • Errors accumulate. Famously: Florida's "butterfly ballot" misaligned candidate names with vote-hole positions, almost certainly causing thousands of voters to vote for the wrong candidate.

When to apply

  • Always. This is one of the few principles that applies on every surface, every time, with no exceptions.
  • In particular, on first-pass layouts before pixel-tweaking. Decide the grid; place elements on it; only then refine.
  • In design-system component specs — components must align by default; designers shouldn't have to manually align components from a system that pre-aligned them.

When alignment can be deliberately broken

A small set of cases where intentional misalignment serves a goal:

  • Marketing surfaces wanting "energetic" or "dynamic" feel. Magazines and posters often deliberately misalign to create visual tension. Use sparingly; never in working app surfaces.
  • A single deliberately-emphasized element. Misaligning one element from a grid pulls the eye to it. Effective if used once per surface; noisy if used repeatedly.
  • Decorative or illustrative content. A hero illustration may not align to the body grid; that's fine.

In production app UI, deliberate misalignment is rare. The default is strict alignment; deviation requires justification.

Alignment dimensions

Vertical alignment (left, right, center)

Elements share a vertical axis (a y-axis line). The most common form in UI work.

  • Left alignment (most common in LTR scripts) — text and form fields share their left edge with the column.
  • Right alignment — used for numbers in tables (so digits stack), and for some labels (label-flush-right against input-flush-left).
  • Center alignment — used for hero text, page titles, button labels. Avoid for body text; ragged edges on both sides slow reading.

Horizontal alignment (baseline, top, middle, bottom)

Elements share a horizontal axis (an x-axis line).

  • Baseline alignment — type baselines line up across columns. The eye threads horizontally.
  • Top / center / bottom alignment for icons-with-labels, buttons-with-text, etc. Choose deliberately.

Grid alignment

A grid imposes both vertical and horizontal alignment. Most modern web design uses 12-column grids (responsive: 12 columns for desktop, 6 for tablet, 4 for mobile).

css
.layout {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 24px;
  max-width: 1200px;
  margin: 0 auto;
}

.layout > .main { grid-column: span 8; }
.layout > .sidebar { grid-column: span 4; }

Within a grid, every element's edges fall on grid columns (or align to multiples of the column width).

Optical alignment

The mathematically-correct alignment doesn't always look right. Curved or pointed shapes (round buttons, triangular icons) need optical adjustment to look aligned with rectangular ones. Designers shift them by a pixel or two so they read as aligned.

Worked examples

Example 1: a form with strict left alignment

html
<form style="display: grid; gap: 16px; max-width: 400px;">
  <div class="field">
    <label for="name">Full name</label>
    <input id="name" type="text" />
  </div>
  <div class="field">
    <label for="email">Email</label>
    <input id="email" type="email" />
  </div>
  <div class="field">
    <label for="phone">Phone</label>
    <input id="phone" type="tel" />
  </div>
  <button type="submit">Submit</button>
</form>

<style>
  .field { display: grid; gap: 4px; }
  label, input, button { width: 100%; }
</style>

Every label, every input, the submit button — all share the same left edge and the same width. The eye reads it as a single coherent column. No alignment surprises.

Example 2: a label-input grid with right-aligned labels

A common pattern for dense forms, especially settings pages where the user scans labels:

html
<form style="display: grid; grid-template-columns: 8rem 1fr; gap: 12px 16px;">
  <label style="text-align: right; padding-top: 0.5rem;">Display name</label>
  <input type="text" />

  <label style="text-align: right; padding-top: 0.5rem;">Email</label>
  <input type="email" />

  <label style="text-align: right; padding-top: 0.5rem;">Phone</label>
  <input type="tel" />
</form>

Two columns: labels on the right, inputs on the left. Labels share a right-edge axis; inputs share a left-edge axis. The space between is the alignment gap. Scanning down either column is effortless.

Example 3: a numeric table

html
<table>
  <thead>
    <tr>
      <th style="text-align: left;">Customer</th>
      <th style="text-align: right;">Amount</th>
      <th style="text-align: right;">Days late</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td>Acme Co.</td>
      <td style="text-align: right; font-variant-numeric: tabular-nums;">$2,480.00</td>
      <td style="text-align: right; font-variant-numeric: tabular-nums;">14</td>
    </tr>
    <tr>
      <td>Bright Labs</td>
      <td style="text-align: right; font-variant-numeric: tabular-nums;">$98,001.50</td>
      <td style="text-align: right; font-variant-numeric: tabular-nums;">3</td>
    </tr>
  </tbody>
</table>

Text columns left-align so the eye traces names. Numeric columns right-align with tabular numerals so digit positions stack — the eye can compare magnitudes by counting digits.

Example 4: a header with title and actions

html
<header style="display: flex; align-items: center; justify-content: space-between;">
  <div>
    <h1 style="font-size: 1.5rem;">Invoices</h1>
    <p style="color: hsl(0 0% 45%); font-size: 0.875rem;">Sent and overdue, this quarter.</p>
  </div>
  <div style="display: flex; gap: 8px;">
    <button>Export</button>
    <button class="primary">New invoice</button>
  </div>
</header>

The header text is left-aligned; the action buttons are right-aligned (against the right edge of the page region). Both groups share the page's vertical center axis. Three alignment axes (left edge, center horizontal, right edge) all working at once.

Example 5: optical alignment for round elements

html
<button class="rounded-button">
  <svg viewBox="0 0 24 24" width="20" height="20" style="margin-left: -1px;">
    <!-- A play icon (triangle) -->
  </svg>
  Play
</button>

A play triangle is mathematically centered in its viewBox but reads as slightly-too-far-right because the triangle's visual mass is offset. A 1px nudge left brings it into optical alignment. Many design systems handle this in their icon set; otherwise designers do it manually.

Cross-domain examples

The butterfly ballot (2000 US election)

The most famous alignment failure in modern history. Palm Beach County, Florida used a "butterfly" ballot where candidate names were listed on facing pages with punch holes between. The misalignment between candidate text and punch positions was such that voters intending to vote for Al Gore (second candidate listed) frequently punched the second hole — which corresponded to Pat Buchanan, not Gore. Buchanan's vote count in Palm Beach County was statistically anomalous compared to surrounding counties; analysis suggested thousands of misvotes. The election was decided by 537 votes in Florida.

A design failure with material consequence. Lidwell, Holden, and Butler use this case as the canonical alignment example precisely because the stakes were so high.

Newspaper layout

Traditional newspapers use strict columnar grids. Headlines align to columns; body text wraps within column widths; photos crop to align with column edges. The discipline is what lets readers scan a dense front page in seconds.

Tax forms (US 1040)

The IRS 1040 form is a masterclass in alignment. Lines align across columns; figures align to decimal points; signature blocks align across pages. Without this discipline, the form would be unreadable; with it, millions of people complete it (with effort, but they complete it).

Spreadsheets

Cells align to a grid by definition. Spreadsheets succeed as a productivity tool partly because alignment is enforced at the data structure level. Word processors and HTML, by contrast, allow alignment to drift unless designers exercise discipline.

Architecture and urban planning

Manhattan's grid is alignment at city scale. Rome's organic streets are aligned to nothing. Both produce navigable cities, but they navigate differently — the grid is faster to learn; the organic is more interesting to walk.

Anti-patterns

  • Centered body text. Reading speeds drop by 30%+ for centered body text vs. left-aligned. Centered text is for short emphasis (headlines, single sentences), not for paragraphs.
  • Justified text without hyphenation. Justified text (both edges flush) creates "rivers of white" between widely-spaced words. Use ragged-right for screens; if you must justify, enable hyphenation.
  • Mixing alignment within a column. Some labels left-aligned, some right-aligned. Each switch is a re-orientation cost.
  • Invisible micro-misalignments. Elements 2–3px off from their intended position because of inconsistent padding. The page feels "off" even if no one can identify why.
  • Decorative misalignment in working UI. Marketing pages can deliberately misalign for energy; settings pages cannot.
  • Different button sizes in a row. Buttons of varying heights or widths in the same row break the row's baseline.

Heuristics

  1. The squint test. Squint at the page. Edges should fall on shared axes. If columns appear to wobble, you have misalignment.
  2. The grid overlay. Show your grid as a CSS overlay. Every element's edge should fall on a grid line or a half-grid line.
  3. The mass-block sketch. Sketch the page as filled rectangles. The rectangles should share axes — left edges, right edges, baselines.
  4. The mobile + desktop check. Many alignments work on desktop and break on mobile (or vice versa). Audit at multiple breakpoints.
  5. The dynamic content audit. Replace placeholder text with real worst-case content (long names, big numbers, multi-line addresses). Did alignment break?

Related principles

  • good-continuation — alignment exploits good continuation; the eye threads along shared edges.
  • hierarchy — alignment supports hierarchy by establishing the rhythm hierarchy varies against.
  • proximity — proximity establishes grouping; alignment establishes the columns those groups inhabit.
  • uniform-connectedness — aligned items connected by a shared axis read as a system.
  • gutenberg-diagram — when alignment is uniform, the eye falls back to the Z-pattern.
  • aesthetic-usability-effect (aesthetics) — alignment is a major component of "classical" aesthetics; misaligned designs are perceived as less usable even when they work.

Sub-aspect skills

  • alignment-grid-systems — formal grid systems (12-column, modular grids, baseline grids) and how to use them.
  • alignment-text-and-numerics — alignment decisions specific to text (left vs. center vs. justified) and to numeric tables (right-align, tabular numerals).

Closing

Alignment is the cheapest design improvement available — it costs only attention, no new content. Yet it's one of the most-violated principles in production UIs because it's invisible when right and accumulates as drift when ignored. The discipline is in noticing every element's edge and asking: what does this align to? If the answer is "nothing," fix it.

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Alignment AI skill do?

Use this skill whenever the design has more than one element on the page — every layout, every form, every table, every page header, every card. Trigger when designing a layout, picking a grid, fixing a UI that "looks off," debating left vs. center alignment for body text, or auditing why a design feels disorderly. Alignment is one of the most foundational principles in 'Universal Principles of Design' (Lidwell, Holden, Butler 2003) — every visible element's edge or center should fall on a shared axis with at least one other element. Misalignment by even a few pixels reads as disorder.

Why use Alignment on TypingMind?

Because you install it once and use it with any model. Alignment is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Alignment in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/Deibler/universal-design-principles/tree/main/plugins/perception-and-hierarchy-principles/skills/alignment. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Alignment?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Alignment?

As many as you like. As long as a model supports skills, you can use Alignment with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Alignment AI skill free?

It is published on GitHub by Deibler. Check the repository for licensing terms. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇