小小白啊
小小白啊
  • 发布:2021-08-26 10:31
  • 更新:2021-08-30 14:34
  • 阅读:497

【报Bug】在原生导航栏中,type为transparent时button为left的时候不居中问题。

分类:uni-app

产品分类: uniapp/H5

PC开发环境操作系统: Windows

PC开发环境操作系统版本号: Windiws10 ltsc

HBuilderX类型: 正式

HBuilderX版本号: 3.2.3

浏览器平台: Chrome

浏览器版本: 92.0.4515.159(正式版本)

项目创建方式: HBuilderX

示例代码:
                "app-plus": {  
                    "bounce": "none",  
                    "titleNView": {  
                        "type": "transparent",  
                        "buttons": [  
                            {  
                                "fontSrc": "/static/navbars.ttf",  
                                "text": "\ue657",  
                                "float":"left",  
                                "fontSize": "20",  
                                "background":"rgba(0,0,0,0)"  
                            },{  
                            "fontSrc": "/static/navbars.ttf",  
                            "text": "\ue71f",  
                            "redDot": false,  
                            "float":"right",  
                            "fontSize": "20",  
                            "background":"rgba(0,0,0,0)"  
                        }]  
                    }  
                }

操作步骤:
                "app-plus": {  
                    "bounce": "none",  
                    "titleNView": {  
                        "type": "transparent",  
                        "buttons": [  
                            {  
                                "fontSrc": "/static/navbars.ttf",  
                                "text": "\ue657",  
                                "float":"left",  
                                "fontSize": "20",  
                                "background":"rgba(0,0,0,0)"  
                            },{  
                            "fontSrc": "/static/navbars.ttf",  
                            "text": "\ue71f",  
                            "redDot": false,  
                            "float":"right",  
                            "fontSize": "20",  
                            "background":"rgba(0,0,0,0)"  
                        }]  
                    }  
                }

预期结果:

导航栏type为transparent时button为left的时候会居中。

实际结果:

button为lleft没有居中。

bug描述:

根据观察button为right的时候 是有 justify-content: center; 属性的。

但是为left的时候,是没有。

需要添加在以下css添加

.uni-page-head-transparent .uni-page-head-btn{  
  justify-content: center;  
}
2021-08-26 10:31 负责人:无 分享
已邀请:
DCloud_UNI_LXH

DCloud_UNI_LXH

已确认bug,已加分,预计下版alpha带上

DCloud_UNI_LXH

DCloud_UNI_LXH

在H5上,你是怎么把左上角的返回按钮去掉的?

DCloud_UNI_GSQ

DCloud_UNI_GSQ

HBuilderX alpha 3.2.5+ 已修复

该问题目前已经被锁定, 无法添加新回复