mirror of
https://github.com/dergigi/boris.git
synced 2026-01-02 22:44:31 +01:00
fix(highlights): always show relay list in tooltip
Remove special case text - always show the actual list of relays. Use plane icon for local-only highlights but still show relay list in tooltip.
This commit is contained in:
@@ -153,28 +153,21 @@ export const HighlightItem: React.FC<HighlightItemProps> = ({
|
||||
if (isRebroadcasting || isSyncing) {
|
||||
return {
|
||||
icon: faSpinner,
|
||||
tooltip: isRebroadcasting ? 'Rebroadcasting to all relays...' : 'Auto-syncing to remote relays...',
|
||||
tooltip: isRebroadcasting ? 'rebroadcasting...' : 'syncing...',
|
||||
spin: true
|
||||
}
|
||||
}
|
||||
|
||||
// Always show relay list, use plane icon for local-only
|
||||
const isLocalOrOffline = highlight.isLocalOnly || showOfflineIndicator
|
||||
|
||||
if (isLocalOrOffline) {
|
||||
return {
|
||||
icon: faPlane,
|
||||
tooltip: 'Click to rebroadcast to all relays',
|
||||
spin: false
|
||||
}
|
||||
}
|
||||
|
||||
// Show server icon with relay info if available
|
||||
if (highlight.publishedRelays && highlight.publishedRelays.length > 0) {
|
||||
const relayNames = highlight.publishedRelays.map(url =>
|
||||
url.replace(/^wss?:\/\//, '').replace(/\/$/, '')
|
||||
)
|
||||
return {
|
||||
icon: faServer,
|
||||
icon: isLocalOrOffline ? faPlane : faServer,
|
||||
tooltip: relayNames.join('\n'),
|
||||
spin: false
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user