Update theme from the web app

This commit is contained in:
kolaente 2019-10-30 20:10:17 +01:00
parent 611b91ba5d
commit 98cd2ce807
Signed by: konrad
GPG Key ID: F40E70337AB24C9B
3 changed files with 298 additions and 3 deletions

260
src/_theme.scss Normal file
View File

@ -0,0 +1,260 @@
@import url('/fonts/fonts.css');
@import 'variables';
@import '../../node_modules/bulma/bulma';
*, *:hover, *:active, *:focus{
outline: none;
}
.button {
transition: all $transition;
border: 0;
text-transform: uppercase;
font-size: 0.85rem;
font-weight: bold;
height: 2.648em;
box-shadow: 0.3em 0.3em 1em lighten($dark, 75);
&.is-hovered,
&:hover {
box-shadow: 0.6em 0.6em 1em lighten($dark, 75);
}
&.fullheight{
padding-right: 7px;
height: 100%;
}
&.is-active,
&.is-focused,
&:active,
&:focus,
&:focus:not(:active) {
box-shadow: 0.1em 0.1em 0.7em lighten($dark, 75) !important;
}
&.icon-only{
padding-left: 16px;
}
@each $name, $pair in $colors {
$color: nth($pair, 1);
&.is-#{$name} {
box-shadow: 0.3em 0.3em 1em lighten($color, 30);
&.is-hovered,
&:hover {
box-shadow: 0.6em 0.6em 1em lighten($color, 30);
}
&.is-active,
&.is-focused,
&:active,
&:focus,
&:focus:not(:active) {
box-shadow: 0.1em 0.1em 0.7em lighten($color, 30) !important;
}
}
}
&.noshadow{
&,
&.is-hovered,
&:hover,
&.is-active,
&.is-focused,
&:active,
&:focus,
&:focus:not(:active) {
box-shadow: none;
}
}
}
.input,
.textarea {
transition: all $transition;
box-shadow: none;
&.is-active,
&.is-focused,
&:active,
&:focus {
box-shadow: none;
}
@each $name, $pair in $colors {
$color: nth($pair, 1);
$color-invert: nth($pair, 2);
&.is-#{$name} {
&.is-active,
&.is-focused,
&:active,
&:focus,
&:focus:not(:active) {
border-color: darken($color, 10);
}
}
}
}
.select:after {
margin-top: -0.575em;
}
.select select {
border-width: $thickness;
&:not([multiple]) {
height: calc(2.25em + #{$thickness});
}
&.is-active,
&.is-focused,
&:active,
&:focus,
&:focus:not(:active) {
box-shadow: none;
}
}
.field.has-addons {
.control .select select {
height: 2.25em;
}
}
.notification {
border: $thickness solid $border;
@each $name, $pair in $colors {
$color: nth($pair, 1);
&.is-#{$name} {
border-color: darken($color, 5);
}
}
}
.progress {
border-radius: $radius-large;
}
.card {
background-color: rgba($grey-lighter, 0.075);
border-radius: $radius;
margin-bottom: 1rem;
.card-image {
img {
border-radius: $radius $radius 0 0;
}
}
.card-header {
box-shadow: none;
border-bottom: 1px solid $grey-lighter;
border-radius: $radius $radius 0 0;
}
}
.box,.card{
border: $thickness solid $border;
box-shadow: 0.3em 0.3em 0.8em darken($light, 6);
}
.message {
.message-body {
border: $thickness solid;
}
}
.hero {
.navbar {
border: none;
box-shadow: none;
}
@each $name, $pair in $colors {
$color: nth($pair, 1);
$color-invert: nth($pair, 2);
&.is-#{$name} {
.navbar {
box-shadow: none;
}
}
}
@include touch {
.navbar-menu {
box-shadow: none;
}
}
}
.navbar {
z-index: 2;
@each $name, $pair in $colors {
$color: nth($pair, 1);
$color-invert: nth($pair, 2);
&.is-#{$name} {
border-color: darken($color, 5);
}
}
.navbar-dropdown {
box-shadow: $navbar-dropdown-boxed-shadow;
top: 101%;
}
}
.pagination-link,
.pagination-next,
.pagination-previous {
border-width: $thickness;
}
h1,h2,h3,h4,h5,h6{
font-family: $vikunja-font;
font-weight: 400 !important;
}
.bigbuttons{
margin-top: 0.5rem;
}
.control.has-icons-left .icon, .control.has-icons-right .icon {
z-index: 0;
}
.buttonright {
margin-right: 0.5rem;
}
.navbar.main-theme {
background: $light-background;
z-index: 5 !important;
@media screen and (max-width: $desktop) {
display: flex;
justify-content: space-between;
@media screen and (max-width: $tablet) {
.navbar-brand {
margin-left: 3em;
}
}
@media screen and (max-width: 640px) { // Magic number to hide the username if it would take too much space otherwise
.user {
width: 7em;
.username {
display: none;
}
}
}
}
}

37
src/_variables.scss Normal file
View File

@ -0,0 +1,37 @@
$black: hsl(0, 0%, 4%) !default
$orange: #ff851b;
$green: #00CE6E;
$blue: #5974d9;
$red: #ff4136;
$primary: #198CFF !default;
$dark: lighten($black, 8);
$info-invert: #fff;
$family-sans-serif: 'Open Sans', Helvetica, Arial, sans-serif;
$thickness: 1px;
$pagination-current-border: darken($primary, 5);
$navbar-item-active-color: $primary;
$dropdown-content-shadow: none;
$navbar-dropdown-boxed-shadow: $dropdown-content-shadow;
$bulmaswatch-import-font: false !default;
$light-background: #F1F5F8;
$transition-duration: 100ms;
$vikunja-font: 'Quicksand', sans-serif;
$vikunja-light-text: darken(#fff, 10%);
$vikunja-blue: #7F23FF;// #7F23FF; // #5974d9
$vikunja-green: #4DB788;
$navbar-padding: 2em;
$vikunja-nav-background: $light-background;
$vikunja-nav-color: lighten($black, 25);
$vikunja-nav-selected-width: 0.4em;
$transition: 150ms ease;
$scrollbar-height: 8px;
$scrollbar-track-color: lighten($dark, 65);
$scrollbar-thumb-color: lighten($dark, 40);
$scrollbar-hover-color: lighten($dark, 30);

View File

@ -2,9 +2,7 @@
outline: none;
}
@import '../node_modules/bulmaswatch/lumen/variables';
@import "../node_modules/bulma/bulma";
@import '../node_modules/bulmaswatch/lumen/overrides';
@import 'theme';
@import url('../fonts/fonts.css');