Skip to content

Commit

Permalink
fixup! Pop open a message when user deletes an annotation
Browse files Browse the repository at this point in the history
  • Loading branch information
ryzokuken committed Oct 21, 2024
1 parent a893637 commit c1cbf9b
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions web/editor_undo_bar.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* limitations under the License.
*/

import { AnnotationEditorType } from "../src/shared/util.js";

class EditorUndoBar {
#container;

Expand Down Expand Up @@ -44,6 +46,11 @@ class EditorUndoBar {
eventBus._on("beforeprint", boundHide);
eventBus._on("download", boundHide);
eventBus._on("secondarytoolbaraction", boundHide);
eventBus._on("annotationeditormodechanged", ({ mode }) => {
if (mode === AnnotationEditorType.NONE) {
this.hide();
}
})
}

show(undoAction, messageData) {
Expand Down

0 comments on commit c1cbf9b

Please sign in to comment.