defmodule ToweropsWeb.MarketingLayouts do
@moduledoc """
Marketing layouts for public-facing pages.
"""
use ToweropsWeb, :html
alias ToweropsWeb.Components.CookieConsent
@doc """
Renders the marketing layout.
Use this for public-facing marketing pages.
## Examples
Marketing Content
"""
attr :flash, :map, required: true, doc: "the map of flash messages"
slot :inner_block, required: true
def marketing(assigns) do
assigns = Map.put_new(assigns, :requires_cookie_consent, false)
~H"""
<.link navigate={~p"/"} aria-label="Home">
<.link
navigate={~p"/users/log-in"}
class="inline-block rounded-lg px-2 py-1 text-sm text-slate-700 dark:text-slate-300 hover:bg-slate-100 dark:hover:bg-slate-800 hover:text-slate-900 dark:hover:text-white"
>
Sign in
<.link
navigate={~p"/users/register"}
class="group inline-flex items-center justify-center rounded-full py-2 px-4 text-sm font-semibold focus-visible:outline-2 focus-visible:outline-offset-2 bg-blue-600 text-white hover:text-slate-100 hover:bg-blue-500 active:bg-blue-800 active:text-blue-100 focus-visible:outline-blue-600"
>
Get started today
{render_slot(@inner_block)}
Product
<.link
href="/#features"
class="text-sm text-slate-600 dark:text-slate-400 hover:text-slate-900 dark:hover:text-white transition-colors"
>
Features
<.link
href="/#pricing"
class="text-sm text-slate-600 dark:text-slate-400 hover:text-slate-900 dark:hover:text-white transition-colors"
>
Pricing
Developers
<.link
navigate={~p"/docs/api"}
class="text-sm text-slate-600 dark:text-slate-400 hover:text-slate-900 dark:hover:text-white transition-colors"
>
API Documentation
<.link
navigate={~p"/docs/graphql"}
class="text-sm text-slate-600 dark:text-slate-400 hover:text-slate-900 dark:hover:text-white transition-colors"
>
GraphQL API
<.link
navigate={~p"/help"}
class="text-sm text-slate-600 dark:text-slate-400 hover:text-slate-900 dark:hover:text-white transition-colors"
>
Help & Docs
Copyright © {Date.utc_today().year} Towerops
<.link
navigate={~p"/privacy"}
class="hover:text-slate-700 dark:hover:text-slate-300 underline decoration-dotted underline-offset-2"
>
Privacy Policy
·
<.link
navigate={~p"/terms"}
class="hover:text-slate-700 dark:hover:text-slate-300 underline decoration-dotted underline-offset-2"
>
Terms of Service
"""
end
end