Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add icons to activity navigation #1622

Merged
merged 1 commit into from
Oct 5, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions apps/comments/lib/Activity/Extension.php
Original file line number Diff line number Diff line change
Expand Up @@ -247,14 +247,15 @@ public function getGroupParameter($activity) {
public function getNavigation() {
$l = $this->getL10N();
return [
'apps' => [],
'top' => [
'apps' => [
self::APP_NAME => [
'id' => self::APP_NAME,
'icon' => 'icon-comment',
'name' => (string) $l->t('Comments'),
'url' => $this->URLGenerator->linkToRoute('activity.Activities.showList', ['filter' => self::APP_NAME]),
],
],
'top' => [],
];
}

Expand Down
2 changes: 2 additions & 0 deletions apps/files/lib/Activity.php
Original file line number Diff line number Diff line change
Expand Up @@ -306,13 +306,15 @@ public function getNavigation() {
'top' => [
self::FILTER_FAVORITES => [
'id' => self::FILTER_FAVORITES,
'icon' => 'icon-favorite',
'name' => (string) $this->l->t('Favorites'),
'url' => $this->URLGenerator->linkToRoute('activity.Activities.showList', ['filter' => self::FILTER_FAVORITES]),
],
],
'apps' => [
self::FILTER_FILES => [
'id' => self::FILTER_FILES,
'icon' => 'icon-files-dark',
'name' => (string) $this->l->t('Files'),
'url' => $this->URLGenerator->linkToRoute('activity.Activities.showList', ['filter' => self::FILTER_FILES]),
],
Expand Down
1 change: 1 addition & 0 deletions apps/files_sharing/lib/Activity.php
Original file line number Diff line number Diff line change
Expand Up @@ -429,6 +429,7 @@ public function getNavigation() {
'top' => [
self::FILTER_SHARES => [
'id' => self::FILTER_SHARES,
'icon' => 'icon-share',
'name' => (string) $l->t('Shares'),
'url' => $this->URLGenerator->linkToRoute('activity.Activities.showList', ['filter' => self::FILTER_SHARES]),
],
Expand Down
2 changes: 1 addition & 1 deletion apps/systemtags/lib/Activity/Extension.php
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ public function getDefaultTypes($method) {
public function getTypeIcon($type) {
switch ($type) {
case self::APP_NAME:
return false;
return 'icon-tag';
}

return false;
Expand Down
7 changes: 7 additions & 0 deletions core/css/icons.css
Original file line number Diff line number Diff line change
Expand Up @@ -282,6 +282,10 @@ img.icon-loading-small-dark, object.icon-loading-small-dark, video.icon-loading-
background-image: url('../img/actions/sound-off.svg?v=1');
}

.icon-favorite {
background-image: url('../img/actions/star-dark.svg?v=1');
}

.icon-star,
.icon-starred:hover,
.icon-starred:focus {
Expand Down Expand Up @@ -365,6 +369,9 @@ img.icon-loading-small-dark, object.icon-loading-small-dark, video.icon-loading-
.icon-files {
background-image: url('../img/places/files.svg?v=1');
}
.icon-files-dark {
background-image: url('../img/places/files-dark.svg?v=1');
}
.icon-file,
.icon-filetype-text {
background-image: url('../img/filetypes/text.svg?v=1');
Expand Down
1 change: 1 addition & 0 deletions core/img/actions/star-dark.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions core/img/places/files-dark.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.