- generic synchronization between widgets

- added basic maptoscale function
- xy-pad and rgb-pad fully operationnal
 - rgb pad has a tiny glitch (only visual) when synchronizing with another one, due to hsbtorgb conversion choosing wrong hue (if saturation and/or lightness equals zero)
- still improving css (atom style...)
This commit is contained in:
jean-emmanuel 2015-08-18 16:33:42 +02:00 • committed by bordun
parent a83f17c1e7
commit e767fd8af6
3 changed files with 236 additions and 122 deletions

View file

@ -1,7 +1,7 @@
/////////////
$color-text:rgba(white,.9);
$color-text-fade:transparentize($color-text,.5);
$color-text-fade:transparentize($color-text,.4);
$color-title:rgba(white,.05);
@ -245,11 +245,21 @@ a {
width:100%;
-webkit-mask: linear-gradient(to left, rgba(0, 0, 0, 0), #000000 10px) no-repeat;
}
color:$color-text-fade;
&.on {
background:#282c34;
border:1px solid $color-border;
border-bottom-color:$color-fg;
color:$color-text;
&:before {
content:"";
position: absolute;
top:0;
left:0;
right:0;
bottom:0;
background:linear-gradient(rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0))
}
&:after {
content:"";
position:absolute;
@ -257,7 +267,7 @@ a {
left:0;
right:0;
height:4px;
background:linear-gradient(rgba($color-accent,0.25),rgba($color-accent,0))
background:linear-gradient(rgba($color-accent,0.5),rgba($color-accent,0))
}
}
}
@ -275,31 +285,47 @@ a {
top:$nav-height - 4px;
right:0;
bottom:0;
padding:5px;
padding:10px 5px 5px;
border-top:1px solid $color-border;
.tab {
height:100%;
//height:100%;
font-size:0;
position:relative;
//position:relative;
overflow: auto;
}
.content {
border:1px solid $color-border;
top:$nav-height - 9px;
}
}
.tab {
display:none;
display:block;
height:0px;
width: 0px;
overflow: hidden;
&.on {
display: block;
height:100%;
width:auto;
}
}
.test.tab.on {
display:flex;width:100%;
flex-wrap: wrap;
flex-direction:column;
//justify-content: stretch;
> .widget {
height:33.33%;
padding-bottom:10px;
//flex: 1
}
}
// WIDGETS
@ -311,14 +337,12 @@ a {
font-size:13px;
// box-shadow: 0 0 0 1px $color-border;
padding-top:35px;
padding-bottom: 8px;
vertical-align:top;
overflow: hidden;
margin-right: 10px;
.title {
border-bottom:1px solid $color-border;
border-left:0;
border-right:0;
background:$color-title;
padding:10px 10px;
position:absolute;
top:0px;
@ -328,6 +352,8 @@ a {
overflow:hidden;
height:35px;
border-radius:2px 2px 0 0 ;
background:linear-gradient(#3a3f4b, #353b45);
box-shadow: 0 0 0 1px $color-bg inset;
}
input {
width:100%;
@ -362,14 +388,15 @@ $button-size:20px;
.button-wrapper {
height:100%;
overflow:hidden;
padding-left: 10px;
.button {
width:100%;
height:100%;
position:relative;
outline:1px solid $color-bg;
outline-offset: -10px;
background: $color-title;
border: 10px solid $color-fg;
background:linear-gradient(#3a3f4b, #353b45);
box-shadow: 0 0 0 1px $color-bg inset;
&:after{
content:"";
position:absolute;
@ -380,7 +407,6 @@ $button-size:20px;
border-radius:$button-size;
background:$color-bg;
}
&.on:after {
background:$color-accent;
box-shadow:0 0 0 4px rgba(255,255,255,0.1);
@ -416,7 +442,7 @@ width:400px;
}
.stack .widget {
height:70px;
//height:70px;
width:100%;
display:block;
padding:0;
@ -435,25 +461,34 @@ width:400px;
padding:20px 20px;
float:right;
width:70%;
height:70px;
}
.stack .button-wrapper {
float:right;
width:70%;
height:70px;
}
.stack .widget .title {
width:30%;
height:50%;
height:35px;
//border-right:1px solid $color-border;
}
.stack .widget input {
.stack .fader-wrapper-outer input, .stack .button-wrapper input {
width:30%;
height:50%;
height:35px;
left:0;
right:auto;
border-top:0;
//border-right:1px solid $color-border;
}
.stack .xy-wrapper {
float:right;
width:70%;
height:300px;
padding-top:0;
}
/* STRIP (vertical fader) */
.fader-wrapper-outer {
@ -465,10 +500,11 @@ width:400px;
input {
position:absolute;
bottom:0;
box-shadow: 0 0 1px 0 $color-border inset;
}
}
.fader-wrapper {
padding:20px 15px;
padding:20px 15px 20px 20px ;
overflow:hidden;
height:100%;
width:95px;
@ -483,14 +519,27 @@ width:400px;
.xy-wrapper {
width:400px;
padding: 10px;
height:100%;
padding: 10px 10px 140px;
height:540px;
overflow: hidden;
.value {
margin-top:30px;
width:100%;
}
input {
width:50%;
float:left;
padding-left: 20px;
position: relative;
left:0px;
right:0px;
box-shadow: 0 0 1px 0 $color-border inset;
}
}
.xy {
position:relative;
width:100%;
height: 400px;
height: 100%;
border:1px solid $color-border;
background: $color-bg;
overflow: hidden;
@ -542,25 +591,10 @@ width:400px;
}
.rgb-wrapper {
.value {
margin-top:30px;
width:100%;
}
input {
width:33.33%;
float:left;
padding-left: 20px;
position: relative;
left:0px;
right:0px;
&.r:after {
content:"Rzd";
display:block;
position: absolute;;
left:0;
}
}
}