Fix table styling
This commit is contained in:
parent
f91730bcd6
commit
3b71f6b00f
@ -52,4 +52,8 @@ body {
|
||||
.button.google {
|
||||
background: rgb(225, 98, 89);
|
||||
color: white;
|
||||
}
|
||||
|
||||
.table-wrapper{
|
||||
box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
|
||||
}
|
@ -1,32 +1,32 @@
|
||||
<h1><%= @form.title %></h1>
|
||||
<p>
|
||||
<%= submission_url(@form) %>
|
||||
</p>
|
||||
<p>
|
||||
<%= link_to 'Google spreadsheet', @form.spreadsheet_url %>
|
||||
</p>
|
||||
<div class="section">
|
||||
<div class="columns">
|
||||
<div class="column is-half is-offset-one-quarter">
|
||||
<div class="container">
|
||||
<div class="content is-paddingless">
|
||||
<h1><%= @form.title %></h1>
|
||||
<p>
|
||||
<%= submission_url(@form) %>
|
||||
</p>
|
||||
<p>
|
||||
<%= link_to 'Google spreadsheet', @form.spreadsheet_url %>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<table class="table is-fullwidth">
|
||||
<thead>
|
||||
<tr>
|
||||
<% @form.spreadsheet_headers.each do |value| %>
|
||||
<th><%= value %></th>
|
||||
<% end %>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<% @submissions.each do |submission| %>
|
||||
<tr>
|
||||
<% @form.spreadsheet_headers.each do |column| %>
|
||||
<div class="box table-wrapper">
|
||||
<table class="table is-fullwidth is-strip is-hoverable">
|
||||
<thead>
|
||||
<tr>
|
||||
<% @form.spreadsheet_headers.each do |value| %>
|
||||
<th><%= value %></th>
|
||||
<% end %>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<% @submissions.each do |submission| %>
|
||||
<tr>
|
||||
<% @form.spreadsheet_headers.each do |column| %>
|
||||
<td><%= submission.data[column] %></td>
|
||||
<% end %>
|
||||
</tr>
|
||||
<% end %>
|
||||
</tr>
|
||||
<% end %>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
Loading…
x
Reference in New Issue
Block a user