@planetaexo/design-system 0.58.3 → 0.59.1
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.cjs +274 -20
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +216 -134
- package/dist/index.d.ts +216 -134
- package/dist/index.js +274 -20
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1305,7 +1305,7 @@ function AdventureCard({
|
|
|
1305
1305
|
labels,
|
|
1306
1306
|
interactionsDisabled
|
|
1307
1307
|
}) {
|
|
1308
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r;
|
|
1308
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s;
|
|
1309
1309
|
const isControlled = (_b = (_a = adventure.optionals) == null ? void 0 : _a.some((o) => o.onCheckedChange !== void 0)) != null ? _b : false;
|
|
1310
1310
|
const [checkedInternal, setCheckedInternal] = React31.useState(
|
|
1311
1311
|
new Set((_d = (_c = adventure.optionals) == null ? void 0 : _c.filter((o) => o.defaultChecked).map((o) => o.id)) != null ? _d : [])
|
|
@@ -1507,22 +1507,48 @@ function AdventureCard({
|
|
|
1507
1507
|
), children: adventure.detailsSlot })
|
|
1508
1508
|
] })
|
|
1509
1509
|
] }),
|
|
1510
|
+
adventure.rooms && adventure.rooms.length > 0 && /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-2.5 mt-1", children: [
|
|
1511
|
+
/* @__PURE__ */ jsx("h4", { className: "text-base font-bold text-foreground font-heading", children: (_p = adventure.accommodationsLabel) != null ? _p : "Accommodations" }),
|
|
1512
|
+
/* @__PURE__ */ jsx("ul", { className: "flex flex-col gap-3", children: adventure.rooms.map((room, i) => {
|
|
1513
|
+
var _a2, _b2;
|
|
1514
|
+
const bedLabel = (_b2 = (_a2 = adventure.bedArrangementLabels) == null ? void 0 : _a2[room.bedArrangement]) != null ? _b2 : room.bedArrangement === "DOUBLE" ? "Double" : room.bedArrangement === "TWIN" ? "Twin" : room.bedArrangement === "SINGLE" ? "Single" : "Triple";
|
|
1515
|
+
return /* @__PURE__ */ jsxs("li", { className: "flex items-start gap-3", children: [
|
|
1516
|
+
room.imageUrl && // eslint-disable-next-line @next/next/no-img-element
|
|
1517
|
+
/* @__PURE__ */ jsx(
|
|
1518
|
+
"img",
|
|
1519
|
+
{
|
|
1520
|
+
src: room.imageUrl,
|
|
1521
|
+
alt: room.roomName,
|
|
1522
|
+
className: "w-20 h-16 object-cover rounded shrink-0"
|
|
1523
|
+
}
|
|
1524
|
+
),
|
|
1525
|
+
/* @__PURE__ */ jsxs("div", { className: "flex-1", children: [
|
|
1526
|
+
/* @__PURE__ */ jsx("div", { className: "text-base font-semibold text-foreground", children: `${room.qty}\xD7 ${room.roomName}` }),
|
|
1527
|
+
/* @__PURE__ */ jsxs("div", { className: "text-sm text-foreground/70 flex items-center gap-2 flex-wrap", children: [
|
|
1528
|
+
/* @__PURE__ */ jsx("span", { children: room.accommodationName }),
|
|
1529
|
+
/* @__PURE__ */ jsx("span", { className: "inline-block px-2 py-0.5 text-xs font-semibold bg-primary/10 text-primary rounded uppercase tracking-wide", children: bedLabel })
|
|
1530
|
+
] }),
|
|
1531
|
+
room.description && /* @__PURE__ */ jsx("p", { className: "text-sm text-foreground/70 mt-1 leading-snug", children: room.description })
|
|
1532
|
+
] })
|
|
1533
|
+
] }, i);
|
|
1534
|
+
}) })
|
|
1535
|
+
] }),
|
|
1510
1536
|
adventure.included && adventure.included.length > 0 && /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-2.5 mt-1", children: [
|
|
1511
|
-
/* @__PURE__ */ jsx("h4", { className: "text-base font-bold text-foreground font-heading", children: (
|
|
1537
|
+
/* @__PURE__ */ jsx("h4", { className: "text-base font-bold text-foreground font-heading", children: (_q = adventure.includedLabel) != null ? _q : "What's included" }),
|
|
1512
1538
|
/* @__PURE__ */ jsx("ul", { className: "flex flex-col gap-1.5", children: adventure.included.map((item, i) => /* @__PURE__ */ jsxs("li", { className: "flex items-start gap-2 text-base text-foreground/80 font-sans", children: [
|
|
1513
1539
|
/* @__PURE__ */ jsx(CheckIcon, { className: "w-4 h-4 text-primary shrink-0 mt-1" }),
|
|
1514
1540
|
item
|
|
1515
1541
|
] }, i)) })
|
|
1516
1542
|
] }),
|
|
1517
1543
|
adventure.notIncluded && adventure.notIncluded.length > 0 && /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-2.5 mt-1", children: [
|
|
1518
|
-
/* @__PURE__ */ jsx("h4", { className: "text-base font-bold text-foreground font-heading", children: (
|
|
1544
|
+
/* @__PURE__ */ jsx("h4", { className: "text-base font-bold text-foreground font-heading", children: (_r = adventure.notIncludedLabel) != null ? _r : "What's not included" }),
|
|
1519
1545
|
/* @__PURE__ */ jsx("ul", { className: "flex flex-col gap-1.5", children: adventure.notIncluded.map((item, i) => /* @__PURE__ */ jsxs("li", { className: "flex items-start gap-2 text-base text-foreground/80 font-sans", children: [
|
|
1520
1546
|
/* @__PURE__ */ jsx(XIcon, { className: "w-4 h-4 text-destructive shrink-0 mt-1" }),
|
|
1521
1547
|
item
|
|
1522
1548
|
] }, i)) })
|
|
1523
1549
|
] }),
|
|
1524
1550
|
adventure.cancellationPolicy && adventure.cancellationPolicy.length > 0 && /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-2.5 mt-1", children: [
|
|
1525
|
-
/* @__PURE__ */ jsx("h4", { className: "text-base font-bold text-foreground font-heading", children: (
|
|
1551
|
+
/* @__PURE__ */ jsx("h4", { className: "text-base font-bold text-foreground font-heading", children: (_s = adventure.cancellationPolicyLabel) != null ? _s : "Cancellation policy" }),
|
|
1526
1552
|
/* @__PURE__ */ jsx("ul", { className: "flex flex-col gap-1.5", children: adventure.cancellationPolicy.map((item, i) => /* @__PURE__ */ jsxs("li", { className: "flex items-start gap-2 text-base text-muted-foreground font-sans", children: [
|
|
1527
1553
|
/* @__PURE__ */ jsx("span", { className: "w-1.5 h-1.5 rounded-full bg-primary shrink-0 mt-2.5" }),
|
|
1528
1554
|
item
|
|
@@ -2702,7 +2728,7 @@ function AdventureSection({
|
|
|
2702
2728
|
cannotRemoveLastTravellerLabel,
|
|
2703
2729
|
labels
|
|
2704
2730
|
}) {
|
|
2705
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r;
|
|
2731
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s;
|
|
2706
2732
|
const [detailsOpen, setDetailsOpen] = React31.useState(false);
|
|
2707
2733
|
const handleCopyUrl = (url) => {
|
|
2708
2734
|
if (onCopyFormLink) {
|
|
@@ -2837,10 +2863,36 @@ function AdventureSection({
|
|
|
2837
2863
|
)) })
|
|
2838
2864
|
] })
|
|
2839
2865
|
] }),
|
|
2866
|
+
adventure.rooms && adventure.rooms.length > 0 && /* @__PURE__ */ jsxs("div", { className: "border-t border-border px-5 lg:px-6 py-5 flex flex-col gap-3", children: [
|
|
2867
|
+
/* @__PURE__ */ jsx("h4", { className: "text-xs font-bold text-muted-foreground font-heading uppercase tracking-widest", children: (_l = labels == null ? void 0 : labels.accommodationsHeading) != null ? _l : "ACCOMMODATIONS" }),
|
|
2868
|
+
/* @__PURE__ */ jsx("div", { className: "flex flex-col gap-3", children: adventure.rooms.map((room, i) => {
|
|
2869
|
+
var _a2, _b2;
|
|
2870
|
+
return /* @__PURE__ */ jsxs("div", { className: "flex items-start gap-3", children: [
|
|
2871
|
+
room.imageUrl && // eslint-disable-next-line @next/next/no-img-element
|
|
2872
|
+
/* @__PURE__ */ jsx(
|
|
2873
|
+
"img",
|
|
2874
|
+
{
|
|
2875
|
+
src: room.imageUrl,
|
|
2876
|
+
alt: room.roomName,
|
|
2877
|
+
className: "w-20 h-15 object-cover rounded-md shrink-0",
|
|
2878
|
+
style: { width: "80px", height: "60px" }
|
|
2879
|
+
}
|
|
2880
|
+
),
|
|
2881
|
+
/* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-0.5 min-w-0", children: [
|
|
2882
|
+
/* @__PURE__ */ jsx("p", { className: "text-sm font-semibold text-foreground font-sans", children: `${room.qty}\xD7 ${room.roomName}` }),
|
|
2883
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2 flex-wrap text-xs text-muted-foreground font-sans", children: [
|
|
2884
|
+
/* @__PURE__ */ jsx("span", { children: room.accommodationName }),
|
|
2885
|
+
/* @__PURE__ */ jsx("span", { className: "inline-block px-1.5 py-0.5 text-[10px] font-semibold text-primary bg-primary/10 rounded uppercase tracking-wider", children: (_b2 = (_a2 = labels == null ? void 0 : labels.bedArrangementLabels) == null ? void 0 : _a2[room.bedArrangement]) != null ? _b2 : room.bedArrangement })
|
|
2886
|
+
] }),
|
|
2887
|
+
room.description && /* @__PURE__ */ jsx("p", { className: "text-xs text-foreground/80 font-sans mt-1 leading-snug", children: room.description })
|
|
2888
|
+
] })
|
|
2889
|
+
] }, i);
|
|
2890
|
+
}) })
|
|
2891
|
+
] }),
|
|
2840
2892
|
/* @__PURE__ */ jsxs("div", { className: "border-t border-border px-5 lg:px-6 py-5 flex flex-col gap-4", children: [
|
|
2841
2893
|
/* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between gap-3 flex-wrap", children: [
|
|
2842
2894
|
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
|
|
2843
|
-
/* @__PURE__ */ jsx("h4", { className: "text-xs font-bold text-muted-foreground font-heading uppercase tracking-widest", children: (
|
|
2895
|
+
/* @__PURE__ */ jsx("h4", { className: "text-xs font-bold text-muted-foreground font-heading uppercase tracking-widest", children: (_m = labels == null ? void 0 : labels.travellersSection) != null ? _m : "Travellers" }),
|
|
2844
2896
|
adventure.formName && /* @__PURE__ */ jsxs("span", { className: "text-xs font-semibold text-muted-foreground/50 font-heading tracking-wide", children: [
|
|
2845
2897
|
"\xB7 ",
|
|
2846
2898
|
adventure.formName
|
|
@@ -2861,8 +2913,8 @@ function AdventureSection({
|
|
|
2861
2913
|
),
|
|
2862
2914
|
children: [
|
|
2863
2915
|
/* @__PURE__ */ jsx(UserPlusIcon, { className: "w-3 h-3" }),
|
|
2864
|
-
/* @__PURE__ */ jsx("span", { className: "hidden sm:inline", children: (
|
|
2865
|
-
/* @__PURE__ */ jsx("span", { className: "sm:hidden", children: (
|
|
2916
|
+
/* @__PURE__ */ jsx("span", { className: "hidden sm:inline", children: (_n = labels == null ? void 0 : labels.addContactAsTraveller) != null ? _n : "Add contact as traveller" }),
|
|
2917
|
+
/* @__PURE__ */ jsx("span", { className: "sm:hidden", children: (_o = labels == null ? void 0 : labels.addContactAsTravellerShort) != null ? _o : "Add contact" })
|
|
2866
2918
|
]
|
|
2867
2919
|
}
|
|
2868
2920
|
),
|
|
@@ -2880,8 +2932,8 @@ function AdventureSection({
|
|
|
2880
2932
|
className: "flex items-center gap-1.5 rounded-full border border-border px-3 py-1.5 text-xs font-ui text-primary hover:border-primary hover:bg-primary/5 transition-colors",
|
|
2881
2933
|
children: [
|
|
2882
2934
|
/* @__PURE__ */ jsx(PlusIcon, { className: "w-3 h-3" }),
|
|
2883
|
-
/* @__PURE__ */ jsx("span", { className: "hidden sm:inline", children: (
|
|
2884
|
-
/* @__PURE__ */ jsx("span", { className: "sm:hidden", children: (
|
|
2935
|
+
/* @__PURE__ */ jsx("span", { className: "hidden sm:inline", children: (_p = adventure.addTravellerLabel) != null ? _p : "More travellers" }),
|
|
2936
|
+
/* @__PURE__ */ jsx("span", { className: "sm:hidden", children: (_r = (_q = adventure.addTravellerShortLabel) != null ? _q : adventure.addTravellerLabel) != null ? _r : "Add" })
|
|
2885
2937
|
]
|
|
2886
2938
|
}
|
|
2887
2939
|
)
|
|
@@ -3073,7 +3125,7 @@ function AdventureSection({
|
|
|
3073
3125
|
)) })
|
|
3074
3126
|
] });
|
|
3075
3127
|
})(),
|
|
3076
|
-
adventure.registrationNotRequired ? /* @__PURE__ */ jsx("div", { className: "flex items-center gap-2 mt-1", children: /* @__PURE__ */ jsx("span", { className: "text-xs font-ui text-muted-foreground", children: (
|
|
3128
|
+
adventure.registrationNotRequired ? /* @__PURE__ */ jsx("div", { className: "flex items-center gap-2 mt-1", children: /* @__PURE__ */ jsx("span", { className: "text-xs font-ui text-muted-foreground", children: (_s = adventure.noRegistrationRequiredLabel) != null ? _s : "No registration required" }) }) : adventure.travellers.length > 0 && totalSlots > 0 && (() => {
|
|
3077
3129
|
var _a2, _b2;
|
|
3078
3130
|
const completed = adventure.travellers.filter((t) => t.status === "completed").length;
|
|
3079
3131
|
const percent = Math.round(completed / totalSlots * 100);
|
|
@@ -4071,7 +4123,14 @@ var DEFAULT_LABELS = {
|
|
|
4071
4123
|
notIncludedHeading: "O que n\xE3o est\xE1 incluso",
|
|
4072
4124
|
childBadge: "child",
|
|
4073
4125
|
adultsUnit: "adult(s)",
|
|
4074
|
-
childrenUnit: "child(ren)"
|
|
4126
|
+
childrenUnit: "child(ren)",
|
|
4127
|
+
accommodationsHeading: "ACCOMMODATIONS",
|
|
4128
|
+
bedArrangementLabels: {
|
|
4129
|
+
DOUBLE: "Double",
|
|
4130
|
+
TWIN: "Twin",
|
|
4131
|
+
SINGLE: "Single",
|
|
4132
|
+
TRIPLE: "Triple"
|
|
4133
|
+
}
|
|
4075
4134
|
};
|
|
4076
4135
|
function BookingAdventureCard({
|
|
4077
4136
|
tag,
|
|
@@ -4091,10 +4150,11 @@ function BookingAdventureCard({
|
|
|
4091
4150
|
notIncluded,
|
|
4092
4151
|
lineItems,
|
|
4093
4152
|
subtotal,
|
|
4153
|
+
rooms,
|
|
4094
4154
|
labels,
|
|
4095
4155
|
className
|
|
4096
4156
|
}) {
|
|
4097
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l;
|
|
4157
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u;
|
|
4098
4158
|
const l = {
|
|
4099
4159
|
travellersHeading: (_a = labels == null ? void 0 : labels.travellersHeading) != null ? _a : DEFAULT_LABELS.travellersHeading,
|
|
4100
4160
|
detailsHeading: (_b = labels == null ? void 0 : labels.detailsHeading) != null ? _b : DEFAULT_LABELS.detailsHeading,
|
|
@@ -4107,7 +4167,14 @@ function BookingAdventureCard({
|
|
|
4107
4167
|
notIncludedHeading: (_i = labels == null ? void 0 : labels.notIncludedHeading) != null ? _i : DEFAULT_LABELS.notIncludedHeading,
|
|
4108
4168
|
childBadge: (_j = labels == null ? void 0 : labels.childBadge) != null ? _j : DEFAULT_LABELS.childBadge,
|
|
4109
4169
|
adultsUnit: (_k = labels == null ? void 0 : labels.adultsUnit) != null ? _k : DEFAULT_LABELS.adultsUnit,
|
|
4110
|
-
childrenUnit: (_l = labels == null ? void 0 : labels.childrenUnit) != null ? _l : DEFAULT_LABELS.childrenUnit
|
|
4170
|
+
childrenUnit: (_l = labels == null ? void 0 : labels.childrenUnit) != null ? _l : DEFAULT_LABELS.childrenUnit,
|
|
4171
|
+
accommodationsHeading: (_m = labels == null ? void 0 : labels.accommodationsHeading) != null ? _m : DEFAULT_LABELS.accommodationsHeading,
|
|
4172
|
+
bedArrangementLabels: {
|
|
4173
|
+
DOUBLE: (_o = (_n = labels == null ? void 0 : labels.bedArrangementLabels) == null ? void 0 : _n.DOUBLE) != null ? _o : DEFAULT_LABELS.bedArrangementLabels.DOUBLE,
|
|
4174
|
+
TWIN: (_q = (_p = labels == null ? void 0 : labels.bedArrangementLabels) == null ? void 0 : _p.TWIN) != null ? _q : DEFAULT_LABELS.bedArrangementLabels.TWIN,
|
|
4175
|
+
SINGLE: (_s = (_r = labels == null ? void 0 : labels.bedArrangementLabels) == null ? void 0 : _r.SINGLE) != null ? _s : DEFAULT_LABELS.bedArrangementLabels.SINGLE,
|
|
4176
|
+
TRIPLE: (_u = (_t = labels == null ? void 0 : labels.bedArrangementLabels) == null ? void 0 : _t.TRIPLE) != null ? _u : DEFAULT_LABELS.bedArrangementLabels.TRIPLE
|
|
4177
|
+
}
|
|
4111
4178
|
};
|
|
4112
4179
|
const hasTravellers = !!travellers && travellers.length > 0;
|
|
4113
4180
|
const hasItinerary = !!itinerary && itinerary.length > 0;
|
|
@@ -4115,6 +4182,7 @@ function BookingAdventureCard({
|
|
|
4115
4182
|
const hasIncluded = !!included && included.length > 0;
|
|
4116
4183
|
const hasNotIncluded = !!notIncluded && notIncluded.length > 0;
|
|
4117
4184
|
const hasLineItems = lineItems.length > 0;
|
|
4185
|
+
const hasRooms = !!rooms && rooms.length > 0;
|
|
4118
4186
|
const dateRange = endDate ? `${startDate} \u2192 ${endDate}` : startDate;
|
|
4119
4187
|
const showSlots = !!slots;
|
|
4120
4188
|
const slotsText = showSlots ? [
|
|
@@ -4411,6 +4479,118 @@ function BookingAdventureCard({
|
|
|
4411
4479
|
);
|
|
4412
4480
|
})
|
|
4413
4481
|
] }),
|
|
4482
|
+
hasRooms && /* @__PURE__ */ jsxs("div", { style: { marginTop: "4px" }, children: [
|
|
4483
|
+
/* @__PURE__ */ jsx(
|
|
4484
|
+
"hr",
|
|
4485
|
+
{
|
|
4486
|
+
style: {
|
|
4487
|
+
border: "none",
|
|
4488
|
+
borderTop: `1px solid ${emailTokens.border}`,
|
|
4489
|
+
marginBottom: "10px"
|
|
4490
|
+
}
|
|
4491
|
+
}
|
|
4492
|
+
),
|
|
4493
|
+
/* @__PURE__ */ jsx(
|
|
4494
|
+
"p",
|
|
4495
|
+
{
|
|
4496
|
+
style: {
|
|
4497
|
+
fontSize: "10px",
|
|
4498
|
+
fontWeight: 700,
|
|
4499
|
+
color: emailTokens.mutedForeground,
|
|
4500
|
+
textTransform: "uppercase",
|
|
4501
|
+
letterSpacing: "0.1em",
|
|
4502
|
+
margin: "0 0 10px 0"
|
|
4503
|
+
},
|
|
4504
|
+
children: l.accommodationsHeading
|
|
4505
|
+
}
|
|
4506
|
+
),
|
|
4507
|
+
rooms.map((room, i) => /* @__PURE__ */ jsx(
|
|
4508
|
+
"table",
|
|
4509
|
+
{
|
|
4510
|
+
cellPadding: 0,
|
|
4511
|
+
cellSpacing: 0,
|
|
4512
|
+
style: {
|
|
4513
|
+
borderCollapse: "collapse",
|
|
4514
|
+
width: "100%",
|
|
4515
|
+
marginBottom: i < rooms.length - 1 ? "10px" : "0"
|
|
4516
|
+
},
|
|
4517
|
+
children: /* @__PURE__ */ jsx("tbody", { children: /* @__PURE__ */ jsxs("tr", { children: [
|
|
4518
|
+
room.imageUrl && /* @__PURE__ */ jsx(
|
|
4519
|
+
"td",
|
|
4520
|
+
{
|
|
4521
|
+
style: {
|
|
4522
|
+
width: "80px",
|
|
4523
|
+
verticalAlign: "top",
|
|
4524
|
+
paddingRight: "10px"
|
|
4525
|
+
},
|
|
4526
|
+
children: /* @__PURE__ */ jsx(
|
|
4527
|
+
"img",
|
|
4528
|
+
{
|
|
4529
|
+
src: room.imageUrl,
|
|
4530
|
+
alt: room.roomName,
|
|
4531
|
+
style: {
|
|
4532
|
+
width: "80px",
|
|
4533
|
+
height: "60px",
|
|
4534
|
+
objectFit: "cover",
|
|
4535
|
+
display: "block",
|
|
4536
|
+
borderRadius: "6px"
|
|
4537
|
+
}
|
|
4538
|
+
}
|
|
4539
|
+
)
|
|
4540
|
+
}
|
|
4541
|
+
),
|
|
4542
|
+
/* @__PURE__ */ jsxs("td", { style: { verticalAlign: "top" }, children: [
|
|
4543
|
+
/* @__PURE__ */ jsx(
|
|
4544
|
+
"div",
|
|
4545
|
+
{
|
|
4546
|
+
style: {
|
|
4547
|
+
fontSize: "14px",
|
|
4548
|
+
fontWeight: 600,
|
|
4549
|
+
color: emailTokens.foreground,
|
|
4550
|
+
marginBottom: "2px"
|
|
4551
|
+
},
|
|
4552
|
+
children: `${room.qty}\xD7 ${room.roomName}`
|
|
4553
|
+
}
|
|
4554
|
+
),
|
|
4555
|
+
/* @__PURE__ */ jsxs("div", { style: { fontSize: "12px", color: emailTokens.mutedForeground }, children: [
|
|
4556
|
+
room.accommodationName,
|
|
4557
|
+
/* @__PURE__ */ jsx(
|
|
4558
|
+
"span",
|
|
4559
|
+
{
|
|
4560
|
+
style: {
|
|
4561
|
+
display: "inline-block",
|
|
4562
|
+
marginLeft: "8px",
|
|
4563
|
+
padding: "1px 6px",
|
|
4564
|
+
fontSize: "10px",
|
|
4565
|
+
fontWeight: 600,
|
|
4566
|
+
color: emailTokens.primary,
|
|
4567
|
+
backgroundColor: emailTokens.primaryLight,
|
|
4568
|
+
borderRadius: "4px",
|
|
4569
|
+
textTransform: "uppercase",
|
|
4570
|
+
letterSpacing: "0.05em"
|
|
4571
|
+
},
|
|
4572
|
+
children: l.bedArrangementLabels[room.bedArrangement]
|
|
4573
|
+
}
|
|
4574
|
+
)
|
|
4575
|
+
] }),
|
|
4576
|
+
room.description && /* @__PURE__ */ jsx(
|
|
4577
|
+
"div",
|
|
4578
|
+
{
|
|
4579
|
+
style: {
|
|
4580
|
+
fontSize: "12px",
|
|
4581
|
+
color: emailTokens.bodyText,
|
|
4582
|
+
marginTop: "4px",
|
|
4583
|
+
lineHeight: "1.4"
|
|
4584
|
+
},
|
|
4585
|
+
children: room.description
|
|
4586
|
+
}
|
|
4587
|
+
)
|
|
4588
|
+
] })
|
|
4589
|
+
] }) })
|
|
4590
|
+
},
|
|
4591
|
+
i
|
|
4592
|
+
))
|
|
4593
|
+
] }),
|
|
4414
4594
|
(hasDescription || hasItinerary) && /* @__PURE__ */ jsxs("div", { style: { marginTop: "4px" }, children: [
|
|
4415
4595
|
/* @__PURE__ */ jsx(
|
|
4416
4596
|
"hr",
|
|
@@ -4663,8 +4843,21 @@ function BookingAdventureCard({
|
|
|
4663
4843
|
}
|
|
4664
4844
|
);
|
|
4665
4845
|
}
|
|
4666
|
-
|
|
4667
|
-
|
|
4846
|
+
var DEFAULT_BED_LABELS = {
|
|
4847
|
+
DOUBLE: "Double",
|
|
4848
|
+
TWIN: "Twin",
|
|
4849
|
+
SINGLE: "Single",
|
|
4850
|
+
TRIPLE: "Triple"
|
|
4851
|
+
};
|
|
4852
|
+
function BookingSummary({ heading, rows, rooms, roomsHeading, bedArrangementLabels, footer, className }) {
|
|
4853
|
+
var _a, _b, _c, _d, _e, _f;
|
|
4854
|
+
const hasRooms = !!rooms && rooms.length > 0;
|
|
4855
|
+
const bedLabels = {
|
|
4856
|
+
DOUBLE: (_a = bedArrangementLabels == null ? void 0 : bedArrangementLabels.DOUBLE) != null ? _a : DEFAULT_BED_LABELS.DOUBLE,
|
|
4857
|
+
TWIN: (_b = bedArrangementLabels == null ? void 0 : bedArrangementLabels.TWIN) != null ? _b : DEFAULT_BED_LABELS.TWIN,
|
|
4858
|
+
SINGLE: (_c = bedArrangementLabels == null ? void 0 : bedArrangementLabels.SINGLE) != null ? _c : DEFAULT_BED_LABELS.SINGLE,
|
|
4859
|
+
TRIPLE: (_d = bedArrangementLabels == null ? void 0 : bedArrangementLabels.TRIPLE) != null ? _d : DEFAULT_BED_LABELS.TRIPLE
|
|
4860
|
+
};
|
|
4668
4861
|
return /* @__PURE__ */ jsxs("div", { className, style: { marginBottom: "24px" }, children: [
|
|
4669
4862
|
heading && /* @__PURE__ */ jsx(
|
|
4670
4863
|
"p",
|
|
@@ -4699,7 +4892,7 @@ function BookingSummary({ heading, rows, footer, className }) {
|
|
|
4699
4892
|
children: /* @__PURE__ */ jsxs("tbody", { children: [
|
|
4700
4893
|
rows.map((row, i) => {
|
|
4701
4894
|
var _a2;
|
|
4702
|
-
const isLastRowWithoutFooter = i === rows.length - 1 && !footer;
|
|
4895
|
+
const isLastRowWithoutFooter = i === rows.length - 1 && !footer && !hasRooms;
|
|
4703
4896
|
return /* @__PURE__ */ jsxs(
|
|
4704
4897
|
"tr",
|
|
4705
4898
|
{
|
|
@@ -4737,6 +4930,50 @@ function BookingSummary({ heading, rows, footer, className }) {
|
|
|
4737
4930
|
i
|
|
4738
4931
|
);
|
|
4739
4932
|
}),
|
|
4933
|
+
hasRooms && /* @__PURE__ */ jsx(
|
|
4934
|
+
"tr",
|
|
4935
|
+
{
|
|
4936
|
+
style: !footer ? {} : { borderBottom: `1px solid ${emailTokens.border}` },
|
|
4937
|
+
children: /* @__PURE__ */ jsxs(
|
|
4938
|
+
"td",
|
|
4939
|
+
{
|
|
4940
|
+
colSpan: 2,
|
|
4941
|
+
style: {
|
|
4942
|
+
padding: "12px 20px",
|
|
4943
|
+
backgroundColor: emailTokens.muted
|
|
4944
|
+
},
|
|
4945
|
+
children: [
|
|
4946
|
+
/* @__PURE__ */ jsx(
|
|
4947
|
+
"div",
|
|
4948
|
+
{
|
|
4949
|
+
style: {
|
|
4950
|
+
fontSize: "10px",
|
|
4951
|
+
fontWeight: 700,
|
|
4952
|
+
color: emailTokens.mutedForeground,
|
|
4953
|
+
textTransform: "uppercase",
|
|
4954
|
+
letterSpacing: "0.1em",
|
|
4955
|
+
marginBottom: "6px"
|
|
4956
|
+
},
|
|
4957
|
+
children: roomsHeading != null ? roomsHeading : "Accommodations"
|
|
4958
|
+
}
|
|
4959
|
+
),
|
|
4960
|
+
rooms.map((room, i) => /* @__PURE__ */ jsx(
|
|
4961
|
+
"div",
|
|
4962
|
+
{
|
|
4963
|
+
style: {
|
|
4964
|
+
fontSize: "14px",
|
|
4965
|
+
color: emailTokens.foreground,
|
|
4966
|
+
marginBottom: i < rooms.length - 1 ? "4px" : 0
|
|
4967
|
+
},
|
|
4968
|
+
children: `${room.qty}\xD7 ${room.roomName} \u2014 ${bedLabels[room.bedArrangement]}`
|
|
4969
|
+
},
|
|
4970
|
+
i
|
|
4971
|
+
))
|
|
4972
|
+
]
|
|
4973
|
+
}
|
|
4974
|
+
)
|
|
4975
|
+
}
|
|
4976
|
+
),
|
|
4740
4977
|
footer && /* @__PURE__ */ jsx("tr", { children: /* @__PURE__ */ jsx(
|
|
4741
4978
|
"td",
|
|
4742
4979
|
{
|
|
@@ -4744,8 +4981,8 @@ function BookingSummary({ heading, rows, footer, className }) {
|
|
|
4744
4981
|
style: {
|
|
4745
4982
|
padding: "12px 20px",
|
|
4746
4983
|
textAlign: "center",
|
|
4747
|
-
fontWeight: (
|
|
4748
|
-
color: (
|
|
4984
|
+
fontWeight: (_e = footer.fontWeight) != null ? _e : 600,
|
|
4985
|
+
color: (_f = footer.color) != null ? _f : emailTokens.foreground,
|
|
4749
4986
|
backgroundColor: footer.backgroundColor
|
|
4750
4987
|
},
|
|
4751
4988
|
children: footer.text
|
|
@@ -6412,6 +6649,13 @@ var DEFAULT_LABELS9 = {
|
|
|
6412
6649
|
datesLabel: "Dates",
|
|
6413
6650
|
numberOfPeopleLabel: "Number of Travellers",
|
|
6414
6651
|
optionalsLabel: "Optionals",
|
|
6652
|
+
accommodationsHeading: "Accommodations",
|
|
6653
|
+
bedArrangementLabels: {
|
|
6654
|
+
DOUBLE: "Double",
|
|
6655
|
+
TWIN: "Twin",
|
|
6656
|
+
SINGLE: "Single",
|
|
6657
|
+
TRIPLE: "Triple"
|
|
6658
|
+
},
|
|
6415
6659
|
registrationPendingNotice: "The travellers' registration details will be sent to you as soon as all travellers have completed their forms.",
|
|
6416
6660
|
mustReplyToConfirm: "Please reply to this email to confirm the booking.",
|
|
6417
6661
|
closingAgent: (agentName, contact) => /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
@@ -6435,6 +6679,7 @@ function PartnerBookingCreatedEmail({
|
|
|
6435
6679
|
dateRange,
|
|
6436
6680
|
travellersCount,
|
|
6437
6681
|
optionals,
|
|
6682
|
+
rooms,
|
|
6438
6683
|
booker,
|
|
6439
6684
|
agent,
|
|
6440
6685
|
logoUrl,
|
|
@@ -6499,7 +6744,16 @@ function PartnerBookingCreatedEmail({
|
|
|
6499
6744
|
/* @__PURE__ */ jsx("p", { style: { marginBottom: "16px" }, children: l.greeting(partnerName) }),
|
|
6500
6745
|
/* @__PURE__ */ jsx("p", { style: { marginBottom: "24px" }, children: l.intro(adventureName) }),
|
|
6501
6746
|
sectionDivider,
|
|
6502
|
-
/* @__PURE__ */ jsx(
|
|
6747
|
+
/* @__PURE__ */ jsx(
|
|
6748
|
+
BookingSummary,
|
|
6749
|
+
{
|
|
6750
|
+
heading: l.summaryHeading,
|
|
6751
|
+
rows: summaryRows,
|
|
6752
|
+
rooms,
|
|
6753
|
+
roomsHeading: l.accommodationsHeading,
|
|
6754
|
+
bedArrangementLabels: l.bedArrangementLabels
|
|
6755
|
+
}
|
|
6756
|
+
),
|
|
6503
6757
|
sectionDivider,
|
|
6504
6758
|
/* @__PURE__ */ jsxs(
|
|
6505
6759
|
"div",
|