@tesouro/embedded-components-react 0.11.169 → 0.11.172
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 -6
- package/dist/index.d.ts +15 -4
- package/dist/lib/BillPayWidget.d.ts +9 -4
- package/dist/lib/ReceivablesWidget.d.ts +6 -0
- package/dist/lib/WidgetSuite.d.ts +6 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index26.js +75 -66
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index27.js +62 -53
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index31.js +44 -38
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index44.js +331 -326
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index46.js +10 -8
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index47.js +190 -187
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index14.js +12 -19
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index15.js +25 -23
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index33.js +4 -7
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index34.js +23 -24
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index5.js +5 -5
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bills-list/feature/dist/index16.js +196 -187
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bills-list/feature/dist/index17.js +8 -5
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bills-list/feature/dist/index8.js +20 -18
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bills-list/ui/dist/index18.js +11 -15
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bills-list/ui/dist/index20.js +313 -324
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/lib/BillPayWidget/BillPayWidget.js +46 -38
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/lib/BillPayWidget/BillsTab.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/ui/dist/index5.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/ui/dist/index6.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index.js +4 -8
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index13.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index14.js +45 -22
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index20.js +5 -27
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index21.js +32 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index22.js +2 -29
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/util/dist/index.js +7 -6
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/util/dist/lib/resolveBillDueDate.js +22 -0
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/lib/ReceivablesWidget/details.js +116 -98
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/lib/ReceivablesWidget/helpers.js +99 -92
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/lib/ReceivablesWidget/labels.js +7 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/lib/ReceivablesWidget/recurringSeries.js +15 -24
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index60.js +59 -69
- 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/ui/dist/index.js +7 -5
- package/dist/libs/tesouro-embedded-components-react/shared/ui/dist/lib/DateDisclosure/DateDisclosure.js +28 -0
- package/dist/libs/tesouro-embedded-components-react/shared/ui/dist/lib/DueDateText/DueDateText.js +19 -0
- package/dist/libs/tesouro-embedded-components-react/shared/util/dist/index.js +28 -27
- package/dist/libs/tesouro-embedded-components-react/shared/util/dist/lib/dueDateDisplay.js +23 -0
- package/package.json +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index23.js +0 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index24.js +0 -6
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index25.js +0 -33
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index26.js +0 -2
package/README.md
CHANGED
|
@@ -491,14 +491,18 @@ Shows "Business Banking provided by" the business customer's bank, plus the FDIC
|
|
|
491
491
|
|
|
492
492
|
A bill pay widget with Tesouro widget auth and theming: a Bills tab for uploading, reviewing and paying bills, and a Vendors tab for the vendors they are paid to.
|
|
493
493
|
|
|
494
|
+
The right end of the tab row holds the active tab's main action: Add bill on Bills and Add vendor on Vendors. While the vendor list is empty, Add vendor shows only in its empty state.
|
|
495
|
+
|
|
494
496
|
#### Props
|
|
495
497
|
|
|
496
|
-
| Prop | Type
|
|
497
|
-
| ------------------- |
|
|
498
|
-
| `initialTab` | `'bills' \| 'vendors'`
|
|
499
|
-
| `
|
|
500
|
-
| `
|
|
501
|
-
| `
|
|
498
|
+
| Prop | Type | Default | Description |
|
|
499
|
+
| ------------------- | ----------------------------------- | ----------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
500
|
+
| `initialTab` | `'bills' \| 'vendors'` | `'bills'` | Tab to open on initial mount when `selectedTab` is omitted. |
|
|
501
|
+
| `selectedTab` | `BillPayWidgetTabId` | `undefined` | The active tab: `'bills'` or `'vendors'`. Omit to let the widget track it, starting on `initialTab`. |
|
|
502
|
+
| `onTabChange` | `(tab: BillPayWidgetTabId) => void` | `undefined` | Called when the active tab changes, from a tab click or a vendor's "View all" or "Add a bill" opening the Bills tab, so you can keep it in the URL. |
|
|
503
|
+
| `initialView` | `'create'` | `undefined` | Opens the Bills tab's "Add a bill" dialog once on arrival, when the user can create bills. Closing it does not reopen it. Ignored when the widget opens on Vendors. |
|
|
504
|
+
| `poweredByBankName` | `string` | `undefined` | Bank shown as "Powered by {bank}" next to the source account when paying a bill. Omit it to hide the badge. |
|
|
505
|
+
| `onSettingsClick` | `() => void` | `undefined` | Opens your bill pay settings surface from a cog on the tab row, beside the active tab's add button. The cog renders only when this is supplied and the user's scopes reach that surface. |
|
|
502
506
|
|
|
503
507
|
### CreditCardsWidget
|
|
504
508
|
|
package/dist/index.d.ts
CHANGED
|
@@ -4802,11 +4802,17 @@ interface ReceivableMessageLabels {
|
|
|
4802
4802
|
detailsPeriodMonth: string;
|
|
4803
4803
|
detailsPeriodQuarter: string;
|
|
4804
4804
|
detailsPeriodYear: string;
|
|
4805
|
+
detailsPeriodEveryDays: string;
|
|
4806
|
+
detailsPeriodEveryWeeks: string;
|
|
4807
|
+
detailsPeriodEveryMonths: string;
|
|
4808
|
+
detailsPeriodEveryQuarters: string;
|
|
4809
|
+
detailsPeriodEveryYears: string;
|
|
4805
4810
|
/** `{name}` and `{frequency}` are replaced, e.g. "Acme - Monthly". */
|
|
4806
4811
|
detailsSeriesTitle: string;
|
|
4807
4812
|
detailsSeriesSubtitle: string;
|
|
4808
4813
|
/** `{frequency}` is replaced, e.g. "Monthly schedule". */
|
|
4809
4814
|
detailsScheduleTitle: string;
|
|
4815
|
+
detailsScheduleTitleEvery: string;
|
|
4810
4816
|
/** `{title}` is replaced with the series title. */
|
|
4811
4817
|
detailsSeriesBack: string;
|
|
4812
4818
|
/** `{number}` is replaced with the invoice number. */
|
|
@@ -6359,8 +6365,12 @@ declare const TabId: {
|
|
|
6359
6365
|
};
|
|
6360
6366
|
type BillPayWidgetTabId = (typeof TabId)[keyof typeof TabId];
|
|
6361
6367
|
interface BillPayWidgetProps extends WidgetProviderProps {
|
|
6362
|
-
/** Tab to open on initial mount. */
|
|
6368
|
+
/** Tab to open on initial mount when `selectedTab` is omitted. */
|
|
6363
6369
|
initialTab?: BillPayWidgetTabId;
|
|
6370
|
+
/** The active tab, for a host that keeps it in its URL. Omit to let the widget track it. */
|
|
6371
|
+
selectedTab?: BillPayWidgetTabId;
|
|
6372
|
+
/** Called when the widget switches tab, from a tab click or a handoff into Bills. */
|
|
6373
|
+
onTabChange?: (tab: BillPayWidgetTabId) => void;
|
|
6364
6374
|
/**
|
|
6365
6375
|
* Opens the Bills tab's Add a bill dialog on arrival, for a host deep link
|
|
6366
6376
|
* such as `?create=1` (EMBD-7011). Named like `ReceivablesWidget`'s
|
|
@@ -6374,8 +6384,9 @@ interface BillPayWidgetProps extends WidgetProviderProps {
|
|
|
6374
6384
|
/** Bank shown as "Powered by {bank}" next to the source account when paying; omitted hides the badge. */
|
|
6375
6385
|
poweredByBankName?: string;
|
|
6376
6386
|
/**
|
|
6377
|
-
* Opens the host's bill-pay settings surface, from a cog
|
|
6378
|
-
* tab's
|
|
6387
|
+
* Opens the host's bill-pay settings surface, from a cog on the tab row
|
|
6388
|
+
* beside the active tab's add button. Only rendered for a user whose scopes
|
|
6389
|
+
* reach it.
|
|
6379
6390
|
*/
|
|
6380
6391
|
onSettingsClick?: () => void;
|
|
6381
6392
|
}
|
|
@@ -6643,4 +6654,4 @@ interface CheckAmountAndDetailScreenProps {
|
|
|
6643
6654
|
type PendingFeatureStyleSources = CheckAmountAndDetailScreenProps | GapCoverageAlertProps | NoPolicyBannerProps;
|
|
6644
6655
|
|
|
6645
6656
|
export { ACCEPT_DISCLOSURES_WIDGET_LABELS_EN, ADDITIONAL_OWNERS_LABELS_EN, APPLICATION_STATUS_LABELS_EN, AcceptDisclosuresWidget, BALANCES_WIDGET_LABELS_EN, BANKING_COMPLIANCE_BANNER_LABELS_EN, BUSINESS_DETAILS_LABELS_EN, BalancesWidget, BankAccountOnboardingWidget, BankAccountsWidget, BankingComplianceBannerWidget, BillPayWidget, CardDetailsWidget, CounterpartsWidget, CreditCardsWidget, DebitCardsWidget, ERROR_STATE_ID, ExpenseManagementWidget, HELP_FAQ_EN, INSIGHTS_FEATURE_LABELS_EN, INSIGHTS_WIDGET_LABELS_EN, InsightsWidget, InvoicingTab, LinkedAccountsWidget, OFFER_WIDGET_LABELS_EN, OFFER_WIDGET_STATUS_LABELS_EN, OfferBenefitIcon, OfferWidget, OnboardingSuppressionReason, PERSONAL_DETAILS_LABELS_EN, RESULT_LABELS_EN, ReceivableStatusCard, ReceivablesWidget, RefreshingRootWidgetProvider, RootWidgetProvider, SINGLE_INSIGHT_LABELS_EN, Scope, SettingsSection, SettingsWidget, THEME_TOKEN_NAMES, 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, configureCsp, createTheme, getGlobalWidgetConfig, getGlobalWidgetInitState, isScope, registerDesignSystemEnsurer, registerUIRenderers, setGlobalWidgetConfig, subscribeToGlobalWidgetInitState, themeIssues, themeToCss, updateGlobalWidgetConfig, useDisclosuresAcceptanceSurface, useOwnWidgetConfig, useRefetchWidget, useWidgetConfig, useWidgetError, useWidgetInitStaleForToken, useWidgetLoading, useWidgetToken };
|
|
6646
|
-
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, BankingComplianceBannerLabels, BankingComplianceBannerWidgetProps, BillPayWidgetProps, BusinessDetailsLabels, BusinessDetailsValues, CardDetailsFeatureLabels, CardDetailsPanelLabels as CardDetailsWidgetLabels, CardDetailsWidgetProps, CardsFeatureLabels, CardsListLabels as CardsLabels, CardsPagination, CompanyStructureValue, ConfirmDeleteDialogLabels, CounterpartActionTarget, CounterpartDetailsSheetLabels, CounterpartFormSheetLabels, CounterpartMessageLabels, CounterpartMode, CounterpartsScreenLabels, CounterpartsWidgetProps, CreditCardsWidgetProps, CspConfig, DebitCardsWidgetProps, DisclosureLinks, EmbeddedClient, Labels$2 as ExpenseManagementWidgetLabels, ExpenseManagementWidgetProps, ExpenseStatusBadgeLabels, FileViewerLabels, HelpFaqAnswer, HelpFaqBullet, HelpFaqBulletType, HelpFaqItem, HelpFaqSection, InsightsFeatureLabels, InsightsWidgetLabels, InsightsWidgetProps, InvoicesFilterBarLabelOverrides, InvoicesFilterBarLabels, InvoicesFilterLabelOverrides, InvoicesFilterLabels, InvoicingTabId, InvoicingTabLabels, 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, ProductFormSheetLabels, ProductMessageLabels, ReceivableActionDialogLabels, ReceivableActionsModalLabels, ReceivableAuditHistoryLabels, ReceivableDetailsPanelLabelOverrides, ReceivableDetailsPanelLabels, ReceivableDocumentType, ReceivableFormDialogLabels, ReceivableFormSheetLabels, ReceivableMessageLabels, ReceivablePaymentDialogLabels, ReceivablePreviewLabels, ReceivableStatusBadgeLabels, ReceivablesScreenLabelOverrides, ReceivablesScreenLabels, ReceivablesWidgetProps, RecurringSeriesScreenLabelOverrides, RecurringSeriesScreenLabels, RefreshingRootWidgetProviderProps, ResultLabels, RootWidgetProviderProps, SettingsWidgetAdditionalSection, FeatureLabels$1 as SettingsWidgetFeatureLabels, Labels as SettingsWidgetLabels, SettingsWidgetProps, SettingsWidgetSection, SettingsWidgetSectionId, SingleInsightLabels, ThemeInput, ThemeIssue, ThemeTokenKey, ThemeTokenName, ThemeTokens, TransactionDetailsActionsLabels, TransactionDetailsLabels, FeatureLabels as TransfersWidgetFeatureLabels, TransfersWidgetLabels, TransfersWidgetProps, WidgetConfig, WidgetConfigInput, WidgetInitResponse, WidgetInitState, WidgetProviderLabels, WidgetProviderProps, WidgetSuiteCardsLabels, WidgetSuiteDashboardLabels, WidgetSuiteDisclosureLabels, WidgetSuiteExpensesLabels, WidgetSuiteInvoicingLabels, WidgetSuiteLabelOverrides, WidgetSuiteLabels, WidgetSuiteMenuLabels, WidgetSuiteOnboardingGateLabels, WidgetSuiteOnboardingLabels, WidgetSuiteProps, WidgetSuiteQuickActionsLabels, WidgetSuiteSectionContentLabels, WidgetSuiteSectionTitleLabels, WidgetTokenFetcher, WidgetTokenManager, WidgetTokenRefreshProviderProps, WidgetTokenState };
|
|
6657
|
+
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, BankingComplianceBannerLabels, BankingComplianceBannerWidgetProps, BillPayWidgetProps, BillPayWidgetTabId, BusinessDetailsLabels, BusinessDetailsValues, CardDetailsFeatureLabels, CardDetailsPanelLabels as CardDetailsWidgetLabels, CardDetailsWidgetProps, CardsFeatureLabels, CardsListLabels as CardsLabels, CardsPagination, CompanyStructureValue, ConfirmDeleteDialogLabels, CounterpartActionTarget, CounterpartDetailsSheetLabels, CounterpartFormSheetLabels, CounterpartMessageLabels, CounterpartMode, CounterpartsScreenLabels, CounterpartsWidgetProps, CreditCardsWidgetProps, CspConfig, DebitCardsWidgetProps, DisclosureLinks, EmbeddedClient, Labels$2 as ExpenseManagementWidgetLabels, ExpenseManagementWidgetProps, ExpenseStatusBadgeLabels, FileViewerLabels, HelpFaqAnswer, HelpFaqBullet, HelpFaqBulletType, HelpFaqItem, HelpFaqSection, InsightsFeatureLabels, InsightsWidgetLabels, InsightsWidgetProps, InvoicesFilterBarLabelOverrides, InvoicesFilterBarLabels, InvoicesFilterLabelOverrides, InvoicesFilterLabels, InvoicingTabId, InvoicingTabLabels, 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, ProductFormSheetLabels, ProductMessageLabels, ReceivableActionDialogLabels, ReceivableActionsModalLabels, ReceivableAuditHistoryLabels, ReceivableDetailsPanelLabelOverrides, ReceivableDetailsPanelLabels, ReceivableDocumentType, ReceivableFormDialogLabels, ReceivableFormSheetLabels, ReceivableMessageLabels, ReceivablePaymentDialogLabels, ReceivablePreviewLabels, ReceivableStatusBadgeLabels, ReceivablesScreenLabelOverrides, ReceivablesScreenLabels, ReceivablesWidgetProps, RecurringSeriesScreenLabelOverrides, RecurringSeriesScreenLabels, RefreshingRootWidgetProviderProps, ResultLabels, RootWidgetProviderProps, SettingsWidgetAdditionalSection, FeatureLabels$1 as SettingsWidgetFeatureLabels, Labels as SettingsWidgetLabels, SettingsWidgetProps, SettingsWidgetSection, SettingsWidgetSectionId, SingleInsightLabels, ThemeInput, ThemeIssue, ThemeTokenKey, ThemeTokenName, ThemeTokens, TransactionDetailsActionsLabels, TransactionDetailsLabels, FeatureLabels as TransfersWidgetFeatureLabels, TransfersWidgetLabels, TransfersWidgetProps, WidgetConfig, WidgetConfigInput, WidgetInitResponse, WidgetInitState, WidgetProviderLabels, WidgetProviderProps, WidgetSuiteCardsLabels, WidgetSuiteDashboardLabels, WidgetSuiteDisclosureLabels, WidgetSuiteExpensesLabels, WidgetSuiteInvoicingLabels, WidgetSuiteLabelOverrides, WidgetSuiteLabels, WidgetSuiteMenuLabels, WidgetSuiteOnboardingGateLabels, WidgetSuiteOnboardingLabels, WidgetSuiteProps, WidgetSuiteQuickActionsLabels, WidgetSuiteSectionContentLabels, WidgetSuiteSectionTitleLabels, WidgetTokenFetcher, WidgetTokenManager, WidgetTokenRefreshProviderProps, WidgetTokenState };
|
|
@@ -601,8 +601,12 @@ declare const TabId: {
|
|
|
601
601
|
};
|
|
602
602
|
type BillPayWidgetTabId = (typeof TabId)[keyof typeof TabId];
|
|
603
603
|
interface BillPayWidgetProps extends WidgetProviderProps {
|
|
604
|
-
/** Tab to open on initial mount. */
|
|
604
|
+
/** Tab to open on initial mount when `selectedTab` is omitted. */
|
|
605
605
|
initialTab?: BillPayWidgetTabId;
|
|
606
|
+
/** The active tab, for a host that keeps it in its URL. Omit to let the widget track it. */
|
|
607
|
+
selectedTab?: BillPayWidgetTabId;
|
|
608
|
+
/** Called when the widget switches tab, from a tab click or a handoff into Bills. */
|
|
609
|
+
onTabChange?: (tab: BillPayWidgetTabId) => void;
|
|
606
610
|
/**
|
|
607
611
|
* Opens the Bills tab's Add a bill dialog on arrival, for a host deep link
|
|
608
612
|
* such as `?create=1` (EMBD-7011). Named like `ReceivablesWidget`'s
|
|
@@ -616,12 +620,13 @@ interface BillPayWidgetProps extends WidgetProviderProps {
|
|
|
616
620
|
/** Bank shown as "Powered by {bank}" next to the source account when paying; omitted hides the badge. */
|
|
617
621
|
poweredByBankName?: string;
|
|
618
622
|
/**
|
|
619
|
-
* Opens the host's bill-pay settings surface, from a cog
|
|
620
|
-
* tab's
|
|
623
|
+
* Opens the host's bill-pay settings surface, from a cog on the tab row
|
|
624
|
+
* beside the active tab's add button. Only rendered for a user whose scopes
|
|
625
|
+
* reach it.
|
|
621
626
|
*/
|
|
622
627
|
onSettingsClick?: () => void;
|
|
623
628
|
}
|
|
624
629
|
declare const BillPayWidget: (props: BillPayWidgetProps) => ReactElement;
|
|
625
630
|
|
|
626
631
|
export { BillPayWidget };
|
|
627
|
-
export type { BillPayWidgetProps };
|
|
632
|
+
export type { BillPayWidgetProps, BillPayWidgetTabId };
|
|
@@ -1545,11 +1545,17 @@ interface ReceivableMessageLabels {
|
|
|
1545
1545
|
detailsPeriodMonth: string;
|
|
1546
1546
|
detailsPeriodQuarter: string;
|
|
1547
1547
|
detailsPeriodYear: string;
|
|
1548
|
+
detailsPeriodEveryDays: string;
|
|
1549
|
+
detailsPeriodEveryWeeks: string;
|
|
1550
|
+
detailsPeriodEveryMonths: string;
|
|
1551
|
+
detailsPeriodEveryQuarters: string;
|
|
1552
|
+
detailsPeriodEveryYears: string;
|
|
1548
1553
|
/** `{name}` and `{frequency}` are replaced, e.g. "Acme - Monthly". */
|
|
1549
1554
|
detailsSeriesTitle: string;
|
|
1550
1555
|
detailsSeriesSubtitle: string;
|
|
1551
1556
|
/** `{frequency}` is replaced, e.g. "Monthly schedule". */
|
|
1552
1557
|
detailsScheduleTitle: string;
|
|
1558
|
+
detailsScheduleTitleEvery: string;
|
|
1553
1559
|
/** `{title}` is replaced with the series title. */
|
|
1554
1560
|
detailsSeriesBack: string;
|
|
1555
1561
|
/** `{number}` is replaced with the invoice number. */
|
|
@@ -3700,11 +3700,17 @@ interface ReceivableMessageLabels {
|
|
|
3700
3700
|
detailsPeriodMonth: string;
|
|
3701
3701
|
detailsPeriodQuarter: string;
|
|
3702
3702
|
detailsPeriodYear: string;
|
|
3703
|
+
detailsPeriodEveryDays: string;
|
|
3704
|
+
detailsPeriodEveryWeeks: string;
|
|
3705
|
+
detailsPeriodEveryMonths: string;
|
|
3706
|
+
detailsPeriodEveryQuarters: string;
|
|
3707
|
+
detailsPeriodEveryYears: string;
|
|
3703
3708
|
/** `{name}` and `{frequency}` are replaced, e.g. "Acme - Monthly". */
|
|
3704
3709
|
detailsSeriesTitle: string;
|
|
3705
3710
|
detailsSeriesSubtitle: string;
|
|
3706
3711
|
/** `{frequency}` is replaced, e.g. "Monthly schedule". */
|
|
3707
3712
|
detailsScheduleTitle: string;
|
|
3713
|
+
detailsScheduleTitleEvery: string;
|
|
3708
3714
|
/** `{title}` is replaced with the series title. */
|
|
3709
3715
|
detailsSeriesBack: string;
|
|
3710
3716
|
/** `{number}` is replaced with the invoice number. */
|
|
@@ -1,103 +1,112 @@
|
|
|
1
1
|
import { formatCalendarDate as e } from "../../../../shared/util/dist/lib/formatCalendarDate.js";
|
|
2
2
|
import "../../../../shared/util/dist/index.js";
|
|
3
3
|
import { formatBillMoney as t } from "../../../util/dist/lib/formatBillMoney.js";
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
4
|
+
import { resolveBillDueDate as n } from "../../../util/dist/lib/resolveBillDueDate.js";
|
|
5
|
+
import { resolveLineItemAmountMinorUnits as r } from "../../../util/dist/lib/resolveLineItemAmount.js";
|
|
6
|
+
import { resolveLineItemQuantity as i } from "../../../util/dist/lib/resolveLineItemQuantity.js";
|
|
7
|
+
import { resolveVendor as a, resolveVendorName as o } from "../../../util/dist/lib/resolveVendor.js";
|
|
7
8
|
import "../../../util/dist/index.js";
|
|
8
|
-
import { formatGlCodeLabel as
|
|
9
|
-
import { derivePayableStatus as
|
|
9
|
+
import { formatGlCodeLabel as s } from "./index15.js";
|
|
10
|
+
import { derivePayableStatus as c } from "../../../../shared/document-status/util/dist/lib/derivePayableStatus.js";
|
|
10
11
|
// ../../libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index26.js
|
|
11
|
-
function
|
|
12
|
+
function l(e) {
|
|
12
13
|
return e.total_amount ?? e.amount_due ?? void 0;
|
|
13
14
|
}
|
|
14
|
-
function
|
|
15
|
+
function u(e) {
|
|
15
16
|
return typeof e == "string" ? e : "";
|
|
16
17
|
}
|
|
17
|
-
function
|
|
18
|
-
let
|
|
19
|
-
apiStatus:
|
|
20
|
-
dueDate:
|
|
21
|
-
scheduledPaymentDate:
|
|
22
|
-
hasScheduledPayment:
|
|
23
|
-
now:
|
|
24
|
-
}),
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
18
|
+
function d({ payable: d, lineItems: p, ledgerAccounts: m, labels: h, hasScheduledPayment: g, now: _, today: v, rejection: y, achInstructions: b, achInstructionsReadable: x = !1 }) {
|
|
19
|
+
let S = d.currency, C = (e) => t(e, S), w = c({
|
|
20
|
+
apiStatus: d.status,
|
|
21
|
+
dueDate: d.due_date,
|
|
22
|
+
scheduledPaymentDate: d.scheduled_payment_date,
|
|
23
|
+
hasScheduledPayment: g,
|
|
24
|
+
now: _
|
|
25
|
+
}), T = a(d), E = o(d), D = e(d.issued_at) || h.notProvided, O = e(d.due_date) || h.notProvided, k = n({
|
|
26
|
+
status: d.status,
|
|
27
|
+
dueDate: d.due_date,
|
|
28
|
+
today: v,
|
|
29
|
+
isScheduled: w.status === "scheduled",
|
|
30
|
+
labels: h.dueDate,
|
|
31
|
+
emptyLabel: h.notProvided
|
|
32
|
+
}), A = [{
|
|
33
|
+
label: h.vendorRow,
|
|
34
|
+
value: E || h.notProvided,
|
|
35
|
+
secondaryValue: T?.email ?? void 0
|
|
36
|
+
}], j = x ? b?.account_number : void 0;
|
|
37
|
+
j && A.push({
|
|
38
|
+
label: h.bankAccountRow,
|
|
39
|
+
value: h.bankAccountValue(j.slice(-4))
|
|
32
40
|
});
|
|
33
|
-
let
|
|
41
|
+
let M = [
|
|
34
42
|
{
|
|
35
|
-
label:
|
|
36
|
-
value:
|
|
43
|
+
label: h.invoiceNumberRow,
|
|
44
|
+
value: d.document_id || h.notProvided
|
|
37
45
|
},
|
|
38
46
|
{
|
|
39
|
-
label:
|
|
40
|
-
value:
|
|
47
|
+
label: h.issueDateRow,
|
|
48
|
+
value: D
|
|
41
49
|
},
|
|
42
50
|
{
|
|
43
|
-
label:
|
|
44
|
-
value:
|
|
51
|
+
label: h.dueDateRow,
|
|
52
|
+
value: O
|
|
45
53
|
},
|
|
46
54
|
{
|
|
47
|
-
label:
|
|
48
|
-
value:
|
|
55
|
+
label: h.poNumberRow,
|
|
56
|
+
value: u(d.purchase_order_number) || h.notProvided
|
|
49
57
|
}
|
|
50
|
-
],
|
|
51
|
-
let t =
|
|
58
|
+
], N = new Map(m.map((e) => [e.id, s(e)])), P = p.map((e) => {
|
|
59
|
+
let t = C(e.unit_price), n = String(i(e));
|
|
52
60
|
return {
|
|
53
61
|
id: e.id,
|
|
54
62
|
description: e.name ?? e.description ?? "",
|
|
55
|
-
glCodeLabel: (e.ledger_account_id ?
|
|
56
|
-
quantityLabel: t ?
|
|
57
|
-
amountLabel:
|
|
63
|
+
glCodeLabel: (e.ledger_account_id ? N.get(e.ledger_account_id) : void 0) || h.glCodeMissing,
|
|
64
|
+
quantityLabel: t ? h.quantityValue(n, t) : h.quantityOnlyValue(n),
|
|
65
|
+
amountLabel: C(r(e)) ?? ""
|
|
58
66
|
};
|
|
59
|
-
}),
|
|
67
|
+
}), F = [
|
|
60
68
|
{
|
|
61
|
-
label:
|
|
62
|
-
value:
|
|
69
|
+
label: h.subtotalRow,
|
|
70
|
+
value: d.subtotal
|
|
63
71
|
},
|
|
64
72
|
{
|
|
65
|
-
label:
|
|
66
|
-
value:
|
|
73
|
+
label: h.discountsRow,
|
|
74
|
+
value: d.discount
|
|
67
75
|
},
|
|
68
76
|
{
|
|
69
|
-
label:
|
|
70
|
-
value:
|
|
77
|
+
label: h.taxRow,
|
|
78
|
+
value: d.tax_amount
|
|
71
79
|
}
|
|
72
80
|
].map(({ label: e, value: t }) => ({
|
|
73
81
|
label: e,
|
|
74
|
-
value:
|
|
75
|
-
})).filter((e) => !!e.value),
|
|
76
|
-
|
|
77
|
-
label:
|
|
78
|
-
value:
|
|
82
|
+
value: C(t)
|
|
83
|
+
})).filter((e) => !!e.value), I = C(l(d));
|
|
84
|
+
I && F.push({
|
|
85
|
+
label: h.totalRow,
|
|
86
|
+
value: I,
|
|
79
87
|
emphasis: !0
|
|
80
88
|
});
|
|
81
|
-
let
|
|
89
|
+
let L = f(d);
|
|
82
90
|
return {
|
|
83
|
-
title:
|
|
84
|
-
subtitle:
|
|
85
|
-
status:
|
|
86
|
-
statusTone:
|
|
87
|
-
amountDueLabel:
|
|
88
|
-
amountPaidLabel:
|
|
89
|
-
paidOnLabel:
|
|
90
|
-
invoiceDateLabel:
|
|
91
|
-
dueDateLabel:
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
91
|
+
title: E,
|
|
92
|
+
subtitle: h.subtitle,
|
|
93
|
+
status: w.status,
|
|
94
|
+
statusTone: w.tone,
|
|
95
|
+
amountDueLabel: C(d.amount_due) ?? C(d.total_amount) ?? "",
|
|
96
|
+
amountPaidLabel: L ? C(d.amount_paid) : void 0,
|
|
97
|
+
paidOnLabel: L ? h.paidOnLabel(L) : void 0,
|
|
98
|
+
invoiceDateLabel: D,
|
|
99
|
+
dueDateLabel: k.label,
|
|
100
|
+
dueDateOverdueLabel: k.overdueLabel,
|
|
101
|
+
dueDateAccessibleLabel: k.accessibleLabel,
|
|
102
|
+
payToItems: A,
|
|
103
|
+
invoiceItems: M,
|
|
104
|
+
lineItems: P,
|
|
105
|
+
totals: F,
|
|
106
|
+
rejection: y
|
|
98
107
|
};
|
|
99
108
|
}
|
|
100
|
-
function
|
|
109
|
+
function f(t) {
|
|
101
110
|
return t.status === "paid" && t.paid_at ? e(t.paid_at.slice(0, 10)) : void 0;
|
|
102
111
|
}
|
|
103
|
-
export {
|
|
112
|
+
export { f as getPaidAtLabel, d as mapPayableToBillDetails, l as resolveInvoiceTotalMinorUnits };
|
|
@@ -2,86 +2,95 @@ import { formatCalendarDate as e } from "../../../../shared/util/dist/lib/format
|
|
|
2
2
|
import "../../../../shared/util/dist/index.js";
|
|
3
3
|
import { formatBillMoney as t } from "../../../util/dist/lib/formatBillMoney.js";
|
|
4
4
|
import { resolveAmountDueMinorUnits as n } from "../../../util/dist/lib/resolveAmountDue.js";
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
5
|
+
import { resolveBillDueDate as r } from "../../../util/dist/lib/resolveBillDueDate.js";
|
|
6
|
+
import { resolveLineItemAmountMinorUnits as i } from "../../../util/dist/lib/resolveLineItemAmount.js";
|
|
7
|
+
import { resolveLineItemQuantity as a } from "../../../util/dist/lib/resolveLineItemQuantity.js";
|
|
8
|
+
import { resolveVendor as o } from "../../../util/dist/lib/resolveVendor.js";
|
|
8
9
|
import "../../../util/dist/index.js";
|
|
9
|
-
import { derivePayableStatus as
|
|
10
|
-
import { getPaidAtLabel as
|
|
10
|
+
import { derivePayableStatus as s } from "../../../../shared/document-status/util/dist/lib/derivePayableStatus.js";
|
|
11
|
+
import { getPaidAtLabel as c, resolveInvoiceTotalMinorUnits as l } from "./index26.js";
|
|
11
12
|
// ../../libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index27.js
|
|
12
|
-
function
|
|
13
|
-
let
|
|
14
|
-
apiStatus:
|
|
15
|
-
dueDate:
|
|
16
|
-
scheduledPaymentDate:
|
|
17
|
-
hasScheduledPayment:
|
|
18
|
-
}),
|
|
13
|
+
function u({ payable: u, lineItems: d, glCodeOptions: f, glCodeRosterAvailable: p = !0, history: m, paymentHistory: h, approvalPolicy: g, labels: _, dueDateLabels: v, today: y, hasScheduledPayment: b, rejection: x, payableAchInstructions: S, payableAchInstructionsReadable: C = !1 }) {
|
|
14
|
+
let w = u.currency, T = s({
|
|
15
|
+
apiStatus: u.status,
|
|
16
|
+
dueDate: u.due_date,
|
|
17
|
+
scheduledPaymentDate: u.scheduled_payment_date,
|
|
18
|
+
hasScheduledPayment: b
|
|
19
|
+
}), E = o(u), D = C ? S : void 0, O = D?.account_number, k = !!(D?.account_holder_name && D.routing_number && D.account_number), A = e(u.issued_at) || _.notProvided, j = e(u.due_date) || _.notProvided, M = r({
|
|
20
|
+
status: u.status,
|
|
21
|
+
dueDate: u.due_date,
|
|
22
|
+
today: y,
|
|
23
|
+
isScheduled: T.status === "scheduled",
|
|
24
|
+
labels: v,
|
|
25
|
+
emptyLabel: _.notProvided
|
|
26
|
+
}), N = new Map(f.map((e) => [e.value, e.label])), P = [
|
|
19
27
|
{
|
|
20
|
-
label:
|
|
21
|
-
minorUnits:
|
|
28
|
+
label: _.subtotalRow,
|
|
29
|
+
minorUnits: u.subtotal
|
|
22
30
|
},
|
|
23
31
|
{
|
|
24
|
-
label:
|
|
25
|
-
minorUnits:
|
|
32
|
+
label: _.discountRow,
|
|
33
|
+
minorUnits: u.discount
|
|
26
34
|
},
|
|
27
35
|
{
|
|
28
|
-
label:
|
|
29
|
-
minorUnits:
|
|
36
|
+
label: _.taxRow,
|
|
37
|
+
minorUnits: u.tax_amount
|
|
30
38
|
}
|
|
31
39
|
].map((e) => ({
|
|
32
40
|
label: e.label,
|
|
33
|
-
value: t(e.minorUnits,
|
|
34
|
-
})).filter((e) => !!e.value),
|
|
35
|
-
|
|
36
|
-
label:
|
|
37
|
-
value:
|
|
41
|
+
value: t(e.minorUnits, w)
|
|
42
|
+
})).filter((e) => !!e.value), F = t(l(u), w);
|
|
43
|
+
F && P.push({
|
|
44
|
+
label: _.totalRow,
|
|
45
|
+
value: F,
|
|
38
46
|
emphasis: !0
|
|
39
47
|
});
|
|
40
|
-
let
|
|
48
|
+
let I = c(u);
|
|
41
49
|
return {
|
|
42
|
-
amountDue: t(n(
|
|
43
|
-
amountPaid:
|
|
44
|
-
paidOnLabel:
|
|
45
|
-
invoiceDateLabel:
|
|
46
|
-
dueDateLabel:
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
+
amountDue: t(n(u), w) ?? "",
|
|
51
|
+
amountPaid: I ? t(u.amount_paid, w) : void 0,
|
|
52
|
+
paidOnLabel: I ? _.paidOnLabel(I) : void 0,
|
|
53
|
+
invoiceDateLabel: A,
|
|
54
|
+
dueDateLabel: M.label,
|
|
55
|
+
dueDateOverdueLabel: M.overdueLabel,
|
|
56
|
+
dueDateAccessibleLabel: M.accessibleLabel,
|
|
57
|
+
status: T.status,
|
|
58
|
+
statusTone: T.tone,
|
|
50
59
|
payTo: {
|
|
51
|
-
name:
|
|
52
|
-
email:
|
|
53
|
-
methodLabel:
|
|
54
|
-
hasPaymentInstructions:
|
|
60
|
+
name: E?.name || _.notProvided,
|
|
61
|
+
email: E?.email ?? "",
|
|
62
|
+
methodLabel: k ? _.paymentInstructionsValue(O?.slice(-4) ?? "") : _.paymentInstructionsNotSet,
|
|
63
|
+
hasPaymentInstructions: k
|
|
55
64
|
},
|
|
56
65
|
invoiceFields: [
|
|
57
66
|
{
|
|
58
|
-
label:
|
|
59
|
-
value:
|
|
67
|
+
label: _.invoiceDateRow,
|
|
68
|
+
value: A
|
|
60
69
|
},
|
|
61
70
|
{
|
|
62
|
-
label:
|
|
63
|
-
value:
|
|
71
|
+
label: _.dueDateRow,
|
|
72
|
+
value: j
|
|
64
73
|
},
|
|
65
74
|
{
|
|
66
|
-
label:
|
|
67
|
-
value:
|
|
75
|
+
label: _.invoiceNumberRow,
|
|
76
|
+
value: u.document_id || _.notProvided
|
|
68
77
|
}
|
|
69
78
|
],
|
|
70
|
-
lineItems:
|
|
71
|
-
let n = t(e.unit_price,
|
|
79
|
+
lineItems: d.map((e) => {
|
|
80
|
+
let n = t(e.unit_price, w), r = String(a(e));
|
|
72
81
|
return {
|
|
73
82
|
id: e.id,
|
|
74
83
|
description: e.name ?? e.description ?? "",
|
|
75
|
-
glCodeLabel: e.ledger_account_id ?
|
|
76
|
-
qtyPriceLabel: n ?
|
|
77
|
-
amount: t(
|
|
84
|
+
glCodeLabel: e.ledger_account_id ? N.get(e.ledger_account_id) ?? (p ? _.glCodeMissing : _.glCodeUnavailable) : _.glCodeMissing,
|
|
85
|
+
qtyPriceLabel: n ? _.qtyPriceValue(r, n) : _.qtyOnlyValue(r),
|
|
86
|
+
amount: t(i(e), w) ?? ""
|
|
78
87
|
};
|
|
79
88
|
}),
|
|
80
|
-
amountRows:
|
|
81
|
-
approvalPolicy:
|
|
82
|
-
paymentHistory:
|
|
83
|
-
history:
|
|
84
|
-
rejection:
|
|
89
|
+
amountRows: P,
|
|
90
|
+
approvalPolicy: g,
|
|
91
|
+
paymentHistory: h,
|
|
92
|
+
history: m,
|
|
93
|
+
rejection: x
|
|
85
94
|
};
|
|
86
95
|
}
|
|
87
|
-
export {
|
|
96
|
+
export { u as buildBillDetailView };
|