Commit 9b8fc456 authored by limingzhe's avatar limingzhe

fix: 增加年级标识

parent 89b32d46
......@@ -1735,6 +1735,28 @@ cc.Class({
const label = labelNode.getComponent(cc.Label);
label.isBold = true;
if (data.text_en.indexOf("一年级起") != -1) {
const labelNode2 = cc.instantiate(labelNode);
labelNode2.parent = labelNode.parent;
labelNode.y += 18
labelNode2.y -= 30;
const label2 = labelNode2.getComponent(cc.Label);
labelNode2.scale *= 0.45;
label2.string = "( 一 年 级 起 )";
}
if (data.text_en.indexOf("三年级起") != -1) {
const labelNode2 = cc.instantiate(labelNode);
labelNode2.parent = labelNode.parent;
labelNode.y += 18
labelNode2.y -= 30;
const label2 = labelNode2.getComponent(cc.Label);
labelNode2.scale *= 0.45;
label2.string = "( 三 年 级 起 )";
}
if (!isShowBookName) {
labelBg.active = false;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment