Ver Fonte

ComposeArea: Use new clear() and focus() methods

Danilo Bargen há 6 anos atrás
pai
commit
be828b07a7
1 ficheiros alterados com 2 adições e 3 exclusões
  1. 2 3
      src/directives/compose_area.ts

+ 2 - 3
src/directives/compose_area.ts

@@ -257,9 +257,8 @@ export default [
                     if (!composeAreaIsEmpty()) {
                         submitText().then(() => {
                             // Clear compose div
-                            // TODO: Use clear() and focus() methods
-                            composeDiv[0].innerText = '';
-                            composeDiv[0].focus();
+                            composeArea.clear();
+                            composeArea.focus();
 
                             // Send stopTyping event
                             stopTyping();