fix(options): mark the default color choice with [ ] in the dropdown, not bold
Row 134: bolding <option> text is not rendered by every browser (native dropdown popups ignore it), so the default entry of a color-chooser dropdown is now enclosed in square brackets instead — e.g. "[Default font color] [#444444]". The brackets live in config.xml on the <option data-default="1"> (navbarfontcolor + the five <el>textcolor dropdowns), so they show even before JS runs; options.js strips and re-adds them idempotently while appending the live hexcode. Removed from the dropdown list: the <b> wrap (row 129), the inline font-weight (row 132), the CSS option[data-default] rule and the :has() closed-select rule. The bold REMAINS only on the swatch label below the swatch (.color-chip-label.is-default), where it renders reliably. OPTIONS_JS_TOKEN -> 20261126.13. Verified: render tc=618 (raw option "[Default font color]", served options.js?v=20261126.13), jsdom 6/6 incl. pins (label "[Default font color] [#444444]", no <b>/inline bold/stale CSS rules, non-default not bracketed, swatch label still bold), export exit 0. Variants not rebuilt (deferred). Generated by Mistral Vibe. Co-Authored-By: Mistral Vibe <vibe@mistral.ai>
This commit is contained in:
parent
1b6ae85f83
commit
57c7009ec2
1 changed files with 35 additions and 46 deletions
|
|
@ -43,7 +43,7 @@
|
|||
heuristically cached copy (the file has only Last-Modified/ETag, no Cache-Control).
|
||||
Re-register it with a version token: bump OPTIONS_JS_TOKEN below whenever
|
||||
options/options.js changes, so every browser fetches the new file once. #}
|
||||
{% set OPTIONS_JS_TOKEN = '20261126.12' %}
|
||||
{% set OPTIONS_JS_TOKEN = '20261126.13' %}
|
||||
{{ unregisterScriptFile(optionsPath ~ '/options.js') }}
|
||||
{{ registerScriptFile(optionsPath ~ '/options.js?v=' ~ OPTIONS_JS_TOKEN, 'POS_END') }}
|
||||
|
||||
|
|
@ -154,18 +154,11 @@
|
|||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
/* row 126: the DEFAULT choice of a color-chooser option (the config.xml
|
||||
<option data-default="1">) is shown in bold — in the dropdown (CSS below)
|
||||
and on its swatch label (is-default class set by options.js) */
|
||||
select option[data-default="1"] {
|
||||
font-weight: 700;
|
||||
}
|
||||
/* row 132: also bold the CLOSED select box when the default choice is the
|
||||
selected one (the popup alone is not enough — some browsers ignore option
|
||||
styling in the closed box) */
|
||||
.action_update_options_string_form select:has(option[data-default="1"]:checked) {
|
||||
font-weight: 700;
|
||||
}
|
||||
/* row 126/134: the DEFAULT choice of a color-chooser option (the config.xml
|
||||
<option data-default="1">) is enclosed in [ ] in the dropdown list — bolding
|
||||
<option> text is not rendered by every browser, so brackets are used there
|
||||
instead. The bold remains ONLY on the swatch label below the swatch
|
||||
(is-default class set by options.js). */
|
||||
.color-chip-label.is-default {
|
||||
font-weight: 700;
|
||||
color: #212529;
|
||||
|
|
|
|||
Loading…
Reference in a new issue