<% if !htmx {%> zettoIT ARS
<% } %>

zettoIT ARS

<% if let ViewerState::Answering((current_field, field, data)) = state { %>

<%= field.name%>

Total Participants: <%= data.iter().fold(0, |acc, e| acc +e) %> <% if (current_field+1) as usize >= quiz.fields.len() { %> <% } else { %> <% } %> <% } else if let ViewerState::Result((current_field, field, data)) = state { %>

<%= field.name%>

Total Participants: <%= data.iter().fold(0, |acc, e| acc +e) %>
The correct answer is: <%=field.answers[field.correct as usize]%> <% if (current_field+1) as usize >= quiz.fields.len() { %> <% } else { %> <% } %> <% } else if let ViewerState::NotStarted((player, qrcode, url)) = state { %>
<%- qrcode %>
<%= url %>
<% } else {%>
The Quiz finished. You can close this tab now.
<% } %> <% if !htmx { %>
<% } %>