Retrospring/app/views/user/theme.css.scss.erb

309 lines
6.8 KiB
Plaintext
Raw Normal View History

// LEGEND
// TYPE_COLOR: BACKGROUND COLOR
// TYPE_BORDER: BORDER COLOR
// TYPE_TEXT: TEXT COLOR
2015-07-29 09:31:34 -07:00
// PRIMARY COLOR
2015-08-24 22:18:01 -07:00
$primary_color: <%= @primary_color || "#5e35b1" %>;
$primary_border: <%= @primary_border || "darken(adjust-hue(#5e35b1, -10), 5%)" %>;
$primary_text: <%= @primary_text || "white" %>;
2015-07-29 09:31:34 -07:00
// DANGER COLOR
2015-08-24 22:18:01 -07:00
$danger_color: <%= @danger_color || "#FF0039" %>;
$danger_border: <%= @danger_border || "darken(adjust-hue(#FF0039, -10), 5%)" %>;
$danger_text: <%= @danger_text || "white" %>;
2015-07-29 09:31:34 -07:00
// SUCCESS COLOR
2015-08-24 22:18:01 -07:00
$success_color: <%= @success_color || "#3FB618" %>;
$success_border: <%= @success_border || "darken(adjust-hue(#3FB618, -10), 5%)" %>;
$success_text: <%= @success_text || "white" %>;
2015-07-29 09:31:34 -07:00
// WARNING COLOR
2015-08-24 22:18:01 -07:00
$warning_color: <%= @warning_color || "#FF7518" %>;
$warning_border: <%= @warning_border || "darken(adjust-hue(#FF7518, -10), 5%)" %>;
$warning_text: <%= @warning_text || "white" %>;
2015-07-29 09:31:34 -07:00
// INFO COLOR
2015-08-24 22:18:01 -07:00
$info_color: <%= @info_color || "#9954BB" %>;
$info_border: <%= @info_border || "darken(adjust-hue(#9954BB, -10), 5%)" %>;
$info_text: <%= @info_text || "white" %>;
2015-07-29 09:31:34 -07:00
// DEFAULT COLOR
$default_color: <%= @default_color || "#222222" %>;
2015-08-24 22:18:01 -07:00
$default_border: <%= @default_border || "darken(adjust-hue(#222222, -10), 5%)" %>;
$default_text: <%= @default_text || "#eeeeee" %>;
2015-07-29 09:31:34 -07:00
2015-08-24 22:18:01 -07:00
// PANEL COLOR
$panel_color: <%= @panel_color || "#F9F9F9" %>;
$panel_border: <%= @panel_border || "darken(adjust-hue(#F9F9F9, -10), 5%)" %>;
$panel_text: <%= @panel_text || "#151515" %>;
2015-07-29 09:31:34 -07:00
// AUXILIARY COLOR
2015-08-24 22:18:01 -07:00
$link_color: <%= @link_color || "#5e35b1" %>;
$background_color: <%= @background_color || "#ffffff" %>;
$background_text: <%= @background_text || "#222222" %>;
2015-07-29 09:31:34 -07:00
$background_muted: <%= @background_muted || "#bbbbbb" %>;
body#version1 {
a, {
&, &:hover, &:active {
2015-07-29 09:31:34 -07:00
color: $link_color;
}
}
hr, .locales #locales-panel ul {
border-color: $link_color;
}
2015-07-29 09:31:34 -07:00
background-color: $background_color;
color: $background_text;
// Navigation
2015-07-29 09:31:34 -07:00
nav.navbar {
// Nav Dropdown
2015-07-29 09:31:34 -07:00
&, .dropdown-menu {
background-color: $primary_color;
border-color: $primary_border;
2015-08-24 22:18:01 -07:00
border-top: none;
color: $primary_text;
2015-08-24 22:18:01 -07:00
.media, .dropdown-header {
color: $primary_text;
}
> li.divider {
background-color: $primary_border;
}
> li {
> a:hover {
2015-08-24 22:18:01 -07:00
background-color: mix($primary_color, $primary_text, 80%);
}
a {
&, &:hover, &:active {
color: $primary_text;
}
}
}
2015-07-29 09:31:34 -07:00
}
// Nav Links
2015-07-29 09:31:34 -07:00
a {
&, &:hover, &:active {
2015-07-29 09:31:34 -07:00
color: $primary_text;
}
}
li:not(.profile--image-dropdown):before {
background-color: $primary_text;
2015-07-29 09:31:34 -07:00
}
}
// Notifications
.media, #notifications .list-group-item {
2015-08-24 22:18:01 -07:00
color: $panel_text;
background: $panel_color;
}
.media {
background: transparent;
}
// Headers
2015-07-29 09:31:34 -07:00
.j2-jumbo {
background-color: $primary_color;
border-color: $primary_border;
}
#profile--header.profile--no-header:before, .userbox--no-header:before {
content: "";
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
2015-08-24 22:18:01 -07:00
background: $primary_color;
2015-07-29 09:31:34 -07:00
img {
opacity: 0;
}
}
.userbox--no-header, .panel-body {
position: relative;
}
// Panels, and modals
.panel, .modal-dialog {
2015-08-24 22:18:01 -07:00
border-color: $panel_border;
.panel-heading, .panel-footer, .panel-body, .modal-header, .modal-footer, .modal-body, .modal-content {
2015-08-24 22:18:01 -07:00
color: $panel_text;
}
2015-08-24 22:18:01 -07:00
a, a:hover, a:active {
color: $panel_text;
}
.answerbox--question-user, .answerbox--question-text, .answerbox--answer-user, .answerbox--answer-text {
color: $panel_text;
&.text-muted {
color: mix($panel_text, $background_muted, 70%);
}
}
select {
2015-08-24 22:18:01 -07:00
background-color: $panel_color;
border-color: $panel_border;
}
.input-group-addon {
2015-08-24 22:18:01 -07:00
background: $panel_color;
border: $panel_color;
}
&, .panel-heading, .panel-footer, .modal-header, .modal-footer {
2015-08-24 22:18:01 -07:00
background-color: mix($panel_color, $panel_text, 90%);
border-color: mix($panel_color, $panel_text, 85%);
}
.panel-body, .modal-body, .modal-content {
2015-08-24 22:18:01 -07:00
background-color: $panel_color;
}
}
// Non-navigation dropdowns
.dropdown-menu {
2015-08-24 22:18:01 -07:00
background-color: $panel_color;
border-color: $panel_border;
color: $panel_text;
> li.divider {
2015-08-24 22:18:01 -07:00
background-color: $panel_border;
}
> li {
> a:hover {
2015-08-24 22:18:01 -07:00
background-color: mix($panel_color, $panel_text, 90%);
}
a {
&, &:hover, &:active {
2015-08-24 22:18:01 -07:00
color: $panel_text;
}
}
}
}
.text-muted {
color: $background_muted;
}
// Tabs
.nav-tabs {
border-color: transparent;
margin-top: -1px;
2015-07-29 09:31:34 -07:00
li.active a, li:active a, li:hover a {
2015-08-24 22:18:01 -07:00
background: mix($panel_color, $panel_text, 90%);
color: mix($panel_text, $panel_color, 90%);
2015-07-29 09:31:34 -07:00
}
}
// Lists
.list-group .list-group-item {
2015-08-24 22:18:01 -07:00
background-color: $panel_color;
color: $panel_text;
border-color: $panel_border;
.badge {
2015-08-24 22:18:01 -07:00
background-color: $panel_text;
border-color: $panel_border;
color: $panel_color;
}
2015-08-24 22:18:01 -07:00
&.active, &:hover {
background-color: $primary_color;
color: $primary_text;
border-color: $primary_border;
.badge {
background-color: $primary_text;
border-color: $primary_border;
color: $primary_color;
}
}
2015-07-29 09:31:34 -07:00
}
// ERB magic for generics because i'm lazy.
<%
for color in %W(primary danger success warning info default)
%>
.btn-<%= color %>, .alert-<%= color %>, .label-<%= color %>, .panel-badge-<%= color %>, .badge-<%= color %>, .list-group-item-<%= color %> {
color: $<%= color %>_text !important;
background-color: $<%= color %>_color !important;
border-color: $<%= color %>_border !important;
.badge {
color: $<%= color %>_color !important;
background-color: $<%= color %>_text !important;
border-color: $<%= color %>_border !important;
}
}
.btn-<%= color %>:hover {
background-color: mix($<%= color %>_color, $<%= color %>_text, 90%) !important;
}
<%
end
%>
// Reset debug
2015-07-29 09:31:34 -07:00
#debug {
background: white;
color: black;
2015-08-24 22:18:01 -07:00
hr {
background-color: inherit;
border-color: inherit;
}
2015-07-29 09:31:34 -07:00
}
}
/* nprogress */
$nprogress-color: lighten($primary_color, 25%);
#nprogress {
.bar {
background: $nprogress-color;
}
.peg {
box-shadow: 0 0 10px $nprogress-color, 0 0 5px $nprogress-color;
}
.spinner-icon {
border-top-color: $nprogress-color;
border-left-color: $nprogress-color;
}
}