2017-06-14 14:42:09 +02:00
.patron
2017-07-06 14:14:16 +02:00
.container
2019-10-23 12:07:21 +02:00
%h1 Icônes
2017-07-27 16:16:14 +02:00
2017-12-12 14:51:44 +01:00
%span.icon.follow
%span.icon.unfollow
%span.icon.archive
%span.icon.unarchive
%span.icon.folder
2019-03-26 17:55:40 +01:00
%span.icon.new-folder
2017-12-12 14:51:44 +01:00
%span.icon.accept
%span.icon.refuse
%span.icon.without-continuation
%span.icon.edit
%span.icon.in-progress
%span.icon.bubble
2019-10-22 12:21:16 +02:00
%span.icon.attached
2017-12-12 14:51:44 +01:00
%span.icon.lock
2019-10-23 13:17:11 +02:00
%span.icon.add
2019-10-15 12:42:51 +02:00
%span.icon.justificatif
2017-12-12 14:51:44 +01:00
%span.icon.printer
2018-07-09 12:54:58 +02:00
%span.icon.account
%span.icon.person
%span.icon.super-admin
%span.icon.mail
2019-07-16 12:11:24 +02:00
%span.icon.reply
2018-07-09 12:54:58 +02:00
%span.icon.search
%span.icon.sign-out
2018-07-11 17:10:56 +02:00
%span.icon.info
2019-03-11 17:26:44 +01:00
%span.icon.delete
2019-03-13 16:49:13 +01:00
%span.icon.help
%span.icon.phone
%span.icon.clock
2019-10-15 12:42:51 +02:00
%span.icon.preview
2020-03-30 15:34:56 +02:00
%span.icon.retry
2018-09-17 15:06:50 +02:00
%span.icon.download
2019-10-15 12:42:51 +02:00
%span.icon.download-white
2019-04-03 16:18:31 +02:00
%span.icon.move-handle
2018-08-08 17:37:41 +02:00
%span.icon.frown
%span.icon.meh
%span.icon.smile
2017-07-27 16:16:14 +02:00
2017-07-18 15:39:21 +02:00
%h1 Formulaires
2017-06-14 17:39:46 +02:00
2017-06-20 11:13:24 +02:00
%form.form
2017-08-02 14:56:08 +02:00
= form_for @dossier, url: '', html: { class: 'form' } do |f|
2022-11-10 22:21:14 +01:00
= f.fields_for :champs_public do |champ_form|
2022-09-08 11:25:39 +02:00
= render EditableChamp::EditableChampComponent.new champ: champ_form.object, form: champ_form
2017-08-02 14:56:08 +02:00
2019-10-09 17:35:33 +02:00
.editable-champ.editable-champ-text
%label Mot de passe
%input{ type: "password", value: "12345678" }
2020-02-10 19:16:00 +01:00
%h3.header-subsection Bouton radio verticaux
.radios.vertical
= f.label :archived, value: true do
= f.radio_button :archived, true
Option A
%p.notice Une option tout à fait valable.
= f.label :archived, value: false do
= f.radio_button :archived, false
Option B
%p.notice Une autre option, pas mal non plus.
2019-10-23 12:07:21 +02:00
2020-07-23 11:22:57 +02:00
%h3.header-subsection Interrupteur
2020-07-24 12:02:40 +02:00
%label.toggle-switch
2020-07-23 11:22:57 +02:00
= f.check_box :archived, class: 'toggle-switch-checkbox'
%span.toggle-switch-control.round
%span.toggle-switch-label.on Activé
%span.toggle-switch-label.off Désactivé
2017-08-02 14:56:08 +02:00
.send-wrapper
= f.submit 'Enregistrer un brouillon (formnovalidate)', formnovalidate: true, class: 'button send'
2019-01-24 16:30:41 +01:00
= f.submit 'Envoyer', class: 'button send primary'
2017-06-14 17:39:46 +02:00
2018-07-11 17:11:19 +02:00
%hr
2017-07-18 15:39:21 +02:00
%h1 Boutons
2017-06-14 14:42:09 +02:00
2019-02-21 16:21:20 +01:00
.patron-section
2017-06-20 11:13:24 +02:00
= link_to ".button", "#", class: "button"
2017-06-14 14:42:09 +02:00
2017-06-20 11:13:24 +02:00
= link_to ".button.primary", "#", class: "button primary"
2017-06-14 14:42:09 +02:00
2017-06-26 11:40:28 +02:00
= link_to ".button.secondary", "#", class: "button secondary"
2018-07-24 17:43:28 +02:00
= link_to ".button.danger", "#", class: "button danger"
2017-09-14 10:36:01 +02:00
2017-12-12 14:53:36 +01:00
= link_to "#", class: "button" do
%span.icon.follow
= "Bouton avec icone et texte"
= link_to "#", class: "button icon-only" do
%span.icon.follow
2019-02-21 16:21:20 +01:00
.patron-section
2018-07-18 16:20:51 +02:00
%button.button{ disabled: true } .button.disabled
%button.button.primary{ disabled: true } .button.primary.disabled
%button.button.secondary{ disabled: true } .button.secondary.disabled
%button.button.danger{ disabled: true } .button.danger.disabled
2019-02-21 16:21:20 +01:00
.patron-section
2018-07-24 17:43:07 +02:00
= link_to ".button.accepted", "#", class: "button accepted"
= link_to ".button.refused", "#", class: "button refused"
= link_to ".button.without-continuation", "#", class: "button without-continuation"
2019-02-21 16:21:20 +01:00
.patron-section
2019-02-18 17:42:32 +01:00
= link_to ".button.small", "#", class: "button small"
= link_to ".button.small.primary", "#", class: "button small primary"
2019-02-21 16:21:20 +01:00
.patron-section
2017-06-20 11:13:24 +02:00
= link_to ".button.large", "#", class: "button large"
2017-06-14 14:42:09 +02:00
2017-06-20 11:13:24 +02:00
= link_to ".button.large.primary", "#", class: "button large primary"
2017-06-14 14:57:30 +02:00
2019-02-21 16:21:20 +01:00
.patron-section
2017-06-20 11:13:24 +02:00
= link_to ".button.primary.expand", "#", class: "button primary expand"
2019-03-12 14:38:29 +01:00
%h1 Dropdown
.dropdown
.button.primary.dropdown-button .button.primary.dropdown-button
.dropdown-content.fade-in-down
%ul.dropdown-items
%li .dropdown-content ul.dropdown-items li
%li .dropdown-content ul.dropdown-items li
.dropdown
.button.dropdown-button .button.dropdown-button
.dropdown-content.fade-in-down
%ul.dropdown-items
2019-03-13 11:35:26 +01:00
%li
%a{ href: '#' }
%span.icon.mail
.dropdown-description
%h4 Action
%p Explanation
%li
%a{ href: '#' }
%span.icon.edit
.dropdown-description
%h4 Other action
%p Explanation
2019-03-12 14:38:29 +01:00
.dropdown
.button.dropdown-button .button.dropdown-button (left)
.dropdown-content.fade-in-down.left-aligned
%ul.dropdown-items
%li .dropdown-content.left-aligned ul.dropdown-items li
%li .dropdown-content.left-aligned ul.dropdown-items li
2017-07-18 15:39:21 +02:00
%h1 Labels
2017-07-03 16:29:29 +02:00
%span.label .label
2018-03-29 10:39:43 +02:00
%span.label.brouillon .label.brouillon
2017-07-27 14:53:18 +02:00
%span.label.instruction .label.instruction
%span.label.construction .label.construction
2017-11-24 10:37:27 +01:00
%span.label.accepted .label.accepted
2017-07-27 14:53:18 +02:00
%span.label.refused .label.refused
%span.label.without-continuation .label.without-continuation
2017-07-03 16:29:29 +02:00
2017-09-20 15:47:57 +02:00
%h1 Badges
%span.badge 1
%span.badge.warning 1
2017-07-18 15:39:21 +02:00
%h1 Cards
2017-07-06 15:49:29 +02:00
.card
.card-title
Titre de la carte
2019-02-21 16:21:20 +01:00
%p Et voici le contenu de la carte
2017-07-06 15:49:29 +02:00
.card.featured
.card-title
Titre de la carte mise en avant
2019-02-21 16:21:20 +01:00
%p Et voici le contenu de la carte
2017-07-06 15:49:29 +02:00
2019-07-09 16:21:45 +02:00
.card.warning
.card-title
Titre de la carte d’ avertissement
%p Et voici le contenu de la carte
2018-06-26 17:00:01 +02:00
.card.feedback
.card-title
Titre de la carte pour demander un avis
2019-02-21 16:21:20 +01:00
%p Utilisez cette carte pour informer d’ une nouveauté produit ou demander l’ avis des utilisateurs.
2018-06-26 17:00:01 +02:00
2017-07-18 15:39:21 +02:00
%h1 Table
2017-07-06 16:25:51 +02:00
2017-07-27 16:02:35 +02:00
%table.table
%thead
%tr
%th Header 1
%th Header 2
%tbody
%tr
%td Table Data 1
%td Table Data 2
%tr
2017-07-27 16:27:29 +02:00
%td Table Data 3
%td Table Data 4
%h2 Hoverable (.table.hoverable)
%table.table.hoverable
%thead
%tr
%th Header 1
%th Header 2
%tbody
%tr
%td Table Data 1
%td Table Data 2
%tr
2017-07-27 16:02:35 +02:00
%td Table Data 3
%td Table Data 4
2017-07-27 15:30:25 +02:00
%h2 Vertical layout (.table.vertical)
%table.table.vertical
2017-07-06 16:25:51 +02:00
%tbody
%tr
%th Header 1
%td Table Data 1
%tr
%th Header 2
%td Table Data 2
2017-07-11 16:50:29 +02:00
%tr
%th.header-section{ colspan: 2 } Header section
2017-07-06 16:25:51 +02:00
%tr
%th Header 3
%td Table Data 3
2017-07-18 15:39:21 +02:00
%h1 Header
2018-04-23 17:22:20 +02:00
.sub-header
2017-07-18 15:03:04 +02:00
.container
Titre
2021-12-24 18:10:50 +01:00
%nav.tabs
%ul
= tab_item("Onglet actif", "#", active: true)
= tab_item("Onglet inactif", "#")
= tab_item("Onglet avec badge", "#", badge: 2)
= tab_item("Onglet avec notification", "#", notification: true)
2017-07-18 15:03:04 +02:00
.container
2017-07-18 15:39:21 +02:00
%h1 Breadcrumbs
2017-07-18 15:38:31 +02:00
%ul.breadcrumbs
%li
2018-09-05 14:48:42 +02:00
= link_to "Démarche 123", "#"
2017-07-18 15:38:31 +02:00
%li
= "Dossier n° 38"
2017-07-18 15:39:21 +02:00
%h1 Layout deux colonnes
2017-06-20 11:13:24 +02:00
.two-columns
.columns-container
.column
Insérer ici le contenu de la colonne 1
.column
Insérer ici le contenu de la colonne 2
2017-09-06 14:08:03 +02:00
.container
%section.ask-avis
%h1 Inviter une personne à donner son avis
2021-05-26 15:16:30 +02:00
%p.avis-notice L’ invité pourra consulter, donner un avis sur le dossier et contribuer au fil de messagerie, mais il ne pourra le modifier.
2017-09-06 14:08:03 +02:00
= form_for Avis.new, url: '/', html: { class: 'form' } do |f|
= f.email_field :email, placeholder: 'Adresse email', required: true
= f.text_area :introduction, rows: 3, value: 'Bonjour, merci de me donner votre avis sur ce dossier.', required: true
.send-wrapper
= f.submit 'Demander un avis', class: 'button send'
%section.list-avis
%h1.title
Avis des invités
2022-10-06 12:58:02 +02:00
%span.fr-badge 1
2017-09-06 14:08:03 +02:00
%ul
%li.one-avis
%h2.claimant
Vous
2021-05-26 15:16:30 +02:00
%span.date Demande d’ avis envoyée le 12/01/2012
2017-09-06 14:08:03 +02:00
%p Bonjour, merci de me donner votre avis sur ce dossier.
.answer.flex.align-start
2017-10-16 18:29:40 +02:00
.icon.bubble.avis-icon
2017-09-06 14:08:03 +02:00
.width-100
2019-08-06 11:02:54 +02:00
%h2.instructeur
2018-05-31 15:43:57 +02:00
= CONTACT_EMAIL
2017-09-06 14:08:03 +02:00
%span.date Réponse donnée le 13/01/2012
%p Je donne un avis favorable
2017-09-20 17:07:09 +02:00
.container
%h2.empty-text Aucun dossier
2018-06-28 11:14:02 +02:00
%p.empty-text-details Vous n’ avez commencé aucune démarche pour l’ instant.
2022-09-07 14:54:16 +02:00
.container
2022-09-16 00:07:16 +02:00
%h1 Dsfr::CalloutComponent
2022-10-18 13:59:50 +02:00
%p= link_to "Documentation DSFR Mis en avant (callout)", "https://www.systeme-de-design.gouv.fr/elements-d-interface/composants/mise-en-avant", **external_link_attributes
2022-09-16 00:07:16 +02:00
= render Dsfr::CalloutComponent.new(title: "Information minimale") do |c|
- c.with_body do
%p Ceci est le minimum pour afficher un callout.
= render Dsfr::CalloutComponent.new(title: "Information importante ou avertissement", theme: :warning) do |c|
- c.with_body do
2022-10-18 13:59:50 +02:00
Le contenu de cette description est libre.
- c.with_bottom do
%button.fr-btn Call to action
2022-09-16 00:07:16 +02:00
= render Dsfr::CalloutComponent.new(title: "Titre d'une information positive", theme: :success, icon: "fr-icon-message-2-fill") do |c|
- c.with_body do
%p
N'importe quelle icône
= link_to("du jeu d'icônes", "https://www.systeme-de-design.gouv.fr/elements-d-interface/fondamentaux-techniques/icones", **external_link_attributes)
peut être utilisée.
2022-09-07 15:46:54 +02:00
%h1 Dsfr::CardVerticalComponent
2022-10-18 13:59:50 +02:00
%p= link_to "Documentation DSFR Carte", "https://www.systeme-de-design.gouv.fr/elements-d-interface/composants/carte", **external_link_attributes
2022-09-07 14:54:16 +02:00
.fr-grid-row.fr-grid-row--gutters.fr-py-5w
.fr-col-md-6.fr-col-12
2022-09-07 15:46:54 +02:00
= render Dsfr::CardVerticalComponent.new(title: "Optional title", desc: "Optional description")
2022-09-07 14:54:16 +02:00
.fr-col-md-6.fr-col-12
2022-09-07 15:46:54 +02:00
= render Dsfr::CardVerticalComponent.new(title: "With footer buttons") do |c|
2022-09-07 14:54:16 +02:00
- c.with_footer_button do
= link_to "Button 1", "#", class: "fr-btn", **external_link_attributes
- c.with_footer_button do
= button_tag "Button 2", class: "fr-btn fr-btn--secondary"
2022-09-14 15:32:56 +02:00
%h1 Dsfr::NoticeComponent
2022-10-18 13:59:50 +02:00
%p= link_to "Documentation DSFR Bandeau d'information", "https://www.systeme-de-design.gouv.fr/elements-d-interface/composants/bandeau-d-information-importante", **external_link_attributes
2022-09-14 15:32:56 +02:00
.my-3
= render Dsfr::NoticeComponent.new(closable: true) do |c|
- c.with_title do
Titre de cette notice
= link_to "avec un lien optionnel.", "#"
Des marges verticales ont ici été rajoutées.
2022-11-09 12:33:20 +01:00
.container
%h1.fr-mt-4w Attachment::EditComponent
%span.fr-hint-text Note: direct upload, suppression ne marchent pas comme attendu ici.
- champ = @dossier.champs_public.first
- tdc = @dossier.champs_public.find { _1.type_champ == TypeDeChamp.type_champs.fetch(:piece_justificative) }.type_de_champ
2022-11-17 19:18:58 +01:00
- avis = Avis.new
2022-11-09 12:33:20 +01:00
- if attachment = ActiveStorage::Attachment.last
- attachment.update(created_at: 1.second.ago)
%h3 New attachment
= render Attachment::EditComponent.new(champ:, attached_file: champ.piece_justificative_file, attachment: nil)
%h3.fr-mt-4w Existing attachment
= render Attachment::EditComponent.new(champ:, attached_file: champ.piece_justificative_file, attachment:)
2022-11-21 18:32:17 +01:00
%h3.fr-mt-4w Existing attachment, user can not destroy
= render Attachment::EditComponent.new(champ:, attached_file: champ.piece_justificative_file, attachment:, user_can_destroy: false)
2022-11-09 12:33:20 +01:00
%h3.fr-mt-4w Existing attachment, antivirus in progress
- attachment.blob.metadata[:virus_scan_result] = ActiveStorage::VirusScanner::PENDING
- attachment.created_at = Time.zone.now
= render Attachment::EditComponent.new(champ:, attached_file: Champ.new.piece_justificative_file, attachment:)
%h3.fr-mt-4w Existing attachment, antivirus in progress since long time
- attachment.blob.metadata[:virus_scan_result] = ActiveStorage::VirusScanner::PENDING
- attachment.created_at = 2.minutes.ago
= render Attachment::EditComponent.new(champ:, attached_file: Champ.new.piece_justificative_file, attachment:)
%h3.fr-mt-4w Existing attachment, error
- attachment.blob.metadata[:virus_scan_result] = ActiveStorage::VirusScanner::INFECTED
= render Attachment::EditComponent.new(champ:, attached_file: Champ.new.piece_justificative_file, attachment:)
2022-11-21 18:32:17 +01:00
2022-11-17 19:18:58 +01:00
%h3.fr-mt-4w New attachment on TypeDeChamp
2022-11-09 12:33:20 +01:00
= render Attachment::EditComponent.new(auto_attach_url: "/some-auto-attach-path", attached_file: tdc.piece_justificative_template, attachment: nil)
2022-12-08 00:15:05 +01:00
%h3.fr-mt-4w Existing attachment on TypeDeChamp, view as link
2022-11-09 12:33:20 +01:00
= render Attachment::EditComponent.new(auto_attach_url: "/some-auto-attach-path", attached_file: tdc.piece_justificative_template, attachment: attachment.reload)
2022-12-08 00:15:05 +01:00
%h3.fr-mt-4w Existing attachment on TypeDeChamp view as download
= render Attachment::EditComponent.new(auto_attach_url: "/some-auto-attach-path", attached_file: tdc.piece_justificative_template, attachment: attachment.reload, view_as: :download)
2022-11-17 19:18:58 +01:00
%h3.fr-mt-4w New attachment on generic object
= render Attachment::EditComponent.new(attached_file: avis.introduction_file)
2022-12-08 00:15:05 +01:00
%h3.fr-mt-4w Existing attachment on generic object, view as download
= render Attachment::EditComponent.new(attached_file: avis.introduction_file, attachment: attachment.reload, view_as: :download)
2022-11-17 19:18:58 +01:00