add polls to home page and fix up styles just a little bit

This commit is contained in:
ansuz 2016-07-15 18:49:50 +02:00
parent 7dd1624206
commit d0ce8f2ca1
4 changed files with 122 additions and 1 deletions

View File

@ -68,6 +68,7 @@
<div id="buttons" class="buttons">
<a id="create-pad" class="button create" href="/pad/">CREATE NEW WYSIWYG PAD</a>
<a id="create-code" class="button create" href="/code/">CREATE NEW CODE PAD</a>
<a id="create-poll" class="button create" href="/poll/">CREATE NEW POLL</a>
</div>
</center>
</div>

View File

@ -136,6 +136,10 @@ tr {
.button {
padding: 4px 12px 4px 12px;
border-radius: 5px;
margin-top: 12px;
margin-bottom: 12px;
white-space: nowrap;
display: inline-block;
}
/* Tables */
table {
@ -239,3 +243,36 @@ tbody td:last-child {
top: 3px;
max-width: 100px;
}
form.realtime {
padding: 0px;
margin: 0px;
}
form.realtime > textarea {
width: 50%;
height: 15vh;
}
form.realtime table {
border-collapse: collapse;
}
form.realtime table input {
height: 100%;
width: 100%;
border: 3px solid #302B28;
display: table-cell;
}
form.realtime table tfoot tr td {
z-index: 4000;
cursor: pointer;
}
form.realtime #adduser,
form.realtime #addoption {
color: #46E981;
border: 1px solid #46E981;
padding: 15px;
}
form.realtime #addoption {
border-bottom-left-radius: 5px;
}
form.realtime #adduser {
border-top-left-radius: 5px;
}

View File

@ -34,7 +34,8 @@ define([
var padTypes = {
'/pad/': 'Pad',
'/code/': 'Code'
'/code/': 'Code',
'/poll/': 'Poll',
};
var truncateTitle = function (title, len) {

View File

@ -170,6 +170,10 @@ p, pre, td, a, table, tr {
padding: @vpad @hpad @vpad @hpad;
border-radius: 5px;
margin-top: 2 * 6px;
margin-bottom: 2 * 6px;
white-space: nowrap;
display: inline-block;
}
/* Tables */
@ -283,3 +287,81 @@ tbody {
}
// form things
form.realtime {
> input {
&[type="text"] {
}
}
> textarea {
width: 50%;
height: 15vh;
}
padding: 0px;
margin: 0px;
table {
border-collapse: collapse;
tr {
td {
//border: 1px solid white;
}
}
input {
height: 100%;
width: 100%;
border: 3px solid @base;
display: table-cell;
}
thead {
tr {
td {
}
}
}
tbody {
tr {
td {
}
}
}
tfoot {
tr {
td {
z-index: 4000;
cursor: pointer;
}
}
}
}
#adduser,
#addoption {
color: @cp-green;
border: 1px solid @cp-green;
padding: 15px;
}
.corner (@tl: 0px, @tr: 0px, @br: 0px, @bl: 0px) {
border-radius: @tl @tr @br @bl;
}
#addoption {
//.corner(0px, 0px,
border-bottom-left-radius: 5px;
}
#adduser {
border-top-left-radius: 5px;
}
}