diff options
author | Alex Auvolat <alex@adnab.me> | 2018-09-26 15:26:06 +0200 |
---|---|---|
committer | Alex Auvolat <alex@adnab.me> | 2018-09-26 15:26:06 +0200 |
commit | 7d0009d83c9b5c747d4adb535817924762429f30 (patch) | |
tree | 59b368cf189fc10976337e8caf4e6b623d69a04b /shardweb/lib/shard_web/templates/room | |
parent | f16973d3a492ae6d4890c40d77b0a93d3293bf3a (diff) | |
download | shard-7d0009d83c9b5c747d4adb535817924762429f30.tar.gz shard-7d0009d83c9b5c747d4adb535817924762429f30.zip |
Make it work, including Web interface
Diffstat (limited to 'shardweb/lib/shard_web/templates/room')
-rw-r--r-- | shardweb/lib/shard_web/templates/room/show.html.eex | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/shardweb/lib/shard_web/templates/room/show.html.eex b/shardweb/lib/shard_web/templates/room/show.html.eex index 5f28cc5..bc1641a 100644 --- a/shardweb/lib/shard_web/templates/room/show.html.eex +++ b/shardweb/lib/shard_web/templates/room/show.html.eex @@ -1,11 +1,8 @@ <ul class="nav nav-tabs"> - <%= for shard <- shard_list() do %> - <%= case shard do %> - <%= {_, %SApp.Chat.Manifest{channel: name}, _} -> %> - <li class="<%= if name == @room do "active" else "" end %>"> - <a href="<%= room_path(@conn, :show, name) %>">#<%= name %></a> - </li> - <% end %> + <%= for {_, %SApp.Chat.Manifest{channel: name}, _} <- shard_list() do %> + <li class="<%= if name == @room do "active" else "" end %>"> + <a href="<%= room_path(@conn, :show, name) %>">#<%= name %></a> + </li> <% end %> <li> <a href="#" onclick="if(new_room=prompt('Enter name of room to join, without preceding # sign:'))window.location.href='/room/'+new_room;">Join room</a> @@ -17,7 +14,7 @@ <div class="row"> <div class="col-xs-3"> - <input type="text" value="<%= @name %>" id="name" class="form-control" placeholder="Your Name"> + <strong><%= @name %></strong> </div> <div class="col-xs-9"> <input type="text" id="msg" class="form-control" placeholder="Your Message" autofocus> |