tum-esi / wade

WoT API Development Environment built on top of thingweb.node-wot

Home Page:https://www.ei.tum.de/en/esi/home/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[UI] Dynamic tabs wrapper for views

miguelrk opened this issue · comments

Problem
Switching between TDs/SDs/Folders is somewhat cumbersome for the users, as he must save before switch, or all edits (e.g. in editor) will be lost.

Solution
A dynamically tabbed interface similar to that of code editors like vscode can be implemented, such that a new tab is created when the user clicks (or double clicks) an item in the left tree-view, a new tab is created. Users can then perform edits, switch tabs, return and changes will be there (although not saved) until manually saved (see bellow).

wade-tabs-dynamic

A keyboard shortcut to save current view edits with Cmd/Ctrl + S could be done as follows:

// 83 corresponds to the "S" character in the ASCII Table
@keydown.ctrl.83="save()"
@keydown.meta.83="save()" // On Macintosh keyboards, meta is the command key (⌘).

Problem
Switching between TDs/SDs/Folders is somewhat cumbersome for the users, as he must save before switch, or all edits (e.g. in editor) will be lost.

Solution
A dynamically tabbed interface similar to that of code editors like vscode can be implemented, such that a new tab is created when the user clicks (or double clicks) an item in the left tree-view, a new tab is created. Users can then perform edits, switch tabs, return and changes will be there (although not saved) until manually saved (see bellow).

wade-tabs-dynamic

A keyboard shortcut to save current view edits with Cmd/Ctrl + S could be done as follows:

// 83 corresponds to the "S" character in the ASCII Table
@keydown.ctrl.83="save()"
@keydown.meta.83="save()" // On Macintosh keyboards, meta is the command key (⌘).

Cool idea! Sounds like a lot of work though 😄
Adding some kind of keyboard commands could be a good first step!