From 2d83df8b32bff7f0028923bb5b64dc0b55f20d03 Mon Sep 17 00:00:00 2001 From: Jordan Bracco Date: Tue, 20 Dec 2022 00:21:54 +0000 Subject: Nola rename: The Big Move, Refs T77 --- lib/nola_web/templates/alcoolog/auth.html.eex | 43 ++++++ lib/nola_web/templates/alcoolog/index.html.eex | 205 +++++++++++++++++++++++++ lib/nola_web/templates/alcoolog/user.html.eex | 170 ++++++++++++++++++++ lib/nola_web/templates/irc/index.html.eex | 44 ++++++ lib/nola_web/templates/irc/txt.html.eex | 27 ++++ lib/nola_web/templates/irc/txts.html.eex | 49 ++++++ lib/nola_web/templates/layout/app.html.eex | 126 +++++++++++++++ lib/nola_web/templates/layout/root.html.leex | 18 +++ lib/nola_web/templates/network/index.html.eex | 1 + lib/nola_web/templates/open_id/error.html.eex | 3 + lib/nola_web/templates/page/api.html.eex | 35 +++++ lib/nola_web/templates/page/index.html.eex | 1 + lib/nola_web/templates/page/irc.html.eex | 19 +++ lib/nola_web/templates/page/user.html.eex | 43 ++++++ lib/nola_web/templates/page/widget.html.eex | 20 +++ 15 files changed, 804 insertions(+) create mode 100644 lib/nola_web/templates/alcoolog/auth.html.eex create mode 100644 lib/nola_web/templates/alcoolog/index.html.eex create mode 100644 lib/nola_web/templates/alcoolog/user.html.eex create mode 100644 lib/nola_web/templates/irc/index.html.eex create mode 100644 lib/nola_web/templates/irc/txt.html.eex create mode 100644 lib/nola_web/templates/irc/txts.html.eex create mode 100644 lib/nola_web/templates/layout/app.html.eex create mode 100644 lib/nola_web/templates/layout/root.html.leex create mode 100644 lib/nola_web/templates/network/index.html.eex create mode 100644 lib/nola_web/templates/open_id/error.html.eex create mode 100644 lib/nola_web/templates/page/api.html.eex create mode 100644 lib/nola_web/templates/page/index.html.eex create mode 100644 lib/nola_web/templates/page/irc.html.eex create mode 100644 lib/nola_web/templates/page/user.html.eex create mode 100644 lib/nola_web/templates/page/widget.html.eex (limited to 'lib/nola_web/templates') diff --git a/lib/nola_web/templates/alcoolog/auth.html.eex b/lib/nola_web/templates/alcoolog/auth.html.eex new file mode 100644 index 0000000..6e5cedc --- /dev/null +++ b/lib/nola_web/templates/alcoolog/auth.html.eex @@ -0,0 +1,43 @@ +
+

authentication

+
+ <%= link("connect using random.sh", to: "/login/oidc", class: "inline-block font-medium underline") %> +
+
+ +
+

+ <%= if @bot, do: "Send this to #{@bot} on #{@network}:", else: "Find your bot nickname and send:" %>

+ /msg <%= @bot || "the-bot-nickname" %> web +

+ ... then come back to this address. +

+
+ + diff --git a/lib/nola_web/templates/alcoolog/index.html.eex b/lib/nola_web/templates/alcoolog/index.html.eex new file mode 100644 index 0000000..5a5423a --- /dev/null +++ b/lib/nola_web/templates/alcoolog/index.html.eex @@ -0,0 +1,205 @@ + + +<%= if @stats == [] do %> +
+
+
+ + + +
+
+

+ CATASTROPHE! Personne n'a bu!!!! +

+
+
+
+<% end %> + + + +<%= if @stats == %{} do %> +
+
+
+ + + +
+
+

+ ENCORE PIRE! Aucune boisson enregistrée! +

+
+
+
+<% else %> + + + +

Classement 15 jours

+ + + +

Historique

+
+
+
+ + + + + + + + + + + <%= for {{{{account, date}, points, _active, cl, deg, nom, comment, _meta}, nick}, index} <- Enum.with_index(@drinks) do %> + <% class = if(Integer.is_even(index), do: "bg-gray-50", else: "bg-white") %> + <% date = DateTime.from_unix!(date, :millisecond) %> + + + + + + + <% end %> + +
+ date + + nick + +   + +   +
+ <%= NolaWeb.LayoutView.format_time(date, false) %> + + <%= link nick, to: alcoolog_path(@conn, :nick, @network, nick) %> + <%= cl %>cl <%= deg %>°<%= comment||"" %>
+
+
+
+<% end %> + +<%= if @conn.assigns.account && (@network || @channel) do %> + <%= link("alcoolog global", to: alcoolog_path(@conn, :index)) %> +<% end %> + + + + + + + + diff --git a/lib/nola_web/templates/alcoolog/user.html.eex b/lib/nola_web/templates/alcoolog/user.html.eex new file mode 100644 index 0000000..d7f716b --- /dev/null +++ b/lib/nola_web/templates/alcoolog/user.html.eex @@ -0,0 +1,170 @@ +<%= if @stats.active > 0 do %> +

+ <% rising_class = if @stats.rising, do: "teal", else: "red" %> + + <%= @stats.trend_symbol %> <%= Float.round(@stats.active, 4) %> g/l + + + <%= @stats.last_cl %>cl @ <%= @stats.last_deg %>° + + <%= if @stats.last_descr && @stats.last_descr != "" do %> + <%= @stats.last_descr %> + <% end %> + + + <%= NolaWeb.LayoutView.format_time(@stats.last_at) %> + +

+ +

+ a commencé il y a <%= @stats.since_s %> + — + sobre dans <%= @stats.sober_in_s %> +

+<% else %> +

+ est sobre! + +

+ dernier verre + <%= @stats.last_cl %>cl @ <%= @stats.last_deg %>° + + <%= if @stats.last_descr && @stats.last_descr != "" do %> + <%= @stats.last_descr %> + <% end %> + + + <%= NolaWeb.LayoutView.format_time(@stats.last_at) %> +

+<% end %> + + + + + +

Historique

+
+
+
+ + + + + + + + + + <%= for {%{at: date, cl: cl, deg: deg, description: comment}, index} <- Enum.with_index(@history) do %> + <% class = if(Integer.is_even(index), do: "bg-gray-50", else: "bg-white") %> + + + + + + <% end %> + +
+ date + +   + +   +
+ <%= NolaWeb.LayoutView.format_time(date, false) %> + <%= cl %>cl <%= deg %>°<%= comment||"" %>
+
+
+
+ +
+ + + + + + + + diff --git a/lib/nola_web/templates/irc/index.html.eex b/lib/nola_web/templates/irc/index.html.eex new file mode 100644 index 0000000..182624d --- /dev/null +++ b/lib/nola_web/templates/irc/index.html.eex @@ -0,0 +1,44 @@ + + +<%= if @members != [] do %> + +<% end %> + +
+ <%= for {identifier, help} <- @commands do %> + <%= if help do %> +
+
<%= NolaWeb.LayoutView.liquid_markdown(@conn, help) %>
+
+ <% end %> + <% end %> +
+ +


+ +

+ + Légende:
+ entre < >: argument obligatoire,
+ entre [ ]: argument optionel; [1 | ]: argument optionel avec valeur par défaut. +
+

+ +


+ +

+ + running beautte version <%= Nola.version() %> — git + +

diff --git a/lib/nola_web/templates/irc/txt.html.eex b/lib/nola_web/templates/irc/txt.html.eex new file mode 100644 index 0000000..fd4ea00 --- /dev/null +++ b/lib/nola_web/templates/irc/txt.html.eex @@ -0,0 +1,27 @@ + + +
    + <%= for {txt, id} <- Enum.with_index(@data) do %> +
  1. + + <%= txt %> + # +
  2. + <% end %> +
+ +

+ télécharger au format texte +

diff --git a/lib/nola_web/templates/irc/txts.html.eex b/lib/nola_web/templates/irc/txts.html.eex new file mode 100644 index 0000000..aff0c5d --- /dev/null +++ b/lib/nola_web/templates/irc/txts.html.eex @@ -0,0 +1,49 @@ +
+

+ <%= @lines %> lignes dans <%= @files %> fichiers + Aide + Fichiers système +

+ +
+ +
<%= NolaWeb.LayoutView.liquid_markdown(@conn, @doc) %>
+ +
+

+ Fichiers système +

+ + + +
diff --git a/lib/nola_web/templates/layout/app.html.eex b/lib/nola_web/templates/layout/app.html.eex new file mode 100644 index 0000000..c774369 --- /dev/null +++ b/lib/nola_web/templates/layout/app.html.eex @@ -0,0 +1,126 @@ +
+
+ +
+
+

+ <%= if n = @conn.assigns[:network] do %><%= n %> › <% end %> + <%= if c = @conn.assigns[:chan] do %><%= c %> › <% end %> + <%= for({name, href} <- Enum.uniq(@conn.assigns[:breadcrumbs]||[]), do: [link(name, to: href), raw(" › ")]) %> + <%= @conn.assigns[:title] %> +

+
+
+
+ +
+
+ +
+ <%= @inner_content %> +
+ +
+
+
diff --git a/lib/nola_web/templates/layout/root.html.leex b/lib/nola_web/templates/layout/root.html.leex new file mode 100644 index 0000000..6a48506 --- /dev/null +++ b/lib/nola_web/templates/layout/root.html.leex @@ -0,0 +1,18 @@ + + + + <%= page_title(@conn) %> + + + + + + <%= Map.get(assigns, :title, "") %> + "> + <%= csrf_meta_tag() %> + + + + <%= @inner_content %> + + diff --git a/lib/nola_web/templates/network/index.html.eex b/lib/nola_web/templates/network/index.html.eex new file mode 100644 index 0000000..fc024dd --- /dev/null +++ b/lib/nola_web/templates/network/index.html.eex @@ -0,0 +1 @@ +pouet diff --git a/lib/nola_web/templates/open_id/error.html.eex b/lib/nola_web/templates/open_id/error.html.eex new file mode 100644 index 0000000..d1b35b9 --- /dev/null +++ b/lib/nola_web/templates/open_id/error.html.eex @@ -0,0 +1,3 @@ +

OpenID authentication error

+ +

<%= @error %>

diff --git a/lib/nola_web/templates/page/api.html.eex b/lib/nola_web/templates/page/api.html.eex new file mode 100644 index 0000000..03dfa6b --- /dev/null +++ b/lib/nola_web/templates/page/api.html.eex @@ -0,0 +1,35 @@ +

sys.115ans.net/api

+ +

Icecast Status

+ +

GET /api/icecast.json

+ +

+ Content-Type: application/json +

+ +

+{
+  "np": String,
+  "genre": null | String,
+  "live": false | true
+}
+
+ +

GET /api/icecast.sse

+

+ Content-Type: text/event-stream +

+ +

+ Stream of: +

+ + +

+ On client connection, the server sends the latest icecast status known. +

+ diff --git a/lib/nola_web/templates/page/index.html.eex b/lib/nola_web/templates/page/index.html.eex new file mode 100644 index 0000000..1b8519a --- /dev/null +++ b/lib/nola_web/templates/page/index.html.eex @@ -0,0 +1 @@ +

vOv

diff --git a/lib/nola_web/templates/page/irc.html.eex b/lib/nola_web/templates/page/irc.html.eex new file mode 100644 index 0000000..f6598ee --- /dev/null +++ b/lib/nola_web/templates/page/irc.html.eex @@ -0,0 +1,19 @@ +

bot `115ans

+ +

Si vous cherchez l'IRC c'est par là.

+ + + +
+ <%= for help <- @bot_helps do %> +
<%= help |> Earmark.as_html! |> raw() %>
+ <% end %> +
+ diff --git a/lib/nola_web/templates/page/user.html.eex b/lib/nola_web/templates/page/user.html.eex new file mode 100644 index 0000000..de9f718 --- /dev/null +++ b/lib/nola_web/templates/page/user.html.eex @@ -0,0 +1,43 @@ +
+ + +

channels

+ + +

connections

+ + +

account

+ + +irc auths: + +
diff --git a/lib/nola_web/templates/page/widget.html.eex b/lib/nola_web/templates/page/widget.html.eex new file mode 100644 index 0000000..65853b3 --- /dev/null +++ b/lib/nola_web/templates/page/widget.html.eex @@ -0,0 +1,20 @@ + + + + + + +"> + + + + +
"> +
+
+
<%= @icecast.genre %>
+
<%= @icecast.np %>
+
+
+ + -- cgit v1.2.3