about summary refs log tree commit diff stats
path: root/app
diff options
context:
space:
mode:
authorStar Rauchenberger <fefferburbia@gmail.com>2023-10-29 14:02:34 -0400
committerStar Rauchenberger <fefferburbia@gmail.com>2023-10-29 14:02:34 -0400
commitd672465c2be3dc54463a92a3f1c4aa23447bc5c8 (patch)
treeacbf66abf9c8b3b4f5387de6c2ca6e396a403ce6 /app
parenta8821b425351cdd8a5f69f5b60e389a1ae81cb72 (diff)
downloadwittle-d672465c2be3dc54463a92a3f1c4aa23447bc5c8.tar.gz
wittle-d672465c2be3dc54463a92a3f1c4aa23447bc5c8.tar.bz2
wittle-d672465c2be3dc54463a92a3f1c4aa23447bc5c8.zip
better display of completions
Diffstat (limited to 'app')
-rw-r--r--app/assets/stylesheets/wittle/general.css.scss2
-rw-r--r--app/views/wittle/puzzles/show.html.haml16
2 files changed, 12 insertions, 6 deletions
diff --git a/app/assets/stylesheets/wittle/general.css.scss b/app/assets/stylesheets/wittle/general.css.scss index 06a7a83..b2b432d 100644 --- a/app/assets/stylesheets/wittle/general.css.scss +++ b/app/assets/stylesheets/wittle/general.css.scss
@@ -83,7 +83,7 @@ input[type="range"]::-ms-thumb {
83 text-align: center; 83 text-align: center;
84 } 84 }
85 85
86 ol { 86 table {
87 width: max-content; 87 width: max-content;
88 margin: 0 auto; 88 margin: 0 auto;
89 } 89 }
diff --git a/app/views/wittle/puzzles/show.html.haml b/app/views/wittle/puzzles/show.html.haml index d5d8b00..75ae288 100644 --- a/app/views/wittle/puzzles/show.html.haml +++ b/app/views/wittle/puzzles/show.html.haml
@@ -14,12 +14,18 @@
14 #scores 14 #scores
15 #by-time 15 #by-time
16 %h2 Fastest Solves 16 %h2 Fastest Solves
17 %ol 17 %table
18 - @puzzle.scores.where("seconds_taken IS NOT NULL").order(seconds_taken: :asc).each do |score| 18 - @puzzle.scores.where("seconds_taken IS NOT NULL").order(seconds_taken: :asc).each do |score|
19 %li= score.name 19 %tr
20 %td #{(i + 1)}.
21 %td= score.name
22 %td
20 #by-when 23 #by-when
21 %h2 Completion Order 24 %h2 Completion Order
22 %ol 25 %table
23 - @puzzle.scores.order(created_at: :desc).each do |score| 26 - @puzzle.scores.order(created_at: :asc).each_with_index do |score, i|
24 %li= score.name 27 %tr
28 %td #{(i + 1)}.
29 %td= score.name
30 %td= score.created_at.getlocal().strftime("%-I:%M:%S%P")
25= render partial: "handle_puzzle" 31= render partial: "handle_puzzle"