Page MenuHomePhabricator

D17794.id42786.diff
No OneTemporary

D17794.id42786.diff

diff --git a/resources/celerity/map.php b/resources/celerity/map.php
--- a/resources/celerity/map.php
+++ b/resources/celerity/map.php
@@ -10,7 +10,7 @@
'conpherence.pkg.css' => 'ff161f2d',
'conpherence.pkg.js' => 'b5b51108',
'core.pkg.css' => '823f43f3',
- 'core.pkg.js' => '47a69358',
+ 'core.pkg.js' => 'fffe0122',
'darkconsole.pkg.js' => '1f9a31bc',
'differential.pkg.css' => '90b30783',
'differential.pkg.js' => 'ddfeb49b',
@@ -508,7 +508,7 @@
'rsrc/js/core/behavior-object-selector.js' => 'e0ec7f2f',
'rsrc/js/core/behavior-oncopy.js' => '2926fff2',
'rsrc/js/core/behavior-phabricator-nav.js' => '08675c6d',
- 'rsrc/js/core/behavior-phabricator-remarkup-assist.js' => '0ca788bd',
+ 'rsrc/js/core/behavior-phabricator-remarkup-assist.js' => 'acd29eee',
'rsrc/js/core/behavior-read-only-warning.js' => 'ba158207',
'rsrc/js/core/behavior-refresh-csrf.js' => 'ab2f381b',
'rsrc/js/core/behavior-remarkup-preview.js' => '4b700e9e',
@@ -536,7 +536,7 @@
'rsrc/js/phui/behavior-phui-tab-group.js' => '0a0b10e9',
'rsrc/js/phuix/PHUIXActionListView.js' => 'b5c256b8',
'rsrc/js/phuix/PHUIXActionView.js' => 'b3465b9b',
- 'rsrc/js/phuix/PHUIXAutocomplete.js' => 'd713a2c5',
+ 'rsrc/js/phuix/PHUIXAutocomplete.js' => 'f6699267',
'rsrc/js/phuix/PHUIXDropdownMenu.js' => '8018ee50',
'rsrc/js/phuix/PHUIXFormControl.js' => '83e03671',
'rsrc/js/phuix/PHUIXIconView.js' => 'bff6884b',
@@ -673,7 +673,7 @@
'javelin-behavior-phabricator-notification-example' => '8ce821c5',
'javelin-behavior-phabricator-object-selector' => 'e0ec7f2f',
'javelin-behavior-phabricator-oncopy' => '2926fff2',
- 'javelin-behavior-phabricator-remarkup-assist' => '0ca788bd',
+ 'javelin-behavior-phabricator-remarkup-assist' => 'acd29eee',
'javelin-behavior-phabricator-reveal-content' => '60821bc7',
'javelin-behavior-phabricator-search-typeahead' => 'eded9ee8',
'javelin-behavior-phabricator-show-older-transactions' => '94c65b72',
@@ -896,7 +896,7 @@
'phui-workpanel-view-css' => 'a3a63478',
'phuix-action-list-view' => 'b5c256b8',
'phuix-action-view' => 'b3465b9b',
- 'phuix-autocomplete' => 'd713a2c5',
+ 'phuix-autocomplete' => 'f6699267',
'phuix-dropdown-menu' => '8018ee50',
'phuix-form-control-view' => '83e03671',
'phuix-icon-view' => 'bff6884b',
@@ -988,17 +988,6 @@
'javelin-dom',
'javelin-router',
),
- '0ca788bd' => array(
- 'javelin-behavior',
- 'javelin-stratcom',
- 'javelin-dom',
- 'phabricator-phtize',
- 'phabricator-textareautils',
- 'javelin-workflow',
- 'javelin-vector',
- 'phuix-autocomplete',
- 'javelin-mask',
- ),
'0f764c35' => array(
'javelin-install',
'javelin-util',
@@ -1822,6 +1811,17 @@
'javelin-util',
'phabricator-busy',
),
+ 'acd29eee' => array(
+ 'javelin-behavior',
+ 'javelin-stratcom',
+ 'javelin-dom',
+ 'phabricator-phtize',
+ 'phabricator-textareautils',
+ 'javelin-workflow',
+ 'javelin-vector',
+ 'phuix-autocomplete',
+ 'javelin-mask',
+ ),
'b003d4fb' => array(
'javelin-behavior',
'javelin-stratcom',
@@ -2087,12 +2087,6 @@
'javelin-json',
'phabricator-prefab',
),
- 'd713a2c5' => array(
- 'javelin-install',
- 'javelin-dom',
- 'phuix-icon-view',
- 'phabricator-prefab',
- ),
'd7a74243' => array(
'javelin-behavior',
'javelin-stratcom',
@@ -2220,6 +2214,12 @@
'javelin-util',
'javelin-reactor',
),
+ 'f6699267' => array(
+ 'javelin-install',
+ 'javelin-dom',
+ 'phuix-icon-view',
+ 'phabricator-prefab',
+ ),
'f7fc67ec' => array(
'javelin-install',
'javelin-typeahead',
diff --git a/webroot/rsrc/js/core/behavior-phabricator-remarkup-assist.js b/webroot/rsrc/js/core/behavior-phabricator-remarkup-assist.js
--- a/webroot/rsrc/js/core/behavior-phabricator-remarkup-assist.js
+++ b/webroot/rsrc/js/core/behavior-phabricator-remarkup-assist.js
@@ -393,6 +393,12 @@
return;
}
+ // Let other listeners (particularly the inline autocomplete) have a
+ // chance to handle this event.
+ if (JX.Stratcom.pass()) {
+ return;
+ }
+
var raw = e.getRawEvent();
if (raw.shiftKey) {
// If the shift key is pressed, let the browser write a newline into
@@ -412,8 +418,7 @@
// This allows 'workflow' and similar actions to take effect.
// Such as pontificate in Conpherence
var form = e.getNode('tag:form');
- var r = JX.DOM.invoke(form, 'didSyntheticSubmit');
-
+ JX.DOM.invoke(form, 'didSyntheticSubmit');
});
}
diff --git a/webroot/rsrc/js/phuix/PHUIXAutocomplete.js b/webroot/rsrc/js/phuix/PHUIXAutocomplete.js
--- a/webroot/rsrc/js/phuix/PHUIXAutocomplete.js
+++ b/webroot/rsrc/js/phuix/PHUIXAutocomplete.js
@@ -127,7 +127,7 @@
}
// Get all the text on the current line. If the line only contains
- // whitespace, don't actiavte: the user is probably typing code or a
+ // whitespace, don't activate: the user is probably typing code or a
// numbered list.
var line = area.value.substring(0, head - 1);
line = line.split('\n');
@@ -454,7 +454,7 @@
// If the user hasn't typed any text yet after typing the character
// which can summon the autocomplete, deactivate and let the keystroke
- // through. For example, We hit this when a line ends with an
+ // through. For example, we hit this when a line ends with an
// autocomplete character and the user is trying to type a newline.
if (range.start == this._cursorHead) {
this._deactivate();
@@ -529,9 +529,13 @@
}
}
+ // Deactivate immediately if the user types an ignored token like ":)",
+ // the smiley face emoticon. Note that we test against "text", not
+ // "trim", because the ignore list and suffix list can otherwise
+ // interact destructively.
var ignore = this._getIgnoreList();
for (ii = 0; ii < ignore.length; ii++) {
- if (trim.indexOf(ignore[ii]) === 0) {
+ if (text.indexOf(ignore[ii]) === 0) {
this._deactivate();
return;
}

File Metadata

Mime Type
text/plain
Expires
Sat, Mar 15, 7:47 PM (3 w, 3 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7702758
Default Alt Text
D17794.id42786.diff (6 KB)

Event Timeline