Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* [ios] fix bug height change to zero when style change
- Loading branch information
Showing
2 changed files
with
72 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,73 @@ | ||
<template> | ||
<div> | ||
<text style="font-size:100px;">Hello World.</text> | ||
</div> | ||
</template> | ||
<scroller style="flex-direction: column; background-color: #ffffff;width:750;height:1000;border-width: 3;border-color: #00ff00;"> | ||
<TC_Support_MainTitle title="TC_DataBind_DefaultClass"></TC_Support_MainTitle> | ||
|
||
<TC_Support_SubTitle title="Default"></TC_Support_SubTitle> | ||
<div class="content"> | ||
<text style="color:#000000; font-size:{{defaultFont}}">Hello weex!</text> | ||
</div> | ||
|
||
<TC_Support_SubTitle title="Content"></TC_Support_SubTitle> | ||
<div class="content"> | ||
<text class="{{contentStyle}}">Hello weex!</text> | ||
</div> | ||
|
||
<TC_Support_SubTitle title="Change"></TC_Support_SubTitle> | ||
<div class="button" onclick="multiStyle"> | ||
<text class="text">Multi style</text> | ||
</div> | ||
<div class="button" onclick="defaultStyle"> | ||
<text class="text">Default style</text> | ||
</div> | ||
|
||
</scroller> | ||
</template> | ||
|
||
<style> | ||
.button { | ||
width:400; | ||
height:50; | ||
background-color:#EEEEEE; | ||
justify-content: center; | ||
margin:20; | ||
} | ||
.text { | ||
font-size:20; | ||
text-align: center; | ||
} | ||
.content { | ||
width:400; | ||
height:100; | ||
background-color:#EEEEEE; | ||
margin-left:20; | ||
} | ||
.multi-style { | ||
border-width:3; | ||
border-style:solid; | ||
border-color:#FFFF00; | ||
border-radius:10; | ||
font-size:60; | ||
color:#FF0000; | ||
background-color:#00F0FF; | ||
} | ||
.default-style { | ||
height:100; | ||
} | ||
</style> | ||
|
||
<script> | ||
module.exports = { | ||
data: { | ||
defaultFont:'', | ||
contentStyle: 'multi-style' | ||
}, | ||
methods: { | ||
multiStyle:function (e) { | ||
this.contentStyle = 'multi-style' | ||
}, | ||
defaultStyle:function (e) { | ||
this.contentStyle = 'default-style' | ||
}, | ||
} | ||
} | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters