strips: continue refactoring, add spacing option
This commit is contained in:
parent
a60710e246
commit
1304ce2586
9 changed files with 318 additions and 144 deletions
|
|
@ -22,6 +22,7 @@ module.exports = class Strip extends Panel {
|
|||
|
||||
horizontal:false,
|
||||
stretch:false,
|
||||
spacing:0,
|
||||
|
||||
_children:'children',
|
||||
|
||||
|
|
@ -38,6 +39,8 @@ module.exports = class Strip extends Panel {
|
|||
|
||||
super(options)
|
||||
|
||||
this.widget[0].style.setProperty('--spacing', this.getProp('spacing'))
|
||||
|
||||
this.container.addClass(this.getProp('horizontal') ? 'horizontal' : 'vertical')
|
||||
this.container.addClass(this.getProp('stretch') ? 'stretch' : '')
|
||||
|
||||
|
|
|
|||
|
|
@ -7,7 +7,6 @@
|
|||
width: 100rem;
|
||||
height: 120rem;
|
||||
align-items: center;
|
||||
flex-shrink: 0;
|
||||
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -24,6 +24,7 @@
|
|||
min-height: 0;
|
||||
min-width: 0;
|
||||
margin:0!important;
|
||||
height: auto;
|
||||
.label {
|
||||
background:none;
|
||||
border:0;
|
||||
|
|
@ -92,7 +93,6 @@
|
|||
overflow: hidden;
|
||||
.white {
|
||||
--color-light-fg: var(--color-white);
|
||||
height:100%;
|
||||
.light.active:before {
|
||||
opacity: .5;
|
||||
background:var(--color-fg);
|
||||
|
|
|
|||
|
|
@ -1,7 +1,6 @@
|
|||
.xy-container, .rgb-container, .multixy-container {
|
||||
width:200rem;
|
||||
height:250rem;
|
||||
flex-shrink: 0;
|
||||
.label {
|
||||
flex-shrink: 0;
|
||||
box-shadow: 0 -11rem 10rem 10rem var(--color-bg);
|
||||
|
|
|
|||
|
|
@ -73,6 +73,7 @@
|
|||
.strip-container {
|
||||
@extend .panel-container-base;
|
||||
|
||||
|
||||
width: 100rem;
|
||||
height: 100%;
|
||||
&.horizontal {
|
||||
|
|
@ -84,11 +85,12 @@
|
|||
> .panel {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: stretch;
|
||||
padding: calc(var(--spacing) / 2 * 1rem);
|
||||
> .widget {
|
||||
// flex:1;
|
||||
width: auto!important;
|
||||
max-width: 100%;
|
||||
width: 100%;
|
||||
min-height: 0!important;
|
||||
margin: calc(var(--spacing) / 2 * 1rem);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -96,11 +98,13 @@
|
|||
> .panel {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: stretch;
|
||||
padding: calc(var(--spacing) / 2 * 1rem);
|
||||
> .widget {
|
||||
// flex:1;
|
||||
height: 100%;
|
||||
height: auto!important;
|
||||
max-height: 100%;
|
||||
min-width: 0!important;
|
||||
margin: calc(var(--spacing) / 2 * 1rem);
|
||||
}
|
||||
left:29rem;
|
||||
top:-1rem;
|
||||
|
|
|
|||
|
|
@ -1,6 +1,5 @@
|
|||
.switch-container {
|
||||
width:100rem;
|
||||
flex-shrink: 0;
|
||||
.label {
|
||||
border-bottom: 1rem solid var(--color-bg);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,7 +1,6 @@
|
|||
.toggle-container {
|
||||
width:100rem;
|
||||
height: 60rem;
|
||||
flex-shrink: 0;
|
||||
padding:0!important;
|
||||
background: var(--color-light-fg);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue