Browse Source

Pull request #1767: 无JIAR任务 bugfix

Merge in VISUAL/fineui from ~GUY/fineui:master to master

* commit 'fad6851b71cc587afe32e96df75370d793fc6404':
  bugfix
  bugfix
master
guy 4 years ago
parent
commit
0ede3149dc
  1. 2
      src/core/wrapper/layout/flex/flex.center.js
  2. 1
      src/core/wrapper/layout/flex/flex.horizontal.center.js
  3. 6
      src/core/wrapper/layout/flex/flex.horizontal.js
  4. 1
      src/core/wrapper/layout/flex/flex.vertical.center.js
  5. 6
      src/core/wrapper/layout/flex/flex.vertical.js
  6. 2
      src/core/wrapper/layout/flex/wrapper/flex.wrapper.center.js
  7. 1
      src/core/wrapper/layout/flex/wrapper/flex.wrapper.horizontal.center.js
  8. 6
      src/core/wrapper/layout/flex/wrapper/flex.wrapper.horizontal.js
  9. 1
      src/core/wrapper/layout/flex/wrapper/flex.wrapper.vertical.center.js
  10. 6
      src/core/wrapper/layout/flex/wrapper/flex.wrapper.vertical.js
  11. 15
      src/less/core/wrapper/flex.horizontal.less
  12. 15
      src/less/core/wrapper/flex.vertical.less
  13. 15
      src/less/core/wrapper/flex.wrapper.horizontal.less
  14. 15
      src/less/core/wrapper/flex.wrapper.vertical.less

2
src/core/wrapper/layout/flex/flex.center.js

@ -28,6 +28,8 @@ BI.FlexCenterLayout = BI.inherit(BI.Layout, {
}, },
horizontalAlign: o.horizontalAlign, horizontalAlign: o.horizontalAlign,
verticalAlign: o.verticalAlign, verticalAlign: o.verticalAlign,
columnSize: o.columnSize,
rowSize: o.rowSize,
scrollx: o.scrollx, scrollx: o.scrollx,
scrolly: o.scrolly, scrolly: o.scrolly,
scrollable: o.scrollable, scrollable: o.scrollable,

1
src/core/wrapper/layout/flex/flex.horizontal.center.js

@ -28,6 +28,7 @@ BI.FlexHorizontalCenter = BI.inherit(BI.Layout, {
}, },
horizontalAlign: BI.HorizontalAlign.Center, horizontalAlign: BI.HorizontalAlign.Center,
verticalAlign: o.verticalAlign, verticalAlign: o.verticalAlign,
columnSize: o.columnSize,
rowSize: o.rowSize, rowSize: o.rowSize,
scrollx: o.scrollx, scrollx: o.scrollx,
scrolly: o.scrolly, scrolly: o.scrolly,

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

@ -35,15 +35,13 @@ BI.FlexHorizontalLayout = BI.inherit(BI.Layout, {
position: "relative" position: "relative"
}); });
if (o.horizontalAlign !== BI.HorizontalAlign.Stretch && o.columnSize[i] !== "auto") { if (o.horizontalAlign !== BI.HorizontalAlign.Stretch && o.columnSize[i] !== "auto") {
w.element.css({ w.element.addClass("shrink-none");
"flex-shrink": "0"
});
} }
if (o.columnSize[i] > 0) { if (o.columnSize[i] > 0) {
w.element.width(o.columnSize[i] <= 1 ? (o.columnSize[i] * 100 + "%") : (o.columnSize[i] / BI.pixRatio + BI.pixUnit)); w.element.width(o.columnSize[i] <= 1 ? (o.columnSize[i] * 100 + "%") : (o.columnSize[i] / BI.pixRatio + BI.pixUnit));
} }
if (o.columnSize[i] === "fill") { if (o.columnSize[i] === "fill") {
w.element.css("flex", "1"); w.element.addClass("fill");
} }
if (o.vgap + o.tgap + (item.tgap || 0) + (item.vgap || 0) !== 0) { if (o.vgap + o.tgap + (item.tgap || 0) + (item.vgap || 0) !== 0) {
w.element.css({ w.element.css({

1
src/core/wrapper/layout/flex/flex.vertical.center.js

@ -30,6 +30,7 @@ BI.FlexVerticalCenter = BI.inherit(BI.Layout, {
verticalAlign: BI.VerticalAlign.Middle, verticalAlign: BI.VerticalAlign.Middle,
horizontalAlign: o.horizontalAlign, horizontalAlign: o.horizontalAlign,
columnSize: o.columnSize, columnSize: o.columnSize,
rowSize: o.rowSize,
scrollx: o.scrollx, scrollx: o.scrollx,
scrolly: o.scrolly, scrolly: o.scrolly,
scrollable: o.scrollable, scrollable: o.scrollable,

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

@ -34,15 +34,13 @@ BI.FlexVerticalLayout = BI.inherit(BI.Layout, {
position: "relative" position: "relative"
}); });
if (o.verticalAlign !== BI.VerticalAlign.Stretch && o.rowSize[i] !== "auto") { if (o.verticalAlign !== BI.VerticalAlign.Stretch && o.rowSize[i] !== "auto") {
w.element.css({ w.element.addClass("shrink-none");
"flex-shrink": "0"
});
} }
if (o.rowSize[i] > 0) { if (o.rowSize[i] > 0) {
w.element.height(o.rowSize[i] <= 1 ? (o.rowSize[i] * 100 + "%") : (o.rowSize[i] / BI.pixRatio + BI.pixUnit)); w.element.height(o.rowSize[i] <= 1 ? (o.rowSize[i] * 100 + "%") : (o.rowSize[i] / BI.pixRatio + BI.pixUnit));
} }
if (o.rowSize[i] === "fill") { if (o.rowSize[i] === "fill") {
w.element.css("flex", "1"); w.element.addClass("fill");
} }
if (o.vgap + o.tgap + (item.tgap || 0) + (item.vgap || 0) !== 0) { if (o.vgap + o.tgap + (item.tgap || 0) + (item.vgap || 0) !== 0) {
w.element.css({ w.element.css({

2
src/core/wrapper/layout/flex/wrapper/flex.wrapper.center.js

@ -31,6 +31,8 @@ BI.FlexWrapperCenterLayout = BI.inherit(BI.Layout, {
}, },
horizontalAlign: o.horizontalAlign, horizontalAlign: o.horizontalAlign,
verticalAlign: o.verticalAlign, verticalAlign: o.verticalAlign,
columnSize: o.columnSize,
rowSize: o.rowSize,
scrollx: o.scrollx, scrollx: o.scrollx,
scrolly: o.scrolly, scrolly: o.scrolly,
scrollable: o.scrollable, scrollable: o.scrollable,

1
src/core/wrapper/layout/flex/wrapper/flex.wrapper.horizontal.center.js

@ -30,6 +30,7 @@ BI.FlexWrapperHorizontalCenter = BI.inherit(BI.Layout, {
}, },
horizontalAlign: BI.HorizontalAlign.Center, horizontalAlign: BI.HorizontalAlign.Center,
verticalAlign: o.verticalAlign, verticalAlign: o.verticalAlign,
columnSize: o.columnSize,
rowSize: o.rowSize, rowSize: o.rowSize,
scrollx: o.scrollx, scrollx: o.scrollx,
scrolly: o.scrolly, scrolly: o.scrolly,

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

@ -36,15 +36,13 @@ BI.FlexWrapperHorizontalLayout = BI.inherit(BI.Layout, {
position: "relative" position: "relative"
}); });
if (o.horizontalAlign !== BI.HorizontalAlign.Stretch && o.columnSize[i] !== "auto") { if (o.horizontalAlign !== BI.HorizontalAlign.Stretch && o.columnSize[i] !== "auto") {
w.element.css({ w.element.addClass("shrink-none");
"flex-shrink": "0"
});
} }
if (o.columnSize[i] > 0) { if (o.columnSize[i] > 0) {
w.element.width(o.columnSize[i] <= 1 ? (o.columnSize[i] * 100 + "%") : (o.columnSize[i] / BI.pixRatio + BI.pixUnit)); w.element.width(o.columnSize[i] <= 1 ? (o.columnSize[i] * 100 + "%") : (o.columnSize[i] / BI.pixRatio + BI.pixUnit));
} }
if (o.columnSize[i] === "fill") { if (o.columnSize[i] === "fill") {
w.element.css("flex", "1"); w.element.addClass("fill");
} }
if (o.vgap + o.tgap + (item.tgap || 0) + (item.vgap || 0) !== 0) { if (o.vgap + o.tgap + (item.tgap || 0) + (item.vgap || 0) !== 0) {
w.element.css({ w.element.css({

1
src/core/wrapper/layout/flex/wrapper/flex.wrapper.vertical.center.js

@ -31,6 +31,7 @@ BI.FlexWrapperVerticalCenter = BI.inherit(BI.Layout, {
verticalAlign: BI.VerticalAlign.Middle, verticalAlign: BI.VerticalAlign.Middle,
horizontalAlign: o.horizontalAlign, horizontalAlign: o.horizontalAlign,
columnSize: o.columnSize, columnSize: o.columnSize,
rowSize: o.rowSize,
scrollx: o.scrollx, scrollx: o.scrollx,
scrolly: o.scrolly, scrolly: o.scrolly,
scrollable: o.scrollable, scrollable: o.scrollable,

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

@ -36,15 +36,13 @@ BI.FlexWrapperVerticalLayout = BI.inherit(BI.Layout, {
position: "relative" position: "relative"
}); });
if (o.verticalAlign !== BI.VerticalAlign.Stretch && o.rowSize[i] !== "auto") { if (o.verticalAlign !== BI.VerticalAlign.Stretch && o.rowSize[i] !== "auto") {
w.element.css({ w.element.addClass("shrink-none");
"flex-shrink": "0"
});
} }
if (o.rowSize[i] > 0) { if (o.rowSize[i] > 0) {
w.element.height(o.rowSize[i] <= 1 ? (o.rowSize[i] * 100 + "%") : (o.rowSize[i] / BI.pixRatio + BI.pixUnit)); w.element.height(o.rowSize[i] <= 1 ? (o.rowSize[i] * 100 + "%") : (o.rowSize[i] / BI.pixRatio + BI.pixUnit));
} }
if (o.rowSize[i] === "fill") { if (o.rowSize[i] === "fill") {
w.element.css("flex", "1"); w.element.addClass("fill");
} }
if (o.vgap + o.tgap + (item.tgap || 0) + (item.vgap || 0) !== 0) { if (o.vgap + o.tgap + (item.tgap || 0) + (item.vgap || 0) !== 0) {
w.element.css({ w.element.css({

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

@ -156,4 +156,19 @@
justify-content: flex-end; justify-content: flex-end;
} }
} }
> .shrink-none {
-webkit-flex-shrink: 0;
-moz-flex-shrink: 0;
-ms-flex-shrink: 0;
flex-shrink: 0;
}
> .fill {
-webkit-box-flex: 1;
-moz-box-flex: 1;
-webkit-flex: 1;
-ms-flex: 1;
flex: 1;
}
} }

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

@ -155,4 +155,19 @@
justify-content: flex-end; justify-content: flex-end;
} }
} }
> .shrink-none {
-webkit-flex-shrink: 0;
-moz-flex-shrink: 0;
-ms-flex-shrink: 0;
flex-shrink: 0;
}
> .fill {
-webkit-box-flex: 1;
-moz-box-flex: 1;
-webkit-flex: 1;
-ms-flex: 1;
flex: 1;
}
} }

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

@ -163,5 +163,20 @@
justify-content: flex-end; justify-content: flex-end;
} }
} }
> .shrink-none {
-webkit-flex-shrink: 0;
-moz-flex-shrink: 0;
-ms-flex-shrink: 0;
flex-shrink: 0;
}
> .fill {
-webkit-box-flex: 1;
-moz-box-flex: 1;
-webkit-flex: 1;
-ms-flex: 1;
flex: 1;
}
} }
} }

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

@ -163,5 +163,20 @@
justify-content: flex-end; justify-content: flex-end;
} }
} }
> .shrink-none {
-webkit-flex-shrink: 0;
-moz-flex-shrink: 0;
-ms-flex-shrink: 0;
flex-shrink: 0;
}
> .fill {
-webkit-box-flex: 1;
-moz-box-flex: 1;
-webkit-flex: 1;
-ms-flex: 1;
flex: 1;
}
} }
} }

Loading…
Cancel
Save