Skip to content

Commit

Permalink
Fix: Don't clear reply textarea when annotation is added to dialog (#36)
Browse files Browse the repository at this point in the history
  • Loading branch information
pramodsum authored Nov 15, 2017
1 parent de7f392 commit 1f88d55
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/AnnotationDialog.js
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ class AnnotationDialog extends EventEmitter {
}

this.addAnnotationElement(annotation);
this.deactivateReply(true); // Deactivate reply area and focus
this.deactivateReply(); // Deactivate reply area and focus
}

/**
Expand Down
2 changes: 1 addition & 1 deletion src/__tests__/AnnotationDialog-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,7 @@ describe('AnnotationDialog', () => {
it('should add annotation to the dialog and deactivate the reply area', () => {
dialog.addAnnotation(new Annotation({}));
expect(stubs.addEl).to.be.called;
expect(stubs.deactivate).to.be.calledWith(true);
expect(stubs.deactivate).to.be.calledWithExactly();
});

it('should hide the create section and show the show section if there are no annotations', () => {
Expand Down

0 comments on commit 1f88d55

Please sign in to comment.