Преглед на файлове

选择器太长截断部分

张文飞 преди 3 години
родител
ревизия
000c21a531
променени са 1 файла, в които са добавени 11 реда и са изтрити 5 реда
  1. 11 5
      components/subComponents/dmPickerView.vue

+ 11 - 5
components/subComponents/dmPickerView.vue

@@ -1,7 +1,7 @@
 <template>
 	<dm-pop-view ref='popView' @confirm='handleConfirm' :title="title" :maskTapHide='maskTapHide'>
 		<picker-view class="pop-pickerView" indicator-style='height:80rpx' :value="selectValue" @change="handleChange">
-			<picker-view-column>
+			<picker-view-column class="picker_column">
 				<view class="column-item" v-for="(item,index) in options" :key="index">{{item.title}}</view>
 			</picker-view-column>
 		</picker-view>
@@ -66,16 +66,22 @@
 		margin: 40rpx 0;
 		width: 750rpx;
 		height: 300rpx;
+		
+		.picker_column{
+			width: 750rpx;
+		}
 
 		.column-item {
+			width: 80%;
 			height: 80rpx;
-			display: flex;
+			line-height: 80rpx;
 			box-sizing: border-box;
 			white-space: nowrap;
 			overflow: hidden;
-			flex-direction: row;
 			align-items: center;
-			justify-content: center;
-		}
+		    text-align: center;
+			text-overflow: ellipsis;
+			margin: 0 auto;
+		} 
 	}
 </style>