mirror of
https://framagit.org/hubzilla/core.git
synced 2026-06-21 00:52:33 -04:00
streamline location rendering
This commit is contained in:
@@ -1467,14 +1467,18 @@ function render_location_default($item) {
|
||||
$location = $item['location'];
|
||||
$coord = $item['coord'];
|
||||
|
||||
if($coord) {
|
||||
if ($coord) {
|
||||
if($location)
|
||||
$location .= ' <span class="smalltext">(' . $coord . ')</span>';
|
||||
$location .= ' (' . $coord . ')';
|
||||
else
|
||||
$location = '<span class="smalltext">' . $coord . '</span>';
|
||||
$location = $coord;
|
||||
}
|
||||
|
||||
return $location;
|
||||
if (!$location) {
|
||||
return '';
|
||||
}
|
||||
|
||||
return '<i class="bi bi-geo-alt" title="' . $location . '"></i>';
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -29,14 +29,14 @@
|
||||
<div class="p-2 wall-item-head{{if !$item.title && !$item.event && !$item.photo}} rounded-top{{/if}}{{if $item.is_new && !$item.event && !$item.is_comment}} wall-item-head-new{{/if}} clearfix">
|
||||
<div class="lh-sm text-end float-end">
|
||||
<div class="wall-item-ago opacity-75" id="wall-item-ago-{{$item.id}}">
|
||||
{{if $item.editedtime}}
|
||||
<i class="bi bi-pencil"></i>
|
||||
{{if $item.location}}
|
||||
{{$item.location}}
|
||||
{{/if}}
|
||||
{{if $item.delayed}}
|
||||
<i class="bi bi-clock"></i>
|
||||
{{/if}}
|
||||
{{if $item.location}}
|
||||
<small class="wall-item-location p-location" id="wall-item-location-{{$item.id}}">{{$item.location}}</small>
|
||||
{{if $item.editedtime}}
|
||||
<i class="bi bi-pencil"></i>
|
||||
{{/if}}
|
||||
{{if $item.verified}}
|
||||
<i class="bi bi-shield-check" title="{{$item.verified}}"></i>
|
||||
|
||||
@@ -23,14 +23,14 @@
|
||||
<div class="p-2 wall-item-head{{if !$item.title && !$item.event && !$item.photo}} rounded-top{{/if}}{{if $item.is_new && !$item.event && !$item.is_comment}} wall-item-head-new{{/if}}" >
|
||||
<div class="lh-sm text-end float-end">
|
||||
<div class="wall-item-ago opacity-75" id="wall-item-ago-{{$item.id}}">
|
||||
{{if $item.editedtime}}
|
||||
<i class="bi bi-pencil"></i>
|
||||
{{if $item.location}}
|
||||
{{$item.location}}
|
||||
{{/if}}
|
||||
{{if $item.delayed}}
|
||||
<i class="bi bi-clock"></i>
|
||||
{{/if}}
|
||||
{{if $item.location}}
|
||||
<small class="wall-item-location p-location" id="wall-item-location-{{$item.id}}">{{$item.location}}</small>
|
||||
{{if $item.editedtime}}
|
||||
<i class="bi bi-pencil"></i>
|
||||
{{/if}}
|
||||
{{if $item.verified}}
|
||||
<i class="bi bi-shield-check" title="{{$item.verified}}"></i>
|
||||
|
||||
@@ -138,12 +138,12 @@
|
||||
<div class="btn-group me-2 d-none d-lg-flex">
|
||||
{{if $setloc}}
|
||||
<button type="button" id="profile-location-wrapper" class="btn btn-outline-secondary btn-sm border-0" title="{{$setloc}}" onclick="jotGetLocation();return false;">
|
||||
<i id="profile-location" class="bi bi-geo-fill jot-icons"></i>
|
||||
<i id="profile-location" class="bi bi-geo-alt-fill jot-icons"></i>
|
||||
</button>
|
||||
{{/if}}
|
||||
{{if $clearloc}}
|
||||
<button type="button" id="profile-nolocation-wrapper" class="btn btn-outline-secondary btn-sm border-0" title="{{$clearloc}}" onclick="jotClearLocation();return false;" disabled="disabled">
|
||||
<i id="profile-nolocation" class="bi bi-geo jot-icons"></i>
|
||||
<i id="profile-nolocation" class="bi bi-geo-alt jot-icons"></i>
|
||||
</button>
|
||||
{{/if}}
|
||||
{{else}}
|
||||
@@ -193,10 +193,10 @@
|
||||
<a class="dropdown-item" href="#" onclick="initializeEmbedPhotoDialog(); return false;"><i class="bi bi-file-image jot-icons"></i> {{$embedPhotos}}</a>
|
||||
{{/if}}
|
||||
{{if $setloc}}
|
||||
<a class="dropdown-item" href="#" onclick="jotGetLocation(); return false;"><i class="bi bi-geo-fill"></i> {{$setloc}}</a>
|
||||
<a class="dropdown-item" href="#" onclick="jotGetLocation(); return false;"><i class="bi bi-geo-alt-fill"></i> {{$setloc}}</a>
|
||||
{{/if}}
|
||||
{{if $clearloc}}
|
||||
<a class="dropdown-item" href="#" onclick="jotClearLocation(); return false;"><i class="bi bi-geo"></i> {{$clearloc}}</a>
|
||||
<a class="dropdown-item" href="#" onclick="jotClearLocation(); return false;"><i class="bi bi-geo-alt"></i> {{$clearloc}}</a>
|
||||
{{/if}}
|
||||
{{/if}}
|
||||
{{if $feature_expire}}
|
||||
|
||||
@@ -23,14 +23,14 @@
|
||||
<div class="p-2 wall-item-head{{if !$item.title && !$item.event && !$item.photo}} rounded-top{{/if}}{{if $item.is_new && !$item.event && !$item.is_comment}} wall-item-head-new{{/if}}" >
|
||||
<div class="lh-sm text-end float-end">
|
||||
<div class="wall-item-ago opacity-75" id="wall-item-ago-{{$item.id}}">
|
||||
{{if $item.editedtime}}
|
||||
<i class="bi bi-pencil"></i>
|
||||
{{if $item.location}}
|
||||
{{$item.location}}
|
||||
{{/if}}
|
||||
{{if $item.delayed}}
|
||||
<i class="bi bi-clock"></i>
|
||||
{{/if}}
|
||||
{{if $item.location}}
|
||||
<small class="wall-item-location p-location" id="wall-item-location-{{$item.id}}">{{$item.location}}</small>
|
||||
{{if $item.editedtime}}
|
||||
<i class="bi bi-pencil"></i>
|
||||
{{/if}}
|
||||
{{if $item.verified}}
|
||||
<i class="bi bi-shield-check" title="{{$item.verified}}"></i>
|
||||
|
||||
Reference in New Issue
Block a user