@tui/design-system 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 +68 -1
- package/dist/themes/crystalski/index.css +24 -20
- package/dist/themes/crystalski/index.css.map +1 -1
- package/dist/themes/firstchoice/index.css +23 -20
- package/dist/themes/firstchoice/index.css.map +1 -1
- package/dist/themes/tui/index.css +36 -32
- package/dist/themes/tui/index.css.map +1 -1
- package/package.json +5 -4
- package/scss/lib/accordion/_mixins.scss +17 -1
- package/scss/lib/cards/product/_index.scss +3 -0
- package/scss/lib/cards/product/_mixins.scss +351 -0
- package/scss/lib/cards/product/_variables.scss +9 -0
- package/scss/lib/cards/search/_mixins.scss +15 -2
- package/scss/lib/forms/input-checkbox/_mixins.scss +2 -1
- package/scss/lib/forms/input-radio/_mixins.scss +2 -1
- package/scss/lib/highlight-panel/_mixins.scss +16 -2
- package/scss/lib/show-more-less/_mixins.scss +15 -4
- package/scss/lib/skeleton/_mixins.scss +33 -12
- package/scss/lib/timeline/_index.scss +2 -0
- package/scss/lib/timeline/_mixins.scss +87 -0
- package/scss/mixins.scss +5 -2
- package/scss/reset.scss +4 -0
- package/scss/themes/crystalski/_overrides.scss +25 -26
- package/scss/themes/crystalski/index.scss +13 -10
- package/scss/themes/firstchoice/_overrides.scss +33 -28
- package/scss/themes/firstchoice/index.scss +9 -6
- package/scss/themes/firstchoice/theme.json +7 -0
- package/scss/themes/tui/_overrides.scss +8 -3
- package/scss/themes/tui/index.scss +12 -9
- package/scss/variables/base-theme.json +30 -8
- package/scss/variables.scss +4 -2
- package/types/components.ts +309 -185
package/types/components.ts
CHANGED
|
@@ -7,6 +7,10 @@ export type IconPosition = 'none' | 'leading' | 'trailing';
|
|
|
7
7
|
export type ButtonVariantBase = 'primary' | 'secondary' | 'promotion' | 'search';
|
|
8
8
|
export type HeadingLevel = '2' | '3' | '4' | '5' | '6';
|
|
9
9
|
|
|
10
|
+
// ═══════════════════════════════════════════════════════════
|
|
11
|
+
// COMPONENTS
|
|
12
|
+
// ═══════════════════════════════════════════════════════════
|
|
13
|
+
|
|
10
14
|
// ─── Accordion ─────────────────────────────────────────
|
|
11
15
|
export interface AccordionProps {
|
|
12
16
|
hasImage?: 'none' | 'logo' | 'icon';
|
|
@@ -20,7 +24,7 @@ export interface AccordionProps {
|
|
|
20
24
|
}
|
|
21
25
|
|
|
22
26
|
export interface AccordionGroupProps extends AccordionProps {
|
|
23
|
-
group?: 'none' | 'default' | 'divider';
|
|
27
|
+
group?: 'none' | 'default' | 'divider' | 'timeline';
|
|
24
28
|
groupLength?: number;
|
|
25
29
|
intro?: string;
|
|
26
30
|
toggleOpen?: string;
|
|
@@ -55,25 +59,6 @@ export interface AlertProps {
|
|
|
55
59
|
theme?: Theme;
|
|
56
60
|
}
|
|
57
61
|
|
|
58
|
-
// ─── Anchor Tabs ───────────────────────────────────────
|
|
59
|
-
export interface AnchorTab {
|
|
60
|
-
label: string;
|
|
61
|
-
href: string;
|
|
62
|
-
icon?: string;
|
|
63
|
-
disabled?: boolean;
|
|
64
|
-
sectionContent?: string;
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
export interface AnchorTabsProps {
|
|
68
|
-
icon?: string;
|
|
69
|
-
tabsLabelledby?: string;
|
|
70
|
-
tabsLabel?: string;
|
|
71
|
-
/** @deprecated Use `tabsLabelledby` instead */
|
|
72
|
-
ariaLabelledby?: string;
|
|
73
|
-
tabs?: AnchorTab[];
|
|
74
|
-
sticky?: boolean;
|
|
75
|
-
}
|
|
76
|
-
|
|
77
62
|
// ─── Breadcrumb ────────────────────────────────────────
|
|
78
63
|
export interface BreadcrumbItem {
|
|
79
64
|
label: string;
|
|
@@ -100,6 +85,8 @@ export interface ButtonProps {
|
|
|
100
85
|
theme?: Theme;
|
|
101
86
|
}
|
|
102
87
|
|
|
88
|
+
// ─── Cards ─────────────────────────────────────────────
|
|
89
|
+
|
|
103
90
|
// ─── Card Article ──────────────────────────────────────
|
|
104
91
|
export interface CardArticleProps {
|
|
105
92
|
type?: 'static' | 'link' | 'multi-link';
|
|
@@ -118,6 +105,26 @@ export interface CardIconProps {
|
|
|
118
105
|
cardText?: string;
|
|
119
106
|
}
|
|
120
107
|
|
|
108
|
+
// ─── Card Promotion ───────────────────────────────────────
|
|
109
|
+
export interface CardPromotionProps {
|
|
110
|
+
type?: 'default' | 'promo-code';
|
|
111
|
+
condensed?: boolean;
|
|
112
|
+
headingLevel?: HeadingLevel;
|
|
113
|
+
headline?: string;
|
|
114
|
+
scarcityLabel?: string;
|
|
115
|
+
conditions?: string;
|
|
116
|
+
linkLabel?: string;
|
|
117
|
+
icon?: string;
|
|
118
|
+
code?: string;
|
|
119
|
+
copied?: boolean;
|
|
120
|
+
copyLabel?: string;
|
|
121
|
+
copiedLabel?: string;
|
|
122
|
+
expired?: boolean;
|
|
123
|
+
expiredLabel?: string;
|
|
124
|
+
announcementLabel?: string;
|
|
125
|
+
theme?: Theme;
|
|
126
|
+
}
|
|
127
|
+
|
|
121
128
|
// ─── Card Selectable ───────────────────────────────────
|
|
122
129
|
export interface CardSelectableProps {
|
|
123
130
|
disabled?: boolean;
|
|
@@ -135,25 +142,42 @@ export interface CardSelectableProps {
|
|
|
135
142
|
includeTag?: boolean;
|
|
136
143
|
}
|
|
137
144
|
|
|
138
|
-
// ───
|
|
139
|
-
export interface
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
weekLabel?: string;
|
|
145
|
-
weekLabelFull?: string;
|
|
146
|
-
hideInput?: boolean;
|
|
147
|
-
separateCal?: boolean;
|
|
148
|
-
value?: string;
|
|
149
|
-
minDate?: string;
|
|
150
|
-
maxDate?: string;
|
|
151
|
-
previousLabel?: string;
|
|
145
|
+
// ─── Carousel ──────────────────────────────────────────
|
|
146
|
+
export interface CarouselProps {
|
|
147
|
+
variant?: 'page' | 'item';
|
|
148
|
+
itemsPerSlide?: string;
|
|
149
|
+
carouselLabel?: string;
|
|
150
|
+
prevLabel?: string;
|
|
152
151
|
nextLabel?: string;
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
152
|
+
announcementLabel?: string;
|
|
153
|
+
secondaryButtonLabel?: string;
|
|
154
|
+
linkLabel?: string;
|
|
155
|
+
items?: string[];
|
|
156
|
+
theme?: Theme;
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
// ─── Product Card ──────────────────────────────────────
|
|
160
|
+
export interface ProductCardProps {
|
|
161
|
+
flagship?: boolean;
|
|
162
|
+
productLabel?: boolean;
|
|
163
|
+
gallery?: boolean;
|
|
164
|
+
quickview?: boolean;
|
|
165
|
+
promoArea?: boolean;
|
|
166
|
+
highlightsArea?: boolean;
|
|
167
|
+
toggleOpen?: string;
|
|
168
|
+
toggleClose?: string;
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
// ─── Search Card ───────────────────────────────────────
|
|
172
|
+
export interface SearchCardProps {
|
|
173
|
+
flagship?: boolean;
|
|
174
|
+
productLabel?: boolean;
|
|
175
|
+
gallery?: boolean;
|
|
176
|
+
quickview?: boolean;
|
|
177
|
+
promoArea?: boolean;
|
|
178
|
+
highlightsArea?: boolean;
|
|
179
|
+
toggleOpen?: string;
|
|
180
|
+
toggleClose?: string;
|
|
157
181
|
}
|
|
158
182
|
|
|
159
183
|
// ─── Divider ───────────────────────────────────────────
|
|
@@ -165,6 +189,43 @@ export interface DividerProps {
|
|
|
165
189
|
theme?: Theme;
|
|
166
190
|
}
|
|
167
191
|
|
|
192
|
+
// ─── Flight Details ────────────────────────────────────
|
|
193
|
+
export interface FlightDetailsLegProps {
|
|
194
|
+
variant?: 'direct' | 'indirect' | 'indirect-concise';
|
|
195
|
+
airline?: string;
|
|
196
|
+
departureDate?: string;
|
|
197
|
+
departureDateLong?: string;
|
|
198
|
+
arrivalDate?: string;
|
|
199
|
+
arrivalDateLong?: string;
|
|
200
|
+
type?: string;
|
|
201
|
+
duration?: string;
|
|
202
|
+
durationLong?: string;
|
|
203
|
+
originTime: string;
|
|
204
|
+
originName: string;
|
|
205
|
+
originCode: string;
|
|
206
|
+
destinationTime: string;
|
|
207
|
+
destinationName: string;
|
|
208
|
+
destinationCode: string;
|
|
209
|
+
connectionTime?: string;
|
|
210
|
+
connectionTimeLong?: string;
|
|
211
|
+
connectionDetails?: string;
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
export interface FlightDetailsExtendedLegProps extends FlightDetailsLegProps {
|
|
215
|
+
extraLegs?: FlightDetailsLegProps[];
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
export interface FlightDetailsGroupProps {
|
|
219
|
+
outboundLeg: FlightDetailsExtendedLegProps;
|
|
220
|
+
returnLeg: FlightDetailsExtendedLegProps;
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
export interface FlightDetailsProps {
|
|
224
|
+
variant?: 'direct' | 'indirect';
|
|
225
|
+
open?: string;
|
|
226
|
+
close?: string;
|
|
227
|
+
}
|
|
228
|
+
|
|
168
229
|
// ─── Flyout Dropdown ───────────────────────────────────
|
|
169
230
|
export interface FlyoutDropdownProps {
|
|
170
231
|
variant?: 'default' | 'menu-flyout';
|
|
@@ -175,6 +236,30 @@ export interface FlyoutDropdownProps {
|
|
|
175
236
|
scrollerAriaLabel?: string;
|
|
176
237
|
}
|
|
177
238
|
|
|
239
|
+
// ─── Forms ─────────────────────────────────────────────
|
|
240
|
+
|
|
241
|
+
// ─── Datepicker ────────────────────────────────────────
|
|
242
|
+
export interface DatepickerProps {
|
|
243
|
+
rangeSelection?: boolean;
|
|
244
|
+
dualView?: boolean;
|
|
245
|
+
scrollableMobile?: boolean;
|
|
246
|
+
weekNumbers?: boolean;
|
|
247
|
+
weekLabel?: string;
|
|
248
|
+
weekLabelFull?: string;
|
|
249
|
+
hideInput?: boolean;
|
|
250
|
+
separateCal?: boolean;
|
|
251
|
+
value?: string;
|
|
252
|
+
minDate?: string;
|
|
253
|
+
maxDate?: string;
|
|
254
|
+
previousLabel?: string;
|
|
255
|
+
nextLabel?: string;
|
|
256
|
+
announceStart?: string;
|
|
257
|
+
announceRange?: string;
|
|
258
|
+
instructions?: string;
|
|
259
|
+
locale?: string;
|
|
260
|
+
allowedDates?: string;
|
|
261
|
+
}
|
|
262
|
+
|
|
178
263
|
// ─── Form Row ────────────────────────────────────────────
|
|
179
264
|
export interface FormRowProps {
|
|
180
265
|
labelText?: string;
|
|
@@ -187,90 +272,6 @@ export interface FormRowProps {
|
|
|
187
272
|
theme?: Theme;
|
|
188
273
|
}
|
|
189
274
|
|
|
190
|
-
// ─── Hero ──────────────────────────────────────────────
|
|
191
|
-
export interface HeroProps {
|
|
192
|
-
alignment?: 'left' | 'right' | 'center';
|
|
193
|
-
reduced?: boolean;
|
|
194
|
-
variant?: 'default' | 'default slim' | 'flagship' | 'flagship slim' | 'illustration';
|
|
195
|
-
heading?: string;
|
|
196
|
-
content?: string;
|
|
197
|
-
hideButton?: boolean;
|
|
198
|
-
buttonLabel?: string;
|
|
199
|
-
caveat?: string;
|
|
200
|
-
imageUrl?: string;
|
|
201
|
-
altText?: string;
|
|
202
|
-
}
|
|
203
|
-
|
|
204
|
-
// ─── Icon ────────────────────────────────────────────────
|
|
205
|
-
export interface IconProps {
|
|
206
|
-
type?: 'standard' | 'color' | 'bullet';
|
|
207
|
-
nameStandard?: string;
|
|
208
|
-
nameColor?: string;
|
|
209
|
-
nameBullet?: string;
|
|
210
|
-
size?: IconSize;
|
|
211
|
-
color?: string;
|
|
212
|
-
theme?: Theme;
|
|
213
|
-
}
|
|
214
|
-
|
|
215
|
-
// ─── Icon Button ─────────────────────────────────────────
|
|
216
|
-
export interface IconButtonProps {
|
|
217
|
-
element?: 'a' | 'button';
|
|
218
|
-
variant?: ButtonVariantBase | 'ghost' | 'control' | 'shortlist';
|
|
219
|
-
size?: 'small' | 'medium' | 'large';
|
|
220
|
-
isDisabled?: boolean;
|
|
221
|
-
label?: string;
|
|
222
|
-
iconAsset?: string;
|
|
223
|
-
selected?: boolean;
|
|
224
|
-
theme?: Theme;
|
|
225
|
-
}
|
|
226
|
-
|
|
227
|
-
// ─── Image ─────────────────────────────────────────────
|
|
228
|
-
export interface ImageSrcItem {
|
|
229
|
-
url: string;
|
|
230
|
-
size: string;
|
|
231
|
-
}
|
|
232
|
-
|
|
233
|
-
export type ImageFocalPoint =
|
|
234
|
-
'top-left' | 'top-center' | 'top-right' | 'center-left' | 'center' | 'center-right' | 'bottom-left' | 'bottom-center' | 'bottom-right';
|
|
235
|
-
|
|
236
|
-
export interface ImageProps {
|
|
237
|
-
altText: string;
|
|
238
|
-
imageUrl: string;
|
|
239
|
-
srcset?: ImageSrcItem[];
|
|
240
|
-
ratio?: 'landscape' | 'panoramic' | 'portrait' | 'square' | 'wide';
|
|
241
|
-
shape?: 'rectangle' | 'rounded';
|
|
242
|
-
focalPoint?: ImageFocalPoint;
|
|
243
|
-
}
|
|
244
|
-
|
|
245
|
-
// ─── In-Page Tabs ──────────────────────────────────────
|
|
246
|
-
export interface InPageTab {
|
|
247
|
-
label: string;
|
|
248
|
-
content?: string;
|
|
249
|
-
icon?: string;
|
|
250
|
-
disabled?: boolean;
|
|
251
|
-
}
|
|
252
|
-
|
|
253
|
-
export interface InPageTabsProps {
|
|
254
|
-
variant?: 'left-aligned' | 'full-width';
|
|
255
|
-
icon?: string;
|
|
256
|
-
active?: string;
|
|
257
|
-
tabsLabelledby?: string;
|
|
258
|
-
tabsLabel?: string;
|
|
259
|
-
/** @deprecated Use `tabsLabelledby` instead */
|
|
260
|
-
ariaLabelledby?: string;
|
|
261
|
-
tabs?: InPageTab[];
|
|
262
|
-
}
|
|
263
|
-
|
|
264
|
-
// ─── Info Tag ───────────────────────────────────────────
|
|
265
|
-
export interface InfoTagProps {
|
|
266
|
-
variant?: 'info' | 'neutral' | 'scarcity' | 'local-product';
|
|
267
|
-
size?: 'small' | 'medium';
|
|
268
|
-
label?: string;
|
|
269
|
-
leadingIcon?: boolean;
|
|
270
|
-
leadingIconAsset?: string;
|
|
271
|
-
theme?: Theme;
|
|
272
|
-
}
|
|
273
|
-
|
|
274
275
|
// ─── Input Checkbox ────────────────────────────────────
|
|
275
276
|
export interface InputCheckboxProps {
|
|
276
277
|
isIndividual?: boolean;
|
|
@@ -370,6 +371,93 @@ export interface InputTextProps {
|
|
|
370
371
|
theme?: Theme;
|
|
371
372
|
}
|
|
372
373
|
|
|
374
|
+
// ─── Textarea ──────────────────────────────────────────
|
|
375
|
+
export interface TextareaProps {
|
|
376
|
+
textareaValue?: string;
|
|
377
|
+
charCount?: number;
|
|
378
|
+
disabled?: boolean;
|
|
379
|
+
theme?: Theme;
|
|
380
|
+
}
|
|
381
|
+
|
|
382
|
+
// ─── Hero ──────────────────────────────────────────────
|
|
383
|
+
export interface HeroProps {
|
|
384
|
+
alignment?: 'left' | 'right' | 'center';
|
|
385
|
+
reduced?: boolean;
|
|
386
|
+
variant?: 'default' | 'default slim' | 'flagship' | 'flagship slim' | 'illustration';
|
|
387
|
+
heading?: string;
|
|
388
|
+
content?: string;
|
|
389
|
+
hideButton?: boolean;
|
|
390
|
+
buttonLabel?: string;
|
|
391
|
+
caveat?: string;
|
|
392
|
+
imageUrl?: string;
|
|
393
|
+
altText?: string;
|
|
394
|
+
}
|
|
395
|
+
|
|
396
|
+
// ─── Highlight Panel ───────────────────────────────────
|
|
397
|
+
export interface HighlightPanelProps {
|
|
398
|
+
variant?: 'no heading' | 'default' | 'strong' | 'brand';
|
|
399
|
+
title?: string;
|
|
400
|
+
subtitle?: string;
|
|
401
|
+
icon?: string;
|
|
402
|
+
collapsible?: boolean;
|
|
403
|
+
open?: boolean;
|
|
404
|
+
content?: string;
|
|
405
|
+
footer?: string;
|
|
406
|
+
divider?: boolean;
|
|
407
|
+
theme?: Theme;
|
|
408
|
+
}
|
|
409
|
+
|
|
410
|
+
// ─── Icon ────────────────────────────────────────────────
|
|
411
|
+
export interface IconProps {
|
|
412
|
+
type?: 'standard' | 'color' | 'bullet';
|
|
413
|
+
nameStandard?: string;
|
|
414
|
+
nameColor?: string;
|
|
415
|
+
nameBullet?: string;
|
|
416
|
+
size?: IconSize;
|
|
417
|
+
color?: string;
|
|
418
|
+
theme?: Theme;
|
|
419
|
+
}
|
|
420
|
+
|
|
421
|
+
// ─── Icon Button ─────────────────────────────────────────
|
|
422
|
+
export interface IconButtonProps {
|
|
423
|
+
element?: 'a' | 'button';
|
|
424
|
+
variant?: ButtonVariantBase | 'ghost' | 'control' | 'shortlist';
|
|
425
|
+
size?: 'small' | 'medium' | 'large';
|
|
426
|
+
isDisabled?: boolean;
|
|
427
|
+
label?: string;
|
|
428
|
+
iconAsset?: string;
|
|
429
|
+
selected?: boolean;
|
|
430
|
+
theme?: Theme;
|
|
431
|
+
}
|
|
432
|
+
|
|
433
|
+
// ─── Image ─────────────────────────────────────────────
|
|
434
|
+
export interface ImageSrcItem {
|
|
435
|
+
url: string;
|
|
436
|
+
size: string;
|
|
437
|
+
}
|
|
438
|
+
|
|
439
|
+
export type ImageFocalPoint =
|
|
440
|
+
'top-left' | 'top-center' | 'top-right' | 'center-left' | 'center' | 'center-right' | 'bottom-left' | 'bottom-center' | 'bottom-right';
|
|
441
|
+
|
|
442
|
+
export interface ImageProps {
|
|
443
|
+
altText: string;
|
|
444
|
+
imageUrl: string;
|
|
445
|
+
srcset?: ImageSrcItem[];
|
|
446
|
+
ratio?: 'landscape' | 'panoramic' | 'portrait' | 'square' | 'wide';
|
|
447
|
+
shape?: 'rectangle' | 'rounded';
|
|
448
|
+
focalPoint?: ImageFocalPoint;
|
|
449
|
+
}
|
|
450
|
+
|
|
451
|
+
// ─── Info Tag ───────────────────────────────────────────
|
|
452
|
+
export interface InfoTagProps {
|
|
453
|
+
variant?: 'info' | 'neutral' | 'scarcity' | 'local-product';
|
|
454
|
+
size?: 'small' | 'medium';
|
|
455
|
+
label?: string;
|
|
456
|
+
leadingIcon?: boolean;
|
|
457
|
+
leadingIconAsset?: string;
|
|
458
|
+
theme?: Theme;
|
|
459
|
+
}
|
|
460
|
+
|
|
373
461
|
// ─── Link ────────────────────────────────────────────────
|
|
374
462
|
export interface LinkProps {
|
|
375
463
|
href?: string;
|
|
@@ -482,26 +570,6 @@ export interface PriceBoxProps {
|
|
|
482
570
|
footerHtml?: string;
|
|
483
571
|
}
|
|
484
572
|
|
|
485
|
-
// ─── Card Promotion ───────────────────────────────────────
|
|
486
|
-
export interface CardPromotionProps {
|
|
487
|
-
type?: 'default' | 'promo-code';
|
|
488
|
-
condensed?: boolean;
|
|
489
|
-
headingLevel?: HeadingLevel;
|
|
490
|
-
headline?: string;
|
|
491
|
-
scarcityLabel?: string;
|
|
492
|
-
conditions?: string;
|
|
493
|
-
linkLabel?: string;
|
|
494
|
-
icon?: string;
|
|
495
|
-
code?: string;
|
|
496
|
-
copied?: boolean;
|
|
497
|
-
copyLabel?: string;
|
|
498
|
-
copiedLabel?: string;
|
|
499
|
-
expired?: boolean;
|
|
500
|
-
expiredLabel?: string;
|
|
501
|
-
announcementLabel?: string;
|
|
502
|
-
theme?: Theme;
|
|
503
|
-
}
|
|
504
|
-
|
|
505
573
|
// ─── Promo Tag ──────────────────────────────────────────
|
|
506
574
|
export const PromoTagSizes = ['xsmall', 'small', 'medium', 'large', 'xlarge', 'xxlarge'] as const;
|
|
507
575
|
export type PromoTagSize = (typeof PromoTagSizes)[number];
|
|
@@ -515,7 +583,22 @@ export interface PromoTagProps {
|
|
|
515
583
|
theme?: Theme;
|
|
516
584
|
}
|
|
517
585
|
|
|
586
|
+
// ─── Ratings & Reviews ─────────────────────────────────
|
|
587
|
+
|
|
588
|
+
// ─── Ratings: shared ───────────────────────────────────
|
|
589
|
+
export type RangeIconsVariant = 'sun' | 'star' | 'tripadvisor' | 'tui-t' | 'customer' | 'holidaycheck';
|
|
590
|
+
export type RangeIconsSize = 'medium' | 'large';
|
|
591
|
+
|
|
592
|
+
export interface SchemaProps {
|
|
593
|
+
reviewCount?: number;
|
|
594
|
+
itemName?: string;
|
|
595
|
+
author?: string;
|
|
596
|
+
reviewAspect?: string;
|
|
597
|
+
}
|
|
598
|
+
|
|
518
599
|
// ─── Ratings: Customer review ─────────────────────────
|
|
600
|
+
export type NumericalType = 'rating' | 'filter';
|
|
601
|
+
|
|
519
602
|
export interface CustomerReviewProps {
|
|
520
603
|
type?: NumericalType;
|
|
521
604
|
variant?: 'brand' | 'tripadvisor';
|
|
@@ -530,7 +613,6 @@ export interface CustomerReviewProps {
|
|
|
530
613
|
}
|
|
531
614
|
|
|
532
615
|
// ─── Ratings: Numerical (9/10) ─────────────────────────
|
|
533
|
-
export type NumericalType = 'rating' | 'filter';
|
|
534
616
|
export type NumericalVariant = 'brand' | 'alt';
|
|
535
617
|
|
|
536
618
|
export interface NumericalProps {
|
|
@@ -575,7 +657,7 @@ export interface RangeBarProps {
|
|
|
575
657
|
items?: { label: string; score: number; accessibleLabel?: string }[];
|
|
576
658
|
}
|
|
577
659
|
|
|
578
|
-
// ─── Ratings: Range icons
|
|
660
|
+
// ─── Ratings: Range icons ──────────────────────────────
|
|
579
661
|
export interface RangeIconsProps {
|
|
580
662
|
variant?: RangeIconsVariant;
|
|
581
663
|
size?: RangeIconsSize;
|
|
@@ -615,17 +697,6 @@ export interface RangeIconsGroupProps {
|
|
|
615
697
|
theme?: Theme;
|
|
616
698
|
}
|
|
617
699
|
|
|
618
|
-
// ─── Ratings: shared ───────────────────────────────────
|
|
619
|
-
export type RangeIconsVariant = 'sun' | 'star' | 'tripadvisor' | 'tui-t' | 'customer' | 'holidaycheck';
|
|
620
|
-
export type RangeIconsSize = 'medium' | 'large';
|
|
621
|
-
|
|
622
|
-
export interface SchemaProps {
|
|
623
|
-
reviewCount?: number;
|
|
624
|
-
itemName?: string;
|
|
625
|
-
author?: string;
|
|
626
|
-
reviewAspect?: string;
|
|
627
|
-
}
|
|
628
|
-
|
|
629
700
|
// ─── Rich Text ─────────────────────────────────────────
|
|
630
701
|
export interface RichTextProps {
|
|
631
702
|
content?: string;
|
|
@@ -641,18 +712,6 @@ export interface ScrollerProps {
|
|
|
641
712
|
label?: string;
|
|
642
713
|
}
|
|
643
714
|
|
|
644
|
-
// ─── Search Card ───────────────────────────────────────
|
|
645
|
-
export interface SearchCardProps {
|
|
646
|
-
flagship?: boolean;
|
|
647
|
-
productLabel?: boolean;
|
|
648
|
-
gallery?: boolean;
|
|
649
|
-
quickview?: boolean;
|
|
650
|
-
promoArea?: boolean;
|
|
651
|
-
highlightsArea?: boolean;
|
|
652
|
-
toggleOpen?: string;
|
|
653
|
-
toggleClose?: string;
|
|
654
|
-
}
|
|
655
|
-
|
|
656
715
|
// ─── Show More Or Less ──────────────────────────────────
|
|
657
716
|
export interface ShowMoreOrLessProps {
|
|
658
717
|
isOpen?: boolean;
|
|
@@ -691,11 +750,66 @@ export interface SkeletonLayoutProps {
|
|
|
691
750
|
theme?: Theme;
|
|
692
751
|
}
|
|
693
752
|
|
|
694
|
-
// ───
|
|
695
|
-
export interface
|
|
696
|
-
|
|
697
|
-
|
|
753
|
+
// ─── Social Proofing ───────────────────────────────────
|
|
754
|
+
export interface SocialProofingProps {
|
|
755
|
+
theme?: Theme;
|
|
756
|
+
iconAsset?: string;
|
|
757
|
+
iconSize?: 'small';
|
|
758
|
+
hasIcon?: boolean;
|
|
759
|
+
closeLabel?: string;
|
|
760
|
+
}
|
|
761
|
+
|
|
762
|
+
// ─── Tabs ──────────────────────────────────────────────
|
|
763
|
+
|
|
764
|
+
// ─── Anchor Tabs ───────────────────────────────────────
|
|
765
|
+
export interface AnchorTab {
|
|
766
|
+
label: string;
|
|
767
|
+
href: string;
|
|
768
|
+
icon?: string;
|
|
698
769
|
disabled?: boolean;
|
|
770
|
+
sectionContent?: string;
|
|
771
|
+
}
|
|
772
|
+
|
|
773
|
+
export interface AnchorTabsProps {
|
|
774
|
+
icon?: string;
|
|
775
|
+
tabsLabelledby?: string;
|
|
776
|
+
tabsLabel?: string;
|
|
777
|
+
/** @deprecated Use `tabsLabelledby` instead */
|
|
778
|
+
ariaLabelledby?: string;
|
|
779
|
+
tabs?: AnchorTab[];
|
|
780
|
+
sticky?: boolean;
|
|
781
|
+
}
|
|
782
|
+
|
|
783
|
+
// ─── In-Page Tabs ──────────────────────────────────────
|
|
784
|
+
export interface InPageTab {
|
|
785
|
+
label: string;
|
|
786
|
+
content?: string;
|
|
787
|
+
icon?: string;
|
|
788
|
+
disabled?: boolean;
|
|
789
|
+
}
|
|
790
|
+
|
|
791
|
+
export interface InPageTabsProps {
|
|
792
|
+
variant?: 'left-aligned' | 'full-width';
|
|
793
|
+
icon?: string;
|
|
794
|
+
active?: string;
|
|
795
|
+
tabsLabelledby?: string;
|
|
796
|
+
tabsLabel?: string;
|
|
797
|
+
/** @deprecated Use `tabsLabelledby` instead */
|
|
798
|
+
ariaLabelledby?: string;
|
|
799
|
+
tabs?: InPageTab[];
|
|
800
|
+
}
|
|
801
|
+
|
|
802
|
+
// ─── Timeline ───────────────────────────────────────────
|
|
803
|
+
export interface TimelineItemProps {
|
|
804
|
+
icon?: string;
|
|
805
|
+
content?: string;
|
|
806
|
+
gap?: boolean;
|
|
807
|
+
}
|
|
808
|
+
|
|
809
|
+
export interface TimelineProps {
|
|
810
|
+
items?: TimelineItemProps[];
|
|
811
|
+
itemCount?: number;
|
|
812
|
+
gap?: boolean;
|
|
699
813
|
theme?: Theme;
|
|
700
814
|
}
|
|
701
815
|
|
|
@@ -709,7 +823,7 @@ export interface TooltipProps {
|
|
|
709
823
|
theme?: Theme;
|
|
710
824
|
}
|
|
711
825
|
|
|
712
|
-
// ─── Travel Aware Banner
|
|
826
|
+
// ─── Travel Aware Banner ────────────────────────────────
|
|
713
827
|
export interface TravelAwareBannerProps {
|
|
714
828
|
imageUrl?: string;
|
|
715
829
|
imageText?: string;
|
|
@@ -720,18 +834,11 @@ export interface TravelAwareBannerProps {
|
|
|
720
834
|
isExternal?: boolean;
|
|
721
835
|
}
|
|
722
836
|
|
|
723
|
-
//
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
iconAsset?: string;
|
|
727
|
-
iconSize?: 'small';
|
|
728
|
-
hasIcon?: boolean;
|
|
729
|
-
closeLabel?: string;
|
|
730
|
-
}
|
|
731
|
-
|
|
732
|
-
// ─── PATTERNS ────────────────────────────────────────────
|
|
733
|
-
// ─── Edit search ────────────────────────────────────────────
|
|
837
|
+
// ═══════════════════════════════════════════════════════════
|
|
838
|
+
// PATTERNS
|
|
839
|
+
// ═══════════════════════════════════════════════════════════
|
|
734
840
|
|
|
841
|
+
// ─── Edit Search ────────────────────────────────────────
|
|
735
842
|
export interface EditSearchProps {
|
|
736
843
|
variant?: 'back' | 'list';
|
|
737
844
|
heading?: string;
|
|
@@ -739,7 +846,24 @@ export interface EditSearchProps {
|
|
|
739
846
|
uniqueId?: string;
|
|
740
847
|
}
|
|
741
848
|
|
|
742
|
-
// ───
|
|
849
|
+
// ─── Reasons To Book ───────────────────────────────────
|
|
850
|
+
export interface ReasonToBookItem {
|
|
851
|
+
pictogram: string;
|
|
852
|
+
text: string;
|
|
853
|
+
}
|
|
854
|
+
|
|
855
|
+
export interface ReasonsToBookProps {
|
|
856
|
+
heading?: string;
|
|
857
|
+
items?: ReasonToBookItem[];
|
|
858
|
+
linkLabel?: string;
|
|
859
|
+
carouselLabel?: string;
|
|
860
|
+
prevLabel?: string;
|
|
861
|
+
nextLabel?: string;
|
|
862
|
+
announcementLabel?: string;
|
|
863
|
+
theme?: Theme;
|
|
864
|
+
}
|
|
865
|
+
|
|
866
|
+
// ─── Review Card ───────────────────────────────────────
|
|
743
867
|
export interface ReviewCardProps {
|
|
744
868
|
layout?: 'default' | 'compact' | 'dual';
|
|
745
869
|
switchLayout?: boolean;
|
|
@@ -747,7 +871,7 @@ export interface ReviewCardProps {
|
|
|
747
871
|
brand?: 'tripadvisor' | 'customer' | 'holidaycheck';
|
|
748
872
|
}
|
|
749
873
|
|
|
750
|
-
// ─── Review Summary
|
|
874
|
+
// ─── Review Summary ────────────────────────────────────
|
|
751
875
|
export interface ReviewSummaryProps {
|
|
752
876
|
brand?: 'tripadvisor' | 'customer';
|
|
753
877
|
}
|