]> git.mxchange.org Git - friendica.git/commitdiff
Update search_item.tpl
authorRaroun <Raroun@users.noreply.github.com>
Sun, 19 Nov 2023 08:52:40 +0000 (09:52 +0100)
committerGitHub <noreply@github.com>
Sun, 19 Nov 2023 08:52:40 +0000 (09:52 +0100)
Added new behavior here also

view/theme/frio/templates/search_item.tpl

index 513ee0a1c290c6247f97d73b3dc2ca3655fabac3..533eb88fce284c09a37986bda8ed2d266af4302e 100644 (file)
                        {{* contact info header*}}
                        <div class="contact-info hidden-sm hidden-xs media-body"><!-- Desktop -->
                                <div class="preferences">
-                                       {{if $item.network_icon != ""}}
-                                               <span class="wall-item-network"><i class="fa fa-{{$item.network_icon}}" title="{{$item.network_name}}" aria-hidden="true"></i></span>
-                                       {{else}}
-                                               <span class="wall-item-network" title="{{$item.app}}">{{$item.network_name}}</span>
-                                       {{/if}}
-                                       {{if $item.plink}}      {{*link to the original source of the item *}}
-                                               <a href="{{$item.plink.href}}" class="plink u-url" aria-label="{{$item.plink.title}}" title="{{$item.plink.title}}">
-                                                       <i class="fa fa-external-link"></i>
-                                               </a>
-                                       {{/if}}
+                                       {{if $item.network_icon && $item.plink}}
+                                               <span class="wall-item-network"><a href="{{$item.plink.href}}" class="plink u-url" aria-label="{{$item.plink.title}}" target="_blank"><i class="fa fa-{{$item.network_icon}} fakelink" title="{{$item.network_name}} - {{$item.plink.title}}" aria-hidden="true"></i></a></span>
+                                       {{elseif $item.plink}}
+                                                       <a href="{{$item.plink.href}}" class="plink u-url" aria-label="{{$item.plink.title}}" title="{{$item.network_name}} - {{$item.plink.title}}" target="_blank">{{$item.network_name}}</a>
+                                       {{elseif $item.network_icon}}
+                                                       <span class="wall-item-network"><i class="fa fa-{{$item.network_icon}}" title="{{$item.network_name}}" aria-hidden="true"></i></span>
+                                       {{else}}
+                                               <span class="wall-item-network" title="{{$item.app}}">{{$item.network_name}}</span>
+                                       {{/if}}
+
                                </div>
                                <h4 class="media-heading">
                                        <a href="{{$item.profile_url}}" title="{{$item.linktitle}}" class="wall-item-name-link userinfo hover-card">
                        {{* contact info header for smartphones *}}
                        <div class="contact-info contact-info-xs hidden-lg hidden-md">
                                <div class="preferences">
-                                       {{if $item.network_icon != ""}}
-                                               <span class="wall-item-network"><i class="fa fa-{{$item.network_icon}}" title="{{$item.network_name}}" aria-hidden="true"></i></span>
-                                       {{else}}
-                                               <span class="wall-item-network" title="{{$item.app}}">{{$item.network_name}}</span>
-                                       {{/if}}
-                                       {{if $item.plink}}      {{*link to the original source of the item *}}
-                                               <a href="{{$item.plink.href}}" class="plink u-url" aria-label="{{$item.plink.title}}" title="{{$item.plink.title}}">
-                                                       <i class="fa fa-external-link"></i>
-                                               </a>
-                                       {{/if}}
+                                       {{if $item.network_icon && $item.plink}}
+                                               <span class="wall-item-network"><a href="{{$item.plink.href}}" class="plink u-url" aria-label="{{$item.plink.title}}" target="_blank"><i class="fa fa-{{$item.network_icon}} fakelink" title="{{$item.network_name}} - {{$item.plink.title}}" aria-hidden="true"></i></a></span>
+                                       {{elseif $item.plink}}
+                                                       <a href="{{$item.plink.href}}" class="plink u-url" aria-label="{{$item.plink.title}}" title="{{$item.network_name}} - {{$item.plink.title}}" target="_blank">{{$item.network_name}}</a>
+                                       {{elseif $item.network_icon}}
+                                                       <span class="wall-item-network"><i class="fa fa-{{$item.network_icon}}" title="{{$item.network_name}}" aria-hidden="true"></i></span>
+                                       {{else}}
+                                               <span class="wall-item-network" title="{{$item.app}}">{{$item.network_name}}</span>
+                                       {{/if}}
                                </div>
                                <h5 class="media-heading">
                                        <a href="{{$item.profile_url}}" title="{{$item.linktitle}}" class="wall-item-name-link userinfo hover-card"><span>{{$item.name}}</span></a>