1
0
mirror of https://github.com/moparisthebest/kaiwa synced 2024-11-16 06:15:08 -05:00

[ux] started on sectioning the content on main page

This commit is contained in:
karolinaszczur 2013-09-25 09:59:59 +02:00
parent 5871a0f0f1
commit e6a6446349
5 changed files with 50 additions and 27 deletions

View File

@ -131,7 +131,7 @@ exports.pages.groupchat = function anonymous(locals) {
exports.pages.main = function anonymous(locals) { exports.pages.main = function anonymous(locals) {
var buf = []; var buf = [];
with (locals || {}) { with (locals || {}) {
buf.push('<section class="page main"><p>Current status:<span contenteditable="true" class="status"></span></p><div id="avatarChanger"><h1>Change Avatar</h1><div class="uploadRegion"><p>Drag and drop a new avatar here</p><img/><form><input id="uploader" type="file"/></form></div></div><button class="enableAlerts">Enable alerts</button><h1>This space intentionally blank</h1></section>'); buf.push('<section class="page main"><div><h3>Current status<span contenteditable="true" class="status"></span></h3></div><div id="avatarChanger"><h3>Change Avatar</h3><div class="uploadRegion"><p>Drag and drop a new avatar here</p><img/><form><input id="uploader" type="file"/></form></div></div><div><h3>Alerts</h3><button class="enableAlerts">Enable alerts</button></div></section>');
} }
return buf.join(""); return buf.join("");
}; };

View File

@ -1,16 +1,17 @@
section.page.main section.page.main
p Current status: div
h3 Current status
span.status(contenteditable="true") span.status(contenteditable="true")
div#avatarChanger div#avatarChanger
h1 Change Avatar h3 Change Avatar
div.uploadRegion div.uploadRegion
p Drag and drop a new avatar here p Drag and drop a new avatar here
img img
form form
input#uploader(type="file") input#uploader(type="file")
div
h3 Alerts
button.enableAlerts Enable alerts button.enableAlerts Enable alerts
h1 This space intentionally blank

View File

@ -12,12 +12,13 @@ body
h1, h2, h3, h4 h1, h2, h3, h4
color: darken($baseText, 30%) color: darken($baseText, 30%)
h3
margin-top: 0
font-size: $fontMedium
#pages #pages
position: absolute position: absolute
top: 0px top: 0px
right: 0px right: 0px
left: 181px left: 181px
borderbox() borderbox()
.page.main
padding: 20px

View File

@ -1,12 +1,22 @@
@import '../_variables' @import '../_variables'
@import '../_mixins' @import '../_mixins'
.main div
padding: 20px
border-bottom: 1px solid $grayOutline
&:last-of-type
border: none
.uploadRegion .uploadRegion
font-size: 12px font-size: $fontSmall
roundall: 10px roundall(3px)
border: 1px dashed #777 margin: 10px 0
margin: 10px color: $textSecondary
text-align: center background: $grayBackground
p
margin: 0
input input
width: 100% width: 100%

View File

@ -260,6 +260,10 @@ h3,
h4 { h4 {
color: #3c3c3c; color: #3c3c3c;
} }
h3 {
margin-top: 0;
font-size: 14px;
}
#pages { #pages {
position: absolute; position: absolute;
top: 0px; top: 0px;
@ -269,9 +273,6 @@ h4 {
-webkit-box-sizing: border-box; -webkit-box-sizing: border-box;
box-sizing: border-box; box-sizing: border-box;
} }
#pages .page.main {
padding: 20px;
}
#connectionOverlay { #connectionOverlay {
position: fixed; position: fixed;
top: 0px; top: 0px;
@ -780,17 +781,27 @@ h4 {
border: 1px solid #efe391; border: 1px solid #efe391;
color: #d2bd2d; color: #d2bd2d;
} }
.main div {
padding: 20px;
border-bottom: 1px solid #e4e4e4;
}
.main div:last-of-type {
border: none;
}
.uploadRegion { .uploadRegion {
font-size: 12px; font-size: 12px;
-moz-border-radius: 10px; -moz-border-radius: 3px;
-webkit-border-radius: 10px; -webkit-border-radius: 3px;
-khtml-border-radius: 10px; -khtml-border-radius: 3px;
-o-border-radius: 10px; -o-border-radius: 3px;
-border-radius: 10px; -border-radius: 3px;
border-radius: 10px; border-radius: 3px;
border: 1px dashed #777; margin: 10px 0;
margin: 10px; color: #b7b7b7;
text-align: center; background: #f7f7f7;
}
.uploadRegion p {
margin: 0;
} }
.uploadRegion input { .uploadRegion input {
width: 100%; width: 100%;