Fixed the Select dropdown to use searchable on the Edit Files Page. (#1204)

Co-authored-by: RMartinOscar <40749467+RMartinOscar@users.noreply.github.com>
This commit is contained in:
tfcprivt 2025-04-06 20:05:54 +02:00 committed by GitHub
parent 49638e75e5
commit b9d4773bd7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 13 additions and 1 deletions

View File

@ -243,6 +243,7 @@ class CreateEgg extends CreateRecord
->default('ghcr.io/pelican-eggs/installers:debian'),
Select::make('script_entry')
->label(trans('admin/egg.script_entry'))
->native(false)
->selectablePlaceholder(false)
->default('bash')
->options(['bash', 'ash', '/bin/bash'])

View File

@ -235,6 +235,7 @@ class EditEgg extends EditRecord
->placeholder('ghcr.io/pelican-eggs/installers:debian'),
Select::make('script_entry')
->label(trans('admin/egg.script_entry'))
->native(false)
->selectablePlaceholder(false)
->options(['bash', 'ash', '/bin/bash'])
->required(),

View File

@ -17,6 +17,12 @@ class CopyFrom extends Select
$this->placeholder(trans('admin/egg.none'));
$this->preload();
$this->searchable();
$this->native(false);
$this->live();
}

View File

@ -113,6 +113,8 @@ class EditFiles extends Page
->schema([
Select::make('lang')
->label('Syntax Highlighting')
->searchable()
->native(false)
->live()
->options(EditorLanguages::class)
->selectablePlaceholder(false)

View File

@ -447,6 +447,8 @@ class ListFiles extends ListRecords
->required(),
Select::make('lang')
->label('Syntax Highlighting')
->searchable()
->native(false)
->live()
->options(EditorLanguages::class)
->selectablePlaceholder(false)

View File

@ -119,8 +119,8 @@
},
wordWrap: 'on',
WrappingIndent: 'same',
});
$el.style.zIndex = '1';
monacoEditor(document.getElementById(monacoId).editor);
document.getElementById(monacoId).addEventListener('monaco-editor-focused', (event) => {
document.getElementById(monacoId).editor.focus();