Skip to content

Commit

Permalink
Merge tag '2024-06-25-01' into devpf
Browse files Browse the repository at this point in the history
  • Loading branch information
Bounga committed Dec 6, 2024
2 parents 845707d + 9cbf1d3 commit e050631
Show file tree
Hide file tree
Showing 255 changed files with 5,745 additions and 2,220 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ public/downloads
doc/*.svg
uploads/*
.byebug_history
.DS_Store
*.swp
.envrc
.env
storage/
/node_modules
Expand Down
1 change: 1 addition & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ gem 'sidekiq'
gem 'sidekiq-cron'
gem 'skylight'
gem 'spreadsheet_architect'
gem 'string-similarity'
gem 'strong_migrations' # lint database migrations
gem 'sys-proctable'
gem 'turbo-rails'
Expand Down
2 changes: 2 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -790,6 +790,7 @@ GEM
activesupport (>= 5.2)
sprockets (>= 3.0.0)
stackprof (0.2.26)
string-similarity (2.1.0)
stringio (3.1.0)
strong_migrations (1.8.0)
activerecord (>= 5.2)
Expand Down Expand Up @@ -1045,6 +1046,7 @@ DEPENDENCIES
spring
spring-commands-rspec
stackprof
string-similarity
strong_migrations
sys-proctable
timecop
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified app/assets/images/faq/sign-in-page.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file modified app/assets/images/faq/usager-dropdown.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
9 changes: 9 additions & 0 deletions app/assets/stylesheets/conditions_component.scss
Original file line number Diff line number Diff line change
Expand Up @@ -59,5 +59,14 @@ form.form > .conditionnel {
select.alert {
border-color: $dark-red;
}

&:first-child {
padding-left: 0;
}

&:last-child {
text-align: right;
padding-right: 0;
}
}
}
12 changes: 12 additions & 0 deletions app/assets/stylesheets/dsfr.scss
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,18 @@ button.fr-tag-bug {
}
}

// on applique le comportement desktop du sélecteur de langue aux terminaux de toute dimension
.fr-translate .fr-menu__list {
display: grid;
grid-template-rows: repeat(var(--rows), auto);
grid-auto-flow: column;
}

.fr-translate__language[aria-current]:not([aria-current="false"]) {
display: inline-flex;
}


// on veut ajouter un gris plus clair dans le side_menu
.fr-sidemenu__item .fr-sidemenu__link.custom-link-grey {
color: var(--text-disabled-grey);
Expand Down
32 changes: 1 addition & 31 deletions app/assets/stylesheets/forms.scss
Original file line number Diff line number Diff line change
Expand Up @@ -698,41 +698,11 @@ textarea::placeholder {
color: $dark-grey;
}

@media (max-width: 62em) {

.padded-fixed-footer {
padding-top: 120px;
}
}

@media (min-width: 62em) {

.padded-fixed-footer {
padding-top: 60px;
}
}

[data-fr-theme="dark"] .fixed-footer {
border-top: 2px solid var(--background-action-low-blue-france-hover);
background-color: var(--background-action-low-blue-france);
}

.mandatory {
fill: currentColor;
}

.fixed-footer {
border-top: 2px solid $blue-france-500;
position: fixed;
bottom: 0;
left: 0;
right: 0;
padding-top: $default-padding;
background-color: $white;
z-index: 2;
}

.fr-menu__list {
:not(.fr-translate) .fr-menu__list {
padding: $default-spacer;
overflow-y: auto;

Expand Down
7 changes: 0 additions & 7 deletions app/assets/stylesheets/merci.scss

This file was deleted.

34 changes: 34 additions & 0 deletions app/assets/stylesheets/new_header.scss
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,37 @@
filter: none;
}
}

// Target mobile version
.fr-header__menu.fr-modal {
// Avoid overflow due to button width
overflow-x: hidden;

.fr-btn {
width: auto;
}

// Align links & buttons
.fr-translate {
margin-left: 0;
margin-right: 0;
}

// Align list content with other items
.fr-menu__list {
margin-left: 0.5rem;
}

// Add space between button edge and content
.fr-container .fr-header__menu-links .fr-btns-group.flex.align-center .fr-translate.fr-nav .fr-nav__item .fr-translate__btn.fr-btn {
margin-right: 0;
margin-left: 0;
padding-right: 0.5rem;
padding-left: 0.5rem;
}

// Remove border on when there is one item only
.fr-nav__item:only-child::before {
box-shadow: none;
}
}
155 changes: 3 additions & 152 deletions app/assets/stylesheets/stats.scss
Original file line number Diff line number Diff line change
@@ -1,162 +1,13 @@
@import "colors";
@import "constants";

$dark-grey: #333333;
$light-grey: #999999;

$default-space: 15px;

$new-h1-margin-bottom: 4 * $default-space;
$new-h2-margin-bottom: 3 * $default-space;

.new-h1,
.new-h2 {
color: $dark-grey;
text-align: center;
font-weight: bold;
}

.new-h1 {
margin-bottom: 3.75rem;
font-size: 2.5rem;
}

.new-h2 {
margin-bottom: $new-h2-margin-bottom;
font-size: 36px;
}

$statistiques-padding-top: $default-space * 2;

.statistiques {
width: 1040px;
margin: 0 auto;
padding-top: $statistiques-padding-top;
}

.stat-cards {
.stat-card:nth-of-type(even) {
margin-right: 0px;
}
}

$stat-card-margin-bottom: 3 * $default-space;

.stat-card {
padding: 15px;
margin-bottom: $stat-card-margin-bottom;
border-radius: 5px;
box-shadow: none;
border: 1px solid rgba(0, 0, 0, 0.15);
}

$stat-card-half-horizontal-spacing: 4 * $default-space;

.stat-card-half {
width: calc((100% - #{$stat-card-half-horizontal-spacing}) / 2);
margin-right: $stat-card-half-horizontal-spacing;
}

.stat-card-title {
color: $dark-grey;
font-size: 26px;
font-weight: bold;
width: 200px;
text-transform: uppercase;
}

.stat-card-details {
font-size: 13px;
font-style: italic;
}

$segmented-control-margin-top: $default-space;

.segmented-control {
border-radius: 36px;
height: 36px;
line-height: 36px;
font-size: 0;
padding: 0;
display: inline-block;
margin-top: $segmented-control-margin-top;
}

$segmented-control-item-horizontal-padding: $default-space;
$segmented-control-item-border-radius: 2 * $default-space;

.segmented-control-item {
display: inline-block;
font-size: 15px;
border: 2px solid $blue-france-700;
margin-right: -2px;
padding-top: var(--li-bottom);
padding-left: $segmented-control-item-horizontal-padding;
padding-right: $segmented-control-item-horizontal-padding;
color: $blue-france-700;

&:first-of-type {
border-radius: $segmented-control-item-border-radius 0px 0px $segmented-control-item-border-radius;
}

&:last-of-type {
border-radius: 0px $segmented-control-item-border-radius $segmented-control-item-border-radius 0px;
margin-right: 0;
}

&:hover {
background-color: $blue-france-500;
color: #FFFFFF;
cursor: pointer;
}
}

.segmented-control-item-active {
background-color: $blue-france-700;
color: #FFFFFF;
}

.chart-container {
margin-top: 36px;
}

.chart {
width: 100%;
}

$big-number-card-padding: 2 * $segmented-control-item-border-radius;

.big-number-card {
padding: $big-number-card-padding $segmented-control-item-horizontal-padding;
}

.big-number-card-title {
display: block;
text-align: center;
margin: 0 auto;
margin-bottom: 20px;
color: $light-grey;
text-transform: uppercase;

&.long-title {
margin-left: -30px;
margin-right: -30px;
}
}

.big-number-card-number {
display: block;
text-align: center;
font-size: 80px;
line-height: 1em;
font-size: 4.5rem;
line-height: 1.5em;
font-weight: bold;
color: $blue-france-500;
color: var(--text-title-blue-france);
white-space: nowrap;
}

.big-number-card-detail {
display: block;
margin-top: $default-padding;
text-align: center;
color: $blue-france-500;
}
49 changes: 49 additions & 0 deletions app/assets/stylesheets/sticky.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
@import "constants";

.fixed-footer {
border-top: 2px solid var(--border-plain-blue-france);
position: fixed;
bottom: 0;
left: 0;
right: 0;
padding-top: $default-padding;
background-color: var(--background-default-grey);
z-index: 2;
}

@media (max-width: 62em) {
.padded-fixed-footer {
padding-top: 120px;
}
}

@media (min-width: 62em) {
.padded-fixed-footer {
padding-top: 60px;
}
}

[data-fr-theme="dark"] .fixed-footer {
background-color: var(--background-action-low-blue-france);
}

.sticky-header {
padding-top: $default-padding;
padding-bottom: $default-padding;

&-container {
position: sticky;
top: 0;
left: 0;
right: 0;
z-index: 800;
}

&-warning {
background-color: var(--background-contrast-warning);
}

p {
margin: 0;
}
}
16 changes: 16 additions & 0 deletions app/components/autosave_notice_component.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# frozen_string_literal: true

class AutosaveNoticeComponent < ApplicationComponent
attr_reader :label_scope

def initialize(success:, label_scope:)
@success = success
@label_scope = label_scope
end

def success? = @success

def label
success? ? t(".#{label_scope}.saved") : t(".#{label_scope}.error")
end
end
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
en:
form:
saved: 'Form saved'
error: 'Form in error'
attestation:
saved: 'Attestation saved'
error: 'Attestation in error'
Loading

0 comments on commit e050631

Please sign in to comment.