@sarimarcus/content-sites-ui 0.38.1 → 0.39.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,10 @@
|
|
|
2
2
|
|
|
3
3
|
All packages in the platform release in lockstep; entries are per release version.
|
|
4
4
|
|
|
5
|
+
## 0.39.0 (2026-10-16)
|
|
6
|
+
|
|
7
|
+
- `layout`: new `AudienceFilters`, the sr-only `audience:<a>` Pagefind filter spans that `EntityDetailShell` and `EventPage` each wrote inline; both now render it, with identical HTML (SLA-3045).
|
|
8
|
+
|
|
5
9
|
## 0.38.1 (2026-10-15)
|
|
6
10
|
|
|
7
11
|
- No changes; lockstep release with tourism (SLA-3125).
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sarimarcus/content-sites-ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.39.0",
|
|
4
4
|
"description": "Universal Astro UI components, layout shell and design tokens shared by the content sites.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -50,6 +50,6 @@
|
|
|
50
50
|
"@lucide/astro": "^1.23.0",
|
|
51
51
|
"astro": "^7.0.6",
|
|
52
52
|
"tailwindcss": "^4.1.18",
|
|
53
|
-
"@sarimarcus/content-sites-core": "0.
|
|
53
|
+
"@sarimarcus/content-sites-core": "0.39.0"
|
|
54
54
|
}
|
|
55
55
|
}
|
|
@@ -18,6 +18,7 @@
|
|
|
18
18
|
*/
|
|
19
19
|
import Container from '../layout/Container.astro';
|
|
20
20
|
import Badge from '../primitives/Badge.astro';
|
|
21
|
+
import AudienceFilters from '../layout/AudienceFilters.astro';
|
|
21
22
|
import BreadcrumbBand from '../layout/BreadcrumbBand.astro';
|
|
22
23
|
import { newTab } from '../primitives/newTab';
|
|
23
24
|
import type { TrustedHtml } from '../types';
|
|
@@ -72,7 +73,7 @@ const withClass = (base: string, s?: Section) => (s?.class ? `${base} ${s.class}
|
|
|
72
73
|
</BreadcrumbBand>
|
|
73
74
|
|
|
74
75
|
<div data-pagefind-body data-pagefind-meta={`type:${pagefindType}`}>
|
|
75
|
-
|
|
76
|
+
<AudienceFilters audiences={audiences} /><slot name="hero" />
|
|
76
77
|
</div>
|
|
77
78
|
|
|
78
79
|
<main class="pt-6 pb-12 lg:pt-8 lg:pb-20">
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
---
|
|
2
|
+
/**
|
|
3
|
+
* AudienceFilters — one sr-only `audience:<a>` Pagefind filter span per audience, so a detail page is filterable by who
|
|
4
|
+
* it is for without showing the list. Rendered inside the page's `data-pagefind-body` wrapper, before the hero.
|
|
5
|
+
*/
|
|
6
|
+
interface Props {
|
|
7
|
+
audiences?: readonly string[];
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
const { audiences = [] } = Astro.props;
|
|
11
|
+
---
|
|
12
|
+
{audiences.map((a) => <span class="sr-only" data-pagefind-filter={`audience:${a}`}>{a}</span>)}
|
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
* - `column={false}`: the default slot goes into <main> as is, for a body that leaves the column.
|
|
11
11
|
* - `closer`: renders the `closer` slot in a default Container; it defaults to whether that slot was passed.
|
|
12
12
|
*/
|
|
13
|
+
import AudienceFilters from './AudienceFilters.astro';
|
|
13
14
|
import BreadcrumbBand from './BreadcrumbBand.astro';
|
|
14
15
|
import Container from './Container.astro';
|
|
15
16
|
|
|
@@ -42,7 +43,7 @@ const wrapsPage = Boolean(pagefindType) && pagefindScope === 'page';
|
|
|
42
43
|
{/* <main> is spelled out per branch: a dynamic wrapper tag buffers its children and moved hoisted scripts above it. */}
|
|
43
44
|
{wrapsPage ? (
|
|
44
45
|
<div data-pagefind-body data-pagefind-meta={meta}>
|
|
45
|
-
|
|
46
|
+
<AudienceFilters audiences={audiences} />
|
|
46
47
|
<slot name="hero" />
|
|
47
48
|
<main class={mainClass}>
|
|
48
49
|
{column ? (
|
|
@@ -60,13 +61,11 @@ const wrapsPage = Boolean(pagefindType) && pagefindScope === 'page';
|
|
|
60
61
|
<Fragment>
|
|
61
62
|
{pagefindType ? (
|
|
62
63
|
<div data-pagefind-body data-pagefind-meta={meta}>
|
|
63
|
-
|
|
64
|
+
<AudienceFilters audiences={audiences} />
|
|
64
65
|
<slot name="hero" />
|
|
65
66
|
</div>
|
|
66
67
|
) : (
|
|
67
|
-
<Fragment
|
|
68
|
-
{audiences.map((a) => <span class="sr-only" data-pagefind-filter={`audience:${a}`}>{a}</span>)}
|
|
69
|
-
<slot name="hero" />
|
|
68
|
+
<Fragment><AudienceFilters audiences={audiences} /><slot name="hero" />
|
|
70
69
|
</Fragment>
|
|
71
70
|
)}
|
|
72
71
|
<main class={mainClass}>
|
package/src/layout/index.ts
CHANGED
|
@@ -4,6 +4,7 @@ export { default as ContentHero } from './ContentHero.astro';
|
|
|
4
4
|
export { default as BreadcrumbBand } from './BreadcrumbBand.astro';
|
|
5
5
|
export { default as ListingShell } from './ListingShell.astro';
|
|
6
6
|
export { default as EntityDetailShell } from './EntityDetailShell.astro';
|
|
7
|
+
export { default as AudienceFilters } from './AudienceFilters.astro';
|
|
7
8
|
export { default as AsyncStylesheet } from './AsyncStylesheet.astro';
|
|
8
9
|
export { default as DocumentShell } from './DocumentShell.astro';
|
|
9
10
|
export { default as ConsentAnalytics } from './ConsentAnalytics.astro';
|