guy 4 years ago
parent
commit
0be831e36d
  1. 4
      src/core/wrapper/layout/flex/flex.horizontal.js
  2. 4
      src/core/wrapper/layout/flex/flex.vertical.js
  3. 4
      src/core/wrapper/layout/flex/wrapper/flex.wrapper.horizontal.js
  4. 4
      src/core/wrapper/layout/flex/wrapper/flex.wrapper.vertical.js
  5. 38
      src/less/core/wrapper/flex.horizontal.less
  6. 38
      src/less/core/wrapper/flex.vertical.less
  7. 38
      src/less/core/wrapper/flex.wrapper.horizontal.less
  8. 38
      src/less/core/wrapper/flex.wrapper.vertical.less

4
src/core/wrapper/layout/flex/flex.horizontal.js

@ -34,7 +34,9 @@ BI.FlexHorizontalLayout = BI.inherit(BI.Layout, {
w.element.css({ w.element.css({
position: "relative" position: "relative"
}); });
if (o.horizontalAlign !== BI.HorizontalAlign.Stretch && o.columnSize[i] !== "auto") { if (o.horizontalAlign === BI.HorizontalAlign.Stretch && o.columnSize[i] !== "") {
w.element.addClass("fill");
} else {
w.element.addClass("shrink-none"); w.element.addClass("shrink-none");
} }
if (o.columnSize[i] > 0) { if (o.columnSize[i] > 0) {

4
src/core/wrapper/layout/flex/flex.vertical.js

@ -33,7 +33,9 @@ BI.FlexVerticalLayout = BI.inherit(BI.Layout, {
w.element.css({ w.element.css({
position: "relative" position: "relative"
}); });
if (o.verticalAlign !== BI.VerticalAlign.Stretch && o.rowSize[i] !== "auto") { if (o.verticalAlign === BI.VerticalAlign.Stretch && o.rowSize[i] !== "") {
w.element.addClass("fill");
} else {
w.element.addClass("shrink-none"); w.element.addClass("shrink-none");
} }
if (o.rowSize[i] > 0) { if (o.rowSize[i] > 0) {

4
src/core/wrapper/layout/flex/wrapper/flex.wrapper.horizontal.js

@ -35,7 +35,9 @@ BI.FlexWrapperHorizontalLayout = BI.inherit(BI.Layout, {
w.element.css({ w.element.css({
position: "relative" position: "relative"
}); });
if (o.horizontalAlign !== BI.HorizontalAlign.Stretch && o.columnSize[i] !== "auto") { if (o.horizontalAlign === BI.HorizontalAlign.Stretch && o.columnSize[i] !== "") {
w.element.addClass("fill");
} else {
w.element.addClass("shrink-none"); w.element.addClass("shrink-none");
} }
if (o.columnSize[i] > 0) { if (o.columnSize[i] > 0) {

4
src/core/wrapper/layout/flex/wrapper/flex.wrapper.vertical.js

@ -35,7 +35,9 @@ BI.FlexWrapperVerticalLayout = BI.inherit(BI.Layout, {
w.element.css({ w.element.css({
position: "relative" position: "relative"
}); });
if (o.verticalAlign !== BI.VerticalAlign.Stretch && o.rowSize[i] !== "auto") { if (o.verticalAlign === BI.VerticalAlign.Stretch && o.rowSize[i] !== "") {
w.element.addClass("fill");
} else {
w.element.addClass("shrink-none"); w.element.addClass("shrink-none");
} }
if (o.rowSize[i] > 0) { if (o.rowSize[i] > 0) {

38
src/less/core/wrapper/flex.horizontal.less

@ -119,44 +119,6 @@
flex-direction: row-reverse; flex-direction: row-reverse;
} }
&.h-stretch {
.vertical();
/* 09版 */
-webkit-box-align: stretch;
/* 12版 */
-webkit-align-items: stretch;
-moz-align-items: stretch;
-ms-align-items: stretch;
-ms-flex-align: stretch;
-o-align-items: stretch;
align-items: stretch;
&.v-middle {
/* 09版 */
-webkit-box-pack: center;
/* 12版 */
-webkit-justify-content: center;
-moz-justify-content: center;
-ms-justify-content: center;
-o-justify-content: center;
-ms-flex-pack: center;
justify-content: center;
}
&.v-bottom {
/* 09版 */
-webkit-box-pack: flex-end;
/* 12版 */
-webkit-justify-content: flex-end;
-moz-justify-content: flex-end;
-ms-justify-content: flex-end;
-o-justify-content: flex-end;
-ms-flex-pack: flex-end;
justify-content: flex-end;
}
}
> .shrink-none { > .shrink-none {
-webkit-flex-shrink: 0; -webkit-flex-shrink: 0;
-moz-flex-shrink: 0; -moz-flex-shrink: 0;

38
src/less/core/wrapper/flex.vertical.less

@ -118,44 +118,6 @@
flex-direction: column-reverse; flex-direction: column-reverse;
} }
&.v-stretch {
.horizontal();
/* 09版 */
-webkit-box-align: stretch;
/* 12版 */
-webkit-align-items: stretch;
-moz-align-items: stretch;
-ms-align-items: stretch;
-ms-flex-align: stretch;
-o-align-items: stretch;
align-items: stretch;
&.h-center {
/* 09版 */
-webkit-box-pack: center;
/* 12版 */
-webkit-justify-content: center;
-moz-justify-content: center;
-ms-justify-content: center;
-ms-flex-pack: center;
-o-justify-content: center;
justify-content: center;
}
&.h-right {
/* 09版 */
-webkit-box-pack: flex-end;
/* 12版 */
-webkit-justify-content: flex-end;
-moz-justify-content: flex-end;
-ms-justify-content: flex-end;
-ms-flex-pack: flex-end;
-o-justify-content: flex-end;
justify-content: flex-end;
}
}
> .shrink-none { > .shrink-none {
-webkit-flex-shrink: 0; -webkit-flex-shrink: 0;
-moz-flex-shrink: 0; -moz-flex-shrink: 0;

38
src/less/core/wrapper/flex.wrapper.horizontal.less

@ -126,44 +126,6 @@
flex-direction: row-reverse; flex-direction: row-reverse;
} }
&.h-stretch {
.vertical();
/* 09版 */
-webkit-box-align: stretch;
/* 12版 */
-webkit-align-items: stretch;
-moz-align-items: stretch;
-ms-align-items: stretch;
-ms-flex-align: stretch;
-o-align-items: stretch;
align-items: stretch;
&.v-middle {
/* 09版 */
-webkit-box-pack: center;
/* 12版 */
-webkit-justify-content: center;
-moz-justify-content: center;
-ms-justify-content: center;
-ms-flex-pack: center;
-o-justify-content: center;
justify-content: center;
}
&.v-bottom {
/* 09版 */
-webkit-box-pack: flex-end;
/* 12版 */
-webkit-justify-content: flex-end;
-moz-justify-content: flex-end;
-ms-justify-content: flex-end;
-ms-flex-pack: end;
-o-justify-content: flex-end;
justify-content: flex-end;
}
}
> .shrink-none { > .shrink-none {
-webkit-flex-shrink: 0; -webkit-flex-shrink: 0;
-moz-flex-shrink: 0; -moz-flex-shrink: 0;

38
src/less/core/wrapper/flex.wrapper.vertical.less

@ -126,44 +126,6 @@
flex-direction: column-reverse; flex-direction: column-reverse;
} }
&.v-stretch {
.horizontal();
/* 09版 */
-webkit-box-align: stretch;
/* 12版 */
-webkit-align-items: stretch;
-moz-align-items: stretch;
-ms-align-items: stretch;
-ms-flex-align: stretch;
-o-align-items: stretch;
align-items: stretch;
&.h-center {
/* 09版 */
-webkit-box-pack: center;
/* 12版 */
-webkit-justify-content: center;
-moz-justify-content: center;
-ms-justify-content: center;
-ms-flex-pack: center;
-o-justify-content: center;
justify-content: center;
}
&.h-right {
/* 09版 */
-webkit-box-pack: flex-end;
/* 12版 */
-webkit-justify-content: flex-end;
-moz-justify-content: flex-end;
-ms-justify-content: flex-end;
-ms-flex-pack: flex-end;
-o-justify-content: flex-end;
justify-content: flex-end;
}
}
> .shrink-none { > .shrink-none {
-webkit-flex-shrink: 0; -webkit-flex-shrink: 0;
-moz-flex-shrink: 0; -moz-flex-shrink: 0;

Loading…
Cancel
Save