@sarimarcus/content-sites-tourism 0.31.2 → 0.31.4

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,21 @@
2
2
 
3
3
  All packages in the platform release in lockstep; entries are per release version.
4
4
 
5
+ ## 0.31.4 (2026-10-08)
6
+
7
+ - `./templates` and `./sections`: `CategoryFacetTone` is `BrandTone | 'secondary-overlay'`, the facet nav `accent` and `SituationalScenario.tone` are ui `BrandTone`; `./cards` `NeighborhoodBadgeTone` is `BrandTone | 'overlay'`. Type-only (SLA-3020).
8
+
9
+ ### Deprecated
10
+
11
+ - `./schema` `monumentBuilder`, `museumBuilder`, `restaurantBuilder`, `barBuilder`, `dishBuilder`, `neighborhoodBuilder`, `GUIDE_ITEM_TYPES` and `MonumentOptions`, `RestaurantOptions`, `BarOptions`, `DishOptions`: no site imports them; `tourismCityBuilders(city)` builds every one. Removed in the next minor (SLA-3020).
12
+ - `./schema` builder options no caller sets: `MonumentOptions.touristType`, `RestaurantOptions.menuSectionName`, `BarOptions.menuSectionName` and `tapasCuisine`, `DishOptions.articleSection` and `inLanguage`, and `guideItemListBuilder`'s `itemTypes`. They still apply when passed, so JSON-LD is unchanged. Removed in the next minor. `touristTripBuilder` and `TouristTripOptions` stay: they replace core's deprecated pair (SLA-3020).
13
+
14
+ ## 0.31.3 (2026-10-08)
15
+
16
+ - `./cards`: `EventCard` renders on ui `EntityCard` (poster variant, `h-48 sm:h-56` media) with a ui `ArrowLabel` "Discover" CTA in place of the `Icon` arrow-right (svg gains `shrink-0`); props are unchanged. Intended output changes: the image gains the reduced-motion zoom cancel (`motion-reduce:group-hover:scale-100`), non-priority images no longer emit `fetchpriority="auto"`, and whitespace around the frame changes. Pages: `events` and `index` on both tourism sites and Granada's `neighborhood/` pages that rail EventCards (SLA-3019).
17
+ - `./cards`: `NeighborhoodCard` stays off EntityCard but takes its frame conventions: the card link gains the focus-visible ring (`ring-2 ring-primary ring-offset-2 rounded-xl`), `motion-reduce:group-hover:scale-100` cancels the image's hover zoom under `prefers-reduced-motion` (replacing the scoped `article img` transition rule; the attractions-panel rule stays), and non-priority images no longer emit `fetchpriority="auto"` (featured or index 0 keeps `"high"`). The dropped selector leaves the inline `<style>` of every page that bundles NeighborhoodCard's scoped CSS (137 Córdoba and 118 Granada pages whose markup is otherwise unchanged) (SLA-3019).
18
+ - `./sections`: `NeighborhoodHubHero` (badge) and `NeighborhoodCategory` (the `authentic` header) draw map-pin through ui `Icon`; the glyph takes Lucide's current map-pin outline at the same size and colour. Markup changes: `neighborhoods` on both tourism sites (hub hero badge and `authentic` header) (SLA-3019).
19
+
5
20
  ## 0.31.2 (2026-10-08)
6
21
 
7
22
  - `./cards`: `RestaurantCard`, `BarCard`, `MonumentCard`/`MuseumCard`, `DishCard` and `WalkCard` render on ui `EntityCard`; every card's props are unchanged and Monument, Dish and Restaurant keep `eager` default 1 and `priority`. Intended output changes: Restaurant, Monument/Museum and Dish non-priority images drop `fetchpriority="auto"` (the spec default); the first `WalkCard` gains `fetchpriority="high"`; Monument's scoped `<style>` and its cid attributes are gone (its reduced-motion zoom cancel, which did not stop Tailwind's `scale`, is replaced by EntityCard's); whitespace around the frame changes (SLA-3019).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sarimarcus/content-sites-tourism",
3
- "version": "0.31.2",
3
+ "version": "0.31.4",
4
4
  "description": "City-tourism vertical: city-entity components, pages templates and utilities for the tourism sites.",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -36,7 +36,7 @@
36
36
  "peerDependencies": {
37
37
  "astro": "^7.0.6",
38
38
  "tailwindcss": "^4.1.18",
39
- "@sarimarcus/content-sites-core": "0.31.2",
40
- "@sarimarcus/content-sites-ui": "0.31.2"
39
+ "@sarimarcus/content-sites-core": "0.31.4",
40
+ "@sarimarcus/content-sites-ui": "0.31.4"
41
41
  }
42
42
  }
@@ -1,10 +1,12 @@
1
1
  ---
2
2
  /**
3
3
  * EventCard — event teaser: period badge coloured by event type, UNESCO and free pills, dates, price, audience
4
- * badges. The site adapter resolves the href, the optimised image, the fallback, the alt text and the tag labels.
4
+ * badges, on the ui EntityCard frame (poster variant). The site adapter resolves the href, the optimised image, the
5
+ * fallback, the alt text and the tag labels.
5
6
  */
6
7
  import type { ImageMetadata } from 'astro';
7
- import { Badge, Icon, ResponsivePicture } from '@sarimarcus/content-sites-ui/primitives';
8
+ import { ArrowLabel, Badge, Icon } from '@sarimarcus/content-sites-ui/primitives';
9
+ import { EntityCard } from '@sarimarcus/content-sites-ui/composed';
8
10
 
9
11
  interface Props {
10
12
  href: string;
@@ -48,9 +50,6 @@ const {
48
50
  eager = 1,
49
51
  } = Astro.props;
50
52
 
51
- const fetchPriority = priority || index === 0 ? "high" : "auto";
52
- const loadingStrategy = index < eager ? "eager" : "lazy";
53
-
54
53
  const isUNESCO = tags.includes('unesco');
55
54
  const isFree = tags.includes('free') || price?.toLowerCase().includes('free');
56
55
 
@@ -63,97 +62,66 @@ const typeColors: Record<string, string> = {
63
62
  };
64
63
  const typeColor = typeColors[type] || 'bg-shadow text-chalk';
65
64
  const labels = tagLabels.slice(0, 3);
65
+ const typeLabels: Record<string, string> = { festival: 'Festival', feria: 'Feria', gastronomie: 'Gastronomy', religieux: 'Tradition' };
66
+ const typeLabel = typeLabels[type] ?? 'Event';
66
67
  ---
67
68
 
68
- <article class:list={['group relative bg-card rounded-xl overflow-hidden card-lift border border-border flex flex-col h-full', className]}>
69
- <a href={href} class="flex flex-col h-full focus-visible:ring-2 focus-visible:ring-primary focus-visible:ring-offset-2 rounded-xl">
70
- <div class="relative h-48 sm:h-56 overflow-hidden img-placeholder shrink-0">
71
- {image ? (
72
- <ResponsivePicture
73
- src={image}
74
- alt={imageAlt}
75
- sizes="(max-width: 639px) 100vw, (max-width: 1023px) 50vw, 33vw"
76
- pictureAttributes={{ class: 'block w-full h-full' }}
77
- class="w-full h-full object-cover transition-transform duration-500 group-hover:scale-105"
78
- loading={loadingStrategy}
79
- fetchpriority={fetchPriority}
80
- decoding="async"
81
- />
82
- ) : (
83
- <img
84
- src={fallbackSrc}
85
- alt={imageAlt}
86
- width="400"
87
- height="224"
88
- class="w-full h-full object-cover transition-transform duration-500 group-hover:scale-105"
89
- loading={loadingStrategy}
90
- fetchpriority={fetchPriority}
91
- decoding="async"
92
- />
93
- )}
94
-
95
- <div class="absolute top-3 right-3 max-w-[55%]">
96
- <Badge tone="custom" toneClass={`${typeColor} backdrop-blur-sm`} size="lg" lines={1}>{period}</Badge>
97
- </div>
69
+ <EntityCard variant="poster" mediaClass="h-48 sm:h-56" href={href} image={image} fallbackSrc={fallbackSrc} imageAlt={imageAlt} index={index} eager={eager} priority={priority} class={className}>
70
+ <div slot="overlay" class="absolute top-3 right-3 max-w-[55%]">
71
+ <Badge tone="custom" toneClass={`${typeColor} backdrop-blur-sm`} size="lg" lines={1}>{period}</Badge>
98
72
  </div>
99
73
 
100
- <div class="p-4 sm:p-5 flex flex-col flex-1">
101
- <span class="text-xs text-muted-foreground uppercase tracking-wider mb-1 block">{category}</span>
102
- <h3 class="text-lg sm:text-xl font-semibold text-foreground leading-tight font-display mb-2">
103
- {name}
104
- </h3>
74
+ <span class="text-xs text-muted-foreground uppercase tracking-wider mb-1 block">{category}</span>
75
+ <h3 class="text-lg sm:text-xl font-semibold text-foreground leading-tight font-display mb-2">
76
+ {name}
77
+ </h3>
105
78
 
106
- {(isUNESCO || isFree) && (
107
- <div class="flex flex-wrap gap-1.5 mb-3">
108
- {isUNESCO && (
109
- <Badge tone="custom" toneClass="bg-accent-strong/10 text-accent-strong" size="sm" lines={1}>
110
- <Icon name="star" filled class="w-3 h-3 inline-block align-[-1px] mr-1" aria-hidden="true" />UNESCO
111
- </Badge>
112
- )}
113
- {isFree && (
114
- <Badge tone="custom" toneClass="bg-secondary/10 text-secondary" size="sm" lines={1}>Free</Badge>
115
- )}
116
- </div>
117
- )}
118
-
119
- <p class="text-base text-muted-foreground line-clamp-2 mb-4">
120
- {description}
121
- </p>
122
-
123
- <div class="flex flex-wrap gap-3 text-sm text-shadow-light mb-4">
124
- {dates && (
125
- <span class="inline-flex items-center gap-1.5">
126
- <Icon name="calendar" class="w-3.5 h-3.5 text-primary" aria-hidden="true" />
127
- <span>{dates}</span>
128
- </span>
79
+ {(isUNESCO || isFree) && (
80
+ <div class="flex flex-wrap gap-1.5 mb-3">
81
+ {isUNESCO && (
82
+ <Badge tone="custom" toneClass="bg-accent-strong/10 text-accent-strong" size="sm" lines={1}>
83
+ <Icon name="star" filled class="w-3 h-3 inline-block align-[-1px] mr-1" aria-hidden="true" />UNESCO
84
+ </Badge>
129
85
  )}
130
- {price && (
131
- <span class="inline-flex items-center gap-1.5">
132
- <Icon name="credit-card" class="w-3.5 h-3.5 text-accent" aria-hidden="true" />
133
- <span>{price.split(',')[0]}</span>
134
- </span>
86
+ {isFree && (
87
+ <Badge tone="custom" toneClass="bg-secondary/10 text-secondary" size="sm" lines={1}>Free</Badge>
135
88
  )}
136
89
  </div>
90
+ )}
137
91
 
138
- {labels.length > 0 && (
139
- <div class="flex flex-wrap gap-1.5 mb-3">
140
- {labels.map((label: string) => (
141
- <Badge tone="primary" size="sm">{label}</Badge>
142
- ))}
143
- </div>
144
- )}
92
+ <p class="text-base text-muted-foreground line-clamp-2 mb-4">
93
+ {description}
94
+ </p>
145
95
 
146
- <div class="flex items-center justify-between pt-3 border-t border-border mt-auto">
147
- <span class="inline-flex items-center gap-1.5 text-sm text-muted-foreground">
148
- <Icon name="calendar" class="w-3.5 h-3.5" aria-hidden="true" />
149
- {type === 'festival' ? 'Festival' : type === 'feria' ? 'Feria' : type === 'gastronomie' ? 'Gastronomy' : type === 'religieux' ? 'Tradition' : 'Event'}
96
+ <div class="flex flex-wrap gap-3 text-sm text-shadow-light mb-4">
97
+ {dates && (
98
+ <span class="inline-flex items-center gap-1.5">
99
+ <Icon name="calendar" class="w-3.5 h-3.5 text-primary" aria-hidden="true" />
100
+ <span>{dates}</span>
150
101
  </span>
151
-
152
- <span class="inline-flex items-center gap-2 text-sm font-medium text-primary group-hover:text-primary-strong transition-colors">
153
- Discover
154
- <Icon name="arrow-right" class="w-4 h-4 transition-transform group-hover:translate-x-1" aria-hidden="true" />
102
+ )}
103
+ {price && (
104
+ <span class="inline-flex items-center gap-1.5">
105
+ <Icon name="credit-card" class="w-3.5 h-3.5 text-accent" aria-hidden="true" />
106
+ <span>{price.split(',')[0]}</span>
155
107
  </span>
156
- </div>
108
+ )}
157
109
  </div>
158
- </a>
159
- </article>
110
+
111
+ {labels.length > 0 && (
112
+ <div class="flex flex-wrap gap-1.5 mb-3">
113
+ {labels.map((label: string) => (
114
+ <Badge tone="primary" size="sm">{label}</Badge>
115
+ ))}
116
+ </div>
117
+ )}
118
+
119
+ <span slot="footer-meta" class="inline-flex items-center gap-1.5 text-sm text-muted-foreground">
120
+ <Icon name="calendar" class="w-3.5 h-3.5" aria-hidden="true" />
121
+ {typeLabel}
122
+ </span>
123
+
124
+ <ArrowLabel slot="footer-cta" class="text-sm font-medium text-primary group-hover:text-primary-strong transition-colors">
125
+ Discover
126
+ </ArrowLabel>
127
+ </EntityCard>
@@ -7,8 +7,9 @@
7
7
  */
8
8
  import type { ImageMetadata } from 'astro';
9
9
  import { Badge, Icon, ResponsivePicture } from '@sarimarcus/content-sites-ui/primitives';
10
+ import type { BrandTone } from '@sarimarcus/content-sites-ui/types';
10
11
 
11
- export type NeighborhoodBadgeTone = 'primary' | 'accent' | 'secondary' | 'overlay';
12
+ export type NeighborhoodBadgeTone = BrandTone | 'overlay';
12
13
 
13
14
  export interface NeighborhoodBadge {
14
15
  label: string;
@@ -77,7 +78,7 @@ const badgeTones: Record<NeighborhoodBadgeTone, string> = {
77
78
  overlay: 'bg-overlay text-accent',
78
79
  };
79
80
 
80
- const fetchPriority = featured || index === 0 ? "high" : "auto";
81
+ const fetchPriority = featured || index === 0 ? "high" : undefined;
81
82
  const loadingStrategy = index < 2 ? "eager" : "lazy";
82
83
 
83
84
  const cardHeight = 'h-72 sm:h-80';
@@ -91,7 +92,7 @@ const cardHeight = 'h-72 sm:h-80';
91
92
  ]}
92
93
  data-neighborhood-card={slug}
93
94
  >
94
- <a href={href} class="block h-full">
95
+ <a href={href} class="block h-full focus-visible:ring-2 focus-visible:ring-primary focus-visible:ring-offset-2 rounded-xl">
95
96
  <div class:list={['relative overflow-hidden img-placeholder', cardHeight]}>
96
97
  {image ? (
97
98
  <ResponsivePicture
@@ -99,7 +100,7 @@ const cardHeight = 'h-72 sm:h-80';
99
100
  alt={imageAlt}
100
101
  sizes="(max-width: 767px) 100vw, (max-width: 1023px) 50vw, 33vw"
101
102
  pictureAttributes={{ class: 'block w-full h-full' }}
102
- class="w-full h-full object-cover transition-transform duration-700 group-hover:scale-110"
103
+ class="w-full h-full object-cover transition-transform duration-700 group-hover:scale-110 motion-reduce:group-hover:scale-100"
103
104
  loading={loadingStrategy}
104
105
  fetchpriority={fetchPriority}
105
106
  decoding="async"
@@ -110,7 +111,7 @@ const cardHeight = 'h-72 sm:h-80';
110
111
  alt={imageAlt}
111
112
  width="600"
112
113
  height="288"
113
- class="w-full h-full object-cover transition-transform duration-700 group-hover:scale-110"
114
+ class="w-full h-full object-cover transition-transform duration-700 group-hover:scale-110 motion-reduce:group-hover:scale-100"
114
115
  loading={loadingStrategy}
115
116
  fetchpriority={fetchPriority}
116
117
  decoding="async"
@@ -218,10 +219,6 @@ const cardHeight = 'h-72 sm:h-80';
218
219
 
219
220
  <style>
220
221
  @media (prefers-reduced-motion: reduce) {
221
- article img {
222
- transition: none !important;
223
- }
224
-
225
222
  article div[class*="translate-y"] {
226
223
  transition: none !important;
227
224
  }
@@ -5,12 +5,17 @@ import {
5
5
  import type { JsonLdNode, SchemaBuilder, SchemaBuilders } from '@sarimarcus/content-sites-core/schema';
6
6
  import { cityAddressPolicy, type TourismCity } from './city.ts';
7
7
 
8
+ /** @deprecated Only `tourismCityBuilders` builds it; Removed in the next minor (SLA-3020). */
8
9
  export interface MonumentOptions {
9
10
  city: TourismCity;
11
+ /** @deprecated No caller sets it; the node keeps `touristType: 'Cultural'`. Removed in the next minor (SLA-3020). */
10
12
  touristType?: string;
11
13
  }
12
14
 
13
- /** TouristAttraction at route `monument`; hours from the free-text `hours` line. */
15
+ /**
16
+ * TouristAttraction at route `monument`; hours from the free-text `hours` line.
17
+ * @deprecated No site imports it; use `tourismCityBuilders(city)`. Removed in the next minor (SLA-3020).
18
+ */
14
19
  export function monumentBuilder(options: MonumentOptions): SchemaBuilder {
15
20
  const address = cityAddressPolicy(options.city);
16
21
  const touristType = options.touristType ?? 'Cultural';
@@ -23,7 +28,10 @@ export function monumentBuilder(options: MonumentOptions): SchemaBuilder {
23
28
  });
24
29
  }
25
30
 
26
- /** Museum at route `museum`; hours from the free-text `hours` line. */
31
+ /**
32
+ * Museum at route `museum`; hours from the free-text `hours` line.
33
+ * @deprecated No site imports it; use `tourismCityBuilders(city)`. Removed in the next minor (SLA-3020).
34
+ */
27
35
  export function museumBuilder(options: { city: TourismCity }): SchemaBuilder {
28
36
  const address = cityAddressPolicy(options.city);
29
37
  return (data, ctx) => placeNode(ctx, data, 'Museum', 'museum', {
@@ -44,12 +52,17 @@ const menu = (sectionName: string, items: string[] | undefined): JsonLdNode | un
44
52
  },
45
53
  } : undefined);
46
54
 
55
+ /** @deprecated Only `tourismCityBuilders` builds it; Removed in the next minor (SLA-3020). */
47
56
  export interface RestaurantOptions {
48
57
  city: TourismCity;
58
+ /** @deprecated No caller sets it; the menu section stays 'Specialties'. Removed in the next minor (SLA-3020). */
49
59
  menuSectionName?: string;
50
60
  }
51
61
 
52
- /** Restaurant at route `restaurant`; `specialties` become its menu. */
62
+ /**
63
+ * Restaurant at route `restaurant`; `specialties` become its menu.
64
+ * @deprecated No site imports it; use `tourismCityBuilders(city)`. Removed in the next minor (SLA-3020).
65
+ */
53
66
  export function restaurantBuilder(options: RestaurantOptions): SchemaBuilder {
54
67
  const address = cityAddressPolicy(options.city);
55
68
  const sectionName = options.menuSectionName ?? 'Specialties';
@@ -66,14 +79,22 @@ export function restaurantBuilder(options: RestaurantOptions): SchemaBuilder {
66
79
  });
67
80
  }
68
81
 
82
+ /** @deprecated Only `tourismCityBuilders` builds it; Removed in the next minor (SLA-3020). */
69
83
  export interface BarOptions {
70
84
  city: TourismCity;
85
+ /** @deprecated No caller sets it; the menu section stays 'Signature Drinks'. Removed in the next minor (SLA-3020). */
71
86
  menuSectionName?: string;
72
- /** `servesCuisine` for a bar whose `category` is `tapas`. */
87
+ /**
88
+ * `servesCuisine` for a bar whose `category` is `tapas`.
89
+ * @deprecated No caller sets it; it stays 'Tapas'. Removed in the next minor (SLA-3020).
90
+ */
73
91
  tapasCuisine?: string;
74
92
  }
75
93
 
76
- /** BarOrPub at route `bar`; `specialties` become its drinks menu. */
94
+ /**
95
+ * BarOrPub at route `bar`; `specialties` become its drinks menu.
96
+ * @deprecated No site imports it; use `tourismCityBuilders(city)`. Removed in the next minor (SLA-3020).
97
+ */
77
98
  export function barBuilder(options: BarOptions): SchemaBuilder {
78
99
  const address = cityAddressPolicy(options.city);
79
100
  const sectionName = options.menuSectionName ?? 'Signature Drinks';
@@ -91,12 +112,18 @@ export function barBuilder(options: BarOptions): SchemaBuilder {
91
112
  });
92
113
  }
93
114
 
115
+ /** @deprecated Only `tourismCityBuilders` builds it; Removed in the next minor (SLA-3020). */
94
116
  export interface DishOptions {
117
+ /** @deprecated No caller sets it; it stays 'Gastronomy'. Removed in the next minor (SLA-3020). */
95
118
  articleSection?: string;
119
+ /** @deprecated No caller sets it; it stays 'en'. Removed in the next minor (SLA-3020). */
96
120
  inLanguage?: string;
97
121
  }
98
122
 
99
- /** A dish page as an Article at route `dish`, dated by `dateModified` (now when absent). */
123
+ /**
124
+ * A dish page as an Article at route `dish`, dated by `dateModified` (now when absent).
125
+ * @deprecated No site imports it; use `tourismCityBuilders(city)`. Removed in the next minor (SLA-3020).
126
+ */
100
127
  export function dishBuilder(options: DishOptions = {}): SchemaBuilder {
101
128
  const { articleSection = 'Gastronomy', inLanguage = 'en' } = options;
102
129
  return (data, ctx) => {
@@ -120,7 +147,10 @@ export function dishBuilder(options: DishOptions = {}): SchemaBuilder {
120
147
  };
121
148
  }
122
149
 
123
- /** Place at route `neighborhood`, inside the city; pinned to the city when it has no coordinates. */
150
+ /**
151
+ * Place at route `neighborhood`, inside the city; pinned to the city when it has no coordinates.
152
+ * @deprecated No site imports it; use `tourismCityBuilders(city)`. Removed in the next minor (SLA-3020).
153
+ */
124
154
  export function neighborhoodBuilder(options: { city: TourismCity }): SchemaBuilder {
125
155
  const { city } = options;
126
156
  const address = cityAddressPolicy(city);
@@ -179,7 +209,10 @@ export function tourismCityBuilders(city: TourismCity): SchemaBuilders {
179
209
  };
180
210
  }
181
211
 
182
- /** Guide item `type` (a plural collection name) → schema type (SLA-2468). */
212
+ /**
213
+ * Guide item `type` (a plural collection name) → schema type (SLA-2468).
214
+ * @deprecated No site imports it; `guideItemListBuilder` applies it by default. Removed in the next minor (SLA-3020).
215
+ */
183
216
  export const GUIDE_ITEM_TYPES: Record<string, string> = {
184
217
  restaurants: 'Restaurant',
185
218
  hotels: 'LodgingBusiness',
@@ -197,7 +230,11 @@ export const GUIDE_ITEM_TYPES: Record<string, string> = {
197
230
  * A ranked guide as an ItemList of mixed-type nested entities. Event nests address and geo under `location`;
198
231
  * TouristTrip carries no `geo`; hotels carry a price range and no hours.
199
232
  */
200
- export function guideItemListBuilder(options: { city: TourismCity; itemTypes?: Record<string, string> }): SchemaBuilder {
233
+ export function guideItemListBuilder(options: {
234
+ city: TourismCity;
235
+ /** @deprecated No caller sets it; the map stays `GUIDE_ITEM_TYPES`. Removed in the next minor (SLA-3020). */
236
+ itemTypes?: Record<string, string>;
237
+ }): SchemaBuilder {
201
238
  const policy = cityAddressPolicy(options.city);
202
239
  const itemTypes = options.itemTypes ?? GUIDE_ITEM_TYPES;
203
240
  return (data, ctx) => {
@@ -3,6 +3,7 @@
3
3
  * NeighborhoodCategory — a thematic group of neighbourhood cards on the neighbourhoods hub, with a category-tinted
4
4
  * header. Cards go in the default slot. The site adapter supplies the title, description and count label.
5
5
  */
6
+ import { Icon } from '@sarimarcus/content-sites-ui/primitives';
6
7
 
7
8
  export type NeighborhoodCategoryType = 'historic' | 'authentic' | 'modern';
8
9
 
@@ -45,9 +46,8 @@ const categoryConfig: Record<NeighborhoodCategoryType, {
45
46
 
46
47
  const config = categoryConfig[category];
47
48
 
48
- const categoryIcons: Record<NeighborhoodCategoryType, string> = {
49
+ const categoryIcons: Record<Exclude<NeighborhoodCategoryType, 'authentic'>, string> = {
49
50
  'historic': 'M3 21h18M3 7v1a3 3 0 0 0 6 0V7m0 1a3 3 0 0 0 6 0V7m0 1a3 3 0 0 0 6 0V7M6 21V7m6 0v14m6-14v14M4 7h16M4 21h16',
50
- 'authentic': 'M12 22s-8-4.5-8-11.8A8 8 0 0 1 12 2a8 8 0 0 1 8 8.2c0 7.3-8 11.8-8 11.8z M12 13a3 3 0 1 0 0-6 3 3 0 0 0 0 6z',
51
51
  'modern': 'M4 22h16a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2H8a2 2 0 0 0-2 2v16a2 2 0 0 1-2 2Zm0 0a2 2 0 0 1-2-2v-9c0-1.1.9-2 2-2h2 M18 14h-8M15 18h-5',
52
52
  };
53
53
  ---
@@ -60,9 +60,13 @@ const categoryIcons: Record<NeighborhoodCategoryType, string> = {
60
60
  <div class="mb-8 pb-6">
61
61
  <div class="flex items-start gap-4 mb-3">
62
62
  <div class:list={['flex-shrink-0 w-10 h-10 rounded-lg flex items-center justify-center', config.iconBg]}>
63
- <svg class:list={['w-5 h-5', config.accentColor]} viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true">
64
- <path d={categoryIcons[category]} />
65
- </svg>
63
+ {category === 'authentic' ? (
64
+ <Icon name="map-pin" class={`w-5 h-5 ${config.accentColor}`} />
65
+ ) : (
66
+ <svg class:list={['w-5 h-5', config.accentColor]} viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true">
67
+ <path d={categoryIcons[category]} />
68
+ </svg>
69
+ )}
66
70
  </div>
67
71
 
68
72
  <div class="flex-1 min-w-0">
@@ -43,10 +43,7 @@ const {
43
43
  <div class="max-w-measure-wide mx-auto">
44
44
  <div class="space-y-6">
45
45
  <Badge tone="custom" toneClass="bg-overlay-foreground/10 text-overlay-foreground/90 backdrop-blur-sm border border-overlay-foreground/10" size="lg" lines={0} class="!px-4 !py-2 !gap-2">
46
- <svg class="w-4 h-4" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true">
47
- <path d="M20 10c0 6-8 12-8 12s-8-6-8-12a8 8 0 0 1 16 0Z" />
48
- <circle cx="12" cy="10" r="3" />
49
- </svg>
46
+ <Icon name="map-pin" class="w-4 h-4" />
50
47
  {badgeLabel}
51
48
  </Badge>
52
49
 
@@ -5,6 +5,7 @@
5
5
  * in-page anchor gets a down chevron, any other href a right arrow.
6
6
  */
7
7
  import { Icon } from '@sarimarcus/content-sites-ui/primitives';
8
+ import type { BrandTone } from '@sarimarcus/content-sites-ui/types';
8
9
 
9
10
  export interface SituationalScenario {
10
11
  title: string;
@@ -15,7 +16,7 @@ export interface SituationalScenario {
15
16
  secondaryLink?: { label: string; href: string };
16
17
  /** SVG path data for the 24×24 icon. */
17
18
  icon: string;
18
- tone: 'primary' | 'secondary' | 'accent';
19
+ tone: BrandTone;
19
20
  }
20
21
 
21
22
  interface Props {
@@ -9,12 +9,12 @@
9
9
  */
10
10
  import { Icon } from '@sarimarcus/content-sites-ui/primitives';
11
11
  import { Container } from '@sarimarcus/content-sites-ui/layout';
12
- import type { TrustedHtml } from '@sarimarcus/content-sites-ui/types';
12
+ import type { BrandTone, TrustedHtml } from '@sarimarcus/content-sites-ui/types';
13
13
  import FacetHero from './FacetHero.astro';
14
14
  import FacetChipNav from './FacetChipNav.astro';
15
15
  import type { FacetLink, FacetNav } from './facet';
16
16
 
17
- export type CategoryFacetTone = 'primary' | 'secondary' | 'accent' | 'secondary-overlay';
17
+ export type CategoryFacetTone = BrandTone | 'secondary-overlay';
18
18
 
19
19
  interface Props {
20
20
  tone: CategoryFacetTone;
@@ -1,4 +1,5 @@
1
1
  // Types shared by the facet page templates.
2
+ import type { BrandTone } from '@sarimarcus/content-sites-ui/types';
2
3
 
3
4
  export interface FacetLink {
4
5
  href: string;
@@ -30,7 +31,7 @@ export interface FacetNav {
30
31
  /** aria-label of the chip nav. */
31
32
  label: string;
32
33
  /** Chip colour; default primary. */
33
- accent?: 'primary' | 'secondary' | 'accent';
34
+ accent?: BrandTone;
34
35
  /** The unfiltered listing, first in the row. */
35
36
  all?: { href: string; label: string; count: number };
36
37
  items: FacetNavItem[];