fix(authentication): improve name editor layout to fill available width#3306
Conversation
deepin pr auto review★ 总体评分:100分■ 【总体评价】
■ 【详细分析】
■ 【改进建议代码示例】 LineEdit {
id: nameEditor
property int maxLength: 15
Layout.leftMargin: 10
Layout.rightMargin: 10
Layout.fillWidth: true
implicitHeight: DS.Style.itemDelegate.height
horizontalAlignment: TextInput.AlignLeft
text: modelData
} |
1. Replace fixed maxWidth with fillWidth for adaptive input width 2. Set input height to 30px with 5px vertical margins (matches itemDelegate height) 3. Remove redundant spacer item before edit button 4. Show blue focus border only during editing (focus + !readOnly) 5. Align with Bluetooth rename UI behavior 1. 将输入框从固定宽度改为 fillWidth 自适应填充 2. 设置输入框高度为30px,上下5px边距,保持行高40px 3. 移除编辑按钮前冗余的占位元素 4. 蓝色焦点边框仅在编辑状态(聚焦且非只读)时显示 5. 与蓝牙重命名界面的交互表现保持一致 Log: 优化认证模块用户名输入框布局与焦点边框样式 PMS: BUG-365807 Influence: 编辑用户名时输入框自适应宽度、高度匹配列表项规范, 蓝色焦点边框仅在编辑模式下显示,与蓝牙重命名体验对齐
98144c8 to
b652f2d
Compare
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: caixr23, Ivy233 The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
3 similar comments
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: caixr23, Ivy233 The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: caixr23, Ivy233 The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: caixr23, Ivy233 The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
/forcemerge |
|
This pr force merged! (status: blocked) |
Replace fixed maximum width with fillWidth for the name editor input, and remove redundant spacer item before edit button.
修复用户名输入框的布局方式,使用 fillWidth 自适应填充
替代固定的最大宽度限制,并移除编辑按钮前冗余的占位元素。
Log: 修复认证模块用户名输入框布局,支持自适应宽度
PMS: BUG-365807
Influence: 在控制中心认证模块中编辑用户名时,输入框将自适应填充可用宽度,不再局限于最大200px