Ionaru / Ionaru/easy-markdown-editor

Disable undo and redo toolbar buttons depending on history

Open
#525 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
3.1k
Forks
363
PR merge metrics
No merged PRs in 30d

Description

The undo and redo buttons are currently always enabled when present in the toolbar, even when there is no history.
Would it be a feature to listen to changes and enable/disable the buttons depending on the history?

https://user-images.githubusercontent.com/935529/213391633-e48ac603-7d28-4f59-878d-90bc966f2463.mov

Demo:
https://codepen.io/snap/pen/dyjRRwr?editors=1010

Contributor guide

Open the contributing guide

Research direction

Reproduce the toolbar behavior shown in the linked video and CodePen demo, then trace how the editor exposes undo and redo history changes. The work is done when each toolbar button is disabled when its corresponding history is empty and enabled when that action is available.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.