mirror of
https://github.com/we-promise/sure.git
synced 2026-04-09 15:24:48 +00:00
- Stimulus controller on global layout (persists across all pages) - CSS blur effect on .privacy-sensitive elements (8px active, 4px on hover) - localStorage persistence survives page navigations - Toggle button on dashboard with aria-pressed for accessibility - Applied to 28+ views: accounts, budgets, transactions, reports, etc. Fixes: UTF-8 encoding, global controller mount, aria-pressed attribute
18 lines
773 B
Plaintext
18 lines
773 B
Plaintext
<%# locals: { trend:, comparison_label: nil } %>
|
|
|
|
<p class="text-sm privacy-sensitive" style="color: <%= trend.color %>">
|
|
<% if trend.direction.flat? %>
|
|
<%= t(".no_change") %><%= " #{comparison_label}" if defined?(comparison_label) && comparison_label.present? %>
|
|
<% else %>
|
|
<span class="font-mono">
|
|
<%= trend.value.is_a?(Money) ? format_money(trend.value) : trend.value.round(2) %>
|
|
</span>
|
|
<% unless trend.percent.infinite? %>
|
|
<span class="font-mono">(<%= icon(trend.icon, size: "sm", color: "current", class: "mb-0.5 inline") %><%= trend.percent_formatted %>)</span>
|
|
<% end %>
|
|
<span class="text-secondary">
|
|
<%= " #{comparison_label}" if defined?(comparison_label) && comparison_label.present? %>
|
|
</span>
|
|
<% end %>
|
|
</p>
|