提交 fd532781 编写于 作者: shutao-dc's avatar shutao-dc

update overflow.uvue

上级 d60b42ea
...@@ -2,41 +2,57 @@ ...@@ -2,41 +2,57 @@
<!-- #ifdef APP --> <!-- #ifdef APP -->
<scroll-view style="flex:1;"> <scroll-view style="flex:1;">
<!-- #endif --> <!-- #endif -->
<text style="font-size: 15px;">overflow=hidden效果 子元素是view</text> <text style="font-size: 15px;">overflow=hidden效果子元素是view border圆角</text>
<view class="backgroundview"> <view class="backgroundview">
<view class="box-hidden"> <view class="box-hidden-border-radius">
<view style="width: 50px; height: 150px; background-color: greenyellow;"></view> <view style="width: 50px; height: 150px; background-color: greenyellow;"></view>
</view> </view>
</view> </view>
<text style="font-size: 15px;">overflow=visible效果 子元素是view</text>
<text style="font-size: 15px;">overflow=hidden效果 子元素是view border边框</text>
<view class="backgroundview">
<view class="box-hidden-border-width">
<view style="width: 50px; height: 150px; background-color: greenyellow;"></view>
</view>
</view>
<text style="font-size: 15px;">overflow=visible效果 子元素是view border圆角</text>
<view class="backgroundview"> <view class="backgroundview">
<view class="box-visible"> <view class="box-visible-border-radius">
<view style="width: 50px; height: 150px; background-color: greenyellow;"></view> <view style="width: 50px; height: 150px; background-color: greenyellow;"></view>
</view> </view>
</view> </view>
<text style="font-size: 15px;">overflow=visible效果 子元素是view border边框</text>
<view class="backgroundview">
<view class="box-visible-border-width">
<view style="width: 50px; height: 150px; background-color: greenyellow;"></view>
</view>
</view>
<view style="flex-grow: 1"> <view style="flex-grow: 1">
<text style="font-size: 15px;">overflow=hidden效果 子元素是text</text> <text style="font-size: 15px;">overflow=hidden效果 子元素是text</text>
<view class="backgroundview"> <view class="backgroundview">
<view class="box-hidden"> <view class="box-hidden-border-radius">
<text class="text1">ABCDEFG</text> <text class="text1">ABCDEFG</text>
</view> </view>
</view> </view>
<text style="font-size: 15px;">overflow=visible效果 子元素是text</text> <text style="font-size: 15px;">overflow=visible效果 子元素是text</text>
<view class="backgroundview"> <view class="backgroundview">
<view class="box-visible"> <view class="box-visible-border-radius">
<text class="text1">ABCDEFG</text> <text class="text1">ABCDEFG</text>
</view> </view>
</view> </view>
<text style="font-size: 15px;">overflow=hidden效果 子元素是image</text> <text style="font-size: 15px;">overflow=hidden效果 子元素是image</text>
<view class="backgroundview"> <view class="backgroundview">
<view class="box-hidden"> <view class="box-hidden-border-radius">
<image style="width: 150px; height: 150px;" src="/static/uni.png"></image> <image style="width: 150px; height: 150px;" src="/static/uni.png"></image>
</view> </view>
</view> </view>
<text style="font-size: 15px;">overflow=visible效果 子元素是image</text> <text style="font-size: 15px;">overflow=visible效果 子元素是image</text>
<view class="backgroundview"> <view class="backgroundview">
<view class="box-visible"> <view class="box-visible-border-radius">
<image style="width: 150px; height: 150px;" src="/static/uni.png"></image> <image style="width: 150px; height: 150px;" src="/static/uni.png"></image>
</view> </view>
</view> </view>
...@@ -70,20 +86,37 @@ ...@@ -70,20 +86,37 @@
align-items: center; align-items: center;
} }
.box-hidden { .box-hidden-border-radius {
width: 100px; width: 100px;
height: 100px; height: 100px;
border-radius: 20px; border-radius: 20px;
overflow: hidden; overflow: hidden;
background-color: green; background-color: green;
}
.box-hidden-border-width {
width: 100px;
height: 100px;
border-width: 2px;
border-style: solid;
background-color: green;
} }
.box-visible { .box-visible-border-radius {
width: 100px; width: 100px;
height: 100px; height: 100px;
border-radius: 20px; border-radius: 20px;
overflow: visible; overflow: visible;
background-color: green; background-color: green;
}
.box-visible-border-width {
width: 100px;
height: 100px;
border-width: 2px;
border-style: solid;
overflow: visible;
background-color: green;
} }
.text1 { .text1 {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册