refactor(forms): update wire:model bindings to use 'blur' instead of 'blur-sm' for input fields across multiple views

This commit is contained in:
Andras Bacsai 2025-09-29 12:50:25 +02:00
parent 03f1f0888c
commit 872c0cbe72
5 changed files with 18 additions and 13 deletions

View file

@ -90,12 +90,12 @@
@if ($application->build_pack !== 'dockercompose')
<div class="flex items-end gap-2">
@if ($application->settings->is_container_label_readonly_enabled == false)
<x-forms.input placeholder="https://coolify.io" wire:model.blur-sm="application.fqdn"
<x-forms.input placeholder="https://coolify.io" wire:model.blur="application.fqdn"
label="Domains" readonly
helper="Readonly labels are disabled. You can set the domains in the labels section."
x-bind:disabled="!canUpdate" />
@else
<x-forms.input placeholder="https://coolify.io" wire:model.blur-sm="application.fqdn"
<x-forms.input placeholder="https://coolify.io" wire:model.blur="application.fqdn"
label="Domains"
helper="You can specify one domain with path or more with comma. You can specify a port to bind the domain to.<br><br><span class='text-helper'>Example</span><br>- http://app.coolify.io,https://cloud.coolify.io/dashboard<br>- http://app.coolify.io/api/v3<br>- http://app.coolify.io:3000 -> app.coolify.io will point to port 3000 inside the container. "
x-bind:disabled="!canUpdate" />

View file

@ -62,9 +62,9 @@ class="loading loading-xs dark:text-warning loading-spinner"></span>
</div>
@if ($build_pack === 'dockercompose')
<div x-data="{ baseDir: '{{ $base_directory }}', composeLocation: '{{ $docker_compose_location }}' }" class="gap-2 flex flex-col">
<x-forms.input placeholder="/" wire:model.blur-sm="base_directory" label="Base Directory"
<x-forms.input placeholder="/" wire:model.blur="base_directory" label="Base Directory"
helper="Directory to use as root. Useful for monorepos." x-model="baseDir" />
<x-forms.input placeholder="/docker-compose.yaml" wire:model.blur-sm="docker_compose_location"
<x-forms.input placeholder="/docker-compose.yaml" wire:model.blur="docker_compose_location"
label="Docker Compose Location" helper="It is calculated together with the Base Directory."
x-model="composeLocation" />
<div class="pt-2">

View file

@ -96,14 +96,18 @@
</div>
@if ($build_pack === 'dockercompose')
<div x-data="{ baseDir: '{{ $base_directory }}', composeLocation: '{{ $docker_compose_location }}' }" class="gap-2 flex flex-col">
<x-forms.input placeholder="/" wire:model.blur-sm="base_directory" label="Base Directory"
helper="Directory to use as root. Useful for monorepos." x-model="baseDir" />
<x-forms.input placeholder="/docker-compose.yaml" wire:model.blur-sm="docker_compose_location"
label="Docker Compose Location" helper="It is calculated together with the Base Directory."
<x-forms.input placeholder="/" wire:model.blur="base_directory"
label="Base Directory"
helper="Directory to use as root. Useful for monorepos."
x-model="baseDir" />
<x-forms.input placeholder="/docker-compose.yaml"
wire:model.blur="docker_compose_location" label="Docker Compose Location"
helper="It is calculated together with the Base Directory."
x-model="composeLocation" />
<div class="pt-2">
<span>
Compose file location in your repository: </span><span class='dark:text-warning'
Compose file location in your repository: </span><span
class='dark:text-warning'
x-text='(baseDir === "/" ? "" : baseDir) + (composeLocation.startsWith("/") ? composeLocation : "/" + composeLocation)'></span>
</div>
</div>

View file

@ -53,9 +53,9 @@
</div>
@if ($build_pack === 'dockercompose')
<div x-data="{ baseDir: '{{ $base_directory }}', composeLocation: '{{ $docker_compose_location }}' }" class="gap-2 flex flex-col">
<x-forms.input placeholder="/" wire:model.blur-sm="base_directory" label="Base Directory"
<x-forms.input placeholder="/" wire:model.blur="base_directory" label="Base Directory"
helper="Directory to use as root. Useful for monorepos." x-model="baseDir" />
<x-forms.input placeholder="/docker-compose.yaml" wire:model.blur-sm="docker_compose_location"
<x-forms.input placeholder="/docker-compose.yaml" wire:model.blur="docker_compose_location"
label="Docker Compose Location" helper="It is calculated together with the Base Directory."
x-model="composeLocation" />
<div class="pt-2">

View file

@ -7,7 +7,7 @@
<x-forms.input required label="Name" id="name" />
<x-forms.input label="Description" id="description" />
</div>
<x-forms.input required type="url" label="Endpoint" wire:model.blur-sm="endpoint" />
<x-forms.input required type="url" label="Endpoint" wire:model.blur="endpoint" />
<div class="flex gap-2">
<x-forms.input required label="Bucket" id="bucket" />
<x-forms.input required helper="Region only required for AWS. Leave it as-is for other providers."
@ -25,6 +25,7 @@
</div>
@else
<x-callout type="warning" title="Permission Required">
You don't have permission to create new S3 storage configurations. Please contact your team administrator for access.
You don't have permission to create new S3 storage configurations. Please contact your team administrator for
access.
</x-callout>
@endcan