@reblu/site-contracts 1.10.0 → 1.12.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
@@ -1,5 +1,17 @@
1
1
  # @reblu/site-contracts
2
2
 
3
+ ## 1.12.0
4
+
5
+ ### Minor Changes
6
+
7
+ - fd17765: Site-level SEO (REB-651). `Config` gains optional `seoTitle`, `seoDescription` and `canonicalUrl`, all `string | null`. `seoTitle` and `seoDescription` are the site's own search title and description (the home page), apart from `siteName` and `siteDescription`; `null` means never set, so fall back to `siteName` and `siteDescription`. A set `seoTitle` is used as-is and never gets the template suffix. `canonicalUrl` is the site's https origin (no trailing slash), to use as Next's `metadataBase`. Purely additive.
8
+
9
+ ## 1.11.0
10
+
11
+ ### Minor Changes
12
+
13
+ - e4dff25: Resolved page titles (REB-871). `PageDetail`, `BlogPostDetail`, `ShopProductDetail` and `AcademyCourseDetail` gain an optional `seo: { title }` — the final page title, already resolved by the API (the entity's own SEO title as-is when set, otherwise the tenant template applied once to the display title); render it verbatim. `AcademyCourseDetail` also exposes its optional `metaTitle`. `Config` gains an optional `seoTitleTemplate` (the tenant template, already resolved to the default `%s | {siteName}` when unset). New `Seo` type. Purely additive: `seoTitle`/`metaTitle` are unchanged.
14
+
3
15
  ## 1.10.0
4
16
 
5
17
  ### Minor Changes
package/README.md CHANGED
@@ -151,6 +151,39 @@ The shape is **forward-compatible** on purpose, so render it defensively:
151
151
  items and 1–80 characters of text are nexus write rules, not wire
152
152
  guarantees.
153
153
 
154
+ ### Page titles — resolved `seo.title` (REB-871)
155
+
156
+ Every detail response (`PageDetail`, `BlogPostDetail`, `ShopProductDetail`,
157
+ `AcademyCourseDetail`) carries `seo: { title }` — the **final** page title,
158
+ already resolved by the API with one rule:
159
+
160
+ - the entity's own SEO title (`seoTitle` on pages, `metaTitle` on posts,
161
+ products and courses) is used **as-is** when it is set — the site name is
162
+ never appended;
163
+ - otherwise the tenant template (`Config.seoTitleTemplate`, default
164
+ `%s | {siteName}`) is applied once to the display title.
165
+
166
+ Render `seo.title` verbatim (e.g. Next `title: { absolute }`) — never wrap it in
167
+ another `"… · Brand"` template. For list/index routes, or an older API without
168
+ `seo`, apply the same rule with `resolveSeoTitle` / `buildMetadata` from
169
+ `@reblu/site-next/seo`. Both fields are optional in the types so the minor stays
170
+ additive; `seoTitle`/`metaTitle` are unchanged.
171
+
172
+ ### Site SEO title, description and canonical URL (REB-651)
173
+
174
+ `Config` carries the site's own search fields, apart from the identity fields
175
+ `siteName`/`siteDescription` (which stay short for breadcrumbs and chrome):
176
+
177
+ - `seoTitle` — the home page title. When set it is used **as-is**, never
178
+ suffixed by `seoTitleTemplate`. `null` → use `siteName`.
179
+ - `seoDescription` — the home page description. `null` → `siteDescription`.
180
+ - `canonicalUrl` — the site origin, `https://…` with no trailing slash, or
181
+ `null`. Use it as Next's `metadataBase` so relative Open Graph paths resolve.
182
+
183
+ They are served raw (`null` = never set). `buildMetadata({ config, home: true })`
184
+ from `@reblu/site-next/seo` applies the fallbacks for you. All three are
185
+ optional in the types so the minor stays additive.
186
+
154
187
  ## How the types stay correct
155
188
 
156
189
  The types are re-derived from the response schemas that live in the Reblu API
package/dist/index.d.cts CHANGED
@@ -5,7 +5,7 @@
5
5
  */
6
6
  export type AcademyCategoryPublic = { id: string; name: string; slug: string; sortOrder: number;}
7
7
 
8
- export type AcademyCourseDetail = { id: string; slug: string; title: string; shortDescription: string | null; coverUrl: string | null; priceCents: number; accessMode: "IMMEDIATE" | "DRIP" | "COHORT"; category: { id: string; name: string; slug: string; sortOrder: number; } | null; description: string | null; modules: { id: string; title: string; description: string | null; lessons: { id: string; slug: string; title: string; isFreePreview: boolean; durationSeconds: number | null; hasVideo: boolean; }[]; }[]; instructors: { id: string; firstName: string | null; lastName: string | null; avatarUrl: string | null; }[]; salesEnabled: boolean; requiresValidation: boolean; validationFieldLabel: string | null; validationFields: { key: string; label: string; required: boolean; maxLength?: number | undefined; }[];}
8
+ export type AcademyCourseDetail = { id: string; slug: string; title: string; shortDescription: string | null; coverUrl: string | null; priceCents: number; accessMode: "IMMEDIATE" | "DRIP" | "COHORT"; category: { id: string; name: string; slug: string; sortOrder: number; } | null; description: string | null; modules: { id: string; title: string; description: string | null; lessons: { id: string; slug: string; title: string; isFreePreview: boolean; durationSeconds: number | null; hasVideo: boolean; }[]; }[]; instructors: { id: string; firstName: string | null; lastName: string | null; avatarUrl: string | null; }[]; salesEnabled: boolean; requiresValidation: boolean; validationFieldLabel: string | null; validationFields: { key: string; label: string; required: boolean; maxLength?: number | undefined; }[]; metaTitle?: string | null | undefined; seo?: { title: string; } | undefined;}
9
9
 
10
10
  export type AcademyCourseSort = "price_asc" | "price_desc" | "newest"
11
11
 
@@ -35,17 +35,17 @@ export type BlogCategory = { id: string; name: string; slug: string;
35
35
 
36
36
  export type BlogCategoryWithCount = { id: string; name: string; slug: string; color: string; _count: { posts: number; };}
37
37
 
38
- export type BlogPostDetail = { id: string; slug: string; title: string; content: string; excerpt: string | null; featuredImageUrl: string | null; publishedAt: string | null; updatedAt: string; metaTitle: string | null; metaDescription: string | null; author: { id: string; firstName: string | null; lastName: string | null; avatarUrl: string | null; }; category: { id: string; name: string; slug: string; color: string; } | null; postTags: { id: string; name: string; slug: string; color: string; }[];}
38
+ export type BlogPostDetail = { id: string; slug: string; title: string; content: string; excerpt: string | null; featuredImageUrl: string | null; publishedAt: string | null; updatedAt: string; metaTitle: string | null; metaDescription: string | null; author: { id: string; firstName: string | null; lastName: string | null; avatarUrl: string | null; }; category: { id: string; name: string; slug: string; color: string; } | null; postTags: { id: string; name: string; slug: string; color: string; }[]; seo?: { title: string; } | undefined;}
39
39
 
40
40
  export type BlogPostListItem = { id: string; slug: string; title: string; excerpt: string | null; featuredImageUrl: string | null; publishedAt: string | null; author: { firstName: string | null; lastName: string | null; avatarUrl: string | null; }; category: { id: string; name: string; slug: string; color: string; } | null; postTags: { id: string; name: string; slug: string; color: string; }[];}
41
41
 
42
- export type BlogPostPreview = { id: string; slug: string; title: string; content: string; excerpt: string | null; featuredImageUrl: string | null; publishedAt: string | null; updatedAt: string; metaTitle: string | null; metaDescription: string | null; author: { id: string; firstName: string | null; lastName: string | null; avatarUrl: string | null; }; category: { id: string; name: string; slug: string; color: string; } | null; postTags: { id: string; name: string; slug: string; color: string; }[]; status: "DRAFT" | "PUBLISHED" | "ARCHIVED"; published: boolean;}
42
+ export type BlogPostPreview = { id: string; slug: string; title: string; content: string; excerpt: string | null; featuredImageUrl: string | null; publishedAt: string | null; updatedAt: string; metaTitle: string | null; metaDescription: string | null; author: { id: string; firstName: string | null; lastName: string | null; avatarUrl: string | null; }; category: { id: string; name: string; slug: string; color: string; } | null; postTags: { id: string; name: string; slug: string; color: string; }[]; status: "DRAFT" | "PUBLISHED" | "ARCHIVED"; published: boolean; seo?: { title: string; } | undefined;}
43
43
 
44
44
  export type BlogSlug = { slug: string; updatedAt: string;}
45
45
 
46
46
  export type BlogTag = { id: string; name: string; slug: string; color: string;}
47
47
 
48
- export type Config = { siteName: string; siteDescription: string | null; language: string | null; contactEmail: string | null; keywords: string[]; businessType: string | null; isSetupComplete: boolean; logoLightExpandedUrl: string | null; logoDarkExpandedUrl: string | null; logoLightSmallUrl: string | null; logoDarkSmallUrl: string | null; ogImageUrl: string | null; owner: { name: string | null; email: string | null; jobTitle: string | null; }; business: { name: string | null; }; address: { street: string | null; city: string | null; region: string | null; postalCode: string | null; country: string | null; telephone: string | null; lat: number | null; lng: number | null; } | null; fiscal: { taxId: string | null; taxIdKind: "NIF" | "CIF" | null; legalName: string | null; registry: { name: string; number: string; } | null; } | null; social: { linkedin: string | null; twitter: string | null; facebook: string | null; instagram: string | null; youtube: string | null; } | null; metadata: unknown; openingHours: { ranges: { days: ("MON" | "TUE" | "WED" | "THU" | "FRI" | "SAT" | "SUN")[]; opens: string; closes: string; }[]; note?: string | undefined; } | null; contactFormMode: "NOT_CONFIGURED" | "DISABLED" | "DB_ONLY" | "WEBHOOK" | "RESEND"; features: Record<string, unknown>;}
48
+ export type Config = { siteName: string; siteDescription: string | null; language: string | null; contactEmail: string | null; keywords: string[]; businessType: string | null; isSetupComplete: boolean; logoLightExpandedUrl: string | null; logoDarkExpandedUrl: string | null; logoLightSmallUrl: string | null; logoDarkSmallUrl: string | null; ogImageUrl: string | null; owner: { name: string | null; email: string | null; jobTitle: string | null; }; business: { name: string | null; }; address: { street: string | null; city: string | null; region: string | null; postalCode: string | null; country: string | null; telephone: string | null; lat: number | null; lng: number | null; } | null; fiscal: { taxId: string | null; taxIdKind: "NIF" | "CIF" | null; legalName: string | null; registry: { name: string; number: string; } | null; } | null; social: { linkedin: string | null; twitter: string | null; facebook: string | null; instagram: string | null; youtube: string | null; } | null; metadata: unknown; openingHours: { ranges: { days: ("MON" | "TUE" | "WED" | "THU" | "FRI" | "SAT" | "SUN")[]; opens: string; closes: string; }[]; note?: string | undefined; } | null; contactFormMode: "NOT_CONFIGURED" | "DISABLED" | "DB_ONLY" | "WEBHOOK" | "RESEND"; features: Record<string, unknown>; seoTitleTemplate?: string | undefined; seoTitle?: string | null | undefined; seoDescription?: string | null | undefined; canonicalUrl?: string | null | undefined;}
49
49
 
50
50
  export type ConfigAddress = { street: string | null; city: string | null; region: string | null; postalCode: string | null; country: string | null; telephone: string | null; lat: number | null; lng: number | null;}
51
51
 
@@ -99,7 +99,7 @@ export type PageCategoryRef = { name: string; slug: string;}
99
99
 
100
100
  export type PageContentMode = "BLOCKS" | "HTML"
101
101
 
102
- export type PageDetail = { slug: string; title: string; subtitle: string | null; excerpt: string | null; coverImageUrl: string | null; type: "SERVICE" | "CUSTOM"; pageType: "custom" | "service" | "treatments" | "specialties" | "team" | "generic"; contentMode: "BLOCKS" | "HTML"; customHtml: string | null; seoTitle: string | null; seoDescription: string | null; category: { name: string; slug: string; } | null; sections: { id: string; order: number; heading: string | null; contentHtml: string; layout: "TEXT" | "TEXT_IMAGE" | "IMAGE_TEXT" | "IMAGE_FULL" | "FEATURE_LIST" | "GALLERY" | "CTA_BLOCK"; backgroundColor: string | null; features: unknown; ctaLabel: string | null; ctaUrl: string | null; ctaIsExternal: boolean; ctaVariant: string | null; images: { url: string; alt: string; caption: string | null; order: number; }[]; }[]; blocks: ({ id: string; order: number; heading?: string | null | undefined; backgroundColor?: string | null | undefined; cta?: { label: string; url: string; isExternal: boolean; variant: string | null; } | null | undefined; resolved?: { slug: string; title: string; excerpt: string | null; coverImageUrl: string | null; role: string | null; pageType?: "custom" | "service" | "treatments" | "specialties" | "team" | "generic" | undefined; category?: { name: string; slug: string; } | null | undefined; } | null | undefined; } & ({ blockType: "hero"; data: { title: string; subtitle?: string | undefined; imageUrl?: string | undefined; ctaSlot?: string | undefined; }; } | { blockType: "richtext"; data: { html: string; }; } | { blockType: "faq"; data: { items: { q: string; a: string; }[]; }; } | { blockType: "stats"; data: { items: { label: string; value: string; }[]; }; } | { blockType: "testimonial"; data: { quote: string; author: string; role?: string | undefined; avatarUrl?: string | undefined; }; } | { blockType: "cta"; data: { slot: string; }; } | { blockType: "feature_list"; data: { items: { text: string; icon?: string | undefined; }[]; }; } | { blockType: "gallery"; data: { images: { url: string; alt?: string | undefined; caption?: string | undefined; }[]; }; } | { blockType: "page_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; }; } | { blockType: "profile_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; }; } | { blockType: "doctor_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; }; } | { blockType: "specialty_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; }; }))[]; jsonLd: unknown; professional: { role: string | null; socialLinks: { platform: "linkedin" | "twitter" | "facebook" | "instagram" | "website" | "other"; url: string; }[]; cv: { education: { id: string; title: string; organization: string | null; startYear: number | null; endYear: number | null; description: string | null; }[]; experience: { id: string; title: string; organization: string | null; startYear: number | null; endYear: number | null; description: string | null; }[]; certifications: { id: string; title: string; organization: string | null; startYear: number | null; endYear: number | null; description: string | null; }[]; memberships: { id: string; title: string; organization: string | null; startYear: number | null; endYear: number | null; description: string | null; }[]; languages: { language: string; level: "basic" | "conversational" | "fluent" | "native" | null; }[]; } | null; } | null;}
102
+ export type PageDetail = { slug: string; title: string; subtitle: string | null; excerpt: string | null; coverImageUrl: string | null; type: "SERVICE" | "CUSTOM"; pageType: "custom" | "service" | "treatments" | "specialties" | "team" | "generic"; contentMode: "BLOCKS" | "HTML"; customHtml: string | null; seoTitle: string | null; seoDescription: string | null; category: { name: string; slug: string; } | null; sections: { id: string; order: number; heading: string | null; contentHtml: string; layout: "TEXT" | "TEXT_IMAGE" | "IMAGE_TEXT" | "IMAGE_FULL" | "FEATURE_LIST" | "GALLERY" | "CTA_BLOCK"; backgroundColor: string | null; features: unknown; ctaLabel: string | null; ctaUrl: string | null; ctaIsExternal: boolean; ctaVariant: string | null; images: { url: string; alt: string; caption: string | null; order: number; }[]; }[]; blocks: ({ id: string; order: number; heading?: string | null | undefined; backgroundColor?: string | null | undefined; cta?: { label: string; url: string; isExternal: boolean; variant: string | null; } | null | undefined; resolved?: { slug: string; title: string; excerpt: string | null; coverImageUrl: string | null; role: string | null; pageType?: "custom" | "service" | "treatments" | "specialties" | "team" | "generic" | undefined; category?: { name: string; slug: string; } | null | undefined; } | null | undefined; } & ({ blockType: "hero"; data: { title: string; subtitle?: string | undefined; imageUrl?: string | undefined; ctaSlot?: string | undefined; }; } | { blockType: "richtext"; data: { html: string; }; } | { blockType: "faq"; data: { items: { q: string; a: string; }[]; }; } | { blockType: "stats"; data: { items: { label: string; value: string; }[]; }; } | { blockType: "testimonial"; data: { quote: string; author: string; role?: string | undefined; avatarUrl?: string | undefined; }; } | { blockType: "cta"; data: { slot: string; }; } | { blockType: "feature_list"; data: { items: { text: string; icon?: string | undefined; }[]; }; } | { blockType: "gallery"; data: { images: { url: string; alt?: string | undefined; caption?: string | undefined; }[]; }; } | { blockType: "page_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; }; } | { blockType: "profile_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; }; } | { blockType: "doctor_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; }; } | { blockType: "specialty_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; }; }))[]; jsonLd: unknown; professional: { role: string | null; socialLinks: { platform: "linkedin" | "twitter" | "facebook" | "instagram" | "website" | "other"; url: string; }[]; cv: { education: { id: string; title: string; organization: string | null; startYear: number | null; endYear: number | null; description: string | null; }[]; experience: { id: string; title: string; organization: string | null; startYear: number | null; endYear: number | null; description: string | null; }[]; certifications: { id: string; title: string; organization: string | null; startYear: number | null; endYear: number | null; description: string | null; }[]; memberships: { id: string; title: string; organization: string | null; startYear: number | null; endYear: number | null; description: string | null; }[]; languages: { language: string; level: "basic" | "conversational" | "fluent" | "native" | null; }[]; } | null; } | null; seo?: { title: string; } | undefined;}
103
103
 
104
104
  export type PageListItem = { slug: string; title: string; subtitle: string | null; excerpt: string | null; coverImageUrl: string | null; type: "SERVICE" | "CUSTOM"; pageType: "custom" | "service" | "treatments" | "specialties" | "team" | "generic"; order: number; seoTitle: string | null; seoDescription: string | null; category: { name: string; slug: string; } | null; professional: { role: string | null; } | null;}
105
105
 
@@ -137,6 +137,8 @@ export type ResolvedEmbed = { slug: string; title: string; excerpt: str
137
137
 
138
138
  export type SectionLayout = "TEXT" | "TEXT_IMAGE" | "IMAGE_TEXT" | "IMAGE_FULL" | "FEATURE_LIST" | "GALLERY" | "CTA_BLOCK"
139
139
 
140
+ export type Seo = { title: string;}
141
+
140
142
  export type ShopAddressInput = { firstName: string; lastName: string; street: string; city: string; postalCode: string; region?: string | undefined; country?: string | undefined; phone?: string | null | undefined;}
141
143
 
142
144
  export type ShopApplyDiscountInput = { code: string; orderSubtotal: number; customerEmail?: string | undefined;}
@@ -181,7 +183,7 @@ export type ShopProductAttributes = unknown
181
183
 
182
184
  export type ShopProductCategoryRef = { id: string; name: string; slug: string;}
183
185
 
184
- export type ShopProductDetail = { id: string; slug: string; name: string; description: string | null; shortDescription: string | null; price: number; comparePrice: number | null; type: "SERVICE" | "PHYSICAL" | "DIGITAL" | "SERVICE_B2B" | "BUNDLE"; isActive: boolean; sku: string | null; trackStock: boolean; weightGrams: number | null; freeShipping: boolean; metaTitle: string | null; metaDescription: string | null; category: { id: string; name: string; slug: string; } | null; taxRate: { rate: number; type: "IVA" | "IGIC" | "RETENTION" | "OTHER"; isExempt: boolean; } | null; retentionRate: { rate: number; type: "IVA" | "IGIC" | "RETENTION" | "OTHER"; isExempt: boolean; } | null; variants: { id: string; name: string; sku: string | null; price: number | null; attributes: unknown; isActive: boolean; sortOrder: number; }[]; images: { url: string; alt: string | null; isPrimary: boolean; sortOrder: number; }[]; videos: { url: string; title: string | null; isExternal: boolean; thumbnailUrl: string | null; sortOrder: number; }[]; bundleComponents: { quantity: number; component: { id: string; name: string; slug: string; price: number; }; }[]; related: { id: string; slug: string; name: string; price: number; comparePrice: number | null; images: { url: string; alt: string | null; isPrimary: boolean; sortOrder: number; }[]; }[]; taxonomyTerms: { taxonomyKey: string; taxonomyLabel: string; showAsBadge: boolean; slug: string; name: string; imageUrl: string | null; }[]; attributes: unknown; attributeDefinitions: { id: string; entityType: "page" | "product"; key: string; label: string; valueType: "boolean" | "text" | "select" | "multiselect"; options: { value: string; label: string; }[]; isFilterable: boolean; showInDetail: boolean; unit: string | null; sortOrder: number; }[];}
186
+ export type ShopProductDetail = { id: string; slug: string; name: string; description: string | null; shortDescription: string | null; price: number; comparePrice: number | null; type: "SERVICE" | "PHYSICAL" | "DIGITAL" | "SERVICE_B2B" | "BUNDLE"; isActive: boolean; sku: string | null; trackStock: boolean; weightGrams: number | null; freeShipping: boolean; metaTitle: string | null; metaDescription: string | null; category: { id: string; name: string; slug: string; } | null; taxRate: { rate: number; type: "IVA" | "IGIC" | "RETENTION" | "OTHER"; isExempt: boolean; } | null; retentionRate: { rate: number; type: "IVA" | "IGIC" | "RETENTION" | "OTHER"; isExempt: boolean; } | null; variants: { id: string; name: string; sku: string | null; price: number | null; attributes: unknown; isActive: boolean; sortOrder: number; }[]; images: { url: string; alt: string | null; isPrimary: boolean; sortOrder: number; }[]; videos: { url: string; title: string | null; isExternal: boolean; thumbnailUrl: string | null; sortOrder: number; }[]; bundleComponents: { quantity: number; component: { id: string; name: string; slug: string; price: number; }; }[]; related: { id: string; slug: string; name: string; price: number; comparePrice: number | null; images: { url: string; alt: string | null; isPrimary: boolean; sortOrder: number; }[]; }[]; taxonomyTerms: { taxonomyKey: string; taxonomyLabel: string; showAsBadge: boolean; slug: string; name: string; imageUrl: string | null; }[]; attributes: unknown; attributeDefinitions: { id: string; entityType: "page" | "product"; key: string; label: string; valueType: "boolean" | "text" | "select" | "multiselect"; options: { value: string; label: string; }[]; isFilterable: boolean; showInDetail: boolean; unit: string | null; sortOrder: number; }[]; seo?: { title: string; } | undefined;}
185
187
 
186
188
  export type ShopProductImage = { url: string; alt: string | null; isPrimary: boolean; sortOrder: number;}
187
189
 
package/dist/index.d.ts CHANGED
@@ -5,7 +5,7 @@
5
5
  */
6
6
  export type AcademyCategoryPublic = { id: string; name: string; slug: string; sortOrder: number;}
7
7
 
8
- export type AcademyCourseDetail = { id: string; slug: string; title: string; shortDescription: string | null; coverUrl: string | null; priceCents: number; accessMode: "IMMEDIATE" | "DRIP" | "COHORT"; category: { id: string; name: string; slug: string; sortOrder: number; } | null; description: string | null; modules: { id: string; title: string; description: string | null; lessons: { id: string; slug: string; title: string; isFreePreview: boolean; durationSeconds: number | null; hasVideo: boolean; }[]; }[]; instructors: { id: string; firstName: string | null; lastName: string | null; avatarUrl: string | null; }[]; salesEnabled: boolean; requiresValidation: boolean; validationFieldLabel: string | null; validationFields: { key: string; label: string; required: boolean; maxLength?: number | undefined; }[];}
8
+ export type AcademyCourseDetail = { id: string; slug: string; title: string; shortDescription: string | null; coverUrl: string | null; priceCents: number; accessMode: "IMMEDIATE" | "DRIP" | "COHORT"; category: { id: string; name: string; slug: string; sortOrder: number; } | null; description: string | null; modules: { id: string; title: string; description: string | null; lessons: { id: string; slug: string; title: string; isFreePreview: boolean; durationSeconds: number | null; hasVideo: boolean; }[]; }[]; instructors: { id: string; firstName: string | null; lastName: string | null; avatarUrl: string | null; }[]; salesEnabled: boolean; requiresValidation: boolean; validationFieldLabel: string | null; validationFields: { key: string; label: string; required: boolean; maxLength?: number | undefined; }[]; metaTitle?: string | null | undefined; seo?: { title: string; } | undefined;}
9
9
 
10
10
  export type AcademyCourseSort = "price_asc" | "price_desc" | "newest"
11
11
 
@@ -35,17 +35,17 @@ export type BlogCategory = { id: string; name: string; slug: string;
35
35
 
36
36
  export type BlogCategoryWithCount = { id: string; name: string; slug: string; color: string; _count: { posts: number; };}
37
37
 
38
- export type BlogPostDetail = { id: string; slug: string; title: string; content: string; excerpt: string | null; featuredImageUrl: string | null; publishedAt: string | null; updatedAt: string; metaTitle: string | null; metaDescription: string | null; author: { id: string; firstName: string | null; lastName: string | null; avatarUrl: string | null; }; category: { id: string; name: string; slug: string; color: string; } | null; postTags: { id: string; name: string; slug: string; color: string; }[];}
38
+ export type BlogPostDetail = { id: string; slug: string; title: string; content: string; excerpt: string | null; featuredImageUrl: string | null; publishedAt: string | null; updatedAt: string; metaTitle: string | null; metaDescription: string | null; author: { id: string; firstName: string | null; lastName: string | null; avatarUrl: string | null; }; category: { id: string; name: string; slug: string; color: string; } | null; postTags: { id: string; name: string; slug: string; color: string; }[]; seo?: { title: string; } | undefined;}
39
39
 
40
40
  export type BlogPostListItem = { id: string; slug: string; title: string; excerpt: string | null; featuredImageUrl: string | null; publishedAt: string | null; author: { firstName: string | null; lastName: string | null; avatarUrl: string | null; }; category: { id: string; name: string; slug: string; color: string; } | null; postTags: { id: string; name: string; slug: string; color: string; }[];}
41
41
 
42
- export type BlogPostPreview = { id: string; slug: string; title: string; content: string; excerpt: string | null; featuredImageUrl: string | null; publishedAt: string | null; updatedAt: string; metaTitle: string | null; metaDescription: string | null; author: { id: string; firstName: string | null; lastName: string | null; avatarUrl: string | null; }; category: { id: string; name: string; slug: string; color: string; } | null; postTags: { id: string; name: string; slug: string; color: string; }[]; status: "DRAFT" | "PUBLISHED" | "ARCHIVED"; published: boolean;}
42
+ export type BlogPostPreview = { id: string; slug: string; title: string; content: string; excerpt: string | null; featuredImageUrl: string | null; publishedAt: string | null; updatedAt: string; metaTitle: string | null; metaDescription: string | null; author: { id: string; firstName: string | null; lastName: string | null; avatarUrl: string | null; }; category: { id: string; name: string; slug: string; color: string; } | null; postTags: { id: string; name: string; slug: string; color: string; }[]; status: "DRAFT" | "PUBLISHED" | "ARCHIVED"; published: boolean; seo?: { title: string; } | undefined;}
43
43
 
44
44
  export type BlogSlug = { slug: string; updatedAt: string;}
45
45
 
46
46
  export type BlogTag = { id: string; name: string; slug: string; color: string;}
47
47
 
48
- export type Config = { siteName: string; siteDescription: string | null; language: string | null; contactEmail: string | null; keywords: string[]; businessType: string | null; isSetupComplete: boolean; logoLightExpandedUrl: string | null; logoDarkExpandedUrl: string | null; logoLightSmallUrl: string | null; logoDarkSmallUrl: string | null; ogImageUrl: string | null; owner: { name: string | null; email: string | null; jobTitle: string | null; }; business: { name: string | null; }; address: { street: string | null; city: string | null; region: string | null; postalCode: string | null; country: string | null; telephone: string | null; lat: number | null; lng: number | null; } | null; fiscal: { taxId: string | null; taxIdKind: "NIF" | "CIF" | null; legalName: string | null; registry: { name: string; number: string; } | null; } | null; social: { linkedin: string | null; twitter: string | null; facebook: string | null; instagram: string | null; youtube: string | null; } | null; metadata: unknown; openingHours: { ranges: { days: ("MON" | "TUE" | "WED" | "THU" | "FRI" | "SAT" | "SUN")[]; opens: string; closes: string; }[]; note?: string | undefined; } | null; contactFormMode: "NOT_CONFIGURED" | "DISABLED" | "DB_ONLY" | "WEBHOOK" | "RESEND"; features: Record<string, unknown>;}
48
+ export type Config = { siteName: string; siteDescription: string | null; language: string | null; contactEmail: string | null; keywords: string[]; businessType: string | null; isSetupComplete: boolean; logoLightExpandedUrl: string | null; logoDarkExpandedUrl: string | null; logoLightSmallUrl: string | null; logoDarkSmallUrl: string | null; ogImageUrl: string | null; owner: { name: string | null; email: string | null; jobTitle: string | null; }; business: { name: string | null; }; address: { street: string | null; city: string | null; region: string | null; postalCode: string | null; country: string | null; telephone: string | null; lat: number | null; lng: number | null; } | null; fiscal: { taxId: string | null; taxIdKind: "NIF" | "CIF" | null; legalName: string | null; registry: { name: string; number: string; } | null; } | null; social: { linkedin: string | null; twitter: string | null; facebook: string | null; instagram: string | null; youtube: string | null; } | null; metadata: unknown; openingHours: { ranges: { days: ("MON" | "TUE" | "WED" | "THU" | "FRI" | "SAT" | "SUN")[]; opens: string; closes: string; }[]; note?: string | undefined; } | null; contactFormMode: "NOT_CONFIGURED" | "DISABLED" | "DB_ONLY" | "WEBHOOK" | "RESEND"; features: Record<string, unknown>; seoTitleTemplate?: string | undefined; seoTitle?: string | null | undefined; seoDescription?: string | null | undefined; canonicalUrl?: string | null | undefined;}
49
49
 
50
50
  export type ConfigAddress = { street: string | null; city: string | null; region: string | null; postalCode: string | null; country: string | null; telephone: string | null; lat: number | null; lng: number | null;}
51
51
 
@@ -99,7 +99,7 @@ export type PageCategoryRef = { name: string; slug: string;}
99
99
 
100
100
  export type PageContentMode = "BLOCKS" | "HTML"
101
101
 
102
- export type PageDetail = { slug: string; title: string; subtitle: string | null; excerpt: string | null; coverImageUrl: string | null; type: "SERVICE" | "CUSTOM"; pageType: "custom" | "service" | "treatments" | "specialties" | "team" | "generic"; contentMode: "BLOCKS" | "HTML"; customHtml: string | null; seoTitle: string | null; seoDescription: string | null; category: { name: string; slug: string; } | null; sections: { id: string; order: number; heading: string | null; contentHtml: string; layout: "TEXT" | "TEXT_IMAGE" | "IMAGE_TEXT" | "IMAGE_FULL" | "FEATURE_LIST" | "GALLERY" | "CTA_BLOCK"; backgroundColor: string | null; features: unknown; ctaLabel: string | null; ctaUrl: string | null; ctaIsExternal: boolean; ctaVariant: string | null; images: { url: string; alt: string; caption: string | null; order: number; }[]; }[]; blocks: ({ id: string; order: number; heading?: string | null | undefined; backgroundColor?: string | null | undefined; cta?: { label: string; url: string; isExternal: boolean; variant: string | null; } | null | undefined; resolved?: { slug: string; title: string; excerpt: string | null; coverImageUrl: string | null; role: string | null; pageType?: "custom" | "service" | "treatments" | "specialties" | "team" | "generic" | undefined; category?: { name: string; slug: string; } | null | undefined; } | null | undefined; } & ({ blockType: "hero"; data: { title: string; subtitle?: string | undefined; imageUrl?: string | undefined; ctaSlot?: string | undefined; }; } | { blockType: "richtext"; data: { html: string; }; } | { blockType: "faq"; data: { items: { q: string; a: string; }[]; }; } | { blockType: "stats"; data: { items: { label: string; value: string; }[]; }; } | { blockType: "testimonial"; data: { quote: string; author: string; role?: string | undefined; avatarUrl?: string | undefined; }; } | { blockType: "cta"; data: { slot: string; }; } | { blockType: "feature_list"; data: { items: { text: string; icon?: string | undefined; }[]; }; } | { blockType: "gallery"; data: { images: { url: string; alt?: string | undefined; caption?: string | undefined; }[]; }; } | { blockType: "page_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; }; } | { blockType: "profile_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; }; } | { blockType: "doctor_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; }; } | { blockType: "specialty_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; }; }))[]; jsonLd: unknown; professional: { role: string | null; socialLinks: { platform: "linkedin" | "twitter" | "facebook" | "instagram" | "website" | "other"; url: string; }[]; cv: { education: { id: string; title: string; organization: string | null; startYear: number | null; endYear: number | null; description: string | null; }[]; experience: { id: string; title: string; organization: string | null; startYear: number | null; endYear: number | null; description: string | null; }[]; certifications: { id: string; title: string; organization: string | null; startYear: number | null; endYear: number | null; description: string | null; }[]; memberships: { id: string; title: string; organization: string | null; startYear: number | null; endYear: number | null; description: string | null; }[]; languages: { language: string; level: "basic" | "conversational" | "fluent" | "native" | null; }[]; } | null; } | null;}
102
+ export type PageDetail = { slug: string; title: string; subtitle: string | null; excerpt: string | null; coverImageUrl: string | null; type: "SERVICE" | "CUSTOM"; pageType: "custom" | "service" | "treatments" | "specialties" | "team" | "generic"; contentMode: "BLOCKS" | "HTML"; customHtml: string | null; seoTitle: string | null; seoDescription: string | null; category: { name: string; slug: string; } | null; sections: { id: string; order: number; heading: string | null; contentHtml: string; layout: "TEXT" | "TEXT_IMAGE" | "IMAGE_TEXT" | "IMAGE_FULL" | "FEATURE_LIST" | "GALLERY" | "CTA_BLOCK"; backgroundColor: string | null; features: unknown; ctaLabel: string | null; ctaUrl: string | null; ctaIsExternal: boolean; ctaVariant: string | null; images: { url: string; alt: string; caption: string | null; order: number; }[]; }[]; blocks: ({ id: string; order: number; heading?: string | null | undefined; backgroundColor?: string | null | undefined; cta?: { label: string; url: string; isExternal: boolean; variant: string | null; } | null | undefined; resolved?: { slug: string; title: string; excerpt: string | null; coverImageUrl: string | null; role: string | null; pageType?: "custom" | "service" | "treatments" | "specialties" | "team" | "generic" | undefined; category?: { name: string; slug: string; } | null | undefined; } | null | undefined; } & ({ blockType: "hero"; data: { title: string; subtitle?: string | undefined; imageUrl?: string | undefined; ctaSlot?: string | undefined; }; } | { blockType: "richtext"; data: { html: string; }; } | { blockType: "faq"; data: { items: { q: string; a: string; }[]; }; } | { blockType: "stats"; data: { items: { label: string; value: string; }[]; }; } | { blockType: "testimonial"; data: { quote: string; author: string; role?: string | undefined; avatarUrl?: string | undefined; }; } | { blockType: "cta"; data: { slot: string; }; } | { blockType: "feature_list"; data: { items: { text: string; icon?: string | undefined; }[]; }; } | { blockType: "gallery"; data: { images: { url: string; alt?: string | undefined; caption?: string | undefined; }[]; }; } | { blockType: "page_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; }; } | { blockType: "profile_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; }; } | { blockType: "doctor_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; }; } | { blockType: "specialty_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; }; }))[]; jsonLd: unknown; professional: { role: string | null; socialLinks: { platform: "linkedin" | "twitter" | "facebook" | "instagram" | "website" | "other"; url: string; }[]; cv: { education: { id: string; title: string; organization: string | null; startYear: number | null; endYear: number | null; description: string | null; }[]; experience: { id: string; title: string; organization: string | null; startYear: number | null; endYear: number | null; description: string | null; }[]; certifications: { id: string; title: string; organization: string | null; startYear: number | null; endYear: number | null; description: string | null; }[]; memberships: { id: string; title: string; organization: string | null; startYear: number | null; endYear: number | null; description: string | null; }[]; languages: { language: string; level: "basic" | "conversational" | "fluent" | "native" | null; }[]; } | null; } | null; seo?: { title: string; } | undefined;}
103
103
 
104
104
  export type PageListItem = { slug: string; title: string; subtitle: string | null; excerpt: string | null; coverImageUrl: string | null; type: "SERVICE" | "CUSTOM"; pageType: "custom" | "service" | "treatments" | "specialties" | "team" | "generic"; order: number; seoTitle: string | null; seoDescription: string | null; category: { name: string; slug: string; } | null; professional: { role: string | null; } | null;}
105
105
 
@@ -137,6 +137,8 @@ export type ResolvedEmbed = { slug: string; title: string; excerpt: str
137
137
 
138
138
  export type SectionLayout = "TEXT" | "TEXT_IMAGE" | "IMAGE_TEXT" | "IMAGE_FULL" | "FEATURE_LIST" | "GALLERY" | "CTA_BLOCK"
139
139
 
140
+ export type Seo = { title: string;}
141
+
140
142
  export type ShopAddressInput = { firstName: string; lastName: string; street: string; city: string; postalCode: string; region?: string | undefined; country?: string | undefined; phone?: string | null | undefined;}
141
143
 
142
144
  export type ShopApplyDiscountInput = { code: string; orderSubtotal: number; customerEmail?: string | undefined;}
@@ -181,7 +183,7 @@ export type ShopProductAttributes = unknown
181
183
 
182
184
  export type ShopProductCategoryRef = { id: string; name: string; slug: string;}
183
185
 
184
- export type ShopProductDetail = { id: string; slug: string; name: string; description: string | null; shortDescription: string | null; price: number; comparePrice: number | null; type: "SERVICE" | "PHYSICAL" | "DIGITAL" | "SERVICE_B2B" | "BUNDLE"; isActive: boolean; sku: string | null; trackStock: boolean; weightGrams: number | null; freeShipping: boolean; metaTitle: string | null; metaDescription: string | null; category: { id: string; name: string; slug: string; } | null; taxRate: { rate: number; type: "IVA" | "IGIC" | "RETENTION" | "OTHER"; isExempt: boolean; } | null; retentionRate: { rate: number; type: "IVA" | "IGIC" | "RETENTION" | "OTHER"; isExempt: boolean; } | null; variants: { id: string; name: string; sku: string | null; price: number | null; attributes: unknown; isActive: boolean; sortOrder: number; }[]; images: { url: string; alt: string | null; isPrimary: boolean; sortOrder: number; }[]; videos: { url: string; title: string | null; isExternal: boolean; thumbnailUrl: string | null; sortOrder: number; }[]; bundleComponents: { quantity: number; component: { id: string; name: string; slug: string; price: number; }; }[]; related: { id: string; slug: string; name: string; price: number; comparePrice: number | null; images: { url: string; alt: string | null; isPrimary: boolean; sortOrder: number; }[]; }[]; taxonomyTerms: { taxonomyKey: string; taxonomyLabel: string; showAsBadge: boolean; slug: string; name: string; imageUrl: string | null; }[]; attributes: unknown; attributeDefinitions: { id: string; entityType: "page" | "product"; key: string; label: string; valueType: "boolean" | "text" | "select" | "multiselect"; options: { value: string; label: string; }[]; isFilterable: boolean; showInDetail: boolean; unit: string | null; sortOrder: number; }[];}
186
+ export type ShopProductDetail = { id: string; slug: string; name: string; description: string | null; shortDescription: string | null; price: number; comparePrice: number | null; type: "SERVICE" | "PHYSICAL" | "DIGITAL" | "SERVICE_B2B" | "BUNDLE"; isActive: boolean; sku: string | null; trackStock: boolean; weightGrams: number | null; freeShipping: boolean; metaTitle: string | null; metaDescription: string | null; category: { id: string; name: string; slug: string; } | null; taxRate: { rate: number; type: "IVA" | "IGIC" | "RETENTION" | "OTHER"; isExempt: boolean; } | null; retentionRate: { rate: number; type: "IVA" | "IGIC" | "RETENTION" | "OTHER"; isExempt: boolean; } | null; variants: { id: string; name: string; sku: string | null; price: number | null; attributes: unknown; isActive: boolean; sortOrder: number; }[]; images: { url: string; alt: string | null; isPrimary: boolean; sortOrder: number; }[]; videos: { url: string; title: string | null; isExternal: boolean; thumbnailUrl: string | null; sortOrder: number; }[]; bundleComponents: { quantity: number; component: { id: string; name: string; slug: string; price: number; }; }[]; related: { id: string; slug: string; name: string; price: number; comparePrice: number | null; images: { url: string; alt: string | null; isPrimary: boolean; sortOrder: number; }[]; }[]; taxonomyTerms: { taxonomyKey: string; taxonomyLabel: string; showAsBadge: boolean; slug: string; name: string; imageUrl: string | null; }[]; attributes: unknown; attributeDefinitions: { id: string; entityType: "page" | "product"; key: string; label: string; valueType: "boolean" | "text" | "select" | "multiselect"; options: { value: string; label: string; }[]; isFilterable: boolean; showInDetail: boolean; unit: string | null; sortOrder: number; }[]; seo?: { title: string; } | undefined;}
185
187
 
186
188
  export type ShopProductImage = { url: string; alt: string | null; isPrimary: boolean; sortOrder: number;}
187
189
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@reblu/site-contracts",
3
- "version": "1.10.0",
3
+ "version": "1.12.0",
4
4
  "private": false,
5
5
  "description": "Public, dependency-free TypeScript types for the Reblu SITE API (types only — no Zod, no Prisma at runtime).",
6
6
  "license": "Apache-2.0",