From b4e83b65375e62259671749c089d9cd7a2a2967a Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Wed, 14 Oct 2015 22:14:19 +0200 Subject: allow photo-items to appear full width if large photos feature is enabled. in prepare_body() split off mentions, tags, categories folders and attachments from body for easier theming. some other little fixes. --- view/tpl/conv_item.tpl | 49 +++++++++++++++---------- view/tpl/item_attach.tpl | 9 ++--- view/tpl/item_categories.tpl | 2 +- view/tpl/search_item.tpl | 85 ++++++++++++++++++++++++++++++-------------- 4 files changed, 93 insertions(+), 52 deletions(-) (limited to 'view/tpl') diff --git a/view/tpl/conv_item.tpl b/view/tpl/conv_item.tpl index a9661d9b5..5bac5b412 100755 --- a/view/tpl/conv_item.tpl +++ b/view/tpl/conv_item.tpl @@ -33,29 +33,42 @@
-
+
{{$item.body}} - {{if $item.tags}} -
- {{foreach $item.tags as $tag}} - {{$tag}} - {{/foreach}} -
- {{/if}} - {{if $item.has_cats}} -
- {{$item.txt_cats}} {{foreach $item.categories as $cat}}{{$cat.name}} [{{$remove}}] {{if $cat.last}}{{else}}, {{/if}}{{/foreach}} -
- {{/if}} - {{if $item.has_folders}} -
- {{$item.txt_folders}} {{foreach $item.folders as $cat}}{{$cat.name}} [{{$remove}}] {{if $cat.last}}{{else}}, {{/if}}{{/foreach}} -
- {{/if}}
+ {{if $item.has_tags}} +
+ {{if $item.mentions}} +
+ {{$item.mentions}} +
+ {{/if}} + {{if $item.tags}} +
+ {{$item.tags}} +
+ {{/if}} + {{if $item.categories}} +
+ {{$item.categories}} +
+ {{/if}} + {{if $item.folders}} +
+ {{$item.folders}} +
+ {{/if}} + {{if $item.attachments}} +
+ {{$item.attachments}} +
+ {{/if}} +
+
+ {{/if}}
{{if $item.like}} diff --git a/view/tpl/item_attach.tpl b/view/tpl/item_attach.tpl index eeea25967..7638f39e7 100644 --- a/view/tpl/item_attach.tpl +++ b/view/tpl/item_attach.tpl @@ -1,8 +1,5 @@ -
{{if $attaches}} -
- {{foreach $attaches as $a}} - - {{/foreach}} -
+{{foreach $attaches as $a}} + {{$a.label}} +{{/foreach}} {{/if}} diff --git a/view/tpl/item_categories.tpl b/view/tpl/item_categories.tpl index ec2639a6f..eea0e0b8f 100644 --- a/view/tpl/item_categories.tpl +++ b/view/tpl/item_categories.tpl @@ -1,7 +1,7 @@ {{if $categories}}
{{foreach $categories as $cat}} - {{if $cat.url}}{{$cat.term}}{{else}}{{$cat.term}}{{/if}} +{{if $cat.url}}{{$cat.term}}{{else}}{{$cat.term}}{{/if}} {{/foreach}}
{{/if}} diff --git a/view/tpl/search_item.tpl b/view/tpl/search_item.tpl index 256443b84..003dae993 100755 --- a/view/tpl/search_item.tpl +++ b/view/tpl/search_item.tpl @@ -2,33 +2,68 @@
-
-
- {{$item.name}} +
+
+
+ {{$item.name}} +
+
-
-
- {{if $item.title}} -

{{$item.title}}

- {{/if}} - {{if $item.lock}} - - {{/if}} -
- {{$item.name}}{{if $item.owner_url}} {{$item.via}} {{$item.owner_name}}{{/if}} -
-
- {{if $item.verified}} {{elseif $item.forged}} {{/if}}{{if $item.location}}{{$item.location}}, {{/if}}{{$item.localtime}}{{if $item.editedtime}} {{$item.editedtime}}{{/if}}{{if $item.expiretime}} {{$item.expiretime}}{{/if}}{{if $item.editedtime}} {{/if}} {{if $item.app}}{{$item.str_app}}{{/if}} + {{if $item.title}} +
+

{{if $item.title_tosource}}{{if $item.plink}}{{/if}}{{/if}}{{$item.title}}{{if $item.title_tosource}}{{if $item.plink}}{{/if}}{{/if}}

+
+ {{/if}} + {{if $item.lock}} + + {{/if}} +
+ {{$item.name}}{{if $item.owner_url}} {{$item.via}} {{$item.owner_name}}{{/if}} +
+
+ {{if $item.verified}} {{elseif $item.forged}} {{/if}}{{if $item.location}}{{$item.location}}, {{/if}}{{$item.localtime}}{{if $item.editedtime}} {{$item.editedtime}}{{/if}}{{if $item.expiretime}} {{$item.expiretime}}{{/if}}{{if $item.editedtime}} {{/if}} {{if $item.app}}{{$item.str_app}}{{/if}} +
+
-
-
+
{{$item.body}}
+
-
+ {{if $item.has_tags}} +
+ {{if $item.mentions}} +
+ {{$item.mentions}} +
+ {{/if}} + {{if $item.tags}} +
+ {{$item.tags}} +
+ {{/if}} + {{if $item.categories}} +
+ {{$item.categories}} +
+ {{/if}} + {{if $item.folders}} +
+ {{$item.folders}} +
+ {{/if}} + {{if $item.attachments}} +
+ {{$item.attachments}} +
+ {{/if}} +
+
+ {{/if}} +
+
- {{* we dont' use this do we? - {{if $item.drop.pagedrop}} - - {{/if}} - *}}
-- cgit v1.2.3