<%= f.label @attribute, class: "block text-sm font-medium leading-6 text-gray-900" %>
<% input_color_class = errors? ? "text-red-900 ring-red-300 placeholder:text-red-300 focus:ring-red-500" : "text-gray-900 ring-gray-300 placeholder:text-gray-400 focus:ring-primary-600" %> <%= f.input_field @attribute, class: "block w-full rounded-md border-0 py-1.5 shadow-sm ring-1 ring-inset focus:ring-2 focus:ring-inset sm:text-sm sm:leading-6 #{input_color_class}" %> <% if f.object.errors[@attribute].present? %>
<%= render(IconComponent.new(:exclamation, class: "h-5 w-5 text-red-500")) %>
<% end %>
<% if @args[:hint] %>

<%= @args[:hint] %>

<% end %> <%= f.error @attribute, id: "#{@attribute}_error", class: "mt-2 text-sm text-red-600" %>