Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions Coder-Desktop/Coder-Desktop/Views/VPN/VPNMenuItem.swift
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,10 @@ struct MenuItemView: View {
return formattedName
}

private var fullItemName: String {
item.primaryHost(hostnameSuffix: state.hostnameSuffix)
}
Copy link
Copy Markdown
Member

@ethanndickson ethanndickson Mar 26, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we replace all references to item.primaryHost(hostnameSuffix: state.hostnameSuffix) elsewhere in this struct with fullItemName to avoid repeating ourselves?

Also, why full? itemName is already full. Maybe this should be plainItemName since itemName is the formatted/stylized one?


private var isExpanded: Bool {
expandedItem == item.id
}
Expand Down Expand Up @@ -134,6 +138,7 @@ struct MenuItemView: View {
.onHover { hovering in
nameIsSelected = hovering
}
.help(fullItemName)
}.buttonStyle(.plain).padding(.trailing, 3)
MenuItemIcons(item: item, wsURL: wsURL)
}
Expand Down
Loading