@tesouro/embedded-components-react 0.3.25 → 0.3.27
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 +3 -0
- package/dist/experimental/WidgetSuite.d.ts +32 -3
- package/dist/experimental/index.d.ts +32 -3
- package/dist/index.d.ts +60 -25
- package/dist/lib/AcceptDisclosuresWidget.d.ts +32 -3
- package/dist/lib/BalancesWidget.d.ts +31 -2
- package/dist/lib/BankAccountOnboardingWidget.d.ts +32 -3
- package/dist/lib/BankAccountsWidget.d.ts +32 -3
- package/dist/lib/BillPayWidget.d.ts +31 -2
- package/dist/lib/CardDetailsWidget.d.ts +32 -3
- package/dist/lib/CardsWidget.d.ts +32 -3
- package/dist/lib/ChartOfAccountsWidget.d.ts +32 -3
- package/dist/lib/CounterpartsWidget.d.ts +32 -3
- package/dist/lib/CreateCardWidget.d.ts +32 -3
- package/dist/lib/ExpenseApprovalPoliciesWidget.d.ts +32 -3
- package/dist/lib/ExpenseManagementWidget.d.ts +32 -3
- package/dist/lib/ExpenseRequirementsWidget.d.ts +32 -3
- package/dist/lib/HelpWidget.d.ts +32 -3
- package/dist/lib/InsightsWidget.d.ts +31 -2
- package/dist/lib/InvoicingWidget.d.ts +32 -3
- package/dist/lib/LinkedAccountsWidget.d.ts +32 -3
- package/dist/lib/ProductsWidget.d.ts +32 -3
- package/dist/lib/ProfileWidget.d.ts +32 -3
- package/dist/lib/ReceiptMatchWidget.d.ts +32 -3
- package/dist/lib/ReceivablesWidget.d.ts +32 -3
- package/dist/lib/SettingsWidget.d.ts +32 -3
- package/dist/lib/TagsWidget.d.ts +32 -3
- package/dist/lib/TeamWidget.d.ts +32 -3
- package/dist/lib/TransfersWidget.d.ts +31 -2
- package/dist/lib/WidgetProvider.d.ts +39 -4
- package/dist/lib/WidgetProviderPublic.d.ts +31 -2
- package/dist/libs/tesouro-embedded-components-react/accept-disclosures-widget/feature/dist/index5.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/bank-account-onboarding-widget/feature/dist/index18.js +131 -130
- package/dist/libs/tesouro-embedded-components-react/bank-accounts-widget/feature/dist/index8.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index51.js +4 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index73.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index90.js +10 -10
- package/dist/libs/tesouro-embedded-components-react/card-details-widget/feature/dist/index6.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/cards-widget/feature/dist/index9.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/counterparts-widget/feature/dist/index8.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/create-card-widget/feature/dist/index7.js +88 -87
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/feature/dist/index13.js +7 -6
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/feature/dist/index6.js +2 -1
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/feature/dist/index9.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/expense-requirements-widget/feature/dist/lib/ExpenseRequirementsWidget.js +2 -1
- package/dist/libs/tesouro-embedded-components-react/gl-code-table-widget/feature/dist/index8.js +5 -4
- package/dist/libs/tesouro-embedded-components-react/help-widget/feature/dist/index3.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index12.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index3.js +5 -4
- package/dist/libs/tesouro-embedded-components-react/linked-accounts-widget/feature/dist/index9.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/products-widget/feature/dist/index8.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/profile-widget/feature/dist/index4.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/settings-widget/feature/dist/index6.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/WidgetProvider/RootWidgetProvider.js +50 -48
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/WidgetProvider/WidgetErrorBoundary.js +13 -13
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/WidgetProvider/WidgetProvider.js +174 -163
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/WidgetProvider/isDisclosuresAcceptanceRequired.js +12 -1
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/WidgetProvider/labels.js +7 -1
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/events.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/tags-widget/feature/dist/index11.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/team-widget/feature/dist/index17.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/widget-suite/feature/dist/index8.js +3 -2
- package/package.json +1 -1
package/dist/lib/HelpWidget.d.ts
CHANGED
|
@@ -650,6 +650,26 @@ interface WidgetProviderBaseProps extends WidgetConfigInput {
|
|
|
650
650
|
analytics?: boolean;
|
|
651
651
|
}
|
|
652
652
|
|
|
653
|
+
/**
|
|
654
|
+
* Copy for the states `WidgetProvider` renders *itself*, in place of the widget:
|
|
655
|
+
* the error-boundary fallback and the disclosures gate. A host overrides any
|
|
656
|
+
* subset through the `providerLabels` prop, which cascades like
|
|
657
|
+
* `disclosuresAcceptance`.
|
|
658
|
+
*
|
|
659
|
+
* Not named `Labels` on the public surface: a widget's own `labels` prop is a
|
|
660
|
+
* different thing, and these two travel together on every widget's props type.
|
|
661
|
+
*/
|
|
662
|
+
interface WidgetProviderLabels {
|
|
663
|
+
/** Default copy for the built-in error boundary fallback. */
|
|
664
|
+
errorBoundaryFallback: string;
|
|
665
|
+
/** Heading when init reports disclosures are required and not yet accepted. */
|
|
666
|
+
disclosuresRequiredTitle: string;
|
|
667
|
+
/** Heading while a token-only refresh leaves init stale for the live token. */
|
|
668
|
+
disclosuresRefreshingTitle: string;
|
|
669
|
+
/** Supporting copy while the accept action is withheld for a stale init. */
|
|
670
|
+
disclosuresRefreshingDescription: string;
|
|
671
|
+
}
|
|
672
|
+
|
|
653
673
|
/**
|
|
654
674
|
* Props for {@link WidgetProvider}.
|
|
655
675
|
*
|
|
@@ -662,8 +682,8 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
662
682
|
* Fallback rendered when a render-time exception is caught inside this
|
|
663
683
|
* provider's subtree. Pass either a `ReactNode` (rendered directly) or a
|
|
664
684
|
* render-prop receiving `{ error, resetErrorBoundary }` from
|
|
665
|
-
* `react-error-boundary`. Default is a plain `role="alert"` div
|
|
666
|
-
*
|
|
685
|
+
* `react-error-boundary`. Default is a plain `role="alert"` div whose copy
|
|
686
|
+
* comes from `providerLabels.errorBoundaryFallback`.
|
|
667
687
|
*/
|
|
668
688
|
errorFallback?: ReactNode | ((props: FallbackProps) => ReactNode);
|
|
669
689
|
/**
|
|
@@ -680,6 +700,15 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
680
700
|
* WidgetProvider cannot import the widget itself (cycle).
|
|
681
701
|
*/
|
|
682
702
|
disclosuresAcceptance?: ReactNode;
|
|
703
|
+
/**
|
|
704
|
+
* Overrides for the copy this provider renders in place of the widget: the
|
|
705
|
+
* built-in error-boundary fallback and the disclosures gate. Any subset;
|
|
706
|
+
* unlisted keys keep their defaults. Cascades like `linkComponent`.
|
|
707
|
+
*
|
|
708
|
+
* Named `providerLabels` rather than `labels` because a widget's own
|
|
709
|
+
* `labels` prop sits alongside this one on the same props type.
|
|
710
|
+
*/
|
|
711
|
+
providerLabels?: Partial<WidgetProviderLabels>;
|
|
683
712
|
}
|
|
684
713
|
|
|
685
714
|
/**
|
|
@@ -704,7 +733,7 @@ type HelpWidgetProps = WidgetProviderProps & HelpContentProps;
|
|
|
704
733
|
* <HelpWidget bankName="Acme Bank" contactUrl="https://acme.example/support" />
|
|
705
734
|
* ```
|
|
706
735
|
*/
|
|
707
|
-
declare function HelpWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, ...contentProps }: HelpWidgetProps): React.JSX.Element;
|
|
736
|
+
declare function HelpWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, providerLabels, ...contentProps }: HelpWidgetProps): React.JSX.Element;
|
|
708
737
|
|
|
709
738
|
export { HELP_FAQ_EN, HELP_WIDGET_LABELS_EN, HelpWidget };
|
|
710
739
|
export type { HelpFaqAnswer, HelpFaqBullet, HelpFaqBulletType, HelpFaqItem, HelpFaqSection, HelpWidgetLabels, HelpWidgetProps };
|
|
@@ -602,6 +602,26 @@ interface WidgetProviderBaseProps extends WidgetConfigInput {
|
|
|
602
602
|
analytics?: boolean;
|
|
603
603
|
}
|
|
604
604
|
|
|
605
|
+
/**
|
|
606
|
+
* Copy for the states `WidgetProvider` renders *itself*, in place of the widget:
|
|
607
|
+
* the error-boundary fallback and the disclosures gate. A host overrides any
|
|
608
|
+
* subset through the `providerLabels` prop, which cascades like
|
|
609
|
+
* `disclosuresAcceptance`.
|
|
610
|
+
*
|
|
611
|
+
* Not named `Labels` on the public surface: a widget's own `labels` prop is a
|
|
612
|
+
* different thing, and these two travel together on every widget's props type.
|
|
613
|
+
*/
|
|
614
|
+
interface WidgetProviderLabels {
|
|
615
|
+
/** Default copy for the built-in error boundary fallback. */
|
|
616
|
+
errorBoundaryFallback: string;
|
|
617
|
+
/** Heading when init reports disclosures are required and not yet accepted. */
|
|
618
|
+
disclosuresRequiredTitle: string;
|
|
619
|
+
/** Heading while a token-only refresh leaves init stale for the live token. */
|
|
620
|
+
disclosuresRefreshingTitle: string;
|
|
621
|
+
/** Supporting copy while the accept action is withheld for a stale init. */
|
|
622
|
+
disclosuresRefreshingDescription: string;
|
|
623
|
+
}
|
|
624
|
+
|
|
605
625
|
/**
|
|
606
626
|
* Props for {@link WidgetProvider}.
|
|
607
627
|
*
|
|
@@ -614,8 +634,8 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
614
634
|
* Fallback rendered when a render-time exception is caught inside this
|
|
615
635
|
* provider's subtree. Pass either a `ReactNode` (rendered directly) or a
|
|
616
636
|
* render-prop receiving `{ error, resetErrorBoundary }` from
|
|
617
|
-
* `react-error-boundary`. Default is a plain `role="alert"` div
|
|
618
|
-
*
|
|
637
|
+
* `react-error-boundary`. Default is a plain `role="alert"` div whose copy
|
|
638
|
+
* comes from `providerLabels.errorBoundaryFallback`.
|
|
619
639
|
*/
|
|
620
640
|
errorFallback?: ReactNode | ((props: FallbackProps) => ReactNode);
|
|
621
641
|
/**
|
|
@@ -632,6 +652,15 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
632
652
|
* WidgetProvider cannot import the widget itself (cycle).
|
|
633
653
|
*/
|
|
634
654
|
disclosuresAcceptance?: ReactNode;
|
|
655
|
+
/**
|
|
656
|
+
* Overrides for the copy this provider renders in place of the widget: the
|
|
657
|
+
* built-in error-boundary fallback and the disclosures gate. Any subset;
|
|
658
|
+
* unlisted keys keep their defaults. Cascades like `linkComponent`.
|
|
659
|
+
*
|
|
660
|
+
* Named `providerLabels` rather than `labels` because a widget's own
|
|
661
|
+
* `labels` prop sits alongside this one on the same props type.
|
|
662
|
+
*/
|
|
663
|
+
providerLabels?: Partial<WidgetProviderLabels>;
|
|
635
664
|
}
|
|
636
665
|
|
|
637
666
|
interface InsightsFeatureLabels {
|
|
@@ -596,6 +596,26 @@ interface WidgetProviderBaseProps extends WidgetConfigInput {
|
|
|
596
596
|
analytics?: boolean;
|
|
597
597
|
}
|
|
598
598
|
|
|
599
|
+
/**
|
|
600
|
+
* Copy for the states `WidgetProvider` renders *itself*, in place of the widget:
|
|
601
|
+
* the error-boundary fallback and the disclosures gate. A host overrides any
|
|
602
|
+
* subset through the `providerLabels` prop, which cascades like
|
|
603
|
+
* `disclosuresAcceptance`.
|
|
604
|
+
*
|
|
605
|
+
* Not named `Labels` on the public surface: a widget's own `labels` prop is a
|
|
606
|
+
* different thing, and these two travel together on every widget's props type.
|
|
607
|
+
*/
|
|
608
|
+
interface WidgetProviderLabels {
|
|
609
|
+
/** Default copy for the built-in error boundary fallback. */
|
|
610
|
+
errorBoundaryFallback: string;
|
|
611
|
+
/** Heading when init reports disclosures are required and not yet accepted. */
|
|
612
|
+
disclosuresRequiredTitle: string;
|
|
613
|
+
/** Heading while a token-only refresh leaves init stale for the live token. */
|
|
614
|
+
disclosuresRefreshingTitle: string;
|
|
615
|
+
/** Supporting copy while the accept action is withheld for a stale init. */
|
|
616
|
+
disclosuresRefreshingDescription: string;
|
|
617
|
+
}
|
|
618
|
+
|
|
599
619
|
/**
|
|
600
620
|
* Props for {@link WidgetProvider}.
|
|
601
621
|
*
|
|
@@ -608,8 +628,8 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
608
628
|
* Fallback rendered when a render-time exception is caught inside this
|
|
609
629
|
* provider's subtree. Pass either a `ReactNode` (rendered directly) or a
|
|
610
630
|
* render-prop receiving `{ error, resetErrorBoundary }` from
|
|
611
|
-
* `react-error-boundary`. Default is a plain `role="alert"` div
|
|
612
|
-
*
|
|
631
|
+
* `react-error-boundary`. Default is a plain `role="alert"` div whose copy
|
|
632
|
+
* comes from `providerLabels.errorBoundaryFallback`.
|
|
613
633
|
*/
|
|
614
634
|
errorFallback?: ReactNode | ((props: FallbackProps) => ReactNode);
|
|
615
635
|
/**
|
|
@@ -626,6 +646,15 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
626
646
|
* WidgetProvider cannot import the widget itself (cycle).
|
|
627
647
|
*/
|
|
628
648
|
disclosuresAcceptance?: ReactNode;
|
|
649
|
+
/**
|
|
650
|
+
* Overrides for the copy this provider renders in place of the widget: the
|
|
651
|
+
* built-in error-boundary fallback and the disclosures gate. Any subset;
|
|
652
|
+
* unlisted keys keep their defaults. Cascades like `linkComponent`.
|
|
653
|
+
*
|
|
654
|
+
* Named `providerLabels` rather than `labels` because a widget's own
|
|
655
|
+
* `labels` prop sits alongside this one on the same props type.
|
|
656
|
+
*/
|
|
657
|
+
providerLabels?: Partial<WidgetProviderLabels>;
|
|
629
658
|
}
|
|
630
659
|
|
|
631
660
|
type MoniteRegionProviderProps = WidgetProviderProps & MoniteWrapperProps;
|
|
@@ -633,7 +662,7 @@ type MoniteRegionProviderProps = WidgetProviderProps & MoniteWrapperProps;
|
|
|
633
662
|
type ReceivablesWidgetMoniteProps = MoniteRegionProviderProps & Omit<ReceivablesProps, 'pageTitleComponent' | 'initialView' | 'initialCounterpartId'> & {
|
|
634
663
|
pageTitleComponent?: ReceivablesProps['pageTitleComponent'];
|
|
635
664
|
};
|
|
636
|
-
declare function ReceivablesWidgetMonite({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, errorFallback, onError, finopsThemeColors, analytics, disclosuresAcceptance, pageTitleComponent, uiFramework, ...receivablesProps }: ReceivablesWidgetMoniteProps): React.JSX.Element;
|
|
665
|
+
declare function ReceivablesWidgetMonite({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, errorFallback, onError, finopsThemeColors, analytics, disclosuresAcceptance, providerLabels, pageTitleComponent, uiFramework, ...receivablesProps }: ReceivablesWidgetMoniteProps): React.JSX.Element;
|
|
637
666
|
|
|
638
667
|
export { ReceivablesWidgetMonite as InvoicingWidget };
|
|
639
668
|
export type { ReceivablesWidgetMoniteProps as InvoicingWidgetProps };
|
|
@@ -634,6 +634,26 @@ interface WidgetProviderBaseProps extends WidgetConfigInput {
|
|
|
634
634
|
analytics?: boolean;
|
|
635
635
|
}
|
|
636
636
|
|
|
637
|
+
/**
|
|
638
|
+
* Copy for the states `WidgetProvider` renders *itself*, in place of the widget:
|
|
639
|
+
* the error-boundary fallback and the disclosures gate. A host overrides any
|
|
640
|
+
* subset through the `providerLabels` prop, which cascades like
|
|
641
|
+
* `disclosuresAcceptance`.
|
|
642
|
+
*
|
|
643
|
+
* Not named `Labels` on the public surface: a widget's own `labels` prop is a
|
|
644
|
+
* different thing, and these two travel together on every widget's props type.
|
|
645
|
+
*/
|
|
646
|
+
interface WidgetProviderLabels {
|
|
647
|
+
/** Default copy for the built-in error boundary fallback. */
|
|
648
|
+
errorBoundaryFallback: string;
|
|
649
|
+
/** Heading when init reports disclosures are required and not yet accepted. */
|
|
650
|
+
disclosuresRequiredTitle: string;
|
|
651
|
+
/** Heading while a token-only refresh leaves init stale for the live token. */
|
|
652
|
+
disclosuresRefreshingTitle: string;
|
|
653
|
+
/** Supporting copy while the accept action is withheld for a stale init. */
|
|
654
|
+
disclosuresRefreshingDescription: string;
|
|
655
|
+
}
|
|
656
|
+
|
|
637
657
|
/**
|
|
638
658
|
* Props for {@link WidgetProvider}.
|
|
639
659
|
*
|
|
@@ -646,8 +666,8 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
646
666
|
* Fallback rendered when a render-time exception is caught inside this
|
|
647
667
|
* provider's subtree. Pass either a `ReactNode` (rendered directly) or a
|
|
648
668
|
* render-prop receiving `{ error, resetErrorBoundary }` from
|
|
649
|
-
* `react-error-boundary`. Default is a plain `role="alert"` div
|
|
650
|
-
*
|
|
669
|
+
* `react-error-boundary`. Default is a plain `role="alert"` div whose copy
|
|
670
|
+
* comes from `providerLabels.errorBoundaryFallback`.
|
|
651
671
|
*/
|
|
652
672
|
errorFallback?: ReactNode | ((props: FallbackProps) => ReactNode);
|
|
653
673
|
/**
|
|
@@ -664,6 +684,15 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
664
684
|
* WidgetProvider cannot import the widget itself (cycle).
|
|
665
685
|
*/
|
|
666
686
|
disclosuresAcceptance?: ReactNode;
|
|
687
|
+
/**
|
|
688
|
+
* Overrides for the copy this provider renders in place of the widget: the
|
|
689
|
+
* built-in error-boundary fallback and the disclosures gate. Any subset;
|
|
690
|
+
* unlisted keys keep their defaults. Cascades like `linkComponent`.
|
|
691
|
+
*
|
|
692
|
+
* Named `providerLabels` rather than `labels` because a widget's own
|
|
693
|
+
* `labels` prop sits alongside this one on the same props type.
|
|
694
|
+
*/
|
|
695
|
+
providerLabels?: Partial<WidgetProviderLabels>;
|
|
667
696
|
}
|
|
668
697
|
|
|
669
698
|
interface FeatureLabels {
|
|
@@ -678,7 +707,7 @@ interface LinkedAccountsWidgetProps extends WidgetProviderProps {
|
|
|
678
707
|
labels?: Partial<Labels>;
|
|
679
708
|
featureLabels?: Partial<FeatureLabels>;
|
|
680
709
|
}
|
|
681
|
-
declare function LinkedAccountsWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, ...innerProps }: LinkedAccountsWidgetProps): React.JSX.Element;
|
|
710
|
+
declare function LinkedAccountsWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, providerLabels, ...innerProps }: LinkedAccountsWidgetProps): React.JSX.Element;
|
|
682
711
|
|
|
683
712
|
export { LinkedAccountsWidget };
|
|
684
713
|
export type { FeatureLabels as LinkedAccountsWidgetFeatureLabels, Labels as LinkedAccountsWidgetLabels, LinkedAccountsWidgetProps };
|
|
@@ -566,6 +566,26 @@ interface WidgetProviderBaseProps extends WidgetConfigInput {
|
|
|
566
566
|
analytics?: boolean;
|
|
567
567
|
}
|
|
568
568
|
|
|
569
|
+
/**
|
|
570
|
+
* Copy for the states `WidgetProvider` renders *itself*, in place of the widget:
|
|
571
|
+
* the error-boundary fallback and the disclosures gate. A host overrides any
|
|
572
|
+
* subset through the `providerLabels` prop, which cascades like
|
|
573
|
+
* `disclosuresAcceptance`.
|
|
574
|
+
*
|
|
575
|
+
* Not named `Labels` on the public surface: a widget's own `labels` prop is a
|
|
576
|
+
* different thing, and these two travel together on every widget's props type.
|
|
577
|
+
*/
|
|
578
|
+
interface WidgetProviderLabels {
|
|
579
|
+
/** Default copy for the built-in error boundary fallback. */
|
|
580
|
+
errorBoundaryFallback: string;
|
|
581
|
+
/** Heading when init reports disclosures are required and not yet accepted. */
|
|
582
|
+
disclosuresRequiredTitle: string;
|
|
583
|
+
/** Heading while a token-only refresh leaves init stale for the live token. */
|
|
584
|
+
disclosuresRefreshingTitle: string;
|
|
585
|
+
/** Supporting copy while the accept action is withheld for a stale init. */
|
|
586
|
+
disclosuresRefreshingDescription: string;
|
|
587
|
+
}
|
|
588
|
+
|
|
569
589
|
/**
|
|
570
590
|
* Props for {@link WidgetProvider}.
|
|
571
591
|
*
|
|
@@ -578,8 +598,8 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
578
598
|
* Fallback rendered when a render-time exception is caught inside this
|
|
579
599
|
* provider's subtree. Pass either a `ReactNode` (rendered directly) or a
|
|
580
600
|
* render-prop receiving `{ error, resetErrorBoundary }` from
|
|
581
|
-
* `react-error-boundary`. Default is a plain `role="alert"` div
|
|
582
|
-
*
|
|
601
|
+
* `react-error-boundary`. Default is a plain `role="alert"` div whose copy
|
|
602
|
+
* comes from `providerLabels.errorBoundaryFallback`.
|
|
583
603
|
*/
|
|
584
604
|
errorFallback?: ReactNode | ((props: FallbackProps) => ReactNode);
|
|
585
605
|
/**
|
|
@@ -596,6 +616,15 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
596
616
|
* WidgetProvider cannot import the widget itself (cycle).
|
|
597
617
|
*/
|
|
598
618
|
disclosuresAcceptance?: ReactNode;
|
|
619
|
+
/**
|
|
620
|
+
* Overrides for the copy this provider renders in place of the widget: the
|
|
621
|
+
* built-in error-boundary fallback and the disclosures gate. Any subset;
|
|
622
|
+
* unlisted keys keep their defaults. Cascades like `linkComponent`.
|
|
623
|
+
*
|
|
624
|
+
* Named `providerLabels` rather than `labels` because a widget's own
|
|
625
|
+
* `labels` prop sits alongside this one on the same props type.
|
|
626
|
+
*/
|
|
627
|
+
providerLabels?: Partial<WidgetProviderLabels>;
|
|
599
628
|
}
|
|
600
629
|
|
|
601
630
|
interface ProductFormSheetLabels {
|
|
@@ -780,7 +809,7 @@ type ProductsWidgetProps = WidgetProviderProps & ProductsWidgetOwnProps;
|
|
|
780
809
|
* <ProductsWidget baseUrl="https://api.tesouro.com" widgetToken="wt_..." organizationId="org_..." />
|
|
781
810
|
* ```
|
|
782
811
|
*/
|
|
783
|
-
declare function ProductsWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, ...innerProps }: ProductsWidgetProps): React.JSX.Element;
|
|
812
|
+
declare function ProductsWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, providerLabels, ...innerProps }: ProductsWidgetProps): React.JSX.Element;
|
|
784
813
|
|
|
785
814
|
export { ProductsWidget };
|
|
786
815
|
export type { MeasureUnitDeleteDialogLabels, MeasureUnitsManagerLabels, ProductDeleteDialogLabels, ProductDetailsSheetLabels, ProductFormSheetLabels, ProductMessageLabels, ProductsScreenLabels, ProductsWidgetProps };
|
|
@@ -579,6 +579,26 @@ interface WidgetProviderBaseProps extends WidgetConfigInput {
|
|
|
579
579
|
analytics?: boolean;
|
|
580
580
|
}
|
|
581
581
|
|
|
582
|
+
/**
|
|
583
|
+
* Copy for the states `WidgetProvider` renders *itself*, in place of the widget:
|
|
584
|
+
* the error-boundary fallback and the disclosures gate. A host overrides any
|
|
585
|
+
* subset through the `providerLabels` prop, which cascades like
|
|
586
|
+
* `disclosuresAcceptance`.
|
|
587
|
+
*
|
|
588
|
+
* Not named `Labels` on the public surface: a widget's own `labels` prop is a
|
|
589
|
+
* different thing, and these two travel together on every widget's props type.
|
|
590
|
+
*/
|
|
591
|
+
interface WidgetProviderLabels {
|
|
592
|
+
/** Default copy for the built-in error boundary fallback. */
|
|
593
|
+
errorBoundaryFallback: string;
|
|
594
|
+
/** Heading when init reports disclosures are required and not yet accepted. */
|
|
595
|
+
disclosuresRequiredTitle: string;
|
|
596
|
+
/** Heading while a token-only refresh leaves init stale for the live token. */
|
|
597
|
+
disclosuresRefreshingTitle: string;
|
|
598
|
+
/** Supporting copy while the accept action is withheld for a stale init. */
|
|
599
|
+
disclosuresRefreshingDescription: string;
|
|
600
|
+
}
|
|
601
|
+
|
|
582
602
|
/**
|
|
583
603
|
* Props for {@link WidgetProvider}.
|
|
584
604
|
*
|
|
@@ -591,8 +611,8 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
591
611
|
* Fallback rendered when a render-time exception is caught inside this
|
|
592
612
|
* provider's subtree. Pass either a `ReactNode` (rendered directly) or a
|
|
593
613
|
* render-prop receiving `{ error, resetErrorBoundary }` from
|
|
594
|
-
* `react-error-boundary`. Default is a plain `role="alert"` div
|
|
595
|
-
*
|
|
614
|
+
* `react-error-boundary`. Default is a plain `role="alert"` div whose copy
|
|
615
|
+
* comes from `providerLabels.errorBoundaryFallback`.
|
|
596
616
|
*/
|
|
597
617
|
errorFallback?: ReactNode | ((props: FallbackProps) => ReactNode);
|
|
598
618
|
/**
|
|
@@ -609,6 +629,15 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
609
629
|
* WidgetProvider cannot import the widget itself (cycle).
|
|
610
630
|
*/
|
|
611
631
|
disclosuresAcceptance?: ReactNode;
|
|
632
|
+
/**
|
|
633
|
+
* Overrides for the copy this provider renders in place of the widget: the
|
|
634
|
+
* built-in error-boundary fallback and the disclosures gate. Any subset;
|
|
635
|
+
* unlisted keys keep their defaults. Cascades like `linkComponent`.
|
|
636
|
+
*
|
|
637
|
+
* Named `providerLabels` rather than `labels` because a widget's own
|
|
638
|
+
* `labels` prop sits alongside this one on the same props type.
|
|
639
|
+
*/
|
|
640
|
+
providerLabels?: Partial<WidgetProviderLabels>;
|
|
612
641
|
}
|
|
613
642
|
|
|
614
643
|
interface FeatureLabels {
|
|
@@ -637,7 +666,7 @@ interface ProfileWidgetProps extends WidgetProviderProps {
|
|
|
637
666
|
*/
|
|
638
667
|
contactUrl?: string;
|
|
639
668
|
}
|
|
640
|
-
declare function ProfileWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, ...innerProps }: ProfileWidgetProps): React.JSX.Element;
|
|
669
|
+
declare function ProfileWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, providerLabels, ...innerProps }: ProfileWidgetProps): React.JSX.Element;
|
|
641
670
|
|
|
642
671
|
export { ProfileWidget };
|
|
643
672
|
export type { FeatureLabels as ProfileWidgetFeatureLabels, Labels as ProfileWidgetLabels, ProfileWidgetProps };
|
|
@@ -566,6 +566,26 @@ interface WidgetProviderBaseProps extends WidgetConfigInput {
|
|
|
566
566
|
analytics?: boolean;
|
|
567
567
|
}
|
|
568
568
|
|
|
569
|
+
/**
|
|
570
|
+
* Copy for the states `WidgetProvider` renders *itself*, in place of the widget:
|
|
571
|
+
* the error-boundary fallback and the disclosures gate. A host overrides any
|
|
572
|
+
* subset through the `providerLabels` prop, which cascades like
|
|
573
|
+
* `disclosuresAcceptance`.
|
|
574
|
+
*
|
|
575
|
+
* Not named `Labels` on the public surface: a widget's own `labels` prop is a
|
|
576
|
+
* different thing, and these two travel together on every widget's props type.
|
|
577
|
+
*/
|
|
578
|
+
interface WidgetProviderLabels {
|
|
579
|
+
/** Default copy for the built-in error boundary fallback. */
|
|
580
|
+
errorBoundaryFallback: string;
|
|
581
|
+
/** Heading when init reports disclosures are required and not yet accepted. */
|
|
582
|
+
disclosuresRequiredTitle: string;
|
|
583
|
+
/** Heading while a token-only refresh leaves init stale for the live token. */
|
|
584
|
+
disclosuresRefreshingTitle: string;
|
|
585
|
+
/** Supporting copy while the accept action is withheld for a stale init. */
|
|
586
|
+
disclosuresRefreshingDescription: string;
|
|
587
|
+
}
|
|
588
|
+
|
|
569
589
|
/**
|
|
570
590
|
* Props for {@link WidgetProvider}.
|
|
571
591
|
*
|
|
@@ -578,8 +598,8 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
578
598
|
* Fallback rendered when a render-time exception is caught inside this
|
|
579
599
|
* provider's subtree. Pass either a `ReactNode` (rendered directly) or a
|
|
580
600
|
* render-prop receiving `{ error, resetErrorBoundary }` from
|
|
581
|
-
* `react-error-boundary`. Default is a plain `role="alert"` div
|
|
582
|
-
*
|
|
601
|
+
* `react-error-boundary`. Default is a plain `role="alert"` div whose copy
|
|
602
|
+
* comes from `providerLabels.errorBoundaryFallback`.
|
|
583
603
|
*/
|
|
584
604
|
errorFallback?: ReactNode | ((props: FallbackProps) => ReactNode);
|
|
585
605
|
/**
|
|
@@ -596,6 +616,15 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
596
616
|
* WidgetProvider cannot import the widget itself (cycle).
|
|
597
617
|
*/
|
|
598
618
|
disclosuresAcceptance?: ReactNode;
|
|
619
|
+
/**
|
|
620
|
+
* Overrides for the copy this provider renders in place of the widget: the
|
|
621
|
+
* built-in error-boundary fallback and the disclosures gate. Any subset;
|
|
622
|
+
* unlisted keys keep their defaults. Cascades like `linkComponent`.
|
|
623
|
+
*
|
|
624
|
+
* Named `providerLabels` rather than `labels` because a widget's own
|
|
625
|
+
* `labels` prop sits alongside this one on the same props type.
|
|
626
|
+
*/
|
|
627
|
+
providerLabels?: Partial<WidgetProviderLabels>;
|
|
599
628
|
}
|
|
600
629
|
|
|
601
630
|
type ReceiptMatchWidgetProps = WidgetProviderProps & {
|
|
@@ -605,7 +634,7 @@ type ReceiptMatchWidgetProps = WidgetProviderProps & {
|
|
|
605
634
|
targetTransactionId?: string;
|
|
606
635
|
onSingleTransactionUpdate?: () => void;
|
|
607
636
|
};
|
|
608
|
-
declare function ReceiptMatchWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, disclosuresAcceptance, isOpen, preSelectedReceiptIds, onClose, targetTransactionId, onSingleTransactionUpdate, }: ReceiptMatchWidgetProps): React.JSX.Element;
|
|
637
|
+
declare function ReceiptMatchWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, disclosuresAcceptance, providerLabels, isOpen, preSelectedReceiptIds, onClose, targetTransactionId, onSingleTransactionUpdate, }: ReceiptMatchWidgetProps): React.JSX.Element;
|
|
609
638
|
|
|
610
639
|
export { ReceiptMatchWidget };
|
|
611
640
|
export type { ReceiptMatchWidgetProps };
|
|
@@ -573,6 +573,26 @@ interface WidgetProviderBaseProps extends WidgetConfigInput {
|
|
|
573
573
|
analytics?: boolean;
|
|
574
574
|
}
|
|
575
575
|
|
|
576
|
+
/**
|
|
577
|
+
* Copy for the states `WidgetProvider` renders *itself*, in place of the widget:
|
|
578
|
+
* the error-boundary fallback and the disclosures gate. A host overrides any
|
|
579
|
+
* subset through the `providerLabels` prop, which cascades like
|
|
580
|
+
* `disclosuresAcceptance`.
|
|
581
|
+
*
|
|
582
|
+
* Not named `Labels` on the public surface: a widget's own `labels` prop is a
|
|
583
|
+
* different thing, and these two travel together on every widget's props type.
|
|
584
|
+
*/
|
|
585
|
+
interface WidgetProviderLabels {
|
|
586
|
+
/** Default copy for the built-in error boundary fallback. */
|
|
587
|
+
errorBoundaryFallback: string;
|
|
588
|
+
/** Heading when init reports disclosures are required and not yet accepted. */
|
|
589
|
+
disclosuresRequiredTitle: string;
|
|
590
|
+
/** Heading while a token-only refresh leaves init stale for the live token. */
|
|
591
|
+
disclosuresRefreshingTitle: string;
|
|
592
|
+
/** Supporting copy while the accept action is withheld for a stale init. */
|
|
593
|
+
disclosuresRefreshingDescription: string;
|
|
594
|
+
}
|
|
595
|
+
|
|
576
596
|
/**
|
|
577
597
|
* Props for {@link WidgetProvider}.
|
|
578
598
|
*
|
|
@@ -585,8 +605,8 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
585
605
|
* Fallback rendered when a render-time exception is caught inside this
|
|
586
606
|
* provider's subtree. Pass either a `ReactNode` (rendered directly) or a
|
|
587
607
|
* render-prop receiving `{ error, resetErrorBoundary }` from
|
|
588
|
-
* `react-error-boundary`. Default is a plain `role="alert"` div
|
|
589
|
-
*
|
|
608
|
+
* `react-error-boundary`. Default is a plain `role="alert"` div whose copy
|
|
609
|
+
* comes from `providerLabels.errorBoundaryFallback`.
|
|
590
610
|
*/
|
|
591
611
|
errorFallback?: ReactNode | ((props: FallbackProps) => ReactNode);
|
|
592
612
|
/**
|
|
@@ -603,6 +623,15 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
603
623
|
* WidgetProvider cannot import the widget itself (cycle).
|
|
604
624
|
*/
|
|
605
625
|
disclosuresAcceptance?: ReactNode;
|
|
626
|
+
/**
|
|
627
|
+
* Overrides for the copy this provider renders in place of the widget: the
|
|
628
|
+
* built-in error-boundary fallback and the disclosures gate. Any subset;
|
|
629
|
+
* unlisted keys keep their defaults. Cascades like `linkComponent`.
|
|
630
|
+
*
|
|
631
|
+
* Named `providerLabels` rather than `labels` because a widget's own
|
|
632
|
+
* `labels` prop sits alongside this one on the same props type.
|
|
633
|
+
*/
|
|
634
|
+
providerLabels?: Partial<WidgetProviderLabels>;
|
|
606
635
|
}
|
|
607
636
|
|
|
608
637
|
interface AddressFieldGroupLabels {
|
|
@@ -1028,7 +1057,7 @@ interface ReceivablesWidgetOwnProps {
|
|
|
1028
1057
|
}
|
|
1029
1058
|
type ReceivablesWidgetProps = WidgetProviderProps & ReceivablesWidgetOwnProps;
|
|
1030
1059
|
|
|
1031
|
-
declare function ReceivablesWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, ...innerProps }: ReceivablesWidgetProps): React.JSX.Element;
|
|
1060
|
+
declare function ReceivablesWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, providerLabels, ...innerProps }: ReceivablesWidgetProps): React.JSX.Element;
|
|
1032
1061
|
|
|
1033
1062
|
export { ReceivablesWidget };
|
|
1034
1063
|
export type { CounterpartFormSheetLabels, CounterpartMessageLabels, MeasureUnitDeleteDialogLabels, MeasureUnitsManagerLabels, ProductFormSheetLabels, ProductMessageLabels, ReceivableActionDialogLabels, ReceivableDetailsSheetLabelOverrides, ReceivableDetailsSheetLabels, ReceivableDocumentType, ReceivableFormSheetLabels, ReceivableMessageLabels, ReceivablePaymentDialogLabels, ReceivableSendDialogLabels, ReceivableStatusBadgeLabels, ReceivablesScreenLabelOverrides, ReceivablesScreenLabels, ReceivablesWidgetProps, ReceivablesWidgetTab };
|
|
@@ -584,6 +584,26 @@ interface WidgetProviderBaseProps extends WidgetConfigInput {
|
|
|
584
584
|
analytics?: boolean;
|
|
585
585
|
}
|
|
586
586
|
|
|
587
|
+
/**
|
|
588
|
+
* Copy for the states `WidgetProvider` renders *itself*, in place of the widget:
|
|
589
|
+
* the error-boundary fallback and the disclosures gate. A host overrides any
|
|
590
|
+
* subset through the `providerLabels` prop, which cascades like
|
|
591
|
+
* `disclosuresAcceptance`.
|
|
592
|
+
*
|
|
593
|
+
* Not named `Labels` on the public surface: a widget's own `labels` prop is a
|
|
594
|
+
* different thing, and these two travel together on every widget's props type.
|
|
595
|
+
*/
|
|
596
|
+
interface WidgetProviderLabels {
|
|
597
|
+
/** Default copy for the built-in error boundary fallback. */
|
|
598
|
+
errorBoundaryFallback: string;
|
|
599
|
+
/** Heading when init reports disclosures are required and not yet accepted. */
|
|
600
|
+
disclosuresRequiredTitle: string;
|
|
601
|
+
/** Heading while a token-only refresh leaves init stale for the live token. */
|
|
602
|
+
disclosuresRefreshingTitle: string;
|
|
603
|
+
/** Supporting copy while the accept action is withheld for a stale init. */
|
|
604
|
+
disclosuresRefreshingDescription: string;
|
|
605
|
+
}
|
|
606
|
+
|
|
587
607
|
/**
|
|
588
608
|
* Props for {@link WidgetProvider}.
|
|
589
609
|
*
|
|
@@ -596,8 +616,8 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
596
616
|
* Fallback rendered when a render-time exception is caught inside this
|
|
597
617
|
* provider's subtree. Pass either a `ReactNode` (rendered directly) or a
|
|
598
618
|
* render-prop receiving `{ error, resetErrorBoundary }` from
|
|
599
|
-
* `react-error-boundary`. Default is a plain `role="alert"` div
|
|
600
|
-
*
|
|
619
|
+
* `react-error-boundary`. Default is a plain `role="alert"` div whose copy
|
|
620
|
+
* comes from `providerLabels.errorBoundaryFallback`.
|
|
601
621
|
*/
|
|
602
622
|
errorFallback?: ReactNode | ((props: FallbackProps) => ReactNode);
|
|
603
623
|
/**
|
|
@@ -614,6 +634,15 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
614
634
|
* WidgetProvider cannot import the widget itself (cycle).
|
|
615
635
|
*/
|
|
616
636
|
disclosuresAcceptance?: ReactNode;
|
|
637
|
+
/**
|
|
638
|
+
* Overrides for the copy this provider renders in place of the widget: the
|
|
639
|
+
* built-in error-boundary fallback and the disclosures gate. Any subset;
|
|
640
|
+
* unlisted keys keep their defaults. Cascades like `linkComponent`.
|
|
641
|
+
*
|
|
642
|
+
* Named `providerLabels` rather than `labels` because a widget's own
|
|
643
|
+
* `labels` prop sits alongside this one on the same props type.
|
|
644
|
+
*/
|
|
645
|
+
providerLabels?: Partial<WidgetProviderLabels>;
|
|
617
646
|
}
|
|
618
647
|
|
|
619
648
|
type MoniteRegionProviderProps = WidgetProviderProps & MoniteWrapperProps;
|
|
@@ -718,7 +747,7 @@ interface SettingsWidgetProps extends MoniteRegionProviderProps {
|
|
|
718
747
|
tagsContent?: ReactNode;
|
|
719
748
|
invoiceContent?: ReactNode;
|
|
720
749
|
}
|
|
721
|
-
declare function SettingsWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, finopsThemeColors, analytics, disclosuresAcceptance, ...innerProps }: SettingsWidgetProps): React.JSX.Element;
|
|
750
|
+
declare function SettingsWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, finopsThemeColors, analytics, disclosuresAcceptance, providerLabels, ...innerProps }: SettingsWidgetProps): React.JSX.Element;
|
|
722
751
|
|
|
723
752
|
export { SettingsSection, SettingsWidget };
|
|
724
753
|
export type { SettingsWidgetAdditionalSection, FeatureLabels as SettingsWidgetFeatureLabels, Labels as SettingsWidgetLabels, SettingsWidgetProps, SettingsWidgetSection, SettingsWidgetSectionId };
|
package/dist/lib/TagsWidget.d.ts
CHANGED
|
@@ -566,6 +566,26 @@ interface WidgetProviderBaseProps extends WidgetConfigInput {
|
|
|
566
566
|
analytics?: boolean;
|
|
567
567
|
}
|
|
568
568
|
|
|
569
|
+
/**
|
|
570
|
+
* Copy for the states `WidgetProvider` renders *itself*, in place of the widget:
|
|
571
|
+
* the error-boundary fallback and the disclosures gate. A host overrides any
|
|
572
|
+
* subset through the `providerLabels` prop, which cascades like
|
|
573
|
+
* `disclosuresAcceptance`.
|
|
574
|
+
*
|
|
575
|
+
* Not named `Labels` on the public surface: a widget's own `labels` prop is a
|
|
576
|
+
* different thing, and these two travel together on every widget's props type.
|
|
577
|
+
*/
|
|
578
|
+
interface WidgetProviderLabels {
|
|
579
|
+
/** Default copy for the built-in error boundary fallback. */
|
|
580
|
+
errorBoundaryFallback: string;
|
|
581
|
+
/** Heading when init reports disclosures are required and not yet accepted. */
|
|
582
|
+
disclosuresRequiredTitle: string;
|
|
583
|
+
/** Heading while a token-only refresh leaves init stale for the live token. */
|
|
584
|
+
disclosuresRefreshingTitle: string;
|
|
585
|
+
/** Supporting copy while the accept action is withheld for a stale init. */
|
|
586
|
+
disclosuresRefreshingDescription: string;
|
|
587
|
+
}
|
|
588
|
+
|
|
569
589
|
/**
|
|
570
590
|
* Props for {@link WidgetProvider}.
|
|
571
591
|
*
|
|
@@ -578,8 +598,8 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
578
598
|
* Fallback rendered when a render-time exception is caught inside this
|
|
579
599
|
* provider's subtree. Pass either a `ReactNode` (rendered directly) or a
|
|
580
600
|
* render-prop receiving `{ error, resetErrorBoundary }` from
|
|
581
|
-
* `react-error-boundary`. Default is a plain `role="alert"` div
|
|
582
|
-
*
|
|
601
|
+
* `react-error-boundary`. Default is a plain `role="alert"` div whose copy
|
|
602
|
+
* comes from `providerLabels.errorBoundaryFallback`.
|
|
583
603
|
*/
|
|
584
604
|
errorFallback?: ReactNode | ((props: FallbackProps) => ReactNode);
|
|
585
605
|
/**
|
|
@@ -596,6 +616,15 @@ interface WidgetProviderProps extends WidgetProviderBaseProps {
|
|
|
596
616
|
* WidgetProvider cannot import the widget itself (cycle).
|
|
597
617
|
*/
|
|
598
618
|
disclosuresAcceptance?: ReactNode;
|
|
619
|
+
/**
|
|
620
|
+
* Overrides for the copy this provider renders in place of the widget: the
|
|
621
|
+
* built-in error-boundary fallback and the disclosures gate. Any subset;
|
|
622
|
+
* unlisted keys keep their defaults. Cascades like `linkComponent`.
|
|
623
|
+
*
|
|
624
|
+
* Named `providerLabels` rather than `labels` because a widget's own
|
|
625
|
+
* `labels` prop sits alongside this one on the same props type.
|
|
626
|
+
*/
|
|
627
|
+
providerLabels?: Partial<WidgetProviderLabels>;
|
|
599
628
|
}
|
|
600
629
|
|
|
601
630
|
/**
|
|
@@ -684,7 +713,7 @@ type TagsWidgetProps = WidgetProviderProps & TagsWidgetOwnProps;
|
|
|
684
713
|
* <TagsWidget baseUrl="https://api.tesouro.com" widgetToken="wt_..." organizationId="org_..." />
|
|
685
714
|
* ```
|
|
686
715
|
*/
|
|
687
|
-
declare function TagsWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, ...innerProps }: TagsWidgetProps): React.JSX.Element;
|
|
716
|
+
declare function TagsWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, providerLabels, ...innerProps }: TagsWidgetProps): React.JSX.Element;
|
|
688
717
|
|
|
689
718
|
export { TagsWidget };
|
|
690
719
|
export type { TagDeleteDialogLabels, TagFormSheetLabels, TagMessageLabels, TagsScreenLabels, TagsWidgetProps };
|