cover-view flex-direction 无效
<map id="map" bindtap="mapTap" latitude="{{lat}}" longitude="{{lon}}" scale="17" controls="{{controls}}" markers="{{markers}}" bindmarkertap="markertap" polyline="{{polyline}}" bindregionchange="regionchange" show-location="true" bindcontroltap='controltap'> <cover-view class="shopInfo" wx:if="{{shopCardModeSatus}}"> <cover-view class="shopInfo-logo"> <cover-image class="shopInfo_logo" src="{{currentShopData.pic_url}}" /> </cover-view> <cover-view class="shopInfo-other"> <cover-view class="shopInfo_name">{{currentShopData.sname}}</cover-view> <cover-view class="shopInfo-item"> <cover-view class="shopInfo-label">地址:</cover-view> <cover-view class="shopInfo-txt">{{currentShopData.address}} | {{currentShopData.distance}}m</cover-view> </cover-view> <cover-view class="shopInfo-item entry-text"> 浏览菜单 </cover-view> </cover-view> </cover-view></map> |
.shopInfo { position: relative; display: flex; flex-direction: row; width: 100%; padding: 10rpx; background-color: white;}.shopInfo-logo{ display: flex; width: 130rpx; height: 130rpx; flex-shrink: 0;}.shopInfo_logo { display: flex; width: 130rpx; height: 130rpx; border-radius: 4rpx;}.shopInfo-other { display: flex; width: 100%; flex-direction: column; flex-basis: 100%; justify-content: space-between;}.shopInfo_name { display: flex; width: 100%; font-size: 13pt; color: #353535; padding-left: 10rpx; padding-right: 10rpx; word-spacing: -10rpx; line-height: 1; word-wrap: break-word;}.shopInfo-item { display: flex; flex-flow: row; width: 100%; font-size: 10pt; padding-left: 10rpx; padding-right: 10rpx; line-height: 1; } |
flex-direction 设置为 column无效
