fix(header): restore the payvip surface on the top-nav VIP chip
The 开通会员 chip rendered in the .jb-red orange gradient instead of the legacy metallic .payvip-icon gradient. The markup always carried payvip-icon, but core/buttons.css restates the legacy .but block and is bundled into public.css, which loads after main.css. Same specificity, later in the cascade, so its background / color / border / text-shadow declarations outrank .payvip-icon and replace the payvip surface with whatever .jb-* skin happens to be on the element. The reference theme has no such compatibility layer, so there its .payvip-icon declarations are the last word and the chip shows the metallic gradient with #ece0e0 text, no border and no text shadow. A previous fix restored the surface only for the user-card CTA, scoped to .aksrt-header-userbox .pay-vip.but.payvip-icon, which left the top-nav chip (and the guest CTA, and the user-card status bar) on the wrong gradient. Re-assert the legacy .payvip-icon declarations unscoped in header-userbox.css, which loads after core/buttons.css, and complete the property set with border: none and text-shadow: none so the chip no longer carries the 1px transparent border the .but block adds. Verified with a cascade resolver that replays the real stylesheet load order (bootstrap, main, public, header-userbox) against the reference theme's own order: background, color, --this-color, border, text-shadow, border-radius, padding, margin, font-size, display, overflow and position now resolve identically for both the publish and the VIP chip.
This commit is contained in:
1 parent
0722c4f00e
commit
5810693e01
5 files changed
+30
-6
No files matched your search
@@ -217,7 +217,12 @@ test('the account popover rows match the reference user box structure', () => {
|
||||
assert.match(header, /radius4 payvip-icon btn-block text-center/);
|
||||
assert.match(header, /vip-expdate-tag/);
|
||||
assert.match(header, /pay-vip but radius4 payvip-icon btn-block/);
|
||||
assert.match(userboxCss, /\.aksrt-header-userbox \.pay-vip\.but\.payvip-icon\s*\{[\s\S]*?background:\s*linear-gradient\(300deg,[\s\S]*?color:\s*#ece0e0;[\s\S]*?--this-color:\s*#ece0e0;/s);
|
||||
// core/buttons.css restates .but after main.css, which would otherwise replace
|
||||
// the legacy .payvip-icon surface with the .jb-* skin. The restoration must
|
||||
// cover background, color, border and text-shadow, and must not be scoped to
|
||||
// one call site or the top-nav chip keeps the wrong gradient.
|
||||
assert.match(userboxCss, /\.payvip-icon\s*\{[\s\S]*?background:\s*linear-gradient\(300deg,[\s\S]*?color:\s*#ece0e0;[\s\S]*?--this-color:\s*#ece0e0;[\s\S]*?border:\s*none;[\s\S]*?text-shadow:\s*none;/s);
|
||||
assert.doesNotMatch(userboxCss, /\.aksrt-header-userbox \.pay-vip\.but\.payvip-icon/)
|
||||
assert.doesNotMatch(header, /vipbg-v2/);
|
||||
|
||||
// Check-in entry is an anchor with the reference button classes.
|
||||
|
||||
Reference in new issue
Block a user