@cleartrip/talos-flight-itinerary-card 11.0.0 → 11.1.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.
|
@@ -57,6 +57,150 @@
|
|
|
57
57
|
}
|
|
58
58
|
})(jsxRuntime);
|
|
59
59
|
|
|
60
|
+
const staticContainerStyles = ctDesignStyleManager.makeStyles(() => {
|
|
61
|
+
return {
|
|
62
|
+
root: {
|
|
63
|
+
display: 'flex',
|
|
64
|
+
flexDirection: 'column',
|
|
65
|
+
pointerEvents: 'auto'
|
|
66
|
+
}
|
|
67
|
+
};
|
|
68
|
+
});
|
|
69
|
+
function getPointerEventsStyles(pointerEvents) {
|
|
70
|
+
if (pointerEvents === 'box-none') {
|
|
71
|
+
return {
|
|
72
|
+
pointerEvents: 'none',
|
|
73
|
+
'& > *': {
|
|
74
|
+
pointerEvents: 'auto'
|
|
75
|
+
}
|
|
76
|
+
};
|
|
77
|
+
}
|
|
78
|
+
if (pointerEvents === 'box-only') {
|
|
79
|
+
return {
|
|
80
|
+
pointerEvents: 'auto',
|
|
81
|
+
'& > *': {
|
|
82
|
+
pointerEvents: 'none'
|
|
83
|
+
}
|
|
84
|
+
};
|
|
85
|
+
}
|
|
86
|
+
if (pointerEvents === 'none') {
|
|
87
|
+
return {
|
|
88
|
+
pointerEvents: 'none'
|
|
89
|
+
};
|
|
90
|
+
}
|
|
91
|
+
return {
|
|
92
|
+
pointerEvents: 'auto'
|
|
93
|
+
};
|
|
94
|
+
}
|
|
95
|
+
const Container = React.forwardRef(({
|
|
96
|
+
id,
|
|
97
|
+
as: ContainerAs = 'div',
|
|
98
|
+
children,
|
|
99
|
+
styleConfig,
|
|
100
|
+
onClick,
|
|
101
|
+
onLayout,
|
|
102
|
+
onMouseEnter,
|
|
103
|
+
onMouseLeave,
|
|
104
|
+
onTransitionEnd,
|
|
105
|
+
onTouchStart,
|
|
106
|
+
onTouchEnd,
|
|
107
|
+
onTouchCancel,
|
|
108
|
+
onTouchMove,
|
|
109
|
+
pointerEvents,
|
|
110
|
+
hitSlop: _hitSlop,
|
|
111
|
+
hapticEnabled: _hapticEnabled,
|
|
112
|
+
hapticVariant: _hapticVariant,
|
|
113
|
+
hapticRepeat: _hapticRepeat
|
|
114
|
+
}, forwardedRef) => {
|
|
115
|
+
const localRef = React.useRef(null);
|
|
116
|
+
const handleFocus = React.useCallback(() => {
|
|
117
|
+
var _a;
|
|
118
|
+
(_a = localRef.current) === null || _a === void 0 ? void 0 : _a.focus();
|
|
119
|
+
}, []);
|
|
120
|
+
const handleGetBoundingRect = React.useCallback(callback => {
|
|
121
|
+
var _a;
|
|
122
|
+
const rect = (_a = localRef.current) === null || _a === void 0 ? void 0 : _a.getBoundingClientRect();
|
|
123
|
+
if (rect) {
|
|
124
|
+
callback === null || callback === void 0 ? void 0 : callback({
|
|
125
|
+
x: rect.x,
|
|
126
|
+
y: rect.y,
|
|
127
|
+
width: rect.width,
|
|
128
|
+
height: rect.height
|
|
129
|
+
});
|
|
130
|
+
}
|
|
131
|
+
}, []);
|
|
132
|
+
const handleAddEventListener = React.useCallback((type, listener, options) => {
|
|
133
|
+
var _a;
|
|
134
|
+
(_a = localRef.current) === null || _a === void 0 ? void 0 : _a.addEventListener(type, listener, options);
|
|
135
|
+
}, []);
|
|
136
|
+
const handleRemoveEventListener = React.useCallback((type, listener, options) => {
|
|
137
|
+
var _a;
|
|
138
|
+
(_a = localRef.current) === null || _a === void 0 ? void 0 : _a.removeEventListener(type, listener, options);
|
|
139
|
+
}, []);
|
|
140
|
+
React.useImperativeHandle(forwardedRef, () => {
|
|
141
|
+
var _a;
|
|
142
|
+
return {
|
|
143
|
+
focus: handleFocus,
|
|
144
|
+
getBoundingRectWithCallback: handleGetBoundingRect,
|
|
145
|
+
getElementRef: () => localRef,
|
|
146
|
+
style: ((_a = localRef.current) === null || _a === void 0 ? void 0 : _a.style) || {},
|
|
147
|
+
classList: {
|
|
148
|
+
add: className => {
|
|
149
|
+
var _a;
|
|
150
|
+
(_a = localRef.current) === null || _a === void 0 ? void 0 : _a.classList.add(className);
|
|
151
|
+
}
|
|
152
|
+
},
|
|
153
|
+
measure: _callback => {
|
|
154
|
+
var _a;
|
|
155
|
+
(_a = localRef.current) === null || _a === void 0 ? void 0 : _a.getBoundingClientRect();
|
|
156
|
+
},
|
|
157
|
+
addEventListener: handleAddEventListener,
|
|
158
|
+
removeEventListener: handleRemoveEventListener
|
|
159
|
+
};
|
|
160
|
+
}, [handleFocus, handleGetBoundingRect, handleAddEventListener, handleRemoveEventListener]);
|
|
161
|
+
const {
|
|
162
|
+
root: rootStyles = []
|
|
163
|
+
} = styleConfig || {};
|
|
164
|
+
const pointerEventsStyle = React.useMemo(() => {
|
|
165
|
+
if (pointerEvents == null) return null;
|
|
166
|
+
return getPointerEventsStyles(pointerEvents);
|
|
167
|
+
}, [pointerEvents]);
|
|
168
|
+
const mergedRootStyles = ctDesignStyleManager.useWebMergeStyles([staticContainerStyles.root, ...rootStyles, ...(pointerEventsStyle ? [pointerEventsStyle] : [])], [rootStyles, pointerEventsStyle]);
|
|
169
|
+
React.useLayoutEffect(() => {
|
|
170
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
171
|
+
onLayout === null || onLayout === void 0 ? void 0 : onLayout({
|
|
172
|
+
layout: {
|
|
173
|
+
height: (_b = (_a = localRef.current) === null || _a === void 0 ? void 0 : _a.clientHeight) !== null && _b !== void 0 ? _b : 0,
|
|
174
|
+
width: (_d = (_c = localRef.current) === null || _c === void 0 ? void 0 : _c.clientWidth) !== null && _d !== void 0 ? _d : 0,
|
|
175
|
+
x: (_f = (_e = localRef.current) === null || _e === void 0 ? void 0 : _e.getBoundingClientRect().x) !== null && _f !== void 0 ? _f : 0,
|
|
176
|
+
y: (_h = (_g = localRef.current) === null || _g === void 0 ? void 0 : _g.getBoundingClientRect().y) !== null && _h !== void 0 ? _h : 0
|
|
177
|
+
}
|
|
178
|
+
});
|
|
179
|
+
}, [onLayout]);
|
|
180
|
+
return jsxRuntimeExports.jsx(ContainerAs, {
|
|
181
|
+
id: id,
|
|
182
|
+
ref: localRef,
|
|
183
|
+
className: mergedRootStyles,
|
|
184
|
+
onClick: event => onClick === null || onClick === void 0 ? void 0 : onClick({
|
|
185
|
+
stopPropagation: () => event.stopPropagation(),
|
|
186
|
+
preventDefault: () => event.preventDefault(),
|
|
187
|
+
nativeEvent: {
|
|
188
|
+
locationX: event.clientX,
|
|
189
|
+
locationY: event.clientY
|
|
190
|
+
}
|
|
191
|
+
}),
|
|
192
|
+
onMouseEnter: onMouseEnter,
|
|
193
|
+
onMouseLeave: onMouseLeave,
|
|
194
|
+
onTransitionEnd: onTransitionEnd,
|
|
195
|
+
onTouchStart: onTouchStart,
|
|
196
|
+
onTouchEnd: onTouchEnd,
|
|
197
|
+
onTouchCancel: onTouchCancel,
|
|
198
|
+
onTouchMove: onTouchMove,
|
|
199
|
+
children: children
|
|
200
|
+
});
|
|
201
|
+
});
|
|
202
|
+
Container.displayName = 'Container';
|
|
203
|
+
|
|
60
204
|
var isDevelopment$1 = false;
|
|
61
205
|
|
|
62
206
|
/*
|
|
@@ -1706,457 +1850,83 @@
|
|
|
1706
1850
|
}),
|
|
1707
1851
|
css = _createEmotion.css;
|
|
1708
1852
|
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
|
|
1712
|
-
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
|
|
1717
|
-
|
|
1718
|
-
|
|
1719
|
-
|
|
1720
|
-
|
|
1721
|
-
|
|
1722
|
-
|
|
1723
|
-
|
|
1853
|
+
var TypographyVariant;
|
|
1854
|
+
(function (TypographyVariant) {
|
|
1855
|
+
TypographyVariant["HD1"] = "HD1";
|
|
1856
|
+
TypographyVariant["HD2"] = "HD2";
|
|
1857
|
+
TypographyVariant["HD3"] = "HD3";
|
|
1858
|
+
TypographyVariant["HM1"] = "HM1";
|
|
1859
|
+
TypographyVariant["HM2"] = "HM2";
|
|
1860
|
+
TypographyVariant["HM3"] = "HM3";
|
|
1861
|
+
TypographyVariant["HM4"] = "HM4";
|
|
1862
|
+
TypographyVariant["B1"] = "B1";
|
|
1863
|
+
TypographyVariant["B2"] = "B2";
|
|
1864
|
+
TypographyVariant["B3"] = "B3";
|
|
1865
|
+
TypographyVariant["B3CAPS"] = "B3CAPS";
|
|
1866
|
+
TypographyVariant["B4"] = "B4";
|
|
1867
|
+
TypographyVariant["B4CAPS"] = "B4CAPS";
|
|
1868
|
+
TypographyVariant["P1"] = "P1";
|
|
1869
|
+
TypographyVariant["P2"] = "P2";
|
|
1870
|
+
TypographyVariant["P3"] = "P3";
|
|
1871
|
+
TypographyVariant["P4"] = "P4";
|
|
1872
|
+
TypographyVariant["L1"] = "L1";
|
|
1873
|
+
TypographyVariant["L2"] = "L2";
|
|
1874
|
+
TypographyVariant["L3"] = "L3";
|
|
1875
|
+
TypographyVariant["OVERLINE"] = "OVERLINE";
|
|
1876
|
+
TypographyVariant["TAG"] = "TAG";
|
|
1877
|
+
TypographyVariant["M4BOLD"] = "M4BOLD";
|
|
1878
|
+
TypographyVariant["WRAPPER"] = "WRAPPER";
|
|
1879
|
+
})(TypographyVariant || (TypographyVariant = {}));
|
|
1880
|
+
var TypographyColor;
|
|
1881
|
+
(function (TypographyColor) {
|
|
1882
|
+
TypographyColor["PRIMARY"] = "primary";
|
|
1883
|
+
TypographyColor["SECONDARY"] = "secondary";
|
|
1884
|
+
TypographyColor["TERTIARY"] = "tertiary";
|
|
1885
|
+
TypographyColor["HEADING"] = "heading";
|
|
1886
|
+
TypographyColor["SUBHEADING"] = "subheading";
|
|
1887
|
+
TypographyColor["SUCCESS"] = "success";
|
|
1888
|
+
TypographyColor["ALERT"] = "alert";
|
|
1889
|
+
TypographyColor["WARNING"] = "warning";
|
|
1890
|
+
TypographyColor["DISABLED"] = "disabled";
|
|
1891
|
+
TypographyColor["LINK"] = "link";
|
|
1892
|
+
TypographyColor["NEUTRAL"] = "neutral";
|
|
1893
|
+
TypographyColor["LINK2"] = "link2";
|
|
1894
|
+
TypographyColor["PRIMARY2"] = "primary2";
|
|
1895
|
+
TypographyColor["SECONDARY2"] = "secondary2";
|
|
1896
|
+
TypographyColor["GRAPETINI"] = "grapetini900";
|
|
1897
|
+
TypographyColor["PINA_COLADA750"] = "pinacolada750";
|
|
1898
|
+
TypographyColor["BRAND"] = "brand";
|
|
1899
|
+
TypographyColor["ALERT500"] = "alert500";
|
|
1900
|
+
TypographyColor["NEUTRAL50"] = "neutral50";
|
|
1901
|
+
TypographyColor["MARGARITA750"] = "margarita750";
|
|
1902
|
+
TypographyColor["GREEN100"] = "green100";
|
|
1903
|
+
TypographyColor["RED100"] = "red100";
|
|
1904
|
+
TypographyColor["ALERT300"] = "alert300";
|
|
1905
|
+
TypographyColor["RED500"] = "red500";
|
|
1906
|
+
TypographyColor["CORALPINK"] = "coralpink";
|
|
1907
|
+
TypographyColor["WARNING500"] = "warning500";
|
|
1908
|
+
TypographyColor["BLUE700"] = "blue700";
|
|
1909
|
+
TypographyColor["NEUTRAL650"] = "neutral650";
|
|
1910
|
+
TypographyColor["GREY700"] = "grey700";
|
|
1911
|
+
TypographyColor["BLACK000"] = "black000";
|
|
1912
|
+
})(TypographyColor || (TypographyColor = {}));
|
|
1913
|
+
const getTypographyVariant = (theme, variant) => {
|
|
1914
|
+
switch (variant) {
|
|
1915
|
+
case TypographyVariant.HD1:
|
|
1916
|
+
{
|
|
1917
|
+
return {
|
|
1918
|
+
fontSize: theme.typography.size[48],
|
|
1919
|
+
fontWeight: theme.typography.weight.semibold,
|
|
1920
|
+
lineHeight: theme.typography.lineHeight[56]
|
|
1921
|
+
};
|
|
1724
1922
|
}
|
|
1725
|
-
|
|
1726
|
-
|
|
1727
|
-
|
|
1728
|
-
|
|
1729
|
-
|
|
1730
|
-
|
|
1731
|
-
|
|
1732
|
-
}
|
|
1733
|
-
};
|
|
1734
|
-
}
|
|
1735
|
-
if (pointerEvents === 'none') {
|
|
1736
|
-
return {
|
|
1737
|
-
pointerEvents: 'none'
|
|
1738
|
-
};
|
|
1739
|
-
}
|
|
1740
|
-
return {
|
|
1741
|
-
pointerEvents: 'auto'
|
|
1742
|
-
};
|
|
1743
|
-
}
|
|
1744
|
-
const Container$1 = React.forwardRef(({
|
|
1745
|
-
id,
|
|
1746
|
-
as: ContainerAs = 'div',
|
|
1747
|
-
children,
|
|
1748
|
-
styleConfig,
|
|
1749
|
-
onClick,
|
|
1750
|
-
onLayout,
|
|
1751
|
-
onMouseEnter,
|
|
1752
|
-
onMouseLeave,
|
|
1753
|
-
onTransitionEnd,
|
|
1754
|
-
onTouchStart,
|
|
1755
|
-
onTouchEnd,
|
|
1756
|
-
onTouchCancel,
|
|
1757
|
-
onTouchMove,
|
|
1758
|
-
pointerEvents,
|
|
1759
|
-
hitSlop: _hitSlop,
|
|
1760
|
-
hapticEnabled: _hapticEnabled,
|
|
1761
|
-
hapticVariant: _hapticVariant,
|
|
1762
|
-
hapticRepeat: _hapticRepeat
|
|
1763
|
-
}, forwardedRef) => {
|
|
1764
|
-
const localRef = React.useRef(null);
|
|
1765
|
-
const handleFocus = React.useCallback(() => {
|
|
1766
|
-
var _a;
|
|
1767
|
-
(_a = localRef.current) === null || _a === void 0 ? void 0 : _a.focus();
|
|
1768
|
-
}, []);
|
|
1769
|
-
const handleGetBoundingRect = React.useCallback(callback => {
|
|
1770
|
-
var _a;
|
|
1771
|
-
const rect = (_a = localRef.current) === null || _a === void 0 ? void 0 : _a.getBoundingClientRect();
|
|
1772
|
-
if (rect) {
|
|
1773
|
-
callback === null || callback === void 0 ? void 0 : callback({
|
|
1774
|
-
x: rect.x,
|
|
1775
|
-
y: rect.y,
|
|
1776
|
-
width: rect.width,
|
|
1777
|
-
height: rect.height
|
|
1778
|
-
});
|
|
1779
|
-
}
|
|
1780
|
-
}, []);
|
|
1781
|
-
const handleAddEventListener = React.useCallback((type, listener, options) => {
|
|
1782
|
-
var _a;
|
|
1783
|
-
(_a = localRef.current) === null || _a === void 0 ? void 0 : _a.addEventListener(type, listener, options);
|
|
1784
|
-
}, []);
|
|
1785
|
-
const handleRemoveEventListener = React.useCallback((type, listener, options) => {
|
|
1786
|
-
var _a;
|
|
1787
|
-
(_a = localRef.current) === null || _a === void 0 ? void 0 : _a.removeEventListener(type, listener, options);
|
|
1788
|
-
}, []);
|
|
1789
|
-
React.useImperativeHandle(forwardedRef, () => {
|
|
1790
|
-
var _a;
|
|
1791
|
-
return {
|
|
1792
|
-
focus: handleFocus,
|
|
1793
|
-
getBoundingRectWithCallback: handleGetBoundingRect,
|
|
1794
|
-
getElementRef: () => localRef,
|
|
1795
|
-
style: ((_a = localRef.current) === null || _a === void 0 ? void 0 : _a.style) || {},
|
|
1796
|
-
classList: {
|
|
1797
|
-
add: className => {
|
|
1798
|
-
var _a;
|
|
1799
|
-
(_a = localRef.current) === null || _a === void 0 ? void 0 : _a.classList.add(className);
|
|
1800
|
-
}
|
|
1801
|
-
},
|
|
1802
|
-
measure: _callback => {
|
|
1803
|
-
var _a;
|
|
1804
|
-
(_a = localRef.current) === null || _a === void 0 ? void 0 : _a.getBoundingClientRect();
|
|
1805
|
-
},
|
|
1806
|
-
addEventListener: handleAddEventListener,
|
|
1807
|
-
removeEventListener: handleRemoveEventListener
|
|
1808
|
-
};
|
|
1809
|
-
}, [handleFocus, handleGetBoundingRect, handleAddEventListener, handleRemoveEventListener]);
|
|
1810
|
-
const {
|
|
1811
|
-
root: rootStyles = []
|
|
1812
|
-
} = styleConfig || {};
|
|
1813
|
-
const pointerEventsStyle = React.useMemo(() => {
|
|
1814
|
-
if (pointerEvents == null) return null;
|
|
1815
|
-
return getPointerEventsStyles$1(pointerEvents);
|
|
1816
|
-
}, [pointerEvents]);
|
|
1817
|
-
const mergedRootStyles = ctDesignStyleManager.useWebMergeStyles([staticContainerStyles$1.root, ...rootStyles, ...(pointerEventsStyle ? [pointerEventsStyle] : [])], [rootStyles, pointerEventsStyle]);
|
|
1818
|
-
React.useLayoutEffect(() => {
|
|
1819
|
-
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
1820
|
-
onLayout === null || onLayout === void 0 ? void 0 : onLayout({
|
|
1821
|
-
layout: {
|
|
1822
|
-
height: (_b = (_a = localRef.current) === null || _a === void 0 ? void 0 : _a.clientHeight) !== null && _b !== void 0 ? _b : 0,
|
|
1823
|
-
width: (_d = (_c = localRef.current) === null || _c === void 0 ? void 0 : _c.clientWidth) !== null && _d !== void 0 ? _d : 0,
|
|
1824
|
-
x: (_f = (_e = localRef.current) === null || _e === void 0 ? void 0 : _e.getBoundingClientRect().x) !== null && _f !== void 0 ? _f : 0,
|
|
1825
|
-
y: (_h = (_g = localRef.current) === null || _g === void 0 ? void 0 : _g.getBoundingClientRect().y) !== null && _h !== void 0 ? _h : 0
|
|
1826
|
-
}
|
|
1827
|
-
});
|
|
1828
|
-
}, [onLayout]);
|
|
1829
|
-
return jsxRuntimeExports.jsx(ContainerAs, {
|
|
1830
|
-
id: id,
|
|
1831
|
-
ref: localRef,
|
|
1832
|
-
className: mergedRootStyles,
|
|
1833
|
-
onClick: event => onClick === null || onClick === void 0 ? void 0 : onClick({
|
|
1834
|
-
stopPropagation: () => event.stopPropagation(),
|
|
1835
|
-
preventDefault: () => event.preventDefault(),
|
|
1836
|
-
nativeEvent: {
|
|
1837
|
-
locationX: event.clientX,
|
|
1838
|
-
locationY: event.clientY
|
|
1839
|
-
}
|
|
1840
|
-
}),
|
|
1841
|
-
onMouseEnter: onMouseEnter,
|
|
1842
|
-
onMouseLeave: onMouseLeave,
|
|
1843
|
-
onTransitionEnd: onTransitionEnd,
|
|
1844
|
-
onTouchStart: onTouchStart,
|
|
1845
|
-
onTouchEnd: onTouchEnd,
|
|
1846
|
-
onTouchCancel: onTouchCancel,
|
|
1847
|
-
onTouchMove: onTouchMove,
|
|
1848
|
-
children: children
|
|
1849
|
-
});
|
|
1850
|
-
});
|
|
1851
|
-
Container$1.displayName = 'Container';
|
|
1852
|
-
|
|
1853
|
-
const staticContainerStyles = ctDesignStyleManager.makeStyles(() => {
|
|
1854
|
-
return {
|
|
1855
|
-
root: {
|
|
1856
|
-
display: 'flex',
|
|
1857
|
-
flexDirection: 'column',
|
|
1858
|
-
pointerEvents: 'auto'
|
|
1859
|
-
}
|
|
1860
|
-
};
|
|
1861
|
-
});
|
|
1862
|
-
function getPointerEventsStyles(pointerEvents) {
|
|
1863
|
-
if (pointerEvents === 'box-none') {
|
|
1864
|
-
return {
|
|
1865
|
-
pointerEvents: 'none',
|
|
1866
|
-
'& > *': {
|
|
1867
|
-
pointerEvents: 'auto'
|
|
1868
|
-
}
|
|
1869
|
-
};
|
|
1870
|
-
}
|
|
1871
|
-
if (pointerEvents === 'box-only') {
|
|
1872
|
-
return {
|
|
1873
|
-
pointerEvents: 'auto',
|
|
1874
|
-
'& > *': {
|
|
1875
|
-
pointerEvents: 'none'
|
|
1876
|
-
}
|
|
1877
|
-
};
|
|
1878
|
-
}
|
|
1879
|
-
if (pointerEvents === 'none') {
|
|
1880
|
-
return {
|
|
1881
|
-
pointerEvents: 'none'
|
|
1882
|
-
};
|
|
1883
|
-
}
|
|
1884
|
-
return {
|
|
1885
|
-
pointerEvents: 'auto'
|
|
1886
|
-
};
|
|
1887
|
-
}
|
|
1888
|
-
const Container = React.forwardRef(({
|
|
1889
|
-
id,
|
|
1890
|
-
as: ContainerAs = 'div',
|
|
1891
|
-
children,
|
|
1892
|
-
styleConfig,
|
|
1893
|
-
onClick,
|
|
1894
|
-
onLayout,
|
|
1895
|
-
onMouseEnter,
|
|
1896
|
-
onMouseLeave,
|
|
1897
|
-
onTransitionEnd,
|
|
1898
|
-
onTouchStart,
|
|
1899
|
-
onTouchEnd,
|
|
1900
|
-
onTouchCancel,
|
|
1901
|
-
onTouchMove,
|
|
1902
|
-
pointerEvents,
|
|
1903
|
-
hitSlop: _hitSlop,
|
|
1904
|
-
hapticEnabled: _hapticEnabled,
|
|
1905
|
-
hapticVariant: _hapticVariant,
|
|
1906
|
-
hapticRepeat: _hapticRepeat
|
|
1907
|
-
}, forwardedRef) => {
|
|
1908
|
-
const localRef = React.useRef(null);
|
|
1909
|
-
const handleFocus = React.useCallback(() => {
|
|
1910
|
-
var _a;
|
|
1911
|
-
(_a = localRef.current) === null || _a === void 0 ? void 0 : _a.focus();
|
|
1912
|
-
}, []);
|
|
1913
|
-
const handleGetBoundingRect = React.useCallback(callback => {
|
|
1914
|
-
var _a;
|
|
1915
|
-
const rect = (_a = localRef.current) === null || _a === void 0 ? void 0 : _a.getBoundingClientRect();
|
|
1916
|
-
if (rect) {
|
|
1917
|
-
callback === null || callback === void 0 ? void 0 : callback({
|
|
1918
|
-
x: rect.x,
|
|
1919
|
-
y: rect.y,
|
|
1920
|
-
width: rect.width,
|
|
1921
|
-
height: rect.height
|
|
1922
|
-
});
|
|
1923
|
-
}
|
|
1924
|
-
}, []);
|
|
1925
|
-
const handleAddEventListener = React.useCallback((type, listener, options) => {
|
|
1926
|
-
var _a;
|
|
1927
|
-
(_a = localRef.current) === null || _a === void 0 ? void 0 : _a.addEventListener(type, listener, options);
|
|
1928
|
-
}, []);
|
|
1929
|
-
const handleRemoveEventListener = React.useCallback((type, listener, options) => {
|
|
1930
|
-
var _a;
|
|
1931
|
-
(_a = localRef.current) === null || _a === void 0 ? void 0 : _a.removeEventListener(type, listener, options);
|
|
1932
|
-
}, []);
|
|
1933
|
-
React.useImperativeHandle(forwardedRef, () => {
|
|
1934
|
-
var _a;
|
|
1935
|
-
return {
|
|
1936
|
-
focus: handleFocus,
|
|
1937
|
-
getBoundingRectWithCallback: handleGetBoundingRect,
|
|
1938
|
-
getElementRef: () => localRef,
|
|
1939
|
-
style: ((_a = localRef.current) === null || _a === void 0 ? void 0 : _a.style) || {},
|
|
1940
|
-
classList: {
|
|
1941
|
-
add: className => {
|
|
1942
|
-
var _a;
|
|
1943
|
-
(_a = localRef.current) === null || _a === void 0 ? void 0 : _a.classList.add(className);
|
|
1944
|
-
}
|
|
1945
|
-
},
|
|
1946
|
-
measure: _callback => {
|
|
1947
|
-
var _a;
|
|
1948
|
-
(_a = localRef.current) === null || _a === void 0 ? void 0 : _a.getBoundingClientRect();
|
|
1949
|
-
},
|
|
1950
|
-
addEventListener: handleAddEventListener,
|
|
1951
|
-
removeEventListener: handleRemoveEventListener
|
|
1952
|
-
};
|
|
1953
|
-
}, [handleFocus, handleGetBoundingRect, handleAddEventListener, handleRemoveEventListener]);
|
|
1954
|
-
const {
|
|
1955
|
-
root: rootStyles = []
|
|
1956
|
-
} = styleConfig || {};
|
|
1957
|
-
const pointerEventsStyle = React.useMemo(() => {
|
|
1958
|
-
if (pointerEvents == null) return null;
|
|
1959
|
-
return getPointerEventsStyles(pointerEvents);
|
|
1960
|
-
}, [pointerEvents]);
|
|
1961
|
-
const mergedRootStyles = ctDesignStyleManager.useWebMergeStyles([staticContainerStyles.root, ...rootStyles, ...(pointerEventsStyle ? [pointerEventsStyle] : [])], [rootStyles, pointerEventsStyle]);
|
|
1962
|
-
React.useLayoutEffect(() => {
|
|
1963
|
-
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
1964
|
-
onLayout === null || onLayout === void 0 ? void 0 : onLayout({
|
|
1965
|
-
layout: {
|
|
1966
|
-
height: (_b = (_a = localRef.current) === null || _a === void 0 ? void 0 : _a.clientHeight) !== null && _b !== void 0 ? _b : 0,
|
|
1967
|
-
width: (_d = (_c = localRef.current) === null || _c === void 0 ? void 0 : _c.clientWidth) !== null && _d !== void 0 ? _d : 0,
|
|
1968
|
-
x: (_f = (_e = localRef.current) === null || _e === void 0 ? void 0 : _e.getBoundingClientRect().x) !== null && _f !== void 0 ? _f : 0,
|
|
1969
|
-
y: (_h = (_g = localRef.current) === null || _g === void 0 ? void 0 : _g.getBoundingClientRect().y) !== null && _h !== void 0 ? _h : 0
|
|
1970
|
-
}
|
|
1971
|
-
});
|
|
1972
|
-
}, [onLayout]);
|
|
1973
|
-
return jsxRuntimeExports.jsx(ContainerAs, {
|
|
1974
|
-
id: id,
|
|
1975
|
-
ref: localRef,
|
|
1976
|
-
className: mergedRootStyles,
|
|
1977
|
-
onClick: event => onClick === null || onClick === void 0 ? void 0 : onClick({
|
|
1978
|
-
stopPropagation: () => event.stopPropagation(),
|
|
1979
|
-
preventDefault: () => event.preventDefault(),
|
|
1980
|
-
nativeEvent: {
|
|
1981
|
-
locationX: event.clientX,
|
|
1982
|
-
locationY: event.clientY
|
|
1983
|
-
}
|
|
1984
|
-
}),
|
|
1985
|
-
onMouseEnter: onMouseEnter,
|
|
1986
|
-
onMouseLeave: onMouseLeave,
|
|
1987
|
-
onTransitionEnd: onTransitionEnd,
|
|
1988
|
-
onTouchStart: onTouchStart,
|
|
1989
|
-
onTouchEnd: onTouchEnd,
|
|
1990
|
-
onTouchCancel: onTouchCancel,
|
|
1991
|
-
onTouchMove: onTouchMove,
|
|
1992
|
-
children: children
|
|
1993
|
-
});
|
|
1994
|
-
});
|
|
1995
|
-
Container.displayName = 'Container';
|
|
1996
|
-
|
|
1997
|
-
const solidBorderStyles = ctDesignStyleManager.makeStyles(theme => {
|
|
1998
|
-
return {
|
|
1999
|
-
container: {
|
|
2000
|
-
display: 'flex',
|
|
2001
|
-
justifyContent: 'center',
|
|
2002
|
-
alignItems: 'center',
|
|
2003
|
-
overflow: 'hidden'
|
|
2004
|
-
},
|
|
2005
|
-
vertical: {
|
|
2006
|
-
margin: -theme.spacing[0.5],
|
|
2007
|
-
marginLeft: theme.spacing[0.5],
|
|
2008
|
-
width: 1
|
|
2009
|
-
},
|
|
2010
|
-
horizontal: {
|
|
2011
|
-
margin: -theme.spacing[0.5],
|
|
2012
|
-
marginTop: theme.spacing[0.5],
|
|
2013
|
-
height: 1
|
|
2014
|
-
},
|
|
2015
|
-
flex: {
|
|
2016
|
-
flex: 1
|
|
2017
|
-
},
|
|
2018
|
-
flexRow: {
|
|
2019
|
-
flexDirection: 'row'
|
|
2020
|
-
}
|
|
2021
|
-
};
|
|
2022
|
-
});
|
|
2023
|
-
const Divider = ({
|
|
2024
|
-
dividerColor = '#F3F3F3',
|
|
2025
|
-
dividerType = 'solid',
|
|
2026
|
-
dividerWidth = 1.5,
|
|
2027
|
-
orientation = 'horizontal',
|
|
2028
|
-
dividerLength = '100%',
|
|
2029
|
-
styleConfig
|
|
2030
|
-
}) => {
|
|
2031
|
-
var _a;
|
|
2032
|
-
const dividerDynamicStyles = ctDesignStyleManager.useStyles(theme => {
|
|
2033
|
-
let defaultContainerStyle = {};
|
|
2034
|
-
let defaultMaskStyle = {};
|
|
2035
|
-
if (orientation === 'horizontal') {
|
|
2036
|
-
defaultContainerStyle = {
|
|
2037
|
-
height: dividerWidth + 1,
|
|
2038
|
-
width: '100%',
|
|
2039
|
-
flexDirection: 'row',
|
|
2040
|
-
flex: 1
|
|
2041
|
-
};
|
|
2042
|
-
defaultMaskStyle = {
|
|
2043
|
-
borderWidth: dividerWidth,
|
|
2044
|
-
borderColor: dividerColor || theme.color.border.neutral,
|
|
2045
|
-
borderStyle: dividerType,
|
|
2046
|
-
width: dividerLength
|
|
2047
|
-
};
|
|
2048
|
-
} else {
|
|
2049
|
-
defaultContainerStyle = {
|
|
2050
|
-
width: dividerWidth + 1,
|
|
2051
|
-
height: '100%'
|
|
2052
|
-
};
|
|
2053
|
-
defaultMaskStyle = {
|
|
2054
|
-
borderWidth: dividerWidth,
|
|
2055
|
-
borderColor: dividerColor,
|
|
2056
|
-
borderStyle: dividerType,
|
|
2057
|
-
height: dividerLength
|
|
2058
|
-
};
|
|
2059
|
-
}
|
|
2060
|
-
return {
|
|
2061
|
-
defaultContainerStyle,
|
|
2062
|
-
defaultMaskStyle
|
|
2063
|
-
};
|
|
2064
|
-
}, [dividerWidth, dividerColor, dividerType, dividerLength]);
|
|
2065
|
-
return jsxRuntimeExports.jsx(Container, {
|
|
2066
|
-
styleConfig: {
|
|
2067
|
-
root: [solidBorderStyles.flex, solidBorderStyles.flexRow, ...((_a = styleConfig === null || styleConfig === void 0 ? void 0 : styleConfig.root) !== null && _a !== void 0 ? _a : [])]
|
|
2068
|
-
},
|
|
2069
|
-
children: jsxRuntimeExports.jsx(Container, {
|
|
2070
|
-
styleConfig: {
|
|
2071
|
-
root: [solidBorderStyles.container, dividerDynamicStyles.defaultContainerStyle]
|
|
2072
|
-
},
|
|
2073
|
-
children: jsxRuntimeExports.jsx(Container, {
|
|
2074
|
-
styleConfig: {
|
|
2075
|
-
root: [solidBorderStyles[orientation], dividerDynamicStyles.defaultMaskStyle]
|
|
2076
|
-
}
|
|
2077
|
-
})
|
|
2078
|
-
})
|
|
2079
|
-
});
|
|
2080
|
-
};
|
|
2081
|
-
Divider.displayName = 'Divider';
|
|
2082
|
-
|
|
2083
|
-
var TypographyVariant;
|
|
2084
|
-
(function (TypographyVariant) {
|
|
2085
|
-
TypographyVariant["HD1"] = "HD1";
|
|
2086
|
-
TypographyVariant["HD2"] = "HD2";
|
|
2087
|
-
TypographyVariant["HD3"] = "HD3";
|
|
2088
|
-
TypographyVariant["HM1"] = "HM1";
|
|
2089
|
-
TypographyVariant["HM2"] = "HM2";
|
|
2090
|
-
TypographyVariant["HM3"] = "HM3";
|
|
2091
|
-
TypographyVariant["HM4"] = "HM4";
|
|
2092
|
-
TypographyVariant["B1"] = "B1";
|
|
2093
|
-
TypographyVariant["B2"] = "B2";
|
|
2094
|
-
TypographyVariant["B3"] = "B3";
|
|
2095
|
-
TypographyVariant["B3CAPS"] = "B3CAPS";
|
|
2096
|
-
TypographyVariant["B4"] = "B4";
|
|
2097
|
-
TypographyVariant["B4CAPS"] = "B4CAPS";
|
|
2098
|
-
TypographyVariant["P1"] = "P1";
|
|
2099
|
-
TypographyVariant["P2"] = "P2";
|
|
2100
|
-
TypographyVariant["P3"] = "P3";
|
|
2101
|
-
TypographyVariant["P4"] = "P4";
|
|
2102
|
-
TypographyVariant["L1"] = "L1";
|
|
2103
|
-
TypographyVariant["L2"] = "L2";
|
|
2104
|
-
TypographyVariant["L3"] = "L3";
|
|
2105
|
-
TypographyVariant["OVERLINE"] = "OVERLINE";
|
|
2106
|
-
TypographyVariant["TAG"] = "TAG";
|
|
2107
|
-
TypographyVariant["M4BOLD"] = "M4BOLD";
|
|
2108
|
-
TypographyVariant["WRAPPER"] = "WRAPPER";
|
|
2109
|
-
})(TypographyVariant || (TypographyVariant = {}));
|
|
2110
|
-
var TypographyColor;
|
|
2111
|
-
(function (TypographyColor) {
|
|
2112
|
-
TypographyColor["PRIMARY"] = "primary";
|
|
2113
|
-
TypographyColor["SECONDARY"] = "secondary";
|
|
2114
|
-
TypographyColor["TERTIARY"] = "tertiary";
|
|
2115
|
-
TypographyColor["HEADING"] = "heading";
|
|
2116
|
-
TypographyColor["SUBHEADING"] = "subheading";
|
|
2117
|
-
TypographyColor["SUCCESS"] = "success";
|
|
2118
|
-
TypographyColor["ALERT"] = "alert";
|
|
2119
|
-
TypographyColor["WARNING"] = "warning";
|
|
2120
|
-
TypographyColor["DISABLED"] = "disabled";
|
|
2121
|
-
TypographyColor["LINK"] = "link";
|
|
2122
|
-
TypographyColor["NEUTRAL"] = "neutral";
|
|
2123
|
-
TypographyColor["LINK2"] = "link2";
|
|
2124
|
-
TypographyColor["PRIMARY2"] = "primary2";
|
|
2125
|
-
TypographyColor["SECONDARY2"] = "secondary2";
|
|
2126
|
-
TypographyColor["GRAPETINI"] = "grapetini900";
|
|
2127
|
-
TypographyColor["PINA_COLADA750"] = "pinacolada750";
|
|
2128
|
-
TypographyColor["BRAND"] = "brand";
|
|
2129
|
-
TypographyColor["ALERT500"] = "alert500";
|
|
2130
|
-
TypographyColor["NEUTRAL50"] = "neutral50";
|
|
2131
|
-
TypographyColor["MARGARITA750"] = "margarita750";
|
|
2132
|
-
TypographyColor["GREEN100"] = "green100";
|
|
2133
|
-
TypographyColor["RED100"] = "red100";
|
|
2134
|
-
TypographyColor["ALERT300"] = "alert300";
|
|
2135
|
-
TypographyColor["RED500"] = "red500";
|
|
2136
|
-
TypographyColor["CORALPINK"] = "coralpink";
|
|
2137
|
-
TypographyColor["WARNING500"] = "warning500";
|
|
2138
|
-
TypographyColor["BLUE700"] = "blue700";
|
|
2139
|
-
TypographyColor["NEUTRAL650"] = "neutral650";
|
|
2140
|
-
TypographyColor["GREY700"] = "grey700";
|
|
2141
|
-
TypographyColor["BLACK000"] = "black000";
|
|
2142
|
-
})(TypographyColor || (TypographyColor = {}));
|
|
2143
|
-
const getTypographyVariant = (theme, variant) => {
|
|
2144
|
-
switch (variant) {
|
|
2145
|
-
case TypographyVariant.HD1:
|
|
2146
|
-
{
|
|
2147
|
-
return {
|
|
2148
|
-
fontSize: theme.typography.size[48],
|
|
2149
|
-
fontWeight: theme.typography.weight.semibold,
|
|
2150
|
-
lineHeight: theme.typography.lineHeight[56]
|
|
2151
|
-
};
|
|
2152
|
-
}
|
|
2153
|
-
case TypographyVariant.HD2:
|
|
2154
|
-
{
|
|
2155
|
-
return {
|
|
2156
|
-
fontSize: theme.typography.size[40],
|
|
2157
|
-
fontWeight: theme.typography.weight.semibold,
|
|
2158
|
-
lineHeight: theme.typography.lineHeight[48]
|
|
2159
|
-
};
|
|
1923
|
+
case TypographyVariant.HD2:
|
|
1924
|
+
{
|
|
1925
|
+
return {
|
|
1926
|
+
fontSize: theme.typography.size[40],
|
|
1927
|
+
fontWeight: theme.typography.weight.semibold,
|
|
1928
|
+
lineHeight: theme.typography.lineHeight[48]
|
|
1929
|
+
};
|
|
2160
1930
|
}
|
|
2161
1931
|
case TypographyVariant.HD3:
|
|
2162
1932
|
{
|
|
@@ -2576,7 +2346,7 @@
|
|
|
2576
2346
|
const clickableContainerStyles = isInlineNode ? [{
|
|
2577
2347
|
display: 'inline'
|
|
2578
2348
|
}, ...customContainerStyles] : customContainerStyles;
|
|
2579
|
-
return jsxRuntimeExports.jsx(Container
|
|
2349
|
+
return jsxRuntimeExports.jsx(Container, {
|
|
2580
2350
|
onClick: onClick,
|
|
2581
2351
|
styleConfig: {
|
|
2582
2352
|
root: clickableContainerStyles
|
|
@@ -2594,6 +2364,92 @@
|
|
|
2594
2364
|
});
|
|
2595
2365
|
};
|
|
2596
2366
|
|
|
2367
|
+
const solidBorderStyles = ctDesignStyleManager.makeStyles(theme => {
|
|
2368
|
+
return {
|
|
2369
|
+
container: {
|
|
2370
|
+
display: 'flex',
|
|
2371
|
+
justifyContent: 'center',
|
|
2372
|
+
alignItems: 'center',
|
|
2373
|
+
overflow: 'hidden'
|
|
2374
|
+
},
|
|
2375
|
+
vertical: {
|
|
2376
|
+
margin: -theme.spacing[0.5],
|
|
2377
|
+
marginLeft: theme.spacing[0.5],
|
|
2378
|
+
width: 1
|
|
2379
|
+
},
|
|
2380
|
+
horizontal: {
|
|
2381
|
+
margin: -theme.spacing[0.5],
|
|
2382
|
+
marginTop: theme.spacing[0.5],
|
|
2383
|
+
height: 1
|
|
2384
|
+
},
|
|
2385
|
+
flex: {
|
|
2386
|
+
flex: 1
|
|
2387
|
+
},
|
|
2388
|
+
flexRow: {
|
|
2389
|
+
flexDirection: 'row'
|
|
2390
|
+
}
|
|
2391
|
+
};
|
|
2392
|
+
});
|
|
2393
|
+
const Divider = ({
|
|
2394
|
+
dividerColor = '#F3F3F3',
|
|
2395
|
+
dividerType = 'solid',
|
|
2396
|
+
dividerWidth = 1.5,
|
|
2397
|
+
orientation = 'horizontal',
|
|
2398
|
+
dividerLength = '100%',
|
|
2399
|
+
styleConfig
|
|
2400
|
+
}) => {
|
|
2401
|
+
var _a;
|
|
2402
|
+
const dividerDynamicStyles = ctDesignStyleManager.useStyles(theme => {
|
|
2403
|
+
let defaultContainerStyle = {};
|
|
2404
|
+
let defaultMaskStyle = {};
|
|
2405
|
+
if (orientation === 'horizontal') {
|
|
2406
|
+
defaultContainerStyle = {
|
|
2407
|
+
height: dividerWidth + 1,
|
|
2408
|
+
width: '100%',
|
|
2409
|
+
flexDirection: 'row',
|
|
2410
|
+
flex: 1
|
|
2411
|
+
};
|
|
2412
|
+
defaultMaskStyle = {
|
|
2413
|
+
borderWidth: dividerWidth,
|
|
2414
|
+
borderColor: dividerColor || theme.color.border.neutral,
|
|
2415
|
+
borderStyle: dividerType,
|
|
2416
|
+
width: dividerLength
|
|
2417
|
+
};
|
|
2418
|
+
} else {
|
|
2419
|
+
defaultContainerStyle = {
|
|
2420
|
+
width: dividerWidth + 1,
|
|
2421
|
+
height: '100%'
|
|
2422
|
+
};
|
|
2423
|
+
defaultMaskStyle = {
|
|
2424
|
+
borderWidth: dividerWidth,
|
|
2425
|
+
borderColor: dividerColor,
|
|
2426
|
+
borderStyle: dividerType,
|
|
2427
|
+
height: dividerLength
|
|
2428
|
+
};
|
|
2429
|
+
}
|
|
2430
|
+
return {
|
|
2431
|
+
defaultContainerStyle,
|
|
2432
|
+
defaultMaskStyle
|
|
2433
|
+
};
|
|
2434
|
+
}, [dividerWidth, dividerColor, dividerType, dividerLength]);
|
|
2435
|
+
return jsxRuntimeExports.jsx(Container, {
|
|
2436
|
+
styleConfig: {
|
|
2437
|
+
root: [solidBorderStyles.flex, solidBorderStyles.flexRow, ...((_a = styleConfig === null || styleConfig === void 0 ? void 0 : styleConfig.root) !== null && _a !== void 0 ? _a : [])]
|
|
2438
|
+
},
|
|
2439
|
+
children: jsxRuntimeExports.jsx(Container, {
|
|
2440
|
+
styleConfig: {
|
|
2441
|
+
root: [solidBorderStyles.container, dividerDynamicStyles.defaultContainerStyle]
|
|
2442
|
+
},
|
|
2443
|
+
children: jsxRuntimeExports.jsx(Container, {
|
|
2444
|
+
styleConfig: {
|
|
2445
|
+
root: [solidBorderStyles[orientation], dividerDynamicStyles.defaultMaskStyle]
|
|
2446
|
+
}
|
|
2447
|
+
})
|
|
2448
|
+
})
|
|
2449
|
+
});
|
|
2450
|
+
};
|
|
2451
|
+
Divider.displayName = 'Divider';
|
|
2452
|
+
|
|
2597
2453
|
var useFlightItineraryCardStyles = function (_a) {
|
|
2598
2454
|
var align = _a.align, selected = _a.selected;
|
|
2599
2455
|
return ctDesignStyleManager.useStyles(function (theme) { return ({
|
|
@@ -2668,7 +2524,7 @@
|
|
|
2668
2524
|
var data = _a.data, _b = _a.align, align = _b === void 0 ? talosTripSegment.TripSegmentAlignment.LEFT : _b;
|
|
2669
2525
|
var _c = data || {}, _d = _c.time, time = _d === void 0 ? "" : _d, _e = _c.name, name = _e === void 0 ? "" : _e, _f = _c.city, city = _f === void 0 ? "" : _f;
|
|
2670
2526
|
var staticStyles = useFlightItineraryCardStyles({ align: align });
|
|
2671
|
-
return (jsxRuntimeExports.jsxs(Container
|
|
2527
|
+
return (jsxRuntimeExports.jsxs(Container, { styleConfig: { root: [staticStyles.itinerarySegmentContainer] }, children: [jsxRuntimeExports.jsx(Typography, { variant: TypographyVariant.HM3, color: TypographyColor.PRIMARY, children: time }), jsxRuntimeExports.jsx(Typography, { variant: TypographyVariant.B4, color: TypographyColor.PRIMARY, children: city }), jsxRuntimeExports.jsx(Typography, { lineClamp: 3, variant: TypographyVariant.B4, color: TypographyColor.SUBHEADING, children: name })] }));
|
|
2672
2528
|
};
|
|
2673
2529
|
|
|
2674
2530
|
var FlightSelectionContext = React.createContext({
|
|
@@ -2696,11 +2552,11 @@
|
|
|
2696
2552
|
var handleClick = function () {
|
|
2697
2553
|
dispatchAll(onClick);
|
|
2698
2554
|
};
|
|
2699
|
-
return (jsxRuntimeExports.jsxs(Container
|
|
2555
|
+
return (jsxRuntimeExports.jsxs(Container, { styleConfig: { root: [staticStyles.root] }, onClick: handleClick, children: [jsxRuntimeExports.jsxs(Container, { styleConfig: { root: [staticStyles.header] }, children: [icon ? (jsxRuntimeExports.jsx(talosImage.Image, { src: iconUrl, alt: airline, width: 20, height: 20, styleConfig: { root: [staticStyles.airlineLogo] }, fallback: jsxRuntimeExports.jsx(Container, { styleConfig: { root: [staticStyles.airlineLogoFallback] } }) })) : (jsxRuntimeExports.jsx(Container, { styleConfig: { root: [staticStyles.airlineLogoFallback] } })), jsxRuntimeExports.jsxs(Container, { styleConfig: { root: [staticStyles.headerText] }, children: [jsxRuntimeExports.jsx(Typography, { variant: TypographyVariant.B3, color: TypographyColor.PRIMARY, children: airline }), jsxRuntimeExports.jsx(Container, { styleConfig: { root: [staticStyles.flightsWrapper] }, children: jsxRuntimeExports.jsxs(Typography, { variant: TypographyVariant.B3, color: TypographyColor.PRIMARY, children: ["(", segments.map(function (segment, index) {
|
|
2700
2556
|
var _a;
|
|
2701
2557
|
var showSeparator = index > 0;
|
|
2702
2558
|
return (jsxRuntimeExports.jsx(React.Fragment, { children: "".concat(showSeparator ? "→ " : "", " ").concat(segment.flightNumber, " ") }, (_a = segment === null || segment === void 0 ? void 0 : segment.flightNumber) !== null && _a !== void 0 ? _a : index));
|
|
2703
|
-
}), ")"] }) })] })] }), jsxRuntimeExports.jsxs(Container
|
|
2559
|
+
}), ")"] }) })] })] }), jsxRuntimeExports.jsxs(Container, { styleConfig: { root: [staticStyles.content] }, children: [jsxRuntimeExports.jsxs(Container, { styleConfig: { root: [staticStyles.itinerarySegments] }, children: [jsxRuntimeExports.jsx(FlightItineraryCardSegment, { data: origin }), jsxRuntimeExports.jsxs(Container, { styleConfig: { root: [staticStyles.connectionSummary] }, children: [jsxRuntimeExports.jsx(Typography, { variant: TypographyVariant.B4, color: TypographyColor.PRIMARY, children: duration }), jsxRuntimeExports.jsx(Divider, { dividerType: "dashed", dividerColor: theme.color.border.disabledDark }), jsxRuntimeExports.jsxs(Typography, { variant: TypographyVariant.B4, color: TypographyColor.SUBHEADING, lineClamp: 3, children: [connectionTitle, jsxRuntimeExports.jsx(Typography, { variant: TypographyVariant.B4, color: TypographyColor.SUBHEADING, children: connectionSubtitle })] })] }), jsxRuntimeExports.jsx(FlightItineraryCardSegment, { data: destination, align: talosTripSegment.TripSegmentAlignment.RIGHT })] }), jsxRuntimeExports.jsx(Container, { children: jsxRuntimeExports.jsx(Typography, { variant: TypographyVariant.HM3, color: TypographyColor.PRIMARY, children: fare }) })] })] }));
|
|
2704
2560
|
};
|
|
2705
2561
|
|
|
2706
2562
|
exports.FlightItineraryCard = FlightItineraryCard;
|