Skip to content
This repository has been archived by the owner on Jul 22, 2020. It is now read-only.

Support undo/redo actions for query editing #204

Open
ferringb opened this issue Dec 20, 2017 · 1 comment
Open

Support undo/redo actions for query editing #204

ferringb opened this issue Dec 20, 2017 · 1 comment
Milestone

Comments

@ferringb
Copy link

This is a fairly minor request, but when manually editing the query field- say to add alertname=My_Stupid_Alert, due to the JS manipulations that occur undo/redo logic isn't possible. Specifically since the text is converted to a different object, the browser cannot 'undo' that action.

When one screws up and removes long parts of the query, this is a bit annoying.

I only have a surface understanding of the DOM/events involved in this, but http://mattjmattj.github.io/simple-undo/ is an example that can likely be examined for which hooks we'd need to file. From there something like https://github.com/ArthurClemens/Javascript-Undo-Manager/blob/master/lib/undomanager.js gives an object approach for managing the queue of changes, and providing a 'history' that the undo/redo can act upon.

@prymitive
Copy link
Contributor

Should be doable after #208, current code doesn't make it easy

@prymitive prymitive self-assigned this Jan 11, 2018
@prymitive prymitive added this to the v0.11 milestone Jan 24, 2018
@prymitive prymitive removed their assignment May 18, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants