1.5.3: shared-menu 1.2.2, and run the glyph style instead of reading it

678f1f03 is withdrawn. It hard-coded the icon box at 36x34, and WordPress
declares that parent three times with different sizes — 36x34 open, 35x30
folded, 34x30 under 960px — so a fixed number is correct in one state and 4px
too tall in the two a laptop is usually in. cache-manager measured where the
ink lands rather than where the box is and found it worse than that: the glyph
moved from 2.5px above centre to 2.5px below in the folded states, the same
error mirrored, in a state that had been nearly right. 1.2.2 removes the number
entirely with width/height at 100%.

1.5.2 is already published with 678f1f03, so this tree shipped the withdrawn
version. Checked before anything else, because a later candidate fatalled on
every admin page with "Unknown format specifier": that file was never taken
here, and the published 1.5.2 emits its stylesheet cleanly — verified by
running sprintf over its format string rather than reading it. So the shop is
cosmetically off in folded menus, not broken.

New assertion, and it is the one this round is really about: the style
function is INVOKED and its output captured, rather than the source being
read. The fatal that prompted it survived three sessions reading the file,
a clean php -l, a clean PHPCS, and two browsers agreeing about the CSS —
because every one of those was fed the stylesheet by hand rather than through
the printf that produces it. A literal per-cent must be doubled in a format
string, and nothing that looks at the file can see that.

Proven red with that exact fault rather than an arbitrary one: undoubling the
per-cent gives "ValueError: Unknown format specifier ';'".

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
kristianwind
2026-09-20 19:07:44 +02:00
co-authored by Claude Opus 5
parent db5c5e33c8
commit 6a789349ec
5 changed files with 77 additions and 19 deletions
+6 -2
View File
@@ -75,7 +75,11 @@ RELEASE_REPO=kw/nolimit-discounts-dist
# The frozen hash is therefore a family-wide fact, not a local one, and taking
# a new one is something all six do in the same window.
#
# 678f1f03 = contract 1.2.1: the glyph is centred with flex inside an explicit
# 471b0a2a = contract 1.2.2: the icon box is sized 100%/100% instead of a
# hardcoded 36x34. WordPress declares that parent three times and they
# disagree (36x34 open, 35x30 folded, 34x30 under 960px), so a fixed number is
# right in one state and wrong in the two a laptop is usually in.
# Withdrawn: 678f1f03 = 1.2.1: the glyph is centred with flex inside an explicit
# 36x34 box instead of inheriting WordPress's 7px padding, which made the
# pseudo-element 42px tall inside a 34px parent and pushed the sign above
# centre. Kristian reported it from the live shop.
@@ -87,4 +91,4 @@ RELEASE_REPO=kw/nolimit-discounts-dist
# backslashes, hex digits and spaces, so there is nothing left to leave the
# string with. Verified here against seven hostile inputs.
# Earlier frozen hashes: 184cebdc = 1.1.0, f4862d5c = 1.0.0.
WPMGR_MENU_SHA=678f1f0368fcc781ce34c0289f6470a6bb0491bc32c0598e859c7ceba66e5e2a
WPMGR_MENU_SHA=471b0a2aab47b6b7f8d839ac8b12d60637bbe2c07df86f7e40089c677fbab3cc