/ui-motion:forms-a11yfrom UI Motion & States
Guides on marking up accessible forms: labels, error messages, focus management, fieldset/legend, and aria attributes. Use when writing form markup, not for auditing existing pages.
Ships in UI Motion & States. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Формы — самая нарушаемая часть accessibility. Делай правильно с первого раза.
a11y-audit: рецепт против измерителяОба скилла ловятся на слово «доступность», и это единственное, что у них общее.
Признак выбора берётся из того, что перед тобой в момент запроса: пишешь разметку
(«как правильно оформить это поле», «нужен fieldset?») — этот файл; проверяешь уже
свёрстанное («покажи нарушения WCAG») — a11y-audit. Тут паттерны, которые нечего
запускать; там прогон axe-core, которому нечего подсказать.
Порядок при работе над формой: разметить отсюда → прогнать a11y-audit → и всё
равно пройти чек-лист внизу руками. Причина в том, что axe проверяет наличие
атрибута, а не его правоту: <label for="email">Телефон</label> для него зелёный,
не переведённый после сабмита фокус — тоже, потому что это поведение, а не DOM.
Ровно эти вещи — смысл label, текст ошибки, focus management, проход табом — здесь
и живут, и зелёный axe их не заменяет.
<!-- ✅ Правильно -->
<label for="email">Email</label>
<input id="email" type="email" name="email">
<!-- ✅ Альтернатива (label оборачивает) -->
<label>
Email
<input type="email" name="email">
</label>
<!-- ❌ Неправильно — placeholder вместо label -->
<input type="email" placeholder="Email">
<!-- ❌ Неправильно — visually-hidden span ≠ label -->
<input type="email" name="email">
<span class="sr-only">Email</span>
<label for="search" class="sr-only">Поиск</label>
<input id="search" type="search" placeholder="Поиск...">
.sr-only {
position: absolute; width: 1px; height: 1px;
padding: 0; margin: -1px; overflow: hidden;
clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
<label for="pwd">Пароль</label>
<input id="pwd" type="password" aria-describedby="pwd-help">
<p id="pwd-help" class="helper">Не меньше 8 символов, цифра и буква.</p>
aria-describedby ID элемента, прочитается скрин-ридером после label.
<label for="email">Email</label>
<input id="email" type="email" aria-invalid="true" aria-describedby="email-err">
<p id="email-err" class="error" role="alert">Введите корректный email — например, [email protected].</p>
aria-invalid="true" — статус.aria-describedby — связывает с текстом.role="alert" — скрин-ридер прочитает сразу.<label for="name">Имя <span aria-hidden="true">*</span></label>
<input id="name" required aria-required="true">
* визуальная — aria-hidden. required + aria-required для скрин-ридера и валидации.
<fieldset>
<legend>Способ оплаты</legend>
<label><input type="radio" name="pay" value="card"> Карта</label>
<label><input type="radio" name="pay" value="cash"> Наличные</label>
</fieldset>
<fieldset> + <legend> — обязательны для группы radio/checkbox. Без них скрин-ридер не понимает, к чему относятся опции.
<input type="text" autocomplete="given-name" name="firstName">
<input type="text" autocomplete="family-name" name="lastName">
<input type="email" autocomplete="email" name="email">
<input type="password" autocomplete="current-password">
<input type="password" autocomplete="new-password">
<input type="tel" autocomplete="tel">
<input type="text" autocomplete="postal-code">
<input type="text" autocomplete="cc-number" inputmode="numeric">
Полный список — на developer.mozilla.org/autocomplete.
inputmode="numeric" — показывает цифровую клавиатуру на мобильных.
После сабмита формы — переведи фокус:
form.addEventListener('submit', async e => {
e.preventDefault();
const result = await validate(form);
if (result.errors.length) {
const firstErrEl = form.querySelector(`[name=${result.errors[0].field}]`);
firstErrEl.focus();
} else {
successEl.tabIndex = -1;
successEl.focus();
}
});
<button type="submit">Создать аккаунт</button>
type="submit" — иначе Enter не сработает.<button type="submit" aria-busy="true" disabled>
<span class="spinner" aria-hidden="true"></span>
<span>Создаём…</span>
</button>
aria-busy + текст «Создаём…» — понятно скрин-ридеру.
Visual-only паттерн. Нужен label под капотом. Никогда не заменяй placeholder'ом.
<div class="float">
<input id="email" type="email" placeholder=" ">
<label for="email">Email</label>
</div>
.float { position: relative; }
.float input { padding: 24px 12px 8px; }
.float label {
position: absolute; left: 12px; top: 16px;
pointer-events: none; transition: all .15s ease;
color: #888;
}
.float input:focus + label, .float input:not(:placeholder-shown) + label {
top: 4px; font-size: 11px; color: #555;
}
Для каждого поля:
<label> или aria-labelaria-describedby (где нужно)role="alert" и aria-invalidautocomplete для известных полейtype соответствует данным (email, tel, url, number)inputmode на мобильныхДля формы:
<fieldset> для групп radio/checkboxdisplay: none — скрин-ридеры пропустят.<div onclick>. Только <button> или <a>.tabindex на не-интерактивных элементах.outline: none без замены focus-кольца.Прежняя расширенная версия скилла (дерево @2026-04-30) сохранена целиком в references/legacy-forms-a11y.md. Секции там: Минимум на каждое поле, Полная таблица типов, Группировка через fieldset, Error UX, Focus rings, Disabled vs read-only, Mobile keyboards, Required indicator, Validation на стороне клиента vs сервера, Антипаттерны.
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub jhamidun/claude-code-config-pack --plugin ui-motion13 skills in this plugin
/animationsТаймлайн-анимации в HTML (React): плеер, скраббер, ease. Триггеры: «анимация в HTML», «motion design», «интро», «transitions для презентации». НЕ: мультик кодом в MP4 с голосом и звуком→code-cartoon./comment-injectorOverlay в HTML: Alt+Click кладёт в clipboard селектор и outerHTML, Shift+Alt+Click — пачку пометок. Триггеры: «ревью прототипа в браузере», «убери всё отмеченное»./device-framesCSS-рамки iOS, Android, окно macOS и браузера вокруг макета. Триггеры: «в iPhone», «iOS frame», «browser frame».Other plugins' skills for the same job