fix(hotspot): improve edit button interaction and icon#582
Conversation
1. Set left label text to T6 font size on detail list items 2. Set right content text to T7 font size on detail list items Log: Adjusted font sizes for labels and content on network details page Influence: Detail page text follows design spec font sizes fix(network): 调整网络详情页面字体大小 1. 将详情列表左侧标签文字字号设置为 T6 2. 将详情列表右侧内容文字字号设置为 T7 Log: 调整网络详情页面的标签和内容字体大小 PMS: BUG-370973 Influence: 详情页文字符合设计规范字号
…ails page Replace IconLabel with ActionButton for better hover/pressed feedback. Add 30x30px hover/pressed background with 6px radius. Right-align the copy button in the header. Update copy icon resource to match foreground color. Log: Improved copy button UX on network details page PMS: https://pms.uniontech.com/bug-view-370975.html Influence: Network details page copy button interaction and appearance fix(network): 优化网络详情页复制按钮交互和图标 将 IconLabel 替换为 ActionButton 以支持 hover/pressed 反馈。 添加 30x30px hover/pressed 背景,圆角 6px。 复制按钮在标题栏中右对齐。 更新 copy 图标资源以匹配前景色。 Log: 优化网络详情页复制按钮交互和外观 PMS: https://pms.uniontech.com/bug-view-370975.html Influence: 网络详情页复制按钮的交互和外观
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: iCancely 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 |
1. Add hover/pressed background to the hotspot edit button with 6px radius and proper light/dark palettes 2. Set explicit 30x30 preferred size for the edit button to stabilize layout 3. Replace the dcc_network_edit icon resource with the correct image Log: Add hover/press feedback and fix the icon for the hotspot edit button Influence: Improves edit button affordance and visual correctness fix(hotspot): 完善热点编辑按钮交互与图标 1. 为热点编辑按钮增加悬浮/按下背景,6px 圆角并适配明暗主题调色板 2. 为编辑按钮设置明确的 30x30 首选尺寸以稳定布局 3. 替换 dcc_network_edit 图标资源为正确图像 Log: 为热点编辑按钮增加悬浮/按下反馈并修正图标 PMS: BUG-371257 Influence: 提升编辑按钮可操作性并修正视觉
4f59cb5 to
b9d3826
Compare
deepin pr auto review★ 总体评分:75分■ 【总体评价】
■ 【详细分析】
■ 【改进建议代码示例】 --- a/dcc-network/qml/PageDetails.qml
+++ b/dcc-network/qml/PageDetails.qml
@@ -60,28 +60,42 @@ DccObject {
text: dccObj.displayName
elide: Text.ElideMiddle
}
- D.IconLabel {
+ D.ActionButton {
property bool clipboard: false
- Layout.alignment: Qt.AlignRight
+ Layout.alignment: Qt.AlignRight | Qt.AlignVCenter
+ Layout.preferredWidth: 30
+ Layout.preferredHeight: 30
icon {
name: "copy"
- palette: D.DTK.makeIconPalette(palette)
+ width: 16
+ height: 16
}
D.ToolTip {
id: tip
palette: parent.palette
}
- MouseArea {
+ hoverEnabled: true
+ background: Rectangle {
anchors.fill: parent
- acceptedButtons: Qt.LeftButton
- onClicked: {
- let text = [infoItem.name]
- for (let i in infoItem.details) {
- text.push(infoItem.details[i][0] + "\t" + infoItem.details[i][1])
- }
- dccData.setClipboard(text.join("\n"))
- tip.show(qsTr("Details has been copied"), 2000)
+ property D.Palette pressedColor: D.Palette {
+ normal: Qt.rgba(0, 0, 0, 0.2)
+ normalDark: Qt.rgba(1, 1, 1, 0.25)
+ }
+ property D.Palette hoveredColor: D.Palette {
+ normal: Qt.rgba(0, 0, 0, 0.1)
+ normalDark: Qt.rgba(1, 1, 1, 0.1)
+ }
+ radius: 6
+ color: parent.pressed ? pressedColor.color : (parent.hovered ? hoveredColor.color : "transparent")
+ }
+ focusPolicy: Qt.StrongFocus
+ onClicked: {
+ let text = [infoItem.name]
+ for (let i in infoItem.details) {
+ text.push(infoItem.details[i][0] + "\t" + infoItem.details[i][1])
}
+ dccData.setClipboard(text.join("\n"))
+ tip.show(qsTr("Details has been copied"), 2000)
}
}
} |
|
TAG Bot New tag: 2.0.98 |
背景
PMS: https://pms.uniontech.com/bug-view-371257.html
个人热点页面的编辑按钮缺少悬浮/按下交互反馈,且使用的图标资源不正确,导致可操作性差且视觉不符合预期。
修改内容
dcc_network_edit)增加悬浮/按下背景:6px 圆角矩形,适配明暗主题调色板(hoverrgba(0,0,0,0.1)/ pressrgba(0,0,0,0.2),暗色主题对应白底半透明)。30x30首选尺寸(Layout.preferredWidth/Height),稳定布局。dcc_network_edit.dci图标资源为正确图像(787 → 811 字节)。影响范围
仅影响控制中心 → 个人热点页面「My Hotspot」标题行的编辑按钮交互与图标显示,不涉及其他页面或后端逻辑。
关联
PMS: BUG-371257