Refactor scss

Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
This commit is contained in:
Dmitriy Zaporozhets 2014-01-10 14:14:55 +02:00
parent 515ed7755e
commit f126676553
No known key found for this signature in database
GPG key ID: 627C5F589F467F17
8 changed files with 484 additions and 495 deletions

View file

@ -12,6 +12,7 @@
@import "main/variables.scss"; @import "main/variables.scss";
@import "main/mixins.scss"; @import "main/mixins.scss";
@import "main/fonts.scss"; @import "main/fonts.scss";
@import "main/layout.scss";
/** /**
* Customized Twitter bootstrap * Customized Twitter bootstrap
@ -27,19 +28,42 @@
/** /**
* Generic css (forms, nav etc): * Generic css (forms, nav etc):
*/ */
@import "generic.scss"; @import "generic/avatar.scss";
@import "generic/common.scss";
@import "generic/typography.scss";
/** @import "generic/buttons.scss";
* Unrefactored css @import "generic/blocks.scss";
*/ @import "generic/ui_box.scss";
@import "common.scss"; @import "generic/issue_box.scss";
@import "generic/files.scss";
@import "generic/lists.scss";
@import "generic/forms.scss";
@import "generic/selects.scss";
/** /**
* Page specific styles (issues, projects etc): * Page specific styles (issues, projects etc):
*/ */
@import "sections.scss"; @import "sections/header.scss";
@import "sections/nav.scss";
@import "sections/commits.scss";
@import "sections/issues.scss";
@import "sections/projects.scss";
@import "sections/snippets.scss";
@import "sections/votes.scss";
@import "sections/merge_requests.scss";
@import "sections/graph.scss";
@import "sections/events.scss";
@import "sections/themes.scss";
@import "sections/tree.scss";
@import "sections/notes.scss";
@import "sections/profile.scss";
@import "sections/login.scss";
@import "sections/editor.scss";
@import "sections/admin.scss";
@import "sections/wiki.scss";
@import "sections/wall.scss";
@import "sections/dashboard.scss";
@import "sections/stat_graph.scss";
/** /**
* Code ighlight * Code ighlight

View file

@ -1,392 +0,0 @@
html {
overflow-y: scroll;
}
/** LAYOUT **/
body {
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
margin-bottom: 20px;
}
.container {
padding-top: 0;
z-index: 5;
}
.container .content {
margin: 0 0;
}
.author_link {
color: $link_color;
}
.help li { color:$style_color; }
.back-link {
font-size: 14px;
}
table a code {
position: relative;
top: -2px;
margin-right: 3px;
}
.loading {
margin: 20px auto;
background: url(ajax_loader.gif) no-repeat center center;
width: 40px;
height: 40px;
&.loading-gray {
background: url(ajax_loader_gray.gif) no-repeat center center;
}
}
/** FLASH message **/
.flash-container {
display: none;
cursor: pointer;
margin: 0;
text-align: center;
color: #fff;
font-size: 14px;
position: fixed;
bottom: 0;
width: 100%;
opacity: 0.8;
z-index: 100;
.flash-notice {
background: #49C;
padding: 10px;
text-shadow: 0 1px 1px #178;
}
.flash-alert {
background: #C67;
text-shadow: 0 1px 1px #945;
padding: 10px;
}
}
span.update-author {
display: block;
color: #999;
font-weight: normal;
font-style: italic;
strong {
font-weight: bold;
font-style: normal;
}
}
.user-mention {
color: #2FA0BB;
font-weight: bold;
}
.field_with_errors {
display: inline;
}
ul.breadcrumb {
background: white;
border: none;
li {
display: inline;
text-shadow: 0 1px 0 white
}
a {
font-size: 16px;
}
}
.line_holder {
&:hover {
td {
background: #FFFFCF !important;
}
}
}
p.time {
color: #999;
font-size: 90%;
margin: 30px 3px 3px 2px;
}
.highlight {
text-shadow: none;
}
.highlight_word {
border-bottom: 2px solid #F90;
}
.thin_area{
height: 150px;
}
// Fixes alignment on notes.
.new_note {
label {
text-align: left;
}
}
// Fix issue with notes & lists creating a bunch of bottom borders.
li.note {
img { max-width:100% }
.note-title {
li {
border-bottom:none !important;
}
}
}
.markdown {
img {
max-width: 100%;
}
}
.wiki_content code, .readme code{
background-color: inherit;
}
.team_member_show {
td:first-child {
color: #aaa;
}
}
.rss-icon {
img {
width: 24px;
vertical-align: top;
}
strong {
line-height: 24px;
}
}
.supp_diff_link,
.show-all-commits {
cursor: pointer;
}
.merge-request,
.issue {
&.today{
background: #EFE;
border-color: #CEC;
}
&.closed {
background: #F5f5f5;
border-color: #E5E5E5;
}
&.merged {
background: #F5f5f5;
border-color: #E5E5E5;
}
}
.git_error_tips {
@extend .col-md-6;
text-align: left;
margin-top: 40px;
pre {
background: white;
border: none;
font-size: 12px;
}
}
.error-message {
padding: 10px;
background: #C67;
margin: 0;
color: #FFF;
a {
color: #fff;
text-decoration: underline;
}
}
.no-ssh-key-message {
padding: 10px 0;
background: #C67;
margin: 0;
color: #FFF;
margin-top: -1px;
text-align: center;
a {
color: #fff;
text-decoration: underline;
}
}
.warning_message {
border-left: 4px solid #ed9;
color: #b90;
padding: 10px;
margin-bottom: 10px;
background: #ffffe6;
padding-left: 20px;
&.centered {
text-align: center;
}
}
.gitlab-promo {
a {
color: #aaa;
margin-right: 30px;
}
}
pre {
&.clean {
background: none;
border: none;
margin: 0;
padding: 0;
}
}
.milestone {
&.milestone-closed {
background: #eee;
}
.progress {
margin-bottom: 0;
margin-top: 4px;
}
}
h1.http_status_code {
font-size: 56px;
line-height: 100px;
font-weight: normal;
color: #456;
}
.control-group {
.controls {
span {
&.descr {
position: relative;
top: 2px;
left: 5px;
color: #666;
}
}
}
}
img.emoji {
height: 20px;
vertical-align: middle;
width: 20px;
}
.appear-data {
display: none;
}
.chart {
overflow: hidden;
height: 220px;
}
.navless-container {
margin-top: 20px;
}
.description-block {
@extend .light-well;
@extend .light;
margin-bottom: 10px;
}
table {
td.permission-x {
background: #D9EDF7 !important;
text-align: center;
}
}
.dashboard-intro-icon {
float: left;
font-size: 32px;
color: #AAA;
padding: 5px 0;
width: 50px;
min-height: 100px;
}
.broadcast-message {
padding: 10px;
text-align: center;
background: #555;
color: #BBB;
}
.broadcast-message-preview {
@extend .broadcast-message;
margin-bottom: 20px;
}
.ajax-users-select {
width: 400px;
&.input-large {
width: 210px;
}
&.input-clamp {
max-width: 100%;
}
}
.user-result {
.user-image {
float: left;
}
.user-name {
}
.user-username {
color: #999;
}
}
.namespace-result {
.namespace-kind {
color: #AAA;
font-weight: normal;
}
.namespace-path {
margin-left: 10px;
font-weight: bolder;
}
}
.side-filters {
fieldset {
margin-bottom: 15px;
}
}
.btn-sign-in {
margin-top: 7px;
text-shadow: none;
}

View file

@ -1,12 +0,0 @@
@import "generic/avatar.scss";
@import "generic/nav.scss";
@import "generic/common.scss";
@import "generic/typography.scss";
@import "generic/buttons.scss";
@import "generic/blocks.scss";
@import "generic/ui_box.scss";
@import "generic/issue_box.scss";
@import "generic/files.scss";
@import "generic/lists.scss";
@import "generic/forms.scss";
@import "generic/selects.scss";

View file

@ -128,3 +128,360 @@ pre.well-pre {
white-space: nowrap; white-space: nowrap;
max-width: 82%; max-width: 82%;
} }
/** FLASH message **/
.flash-container {
display: none;
cursor: pointer;
margin: 0;
text-align: center;
color: #fff;
font-size: 14px;
position: fixed;
bottom: 0;
width: 100%;
opacity: 0.8;
z-index: 100;
.flash-notice {
background: #49C;
padding: 10px;
text-shadow: 0 1px 1px #178;
}
.flash-alert {
background: #C67;
text-shadow: 0 1px 1px #945;
padding: 10px;
}
}
.author_link {
color: $link_color;
}
.help li { color:$style_color; }
.back-link {
font-size: 14px;
}
table a code {
position: relative;
top: -2px;
margin-right: 3px;
}
.loading {
margin: 20px auto;
background: url(ajax_loader.gif) no-repeat center center;
width: 40px;
height: 40px;
&.loading-gray {
background: url(ajax_loader_gray.gif) no-repeat center center;
}
}
span.update-author {
display: block;
color: #999;
font-weight: normal;
font-style: italic;
strong {
font-weight: bold;
font-style: normal;
}
}
.user-mention {
color: #2FA0BB;
font-weight: bold;
}
.field_with_errors {
display: inline;
}
.line_holder {
&:hover {
td {
background: #FFFFCF !important;
}
}
}
p.time {
color: #999;
font-size: 90%;
margin: 30px 3px 3px 2px;
}
.highlight {
text-shadow: none;
}
.highlight_word {
border-bottom: 2px solid #F90;
}
.thin_area{
height: 150px;
}
// Fixes alignment on notes.
.new_note {
label {
text-align: left;
}
}
// Fix issue with notes & lists creating a bunch of bottom borders.
li.note {
img { max-width:100% }
.note-title {
li {
border-bottom:none !important;
}
}
}
.markdown {
img {
max-width: 100%;
}
}
.wiki_content code, .readme code{
background-color: inherit;
}
.team_member_show {
td:first-child {
color: #aaa;
}
}
.rss-icon {
img {
width: 24px;
vertical-align: top;
}
strong {
line-height: 24px;
}
}
.supp_diff_link,
.show-all-commits {
cursor: pointer;
}
.merge-request,
.issue {
&.today{
background: #EFE;
border-color: #CEC;
}
&.closed {
background: #F5f5f5;
border-color: #E5E5E5;
}
&.merged {
background: #F5f5f5;
border-color: #E5E5E5;
}
}
.git_error_tips {
@extend .col-md-6;
text-align: left;
margin-top: 40px;
pre {
background: white;
border: none;
font-size: 12px;
}
}
.error-message {
padding: 10px;
background: #C67;
margin: 0;
color: #FFF;
a {
color: #fff;
text-decoration: underline;
}
}
.no-ssh-key-message {
padding: 10px 0;
background: #C67;
margin: 0;
color: #FFF;
margin-top: -1px;
text-align: center;
a {
color: #fff;
text-decoration: underline;
}
}
.warning_message {
border-left: 4px solid #ed9;
color: #b90;
padding: 10px;
margin-bottom: 10px;
background: #ffffe6;
padding-left: 20px;
&.centered {
text-align: center;
}
}
.gitlab-promo {
a {
color: #aaa;
margin-right: 30px;
}
}
pre {
&.clean {
background: none;
border: none;
margin: 0;
padding: 0;
}
}
.milestone {
&.milestone-closed {
background: #eee;
}
.progress {
margin-bottom: 0;
margin-top: 4px;
}
}
h1.http_status_code {
font-size: 56px;
line-height: 100px;
font-weight: normal;
color: #456;
}
.control-group {
.controls {
span {
&.descr {
position: relative;
top: 2px;
left: 5px;
color: #666;
}
}
}
}
img.emoji {
height: 20px;
vertical-align: middle;
width: 20px;
}
.appear-data {
display: none;
}
.chart {
overflow: hidden;
height: 220px;
}
.navless-container {
margin-top: 20px;
}
.description-block {
@extend .light-well;
@extend .light;
margin-bottom: 10px;
}
table {
td.permission-x {
background: #D9EDF7 !important;
text-align: center;
}
}
.dashboard-intro-icon {
float: left;
font-size: 32px;
color: #AAA;
padding: 5px 0;
width: 50px;
min-height: 100px;
}
.broadcast-message {
padding: 10px;
text-align: center;
background: #555;
color: #BBB;
}
.broadcast-message-preview {
@extend .broadcast-message;
margin-bottom: 20px;
}
.ajax-users-select {
width: 400px;
&.input-large {
width: 210px;
}
&.input-clamp {
max-width: 100%;
}
}
.user-result {
.user-image {
float: left;
}
.user-name {
}
.user-username {
color: #999;
}
}
.namespace-result {
.namespace-kind {
color: #AAA;
font-weight: normal;
}
.namespace-path {
margin-left: 10px;
font-weight: bolder;
}
}
.side-filters {
fieldset {
margin-bottom: 15px;
}
}
.btn-sign-in {
margin-top: 7px;
text-shadow: none;
}

View file

@ -1,61 +0,0 @@
/**
* nav-pills
*
*/
.nav-pills {
.active a {
background: $primary_color;
}
&.nav-stacked {
> li > a {
@include border-radius(0);
border-left: 4px solid #EEE;
padding: 12px;
color: #777;
}
> .active > a {
border-color: $primary_color;
background: none;
color: #333;
font-weight: bolder;
&:hover {
background: none;
color: #333;
}
}
&.nav-stacked-menu {
li > a {
padding: 16px;
}
}
}
&.nav-pills-small {
> li > a {
padding: 8px 12px;
font-size: 12px;
}
}
}
.nav-pills > .active > a > i[class^="icon-"] { background: inherit; }
/**
* nav-tabs
*
*/
.nav-tabs > li > a, .nav-pills > li > a { color: $style_color; }
/**
* fix to keep tooltips position in top navigation bar
*
*/
.navbar .nav > li {
position: relative;
white-space: nowrap;
}

View file

@ -1,3 +1,12 @@
/*
* Twitter bootstrap with GitLab customizations/additions
*
* Some unused bootstrap compontents like panels are not included.
* Other components like tabs are modified to GitLab style.
*
*/
// Core variables and mixins // Core variables and mixins
@import "bootstrap/variables"; @import "bootstrap/variables";
@import "bootstrap/mixins"; @import "bootstrap/mixins";
@ -128,6 +137,50 @@
} }
} }
.nav-tabs > li > a, .nav-pills > li > a { color: $style_color; }
// Nav pills
.nav-pills {
.active a {
background: $primary_color;
}
&.nav-stacked {
> li > a {
@include border-radius(0);
border-left: 4px solid #EEE;
padding: 12px;
color: #777;
}
> .active > a {
border-color: $primary_color;
background: none;
color: #333;
font-weight: bolder;
&:hover {
background: none;
color: #333;
}
}
&.nav-stacked-menu {
li > a {
padding: 16px;
}
}
}
&.nav-pills-small {
> li > a {
padding: 8px 12px;
font-size: 12px;
}
}
}
.nav-pills > .active > a > i[class^="icon-"] { background: inherit; }
/* /*
* Callouts from Bootstrap3 docs * Callouts from Bootstrap3 docs
* *
@ -172,3 +225,26 @@
border-color: #5cA64d; border-color: #5cA64d;
color: #3c763d; color: #3c763d;
} }
// Breadcrumb
ul.breadcrumb {
background: white;
border: none;
li {
display: inline;
text-shadow: 0 1px 0 white
}
a {
font-size: 16px;
}
}
/**
* fix to keep tooltips position in top navigation bar
*
*/
.navbar .nav > li {
position: relative;
white-space: nowrap;
}

View file

@ -0,0 +1,18 @@
html {
overflow-y: scroll;
}
body {
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
margin-bottom: 20px;
}
.container {
padding-top: 0;
z-index: 5;
}
.container .content {
margin: 0 0;
}

View file

@ -1,21 +0,0 @@
@import "sections/header.scss";
@import "sections/nav.scss";
@import "sections/commits.scss";
@import "sections/issues.scss";
@import "sections/projects.scss";
@import "sections/snippets.scss";
@import "sections/votes.scss";
@import "sections/merge_requests.scss";
@import "sections/graph.scss";
@import "sections/events.scss";
@import "sections/themes.scss";
@import "sections/tree.scss";
@import "sections/notes.scss";
@import "sections/profile.scss";
@import "sections/login.scss";
@import "sections/editor.scss";
@import "sections/admin.scss";
@import "sections/wiki.scss";
@import "sections/wall.scss";
@import "sections/dashboard.scss";
@import "sections/stat_graph.scss";