2024-10-29 11:03:57 +01:00
|
|
|
= form_with model: label, url: [:admin, @procedure, @label], local: true do |f|
|
2024-10-16 14:31:08 +02:00
|
|
|
= render Dsfr::InputComponent.new(form: f, attribute: :name, input_type: :text_field, opts: { maxlength: ProcedureLabel::NAME_MAX_LENGTH})
|
2024-10-28 14:33:57 +01:00
|
|
|
|
|
|
|
%fieldset.fr-fieldset
|
|
|
|
%legend.fr-fieldset__legend.fr-fieldset__legend--regular
|
|
|
|
= t('activerecord.attributes.procedure_label.color')
|
2024-10-29 11:03:57 +01:00
|
|
|
= asterisk
|
2024-10-28 14:33:57 +01:00
|
|
|
|
|
|
|
.grid-tags
|
|
|
|
- @colors_collection.each do |color|
|
|
|
|
.fr-fieldset__element
|
|
|
|
.fr-radio-group
|
|
|
|
= f.radio_button :color, color, checked: (label.color == color.underscore)
|
|
|
|
= f.label :color, value: color, class: "fr-label fr-tag fr-tag--sm fr-tag--#{color}"
|
2024-10-16 14:31:08 +02:00
|
|
|
|
|
|
|
= render Procedure::FixedFooterComponent.new(procedure: @procedure, form: f)
|