From 76749e8f64ce3caf7e0e5c17dfee373dcf4dfe6e Mon Sep 17 00:00:00 2001 From: Alex Auvolat Date: Fri, 12 Oct 2018 16:47:54 +0200 Subject: tweaks --- shardweb/assets/brunch-config.js | 17 +++++++++-------- shardweb/assets/package-lock.json | 5 +++++ shardweb/assets/package.json | 6 +++--- shardweb/lib/router.ex | 4 ++-- shardweb/lib/templates/chat/chat.html.eex | 2 +- shardweb/lib/templates/layout/app.html.eex | 7 ++----- shardweb/lib/templates/page/shard_list.html.eex | 8 ++++---- 7 files changed, 26 insertions(+), 23 deletions(-) diff --git a/shardweb/assets/brunch-config.js b/shardweb/assets/brunch-config.js index 9808ab0..28e4593 100644 --- a/shardweb/assets/brunch-config.js +++ b/shardweb/assets/brunch-config.js @@ -48,14 +48,15 @@ exports.config = { // Do not use ES6 compiler in vendor code ignore: [/vendor/] }, - copycat: { - "fonts": ["node_modules/startbootstrap-sb-admin/fonts"], - "css": ["node_modules/startbootstrap-sb-admin/css"], - "js": ["node_modules/startbootstrap-sb-admin/js"], - "font-awesome": ["node_modules/startbootstrap-sb-admin/font-awesome"], - verbose: true, - onlyChanged: true - } + copycat: { + "fonts": ["node_modules/startbootstrap-sb-admin/fonts", + "node_modules/font-awesome/fonts"], + "css": ["node_modules/startbootstrap-sb-admin/css", + "node_modules/font-awesome/css"], + "js": ["node_modules/startbootstrap-sb-admin/js"], + verbose: true, + onlyChanged: true + } }, modules: { diff --git a/shardweb/assets/package-lock.json b/shardweb/assets/package-lock.json index f8e5231..3e06420 100644 --- a/shardweb/assets/package-lock.json +++ b/shardweb/assets/package-lock.json @@ -2803,6 +2803,11 @@ "resolve-dir": "^0.1.0" } }, + "font-awesome": { + "version": "4.7.0", + "resolved": "https://registry.npmjs.org/font-awesome/-/font-awesome-4.7.0.tgz", + "integrity": "sha1-j6jPBBGhoxr9B7BtKQK7n8gVoTM=" + }, "for-in": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/for-in/-/for-in-1.0.2.tgz", diff --git a/shardweb/assets/package.json b/shardweb/assets/package.json index 797f7f7..5fedb68 100644 --- a/shardweb/assets/package.json +++ b/shardweb/assets/package.json @@ -6,16 +6,16 @@ "watch": "brunch watch --stdin" }, "dependencies": { - "copycat-brunch": "^1.1.0", + "font-awesome": "^4.7.0", "phoenix": "file:../deps/phoenix", "phoenix_html": "file:../deps/phoenix_html", "startbootstrap-sb-admin": "3.3.7" }, "devDependencies": { + "copycat-brunch": "^1.1.0", "babel-brunch": "6.1.1", "brunch": "^2.10.17", "clean-css-brunch": "2.10.0", - "uglify-js-brunch": "2.10.0", - "copycat-brunch": "1.1.0" + "uglify-js-brunch": "2.10.0" } } diff --git a/shardweb/lib/router.ex b/shardweb/lib/router.ex index 2c69b8c..981f946 100644 --- a/shardweb/lib/router.ex +++ b/shardweb/lib/router.ex @@ -18,9 +18,9 @@ defmodule ShardWeb.Router do scope "/", ShardWeb do pipe_through :browser # Use the default browser stack - get "/", PageController, :peer_list + get "/", PageController, :shard_list + get "/peers", PageController, :peer_list post "/peer/add", PageController, :add_peer - get "/dashboard", PageController, :shard_list get "/people", IdentityController, :list get "/people/:pk", IdentityController, :view diff --git a/shardweb/lib/templates/chat/chat.html.eex b/shardweb/lib/templates/chat/chat.html.eex index 45609d8..28cc9e6 100644 --- a/shardweb/lib/templates/chat/chat.html.eex +++ b/shardweb/lib/templates/chat/chat.html.eex @@ -18,7 +18,7 @@ Chat rooms
  • - #<%= @chan %> + <%= @chan %>
  • <% else %>
  • diff --git a/shardweb/lib/templates/layout/app.html.eex b/shardweb/lib/templates/layout/app.html.eex index 067ad57..44ba35d 100644 --- a/shardweb/lib/templates/layout/app.html.eex +++ b/shardweb/lib/templates/layout/app.html.eex @@ -21,7 +21,7 @@ " rel="stylesheet"> - " rel="stylesheet" type="text/css"> + " rel="stylesheet" type="text/css"> @@ -47,7 +47,7 @@ - Shard + Shard diff --git a/shardweb/lib/templates/page/shard_list.html.eex b/shardweb/lib/templates/page/shard_list.html.eex index 485bfa1..012223a 100644 --- a/shardweb/lib/templates/page/shard_list.html.eex +++ b/shardweb/lib/templates/page/shard_list.html.eex @@ -35,15 +35,15 @@ <%= Shard.Keys.pk_display pk %> - <% %SApp.Chat.Manifest{channel: chan} -> %> + <% %SApp.Chat.Manifest{channel: chan} -> %> - #<%= chan %> + <%= chan %> - <% %SApp.Chat.PrivChat.Manifest{pk_list: pk_list} -> %> + <% %SApp.Chat.PrivChat.Manifest{pk_list: pk_list} -> %> "> - @<%= pk_list |> Enum.filter(&(&1!=@pk)) |> Enum.map(&SApp.Identity.get_nick/1) |> Enum.join(", ") %> + <%= pk_list |> Enum.filter(&(&1!=@pk)) |> Enum.map(&SApp.Identity.get_nick/1) |> Enum.join(", ") %> <% x -> %> <%= inspect x %> -- cgit v1.2.3