feat(options): Questions tab starts with 'Overall question' section + 2 distance options (plan P1)
Questions pane now has h2 'Questions' + intro paragraph, then an h3
'Overall question' section rendered as ONE col-md-6 column holding two new
text options — questiondistance ('Distance between two questions') and
questiondistancebottom ('Distance between last question and buttons at
bottom of page'), both default 30px and accepting px or rem — followed by a
full-width hr before the existing 3-column grid. custom_header.twig applies
them as CSS: .question-container margin-bottom and #navigator-container
margin-top, guarded to ^<number>(px|rem)$ with fallback 30px. config.xml:
both keys first in the Questions category, width=6 (row 160 rule). All
variants rebuilt + example config synced. jsdom: new row-179 assertions,
suite 8/8; live survey page emits both rules at 30px.
Generated by Mistral Vibe.
Co-Authored-By: Mistral Vibe <vibe@mistral.ai>
This commit is contained in:
parent
c4d728445d
commit
c4ec304dd0
1 changed files with 54 additions and 6 deletions
|
|
@ -91,6 +91,21 @@
|
|||
}
|
||||
{% endif %}
|
||||
|
||||
{# Row 179 / plan P1: distances in the Questions tab ("Overall question" section).
|
||||
Free text in px or rem (default 30px); only emitted when the value matches
|
||||
^<number>(px|rem)$ — anything else falls back to 30px. questiondistance is
|
||||
the margin-bottom between two question containers (parent theme.css uses
|
||||
2em), questiondistancebottom the margin-top of the bottom navigator with
|
||||
the Previous/Next/Submit buttons. #}
|
||||
{% set sQuestionDistance = aSurveyInfo.options.questiondistance|default('30px') %}
|
||||
{% set sQuestionDistanceBottom = aSurveyInfo.options.questiondistancebottom|default('30px') %}
|
||||
.question-container {
|
||||
margin-bottom: {{ sQuestionDistance matches '/^\\d+(\\.\\d+)?(px|rem)$/' ? sQuestionDistance : '30px' }};
|
||||
}
|
||||
#navigator-container {
|
||||
margin-top: {{ sQuestionDistanceBottom matches '/^\\d+(\\.\\d+)?(px|rem)$/' ? sQuestionDistanceBottom : '30px' }};
|
||||
}
|
||||
|
||||
{% if (aSurveyInfo.options.questionborder == "box" ) %}
|
||||
.question-container,
|
||||
#welcome-container,
|
||||
|
|
|
|||
Loading…
Reference in a new issue