Page MenuHomePhabricator

D12801.id30769.diff
No OneTemporary

D12801.id30769.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' => 'ed3d6355',
- 'core.pkg.js' => '31eaf90a',
+ 'core.pkg.js' => '73942604',
'darkconsole.pkg.js' => 'e7393ebb',
'differential.pkg.css' => 'bb338e4b',
'differential.pkg.js' => '895b8d62',
@@ -122,7 +122,7 @@
'rsrc/css/layout/phabricator-source-code-view.css' => '2ceee894',
'rsrc/css/phui/calendar/phui-calendar-day.css' => '49037167',
'rsrc/css/phui/calendar/phui-calendar-list.css' => 'c1d0ca59',
- 'rsrc/css/phui/calendar/phui-calendar-month.css' => 'a92e47d2',
+ 'rsrc/css/phui/calendar/phui-calendar-month.css' => '55953dd2',
'rsrc/css/phui/calendar/phui-calendar.css' => '8675968e',
'rsrc/css/phui/phui-action-header-view.css' => '89c497e7',
'rsrc/css/phui/phui-action-list.css' => '4f4d09f2',
@@ -211,7 +211,7 @@
'rsrc/externals/javelin/lib/Resource.js' => '44959b73',
'rsrc/externals/javelin/lib/Routable.js' => 'b3e7d692',
'rsrc/externals/javelin/lib/Router.js' => '29274e2b',
- 'rsrc/externals/javelin/lib/Scrollbar.js' => '4f812f8a',
+ 'rsrc/externals/javelin/lib/Scrollbar.js' => '087e919c',
'rsrc/externals/javelin/lib/Sound.js' => '949c0fe5',
'rsrc/externals/javelin/lib/URI.js' => '6eff08aa',
'rsrc/externals/javelin/lib/Vector.js' => '2caa8fb8',
@@ -681,7 +681,7 @@
'javelin-resource' => '44959b73',
'javelin-routable' => 'b3e7d692',
'javelin-router' => '29274e2b',
- 'javelin-scrollbar' => '4f812f8a',
+ 'javelin-scrollbar' => '087e919c',
'javelin-sound' => '949c0fe5',
'javelin-stratcom' => '6c53634d',
'javelin-tokenizer' => 'ab5f468d',
@@ -779,7 +779,7 @@
'phui-calendar-css' => '8675968e',
'phui-calendar-day-css' => '49037167',
'phui-calendar-list-css' => 'c1d0ca59',
- 'phui-calendar-month-css' => 'a92e47d2',
+ 'phui-calendar-month-css' => '55953dd2',
'phui-crumbs-view-css' => '594d719e',
'phui-document-view-css' => '94d5dcd8',
'phui-feed-story-css' => 'c9f3a0b5',
@@ -868,6 +868,12 @@
'javelin-uri',
'phabricator-file-upload',
),
+ '087e919c' => array(
+ 'javelin-install',
+ 'javelin-dom',
+ 'javelin-stratcom',
+ 'javelin-vector',
+ ),
'0a3f3021' => array(
'javelin-behavior',
'javelin-stratcom',
@@ -1134,12 +1140,6 @@
'javelin-stratcom',
'javelin-request',
),
- '4f812f8a' => array(
- 'javelin-install',
- 'javelin-dom',
- 'javelin-stratcom',
- 'javelin-vector',
- ),
'4fdb476d' => array(
'javelin-behavior',
'javelin-stratcom',
diff --git a/src/view/phui/calendar/PHUICalendarDayView.php b/src/view/phui/calendar/PHUICalendarDayView.php
--- a/src/view/phui/calendar/PHUICalendarDayView.php
+++ b/src/view/phui/calendar/PHUICalendarDayView.php
@@ -271,12 +271,14 @@
$widget = new PHUICalendarWidgetView();
$list = id(new PHUICalendarListView())
- ->setUser($this->user);
+ ->setUser($this->user)
+ ->setIsDayView(true);
if (count($events) == 0) {
$list->showBlankState(true);
} else {
- foreach ($events as $event) {
+ $sorted_events = msort($events, 'getEpochStart');
+ foreach ($sorted_events as $event) {
$list->addEvent($event);
}
}
diff --git a/src/view/phui/calendar/PHUICalendarListView.php b/src/view/phui/calendar/PHUICalendarListView.php
--- a/src/view/phui/calendar/PHUICalendarListView.php
+++ b/src/view/phui/calendar/PHUICalendarListView.php
@@ -5,6 +5,7 @@
private $events = array();
private $blankState;
private $showMoreURI;
+ private $isDayView = false;
public function addEvent(AphrontCalendarEventView $event) {
$this->events[] = $event;
@@ -15,6 +16,11 @@
$this->showMoreURI = $uri;
}
+ public function setIsDayView($is_day_view) {
+ $this->isDayView = $is_day_view;
+ return $this;
+ }
+
public function getEventCount() {
return count($this->events);
}
@@ -76,7 +82,8 @@
$class = 'phui-calendar-list-item phui-calendar-'.$color;
if ($event->getIsAllDay()) {
- $class = $class.' all-day';
+ $all_day_class = $this->isDayView ? ' sidebar-all-day' : ' all-day';
+ $class = $class.$all_day_class;
}
$singletons[] = phutil_tag(

File Metadata

Mime Type
text/plain
Expires
Sun, Mar 23, 1:33 PM (1 w, 6 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7582032
Default Alt Text
D12801.id30769.diff (4 KB)

Event Timeline