fix: Updates for home page

This commit is contained in:
Robert Prehn 2021-03-25 16:04:31 -05:00
parent 263ffadd8c
commit 873af60df5
6 changed files with 62 additions and 24 deletions

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 5.3 KiB

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 8.2 KiB

View file

@ -23,16 +23,6 @@
<%= link "Sign Out", to: Routes.pow_session_path(@conn, :delete), method: :delete, class: "inline-block text-white no-underline hover:text-white hover:text-underline py-2 px-4" %> <%= link "Sign Out", to: Routes.pow_session_path(@conn, :delete), method: :delete, class: "inline-block text-white no-underline hover:text-white hover:text-underline py-2 px-4" %>
</li> </li>
<% else %> <% else %>
<li class="mr-3">
<%= link to: Routes.pow_session_path(@conn, :new), class: "inline-block text-white no-underline hover:text-white hover:text-underline py-2 px-4" do %>
Log In
<% end %>
</li>
<li class="mr-3">
<%= link to: Routes.pow_registration_path(@conn, :new), class: "inline-block text-white no-underline hover:text-white hover:text-underline py-2 px-4" do %>
Sign Up
<% end %>
</li>
<% end %> <% end %>
</ul> </ul>
</div> </div>

View file

@ -58,6 +58,13 @@ defmodule Content.PostsController do
conn |> index_posts(%{"id" => "blog", "page" => page_string}) conn |> index_posts(%{"id" => "blog", "page" => page_string})
end end
def show(conn, %{"id" => id, "page" => page_string}) when is_list(id) do
show(conn, %{
"id" => Enum.join(id, "/"),
"page" => page_string
})
end
def show(conn, %{"id" => id, "page" => page_string}) do def show(conn, %{"id" => id, "page" => page_string}) do
post = Posts.get_post(id) post = Posts.get_post(id)

View file

@ -32,7 +32,7 @@ defmodule Content.Routes do
post "/wp-login.php", PostPasswordController, :create post "/wp-login.php", PostPasswordController, :create
get "/", PostsController, :index get "/", PostsController, :index
resources "/sitemap", SitemapController, only: [:index] resources "/sitemap", SitemapController, only: [:index]
get "/:id", PostsController, :show get "/*id", PostsController, :show
get "/:id/:page", PostsController, :show, as: :paged_post get "/:id/:page", PostsController, :show, as: :paged_post
end end
end end

View file

@ -9,13 +9,19 @@
</div> </div>
<div class="relative mx-auto"> <div class="relative mx-auto">
<div class="items-center flex flex-wrap"> <div class="items-center flex flex-wrap">
<div class="w-full lg:w-8/12 px-4 ml-auto mr-auto text-center"> <div class="w-full lg:w-6/12 px-4 ml-auto mr-auto text-center">
<div> <div>
<h1 class="text-white font-semibold text-4xl"> <h1 class="text-white font-semibold text-4xl">
The Stuff of Legend. A Batteries-included Phoenix & Elixir Application Template.
</h1> </h1>
<p class="mt-6 text-lg text-gray-100"> <p class="mt-6 text-lg text-gray-100">
Legendary makes it easy to quickly build Phoenix applications with all the bells and whistles. Legendary makes it easy to quickly build
<a href="" target="_blank" rel="noopener">PETAL-stack</a> Phoenix / Elixir
applications with all the bells and whistles.
</p>
<p class="mt-6 text-lg text-gray-100 font-bold">
Don't re-invent the
wheel&mdash; build something Legendary.
</p> </p>
</div> </div>
</div> </div>
@ -41,8 +47,12 @@
</div> </div>
<h6 class="text-xl font-semibold">Batteries Included</h6> <h6 class="text-xl font-semibold">Batteries Included</h6>
<p class="mt-2 mb-6 text-gray-600"> <p class="mt-2 mb-6 text-gray-600">
We include authentication, content management, administration, Tailwind styles, We include authentication, content management, administration,
and fluid email templates so that you can build your app as quickly as possible. fluid email templates,
<a href="https://tailwindcss.com/" target="_blank" rel="noopener">Tailwind styles</a>,
<a href="https://github.com/alpinejs/alpine" target="_blank" rel="noopener">AlpineJS</a>,
and <a href="https://www.phoenixframework.org/blog/build-a-real-time-twitter-clone-in-15-minutes-with-live-view-and-phoenix-1-5" target="_blank" rel="noopener">LiveView</a>
so that you can build your app as quickly and easily as possible.
</p> </p>
</div> </div>
</div> </div>
@ -59,7 +69,9 @@
</div> </div>
<h6 class="text-xl font-semibold">Hyper-scalable</h6> <h6 class="text-xl font-semibold">Hyper-scalable</h6>
<p class="mt-2 mb-6 text-gray-600"> <p class="mt-2 mb-6 text-gray-600">
Legendary is built on top of Phoenix and Elixir, so it can handle millions of connections without a problem. Legendary is built on Phoenix and Elixir, by people with years
of experience running Phoenix and Elixir in production. That means it can
scale to handle any volume you throw at it.
</p> </p>
</div> </div>
</div> </div>
@ -72,12 +84,13 @@
<div <div
class="text-white p-3 text-center inline-flex items-center justify-center w-12 h-12 mb-5 shadow-lg rounded-full bg-green-400" class="text-white p-3 text-center inline-flex items-center justify-center w-12 h-12 mb-5 shadow-lg rounded-full bg-green-400"
> >
<i class="fas fa-toolbox"></i> <i class="far fa-smile"></i>
</div> </div>
<h6 class="text-xl font-semibold">Flexible Toolbox</h6> <h6 class="text-xl font-semibold">Built for Developer Happiness</h6>
<p class="mt-2 mb-6 text-gray-600"> <p class="mt-2 mb-6 text-gray-600">
We used our years of experience building Phoenix applications at scale to design Legendary with everything you need. We built Legendary so that you can focus on building cool things
But we stay out of your way while you create your application. with Phoenix. We don't think you should have to write yet another
auth framework or admin interface to do that.
</p> </p>
</div> </div>
</div> </div>
@ -85,7 +98,7 @@
</div> </div>
<div class="flex flex-wrap items-center mt-32"> <div class="flex flex-wrap items-center mt-32">
<h2 class="w-full text-3xl text-center"> <h2 class="w-full text-3xl text-center">
Features Out of the Box Features
</h2> </h2>
<div class="w-full border-gray-400 border-t-2 border-b-2 py-12 px-4 mt-12 flex"> <div class="w-full border-gray-400 border-t-2 border-b-2 py-12 px-4 mt-12 flex">
<div class="lg:w-1/2 mr-12"> <div class="lg:w-1/2 mr-12">
@ -114,7 +127,7 @@
<div class="lg:w-1/2 mr-12"> <div class="lg:w-1/2 mr-12">
<h1 class="text-2xl">Admin Dashboard</h1> <h1 class="text-2xl">Admin Dashboard</h1>
<p class="text-xl mt-6"> <p class="text-xl mt-6">
There are plenty of tasks that don't require custom code. Legendary integrates the Kaffy admin dashboard There are plenty of tasks that don't require custom code. Legendary integrates the Kaffy admin dashboard
so that you can focus on what is unique to your application instead of churning out CRUD or editing database so that you can focus on what is unique to your application instead of churning out CRUD or editing database
rows by hand. rows by hand.
</p> </p>
@ -135,7 +148,7 @@
</p> </p>
</div> </div>
</div> </div>
<div class="w-full border-gray-400 py-12 px-4 pb-24 flex"> <div class="w-full border-gray-400 border-b-2 py-12 px-4 pb-24 flex">
<div class="lg:w-1/2"> <div class="lg:w-1/2">
<h1 class="text-2xl">Battle-tested Fluid Email Templates</h1> <h1 class="text-2xl">Battle-tested Fluid Email Templates</h1>
<p class="text-xl mt-6"> <p class="text-xl mt-6">
@ -148,6 +161,32 @@
<img src="/images/email.svg" /> <img src="/images/email.svg" />
</div> </div>
</div> </div>
<div class="w-full border-gray-400 border-b-2 py-12 px-4 flex">
<div class="lg:w-1/2">
<img src="/images/infra.svg" />
</div>
<div class="lg:w-1/2 ml-12">
<h1 class="text-2xl">Full DevOps Stack</h1>
<p class="text-xl mt-6">
Legendary includes a full set of CI / CD scripts so you can immediately
test and deploy your app as a semantically-versioned Docker
container. We also provide all the configuration that you need to
deploy your app to Kubernetes.
</p>
</div>
</div>
<div class="w-full border-gray-400 py-12 px-4 pb-24 flex">
<div class="lg:w-1/2">
<h1 class="text-2xl">And More.</h1>
<p class="text-xl mt-6">
A lot more. Like Background jobs, localization / internationalization,
great out-of-the-box forms, list views, and detail pages.
</p>
</div>
<div class="lg:w-1/2">
<img src="/images/power.svg" />
</div>
</div>
</div> </div>
</div> </div>
</section> </section>