mirror of
https://github.com/plausible/analytics.git
synced 2024-12-18 14:51:57 +03:00
844af698ce
* Add embedded mode for shared links * Add test for X-Frame-Options * Improve embed code generator * Add changelog entry Co-authored-by: aymanterra <aymanterra@users.noreply.github.com> Co-authored-by: Brad Kane <bradkane@users.noreply.github.com>
48 lines
3.1 KiB
Elixir
48 lines
3.1 KiB
Elixir
<%= if @conn.private[:phoenix_flash] do %>
|
|
<%= render("_flash.html", assigns) %>
|
|
<% end %>
|
|
|
|
<%= if @conn.assigns[:current_user] && @conn.assigns[:current_user].subscription && @conn.assigns[:current_user].subscription.status == "past_due" do %>
|
|
<div class="container">
|
|
<div class="p-2 bg-yellow-100 rounded-lg sm:p-3">
|
|
<div class="flex flex-wrap items-center justify-between">
|
|
<div class="flex items-center flex-1 w-0">
|
|
<svg class="w-6 h-6 text-yellow-800" viewBox="0 0 24 24" stroke="currentColor" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
<path d="M12 9V11M12 15H12.01M5.07183 19H18.9282C20.4678 19 21.4301 17.3333 20.6603 16L13.7321 4C12.9623 2.66667 11.0378 2.66667 10.268 4L3.33978 16C2.56998 17.3333 3.53223 19 5.07183 19Z" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
|
</svg>
|
|
<p class="ml-3 font-medium text-yellow-800">
|
|
Your latest payment failed. Please provide valid payment details to keep using Plausible.
|
|
</p>
|
|
</div>
|
|
<div class="flex-shrink-0 order-3 w-full mt-2 sm:order-2 sm:mt-0 sm:w-auto">
|
|
<div class="rounded-md shadow-sm">
|
|
<%= link("Update billing info", to: @conn.assigns[:current_user].subscription.update_url, class: "flex items-center justify-center px-4 py-2 border border-transparent text-sm leading-5 font-medium rounded-md text-gray-600 dark:text-gray-400 bg-white dark:bg-gray-800 hover:text-gray-500 dark:hover:text-gray-200 focus:outline-none focus:ring transition ease-in-out duration-150") %>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<% end %>
|
|
|
|
<%= if @conn.assigns[:current_user] && @conn.assigns[:current_user].subscription && @conn.assigns[:current_user].subscription.status == "paused" do %>
|
|
<div class="container">
|
|
<div class="p-2 bg-red-100 rounded-lg sm:p-3">
|
|
<div class="flex flex-wrap items-center justify-between">
|
|
<div class="flex items-center flex-1 w-0">
|
|
<svg class="w-6 h-6 text-red-800" viewBox="0 0 24 24" stroke="currentColor" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
<path d="M12 9V11M12 15H12.01M5.07183 19H18.9282C20.4678 19 21.4301 17.3333 20.6603 16L13.7321 4C12.9623 2.66667 11.0378 2.66667 10.268 4L3.33978 16C2.56998 17.3333 3.53223 19 5.07183 19Z" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
|
</svg>
|
|
<p class="ml-3 font-medium text-red-800">
|
|
Your subscription is paused due to failed payments. Please provide valid payment details to keep using Plausible.
|
|
</p>
|
|
</div>
|
|
<div class="flex-shrink-0 order-3 w-full mt-2 sm:order-2 sm:mt-0 sm:w-auto">
|
|
<div class="rounded-md shadow-sm">
|
|
<%= link("Update billing info", to: @conn.assigns[:current_user].subscription.update_url, class: "flex items-center justify-center px-4 py-2 border border-transparent text-sm leading-5 font-medium rounded-md text-gray-600 dark:text-gray-400 bg-white dark:bg-gray-800 hover:text-gray-500 dark:hover:text-gray-200 focus:outline-none focus:ring transition ease-in-out duration-150") %>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<% end %>
|