Skip to content

fix(AppShell): wire up <colour> control hint for script textboxes - #2156

Open
alexwarren wants to merge 1 commit into
mainfrom
fix/editor-colour-script-hint
Open

fix(AppShell): wire up <colour> control hint for script textboxes#2156
alexwarren wants to merge 1 commit into
mainfrom
fix/editor-colour-script-hint

Conversation

@alexwarren

Copy link
Copy Markdown
Contributor

Summary

Test plan

  • dotnet build --configuration Release
  • dotnet test --configuration Release (all passing)
  • npm run check / npm run lint in src/AppShell (clean)
  • node tests/e2e/find-affected-tests.mjs + ran the relevant flagged scripts (verify-appshell-code-view, verify-appshell-script-label-stacks-below, verify-appshell-scripteditor-row-buttons, verify-appshell-scripteditor-selection-toolbar) against a local dev server - all pass.
  • Manual check in-browser: added a // Comment script command and confirmed via computed style it's now a <textarea> (rows: 1, auto-growing height) with color: green (previously a plain <input> with no color). Typed multi-line text into it and confirmed the box grows to fit, staying green throughout.

🤖 Generated with Claude Code

for direct "textbox" controltype script controls

<colour> was fully dead (2 uses: @failed's fallback-script text in red,
a // comment's text in green, both CoreEditorScriptsScripts.aslx). While
wiring it up, found its two controls also declare <multiline/>/<expand/>
(the tags #2115 fixed) but never got that fix - #2115 only touched the
"expression" controltype's textbox *simple editor* path; @failed/// use
controltype=textbox directly, a separate code path in ScriptEditor.svelte
that still rendered a plain single-line input regardless of the hints.
Fixing colour alone would have produced a colored box that still couldn't
show its own (often multi-line) text properly, so multiline/expand are
completed for this controltype too, in the same branch.

ScriptControlData.Multiline/Expand were already read unconditionally in
BuildScriptControlData (the gap was frontend-only); this adds Colour next
to them and mirrors the existing simple-editor multiline/expand rendering
into the direct "textbox"/"richtext" controlType branch of ScriptEditor.svelte.

Part of #2116.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant