Skip to content

Commit 376969d

Browse files
committed
chore: Cleanup media server integration fields a bit
Add prefixes and indicators for connection
1 parent 00f2762 commit 376969d

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

app/Filament/Resources/MediaServerIntegrations/MediaServerIntegrationResource.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,12 +82,14 @@ public static function form(Schema $schema): Schema
8282
'jellyfin' => 'Jellyfin',
8383
])
8484
->required()
85+
->default('emby')
8586
->native(false),
8687
]),
8788

8889
Grid::make(3)->schema([
8990
TextInput::make('host')
9091
->label('Host / IP Address')
92+
->prefix(fn (callable $get) => $get('ssl') ? 'https://' : 'http://')
9193
->placeholder('192.168.1.100 or media.example.com')
9294
->required()
9395
->maxLength(255),
@@ -101,6 +103,8 @@ public static function form(Schema $schema): Schema
101103
->maxValue(65535),
102104

103105
Toggle::make('ssl')
106+
->live()
107+
->inline(false)
104108
->label('Use HTTPS')
105109
->helperText('Enable if your server uses SSL/TLS')
106110
->default(false),

0 commit comments

Comments
 (0)