@php
$errors = $errors ?? null;
$fieldLabel = $field['label'];
$fieldName = $field['name'];
$fieldDotName = square_brackets_to_dots(implode(',', (array) $fieldName));
$inputId = str()->slug($fieldDotName);
$options = $field['options'];
if (array_key_exists('validation', $options)) {
$tailleMaxMo = ($options['validation']['maxsize'] ?? 5120) / 1024;
if (strlen($field['hint'])) {
$field['hint'] .= '
';
}
$field['hint'] .= 'Taille max. ' . $tailleMaxMo . 'Mo, Type de fichier : ' . $options['validation']['mimes'];
}
@endphp
{{ old_empty_or_null($fieldName, '') ?? ($field['value'] ?? ($field['default'] ?? '')) }}