/ 分列式弹性盒子,以X轴从左到右排列 /
.h-flex-x{
width: 100%;
display: flex;
flex-direction: row;
flex-wrap: nowrap;
justify-content: flex-start;
/align-items: center;/
/#ifdef H5/
padding-top: 3px;
/#endif/
align-content: center;
/* 水平左对齐 */
&.h-flex-left{
justify-content: flex-start;
}
/* 水平居中对齐 */
&.h-flex-center{
justify-content: center;
}
/* 水平右对齐 */
&.h-flex-right{
justify-content: flex-end;
}
/* 水平两端对齐 */
&.h-flex-space{
justify-content: space-between;
}
/* 垂直顶部对齐 */
&.h-flex-top{
align-items: flex-start;
align-content: flex-start;
}
/* 垂直底部对齐 */
&.h-flex-bottom{
align-items: flex-end;
align-content: flex-end;
}
/* 允许换行 */
&.h-flex-wrap{
flex-wrap: wrap;
}
/* 等比分列,2-6列 */
@for $i from 2 through 6
{
&.h-flex-#{$i}{
&>view{
width:(100% / $i);
}
}
}
/* 弹性元素 */
&>.h-flex-item-grow{
flex-grow: 1;
width:0;
}
}
/ 分行式弹性盒子,以Y轴从上到下排列 /
.h-flex-y{
display: flex;
flex-direction: column;
flex-wrap: nowrap;
justify-content: flex-start;
align-items: flex-start;
align-content: flex-start;
/* 垂直居中对齐 */
&.h-flex-center{
justify-content: center;
align-items: center;
align-content: center;
}
/* 水平左对齐 */
&.h-flex-left{
align-items: flex-start;
align-content: flex-start;
}
/* 水平右对齐 */
&.h-flex-right{
align-items: flex-end;
align-content: flex-end;
}
/* 垂直两端对齐 */
&.h-flex-space{
justify-content: space-between;
}
/* 垂直顶部对齐 */
&.h-flex-top{
justify-content: flex-start;
}
/* 垂直底部对齐 */
&.h-flex-bottom{
justify-content: flex-end;
}
/* 等比分行,2-6行 */
@for $i from 2 through 6
{
&.h-flex-#{$i}{
&>view{
height:(100% / $i);
}
}
}
/* 弹性元素 */
&>.h-flex-item-grow{
flex-grow: 1;
height: 0;
}
}
helang-flex.scss
8***@qq.com (作者)
4.45 之前的版本都打包调试都没问题,只有4.55出现这个问题 就是以后的版本都不支持这样了吗?
2025-03-09 22:06
DCloud_heavensoft
回复 8***@qq.com: 你原来是 intel 版还是 arm 版?
2025-03-09 22:34
8***@qq.com (作者)
回复 DCloud_heavensoft: 应该是升级了什么功能导致,4.45之前的版本都正常,我是台式机windows11 属于intel版本吧。主要是说不支持写法了,但是很多项目以前是按这个写的。如果后面不兼容了就都需要重新写,我这个项目好像是用了插件市场里头一个插件采用到了这些写法。如果后续不支持了,那就要考虑重写所有项目,不然都会报错。主要插件市场里头也有好多这样的写法,如果不支持会有很大的兼容问题。
2025-03-09 22:49
DCloud_UNI_FXY
回复 8***@qq.com: 尝试下重新完整安装4.55版本?
2025-03-10 00:11