feat(options): logo top margin (logotopmargin)

- config.xml: new duration option "logotopmargin" in the Images category (default 15px).
- custom_header.twig: sets padding-top of the header logos, so 0px aligns a logo
  exactly with the top of the screen.

Generated by Mistral Vibe.
Co-Authored-By: Mistral Vibe <vibe@mistral.ai>
This commit is contained in:
Tammo ter Hark 2026-11-16 19:51:19 +01:00
commit b6a9ac74db
3 changed files with 11 additions and 0 deletions

View file

@ -36,3 +36,9 @@ Option `navbarfontcolor` (Colors category) sets the text color of the menu
items in the navbar; it is applied in `views/subviews/header/custom_header.twig`
and should contrast with `headerbackgroundcolor`.
## Distance from the logo to the top of the screen
Option `logotopmargin` (Images category, e.g. `15px` or `0px`) sets the top
padding of the header logos, applied in `custom_header.twig`. Use `0px` to
align a logo exactly with the top of the screen.

View file

@ -73,6 +73,7 @@
<centerlogofile type="imagefile" category="Images" width="7" title="Logo file (center)" parent="centerlogo">./files/logo.png</centerlogofile>
<rightlogo type="buttons" category="Images" width="2" title="Display logo on the right of the header" options="on|off" optionlabels="Yes|No">off</rightlogo>
<rightlogofile type="imagefile" category="Images" width="7" title="Logo file (right)" parent="rightlogo">./files/logo2.png</rightlogofile>
<logotopmargin type="duration" category="Images" width="3" title="Distance from the logo to the top of the screen (use 0px to align a logo exactly with the very top)">15px</logotopmargin>
<backgroundimage type="buttons" category="Images" width="4" title="Background image (behind body of page)" options="on|off" optionlabels="Yes|No">on</backgroundimage>
<backgroundimagefixed type="buttons" category="Images" width="4" title="Background image fixed or scroll" options="fixed|scroll" optionlabels="Fixed|Scroll">scroll</backgroundimagefixed>
<backgroundimagedisplay type="buttons" category="Images" width="4" title="Background image display" options="tile|cover" optionlabels="Tile|Cover">tile</backgroundimagedisplay>

View file

@ -145,6 +145,10 @@
background-color: {{ aSurveyInfo.options.headerbackgroundcolor }};
}
#survey-nav .logo-container > img {
padding-top: {{ aSurveyInfo.options.logotopmargin }};
}
#survey-nav .navbar-nav > li > a,
#survey-nav .navbar-nav .nav-link {
color: {{ aSurveyInfo.options.navbarfontcolor }};