feat(authoring): allow list_item_multi_column on repeat-bound elements#142
Merged
Merged
Conversation
Member
Author
|
Cross-linking the three operator_v2 substrate-gap items (per project-ariston Update 8):
|
Adds `list_item_multi_column` to the `@list_widgets` MapSet in `AshUI.Resources.Validations.Authoring`. Repeat-bound Elements (those declaring `binding_type :list`) can now use this kind directly without the `custom:*` workaround. Rebased onto origin/main (7556bae) from original PR #142. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
6ffb940 to
baf2652
Compare
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.
Summary
One-line widening: add
list_item_multi_columnto the@list_widgetsMapSet inAshUI.Resources.Validations.Authoring. The canonical renderer already supports this kind on repeat-bound Elements; the authoring validator just hadn't been widened to allow it.Why
Currently a repeat-bound Element that wants to render multi-column rows must either:
custom:*prefix on the type and add aRepeatRowFlatteningclause that rewrites the node type to"list_item_multi_column"before render, ORui_bindings :listblock (which then tripsInfo.destination_list_binding?at runtime)Neither is ideal. The renderer has full
list_item_multi_columncoverage inLiveUIAdapter.generate_heex/2; the validator just rejects the sametypedeclaration that the renderer is ready to handle.ariston-ui downstream cleanup once this lands
lib/ariston_ui_web/iur/repeat_row_flattening.exhas 3 flatten clauses that exist solely to bridge this gap:flatten_map_repo_row/1,flatten_map_activity_row/1,flatten_map_system_event/1. All three can be removed and the corresponding Elements declared astype "list_item_multi_column"directly. Documented in ariston-uidocs/operator-v2-phase-2-deferred-findings.md(substrate items section, item #2).Test plan
mix format --check-formattedpassesmix compile --warnings-as-errorspassesmix test test/ash_ui/authoring test/ash_ui/phase_31_canonical_conversion_test.exs test/ash_ui/phase_31_package_boundary_test.exs-> 15 tests, 0 failuresTier classification
Tier 1 mechanical fix per the substrate-gap co-maintain framing — single-line allowlist widening, no behavioral change to existing callers, no API design choice. Pinging @pcharbon70 for approval; happy to merge once blessed.
🤖 Generated with Claude Code