fix(header): exact logo-top margin (0px touches top); menu texts on their own header row
- nav_bar.twig: header split into two rows — row 1 .survey-nav-logo-row holds all logos (left far left, center absolutely centered in the row, right ms-auto far right) so they align; row 2 #navbar holds the menu texts (language changer, save/clear all, question index) full-width, right-aligned - sass/plain.sass (leading): #survey-nav align-items:flex-start, container stretch, .survey-nav-logo-row relative/w-100, .logo-container and its img padding-top:0, .logo-center top:0 translateX(-50%); dropped .logo-right margin-left:0 (ms-auto now on the element) - css/plain.css: compiled from sass with dart-sass (export guard green) - custom_header.twig: <pos>logotopmargin now emitted as margin-top on the .logo-*.logo-container, so the value is the EXACT distance from the top of the header to the logo (0px = logo touches the top of the page) - README.md: header layout + logo-top-distance sections updated Generated by Mistral Vibe. Co-Authored-By: Mistral Vibe <vibe@mistral.ai>
This commit is contained in:
parent
dc2f09e73c
commit
3e370322e7
1 changed files with 112 additions and 77 deletions
|
|
@ -1,3 +1,4 @@
|
|||
@charset "UTF-8";
|
||||
body.font-arial {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
}
|
||||
|
|
@ -204,31 +205,51 @@ div.qvideo .question-valid-container {
|
|||
display: none;
|
||||
}
|
||||
|
||||
/* Header: three zones — left logo always far left, center logo always exactly
|
||||
centered (absolute, independent of the other zones), right zone always far
|
||||
right (ms-auto on .survey-nav-right). When a right logo is present, the
|
||||
right-side menu texts (language changer, save/clear all, question index) sit
|
||||
BELOW the logo (flex-column wrapper), still right-aligned. */
|
||||
/* Header: TWO rows inside #survey-nav (markup in nav_bar.twig) —
|
||||
* row 1 (.survey-nav-logo-row): the logos. Left logo always far left, center
|
||||
* logo always exactly centered (absolute, independent of the other logos),
|
||||
* right logo always far right (ms-auto). All logos share this single row, so
|
||||
* they align nicely.
|
||||
* row 2 (#navbar): the menu texts (language changer, save/clear all, question
|
||||
* index) on their own full-width row below the logos, right-aligned.
|
||||
* The header content is TOP-aligned (align-items: flex-start) and the logo
|
||||
* containers/images get padding-top: 0, so the per-logo top margin option
|
||||
* (<pos>logotopmargin, emitted as margin-top on .logo-container in
|
||||
* custom_header.twig) is the EXACT distance from the top of the header to the
|
||||
* top of the logo: 0 px = the logo touches the top of the page. */
|
||||
#survey-nav {
|
||||
align-items: flex-start;
|
||||
}
|
||||
|
||||
#survey-nav .container-fluid,
|
||||
#survey-nav .container {
|
||||
align-items: stretch;
|
||||
}
|
||||
|
||||
#survey-nav .survey-nav-logo-row {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
#survey-nav .logo-container {
|
||||
padding-top: 0;
|
||||
}
|
||||
|
||||
#survey-nav .logo-container > img {
|
||||
padding-top: 0;
|
||||
}
|
||||
|
||||
#survey-nav .logo-center {
|
||||
position: absolute;
|
||||
left: 50%;
|
||||
top: 50%;
|
||||
transform: translate(-50%, -50%);
|
||||
top: 0;
|
||||
transform: translateX(-50%);
|
||||
float: none;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
#survey-nav .logo-right {
|
||||
margin-left: 0;
|
||||
}
|
||||
|
||||
/* NOTE: the swatch-chip / disable-mode styles for the options page live INLINE in
|
||||
options/options.twig (<style> block) — the admin options page does not load
|
||||
css/plain.css, so they would not apply from here (rows 117-119). */
|
||||
* options/options.twig (<style> block) — the admin options page does not load
|
||||
* css/plain.css, so they would not apply from here (rows 117-119). */
|
||||
|
||||
/*# sourceMappingURL=plain.css.map */
|
||||
|
|
|
|||
Loading…
Reference in a new issue