feat(execute-container): enhance container command form with auto-connect feature for single container scenarios
This commit is contained in:
@@ -8360,6 +8360,9 @@
|
|||||||
"is_preview": {
|
"is_preview": {
|
||||||
"type": "boolean"
|
"type": "boolean"
|
||||||
},
|
},
|
||||||
|
"is_buildtime_only": {
|
||||||
|
"type": "boolean"
|
||||||
|
},
|
||||||
"is_shared": {
|
"is_shared": {
|
||||||
"type": "boolean"
|
"type": "boolean"
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -5411,6 +5411,8 @@ components:
|
|||||||
type: boolean
|
type: boolean
|
||||||
is_preview:
|
is_preview:
|
||||||
type: boolean
|
type: boolean
|
||||||
|
is_buildtime_only:
|
||||||
|
type: boolean
|
||||||
is_shared:
|
is_shared:
|
||||||
type: boolean
|
type: boolean
|
||||||
is_shown_once:
|
is_shown_once:
|
||||||
|
|||||||
@@ -20,7 +20,11 @@
|
|||||||
@if (count($containers) === 0)
|
@if (count($containers) === 0)
|
||||||
<div>No containers are running or terminal access is disabled on this server.</div>
|
<div>No containers are running or terminal access is disabled on this server.</div>
|
||||||
@else
|
@else
|
||||||
<form class="w-full flex gap-2 items-end" wire:submit="$dispatchSelf('connectToContainer')">
|
<form class="w-96 min-w-fit flex gap-2 items-end" wire:submit="$dispatchSelf('connectToContainer')"
|
||||||
|
x-data="{ autoConnected: false }" x-init="if ({{ count($containers) }} === 1 && !autoConnected) {
|
||||||
|
autoConnected = true;
|
||||||
|
$nextTick(() => $wire.dispatchSelf('connectToContainer'));
|
||||||
|
}">
|
||||||
<x-forms.select label="Container" id="container" required wire:model.live="selected_container">
|
<x-forms.select label="Container" id="container" required wire:model.live="selected_container">
|
||||||
@foreach ($containers as $container)
|
@foreach ($containers as $container)
|
||||||
@if ($loop->first)
|
@if ($loop->first)
|
||||||
|
|||||||
Reference in New Issue
Block a user