Skip to content
Discussion options

You must be logged in to vote

On the "why": the change came with #41953, which rebuilt the accordion on native <details>/<summary> with the name attribute. The PR description doesn't give a specific reason for moving the chevron into markup, so only the maintainers can answer that. Since v6 is still in alpha, this thread is the right place to push for an automatic icon.

You can get one back today, though, without touching the markup. In 6.0.0-alpha.1, the chevron's size, rotation and transition are all driven by accordion CSS variables. A ::after on .accordion-header can use the same variables, with the SVG stored in a custom property as you suggested:

.accordion {
  --accordion-auto-icon: url("data:image/svg+xml,%3cs…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by scottdorman
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants