提交 a9993dc8 编写于 作者: DCloud_iOS_WZT's avatar DCloud_iOS_WZT

补充border-style测试例

上级 1bc5ef47
...@@ -58,12 +58,39 @@ ...@@ -58,12 +58,39 @@
style="border-style: none; border-width: 5px;" style="border-style: none; border-width: 5px;"
></view> ></view>
</view> </view>
<view @click="changeBorderStyle">
<text>border-style: 点击切换</text>
<view
class="common"
:style="borderStyle"
></view>
</view>
</view> </view>
<!-- #ifdef APP --> <!-- #ifdef APP -->
</scroll-view> </scroll-view>
<!-- #endif --> <!-- #endif -->
</template> </template>
<script>
export default {
data() {
return {
isSolid : false,
borderStyle: "border-style: none; border-width: 5px;",
}
},
methods: {
changeBorderStyle() {
this.isSolid = !this.isSolid;
const solid = "border-style: solid; border-width: 5px;";
const none = "";
this.borderStyle = this.isSolid ? solid : none;
}
}
}
</script>
<style> <style>
.common { .common {
width: 250px; width: 250px;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册