1
0
mirror of https://github.com/AvengeMedia/DankMaterialShell.git synced 2026-04-11 16:22:09 -04:00

doctor: add links to dr command

This commit is contained in:
bbedward
2026-01-04 22:44:19 -05:00
parent 5e03afe7f0
commit 9b027df1d5
5 changed files with 112 additions and 88 deletions

View File

@@ -50,8 +50,8 @@ Rectangle {
Column {
anchors.left: statusIcon.right
anchors.leftMargin: Theme.spacingS
anchors.right: categoryChip.visible ? categoryChip.left : parent.right
anchors.rightMargin: Theme.spacingM
anchors.right: categoryChip.visible ? categoryChip.left : (urlButton.visible ? urlButton.left : parent.right)
anchors.rightMargin: Theme.spacingS
anchors.verticalCenter: parent.verticalCenter
spacing: 1
@@ -76,8 +76,8 @@ Rectangle {
Rectangle {
id: categoryChip
anchors.right: parent.right
anchors.rightMargin: Theme.spacingM
anchors.right: urlButton.visible ? urlButton.left : parent.right
anchors.rightMargin: urlButton.visible ? Theme.spacingXS : Theme.spacingM
anchors.verticalCenter: parent.verticalCenter
height: Math.round(Theme.fontSizeSmall * 1.67)
width: categoryText.implicitWidth + Theme.spacingS
@@ -93,4 +93,17 @@ Rectangle {
color: Theme.surfaceVariantText
}
}
DankActionButton {
id: urlButton
anchors.right: parent.right
anchors.rightMargin: Theme.spacingM
anchors.verticalCenter: parent.verticalCenter
iconName: "open_in_new"
iconSize: Theme.iconSize - 6
buttonSize: 24
visible: !!(root.resultData?.url)
tooltipText: root.resultData?.url || ""
onClicked: Qt.openUrlExternally(root.resultData.url)
}
}

View File

@@ -102,12 +102,10 @@ Item {
property string text: ""
implicitWidth: Math.min(300, Math.max(120, textContent.implicitWidth + Theme.spacingM * 2))
implicitHeight: textContent.implicitHeight + Theme.spacingS * 2
width: implicitWidth
height: implicitHeight
padding: 0
leftPadding: Theme.spacingM
rightPadding: Theme.spacingM
topPadding: Theme.spacingS
bottomPadding: Theme.spacingS
closePolicy: Popup.NoAutoClose
modal: false
dim: false
@@ -122,6 +120,7 @@ Item {
contentItem: Text {
id: textContent
width: Math.min(implicitWidth, 500)
text: tooltip.text
font.pixelSize: Theme.fontSizeSmall
color: Theme.surfaceText

View File

@@ -23,7 +23,7 @@ MouseArea {
Timer {
id: hoverDelay
interval: 1000
interval: 400
repeat: false
onTriggered: {
tooltip.show(root.tooltipText, root, 0, 0, "bottom");