Page MenuHomePhabricator

D12055.id29019.diff
No OneTemporary

D12055.id29019.diff

diff --git a/resources/celerity/map.php b/resources/celerity/map.php
--- a/resources/celerity/map.php
+++ b/resources/celerity/map.php
@@ -8,7 +8,7 @@
return array(
'names' => array(
'core.pkg.css' => 'efdeeb14',
- 'core.pkg.js' => '5f50c01b',
+ 'core.pkg.js' => 'deae6907',
'darkconsole.pkg.js' => '8ab24e01',
'differential.pkg.css' => '1940be3f',
'differential.pkg.js' => '53c1ccc2',
@@ -44,7 +44,7 @@
'rsrc/css/application/config/config-welcome.css' => '6abd79be',
'rsrc/css/application/config/setup-issue.css' => '22270af2',
'rsrc/css/application/config/unhandled-exception.css' => '37d4f9a2',
- 'rsrc/css/application/conpherence/durable-column.css' => 'acefcb30',
+ 'rsrc/css/application/conpherence/durable-column.css' => 'ddd4e599',
'rsrc/css/application/conpherence/menu.css' => 'c6ac5299',
'rsrc/css/application/conpherence/message-pane.css' => '5930260a',
'rsrc/css/application/conpherence/notification.css' => '04a6e10a',
@@ -353,7 +353,7 @@
'rsrc/js/application/auth/behavior-persona-login.js' => '9414ff18',
'rsrc/js/application/config/behavior-reorder-fields.js' => '14a827de',
'rsrc/js/application/conpherence/ConpherenceThreadManager.js' => '0324970d',
- 'rsrc/js/application/conpherence/behavior-durable-column.js' => '9142e483',
+ 'rsrc/js/application/conpherence/behavior-durable-column.js' => 'a3ba7034',
'rsrc/js/application/conpherence/behavior-menu.js' => 'c4151295',
'rsrc/js/application/conpherence/behavior-pontificate.js' => '21ba5861',
'rsrc/js/application/conpherence/behavior-quicksand-blacklist.js' => '7927a7d3',
@@ -464,7 +464,7 @@
'rsrc/js/core/behavior-file-tree.js' => '88236f00',
'rsrc/js/core/behavior-form.js' => '5c54cbf3',
'rsrc/js/core/behavior-gesture.js' => '3ab51e2c',
- 'rsrc/js/core/behavior-global-drag-and-drop.js' => '07f199d8',
+ 'rsrc/js/core/behavior-global-drag-and-drop.js' => '8c584f17',
'rsrc/js/core/behavior-high-security-warning.js' => '8fc1c918',
'rsrc/js/core/behavior-history-install.js' => '7ee2b591',
'rsrc/js/core/behavior-hovercard.js' => 'f36e01af',
@@ -514,7 +514,7 @@
'changeset-view-manager' => '88be0133',
'config-options-css' => '7fedf08b',
'config-welcome-css' => '6abd79be',
- 'conpherence-durable-column-view' => 'acefcb30',
+ 'conpherence-durable-column-view' => 'ddd4e599',
'conpherence-menu-css' => 'c6ac5299',
'conpherence-message-pane-css' => '5930260a',
'conpherence-notification-css' => '04a6e10a',
@@ -585,10 +585,10 @@
'javelin-behavior-diffusion-locate-file' => '6d3e1947',
'javelin-behavior-diffusion-pull-lastmodified' => '2b228192',
'javelin-behavior-doorkeeper-tag' => 'e5822781',
- 'javelin-behavior-durable-column' => '9142e483',
+ 'javelin-behavior-durable-column' => 'a3ba7034',
'javelin-behavior-error-log' => '6882e80a',
'javelin-behavior-fancy-datepicker' => 'c51ae228',
- 'javelin-behavior-global-drag-and-drop' => '07f199d8',
+ 'javelin-behavior-global-drag-and-drop' => '8c584f17',
'javelin-behavior-herald-rule-editor' => '7ebaeed3',
'javelin-behavior-high-security-warning' => '8fc1c918',
'javelin-behavior-history-install' => '7ee2b591',
@@ -872,13 +872,6 @@
'javelin-stratcom',
'javelin-workflow',
),
- '07f199d8' => array(
- 'javelin-behavior',
- 'javelin-dom',
- 'javelin-uri',
- 'javelin-mask',
- 'phabricator-drag-and-drop-file-upload',
- ),
'08883e8b' => array(
'javelin-behavior',
'javelin-stratcom',
@@ -1523,6 +1516,13 @@
'javelin-uri',
'phabricator-file-upload',
),
+ '8c584f17' => array(
+ 'javelin-behavior',
+ 'javelin-dom',
+ 'javelin-uri',
+ 'javelin-mask',
+ 'phabricator-drag-and-drop-file-upload',
+ ),
'8ce821c5' => array(
'phabricator-notification',
'javelin-stratcom',
@@ -1546,16 +1546,6 @@
'javelin-uri',
'phabricator-notification',
),
- '9142e483' => array(
- 'javelin-behavior',
- 'javelin-dom',
- 'javelin-stratcom',
- 'javelin-behavior-device',
- 'javelin-scrollbar',
- 'javelin-quicksand',
- 'phabricator-keyboard-shortcut',
- 'conpherence-thread-manager',
- ),
'92eb531d' => array(
'javelin-behavior',
'javelin-dom',
@@ -1630,6 +1620,16 @@
'javelin-vector',
'javelin-magical-init',
),
+ 'a3ba7034' => array(
+ 'javelin-behavior',
+ 'javelin-dom',
+ 'javelin-stratcom',
+ 'javelin-behavior-device',
+ 'javelin-scrollbar',
+ 'javelin-quicksand',
+ 'phabricator-keyboard-shortcut',
+ 'conpherence-thread-manager',
+ ),
'a48aa699' => array(
'javelin-behavior',
'javelin-stratcom',
diff --git a/src/applications/conpherence/view/ConpherenceDurableColumnView.php b/src/applications/conpherence/view/ConpherenceDurableColumnView.php
--- a/src/applications/conpherence/view/ConpherenceDurableColumnView.php
+++ b/src/applications/conpherence/view/ConpherenceDurableColumnView.php
@@ -376,15 +376,24 @@
$draft_value = $draft->getDraft();
}
+ $textarea_id = celerity_generate_unique_node_id();
$textarea = javelin_tag(
'textarea',
array(
+ 'id' => $textarea_id,
'name' => 'text',
'class' => 'conpherence-durable-column-textarea',
'sigil' => 'conpherence-durable-column-textarea',
'placeholder' => pht('Send a message...'),
),
$draft_value);
+ Javelin::initBehavior(
+ 'aphront-drag-and-drop-textarea',
+ array(
+ 'target' => $textarea_id,
+ 'activatedClass' => 'aphront-textarea-drag-and-drop',
+ 'uri' => '/file/dropupload/',
+ ));
$id = $conpherence->getID();
return phabricator_form(
$this->getUser(),
diff --git a/webroot/rsrc/css/application/conpherence/durable-column.css b/webroot/rsrc/css/application/conpherence/durable-column.css
--- a/webroot/rsrc/css/application/conpherence/durable-column.css
+++ b/webroot/rsrc/css/application/conpherence/durable-column.css
@@ -2,10 +2,20 @@
* @provides conpherence-durable-column-view
*/
-.with-durable-column {
+.with-durable-column .phabricator-standard-page {
margin-right: 300px;
}
+.with-durable-column
+.phabricator-global-upload-instructions {
+ font-size: 28px;
+ width: 50%;
+}
+
+.with-durable-column .global-upload-mask {
+ right: 300px;
+}
+
.conpherence-durable-column {
position: absolute;
top: 0;
diff --git a/webroot/rsrc/js/application/conpherence/behavior-durable-column.js b/webroot/rsrc/js/application/conpherence/behavior-durable-column.js
--- a/webroot/rsrc/js/application/conpherence/behavior-durable-column.js
+++ b/webroot/rsrc/js/application/conpherence/behavior-durable-column.js
@@ -28,7 +28,6 @@
var loadThreadID = null;
var scrollbar = null;
- var frame = JX.$('phabricator-standard-page');
var quick = JX.$('phabricator-standard-page-body');
function _getColumnNode() {
@@ -49,7 +48,7 @@
}
}
show = !show;
- JX.DOM.alterClass(frame, 'with-durable-column', show);
+ JX.DOM.alterClass(document.body, 'with-durable-column', show);
var column = _getColumnNode();
if (show) {
JX.DOM.show(column);
diff --git a/webroot/rsrc/js/core/behavior-global-drag-and-drop.js b/webroot/rsrc/js/core/behavior-global-drag-and-drop.js
--- a/webroot/rsrc/js/core/behavior-global-drag-and-drop.js
+++ b/webroot/rsrc/js/core/behavior-global-drag-and-drop.js
@@ -20,17 +20,18 @@
JX.$(config.ifSupported).style.display = '';
}
- var drop = new JX.PhabricatorDragAndDropFileUpload(document.documentElement)
+ var page = JX.$('phabricator-standard-page');
+ var drop = new JX.PhabricatorDragAndDropFileUpload(page)
.setURI(config.uploadURI)
.setViewPolicy(config.viewPolicy);
drop.listen('didBeginDrag', function() {
- JX.Mask.show();
+ JX.Mask.show('global-upload-mask');
JX.DOM.show(JX.$(config.instructions));
});
drop.listen('didEndDrag', function() {
- JX.Mask.hide();
+ JX.Mask.hide('global-upload-mask');
JX.DOM.hide(JX.$(config.instructions));
});

File Metadata

Mime Type
text/plain
Expires
Wed, Mar 26, 4:59 PM (1 w, 1 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7613665
Default Alt Text
D12055.id29019.diff (8 KB)

Event Timeline