agentleFS
CodeCaroSCodeCaroS/MythOs_Aegis/.agents/skills/ui-ux-dropdowns/SKILL.md

ui-ux-dropdowns

Skill0 starsChanged 3 months agoApache-2.0View on GitHub

Generate, implement, or fix dropdowns, selects, comboboxes, popup option lists, and action menus with obvious triggers, collision-aware placement, complete keyboard operation, scalable filtering and virtualization, and fast motion. Use whenever UI work creates or changes a dropdown-style control.

The file

We split this skill into the rules it gives an agent

5 rules. About 0 are common, 2 are distinctive, and 3 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈2

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 3

    Very specific

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

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

    Use a native select when its appearance and behavior meet the brief.

    line 20
  2. Very specific:

    Use arrow keys to move through enabled items, Enter to select or invoke, and Escape to close without applying a pending choice.

    line 43
  3. Distinctive:

    Leave one runnable interaction check covering the changed control.

    line 61
  4. Distinctive:

    Search at 11 items and virtualization at 101 items.

    line 66
  5. Very specific:

    Use real boundary values (10, 11, 100, and 101) instead of assuming the thresholds work.

    line 69

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “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/UX Dropdowns

Build dropdowns that remain obvious, reachable, operable, and fast at every supported size.

Choose the smallest correct control

  1. Use a native select when its appearance and behavior meet the brief.
  2. Otherwise reuse the product's existing select, combobox, popover, or menu primitive.
  3. Distinguish selection controls from action menus and preserve the matching native or WAI-ARIA interaction pattern. Do not add ARIA that duplicates native semantics.

Required rules

1. Make the trigger obvious

  • Show a caret or equivalent disclosure indicator.
  • Provide visible hover, keyboard-focus, open, disabled, and error states where applicable.
  • Give the trigger a minimum 44px by 44px pointer target without forcing the visible control itself to look oversized.
  • Expose the control's name, current value or purpose, and expanded state. Do not rely on color alone to communicate clickability or state.

2. Keep the popup inside the viewport

  • Anchor the popup to its trigger and use collision detection.
  • Open upward when the available space below cannot contain the popup and more useful space exists above.
  • Constrain the popup to the remaining viewport, scroll inside it, and keep the active or selected item visible.
  • Recompute placement after resize, scroll, zoom, filtering, or content-size changes. Never leave the final item unreachable off-screen.

3. Make keyboard navigation complete

  • Let Tab reach the trigger and use Enter or Space to open it.
  • Use arrow keys to move through enabled items, Enter to select or invoke, and Escape to close without applying a pending choice.
  • Return focus to the trigger when the popup closes. Keep focus and selection distinct when the chosen pattern requires it.
  • Preserve native type-ahead or provide equivalent behavior for a custom non-editable list. Keep pointer and touch support in addition to keyboard support.

4. Scale the option list

  • With more than 10 items, add a clearly labelled search field that filters immediately and provides a no-results state.
  • With more than 100 items, virtualize the list while preserving keyboard reachability, active-item scrolling, accessible item count and position, and the selected value.
  • Reuse an installed virtualization primitive before writing windowing logic.

5. Keep motion under 150 milliseconds

  • Complete open and close motion in less than 150ms.
  • Animate compositor-friendly opacity or transform properties, not layout.
  • Resolve the final placement before animating and honor prefers-reduced-motion.

Verification

Leave one runnable interaction check covering the changed control. At minimum, verify:

  • Pointer and focus affordances plus a 44px target.
  • Upward placement at the viewport bottom and full access to the last item.
  • Arrow, Enter, and Escape behavior with focus restoration.
  • Search at 11 items and virtualization at 101 items.
  • Motion duration and reduced-motion behavior.

Use real boundary values (10, 11, 100, and 101) instead of assuming the thresholds work. If runtime verification is unavailable, state exactly which interactions remain unverified.

Output

Return the implementation or component specification first, then the verification result and any remaining runtime limits.

Shared output profile

Compose the execution profile from output-templates. Preserve the required dropdown rules above, omit empty components, and never present static inspection as proof of runtime behavior.

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.