Skip to content

Fix #2462: [Bug]: JS/TS Editor - The log window is cleared when the show/hide button of the 'script list' is used. - #2463

Merged
GermanBluefox merged 2 commits into
masterfrom
fix/issue-2462-mwfatw07
Nov 17, 2026
Merged

GermanBluefox merged 2 commits into
masterfrom
fix/issue-2462-mwfatw07

Conversation

@GermanBluefox

Copy link
Copy Markdown
Contributor

The editor log lost all its lines when the script list or the log was hidden and shown again, because Log is mounted anew on these layout changes and kept its lines in component state. The log lines are now kept at module level in Log.tsx (next to the existing copy buffer gText), so they survive remounting. Lines are also collected while the log is hidden: App registers one log handler per socket via Log.attach() in onConnectionReady and keeps the list of edited scripts up to date with Log.setEditing(). A mounted Log only subscribes for re-renders, and when it is shown again it displays all collected lines and scrolls to the bottom if "follow" is active. Filtering by the edited scripts, the limit of 300 lines per script, clearing and copying work as before (#2462).

Fixes #2462

…how/hide button of the 'script list' is used.

The editor log lost all its lines when the script list or the log was hidden and shown again, because `Log` is mounted anew on these layout changes and kept its lines in component state. The log lines are now kept at module level in `Log.tsx` (next to the existing copy buffer `gText`), so they survive remounting. Lines are also collected while the log is hidden: `App` registers one log handler per socket via `Log.attach()` in `onConnectionReady` and keeps the list of edited scripts up to date with `Log.setEditing()`. A mounted `Log` only subscribes for re-renders, and when it is shown again it displays all collected lines and scrolls to the bottom if "follow" is active. Filtering by the edited scripts, the limit of 300 lines per script, clearing and copying work as before (#2462).

Fixes #2462
@GermanBluefox
GermanBluefox merged commit 24ec24e into master Nov 17, 2026
16 checks passed
@GermanBluefox
GermanBluefox deleted the fix/issue-2462-mwfatw07 branch November 17, 2026 09:05
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.

[Bug]: JS/TS Editor - The log window is cleared when the show/hide button of the 'script list' is used.

1 participant