Update server button styles and connection logic for online servers
This commit is contained in:
@@ -310,9 +310,9 @@ function Servers() {
|
|||||||
style={{
|
style={{
|
||||||
width: '100%',
|
width: '100%',
|
||||||
padding: '0.75rem',
|
padding: '0.75rem',
|
||||||
background: server.status === 'online' ? 'var(--accent-primary)' : 'var(--text-secondary)',
|
background: 'transparent',
|
||||||
color: 'white',
|
color: server.status === 'online' ? 'var(--accent-primary)' : 'var(--text-secondary)',
|
||||||
border: 'none',
|
border: `2px solid ${server.status === 'online' ? 'var(--accent-primary)' : 'var(--text-secondary)'}`,
|
||||||
borderRadius: '6px',
|
borderRadius: '6px',
|
||||||
fontWeight: 'bold',
|
fontWeight: 'bold',
|
||||||
cursor: server.status === 'online' ? 'pointer' : 'not-allowed',
|
cursor: server.status === 'online' ? 'pointer' : 'not-allowed',
|
||||||
@@ -321,8 +321,7 @@ function Servers() {
|
|||||||
disabled={server.status !== 'online'}
|
disabled={server.status !== 'online'}
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
if (server.status === 'online') {
|
if (server.status === 'online') {
|
||||||
// In a real app, this would connect to the server
|
window.open(`steam://connect/${server.ip}:${server.port}`)
|
||||||
alert(`Connecting to ${server.name}...`)
|
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
|
|||||||
Reference in New Issue
Block a user