Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15491464
D16563.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
7 KB
Referenced Files
None
Subscribers
None
D16563.diff
View Options
diff --git a/resources/celerity/map.php b/resources/celerity/map.php
--- a/resources/celerity/map.php
+++ b/resources/celerity/map.php
@@ -7,7 +7,7 @@
*/
return array(
'names' => array(
- 'conpherence.pkg.css' => '1e8e5a40',
+ 'conpherence.pkg.css' => '80a3fcb3',
'conpherence.pkg.js' => '89b4837e',
'core.pkg.css' => '476e9330',
'core.pkg.js' => '1d376fa9',
@@ -48,8 +48,8 @@
'rsrc/css/application/config/unhandled-exception.css' => '4c96257a',
'rsrc/css/application/conpherence/durable-column.css' => '194ac487',
'rsrc/css/application/conpherence/header-pane.css' => '517de9fe',
- 'rsrc/css/application/conpherence/menu.css' => '8344d122',
- 'rsrc/css/application/conpherence/message-pane.css' => 'c075e8fe',
+ 'rsrc/css/application/conpherence/menu.css' => '78c7b811',
+ 'rsrc/css/application/conpherence/message-pane.css' => '8d13ac4d',
'rsrc/css/application/conpherence/notification.css' => '6cdcc253',
'rsrc/css/application/conpherence/participant-pane.css' => '7bba0b56',
'rsrc/css/application/conpherence/transaction.css' => '46253e19',
@@ -620,8 +620,8 @@
'config-page-css' => '8798e14f',
'conpherence-durable-column-view' => '194ac487',
'conpherence-header-pane-css' => '517de9fe',
- 'conpherence-menu-css' => '8344d122',
- 'conpherence-message-pane-css' => 'c075e8fe',
+ 'conpherence-menu-css' => '78c7b811',
+ 'conpherence-message-pane-css' => '8d13ac4d',
'conpherence-notification-css' => '6cdcc253',
'conpherence-participant-pane-css' => '7bba0b56',
'conpherence-thread-manager' => '01774ab2',
diff --git a/src/applications/conpherence/controller/ConpherenceViewController.php b/src/applications/conpherence/controller/ConpherenceViewController.php
--- a/src/applications/conpherence/controller/ConpherenceViewController.php
+++ b/src/applications/conpherence/controller/ConpherenceViewController.php
@@ -154,7 +154,7 @@
$button_text = pht('Send');
} else if ($user->isLoggedIn()) {
$action = ConpherenceUpdateActions::JOIN_ROOM;
- $button_text = pht('Join');
+ $button_text = pht('Join Room');
} else {
// user not logged in so give them a login button.
$login_href = id(new PhutilURI('/auth/start/'))
diff --git a/src/applications/conpherence/view/ConpherenceLayoutView.php b/src/applications/conpherence/view/ConpherenceLayoutView.php
--- a/src/applications/conpherence/view/ConpherenceLayoutView.php
+++ b/src/applications/conpherence/view/ConpherenceLayoutView.php
@@ -72,6 +72,7 @@
$selected_thread_id = null;
$selected_thread_phid = null;
$can_edit_selected = null;
+ $nux = null;
if ($this->thread) {
$selected_id = $this->thread->getPHID().'-nav-item';
$selected_thread_id = $this->thread->getID();
@@ -80,6 +81,8 @@
$this->getUser(),
$this->thread,
PhabricatorPolicyCapability::CAN_EDIT);
+ } else {
+ $nux = $this->buildNUXView();
}
$this->initBehavior('conpherence-menu',
array(
@@ -146,29 +149,7 @@
'sigil' => 'conpherence-no-threads',
'style' => 'display: none;',
),
- array(
- phutil_tag(
- 'div',
- array(
- 'class' => 'text',
- ),
- pht('You are not in any rooms yet.')),
- javelin_tag(
- 'a',
- array(
- 'href' => '/conpherence/search/',
- 'class' => 'button grey mlr',
- ),
- pht('Join a Room')),
- javelin_tag(
- 'a',
- array(
- 'href' => '/conpherence/new/',
- 'class' => 'button grey',
- 'sigil' => 'workflow',
- ),
- pht('Create a Room')),
- )),
+ $nux),
javelin_tag(
'div',
array(
@@ -224,4 +205,55 @@
));
}
+ private function buildNUXView() {
+ $viewer = $this->getViewer();
+
+ $engine = new ConpherenceThreadSearchEngine();
+ $engine->setViewer($viewer);
+ $saved = $engine->buildSavedQueryFromBuiltin('all');
+ $query = $engine->buildQueryFromSavedQuery($saved);
+ $pager = $engine->newPagerForSavedQuery($saved);
+ $pager->setPageSize(10);
+ $results = $engine->executeQuery($query, $pager);
+ $view = $engine->renderResults($results, $saved);
+
+ $create_button = id(new PHUIButtonView())
+ ->setTag('a')
+ ->setText(pht('New Room'))
+ ->setHref('/conpherence/new/')
+ ->setWorkflow(true)
+ ->setColor(PHUIButtonView::GREEN);
+
+ if ($results) {
+ $create_button->setIcon('fa-comments');
+
+ $header = id(new PHUIHeaderView())
+ ->setHeader(pht('Joinable Rooms'))
+ ->addActionLink($create_button);
+
+ $box = id(new PHUIObjectBoxView())
+ ->setHeader($header)
+ ->setObjectList($view->getObjectList());
+ if ($viewer->isLoggedIn()) {
+ $info = id(new PHUIInfoView())
+ ->appendChild(pht('You have not joined any rooms yet.'))
+ ->setSeverity(PHUIInfoView::SEVERITY_NOTICE);
+ $box->setInfoView($info);
+ }
+
+ return $box;
+ } else {
+
+ $view = id(new PHUIBigInfoView())
+ ->setIcon('fa-comments')
+ ->setTitle(pht('Welcome to Conpherence'))
+ ->setDescription(
+ pht('Conpherence lets you create public or private rooms to '.
+ 'communicate with others.'))
+ ->addAction($create_button);
+
+ return $view;
+ }
+ }
+
}
diff --git a/webroot/rsrc/css/application/conpherence/menu.css b/webroot/rsrc/css/application/conpherence/menu.css
--- a/webroot/rsrc/css/application/conpherence/menu.css
+++ b/webroot/rsrc/css/application/conpherence/menu.css
@@ -11,27 +11,6 @@
background: #fff;
}
-.conpherence-layout .conpherence-no-threads {
- text-align: center;
- position: fixed;
- left: 240px;
- right: 240px;
- top: 76px;
- bottom: 0px;
- min-width: 300px;
- width: auto;
-}
-
-.device .conpherence-layout .conpherence-no-threads {
- left: 0;
- right: 0;
- width: 100%;
-}
-
-.conpherence-layout .conpherence-no-threads .text {
- margin: 0px 0px 16px 0px;
-}
-
.conpherence-menu-pane {
width: 100%;
position: absolute;
diff --git a/webroot/rsrc/css/application/conpherence/message-pane.css b/webroot/rsrc/css/application/conpherence/message-pane.css
--- a/webroot/rsrc/css/application/conpherence/message-pane.css
+++ b/webroot/rsrc/css/application/conpherence/message-pane.css
@@ -24,12 +24,20 @@
width: 100%;
}
-.conpherence-layout .conpherence-no-threads {
- text-align: center;
+.conpherence-layout .conpherence-content-pane .conpherence-no-threads {
+ top: 44px;
+ right: 0;
+ background: #fff;
+ z-index: 26;
}
-.conpherence-layout .conpherence-no-threads .text {
- margin: 16px 0px 16px 0px;
+.conpherence-layout .phui-big-info-view {
+ margin: 16px;
+}
+
+.conpherence-layout .conpherence-no-threads .phui-box-border {
+ border: none;
+ margin: 0;
}
.conpherence-show-more-messages {
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Apr 13, 3:49 AM (1 w, 3 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7355969
Default Alt Text
D16563.diff (7 KB)
Attached To
Mode
D16563: New NUX states for Conpherence
Attached
Detach File
Event Timeline
Log In to Comment