@tesouro/embedded-components-react 0.7.34 → 0.7.36
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/README.md +10 -8
- package/dist/index.d.ts +31 -32
- package/dist/index.js +5 -5
- package/dist/lib/CounterpartsWidget.d.ts +0 -1
- package/dist/lib/CounterpartsWidgetPublic.d.ts +0 -1
- package/dist/lib/CustomersWidget.d.ts +0 -1
- package/dist/lib/{MarketingWidget.d.ts → OfferWidget.d.ts} +31 -31
- package/dist/lib/OfferWidget.js +6 -0
- package/dist/lib/ReceivablesWidget.d.ts +0 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index33.js +109 -110
- package/dist/libs/tesouro-embedded-components-react/counterparts-widget/feature/dist/lib/CounterpartsWidget/CounterpartDetailsPanel.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/counterparts-widget/feature/dist/lib/CounterpartsWidget/useCounterpartsTable.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/lib/ReceivablesWidget/useReceivableForm.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/offer-widget/feature/dist/index.js +5 -0
- package/dist/libs/tesouro-embedded-components-react/{marketing-widget/feature/dist/lib/MarketingWidget/MarketingWidget.js → offer-widget/feature/dist/lib/OfferWidget/OfferWidget.js} +11 -11
- package/dist/libs/tesouro-embedded-components-react/{marketing-widget/feature/dist/lib/MarketingWidget → offer-widget/feature/dist/lib/OfferWidget}/labels.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/{marketing-widget/feature/dist/lib/MarketingWidget/marketingApplicationView.js → offer-widget/feature/dist/lib/OfferWidget/offerApplicationView.js} +2 -2
- package/dist/libs/tesouro-embedded-components-react/offer-widget/feature/dist/lib/analytics/events.js +8 -0
- package/dist/libs/tesouro-embedded-components-react/{marketing-widget → offer-widget}/feature/dist/lib/testIds.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/{marketing-widget → offer-widget}/feature/dist/mocks/labels.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/{marketing-widget/feature/dist/mocks/marketing.js → offer-widget/feature/dist/mocks/offer.js} +3 -3
- package/dist/libs/tesouro-embedded-components-react/offer-widget/feature/dist/scenarios.js +2 -0
- package/dist/libs/tesouro-embedded-components-react/offer-widget/ui/dist/index.js +5 -0
- package/dist/libs/tesouro-embedded-components-react/offer-widget/ui/dist/index2.js +10 -0
- package/dist/libs/tesouro-embedded-components-react/{marketing-widget → offer-widget}/ui/dist/index3.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/{marketing-widget → offer-widget}/ui/dist/index4.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/{marketing-widget → offer-widget}/ui/dist/index5.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/{marketing-widget → offer-widget}/ui/dist/index6.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/{marketing-widget → offer-widget}/ui/dist/index7.js +5 -5
- package/dist/libs/tesouro-embedded-components-react/{marketing-widget → offer-widget}/ui/dist/index8.js +3 -3
- package/dist/libs/tesouro-embedded-components-react/{marketing-widget → offer-widget}/ui/dist/index9.js +6 -6
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/data-access/dist/index.js +2 -4
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/data-access/dist/index4.js +89 -2
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/data-access/dist/index5.js +48 -50
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/index.js +4 -6
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/helpers.js +2 -3
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/labels.js +0 -1
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/subEntityForms.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/useAddressForm.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/useCounterpartDetails.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/useCounterpartForm.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/useDeleteController.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/usePayableAchInstructions.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index.js +3 -6
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index11.js +48 -7
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index12.js +4 -48
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index13.js +28 -6
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/widget-suite/feature/dist/mocks/widgetSuite.js +2 -2
- package/dist/scenarios/index.d.ts +2 -2
- package/dist/scenarios/index.js +3 -3
- package/package.json +1 -1
- package/dist/lib/MarketingWidget.js +0 -6
- package/dist/libs/tesouro-embedded-components-react/marketing-widget/feature/dist/index.js +0 -5
- package/dist/libs/tesouro-embedded-components-react/marketing-widget/feature/dist/lib/analytics/events.js +0 -8
- package/dist/libs/tesouro-embedded-components-react/marketing-widget/feature/dist/scenarios.js +0 -2
- package/dist/libs/tesouro-embedded-components-react/marketing-widget/ui/dist/index.js +0 -5
- package/dist/libs/tesouro-embedded-components-react/marketing-widget/ui/dist/index2.js +0 -10
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/data-access/dist/index6.js +0 -7
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/data-access/dist/index7.js +0 -92
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/CounterpartSelector.js +0 -7
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/useCounterpartSelector.js +0 -8
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index14.js +0 -4
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index15.js +0 -28
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index16.js +0 -4
package/README.md
CHANGED
|
@@ -444,18 +444,20 @@ Walks an applicant through bank-account onboarding: business details, personal d
|
|
|
444
444
|
| `showApplicationStatusRefresh` | `boolean` | `false` | Adds a **Check again** button to the application status card that re-reads the organization's application. Never shown over the form or result screens. |
|
|
445
445
|
| `onResultPhaseChange` | `(isInResultPhase: boolean) => void` | `undefined` | Called with `true` once the widget starts processing a submitted application, and with `false` if it unmounts after that. While `true` it keeps its processing or result screen up whatever the status read says, so leave it mounted. |
|
|
446
446
|
|
|
447
|
-
###
|
|
447
|
+
### OfferWidget
|
|
448
448
|
|
|
449
|
-
|
|
449
|
+
An offer card and modal that invites the user to apply for a product (today, a bank account) and then shows where their application stands.
|
|
450
|
+
|
|
451
|
+
The card and its "Learn more" modal present your product copy (logo, captions, "How it works" steps, benefits). Its Apply now and modal CTAs call `onPrimaryCtaClick`, which you typically wire to open `BankAccountOnboardingWidget`. Once an application exists, the card swaps its CTAs for the application's status (see Behaviour), and it hides itself when the user already has an account.
|
|
450
452
|
|
|
451
453
|
#### Props
|
|
452
454
|
|
|
453
|
-
| Prop | Type
|
|
454
|
-
| ------------------- |
|
|
455
|
-
| `content` | `
|
|
456
|
-
| `onPrimaryCtaClick` | `() => void`
|
|
457
|
-
| `labels` | `PartialDeep<
|
|
458
|
-
| `statusLabels` | `PartialDeep<
|
|
455
|
+
| Prop | Type | Default | Description |
|
|
456
|
+
| ------------------- | -------------------------------------- | -------------- | ----------------------------------------------------------------------------------------------------------------------------------- |
|
|
457
|
+
| `content` | `OfferWidgetContent` | **Required** | Host-resolved card and modal copy, images, "How it works" steps, and benefits. |
|
|
458
|
+
| `onPrimaryCtaClick` | `() => void` | **Required** | Called when the applicant clicks Apply now on the card or the modal CTA (default label: Start application). Closes the modal first. |
|
|
459
|
+
| `labels` | `PartialDeep<OfferWidgetLabels>` | English labels | Override the card and modal copy. See the exported `OfferWidgetLabels` type for every key. |
|
|
460
|
+
| `statusLabels` | `PartialDeep<OfferWidgetStatusLabels>` | English labels | Override the Resume application label and each status message. Heading and body are functions of `{ bankName }`. |
|
|
459
461
|
|
|
460
462
|
### ProductsWidget
|
|
461
463
|
|
package/dist/index.d.ts
CHANGED
|
@@ -4444,7 +4444,6 @@ interface CounterpartMessageLabels {
|
|
|
4444
4444
|
accountHolderNameRequired: string;
|
|
4445
4445
|
routingNumberInvalid: string;
|
|
4446
4446
|
accountNumberInvalid: string;
|
|
4447
|
-
vatIdValueRequired: string;
|
|
4448
4447
|
/** Shown for a non-field-specific submit failure. */
|
|
4449
4448
|
genericError: string;
|
|
4450
4449
|
/** Toasted when the list's billed/received/due analytics fail to load. */
|
|
@@ -4811,7 +4810,7 @@ type CustomersWidgetProps = WidgetProviderProps & CustomersWidgetOwnProps;
|
|
|
4811
4810
|
*/
|
|
4812
4811
|
declare function CustomersWidget({ pageSizeOptions, onViewAllDocuments, onCreateDocument, screenLabels, formLabels, detailsLabels, addressLabels, deleteLabels, messageLabels, ...widgetProviderProps }: CustomersWidgetProps): React.JSX.Element;
|
|
4813
4812
|
|
|
4814
|
-
interface
|
|
4813
|
+
interface OfferWidgetLabels {
|
|
4815
4814
|
applyNow: string;
|
|
4816
4815
|
learnMore: string;
|
|
4817
4816
|
primaryCta: string;
|
|
@@ -4819,33 +4818,33 @@ interface MarketingWidgetLabels {
|
|
|
4819
4818
|
primaryCtaSubtext: string;
|
|
4820
4819
|
dismissModalAriaLabel: string;
|
|
4821
4820
|
}
|
|
4822
|
-
declare const
|
|
4821
|
+
declare const OFFER_WIDGET_LABELS_EN: OfferWidgetLabels;
|
|
4823
4822
|
|
|
4824
|
-
interface
|
|
4823
|
+
interface OfferWidgetImage {
|
|
4825
4824
|
src: string;
|
|
4826
4825
|
alt: string;
|
|
4827
4826
|
width?: number;
|
|
4828
4827
|
}
|
|
4829
|
-
declare const
|
|
4828
|
+
declare const OfferBenefitIcon: {
|
|
4830
4829
|
readonly Sync: "sync";
|
|
4831
4830
|
readonly Users: "users";
|
|
4832
4831
|
readonly Document: "document";
|
|
4833
4832
|
readonly Dollar: "dollar";
|
|
4834
4833
|
readonly Card: "card";
|
|
4835
4834
|
};
|
|
4836
|
-
type
|
|
4837
|
-
interface
|
|
4835
|
+
type OfferBenefitIcon = (typeof OfferBenefitIcon)[keyof typeof OfferBenefitIcon];
|
|
4836
|
+
interface OfferWidgetBenefit {
|
|
4838
4837
|
text: string;
|
|
4839
|
-
icon:
|
|
4838
|
+
icon: OfferBenefitIcon;
|
|
4840
4839
|
}
|
|
4841
|
-
interface
|
|
4840
|
+
interface OfferWidgetHowItWorksStep {
|
|
4842
4841
|
/** Caller-supplied step badge text, e.g. "1" — the component never derives this from position. */
|
|
4843
4842
|
number: string;
|
|
4844
4843
|
title: string;
|
|
4845
4844
|
description: string;
|
|
4846
4845
|
}
|
|
4847
|
-
interface
|
|
4848
|
-
vspLogo:
|
|
4846
|
+
interface OfferWidgetContent {
|
|
4847
|
+
vspLogo: OfferWidgetImage;
|
|
4849
4848
|
bankingText: string;
|
|
4850
4849
|
primaryCaption: string;
|
|
4851
4850
|
secondaryCaption: string;
|
|
@@ -4856,10 +4855,10 @@ interface MarketingWidgetContent {
|
|
|
4856
4855
|
howItWorksHeader: string;
|
|
4857
4856
|
/** Numbered steps shown in the modal. A VSP may supply any number of steps;
|
|
4858
4857
|
* the section is omitted entirely when the array is empty. */
|
|
4859
|
-
howItWorksSteps:
|
|
4858
|
+
howItWorksSteps: OfferWidgetHowItWorksStep[];
|
|
4860
4859
|
/** Section heading above the benefits grid, e.g. "FROM DAY ONE". */
|
|
4861
4860
|
fromDayOneHeader: string;
|
|
4862
|
-
benefits:
|
|
4861
|
+
benefits: OfferWidgetBenefit[];
|
|
4863
4862
|
}
|
|
4864
4863
|
|
|
4865
4864
|
/**
|
|
@@ -4873,7 +4872,7 @@ interface MarketingWidgetContent {
|
|
|
4873
4872
|
* copy for the applicant's own application says "your email" instead of the
|
|
4874
4873
|
* spec's "[applicant email]".
|
|
4875
4874
|
*/
|
|
4876
|
-
interface
|
|
4875
|
+
interface OfferStatusLabelValues {
|
|
4877
4876
|
bankName: string;
|
|
4878
4877
|
/** The applicant's full name, for either ownership. */
|
|
4879
4878
|
applicantName?: string;
|
|
@@ -4888,13 +4887,13 @@ interface MarketingStatusLabelValues {
|
|
|
4888
4887
|
* Copy for one application state: the status chip, an optional brand-colored
|
|
4889
4888
|
* heading, and the lines under it.
|
|
4890
4889
|
*/
|
|
4891
|
-
interface
|
|
4890
|
+
interface OfferStatusNoticeLabels {
|
|
4892
4891
|
chipLabel: string;
|
|
4893
4892
|
/** Omit for a state whose mock has no heading (the denied states). */
|
|
4894
|
-
heading?: (values:
|
|
4895
|
-
body: (values:
|
|
4893
|
+
heading?: (values: OfferStatusLabelValues) => string;
|
|
4894
|
+
body: (values: OfferStatusLabelValues) => string[];
|
|
4896
4895
|
}
|
|
4897
|
-
interface
|
|
4896
|
+
interface OfferWidgetStatusLabels {
|
|
4898
4897
|
/** Replaces the Apply CTA (card and modal) while the caller's own application is a draft. */
|
|
4899
4898
|
resumeApplication: string;
|
|
4900
4899
|
/** Stands in for the bank's name when widget init does not carry one. */
|
|
@@ -4905,24 +4904,24 @@ interface MarketingWidgetStatusLabels {
|
|
|
4905
4904
|
* hardcoded formatter, so a host can localize it with the copy.
|
|
4906
4905
|
*/
|
|
4907
4906
|
formatDate: (isoDateTime: string) => string;
|
|
4908
|
-
draftStartedByOther:
|
|
4909
|
-
submittedByYou:
|
|
4910
|
-
submittedByOther:
|
|
4911
|
-
deniedByYou:
|
|
4912
|
-
deniedByOther:
|
|
4907
|
+
draftStartedByOther: OfferStatusNoticeLabels;
|
|
4908
|
+
submittedByYou: OfferStatusNoticeLabels;
|
|
4909
|
+
submittedByOther: OfferStatusNoticeLabels;
|
|
4910
|
+
deniedByYou: OfferStatusNoticeLabels;
|
|
4911
|
+
deniedByOther: OfferStatusNoticeLabels;
|
|
4913
4912
|
}
|
|
4914
|
-
declare const
|
|
4913
|
+
declare const OFFER_WIDGET_STATUS_LABELS_EN: OfferWidgetStatusLabels;
|
|
4915
4914
|
|
|
4916
4915
|
type InnerProps = {
|
|
4917
|
-
content:
|
|
4916
|
+
content: OfferWidgetContent;
|
|
4918
4917
|
onPrimaryCtaClick: () => void;
|
|
4919
|
-
labels?: PartialDeep<
|
|
4918
|
+
labels?: PartialDeep<OfferWidgetLabels>;
|
|
4920
4919
|
/** Overrides for the copy shown when the organization already has an application. */
|
|
4921
|
-
statusLabels?: PartialDeep<
|
|
4920
|
+
statusLabels?: PartialDeep<OfferWidgetStatusLabels>;
|
|
4922
4921
|
};
|
|
4923
|
-
type
|
|
4922
|
+
type OfferWidgetProps = WidgetProviderProps & InnerProps;
|
|
4924
4923
|
/**
|
|
4925
|
-
* Self-contained
|
|
4924
|
+
* Self-contained offer card + modal. Hosts supply tenant-specific
|
|
4926
4925
|
* `content` (logos, copy, colors) and wire `onPrimaryCtaClick` to whatever
|
|
4927
4926
|
* should happen next — typically opening bank-account onboarding.
|
|
4928
4927
|
*
|
|
@@ -4938,7 +4937,7 @@ type MarketingWidgetProps = WidgetProviderProps & InnerProps;
|
|
|
4938
4937
|
* normal offer. A `DENIED` message hides itself 30 days after the denial, and
|
|
4939
4938
|
* a status this widget does not know hides the card.
|
|
4940
4939
|
*/
|
|
4941
|
-
declare function
|
|
4940
|
+
declare function OfferWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, providerLabels, ...innerProps }: OfferWidgetProps): React.JSX.Element;
|
|
4942
4941
|
|
|
4943
4942
|
interface ProductFormSheetLabels {
|
|
4944
4943
|
createTitle: string;
|
|
@@ -6013,5 +6012,5 @@ interface CheckAmountAndDetailScreenProps {
|
|
|
6013
6012
|
|
|
6014
6013
|
type PendingFeatureStyleSources = CheckAmountAndDetailScreenProps | GapCoverageAlertProps | NoPolicyBannerProps;
|
|
6015
6014
|
|
|
6016
|
-
export { ACCEPT_DISCLOSURES_WIDGET_LABELS_EN, ADDITIONAL_OWNERS_LABELS_EN, APPLICATION_STATUS_LABELS_EN, AcceptDisclosuresWidget, BALANCES_WIDGET_LABELS_EN, BUSINESS_DETAILS_LABELS_EN, BalancesWidget, BankAccountOnboardingWidget, BankAccountsWidget, BillPayWidget, CardDetailsWidget, CounterpartsWidget, CreditCardsWidget, CustomersWidget, DebitCardsWidget, ERROR_STATE_ID, ExpenseManagementWidget, HELP_FAQ_EN, INSIGHTS_FEATURE_LABELS_EN, INSIGHTS_WIDGET_LABELS_EN, Implementation, InsightsWidget, LinkedAccountsWidget,
|
|
6017
|
-
export type { AcceptDisclosuresWidgetLabels, AcceptDisclosuresWidgetProps, AccordionItemCardLabels, Labels$3 as AccountDetailsWidgetLabels, ActivateCardPanelLabels, AdditionalOwner, AdditionalOwnersLabels, AddressFormSheetLabels, ApplicationStatusLabelValues, ApplicationStatusLabels, ApplicationStatusNoticeLabels, BalancesWidgetLabels, BalancesWidgetProps, BankAccountFormSheetLabels, BankAccountOnboardingWidgetLabels, BankAccountOnboardingWidgetProps, FeatureLabels$3 as BankAccountsWidgetFeatureLabels, Labels$4 as BankAccountsWidgetLabels, BankAccountsWidgetProps, BillPayWidgetProps, BusinessDetailsLabels, BusinessDetailsValues, CardDetailsFeatureLabels, CardDetailsPanelLabels as CardDetailsWidgetLabels, CardDetailsWidgetProps, CardsFeatureLabels, CardsListLabels as CardsLabels, CardsPagination, CompanyStructureValue, ConfirmDeleteDialogLabels, CounterpartActionTarget, CounterpartDetailsSheetLabels, CounterpartFormSheetLabels, CounterpartMessageLabels, CounterpartMode, CounterpartsScreenLabels, CounterpartsWidgetProps, CreditCardsWidgetProps, CustomersWidgetOwnProps, CustomersWidgetProps, DebitCardsWidgetProps, DisclosureLinks, EmbeddedClient, Labels$2 as ExpenseManagementWidgetLabels, ExpenseManagementWidgetProps, ExpenseStatusBadgeLabels, FileViewerLabels, HelpFaqAnswer, HelpFaqBullet, HelpFaqBulletType, HelpFaqItem, HelpFaqSection, InsightsFeatureLabels, InsightsWidgetLabels, InsightsWidgetProps, InvoicesFilterBarLabelOverrides, InvoicesFilterBarLabels, InvoicesFilterLabelOverrides, InvoicesFilterLabels, LinkComponent, LinkComponentProps, FeatureLabels$2 as LinkedAccountsWidgetFeatureLabels, Labels$1 as LinkedAccountsWidgetLabels, LinkedAccountsWidgetProps,
|
|
6015
|
+
export { ACCEPT_DISCLOSURES_WIDGET_LABELS_EN, ADDITIONAL_OWNERS_LABELS_EN, APPLICATION_STATUS_LABELS_EN, AcceptDisclosuresWidget, BALANCES_WIDGET_LABELS_EN, BUSINESS_DETAILS_LABELS_EN, BalancesWidget, BankAccountOnboardingWidget, BankAccountsWidget, BillPayWidget, CardDetailsWidget, CounterpartsWidget, CreditCardsWidget, CustomersWidget, DebitCardsWidget, ERROR_STATE_ID, ExpenseManagementWidget, HELP_FAQ_EN, INSIGHTS_FEATURE_LABELS_EN, INSIGHTS_WIDGET_LABELS_EN, Implementation, InsightsWidget, LinkedAccountsWidget, OFFER_WIDGET_LABELS_EN, OFFER_WIDGET_STATUS_LABELS_EN, OfferBenefitIcon, OfferWidget, PERSONAL_DETAILS_LABELS_EN, ProductsWidget, RESULT_LABELS_EN, ReceivablesWidget, RefreshingRootWidgetProvider, RootWidgetProvider, SINGLE_INSIGHT_LABELS_EN, Scope, SettingsSection, SettingsWidget, DEFAULT_FEATURE_LABELS as TRANSFERS_FEATURE_LABELS_EN, TRANSFERS_WIDGET_LABELS_EN, TransfersWidget, UIFramework, WIDGET_SUITE_DEFAULT_SECTIONS, WIDGET_SUITE_LABELS_EN, WidgetProvider, WidgetSuite, WidgetSuiteSectionId, WidgetTokenRefreshProvider, cloneEmbeddedClient, getGlobalWidgetConfig, getGlobalWidgetInitState, isScope, registerDesignSystemEnsurer, registerUIRenderers, setGlobalWidgetConfig, subscribeToGlobalWidgetInitState, updateGlobalWidgetConfig, useDisclosuresAcceptanceSurface, useOwnWidgetConfig, useRefetchWidget, useWidgetConfig, useWidgetError, useWidgetInitStaleForToken, useWidgetLoading, useWidgetToken };
|
|
6016
|
+
export type { AcceptDisclosuresWidgetLabels, AcceptDisclosuresWidgetProps, AccordionItemCardLabels, Labels$3 as AccountDetailsWidgetLabels, ActivateCardPanelLabels, AdditionalOwner, AdditionalOwnersLabels, AddressFormSheetLabels, ApplicationStatusLabelValues, ApplicationStatusLabels, ApplicationStatusNoticeLabels, BalancesWidgetLabels, BalancesWidgetProps, BankAccountFormSheetLabels, BankAccountOnboardingWidgetLabels, BankAccountOnboardingWidgetProps, FeatureLabels$3 as BankAccountsWidgetFeatureLabels, Labels$4 as BankAccountsWidgetLabels, BankAccountsWidgetProps, BillPayWidgetProps, BusinessDetailsLabels, BusinessDetailsValues, CardDetailsFeatureLabels, CardDetailsPanelLabels as CardDetailsWidgetLabels, CardDetailsWidgetProps, CardsFeatureLabels, CardsListLabels as CardsLabels, CardsPagination, CompanyStructureValue, ConfirmDeleteDialogLabels, CounterpartActionTarget, CounterpartDetailsSheetLabels, CounterpartFormSheetLabels, CounterpartMessageLabels, CounterpartMode, CounterpartsScreenLabels, CounterpartsWidgetProps, CreditCardsWidgetProps, CustomersWidgetOwnProps, CustomersWidgetProps, DebitCardsWidgetProps, DisclosureLinks, EmbeddedClient, Labels$2 as ExpenseManagementWidgetLabels, ExpenseManagementWidgetProps, ExpenseStatusBadgeLabels, FileViewerLabels, HelpFaqAnswer, HelpFaqBullet, HelpFaqBulletType, HelpFaqItem, HelpFaqSection, InsightsFeatureLabels, InsightsWidgetLabels, InsightsWidgetProps, InvoicesFilterBarLabelOverrides, InvoicesFilterBarLabels, InvoicesFilterLabelOverrides, InvoicesFilterLabels, LinkComponent, LinkComponentProps, FeatureLabels$2 as LinkedAccountsWidgetFeatureLabels, Labels$1 as LinkedAccountsWidgetLabels, LinkedAccountsWidgetProps, MeasureUnitDeleteDialogLabels, MeasureUnitsManagerLabels, OfferStatusLabelValues, OfferStatusNoticeLabels, OfferWidgetBenefit, OfferWidgetContent, OfferWidgetHowItWorksStep, OfferWidgetImage, OfferWidgetLabels, OfferWidgetProps, OfferWidgetStatusLabels, PendingFeatureStyleSources, PersonalDetailsLabels, PersonalDetailsValues, ProductDeleteDialogLabels, ProductDetailsSheetLabels, ProductFormSheetLabels, ProductMessageLabels, ProductsScreenLabels, ProductsWidgetProps, ReceivableActionDialogLabels, ReceivableActionsModalLabels, ReceivableAuditHistoryLabels, ReceivableBankAttribution, ReceivableDetailsPanelLabelOverrides, ReceivableDetailsPanelLabels, ReceivableDocumentType, ReceivableFormDialogLabels, ReceivableFormSheetLabels, ReceivableMessageLabels, ReceivablePaymentDialogLabels, ReceivablePreviewLabels, ReceivableStatusBadgeLabels, ReceivablesScreenLabelOverrides, ReceivablesScreenLabels, ReceivablesWidgetProps, RefreshingRootWidgetProviderProps, ResultLabels, RootWidgetProviderProps, SettingsWidgetAdditionalSection, FeatureLabels$1 as SettingsWidgetFeatureLabels, Labels as SettingsWidgetLabels, SettingsWidgetProps, SettingsWidgetSection, SettingsWidgetSectionId, SingleInsightLabels, TransactionDetailsActionsLabels, TransactionDetailsLabels, FeatureLabels as TransfersWidgetFeatureLabels, TransfersWidgetLabels, TransfersWidgetProps, WidgetConfig, WidgetConfigInput, WidgetInitResponse, WidgetInitState, WidgetProviderLabels, WidgetProviderProps, WidgetSuiteCardsLabels, WidgetSuiteDashboardLabels, WidgetSuiteDisclosureLabels, WidgetSuiteExpensesLabels, WidgetSuiteLabelOverrides, WidgetSuiteLabels, WidgetSuiteMenuLabels, WidgetSuiteOnboardingGateLabels, WidgetSuiteOnboardingLabels, WidgetSuiteProps, WidgetSuiteSectionContentLabels, WidgetSuiteSectionTitleLabels, WidgetTokenFetcher, WidgetTokenManager, WidgetTokenRefreshProviderProps, WidgetTokenState };
|
package/dist/index.js
CHANGED
|
@@ -44,10 +44,10 @@ import { BankAccountOnboardingWidget as ee } from "./libs/tesouro-embedded-compo
|
|
|
44
44
|
import { WidgetSuite as te } from "./libs/tesouro-embedded-components-react/widget-suite/feature/dist/lib/WidgetSuite/WidgetSuite.js";
|
|
45
45
|
import { CounterpartsWidget as ne } from "./lib/CounterpartsWidgetPublic.js";
|
|
46
46
|
import { CustomersWidget as re } from "./libs/tesouro-embedded-components-react/customers-widget/feature/dist/lib/CustomersWidget/CustomersWidget.js";
|
|
47
|
-
import {
|
|
48
|
-
import {
|
|
49
|
-
import {
|
|
50
|
-
import {
|
|
47
|
+
import { OFFER_WIDGET_STATUS_LABELS_EN as ie } from "./libs/tesouro-embedded-components-react/offer-widget/feature/dist/lib/OfferWidget/labels.js";
|
|
48
|
+
import { OFFER_WIDGET_LABELS_EN as ae } from "./libs/tesouro-embedded-components-react/offer-widget/ui/dist/index2.js";
|
|
49
|
+
import { OfferBenefitIcon as oe } from "./libs/tesouro-embedded-components-react/offer-widget/ui/dist/index3.js";
|
|
50
|
+
import { OfferWidget as se } from "./libs/tesouro-embedded-components-react/offer-widget/feature/dist/lib/OfferWidget/OfferWidget.js";
|
|
51
51
|
import { ProductsWidget as ce } from "./libs/tesouro-embedded-components-react/products-widget/feature/dist/lib/ProductsWidget/ProductsWidget.js";
|
|
52
52
|
import { WidgetProvider as le } from "./lib/WidgetProviderPublic.js";
|
|
53
|
-
export { q as ACCEPT_DISCLOSURES_WIDGET_LABELS_EN, Y as ADDITIONAL_OWNERS_LABELS_EN, $ as APPLICATION_STATUS_LABELS_EN, J as AcceptDisclosuresWidget, M as BALANCES_WIDGET_LABELS_EN, X as BUSINESS_DETAILS_LABELS_EN, N as BalancesWidget, ee as BankAccountOnboardingWidget, D as BankAccountsWidget, O as BillPayWidget, k as CardDetailsWidget, ne as CounterpartsWidget, A as CreditCardsWidget, re as CustomersWidget, j as DebitCardsWidget, l as ERROR_STATE_ID, R as ExpenseManagementWidget, V as HELP_FAQ_EN, P as INSIGHTS_FEATURE_LABELS_EN, F as INSIGHTS_WIDGET_LABELS_EN, u as Implementation, L as InsightsWidget, U as LinkedAccountsWidget, ae as
|
|
53
|
+
export { q as ACCEPT_DISCLOSURES_WIDGET_LABELS_EN, Y as ADDITIONAL_OWNERS_LABELS_EN, $ as APPLICATION_STATUS_LABELS_EN, J as AcceptDisclosuresWidget, M as BALANCES_WIDGET_LABELS_EN, X as BUSINESS_DETAILS_LABELS_EN, N as BalancesWidget, ee as BankAccountOnboardingWidget, D as BankAccountsWidget, O as BillPayWidget, k as CardDetailsWidget, ne as CounterpartsWidget, A as CreditCardsWidget, re as CustomersWidget, j as DebitCardsWidget, l as ERROR_STATE_ID, R as ExpenseManagementWidget, V as HELP_FAQ_EN, P as INSIGHTS_FEATURE_LABELS_EN, F as INSIGHTS_WIDGET_LABELS_EN, u as Implementation, L as InsightsWidget, U as LinkedAccountsWidget, ae as OFFER_WIDGET_LABELS_EN, ie as OFFER_WIDGET_STATUS_LABELS_EN, oe as OfferBenefitIcon, se as OfferWidget, Z as PERSONAL_DETAILS_LABELS_EN, ce as ProductsWidget, Q as RESULT_LABELS_EN, z as ReceivablesWidget, y as RefreshingRootWidgetProvider, g as RootWidgetProvider, I as SINGLE_INSIGHT_LABELS_EN, i as Scope, B as SettingsSection, H as SettingsWidget, W as TRANSFERS_FEATURE_LABELS_EN, G as TRANSFERS_WIDGET_LABELS_EN, K as TransfersWidget, o as UIFramework, t as WIDGET_SUITE_DEFAULT_SECTIONS, e as WIDGET_SUITE_LABELS_EN, le as WidgetProvider, te as WidgetSuite, n as WidgetSuiteSectionId, _ as WidgetTokenRefreshProvider, r as cloneEmbeddedClient, d as getGlobalWidgetConfig, m as getGlobalWidgetInitState, a as isScope, s as registerDesignSystemEnsurer, c as registerUIRenderers, f as setGlobalWidgetConfig, h as subscribeToGlobalWidgetInitState, p as updateGlobalWidgetConfig, b as useDisclosuresAcceptanceSurface, x as useOwnWidgetConfig, S as useRefetchWidget, C as useWidgetConfig, w as useWidgetError, T as useWidgetInitStaleForToken, E as useWidgetLoading, v as useWidgetToken };
|
|
@@ -787,7 +787,6 @@ interface CounterpartMessageLabels {
|
|
|
787
787
|
accountHolderNameRequired: string;
|
|
788
788
|
routingNumberInvalid: string;
|
|
789
789
|
accountNumberInvalid: string;
|
|
790
|
-
vatIdValueRequired: string;
|
|
791
790
|
/** Shown for a non-field-specific submit failure. */
|
|
792
791
|
genericError: string;
|
|
793
792
|
/** Toasted when the list's billed/received/due analytics fail to load. */
|
|
@@ -787,7 +787,6 @@ interface CounterpartMessageLabels {
|
|
|
787
787
|
accountHolderNameRequired: string;
|
|
788
788
|
routingNumberInvalid: string;
|
|
789
789
|
accountNumberInvalid: string;
|
|
790
|
-
vatIdValueRequired: string;
|
|
791
790
|
/** Shown for a non-field-specific submit failure. */
|
|
792
791
|
genericError: string;
|
|
793
792
|
/** Toasted when the list's billed/received/due analytics fail to load. */
|
|
@@ -777,7 +777,6 @@ interface CounterpartMessageLabels {
|
|
|
777
777
|
accountHolderNameRequired: string;
|
|
778
778
|
routingNumberInvalid: string;
|
|
779
779
|
accountNumberInvalid: string;
|
|
780
|
-
vatIdValueRequired: string;
|
|
781
780
|
/** Shown for a non-field-specific submit failure. */
|
|
782
781
|
genericError: string;
|
|
783
782
|
/** Toasted when the list's billed/received/due analytics fail to load. */
|
|
@@ -3,7 +3,7 @@ import { ComponentType, AnchorHTMLAttributes, ReactNode, ErrorInfo } from 'react
|
|
|
3
3
|
import { PartialDeep } from 'type-fest';
|
|
4
4
|
import { FallbackProps } from 'react-error-boundary';
|
|
5
5
|
|
|
6
|
-
interface
|
|
6
|
+
interface OfferWidgetLabels {
|
|
7
7
|
applyNow: string;
|
|
8
8
|
learnMore: string;
|
|
9
9
|
primaryCta: string;
|
|
@@ -11,33 +11,33 @@ interface MarketingWidgetLabels {
|
|
|
11
11
|
primaryCtaSubtext: string;
|
|
12
12
|
dismissModalAriaLabel: string;
|
|
13
13
|
}
|
|
14
|
-
declare const
|
|
14
|
+
declare const OFFER_WIDGET_LABELS_EN: OfferWidgetLabels;
|
|
15
15
|
|
|
16
|
-
interface
|
|
16
|
+
interface OfferWidgetImage {
|
|
17
17
|
src: string;
|
|
18
18
|
alt: string;
|
|
19
19
|
width?: number;
|
|
20
20
|
}
|
|
21
|
-
declare const
|
|
21
|
+
declare const OfferBenefitIcon: {
|
|
22
22
|
readonly Sync: "sync";
|
|
23
23
|
readonly Users: "users";
|
|
24
24
|
readonly Document: "document";
|
|
25
25
|
readonly Dollar: "dollar";
|
|
26
26
|
readonly Card: "card";
|
|
27
27
|
};
|
|
28
|
-
type
|
|
29
|
-
interface
|
|
28
|
+
type OfferBenefitIcon = (typeof OfferBenefitIcon)[keyof typeof OfferBenefitIcon];
|
|
29
|
+
interface OfferWidgetBenefit {
|
|
30
30
|
text: string;
|
|
31
|
-
icon:
|
|
31
|
+
icon: OfferBenefitIcon;
|
|
32
32
|
}
|
|
33
|
-
interface
|
|
33
|
+
interface OfferWidgetHowItWorksStep {
|
|
34
34
|
/** Caller-supplied step badge text, e.g. "1" — the component never derives this from position. */
|
|
35
35
|
number: string;
|
|
36
36
|
title: string;
|
|
37
37
|
description: string;
|
|
38
38
|
}
|
|
39
|
-
interface
|
|
40
|
-
vspLogo:
|
|
39
|
+
interface OfferWidgetContent {
|
|
40
|
+
vspLogo: OfferWidgetImage;
|
|
41
41
|
bankingText: string;
|
|
42
42
|
primaryCaption: string;
|
|
43
43
|
secondaryCaption: string;
|
|
@@ -48,10 +48,10 @@ interface MarketingWidgetContent {
|
|
|
48
48
|
howItWorksHeader: string;
|
|
49
49
|
/** Numbered steps shown in the modal. A VSP may supply any number of steps;
|
|
50
50
|
* the section is omitted entirely when the array is empty. */
|
|
51
|
-
howItWorksSteps:
|
|
51
|
+
howItWorksSteps: OfferWidgetHowItWorksStep[];
|
|
52
52
|
/** Section heading above the benefits grid, e.g. "FROM DAY ONE". */
|
|
53
53
|
fromDayOneHeader: string;
|
|
54
|
-
benefits:
|
|
54
|
+
benefits: OfferWidgetBenefit[];
|
|
55
55
|
}
|
|
56
56
|
|
|
57
57
|
type AuthToken = string | undefined;
|
|
@@ -690,7 +690,7 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
690
690
|
* copy for the applicant's own application says "your email" instead of the
|
|
691
691
|
* spec's "[applicant email]".
|
|
692
692
|
*/
|
|
693
|
-
interface
|
|
693
|
+
interface OfferStatusLabelValues {
|
|
694
694
|
bankName: string;
|
|
695
695
|
/** The applicant's full name, for either ownership. */
|
|
696
696
|
applicantName?: string;
|
|
@@ -705,13 +705,13 @@ interface MarketingStatusLabelValues {
|
|
|
705
705
|
* Copy for one application state: the status chip, an optional brand-colored
|
|
706
706
|
* heading, and the lines under it.
|
|
707
707
|
*/
|
|
708
|
-
interface
|
|
708
|
+
interface OfferStatusNoticeLabels {
|
|
709
709
|
chipLabel: string;
|
|
710
710
|
/** Omit for a state whose mock has no heading (the denied states). */
|
|
711
|
-
heading?: (values:
|
|
712
|
-
body: (values:
|
|
711
|
+
heading?: (values: OfferStatusLabelValues) => string;
|
|
712
|
+
body: (values: OfferStatusLabelValues) => string[];
|
|
713
713
|
}
|
|
714
|
-
interface
|
|
714
|
+
interface OfferWidgetStatusLabels {
|
|
715
715
|
/** Replaces the Apply CTA (card and modal) while the caller's own application is a draft. */
|
|
716
716
|
resumeApplication: string;
|
|
717
717
|
/** Stands in for the bank's name when widget init does not carry one. */
|
|
@@ -722,24 +722,24 @@ interface MarketingWidgetStatusLabels {
|
|
|
722
722
|
* hardcoded formatter, so a host can localize it with the copy.
|
|
723
723
|
*/
|
|
724
724
|
formatDate: (isoDateTime: string) => string;
|
|
725
|
-
draftStartedByOther:
|
|
726
|
-
submittedByYou:
|
|
727
|
-
submittedByOther:
|
|
728
|
-
deniedByYou:
|
|
729
|
-
deniedByOther:
|
|
725
|
+
draftStartedByOther: OfferStatusNoticeLabels;
|
|
726
|
+
submittedByYou: OfferStatusNoticeLabels;
|
|
727
|
+
submittedByOther: OfferStatusNoticeLabels;
|
|
728
|
+
deniedByYou: OfferStatusNoticeLabels;
|
|
729
|
+
deniedByOther: OfferStatusNoticeLabels;
|
|
730
730
|
}
|
|
731
|
-
declare const
|
|
731
|
+
declare const OFFER_WIDGET_STATUS_LABELS_EN: OfferWidgetStatusLabels;
|
|
732
732
|
|
|
733
733
|
type InnerProps = {
|
|
734
|
-
content:
|
|
734
|
+
content: OfferWidgetContent;
|
|
735
735
|
onPrimaryCtaClick: () => void;
|
|
736
|
-
labels?: PartialDeep<
|
|
736
|
+
labels?: PartialDeep<OfferWidgetLabels>;
|
|
737
737
|
/** Overrides for the copy shown when the organization already has an application. */
|
|
738
|
-
statusLabels?: PartialDeep<
|
|
738
|
+
statusLabels?: PartialDeep<OfferWidgetStatusLabels>;
|
|
739
739
|
};
|
|
740
|
-
type
|
|
740
|
+
type OfferWidgetProps = WidgetProviderProps & InnerProps;
|
|
741
741
|
/**
|
|
742
|
-
* Self-contained
|
|
742
|
+
* Self-contained offer card + modal. Hosts supply tenant-specific
|
|
743
743
|
* `content` (logos, copy, colors) and wire `onPrimaryCtaClick` to whatever
|
|
744
744
|
* should happen next — typically opening bank-account onboarding.
|
|
745
745
|
*
|
|
@@ -755,7 +755,7 @@ type MarketingWidgetProps = WidgetProviderProps & InnerProps;
|
|
|
755
755
|
* normal offer. A `DENIED` message hides itself 30 days after the denial, and
|
|
756
756
|
* a status this widget does not know hides the card.
|
|
757
757
|
*/
|
|
758
|
-
declare function
|
|
758
|
+
declare function OfferWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, providerLabels, ...innerProps }: OfferWidgetProps): React.JSX.Element;
|
|
759
759
|
|
|
760
|
-
export {
|
|
761
|
-
export type {
|
|
760
|
+
export { OFFER_WIDGET_LABELS_EN, OFFER_WIDGET_STATUS_LABELS_EN, OfferBenefitIcon, OfferWidget };
|
|
761
|
+
export type { OfferStatusLabelValues, OfferStatusNoticeLabels, OfferWidgetBenefit, OfferWidgetContent, OfferWidgetHowItWorksStep, OfferWidgetImage, OfferWidgetLabels, OfferWidgetProps, OfferWidgetStatusLabels };
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { OFFER_WIDGET_STATUS_LABELS_EN as e } from "../libs/tesouro-embedded-components-react/offer-widget/feature/dist/lib/OfferWidget/labels.js";
|
|
2
|
+
import { OFFER_WIDGET_LABELS_EN as t } from "../libs/tesouro-embedded-components-react/offer-widget/ui/dist/index2.js";
|
|
3
|
+
import { OfferBenefitIcon as n } from "../libs/tesouro-embedded-components-react/offer-widget/ui/dist/index3.js";
|
|
4
|
+
import { OfferWidget as r } from "../libs/tesouro-embedded-components-react/offer-widget/feature/dist/lib/OfferWidget/OfferWidget.js";
|
|
5
|
+
import "../libs/tesouro-embedded-components-react/offer-widget/feature/dist/index.js";
|
|
6
|
+
export { t as OFFER_WIDGET_LABELS_EN, e as OFFER_WIDGET_STATUS_LABELS_EN, n as OfferBenefitIcon, r as OfferWidget };
|
|
@@ -852,7 +852,6 @@ interface CounterpartMessageLabels {
|
|
|
852
852
|
accountHolderNameRequired: string;
|
|
853
853
|
routingNumberInvalid: string;
|
|
854
854
|
accountNumberInvalid: string;
|
|
855
|
-
vatIdValueRequired: string;
|
|
856
855
|
/** Shown for a non-field-specific submit failure. */
|
|
857
856
|
genericError: string;
|
|
858
857
|
/** Toasted when the list's billed/received/due analytics fail to load. */
|