@planetaexo/design-system 0.13.3 → 0.14.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 +146 -131
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +102 -2
- package/dist/index.d.ts +102 -2
- package/dist/index.js +146 -131
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -81,6 +81,49 @@ interface OfferAdventureItem {
|
|
|
81
81
|
detailsSlot?: React.ReactNode;
|
|
82
82
|
/** Label shown above the itinerary/detailsSlot section. Defaults to "Details". */
|
|
83
83
|
itineraryLabel?: string;
|
|
84
|
+
/** Label da seção "What's included". Default: "What's included". */
|
|
85
|
+
includedLabel?: string;
|
|
86
|
+
/** Label da seção "What's not included". Default: "What's not included". */
|
|
87
|
+
notIncludedLabel?: string;
|
|
88
|
+
/** Label da seção "Cancellation policy". Default: "Cancellation policy". */
|
|
89
|
+
cancellationPolicyLabel?: string;
|
|
90
|
+
}
|
|
91
|
+
interface OfferLabels {
|
|
92
|
+
/** Cartão lateral "Booking Total". */
|
|
93
|
+
bookingTotal?: string;
|
|
94
|
+
/** Header "Available optionals". */
|
|
95
|
+
availableOptionals?: string;
|
|
96
|
+
/** Botão "Remove" do card de adventure. */
|
|
97
|
+
remove?: string;
|
|
98
|
+
/** Sumário "Summary". */
|
|
99
|
+
summary?: string;
|
|
100
|
+
/** "Subtotal". */
|
|
101
|
+
subtotal?: string;
|
|
102
|
+
/** "Total". */
|
|
103
|
+
total?: string;
|
|
104
|
+
/** "Remaining balance". */
|
|
105
|
+
remainingBalance?: string;
|
|
106
|
+
/** "Balance due". */
|
|
107
|
+
balanceDue?: string;
|
|
108
|
+
/** Card do agente "Need help with your offer?". */
|
|
109
|
+
needHelp?: string;
|
|
110
|
+
/** Header de seção "Included Adventures". */
|
|
111
|
+
includedAdventures?: string;
|
|
112
|
+
/** Header `PaymentMethodSelector` quando renderizado pelo wizard interno. */
|
|
113
|
+
paymentMethod?: string;
|
|
114
|
+
/** `BookingConfirmedCard.title` quando renderizado pelo wizard interno. */
|
|
115
|
+
bookingConfirmed?: string;
|
|
116
|
+
/** Steps do wizard interno. */
|
|
117
|
+
wizardSteps?: {
|
|
118
|
+
responsible?: string;
|
|
119
|
+
travellers?: string;
|
|
120
|
+
paymentAndTerms?: string;
|
|
121
|
+
};
|
|
122
|
+
/** Botão "Pay deposit". */
|
|
123
|
+
payDeposit?: string;
|
|
124
|
+
/** Wizard: badges "Adult" / "Child". */
|
|
125
|
+
adultLabel?: string;
|
|
126
|
+
childLabel?: string;
|
|
84
127
|
}
|
|
85
128
|
interface OfferDepositInfo {
|
|
86
129
|
depositPercent: number;
|
|
@@ -125,6 +168,8 @@ interface OfferProps {
|
|
|
125
168
|
};
|
|
126
169
|
/** Disable the primary continue button. */
|
|
127
170
|
continueDisabled?: boolean;
|
|
171
|
+
/** Overrides i18n para labels hardcoded no componente. */
|
|
172
|
+
labels?: OfferLabels;
|
|
128
173
|
className?: string;
|
|
129
174
|
}
|
|
130
175
|
interface BookingShellProps {
|
|
@@ -198,7 +243,7 @@ declare function BookingConfirmedCard({ title, email, message, onBack, backLabel
|
|
|
198
243
|
declare function OfferAdventureCard({ adventure }: {
|
|
199
244
|
adventure: OfferAdventureItem;
|
|
200
245
|
}): react_jsx_runtime.JSX.Element;
|
|
201
|
-
declare function Offer({ logo, logoAlt, title, subtitle, adventures, subtotal, total, depositInfo, agent, onContinue, continueLabel, externalBookingFlow, checkoutSlot, summaryNotesSlot, summaryDiscountLine, continueDisabled, className, }: OfferProps): react_jsx_runtime.JSX.Element;
|
|
246
|
+
declare function Offer({ logo, logoAlt, title, subtitle, adventures, subtotal, total, depositInfo, agent, onContinue, continueLabel, externalBookingFlow, checkoutSlot, summaryNotesSlot, summaryDiscountLine, continueDisabled, labels, className, }: OfferProps): react_jsx_runtime.JSX.Element;
|
|
202
247
|
|
|
203
248
|
type BookingStatus = "pending" | "confirmed" | "cancelled" | "completed" | "pendingRegistration" | "pendingPayment" | "pendingPaymentOverdue" | "complete";
|
|
204
249
|
interface BookingTraveller {
|
|
@@ -261,6 +306,59 @@ interface TravellerFormConfig {
|
|
|
261
306
|
childEmailFromContact?: string;
|
|
262
307
|
labels?: TravellerFormLabels;
|
|
263
308
|
}
|
|
309
|
+
interface BookingDetailsLabels {
|
|
310
|
+
/** "Created on {date}" — render em sub-header. */
|
|
311
|
+
createdOn?: (date: string) => string;
|
|
312
|
+
/** Header InfoCard "CONTACT". */
|
|
313
|
+
contactInfo?: string;
|
|
314
|
+
/** Header InfoCard "TOTAL PEOPLE". */
|
|
315
|
+
totalPeople?: string;
|
|
316
|
+
/** "{count} person(s)" (ICU plural). */
|
|
317
|
+
personCount?: (count: number) => string;
|
|
318
|
+
/** "Adults: {n}", "Children: {n}", "Seniors: {n}". */
|
|
319
|
+
peopleBreakdown?: {
|
|
320
|
+
adults?: (n: number) => string;
|
|
321
|
+
children?: (n: number) => string;
|
|
322
|
+
seniors?: (n: number) => string;
|
|
323
|
+
};
|
|
324
|
+
/** "Adventures ({count})" — header de seção. */
|
|
325
|
+
adventuresSection?: (count: number) => string;
|
|
326
|
+
/** "Travellers" — header de cada AdventureSection. */
|
|
327
|
+
travellersSection?: string;
|
|
328
|
+
/** Botão "Add contact as traveller" / "Add contact". */
|
|
329
|
+
addContactAsTraveller?: string;
|
|
330
|
+
addContactAsTravellerShort?: string;
|
|
331
|
+
/** Badge inline "Child". */
|
|
332
|
+
childBadge?: string;
|
|
333
|
+
/** Status do traveller (mostrado como badge). */
|
|
334
|
+
travellerStatusCompleted?: string;
|
|
335
|
+
travellerStatusPending?: string;
|
|
336
|
+
/** Link "Open" do form URL. */
|
|
337
|
+
openFormLink?: string;
|
|
338
|
+
/** aria-label "Copy form URL". */
|
|
339
|
+
copyFormUrlAria?: string;
|
|
340
|
+
/** aria-labels com placeholder {name}. */
|
|
341
|
+
editTravellerAria?: (name: string) => string;
|
|
342
|
+
deleteTravellerAria?: (name: string) => string;
|
|
343
|
+
removeFromAdventureAria?: (name: string) => string;
|
|
344
|
+
/** Header de sugestões: "Add to this adventure". */
|
|
345
|
+
addToThisAdventure?: string;
|
|
346
|
+
/** "{completed} of {total} travellers registered" (ICU). */
|
|
347
|
+
travellersRegistered?: (args: {
|
|
348
|
+
completed: number;
|
|
349
|
+
total: number;
|
|
350
|
+
}) => string;
|
|
351
|
+
/** Header h3 do OrderSummary: "Order Summary". */
|
|
352
|
+
orderSummary?: string;
|
|
353
|
+
/** Linha por aventura: "Subtotal this adventure". */
|
|
354
|
+
subtotalThisAdventure?: string;
|
|
355
|
+
/** Linha global: "Subtotal". */
|
|
356
|
+
subtotal?: string;
|
|
357
|
+
/** Linha total: "Total". */
|
|
358
|
+
total?: string;
|
|
359
|
+
/** Linha do bloco depósito: "Remaining balance". */
|
|
360
|
+
remainingBalance?: string;
|
|
361
|
+
}
|
|
264
362
|
interface SuggestedTraveller {
|
|
265
363
|
id: string;
|
|
266
364
|
firstName: string;
|
|
@@ -436,9 +534,11 @@ interface BookingDetailsProps {
|
|
|
436
534
|
onSignOut?: () => void;
|
|
437
535
|
/** Texto do botão de Sign Out. Default: "Sign out". */
|
|
438
536
|
signOutLabel?: string;
|
|
537
|
+
/** Overrides i18n para labels hardcoded no componente. */
|
|
538
|
+
labels?: BookingDetailsLabels;
|
|
439
539
|
className?: string;
|
|
440
540
|
}
|
|
441
|
-
declare function BookingDetails({ bookingId, status, statusLabel, createdAt, contact, agent, agentName, agentContactUrl, agentNameFallback, agentLabel, agentContactLabel, contactSectionLabel, payBalanceLabel, balanceDueLabel, totalPaidLabel, cannotRemoveLastTravellerLabel, adventures, summaryLineItems, subtotal, total, depositInfo, onAddContactAsTraveller, onEditTraveller, onRemoveTraveller, onAddSuggestedTraveller, onAddTraveller, onUnassignFromAdventure, onCopyFormLink, onSubmitAddTraveller, onSubmitEditTraveller, onConfirmRemoveTraveller, travellerFormConfig, addTravellerSaving, editTravellerSaving, removeTravellerSaving, travellerFormError, onPayBalance, onCancelRequest, logoSrc, logoAlt, onSignOut, signOutLabel, className, }: BookingDetailsProps): react_jsx_runtime.JSX.Element;
|
|
541
|
+
declare function BookingDetails({ bookingId, status, statusLabel, createdAt, contact, agent, agentName, agentContactUrl, agentNameFallback, agentLabel, agentContactLabel, contactSectionLabel, payBalanceLabel, balanceDueLabel, totalPaidLabel, cannotRemoveLastTravellerLabel, adventures, summaryLineItems, subtotal, total, depositInfo, onAddContactAsTraveller, onEditTraveller, onRemoveTraveller, onAddSuggestedTraveller, onAddTraveller, onUnassignFromAdventure, onCopyFormLink, onSubmitAddTraveller, onSubmitEditTraveller, onConfirmRemoveTraveller, travellerFormConfig, addTravellerSaving, editTravellerSaving, removeTravellerSaving, travellerFormError, onPayBalance, onCancelRequest, logoSrc, logoAlt, onSignOut, signOutLabel, labels, className, }: BookingDetailsProps): react_jsx_runtime.JSX.Element;
|
|
442
542
|
|
|
443
543
|
interface AgentContactCardProps {
|
|
444
544
|
layout: "compact" | "wide";
|
package/dist/index.d.ts
CHANGED
|
@@ -81,6 +81,49 @@ interface OfferAdventureItem {
|
|
|
81
81
|
detailsSlot?: React.ReactNode;
|
|
82
82
|
/** Label shown above the itinerary/detailsSlot section. Defaults to "Details". */
|
|
83
83
|
itineraryLabel?: string;
|
|
84
|
+
/** Label da seção "What's included". Default: "What's included". */
|
|
85
|
+
includedLabel?: string;
|
|
86
|
+
/** Label da seção "What's not included". Default: "What's not included". */
|
|
87
|
+
notIncludedLabel?: string;
|
|
88
|
+
/** Label da seção "Cancellation policy". Default: "Cancellation policy". */
|
|
89
|
+
cancellationPolicyLabel?: string;
|
|
90
|
+
}
|
|
91
|
+
interface OfferLabels {
|
|
92
|
+
/** Cartão lateral "Booking Total". */
|
|
93
|
+
bookingTotal?: string;
|
|
94
|
+
/** Header "Available optionals". */
|
|
95
|
+
availableOptionals?: string;
|
|
96
|
+
/** Botão "Remove" do card de adventure. */
|
|
97
|
+
remove?: string;
|
|
98
|
+
/** Sumário "Summary". */
|
|
99
|
+
summary?: string;
|
|
100
|
+
/** "Subtotal". */
|
|
101
|
+
subtotal?: string;
|
|
102
|
+
/** "Total". */
|
|
103
|
+
total?: string;
|
|
104
|
+
/** "Remaining balance". */
|
|
105
|
+
remainingBalance?: string;
|
|
106
|
+
/** "Balance due". */
|
|
107
|
+
balanceDue?: string;
|
|
108
|
+
/** Card do agente "Need help with your offer?". */
|
|
109
|
+
needHelp?: string;
|
|
110
|
+
/** Header de seção "Included Adventures". */
|
|
111
|
+
includedAdventures?: string;
|
|
112
|
+
/** Header `PaymentMethodSelector` quando renderizado pelo wizard interno. */
|
|
113
|
+
paymentMethod?: string;
|
|
114
|
+
/** `BookingConfirmedCard.title` quando renderizado pelo wizard interno. */
|
|
115
|
+
bookingConfirmed?: string;
|
|
116
|
+
/** Steps do wizard interno. */
|
|
117
|
+
wizardSteps?: {
|
|
118
|
+
responsible?: string;
|
|
119
|
+
travellers?: string;
|
|
120
|
+
paymentAndTerms?: string;
|
|
121
|
+
};
|
|
122
|
+
/** Botão "Pay deposit". */
|
|
123
|
+
payDeposit?: string;
|
|
124
|
+
/** Wizard: badges "Adult" / "Child". */
|
|
125
|
+
adultLabel?: string;
|
|
126
|
+
childLabel?: string;
|
|
84
127
|
}
|
|
85
128
|
interface OfferDepositInfo {
|
|
86
129
|
depositPercent: number;
|
|
@@ -125,6 +168,8 @@ interface OfferProps {
|
|
|
125
168
|
};
|
|
126
169
|
/** Disable the primary continue button. */
|
|
127
170
|
continueDisabled?: boolean;
|
|
171
|
+
/** Overrides i18n para labels hardcoded no componente. */
|
|
172
|
+
labels?: OfferLabels;
|
|
128
173
|
className?: string;
|
|
129
174
|
}
|
|
130
175
|
interface BookingShellProps {
|
|
@@ -198,7 +243,7 @@ declare function BookingConfirmedCard({ title, email, message, onBack, backLabel
|
|
|
198
243
|
declare function OfferAdventureCard({ adventure }: {
|
|
199
244
|
adventure: OfferAdventureItem;
|
|
200
245
|
}): react_jsx_runtime.JSX.Element;
|
|
201
|
-
declare function Offer({ logo, logoAlt, title, subtitle, adventures, subtotal, total, depositInfo, agent, onContinue, continueLabel, externalBookingFlow, checkoutSlot, summaryNotesSlot, summaryDiscountLine, continueDisabled, className, }: OfferProps): react_jsx_runtime.JSX.Element;
|
|
246
|
+
declare function Offer({ logo, logoAlt, title, subtitle, adventures, subtotal, total, depositInfo, agent, onContinue, continueLabel, externalBookingFlow, checkoutSlot, summaryNotesSlot, summaryDiscountLine, continueDisabled, labels, className, }: OfferProps): react_jsx_runtime.JSX.Element;
|
|
202
247
|
|
|
203
248
|
type BookingStatus = "pending" | "confirmed" | "cancelled" | "completed" | "pendingRegistration" | "pendingPayment" | "pendingPaymentOverdue" | "complete";
|
|
204
249
|
interface BookingTraveller {
|
|
@@ -261,6 +306,59 @@ interface TravellerFormConfig {
|
|
|
261
306
|
childEmailFromContact?: string;
|
|
262
307
|
labels?: TravellerFormLabels;
|
|
263
308
|
}
|
|
309
|
+
interface BookingDetailsLabels {
|
|
310
|
+
/** "Created on {date}" — render em sub-header. */
|
|
311
|
+
createdOn?: (date: string) => string;
|
|
312
|
+
/** Header InfoCard "CONTACT". */
|
|
313
|
+
contactInfo?: string;
|
|
314
|
+
/** Header InfoCard "TOTAL PEOPLE". */
|
|
315
|
+
totalPeople?: string;
|
|
316
|
+
/** "{count} person(s)" (ICU plural). */
|
|
317
|
+
personCount?: (count: number) => string;
|
|
318
|
+
/** "Adults: {n}", "Children: {n}", "Seniors: {n}". */
|
|
319
|
+
peopleBreakdown?: {
|
|
320
|
+
adults?: (n: number) => string;
|
|
321
|
+
children?: (n: number) => string;
|
|
322
|
+
seniors?: (n: number) => string;
|
|
323
|
+
};
|
|
324
|
+
/** "Adventures ({count})" — header de seção. */
|
|
325
|
+
adventuresSection?: (count: number) => string;
|
|
326
|
+
/** "Travellers" — header de cada AdventureSection. */
|
|
327
|
+
travellersSection?: string;
|
|
328
|
+
/** Botão "Add contact as traveller" / "Add contact". */
|
|
329
|
+
addContactAsTraveller?: string;
|
|
330
|
+
addContactAsTravellerShort?: string;
|
|
331
|
+
/** Badge inline "Child". */
|
|
332
|
+
childBadge?: string;
|
|
333
|
+
/** Status do traveller (mostrado como badge). */
|
|
334
|
+
travellerStatusCompleted?: string;
|
|
335
|
+
travellerStatusPending?: string;
|
|
336
|
+
/** Link "Open" do form URL. */
|
|
337
|
+
openFormLink?: string;
|
|
338
|
+
/** aria-label "Copy form URL". */
|
|
339
|
+
copyFormUrlAria?: string;
|
|
340
|
+
/** aria-labels com placeholder {name}. */
|
|
341
|
+
editTravellerAria?: (name: string) => string;
|
|
342
|
+
deleteTravellerAria?: (name: string) => string;
|
|
343
|
+
removeFromAdventureAria?: (name: string) => string;
|
|
344
|
+
/** Header de sugestões: "Add to this adventure". */
|
|
345
|
+
addToThisAdventure?: string;
|
|
346
|
+
/** "{completed} of {total} travellers registered" (ICU). */
|
|
347
|
+
travellersRegistered?: (args: {
|
|
348
|
+
completed: number;
|
|
349
|
+
total: number;
|
|
350
|
+
}) => string;
|
|
351
|
+
/** Header h3 do OrderSummary: "Order Summary". */
|
|
352
|
+
orderSummary?: string;
|
|
353
|
+
/** Linha por aventura: "Subtotal this adventure". */
|
|
354
|
+
subtotalThisAdventure?: string;
|
|
355
|
+
/** Linha global: "Subtotal". */
|
|
356
|
+
subtotal?: string;
|
|
357
|
+
/** Linha total: "Total". */
|
|
358
|
+
total?: string;
|
|
359
|
+
/** Linha do bloco depósito: "Remaining balance". */
|
|
360
|
+
remainingBalance?: string;
|
|
361
|
+
}
|
|
264
362
|
interface SuggestedTraveller {
|
|
265
363
|
id: string;
|
|
266
364
|
firstName: string;
|
|
@@ -436,9 +534,11 @@ interface BookingDetailsProps {
|
|
|
436
534
|
onSignOut?: () => void;
|
|
437
535
|
/** Texto do botão de Sign Out. Default: "Sign out". */
|
|
438
536
|
signOutLabel?: string;
|
|
537
|
+
/** Overrides i18n para labels hardcoded no componente. */
|
|
538
|
+
labels?: BookingDetailsLabels;
|
|
439
539
|
className?: string;
|
|
440
540
|
}
|
|
441
|
-
declare function BookingDetails({ bookingId, status, statusLabel, createdAt, contact, agent, agentName, agentContactUrl, agentNameFallback, agentLabel, agentContactLabel, contactSectionLabel, payBalanceLabel, balanceDueLabel, totalPaidLabel, cannotRemoveLastTravellerLabel, adventures, summaryLineItems, subtotal, total, depositInfo, onAddContactAsTraveller, onEditTraveller, onRemoveTraveller, onAddSuggestedTraveller, onAddTraveller, onUnassignFromAdventure, onCopyFormLink, onSubmitAddTraveller, onSubmitEditTraveller, onConfirmRemoveTraveller, travellerFormConfig, addTravellerSaving, editTravellerSaving, removeTravellerSaving, travellerFormError, onPayBalance, onCancelRequest, logoSrc, logoAlt, onSignOut, signOutLabel, className, }: BookingDetailsProps): react_jsx_runtime.JSX.Element;
|
|
541
|
+
declare function BookingDetails({ bookingId, status, statusLabel, createdAt, contact, agent, agentName, agentContactUrl, agentNameFallback, agentLabel, agentContactLabel, contactSectionLabel, payBalanceLabel, balanceDueLabel, totalPaidLabel, cannotRemoveLastTravellerLabel, adventures, summaryLineItems, subtotal, total, depositInfo, onAddContactAsTraveller, onEditTraveller, onRemoveTraveller, onAddSuggestedTraveller, onAddTraveller, onUnassignFromAdventure, onCopyFormLink, onSubmitAddTraveller, onSubmitEditTraveller, onConfirmRemoveTraveller, travellerFormConfig, addTravellerSaving, editTravellerSaving, removeTravellerSaving, travellerFormError, onPayBalance, onCancelRequest, logoSrc, logoAlt, onSignOut, signOutLabel, labels, className, }: BookingDetailsProps): react_jsx_runtime.JSX.Element;
|
|
442
542
|
|
|
443
543
|
interface AgentContactCardProps {
|
|
444
544
|
layout: "compact" | "wide";
|