Luigit
repositories / dotfiles

dotfiles

bugabingas dorkfiles

owned by admin

pi/agent/skills/optional/qml/examples/05-form/README.md

Raw
Rendered preview

05: Form

A two-column form with explicit state ownership and live validation.

qml6 form.qml

ApplicationWindow comes from QtQuick.Controls. The root owns the field values. Each field binds from root state and writes user edits back through a user-only signal such as textEdited or valueModified. The fields use ids and Accessible.name rather than structural parent.parent access.

isValid and passwordsMatch are readonly derived bindings. The Submit handler runs synchronously because this example has no deferred or asynchronous requirement.

This file is load-tested only unless a separate interaction test exercises focus traversal, editing, validation, and submission.

# 05: Form

A two-column form with explicit state ownership and live validation.

```sh
qml6 form.qml
```

`ApplicationWindow` comes from `QtQuick.Controls`.
The root owns the field values.
Each field binds from root state and writes user edits back through a user-only signal such as `textEdited` or `valueModified`.
The fields use ids and `Accessible.name` rather than structural `parent.parent` access.

`isValid` and `passwordsMatch` are readonly derived bindings.
The Submit handler runs synchronously because this example has no deferred or asynchronous requirement.

This file is load-tested only unless a separate interaction test exercises focus traversal, editing, validation, and submission.