瀏覽代碼

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

Danilo Bargen 6 年之前
父節點
當前提交
be828b07a7
共有 1 個文件被更改,包括 2 次插入3 次删除
  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();