Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .claude/skills/forma-testing/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,9 @@ bUnit renders markup and drives its own synchronous JS interop, so a green suite

A test that passes alone and fails under load is broken, not unlucky: its assertion depends on how quickly a continuation is scheduled. Load only exposes the race.

- Do hold a component's asynchronous work in a fake the test controls, or in a script answer bUnit holds, and let it go through `cut.ReleaseAsync(...)` from the bUnit support project, which runs the release on the renderer and then takes a second turn there, so the component has acted once it returns and the test asserts directly after.
- Do give such a fake a plain `TaskCompletionSource`, which runs the component's continuation inline in the release; one created to run its continuations asynchronously, as bUnit's held script answers are, queues it on the renderer, which only the second turn waits out, so a release made any other way than through `ReleaseAsync` races it.
- Do hold a component's asynchronous work in a fake the test controls, or a script's answer in the bUnit support project's `HeldCallHandler<TResult>` or `HeldVoidCallHandler`, and let it go through `cut.ReleaseAsync(...)` from the same project, which runs the release on the renderer and then takes a second turn there, so the component has acted once it returns and the test asserts directly after.
- Don't hold a script's answer in a handler bUnit sets up, `Setup` or `SetupVoid` left without a result: bUnit fails each call such a handler holds once `BunitContext.DefaultWaitTimeout`, a second, has passed, so on a loaded machine the component meets a failed call where the test meant a held one.
- Do give such a fake a plain `TaskCompletionSource`, which runs the component's continuation inline in the release; one created to run its continuations asynchronously queues it on the renderer, which only the second turn waits out, so a release made any other way than through `ReleaseAsync` races it.
- Do hand a fake's answer on through a continuation that runs synchronously, `ContinueWith` with `ExecuteSynchronously`, where it has to convert it; an await with `ConfigureAwait(false)` completing under the renderer's context is queued to the thread pool, and the component's continuation with it.
- Do await the handler's own task, from `ClickAsync` or `TriggerEventAsync`, where the component's work passes through a library that awaits with `ConfigureAwait(false)`; that work leaves the renderer, and nothing done on the renderer can wait for it.
- Do give a component a contract to inject, as `IEmojiSpriteLoader` beside `EmojiSpriteLoader`, when a test needs to hold its work and the only way in was a pending script call.
Expand Down
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,19 @@ release is cut, and reads *Unreleased* until then. It lists every change a consu
breaks what the release before it allowed says how to migrate, as [Versioning's rules](https://github.com/FormaUI/Versioning/blob/v1.0.0-preview.5/docs/releases.md#the-release-record)
set out. What Forma gained before its first release, month by month, is in [the feature history](FEATURE-HISTORY.md).

## `1.0.0-preview.26`

*December 3, 2026*

- A [labeled field](docs/component-catalog.md#formafield)'s resting label stands centered on its box again, and over
a `FormaTextArea` level with where a one-line field's rests, where it sat on the value's line at the box's lower edge
and over the text area's first line.
- A `FormaSortableList` nested in another's item takes a press and a drag of its own handles, by mouse, pen or touch,
as it takes their keys, where the press lifted the item of the list around it and the nested list kept its order.
- `FormaDataView` takes `FocusItemAsync`, which brings the item a key names back on screen with the focus once the
items on their way have arrived, so a reader coming back to a list lands on the item they opened, as
[the data view design](docs/data-view-design.md#virtualization-and-the-scroll-region) sets out.

## `1.0.0-preview.25`

*December 2, 2026*
Expand Down
2 changes: 1 addition & 1 deletion Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
<!-- The one version every package ships at; a preview, as the framework it targets is. -->
<PropertyGroup>
<VersionPrefix>1.0.0</VersionPrefix>
<VersionSuffix>preview.25</VersionSuffix>
<VersionSuffix>preview.26</VersionSuffix>
</PropertyGroup>

<!-- Outside CI, which makes every package, a build stamps no commit into its assemblies or the source map of their symbols, so a build after a commit finds every project it didn't change up to date rather than compiling the whole solution again for a commit id. -->
Expand Down
9 changes: 9 additions & 0 deletions docs/data-view-design.md
Original file line number Diff line number Diff line change
Expand Up @@ -391,6 +391,15 @@ items on screen stay put, `InitialItemIndex` opens the data view on an item, and
`ScrollToItemAsync` scrolls to one later, and moves a paged data view to the item's page. The region announces its real item count, so
assistive technology knows how many items exist rather than how many are drawn.

`FocusItemAsync` gives the focus to the item a key names, as a host bringing a reader back to
the item they opened does. It waits for the items on their way, a page loading or one
appending, and for the behavior that lands the focus to attach. It then looks for the item
on the page shown, among the pages appended, scrolling a virtualizing view to it, or among
the items a virtualizing view draws, which `ScrollToItemAsync` reaches first where the host
knows the index. The item takes the focus and the collection's tab stop where its view gives
the items the focus, and is scrolled into view alone where it doesn't. The call answers
whether the item took the focus, and a newer call replaces one still waiting.

A view whose markers carry the focus pins the focused item with the items either side of
it, so the item an arrow reaches is drawn beside the focused one however far the view has
scrolled; the cards keep those neighbors as rows, so a focus moving along a row of cards or
Expand Down
Loading