mirror of
https://github.com/we-promise/sure.git
synced 2026-05-25 13:34:58 +00:00
* Extract hardcoded strings to i18n
Replace numerous hardcoded English strings with I18n lookups (t / I18n.t) across controllers, views, helpers, and components, and convert model validation error messages to symbol keys. Added multiple locale files under config/locales for models and views. This centralizes user-facing notices/alerts, UI text, import/validation messages, and prepares the app for localization and easier translation maintenance.
* Update en.yml
* Update preview-cleanup.yml
* Revert "Update preview-cleanup.yml"
This reverts commit 1ba6d3c34c.
* test: align i18n assertions with translated messages
* Standardize balance error key and tweak locales
Replace SophtronAccount's :requires_balance error key with :no_balance and update related locale strings for sophtron, plaid, and simplefin accounts to use the new key and clearer copy. Also switch the QIF upload redirect notice to use a relative translation key (t('.qif_uploaded')), remove an unused SSO providers help line, and fix a trailing-newline/whitespace issue in the subscriptions locale. These changes standardize validation keys and improve translation consistency and messaging.
---------
Co-authored-by: KiloClaw <kiloclaw@openclaw.ai>
63 lines
2.3 KiB
Plaintext
63 lines
2.3 KiB
Plaintext
<div class="flex flex-col h-full justify-between bg-surface">
|
|
<nav class="p-4">
|
|
<h1 class="sr-only"><%= t(".page_title") %></h1>
|
|
|
|
<div class="flex justify-end gap-2">
|
|
<%= render DS::Link.new(
|
|
text: t(".account_settings"),
|
|
icon: "settings",
|
|
variant: "ghost",
|
|
href: settings_profile_path,
|
|
) %>
|
|
|
|
<%= render DS::Button.new(
|
|
text: t(".sign_out"),
|
|
icon: "log-out",
|
|
icon_position: :right,
|
|
variant: "ghost",
|
|
href: session_path(Current.session),
|
|
method: :delete
|
|
) %>
|
|
</div>
|
|
</nav>
|
|
|
|
<div class="grow flex flex-col items-center justify-center">
|
|
<%= image_tag "logo-color.png", class: "w-16 mb-6" %>
|
|
|
|
<% if Current.family.trialing? %>
|
|
<p class="text-xl lg:text-3xl text-primary font-display font-medium"><%= t("subscriptions.upgrade.trialing", count: Current.family.days_left_in_trial, days: Current.family.days_left_in_trial) %></p>
|
|
<% else %>
|
|
<p class="text-xl lg:text-3xl text-primary font-display font-medium"><%= t("subscriptions.upgrade.trial_over") %></p>
|
|
<% end %>
|
|
|
|
<h2 class="text-xl lg:text-3xl font-display font-medium mb-2">
|
|
<span class="text-secondary"><%= t("subscriptions.upgrade.header.support") %></span>
|
|
<span class="bg-gradient-to-r from-[#EABE7F] to-[#957049] bg-clip-text text-transparent"><%= t("subscriptions.upgrade.header.sure") %></span>
|
|
<span class="text-secondary"><%= t("subscriptions.upgrade.header.today") %></span>
|
|
</h2>
|
|
|
|
<p class="text-sm text-secondary mb-8"><%= t("subscriptions.upgrade.cta") %></p>
|
|
|
|
<%= form_with url: new_subscription_path, method: :get, class: "max-w-xs", data: { turbo: false } do |form| %>
|
|
<div class="space-y-4 mb-6">
|
|
<%= render "subscriptions/plan_choice", form: form, plan: "annual", checked: @plan == "annual" %>
|
|
<%= render "subscriptions/plan_choice", form: form, plan: "monthly", checked: @plan == "monthly" %>
|
|
</div>
|
|
|
|
<div class="text-center space-y-2">
|
|
<%= render DS::Button.new(
|
|
text: t("subscriptions.upgrade.contribute_and_support_sure"),
|
|
variant: "primary",
|
|
full_width: true
|
|
) %>
|
|
|
|
<p class="text-xs text-secondary">
|
|
<%= t("subscriptions.upgrade.redirect_to_stripe") %>
|
|
</p>
|
|
</div>
|
|
<% end %>
|
|
</div>
|
|
|
|
<%= render "layouts/shared/footer" %>
|
|
</div>
|