timestamper/www/css/ts-screen.scss
Jonathan Bernard 2cc17b85f1 Implemented notes UI.
- Switched from a global reset in www/css/ts-screen.scss to a selected
  top-level elements reset to allow default formatting for user notes.
- Restructured the #entry-list and entry displays.
- Restructured notes div, now has a sub-div for text and a textarea
  element for input.
- Added Showdown.js, a JavaScript Markdown library for formatting comments.
- Moved EntryView blur events to the View events map.
- Added images for expansion of notes.
- Added the ability to edit notes.
- Split EntryListView.addOne into renderOne and addOne so that renderOne
  can be called with a new entry (fixes duration glitch)
2011-05-16 04:09:37 -05:00

390 lines
6.9 KiB
SCSS

/*
* author: Jonathan Bernard
* TimeStamper main CSS for screen media types
*/
@import "rounded";
$darkTxt: #222;
$lightTxt: #eee;
$darkBg: #222;
$lightBg: #eee;
$medBg: #CCC;
* {
color: inherit;
}
body {
color: $darkTxt;
width: 75%;
margin: auto;
padding: 0;
}
input {
border: solid thin lighten($darkTxt, 20%);
-webkit-box-shadow: inset 0px 2px 4px #CCC;
box-shadow: inset 0px 2px 4px #CCC;
margin: 0;
margin-bottom: 0.5em; // IE fix
padding: 0;
font-family: Cantarell;
}
#top {
background: $darkBg;
color: $lightTxt;
margin: 0;
opacity: 1;
padding: 0.5em 0; // IE Fix
padding: 0.5rem 0;
position: fixed;
top: 0px;
width: 75%;
z-index: 1;
* {
margin: 0;
padding: 0;
}
#fade-bar {
background: url('img/fade.png') repeat-x;
height: 32px;
width: 100%;
}
}
#timeline {
border-bottom: thin solid $lightBg;
font-family: Arvo;
font-size: 1.5em;
padding: 0 2em;
padding: 0 2rem;
.timeline-desc {
display: inline-block;
width: 70%;
}
.timeline-desc-input { width: 70% }
.timeline-id { display: inline-block; }
.timeline-desc-input, .timeline-id-input {
font-family: inherit;
font-size: inherit;
color: $darkBg;
display: none;
}
&.edit-id {
.timeline-id-input { display: inline-block; }
.timeline-id { display: none; }
}
&.edit-desc {
.timeline-desc-input { display: inline-block; }
.timeline-desc { display: none; }
}
.drop-menu {
text-align: right;
display: inline-block;
width: 29%;
.drop-menu-items {
text-align: right;
right: 0;
width: 172.41%;
.timeline-link {
font-size: medium;
}
}
}
}
#login {
background: white;
color: $lightTxt;
margin: 0;
padding: 0;
opacity: 1;
position: fixed;
top: 0px;
left: 0px;
width: 100%;
height: 100em;
z-index: 10;
* {
margin: 0;
padding: 0;
}
div.container {
background: $darkBg;
border-radius: 10px;
font-family: Cantarell;
margin-left: auto;
margin-right: auto;
margin-top: 4em;
padding: 1em;
width: 20em;
h2 {
border-bottom: thin solid $lightBg;
font-family: Arvo;
padding-bottom: 0.5em;
margin-bottom: 0.5em;
}
label {
display: inline-block;
width: 6em;
}
input {
color: $darkTxt;
}
#login-button {
text-align: right;
margin-top: 0.5em;
font-family: Arvo;
font-size: 1.2em;
.validate-tips { font-size: 1em; }
a { color: $lightBg; }
}
}
}
#user {
font-family: "Josefin Sans";
margin-top: -0.3em; // IE fix
padding: 0 2em;
margin-top: -0.3rem;
padding: 0 2rem;
width: 100%;
.fullname, .username {
display: inline-block;
font-size: larger;
}
.fullname-input {
font-family: inherit;
font-size: inherit;
color: $darkBg;
display: none;
}
&.edit-fullname{
.fullname-input { display: inline-block; }
.fullname { display: none; }
}
.drop-menu { display: inline-block; }
.drop-menu .drop-menu-items {
margin-top: -0.5em;
text-align: right;
right: 0;
list-style: none;
width: 10em;
}
}
#entry-list {
margin: 6em 0 0 0;
margin: 6rem 0 0 0;
padding-bottom: 1em 0 0 0;
padding-bottom: 1rem 0 0 0;
.day-seperator {
background: $medBg;
color: $darkBg;
font-family: Cantarell;
font-weight: bold;
margin: 1em 0 0 0;
margin: 1rem 0 0 0;
padding: 0 2em;
padding: 0 2rem;
* {
margin: 0;
padding: 0;
}
h4, h5 { display: inline-block; }
h5 { color: #667; }
}
#new-entry {
margin: 0.5em 0 0 0;
padding: 0 2em;
margin: 0.5rem 0 0 0;
padding: 0 2rem;
* {
margin: 0;
padding: 0;
}
}
.timestamp, .timestamp-input, .duration {
text-align: right;
width: 14%;
}
.mark, .mark-input { width: 70%; }
.entry {
font-family: Cantarell;
padding: 0 2em;
padding: 0 2rem;
div { display: inline-block; }
.mark {
margin: 0;
padding: 0;
position: relative;
* {
margin: 0;
padding: 0;
}
img.expand-entry, img.collapse-entry {
display: none;
left: -20px;
position: absolute;
top: 6px;
}
}
&:hover .mark img.expand-entry, &.show-notes img.collapse-entry { display: inline; }
.mark-input, .timestamp-input,
&.show-notes:hover img.expand-entry { display: none; }
.notes {
display: none;
font-family: Cantarell;
font-size: small;
margin: 0;
padding: 0 0 0 1em;
:first-child { margin-top: 0; }
.notes-input, pre, code { font-family: 'Anonymous Pro'; }
}
.notes * { width: 100%; }
&.edit-mark {
.mark-input { display: inline-block; }
.mark { display: none; }
}
&.edit-timestamp {
.timestamp-input { display: inline-block; }
.timestamp { display: none; }
}
.notes-input { display: none; }
&.edit-notes .notes-input { display: block; }
&.edit-notes .notes-text { display: none; }
}
}
.drop-menu {
margin: 0;
padding: 0;
position: relative;
* {
margin: 0;
padding: 0;
}
.drop-menu-items {
display: none;
list-style: none;
position: absolute;
li {
display: inline-block;
padding-left: 0.5em;
}
}
&:hover .drop-menu-items, .drop-menu-items:hover { display: block; }
a {
display: inline-block;
text-decoration: none;
&:hover {
text-decoration: underline;
}
}
}
.footer {
background: $darkBg;
color: $lightTxt;
font-family: Bentham;
margin: 0;
padding: 1em 0;
padding: 1rem 0;
text-align: center;
width: 100%;
* {
margin: 0;
padding: 0;
}
a {
color: lighten($lightTxt, 20%);
text-decoration: none;
&:hover { text-decoration: underline; }
}
}
.logo {
font-family: Bentham;
text-decoration: overline underline;
color: inherit;
}
.hidden { display: none; }