Started work to move the CSS framework to Bootstrap 5
This commit is contained in:
@ -1,43 +1,36 @@
|
||||
<div class="grid-x grid-margin-x">
|
||||
<div class="cell small-12">
|
||||
<div class="row mb-4">
|
||||
<div class="col-12">
|
||||
<h1>Add new benchmark</h1>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="grid-x grid-margin-x">
|
||||
<div class="row">
|
||||
|
||||
<form class="cell small-12" action="/benchmark/add" method="post">
|
||||
<div class="grid-x grid-padding-x">
|
||||
<div class="cell medium-9">
|
||||
<label>
|
||||
Benchmark name
|
||||
<input type="text" name="benchmark_name" placeholder="Example benchmark">
|
||||
</label>
|
||||
<form class="col-12" action="/benchmark/add" method="post">
|
||||
<div class="row mb-3">
|
||||
<div class="col-9">
|
||||
<label for="benchmark_name">Benchmark name</label>
|
||||
<input id="benchmark_name" class="form-control" type="text" name="benchmark_name" placeholder="Example benchmark">
|
||||
</div>
|
||||
|
||||
<div class="cell medium-3">
|
||||
<label>
|
||||
Scoring type
|
||||
<select name="benchmark_scoring">
|
||||
<option value="fps">Frames per Second (fps)</option>
|
||||
<option value="ms">Frame Time (ms)</option>
|
||||
<option value="pts">Total Points</option>
|
||||
</select>
|
||||
</label>
|
||||
<div class="col-3">
|
||||
<label for="benchmark_scoring">Scoring type</label>
|
||||
<select id="benchmark_scoring" class="form-select" name="benchmark_scoring">
|
||||
<option value="fps">Frames per Second (fps)</option>
|
||||
<option value="ms">Frame Time (ms)</option>
|
||||
<option value="pts">Total Points</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="grid-x grid-padding-x">
|
||||
<div class="cell small-12">
|
||||
<textarea name="benchmark_description" class="cell small-12">Enter a description/notes here.</textarea>
|
||||
<div class="row mb-3">
|
||||
<div class="col-12">
|
||||
<label for="benchmark_description">Benchmark description</label>
|
||||
<textarea id="benchmark_description" class="form-control" name="benchmark_description">Enter a description/notes here.</textarea>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="grid-x grid-padding-x">
|
||||
<div class="cell small-12">
|
||||
<input type="submit" class="button" value="Submit">
|
||||
</div>
|
||||
</div>
|
||||
<input class="btn btn-primary" type="submit" value="Create Benchmark">
|
||||
</form>
|
||||
|
||||
</div>
|
||||
|
@ -1,43 +1,36 @@
|
||||
<div class="grid-x grid-margin-x">
|
||||
<div class="cell small-12">
|
||||
<div class="row mb-4">
|
||||
<div class="col-12">
|
||||
<h1>Editing: <%= benchmark.name %></h1>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="grid-x grid-margin-x">
|
||||
<div class="row">
|
||||
|
||||
<form class="cell small-12" action="/benchmark/<%= benchmark.id %>/edit" method="post">
|
||||
<div class="grid-x grid-padding-x">
|
||||
<div class="cell medium-9">
|
||||
<label>
|
||||
Benchmark name
|
||||
<input type="text" name="benchmark_name" placeholder="Example benchmark" value="<%= benchmark.name %>">
|
||||
</label>
|
||||
<div class="row mb-3">
|
||||
<div class="col-9">
|
||||
<label for="benchmark_name">Benchmark name</label>
|
||||
<input id="benchmark_name" class="form-control" type="text" name="benchmark_name" placeholder="Example benchmark" value="<%= benchmark.name %>">
|
||||
</div>
|
||||
|
||||
<div class="cell medium-3">
|
||||
<label>
|
||||
Scoring type
|
||||
<select name="benchmark_scoring">
|
||||
<option value="fps" <% if benchmark.scoring == 'fps' %>selected<% end %>>Frames per Second (fps)</option>
|
||||
<option value="ms" <% if benchmark.scoring == 'ms' %>selected<% end %>>Frame Time (ms)</option>
|
||||
<option value="pts" <% if benchmark.scoring == 'pts' %>selected<% end %>>Total Points</option>
|
||||
</select>
|
||||
</label>
|
||||
<div class="col-3">
|
||||
<label for="benchmark_scoring">Scoring type</label>
|
||||
<select id="benchmark_scoring" class="form-select" name="benchmark_scoring">
|
||||
<option value="fps" <% if benchmark.scoring == 'fps' %>selected<% end %>>Frames per Second (fps)</option>
|
||||
<option value="ms" <% if benchmark.scoring == 'ms' %>selected<% end %>>Frame Time (ms)</option>
|
||||
<option value="pts" <% if benchmark.scoring == 'pts' %>selected<% end %>>Total Points</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="grid-x grid-padding-x">
|
||||
<div class="cell small-12">
|
||||
<textarea name="benchmark_description" class="cell small-12"><%= benchmark.description %></textarea>
|
||||
<div class="row mb-3">
|
||||
<div class="col-12">
|
||||
<label for="benchmark_description">Benchmark description</label>
|
||||
<textarea id="benchmark_description" class="form-control" name="benchmark_description"><%= benchmark.description %></textarea>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="grid-x grid-padding-x">
|
||||
<div class="cell small-12">
|
||||
<input type="submit" class="button" value="Submit">
|
||||
</div>
|
||||
</div>
|
||||
<input class="btn btn-primary" type="submit" value="Submit Changes">
|
||||
</form>
|
||||
|
||||
</div>
|
||||
|
@ -1,20 +1,20 @@
|
||||
<div class="grid-x grid-margin-x">
|
||||
<div class="cell small-12">
|
||||
<div class="row mb-3">
|
||||
<div class="col-12">
|
||||
<h1>List of benchmarks</h1>
|
||||
</div>
|
||||
|
||||
<div class="cell small-12">
|
||||
<div class="col-12">
|
||||
<p>
|
||||
<a href="/benchmark/add">Add new benchmark</a>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="grid-x grid-margin-x">
|
||||
<div class="row">
|
||||
<% if benchmarks.length > 0 %>
|
||||
<div class="cell small-12">
|
||||
<table>
|
||||
<thead>
|
||||
<div class="col-12">
|
||||
<table class="table table-hover table-responsive">
|
||||
<thead class="table-light">
|
||||
<tr>
|
||||
<th>Benchmark name</th>
|
||||
<th>Scoring type</th>
|
||||
@ -24,7 +24,7 @@
|
||||
<tbody>
|
||||
<% benchmarks.each do |b| %>
|
||||
<tr>
|
||||
<td><a href="/benchmark/<%= b.id %>"><%= b.name %></a</td>
|
||||
<td><a href="/benchmark/<%= b.id %>"><%= b.name %></a></td>
|
||||
<td><%= b.scoring %></td>
|
||||
<td><%= b.description %></td>
|
||||
</tr>
|
||||
@ -33,7 +33,7 @@
|
||||
</table>
|
||||
</div>
|
||||
<% else %>
|
||||
<div class="cell small-12">
|
||||
<div class="col-12">
|
||||
<p>I'm sorry, there doesn't appear to be any benchmarks added yet. Check again later!</p>
|
||||
</div>
|
||||
<% end %>
|
||||
|
@ -1,17 +1,17 @@
|
||||
<div class="grid-x grid-margin-x">
|
||||
<div class="cell small-12">
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
<h1><%= benchmark.name %></h1>
|
||||
</div>
|
||||
|
||||
<div class="cell small-12">
|
||||
<div class="col-12">
|
||||
<p><a href="/benchmark/<%= benchmark.id %>/edit">Edit</a></p>
|
||||
</div>
|
||||
|
||||
<div class="cell small-12">
|
||||
<div class="col-12">
|
||||
Benchmark scoring type: <%= benchmark.scoring %>
|
||||
</div>
|
||||
|
||||
<div class="cell small-12">
|
||||
<div class="col-12">
|
||||
Description:
|
||||
<p><%= benchmark.description %></p>
|
||||
</div>
|
||||
|
Reference in New Issue
Block a user