@flood-md/agent 0.2.6 → 0.2.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/DESIGN.md CHANGED
@@ -1,17 +1,46 @@
1
- # Flood design system · 0.2.6
1
+ # Flood design system · 0.2.9
2
+
3
+ ListBox owns native required validation for accepted selection. Use its
4
+ description/message/status props rather than duplicating feedback markup. Visual
5
+ invalid/status flags alone do not block submission; validationMessage supplies a
6
+ host-owned blocking constraint. Readonly retains values and bypasses validity;
7
+ disabled excludes submission. TimePicker keeps its plain manual-selection list.
8
+
9
+ Use TimePicker for civil time suggestions and DateTimeRangePicker for complete,
10
+ ordered civil endpoints. Calendar switches day/month/year views in place. Resolve
11
+ timezones and DST in the host. These are source APIs; check the installed version.
12
+
13
+ ## Composition is built from library primitives
14
+
15
+ Use existing Flood components inside larger components, the website and playgrounds.
16
+ Do not replace them with ordinary text or custom markup to fix a visual issue.
17
+ When a small capability is missing, improve or create that reusable primitive
18
+ first, then compose it. Preserve component anatomy and semantics. The manifest
19
+ ships the composition skill from `references/flood-composition/SKILL.md` to
20
+ project-root `.agents/skills/flood-ui/references/flood-composition/SKILL.md`.
21
+ Apply that skill. Native semantic markup and neutral structural wrappers remain
22
+ valid inside their proper owners.
23
+
24
+
25
+ Readonly date/time entry bypasses native validity constraints while retaining
26
+ accepted canonical values, including values outside current bounds, time steps or
27
+ range availability. Do not silently clear those values. Partial, reversed ranges
28
+ and refused controlled drafts never become accepted by setting readonly. Disabled
29
+ values remain excluded from submission.
2
30
 
3
31
  Read project-root flood.json and installed declarations with this contract.
4
- The source bundle's SKILL.md routes to focused composition, accessibility,
5
- customization and verification references. Its routing matrix names prerequisites
6
- and sources of truth; flood/rules.json indexes observable checks. Read only the
7
- relevant reference. This expanded bundle belongs to 0.2.6; existing installations
8
- keep their matching guide set.
32
+ The installed entry is .agents/skills/flood-ui/SKILL.md; its references live under
33
+ .agents/skills/flood-ui/references/. Read only the relevant composition, spacing,
34
+ accessibility, customization or verification reference. flood/manifest.json maps
35
+ package sources to those installed paths; flood/rules.json indexes observable
36
+ checks. In the Flood repository the corresponding sources are packages/agent/.
37
+ This bundle belongs to 0.2.7; older installations keep their matching guide set.
9
38
 
10
39
  React + TypeScript and Next.js App Router. Use this guide with matching installed
11
40
  Flood packages and flood.json. The source repository's release status does not
12
41
  grant permission to publish or assume a version is available on npm.
13
42
 
14
- This guide covers the supported exports in 0.2.6 and their layout refinements. Confirm
43
+ This guide covers the supported exports in 0.2.7 and their layout refinements. Confirm
15
44
  the matching installed declarations before using APIs absent from older versions.
16
45
 
17
46
  ## Connect
@@ -30,6 +59,9 @@ child. Keep server data fetching in server components.
30
59
  does not associate a form control; use Field.
31
60
  - Reserve display for a marketing headline; preserve normal page/section sizes
32
61
  inside product UI. Hosts own responsive composition.
62
+ - Use Tree for application-object selection and NavigationTree for nested URLs.
63
+ Their expansion and selection/current-location contracts are separate. Do not
64
+ turn ordinary website navigation into an ARIA tree or treat Tree as a form field.
33
65
  - Use CodeSnippet with a code string and optional action slot for commands or
34
66
  short examples. The host owns clipboard permission, feedback and errors;
35
67
  selectable wrapped code remains available when copying fails.
@@ -160,7 +192,10 @@ export function Profile() {
160
192
  ```
161
193
 
162
194
 
163
- 0.2.5 adds Badge, Spinner, Skeleton and Avatar. Read references/composition.md and references/accessibility.md for status announcements, fallback geometry and decorative naming. Button loading reuses Spinner. These APIs are not present in 0.2.3.
195
+ 0.2.5 adds Badge, Spinner, Skeleton and Avatar. Read the installed composition and
196
+ accessibility references under .agents/skills/flood-ui/references/ for status
197
+ announcements, fallback geometry and decorative naming. Button loading reuses
198
+ Spinner. These APIs are not present in 0.2.3.
164
199
 
165
200
  Progress, Meter and Alert are also available in 0.2.5. Distinguish task completion from bounded measurements, preserve names/units, and select alert announcement priority explicitly.
166
201
 
@@ -271,3 +306,137 @@ original OFL notices. Color alone never communicates validation or progress.
271
306
  CodeSnippet codeDirection defaults to ltr independently of RTL parent action layout; choose rtl/auto explicitly for content that needs it. Native dir still applies to the wrapper. Protected ScrollArea reveals focused descendants fully when needed, composes the host focus handler and avoids scrolling to nested top-layer controls.
272
307
 
273
308
  Checkbox, Radio and Switch apply native hidden/dir/lang to their visible label wrapper as well as the input, so a component-local language/direction applies to its whole choice.
309
+
310
+ ## Base capabilities · 0.2.7
311
+
312
+ The added exports are Editable, TagInput, CommandList, DateField, TimeField,
313
+ Calendar, DatePicker, RangeCalendar, DateRangeField, DateRangePicker,
314
+ ResizablePanels, ErrorSummary, ContextMenu, Tree and NavigationTree. Menu preference
315
+ items and submenus extend Menu; a command palette is Dialog + CommandList
316
+ composition, not a separate export. Use the matching installed declarations.
317
+
318
+ ### Editing and commands
319
+
320
+ Editable separates draft and committed value. Enter commits, Escape cancels and
321
+ blurAction selects commit/cancel/none. Controlled value/editing require host
322
+ acceptance; only committed text submits. TagInput accepts free-form tokens while
323
+ MultiSelect selects known option IDs. Only committed tags submit repeated named
324
+ entries. Preserve IME, reset cancellation, required and readonly/disabled behavior.
325
+
326
+ CommandList filters and invokes commands without a submitted selection or modal
327
+ lifecycle. The host owns effects, routing, shortcuts and closure. Compose Dialog
328
+ around it for a command palette; preserve input naming, active-option semantics,
329
+ disabled/loading states and existing Escape ownership.
330
+
331
+ Menu preferences expose controlled aria-checked states and labelled radio groups;
332
+ the host owns exclusivity. Preference activation stays open unless closeOnSelect
333
+ requests dismissal; commands dismiss and call onAction. Nested submenus and
334
+ ContextMenu reuse this action engine. ContextMenu opens from pointer context or
335
+ ContextMenu/Shift+F10; provide a visible Menu alternative for touch. None is a
336
+ native form-selection control or a data-fetching service.
337
+
338
+ ### Civil dates, time and ranges
339
+
340
+ DateField owns canonical Gregorian YYYY-MM-DD dates, not timestamps or time zones.
341
+ Keep labelled text segments, explicit order and native required/bounds validity.
342
+ Invalid drafts cannot submit an old canonical date. validationMessage adds a host
343
+ native constraint without overriding own calendar errors. TimeField uses 24-hour
344
+ HH:mm or HH:mm:ss precision and seconds-based steps; do not invent AM/PM,
345
+ overnight bounds, zone conversion or combined date-time semantics.
346
+
347
+ Calendar owns a single-date grid. DatePicker composes DateField, Calendar and
348
+ Popover, keeping native forms, controlled state and focus ownership intact.
349
+ onDateSelect confirms allowed activation even when the value is unchanged.
350
+ Translate calendar labels, segment names and validation messages. Calendar Intl
351
+ formatting is explicitly Gregorian UTC, weekStartsOn remains explicit and today
352
+ can provide deterministic rendering.
353
+
354
+ RangeCalendar selects one inclusive interval start then end; hover/focus previews
355
+ are uncommitted. DateRangeField owns paired text entry and atomic startName/endName
356
+ bridges; DateRangePicker composes the pair with one popup. Values are {start,end}
357
+ with empty strings for empty/partial endpoints. Controlled hosts must accept
358
+ partial starts to advance calendar selection. Calendar gestures normalize earlier
359
+ endpoints; typed reversed drafts stay editable and invalid. Partial, reversed,
360
+ unavailable or refused pairs never submit one new endpoint beside an old one.
361
+ isDateDisabled blocks endpoints; interior blocked dates are allowed unless
362
+ isRangeDisabled rejects the interval. Apply the same predicates to typed entry.
363
+ Escape/outside dismissal may leave an accepted partial range; do not manufacture
364
+ completion to make the form valid. Preserve reset cancellation and return focus.
365
+
366
+ ### Hierarchy, layout and error ownership
367
+
368
+ Tree selects application objects through independent value and expandedValues
369
+ contracts. Keep globally unique item values and noninteractive icons/descriptions.
370
+ Descriptions participate in each row's accessible name; descendant labels do not.
371
+ Arrows/Home/End/typeahead move focus independently from selection. Collapsing
372
+ retains known selected descendants; removed/nonselectable values are excluded
373
+ from later selection requests. Deferred hasChildren/loading branches belong to
374
+ the host; no fetching or virtualization is implied.
375
+
376
+ Tree readonly prevents selection while retaining browse/expand behavior. Translate
377
+ readOnlyMessage for the associated explanation; tree/treeitem do not support
378
+ aria-readonly. Disabled rows remain discoverable but cannot select/expand; item
379
+ restrictions do not implicitly cascade. Tree submits no form values and does not
380
+ automatically inherit a native fieldset's disabled state.
381
+
382
+ NavigationTree uses native nav/list/links and normal Tab order. A destination and
383
+ its disclosure are separate controls, so expansion does not navigate. The host
384
+ owns currentValue, hrefs and expanded ancestors. Preserve linkProps, modifier
385
+ navigation, localized disclosure labels and distinct disabled states.
386
+
387
+ ResizablePanels owns constrained pointer/keyboard geometry and separator keys;
388
+ its value is the main pane's percentage after the separator. The host supplies
389
+ vertical height, content scrolling and persistence. Preserve RTL, cancellation,
390
+ focus transfer and inert zero-sized panes. Use static Split when resizing is not
391
+ needed. ErrorSummary receives host errors with exact field IDs. It links/focuses
392
+ those controls without validating, expanding sections or submitting. Opt into
393
+ autofocus/announcement deliberately for the host's submission lifecycle.
394
+
395
+ Required, status, loading, empty and readonly contracts are component-specific.
396
+ Preserve native validity and cancelled resets where supported; do not infer a
397
+ form contract from Tree/Menu/CommandList selection or active state. Package source
398
+ availability and focused examples do not prove registry publication, deployment
399
+ or accessibility of the host application.
400
+
401
+ ## Extended controls in 0.2.8
402
+
403
+ HoverCard opens a named interactive preview on hover or focus and supports explicit
404
+ activation. Use Tooltip for short noninteractive descriptions. ColorSwatch and
405
+ ColorPicker use opaque RGB hex colors; they do not imply alpha, gradients or a
406
+ contrast guarantee. TreeSelect provides single hierarchical selection; Tree
407
+ remains the standalone single/multiple control. DateTimePicker composes civil
408
+ date and clock time with separate form values and no inferred timezone. Use
409
+ application validation for relationships between the parts. Recipes for Select
410
+ all, split actions and form submission live in the public user documentation.
411
+
412
+ DataList/DataListItem are native list content, not selection widgets. Keep links
413
+ in the title and actions separate; do not turn the whole row into a button.
414
+ CheckCard/RadioCard compose the native choice primitives into clickable labels.
415
+ Keep their description, icon and metadata noninteractive. Use one radio name and
416
+ an enclosing Fieldset for exclusive choices; derive aggregate checkbox state
417
+ in the host. Read-only choice cards preserve submission and block editing; apply
418
+ readOnly to an entire radio group consistently.
419
+
420
+ DataTable pages and sorts one complete client-side collection. It is not a
421
+ server query engine or a virtualized grid. Rich cells require explicit sortValues
422
+ when they are sortable. Select all affects the current page only and preserves
423
+ other pages; permission-restricted rows use selectionDisabled. Native links and
424
+ actions in cells remain independent. Compose search and filters at the host
425
+ boundary, reset page deliberately and specify the intended selection lifetime.
426
+ Use Table + Pagination for remote pagination rather than passing one remote page
427
+ into the client-paginated DataTable.
428
+
429
+ FileItem/FileList display host-owned attachment metadata; UploadItem/UploadList
430
+ display explicit queued/uploading/success/error/cancelled states. Cancel and retry
431
+ callbacks are intents, not an upload engine. Do not show success merely because
432
+ bytes reach100%; wait for the host confirmation. Use stable IDs, not filenames,
433
+ for identity. FileInput retains native form ownership; removing a display row
434
+ does not alter its FileList. ImagePreview reuses Dialog; the host owns trusted
435
+ URLs, blob URL lifetime, download permissions and image alt text. No built-in
436
+ network, file reading or object URL creation is implied by these components.
437
+
438
+ FileMeta combines a display format label and byte size in one quiet chip. FileItem
439
+ and UploadItem place it with the filename, reserving the next line for status or
440
+ supporting text. Filename extensions are display hints only, never validation.
441
+ Override with format or hide the format using format=null; do not infer upload
442
+ safety or MIME permissions from a visible chip.
package/README.md CHANGED
@@ -1,22 +1,31 @@
1
1
  # @flood-md/agent
2
2
 
3
3
  Version-matched guidance for Flood React/Next.js projects. Read the installed
4
- contract before composing screens. The 0.2.6 reference bundle includes spacing
4
+ contract before composing screens. The 0.2.9 reference bundle includes spacing
5
5
  guidance, routing and observable rules. These files grant
6
6
  no authority to modify external services.
7
7
 
8
+ The source bundle also includes ten routed workflows for the existing dark base:
9
+ composition, spacing, foundations, accessibility, forms, overlays, navigation,
10
+ data display, feedback and verification. The lightweight flood-ui entry selects
11
+ relevant skills; nested folders do not imply independent automatic discovery.
12
+ workflows.json describes applicability. rules.json describes observable checks;
13
+ neither is a completed component-audit report or executable enforcement engine.
14
+
8
15
  | Source | Role |
9
16
  | --- | --- |
10
17
  | DESIGN.md | Shared versioned UI/component contract |
11
18
  | SKILL.md | Short entry and task router |
12
19
  | references/routing.md | Applicability, audience, prerequisites and governing source |
13
20
  | references/composition.md | Screen/form composition workflow |
21
+ | references/flood-composition/SKILL.md | Full primitives-first composition skill routed from flood-ui |
14
22
  | references/spacing.md | Measured spacing, density, nested geometry and hit areas |
15
23
  | references/accessibility.md | Interaction and perception checks |
16
24
  | references/customization.md | Scoped semantic customization |
17
25
  | references/verification.md | Evidence before reporting completion |
18
26
  | rules.json | Stable rule IDs with conditions, sources and observable checks |
19
27
  | manifest.json | Source → installed-path mapping used by the CLI |
28
+ | workflows.json | Component-family applicability and routed full-skill sources |
20
29
 
21
30
  CLI init copies every manifest entry into an unused owned path. Doctor checks
22
31
  expected regular files without linked destinations. Neither tool rewrites host
package/SKILL.md CHANGED
@@ -19,11 +19,18 @@ invented as a package API. No external component library or parallel token syste
19
19
 
20
20
  | Work | Read next | Required result |
21
21
  | --- | --- | --- |
22
+ | Component, composite, website or playground UI | [Composition skill](references/flood-composition/SKILL.md) | Reused primitives; missing small capabilities implemented before composites |
22
23
  | New screen, layout or form | [Composition](references/composition.md) | Existing primitives, correct host width and form ownership |
23
- | Spacing, density, nested geometry or shifting previews | [Spacing](references/spacing.md) | Measured visual relationships and nonoverlapping interactive areas |
24
- | Keyboard, validation, names or states | [Accessibility](references/accessibility.md) | Real interaction and associations preserved |
25
- | Brand, colors or typography | [Customization](references/customization.md) | Scoped semantic overrides; unchanged behavior |
26
- | Completion, regression or upgrade review | [Verification](references/verification.md) | Checks and limits reported against the actual host |
24
+ | Spacing, density, nested geometry or shifting previews | [Spacing skill](references/flood-spacing/SKILL.md) | Measured visual relationships and nonoverlapping interactive areas |
25
+ | Existing dark surfaces, type, control and icon sizing | [Foundations skill](references/flood-foundations/SKILL.md) | Correct semantic roles and coherent consumers |
26
+ | Keyboard, names, focus, perception or reflow | [Accessibility skill](references/flood-accessibility/SKILL.md) | Real interaction and associations preserved |
27
+ | Field ownership, validation, submission and reset | [Forms skill](references/flood-forms/SKILL.md) | Actual form values and accepted/refused transitions |
28
+ | Popup, dialog, drawer or nested layer | [Overlays skill](references/flood-overlays/SKILL.md) | Appropriate geometry, dismissal and focus ownership |
29
+ | Destinations, panels, disclosure or hierarchy | [Navigation skill](references/flood-navigation/SKILL.md) | Navigation, selection and expansion kept distinct |
30
+ | Tables, lists, cards, files and long content | [Data display skill](references/flood-data-display/SKILL.md) | Meaningful structures and reachable overflow |
31
+ | Status, progress, alerts, loading or empty content | [Feedback skill](references/flood-feedback/SKILL.md) | Honest operation state with one announcement owner |
32
+ | Brand or deliberate semantic overrides | [Customization](references/customization.md) | Scoped semantic overrides; unchanged behavior |
33
+ | Completion, stabilization or regression review | [Verification skill](references/flood-verification/SKILL.md) | Checks and limits reported against the actual host |
27
34
  | Decide which document governs a change | [Routing and sources](references/routing.md) | Source of truth and prerequisites identified |
28
35
 
29
36
  The project-root flood/rules.json lists stable rule IDs and their observable
@@ -31,5 +38,10 @@ checks; it is an index, not executable policy. At completion report which checks
31
38
  ran, their result and any unverified behavior. Doctor checks installation only.
32
39
  Guidance cannot guarantee an agent's compliance or certify application accessibility.
33
40
 
41
+ The workflow index lists component-family applicability, not a requirement to load
42
+ every skill or proof that a component passed its checks. These specialized skills
43
+ are routed references inside flood-ui; independent discovery of nested folders
44
+ is not assumed. Resolve sources through the installed manifest when needed.
45
+
34
46
  Preserve existing instructions and customized guides. This skill authorizes no
35
47
  deployment, deletion, external messages or sending host source to other services.
package/manifest.json CHANGED
@@ -51,9 +51,64 @@
51
51
  "source": "references/spacing.md",
52
52
  "target": ".agents/skills/flood-ui/references/spacing.md",
53
53
  "kind": "reference"
54
+ },
55
+ {
56
+ "source": "references/flood-composition/SKILL.md",
57
+ "target": ".agents/skills/flood-ui/references/flood-composition/SKILL.md",
58
+ "kind": "skill"
59
+ },
60
+ {
61
+ "source": "workflows.json",
62
+ "target": ".agents/skills/flood-ui/workflows.json",
63
+ "kind": "reference"
64
+ },
65
+ {
66
+ "source": "references/flood-spacing/SKILL.md",
67
+ "target": ".agents/skills/flood-ui/references/flood-spacing/SKILL.md",
68
+ "kind": "skill"
69
+ },
70
+ {
71
+ "source": "references/flood-foundations/SKILL.md",
72
+ "target": ".agents/skills/flood-ui/references/flood-foundations/SKILL.md",
73
+ "kind": "skill"
74
+ },
75
+ {
76
+ "source": "references/flood-accessibility/SKILL.md",
77
+ "target": ".agents/skills/flood-ui/references/flood-accessibility/SKILL.md",
78
+ "kind": "skill"
79
+ },
80
+ {
81
+ "source": "references/flood-forms/SKILL.md",
82
+ "target": ".agents/skills/flood-ui/references/flood-forms/SKILL.md",
83
+ "kind": "skill"
84
+ },
85
+ {
86
+ "source": "references/flood-overlays/SKILL.md",
87
+ "target": ".agents/skills/flood-ui/references/flood-overlays/SKILL.md",
88
+ "kind": "skill"
89
+ },
90
+ {
91
+ "source": "references/flood-navigation/SKILL.md",
92
+ "target": ".agents/skills/flood-ui/references/flood-navigation/SKILL.md",
93
+ "kind": "skill"
94
+ },
95
+ {
96
+ "source": "references/flood-data-display/SKILL.md",
97
+ "target": ".agents/skills/flood-ui/references/flood-data-display/SKILL.md",
98
+ "kind": "skill"
99
+ },
100
+ {
101
+ "source": "references/flood-feedback/SKILL.md",
102
+ "target": ".agents/skills/flood-ui/references/flood-feedback/SKILL.md",
103
+ "kind": "skill"
104
+ },
105
+ {
106
+ "source": "references/flood-verification/SKILL.md",
107
+ "target": ".agents/skills/flood-ui/references/flood-verification/SKILL.md",
108
+ "kind": "skill"
54
109
  }
55
110
  ],
56
- "version": "0.2.6",
111
+ "version": "0.2.9",
57
112
  "installedEntry": ".agents/skills/flood-ui/SKILL.md",
58
113
  "pathBase": "source is package-relative; target is relative to the host project root"
59
114
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flood-md/agent",
3
- "version": "0.2.6",
3
+ "version": "0.2.9",
4
4
  "type": "module",
5
5
  "description": "Versioned Flood design instructions for coding agents.",
6
6
  "license": "MIT",
@@ -13,6 +13,7 @@
13
13
  "DESIGN.md",
14
14
  "SKILL.md",
15
15
  "references",
16
+ "workflows.json",
16
17
  "rules.json",
17
18
  "manifest.json",
18
19
  "README.md"
@@ -22,6 +23,7 @@
22
23
  "./SKILL.md": "./SKILL.md",
23
24
  "./manifest.json": "./manifest.json",
24
25
  "./rules.json": "./rules.json",
26
+ "./workflows.json": "./workflows.json",
25
27
  "./references/*": "./references/*"
26
28
  },
27
29
  "publishConfig": {
@@ -1,5 +1,15 @@
1
1
  # Compose an interface
2
2
 
3
+ Apply the [Flood composition skill](flood-composition/SKILL.md) before building
4
+ or changing UI. Reuse the existing semantic primitive, including inside library
5
+ components. Fix its layout or extend its API instead of substituting custom markup.
6
+
7
+ Use Tree for hierarchical application selection, with explicit value and expansion
8
+ ownership. Use NavigationTree for nested destinations: preserve native links and
9
+ their browser behavior rather than forcing a website sidebar into tree/menu roles.
10
+ Do not infer cascading selection, lazy fetching, form submission or expansion of
11
+ current-page ancestors. Keep item values globally unique and text labels present.
12
+
3
13
  For spacing, density or nested-geometry decisions, read [Spacing](spacing.md).
4
14
  Measure the complete row geometry before adding a gap to repeated controls.
5
15
 
@@ -267,3 +277,5 @@ host-owned. No third-party component implementation was introduced.
267
277
  Section headingLevel controls native h2–h6 semantics. Its independent headingSize
268
278
  uses the existing Heading roles (section/page/large/display), defaulting to section.
269
279
  Keep document hierarchy meaningful when changing visual emphasis.
280
+
281
+ For a command palette, compose Dialog and CommandList. The host owns commands, permissions, query reset and shortcuts; keep Escape available to the dialog. Avoid a duplicate modal or command-search engine. The project recipe lives in docs/recipes/command-palette.md in the source repository.
@@ -0,0 +1,40 @@
1
+ ---
2
+ name: flood-accessibility
3
+ description: Review Flood interface names, keyboard flow, focus, perception and reflow in the actual host. Use for interaction or accessibility acceptance.
4
+ ---
5
+
6
+ # Review an actual task
7
+
8
+ Use [accessibility](../accessibility.md) and the installed component's contract.
9
+ A scanner result is supporting evidence, not certification of an application.
10
+
11
+ ## Trace the task from entry to completion
12
+
13
+ - Identify the name, role, state and instruction for each actionable control.
14
+ Retain native semantics before adding ARIA. A placeholder, color or tooltip
15
+ alone is not an adequate field name or required instruction.
16
+ - If a visible label is intentionally hidden, preserve the supplied label/legend
17
+ through the supported API and verify its contextual meaning and focus reveal.
18
+ Do not remove the label or invent unsupported hideLabel props on bare controls.
19
+ - Complete the task with keyboard only, including reverse navigation, cancel,
20
+ invalid submission and recovery. Distinguish roving focus, selection and
21
+ activation; arrow behavior follows the specific component contract.
22
+ - After pointer activation of a custom keyboard-owning control, inspect actual
23
+ focus before testing keys. Some browsers do not mouse-focus native buttons;
24
+ a custom combobox cannot rely on that default. Preserve an intentional focus
25
+ move made by the host callback rather than forcing focus back afterward.
26
+ - Check the accent focus perimeter in combinations with invalid, selected and
27
+ read-only states. It must remain visible without changing layout or hiding
28
+ beneath a rail, sticky region or overlay. Closing an overlay returns focus
29
+ appropriately without overriding a deliberate host focus move.
30
+ - Evaluate text with its actual size, weight and composited background using
31
+ applicable WCAG checks and supplementary APCA guidance. Decorative lines are
32
+ different from necessary control/state indicators; do not relabel a necessary
33
+ cue as decoration to avoid checking it. APCA is not WCAG conformance.
34
+ - Exercise narrow width, root text enlargement, long content, RTL where supported,
35
+ forced colors and the existing reduced-motion fallback. These checks do not
36
+ introduce new animation or theme requirements.
37
+
38
+ For assistive-technology announcements, inspect live-region semantics and test
39
+ with the actual technology when available. Do not report audible announcements
40
+ from a DOM role alone. Record any device/technology that was not tested.
@@ -0,0 +1,63 @@
1
+ ---
2
+ name: flood-composition
3
+ description: Build or review Flood UI from existing library primitives before adding composites. Use for component, website, playground and host-interface work, especially when a layout fix risks replacing a reusable element with custom markup.
4
+ ---
5
+
6
+ # Compose Flood from its primitives
7
+
8
+ Existing Flood components are the building blocks, including inside other Flood
9
+ components. Preserve their anatomy and behavior when improving a composition.
10
+ Read the governing project instructions, matching declarations and relevant
11
+ component guide first. This skill grants no additional permissions.
12
+
13
+ ## Choose the smallest existing owner
14
+
15
+ Before changing JSX, identify the visible roles and their existing owners:
16
+ StatusIndicator for a named state, Progress for progress, Badge/FileMeta for
17
+ metadata, IconButton for an icon action, Dialog for modal behavior, Text/Heading
18
+ for typography, and the appropriate form, list or table primitive for semantics.
19
+ Check the actual installed exports and props; do not invent APIs from newer docs.
20
+
21
+ - Reuse the matching component with its supported props and tokens.
22
+ - If spacing or alignment is wrong, inspect both the primitive and the parent
23
+ composition. Fix the owner of the relationship. Keep the primitive intact.
24
+ - If a primitive lacks a real reusable capability, improve that primitive first,
25
+ with an intentional API/variant and the matching docs and checks, then compose it.
26
+ - If no primitive exists, build the small reusable component before the larger
27
+ composition. Define its semantics, anatomy, states and size before exposing it.
28
+
29
+ In the Flood library, add public primitives through the source API, catalog,
30
+ declarations, guidance and current version decision. In a consuming application,
31
+ do not pretend that an uninstalled export exists: use the supported primitives or
32
+ an explicitly project-owned adapter, and identify any upstream gap.
33
+
34
+ ## Do not bypass a component to fix its appearance
35
+
36
+ Do not replace StatusIndicator with a styled span, Badge with a handmade chip,
37
+ Progress with a local track, or Dialog with a parallel modal merely to make one
38
+ example fit. Do not hide a component's glyph, label, focus state or other anatomy
39
+ through descendant CSS and reproduce it beside the component. Intentional variants
40
+ belong in the primitive's API, not in a consumer-specific imitation.
41
+
42
+ For example, an upload row keeps StatusIndicator and Progress as separate reused
43
+ components. Its parent aligns their centers and controls the gap; it does not
44
+ remove the status dot or replace the status with ordinary text. Fix internal dot
45
+ alignment in StatusIndicator only if the primitive itself is wrong.
46
+
47
+ Native semantic markup is necessary inside primitive implementations. Content
48
+ strings and neutral structural wrappers are also valid in compositions. They must
49
+ not introduce a competing visual or behavioral component. A wrapper that starts
50
+ owning a reusable role should become a named small component instead.
51
+
52
+ ## Review the composed result
53
+
54
+ Check the reused component and its neighboring elements in the real host: wide
55
+ and narrow layout, enlarged text, long labels, optional content and relevant
56
+ interaction states. Measure the visible glyph/text/control centers when alignment
57
+ is the issue. Keep focus, accessible names, callbacks and native form semantics.
58
+
59
+ If changing a shared primitive, check another consumer of it. Report which
60
+ components were reused, which primitive changed or was added, and what remains
61
+ unverified. A new wrapper name alone is not evidence of reuse. Use the project's
62
+ verification scope; this guidance does not require a full release run for every
63
+ local design adjustment.
@@ -0,0 +1,37 @@
1
+ ---
2
+ name: flood-data-display
3
+ description: Assemble Flood tables, lists, cards and file records with long or changing data. Use for content hierarchy, overflow, row actions and data-state composition.
4
+ ---
5
+
6
+ # Compose meaningful data structures
7
+
8
+ Use the installed component contracts and
9
+ [composition workflow](../flood-composition/SKILL.md). Start with the content's
10
+ relationships, not a wrapper around every piece of text.
11
+
12
+ - Table/DataTable preserve caption, headers, cell relationships and documented
13
+ sorting/selection behavior. A footer represents a summary and should be
14
+ visually distinguishable without relying on a heavy border everywhere.
15
+ - DescriptionList expresses named values; DataList/DataListItem express records.
16
+ Card/Section/Surface organize groups without inventing a second typography or
17
+ spacing system. A heading's semantic level does not prescribe its visual size.
18
+ - Keep row actions as named Flood Button/IconButton/Menu controls. Do not turn
19
+ a whole row into a competing clickable wrapper around its nested actions.
20
+ - FileItem/FileMeta/UploadItem and their list owners compose file presentation;
21
+ use their existing format/size/status/progress primitives. Selection, transport
22
+ and preview are separate host operations. Do not manufacture upload completion.
23
+ - Preserve native image alt/fallback semantics and aspect constraints. Decorative
24
+ artwork should not duplicate an adjacent accessible identity.
25
+
26
+ ## Exercise data and geometry
27
+
28
+ Test no records, one record, long/wrapping names, absent optional media/actions,
29
+ loading, error/retry and selection/sorting where available. Keep error text useful
30
+ without inserting a second empty-state design or moving unrelated controls.
31
+ Align file title/metadata and status/progress by their intended row relationship;
32
+ do not hide a StatusIndicator dot or replace Progress with a custom track.
33
+
34
+ Use the documented local overflow owner, with a meaningful accessible name. Focus
35
+ the last action/cell and check that a rail or rounded corner does not cover it.
36
+ Compare narrow/wide, enlarged text and RTL. Locale-sensitive text in prerendered
37
+ examples needs consistent server/client locale to avoid hydration differences.
@@ -0,0 +1,37 @@
1
+ ---
2
+ name: flood-feedback
3
+ description: Choose Flood status, progress, alert, loading and empty-state feedback with honest operation state. Use for meaningful messages and announcement ownership.
4
+ ---
5
+
6
+ # Describe what actually happened
7
+
8
+ Use installed declarations and [accessibility](../accessibility.md). Assign the
9
+ visible role before choosing color: StatusIndicator names a state, Badge marks
10
+ metadata, Progress describes task progress, Meter describes a bounded measurement,
11
+ Alert gives contextual feedback and EmptyState explains missing content.
12
+
13
+ ## Keep one owner for each message
14
+
15
+ - Status text must distinguish pending, success, failure, cancellation and local
16
+ preview state. A callback firing or elapsed timer is not a completed backend
17
+ operation. Do not display a success count, upload or save that did not occur.
18
+ - Unknown Progress has no known percentage; Meter has no unknown state. A useful
19
+ label/valueText explains units when a percentage would be misleading.
20
+ - Alert/Toast/live-region choices depend on urgency. Keep static explanation
21
+ silent unless a change requires announcement; do not add multiple live regions
22
+ around a composite's existing announcement. Announce does not imply a visible
23
+ style change or guarantee speech from every assistive technology.
24
+ - Spinner retains a meaningful accessible label where standalone. Skeleton is
25
+ decoration, not another announced task. Preserve the existing reduced-motion
26
+ behavior without introducing a new animation system.
27
+ - EmptyState needs a reason and an appropriate next action when available. Its
28
+ icon/illustration and action remain existing primitives with consistent geometry.
29
+
30
+ ## Evidence
31
+
32
+ Trigger the operation and observe each applicable transition, including failure
33
+ and retry. Check optional description/action/icon slots, long messages and text
34
+ enlargement. Keep content visible without stealing focus merely to announce it.
35
+ Reserve feedback space in a demo when needed for a stable sample, not universally
36
+ inside every production component. Report audible announcement behavior only
37
+ when it was actually tested with the relevant assistive technology.
@@ -0,0 +1,45 @@
1
+ ---
2
+ name: flood-forms
3
+ description: Compose and verify Flood form ownership, labels, values, validation and reset. Use for fields, selection controls or composed form inputs.
4
+ ---
5
+
6
+ # Preserve the form contract
7
+
8
+ Consult installed declarations and the matching component guide before choosing
9
+ props. The [composition reference](../composition.md) documents selection and file
10
+ ownership. Read the matching DateField/DateTimePicker component guide for its
11
+ specific civil-value and draft contract; [accessibility](../accessibility.md)
12
+ documents associations and feedback.
13
+
14
+ ## Assign ownership
15
+
16
+ - Field supplies label/description/error associations through its render props;
17
+ spread those props onto the actual Flood control. Fieldset groups related
18
+ controls with a legend; each choice still needs its own meaningful label.
19
+ - Decide controlled value/onValueChange versus uncontrolled defaultValue. A
20
+ default initializes; changing it is not an update contract. Handle host refusal
21
+ of a requested value without reporting that it was saved or losing focus.
22
+ - Set native name/form/required and submit/reset button types deliberately.
23
+ Inspect FormData, including repeated checkbox names with getAll and the
24
+ component's documented submission shape. Visible prefixes are not submitted
25
+ values; Token/Tag/Toggle actions are not automatically native form inputs.
26
+ - Read-only and disabled are different. Use readOnly only where the installed
27
+ API supports it; retain copy/focus/submission as documented. Disabled values
28
+ are excluded from native submission. Do not synthesize read-only behavior by
29
+ disabling unrelated controls or hiding a field's value.
30
+ - Error is invalid; warning/success/info are advisory, not validation algorithms.
31
+ Host validation decides the error and useful message. Keep native constraints,
32
+ invalid focus and the accessible message association coherent.
33
+
34
+ ## Exercise transitions, not just props
35
+
36
+ Check entry, clear, incomplete drafts, invalid input, accepted/refused controlled
37
+ updates, submit and normal/cancelled reset where supported. Match date/time
38
+ default values to the selected precision and remount only the demo when a changed
39
+ representation genuinely requires it. Do not silently replace user edits.
40
+
41
+ FileInput cannot receive a fabricated FileList or ordinary controlled text value.
42
+ Separate selection from upload transport and progress. Calendar/date/time controls
43
+ represent their documented civil values; do not infer a timezone or server save.
44
+ Show a real success only after the host operation succeeds. In a local example,
45
+ state explicitly that changes are local.
@@ -0,0 +1,37 @@
1
+ ---
2
+ name: flood-foundations
3
+ description: Apply Flood's existing dark semantic surfaces, typography, control sizing and icon geometry. Use for foundation consistency or token-consumer review.
4
+ ---
5
+
6
+ # Apply the dark foundations
7
+
8
+ Use the installed declarations, token manifest and DESIGN contract. This workflow
9
+ applies the existing dark base; it does not start a palette, theme or motion redesign.
10
+
11
+ ## Decide the role before the value
12
+
13
+ - FloodRoot owns the dark profile; import the shared stylesheet once in the host.
14
+ A legacy light control outside it is not evidence of a supported new theme.
15
+ - Distinguish reference values, semantic roles, component recipes and host layout.
16
+ In a consumer override an existing semantic role on a deliberate scope; never
17
+ edit node_modules. In Flood source, author tokens only in tokens.json.
18
+ - Choose canvas, container, field and floating-surface roles from their actual
19
+ context. A floating surface must remain legible over its parent; inspect alpha
20
+ compositing, its perimeter and shadow together rather than darkening everything.
21
+ - Decorative dividers, necessary control boundaries, selection and keyboard focus
22
+ have different jobs. Do not substitute an emphasized border for a quiet divider
23
+ or mute an entire control to soften one line. Focus remains a clear accent.
24
+ - Heading level expresses document structure; visual size is a separate decision.
25
+ Supporting labels/descriptions stay subordinate without becoming unreadable.
26
+ - Preserve rem sizing, the host root font, role line height and tracking. IconSlot
27
+ owns explicit artwork dimensions; IconButton owns the accessible action/target.
28
+ A large control does not mean an unconstrained SVG or oversized supporting copy.
29
+
30
+ ## Evidence
31
+
32
+ Trace a changed role to its consumers and compare resting, hover, selected,
33
+ focused, disabled and advisory/error states where applicable. Inspect a field on
34
+ a Surface and a popup over that field; inspect long text and enlarged root text.
35
+ Do not claim visual consistency from token names or matching hex values alone.
36
+ See [customization](../customization.md) and
37
+ [accessibility](../accessibility.md) for perception/override details.
@@ -0,0 +1,35 @@
1
+ ---
2
+ name: flood-navigation
3
+ description: Choose and verify Flood links, tabs, disclosure and hierarchical navigation. Use when destination, selection and expansion semantics can be confused.
4
+ ---
5
+
6
+ # Separate destination, selection and disclosure
7
+
8
+ Use installed declarations and the [composition reference](../composition.md).
9
+ Choose Link/NavigationList/NavigationTree for destinations; Tree for application
10
+ object selection; Tabs for associated panels; Accordion/Collapsible for disclosure.
11
+ SegmentedControl selects one value and is not a tab panel controller. Do not use
12
+ Menu just because links appear vertically.
13
+
14
+ ## Preserve browser and keyboard behavior
15
+
16
+ - Links retain real href, modifier/open-in-new-tab behavior and current-page
17
+ indication. A route change and a selection change are not interchangeable.
18
+ - Hierarchical items need stable unique values and readable labels. Expansion,
19
+ current destination, selection and keyboard focus have separate owners. Do not
20
+ infer cascading selection, automatic fetching or ancestor expansion.
21
+ - Apply each component's keyboard contract. ButtonGroup keeps ordinary Tab
22
+ navigation; Toolbar, Tabs and selection widgets have their own focus models.
23
+ Avoid adding generic arrow-key handlers around nested interactive content.
24
+ - Disclosure state must match its trigger and panel. Check whether content remains
25
+ mounted, and preserve any native form/focus consequences of the installed API.
26
+
27
+ ## Evidence
28
+
29
+ Exercise forward/back navigation, current state, disabled/empty items, long labels,
30
+ both orientations when supported and keyboard entry/exit. For breadcrumbs, check
31
+ intrinsic text width and wrapping in each supported browser: a final letter on a
32
+ new line can indicate a sizing error rather than a legitimate responsive layout.
33
+ For sidebar navigation, scroll/focus the final item and keep its selected surface
34
+ clear of the scrollbar. Verify the actual navigation composition at narrow width
35
+ and enlarged text; an isolated item's screenshot is insufficient.
@@ -0,0 +1,45 @@
1
+ ---
2
+ name: flood-overlays
3
+ description: Compose or review Flood dialogs, drawers, popovers, menus and anchored selection surfaces. Use for popup geometry, nested dismissal or focus ownership.
4
+ ---
5
+
6
+ # Give each layer an owner
7
+
8
+ Use the actual installed overlay and trigger contract; see
9
+ [accessibility](../accessibility.md) for native/dialog/menu behavior. Tooltip is
10
+ noninteractive help; interactive content needs the appropriate Popover or dialog.
11
+ Do not put an action inside a tooltip or apply application-menu roles to site links.
12
+
13
+ ## Preserve trigger and state
14
+
15
+ Forward trigger props/ref onto one mounted native action. Preserve its accessible
16
+ name and open/controls semantics. Choose host-controlled open state or a default,
17
+ and test a host refusing an open/close request. Do not claim control state changed
18
+ merely because a callback ran. The host owns persistent values in unmounted panels.
19
+
20
+ Modal and nonmodal focus are different: do not add a trap to every floating
21
+ surface or remove a modal's background inertness. Escape dismisses the active
22
+ layer; a nested menu/select must not also close its parent dialog. Restore opener
23
+ focus unless the host intentionally moved it elsewhere.
24
+
25
+ ## Inspect the actual host
26
+
27
+ Check placement at viewport edges, resize, narrow/enlarged text, RTL and parent
28
+ scrolling. Selection popups and calendar popups have distinct content geometry;
29
+ use the supported field/anchor sizing behavior, not a universal fixed width.
30
+ Verify nested radii/insets, surface distinction over a parent Surface and that
31
+ essential content stays outside scrollbar rails. No clipping or noisy duplicate
32
+ contours should be concealed with extra wrappers.
33
+
34
+ Drawers must reach the selected viewport edge even with a page scrollbar gutter.
35
+ For a shared Drawer correction check all supported sides; in a host composition
36
+ check the sides that host actually uses. Check long scrollable content, title/description spacing
37
+ and the close IconButton. Verify scroll locking/restoration and nested focus in
38
+ the real composition. CSS elevation tokens alone do not implement these behaviors.
39
+
40
+ Inspect the useful reading area, not only whether the panel fits the viewport.
41
+ At enlarged text, inherited padding and a long fixed header/footer can consume
42
+ the body. Keep enough width for readable text and enough height to review it;
43
+ allow a reachable whole-panel scroll fallback when fixed chrome cannot fit.
44
+ Do not shorten every host title or reduce the user's font size to conceal a
45
+ shared Drawer sizing problem.
@@ -0,0 +1,46 @@
1
+ ---
2
+ name: flood-spacing
3
+ description: Diagnose Flood spacing, density, nested radii and alignment from rendered geometry. Use for large gaps, crowded rows or shifting compositions.
4
+ ---
5
+
6
+ # Measure the relationship
7
+
8
+ Read the [spacing reference](../spacing.md), installed component anatomy and
9
+ host content requirements. Existing user-approved geometry governs the task.
10
+
11
+ Identify what a gap separates: indicator/text, title/description, related choices,
12
+ independent actions, sections, or nested surfaces. Do not propagate one gap to
13
+ every wrapper. Stack and Inline organize relationships; component padding and
14
+ line height still contribute to the visible distance.
15
+
16
+ ## Find the owner
17
+
18
+ Inspect bounding rectangles plus computed padding, margin, gap, minimum height
19
+ and line height. For centered repeated rows, visible glyph separation includes
20
+ row height minus glyph height plus the row gap. A zero gap can still be spacious.
21
+
22
+ Remove redundant space at the layer that creates it. Preserve the choice glyph
23
+ and label pair, explicit icon dimensions and nonoverlapping click targets. Avoid
24
+ negative margins or transforms that merely hide a bad parent relationship.
25
+
26
+ For a nested surface, compare its radius with the outer radius minus the actual
27
+ inset/stroke. Do not force unrelated actions to follow that formula. Compare
28
+ top/bottom and start/end insets around a nested InputGroup action optically.
29
+
30
+ Distinguish a real component from its preview scene. Fixed preview height and
31
+ reserved feedback space can prevent a demo from jumping; they should not impose
32
+ an empty message row or fixed height on every production field.
33
+
34
+ ## Evidence
35
+
36
+ Check short/wrapping labels, optional descriptions/messages/actions, all relevant
37
+ sizes, narrow width, enlarged text and both pointer modes. Rows can grow for
38
+ content; compact spacing must not clip text or overlap touch targets. Check a
39
+ sibling using the same recipe after a shared correction. Report actual measures
40
+ and rendered evidence, not only the declaration that was changed.
41
+
42
+ No horizontal overflow does not prove a readable layout. Inspect the actual
43
+ remaining copy width and body height after padding, title/description, fixed
44
+ actions and scrollbar space. A thin scrolling slot or words broken into fragments
45
+ is a failure even when every rectangle technically fits. Correct the owning
46
+ container's responsive budget without shrinking the user's enlarged text.
@@ -0,0 +1,47 @@
1
+ ---
2
+ name: flood-verification
3
+ description: Verify Flood component or composed-interface changes against applicable contracts and actual evidence. Use for stabilization, regression or completion review.
4
+ ---
5
+
6
+ # Turn a rule into an observation
7
+
8
+ Read [verification](../verification.md), the host's scripts and the changed
9
+ component's contract. Use project-root flood/rules.json to identify applicable
10
+ rule IDs; it is an index of guidance, not an automatic pass/fail policy engine.
11
+
12
+ ## Bound the coverage
13
+
14
+ Record the affected primitive, its real consumers, supported states and ownership.
15
+ Mark an inapplicable check with a reason rather than forcing keyboard behavior
16
+ onto decoration or readOnly onto every control. Distinguish existing test coverage
17
+ from checks actually run for this source revision.
18
+
19
+ Check the public contract at the boundary: installed exports/types, actual form
20
+ values, controlled acceptance/refusal, reset, names/focus and semantic state. For
21
+ visual changes inspect rendered geometry, long/optional content, narrow/wide,
22
+ enlarged text and the relevant pointer/RTL/forced-color modes. A CSS declaration
23
+ or component count is not evidence that the user-visible relationship works.
24
+
25
+ For geometry and screenshots, wait for fonts, pending animations and a settled
26
+ rendering frame. A zero running-animation count alone may precede final
27
+ presentation. Preserve real motion and strict geometry tolerances; distinguish
28
+ an entry frame from the final layout rather than accepting either as proof.
29
+
30
+ During local iteration run focused checks and show the result promptly. A shared
31
+ primitive correction also checks its consumers. At a consolidated Flood source
32
+ candidate run npm run verify and the required applicable browser matrix; use the
33
+ host's equivalent gates in a consuming app. Do not continually repeat a full
34
+ release gate for every reversible visual adjustment.
35
+
36
+ ## Report a usable result
37
+
38
+ For a failure preserve the source revision, affected state and actual trace or
39
+ measurement; distinguish library, host recipe, assertion and infrastructure causes.
40
+ Correct the responsible owner without weakening a meaningful assertion to get
41
+ green. Add regression coverage for demonstrated risks rather than mirroring CSS.
42
+
43
+ State what ran, results, manual observations and remaining limits. A source scan,
44
+ agent instruction, screenshot or accessibility scanner cannot independently prove
45
+ all behavior or certify conformance. A local build does not prove registry
46
+ publication, website deployment or a host backend save. Keep installation upgrades
47
+ deliberate and preserve customized/linked destination protections.
@@ -6,6 +6,7 @@ override user authority or grant permission for unrelated operations.
6
6
 
7
7
  | Question / when | Audience | Prerequisite | Source of truth | Verify with |
8
8
  | --- | --- | --- | --- | --- |
9
+ | Which primitive owns this role? Component/composite UI work | Developer / agent / reviewer | Matching catalog and component anatomy | flood-composition/SKILL.md | Reuse existing primitives; extend small capabilities first |
9
10
  | Which API can I import? Every component edit | Developer / agent | Installed exact versions | Installed @flood-md/react declarations; flood.json | Type-check host imports; CLI doctor for alignment |
10
11
  | What does this release mean? Setup / upgrade | Developer / agent | Matching guide | flood/DESIGN.md, package changelog | Compare version and declarations; preserve host edits |
11
12
  | How should a screen fit together? Screen / form work | Designer / developer / agent | Scope, content and current API | composition.md; host layout requirements | Narrow/wide rendered screen and native form interaction |
package/rules.json CHANGED
@@ -181,6 +181,330 @@
181
181
  "Check fine/coarse pointers and nonoverlapping interactive targets",
182
182
  "Preserve keyboard focus and label activation"
183
183
  ]
184
+ },
185
+ {
186
+ "id": "composition.reuse",
187
+ "when": "Building or reviewing Flood components, composites, website or host UI",
188
+ "for": [
189
+ "designer",
190
+ "developer",
191
+ "reviewer",
192
+ "agent"
193
+ ],
194
+ "requires": [
195
+ "Matching installed exports and component contracts",
196
+ "Existing component anatomy and current composition"
197
+ ],
198
+ "sourceOfTruth": "DESIGN.md and the Flood composition skill",
199
+ "guide": "references/flood-composition/SKILL.md",
200
+ "verify": [
201
+ "Existing semantic primitives remain present in the rendered composition",
202
+ "Missing reusable capabilities are implemented in a small primitive before the larger composite",
203
+ "No replacement markup or hidden anatomy used to bypass a primitive",
204
+ "Alignment checked within each row and in the real host"
205
+ ]
206
+ },
207
+ {
208
+ "id": "foundations.roles",
209
+ "when": "Applying dark surfaces, type, control or icon roles",
210
+ "for": [
211
+ "developer",
212
+ "reviewer",
213
+ "agent"
214
+ ],
215
+ "requires": [
216
+ "Matching installed declarations and guide set",
217
+ "Runnable host and actual content/state requirements"
218
+ ],
219
+ "sourceOfTruth": "Installed semantic roles and actual composited backgrounds",
220
+ "guide": "references/flood-foundations/SKILL.md",
221
+ "verify": [
222
+ "Trace changed roles to their actual consumers",
223
+ "Distinguish decoration, necessary boundaries, selection and accent focus",
224
+ "Check explicit icon sizing, heading semantics, long text and enlarged root geometry"
225
+ ]
226
+ },
227
+ {
228
+ "id": "spacing.nesting",
229
+ "when": "Aligning nested surfaces or controls",
230
+ "for": [
231
+ "developer",
232
+ "reviewer",
233
+ "agent"
234
+ ],
235
+ "requires": [
236
+ "Matching installed declarations and guide set",
237
+ "Runnable host and actual content/state requirements"
238
+ ],
239
+ "sourceOfTruth": "Rendered anatomy, insets, radii and spacing roles",
240
+ "guide": "references/flood-spacing/SKILL.md",
241
+ "verify": [
242
+ "Measure both axes including line height and minimum height",
243
+ "Compare nested radius/inset geometry without overriding independent actions",
244
+ "Check shared siblings and nonoverlapping targets"
245
+ ]
246
+ },
247
+ {
248
+ "id": "spacing.preview",
249
+ "when": "Demonstrating size or feedback transitions",
250
+ "for": [
251
+ "developer",
252
+ "reviewer",
253
+ "agent"
254
+ ],
255
+ "requires": [
256
+ "Matching installed declarations and guide set",
257
+ "Runnable host and actual content/state requirements"
258
+ ],
259
+ "sourceOfTruth": "Component behavior distinguished from preview scene ownership",
260
+ "guide": "references/flood-spacing/SKILL.md",
261
+ "verify": [
262
+ "Changing size does not resize the preview scene",
263
+ "Feedback does not move an unrelated sample",
264
+ "Production controls do not inherit unnecessary fixed demo space"
265
+ ]
266
+ },
267
+ {
268
+ "id": "forms.ownership",
269
+ "when": "Connecting controlled values or native form data",
270
+ "for": [
271
+ "developer",
272
+ "reviewer",
273
+ "agent"
274
+ ],
275
+ "requires": [
276
+ "Matching installed declarations and guide set",
277
+ "Runnable host and actual content/state requirements"
278
+ ],
279
+ "sourceOfTruth": "Installed control values, callbacks and native form contract",
280
+ "guide": "references/flood-forms/SKILL.md",
281
+ "verify": [
282
+ "Inspect actual FormData and field ownership",
283
+ "Exercise accepted/refused controlled updates and incomplete drafts",
284
+ "Defaults match representation; no defaultValue-as-update or invented save guarantee"
285
+ ]
286
+ },
287
+ {
288
+ "id": "forms.reset",
289
+ "when": "Resetting a form or changing value representation",
290
+ "for": [
291
+ "developer",
292
+ "reviewer",
293
+ "agent"
294
+ ],
295
+ "requires": [
296
+ "Matching installed declarations and guide set",
297
+ "Runnable host and actual content/state requirements"
298
+ ],
299
+ "sourceOfTruth": "Installed controlled/uncontrolled, reset and precision contract",
300
+ "guide": "references/flood-forms/SKILL.md",
301
+ "verify": [
302
+ "Normal and prevented reset preserve documented ownership",
303
+ "Minute/second defaults match selected precision",
304
+ "Advisory messages remain valid; native errors and disabled/read-only retain distinct semantics"
305
+ ]
306
+ },
307
+ {
308
+ "id": "overlays.ownership",
309
+ "when": "Opening or nesting a modal or anchored layer",
310
+ "for": [
311
+ "developer",
312
+ "reviewer",
313
+ "agent"
314
+ ],
315
+ "requires": [
316
+ "Matching installed declarations and guide set",
317
+ "Runnable host and actual content/state requirements"
318
+ ],
319
+ "sourceOfTruth": "Installed trigger, open-state, focus and dismissal contract",
320
+ "guide": "references/flood-overlays/SKILL.md",
321
+ "verify": [
322
+ "One mounted trigger retains props/ref and name",
323
+ "Topmost Escape and host refusal behave correctly",
324
+ "Appropriate modal/nonmodal focus and scroll restoration"
325
+ ]
326
+ },
327
+ {
328
+ "id": "overlays.geometry",
329
+ "when": "Placing popups or viewport-edge drawers",
330
+ "for": [
331
+ "developer",
332
+ "reviewer",
333
+ "agent"
334
+ ],
335
+ "requires": [
336
+ "Matching installed declarations and guide set",
337
+ "Runnable host and actual content/state requirements"
338
+ ],
339
+ "sourceOfTruth": "Actual anchor, viewport, scroll container and semantic surface",
340
+ "guide": "references/flood-overlays/SKILL.md",
341
+ "verify": [
342
+ "Check used sides, viewport edges, resize, long content and RTL",
343
+ "No drawer gap caused by page scrollbar gutter",
344
+ "Header, footer and padding leave a useful body reading area at enlarged narrow sizes; fitting rectangles alone is insufficient",
345
+ "Popup remains distinguishable with no rail-covered or clipped essential content"
346
+ ]
347
+ },
348
+ {
349
+ "id": "navigation.intent",
350
+ "when": "Choosing destinations, selection, panels or disclosure",
351
+ "for": [
352
+ "developer",
353
+ "reviewer",
354
+ "agent"
355
+ ],
356
+ "requires": [
357
+ "Matching installed declarations and guide set",
358
+ "Runnable host and actual content/state requirements"
359
+ ],
360
+ "sourceOfTruth": "Installed navigation, selection and disclosure contract",
361
+ "guide": "references/flood-navigation/SKILL.md",
362
+ "verify": [
363
+ "Native link behavior and current destination preserved",
364
+ "Selection, focus and expansion remain distinct",
365
+ "Long labels and final sidebar items remain usable in actual supported orientations"
366
+ ]
367
+ },
368
+ {
369
+ "id": "data.structure",
370
+ "when": "Presenting records, file items or tables",
371
+ "for": [
372
+ "developer",
373
+ "reviewer",
374
+ "agent"
375
+ ],
376
+ "requires": [
377
+ "Matching installed declarations and guide set",
378
+ "Runnable host and actual content/state requirements"
379
+ ],
380
+ "sourceOfTruth": "Installed semantic primitives and content relationships",
381
+ "guide": "references/flood-data-display/SKILL.md",
382
+ "verify": [
383
+ "Caption, headers and named-value relationships preserved",
384
+ "Row actions remain independent named controls",
385
+ "File metadata/status/progress reuse their existing primitives"
386
+ ]
387
+ },
388
+ {
389
+ "id": "data.overflow",
390
+ "when": "Presenting long, missing or changing content",
391
+ "for": [
392
+ "developer",
393
+ "reviewer",
394
+ "agent"
395
+ ],
396
+ "requires": [
397
+ "Matching installed declarations and guide set",
398
+ "Runnable host and actual content/state requirements"
399
+ ],
400
+ "sourceOfTruth": "Actual data surface and overflow ownership",
401
+ "guide": "references/flood-data-display/SKILL.md",
402
+ "verify": [
403
+ "Empty/loading/error and absent optional slots exercised",
404
+ "Final item/cell action and full essential text remain accessible outside rails",
405
+ "Server/client locale, narrow/enlarged text and RTL checked"
406
+ ]
407
+ },
408
+ {
409
+ "id": "feedback.truth",
410
+ "when": "Reporting operation state or progress",
411
+ "for": [
412
+ "developer",
413
+ "reviewer",
414
+ "agent"
415
+ ],
416
+ "requires": [
417
+ "Matching installed declarations and guide set",
418
+ "Runnable host and actual content/state requirements"
419
+ ],
420
+ "sourceOfTruth": "Actual host operation and installed feedback primitive",
421
+ "guide": "references/flood-feedback/SKILL.md",
422
+ "verify": [
423
+ "Pending/success/error/cancel/local state is truthful",
424
+ "Unknown progress never fabricates a percentage",
425
+ "Empty content explains its cause and appropriate next action"
426
+ ]
427
+ },
428
+ {
429
+ "id": "feedback.announcements",
430
+ "when": "Announcing status, alert or loading transitions",
431
+ "for": [
432
+ "developer",
433
+ "reviewer",
434
+ "agent"
435
+ ],
436
+ "requires": [
437
+ "Matching installed declarations and guide set",
438
+ "Runnable host and actual content/state requirements"
439
+ ],
440
+ "sourceOfTruth": "Installed semantics and required urgency",
441
+ "guide": "references/flood-feedback/SKILL.md",
442
+ "verify": [
443
+ "One announcement owner rather than duplicate live regions",
444
+ "Messages do not steal focus merely to announce",
445
+ "Audible behavior claimed only when tested with actual assistive technology"
446
+ ]
447
+ },
448
+ {
449
+ "id": "accessibility.focus",
450
+ "when": "Reviewing names, keyboard or focus through a task",
451
+ "for": [
452
+ "developer",
453
+ "reviewer",
454
+ "agent"
455
+ ],
456
+ "requires": [
457
+ "Matching installed declarations and guide set",
458
+ "Runnable host and actual content/state requirements"
459
+ ],
460
+ "sourceOfTruth": "Installed component behavior and actual accessibility tree",
461
+ "guide": "references/flood-accessibility/SKILL.md",
462
+ "verify": [
463
+ "Name, role and state observed rather than inferred visually",
464
+ "Keyboard completion, reverse navigation, cancel and recovery",
465
+ "Pointer activation gives custom keyboard owners actual focus across browsers while preserving deliberate host callback focus moves",
466
+ "Accent focus survives selected/invalid/read-only combinations without layout shift"
467
+ ]
468
+ },
469
+ {
470
+ "id": "accessibility.perception",
471
+ "when": "Reviewing readability under alternate viewing conditions",
472
+ "for": [
473
+ "developer",
474
+ "reviewer",
475
+ "agent"
476
+ ],
477
+ "requires": [
478
+ "Matching installed declarations and guide set",
479
+ "Runnable host and actual content/state requirements"
480
+ ],
481
+ "sourceOfTruth": "Actual text size/weight/background and applicable WCAG criteria",
482
+ "guide": "references/flood-accessibility/SKILL.md",
483
+ "verify": [
484
+ "Text contrast and supplementary APCA interpretation kept distinct",
485
+ "Necessary cues are not reclassified as decoration",
486
+ "Reflow, enlargement, relevant pointer/RTL/forced-color checks and limits reported"
487
+ ]
488
+ },
489
+ {
490
+ "id": "verification.applicability",
491
+ "when": "Stabilizing components or declaring a composition complete",
492
+ "for": [
493
+ "developer",
494
+ "reviewer",
495
+ "agent"
496
+ ],
497
+ "requires": [
498
+ "Matching installed declarations and guide set",
499
+ "Runnable host and actual content/state requirements"
500
+ ],
501
+ "sourceOfTruth": "Current revision, applicable contracts and observed outcomes",
502
+ "guide": "references/flood-verification/SKILL.md",
503
+ "verify": [
504
+ "Explicit applicable-check disposition for every affected component",
505
+ "Existing coverage distinguished from checks run for this revision",
506
+ "Failures, source/host ownership and remaining limits recorded"
507
+ ]
184
508
  }
185
509
  ],
186
510
  "guideResolution": "Match guide to source in manifest.files; use its target relative to the host project root."
package/workflows.json ADDED
@@ -0,0 +1,16 @@
1
+ {
2
+ "schemaVersion": 1,
3
+ "scope": "Task routing for the existing Flood dark base; applicability is not test evidence",
4
+ "workflows": [
5
+ { "id": "composition", "guide": "references/flood-composition/SKILL.md", "all": true },
6
+ { "id": "spacing", "guide": "references/flood-spacing/SKILL.md", "all": true },
7
+ { "id": "foundations", "guide": "references/flood-foundations/SKILL.md", "all": true },
8
+ { "id": "accessibility", "guide": "references/flood-accessibility/SKILL.md", "all": true },
9
+ { "id": "forms", "guide": "references/flood-forms/SKILL.md", "groups": ["forms"], "components": ["Button", "Label", "Fieldset", "ErrorSummary"] },
10
+ { "id": "overlays", "guide": "references/flood-overlays/SKILL.md", "groups": ["overlays"], "components": ["Select", "Combobox", "MultiSelect", "TreeSelect", "DatePicker", "DateRangePicker", "TimePicker", "DateTimePicker", "DateTimeRangePicker"] },
11
+ { "id": "navigation", "guide": "references/flood-navigation/SKILL.md", "groups": ["navigation"], "components": ["Tree", "TreeSelect", "Toolbar", "CommandList", "ListBox", "ToggleGroup", "SegmentedControl", "Accordion", "Collapsible"] },
12
+ { "id": "data-display", "guide": "references/flood-data-display/SKILL.md", "groups": ["content"], "components": ["UploadItem", "UploadList", "EmptyState", "ScrollArea"] },
13
+ { "id": "feedback", "guide": "references/flood-feedback/SKILL.md", "groups": ["feedback"], "components": ["Field", "Fieldset", "Input", "Textarea", "Select", "ListBox", "CopyButton", "Badge", "UploadItem", "UploadList"] },
14
+ { "id": "verification", "guide": "references/flood-verification/SKILL.md", "all": true }
15
+ ]
16
+ }