agentleFS
aaziraniaazirani/flutter_agentify/.agents/skills/ui-design/SKILL.md

ui-design

Skill0 starsChanged 4 days agoMITView on GitHub

How screens are built here, with Material 3 tokens from the theme, loading, empty, error, success and narrow-width states, matching skeletons, and response timing. Use when building or restyling a screen or widget.

61 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use harness-design, graphic-design and 9 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • VictoriakaeySkill

    harness-design

    Use when designing or improving the action space, observation format, tool boundaries, and evaluation signals of an LLM agent. Covers the five layers of harness design: what tools the agent has, what it sees after acting, how each tool is scoped, how behavior is evaluated, and how to iterate when the agent misbehaves. Prevents the most common harness failures — agents that pick wrong tools, ignore critical information, or loop without progress.

    Also in 3 projects that use this

  • travisjneumanSkill

    graphic-design

    Professional graphic design principles for digital and print media. Use when creating visual designs, choosing color palettes, typography, layouts, or providing design feedback.

    Also in 3 projects that use this

  • soilmassSkill

    typography

    Typography and kinetic text animations including character reveals, typewriter effects, scramble/decode, wave motion, and animated gradients. Use when creating text reveals, headline animations, number counters, or any text-based motion effects.

    Also in 3 projects that use this

  • MicrosoftSkill

    typescript

    TypeScript best practices for this monorepo. Use this skill when: (1) writing new TypeScript code, (2) reviewing TypeScript code, (3) working with API responses, fetch calls, or JSON parsing, (4) adding or modifying types and interfaces.

    Also in 7 projects that use this

  • OpenAISkill

    auth

    Authentication integration guidance — Clerk (native Vercel Marketplace), Descope, and Auth0 setup for Next.js applications. Covers middleware auth patterns, sign-in/sign-up flows, and Marketplace provisioning. Use when implementing user authentication.

    Also in 3 projects that use this

  • VercelSkill

    react

    React renderer for json-render that turns JSON specs into React components. Use when working with @json-render/react, building React UIs from JSON, creating component catalogs, or rendering AI-generated specs.

    Also in 4 projects that use this

The file

We split this skill into the rules it gives an agent

4 rules. 0 are common, 2 are distinctive, and 2 are very specific to this project.

  • 0

    Common

    Most of the 52 edited versions we read keep these.

  • 2

    Distinctive

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Don't load this for string keys and right-to-left layout.

    line 8
  2. Distinctive:

    Every screen that loads data handles five cases: loading, empty, error, success, and a narrow width (a phone at 320 dp wide, and the …

    line 13
  3. Very specific:

    States: import package:flutter_agentify/core/widgets/states/states.dart.

    line 25
  4. Distinctive:

    Run the app at a narrow width and in dark mode and look.

    line 47

“Common” is measured: kept by at least 6 in 10 of the 52 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

UI design

Don't load this for string keys and right-to-left layout; see i18n-and-rtl.

Rule

  • Colors, spacing, shapes and type come from the theme: Theme.of(context).colorScheme, textTheme, and the tokens in lib/core/theme/ (app_spacing.dart, app_shapes.dart, app_animations.dart). No Color(0xFF...) and no Colors.red outside lib/core/theme/.
  • Every screen that loads data handles five cases: loading, empty, error, success, and a narrow width (a phone at 320 dp wide, and the side-panel case at 840 dp and up).
  • A skeleton has the same layout as the final content.
  • Respond to a tap within 100 ms. Show a pending state if the work takes more than 400 ms.

Enforced by the lint rule no_hardcoded_colors for colors. No automated check covers the five states, skeleton shape or timing; review them.

Why

Theme tokens keep light, dark and custom themes consistent. Missing states are what people see first when something is slow or wrong. A skeleton that does not match makes the layout jump when data arrives.

How

  • States: import package:flutter_agentify/core/widgets/states/states.dart. It exports LoadingState, EmptyState, ErrorState and the shimmer skeletons (SkeletonListItem, SkeletonCard, SkeletonList). lib/presentation/home/home_screen.dart is the model: itemsAsync.when(loading: ..., error: ... onRetry: () => ref.invalidate(...), data: ...), and an EmptyState with an action when the list is empty.
  • Skeletons: build the placeholder from the same row widget shape (SkeletonListItem for list rows). Wrap in Shimmer / SkeletonList.
  • Status colors: success, warning, info, muted and disabled come from the SemanticColors theme extension in lib/core/theme/app_colors.dart: Theme.of(context).extension<SemanticColors>(). Errors use colorScheme.error.
  • Timing: AppAnimations.durationInstant is 100 ms and durationModerate is 400 ms in lib/core/theme/app_animations.dart. Press feedback uses the 100–150 ms tokens. For work that may run long, show nothing until 400 ms have passed, then a progress or skeleton state, so quick results do not flash.
  • Width: the breakpoint is assistantPanelBreakpoint (840) in lib/presentation/assistant/assistant_shell.dart. Use Expanded, Flexible and maxLines with TextOverflow.ellipsis, not fixed widths on text.
  • Failures from actions: show them with showActionFailure from lib/presentation/action_failure_message.dart.
  • Dialogs close with Navigator.of(context).pop(); open screens with GoRouter.
  • Theme values live in lib/core/theme/app_theme.dart (light, dark). Add a token there before using a new raw value.

Anti-patterns

  • color: Colors.grey or a hex color in a widget.
  • A bare CircularProgressIndicator for a list that has a skeleton available.
  • An empty list that shows a blank screen, or an error that shows a stack trace.
  • A fixed SizedBox(width: 400) around text.
  • Showing a spinner for every call, even one that returns in 50 ms.
  • // ignore: flutter_agentify_lints/no_hardcoded_colors to avoid adding a token.

Verification

  • dart analyze --fatal-infos reports no_hardcoded_colors.
  • Widget tests: test/widgets/loading_state_test.dart, test/widgets/error_state_test.dart, test/presentation/home/home_screen_test.dart.
  • Run the app at a narrow width and in dark mode and look.
  • tool/check.sh ends with All checks passed.

Related skills

  • i18n-and-rtl — strings and mirrored layout.
  • accessibility — touch targets, contrast and labels.
  • state-management — where the loading and error values come from.
  • performance — long lists and smooth frames.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.