feat(ibox): 实现信息弹窗背景自适应高度功能
1. 重构IBoxComp组件,移除旧的标题名称渲染逻辑 2. 添加动态背景节点,根据RichText内容自动调整高度 3. 优化cardbg和herobox预制体样式,调整尺寸与透明度 4. 新增通用背景预制体hbg,支持多配色快速复用 5. 重写ibox预制体结构,适配新的组件逻辑
This commit is contained in:
@@ -2998,7 +2998,7 @@
|
||||
"_lpos": {
|
||||
"__type__": "cc.Vec3",
|
||||
"x": 0,
|
||||
"y": -62.269,
|
||||
"y": -60.02,
|
||||
"z": 0
|
||||
},
|
||||
"_lrot": {
|
||||
@@ -3010,8 +3010,8 @@
|
||||
},
|
||||
"_lscale": {
|
||||
"__type__": "cc.Vec3",
|
||||
"x": 0.2,
|
||||
"y": 0.3,
|
||||
"x": 0.15,
|
||||
"y": 0.15,
|
||||
"z": 1
|
||||
},
|
||||
"_mobility": 0,
|
||||
@@ -3069,10 +3069,10 @@
|
||||
"_dstBlendFactor": 4,
|
||||
"_color": {
|
||||
"__type__": "cc.Color",
|
||||
"r": 255,
|
||||
"g": 255,
|
||||
"b": 255,
|
||||
"a": 255
|
||||
"r": 61,
|
||||
"g": 61,
|
||||
"b": 61,
|
||||
"a": 195
|
||||
},
|
||||
"_spriteFrame": {
|
||||
"__uuid__": "cb93c900-b440-4571-91d1-7da1636e3d73@34d88",
|
||||
@@ -3627,7 +3627,7 @@
|
||||
},
|
||||
"_contentSize": {
|
||||
"__type__": "cc.Size",
|
||||
"width": 84,
|
||||
"width": 92,
|
||||
"height": 35.373999999999995
|
||||
},
|
||||
"_anchorPoint": {
|
||||
@@ -3666,8 +3666,8 @@
|
||||
"_string": "英雄名称",
|
||||
"_horizontalAlign": 1,
|
||||
"_verticalAlign": 1,
|
||||
"_actualFontSize": 20,
|
||||
"_fontSize": 20,
|
||||
"_actualFontSize": 22,
|
||||
"_fontSize": 22,
|
||||
"_fontFamily": "Arial",
|
||||
"_lineHeight": 24.9,
|
||||
"_overflow": 0,
|
||||
@@ -3782,7 +3782,7 @@
|
||||
"_lpos": {
|
||||
"__type__": "cc.Vec3",
|
||||
"x": 0,
|
||||
"y": -117.839,
|
||||
"y": -113.062,
|
||||
"z": 0
|
||||
},
|
||||
"_lrot": {
|
||||
@@ -3822,7 +3822,7 @@
|
||||
},
|
||||
"_contentSize": {
|
||||
"__type__": "cc.Size",
|
||||
"width": 47.1671468533978,
|
||||
"width": 51.483861538737585,
|
||||
"height": 54.4
|
||||
},
|
||||
"_anchorPoint": {
|
||||
@@ -3861,8 +3861,8 @@
|
||||
"_string": "Lv.1",
|
||||
"_horizontalAlign": 1,
|
||||
"_verticalAlign": 1,
|
||||
"_actualFontSize": 20,
|
||||
"_fontSize": 20,
|
||||
"_actualFontSize": 22,
|
||||
"_fontSize": 22,
|
||||
"_fontFamily": "Arial",
|
||||
"_lineHeight": 40,
|
||||
"_overflow": 0,
|
||||
@@ -4416,7 +4416,7 @@
|
||||
},
|
||||
"_lpos": {
|
||||
"__type__": "cc.Vec3",
|
||||
"x": -22.182,
|
||||
"x": -25.305,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
@@ -4529,7 +4529,7 @@
|
||||
},
|
||||
"_lpos": {
|
||||
"__type__": "cc.Vec3",
|
||||
"x": -72.49951171875,
|
||||
"x": -69.669921875,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
@@ -4570,8 +4570,8 @@
|
||||
},
|
||||
"_contentSize": {
|
||||
"__type__": "cc.Size",
|
||||
"width": 45.0009765625,
|
||||
"height": 27.814
|
||||
"width": 50.66015625,
|
||||
"height": 30.46
|
||||
},
|
||||
"_anchorPoint": {
|
||||
"__type__": "cc.Vec2",
|
||||
@@ -4601,34 +4601,34 @@
|
||||
"_dstBlendFactor": 4,
|
||||
"_color": {
|
||||
"__type__": "cc.Color",
|
||||
"r": 32,
|
||||
"g": 32,
|
||||
"b": 32,
|
||||
"r": 255,
|
||||
"g": 255,
|
||||
"b": 255,
|
||||
"a": 255
|
||||
},
|
||||
"_string": "攻击:",
|
||||
"_horizontalAlign": 1,
|
||||
"_verticalAlign": 1,
|
||||
"_actualFontSize": 18,
|
||||
"_fontSize": 18,
|
||||
"_actualFontSize": 20,
|
||||
"_fontSize": 20,
|
||||
"_fontFamily": "Arial",
|
||||
"_lineHeight": 18.9,
|
||||
"_lineHeight": 21,
|
||||
"_overflow": 0,
|
||||
"_enableWrapText": true,
|
||||
"_font": null,
|
||||
"_isSystemFontUsed": true,
|
||||
"_spacingX": 0,
|
||||
"_isItalic": false,
|
||||
"_isBold": false,
|
||||
"_isBold": true,
|
||||
"_isUnderline": false,
|
||||
"_underlineHeight": 2,
|
||||
"_cacheMode": 0,
|
||||
"_enableOutline": true,
|
||||
"_outlineColor": {
|
||||
"__type__": "cc.Color",
|
||||
"r": 255,
|
||||
"g": 255,
|
||||
"b": 255,
|
||||
"r": 0,
|
||||
"g": 0,
|
||||
"b": 0,
|
||||
"a": 255
|
||||
},
|
||||
"_outlineWidth": 2,
|
||||
@@ -4688,7 +4688,7 @@
|
||||
},
|
||||
"_lpos": {
|
||||
"__type__": "cc.Vec3",
|
||||
"x": -26.9775390625,
|
||||
"x": -19.09375,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
@@ -4729,8 +4729,8 @@
|
||||
},
|
||||
"_contentSize": {
|
||||
"__type__": "cc.Size",
|
||||
"width": 44.04296875,
|
||||
"height": 27.94
|
||||
"width": 48.4921875,
|
||||
"height": 30.46
|
||||
},
|
||||
"_anchorPoint": {
|
||||
"__type__": "cc.Vec2",
|
||||
@@ -4760,18 +4760,18 @@
|
||||
"_dstBlendFactor": 4,
|
||||
"_color": {
|
||||
"__type__": "cc.Color",
|
||||
"r": 0,
|
||||
"g": 0,
|
||||
"b": 0,
|
||||
"r": 255,
|
||||
"g": 255,
|
||||
"b": 255,
|
||||
"a": 255
|
||||
},
|
||||
"_string": "9999",
|
||||
"_horizontalAlign": 1,
|
||||
"_verticalAlign": 1,
|
||||
"_actualFontSize": 18,
|
||||
"_fontSize": 18,
|
||||
"_actualFontSize": 20,
|
||||
"_fontSize": 20,
|
||||
"_fontFamily": "Arial",
|
||||
"_lineHeight": 19,
|
||||
"_lineHeight": 21,
|
||||
"_overflow": 0,
|
||||
"_enableWrapText": true,
|
||||
"_font": null,
|
||||
@@ -4785,9 +4785,9 @@
|
||||
"_enableOutline": true,
|
||||
"_outlineColor": {
|
||||
"__type__": "cc.Color",
|
||||
"r": 255,
|
||||
"g": 255,
|
||||
"b": 255,
|
||||
"r": 0,
|
||||
"g": 0,
|
||||
"b": 0,
|
||||
"a": 255
|
||||
},
|
||||
"_outlineWidth": 2,
|
||||
@@ -4847,7 +4847,7 @@
|
||||
},
|
||||
"_lpos": {
|
||||
"__type__": "cc.Vec3",
|
||||
"x": -3.9560546875,
|
||||
"x": 6.15234375,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
@@ -4888,8 +4888,8 @@
|
||||
},
|
||||
"_contentSize": {
|
||||
"__type__": "cc.Size",
|
||||
"width": 56.5322265625,
|
||||
"height": 27.94
|
||||
"width": 62.369140625,
|
||||
"height": 30.46
|
||||
},
|
||||
"_anchorPoint": {
|
||||
"__type__": "cc.Vec2",
|
||||
@@ -4927,17 +4927,17 @@
|
||||
"_string": "(+999)",
|
||||
"_horizontalAlign": 0,
|
||||
"_verticalAlign": 1,
|
||||
"_actualFontSize": 18,
|
||||
"_fontSize": 18,
|
||||
"_actualFontSize": 20,
|
||||
"_fontSize": 20,
|
||||
"_fontFamily": "Arial",
|
||||
"_lineHeight": 19,
|
||||
"_lineHeight": 21,
|
||||
"_overflow": 0,
|
||||
"_enableWrapText": true,
|
||||
"_font": null,
|
||||
"_isSystemFontUsed": true,
|
||||
"_spacingX": 0,
|
||||
"_isItalic": false,
|
||||
"_isBold": false,
|
||||
"_isBold": true,
|
||||
"_isUnderline": false,
|
||||
"_underlineHeight": 2,
|
||||
"_cacheMode": 0,
|
||||
@@ -5184,7 +5184,7 @@
|
||||
},
|
||||
"_lpos": {
|
||||
"__type__": "cc.Vec3",
|
||||
"x": -72.49951171875,
|
||||
"x": -69.669921875,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
@@ -5225,8 +5225,8 @@
|
||||
},
|
||||
"_contentSize": {
|
||||
"__type__": "cc.Size",
|
||||
"width": 45.0009765625,
|
||||
"height": 27.814
|
||||
"width": 50.66015625,
|
||||
"height": 30.46
|
||||
},
|
||||
"_anchorPoint": {
|
||||
"__type__": "cc.Vec2",
|
||||
@@ -5256,34 +5256,34 @@
|
||||
"_dstBlendFactor": 4,
|
||||
"_color": {
|
||||
"__type__": "cc.Color",
|
||||
"r": 32,
|
||||
"g": 32,
|
||||
"b": 32,
|
||||
"r": 255,
|
||||
"g": 255,
|
||||
"b": 255,
|
||||
"a": 255
|
||||
},
|
||||
"_string": "生命:",
|
||||
"_horizontalAlign": 1,
|
||||
"_verticalAlign": 1,
|
||||
"_actualFontSize": 18,
|
||||
"_fontSize": 18,
|
||||
"_actualFontSize": 20,
|
||||
"_fontSize": 20,
|
||||
"_fontFamily": "Arial",
|
||||
"_lineHeight": 18.9,
|
||||
"_lineHeight": 21,
|
||||
"_overflow": 0,
|
||||
"_enableWrapText": true,
|
||||
"_font": null,
|
||||
"_isSystemFontUsed": true,
|
||||
"_spacingX": 0,
|
||||
"_isItalic": false,
|
||||
"_isBold": false,
|
||||
"_isBold": true,
|
||||
"_isUnderline": false,
|
||||
"_underlineHeight": 2,
|
||||
"_cacheMode": 0,
|
||||
"_enableOutline": true,
|
||||
"_outlineColor": {
|
||||
"__type__": "cc.Color",
|
||||
"r": 255,
|
||||
"g": 255,
|
||||
"b": 255,
|
||||
"r": 0,
|
||||
"g": 0,
|
||||
"b": 0,
|
||||
"a": 255
|
||||
},
|
||||
"_outlineWidth": 2,
|
||||
@@ -5343,7 +5343,7 @@
|
||||
},
|
||||
"_lpos": {
|
||||
"__type__": "cc.Vec3",
|
||||
"x": -26.9775390625,
|
||||
"x": -19.09375,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
@@ -5384,8 +5384,8 @@
|
||||
},
|
||||
"_contentSize": {
|
||||
"__type__": "cc.Size",
|
||||
"width": 44.04296875,
|
||||
"height": 27.94
|
||||
"width": 48.4921875,
|
||||
"height": 30.46
|
||||
},
|
||||
"_anchorPoint": {
|
||||
"__type__": "cc.Vec2",
|
||||
@@ -5415,18 +5415,18 @@
|
||||
"_dstBlendFactor": 4,
|
||||
"_color": {
|
||||
"__type__": "cc.Color",
|
||||
"r": 0,
|
||||
"g": 0,
|
||||
"b": 0,
|
||||
"r": 255,
|
||||
"g": 255,
|
||||
"b": 255,
|
||||
"a": 255
|
||||
},
|
||||
"_string": "9999",
|
||||
"_horizontalAlign": 1,
|
||||
"_verticalAlign": 1,
|
||||
"_actualFontSize": 18,
|
||||
"_fontSize": 18,
|
||||
"_actualFontSize": 20,
|
||||
"_fontSize": 20,
|
||||
"_fontFamily": "Arial",
|
||||
"_lineHeight": 19,
|
||||
"_lineHeight": 21,
|
||||
"_overflow": 0,
|
||||
"_enableWrapText": true,
|
||||
"_font": null,
|
||||
@@ -5440,9 +5440,9 @@
|
||||
"_enableOutline": true,
|
||||
"_outlineColor": {
|
||||
"__type__": "cc.Color",
|
||||
"r": 255,
|
||||
"g": 255,
|
||||
"b": 255,
|
||||
"r": 0,
|
||||
"g": 0,
|
||||
"b": 0,
|
||||
"a": 255
|
||||
},
|
||||
"_outlineWidth": 2,
|
||||
@@ -5502,7 +5502,7 @@
|
||||
},
|
||||
"_lpos": {
|
||||
"__type__": "cc.Vec3",
|
||||
"x": -3.9560546875,
|
||||
"x": 6.15234375,
|
||||
"y": 0,
|
||||
"z": 0
|
||||
},
|
||||
@@ -5543,8 +5543,8 @@
|
||||
},
|
||||
"_contentSize": {
|
||||
"__type__": "cc.Size",
|
||||
"width": 56.5322265625,
|
||||
"height": 27.94
|
||||
"width": 62.369140625,
|
||||
"height": 30.46
|
||||
},
|
||||
"_anchorPoint": {
|
||||
"__type__": "cc.Vec2",
|
||||
@@ -5582,17 +5582,17 @@
|
||||
"_string": "(+999)",
|
||||
"_horizontalAlign": 0,
|
||||
"_verticalAlign": 1,
|
||||
"_actualFontSize": 18,
|
||||
"_fontSize": 18,
|
||||
"_actualFontSize": 20,
|
||||
"_fontSize": 20,
|
||||
"_fontFamily": "Arial",
|
||||
"_lineHeight": 19,
|
||||
"_lineHeight": 21,
|
||||
"_overflow": 0,
|
||||
"_enableWrapText": true,
|
||||
"_font": null,
|
||||
"_isSystemFontUsed": true,
|
||||
"_spacingX": 0,
|
||||
"_isItalic": false,
|
||||
"_isBold": false,
|
||||
"_isBold": true,
|
||||
"_isUnderline": false,
|
||||
"_underlineHeight": 2,
|
||||
"_cacheMode": 0,
|
||||
@@ -5799,7 +5799,7 @@
|
||||
"_right": 437.303,
|
||||
"_top": -2.5,
|
||||
"_bottom": -2.5,
|
||||
"_horizontalCenter": -22.182,
|
||||
"_horizontalCenter": -25.305,
|
||||
"_verticalCenter": 0,
|
||||
"_isAbsLeft": true,
|
||||
"_isAbsRight": true,
|
||||
|
||||
Reference in New Issue
Block a user