- <SeoPagination> (UI-SPEC L2): previous and next (left out at the ends), page 1, the last page and five pages around the current one with gap items; nothing when last <= 1; props current, last, labels, classPrefix, locale - usePagination(): hrefs in the CMS form (resolve answer, then site answer, then seo.pagination), other query parameters kept, page 1 unnumbered, <link rel=prev/next> in the head - the CMS head fills %pages% in the title and description once the listing's page count is known (seoFillPages) - seoPaginationWindow, seoPageHref, seoPageNumber; L2 default styles
99 lines
2.6 KiB
CSS
99 lines
2.6 KiB
CSS
/* SEO layer base styles. Only .seo-* classes, never a bare element or
|
|
another layer's classes; values come from seo-tokens.css, and the app's
|
|
own CSS (loaded after the layers') wins. Long names and titles wrap and
|
|
are never truncated: the full text stays in the HTML. */
|
|
|
|
/* Visually hidden, still read by screen readers (the new-tab hint inside
|
|
external links, labels of icon-only controls). */
|
|
.seo-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;
|
|
clip-path: inset(50%) !important;
|
|
white-space: nowrap !important;
|
|
border: 0 !important;
|
|
}
|
|
|
|
/* The focus ring of every layer link: 2px in the accent colour. */
|
|
.seo-breadcrumbs a:focus-visible,
|
|
.seo-pagination a:focus-visible,
|
|
.seo-sitemap a:focus-visible,
|
|
.seo-sitemap-link:focus-visible {
|
|
outline: 2px solid var(--seo-color-accent);
|
|
outline-offset: 2px;
|
|
}
|
|
|
|
/* L1 breadcrumbs: a wrapping row, separators generated here (never read by
|
|
screen readers), the current page muted and bold. */
|
|
.seo-breadcrumbs {
|
|
font-size: var(--seo-font-size-small);
|
|
}
|
|
.seo-breadcrumbs__list {
|
|
display: flex;
|
|
flex-wrap: wrap;
|
|
align-items: center;
|
|
list-style: none;
|
|
margin: 0 0 var(--seo-space-4);
|
|
padding: 0;
|
|
}
|
|
.seo-breadcrumbs__item {
|
|
overflow-wrap: anywhere;
|
|
}
|
|
.seo-breadcrumbs__item + .seo-breadcrumbs__item::before {
|
|
content: var(--seo-breadcrumbs-separator) / '';
|
|
color: var(--seo-color-muted);
|
|
padding-inline: var(--seo-space-2);
|
|
}
|
|
.seo-breadcrumbs__link {
|
|
display: inline-block;
|
|
padding-block: var(--seo-space-1);
|
|
}
|
|
.seo-breadcrumbs__current {
|
|
color: var(--seo-color-muted);
|
|
font-weight: 600;
|
|
}
|
|
|
|
/* L2 pagination: previous, the page list and next in a wrapping row;
|
|
44px targets; the current page on the accent colour. */
|
|
.seo-pagination {
|
|
display: flex;
|
|
flex-wrap: wrap;
|
|
align-items: center;
|
|
gap: var(--seo-space-3);
|
|
margin-top: var(--seo-space-5);
|
|
}
|
|
.seo-pagination__pages {
|
|
display: flex;
|
|
flex-wrap: wrap;
|
|
align-items: center;
|
|
gap: var(--seo-space-1);
|
|
list-style: none;
|
|
margin: 0;
|
|
padding: 0;
|
|
}
|
|
.seo-pagination__prev,
|
|
.seo-pagination__next,
|
|
.seo-pagination__pages a,
|
|
.seo-pagination__current,
|
|
.seo-pagination__gap {
|
|
display: inline-flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
min-width: var(--seo-target-size);
|
|
min-height: var(--seo-target-size);
|
|
padding-inline: var(--seo-space-2);
|
|
box-sizing: border-box;
|
|
}
|
|
.seo-pagination__current {
|
|
background: var(--seo-color-accent);
|
|
color: var(--seo-color-on-accent);
|
|
font-weight: 600;
|
|
}
|
|
.seo-pagination__gap {
|
|
color: var(--seo-color-muted);
|
|
}
|