mirror of
https://github.com/mum4k/termdash.git
synced 2026-04-26 19:05:52 +03:00
[GH-ISSUE #358] How to add sub-container with id #162
Labels
No labels
bug
cleanup
enhancement
enhancement
enhancement
good first issue
help wanted
help wanted
pull-request
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/termdash#162
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @pavel-blagodov on GitHub (Dec 28, 2023).
Original GitHub issue: https://github.com/mum4k/termdash/issues/358
Hey,
Could you please clarify how to add sub-container with id, so that it can be updated without updating siblings containers. I'm using grid layout
Thank you
@mum4k commented on GitHub (Jan 4, 2024):
Thank you for reaching out @pavel-blagodov. To update a sub-container, you would first give that sub-container a known ID using the
contained.ID("some_id")option. You can then update any options on that container including sub-splits by calling thecontainer.Update()method as documented in Dynamic Layout and referring back to the sameID.Please refer to https://github.com/mum4k/termdash/pull/359 which demonstrates this on the
termdashdemo. When running the demo, you can pressCtrl-Uto update a sub-container (changes widget from green sparkline to a red sparkline). Any other updates are possible as well.