gitlab-org--gitlab-foss/app/assets/stylesheets/pages/notes.scss

254 lines
4.1 KiB
SCSS
Raw Normal View History

2012-02-26 17:41:53 -05:00
/**
* Notes
*/
@-webkit-keyframes targe3-note {
from { background:#fffff0; }
50% { background:#ffffd3; }
to { background:#fffff0; }
}
ul.notes {
display: block;
list-style: none;
margin: 0px;
padding: 0px;
.system-note {
font-size: 14px;
padding-top: 10px;
padding-bottom: 10px;
background: #f8fafc;
.timeline-icon {
.avatar {
visibility: hidden;
}
}
}
.discussion-header,
.note-header {
@extend .cgray;
padding-bottom: 15px;
a:hover {
text-decoration: none;
}
.avatar {
float: left;
margin-right: 10px;
}
.discussion-last-update,
.note-last-update {
&:before {
content: "\00b7";
}
2015-05-14 06:18:19 -04:00
a {
color: $gl-gray;
2015-05-14 06:18:19 -04:00
&:hover {
text-decoration: underline;
}
}
}
.author {
color: #4c4e54;
margin-right: 3px;
&:hover {
2015-03-06 23:02:34 -05:00
color: $gl-link-color;
}
}
.author-username {
}
2015-05-12 06:16:34 -04:00
.note-role {
float: right;
2015-05-14 06:18:19 -04:00
margin-top: 1px;
2015-05-12 06:16:34 -04:00
border: 1px solid #bbb;
background-color: transparent;
color: $gl-gray;
2015-05-12 06:16:34 -04:00
}
}
.discussion {
overflow: hidden;
display: block;
position:relative;
}
.note {
display: block;
position:relative;
.note-body {
overflow: auto;
.note-text {
overflow: auto;
word-wrap: break-word;
@include md-typography;
// Reset ul style types since we're nested inside a ul already
& > ul {
list-style-type: disc;
ul {
list-style-type: circle;
ul {
list-style-type: square;
}
}
}
// Reduce left padding of first task list ul element
2015-04-29 20:36:12 -04:00
ul.task-list:first-child {
padding-left: 10px;
// sub-tasks should be padded normally
2015-04-29 20:36:12 -04:00
ul {
padding-left: 20px;
}
}
hr {
// Darken 'whitesmoke' a bit to make it more visible in note bodies
border-color: darken(#F5F5F5, 8%);
margin: 10px 0;
}
}
}
.note-header {
padding-bottom: 3px;
}
&:last-child {
border-bottom: none;
}
}
}
// Diff code in discussion view
2015-03-26 02:21:13 -04:00
.discussion-body .diff-file {
.diff-header > span {
margin-right: 10px;
}
.line_content {
white-space: pre-wrap;
}
}
.diff-file .notes_holder {
font-family: $regular_font;
2012-11-20 11:46:55 -05:00
td {
border: 1px solid #ddd;
border-left: none;
&.notes_line {
text-align: center;
padding: 10px 0;
background: #FFF;
2012-11-20 11:46:55 -05:00
}
&.notes_line2 {
text-align: center;
padding: 10px 0;
border-left: 1px solid #ddd !important;
}
2012-11-20 11:46:55 -05:00
&.notes_content {
background-color: #fff;
2012-11-20 11:46:55 -05:00
border-width: 1px 0;
padding-top: 0;
vertical-align: top;
2014-09-12 12:43:44 -04:00
&.parallel{
border-width: 1px;
}
2012-11-20 11:46:55 -05:00
}
}
}
/**
2012-12-03 15:43:17 -05:00
* Actions for Discussions/Notes
*/
2012-12-03 15:43:17 -05:00
.discussion,
.note {
.discussion-actions,
.note-actions {
float: right;
2015-05-14 06:18:19 -04:00
margin-left: 10px;
a {
2015-05-12 06:16:34 -04:00
margin-left: 5px;
color: $gl-gray;
2015-05-14 06:18:19 -04:00
i.fa {
font-size: 16px;
line-height: 16px;
}
&:hover {
2015-05-14 06:18:19 -04:00
@extend .cgray;
&.danger { @extend .cred; }
}
}
}
}
.diff-file .note .note-actions {
right: 0;
top: 0;
2011-11-12 06:04:43 -05:00
}
2012-09-12 20:12:44 -04:00
2012-11-20 11:46:55 -05:00
/**
2012-12-03 15:43:17 -05:00
* Line note button on the side of diffs
2012-11-20 11:46:55 -05:00
*/
2012-12-03 15:43:17 -05:00
.diff-file tr.line_holder {
2014-09-19 10:16:45 -04:00
@mixin show-add-diff-note {
filter: alpha(opacity=100);
opacity: 1.0;
}
2012-11-20 11:46:55 -05:00
.add-diff-note {
margin-top: -4px;
@include border-radius(40px);
background: #FFF;
padding: 4px;
font-size: 16px;
2015-03-06 23:02:34 -05:00
color: $gl-link-color;
margin-left: -60px;
position: absolute;
z-index: 10;
width: 32px;
transition: all 0.2s ease;
// "hide" it by default
2012-11-20 11:46:55 -05:00
opacity: 0.0;
filter: alpha(opacity=0);
2012-11-20 11:46:55 -05:00
&:hover {
background: $gl-info;
color: #FFF;
2014-09-19 10:16:45 -04:00
@include show-add-diff-note;
2012-11-20 11:46:55 -05:00
}
}
// "show" the icon also if we just hover somewhere over the line
2012-11-20 11:46:55 -05:00
&:hover > td {
background: $hover !important;
.add-diff-note {
2014-09-19 10:16:45 -04:00
@include show-add-diff-note;
}
2012-07-10 13:15:33 -04:00
}
}