Merge pull request #10691 from colinux/fix-attestation-footer
ETQ usager, l'attestation v2 gère mieux les pieds de page
This commit is contained in:
commit
3b3697a67e
2 changed files with 14 additions and 5 deletions
|
@ -27,6 +27,7 @@
|
||||||
font-size: 8pt;
|
font-size: 8pt;
|
||||||
content: counter(page) " / " counter(pages);
|
content: counter(page) " / " counter(pages);
|
||||||
margin-top: 17mm;
|
margin-top: 17mm;
|
||||||
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
@bottom-left {
|
@bottom-left {
|
||||||
|
@ -41,11 +42,12 @@
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
justify-content: space-between; // This will push the footer down
|
justify-content: space-between; // This will push the footer down
|
||||||
max-width: 21cm;
|
max-width: 21cm;
|
||||||
height: 29.7cm;
|
min-height: 29.7cm;
|
||||||
padding: 17mm;
|
padding: 17mm;
|
||||||
margin: 0 auto;
|
margin: 0 auto;
|
||||||
background: #FFFFFF;
|
background: #FFFFFF;
|
||||||
box-shadow: 0 0 10px rgba(0, 0, 0, 0.5); // Optional: for better visualization
|
box-shadow: 0 0 10px rgba(0, 0, 0, 0.5); // Optional: for better visualization
|
||||||
|
position: relative;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -165,9 +167,15 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.footer {
|
footer {
|
||||||
position: running(footer);
|
position: running(footer);
|
||||||
font-size: 7pt;
|
font-size: 7pt;
|
||||||
font-weight: 100;
|
font-weight: 100;
|
||||||
|
white-space: nowrap;
|
||||||
|
|
||||||
|
@media screen {
|
||||||
|
position: absolute;
|
||||||
|
bottom: 0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -30,12 +30,13 @@
|
||||||
- if @attestation_template.label_direction.present?
|
- if @attestation_template.label_direction.present?
|
||||||
= simple_format @attestation_template.label_direction, class: "direction"
|
= simple_format @attestation_template.label_direction, class: "direction"
|
||||||
|
|
||||||
|
- if @attestation_template.footer.present?
|
||||||
|
%footer
|
||||||
|
= simple_format @attestation_template.footer
|
||||||
|
|
||||||
.main
|
.main
|
||||||
= sanitize(@body, attributes: %w[class style], tags: Rails.configuration.action_view.sanitized_allowed_tags + %w[header])
|
= sanitize(@body, attributes: %w[class style], tags: Rails.configuration.action_view.sanitized_allowed_tags + %w[header])
|
||||||
|
|
||||||
- if @attestation_template.signature.present?
|
- if @attestation_template.signature.present?
|
||||||
.signature
|
.signature
|
||||||
= image_tag(@attestation_template.signature_url)
|
= image_tag(@attestation_template.signature_url)
|
||||||
|
|
||||||
- if @attestation_template.footer.present?
|
|
||||||
= simple_format @attestation_template.footer, class: "footer"
|
|
||||||
|
|
Loading…
Reference in a new issue