@planetaexo/design-system 0.20.0 → 0.22.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
@@ -5181,13 +5181,14 @@ function formatDateRange(adventure, fmt) {
5181
5181
  function FormSection2({
5182
5182
  title,
5183
5183
  children,
5184
- className
5184
+ className,
5185
+ breakInside = "avoid"
5185
5186
  }) {
5186
5187
  return /* @__PURE__ */ jsxRuntime.jsxs(
5187
5188
  "div",
5188
5189
  {
5189
5190
  className: cn("flex flex-col gap-5", className),
5190
- style: { breakInside: "avoid" },
5191
+ style: { breakInside },
5191
5192
  children: [
5192
5193
  /* @__PURE__ */ jsxRuntime.jsxs(
5193
5194
  "div",
@@ -6123,7 +6124,9 @@ function RegistrationSuccessCard({
6123
6124
  density = "comfortable",
6124
6125
  submissionTimestamps,
6125
6126
  submissionTimestampsLabels,
6126
- labels: scLabels
6127
+ labels: scLabels,
6128
+ sectionsBreakInside = "avoid",
6129
+ termsTypography = "default"
6127
6130
  }) {
6128
6131
  var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l;
6129
6132
  const isMinimal = variant === "minimal";
@@ -6188,7 +6191,7 @@ function RegistrationSuccessCard({
6188
6191
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "tabular-nums", children: submissionTimestamps.lastUpdatedAt })
6189
6192
  ] })
6190
6193
  ] }),
6191
- hasTripInfo && /* @__PURE__ */ jsxRuntime.jsx(FormSection2, { title: TL.sectionTitle, children: /* @__PURE__ */ jsxRuntime.jsxs("dl", { className: "flex flex-col gap-y-3 text-sm font-ui", children: [
6194
+ hasTripInfo && /* @__PURE__ */ jsxRuntime.jsx(FormSection2, { title: TL.sectionTitle, breakInside: sectionsBreakInside, children: /* @__PURE__ */ jsxRuntime.jsxs("dl", { className: "flex flex-col gap-y-3 text-sm font-ui", children: [
6192
6195
  adventure && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start gap-x-4", children: [
6193
6196
  /* @__PURE__ */ jsxRuntime.jsx("dt", { className: "w-1/2 text-muted-foreground break-words", children: TL.adventureLabel }),
6194
6197
  /* @__PURE__ */ jsxRuntime.jsx("dd", { className: "w-1/2 text-foreground font-medium text-right min-w-0 break-words", children: adventure.name })
@@ -6210,7 +6213,7 @@ function RegistrationSuccessCard({
6210
6213
  /* @__PURE__ */ jsxRuntime.jsx("dd", { className: "w-1/2 text-foreground font-medium text-right min-w-0 break-words", children: traveller.fullName })
6211
6214
  ] })
6212
6215
  ] }) }),
6213
- sorted.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(FormSection2, { title: answersTitle, children: /* @__PURE__ */ jsxRuntime.jsx("dl", { className: "flex flex-col gap-y-3 text-sm font-ui", children: sorted.map((f) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start gap-x-4", children: [
6216
+ sorted.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(FormSection2, { title: answersTitle, breakInside: sectionsBreakInside, children: /* @__PURE__ */ jsxRuntime.jsx("dl", { className: "flex flex-col gap-y-3 text-sm font-ui", children: sorted.map((f) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start gap-x-4", children: [
6214
6217
  /* @__PURE__ */ jsxRuntime.jsx("dt", { className: "w-1/2 text-muted-foreground break-words", children: f.label }),
6215
6218
  /* @__PURE__ */ jsxRuntime.jsx("dd", { className: "w-1/2 text-foreground text-right min-w-0 break-words", children: (formatAnswer != null ? formatAnswer : ((field, v) => defaultFormatAnswer(field, v, dateFormatter, {
6216
6219
  yesLabel: scLabels == null ? void 0 : scLabels.yesLabel,
@@ -6220,7 +6223,7 @@ function RegistrationSuccessCard({
6220
6223
  answers[f.id]
6221
6224
  ) })
6222
6225
  ] }, f.id)) }) }),
6223
- !isMinimal && terms && /* @__PURE__ */ jsxRuntime.jsx(FormSection2, { title: (_j = termsLabels == null ? void 0 : termsLabels.title) != null ? _j : "Terms & Conditions", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-3 text-sm font-ui", children: [
6226
+ !isMinimal && terms && /* @__PURE__ */ jsxRuntime.jsx(FormSection2, { title: (_j = termsLabels == null ? void 0 : termsLabels.title) != null ? _j : "Terms & Conditions", breakInside: sectionsBreakInside, children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-3 text-sm font-ui", children: [
6224
6227
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
6225
6228
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn(
6226
6229
  "inline-flex h-5 w-5 items-center justify-center rounded-full text-white text-xs font-bold",
@@ -6240,8 +6243,8 @@ function RegistrationSuccessCard({
6240
6243
  "p",
6241
6244
  {
6242
6245
  className: cn(
6243
- "whitespace-pre-wrap break-words text-foreground font-ui",
6244
- isCompact ? "text-xs leading-snug" : "text-sm leading-relaxed"
6246
+ "whitespace-pre-wrap break-words text-foreground",
6247
+ termsTypography === "compact-serif" ? "font-serif text-[8pt] leading-tight" : cn("font-ui", isCompact ? "text-xs leading-snug" : "text-sm leading-relaxed")
6245
6248
  ),
6246
6249
  children: terms.markdown
6247
6250
  }