@planetaexo/design-system 0.14.2 → 0.15.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 +106 -72
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +91 -1
- package/dist/index.d.ts +91 -1
- package/dist/index.js +106 -72
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -124,6 +124,57 @@ interface OfferLabels {
|
|
|
124
124
|
/** Wizard: badges "Adult" / "Child". */
|
|
125
125
|
adultLabel?: string;
|
|
126
126
|
childLabel?: string;
|
|
127
|
+
/**
|
|
128
|
+
* Template para o texto "Contact {name} your travel advisor" do AgentContactCard
|
|
129
|
+
* variant `wide`. Quando ausente, usa default EN.
|
|
130
|
+
*/
|
|
131
|
+
agentContactTemplate?: (name: string) => React.ReactNode;
|
|
132
|
+
/**
|
|
133
|
+
* Template para a label do depósito "Deposit ({percent}%)". Default EN.
|
|
134
|
+
*/
|
|
135
|
+
depositLabel?: (percent: number) => string;
|
|
136
|
+
/**
|
|
137
|
+
* Mensagem do `BookingConfirmedCard` ("A confirmation email has been sent...").
|
|
138
|
+
* Pode ser nó React direto ou função recebendo o e-mail do cliente.
|
|
139
|
+
*/
|
|
140
|
+
bookingConfirmedMessage?: React.ReactNode | ((args: {
|
|
141
|
+
email: string;
|
|
142
|
+
}) => React.ReactNode);
|
|
143
|
+
/**
|
|
144
|
+
* Strings do BookingWizard interno (renderizado quando `checkoutSlot` é
|
|
145
|
+
* undefined — em produção do bookings esse caminho é ofuscado, mas
|
|
146
|
+
* mantemos os labels para evitar dívida latente).
|
|
147
|
+
*/
|
|
148
|
+
wizard?: {
|
|
149
|
+
confirmBookingLabel?: string;
|
|
150
|
+
nextLabel?: string;
|
|
151
|
+
backLabel?: string;
|
|
152
|
+
cancelLabel?: string;
|
|
153
|
+
step1Description?: string;
|
|
154
|
+
step2Heading?: string;
|
|
155
|
+
step2TravellerCard?: (n: number) => string;
|
|
156
|
+
step3Description?: string;
|
|
157
|
+
fields?: {
|
|
158
|
+
dateOfBirth?: string;
|
|
159
|
+
email?: string;
|
|
160
|
+
phone?: string;
|
|
161
|
+
notesOptional?: string;
|
|
162
|
+
};
|
|
163
|
+
paymentMethods?: {
|
|
164
|
+
creditCard?: {
|
|
165
|
+
label?: string;
|
|
166
|
+
description?: string;
|
|
167
|
+
};
|
|
168
|
+
pix?: {
|
|
169
|
+
label?: string;
|
|
170
|
+
description?: string;
|
|
171
|
+
};
|
|
172
|
+
bankTransfer?: {
|
|
173
|
+
label?: string;
|
|
174
|
+
description?: string;
|
|
175
|
+
};
|
|
176
|
+
};
|
|
177
|
+
};
|
|
127
178
|
}
|
|
128
179
|
interface OfferDepositInfo {
|
|
129
180
|
depositPercent: number;
|
|
@@ -358,6 +409,26 @@ interface BookingDetailsLabels {
|
|
|
358
409
|
total?: string;
|
|
359
410
|
/** Linha do bloco depósito: "Remaining balance". */
|
|
360
411
|
remainingBalance?: string;
|
|
412
|
+
/** Labels das linhas do card "Booking Person" / "Responsible Person". */
|
|
413
|
+
contactDetailsFields?: {
|
|
414
|
+
name?: string;
|
|
415
|
+
email?: string;
|
|
416
|
+
phone?: string;
|
|
417
|
+
country?: string;
|
|
418
|
+
/** Default EN: "Passport / ID". Atualmente o componente exibia "Passport / CPF" (PT-BR fixo). */
|
|
419
|
+
document?: string;
|
|
420
|
+
};
|
|
421
|
+
/** Headers das seções do accordion de cada aventura (atualmente PT-BR fixo). */
|
|
422
|
+
adventureSections?: {
|
|
423
|
+
/** Default EN: "What's included". */
|
|
424
|
+
included?: string;
|
|
425
|
+
/** Default EN: "What's not included". */
|
|
426
|
+
notIncluded?: string;
|
|
427
|
+
/** Default EN: "Cancellation policy". */
|
|
428
|
+
cancellationPolicy?: string;
|
|
429
|
+
};
|
|
430
|
+
/** Botão "Request cancellation" no fim do card. Default EN. */
|
|
431
|
+
cancelRequestLabel?: string;
|
|
361
432
|
}
|
|
362
433
|
interface SuggestedTraveller {
|
|
363
434
|
id: string;
|
|
@@ -556,6 +627,10 @@ interface AgentContactCardProps {
|
|
|
556
627
|
legacyContactLabel?: string;
|
|
557
628
|
/** Texto adicional descritivo (ex.: "your travel advisor"). Usado em `wide`. */
|
|
558
629
|
helperText?: string;
|
|
630
|
+
/** Label do botão WhatsApp na variant `wide`. Default EN: "WhatsApp". */
|
|
631
|
+
whatsappLabel?: string;
|
|
632
|
+
/** Label do botão Email na variant `wide`. Default EN: "Email". */
|
|
633
|
+
emailLabel?: string;
|
|
559
634
|
className?: string;
|
|
560
635
|
}
|
|
561
636
|
declare function AgentContactCard(props: AgentContactCardProps): react_jsx_runtime.JSX.Element;
|
|
@@ -887,6 +962,14 @@ interface RegistrationFormLabels {
|
|
|
887
962
|
selectPlaceholder?: string;
|
|
888
963
|
optionalLabel?: string;
|
|
889
964
|
requiredFieldError?: string;
|
|
965
|
+
/** "Date" — usado no bloco TripInfo quando há apenas data inicial. */
|
|
966
|
+
dateLabel?: string;
|
|
967
|
+
/** "Dates" — usado no bloco TripInfo quando há range. */
|
|
968
|
+
datesLabel?: string;
|
|
969
|
+
/** "Yes" — usado em `defaultFormatAnswer` para campos boolean. */
|
|
970
|
+
yesLabel?: string;
|
|
971
|
+
/** "No" — usado em `defaultFormatAnswer` para campos boolean. */
|
|
972
|
+
noLabel?: string;
|
|
890
973
|
}
|
|
891
974
|
interface RegistrationFormProps {
|
|
892
975
|
/** Logo shown above the title. Defaults to "/logo-planetaexo.png" (matching Offer). Pass null to hide. */
|
|
@@ -995,8 +1078,15 @@ interface RegistrationSuccessCardProps {
|
|
|
995
1078
|
submittedAt?: string;
|
|
996
1079
|
lastUpdatedAt?: string;
|
|
997
1080
|
};
|
|
1081
|
+
/**
|
|
1082
|
+
* Overrides para labels compartilhados com `RegistrationForm` — usado nesse
|
|
1083
|
+
* card para `dateLabel`/`datesLabel` (linha "Date(s)" do TripInfo) e
|
|
1084
|
+
* `yesLabel`/`noLabel` (formatação default de respostas booleanas). Outros
|
|
1085
|
+
* campos da interface são ignorados aqui.
|
|
1086
|
+
*/
|
|
1087
|
+
labels?: RegistrationFormLabels;
|
|
998
1088
|
}
|
|
999
|
-
declare function RegistrationSuccessCard({ variant, title, message, answersTitle, fields, answers, dateFormatter, formatAnswer, className, actions, logo, logoAlt, terms, termsLayout, termsLabels, adventure, booking, traveller, tripInfoLabels, density, submissionTimestamps, submissionTimestampsLabels, }: RegistrationSuccessCardProps): react_jsx_runtime.JSX.Element;
|
|
1089
|
+
declare function RegistrationSuccessCard({ variant, title, message, answersTitle, fields, answers, dateFormatter, formatAnswer, className, actions, logo, logoAlt, terms, termsLayout, termsLabels, adventure, booking, traveller, tripInfoLabels, density, submissionTimestamps, submissionTimestampsLabels, labels: scLabels, }: RegistrationSuccessCardProps): react_jsx_runtime.JSX.Element;
|
|
1000
1090
|
|
|
1001
1091
|
interface FloatingInputProps extends React.InputHTMLAttributes<HTMLInputElement> {
|
|
1002
1092
|
label: string;
|
package/dist/index.d.ts
CHANGED
|
@@ -124,6 +124,57 @@ interface OfferLabels {
|
|
|
124
124
|
/** Wizard: badges "Adult" / "Child". */
|
|
125
125
|
adultLabel?: string;
|
|
126
126
|
childLabel?: string;
|
|
127
|
+
/**
|
|
128
|
+
* Template para o texto "Contact {name} your travel advisor" do AgentContactCard
|
|
129
|
+
* variant `wide`. Quando ausente, usa default EN.
|
|
130
|
+
*/
|
|
131
|
+
agentContactTemplate?: (name: string) => React.ReactNode;
|
|
132
|
+
/**
|
|
133
|
+
* Template para a label do depósito "Deposit ({percent}%)". Default EN.
|
|
134
|
+
*/
|
|
135
|
+
depositLabel?: (percent: number) => string;
|
|
136
|
+
/**
|
|
137
|
+
* Mensagem do `BookingConfirmedCard` ("A confirmation email has been sent...").
|
|
138
|
+
* Pode ser nó React direto ou função recebendo o e-mail do cliente.
|
|
139
|
+
*/
|
|
140
|
+
bookingConfirmedMessage?: React.ReactNode | ((args: {
|
|
141
|
+
email: string;
|
|
142
|
+
}) => React.ReactNode);
|
|
143
|
+
/**
|
|
144
|
+
* Strings do BookingWizard interno (renderizado quando `checkoutSlot` é
|
|
145
|
+
* undefined — em produção do bookings esse caminho é ofuscado, mas
|
|
146
|
+
* mantemos os labels para evitar dívida latente).
|
|
147
|
+
*/
|
|
148
|
+
wizard?: {
|
|
149
|
+
confirmBookingLabel?: string;
|
|
150
|
+
nextLabel?: string;
|
|
151
|
+
backLabel?: string;
|
|
152
|
+
cancelLabel?: string;
|
|
153
|
+
step1Description?: string;
|
|
154
|
+
step2Heading?: string;
|
|
155
|
+
step2TravellerCard?: (n: number) => string;
|
|
156
|
+
step3Description?: string;
|
|
157
|
+
fields?: {
|
|
158
|
+
dateOfBirth?: string;
|
|
159
|
+
email?: string;
|
|
160
|
+
phone?: string;
|
|
161
|
+
notesOptional?: string;
|
|
162
|
+
};
|
|
163
|
+
paymentMethods?: {
|
|
164
|
+
creditCard?: {
|
|
165
|
+
label?: string;
|
|
166
|
+
description?: string;
|
|
167
|
+
};
|
|
168
|
+
pix?: {
|
|
169
|
+
label?: string;
|
|
170
|
+
description?: string;
|
|
171
|
+
};
|
|
172
|
+
bankTransfer?: {
|
|
173
|
+
label?: string;
|
|
174
|
+
description?: string;
|
|
175
|
+
};
|
|
176
|
+
};
|
|
177
|
+
};
|
|
127
178
|
}
|
|
128
179
|
interface OfferDepositInfo {
|
|
129
180
|
depositPercent: number;
|
|
@@ -358,6 +409,26 @@ interface BookingDetailsLabels {
|
|
|
358
409
|
total?: string;
|
|
359
410
|
/** Linha do bloco depósito: "Remaining balance". */
|
|
360
411
|
remainingBalance?: string;
|
|
412
|
+
/** Labels das linhas do card "Booking Person" / "Responsible Person". */
|
|
413
|
+
contactDetailsFields?: {
|
|
414
|
+
name?: string;
|
|
415
|
+
email?: string;
|
|
416
|
+
phone?: string;
|
|
417
|
+
country?: string;
|
|
418
|
+
/** Default EN: "Passport / ID". Atualmente o componente exibia "Passport / CPF" (PT-BR fixo). */
|
|
419
|
+
document?: string;
|
|
420
|
+
};
|
|
421
|
+
/** Headers das seções do accordion de cada aventura (atualmente PT-BR fixo). */
|
|
422
|
+
adventureSections?: {
|
|
423
|
+
/** Default EN: "What's included". */
|
|
424
|
+
included?: string;
|
|
425
|
+
/** Default EN: "What's not included". */
|
|
426
|
+
notIncluded?: string;
|
|
427
|
+
/** Default EN: "Cancellation policy". */
|
|
428
|
+
cancellationPolicy?: string;
|
|
429
|
+
};
|
|
430
|
+
/** Botão "Request cancellation" no fim do card. Default EN. */
|
|
431
|
+
cancelRequestLabel?: string;
|
|
361
432
|
}
|
|
362
433
|
interface SuggestedTraveller {
|
|
363
434
|
id: string;
|
|
@@ -556,6 +627,10 @@ interface AgentContactCardProps {
|
|
|
556
627
|
legacyContactLabel?: string;
|
|
557
628
|
/** Texto adicional descritivo (ex.: "your travel advisor"). Usado em `wide`. */
|
|
558
629
|
helperText?: string;
|
|
630
|
+
/** Label do botão WhatsApp na variant `wide`. Default EN: "WhatsApp". */
|
|
631
|
+
whatsappLabel?: string;
|
|
632
|
+
/** Label do botão Email na variant `wide`. Default EN: "Email". */
|
|
633
|
+
emailLabel?: string;
|
|
559
634
|
className?: string;
|
|
560
635
|
}
|
|
561
636
|
declare function AgentContactCard(props: AgentContactCardProps): react_jsx_runtime.JSX.Element;
|
|
@@ -887,6 +962,14 @@ interface RegistrationFormLabels {
|
|
|
887
962
|
selectPlaceholder?: string;
|
|
888
963
|
optionalLabel?: string;
|
|
889
964
|
requiredFieldError?: string;
|
|
965
|
+
/** "Date" — usado no bloco TripInfo quando há apenas data inicial. */
|
|
966
|
+
dateLabel?: string;
|
|
967
|
+
/** "Dates" — usado no bloco TripInfo quando há range. */
|
|
968
|
+
datesLabel?: string;
|
|
969
|
+
/** "Yes" — usado em `defaultFormatAnswer` para campos boolean. */
|
|
970
|
+
yesLabel?: string;
|
|
971
|
+
/** "No" — usado em `defaultFormatAnswer` para campos boolean. */
|
|
972
|
+
noLabel?: string;
|
|
890
973
|
}
|
|
891
974
|
interface RegistrationFormProps {
|
|
892
975
|
/** Logo shown above the title. Defaults to "/logo-planetaexo.png" (matching Offer). Pass null to hide. */
|
|
@@ -995,8 +1078,15 @@ interface RegistrationSuccessCardProps {
|
|
|
995
1078
|
submittedAt?: string;
|
|
996
1079
|
lastUpdatedAt?: string;
|
|
997
1080
|
};
|
|
1081
|
+
/**
|
|
1082
|
+
* Overrides para labels compartilhados com `RegistrationForm` — usado nesse
|
|
1083
|
+
* card para `dateLabel`/`datesLabel` (linha "Date(s)" do TripInfo) e
|
|
1084
|
+
* `yesLabel`/`noLabel` (formatação default de respostas booleanas). Outros
|
|
1085
|
+
* campos da interface são ignorados aqui.
|
|
1086
|
+
*/
|
|
1087
|
+
labels?: RegistrationFormLabels;
|
|
998
1088
|
}
|
|
999
|
-
declare function RegistrationSuccessCard({ variant, title, message, answersTitle, fields, answers, dateFormatter, formatAnswer, className, actions, logo, logoAlt, terms, termsLayout, termsLabels, adventure, booking, traveller, tripInfoLabels, density, submissionTimestamps, submissionTimestampsLabels, }: RegistrationSuccessCardProps): react_jsx_runtime.JSX.Element;
|
|
1089
|
+
declare function RegistrationSuccessCard({ variant, title, message, answersTitle, fields, answers, dateFormatter, formatAnswer, className, actions, logo, logoAlt, terms, termsLayout, termsLabels, adventure, booking, traveller, tripInfoLabels, density, submissionTimestamps, submissionTimestampsLabels, labels: scLabels, }: RegistrationSuccessCardProps): react_jsx_runtime.JSX.Element;
|
|
1000
1090
|
|
|
1001
1091
|
interface FloatingInputProps extends React.InputHTMLAttributes<HTMLInputElement> {
|
|
1002
1092
|
label: string;
|