2025-02-21 11:57:59 -05:00
|
|
|
<%= content_for :page_title, t(".page_title") %>
|
2024-10-24 11:02:27 -04:00
|
|
|
|
2025-02-21 11:57:59 -05:00
|
|
|
<%= settings_section title: t(".subscription_title"), subtitle: t(".subscription_subtitle") do %>
|
|
|
|
<div class="space-y-4">
|
2025-04-11 09:28:00 -05:00
|
|
|
<div class="p-3 shadow-border-xs bg-container rounded-lg flex justify-between items-center">
|
2025-02-21 11:57:59 -05:00
|
|
|
<div class="flex items-center gap-3">
|
|
|
|
<div class="w-9 h-9 rounded-full bg-gray-25 flex justify-center items-center">
|
2025-04-30 18:14:22 -04:00
|
|
|
<%= icon "gem" %>
|
2024-10-24 11:02:27 -04:00
|
|
|
</div>
|
|
|
|
|
2025-02-21 11:57:59 -05:00
|
|
|
<div class="text-sm space-y-1">
|
|
|
|
<% if @user.family.subscribed? || subscription_pending? %>
|
|
|
|
<p class="text-primary">You are currently subscribed to <span class="font-medium">Maybe+</span></p>
|
|
|
|
<% else %>
|
|
|
|
<p class="text-primary">You are currently <span class="font-medium">not subscribed</span></p>
|
|
|
|
<p class="text-secondary">Once you subscribe to Maybe+, you'll see your billing settings here.</p>
|
2024-10-24 11:02:27 -04:00
|
|
|
<% end %>
|
2025-02-21 11:57:59 -05:00
|
|
|
</div>
|
2024-10-24 11:02:27 -04:00
|
|
|
</div>
|
|
|
|
|
2025-02-21 11:57:59 -05:00
|
|
|
<% if @user.family.subscribed? || subscription_pending? %>
|
2025-04-30 18:14:22 -04:00
|
|
|
<%= render LinkComponent.new(
|
|
|
|
text: "Manage",
|
|
|
|
icon: "external-link",
|
|
|
|
variant: "primary",
|
|
|
|
icon_position: "right",
|
|
|
|
href: subscription_path,
|
|
|
|
target: "_blank",
|
|
|
|
rel: "noopener"
|
|
|
|
) %>
|
2025-02-21 11:57:59 -05:00
|
|
|
<% else %>
|
2025-04-30 18:14:22 -04:00
|
|
|
<%= render LinkComponent.new(
|
|
|
|
text: "Subscribe",
|
|
|
|
variant: "primary",
|
|
|
|
icon: "external-link",
|
|
|
|
icon_position: "right",
|
|
|
|
href: new_subscription_path,
|
|
|
|
target: "_blank",
|
|
|
|
rel: "noopener") %>
|
2025-02-21 11:57:59 -05:00
|
|
|
<% end %>
|
2024-10-24 11:02:27 -04:00
|
|
|
</div>
|
2024-10-08 14:37:47 -05:00
|
|
|
|
2025-02-21 11:57:59 -05:00
|
|
|
<div class="flex items-center gap-2">
|
|
|
|
<%= image_tag "stripe-logo.svg", class: "w-5 h-5 shrink-0" %>
|
2025-03-11 13:00:34 -05:00
|
|
|
<p class="text-secondary text-sm">Billing via Stripe</p>
|
2025-02-21 11:57:59 -05:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<% end %>
|