app/components/one_time_code_input_component.html.erb
<%= content_tag(:'lg-one-time-code-input', **tag_options, transport:) do %>
<%= render ValidatedFieldComponent.new(
form:,
name:,
label: t('components.one_time_code_input.label'),
hint:,
required: true,
error_messages: { patternMismatch: t('errors.messages.otp_format') },
**field_options,
input_html: {
**field_options[:input_html].to_h,
value:,
maxlength: input_maxlength,
autofocus: autofocus?,
class: input_css_class,
pattern: input_pattern,
autocomplete: 'one-time-code',
inputmode: input_inputmode,
},
) %>
<% end %>