@tesouro/embedded-components-react 0.5.145 → 0.5.147

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.
Files changed (30) hide show
  1. package/README.md +22 -1
  2. package/dist/index.d.ts +72 -22
  3. package/dist/index.js +38 -36
  4. package/dist/lib/CounterpartsWidget.d.ts +21 -18
  5. package/dist/lib/CounterpartsWidget.js +1 -2
  6. package/dist/lib/CounterpartsWidgetPublic.d.ts +976 -0
  7. package/dist/lib/CounterpartsWidgetPublic.js +10 -0
  8. package/dist/lib/CustomersWidget.d.ts +955 -0
  9. package/dist/lib/CustomersWidget.js +3 -0
  10. package/dist/lib/ReceivablesWidget.d.ts +2 -0
  11. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index90.js +1 -0
  12. package/dist/libs/tesouro-embedded-components-react/counterparts-widget/feature/dist/index4.js +98 -89
  13. package/dist/libs/tesouro-embedded-components-react/counterparts-widget/feature/dist/index7.js +114 -108
  14. package/dist/libs/tesouro-embedded-components-react/counterparts-widget/feature/dist/index8.js +40 -42
  15. package/dist/libs/tesouro-embedded-components-react/counterparts-widget/ui/dist/index2.js +1 -0
  16. package/dist/libs/tesouro-embedded-components-react/counterparts-widget/ui/dist/index3.js +90 -76
  17. package/dist/libs/tesouro-embedded-components-react/counterparts-widget/ui/dist/index4.js +300 -226
  18. package/dist/libs/tesouro-embedded-components-react/customers-widget/feature/dist/index.js +2 -0
  19. package/dist/libs/tesouro-embedded-components-react/customers-widget/feature/dist/index2.js +4 -0
  20. package/dist/libs/tesouro-embedded-components-react/customers-widget/feature/dist/index3.js +45 -0
  21. package/dist/libs/tesouro-embedded-components-react/customers-widget/feature/dist/index4.js +42 -0
  22. package/dist/libs/tesouro-embedded-components-react/customers-widget/feature/dist/index5.js +27 -0
  23. package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/index.js +11 -12
  24. package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/helpers.js +103 -100
  25. package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/labels.js +1 -0
  26. package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index.js +9 -9
  27. package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index13.js +4 -74
  28. package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/rest/zod.gen.js +6 -1
  29. package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
  30. package/package.json +1 -1
package/README.md CHANGED
@@ -369,10 +369,31 @@ A self-contained widget for managing an organization's customers or vendors with
369
369
  | `formLabels` | `Partial<CounterpartFormSheetLabels>` | Create/edit counterpart form copy. |
370
370
  | `detailsLabels` | `Partial<CounterpartDetailsSheetLabels>` | Details sheet sections, summary labels, subtitle/entity/reminder/payment-method labels, row labels, and actions. |
371
371
  | `bankAccountLabels` | `PartialDeep<BankAccountFormSheetLabels>` | Vendor payment-method form copy, including nested field-marker labels. |
372
- | `addressLabels` | `Partial<AddressFormSheetLabels>` | Address form copy. |
372
+ | `addressLabels` | `PartialDeep<AddressFormSheetLabels>` | Address form copy. |
373
373
  | `deleteLabels` | `Partial<ConfirmDeleteDialogLabels>` | Delete-dialog copy. |
374
374
  | `messageLabels` | `Partial<CounterpartMessageLabels>` | Validation, API failure, and delete-prompt messages produced by feature logic. |
375
375
 
376
+ ### CustomersWidget
377
+
378
+ A self-contained widget for managing an organization's customers: searchable list, money columns, details, editing, and deletion.
379
+
380
+ #### Props
381
+
382
+ | Prop | Type | Default | Description |
383
+ | -------------------- | --------------------------------------------- | ------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
384
+ | `pageSizeOptions` | `number[]` | `[10, 25, 50, 100]` | Page-size choices shown by the table. |
385
+ | `onViewAllDocuments` | `(customer: CounterpartActionTarget) => void` | `undefined` | Reveals a "View all" action beside the recent-invoices heading in the details sheet, and hands over the customer's `id` and `name` so the destination can filter to them. Omit when the host has no invoice list to navigate to. Under `implementation="monite"`, `name` is always empty. |
386
+ | `onCreateDocument` | `(customer: CounterpartActionTarget) => void` | `undefined` | Runs the details sheet's "Issue an invoice" action with the customer's `id` and `name`, so the host can open its create flow pre-linked to them. Omit and the button renders disabled. The destination's own invoice-write scope is the host's to check. Under `implementation="monite"`, `name` is always empty. |
387
+
388
+ | Prop | Type | Description |
389
+ | --------------- | ---------------------------------------- | ------------------------------------------------------------------------------------------------- |
390
+ | `screenLabels` | `Partial<CounterpartsScreenLabels>` | Table title, columns, search/filter, empty, error, and access-restricted copy. |
391
+ | `formLabels` | `Partial<CounterpartFormSheetLabels>` | Create/edit customer form copy. |
392
+ | `detailsLabels` | `Partial<CounterpartDetailsSheetLabels>` | Details sheet sections, summary labels, subtitle/entity/reminder labels, row labels, and actions. |
393
+ | `addressLabels` | `PartialDeep<AddressFormSheetLabels>` | Address form copy. |
394
+ | `deleteLabels` | `Partial<ConfirmDeleteDialogLabels>` | Delete-dialog copy. |
395
+ | `messageLabels` | `Partial<CounterpartMessageLabels>` | Validation, API failure, and delete-prompt messages produced by feature logic. |
396
+
376
397
  ### ExpenseManagementWidget
377
398
 
378
399
  A composite expense widget for receipt upload, matching slots, approval policies, and transaction requirements.
package/dist/index.d.ts CHANGED
@@ -3946,6 +3946,8 @@ interface CounterpartMessageLabels {
3946
3946
  vatIdValueRequired: string;
3947
3947
  /** Shown for a non-field-specific submit failure. */
3948
3948
  genericError: string;
3949
+ /** Toasted when the list's billed/received/due analytics fail to load. */
3950
+ amountsUnavailable: string;
3949
3951
  /** Delete confirmation title; `{name}` is replaced with the entity name. */
3950
3952
  deleteTitle: string;
3951
3953
  /** Delete confirmation title for a bank account; `{account}` is display-ready. */
@@ -4211,6 +4213,8 @@ interface CounterpartDetailsSheetLabels {
4211
4213
  customerTaxIdHelp: string;
4212
4214
  vendorTaxIdHelp: string;
4213
4215
  addressHeading: string;
4216
+ /** Customer mode's own section heading — vendor mode uses `addressHeading` as a `DetailLine` row label instead. */
4217
+ customerAddressHeading: string;
4214
4218
  customerAddressDescription: string;
4215
4219
  addAddressAction: string;
4216
4220
  editAddressAction: string;
@@ -4259,7 +4263,7 @@ interface CounterpartsWidgetOwnProps {
4259
4263
  formLabels?: PartialDeep<CounterpartFormSheetLabels>;
4260
4264
  detailsLabels?: Partial<CounterpartDetailsSheetLabels>;
4261
4265
  bankAccountLabels?: PartialDeep<BankAccountFormSheetLabels>;
4262
- addressLabels?: Partial<AddressFormSheetLabels>;
4266
+ addressLabels?: PartialDeep<AddressFormSheetLabels>;
4263
4267
  deleteLabels?: Partial<ConfirmDeleteDialogLabels>;
4264
4268
  /** Overrides for validation / error / delete-prompt messages. */
4265
4269
  messageLabels?: Partial<CounterpartMessageLabels>;
@@ -4267,25 +4271,6 @@ interface CounterpartsWidgetOwnProps {
4267
4271
  /** Public props for {@link CounterpartsWidget}. */
4268
4272
  type CounterpartsWidgetProps = WidgetProviderProps & CounterpartsWidgetOwnProps;
4269
4273
 
4270
- /**
4271
- * Self-contained customers/vendors widget: lists counterparts with money
4272
- * columns, and creates, edits, views, and deletes counterparts plus their
4273
- * payment method and address. `counterpartType` selects customer (receivables)
4274
- * vs vendor (payables) behavior. The provider/inner split keeps the public
4275
- * component a pure {@link WidgetProvider} wrapper.
4276
- *
4277
- * @example
4278
- * ```tsx
4279
- * <CounterpartsWidget
4280
- * counterpartType="customer"
4281
- * baseUrl="https://api.tesouro.com"
4282
- * widgetToken="wt_..."
4283
- * organizationId="org_..."
4284
- * />
4285
- * ```
4286
- */
4287
- declare function CounterpartsWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, providerLabels, ...innerProps }: CounterpartsWidgetProps): React.JSX.Element;
4288
-
4289
4274
  declare const TabId: {
4290
4275
  readonly Bills: "bills";
4291
4276
  readonly Vendors: "vendors";
@@ -4324,6 +4309,71 @@ type BillPayWidgetProps = BillPayWidgetMoniteProps & {
4324
4309
  */
4325
4310
  declare function BillPayWidget({ implementation, initialTab, onSettingsClick, ...props }: BillPayWidgetProps): React.JSX.Element;
4326
4311
 
4312
+ /**
4313
+ * Public {@link CounterpartsWidget} — the integrator-facing widget.
4314
+ *
4315
+ * The workspace-internal component additionally accepts a `passThrough` prop
4316
+ * that tells it to give up its own analytics identity when a composing widget
4317
+ * (`CustomersWidgetNative`, `BillPayWidgetNative`'s Vendors tab) mounts it to
4318
+ * inherit the host's identity instead (EMBD-5384). That choice is set **only**
4319
+ * by those composing widgets, never by integrators: an integrator's own
4320
+ * standalone mount must always claim its own identity.
4321
+ *
4322
+ * `CounterpartsWidgetProps` deliberately omits `passThrough`, so typed (TS)
4323
+ * consumers cannot pass it. This wrapper additionally strips any stray
4324
+ * `passThrough` a non-typed (JS) host might pass at runtime before
4325
+ * delegating, so the internal prop is unreachable from the published surface
4326
+ * in every case — the widget's declaration in the emitted types carries no
4327
+ * `passThrough`.
4328
+ */
4329
+ declare function CounterpartsWidget(props: CounterpartsWidgetProps): ReactNode;
4330
+
4331
+ /**
4332
+ * Own props shared by both implementations. Named after
4333
+ * {@link CounterpartsWidgetOwnProps} (this widget's native implementation is a
4334
+ * thin `counterpartType="customer"` wrapper around `CounterpartsWidget`) minus
4335
+ * `counterpartType` itself, which this widget hardcodes.
4336
+ */
4337
+ interface CustomersWidgetOwnProps {
4338
+ pageSizeOptions?: number[];
4339
+ /**
4340
+ * Reveals a "View all" action beside the recent-documents heading in the
4341
+ * details sheet. Omit when the host has nowhere to send the user.
4342
+ */
4343
+ onViewAllDocuments?: (counterpart: CounterpartActionTarget) => void;
4344
+ /**
4345
+ * Opens the host's create-invoice flow for this customer, behind the
4346
+ * "Issue an invoice" button, which stays disabled while unwired.
4347
+ */
4348
+ onCreateDocument?: (counterpart: CounterpartActionTarget) => void;
4349
+ screenLabels?: Partial<CounterpartsScreenLabels>;
4350
+ formLabels?: PartialDeep<CounterpartFormSheetLabels>;
4351
+ detailsLabels?: Partial<CounterpartDetailsSheetLabels>;
4352
+ addressLabels?: PartialDeep<AddressFormSheetLabels>;
4353
+ deleteLabels?: Partial<ConfirmDeleteDialogLabels>;
4354
+ /** Overrides for validation / error / delete-prompt messages. */
4355
+ messageLabels?: Partial<CounterpartMessageLabels>;
4356
+ }
4357
+ /** Public props for {@link CustomersWidget}. */
4358
+ type CustomersWidgetProps = WidgetProviderProps & CustomersWidgetOwnProps;
4359
+
4360
+ /**
4361
+ * Customers widget entry point — selects the rendering implementation.
4362
+ *
4363
+ * Unlike `BillPayWidget`, this one is not pinned to Monite: the native
4364
+ * implementation (a thin `counterpartType="customer"` wrapper around the
4365
+ * published `CounterpartsWidget`) is already at parity, so this simply
4366
+ * inherits the package-wide `native` default. An explicit selection is still
4367
+ * honored, whether from this widget's `implementation` prop or from the
4368
+ * provider/global cascade (`RootWidgetProvider implementation="monite"`,
4369
+ * `setGlobalWidgetConfig`) — for a host that has not yet moved off Monite.
4370
+ *
4371
+ * `onViewAllDocuments` / `onCreateDocument` receive a `CounterpartActionTarget`
4372
+ * (`{ id, name }`) under native. Under `monite`, `name` is always empty — the
4373
+ * Monite SDK's own callbacks only carry the id.
4374
+ */
4375
+ declare function CustomersWidget({ implementation, onViewAllDocuments, onCreateDocument, ...rest }: CustomersWidgetProps): React.JSX.Element;
4376
+
4327
4377
  interface Labels$1 {
4328
4378
  description: string;
4329
4379
  receiptsTab: string;
@@ -5080,5 +5130,5 @@ interface CheckAmountAndDetailScreenProps {
5080
5130
 
5081
5131
  type PendingFeatureStyleSources = CheckAmountAndDetailScreenProps | GapCoverageAlertProps | NoPolicyBannerProps;
5082
5132
 
5083
- export { ACCEPT_DISCLOSURES_WIDGET_LABELS_EN, ADDITIONAL_OWNERS_LABELS_EN, AcceptDisclosuresWidget, BALANCES_WIDGET_LABELS_EN, BUSINESS_DETAILS_LABELS_EN, BalancesWidget, BankAccountOnboardingWidget, BankAccountsWidget, BillPayWidget, CardDetailsWidget, CounterpartsWidget, CreditCardsWidget, DebitCardsWidget, ERROR_STATE_ID, ExpenseManagementWidget, HELP_FAQ_EN, INSIGHTS_FEATURE_LABELS_EN, INSIGHTS_WIDGET_LABELS_EN, Implementation, InsightsWidget, ReceivablesWidgetMonite as InvoicingWidget, LinkedAccountsWidget, MARKETING_WIDGET_LABELS_EN, MarketingBenefitIcon, MarketingWidget, 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, UploadReceiptWidget, 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 };
5084
- export type { AcceptDisclosuresWidgetLabels, AcceptDisclosuresWidgetProps, Labels$3 as AccountDetailsWidgetLabels, ActivateCardPanelLabels, AdditionalOwner, AdditionalOwnersLabels, AddressFormSheetLabels, 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, DebitCardsWidgetProps, DisclosureLinks, EmbeddedClient, Labels$1 as ExpenseManagementWidgetLabels, ExpenseManagementWidgetProps, HelpFaqAnswer, HelpFaqBullet, HelpFaqBulletType, HelpFaqItem, HelpFaqSection, InsightsFeatureLabels, InsightsWidgetLabels, InsightsWidgetProps, ReceivablesWidgetMoniteProps as InvoicingWidgetProps, LinkComponent, LinkComponentProps, FeatureLabels as LinkedAccountsWidgetFeatureLabels, Labels as LinkedAccountsWidgetLabels, LinkedAccountsWidgetProps, MarketingWidgetAppearance, MarketingWidgetBenefit, MarketingWidgetContent, MarketingWidgetHowItWorksStep, MarketingWidgetImage, MarketingWidgetLabels, MarketingWidgetProps, MeasureUnitDeleteDialogLabels, MeasureUnitsManagerLabels, PendingFeatureStyleSources, PersonalDetailsLabels, PersonalDetailsValues, ProductDeleteDialogLabels, ProductDetailsSheetLabels, ProductFormSheetLabels, ProductMessageLabels, ProductsScreenLabels, ProductsWidgetProps, ReceiptMatchSummary, ReceivableActionDialogLabels, ReceivableDetailsSheetLabelOverrides, ReceivableDetailsSheetLabels, ReceivableDocumentType, ReceivableFormSheetLabels, ReceivableMessageLabels, ReceivablePaymentDialogLabels, ReceivableSendDialogLabels, ReceivableStatusBadgeLabels, ReceivablesScreenLabelOverrides, ReceivablesScreenLabels, ReceivablesWidgetProps, ReceivablesWidgetTab, RefreshingRootWidgetProviderProps, ResultLabels, RootWidgetProviderProps, SettingsWidgetAdditionalSection, FeatureLabels$2 as SettingsWidgetFeatureLabels, Labels$2 as SettingsWidgetLabels, SettingsWidgetProps, SettingsWidgetSection, SettingsWidgetSectionId, SingleInsightLabels, FeatureLabels$1 as TransfersWidgetFeatureLabels, TransfersWidgetLabels, TransfersWidgetProps, UploadReceiptWidgetProps, WidgetConfig, WidgetConfigInput, WidgetInitResponse, WidgetInitState, WidgetProviderLabels, WidgetProviderProps, WidgetSuiteCardsLabels, WidgetSuiteDashboardLabels, WidgetSuiteDisclosureLabels, WidgetSuiteExpensesLabels, WidgetSuiteLabelOverrides, WidgetSuiteLabels, WidgetSuiteMenuLabels, WidgetSuiteOnboardingGateLabels, WidgetSuiteOnboardingLabels, WidgetSuiteProps, WidgetSuiteSectionContentLabels, WidgetSuiteSectionTitleLabels, WidgetTokenFetcher, WidgetTokenManager, WidgetTokenRefreshProviderProps, WidgetTokenState };
5133
+ export { ACCEPT_DISCLOSURES_WIDGET_LABELS_EN, ADDITIONAL_OWNERS_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, ReceivablesWidgetMonite as InvoicingWidget, LinkedAccountsWidget, MARKETING_WIDGET_LABELS_EN, MarketingBenefitIcon, MarketingWidget, 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, UploadReceiptWidget, 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 };
5134
+ export type { AcceptDisclosuresWidgetLabels, AcceptDisclosuresWidgetProps, Labels$3 as AccountDetailsWidgetLabels, ActivateCardPanelLabels, AdditionalOwner, AdditionalOwnersLabels, AddressFormSheetLabels, 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$1 as ExpenseManagementWidgetLabels, ExpenseManagementWidgetProps, HelpFaqAnswer, HelpFaqBullet, HelpFaqBulletType, HelpFaqItem, HelpFaqSection, InsightsFeatureLabels, InsightsWidgetLabels, InsightsWidgetProps, ReceivablesWidgetMoniteProps as InvoicingWidgetProps, LinkComponent, LinkComponentProps, FeatureLabels as LinkedAccountsWidgetFeatureLabels, Labels as LinkedAccountsWidgetLabels, LinkedAccountsWidgetProps, MarketingWidgetAppearance, MarketingWidgetBenefit, MarketingWidgetContent, MarketingWidgetHowItWorksStep, MarketingWidgetImage, MarketingWidgetLabels, MarketingWidgetProps, MeasureUnitDeleteDialogLabels, MeasureUnitsManagerLabels, PendingFeatureStyleSources, PersonalDetailsLabels, PersonalDetailsValues, ProductDeleteDialogLabels, ProductDetailsSheetLabels, ProductFormSheetLabels, ProductMessageLabels, ProductsScreenLabels, ProductsWidgetProps, ReceiptMatchSummary, ReceivableActionDialogLabels, ReceivableDetailsSheetLabelOverrides, ReceivableDetailsSheetLabels, ReceivableDocumentType, ReceivableFormSheetLabels, ReceivableMessageLabels, ReceivablePaymentDialogLabels, ReceivableSendDialogLabels, ReceivableStatusBadgeLabels, ReceivablesScreenLabelOverrides, ReceivablesScreenLabels, ReceivablesWidgetProps, ReceivablesWidgetTab, RefreshingRootWidgetProviderProps, ResultLabels, RootWidgetProviderProps, SettingsWidgetAdditionalSection, FeatureLabels$2 as SettingsWidgetFeatureLabels, Labels$2 as SettingsWidgetLabels, SettingsWidgetProps, SettingsWidgetSection, SettingsWidgetSectionId, SingleInsightLabels, FeatureLabels$1 as TransfersWidgetFeatureLabels, TransfersWidgetLabels, TransfersWidgetProps, UploadReceiptWidgetProps, 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
@@ -14,35 +14,34 @@ import { useWidgetToken as v } from "./libs/tesouro-embedded-components-react/sh
14
14
  import { RefreshingRootWidgetProvider as y } from "./libs/tesouro-embedded-components-react/shared/feature/dist/lib/WidgetProvider/RefreshingRootWidgetProvider.js";
15
15
  import { useDisclosuresAcceptanceSurface as b, useOwnWidgetConfig as x, useRefetchWidget as S, useWidgetConfig as C, useWidgetError as w, useWidgetInitStaleForToken as T, useWidgetLoading as E } from "./libs/tesouro-embedded-components-react/shared/feature/dist/lib/WidgetProvider/hooks.js";
16
16
  import { BankAccountsWidget as D } from "./libs/tesouro-embedded-components-react/bank-accounts-widget/feature/dist/index8.js";
17
- import { CounterpartsWidget as O } from "./libs/tesouro-embedded-components-react/counterparts-widget/feature/dist/index8.js";
18
- import { BillPayWidget as k } from "./libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index92.js";
19
- import { CardDetailsWidget as A } from "./libs/tesouro-embedded-components-react/card-details-widget/feature/dist/index13.js";
20
- import { CreditCardsWidget as j } from "./libs/tesouro-embedded-components-react/cards-widget/feature/dist/index10.js";
21
- import { DebitCardsWidget as M } from "./libs/tesouro-embedded-components-react/cards-widget/feature/dist/index11.js";
22
- import { BALANCES_WIDGET_LABELS_EN as N } from "./libs/tesouro-embedded-components-react/balances-widget/ui/dist/lib/BalancesWidget/labels.js";
23
- import { BalancesWidget as P } from "./libs/tesouro-embedded-components-react/balances-widget/feature/dist/index6.js";
24
- import { INSIGHTS_FEATURE_LABELS_EN as F } from "./libs/tesouro-embedded-components-react/insights-widget/feature/dist/index3.js";
25
- import { INSIGHTS_WIDGET_LABELS_EN as I } from "./libs/tesouro-embedded-components-react/insights-widget/ui/dist/lib/InsightsWidget/labels.js";
26
- import { SINGLE_INSIGHT_LABELS_EN as L } from "./libs/tesouro-embedded-components-react/insights-widget/ui/dist/lib/InsightsWidget/SingleInsight/labels.js";
27
- import { InsightsWidget as R } from "./libs/tesouro-embedded-components-react/insights-widget/feature/dist/index12.js";
28
- import { InvoicingWidget as z } from "./libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index3.js";
29
- import { ReceivablesWidget as B } from "./libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index12.js";
30
- import { SettingsSection as V } from "./libs/tesouro-embedded-components-react/settings-widget/feature/dist/index4.js";
31
- import { UploadReceiptWidget as H } from "./libs/tesouro-embedded-components-react/expense-management-widget/feature/dist/index7.js";
32
- import { ExpenseManagementWidget as U } from "./libs/tesouro-embedded-components-react/expense-management-widget/feature/dist/index13.js";
33
- import { HELP_FAQ_EN as W } from "./libs/tesouro-embedded-components-react/settings-widget/help/ui/contract/dist/index3.js";
34
- import { SettingsWidget as G } from "./libs/tesouro-embedded-components-react/settings-widget/feature/dist/index6.js";
35
- import { DEFAULT_FEATURE_LABELS as K } from "./libs/tesouro-embedded-components-react/transfers-widget/feature/dist/index3.js";
36
- import { TRANSFERS_WIDGET_LABELS_EN as q } from "./libs/tesouro-embedded-components-react/transfers-widget/ui/dist/lib/TransfersWidget/labels.js";
37
- import { TransfersWidget as J } from "./libs/tesouro-embedded-components-react/transfers-widget/feature/dist/index7.js";
38
- import { ACCEPT_DISCLOSURES_WIDGET_LABELS_EN as Y } from "./libs/tesouro-embedded-components-react/accept-disclosures-widget/ui/dist/lib/AcceptDisclosuresWidget/labels.js";
39
- import { AcceptDisclosuresWidget as X } from "./libs/tesouro-embedded-components-react/accept-disclosures-widget/feature/dist/index5.js";
40
- import { ADDITIONAL_OWNERS_LABELS_EN as Z } from "./libs/tesouro-embedded-components-react/bank-account-onboarding-widget/ui/dist/index5.js";
41
- import { BUSINESS_DETAILS_LABELS_EN as Q } from "./libs/tesouro-embedded-components-react/bank-account-onboarding-widget/ui/dist/index7.js";
42
- import { PERSONAL_DETAILS_LABELS_EN as $ } from "./libs/tesouro-embedded-components-react/bank-account-onboarding-widget/ui/dist/index8.js";
43
- import { RESULT_LABELS_EN as ee } from "./libs/tesouro-embedded-components-react/bank-account-onboarding-widget/ui/dist/index13.js";
44
- import { BankAccountOnboardingWidget as te } from "./libs/tesouro-embedded-components-react/bank-account-onboarding-widget/feature/dist/index22.js";
45
- import { WidgetSuite as ne } from "./libs/tesouro-embedded-components-react/widget-suite/feature/dist/index16.js";
17
+ import { BillPayWidget as O } from "./libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index92.js";
18
+ import { CardDetailsWidget as k } from "./libs/tesouro-embedded-components-react/card-details-widget/feature/dist/index13.js";
19
+ import { CreditCardsWidget as A } from "./libs/tesouro-embedded-components-react/cards-widget/feature/dist/index10.js";
20
+ import { DebitCardsWidget as j } from "./libs/tesouro-embedded-components-react/cards-widget/feature/dist/index11.js";
21
+ import { BALANCES_WIDGET_LABELS_EN as M } from "./libs/tesouro-embedded-components-react/balances-widget/ui/dist/lib/BalancesWidget/labels.js";
22
+ import { BalancesWidget as N } from "./libs/tesouro-embedded-components-react/balances-widget/feature/dist/index6.js";
23
+ import { INSIGHTS_FEATURE_LABELS_EN as P } from "./libs/tesouro-embedded-components-react/insights-widget/feature/dist/index3.js";
24
+ import { INSIGHTS_WIDGET_LABELS_EN as F } from "./libs/tesouro-embedded-components-react/insights-widget/ui/dist/lib/InsightsWidget/labels.js";
25
+ import { SINGLE_INSIGHT_LABELS_EN as I } from "./libs/tesouro-embedded-components-react/insights-widget/ui/dist/lib/InsightsWidget/SingleInsight/labels.js";
26
+ import { InsightsWidget as L } from "./libs/tesouro-embedded-components-react/insights-widget/feature/dist/index12.js";
27
+ import { InvoicingWidget as R } from "./libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index3.js";
28
+ import { ReceivablesWidget as z } from "./libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index12.js";
29
+ import { SettingsSection as B } from "./libs/tesouro-embedded-components-react/settings-widget/feature/dist/index4.js";
30
+ import { UploadReceiptWidget as V } from "./libs/tesouro-embedded-components-react/expense-management-widget/feature/dist/index7.js";
31
+ import { ExpenseManagementWidget as H } from "./libs/tesouro-embedded-components-react/expense-management-widget/feature/dist/index13.js";
32
+ import { HELP_FAQ_EN as U } from "./libs/tesouro-embedded-components-react/settings-widget/help/ui/contract/dist/index3.js";
33
+ import { SettingsWidget as W } from "./libs/tesouro-embedded-components-react/settings-widget/feature/dist/index6.js";
34
+ import { DEFAULT_FEATURE_LABELS as G } from "./libs/tesouro-embedded-components-react/transfers-widget/feature/dist/index3.js";
35
+ import { TRANSFERS_WIDGET_LABELS_EN as K } from "./libs/tesouro-embedded-components-react/transfers-widget/ui/dist/lib/TransfersWidget/labels.js";
36
+ import { TransfersWidget as q } from "./libs/tesouro-embedded-components-react/transfers-widget/feature/dist/index7.js";
37
+ import { ACCEPT_DISCLOSURES_WIDGET_LABELS_EN as J } from "./libs/tesouro-embedded-components-react/accept-disclosures-widget/ui/dist/lib/AcceptDisclosuresWidget/labels.js";
38
+ import { AcceptDisclosuresWidget as Y } from "./libs/tesouro-embedded-components-react/accept-disclosures-widget/feature/dist/index5.js";
39
+ import { ADDITIONAL_OWNERS_LABELS_EN as X } from "./libs/tesouro-embedded-components-react/bank-account-onboarding-widget/ui/dist/index5.js";
40
+ import { BUSINESS_DETAILS_LABELS_EN as Z } from "./libs/tesouro-embedded-components-react/bank-account-onboarding-widget/ui/dist/index7.js";
41
+ import { PERSONAL_DETAILS_LABELS_EN as Q } from "./libs/tesouro-embedded-components-react/bank-account-onboarding-widget/ui/dist/index8.js";
42
+ import { RESULT_LABELS_EN as $ } from "./libs/tesouro-embedded-components-react/bank-account-onboarding-widget/ui/dist/index13.js";
43
+ import { BankAccountOnboardingWidget as ee } from "./libs/tesouro-embedded-components-react/bank-account-onboarding-widget/feature/dist/index22.js";
44
+ import { WidgetSuite as te } from "./libs/tesouro-embedded-components-react/widget-suite/feature/dist/index16.js";
46
45
  import "./lib/WidgetSuite.js";
47
46
  import "./lib/AcceptDisclosuresWidget.js";
48
47
  import "./lib/BankAccountsWidget.js";
@@ -50,25 +49,28 @@ import "./lib/BillPayWidget.js";
50
49
  import "./lib/CreditCardsWidget.js";
51
50
  import "./lib/DebitCardsWidget.js";
52
51
  import "./lib/CardDetailsWidget.js";
52
+ import { CounterpartsWidget as ne } from "./lib/CounterpartsWidgetPublic.js";
53
53
  import "./lib/CounterpartsWidget.js";
54
+ import { CustomersWidget as re } from "./libs/tesouro-embedded-components-react/customers-widget/feature/dist/index5.js";
55
+ import "./lib/CustomersWidget.js";
54
56
  import "./lib/ExpenseManagementWidget.js";
55
57
  import "./lib/UploadReceiptWidget.js";
56
58
  import "./lib/BalancesWidget.js";
57
59
  import "./lib/InsightsWidget.js";
58
60
  import "./lib/InvoicingWidget.js";
59
- import { LinkedAccountsWidget as re } from "./libs/tesouro-embedded-components-react/linked-accounts-widget/feature/dist/index10.js";
61
+ import { LinkedAccountsWidget as ie } from "./libs/tesouro-embedded-components-react/linked-accounts-widget/feature/dist/index10.js";
60
62
  import "./lib/LinkedAccountsWidget.js";
61
63
  import "./lib/BankAccountOnboardingWidget.js";
62
- import { MARKETING_WIDGET_LABELS_EN as ie } from "./libs/tesouro-embedded-components-react/marketing-widget/ui/dist/index2.js";
63
- import { MarketingBenefitIcon as ae } from "./libs/tesouro-embedded-components-react/marketing-widget/ui/dist/index3.js";
64
- import { MarketingWidget as oe } from "./libs/tesouro-embedded-components-react/marketing-widget/feature/dist/index4.js";
64
+ import { MARKETING_WIDGET_LABELS_EN as ae } from "./libs/tesouro-embedded-components-react/marketing-widget/ui/dist/index2.js";
65
+ import { MarketingBenefitIcon as oe } from "./libs/tesouro-embedded-components-react/marketing-widget/ui/dist/index3.js";
66
+ import { MarketingWidget as se } from "./libs/tesouro-embedded-components-react/marketing-widget/feature/dist/index4.js";
65
67
  import "./lib/MarketingWidget.js";
66
- import { ProductsWidget as se } from "./libs/tesouro-embedded-components-react/products-widget/feature/dist/index8.js";
68
+ import { ProductsWidget as ce } from "./libs/tesouro-embedded-components-react/products-widget/feature/dist/index8.js";
67
69
  import "./lib/ProductsWidget.js";
68
70
  import "./lib/ReceivablesWidget.js";
69
71
  import "./lib/SettingsWidget.js";
70
72
  import "./lib/TransfersWidget.js";
71
- import { WidgetProvider as ce } from "./lib/WidgetProviderPublic.js";
73
+ import { WidgetProvider as le } from "./lib/WidgetProviderPublic.js";
72
74
  import "./lib/WidgetProvider.js";
73
75
  import "./packages/tesouro-embedded-components-react/src/scopes.js";
74
- export { Y as ACCEPT_DISCLOSURES_WIDGET_LABELS_EN, Z as ADDITIONAL_OWNERS_LABELS_EN, X as AcceptDisclosuresWidget, N as BALANCES_WIDGET_LABELS_EN, Q as BUSINESS_DETAILS_LABELS_EN, P as BalancesWidget, te as BankAccountOnboardingWidget, D as BankAccountsWidget, k as BillPayWidget, A as CardDetailsWidget, O as CounterpartsWidget, j as CreditCardsWidget, M as DebitCardsWidget, l as ERROR_STATE_ID, U as ExpenseManagementWidget, W as HELP_FAQ_EN, F as INSIGHTS_FEATURE_LABELS_EN, I as INSIGHTS_WIDGET_LABELS_EN, u as Implementation, R as InsightsWidget, z as InvoicingWidget, re as LinkedAccountsWidget, ie as MARKETING_WIDGET_LABELS_EN, ae as MarketingBenefitIcon, oe as MarketingWidget, $ as PERSONAL_DETAILS_LABELS_EN, se as ProductsWidget, ee as RESULT_LABELS_EN, B as ReceivablesWidget, y as RefreshingRootWidgetProvider, g as RootWidgetProvider, L as SINGLE_INSIGHT_LABELS_EN, i as Scope, V as SettingsSection, G as SettingsWidget, K as TRANSFERS_FEATURE_LABELS_EN, q as TRANSFERS_WIDGET_LABELS_EN, J as TransfersWidget, o as UIFramework, H as UploadReceiptWidget, t as WIDGET_SUITE_DEFAULT_SECTIONS, e as WIDGET_SUITE_LABELS_EN, ce as WidgetProvider, ne 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 };
76
+ export { J as ACCEPT_DISCLOSURES_WIDGET_LABELS_EN, X as ADDITIONAL_OWNERS_LABELS_EN, Y as AcceptDisclosuresWidget, M as BALANCES_WIDGET_LABELS_EN, Z 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, H as ExpenseManagementWidget, U as HELP_FAQ_EN, P as INSIGHTS_FEATURE_LABELS_EN, F as INSIGHTS_WIDGET_LABELS_EN, u as Implementation, L as InsightsWidget, R as InvoicingWidget, ie as LinkedAccountsWidget, ae as MARKETING_WIDGET_LABELS_EN, oe as MarketingBenefitIcon, se as MarketingWidget, Q as PERSONAL_DETAILS_LABELS_EN, ce as ProductsWidget, $ 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, W as SettingsWidget, G as TRANSFERS_FEATURE_LABELS_EN, K as TRANSFERS_WIDGET_LABELS_EN, q as TransfersWidget, o as UIFramework, V as UploadReceiptWidget, 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 };
@@ -1,6 +1,5 @@
1
- import * as React from 'react';
2
- import { ComponentType, AnchorHTMLAttributes, ReactNode, ErrorInfo } from 'react';
3
1
  import { PartialDeep } from 'type-fest';
2
+ import { ComponentType, AnchorHTMLAttributes, ReactNode, ErrorInfo } from 'react';
4
3
  import { FallbackProps } from 'react-error-boundary';
5
4
 
6
5
  type AuthToken = string | undefined;
@@ -792,6 +791,8 @@ interface CounterpartMessageLabels {
792
791
  vatIdValueRequired: string;
793
792
  /** Shown for a non-field-specific submit failure. */
794
793
  genericError: string;
794
+ /** Toasted when the list's billed/received/due analytics fail to load. */
795
+ amountsUnavailable: string;
795
796
  /** Delete confirmation title; `{name}` is replaced with the entity name. */
796
797
  deleteTitle: string;
797
798
  /** Delete confirmation title for a bank account; `{account}` is display-ready. */
@@ -895,6 +896,8 @@ interface CounterpartDetailsSheetLabels {
895
896
  customerTaxIdHelp: string;
896
897
  vendorTaxIdHelp: string;
897
898
  addressHeading: string;
899
+ /** Customer mode's own section heading — vendor mode uses `addressHeading` as a `DetailLine` row label instead. */
900
+ customerAddressHeading: string;
898
901
  customerAddressDescription: string;
899
902
  addAddressAction: string;
900
903
  editAddressAction: string;
@@ -943,7 +946,7 @@ interface CounterpartsWidgetOwnProps {
943
946
  formLabels?: PartialDeep<CounterpartFormSheetLabels>;
944
947
  detailsLabels?: Partial<CounterpartDetailsSheetLabels>;
945
948
  bankAccountLabels?: PartialDeep<BankAccountFormSheetLabels>;
946
- addressLabels?: Partial<AddressFormSheetLabels>;
949
+ addressLabels?: PartialDeep<AddressFormSheetLabels>;
947
950
  deleteLabels?: Partial<ConfirmDeleteDialogLabels>;
948
951
  /** Overrides for validation / error / delete-prompt messages. */
949
952
  messageLabels?: Partial<CounterpartMessageLabels>;
@@ -952,23 +955,23 @@ interface CounterpartsWidgetOwnProps {
952
955
  type CounterpartsWidgetProps = WidgetProviderProps & CounterpartsWidgetOwnProps;
953
956
 
954
957
  /**
955
- * Self-contained customers/vendors widget: lists counterparts with money
956
- * columns, and creates, edits, views, and deletes counterparts plus their
957
- * payment method and address. `counterpartType` selects customer (receivables)
958
- * vs vendor (payables) behavior. The provider/inner split keeps the public
959
- * component a pure {@link WidgetProvider} wrapper.
958
+ * Public {@link CounterpartsWidget} — the integrator-facing widget.
959
+ *
960
+ * The workspace-internal component additionally accepts a `passThrough` prop
961
+ * that tells it to give up its own analytics identity when a composing widget
962
+ * (`CustomersWidgetNative`, `BillPayWidgetNative`'s Vendors tab) mounts it to
963
+ * inherit the host's identity instead (EMBD-5384). That choice is set **only**
964
+ * by those composing widgets, never by integrators: an integrator's own
965
+ * standalone mount must always claim its own identity.
960
966
  *
961
- * @example
962
- * ```tsx
963
- * <CounterpartsWidget
964
- * counterpartType="customer"
965
- * baseUrl="https://api.tesouro.com"
966
- * widgetToken="wt_..."
967
- * organizationId="org_..."
968
- * />
969
- * ```
967
+ * `CounterpartsWidgetProps` deliberately omits `passThrough`, so typed (TS)
968
+ * consumers cannot pass it. This wrapper additionally strips any stray
969
+ * `passThrough` a non-typed (JS) host might pass at runtime before
970
+ * delegating, so the internal prop is unreachable from the published surface
971
+ * in every case — the widget's declaration in the emitted types carries no
972
+ * `passThrough`.
970
973
  */
971
- declare function CounterpartsWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, implementation, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, providerLabels, ...innerProps }: CounterpartsWidgetProps): React.JSX.Element;
974
+ declare function CounterpartsWidget(props: CounterpartsWidgetProps): ReactNode;
972
975
 
973
976
  export { CounterpartsWidget };
974
977
  export type { AddressFormSheetLabels, BankAccountFormSheetLabels, ConfirmDeleteDialogLabels, CounterpartActionTarget, CounterpartDetailsSheetLabels, CounterpartFormSheetLabels, CounterpartMessageLabels, CounterpartMode, CounterpartsScreenLabels, CounterpartsWidgetProps };
@@ -1,3 +1,2 @@
1
- import { CounterpartsWidget as e } from "../libs/tesouro-embedded-components-react/counterparts-widget/feature/dist/index8.js";
2
- import "../libs/tesouro-embedded-components-react/counterparts-widget/feature/dist/index.js";
1
+ import { CounterpartsWidget as e } from "./CounterpartsWidgetPublic.js";
3
2
  export { e as CounterpartsWidget };