Closed badboy-tian closed 1 month ago
[{
"node": "element",
"attr": {},
"tag": "span",
"tagType": "inline",
"artUIStyleObject": {
"fontSize": 15,
"fontColor": "#99000000",
"textAlign": 1
},
"nodes": [{
"node": "text",
"text": "您好, 现在会员促销期间"
}, {
"node": "element",
"attr": {
"color": "red"
},
"tag": "font",
"tagType": "inline",
"artUIStyleObject": {
"fontSize": 15,
"fontColor": "red",
"textAlign": 1,
"border": {},
"margin": {},
"padding": {}
},
"nodes": [{
"node": "text",
"text": "打6折"
}, {
"node": "text",
"text": "哟~错过时间"
}, {
"node": "element",
"attr": {
"color": "red"
},
"tag": "font",
"tagType": "inline",
"artUIStyleObject": {
"fontSize": 15,
"fontColor": "red",
"textAlign": 1,
"border": {},
"margin": {},
"padding": {}
},
"nodes": [{
"node": "text",
"text": "恢复原价"
}],
"isInlinePushNode": true
}, {
"node": "text",
"text": "哈!"
}],
"isInlinePushNode": true
}],
"addHarmonyTextTag": true
}]
解析后的数据中, 有点没看懂
{
"node": "text",
"text": "打6折"
}, {
"node": "text",
"text": "哟~错过时间"
}
这2个都是没有其他属性标签, 你怎么确认的打6折是红色, "哟~错过时间"是黑色, 而不是black90颜色?
你好 请问有后文么
参考 Example_14.ets
一模一样的代码 还是不行啊
哦 需要新版本哈 这个发布新版本需要多久 才能用ohpm下载更新呢
我把你源码clone下来, 然后跑标签
效果如图
感觉是font标签后面的字颜色都变黑了, 设置baseFontColor失效了. font标签之前的字是black90的颜色 淡黑色