Eliminate style attributes
This commit is contained in:
parent
8d01a2689d
commit
b1c06ae55b
|
@ -19,9 +19,6 @@ class PollController extends Controller
|
|||
return view('create_poll');
|
||||
}
|
||||
|
||||
//TODO: Close polls
|
||||
//TODO: Implement poll editing
|
||||
|
||||
public function create(Request $request)
|
||||
{
|
||||
if($request->has('options')) {
|
||||
|
@ -268,7 +265,7 @@ class PollController extends Controller
|
|||
$extraCodes = $request->session()->pull('extraCodes', null);
|
||||
|
||||
if($poll->admin_password == null || $request->query('password') != $poll->admin_password) {
|
||||
return redirect()->action('PollController@view', ['poll' => $poll]);
|
||||
return redirect()->action('PollController@viewResults', ['poll' => $poll]);
|
||||
}
|
||||
|
||||
return view('edit_poll')->with('poll', $poll)->with('changed', $changed)->with('extraCodes', $extraCodes);
|
||||
|
|
|
@ -100,7 +100,7 @@
|
|||
<input type="hidden" name="automatically_close_poll" value="1">
|
||||
<input type="hidden" name="automatically_close_poll_datetime" value="now">
|
||||
|
||||
<input type="submit" class="btn" style="width:100%" value="Close poll now">
|
||||
<input type="submit" class="btn huge-button" value="Close poll now">
|
||||
</div>
|
||||
</form>
|
||||
</section>
|
||||
|
|
|
@ -17,12 +17,24 @@
|
|||
.some-more-bottom-margin { margin-bottom: 2.0rem; }
|
||||
.inline-block { display: inline-block; }
|
||||
.text-browser { display: none; }
|
||||
.huge-button { width: 100%; }
|
||||
.float-right { float: right; }
|
||||
|
||||
.primary-box {
|
||||
padding: 1rem 1rem 1rem 1rem!important;
|
||||
border: 2px solid #e83fb8;
|
||||
}
|
||||
|
||||
.vote-bar {
|
||||
background-color: #e83fb8;
|
||||
height: 2rem;
|
||||
}
|
||||
|
||||
img.centered-image {
|
||||
display: block;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
.copyarea {
|
||||
user-select: all;
|
||||
width: calc(100% - 0.4rem);
|
||||
|
|
|
@ -38,10 +38,10 @@
|
|||
<div>
|
||||
<span>{{ $option->text }}</span>
|
||||
<span class="text-browser">:</span>
|
||||
<span style="float:right">{{ $votes }} votes</span>
|
||||
<span class="float-right">{{ $votes }} votes</span>
|
||||
</div>
|
||||
<div>
|
||||
<div style="background-color:#e83fb8;height:2rem;width:{{ $total == 0 ? 0 : ($votes / $total * 100) }}%;" "{{ $total == 0 ? 0 : ($votes / $total * 100)}}% of votes">
|
||||
<div class="vote-bar" style="width:{{ $total == 0 ? 0 : ($votes / $total * 100) }}%;">
|
||||
<div class="text-browser">
|
||||
<span>{{ $total == 0 ? 0 : round($votes / $total * 100, 2) }}% of votes</span>
|
||||
<br><br>
|
||||
|
@ -60,14 +60,14 @@
|
|||
|
||||
@if ($total != 0)
|
||||
<div class="primary-box">
|
||||
<img src="{{ $cache['pie_chart']}}" style="display:block;margin: 0 auto">
|
||||
<img src="{{ $cache['pie_chart']}}" class="centered-image">
|
||||
|
||||
<br>
|
||||
|
||||
<div class="text-browser"><br></div>
|
||||
|
||||
@foreach ($nonZeroOptions as $option)
|
||||
<img src="{{ $cache['colour_squares'][$option->id] }}" style="display:inline-block">
|
||||
<img src="{{ $cache['colour_squares'][$option->id] }}" class="inline-block">
|
||||
<span>{{ $option->text }}</span>
|
||||
|
||||
<br>
|
||||
|
|
Loading…
Reference in New Issue