Generic link hover color overrides header cart icon color
维护者通常 1 天内回复
@HardeepAsrani 已经在做这个了。
开始于 2026年9月30日。
评估
这个 Issue 还没有评估数据。
描述
Summary
The header cart icon does not retain its configured hover color after the recent Neve update. The cart link is expected to use its component --hovercolor value while hovered, but the inspected CSS cascade applies Neve's secondary accent instead. This prevents the cart component's color setting from determining the visible hover state and has led to a child-theme !important workaround.
Customer context
Product / area: Neve header cart component with Neve Pro styling active
Version: Exact installed versions were not provided; the relevant Neve change first shipped in 4.2.13 and remains in 4.2.14
Environment: WordPress frontend using WooCommerce and a child theme
Integration / third party: WooCommerce; Neve Pro Addon is present
Reported error / symptom: Cart icon hover color resolves to the Neve secondary accent rather than the component hover color
Impact: Configured cart styling is not reflected without a CSS specificity workaround
Reproduction notes
- Use Neve 4.2.13 or 4.2.14 with WooCommerce and a header cart component.
- Configure a cart hover color distinct from Neve's secondary accent.
- Hover the
.cart-icon-wrapperlink or focus it with the keyboard. - Observe that the computed color comes from the generic Neve link-state rule rather than the cart component's configured hover value.
The customer supplied the conflicting selectors and reported that an !important child-theme override restores the desired state. A clean local runtime reproduction was not performed.
Diagnosis
Conclusion
This is a confirmed CSS-specificity regression. Neve 4.2.13 changed the generic hover/focus color selector from a:hover / a:focus to a:not([class*="button"]):hover / :focus. The resulting selector has greater specificity than .cart-icon-wrapper:hover, so the global secondary-accent color wins over the cart component's configured color. Commit 17a3c2e0da2446dd162acc4459ada710bbb91ed2 introduced the selector; tag comparison shows the lower-specificity behavior in 4.2.12 and the conflict in 4.2.13. No later typography change exists through 4.2.14.
Where this likely occurs
- User-visible surface: WooCommerce cart component in the Neve header on hover and focus.
assets/scss/components/main/_typography.scss— global anchor state rules, approx. lines 52–60, selectora:not([class*="button"]): assigns--nv-secondary-accentwith specificity above the cart rule.assets/scss/components/compat/woocommerce/_nav-cart.scss— cart component styling, lines 6–12, selector.cart-icon-wrapper:hover: assigns--hovercolorwith a fallback to--colorbut loses the cascade.header-footer-grid/templates/components/component-cart-icon.php— cart component template, approx. line 52, emits the affected anchor with classcart-icon-wrapper.- Git history: commit
17a3c2e0dis contained in release tags 4.2.13 and 4.2.14; release 4.2.12 retains the lower-specificity generic anchor selector.
Engineering notes
The cart anchor class does not contain button, so it is inside the new global selector's scope. The inspected conflict is deterministic from the emitted selectors: the global rule has specificity (0,2,1), while the cart hover rule has (0,2,0). The cart SVG inherits the anchor's currentColor through the component styling path. The defect is routed to Neve because both the regression-producing global selector and the cart component's intended hover rule are in the theme repository.
Test coverage status
tests/test-neve-cart-guards.php checks cart rendering guards and the presence of cart-icon-wrapper, but not computed styling. The Neve Pro WooCommerce Booster e2e suites cover cart behavior, while the searched Neve and Pro suites contain no computed hover-color assertion for cart-icon-wrapper. No relevant color-state coverage was found during inspection.
What to verify or explore next
- Reproduce with Neve 4.2.14 by assigning distinct secondary-accent and cart hover colors, then inspect the cart link's computed color during hover and keyboard focus.
- Compare the same WooCommerce header configuration under Neve 4.2.12 and 4.2.13 to validate the identified release boundary at runtime.
- Run the Neve cart guard test and relevant WooCommerce Booster Playwright suites after exercising the computed hover/focus color path.
Unknowns / follow-up
The customer's exact Neve, Neve Pro, and WooCommerce versions were not stated. Runtime reproduction was not performed, but the reported selectors and deterministic cascade match the inspected released source.
Confidence
Confidence: 98/100
Repository inspection confirms that Neve 4.2.13 increased the generic link-state selector's specificity above both affected header-component selectors, and the regression remains in 4.2.14. No matching open GitHub issue was found for either independently testable symptom.
Source: HelpScout #3466631245
Generated by bug-report-triage (ID: bug-report-triage_6abbeeb198c984.22566267)
- 主要语言
- PHP
- 星标
- 307
- 派生
- 88
- 平均合并
- 2 天 21 小时
- 30 天内合并 PR
- 15
环境准备
- 提供 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
Codeinwp/neve 的其他 Issue
-
Customizer responsive sanitizer fatals when input is an array可能已有人在做 @HardeepAsrani 于 5 天前认领。 未关闭bug-report bug-report-triage crash-report
难度 2/5 1-3 小时 新手友好度 66/100
Codeinwp/neve#4651 · 已指派 1 人 ·
维护者通常 1 天内回复
-
Customizer controls script throws when WooCommerce is inactive and an Elementor shop template exists (woocommerce_product_catalog section missing)可能已有人在做 @girishpanchal30 于 1 天前认领。 未关闭bug-report bug-report-triage customer report
Codeinwp/neve#4653 · 3 条评论 · 已指派 1 人 ·
维护者通常 1 天内回复
-
Duplicate H1: hidden screen-reader title H1 rendered alongside custom layout H1 when page title is hidden可能已有人在做 @HardeepAsrani 于 2 天前认领。 未关闭bug-report bug-report-triage customer report
难度 4/5 1-2 天 新手友好度 48/100
Codeinwp/neve#4652 · 已指派 1 人 ·
维护者通常 1 天内回复
-
feature-request-triage
难度 5/5 一周以上 新手友好度 25/100
维护者通常 1 天内回复
-
feature-request-triage
难度 4/5 3-5 天 新手友好度 48/100
维护者通常 1 天内回复
相似的 Issue
-
feature request
难度 1/5 1 小时以内 新手友好度 88/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 72/100
Automattic/blocks-engine#2803 ·
维护者通常 1 天内回复
-
bug
难度 2/5 1-3 小时 新手友好度 72/100
hestiacp/hestiacp#5798 · 2 条评论 ·
维护者通常 1 天内回复
-
Bug Component: HTTP Component: Telemetry
难度 2/5 1-3 小时 新手友好度 74/100
-
难度 2/5 1-3 小时 新手友好度 62/100
woocommerce/woocommerce-google-analytics-integration#699 ·
维护者通常 1 天内回复