project-form-patterns

project-form-patterns is a skill for Claude Code, Codex from AkaraChen/aghub. It costs 0 tokens per session (914 once invoked), scanned A, original, MIT.

A project-specific guide for building and refactoring forms in the aghub desktop app using React, HeroUI, and react-hook-form, a library for managing form state and validation.

In plain words
What is it for?
Use it for settings dialogs, create or edit panels, text fields, selects, custom editors, and other forms in the desktop application.
Why use it?
It keeps validation, field control, and error messages consistent instead of letting multiple systems handle the same form behavior.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/akarachen/aghub/project-form-patterns
Any agent
npx skills add AkaraChen/aghub --skill project-form-patterns
Clone the repo
git clone --depth 1 https://github.com/AkaraChen/aghub

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for project-form-patterns

README.md
[![agentmods](https://agentmods.dev/badge/skills/akarachen/aghub/project-form-patterns.svg)](https://agentmods.dev/skills/akarachen/aghub/project-form-patterns)
Your own site
<a href="https://agentmods.dev/skills/akarachen/aghub/project-form-patterns"><img src="https://agentmods.dev/badge/skills/akarachen/aghub/project-form-patterns.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 914 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.00914
Opus 5 $0.00000 $0.00457
Sonnet 5 $0.00000 $0.00183
Haiku 4.5 $0.00000 $0.00091

Measured 4d ago against content hash 1c8683d2b557, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

project-form-patterns scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.agents/skills/project-form-patterns/SKILL.md · 81 lines

How it starts

The opening of the file, as written. The whole thing — 81 lines — stays where its author put it; the contents beside it link to each section on GitHub.

aghub Form Patterns

Follow these rules when building forms in this project.

Source of Truth

  • Check the official docs first, not memory and not bundled/local docs, when form behavior is in question.
  • For HeroUI, prefer the official site:
    • https://v3.heroui.com/docs/react/components/form
    • https://v3.heroui.com/docs/react/components/text-field
    • https://v3.heroui.com/docs/react/components/field-error
    • https://v3.heroui.com/docs/react/components/select
  • Use local skill docs only as a convenience after confirming the official API.

Default Stack

  • Prefer react-hook-form for non-trivial forms.
  • Use Controller for HeroUI Select and any custom controlled widgets.
  • Keep one form state. Do not create a second derived validation state unless there is a concrete need the form library cannot express.

Validation Behavior

  • When RHF controls validation, set HeroUI form fields to validationBehavior="aria".
  • Do not rely on HeroUI/native validation defaults together with RHF. Native validation can steal focus and submission flow while bypassing the error UI you expect from RHF.
  • Let RHF own validation rules and submission blocking.

Error Rendering

  • For HeroUI text fields, use:
    • isInvalid={Boolean(fieldState.error)}
    • Conditionally render <FieldError>{fieldState.error.message}</FieldError> inside the same TextField.
  • Do not invent unsupported props. In particular, do not assume TextField supports an errorMessage prop.
  • Keep the official anatomy:
<TextField isInvalid={Boolean(fieldState.error)} validationBehavior="aria">
	<Label>Name</Label>
	<Input {...inputProps} />
	{fieldState.error && <FieldError>{fieldState.error.message}</FieldError>}
</TextField>
  • For non-form or custom composite controls, prefer HeroUI ErrorMessage instead of hand-rolled error text.
  • Use ErrorMessage for collection-style or custom editors that are not true form fields, including key/value editors, tag selectors, and similar composite controls.

Read the full file on GitHub · 81 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 81 lines · 0 tokens per session scan A 1c8683d2b557

Subscribe to this mod's changes

project-form-patterns is a skill published in the GitHub repository AkaraChen/aghub (264 stars, last pushed yesterday), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 914 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

auth-web-cloudbase

CloudBase Web Authentication Quick Guide for frontend integration after auth-tool has already been checked. Provides concise and practical Web authentication solutions with multiple login methods and complete user management.

TencentCloudBase/CloudBase-AI-Toolkit · 38 tokens

github-skill

Work with GitHub via the gh CLI — clone repositories, create/list/merge pull requests, create/list issues, and run any other gh command (API calls, workflow runs, releases, repo administration). List operations return parsed JSON.

zeenie-ai/OpenCompany · 51 tokens

whatsapp-send-skill

Send WhatsApp messages to contacts, groups, or channels. Supports text, images, videos, audio, documents, stickers, locations, and contacts.

zeenie-ai/OpenCompany · 36 tokens

discord-user-post

Post an approved message as the logged-in Discord user through the Discord desktop app. Use for release announcements or other direct user-authored Discord posts; not for OpenClaw channel sends, bots, webhooks, relays, agent sessions, or archive search.

openclaw/openclaw · 56 tokens

browse-and-evaluate

Use when exploring the ai-agent-skills catalog to find, compare, and evaluate skills before installing. Always use --fields to limit output size and --dry-run before committing to an install.

MoizIbnYousaf/Ai-Agent-Skills · 43 tokens

loop-engineering

Shared loop-engineering reference for COG skills - the agent loop, deterministic verifiers, termination conditions, in-loop context management, and named patterns. Invoke when designing or debugging a skill that iterates (search-verify-retry, scan-until-dry, fetch-retry-gate).

huytieu/COG-second-brain · 63 tokens