Skip to content

Open source, privacy-first web analytics. Lightweight, cookie-free Google Analytics alternative. Self-hosted or cloud.

Wrap top-level flex items in block containers

Uku Taht12163cc333f0
diff --git a/lib/plausible_web/templates/auth/register_form.html.eex b/lib/plausible_web/templates/auth/register_form.html.eex
index 1c334cd85c..4105e54f89 100644
--- a/lib/plausible_web/templates/auth/register_form.html.eex
+++ b/lib/plausible_web/templates/auth/register_form.html.eex
@@ -3,46 +3,47 @@
<div class="text-xl font-medium">Set up privacy-friendly analytics with just a few clicks</div>
</div>
-<div class="w-full max-w-3xl mt-4 mx-auto flex">
- <%= form_for @changeset, "/register", [class: "w-full max-w-md mx-auto bg-white shadow-md rounded px-8 py-6 mb-4 mt-8", id: "register-form"], fn f -> %>
- <h2 class="text-xl font-black">Enter your details</h2>
- <div class="my-4">
- <%= label f, :name, "Full name", class: "block text-gray-700 text-sm font-bold mb-2" %>
- <%= text_input f, :name, class: "transition bg-gray-100 appearance-none border border-transparent rounded w-full p-2 text-gray-700 leading-normal appearance-none focus:outline-none focus:bg-white focus:border-gray-300", placeholder: "Jane Doe" %>
- <%= error_tag f, :name %>
- </div>
- <div class="my-4">
- <%= label f, :email, class: "block text-gray-700 text-sm font-bold mb-2" %>
- <p class="text-gray-600 text-xs mt-1 mb-2">No spam, guaranteed.</p>
- <%= email_input f, :email, class: "transition bg-gray-100 appearance-none border border-transparent rounded w-full p-2 text-gray-700 leading-normal appearance-none focus:outline-none focus:bg-white focus:border-gray-300", placeholder: "[email protected]" %>
- <%= error_tag f, :email %>
- </div>
+<div>
+ <div class="w-full max-w-3xl mt-4 mx-auto flex">
+ <%= form_for @changeset, "/register", [class: "w-full max-w-md mx-auto bg-white shadow-md rounded px-8 py-6 mb-4 mt-8", id: "register-form"], fn f -> %>
+ <h2 class="text-xl font-black">Enter your details</h2>
+ <div class="my-4">
+ <%= label f, :name, "Full name", class: "block text-gray-700 text-sm font-bold mb-2" %>
+ <%= text_input f, :name, class: "transition bg-gray-100 appearance-none border border-transparent rounded w-full p-2 text-gray-700 leading-normal appearance-none focus:outline-none focus:bg-white focus:border-gray-300", placeholder: "Jane Doe" %>
+ <%= error_tag f, :name %>
+ </div>
+ <div class="my-4">
+ <%= label f, :email, class: "block text-gray-700 text-sm font-bold mb-2" %>
+ <p class="text-gray-600 text-xs mt-1 mb-2">No spam, guaranteed.</p>
+ <%= email_input f, :email, class: "transition bg-gray-100 appearance-none border border-transparent rounded w-full p-2 text-gray-700 leading-normal appearance-none focus:outline-none focus:bg-white focus:border-gray-300", placeholder: "[email protected]" %>
+ <%= error_tag f, :email %>
+ </div>
- <%= submit "Start my free trial →", class: "button mt-4 w-full" %>
+ <%= submit "Start my free trial →", class: "button mt-4 w-full" %>
- <p class="text-center text-gray-600 text-xs mt-4">
- Already have an account? <%= link("Log in", to: "/login", class: "underline text-gray-800") %> instead.
- </p>
- <% end %>
- <div class="pt-12 pl-8 hidden md:block">
- <ul class="mt-2 leading-loose">
- <li>
- <svg class="feather text-indigo-600 mr-1"><use xlink:href="#feather-check-circle" /></svg>
- Quick and easy to set up
- </li>
- <li>
- <svg class="feather text-indigo-600 mr-1"><use xlink:href="#feather-check-circle" /></svg>
- No credit card required
- </li>
- <li>
- <svg class="feather text-indigo-600 mr-1"><use xlink:href="#feather-check-circle" /></svg>
- Unlimited use during the trial
- </li>
- <li>
- <svg class="feather text-indigo-600 mr-1"><use xlink:href="#feather-check-circle" /></svg>
- From just $6/mo after the trial
- </li>
- </ul>
+ <p class="text-center text-gray-600 text-xs mt-4">
+ Already have an account? <%= link("Log in", to: "/login", class: "underline text-gray-800") %> instead.
+ </p>
+ <% end %>
+ <div class="pt-12 pl-8 hidden md:block">
+ <ul class="mt-2 leading-loose">
+ <li>
+ <svg class="feather text-indigo-600 mr-1"><use xlink:href="#feather-check-circle" /></svg>
+ Quick and easy to set up
+ </li>
+ <li>
+ <svg class="feather text-indigo-600 mr-1"><use xlink:href="#feather-check-circle" /></svg>
+ No credit card required
+ </li>
+ <li>
+ <svg class="feather text-indigo-600 mr-1"><use xlink:href="#feather-check-circle" /></svg>
+ Unlimited use during the trial
+ </li>
+ <li>
+ <svg class="feather text-indigo-600 mr-1"><use xlink:href="#feather-check-circle" /></svg>
+ From just $6/mo after the trial
+ </li>
+ </ul>
+ </div>
</div>
-
</div>
diff --git a/lib/plausible_web/templates/billing/upgrade.html.eex b/lib/plausible_web/templates/billing/upgrade.html.eex
index 9d9a3d1176..5f8b40cf20 100644
--- a/lib/plausible_web/templates/billing/upgrade.html.eex
+++ b/lib/plausible_web/templates/billing/upgrade.html.eex
@@ -6,118 +6,120 @@
<h1 class="text-3xl font-black">Upgrade your free trial</h1>
</div>
-<div class="w-full max-w-4xl px-4 mt-4 mx-auto flex flex-col md:flex-row">
- <div x-data="{planSize: '10k', billingCycle: 'monthly'}" class="flex-1 bg-white shadow-md rounded px-8 py-4 mb-4 mt-8">
- <div class="w-full py-4">
- <span>You've used <b><%= PlausibleWeb.AuthView.delimit_integer(@usage) %></b> pageviews in the last 30 days</span>
- </div>
+<div>
+ <div class="w-full max-w-4xl px-4 mt-4 mx-auto flex flex-col md:flex-row">
+ <div x-data="{planSize: '10k', billingCycle: 'monthly'}" class="flex-1 bg-white shadow-md rounded px-8 py-4 mb-4 mt-8">
+ <div class="w-full py-4">
+ <span>You've used <b><%= PlausibleWeb.AuthView.delimit_integer(@usage) %></b> pageviews in the last 30 days</span>
+ </div>
- <div class="pt-2"></div>
+ <div class="pt-2"></div>
- <span class="relative z-0 inline-flex shadow-sm w-full">
- <button type="button" @click="billingCycle = 'monthly'" :class="{'bg-indigo-600 text-white border-indigo-600': billingCycle === 'monthly', 'bg-white text-gray-700 hover:text-gray-500 border-gray-300': billingCycle === 'yearly'}" class="relative w-full text-center px-4 py-2 rounded-l-md border text-sm leading-5 font-medium focus:outline-none focus:border-blue-300 focus:shadow-outline-blue transition ease-in-out duration-150">
- Monthly billing
- </button>
- <button type="button" @click="billingCycle = 'yearly'" :class="{'bg-indigo-600 text-white border-indigo-600': billingCycle === 'yearly', 'bg-white text-gray-700 hover:text-gray-500 border-gray-300': billingCycle === 'monthly'}" class="-ml-px relative w-full text-center px-4 py-2 rounded-r-md border text-sm leading-5 font-medium focus:outline-none focus:border-blue-300 focus:shadow-outline-blue transition ease-in-out duration-150">
- Yearly billing
- <span class="inline-flex items-center px-2 py-0.5 rounded text-xs font-medium leading-4 bg-yellow-100 text-yellow-800">
- -33%
- </span>
- </button>
- </span>
+ <span class="relative z-0 inline-flex shadow-sm w-full">
+ <button type="button" @click="billingCycle = 'monthly'" :class="{'bg-indigo-600 text-white border-indigo-600': billingCycle === 'monthly', 'bg-white text-gray-700 hover:text-gray-500 border-gray-300': billingCycle === 'yearly'}" class="relative w-full text-center px-4 py-2 rounded-l-md border text-sm leading-5 font-medium focus:outline-none focus:border-blue-300 focus:shadow-outline-blue transition ease-in-out duration-150">
+ Monthly billing
+ </button>
+ <button type="button" @click="billingCycle = 'yearly'" :class="{'bg-indigo-600 text-white border-indigo-600': billingCycle === 'yearly', 'bg-white text-gray-700 hover:text-gray-500 border-gray-300': billingCycle === 'monthly'}" class="-ml-px relative w-full text-center px-4 py-2 rounded-r-md border text-sm leading-5 font-medium focus:outline-none focus:border-blue-300 focus:shadow-outline-blue transition ease-in-out duration-150">
+ Yearly billing
+ <span class="inline-flex items-center px-2 py-0.5 rounded text-xs font-medium leading-4 bg-yellow-100 text-yellow-800">
+ -33%
+ </span>
+ </button>
+ </span>
- <div class="pt-6"></div>
+ <div class="pt-6"></div>
- <div class="flex flex-col">
- <div class="-my-2 py-2 overflow-x-auto sm:-mx-6 sm:px-6 lg:-mx-8 lg:px-8">
- <div class="align-middle inline-block min-w-full shadow overflow-hidden sm:rounded-lg border-b border-gray-200">
- <table class="min-w-full">
- <thead>
- <tr>
- <th class="px-6 py-3 border-b border-gray-200 bg-gray-100 text-left text-xs leading-4 font-medium text-gray-500 uppercase tracking-wider">
- Monthly pageviews
- </th>
- <th class="px-6 py-3 border-b border-gray-200 bg-gray-100 text-left text-xs leading-4 font-medium text-gray-500 uppercase tracking-wider">
- Price per month
- </th>
- </tr>
- </thead>
- <tbody class="bg-white">
- <tr @click="planSize = '10k'" :class="{'border-2 border-green-300': planSize === '10k', 'border-b border-gray-200 cursor-pointer': planSize !== '10k'}">
- <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '10k'}">10k</td>
- <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '10k'}">
- <span x-show="billingCycle === 'monthly'">$6</span>
- <span x-show="billingCycle === 'yearly'">$4</span>
- </td>
- </tr>
- <tr @click="planSize = '100k'" :class="{'border-2 border-green-300': planSize === '100k', 'border-b border-gray-200 cursor-pointer': planSize !== '100k'}">
- <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '100k'}">100k</td>
- <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '100k'}">
- <span x-show="billingCycle === 'monthly'">$12</span>
- <span x-show="billingCycle === 'yearly'">$8</span>
- </td>
- </tr>
- <tr @click="planSize = '200k'" :class="{'border-2 border-green-300': planSize === '200k', 'border-b border-gray-200 cursor-pointer': planSize !== '200k'}">
- <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '200k'}">200k</td>
- <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '200k'}">
- <span x-show="billingCycle === 'monthly'">$18</span>
- <span x-show="billingCycle === 'yearly'">$12</span>
- </td>
- </tr>
- <tr @click="planSize = '500k'" :class="{'border-2 border-green-300': planSize === '500k', 'border-b border-gray-200 cursor-pointer': planSize !== '500k'}">
- <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '500k'}">500k</td>
- <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '500k'}">
- <span x-show="billingCycle === 'monthly'">$27</span>
- <span x-show="billingCycle === 'yearly'">$18</span>
- </td>
- </tr>
- <tr @click="planSize = '1m'" :class="{'border-2 border-green-300': planSize === '1m', 'border-b border-gray-200 cursor-pointer': planSize !== '1m'}">
- <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '1m'}">1m</td>
- <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '1m'}">
- <span x-show="billingCycle === 'monthly'">$48</span>
- <span x-show="billingCycle === 'yearly'">$32</span>
- </td>
- </tr>
- <tr @click="planSize = '2m'" :class="{'border-2 border-green-300': planSize === '2m', 'border-b border-gray-200 cursor-pointer': planSize !== '2m'}">
- <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '2m'}">2m</td>
- <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '2m'}">
- <span x-show="billingCycle === 'monthly'">$69</span>
- <span x-show="billingCycle === 'yearly'">$46</span>
- </td>
- </tr>
- <tr @click="planSize = '5m'" :class="{'border-2 border-green-300': planSize === '5m', 'border-b border-gray-200 cursor-pointer': planSize !== '5m'}">
- <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '5m'}">5m</td>
- <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '5m'}">
- <span x-show="billingCycle === 'monthly'">$99</span>
- <span x-show="billingCycle === 'yearly'">$66</span>
- </td>
- </tr>
- </tbody>
- </table>
+ <div class="flex flex-col">
+ <div class="-my-2 py-2 overflow-x-auto sm:-mx-6 sm:px-6 lg:-mx-8 lg:px-8">
+ <div class="align-middle inline-block min-w-full shadow overflow-hidden sm:rounded-lg border-b border-gray-200">
+ <table class="min-w-full">
+ <thead>
+ <tr>
+ <th class="px-6 py-3 border-b border-gray-200 bg-gray-100 text-left text-xs leading-4 font-medium text-gray-500 uppercase tracking-wider">
+ Monthly pageviews
+ </th>
+ <th class="px-6 py-3 border-b border-gray-200 bg-gray-100 text-left text-xs leading-4 font-medium text-gray-500 uppercase tracking-wider">
+ Price per month
+ </th>
+ </tr>
+ </thead>
+ <tbody class="bg-white">
+ <tr @click="planSize = '10k'" :class="{'border-2 border-green-300': planSize === '10k', 'border-b border-gray-200 cursor-pointer': planSize !== '10k'}">
+ <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '10k'}">10k</td>
+ <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '10k'}">
+ <span x-show="billingCycle === 'monthly'">$6</span>
+ <span x-show="billingCycle === 'yearly'">$4</span>
+ </td>
+ </tr>
+ <tr @click="planSize = '100k'" :class="{'border-2 border-green-300': planSize === '100k', 'border-b border-gray-200 cursor-pointer': planSize !== '100k'}">
+ <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '100k'}">100k</td>
+ <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '100k'}">
+ <span x-show="billingCycle === 'monthly'">$12</span>
+ <span x-show="billingCycle === 'yearly'">$8</span>
+ </td>
+ </tr>
+ <tr @click="planSize = '200k'" :class="{'border-2 border-green-300': planSize === '200k', 'border-b border-gray-200 cursor-pointer': planSize !== '200k'}">
+ <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '200k'}">200k</td>
+ <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '200k'}">
+ <span x-show="billingCycle === 'monthly'">$18</span>
+ <span x-show="billingCycle === 'yearly'">$12</span>
+ </td>
+ </tr>
+ <tr @click="planSize = '500k'" :class="{'border-2 border-green-300': planSize === '500k', 'border-b border-gray-200 cursor-pointer': planSize !== '500k'}">
+ <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '500k'}">500k</td>
+ <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '500k'}">
+ <span x-show="billingCycle === 'monthly'">$27</span>
+ <span x-show="billingCycle === 'yearly'">$18</span>
+ </td>
+ </tr>
+ <tr @click="planSize = '1m'" :class="{'border-2 border-green-300': planSize === '1m', 'border-b border-gray-200 cursor-pointer': planSize !== '1m'}">
+ <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '1m'}">1m</td>
+ <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '1m'}">
+ <span x-show="billingCycle === 'monthly'">$48</span>
+ <span x-show="billingCycle === 'yearly'">$32</span>
+ </td>
+ </tr>
+ <tr @click="planSize = '2m'" :class="{'border-2 border-green-300': planSize === '2m', 'border-b border-gray-200 cursor-pointer': planSize !== '2m'}">
+ <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '2m'}">2m</td>
+ <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '2m'}">
+ <span x-show="billingCycle === 'monthly'">$69</span>
+ <span x-show="billingCycle === 'yearly'">$46</span>
+ </td>
+ </tr>
+ <tr @click="planSize = '5m'" :class="{'border-2 border-green-300': planSize === '5m', 'border-b border-gray-200 cursor-pointer': planSize !== '5m'}">
+ <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '5m'}">5m</td>
+ <td class="px-6 py-4 text-sm leading-5" :class="{'font-bold': planSize === '5m'}">
+ <span x-show="billingCycle === 'monthly'">$99</span>
+ <span x-show="billingCycle === 'yearly'">$66</span>
+ </td>
+ </tr>
+ </tbody>
+ </table>
+ </div>
</div>
</div>
- </div>
- <div class="text-right mt-6">
- <div class="mb-4 text-sm font-medium">Due today: <b x-text="window.plans[billingCycle][planSize].due_now">$6</b></div>
- <span class="inline-flex rounded-md shadow-sm">
- <button type="button" data-theme="none" :data-product="window.plans[billingCycle][planSize].product_id" data-email="<%= @conn.assigns[:current_user].email %>" data-disable-logout="true" data-passthrough="<%= @conn.assigns[:current_user].id %>" data-success="/billing/success" class="paddle_button inline-flex items-center px-4 py-2 border border-transparent text-sm leading-5 font-medium rounded-md text-white bg-indigo-600 hover:bg-indigo-500 focus:outline-none focus:border-indigo-700 focus:shadow-outline-indigo active:bg-indigo-700 transition ease-in-out duration-150">
- <svg fill="currentColor" viewBox="0 0 20 20" class="w-4 h-4 inline mr-2"><path fill-rule="evenodd" d="M5 9V7a5 5 0 0110 0v2a2 2 0 012 2v5a2 2 0 01-2 2H5a2 2 0 01-2-2v-5a2 2 0 012-2zm8-2v2H7V7a3 3 0 016 0z" clip-rule="evenodd"></path></svg>
- Pay securely via Paddle
- </button>
- </span>
+ <div class="text-right mt-6">
+ <div class="mb-4 text-sm font-medium">Due today: <b x-text="window.plans[billingCycle][planSize].due_now">$6</b></div>
+ <span class="inline-flex rounded-md shadow-sm">
+ <button type="button" data-theme="none" :data-product="window.plans[billingCycle][planSize].product_id" data-email="<%= @conn.assigns[:current_user].email %>" data-disable-logout="true" data-passthrough="<%= @conn.assigns[:current_user].id %>" data-success="/billing/success" class="paddle_button inline-flex items-center px-4 py-2 border border-transparent text-sm leading-5 font-medium rounded-md text-white bg-indigo-600 hover:bg-indigo-500 focus:outline-none focus:border-indigo-700 focus:shadow-outline-indigo active:bg-indigo-700 transition ease-in-out duration-150">
+ <svg fill="currentColor" viewBox="0 0 20 20" class="w-4 h-4 inline mr-2"><path fill-rule="evenodd" d="M5 9V7a5 5 0 0110 0v2a2 2 0 012 2v5a2 2 0 01-2 2H5a2 2 0 01-2-2v-5a2 2 0 012-2zm8-2v2H7V7a3 3 0 016 0z" clip-rule="evenodd"></path></svg>
+ Pay securely via Paddle
+ </button>
+ </span>
+ </div>
</div>
- </div>
- <div class="flex-1 pt-14 pl-8">
- <h3 class="text-lg leading-6 font-medium text-gray-900">
- What happens if I go over my page views limit?
- </h3>
- <div class="mt-2 text-base leading-6 text-gray-500">
- You will never be charged extra for an occasional traffic spike. There are no surprise fees and your card will never be charged unexpectedly.<br /><br />
- If your page views exceed your plan for two consecutive months, we will contact you to upgrade to a higher plan for the following month. You will have two weeks to make a decision. You can decide to continue with a higher plan or to cancel your account at that point.
- </div>
+ <div class="flex-1 pt-14 pl-8">
+ <h3 class="text-lg leading-6 font-medium text-gray-900">
+ What happens if I go over my page views limit?
+ </h3>
+ <div class="mt-2 text-base leading-6 text-gray-500">
+ You will never be charged extra for an occasional traffic spike. There are no surprise fees and your card will never be charged unexpectedly.<br /><br />
+ If your page views exceed your plan for two consecutive months, we will contact you to upgrade to a higher plan for the following month. You will have two weeks to make a decision. You can decide to continue with a higher plan or to cancel your account at that point.
+ </div>
+ </div>
</div>
</div>