From 6249a0aba7fea37989f0e7dda3b79e4fa6de8082 Mon Sep 17 00:00:00 2001 From: outfoxxed Date: Sun, 20 Oct 2024 03:09:48 -0700 Subject: [PATCH] fix docs collapsible color+margins --- src/styles/components/accordion.css | 5 ----- src/styles/docs/docs.css | 23 ++++++++++++++++------- 2 files changed, 16 insertions(+), 12 deletions(-) diff --git a/src/styles/components/accordion.css b/src/styles/components/accordion.css index ad8c873..db316b0 100644 --- a/src/styles/components/accordion.css +++ b/src/styles/components/accordion.css @@ -2,11 +2,6 @@ & summary { list-style: none; transition: background-color 0.15s ease-out; - - &:hover { - background-color: hsla(250 11 100 / 0.06); - cursor: pointer; - } } & .accordion-container { diff --git a/src/styles/docs/docs.css b/src/styles/docs/docs.css index a2c564a..398fa8a 100644 --- a/src/styles/docs/docs.css +++ b/src/styles/docs/docs.css @@ -151,6 +151,12 @@ ul { & summary { padding: 1.2rem; user-select: none; + box-shadow: 0 0 0.5rem 0px rgba(0 0 0 / 0.25); + + &:hover { + background-color: hsla(250 11 100 / 0.06); + cursor: pointer; + } & > div { display: flex; @@ -169,14 +175,17 @@ ul { & .accordion-container > div { padding: 0 1.2rem; - - & p:first-child { - padding-top: 0; - margin-top: 0; - } } } -.docs-collapsible[open]:not(.closing) > summary > div > svg { - transform: rotate(90deg); +.docs-collapsible[open]:not(.closing) { + & summary { + background-color: hsla(250 11 100 / 0.03); + &:hover { + background-color: hsla(250 11 100 / 0.06); + cursor: pointer; + } + + & div > svg { transform: rotate(90deg) } + } }