summaryrefslogtreecommitdiffstats
path: root/templates/part.content.php
diff options
context:
space:
mode:
authorBernhard Posselt <dev@bernhard-posselt.com>2014-10-21 18:19:23 +0200
committerBernhard Posselt <dev@bernhard-posselt.com>2014-10-21 18:19:23 +0200
commit66c73a96ac2dda076bcfe0dc0a1ca2a7e169149d (patch)
treedc0318fa459e4f313217ee38e4bc63524513d721 /templates/part.content.php
parentf5e64d35c05b14016eb4fffff7199386a97a9b43 (diff)
first try to set indention limit at 80 characters in php
Diffstat (limited to 'templates/part.content.php')
-rw-r--r--templates/part.content.php91
1 files changed, 71 insertions, 20 deletions
diff --git a/templates/part.content.php b/templates/part.content.php
index 10f8d860e..beb8bd24d 100644
--- a/templates/part.content.php
+++ b/templates/part.content.php
@@ -2,13 +2,21 @@
<div news-auto-focus="#app-content"
id="articles"
- ng-class="{compact: Content.isCompactView(), 'feed-view': Content.isFeed()}">
- <div class="pull-to-refresh" ng-class="{'show-pull-to-refresh': showPullToRefresh}">
- <button ng-click="Content.refresh()"><?php p($l->t('Refresh')) ?> (r)</button>
+ ng-class="{
+ compact: Content.isCompactView(),
+ 'feed-view': Content.isFeed()
+ }">
+ <div class="pull-to-refresh" ng-class="{
+ 'show-pull-to-refresh': showPullToRefresh
+ }">
+ <button ng-click="Content.refresh()">
+ <?php p($l->t('Refresh')) ?> (r)
+ </button>
</div>
<ul>
<li class="item {{ Content.getFeed(item.feedId).cssClass }}"
- ng-repeat="item in Content.getItems() | orderBy:[Content.orderBy()] track by item.id"
+ ng-repeat="item in Content.getItems() |
+ orderBy:[Content.orderBy()] track by item.id"
ng-click="Content.markRead(item.id)"
ng-class="{read: !item.unread, open: item.show}"
data-id="{{ item.id }}">
@@ -26,22 +34,53 @@
</li>
<li class="title only-in-compact"
title="{{ item.title }}"
- ng-class="{'icon-rss': !Content.getFeed(item.feedId).faviconLink }"
- ng-style="{ backgroundImage: 'url(' + Content.getFeed(item.feedId).faviconLink + ')'}">
+ ng-class="{
+ 'icon-rss':
+ !Content.getFeed(item.feedId).faviconLink
+ }"
+ ng-style="{
+ backgroundImage:
+ 'url('
+ + Content.getFeed(item.feedId).faviconLink +
+ ')'
+ }">
<h1><a>{{ item.title }}</a></h1>
</li>
<li class="only-in-compact">
- <time class="date" title="{{ item.pubDate*1000|date:'yyyy-MM-dd HH:mm:ss' }}"
- datetime="{{ item.pubDate*1000|date:'yyyy-MM-ddTHH:mm:ssZ' }}">{{ Content.getRelativeDate(item.pubDate) }}
+ <time class="date"
+ title="{{ item.pubDate*1000 |
+ date:'yyyy-MM-dd HH:mm:ss' }}"
+ datetime="{{ item.pubDate*1000 |
+ date:'yyyy-MM-ddTHH:mm:ssZ' }}">
+ {{ Content.getRelativeDate(item.pubDate) }}
</time>
</li>
- <li ng-click="Content.toggleStar(item.id)" class="util" news-stop-propagation>
- <button class="star svg" ng-hide="item.starred" title="<?php p($l->t('Star article')); ?>"></button>
- <button class="starred svg" ng-show="item.starred" title="<?php p($l->t('Unstar article')); ?>"></button>
+ <li ng-click="Content.toggleStar(item.id)"
+ class="util"
+ news-stop-propagation>
+ <button class="star svg"
+ ng-hide="item.starred"
+ title="<?php p($l->t('Star article')); ?>">
+ </button>
+ <button class="starred svg"
+ ng-show="item.starred"
+ title="<?php p($l->t('Unstar article')); ?>">
+ </button>
</li>
- <li ng-click="Content.toggleKeepUnread(item.id)" class="util" news-stop-propagation>
- <button class="icon-toggle toggle-keep-unread" ng-hide="item.keepUnread" title="<?php p($l->t('Keep article unread')); ?>"></button>
- <button class="icon-toggle toggle-keep-unread keep-unread" ng-show="item.keepUnread" title="<?php p($l->t('Remove keep article unread')); ?>"></button>
+ <li ng-click="Content.toggleKeepUnread(item.id)"
+ class="util"
+ news-stop-propagation>
+ <button class="icon-toggle toggle-keep-unread"
+ ng-hide="item.keepUnread"
+ title="<?php p($l->t('Keep article unread')); ?>">
+ </button>
+ <button
+ class="icon-toggle toggle-keep-unread keep-unread"
+ ng-show="item.keepUnread"
+ title="<?php
+ p($l->t('Remove keep article unread'));
+ ?>">
+ </button>
</li>
</ul>
</div>
@@ -49,8 +88,13 @@
<div class="article">
<div class="heading only-in-expanded">
- <time class="date" title="{{ item.pubDate*1000|date:'yyyy-MM-dd HH:mm:ss' }}"
- datetime="{{ item.pubDate*1000|date:'yyyy-MM-ddTHH:mm:ssZ' }}">{{ Content.getRelativeDate(item.pubDate) }}</time>
+ <time class="date"
+ title="{{ item.pubDate*1000 |
+ date:'yyyy-MM-dd HH:mm:ss' }}"
+ datetime="{{ item.pubDate*1000 |
+ date:'yyyy-MM-ddTHH:mm:ssZ' }}">
+ {{ Content.getRelativeDate(item.pubDate) }}
+ </time>
<h1>
<a class="external"
target="_blank"
@@ -62,8 +106,14 @@
</div>
<div class="subtitle">
- <span class="author" ng-show="item.author"> <?php p($l->t('by')) ?> {{ item.author }}</span>
- <span class="source"><?php p($l->t('from')) ?> <a ng-href="#/items/feeds/{{ item.feedId }}/">{{ Content.getFeed(item.feedId).title }}</a></span>
+ <span class="author" ng-show="item.author">
+ <?php p($l->t('by')) ?> {{ item.author }}
+ </span>
+ <span class="source"><?php p($l->t('from')) ?>
+ <a ng-href="#/items/feeds/{{ item.feedId }}/">
+ {{ Content.getFeed(item.feedId).title }}
+ </a>
+ </span>
</div>
@@ -72,8 +122,9 @@
<news-enclosure type="{{ item.enclosureMime }}"
link="{{ item.enclosureLink }}">
<p class="enclosure-error">
- <?php p($l->t('Browser can not play media type')) ?>:
- {{ item.enclosureMime }}
+ <?php
+ p($l->t('Browser can not play media type'))
+ ?>: {{ item.enclosureMime }}
</p>
<a class="button"
ng-href="{{ item.enclosureLink | trustUrl }}"