summaryrefslogtreecommitdiff
path: root/app/views/application/_timer.html.erb
diff options
context:
space:
mode:
Diffstat (limited to 'app/views/application/_timer.html.erb')
-rw-r--r--app/views/application/_timer.html.erb37
1 files changed, 36 insertions, 1 deletions
diff --git a/app/views/application/_timer.html.erb b/app/views/application/_timer.html.erb
index 908689b..ec10258 100644
--- a/app/views/application/_timer.html.erb
+++ b/app/views/application/_timer.html.erb
@@ -1,4 +1,5 @@
<% if current_char.activity %>
+ <h2 class="text-lg text-display text-center"><%= current_char.activity.name %></h2>
<div data-controller="timer"
data-timer-start-value="<%= current_char.activity_time_remaining.ceil %>"
data-timer-post-url-value="<%= finish_activity_url %>"
@@ -12,7 +13,41 @@
<div><%= most_recent_cs.xp_to_next_level %> XP to next level</div>
</div>
- <div class="text-center my-4">
+ <div class="text-center my-3">
<%= button_to "Stop", stop_activity_path %>
</div>
+
+ <div class="text-center text-xs my-2">
+ <% if current_char.activity.gid.include?("beastslay") %>
+ <%= current_char.wounds %> / <%= current_char.max_wounds %> wounds
+ <% end %>
+ <% current_char.active_states.each do |state| %>
+ <div>
+ <%= state.condition.name %>
+ </div>
+ <div>
+ (expires in <%= distance_of_time_in_words_to_now(state.expires_at) %>)
+ </div>
+ <% end %>
+ </div>
+
+<% else %>
+ <div class="text-center">
+ <% if current_char.resting? %>
+ <p>You're resting.</p>
+ <% else %>
+ <p>You're not doing anything.</p>
+ <% end %>
+
+ <div class="my-2">
+ <%= button_to current_char.resting? ? "Stop Resting" : "Start Resting", toggle_resting_path %>
+ </div>
+
+ <div class="text-xs">
+ You have <%= distance_of_time_in_words_to_now(current_char.rested_until) %> of rested time.
+ <% if current_char.resting? %>
+ This does not include time from your current rest. That time will be added when you stop resting.
+ <% end %>
+ </div>
+ </div>
<% end %>