diego3g/craft

craft-states

Use when designing or redesigning a screen, flow or component, when asked to cover all states or find missing ones, or before handing a screen to code.

ソースを見る

使い方

  1. インストールコマンドをコピーし、自分の環境へ導入する前にソースを確認します。
  2. 必要なツール、認証情報、対応環境を原文で確認します。
  3. 入力と成果物を指定し、出力を資料と照合します。
npx skills add https://github.com/diego3g/craft --skill craft-states

開始前の確認

  • 導入にはモデル契約、API枠、ファイルへのアクセス許可は含まれません。
  • スター数や導入数は活動の指標であり、独立した品質・安全性試験ではありません。
リポジトリの原文

見出し、例、コード、表、リンク、参照画像を含む原文を表示しています。

Screen states

Overview

A screen is not designed until every state it can be in is designed. The happy path is one state out of twenty. List the states in words first, get the list approved, then draw. Agreeing on a list costs a minute. Discovering a missing state in code costs a day.

When to use

  • A new screen, flow or component, or a redesign of one.
  • "Cover all the states", "what are we missing?", "is this ready for dev?"
  • The design shows one perfect case: three orders, short names, everything loaded.

When NOT to use

  • A small edit to an existing screen ("make the button 2px taller", "fix this typo"). Make the edit and stop.
  • Pure copy changes, or a question about the design.

Before you start

  1. Read DESIGN.md at the project root if it exists: it is the project's design brief.
  2. Read the project's design system and existing screens. They win on look: reuse their empty state, banner and loading pieces instead of inventing new ones.
  3. Pick your tool's adapter in references/adapters/ (paper.md, pen.md, figma.md, html.md). If no adapter matches your tool, do the same verbs in your tool and say which you mapped by hand. With no design tool at all, build in HTML (html.md). If an image is all you have, say that values read from it are estimates.
  4. Know the screen's job: who uses it, what they came to do, and what the one next action is.

Steps

  1. Write the state list. Walk every group in the state catalogue: Data, System, Activity, People, Interaction. Mark each item in one of three ways:
  • applies, with a one-line description of what the screen shows;
  • doesn't apply, with a reason;
  • open question for the person.

Stop and show the person the list. Do not draw yet.

  1. Draw the main state with realistic invented data: the most complex realistic case, not the tidiest. Use long names, many items, and mixed statuses. Build it one section at a time, and check each section rendered before the next.
  2. Draw every other state that applies:
  • a state that changes the whole screen (empty, offline, couldn't load) gets a full board;
  • a state that changes one part (a failed row, a saving button, a stale banner) goes on a state sheet that shows just that part.
  1. Check every state:
  • Does it offer the action that resolves it, and say who does it?
  • Does moving between states keep the layout still (same widths and heights, no jumping)?
  1. Name and order the boards as described in naming and sheets: <number> · <screen> · <state>, the main state first, the other states next, sheets last, and a cover note at the start of each row.
  2. Look at what you made. Screenshot or render every board and compare it with the list. If you cannot render, say so plainly, and name what wasn't checked.

Rules

RuleWhy
The list comes before any drawing, and the person approves itIt's the cheapest moment to find a missing state or one that doesn't apply
Sample data is long, many and messyShort tidy data hides truncation, overflow and wrapping bugs
Assume more than one person uses it"Someone else already did it" and "changed while you looked" happen every day
No state without a way out: what to do next and who does itA dead end makes people call support
A failure is worded as a failure, never as a deliberate pause"Stopped" reads like someone chose it; "Couldn't save" tells the truth
One standard empty-state piece across the productTen bespoke empty states drift apart and cost ten times more
A whole-app problem goes in a top banner; a problem with one item goes inline on that itemA banner for one row's error shouts at everyone about nothing
Loading and label swaps keep the element's sizeLayout shift makes people click the wrong thing
Interaction states (hover, focus, disabled…) come from the design system's states matrixRedrawing them on every screen creates drift; draw them once, in the system

Done when

Every catalogue item is drawn, marked "doesn't apply" with a reason, or listed as an open question. The boards are named and ordered, and you looked at each one or said which you couldn't.

Common mistakes

ThoughtReality
"I'll just design all the states in one go, it's faster"Without an approved list you draw states nobody needs and miss the ones they do. List, stop, then draw.
"Three sample orders show the idea"Show forty, and show a customer called "Maria Fernanda de Albuquerque Santos". The overflow state is a real state.
"Loading, empty, error, offline: covered"Those are four of the catalogue's groups' easiest items. Also check many/overflow, long text, someone-else-did-it, changed-while-viewing, permissions and slow.
"I'll put all the states on one page"An unnamed pile can't be reviewed or handed off. Name and order the boards.
"I couldn't render it, but it's fine"Say what you couldn't check. Unverified layout is a guess.

Red flags: stop and go back to step 1

  • You are drawing and no state list was approved.
  • Every name in the mock fits on one line.
  • The design never mentions a second person.
同じリポジトリから

関連する Skills

すべての Skills
diego3g
コミュニティ

craft

Use when asked to design, create, mock up or redesign one or more pages, screens, flows or UI elements, or when the person runs /craft (/craft:craft in the Claude Code plugin).

1時間の導入数
2
GitHub Stars
366
更新日
11月17日
diego3g
コミュニティ

craft-critique

Use when asked to review, critique, refine or polish a design or screen, when something "feels off", "looks busy" or "isn't good yet", after finishing a screen and before showing it, or before handing a design to code.

1時間の導入数
2
GitHub Stars
309
更新日
11月17日
diego3g
コミュニティ

craft-explore

Use when asked for options, alternatives, variations, directions or "a few ideas" for a screen, flow or element, when the person rejects a design or says they don't like it, or says "rethink this", "try something else" or "design both so I can pick".

1時間の導入数
2
GitHub Stars
309
更新日
11月17日
diego3g
コミュニティ

craft-setup

Use when a request to design or create a page, screen or element starts in a project with no DESIGN.md at its root, when the person asks to set up, define or start the design, style, brand or guidelines of a product, or runs /craft-setup (/craft:craft-setup in the Claude Code plugin).

1時間の導入数
2
GitHub Stars
309
更新日
11月17日