mirror of
https://github.com/SillyTavern/SillyTavern-Timelines.git
synced 2026-10-15 18:12:00 +00:00
[GH-ISSUE #17] UX bugs #4
Labels
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
SillyTavern/SillyTavern-Timelines#4
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 @Technologicat on GitHub (Jan 26, 2024).
Original GitHub issue: https://github.com/SillyTavern/SillyTavern-Timelines/issues/17
From quickly trying out Timelines for a small creative writing test, the UX has some rough edges:
bookmark_linkin existing chat files that points to the deleted file. If you manually edit that out, the ghost checkpoint disappears from the legend.onTimelineButtonClickinSillyTavern/public/scripts/extensions/third-party/SillyTavern-Timelines/index.jsupdateTimelineDataIfNeededinSillyTavern/public/scripts/extensions/third-party/SillyTavern-Timelines/index.jsfetchDatainSillyTavern/public/scripts/extensions/third-party/SillyTavern-Timelines/tl_node_data.js/api/characters/chats-> the returned filenames include deleted chat files/chatsendpoint handler inSillyTavern/src/endpoints/characters.jsgets its list of chat files directly by scanning the folder on the disk. Not much can go wrong there.bookmark_link, but forgot to delete the chat file -> "ghost checkpoint" in the jump buttons in a graph node (because the chat file still exists), although no longer listed in the legendPossible simple fix: when Timelines gathers information about checkpoints and finds aEDIT: Yep, pruning dead links when constructing the timeline graph solves this. Fix stashed for the next PR.bookmark_link, it could also check that the linked chat file exists in the set of all chats (that the graph is built out of). Then dead links wouldn't matter. I'll try this approach.Would be useful to automatically focus and zoom to the clicked checkpoint in the legend.Done, stashed for next PR.Same for a text search result, if unique.Done, zooms to show all matches. This too stashed for next PR.Also, when opening the timeline view, would be nice to focus and zoom the graph to the current chat.Need to get that data from the context.Then this also needs a button to fit the view to the whole graph.When the timeline view is opened, if there is a previous fulltext search term, it remains in the search field but the search is not applied. The search should be applied (and perhaps the content of the field selected, so that starting to type would replace the current search term).Added to #16.RossAscends-mods.js, since this is a third-party extension.I'll see if I have the time to do something to these - as usual, no promises except of the async/await kind.
EDIT: My mistake. The API endpoint gets the correct file list.
@Technologicat commented on GitHub (Jan 27, 2024):
Talking to myself here...
bookmark_link) the relevant message in the originating chat file as having spawned that checkpointbookmark_linkfield to identify checkpointsTherefore:
bookmark_link), this spawns another new chat file, and overwrites thebookmark_linkfield in the originating chat file. But the previous spawned chat file still also exists; the originating chat file just no longer links to it.bookmark_linkin the original chat file remains.Will need to think about what this all means for Timelines when less tired.
@Technologicat commented on GitHub (Jan 29, 2024):
I have this pretty much working, now pending on #16.
@Cohee1207: What's the preferred way to handle hotkeys in third-party extensions? I'd like
Escto close the timeline view, like in many built-in views, but I suppose modding the Esc catcher inRossAscends-mods.jsis not the way to do it. :)@Cohee1207 commented on GitHub (Jan 29, 2024):
Possibly
stopPropagationis your bro here if you want to cancel out the default top-level handler of Esc key.@Technologicat commented on GitHub (Jan 29, 2024):
Upcoming PR posted as #18.
Changelog moved there.
@Technologicat commented on GitHub (Jan 29, 2024):
I have no problem with the top-level handler, except it's not closing the timeline view. :)
I noticed that the new Token probabilities feature added a case to
RossAscends-mods.js, but that's a core feature, not a third-party plugin. Hence, I was thinking that I probably need to wire in a custom handler when the plugin initializes...@Cohee1207 commented on GitHub (Jan 29, 2024):
Yes, a custom handler with stopPropagation cancels the event bubbling to the top-level handler if it was used to close a Timelines view.
@Technologicat commented on GitHub (Jan 29, 2024):
I missed the obvious implication, as usual. Thanks for the clarification. :)
@Technologicat commented on GitHub (Feb 6, 2024):
Resolved by #18.