From b6018ad11156d8b38a87dc682064495cd788608c Mon Sep 17 00:00:00 2001 From: Kelly Rauchenberger Date: Wed, 13 Mar 2019 15:00:38 -0400 Subject: Game started/finished now displayed in table --- app/assets/stylesheets/main/games.scss | 11 +++++++++++ app/views/games/index.html.haml | 11 ++++++++++- 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/app/assets/stylesheets/main/games.scss b/app/assets/stylesheets/main/games.scss index db495e2..98aca43 100644 --- a/app/assets/stylesheets/main/games.scss +++ b/app/assets/stylesheets/main/games.scss @@ -23,3 +23,14 @@ .game-progress p { margin: 0; } + +.game-title { + display: block; + margin-bottom: 0.25em; +} + +.game-started, .game-finished { + display: block; + font-size: 0.8em; + color: #777; +} diff --git a/app/views/games/index.html.haml b/app/views/games/index.html.haml index 64fbfd9..f7e7a44 100644 --- a/app/views/games/index.html.haml +++ b/app/views/games/index.html.haml @@ -8,7 +8,16 @@ %th Progress - @games.each do |game| %tr{ class: cycle("even", "odd") } - %td= game.title + %td + %span.game-title= game.title + - unless game.started_on.blank? + %span.game-started + Started on + %time= game.started_on + - unless game.finished_on.blank? + %span.game-finished + Finished on + %time= game.finished_on %td= game.status %td= game.score %td.game-progress= simple_format game.progress -- cgit 1.4.1