Repair Tailscale authorization flow

This commit is contained in:
David Heinemeier Hansson
2026-07-17 10:20:08 -07:00
parent 16b5f2157f
commit fe48e83222
8 changed files with 167 additions and 9 deletions
+50
View File
@@ -498,6 +498,56 @@ Panel {
}
}
CursorSurface {
id: connectionRow
visible: tailscale.installed && !tailscale.running
width: parent.width
implicitHeight: connectionText.implicitHeight + Style.spacing.rowPaddingX
hasCursor: root.cursorActive && root.focusSection === "header"
foreground: root.foreground
fill: root.hoverFill
MouseArea {
anchors.fill: parent
hoverEnabled: true
enabled: !tailscale.busy
cursorShape: enabled ? Qt.PointingHandCursor : Qt.ArrowCursor
onEntered: {
root.cursorActive = true
root.focusSection = "header"
}
onClicked: tailscale.loginOrUp()
}
Column {
id: connectionText
anchors.left: parent.left
anchors.right: parent.right
anchors.verticalCenter: parent.verticalCenter
anchors.leftMargin: Style.space(12)
anchors.rightMargin: Style.space(12)
spacing: Style.space(2)
Text {
width: parent.width
text: tailscale.needsLogin ? "Authorize this device" : "Connect Tailscale"
color: root.foreground
font.family: root.fontFamily
font.pixelSize: Style.font.body
font.weight: Font.Medium
}
Text {
width: parent.width
text: tailscale.needsLogin ? "Open Tailscale to restore this device's access" : "Reconnect with the current Tailscale settings"
color: root.dim
font.family: root.fontFamily
font.pixelSize: Style.font.caption
wrapMode: Text.WordWrap
}
}
}
Text {
visible: tailscale.actionStatus !== "" || tailscale.lastError !== ""
width: parent.width