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

update background-image.uvue

上级 d4502906
<template>
<view style="flex-grow: 1;">
<scroll-view>
<view>
<text>不支持背景图片,仅支持linear-gradient方法</text>
<text>background-image: linear-gradient(to right, red, yellow)</text>
<view class="common" style="background-image: linear-gradient(to right, red, yellow);"></view>
<view v-for="(direction) in directionData">
<text>background-image: linear-gradient({{direction}}, red, yellow)</text>
<view class="common" :style="{'background-image': 'linear-gradient('+direction+', red, yellow)'}"></view>
</view>
</view>
</view>
</scroll-view>
</template>
<script>
export default {
data(){
return {
directionData: ['to right', 'to left', 'to bottom', 'to top', 'to bottom left', 'to bottom right', 'to top left', 'to top right']
}
}
}
</script>
<style>
......@@ -17,4 +25,4 @@
width: 500rpx;
height: 500rpx;
}
</style>
\ No newline at end of file
</style>
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册