New UI : Style file uploader

This commit is contained in:
Mathieu Magnin 2017-10-31 16:22:27 +01:00
parent 7f4652fd1e
commit 7ea7eea952

View file

@ -30,6 +30,12 @@
= form_for(@commentaire, url: commentaire_dossier_path(@dossier.procedure, @dossier), html: { class: 'form' }) do |f| = form_for(@commentaire, url: commentaire_dossier_path(@dossier.procedure, @dossier), html: { class: 'form' }) do |f|
= f.text_area :body, rows: 5, placeholder: 'Répondre ici', required: true = f.text_area :body, rows: 5, placeholder: 'Répondre ici', required: true
= f.file_field :file, accept: @commentaire.accept_extension_list .flex.justify-between
.send-wrapper %div
= f.submit 'Envoyer', class: 'button send', data: { disable_with: "Envoi..." } = f.file_field :file, id: :file, accept: @commentaire.file.accept_extension_list
%label{ for: :file }
.notice
(taille max : 20 Mo)
.send-wrapper
= f.submit 'Envoyer', class: 'button send', data: { disable_with: "Envoi…" }