Skip to content
This repository has been archived by the owner on Oct 8, 2021. It is now read-only.

无法获取style属性的值 #198

Open
linyouzhen124 opened this issue Jul 31, 2020 · 1 comment
Open

无法获取style属性的值 #198

linyouzhen124 opened this issue Jul 31, 2020 · 1 comment

Comments

@linyouzhen124
Copy link

使用自定义model的形式进行开发,json数据配置了margin,padding等数据,通过style获取属性值都为默认值,但是页面效果是有的。是不支持在bindView中获取style的值吗?
这是打印的style值:
style: {"aspectRatio":null,"bgColor":-4635,"bgImage":"","bgImgUrl":"","extras":{},"forLabel":"","height":-2,"margin":[0,0,0,0],"padding":[0,0,0,0],"slidable":false,"width":-1,"zIndex":0}

这是data数据:
{
"id": "banner1",
"type": "container-oneColumn",
"style": {
"aspectRatio": 3.223,
"bgColor": "#ffffff",
"margin": [
10,
10,
0,
10
],
"padding": [
5,
10,
5,
10
],
"cols": [
25,
25,
25,
25
],
"cornerRadius": [
15,
15,
15,
15
]
},
"items": [
{
"bizId": "item1",
"type": 110,
"msg": "info1",
"style": {
"bgColor": "#FFEDE5"
}
},
{
"bizId": "item2",
"type": 110,
"msg": "info2"
}
]
}

@kebeyDing
Copy link

+1求大神解答

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants