/* Live demos (components/Demo.vue). */
.caelrik-demo {
margin: 1.5rem 0;
border: 1px solid var(--vp-c-divider);
border-radius: 6px;
overflow: hidden;
}
.caelrik-demo__bar {
display: flex;
flex-wrap: wrap;
gap: 0.5rem 1rem;
align-items: center;
padding: 0.5rem 0.75rem;
font-size: 0.875rem;
background: var(--vp-c-bg-soft);
border-bottom: 1px solid var(--vp-c-divider);
}
.caelrik-demo__bar a {
margin-left: auto;
}
.caelrik-demo iframe {
display: block;
width: 100%;
border: 0;
background: var(--vp-c-bg);
}
.caelrik-demo figcaption {
padding: 0.375rem 0.75rem;
font-size: 0.8125rem;
color: var(--vp-c-text-2);
border-top: 1px solid var(--vp-c-divider);
}
.visually-hidden {
position: absolute !important;
width: 1px !important;
height: 1px !important;
padding: 0 !important;
margin: -1px !important;
overflow: hidden !important;
clip: rect(0, 0, 0, 0) !important;
white-space: nowrap !important;
border: 0 !important;
}
/* Accessible brand colors (WCAG 1.4.3): Caelrik's blue, with white text on buttons. */
:root {
--vp-c-brand-1: #0a58ca;
--vp-c-brand-2: #084298;
--vp-c-brand-3: #0a58ca;
--vp-c-brand-soft: rgba(10, 88, 202, 0.14);
--vp-button-brand-bg: #0a58ca;
--vp-button-brand-hover-bg: #084298;
--vp-button-brand-active-bg: #052c65;
--vp-button-brand-text: #fff;
--vp-button-brand-hover-text: #fff;
--vp-button-brand-active-text: #fff;
}
.dark {
--vp-c-brand-1: #6ea8fe;
--vp-c-brand-2: #9ec5fe;
--vp-c-brand-3: #0a58ca;
--vp-c-brand-soft: rgba(110, 168, 254, 0.16);
}
/* The language label of code blocks, at 4.5:1 on the code background. */
.vp-doc [class*='language-'] > span.lang {
color: var(--vp-c-text-2);
}
/* The search button is named "Search": hide the shortcut hint so its visible text matches
its accessible name (WCAG 2.5.3). Ctrl+K and / still open the search. */
.DocSearch-Button-Keys {
display: none !important;
}
/* Flat design, like the components (resources/scss/_flat.scss): 1px borders instead of
shadows and filled panels, and one small corner radius. VitePress's component styles
are scoped ([data-v-?]): ":root" and a repeated class make these win over them. */
:root {
--vp-shadow-1: none;
--vp-shadow-2: none;
--vp-shadow-3: none;
--vp-shadow-4: none;
--vp-shadow-5: none;
--vp-sidebar-bg-color: var(--vp-c-bg);
--caelrik-docs-radius: 6px;
}
:root .VPButton.VPButton {
border-radius: var(--caelrik-docs-radius);
}
/* The secondary button is outlined, not a grey pill. */
:root .VPButton.VPButton.alt {
background-color: transparent;
border-color: var(--vp-c-divider);
}
:root .VPButton.VPButton.alt:hover {
background-color: var(--vp-c-default-soft);
}
/* Home page features: outlined, not grey cards. */
:root .VPFeature.VPFeature {
background-color: transparent;
border: 1px solid var(--vp-c-divider);
border-radius: var(--caelrik-docs-radius);
}
/* Search button: an outlined field, like the components' inputs. */
:root .DocSearch-Button.DocSearch-Button {
background-color: transparent;
border: 1px solid var(--vp-c-divider);
border-radius: var(--caelrik-docs-radius);
}
/* Search dialog and flyout menus: a border instead of a shadow. */
:root .VPLocalSearchBox .shell.shell {
border: 1px solid var(--vp-c-divider);
border-radius: var(--caelrik-docs-radius);
}
:root .VPMenu.VPMenu {
border-radius: var(--caelrik-docs-radius);
}
/* Sidebar on the page background, set apart by a line. */
@media (min-width: 960px) {
:root .VPSidebar.VPSidebar {
border-right: 1px solid var(--vp-c-divider);
}
}
/* Code blocks, tips and warnings, and the demos: the same small radius. */
.vp-doc div[class*='language-'],
.vp-doc .custom-block,
.caelrik-demo {
border-radius: var(--caelrik-docs-radius);
}
|