Agent skill

Viewer UI Guidelines

by simonliu-ai-product in simonliu-ai-product/open-doc

Design and accessibility rules for the open-doc viewer chrome — the browser shell, sidebars, thumbnail rail, outline, assets and design panels, inspector overlay, and menus.

MITAuto-check passedFrontend & Design

Install Viewer UI Guidelines

skills CLI
$ npx skills add simonliu-ai-product/open-doc --skill viewer-ui-guidelines -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install simonliu-ai-product/open-doc viewer-ui-guidelines --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/simonliu-ai-product/open-doc.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/viewer-ui-guidelines .claude/skills/viewer-ui-guidelines && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
viewer-ui-guidelines
GitHub stars
108
Token cost
~1.6k tokens
SKILL.md length
870 words
Files
1
Skills in repo
7
Repo updated
First seen
Licence
MIT

At a glance

Design and accessibility rules for the open-doc viewer chrome — the browser shell, sidebars, thumbnail rail, outline, assets and design panels, inspector overlay, and menus.

  • Works in 10 steps: The page is the subject. The sheet sits… → Tokens, not literals. Colour comes from… → Both themes, always. Dark mode is the… → …
  • Reviewing UI under packages/core/src/app that surrounds a document
  • SKILL.md covers Non-negotiables, Structure rules, Escalation triggers — flag on… and Output when reviewing
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Viewer UI Guidelines is an agent skill from simonliu-ai-product/open-doc. Design and accessibility rules for the open-doc viewer chrome — the browser shell, sidebars, thumbnail rail, outline, assets and design panels, inspector overlay, and menus. Use when building or reviewing UI under packages/core/src/app that surrounds a document. Does not apply to the printed page itself, which is governed by print-layout-review.

Its SKILL.md is about 1.6k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Frontend & Design. The repository describes itself as: The document framework built for agents — write reports as React, get real A4 pages, an outline, page numbers, and a PDF. The licence is MIT.

When your agent uses it

  • Reviewing UI under packages/core/src/app that surrounds a document

Example prompts

  • “/viewer-ui-guidelines”

Workflow steps

10 steps, taken from the first numbered list in SKILL.md.

  1. The page is the subject. The sheet sits on --canvas; the chrome sits on --background. Chrome never competes with the document for…
  2. Tokens, not literals. Colour comes from the theme tokens defined in app/styles.css — --background, --foreground, --canvas, --muted…
  3. Both themes, always. Dark mode is the .dark class variant wired through next-themes; every token has a dark value. Any new surface is…
  4. Document colours are not chrome colours. --od-* variables (--od-bg, --od-text, --od-accent, --od-margin, --od-size-*) belong to the…
  5. Keyboard first. Every action reachable by mouse is reachable by keyboard. Focus is visible (never outline: none without a replacement)…
  6. Real semantics. Buttons are , links are , lists are lists. A is a finding. Interactive controls carry an accessible name — an icon-only…
  7. Motion is functional or absent. The viewer is a reading tool. Animate only to explain a spatial relationship (a panel sliding from its…
  8. Hit targets and pointer gating. Interactive targets are at least 32×32 CSS px in dense rails, 40×40 elsewhere. Hover-revealed affordances…
  9. State is honest. Loading, empty, and error states are designed, not accidental. Prefer a hairline progress affordance over a spinner for…
  10. Density is deliberate. The rails are dense by design: small type, tight leading, generous hit targets. Chrome type stays in the small end…

What it can do on your machine

Read from SKILL.md and the folder at commit af6095d. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md.

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Viewer UI Guidelines loads about 1.6k tokens when it runs. Until then it costs about 92 tokens; SKILL.md has 870 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~92
When it runs · the whole SKILL.md, loaded when a task matches
~1.6k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from simonliu-ai-product/open-doc at commit af6095d, republished under its MIT licence (© simonliu-ai-product). 870 words, ~1,561 tokens.

Download SKILL.mdSave it as .claude/skills/viewer-ui-guidelines/SKILL.md (or your agent's skills folder).
name
viewer-ui-guidelines
description
Design and accessibility rules for the open-doc viewer chrome — the browser shell, sidebars, thumbnail rail, outline, assets and design panels, inspector overlay, and menus. Use when building or reviewing UI under packages/core/src/app that surrounds a document. Does not apply to the printed page itself, which is governed by print-layout-review.

open-doc viewer UI

The chrome is everything that is not the sheet: the shell, the rails, the panels, the menus. It has one job — keep the paper the loudest thing on screen and get out of the way. Judge it against that, not against how interesting it looks in a screenshot.

Non-negotiables

  1. The page is the subject. The sheet sits on --canvas; the chrome sits on --background. Chrome never competes with the document for contrast, saturation, or motion. A control that draws the eye away from the page during reading is a defect regardless of how well it's made.

  2. Tokens, not literals. Colour comes from the theme tokens defined in app/styles.css — --background, --foreground, --canvas, --muted, --muted-foreground, --accent, --accent-foreground, --primary, --primary-foreground, --border. A raw hex, rgb(), or Tailwind palette colour (bg-zinc-800) in chrome code is a finding: it won't follow the dark theme.

  3. Both themes, always. Dark mode is the .dark class variant wired through next-themes; every token has a dark value. Any new surface is checked in both. Never define a colour only inside one branch.

  4. Document colours are not chrome colours. --od-* variables (--od-bg, --od-text, --od-accent, --od-margin, --od-size-*) belong to the document's design system and are scoped to the page. Chrome must never read them, and page content must never read chrome tokens — that leak is what makes a printed page follow the viewer's dark mode.

  5. Keyboard first. Every action reachable by mouse is reachable by keyboard. Focus is visible (never outline: none without a replacement), focus order follows visual order, and focus is trapped and restored around any panel or menu that overlays content. New shortcuts are documented where the user can find them, and must not collide with browser or OS bindings.

  6. Real semantics. Buttons are <button>, links are <a>, lists are lists. A <div onClick> is a finding. Interactive controls carry an accessible name — an icon-only control needs aria-label. Panels that appear over content announce themselves (role="dialog" + labelled) or are inert to assistive tech if purely decorative.

  7. Motion is functional or absent. The viewer is a reading tool. Animate only to explain a spatial relationship (a panel sliding from its edge, a rail expanding). Duration stays under 200ms, easing is ease-out, and only transform/opacity animate. Animating width/height/top/left, or animating anything on a keyboard-triggered action, is a finding. Honour prefers-reduced-motion by dropping movement while keeping opacity.

  8. Hit targets and pointer gating. Interactive targets are at least 32×32 CSS px in dense rails, 40×40 elsewhere. Hover-revealed affordances are gated behind @media (hover: hover) and (pointer: fine) and must have a non-hover path.

  9. State is honest. Loading, empty, and error states are designed, not accidental. Prefer a hairline progress affordance over a spinner for short waits; prefer an empty state that says what to do next over a blank rail. Never show a stale page count while re-measuring — show the previous value or nothing, never a wrong one.

  10. Density is deliberate. The rails are dense by design: small type, tight leading, generous hit targets. Chrome type stays in the small end of the scale (text-xs / text-sm) so it reads as instrumentation, not content. Do not import the document's type scale into the chrome.

Show full SKILL.md (336 more words)Show less

Structure rules

  • The shell owns shared state. routes/home-shell.tsx holds the left sidebar (nav counts, folders, theme toggle) and passes folder state to routes through the outlet context. A route that fetches the folders manifest itself is a finding.
  • The document view mirrors it. components/doc-sidebar.tsx is the left rail (thumbnails / outline), pages scroll in the middle, the design panel docks right. New surfaces pick one of those three homes rather than inventing a fourth region.
  • app/components/ui/ is the primitive layer. Shared, unopinionated pieces only (currently menu.tsx). Feature-specific UI lives next to its feature, not here.
  • Edit mode types on the page, never into React's DOM. Text is edited in a clone that stands in for the element (lib/inspector/inline-edit.ts); the rendered node is only hidden. Anything shown before Save must be visibly unsaved — the dashed pending frame and the unsaved-edits bar — and Discard must restore exactly what was rendered. After Save, what you see is the re-render from source; the clone only bridges the reload.

Escalation triggers — flag on sight

  • A hex/rgb/Tailwind palette colour in chrome code
  • A new surface with no dark-theme value
  • Chrome reading --od-*, or page content reading chrome tokens
  • <div>/<span> with a click handler; icon button with no accessible name
  • outline: none without a visible replacement
  • A panel or menu that doesn't restore focus on close
  • Animation over 200ms, ease-in, or animating layout properties
  • Any motion tied to a keyboard shortcut or a high-frequency action
  • Hover-only access to a function with no keyboard or click path
  • A spinner for a wait the code knows is under ~300ms
  • Fixed pixel widths on rails that make the page area collapse below ~900px viewport

Output when reviewing

A findings table (Before / After / Why), then a verdict grouped by: accessibility blocks, theming correctness, hierarchy & density, motion, structure fit. Cite file:line. Block on any keyboard/screen-reader regression, any hardcoded colour, or any chrome/document token leak.

When building rather than reviewing: choose the boring, quiet option. The chrome's ceiling is "invisible"; there is no version of it that should be memorable.

© simonliu-ai-product, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .agents/skills/viewer-ui-guidelines of simonliu-ai-product/open-doc.

Open the folder on GitHubat commit af6095d

Compare with similar skills

Viewer UI Guidelines next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Viewer UI Guidelines compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Viewer UI Guidelines this skillsimonliu-ai-product/open-doc108—~1.6kAutomated safety check: PassMIT
Web Artifacts Builderanthropics/skills180k40 repos~769Automated safety check: PassApache-2.0
React Doctormakeplane/plane61k12 repos~657Automated safety check: PassAGPL-3.0
Impeccablebestofjs/bestofjs3.1k26 repos~2.6kAutomated safety check: PassMIT
Figma Design System Builderwarpdotdev/warp65k2 repos~4.4kAutomated safety check: PassAGPL-3.0
Web Interface Guidelines Reviewervercel-labs/openreview1.7k97 repos~308Automated safety check: PassNone

Similar skills

  • Web Artifacts Builder

    anthropics/skills

    Official

    Builds multi-component claude.ai HTML artifacts as a small React, TypeScript and Tailwind project, then bundles it into one shareable HTML file.

    180k GitHub starsUsed in 40 repos~769 tokens
    Frontend & DesignAuto-check passed
  • React Doctor

    makeplane/plane

    Scans React code for lint, accessibility, bundle size and architecture issues, reports a health score and checks that changes do not lower it.

    61k GitHub starsUsed in 12 repos~657 tokens
    Frontend & DesignAuto-check passed
  • Impeccable

    bestofjs/bestofjs

    A skill your agent uses when the user wants to design, redesign, shape, critique, audit, polish, clarify, distill, harden, optimize, adapt, animate, colorize, extract, or otherwise improve a…

    3.1k GitHub starsUsed in 26 repos~2.6k tokens
    Frontend & DesignAuto-check passed
  • Builds or updates a design system in Figma from a codebase in ordered phases: discovery, variables and tokens, components, theming and documentation, with checkpoints.

    65k GitHub starsUsed in 2 repos~4.4k tokens
    Frontend & DesignAuto-check passed
  • Web Interface Guidelines Reviewer

    vercel-labs/openreview

    Official

    Review UI code for Web Interface Guidelines compliance. Use when asked to "review my UI", "check accessibility", "audit design", "review UX", or "check my…

    1.7k GitHub starsUsed in 97 repos~308 tokens
    Frontend & DesignAuto-check passed
  • Tailwindcss Development

    anonaddy/anonaddy

    Always invoke when the user's message includes 'tailwind' in any form.

    4.9k GitHub starsUsed in 10 repos~865 tokens
    Frontend & DesignAuto-check passed

More from simonliu-ai-product/open-doc

  • Apply Comments

    simonliu-ai-product/open-doc

    A skill your agent uses when the user asks to apply, process, or clear the comments they left in the open-doc inspector — phrases like "apply the comments", "apply my edits", "I left notes on the…

    108 GitHub stars~948 tokensUpdated 4 days ago
    Auto-check passed
  • Doc Authoring

    simonliu-ai-product/open-doc

    Technical reference for writing or editing open-doc pages — file contract, the A4/B4/A3 page canvas, print type scale, the vertical budget that decides where a page breaks, tables, charts, table of…

    108 GitHub stars~6.8k tokensUpdated 4 days ago
    Auto-check passed
  • Create Doc

    simonliu-ai-product/open-doc

    A skill your agent uses when the user wants to create, draft, author, or generate a new document, report, whitepaper, proposal, memo, or spec in this open-doc repo.

    108 GitHub stars~2.4k tokensUpdated 4 days ago
    Auto-check passed
  • Current Doc

    simonliu-ai-product/open-doc

    Resolve which document, page, and (optionally) selected element the user is currently viewing in the open-doc dev server.

    108 GitHub stars~1.8k tokensUpdated 4 days ago
    Auto-check passed
  • Doc Runtime Patterns

    simonliu-ai-product/open-doc

    Implementation patterns for the @open-doc/core runtime — the split between the viewer and the published bundle, virtual modules, the flow pipeline, the ops layer, dev-only plugins, and the…

    108 GitHub stars~2.1k tokensUpdated 4 days ago
    Auto-check passed
  • Print Layout Review

    simonliu-ai-product/open-doc

    Reviews page layout, typography, and pagination code in open-doc against a print craft bar — the sheet is the deliverable, not the screen.

    108 GitHub stars~2k tokensUpdated 4 days ago
    Auto-check passed

Questions about Viewer UI Guidelines

What does Viewer UI Guidelines do?

Design and accessibility rules for the open-doc viewer chrome — the browser shell, sidebars, thumbnail rail, outline, assets and design panels, inspector overlay, and menus. Viewer UI Guidelines is an agent skill from simonliu-ai-product/open-doc. Design and accessibility rules for the open-doc viewer chrome — the browser shell, sidebars, thumbnail rail, outline, assets and design panels, inspector overlay, and menus.

When should I use Viewer UI Guidelines?

Viewer UI Guidelines fits situations like: reviewing UI under packages/core/src/app that surrounds a document.

How do I install Viewer UI Guidelines in Claude Code?

Run `npx skills add simonliu-ai-product/open-doc --skill viewer-ui-guidelines -a claude-code`. Or copy the skill folder (.agents/skills/viewer-ui-guidelines in simonliu-ai-product/open-doc) into .claude/skills/viewer-ui-guidelines in your project. Claude Code loads it when a task matches its description.

How do I install Viewer UI Guidelines in Codex?

Run `npx skills add simonliu-ai-product/open-doc --skill viewer-ui-guidelines -a codex`. Or copy the skill folder (.agents/skills/viewer-ui-guidelines in simonliu-ai-product/open-doc) into .agents/skills/viewer-ui-guidelines in your project. Codex loads it when a task matches its description.

Can I use Viewer UI Guidelines in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add simonliu-ai-product/open-doc --skill viewer-ui-guidelines -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/viewer-ui-guidelines, .gemini/skills/viewer-ui-guidelines, .github/skills/viewer-ui-guidelines and .opencode/skills/viewer-ui-guidelines in your project.

What does Viewer UI Guidelines need to run?

SKILL.md names no scripts, command-line tools or credentials: Viewer UI Guidelines is instructions for the agent only.

Does Viewer UI Guidelines access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Viewer UI Guidelines safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Viewer UI Guidelines use?

Viewer UI Guidelines is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Viewer UI Guidelines use?

About 1.6k tokens (SKILL.md is roughly 6.2k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Viewer UI Guidelines?

Skills that share tags, products or a category with Viewer UI Guidelines: Web Artifacts Builder (anthropics/skills, 180k stars), React Doctor (makeplane/plane, 61k stars), Impeccable (bestofjs/bestofjs, 3.1k stars) and Figma Design System Builder (warpdotdev/warp, 65k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Viewer UI Guidelines?

simonliu-ai-product (a GitHub organization) maintains it in simonliu-ai-product/open-doc, which has 108 GitHub stars. The repository holds 7 skills in this directory. The repository was last updated on October 7, 2026.

Source: simonliu-ai-product/open-doc on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.