accordion.pcss.css

Same filename in other branches
  1. 9 core/themes/claro/css/components/accordion.pcss.css
  2. 8.9.x core/themes/claro/css/components/accordion.pcss.css
  3. 10 core/themes/claro/css/components/accordion.pcss.css

Accordion styles.

File

core/themes/claro/css/components/accordion.pcss.css

View source
  1. /**
  2. * @file
  3. * Accordion styles.
  4. */
  5. .accordion {
  6. --accordion-color: var(--color-text);
  7. --accordion-border-size: var(--details-border-size);
  8. --accordion-border-color: var(--details-border-color);
  9. --accordion-border-radius: var(--details-accordion-border-size-radius);
  10. --accordion-bg-color: var(--color-white);
  11. --accordion-box-shadow: var(--details-box-shadow);
  12. color: var(--accordion-color);
  13. border: var(--accordion-border-size) solid var(--accordion-border-color);
  14. border-radius: var(--accordion-border-radius);
  15. background-color: var(--accordion-bg-color);
  16. box-shadow: var(--accordion-box-shadow);
  17. }
  18. .accordion__item {
  19. --accordion-item-border-radius: var(--details-accordion-border-size-radius);
  20. margin: 0 -1px;
  21. border-radius: 0;
  22. &:first-child {
  23. margin-top: -1px;
  24. border-top-left-radius: var(--accordion-item-border-radius);
  25. border-top-right-radius: var(--accordion-item-border-radius);
  26. }
  27. & + .accordion__item {
  28. margin-top: -1px;
  29. }
  30. &:last-child {
  31. margin-bottom: -1px;
  32. border-bottom-right-radius: var(--accordion-item-border-radius);
  33. border-bottom-left-radius: var(--accordion-item-border-radius);
  34. }
  35. & .claro-details__summary .summary {
  36. --accordion-summary-color: var(--color-gray-800);
  37. display: block;
  38. color: var(--accordion-summary-color);
  39. font-weight: normal;
  40. }
  41. }

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.