@planetaexo/design-system 0.44.0 → 0.46.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/dist/index.cjs CHANGED
@@ -3799,7 +3799,20 @@ function BookingDetails({
3799
3799
  contact.passport && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
3800
3800
  /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs font-bold text-muted-foreground/60 font-heading uppercase tracking-widest mb-0.5", children: (_E = (_D = labels == null ? void 0 : labels.contactDetailsFields) == null ? void 0 : _D.document) != null ? _E : "Passport / ID" }),
3801
3801
  /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-foreground font-sans", children: contact.passport })
3802
- ] })
3802
+ ] }),
3803
+ (() => {
3804
+ var _a2, _b2, _c2;
3805
+ const parts = [
3806
+ [contact.addressLine1, contact.addressLine2].map((s) => s == null ? void 0 : s.trim()).filter(Boolean).join(", "),
3807
+ [contact.city, contact.state].map((s) => s == null ? void 0 : s.trim()).filter(Boolean).join(", "),
3808
+ (_a2 = contact.postalCode) == null ? void 0 : _a2.trim()
3809
+ ].filter((p) => p && p.length > 0);
3810
+ if (parts.length === 0) return null;
3811
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "col-span-2 sm:col-span-3", children: [
3812
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs font-bold text-muted-foreground/60 font-heading uppercase tracking-widest mb-0.5", children: (_c2 = (_b2 = labels == null ? void 0 : labels.contactDetailsFields) == null ? void 0 : _b2.address) != null ? _c2 : "Address" }),
3813
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-foreground font-sans whitespace-pre-line", children: parts.join("\n") })
3814
+ ] });
3815
+ })()
3803
3816
  ] })
3804
3817
  ] }),
3805
3818
  (onPayBalance || onCancelRequest) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-4", children: [
@@ -4655,7 +4668,10 @@ function BookingSummary({ heading, rows, footer, className }) {
4655
4668
  padding: "12px 20px",
4656
4669
  fontWeight: row.valueColor === emailTokens.primary ? 600 : 500,
4657
4670
  color: (_a2 = row.valueColor) != null ? _a2 : emailTokens.foreground,
4658
- verticalAlign: "top"
4671
+ verticalAlign: "top",
4672
+ // Preserva quebras de linha em valores multi-linha (ex.: endereço
4673
+ // montado com "\n"). Inócuo para valores de uma linha.
4674
+ whiteSpace: "pre-line"
4659
4675
  },
4660
4676
  children: row.value
4661
4677
  }
@@ -4793,6 +4809,12 @@ var DEFAULT_LABELS3 = {
4793
4809
  adventuresLabel: "Adventures",
4794
4810
  totalTravellersLabel: "Total Travellers",
4795
4811
  agentLabel: "Agent",
4812
+ bookingPersonHeading: "Booking person",
4813
+ nameLabel: "Name",
4814
+ emailLabel: "Email",
4815
+ phoneLabel: "Phone",
4816
+ countryLabel: "Country",
4817
+ addressLabel: "Billing address",
4796
4818
  adultsUnit: "adult(s)",
4797
4819
  childrenUnit: "child(ren)",
4798
4820
  travellersLabel: "Travellers",
@@ -4823,6 +4845,10 @@ function BookingPaymentConfirmationEmail({
4823
4845
  total,
4824
4846
  depositInfo,
4825
4847
  agent,
4848
+ responsiblePersonAddress,
4849
+ responsiblePersonEmail,
4850
+ responsiblePersonPhone,
4851
+ responsiblePersonCountry,
4826
4852
  viewBookingUrl,
4827
4853
  labels,
4828
4854
  className,
@@ -4834,6 +4860,26 @@ function BookingPaymentConfirmationEmail({
4834
4860
  return (_a = a.travellers) != null ? _a : [];
4835
4861
  });
4836
4862
  const isManualFlow = flow === "manual";
4863
+ const personFieldLabel = {
4864
+ margin: "0 0 2px 0",
4865
+ fontSize: "11px",
4866
+ fontWeight: 700,
4867
+ color: emailTokens.mutedForeground,
4868
+ textTransform: "uppercase",
4869
+ letterSpacing: "0.08em",
4870
+ fontFamily: emailTokens.fontFamily
4871
+ };
4872
+ const personFieldValue = {
4873
+ margin: 0,
4874
+ fontSize: "14px",
4875
+ color: emailTokens.foreground,
4876
+ lineHeight: "1.5"
4877
+ };
4878
+ const personFieldCell = {
4879
+ verticalAlign: "top",
4880
+ padding: "0 12px 14px 0",
4881
+ width: "50%"
4882
+ };
4837
4883
  const ctaStyle = {
4838
4884
  display: "inline-block",
4839
4885
  backgroundColor: emailTokens.primary,
@@ -5010,6 +5056,50 @@ function BookingPaymentConfirmationEmail({
5010
5056
  ) })
5011
5057
  ] }),
5012
5058
  /* @__PURE__ */ jsxRuntime.jsx("hr", { style: { border: "none", borderTop: `1px solid ${emailTokens.border}`, margin: "0 32px" } }),
5059
+ /* @__PURE__ */ jsxRuntime.jsx("div", { style: { paddingLeft: "32px", paddingRight: "32px", paddingTop: "32px", paddingBottom: "32px" }, children: /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { borderRadius: "16px", border: `1px solid ${emailTokens.border}`, padding: "20px" }, children: [
5060
+ /* @__PURE__ */ jsxRuntime.jsx(
5061
+ "p",
5062
+ {
5063
+ style: {
5064
+ margin: "0 0 16px 0",
5065
+ fontSize: "12px",
5066
+ fontWeight: 700,
5067
+ color: emailTokens.mutedForeground,
5068
+ textTransform: "uppercase",
5069
+ letterSpacing: "0.1em",
5070
+ fontFamily: emailTokens.fontFamily
5071
+ },
5072
+ children: l.bookingPersonHeading
5073
+ }
5074
+ ),
5075
+ /* @__PURE__ */ jsxRuntime.jsx("table", { cellPadding: 0, cellSpacing: 0, style: { width: "100%", borderCollapse: "collapse" }, children: /* @__PURE__ */ jsxRuntime.jsxs("tbody", { children: [
5076
+ /* @__PURE__ */ jsxRuntime.jsxs("tr", { children: [
5077
+ /* @__PURE__ */ jsxRuntime.jsxs("td", { style: personFieldCell, children: [
5078
+ /* @__PURE__ */ jsxRuntime.jsx("p", { style: personFieldLabel, children: l.nameLabel }),
5079
+ /* @__PURE__ */ jsxRuntime.jsx("p", { style: __spreadProps(__spreadValues({}, personFieldValue), { fontWeight: 600 }), children: recipientName })
5080
+ ] }),
5081
+ /* @__PURE__ */ jsxRuntime.jsxs("td", { style: personFieldCell, children: [
5082
+ /* @__PURE__ */ jsxRuntime.jsx("p", { style: personFieldLabel, children: l.emailLabel }),
5083
+ /* @__PURE__ */ jsxRuntime.jsx("p", { style: personFieldValue, children: responsiblePersonEmail || "\u2014" })
5084
+ ] })
5085
+ ] }),
5086
+ /* @__PURE__ */ jsxRuntime.jsxs("tr", { children: [
5087
+ /* @__PURE__ */ jsxRuntime.jsxs("td", { style: personFieldCell, children: [
5088
+ /* @__PURE__ */ jsxRuntime.jsx("p", { style: personFieldLabel, children: l.phoneLabel }),
5089
+ /* @__PURE__ */ jsxRuntime.jsx("p", { style: personFieldValue, children: responsiblePersonPhone || "\u2014" })
5090
+ ] }),
5091
+ /* @__PURE__ */ jsxRuntime.jsx("td", { style: personFieldCell, children: responsiblePersonCountry && responsiblePersonCountry.trim().length > 0 ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
5092
+ /* @__PURE__ */ jsxRuntime.jsx("p", { style: personFieldLabel, children: l.countryLabel }),
5093
+ /* @__PURE__ */ jsxRuntime.jsx("p", { style: personFieldValue, children: responsiblePersonCountry })
5094
+ ] }) : null })
5095
+ ] }),
5096
+ responsiblePersonAddress && responsiblePersonAddress.trim().length > 0 && /* @__PURE__ */ jsxRuntime.jsx("tr", { children: /* @__PURE__ */ jsxRuntime.jsxs("td", { colSpan: 2, style: __spreadProps(__spreadValues({}, personFieldCell), { width: "auto", paddingRight: 0, paddingBottom: 0 }), children: [
5097
+ /* @__PURE__ */ jsxRuntime.jsx("p", { style: personFieldLabel, children: l.addressLabel }),
5098
+ /* @__PURE__ */ jsxRuntime.jsx("p", { style: __spreadProps(__spreadValues({}, personFieldValue), { whiteSpace: "pre-line" }), children: responsiblePersonAddress })
5099
+ ] }) })
5100
+ ] }) })
5101
+ ] }) }),
5102
+ /* @__PURE__ */ jsxRuntime.jsx("hr", { style: { border: "none", borderTop: `1px solid ${emailTokens.border}`, margin: "0 32px" } }),
5013
5103
  /* @__PURE__ */ jsxRuntime.jsx("div", { style: { paddingLeft: "32px", paddingRight: "32px", paddingTop: "32px", paddingBottom: "40px" }, children: isManualFlow ? (
5014
5104
  // Manual flow: closing message + CTA no rodapé (substitui footerMessage/footerContact).
5015
5105
  /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [