@reblu/site-contracts 1.8.0 → 1.10.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 +27 -0
- package/README.md +38 -0
- package/dist/index.d.cts +14 -6
- package/dist/index.d.ts +14 -6
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,32 @@
|
|
|
1
1
|
# @reblu/site-contracts
|
|
2
2
|
|
|
3
|
+
## 1.10.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 00b203e: Page slugs are unique per category, not globally (REB-867). `@reblu/site-contracts` adds `PageAmbiguousSlugError` (the 409 `ambiguous_slug` body of `GET /api/site/pages/[slug]`), `EmbedReferenceData` (embed `data` gains optional `pageId`/`categorySlug`) and an optional `category` on `PageSlug`. `@reblu/site-client`'s `pages.bySlug(slug, { category })` addresses a page inside a category (`category: null` = uncategorised) and throws a typed `AmbiguousPageSlugError` (an `ApiError`, status 409, with `candidates`) when a slug exists in several categories; passing a cache policy as the second argument keeps working.
|
|
8
|
+
|
|
9
|
+
## 1.9.0
|
|
10
|
+
|
|
11
|
+
### Minor Changes
|
|
12
|
+
|
|
13
|
+
- cc0ce0c: Add `ShopConfig.productTrustItems` (REB-858): store-wide product trust items,
|
|
14
|
+
optional `ShopProductTrustItem[] | null`, in the owner's display order. New
|
|
15
|
+
exported types `ShopProductTrustIcon` (the icons known today: `shipping |
|
|
16
|
+
returns | secure-payment | support | gift | pickup | warranty | quality`) and
|
|
17
|
+
`ShopProductTrustItem` (`{ icon: ShopProductTrustIcon | (string & {}); text:
|
|
18
|
+
string }`, open to extra keys).
|
|
19
|
+
|
|
20
|
+
The item shape is forward-compatible: a newer API may send an icon or an item
|
|
21
|
+
key this version does not know. Consumers must ignore items whose icon they
|
|
22
|
+
don't recognise (see the README).
|
|
23
|
+
|
|
24
|
+
Absent, `null` or `[]` all mean the SITE hides the block — no default items
|
|
25
|
+
are ever served. The API always emits the key (`null` when not configured);
|
|
26
|
+
it is optional in the type so the change is purely additive: existing typed
|
|
27
|
+
`ShopConfig` fixtures keep compiling, and a consumer on this version talking
|
|
28
|
+
to an older base-api (which does not emit the key) still validates.
|
|
29
|
+
|
|
3
30
|
## 1.8.0
|
|
4
31
|
|
|
5
32
|
### Minor Changes
|
package/README.md
CHANGED
|
@@ -113,6 +113,44 @@ longer offered as a choice for a new section in nexus. They will be removed
|
|
|
113
113
|
after 2027-01-31, once no tenant data uses them (REB-852) — this release does
|
|
114
114
|
not migrate existing data.
|
|
115
115
|
|
|
116
|
+
### Page slugs are unique per category (REB-867)
|
|
117
|
+
|
|
118
|
+
A page slug is unique **within its category**, not globally — `micropigmentacion`
|
|
119
|
+
may exist in both `tratamientos` and `especialidades`. Consequences for a SITE:
|
|
120
|
+
|
|
121
|
+
- **Detail** — `GET /api/site/pages/[slug]` takes an optional `?category=`:
|
|
122
|
+
`?category=<categorySlug>` addresses the page in that category, `?category=`
|
|
123
|
+
(empty) the uncategorised page. Without it a unique slug is served as before;
|
|
124
|
+
an ambiguous one answers **409** with `PageAmbiguousSlugError`
|
|
125
|
+
(`{ error, code: 'ambiguous_slug', candidates: [{ categorySlug }] }`,
|
|
126
|
+
`categorySlug: null` = uncategorised) — the server never picks one for you.
|
|
127
|
+
- **Sitemap** — each `PageSlug` now carries `category` (`PageCategoryRef | null`)
|
|
128
|
+
so the URL can be built as `/<category>/<slug>`.
|
|
129
|
+
- **Embeds** — embed block `data` (`EmbedReferenceData`) gains optional
|
|
130
|
+
`pageId` and `categorySlug` next to `pageSlug`. nexus writes them on save;
|
|
131
|
+
the server resolves `pageId` first, then (`categorySlug`, `pageSlug`), then a
|
|
132
|
+
legacy slug-only reference **only when that slug is unique** — otherwise
|
|
133
|
+
`resolved` is `null`. Build the embed's href from `resolved.category`.
|
|
134
|
+
|
|
135
|
+
### Shop — product trust items (REB-858)
|
|
136
|
+
|
|
137
|
+
`ShopConfig.productTrustItems` is the store-wide list of short trust messages
|
|
138
|
+
(shipping, returns, secure payment…) the owner configures in nexus, in display
|
|
139
|
+
order. Absent, `null` or `[]` all mean **hide the block** — the API never
|
|
140
|
+
serves default items.
|
|
141
|
+
|
|
142
|
+
The shape is **forward-compatible** on purpose, so render it defensively:
|
|
143
|
+
|
|
144
|
+
- **Ignore any item whose `icon` you don't recognise.** `icon` is typed as
|
|
145
|
+
`ShopProductTrustIcon | (string & {})`: today's icons are `shipping`,
|
|
146
|
+
`returns`, `secure-payment`, `support`, `gift`, `pickup`, `warranty` and
|
|
147
|
+
`quality`, but a newer API may add more. Skip unknown icons; never fail on
|
|
148
|
+
them.
|
|
149
|
+
- **Ignore unknown item keys.** A newer API may add fields to an item.
|
|
150
|
+
- Don't rely on the count or length bounds in the response type: at most 6
|
|
151
|
+
items and 1–80 characters of text are nexus write rules, not wire
|
|
152
|
+
guarantees.
|
|
153
|
+
|
|
116
154
|
## How the types stay correct
|
|
117
155
|
|
|
118
156
|
The types are re-derived from the response schemas that live in the Reblu API
|
package/dist/index.d.cts
CHANGED
|
@@ -21,11 +21,11 @@ export type AcademyValidationFieldPublic = { key: string; label: string;
|
|
|
21
21
|
|
|
22
22
|
export type Analytics = { gaId: string | null; clarityId: string | null; recaptchaSiteKey: string | null; contactFormMode: "NOT_CONFIGURED" | "DISABLED" | "DB_ONLY" | "WEBHOOK" | "RESEND"; metaPixelId: string | null; metaVerificationContent: string | null; googleVerificationContent: string | null; consentRequired: boolean; cookiePolicyVersion: string | null; cookieBanner: { enabled: boolean; title: string | null; body: string | null; acceptLabel: string | null; rejectLabel: string | null; manageLabel: string | null; policyUrl: string | null; }; cookieInventory: { vendor: string; category: "necessary" | "analytics" | "marketing"; }[];}
|
|
23
23
|
|
|
24
|
-
export type Block = { 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; };} | { blockType: "profile_embed"; data: { pageSlug: string; };} | { blockType: "doctor_embed"; data: { pageSlug: string; };} | { blockType: "specialty_embed"; data: { pageSlug: string; };}
|
|
24
|
+
export type Block = { 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; };}
|
|
25
25
|
|
|
26
26
|
export type BlockCta = null | { label: string; url: string; isExternal: boolean; variant: string | null;}
|
|
27
27
|
|
|
28
|
-
export type BlockType = "hero" | "
|
|
28
|
+
export type BlockType = "hero" | "page_embed" | "profile_embed" | "doctor_embed" | "specialty_embed" | "richtext" | "faq" | "stats" | "testimonial" | "cta" | "feature_list" | "gallery"
|
|
29
29
|
|
|
30
30
|
export type BlogAuthor = { firstName: string | null; lastName: string | null; avatarUrl: string | null;}
|
|
31
31
|
|
|
@@ -81,6 +81,8 @@ export type CustomFieldOption = { value: string; label: string;}
|
|
|
81
81
|
|
|
82
82
|
export type CustomFieldValueType = "boolean" | "text" | "select" | "multiselect"
|
|
83
83
|
|
|
84
|
+
export type EmbedReferenceData = { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined;}
|
|
85
|
+
|
|
84
86
|
export type LeadInput = { name: string; email?: string | undefined; phone?: string | undefined; businessName?: string | undefined; message?: string | undefined; source?: string | undefined; metadata?: Record<string, unknown> | undefined;}
|
|
85
87
|
|
|
86
88
|
export type LeadSubmission = { id: string; createdAt: string;}
|
|
@@ -89,13 +91,15 @@ export type LegacyPageType = "SERVICE" | "CUSTOM"
|
|
|
89
91
|
|
|
90
92
|
export type Legal = { privacyPolicy: string | null; termsAndConditions: string | null; cookiePolicy: string | null;}
|
|
91
93
|
|
|
92
|
-
export type
|
|
94
|
+
export type PageAmbiguousSlugError = { error: string; code: "ambiguous_slug"; candidates: { categorySlug: string | null; }[];}
|
|
95
|
+
|
|
96
|
+
export type PageBlock = { 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; };} | { 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: "richtext"; data: { html: string; };} | { 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: "faq"; data: { items: { q: string; a: string; }[]; };} | { 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: "stats"; data: { items: { label: string; value: string; }[]; };} | { 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: "testimonial"; data: { quote: string; author: string; role?: string | undefined; avatarUrl?: string | undefined; };} | { 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: "cta"; data: { slot: string; };} | { 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: "feature_list"; data: { items: { text: string; icon?: string | undefined; }[]; };} | { 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: "gallery"; data: { images: { url: string; alt?: string | undefined; caption?: string | undefined; }[]; };} | { 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: "page_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; };} | { 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: "profile_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; };} | { 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: "doctor_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; };} | { 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: "specialty_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; };}
|
|
93
97
|
|
|
94
98
|
export type PageCategoryRef = { name: string; slug: string;}
|
|
95
99
|
|
|
96
100
|
export type PageContentMode = "BLOCKS" | "HTML"
|
|
97
101
|
|
|
98
|
-
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; }; } | { blockType: "profile_embed"; data: { pageSlug: string; }; } | { blockType: "doctor_embed"; data: { pageSlug: string; }; } | { blockType: "specialty_embed"; data: { pageSlug: string; }; }))[]; 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;}
|
|
99
103
|
|
|
100
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;}
|
|
101
105
|
|
|
@@ -103,7 +107,7 @@ export type PageSection = { id: string; order: number; heading: string
|
|
|
103
107
|
|
|
104
108
|
export type PageSectionImage = { url: string; alt: string; caption: string | null; order: number;}
|
|
105
109
|
|
|
106
|
-
export type PageSlug = { slug: string; type: "SERVICE" | "CUSTOM"; updatedAt: string;}
|
|
110
|
+
export type PageSlug = { slug: string; type: "SERVICE" | "CUSTOM"; updatedAt: string; category?: { name: string; slug: string; } | null | undefined;}
|
|
107
111
|
|
|
108
112
|
export type PageType = "custom" | "service" | "treatments" | "specialties" | "team" | "generic"
|
|
109
113
|
|
|
@@ -157,7 +161,7 @@ export type ShopCheckoutInput = { items: { productId: string; q
|
|
|
157
161
|
|
|
158
162
|
export type ShopCheckoutSession = { url: string; sessionId: string;}
|
|
159
163
|
|
|
160
|
-
export type ShopConfig = { shopName: string | null; defaultLowStockThreshold: number; currencyCode: string; stripePublishableKey: string | null; stripeTestPublishableKey: string | null; stripeTestMode: boolean; shippingEnabled: boolean; pickupEnabled: boolean; taxEnabled: boolean; taxIncludedInPrice: boolean;}
|
|
164
|
+
export type ShopConfig = { shopName: string | null; defaultLowStockThreshold: number; currencyCode: string; stripePublishableKey: string | null; stripeTestPublishableKey: string | null; stripeTestMode: boolean; shippingEnabled: boolean; pickupEnabled: boolean; taxEnabled: boolean; taxIncludedInPrice: boolean; productTrustItems?: { [x: string]: unknown; icon: (string & {}) | "shipping" | "returns" | "secure-payment" | "support" | "gift" | "pickup" | "warranty" | "quality"; text: string; }[] | null | undefined;}
|
|
161
165
|
|
|
162
166
|
export type ShopDiscountApplication = { valid: boolean; discount: number; type: "PERCENTAGE" | "FIXED" | null; code: string | null; error?: string | undefined;}
|
|
163
167
|
|
|
@@ -185,6 +189,10 @@ export type ShopProductListItem = { id: string; slug: string; name: str
|
|
|
185
189
|
|
|
186
190
|
export type ShopProductListParams = { page?: number | undefined; limit?: number | undefined; q?: string | undefined; sort?: "price_asc" | "price_desc" | "newest" | "on_sale" | undefined; category?: string | undefined; priceMin?: number | undefined; priceMax?: number | undefined; onSale?: boolean | undefined; taxonomy?: Record<string, string> | undefined; attr?: Record<string, string | string[]> | undefined;}
|
|
187
191
|
|
|
192
|
+
export type ShopProductTrustIcon = "shipping" | "returns" | "secure-payment" | "support" | "gift" | "pickup" | "warranty" | "quality"
|
|
193
|
+
|
|
194
|
+
export type ShopProductTrustItem = { [x: string]: unknown; icon: (string & {}) | "shipping" | "returns" | "secure-payment" | "support" | "gift" | "pickup" | "warranty" | "quality"; text: string;}
|
|
195
|
+
|
|
188
196
|
export type ShopProductVariant = { id: string; name: string; sku: string | null; price: number | null; attributes: unknown; isActive: boolean; sortOrder: number;}
|
|
189
197
|
|
|
190
198
|
export type ShopProductVideo = { url: string; title: string | null; isExternal: boolean; thumbnailUrl: string | null; sortOrder: number;}
|
package/dist/index.d.ts
CHANGED
|
@@ -21,11 +21,11 @@ export type AcademyValidationFieldPublic = { key: string; label: string;
|
|
|
21
21
|
|
|
22
22
|
export type Analytics = { gaId: string | null; clarityId: string | null; recaptchaSiteKey: string | null; contactFormMode: "NOT_CONFIGURED" | "DISABLED" | "DB_ONLY" | "WEBHOOK" | "RESEND"; metaPixelId: string | null; metaVerificationContent: string | null; googleVerificationContent: string | null; consentRequired: boolean; cookiePolicyVersion: string | null; cookieBanner: { enabled: boolean; title: string | null; body: string | null; acceptLabel: string | null; rejectLabel: string | null; manageLabel: string | null; policyUrl: string | null; }; cookieInventory: { vendor: string; category: "necessary" | "analytics" | "marketing"; }[];}
|
|
23
23
|
|
|
24
|
-
export type Block = { 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; };} | { blockType: "profile_embed"; data: { pageSlug: string; };} | { blockType: "doctor_embed"; data: { pageSlug: string; };} | { blockType: "specialty_embed"; data: { pageSlug: string; };}
|
|
24
|
+
export type Block = { 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; };}
|
|
25
25
|
|
|
26
26
|
export type BlockCta = null | { label: string; url: string; isExternal: boolean; variant: string | null;}
|
|
27
27
|
|
|
28
|
-
export type BlockType = "hero" | "
|
|
28
|
+
export type BlockType = "hero" | "page_embed" | "profile_embed" | "doctor_embed" | "specialty_embed" | "richtext" | "faq" | "stats" | "testimonial" | "cta" | "feature_list" | "gallery"
|
|
29
29
|
|
|
30
30
|
export type BlogAuthor = { firstName: string | null; lastName: string | null; avatarUrl: string | null;}
|
|
31
31
|
|
|
@@ -81,6 +81,8 @@ export type CustomFieldOption = { value: string; label: string;}
|
|
|
81
81
|
|
|
82
82
|
export type CustomFieldValueType = "boolean" | "text" | "select" | "multiselect"
|
|
83
83
|
|
|
84
|
+
export type EmbedReferenceData = { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined;}
|
|
85
|
+
|
|
84
86
|
export type LeadInput = { name: string; email?: string | undefined; phone?: string | undefined; businessName?: string | undefined; message?: string | undefined; source?: string | undefined; metadata?: Record<string, unknown> | undefined;}
|
|
85
87
|
|
|
86
88
|
export type LeadSubmission = { id: string; createdAt: string;}
|
|
@@ -89,13 +91,15 @@ export type LegacyPageType = "SERVICE" | "CUSTOM"
|
|
|
89
91
|
|
|
90
92
|
export type Legal = { privacyPolicy: string | null; termsAndConditions: string | null; cookiePolicy: string | null;}
|
|
91
93
|
|
|
92
|
-
export type
|
|
94
|
+
export type PageAmbiguousSlugError = { error: string; code: "ambiguous_slug"; candidates: { categorySlug: string | null; }[];}
|
|
95
|
+
|
|
96
|
+
export type PageBlock = { 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; };} | { 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: "richtext"; data: { html: string; };} | { 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: "faq"; data: { items: { q: string; a: string; }[]; };} | { 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: "stats"; data: { items: { label: string; value: string; }[]; };} | { 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: "testimonial"; data: { quote: string; author: string; role?: string | undefined; avatarUrl?: string | undefined; };} | { 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: "cta"; data: { slot: string; };} | { 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: "feature_list"; data: { items: { text: string; icon?: string | undefined; }[]; };} | { 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: "gallery"; data: { images: { url: string; alt?: string | undefined; caption?: string | undefined; }[]; };} | { 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: "page_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; };} | { 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: "profile_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; };} | { 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: "doctor_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; };} | { 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: "specialty_embed"; data: { pageSlug: string; pageId?: string | undefined; categorySlug?: string | null | undefined; };}
|
|
93
97
|
|
|
94
98
|
export type PageCategoryRef = { name: string; slug: string;}
|
|
95
99
|
|
|
96
100
|
export type PageContentMode = "BLOCKS" | "HTML"
|
|
97
101
|
|
|
98
|
-
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; }; } | { blockType: "profile_embed"; data: { pageSlug: string; }; } | { blockType: "doctor_embed"; data: { pageSlug: string; }; } | { blockType: "specialty_embed"; data: { pageSlug: string; }; }))[]; 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;}
|
|
99
103
|
|
|
100
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;}
|
|
101
105
|
|
|
@@ -103,7 +107,7 @@ export type PageSection = { id: string; order: number; heading: string
|
|
|
103
107
|
|
|
104
108
|
export type PageSectionImage = { url: string; alt: string; caption: string | null; order: number;}
|
|
105
109
|
|
|
106
|
-
export type PageSlug = { slug: string; type: "SERVICE" | "CUSTOM"; updatedAt: string;}
|
|
110
|
+
export type PageSlug = { slug: string; type: "SERVICE" | "CUSTOM"; updatedAt: string; category?: { name: string; slug: string; } | null | undefined;}
|
|
107
111
|
|
|
108
112
|
export type PageType = "custom" | "service" | "treatments" | "specialties" | "team" | "generic"
|
|
109
113
|
|
|
@@ -157,7 +161,7 @@ export type ShopCheckoutInput = { items: { productId: string; q
|
|
|
157
161
|
|
|
158
162
|
export type ShopCheckoutSession = { url: string; sessionId: string;}
|
|
159
163
|
|
|
160
|
-
export type ShopConfig = { shopName: string | null; defaultLowStockThreshold: number; currencyCode: string; stripePublishableKey: string | null; stripeTestPublishableKey: string | null; stripeTestMode: boolean; shippingEnabled: boolean; pickupEnabled: boolean; taxEnabled: boolean; taxIncludedInPrice: boolean;}
|
|
164
|
+
export type ShopConfig = { shopName: string | null; defaultLowStockThreshold: number; currencyCode: string; stripePublishableKey: string | null; stripeTestPublishableKey: string | null; stripeTestMode: boolean; shippingEnabled: boolean; pickupEnabled: boolean; taxEnabled: boolean; taxIncludedInPrice: boolean; productTrustItems?: { [x: string]: unknown; icon: (string & {}) | "shipping" | "returns" | "secure-payment" | "support" | "gift" | "pickup" | "warranty" | "quality"; text: string; }[] | null | undefined;}
|
|
161
165
|
|
|
162
166
|
export type ShopDiscountApplication = { valid: boolean; discount: number; type: "PERCENTAGE" | "FIXED" | null; code: string | null; error?: string | undefined;}
|
|
163
167
|
|
|
@@ -185,6 +189,10 @@ export type ShopProductListItem = { id: string; slug: string; name: str
|
|
|
185
189
|
|
|
186
190
|
export type ShopProductListParams = { page?: number | undefined; limit?: number | undefined; q?: string | undefined; sort?: "price_asc" | "price_desc" | "newest" | "on_sale" | undefined; category?: string | undefined; priceMin?: number | undefined; priceMax?: number | undefined; onSale?: boolean | undefined; taxonomy?: Record<string, string> | undefined; attr?: Record<string, string | string[]> | undefined;}
|
|
187
191
|
|
|
192
|
+
export type ShopProductTrustIcon = "shipping" | "returns" | "secure-payment" | "support" | "gift" | "pickup" | "warranty" | "quality"
|
|
193
|
+
|
|
194
|
+
export type ShopProductTrustItem = { [x: string]: unknown; icon: (string & {}) | "shipping" | "returns" | "secure-payment" | "support" | "gift" | "pickup" | "warranty" | "quality"; text: string;}
|
|
195
|
+
|
|
188
196
|
export type ShopProductVariant = { id: string; name: string; sku: string | null; price: number | null; attributes: unknown; isActive: boolean; sortOrder: number;}
|
|
189
197
|
|
|
190
198
|
export type ShopProductVideo = { url: string; title: string | null; isExternal: boolean; thumbnailUrl: string | null; sortOrder: number;}
|
package/package.json
CHANGED