Style fixes

This commit is contained in:
Juan Ferrer 2019-02-13 14:01:37 +01:00
parent d65a6fd59e
commit 1f759b6b8c
21 changed files with 126 additions and 141 deletions

21
Jenkinsfile vendored
View File

@ -15,7 +15,7 @@ pipeline {
stage('Checkout') { stage('Checkout') {
steps { steps {
script { script {
env.COMPOSE_PROJECT_NAME = env.JOB_NAME.replace('/', '-'); env.COMPOSE_PROJECT_NAME = env.JOB_NAME.replace('/', '-')
env.GIT_COMMITTER_EMAIL = sh( env.GIT_COMMITTER_EMAIL = sh(
script: 'git --no-pager show -s --format="%ae"', script: 'git --no-pager show -s --format="%ae"',
returnStdout: true returnStdout: true
@ -24,21 +24,24 @@ pipeline {
switch (env.BRANCH_NAME) { switch (env.BRANCH_NAME) {
case 'master': case 'master':
env.PORT = 5002 env.PORT = 5002
break; break
case 'test': case 'test':
env.PORT = 5001 env.PORT = 5001
break; break
case 'test':
env.PORT = 5000
break
} }
switch (env.BRANCH_NAME) { switch (env.BRANCH_NAME) {
case 'master': case 'master':
env.NODE_ENV = 'production' env.NODE_ENV = 'production'
break; break
case 'test': case 'test':
env.NODE_ENV = 'test' env.NODE_ENV = 'test'
break; break
case 'dev': case 'dev':
env.NODE_ENV = 'development' env.NODE_ENV = 'development'
break; break
} }
} }
echo "Committer: ${env.GIT_COMMITTER_EMAIL}" echo "Committer: ${env.GIT_COMMITTER_EMAIL}"
@ -57,7 +60,7 @@ pipeline {
} }
stage('Test') { stage('Test') {
when { when {
branch 'dev'; branch 'dev'
} }
environment { environment {
NODE_ENV = "" NODE_ENV = ""

View File

@ -22,7 +22,7 @@
& > div { & > div {
position: relative; position: relative;
box-shadow: 0 0 .4em $color-shadow; box-shadow: 0 0 .4em $color-shadow;
background-color: white; background-color: $color-bg-panel;
border-radius: .2em; border-radius: .2em;
overflow: auto; overflow: auto;
padding: 2em; padding: 2em;

View File

@ -6,7 +6,7 @@ export default class IconButton {
if ($element[0].getAttribute('tabindex') == null) if ($element[0].getAttribute('tabindex') == null)
$element[0].tabIndex = 0; $element[0].tabIndex = 0;
$element.on("keyup", event => this.onKeyDown(event, $element)); $element.on('keyup', event => this.onKeyDown(event, $element));
let button = $element[0].querySelector('button'); let button = $element[0].querySelector('button');
$element[0].addEventListener('click', event => { $element[0].addEventListener('click', event => {
if (this.disabled || button.disabled) if (this.disabled || button.disabled)

View File

@ -3,16 +3,20 @@
vn-icon-button { vn-icon-button {
outline: 0; outline: 0;
color: $color-main; color: $color-main;
display: inline-block;
button { & > button {
background: transparent !important; background-color: transparent;
background-color: transparent !important; display: block;
display: inline-block;
color: inherit; color: inherit;
border: 0; border: 0;
padding: .25em;
&.mdl-button--colored { &:hover {
color: inherit; background-color: initial;
}
& > vn-icon {
display: block;
} }
} }
} }

View File

@ -15,7 +15,7 @@ vn-table {
display: table-header-group; display: table-header-group;
border-bottom: .15em solid $color-spacer; border-bottom: .15em solid $color-spacer;
vn-th[field] { & > * > vn-th[field] {
position: relative; position: relative;
overflow: visible; overflow: visible;
cursor: pointer; cursor: pointer;
@ -49,17 +49,22 @@ vn-table {
border-top: .15em solid $color-spacer; border-top: .15em solid $color-spacer;
display: table-footer-group display: table-footer-group
} }
vn-tr, a.vn-tr { & > * > vn-tr,
& > * > a.vn-tr {
display: table-row display: table-row
} }
vn-thead, vn-tbody, vn-tfoot { vn-thead, vn-tbody, vn-tfoot {
& > * { & > * {
display: table-row; display: table-row;
vn-th { & > vn-th {
font-weight: bold font-weight: bold;
padding-top: 1em;
padding-bottom: .8em;
} }
vn-td, vn-th, vn-td-editable { & > vn-th,
& > vn-td,
& > vn-td-editable {
vertical-align: middle; vertical-align: middle;
display: table-cell; display: table-cell;
text-align: left; text-align: left;
@ -87,11 +92,6 @@ vn-table {
color: #f7931e; color: #f7931e;
} }
} }
vn-th {
font-weight: bold;
padding-top: 1em;
padding-bottom: .8em;
}
& > :last-child { & > :last-child {
padding-right: 1em; padding-right: 1em;
} }
@ -99,18 +99,13 @@ vn-table {
padding-left: 1em; padding-left: 1em;
} }
} }
a.vn-tr { & > a.vn-tr {
color: inherit; color: inherit;
} }
} }
vn-tbody > * { vn-tbody > * {
border-bottom: .1em solid $color-spacer-light; border-bottom: .1em solid $color-spacer-light;
&,
& > vn-td,
& > vn-td > .chip {
transition: background-color 200ms ease-in-out;
}
&:last-child { &:last-child {
border-bottom: none; border-bottom: none;
} }
@ -124,37 +119,44 @@ vn-table {
&.notice, &.notice,
& > .notice, & > .notice,
& > vn-td > .notice { & > vn-td > .notice {
color: white; color: $color-font-bg;
background-color: $color-notice; background-color: $color-notice-medium;
} }
&.success, &.success,
& > .success, & > .success,
& > vn-td > .success { & > vn-td > .success {
color: white; color: $color-font-bg;
background-color: $color-success; background-color: $color-success-medium;
} }
&.warning, &.warning,
& > .warning, & > .warning,
& > vn-td > .warning { & > vn-td > .warning {
color: white; color: $color-font-bg;
background-color: $color-main; background-color: $color-main-medium;
} }
&.alert, &.alert,
& > .alert, & > .alert,
& > vn-td > .alert { & > vn-td > .alert {
color: white; color: $color-font-bg;
background-color: $color-alert; background-color: $color-alert-medium;
}
& > [actions] {
width: 1px;
& > * {
vertical-align: middle;
}
} }
} }
} & > vn-empty-rows {
vn-empty-rows { display: table-caption;
display: table-caption; caption-side: bottom;
caption-side: bottom; text-align: center;
text-align: center; padding: 1.5em;
padding: 1.5em; width: 100%;
width: 100%; box-sizing: border-box;
box-sizing: border-box; color: $color-font-secondary;
color: $color-font-secondary; }
} }
vn-autocomplete { vn-autocomplete {
div.mdl-textfield { div.mdl-textfield {

View File

@ -24,7 +24,7 @@ vn-home {
overflow:hidden; overflow:hidden;
border-radius: 6px; border-radius: 6px;
background-color: $color-main; background-color: $color-main;
color: white; color: $color-font-dark;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
height: 8em; height: 8em;
@ -54,7 +54,7 @@ vn-home {
text-overflow: ellipsis; text-overflow: ellipsis;
white-space: nowrap; white-space: nowrap;
overflow: hidden; overflow: hidden;
color: white; color: inherit;
margin: 0; margin: 0;
/* & > .bind-letter { /* & > .bind-letter {

View File

@ -1,4 +1,5 @@
@import "effects"; @import "effects";
@import "variables";
vn-main-menu { vn-main-menu {
display: flex; display: flex;
@ -31,7 +32,7 @@ vn-main-menu {
vn-menu.vn-popover > div > div.content > ul { vn-menu.vn-popover > div > div.content > ul {
list-style-type: none; list-style-type: none;
margin: 0; margin: 0;
color: white; color: $color-font-dark;
& > li { & > li {
@extend %clickable-light; @extend %clickable-light;

View File

@ -2,7 +2,7 @@
vn-topbar { vn-topbar {
display: flex; display: flex;
color: white; color: $color-font-dark;
box-sizing: border-box; box-sizing: border-box;
background-color: $color-header; background-color: $color-header;
align-items: center; align-items: center;

View File

@ -8,10 +8,9 @@
& > .header { & > .header {
display: flex; display: flex;
background: $color-main; background: $color-main;
color: white;
justify-content: space-between; justify-content: space-between;
align-items: stretch; align-items: stretch;
color: white; color: $color-font-dark;
& > * { & > * {
min-width: 1.8em; min-width: 1.8em;

View File

@ -20,7 +20,7 @@ input[type=reset]::-moz-focus-inner {
} }
a , .link{ a , .link{
color: $color-main; color: $color-font-link;
text-decoration: none; text-decoration: none;
} }
.link { .link {
@ -148,11 +148,9 @@ vn-tool-bar {
max-width: 36em; max-width: 36em;
margin: 0 auto; margin: 0 auto;
} }
a.vn-list-item { a.vn-list-item {
@extend %clickable; @extend %clickable;
} }
.vn-list-item { .vn-list-item {
padding: $pad-medium; padding: $pad-medium;
border-bottom: $border-thin solid $color-spacer-light; border-bottom: $border-thin solid $color-spacer-light;
@ -180,7 +178,13 @@ a.vn-list-item {
} }
} }
} }
} }
}
vn-empty-rows.vn-list-item {
text-align: center;
padding: 1.5em;
box-sizing: border-box;
color: $color-font-secondary;
} }
/** START - FORM ELEMENTS DISABLED **/ /** START - FORM ELEMENTS DISABLED **/

View File

@ -9,7 +9,7 @@
padding: $pad-small; padding: $pad-small;
border: none; border: none;
background: $color-main; background: $color-main;
color: white; color: $color-font-dark;
margin: 0; margin: 0;
text-align: center; text-align: center;
line-height: 1.3em; line-height: 1.3em;

View File

@ -28,8 +28,10 @@ $border-thick: .15em;
$color-header: #3d3d3d; $color-header: #3d3d3d;
$color-bg: #e5e5e5; $color-bg: #e5e5e5;
$color-bg-dark: #3d3d3d; $color-bg-dark: #3d3d3d;
$color-font:#222222; $color-font: #222222;
$color-font-secondary: #9b9b9b; $color-font-secondary: #9b9b9b;
$color-font-dark: white;
$color-font-bg: rgba(0, 0, 0, .7);
$color-active: #3d3d3d; $color-active: #3d3d3d;
$color-active-font: white; $color-active-font: white;
$color-bg-panel: white; $color-bg-panel: white;
@ -47,6 +49,7 @@ $color-hover-cd: rgba(0, 0, 0, .1);
$color-hover-dc: .7; $color-hover-dc: .7;
$color-disabled: .6; $color-disabled: .6;
$color-font-link: darken($color-main, 10%);
$color-main-medium: lighten($color-main, 20%); $color-main-medium: lighten($color-main, 20%);
$color-main-light: lighten($color-main, 35%); $color-main-light: lighten($color-main, 35%);
$color-success-medium: lighten($color-success, 20%); $color-success-medium: lighten($color-success, 20%);
@ -63,6 +66,8 @@ $color-bg: #222;
$color-bg-dark: #222; $color-bg-dark: #222;
$color-font: white; $color-font: white;
$color-font-secondary: #777; $color-font-secondary: #777;
$color-font-dark: white;
$color-font-bg: rgba(0, 0, 0, .8);
$color-active: #666; $color-active: #666;
$color-active-font: white; $color-active-font: white;
$color-bg-panel: #3c3b3b; $color-bg-panel: #3c3b3b;
@ -80,6 +85,7 @@ $color-hover-cd: rgba(255, 255, 255, .1);
$color-hover-dc: .7; $color-hover-dc: .7;
$color-disabled: .6; $color-disabled: .6;
$color-font-link: lighten($color-main, 10%);
$color-main-medium: darken($color-main, 20%); $color-main-medium: darken($color-main, 20%);
$color-main-light: darken($color-main, 35%); $color-main-light: darken($color-main, 35%);
$color-success-medium: darken($color-success, 20%); $color-success-medium: darken($color-success, 20%);

View File

@ -115,7 +115,7 @@ async function backTestDocker() {
if (argv['random']) if (argv['random'])
await execP(`docker rm -fv ${containerId}`); await execP(`docker rm -fv ${containerId}`);
} }
backTestDocker.description = `Runs backend tests using in site container`; backTestDocker.description = `Runs backend tests restoring fixtures first`;
function backTest(done) { function backTest(done) {
const nodemon = require('gulp-nodemon'); const nodemon = require('gulp-nodemon');

View File

@ -22,11 +22,11 @@
ng-repeat="client in clients track by client.id" ng-repeat="client in clients track by client.id"
client="::client"> client="::client">
</vn-item-client> </vn-item-client>
<vn-empty-rows class="vn-list-item" style="text-align: center" <vn-empty-rows class="vn-list-item"
ng-if="model.data.length === 0" translate> ng-if="model.data.length === 0" translate>
No results No results
</vn-empty-rows> </vn-empty-rows>
<vn-empty-rows class="vn-list-item" style="text-align: center" <vn-empty-rows class="vn-list-item"
ng-if="model.data === null" translate> ng-if="model.data === null" translate>
Enter a new search Enter a new search
</vn-empty-rows> </vn-empty-rows>

View File

@ -5,7 +5,7 @@ vn-item-product {
.id { .id {
background-color: $color-main; background-color: $color-main;
color: white; color: $color-font-dark;
margin-bottom: 0em; margin-bottom: 0em;
} }
.image { .image {

View File

@ -1,21 +1,23 @@
@import "variables"; @import "variables";
vn-item-last-entries { vn-item-last-entries {
.round { .round {
background-color: $color-spacer; background-color: $color-spacer;
border-radius: 25px; border-radius: 25px;
float: right; float: right;
width: 25px; width: 25px;
color: white; color: $color-font-dark;
text-align: center; text-align: center;
font-weight: bold; font-weight: bold;
} }
& vn-horizontal { vn-horizontal {
justify-content: center; justify-content: center;
} }
& vn-date-picker { vn-date-picker {
flex: none!important; flex: none !important;
& .mdl-textfield{
width: 400px!important; .mdl-textfield{
width: 400px !important;
} }
} }
@media screen and (max-width: 1440px) { @media screen and (max-width: 1440px) {

View File

@ -9,7 +9,7 @@ vn-item-summary {
.item-state { .item-state {
padding: .4em; padding: .4em;
background-color: $color-main; background-color: $color-main;
color: white; color: $color-font-dark;
p { p {
font-size: .8em; font-size: .8em;

View File

@ -1,10 +1,12 @@
@import "variables"; @import "variables";
vn-dialog.modal-form { vn-dialog.modal-form {
vn-horizontal.header{ vn-horizontal.header {
background-color: $color-main; background-color: $color-main;
h5{ color: $color-font-dark;
color: white;
h5 {
color: inherit;
margin: 0 auto; margin: 0 auto;
} }
} }
@ -14,23 +16,22 @@ vn-dialog.modal-form {
table { table {
width: 100% width: 100%
} }
&>div{ & > div {
padding: 0!important; padding: 0 !important;
} }
vn-textfield { vn-textfield {
width: 100%; width: 100%;
} }
.buttons{ .buttons {
margin-top: 0!important; margin-top: 0 !important;
} }
p {
p{
display: none; display: none;
} }
button.close > vn-icon{ button.close > vn-icon {
color: white!important; color: white !important;
} }
vn-ticket-sale-edit-discount > div { vn-ticket-sale-edit-discount > div {
padding-bottom: 0!important; padding-bottom: 0 !important;
} }
} }

View File

@ -82,7 +82,7 @@
<vn-td>{{::ticket.agencyMode}}</vn-td> <vn-td>{{::ticket.agencyMode}}</vn-td>
<vn-td>{{::ticket.warehouse}}</vn-td> <vn-td>{{::ticket.warehouse}}</vn-td>
<vn-td number>{{::ticket.total | currency: 'EUR': 2}}</vn-td> <vn-td number>{{::ticket.total | currency: 'EUR': 2}}</vn-td>
<vn-td shrink> <vn-td actions>
<vn-icon-button <vn-icon-button
ng-click="$ctrl.goToLines($event, ticket.id)" ng-click="$ctrl.goToLines($event, ticket.id)"
vn-tooltip="Go to lines" vn-tooltip="Go to lines"

View File

@ -1,44 +1,11 @@
@import "variables"; @import "variables";
vn-ticket-index{ vn-ticket-index vn-icon-menu {
vn-icon-menu{ padding-top: 30px;
padding-top: 30px; padding-left: 10px;
padding-left: 10px; color: $color-main;
color: $color-main;
li {
color: initial;
}
}
.alert1 { li {
color: white; color: initial;
background-color: $color-main-light;
} }
vn-tr:hover .alert1 { }
background-color: $color-main-medium;
}
.alertOk {
color: white;
background-color: $color-success-light;
}
vn-tr:hover .alertOk {
background-color: $color-success-medium;
}
.alertFree {
color: white;
background-color: $color-notice-light;
}
vn-tr:hover .alertFree {
background-color: $color-notice-medium;
}
.alert0 {
color: white;
background-color: $color-alert-light;
}
vn-tr:hover .alert0 {
background-color: $color-alert-medium;
}
}

View File

@ -1,38 +1,35 @@
@import "variables"; @import "variables";
vn-ticket-sale { vn-ticket-sale {
.header { .header {
justify-content: space-between !important; justify-content: space-between !important;
align-items: center; align-items: center;
} }
vn-popover.edit { vn-popover.edit {
div.popover{ div.popover {
width: 200px; width: 200px;
} }
vn-horizontal.header {
vn-horizontal.header{
background-color: $color-main; background-color: $color-main;
h5{ color: $color-font-dark;
color: white;
h5 {
color: inherit;
margin: 0 auto; margin: 0 auto;
} }
} }
p.simulatorTitle {
p.simulatorTitle{
margin-bottom: 0px; margin-bottom: 0px;
font-size: 12px; font-size: 12px;
color: $color-main; color: $color-main;
} }
vn-label-value {
vn-label-value{
padding-bottom: 20px; padding-bottom: 20px;
} }
div.simulator{ div.simulator{
text-align: center; text-align: center;
} }
} }
vn-dialog.edit { vn-dialog.edit {
@extend vn-popover.edit; @extend vn-popover.edit;
@ -45,8 +42,7 @@ vn-ticket-sale {
.buttons{ .buttons{
margin-top: 0!important; margin-top: 0!important;
} }
p {
p{
display: none; display: none;
} }
button.close > vn-icon{ button.close > vn-icon{