feat(options): Groups tab with intro and two columns; group colors become color choosers; font options Normal|Bold|Italic|Bold italic

Row 157. Groups pane gets a full-width h2 'Groups' + explanatory text and a
two-column slot layout: col 1 = group title options (font, color, custom,
size, font options), col 2 = same for the group description (singular wording).
grouptitletextcolor/groupdescriptiontextcolor switch from the old 4-way
dropdown to the row-135 color chooser (6 modes, default 'Default font color',
swatch chips, grayed-out custom picker unless 'other'); legacy stored modes
primary/secondary and raw hex migrate client-side (options.js) and in the views.
The old *fontweight keys (400|700) become *fontoptions (normal|bold|italic|
bolditalic), mapped to font-weight/font-style in custom_header.twig with a
legacy 400/700 fallback until theme reset. build.php migrates variant jsons
(chooser hex/modes + fontweight keys). OPTIONS_JS_TOKEN 20261127.1.

Generated by Mistral Vibe.
Co-Authored-By: Mistral Vibe <vibe@mistral.ai>
This commit is contained in:
Tammo ter Hark 2026-11-27 02:50:06 +01:00
commit 956324775b

View file

@ -440,24 +440,40 @@
<option value="other">Other…</option>
</dropdownoptions></answerstextcolor>
<answerstextcolorcustom type="colorpicker" category="Questions" width="12" title="Custom text color for answers and help texts" parent="answerstextcolor">#444444</answerstextcolorcustom>
<!-- Row 157: the group options are shown in the dedicated "Groups" tab (pulled
out of the Questions category by aGroupKeys in options.twig, laid out in
two columns there: col 1 = group title, col 2 = group description).
grouptitletextcolor/groupdescriptiontextcolor use the color-chooser scheme
(row 135 pattern: mode dropdown default|defaultbackgroundcolor|color1|
color2|color3|other + <key>custom child, default "Default font color" =
mode "default"); a legacy stored mode "primary"/"secondary" (old 4-mode
dropdown) or a raw hex migrates client-side in options.js, and the views
accept both. The old <el>fontweight keys (400|700) became <el>fontoptions
(normal|bold|italic|bolditalic) — font-style included; custom_header.twig
maps them to font-weight/font-style. Defaults keep the old look: title
bold, description normal. -->
<grouptitlefont type="fontselect" category="Questions" width="4" title="Font for group titles">base</grouptitlefont>
<grouptitletextcolor type="dropdown" category="Questions" width="12" title="Text color for group titles" options="default|primary|secondary|other" optionlabels="Default font color|Primary color|Secondary color|Other…">default
<grouptitletextcolor type="dropdown" category="Questions" width="12" title="Group title color" options="default|defaultbackgroundcolor|color1|color2|color3|other" optionlabels="Default font color|Default background color|Color 1|Color 2|Color 3|Other ...">default
<dropdownoptions>
<option value="default" data-default="1">[Default font color]</option>
<option value="primary">Primary color</option>
<option value="secondary">Secondary color</option>
<option value="other">Other…</option>
<option value="defaultbackgroundcolor">Default background color</option>
<option value="color1">Color 1</option>
<option value="color2">Color 2</option>
<option value="color3">Color 3</option>
<option value="other">Other ...</option>
</dropdownoptions></grouptitletextcolor>
<grouptitletextcolorcustom type="colorpicker" category="Questions" width="12" title="Custom text color for group titles" parent="grouptitletextcolor">#444444</grouptitletextcolorcustom>
<groupdescriptionfont type="fontselect" category="Questions" width="4" title="Font for group descriptions">base</groupdescriptionfont>
<groupdescriptiontextcolor type="dropdown" category="Questions" width="12" title="Text color for group descriptions" options="default|primary|secondary|other" optionlabels="Default font color|Primary color|Secondary color|Other…">default
<grouptitletextcolorcustom type="colorpicker" category="Questions" width="12" title="Custom group title color (for 'Other ...')" parent="grouptitletextcolor">#444444</grouptitletextcolorcustom>
<groupdescriptionfont type="fontselect" category="Questions" width="4" title="Font for group description">base</groupdescriptionfont>
<groupdescriptiontextcolor type="dropdown" category="Questions" width="12" title="Group description color" options="default|defaultbackgroundcolor|color1|color2|color3|other" optionlabels="Default font color|Default background color|Color 1|Color 2|Color 3|Other ...">default
<dropdownoptions>
<option value="default" data-default="1">[Default font color]</option>
<option value="primary">Primary color</option>
<option value="secondary">Secondary color</option>
<option value="other">Other…</option>
<option value="defaultbackgroundcolor">Default background color</option>
<option value="color1">Color 1</option>
<option value="color2">Color 2</option>
<option value="color3">Color 3</option>
<option value="other">Other ...</option>
</dropdownoptions></groupdescriptiontextcolor>
<groupdescriptiontextcolorcustom type="colorpicker" category="Questions" width="12" title="Custom text color for group descriptions" parent="groupdescriptiontextcolor">#444444</groupdescriptiontextcolorcustom>
<groupdescriptiontextcolorcustom type="colorpicker" category="Questions" width="12" title="Custom group description color (for 'Other ...')" parent="groupdescriptiontextcolor">#444444</groupdescriptiontextcolorcustom>
<buttonsfont type="fontselect" category="Questions" width="4" title="Font for the buttons (Previous/Next/Submit)">base</buttonsfont>
<buttonstextcolor type="dropdown" category="Questions" width="12" title="Text color for the buttons (Previous/Next/Submit)" options="default|primary|secondary|other" optionlabels="Default font color|Primary color|Secondary color|Other…">default
<dropdownoptions>
@ -470,9 +486,9 @@
<questiontitlefontsize type="buttons" category="Questions" width="6" title="Question title font size" options="1.0rem|1.2rem|1.5rem|2.0rem|20px|24px" optionlabels="Same as Base Font Size(BFS)|1.2 BFS|1.5 BFS|2.0 BFS|20px|24px">1.2rem</questiontitlefontsize>
<questiontitlefontweight type="buttons" category="Questions" width="6" title="Question title font weight" options="400|700" optionlabels="Normal|Bold">700</questiontitlefontweight>
<grouptitlefontsize type="buttons" category="Questions" width="6" title="Group title font size" options="1.0rem|1.2rem|1.5rem|2.0rem|20px|24px" optionlabels="Same as Base Font Size(BFS)|1.2 BFS|1.5 BFS|2.0 BFS|20px|24px">2.0rem</grouptitlefontsize>
<grouptitlefontweight type="buttons" category="Questions" width="6" title="Group title font weight" options="400|700" optionlabels="Normal|Bold">700</grouptitlefontweight>
<grouptitlefontoptions type="buttons" category="Questions" width="6" title="Group title font options" options="normal|bold|italic|bolditalic" optionlabels="Normal|Bold|Italic|Bold italic">bold</grouptitlefontoptions>
<groupdescriptionfontsize type="buttons" category="Questions" width="6" title="Group description font size" options="1.0rem|1.2rem|1.5rem|2.0rem|20px|24px" optionlabels="Same as Base Font Size(BFS)|1.2 BFS|1.5 BFS|2.0 BFS|20px|24px">1.2rem</groupdescriptionfontsize>
<groupdescriptionfontweight type="buttons" category="Questions" width="6" title="Group description font weight" options="400|700" optionlabels="Normal|Bold">400</groupdescriptionfontweight>
<groupdescriptionfontoptions type="buttons" category="Questions" width="6" title="Group description font options" options="normal|bold|italic|bolditalic" optionlabels="Normal|Bold|Italic|Bold italic">normal</groupdescriptionfontoptions>
</options>
<!-- Here datas about how LimeSurvey should load the theme -->