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

无法获取style属性的值 #198

@linyouzhen124

Description

@linyouzhen124

使用自定义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"
}
]
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions