style: update time display format
- Replace local timezone display with UTC in the weather display components - Adjust time formatting in both city and weather art views This change standardizes the time format across the application, making it clear that the displayed times are in UTC, aiding user understanding and consistency in time representation.
This commit is contained in:
parent
b01cbe960a
commit
681ad5320f
@ -35,7 +35,8 @@
|
||||
<%= "#{@city&.country&.emoji + " " || ""}#{@city&.country&.name}" %>, <%= @city.region %>
|
||||
</div>
|
||||
<div class="badge badge-lg badge-secondary gap-2">
|
||||
<%= @city.timezone.present? ? Time.current.in_time_zone(@city.timezone).strftime("%Y-%m-%d %H:%M") : "Timezone undefined" %>
|
||||
<%#= @city.timezone.present? ? Time.current.in_time_zone(@city.timezone).strftime("%Y-%m-%d %H:%M") : "Timezone undefined" %>
|
||||
<%= @city&.state&.name %>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -109,7 +110,7 @@
|
||||
<div class="flex items-center justify-between text-white">
|
||||
<div class="text-2xl font-bold"><%= art.temperature %>°C</div>
|
||||
<div class="text-right">
|
||||
<div class="font-medium"><%= art.created_at.strftime("%H:%M") %></div>
|
||||
<div class="font-medium">UTC <%= art.created_at.strftime("%H:%M") %></div>
|
||||
<div class="text-sm opacity-80"><%= art.weather_date.strftime("%B %d, %Y") %></div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -55,7 +55,7 @@
|
||||
<%= @weather_art.weather_date.strftime("%B %d, %Y") %>
|
||||
</div>
|
||||
<div class="badge badge-lg badge-secondary">
|
||||
<%= @weather_art.created_at.strftime("%H:%M") %>
|
||||
UTC <%= @weather_art.created_at.strftime("%H:%M") %>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user