Compare commits
2 Commits
4ec41ad4b3
...
cc6586587f
| Author | SHA1 | Date | |
|---|---|---|---|
| cc6586587f | |||
| 315b108fa1 |
@@ -4,8 +4,22 @@
|
|||||||
<meta charset="utf-8" />
|
<meta charset="utf-8" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||||
<meta name="csrf-token" content={get_csrf_token()} />
|
<meta name="csrf-token" content={get_csrf_token()} />
|
||||||
<.live_title default="Mixer" suffix=" · Phoenix Framework">
|
<link rel="icon" href={~p"/favicon.ico"} sizes="any" />
|
||||||
{assigns[:page_title]}
|
<%
|
||||||
|
meta_title = (assigns[:page_title] || "Mixer")
|
||||||
|
meta_description = assigns[:page_description] || "Mixer is a social feed for all. Come join the conversation — built with Elixir."
|
||||||
|
%>
|
||||||
|
<meta name="description" content={meta_description} />
|
||||||
|
<meta name="robots" content={assigns[:robots] || "index, follow"} />
|
||||||
|
<meta property="og:site_name" content="Mixer" />
|
||||||
|
<meta property="og:title" content={meta_title} />
|
||||||
|
<meta property="og:description" content={meta_description} />
|
||||||
|
<meta property="og:type" content="website" />
|
||||||
|
<meta name="twitter:card" content="summary" />
|
||||||
|
<meta name="twitter:title" content={meta_title} />
|
||||||
|
<meta name="twitter:description" content={meta_description} />
|
||||||
|
<.live_title suffix=" · Mixer">
|
||||||
|
{assigns[:page_title] || "Mixer"}
|
||||||
</.live_title>
|
</.live_title>
|
||||||
<link phx-track-static rel="stylesheet" href={~p"/assets/css/app.css"} />
|
<link phx-track-static rel="stylesheet" href={~p"/assets/css/app.css"} />
|
||||||
<script defer phx-track-static type="module" src={~p"/assets/app.js"}>
|
<script defer phx-track-static type="module" src={~p"/assets/app.js"}>
|
||||||
|
|||||||
@@ -8,7 +8,38 @@ SPDX-License-Identifier: MIT
|
|||||||
<meta charset="utf-8" />
|
<meta charset="utf-8" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||||
<meta name="csrf-token" content={get_csrf_token()} />
|
<meta name="csrf-token" content={get_csrf_token()} />
|
||||||
<.live_title default="AshTypescript">Page</.live_title>
|
<link rel="icon" href={~p"/favicon.ico"} sizes="any" />
|
||||||
|
<%
|
||||||
|
{spa_title, spa_description} = case @page do
|
||||||
|
"feed" -> {"Mixer · Feed", "See the latest posts from everyone on Mixer."}
|
||||||
|
"tweet" -> {"Mixer · Post", "Read this post and join the conversation on Mixer."}
|
||||||
|
"following" -> {"Mixer · Following", "Posts from the people you follow on Mixer."}
|
||||||
|
"profile" -> {"Mixer · My Profile", "View and manage your Mixer profile."}
|
||||||
|
"users" -> {"Mixer · People", "Discover and follow people on Mixer."}
|
||||||
|
"user-detail" -> {"Mixer · Profile", "View this user's profile and posts on Mixer."}
|
||||||
|
_ -> {"Mixer", "A social feed built in Elixir."}
|
||||||
|
end
|
||||||
|
%>
|
||||||
|
<meta name="description" content={spa_description} />
|
||||||
|
<meta name="robots" content="index, follow" />
|
||||||
|
<meta property="og:site_name" content="Mixer" />
|
||||||
|
<meta property="og:title" content={spa_title} />
|
||||||
|
<meta property="og:description" content={spa_description} />
|
||||||
|
<meta property="og:type" content="website" />
|
||||||
|
<meta name="twitter:card" content="summary" />
|
||||||
|
<meta name="twitter:title" content={spa_title} />
|
||||||
|
<meta name="twitter:description" content={spa_description} />
|
||||||
|
<.live_title default="Mixer">
|
||||||
|
{case @page do
|
||||||
|
"feed" -> "Mixer · Feed"
|
||||||
|
"tweet" -> "Mixer · Post"
|
||||||
|
"following" -> "Mixer · Following"
|
||||||
|
"profile" -> "Mixer · My Profile"
|
||||||
|
"users" -> "Mixer · People"
|
||||||
|
"user-detail" -> "Mixer · Profile"
|
||||||
|
_ -> "Mixer"
|
||||||
|
end}
|
||||||
|
</.live_title>
|
||||||
<link phx-track-static rel="stylesheet" href={~p"/assets/css/app.css"} />
|
<link phx-track-static rel="stylesheet" href={~p"/assets/css/app.css"} />
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
|||||||
@@ -5,7 +5,9 @@ defmodule MixerWeb.PageController do
|
|||||||
if conn.assigns[:current_user] do
|
if conn.assigns[:current_user] do
|
||||||
redirect(conn, to: ~p"/feed")
|
redirect(conn, to: ~p"/feed")
|
||||||
else
|
else
|
||||||
render(conn, :home)
|
conn
|
||||||
|
|> assign(:page_title, "Mixer")
|
||||||
|
|> render(:home)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
BIN
priv/static/favicon-3133be378e68a7fd3d9cb261166b0629.ico
Normal file
BIN
priv/static/favicon-3133be378e68a7fd3d9cb261166b0629.ico
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 15 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 152 B |
Binary file not shown.
|
Before Width: | Height: | Size: 152 B After Width: | Height: | Size: 15 KiB |
Reference in New Issue
Block a user