@asdp/ferryui 0.1.22-dev.10593 → 0.1.22-dev.10665
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/dist/index.d.mts +32 -3
- package/dist/index.d.ts +32 -3
- package/dist/index.js +179 -31
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +180 -32
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import React$1, { ReactNode } from 'react';
|
|
2
2
|
import { CarouselAnnouncerFunction, DialogProps } from '@fluentui/react-components';
|
|
3
|
-
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
4
3
|
import * as react_hook_form from 'react-hook-form';
|
|
5
4
|
import { FieldValues, Path, Control, UseFormWatch, UseFormSetValue, UseFormGetValues } from 'react-hook-form';
|
|
6
5
|
|
|
@@ -548,13 +547,13 @@ declare const CardTicket: React$1.FC<CardTicketProps>;
|
|
|
548
547
|
* Horizontal ticket card background with decorative perforated edges
|
|
549
548
|
* Use this for desktop/landscape layouts
|
|
550
549
|
*/
|
|
551
|
-
declare const BackgroundTicketCard: (props: React$1.SVGProps<SVGSVGElement>) =>
|
|
550
|
+
declare const BackgroundTicketCard: (props: React$1.SVGProps<SVGSVGElement>) => React$1.JSX.Element;
|
|
552
551
|
|
|
553
552
|
/**
|
|
554
553
|
* Vertical ticket card background with decorative perforated edges
|
|
555
554
|
* Use this for mobile/portrait layouts
|
|
556
555
|
*/
|
|
557
|
-
declare const BackgroundTicketCardVertical: (props: React$1.SVGProps<SVGSVGElement>) =>
|
|
556
|
+
declare const BackgroundTicketCardVertical: (props: React$1.SVGProps<SVGSVGElement>) => React$1.JSX.Element;
|
|
558
557
|
|
|
559
558
|
type ServiceId = 'ferry' | 'ifcs' | 'skpt' | 'hotel' | 'other';
|
|
560
559
|
interface CardServiceMenuLabels {
|
|
@@ -2504,6 +2503,7 @@ type StepStatus = 'completed' | 'active' | 'inactive';
|
|
|
2504
2503
|
|
|
2505
2504
|
declare const Stepper: React$1.FC<StepperProps>;
|
|
2506
2505
|
|
|
2506
|
+
type NotificationType = 'whatsapp' | 'sms';
|
|
2507
2507
|
interface Orderer {
|
|
2508
2508
|
name?: string;
|
|
2509
2509
|
phoneNumber?: string;
|
|
@@ -2514,6 +2514,13 @@ interface CardOrdererInfoLabels {
|
|
|
2514
2514
|
ordererName: string;
|
|
2515
2515
|
phoneNumber: string;
|
|
2516
2516
|
email: string;
|
|
2517
|
+
addCcEmail: string;
|
|
2518
|
+
ccEmail: string;
|
|
2519
|
+
ccEmailPlaceholder: string;
|
|
2520
|
+
ccEmailHint: string;
|
|
2521
|
+
notificationLabel: string;
|
|
2522
|
+
whatsapp: string;
|
|
2523
|
+
sms: string;
|
|
2517
2524
|
}
|
|
2518
2525
|
interface CardOrdererInfoProps {
|
|
2519
2526
|
/**
|
|
@@ -2534,6 +2541,28 @@ interface CardOrdererInfoProps {
|
|
|
2534
2541
|
* Additional CSS class name
|
|
2535
2542
|
*/
|
|
2536
2543
|
className?: string;
|
|
2544
|
+
/**
|
|
2545
|
+
* Current CC email value
|
|
2546
|
+
*/
|
|
2547
|
+
ccEmail?: string;
|
|
2548
|
+
/**
|
|
2549
|
+
* Callback when CC email input value changes
|
|
2550
|
+
*/
|
|
2551
|
+
onCcEmailChange?: (value: string) => void;
|
|
2552
|
+
/**
|
|
2553
|
+
* Callback when CC email is removed (trash button clicked)
|
|
2554
|
+
* When provided, the "Tambahkan Cc Email" link is shown
|
|
2555
|
+
*/
|
|
2556
|
+
onCcEmailRemove?: () => void;
|
|
2557
|
+
/**
|
|
2558
|
+
* Selected notification type
|
|
2559
|
+
* @default 'whatsapp'
|
|
2560
|
+
*/
|
|
2561
|
+
notificationType?: NotificationType;
|
|
2562
|
+
/**
|
|
2563
|
+
* Callback when notification type changes
|
|
2564
|
+
*/
|
|
2565
|
+
onNotificationTypeChange?: (type: NotificationType) => void;
|
|
2537
2566
|
}
|
|
2538
2567
|
|
|
2539
2568
|
declare const CardOrdererInfo: React$1.FC<CardOrdererInfoProps>;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import React$1, { ReactNode } from 'react';
|
|
2
2
|
import { CarouselAnnouncerFunction, DialogProps } from '@fluentui/react-components';
|
|
3
|
-
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
4
3
|
import * as react_hook_form from 'react-hook-form';
|
|
5
4
|
import { FieldValues, Path, Control, UseFormWatch, UseFormSetValue, UseFormGetValues } from 'react-hook-form';
|
|
6
5
|
|
|
@@ -548,13 +547,13 @@ declare const CardTicket: React$1.FC<CardTicketProps>;
|
|
|
548
547
|
* Horizontal ticket card background with decorative perforated edges
|
|
549
548
|
* Use this for desktop/landscape layouts
|
|
550
549
|
*/
|
|
551
|
-
declare const BackgroundTicketCard: (props: React$1.SVGProps<SVGSVGElement>) =>
|
|
550
|
+
declare const BackgroundTicketCard: (props: React$1.SVGProps<SVGSVGElement>) => React$1.JSX.Element;
|
|
552
551
|
|
|
553
552
|
/**
|
|
554
553
|
* Vertical ticket card background with decorative perforated edges
|
|
555
554
|
* Use this for mobile/portrait layouts
|
|
556
555
|
*/
|
|
557
|
-
declare const BackgroundTicketCardVertical: (props: React$1.SVGProps<SVGSVGElement>) =>
|
|
556
|
+
declare const BackgroundTicketCardVertical: (props: React$1.SVGProps<SVGSVGElement>) => React$1.JSX.Element;
|
|
558
557
|
|
|
559
558
|
type ServiceId = 'ferry' | 'ifcs' | 'skpt' | 'hotel' | 'other';
|
|
560
559
|
interface CardServiceMenuLabels {
|
|
@@ -2504,6 +2503,7 @@ type StepStatus = 'completed' | 'active' | 'inactive';
|
|
|
2504
2503
|
|
|
2505
2504
|
declare const Stepper: React$1.FC<StepperProps>;
|
|
2506
2505
|
|
|
2506
|
+
type NotificationType = 'whatsapp' | 'sms';
|
|
2507
2507
|
interface Orderer {
|
|
2508
2508
|
name?: string;
|
|
2509
2509
|
phoneNumber?: string;
|
|
@@ -2514,6 +2514,13 @@ interface CardOrdererInfoLabels {
|
|
|
2514
2514
|
ordererName: string;
|
|
2515
2515
|
phoneNumber: string;
|
|
2516
2516
|
email: string;
|
|
2517
|
+
addCcEmail: string;
|
|
2518
|
+
ccEmail: string;
|
|
2519
|
+
ccEmailPlaceholder: string;
|
|
2520
|
+
ccEmailHint: string;
|
|
2521
|
+
notificationLabel: string;
|
|
2522
|
+
whatsapp: string;
|
|
2523
|
+
sms: string;
|
|
2517
2524
|
}
|
|
2518
2525
|
interface CardOrdererInfoProps {
|
|
2519
2526
|
/**
|
|
@@ -2534,6 +2541,28 @@ interface CardOrdererInfoProps {
|
|
|
2534
2541
|
* Additional CSS class name
|
|
2535
2542
|
*/
|
|
2536
2543
|
className?: string;
|
|
2544
|
+
/**
|
|
2545
|
+
* Current CC email value
|
|
2546
|
+
*/
|
|
2547
|
+
ccEmail?: string;
|
|
2548
|
+
/**
|
|
2549
|
+
* Callback when CC email input value changes
|
|
2550
|
+
*/
|
|
2551
|
+
onCcEmailChange?: (value: string) => void;
|
|
2552
|
+
/**
|
|
2553
|
+
* Callback when CC email is removed (trash button clicked)
|
|
2554
|
+
* When provided, the "Tambahkan Cc Email" link is shown
|
|
2555
|
+
*/
|
|
2556
|
+
onCcEmailRemove?: () => void;
|
|
2557
|
+
/**
|
|
2558
|
+
* Selected notification type
|
|
2559
|
+
* @default 'whatsapp'
|
|
2560
|
+
*/
|
|
2561
|
+
notificationType?: NotificationType;
|
|
2562
|
+
/**
|
|
2563
|
+
* Callback when notification type changes
|
|
2564
|
+
*/
|
|
2565
|
+
onNotificationTypeChange?: (type: NotificationType) => void;
|
|
2537
2566
|
}
|
|
2538
2567
|
|
|
2539
2568
|
declare const CardOrdererInfo: React$1.FC<CardOrdererInfoProps>;
|
package/dist/index.js
CHANGED
|
@@ -10786,13 +10786,27 @@ var DEFAULT_LABELS21 = {
|
|
|
10786
10786
|
title: "Informasi Pemesan",
|
|
10787
10787
|
ordererName: "Nama Pemesan",
|
|
10788
10788
|
phoneNumber: "Nomor Handphone",
|
|
10789
|
-
email: "Email"
|
|
10789
|
+
email: "Email",
|
|
10790
|
+
addCcEmail: "Tambahkan Cc Email",
|
|
10791
|
+
ccEmail: "CC Email",
|
|
10792
|
+
ccEmailPlaceholder: "Masukkan email",
|
|
10793
|
+
ccEmailHint: "E-Tiket akan di kirim ke email ini",
|
|
10794
|
+
notificationLabel: "Pilih pengiriman notifkasi",
|
|
10795
|
+
whatsapp: "WhatsApp",
|
|
10796
|
+
sms: "SMS"
|
|
10790
10797
|
},
|
|
10791
10798
|
en: {
|
|
10792
10799
|
title: "Orderer Information",
|
|
10793
10800
|
ordererName: "Orderer Name",
|
|
10794
10801
|
phoneNumber: "Phone Number",
|
|
10795
|
-
email: "Email"
|
|
10802
|
+
email: "Email",
|
|
10803
|
+
addCcEmail: "Add Cc Email",
|
|
10804
|
+
ccEmail: "CC Email",
|
|
10805
|
+
ccEmailPlaceholder: "Enter email",
|
|
10806
|
+
ccEmailHint: "E-Ticket will be sent to this email",
|
|
10807
|
+
notificationLabel: "Select notification delivery",
|
|
10808
|
+
whatsapp: "WhatsApp",
|
|
10809
|
+
sms: "SMS"
|
|
10796
10810
|
}
|
|
10797
10811
|
};
|
|
10798
10812
|
var useStyles22 = reactComponents.makeStyles({
|
|
@@ -10802,46 +10816,169 @@ var useStyles22 = reactComponents.makeStyles({
|
|
|
10802
10816
|
boxShadow: reactComponents.tokens.shadow4,
|
|
10803
10817
|
zIndex: 3
|
|
10804
10818
|
},
|
|
10805
|
-
|
|
10819
|
+
header: {
|
|
10806
10820
|
display: "flex",
|
|
10807
|
-
|
|
10808
|
-
|
|
10821
|
+
alignItems: "center",
|
|
10822
|
+
gap: "1rem",
|
|
10823
|
+
marginBottom: "1.25rem"
|
|
10824
|
+
},
|
|
10825
|
+
title: {
|
|
10826
|
+
flexShrink: 0
|
|
10827
|
+
},
|
|
10828
|
+
divider: {
|
|
10829
|
+
flexGrow: 1
|
|
10809
10830
|
},
|
|
10810
10831
|
fieldGroup: {
|
|
10811
10832
|
display: "flex",
|
|
10812
10833
|
flexDirection: "column",
|
|
10813
|
-
gap: "0.25rem"
|
|
10834
|
+
gap: "0.25rem",
|
|
10835
|
+
flex: 1
|
|
10814
10836
|
},
|
|
10815
10837
|
label: {
|
|
10816
10838
|
color: reactComponents.tokens.colorNeutralForeground2
|
|
10817
10839
|
},
|
|
10818
10840
|
value: {
|
|
10819
10841
|
color: tokensV2_default.lightModeColors.Neutral_Foreground_Disabled_Rest
|
|
10842
|
+
},
|
|
10843
|
+
addCcLink: {
|
|
10844
|
+
marginTop: "0.375rem"
|
|
10845
|
+
},
|
|
10846
|
+
bottomRow: {
|
|
10847
|
+
display: "flex",
|
|
10848
|
+
flexDirection: "row",
|
|
10849
|
+
gap: "2rem",
|
|
10850
|
+
marginTop: "1.25rem",
|
|
10851
|
+
alignItems: "flex-start"
|
|
10852
|
+
},
|
|
10853
|
+
// Notification section aligns under the first column (Nama Pemesan)
|
|
10854
|
+
notificationSection: {
|
|
10855
|
+
flex: 1,
|
|
10856
|
+
display: "flex",
|
|
10857
|
+
flexDirection: "column"
|
|
10858
|
+
},
|
|
10859
|
+
notificationLabel: {
|
|
10860
|
+
color: reactComponents.tokens.colorNeutralForeground2,
|
|
10861
|
+
display: "block",
|
|
10862
|
+
marginBottom: "0.5rem"
|
|
10863
|
+
},
|
|
10864
|
+
// CC section spans the remaining two columns (Phone + Email)
|
|
10865
|
+
ccSection: {
|
|
10866
|
+
flex: 1,
|
|
10867
|
+
display: "flex",
|
|
10868
|
+
flexDirection: "column",
|
|
10869
|
+
gap: "0.375rem"
|
|
10870
|
+
},
|
|
10871
|
+
ccLabel: {
|
|
10872
|
+
color: reactComponents.tokens.colorNeutralForeground2
|
|
10873
|
+
},
|
|
10874
|
+
ccInputRow: {
|
|
10875
|
+
display: "flex",
|
|
10876
|
+
alignItems: "center"
|
|
10877
|
+
},
|
|
10878
|
+
ccInput: {
|
|
10879
|
+
flex: 1
|
|
10880
|
+
},
|
|
10881
|
+
deleteButton: {
|
|
10882
|
+
color: reactComponents.tokens.colorStatusDangerForeground1,
|
|
10883
|
+
minWidth: "unset",
|
|
10884
|
+
padding: "0 0.5rem"
|
|
10885
|
+
},
|
|
10886
|
+
ccHint: {
|
|
10887
|
+
color: tokensV2_default.lightModeColors.Neutral_Foreground_Disabled_Rest
|
|
10820
10888
|
}
|
|
10821
10889
|
});
|
|
10822
10890
|
var CardOrdererInfo = ({
|
|
10823
10891
|
language = "id",
|
|
10824
10892
|
orderer,
|
|
10825
10893
|
labels,
|
|
10826
|
-
className
|
|
10894
|
+
className,
|
|
10895
|
+
ccEmail,
|
|
10896
|
+
onCcEmailChange,
|
|
10897
|
+
onCcEmailRemove,
|
|
10898
|
+
notificationType: notificationTypeProp = "whatsapp",
|
|
10899
|
+
onNotificationTypeChange
|
|
10827
10900
|
}) => {
|
|
10828
10901
|
const styles = useStyles22();
|
|
10829
10902
|
const mergedLabels = { ...DEFAULT_LABELS21[language], ...labels };
|
|
10903
|
+
const [showCcForm, setShowCcForm] = React.useState(false);
|
|
10904
|
+
const [notificationType, setNotificationType] = React.useState(notificationTypeProp);
|
|
10905
|
+
const handleNotificationChange = (_e, data) => {
|
|
10906
|
+
const value = data.value;
|
|
10907
|
+
setNotificationType(value);
|
|
10908
|
+
onNotificationTypeChange?.(value);
|
|
10909
|
+
};
|
|
10910
|
+
const handleAddCcClick = () => {
|
|
10911
|
+
setShowCcForm(true);
|
|
10912
|
+
};
|
|
10913
|
+
const handleRemoveCc = () => {
|
|
10914
|
+
setShowCcForm(false);
|
|
10915
|
+
onCcEmailChange?.("");
|
|
10916
|
+
onCcEmailRemove?.();
|
|
10917
|
+
};
|
|
10830
10918
|
return /* @__PURE__ */ jsxRuntime.jsxs(reactComponents.Card, { className: className || styles.card, children: [
|
|
10831
|
-
/* @__PURE__ */ jsxRuntime.
|
|
10832
|
-
|
|
10833
|
-
/* @__PURE__ */ jsxRuntime.
|
|
10834
|
-
|
|
10919
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: styles.header, children: [
|
|
10920
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.Title3, { className: styles.title, children: mergedLabels.title }),
|
|
10921
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.Divider, { className: styles.divider })
|
|
10922
|
+
] }),
|
|
10923
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactGridSystem.Row, { children: [
|
|
10924
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactGridSystem.Col, { md: 4, children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: styles.fieldGroup, children: [
|
|
10925
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.Caption1, { className: styles.label, children: mergedLabels.ordererName }),
|
|
10835
10926
|
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.Body1, { className: styles.value, children: orderer?.name || "-" })
|
|
10836
|
-
] }),
|
|
10837
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: styles.fieldGroup, children: [
|
|
10838
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.
|
|
10927
|
+
] }) }),
|
|
10928
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactGridSystem.Col, { md: 4, children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: styles.fieldGroup, children: [
|
|
10929
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.Caption1, { className: styles.label, children: mergedLabels.phoneNumber }),
|
|
10839
10930
|
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.Body1, { className: styles.value, children: orderer?.phoneNumber || "-" })
|
|
10840
|
-
] }),
|
|
10841
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: styles.fieldGroup, children: [
|
|
10842
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.
|
|
10843
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.Body1, { className: styles.value, children: orderer?.email || "-" })
|
|
10844
|
-
|
|
10931
|
+
] }) }),
|
|
10932
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactGridSystem.Col, { md: 4, children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: styles.fieldGroup, children: [
|
|
10933
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.Caption1, { className: styles.label, children: mergedLabels.email }),
|
|
10934
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.Body1, { className: styles.value, children: orderer?.email || "-" }),
|
|
10935
|
+
!showCcForm && /* @__PURE__ */ jsxRuntime.jsx(reactComponents.Link, { className: styles.addCcLink, onClick: handleAddCcClick, children: mergedLabels.addCcEmail })
|
|
10936
|
+
] }) }),
|
|
10937
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactGridSystem.Col, { md: 4, children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: styles.notificationSection, children: [
|
|
10938
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.Body2, { className: styles.notificationLabel, children: mergedLabels.notificationLabel }),
|
|
10939
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
10940
|
+
reactComponents.RadioGroup,
|
|
10941
|
+
{
|
|
10942
|
+
layout: "horizontal",
|
|
10943
|
+
value: notificationType,
|
|
10944
|
+
onChange: handleNotificationChange,
|
|
10945
|
+
children: [
|
|
10946
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.Radio, { value: "whatsapp", label: mergedLabels.whatsapp }),
|
|
10947
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.Radio, { value: "sms", label: mergedLabels.sms })
|
|
10948
|
+
]
|
|
10949
|
+
}
|
|
10950
|
+
)
|
|
10951
|
+
] }) }),
|
|
10952
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactGridSystem.Col, { md: 4, children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: styles.ccSection, children: showCcForm && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
10953
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.Caption1, { className: styles.ccLabel, children: mergedLabels.ccEmail }),
|
|
10954
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: styles.ccInputRow, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
10955
|
+
reactComponents.Input,
|
|
10956
|
+
{
|
|
10957
|
+
className: styles.ccInput,
|
|
10958
|
+
type: "email",
|
|
10959
|
+
placeholder: mergedLabels.ccEmailPlaceholder,
|
|
10960
|
+
value: ccEmail ?? "",
|
|
10961
|
+
onChange: (_e, data) => onCcEmailChange?.(data.value),
|
|
10962
|
+
contentAfter: /* @__PURE__ */ jsxRuntime.jsx(
|
|
10963
|
+
reactComponents.Button,
|
|
10964
|
+
{
|
|
10965
|
+
appearance: "transparent",
|
|
10966
|
+
className: styles.deleteButton,
|
|
10967
|
+
onClick: handleRemoveCc,
|
|
10968
|
+
icon: /* @__PURE__ */ jsxRuntime.jsx(
|
|
10969
|
+
react.Icon,
|
|
10970
|
+
{
|
|
10971
|
+
icon: "fluent:delete-24-regular",
|
|
10972
|
+
color: reactComponents.tokens.colorStatusDangerForeground1,
|
|
10973
|
+
width: 18
|
|
10974
|
+
}
|
|
10975
|
+
)
|
|
10976
|
+
}
|
|
10977
|
+
)
|
|
10978
|
+
}
|
|
10979
|
+
) }),
|
|
10980
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.Caption2, { className: styles.ccHint, children: mergedLabels.ccEmailHint })
|
|
10981
|
+
] }) }) })
|
|
10845
10982
|
] })
|
|
10846
10983
|
] });
|
|
10847
10984
|
};
|
|
@@ -14518,22 +14655,22 @@ var CardBookingAddOn = ({
|
|
|
14518
14655
|
const styles = useStyles29();
|
|
14519
14656
|
const mergedLabels = { ...DEFAULT_LABELS28[language], ...labels };
|
|
14520
14657
|
const addOnRows = [
|
|
14521
|
-
{
|
|
14658
|
+
addOnData?.lounge && {
|
|
14522
14659
|
key: "lounge",
|
|
14523
|
-
label: addOnData
|
|
14524
|
-
price: addOnData
|
|
14660
|
+
label: addOnData.lounge.label || mergedLabels.loungeLabel,
|
|
14661
|
+
price: addOnData.lounge.price
|
|
14525
14662
|
},
|
|
14526
|
-
{
|
|
14663
|
+
addOnData?.assurance && {
|
|
14527
14664
|
key: "assurance",
|
|
14528
|
-
label: addOnData
|
|
14529
|
-
price: addOnData
|
|
14665
|
+
label: addOnData.assurance.label || mergedLabels.assuranceLabel,
|
|
14666
|
+
price: addOnData.assurance.price
|
|
14530
14667
|
},
|
|
14531
|
-
{
|
|
14668
|
+
addOnData?.meal && {
|
|
14532
14669
|
key: "meal",
|
|
14533
|
-
label: addOnData
|
|
14534
|
-
price: addOnData
|
|
14670
|
+
label: addOnData.meal.label || mergedLabels.mealLabel,
|
|
14671
|
+
price: addOnData.meal.price
|
|
14535
14672
|
}
|
|
14536
|
-
];
|
|
14673
|
+
].filter(Boolean);
|
|
14537
14674
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: `${styles.container} ${className || ""}`, children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: styles.bookingDetail, children: [
|
|
14538
14675
|
/* @__PURE__ */ jsxRuntime.jsxs(reactComponents.Card, { className: styles.bookingDetailTop, children: [
|
|
14539
14676
|
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.Subtitle1, { children: mergedLabels.bookingDetails }),
|
|
@@ -15552,6 +15689,16 @@ var useStyles34 = reactComponents.makeStyles({
|
|
|
15552
15689
|
flexDirection: "column",
|
|
15553
15690
|
rowGap: reactComponents.tokens.spacingVerticalL
|
|
15554
15691
|
},
|
|
15692
|
+
passengerList: {
|
|
15693
|
+
display: "flex",
|
|
15694
|
+
flexDirection: "column",
|
|
15695
|
+
rowGap: reactComponents.tokens.spacingVerticalL
|
|
15696
|
+
},
|
|
15697
|
+
passengerListScrollable: {
|
|
15698
|
+
maxHeight: "560px",
|
|
15699
|
+
overflowY: "auto",
|
|
15700
|
+
paddingRight: reactComponents.tokens.spacingHorizontalXS
|
|
15701
|
+
},
|
|
15555
15702
|
passengerCard: {
|
|
15556
15703
|
boxShadow: "none",
|
|
15557
15704
|
border: `${reactComponents.tokens.strokeWidthThin} solid ${reactComponents.tokens.colorNeutralStroke1}`,
|
|
@@ -15610,12 +15757,13 @@ var CardReviewPassenger = ({
|
|
|
15610
15757
|
const styles = useStyles34();
|
|
15611
15758
|
const mergedLabels = { ...DEFAULT_LABELS33[language], ...labels };
|
|
15612
15759
|
const displayTitle = title || mergedLabels.title;
|
|
15760
|
+
const isScrollable = !isLoading && passengers.length > 5;
|
|
15613
15761
|
return /* @__PURE__ */ jsxRuntime.jsx(reactComponents.Card, { className: `${styles.card} ${className || ""}`, children: /* @__PURE__ */ jsxRuntime.jsxs(reactGridSystem.Row, { direction: "column", nogutter: true, className: styles.list, children: [
|
|
15614
15762
|
/* @__PURE__ */ jsxRuntime.jsx(reactGridSystem.Col, { xs: 12, children: /* @__PURE__ */ jsxRuntime.jsxs(reactGridSystem.Row, { nogutter: true, className: styles.titleRow, children: [
|
|
15615
15763
|
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.Subtitle1, { children: displayTitle }),
|
|
15616
15764
|
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.Divider, { className: styles.titleDivider })
|
|
15617
15765
|
] }) }),
|
|
15618
|
-
isLoading ? Array.from({ length: 2 }).map((_, index) => /* @__PURE__ */ jsxRuntime.jsx(reactGridSystem.Col, { xs: 12, children: /* @__PURE__ */ jsxRuntime.jsx(reactComponents.Card, { className: styles.passengerCard, children: /* @__PURE__ */ jsxRuntime.jsxs(reactGridSystem.Row, { nogutter: true, className: styles.passengerRow, children: [
|
|
15766
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: `${styles.passengerList} ${isScrollable ? styles.passengerListScrollable : ""}`, children: isLoading ? Array.from({ length: 2 }).map((_, index) => /* @__PURE__ */ jsxRuntime.jsx(reactGridSystem.Col, { xs: 12, children: /* @__PURE__ */ jsxRuntime.jsx(reactComponents.Card, { className: styles.passengerCard, children: /* @__PURE__ */ jsxRuntime.jsxs(reactGridSystem.Row, { nogutter: true, className: styles.passengerRow, children: [
|
|
15619
15767
|
/* @__PURE__ */ jsxRuntime.jsx(reactGridSystem.Col, { children: /* @__PURE__ */ jsxRuntime.jsxs(reactComponents.Skeleton, { children: [
|
|
15620
15768
|
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.SkeletonItem, { style: { width: "180px", height: "18px", marginBottom: "8px" } }),
|
|
15621
15769
|
/* @__PURE__ */ jsxRuntime.jsx(reactComponents.SkeletonItem, { style: { width: "220px", height: "16px" } })
|
|
@@ -15653,7 +15801,7 @@ var CardReviewPassenger = ({
|
|
|
15653
15801
|
}
|
|
15654
15802
|
) })
|
|
15655
15803
|
] }) }) }, passenger.id || index);
|
|
15656
|
-
})
|
|
15804
|
+
}) })
|
|
15657
15805
|
] }) });
|
|
15658
15806
|
};
|
|
15659
15807
|
|