diff --git a/resources/celerity/map.php b/resources/celerity/map.php index 469dc9eb02..d2953c72dd 100644 --- a/resources/celerity/map.php +++ b/resources/celerity/map.php @@ -9,7 +9,7 @@ return array( 'names' => array( 'conpherence.pkg.css' => 'a520d619', 'conpherence.pkg.js' => '6249a1cf', - 'core.pkg.css' => '1179d101', + 'core.pkg.css' => '0d7ecd3b', 'core.pkg.js' => '1fa7c0c5', 'darkconsole.pkg.js' => 'e7393ebb', 'differential.pkg.css' => '4815647b', @@ -55,7 +55,7 @@ return array( 'rsrc/css/application/contentsource/content-source-view.css' => '4b8b05d4', 'rsrc/css/application/countdown/timer.css' => '16c52f5c', 'rsrc/css/application/daemon/bulk-job.css' => 'df9c1d4a', - 'rsrc/css/application/dashboard/dashboard.css' => '005e064e', + 'rsrc/css/application/dashboard/dashboard.css' => '0921c307', 'rsrc/css/application/diff/inline-comment-summary.css' => '51efda3a', 'rsrc/css/application/differential/add-comment.css' => 'c47f8c40', 'rsrc/css/application/differential/changeset-view.css' => '6a9bdf9c', @@ -392,7 +392,7 @@ return array( 'rsrc/js/application/countdown/timer.js' => 'e4cc26b3', 'rsrc/js/application/daemon/behavior-bulk-job-reload.js' => 'edf8a145', 'rsrc/js/application/dashboard/behavior-dashboard-async-panel.js' => '469c0d9e', - 'rsrc/js/application/dashboard/behavior-dashboard-move-panels.js' => '019f36c4', + 'rsrc/js/application/dashboard/behavior-dashboard-move-panels.js' => '408bf173', 'rsrc/js/application/dashboard/behavior-dashboard-query-panel-select.js' => '453c5375', 'rsrc/js/application/dashboard/behavior-dashboard-tab-panel.js' => 'd4eecc63', 'rsrc/js/application/diff/behavior-preview-link.js' => '051c7832', @@ -617,7 +617,7 @@ return array( 'javelin-behavior-countdown-timer' => 'e4cc26b3', 'javelin-behavior-dark-console' => 'f411b6ae', 'javelin-behavior-dashboard-async-panel' => '469c0d9e', - 'javelin-behavior-dashboard-move-panels' => '019f36c4', + 'javelin-behavior-dashboard-move-panels' => '408bf173', 'javelin-behavior-dashboard-query-panel-select' => '453c5375', 'javelin-behavior-dashboard-tab-panel' => 'd4eecc63', 'javelin-behavior-day-view' => '4b3c4443', @@ -786,7 +786,7 @@ return array( 'phabricator-content-source-view-css' => '4b8b05d4', 'phabricator-core-css' => '9f4cb463', 'phabricator-countdown-css' => '16c52f5c', - 'phabricator-dashboard-css' => '005e064e', + 'phabricator-dashboard-css' => '0921c307', 'phabricator-drag-and-drop-file-upload' => '58dea2fa', 'phabricator-draggable-list' => 'bea6e7f4', 'phabricator-fatal-config-template-css' => '8f18fa41', @@ -927,14 +927,6 @@ return array( 'javelin-request', 'javelin-typeahead-source', ), - '019f36c4' => array( - 'javelin-behavior', - 'javelin-dom', - 'javelin-util', - 'javelin-stratcom', - 'javelin-workflow', - 'phabricator-draggable-list', - ), '01fca1f0' => array( 'javelin-behavior', 'javelin-workflow', @@ -1161,6 +1153,14 @@ return array( 'javelin-workflow', 'javelin-stratcom', ), + '408bf173' => array( + 'javelin-behavior', + 'javelin-dom', + 'javelin-util', + 'javelin-stratcom', + 'javelin-workflow', + 'phabricator-draggable-list', + ), '40a6a403' => array( 'javelin-install', 'javelin-dom', diff --git a/src/applications/dashboard/engine/PhabricatorDashboardPanelRenderingEngine.php b/src/applications/dashboard/engine/PhabricatorDashboardPanelRenderingEngine.php index fbd5aaa2bb..26aa24cb0c 100644 --- a/src/applications/dashboard/engine/PhabricatorDashboardPanelRenderingEngine.php +++ b/src/applications/dashboard/engine/PhabricatorDashboardPanelRenderingEngine.php @@ -13,6 +13,7 @@ final class PhabricatorDashboardPanelRenderingEngine extends Phobject { private $parentPanelPHIDs; private $headerMode = self::HEADER_MODE_NORMAL; private $dashboardID; + private $movable = true; public function setDashboardID($id) { $this->dashboardID = $id; @@ -63,6 +64,15 @@ final class PhabricatorDashboardPanelRenderingEngine extends Phobject { return $this; } + public function setMovable($movable) { + $this->movable = $movable; + return $this; + } + + public function getMovable() { + return $this->movable; + } + public function getPanel() { return $this->panel; } @@ -221,8 +231,13 @@ final class PhabricatorDashboardPanelRenderingEngine extends Phobject { $box ->setHeader($header) ->setID($id) + ->addClass('dashboard-box') ->addSigil('dashboard-panel'); + if ($this->getMovable()) { + $box->addSigil('panel-movable'); + } + if ($panel) { $box->setMetadata( array( diff --git a/src/applications/dashboard/paneltype/PhabricatorDashboardTabsPanelType.php b/src/applications/dashboard/paneltype/PhabricatorDashboardTabsPanelType.php index 292446fe55..b4772ba83f 100644 --- a/src/applications/dashboard/paneltype/PhabricatorDashboardTabsPanelType.php +++ b/src/applications/dashboard/paneltype/PhabricatorDashboardTabsPanelType.php @@ -97,6 +97,7 @@ final class PhabricatorDashboardTabsPanelType ->setPanel($panel) ->setPanelPHID($panel->getPHID()) ->setHeaderMode($no_headers) + ->setMovable(false) ->renderPanel(); } else { $panel_content = pht('(Invalid Panel)'); diff --git a/webroot/rsrc/css/application/dashboard/dashboard.css b/webroot/rsrc/css/application/dashboard/dashboard.css index 8bce842053..037dd227df 100644 --- a/webroot/rsrc/css/application/dashboard/dashboard.css +++ b/webroot/rsrc/css/application/dashboard/dashboard.css @@ -14,12 +14,12 @@ margin: 0 0 16px 0; } -.dashboard-view .phui-header-shell { +.dashboard-box .phui-header-shell { padding-top: 4px; padding-bottom: 16px; } -.dashboard-view .phui-header-header { +.dashboard-box .phui-header-header { color: #000; } @@ -49,16 +49,16 @@ width: 66.66%; } -.grippable .aphront-multi-column-column .dashboard-pane .phui-object-box { +.grippable .aphront-multi-column-column .dashboard-box.phui-object-box { cursor: move; } -.grippable .aphront-multi-column-column .dashboard-pane .phui-object-box:hover { +.grippable .aphront-multi-column-column .dashboard-box.phui-object-box:hover { box-shadow: {$dropshadow}; } -.grippable .aphront-multi-column-column .dashboard-pane .phui-object-box:hover - .phui-object-box { +.grippable .aphront-multi-column-column .dashboard-box.phui-object-box:hover + .dashboard-box { box-shadow: none; } diff --git a/webroot/rsrc/js/application/dashboard/behavior-dashboard-move-panels.js b/webroot/rsrc/js/application/dashboard/behavior-dashboard-move-panels.js index fbbf411be8..d8d08eca5f 100644 --- a/webroot/rsrc/js/application/dashboard/behavior-dashboard-move-panels.js +++ b/webroot/rsrc/js/application/dashboard/behavior-dashboard-move-panels.js @@ -10,7 +10,7 @@ JX.behavior('dashboard-move-panels', function(config) { - var itemSigil = 'dashboard-panel'; + var itemSigil = 'panel-movable'; function finditems(col) { return JX.DOM.scry(col, 'div', itemSigil);