Öffne die Medienmaske vor den Dialogen im Modul.
Deploy Test / test (push) Successful in 25s
Deploy Test / deploy (push) Successful in 27s

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
LarsandCursor committed 2026-11-17 11:05:44 +01:00
1 parent 89c574106f
commit b71ee8023b
3 files changed
+14

No files matched your search

@@ -828,6 +828,13 @@ public function addText(): void
$this->feedback = $title.' ist angelegt und in den Aufbau übernommen. Der Text bleibt bearbeitbar, solange diese Fassung nicht freigegeben und verwendet wird. Es entsteht keine neue Fassung dieses Eintrags.';
}
private function revealMediumForm(): void
{
$this->pickerOpen = false;
$this->partOpen = false;
$this->textOpen = false;
}
public function createMediumAction(): Action
{
return Action::make('createMedium')
@@ -836,6 +843,7 @@ public function createMediumAction(): Action
->modalDescription('Dieselbe Maske gilt im Medienbestand, im Modul und im Programm. Der Upload zeigt seinen Fortschritt. Beschreibung, Hinweise und Vorschaubild trägst du danach in dieser Maske ein.')
->modalSubmitActionLabel('Anlegen und übernehmen')
->modalWidth(Width::Large)
->beforeFormFilled(fn () => $this->revealMediumForm())
->schema(fn (): array => MediumForm::fields(creating: true))
->action(function (array $data): void {
try {
@@ -863,6 +871,7 @@ public function editMediumAction(): Action
->modalDescription('Titel, Beschreibung, Hinweise und Vorschaubild gelten für das Medium. Eine neue Fassung entsteht nur, wenn der Text bereits freigegeben und verwendet wird.')
->modalSubmitActionLabel('Speichern')
->modalWidth(Width::Large)
->beforeFormFilled(fn () => $this->revealMediumForm())
->fillForm(function (array $arguments): array {
$element = ContentElement::query()->find($arguments['element'] ?? 0);
@@ -245,6 +245,7 @@
.luf-picker { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(14rem, 0.8fr); gap: 0.8rem; align-items: start; }
.luf-detail { background: var(--luf-paper); border: 1px solid var(--luf-line); padding: 0.8rem; }
.luf-modal { position: fixed; inset: 0; z-index: 50; background: rgba(27, 40, 56, 0.46); display: grid; place-items: center; padding: 1rem; }
.fi-modal > .fi-modal-close-overlay, .fi-modal > .fi-modal-window-ctn { z-index: 80; }
.luf-modal-card { width: min(76rem, 100%); max-height: calc(100vh - 2rem); overflow: auto; background: #fff; border: 1px solid var(--luf-line); padding: 1rem 1.1rem 1.25rem; }
.luf-modal-narrow { width: min(36rem, 100%); }
.luf-confirm { margin: 0 0 1rem; padding: 0.9rem 1rem; background: #fff; border: 1px solid var(--luf-yellow); }
+4
View File
@@ -618,7 +618,11 @@ public function test_a_file_can_be_created_inside_the_module(): void
$component = Livewire::actingAs($editor, 'staff')
->test(EditExercise::class, ['record' => $module->id])
->assertSee('Medium anlegen')
->set('pickerOpen', true)
->assertSee('Material auswählen')
->mountAction('createMedium')
->assertSet('pickerOpen', false)
->assertMountedActionModalSee('Vorschaubild')
->fillForm([
'working_title' => 'Merkblatt',