Tangram-Android icon indicating copy to clipboard operation
Tangram-Android copied to clipboard

无法获取style属性的值

Open linyouzhen124 opened this issue 4 years ago • 1 comments

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

linyouzhen124 avatar Jul 31 '20 09:07 linyouzhen124

+1求大神解答

kebeyDing avatar Sep 25 '20 05:09 kebeyDing