Repository navigation
Teach How it works and Extending the defineWidget form of a widget - #7551
Merged
Merged
Conversation
Max asked whether How it works was being updated for the new interfaces. The site's How it works and Extending pages now teach the form the references teach since #7544: a widget is its declaration plus, if it draws, an Effect UI component that `defineWidget` defines, which takes `state` as a prop and issues Commands such as `RecordAction`. How it works' Package interface tab gets a new widget definition, drawing, forms table and principles, and walks through `lf-verdict` as the component `module-widgets.md` shows. `docs/verdict`, which the page runs and quotes, changes with it. The prose describes a widget acting on Leaf through Commands and names none of the thread and obligation functions Max chose to remove. The example's two buttons touched. `docs/verdict`, the `module-widgets.md` example and the starter `leaf package init --widget` writes now space their row with a class of their own. `leaf-dev interface --base` reports no name added. The product-page, interface and starter tests pass, among them `test_widget_quality.py` and `test_plain_elements.py`'s starter test. A probe pressed Ship and Undo in the page's live sample. > _This was written by Claude Code on behalf of max-sixty_
leaf-agent
approved these changes
Nov 28, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Max asked whether How it works was being updated for the new interfaces. The site's How it works and Extending pages now teach the form the references teach since #7544: a widget is its declaration plus, if it draws, an Effect UI component that
defineWidgetdefines, which takesstateas a prop and issues Commands such asRecordAction.How it works' Package interface tab gets a new widget definition, drawing, forms table and principles, and walks through
lf-verdictas the componentmodule-widgets.mdshows.docs/verdict, which the page runs and quotes, changes with it. The prose describes a widget acting on Leaf through Commands and names none of the thread and obligation functions Max chose to remove.The example's two buttons sat with no gap between them.
docs/verdict, themodule-widgets.mdexample and the starterleaf package init --widgetwrites now space their row with a class of their own.leaf-dev interface --basereports no name added. The product-page, interface and starter tests pass, among themtest_widget_quality.pyandtest_plain_elements.py's starter test. A probe pressed Ship and Undo in the page's live sample.