Improve subtle awareness of key to hide donate prompts

- Add tooltips on sidebar and header support links (key option on hover)
- Add muted 'Get a one-time key' line under donate page hero
- Add muted key hint in about page support section
- Rephrase dashboard widget to 'You can hide this with a one-time key'
- Add new translatable strings to en messages.po
This commit is contained in:
Dries Peeters
2026-02-28 17:28:04 +01:00
parent 61256cdc60
commit 52a30edf43
5 changed files with 40 additions and 4 deletions
+2 -2
View File
@@ -954,7 +954,7 @@
</li>
{% if current_user.is_authenticated and (not settings or not getattr(settings, 'donate_ui_hidden', false)) and current_user.ui_show_donate %}
<li class="mt-2">
<a href="{{ url_for('main.donate') }}" class="sidebar-nav-item flex items-center p-2 rounded-lg {% if ep == 'main.donate' %}bg-background-light dark:bg-background-dark text-primary font-semibold{% else %}bg-gradient-to-r from-amber-500/10 to-orange-500/10 border border-amber-500/20 text-amber-600 dark:text-amber-400 hover:from-amber-500/20 hover:to-orange-500/20 hover:border-amber-500/30{% endif %} transition-all duration-200 group">
<a href="{{ url_for('main.donate') }}" class="sidebar-nav-item flex items-center p-2 rounded-lg {% if ep == 'main.donate' %}bg-background-light dark:bg-background-dark text-primary font-semibold{% else %}bg-gradient-to-r from-amber-500/10 to-orange-500/10 border border-amber-500/20 text-amber-600 dark:text-amber-400 hover:from-amber-500/20 hover:to-orange-500/20 hover:border-amber-500/30{% endif %} transition-all duration-200 group" title="{{ _('Support development — or purchase a key to hide this') }}">
<i class="fas fa-mug-saucer w-6 text-center group-hover:scale-110 transition-transform"></i>
<span class="ml-3 sidebar-label font-medium">{{ _('Support Development') }}</span>
<span class="ml-auto text-xs opacity-70"></span>
@@ -1003,7 +1003,7 @@
rel="noopener noreferrer"
onclick="trackDonationClick('header')"
class="hidden md:flex items-center gap-2 px-3 py-1.5 rounded-lg bg-gradient-to-r from-amber-500/10 to-orange-500/10 border border-amber-500/20 text-amber-600 dark:text-amber-400 hover:from-amber-500/20 hover:to-orange-500/20 hover:border-amber-500/30 transition-all duration-200 text-sm font-medium"
title="{{ _('Support TimeTracker development') }}">
title="{{ _('Support development (key available to hide this)') }}">
<i class="fas fa-mug-saucer"></i>
<span class="hidden lg:inline">{{ _('Support') }}</span>
</a>
+4
View File
@@ -208,6 +208,10 @@
<i class="fas fa-mug-saucer mr-2"></i>{{ _('Donate Now') }}
</a>
</div>
<p class="mt-3 text-xs text-amber-700 dark:text-amber-300">
{{ _('Admins can purchase a key to hide support prompts for this instance.') }}
<a href="{{ support_purchase_url }}" target="_blank" rel="noopener noreferrer" class="underline hover:no-underline">{{ _('Purchase a key') }}</a>.
</p>
</div>
</div>
</div>
+2 -2
View File
@@ -517,8 +517,8 @@
</a>
</div>
<p class="mt-3 text-xs opacity-90">
{{ _('Want to hide this widget?') }}
<a href="{{ support_purchase_url }}" target="_blank" rel="noopener noreferrer" class="underline hover:no-underline font-medium">{{ _('Purchase a key') }}</a>.
{{ _('You can hide this with a one-time key.') }}
<a href="{{ support_purchase_url }}" target="_blank" rel="noopener noreferrer" class="underline hover:no-underline font-medium">{{ _('Get key') }}</a>
</p>
</div>
{% endif %}
+4
View File
@@ -28,6 +28,10 @@
<i class="fas fa-external-link-alt ml-2 text-xs"></i>
</a>
</div>
<p class="mt-4 text-sm opacity-80">
{{ _('Prefer to remove these prompts?') }}
<a href="{{ support_purchase_url }}" target="_blank" rel="noopener noreferrer" class="underline hover:no-underline">{{ _('Get a one-time key') }}</a>.
</p>
</div>
</div>