@npm-zenwork/tax-remittance-ui 0.2.4 → 0.2.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api/bankAccounts.d.ts +9 -7
- package/dist/api/dashboard.d.ts +3 -1
- package/dist/api/entities.d.ts +10 -7
- package/dist/api/remittancePayments.d.ts +2 -0
- package/dist/api/taxAccounts.d.ts +10 -1
- package/dist/components/dashboard/AddFirstPaymentModal.d.ts +12 -0
- package/dist/components/dashboard/DashboardKpiCards.d.ts +10 -0
- package/dist/components/dashboard/FederalPaymentsChartCard.d.ts +11 -0
- package/dist/components/dashboard/NeedAttentionCarousel.d.ts +6 -0
- package/dist/components/dashboard/PaymentsTypeCard.d.ts +7 -0
- package/dist/components/dashboard/RecentPaymentsCard.d.ts +6 -0
- package/dist/components/dashboard/RowActionsMenu.d.ts +13 -0
- package/dist/components/dashboard/SetupChecklist.d.ts +22 -0
- package/dist/components/dashboard/StatePaymentsChartCard.d.ts +11 -0
- package/dist/components/dashboard/TaxYearSelect.d.ts +9 -0
- package/dist/components/dashboard/UpcomingPaymentsCard.d.ts +6 -0
- package/dist/components/dashboard/dashboardMockData.d.ts +63 -0
- package/dist/components/dashboard/dashboardOverviewMappers.d.ts +15 -0
- package/dist/components/dashboard/dashboardUtils.d.ts +18 -0
- package/dist/components/dashboard/useSetupProgress.d.ts +30 -0
- package/dist/components/entities/EntityActionsMenu.d.ts +3 -1
- package/dist/components/entities/EntityCard.d.ts +8 -0
- package/dist/components/entities/EntityTypeFilter.d.ts +8 -0
- package/dist/components/entities/entityListUtils.d.ts +5 -8
- package/dist/components/forms/PhoneInputGroup.d.ts +5 -7
- package/dist/components/forms/SegmentedControl.d.ts +9 -5
- package/dist/components/icons/BankIcon.d.ts +1 -0
- package/dist/components/icons/BusinessIcon.d.ts +1 -0
- package/dist/components/icons/CheckCircleIcon.d.ts +1 -0
- package/dist/components/icons/EmptyTaxAccountsIllustration.d.ts +5 -0
- package/dist/components/icons/EntitySuccessIllustration.d.ts +2 -0
- package/dist/components/icons/EyeIcon.d.ts +1 -0
- package/dist/components/icons/EyeOffIcon.d.ts +1 -0
- package/dist/components/icons/IndividualEntitySuccessIllustration.d.ts +2 -0
- package/dist/components/icons/PersonIcon.d.ts +1 -0
- package/dist/components/icons/XCircleIcon.d.ts +1 -0
- package/dist/components/onboarding/EntityAccountTypeRow.d.ts +16 -0
- package/dist/components/onboarding/EntityAddressFields.d.ts +17 -0
- package/dist/components/onboarding/EntityBusinessFields.d.ts +17 -0
- package/dist/components/onboarding/EntityCreatedModal.d.ts +14 -0
- package/dist/components/onboarding/EntityForm.d.ts +5 -0
- package/dist/components/onboarding/EntityFormHelpPanel.d.ts +8 -0
- package/dist/components/onboarding/EntityIdNumberInput.d.ts +14 -0
- package/dist/components/onboarding/EntityPhoneField.d.ts +9 -0
- package/dist/components/onboarding/EntityPrimaryTaxpayerFields.d.ts +16 -0
- package/dist/components/onboarding/EntitySuccessModal.d.ts +35 -0
- package/dist/components/onboarding/SecondaryTaxpayerSection.d.ts +23 -0
- package/dist/components/onboarding/SecondaryTaxpayerToggle.d.ts +10 -0
- package/dist/components/onboarding/entityHelpContent.d.ts +123 -0
- package/dist/components/onboarding/useEntityForm.d.ts +80 -0
- package/dist/components/payments/BankAccountCard.d.ts +16 -0
- package/dist/components/payments/BankAccountDrawer.d.ts +15 -0
- package/dist/components/payments/BankConnectionMethodModal.d.ts +11 -0
- package/dist/components/payments/BankConnectionMethodPicker.d.ts +10 -0
- package/dist/components/payments/FederalPaymentReviewPanel.d.ts +14 -0
- package/dist/components/payments/FederalPaymentReviewStep.d.ts +13 -0
- package/dist/components/payments/InlineRowActions.d.ts +17 -0
- package/dist/components/payments/PaymentActionButton.d.ts +9 -0
- package/dist/components/payments/PaymentActionsFooter.d.ts +43 -0
- package/dist/components/payments/PaymentFormSection.d.ts +1 -1
- package/dist/components/payments/PaymentRowMenu.d.ts +14 -0
- package/dist/components/payments/PaymentStatusBadge.d.ts +7 -0
- package/dist/components/payments/PaymentStepper.d.ts +14 -0
- package/dist/components/payments/PaymentTableRow.d.ts +14 -0
- package/dist/components/payments/PaymentsNeedAttention.d.ts +14 -0
- package/dist/components/payments/RecurringPaymentToggle.d.ts +16 -0
- package/dist/components/payments/RecurringPeriodRows.d.ts +34 -0
- package/dist/components/payments/StateBankDetailsForm.d.ts +8 -0
- package/dist/components/payments/StatePaymentReviewPanel.d.ts +14 -0
- package/dist/components/payments/eftpsIndividualEnrollmentConfig.d.ts +3 -3
- package/dist/components/payments/federalPaymentSteps.d.ts +6 -0
- package/dist/components/payments/federalPaymentUtils.d.ts +4 -0
- package/dist/components/payments/paymentsTableConfig.d.ts +20 -9
- package/dist/components/payments/remittancePaymentMappers.d.ts +3 -0
- package/dist/components/payments/statePaymentAuthorizationConfig.d.ts +1 -1
- package/dist/components/payments/useStatePaymentDraftSave.d.ts +11 -0
- package/dist/components/settings/BankAccountActionsMenu.d.ts +3 -1
- package/dist/components/settings/EditEntityForm.d.ts +12 -0
- package/dist/components/settings/TaxAccountDrawer.d.ts +22 -0
- package/dist/components/settings/settingsNavConfig.d.ts +1 -1
- package/dist/components/settings/taxAccountDrawerConfig.d.ts +1 -0
- package/dist/components/tax-forms/TaxFormCard.d.ts +7 -0
- package/dist/components/tax-forms/TaxFormsGrid.d.ts +9 -0
- package/dist/components/tax-forms/states/virginia/VA16Form.d.ts +53 -0
- package/dist/components/tax-forms/states/virginia/VA16Form.preview.d.ts +2 -0
- package/dist/components/ui/SideDrawer.d.ts +18 -0
- package/dist/components/ui/StatusPill.d.ts +10 -0
- package/dist/components/ui/ToastProvider.d.ts +2 -2
- package/dist/embedded/EmbeddedContext.d.ts +4 -1
- package/dist/embedded/EmbeddedWidgetBase.d.ts +3 -1
- package/dist/embedded/TaxRemittanceEmbedded.d.ts +6 -0
- package/dist/embedded/pages/EmbeddedEntityEditPage.d.ts +6 -0
- package/dist/index.cjs +34 -34
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.mjs +14305 -11075
- package/dist/index.mjs.map +1 -1
- package/dist/lib/bankAccountInputRules.d.ts +17 -0
- package/dist/lib/entityFormUtils.d.ts +63 -8
- package/dist/lib/fieldRules.d.ts +92 -0
- package/dist/lib/fieldSchemas.d.ts +12 -0
- package/dist/lib/jwt.d.ts +10 -0
- package/dist/lib/paymentFrequency.d.ts +10 -0
- package/dist/lib/paymentStatus.d.ts +7 -0
- package/dist/lib/paymentsNavigation.d.ts +16 -2
- package/dist/lib/useElementWidth.d.ts +9 -0
- package/dist/pages/FederalPaymentReviewPage.d.ts +1 -0
- package/dist/pages/StateBankDetailsPage.d.ts +2 -0
- package/dist/styles.css +1 -1
- package/dist/types/bankAccount.d.ts +2 -0
- package/dist/types/createBankAccount.d.ts +2 -0
- package/dist/types/dashboard.d.ts +59 -0
- package/dist/types/entity.d.ts +27 -2
- package/dist/types/federalPaymentFlow.d.ts +2 -0
- package/dist/types/statePayment.d.ts +7 -0
- package/dist/types/statePaymentFlow.d.ts +3 -0
- package/dist/types/taxAccountDetails.d.ts +31 -29
- package/package.json +1 -1
- package/dist/api/paymentTransactions.d.ts +0 -7
- package/dist/components/dashboard/EmptyPaymentCard.d.ts +0 -9
- package/dist/components/dashboard/MonthlyOverviewSection.d.ts +0 -8
- package/dist/components/dashboard/MyPaymentsTable.d.ts +0 -8
- package/dist/components/dashboard/PaymentSummaryCard.d.ts +0 -21
- package/dist/components/payments/PaymentRowActions.d.ts +0 -13
- package/dist/components/settings/AddBankAccountManualForm.d.ts +0 -7
- package/dist/components/settings/AddBankAccountModal.d.ts +0 -8
- package/dist/components/settings/AddTaxAccountForm.d.ts +0 -32
- package/dist/components/settings/EditBankAccountModal.d.ts +0 -8
- package/dist/components/settings/EditEntityModal.d.ts +0 -8
- package/dist/components/settings/PaymentHistorySection.d.ts +0 -5
- package/dist/components/settings/SettingsPlaceholderSection.d.ts +0 -6
- package/dist/components/settings/taxAccountFormConfig.d.ts +0 -18
- package/dist/components/tax-forms/TaxFormsTable.d.ts +0 -8
- package/dist/pages/AddTaxAccountPage.d.ts +0 -1
- package/dist/pages/StatePaymentEditorPage.d.ts +0 -5
- package/dist/types/paymentHistory.d.ts +0 -26
- package/dist/types/taxAccount.d.ts +0 -9
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
import { BankAccountResponse } from '../types/bankAccount';
|
|
2
2
|
import { CreateBankAccountRequest, UpdateBankAccountRequest } from '../types/createBankAccount';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
3
|
+
/**
|
|
4
|
+
* The entity's bank accounts.
|
|
5
|
+
*
|
|
6
|
+
* GET /portal/bank-accounts returns a paged envelope in `data`
|
|
7
|
+
* (BankAccountController.List). Every `['bank-accounts', entityId]` consumer
|
|
8
|
+
* filters/paginates client-side, so this requests one large page and unwraps
|
|
9
|
+
* it to a bare array rather than exposing pagination to callers.
|
|
10
|
+
*/
|
|
11
|
+
export declare function getBankAccounts(entityId: number): Promise<BankAccountResponse[]>;
|
|
10
12
|
export declare function createBankAccount(request: CreateBankAccountRequest): Promise<BankAccountResponse>;
|
|
11
13
|
export declare function updateBankAccount(bankAccountDetailId: number, request: UpdateBankAccountRequest): Promise<BankAccountResponse>;
|
package/dist/api/dashboard.d.ts
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
import { DashboardPaymentsPage, DashboardPaymentsQuery, DashboardResponse, MonthlyOverview, PaymentCategorySummary } from '../types/dashboard';
|
|
1
|
+
import { DashboardCharts, DashboardOverview, DashboardPaymentsPage, DashboardPaymentsQuery, DashboardResponse, MonthlyOverview, PaymentCategorySummary } from '../types/dashboard';
|
|
2
2
|
export declare function getDashboard(entityId: number, taxYear?: number): Promise<DashboardResponse>;
|
|
3
3
|
export declare function getDashboardSummary(entityId: number, category: string, taxYear: number): Promise<PaymentCategorySummary>;
|
|
4
4
|
export declare function getDashboardMonthlyOverview(entityId: number, month: number, year?: number): Promise<MonthlyOverview>;
|
|
5
5
|
export declare function getDashboardPayments({ entityId, search, taxYear, status, page, pageSize, }: DashboardPaymentsQuery): Promise<DashboardPaymentsPage>;
|
|
6
|
+
export declare function getDashboardOverview(entityId: number, taxYear?: number): Promise<DashboardOverview>;
|
|
7
|
+
export declare function getDashboardCharts(entityId: number, taxYear?: number): Promise<DashboardCharts>;
|
package/dist/api/entities.d.ts
CHANGED
|
@@ -1,17 +1,20 @@
|
|
|
1
1
|
import { CreateEntityDetailsRequest, EntityDetailsResponse, UpdateEntityDetailsRequest } from '../types/entity';
|
|
2
|
-
import { PagedResult } from '../types/pagination';
|
|
3
2
|
interface CreateEntityDetailsResponse {
|
|
4
3
|
entityId: number;
|
|
5
4
|
userId: number | null;
|
|
6
5
|
apiClientId: number | null;
|
|
7
6
|
status: string;
|
|
8
7
|
}
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
8
|
+
/**
|
|
9
|
+
* The caller's entity list.
|
|
10
|
+
*
|
|
11
|
+
* GET /portal/entities/mine returns a paged envelope in `data`
|
|
12
|
+
* (EntitiesController.GetMine). Backs the shared `['entities', 'mine']` query
|
|
13
|
+
* used by EmbeddedContext, the entity list page and the entity form, all of
|
|
14
|
+
* which filter/paginate client-side, so this requests one large page and
|
|
15
|
+
* unwraps it to a bare array rather than exposing pagination to callers.
|
|
16
|
+
*/
|
|
17
|
+
export declare function getAllMyEntities(): Promise<EntityDetailsResponse[]>;
|
|
15
18
|
export declare function createEntity(request: CreateEntityDetailsRequest): Promise<CreateEntityDetailsResponse>;
|
|
16
19
|
export declare function updateEntity(entityId: number, request: UpdateEntityDetailsRequest): Promise<EntityDetailsResponse>;
|
|
17
20
|
export {};
|
|
@@ -11,6 +11,8 @@ export interface RemittancePaymentResponse {
|
|
|
11
11
|
paymentDate: string;
|
|
12
12
|
status: string | null;
|
|
13
13
|
reason: string | null;
|
|
14
|
+
/** Federal tax form / state reason for payment — not served by the API yet. */
|
|
15
|
+
formType?: string | null;
|
|
14
16
|
}
|
|
15
17
|
export interface RemittancePaymentStatusCounts {
|
|
16
18
|
drafts: number;
|
|
@@ -2,10 +2,19 @@ import { CreateTaxAccountRequest, TaxAccountDetailResponse, UpdateTaxAccountRequ
|
|
|
2
2
|
import { PagedResult } from '../types/pagination';
|
|
3
3
|
export interface GetTaxAccountsQuery {
|
|
4
4
|
entityId: number;
|
|
5
|
+
state?: string;
|
|
6
|
+
reasonForPayment?: string;
|
|
7
|
+
status?: string;
|
|
5
8
|
pageNumber?: number;
|
|
6
9
|
pageSize?: number;
|
|
7
10
|
}
|
|
8
|
-
|
|
11
|
+
/**
|
|
12
|
+
* Lists tax accounts for an entity. When `state` and `reasonForPayment` are
|
|
13
|
+
* both supplied, this is also the State Payment autobind lookup — the
|
|
14
|
+
* EntityId+State+ReasonForPayment unique index guarantees at most one item
|
|
15
|
+
* comes back.
|
|
16
|
+
*/
|
|
17
|
+
export declare function getTaxAccounts({ entityId, state, reasonForPayment, status, pageNumber, pageSize, }: GetTaxAccountsQuery): Promise<PagedResult<TaxAccountDetailResponse>>;
|
|
9
18
|
export declare function getTaxAccount(taxAccountDetailId: number): Promise<TaxAccountDetailResponse>;
|
|
10
19
|
export declare function createTaxAccount(request: CreateTaxAccountRequest): Promise<TaxAccountDetailResponse>;
|
|
11
20
|
export declare function updateTaxAccount(taxAccountDetailId: number, request: UpdateTaxAccountRequest): Promise<TaxAccountDetailResponse>;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { PaymentType } from '../../embedded/EmbeddedContext';
|
|
2
|
+
interface AddFirstPaymentModalProps {
|
|
3
|
+
open: boolean;
|
|
4
|
+
onClose: () => void;
|
|
5
|
+
/** Payment types the host enabled — local is always shown as coming soon. */
|
|
6
|
+
enabledPayments: PaymentType[];
|
|
7
|
+
onSelectFederal: () => void;
|
|
8
|
+
onSelectState: () => void;
|
|
9
|
+
}
|
|
10
|
+
/** Payment-type picker shown when starting the first payment from the dashboard. */
|
|
11
|
+
export declare function AddFirstPaymentModal({ open, onClose, enabledPayments, onSelectFederal, onSelectState, }: AddFirstPaymentModalProps): import('react').ReactPortal | null;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { DashboardKpi } from './dashboardMockData';
|
|
2
|
+
interface DashboardKpiCardsProps {
|
|
3
|
+
items: DashboardKpi[];
|
|
4
|
+
}
|
|
5
|
+
/**
|
|
6
|
+
* Top row of the redesigned dashboard: four at-a-glance figures.
|
|
7
|
+
* Each card is label / value / caption with no chrome beyond a hairline border.
|
|
8
|
+
*/
|
|
9
|
+
export declare function DashboardKpiCards({ items }: DashboardKpiCardsProps): import("react").JSX.Element;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { TaxYearOption } from './dashboardUtils';
|
|
2
|
+
import { FederalQuarterPoint } from './dashboardMockData';
|
|
3
|
+
interface FederalPaymentsChartCardProps {
|
|
4
|
+
points: FederalQuarterPoint[];
|
|
5
|
+
/** Owned by the dashboard page — changing it refetches `points` for that year. */
|
|
6
|
+
taxYear: number;
|
|
7
|
+
taxYearOptions: TaxYearOption[];
|
|
8
|
+
onTaxYearChange: (taxYear: number) => void;
|
|
9
|
+
}
|
|
10
|
+
export declare function FederalPaymentsChartCard({ points, taxYear, taxYearOptions, onTaxYearChange, }: FederalPaymentsChartCardProps): import("react").JSX.Element;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export interface RowAction {
|
|
2
|
+
key: string;
|
|
3
|
+
label: string;
|
|
4
|
+
onSelect: () => void;
|
|
5
|
+
}
|
|
6
|
+
interface RowActionsMenuProps {
|
|
7
|
+
/** Accessible name, e.g. "Actions for IRS — Federal Q2 2026". */
|
|
8
|
+
label: string;
|
|
9
|
+
actions: RowAction[];
|
|
10
|
+
}
|
|
11
|
+
/** The `⋮` row menu used by the Recent and Upcoming payment lists. */
|
|
12
|
+
export declare function RowActionsMenu({ label, actions }: RowActionsMenuProps): import("react").JSX.Element;
|
|
13
|
+
export {};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export interface SetupStep {
|
|
2
|
+
title: string;
|
|
3
|
+
description: string;
|
|
4
|
+
/** Label for the call-to-action shown while this step is the active one. */
|
|
5
|
+
actionLabel: string;
|
|
6
|
+
done: boolean;
|
|
7
|
+
onAction?: () => void;
|
|
8
|
+
/** Where the "View" button goes once the step is done. */
|
|
9
|
+
onView?: () => void;
|
|
10
|
+
}
|
|
11
|
+
interface SetupChecklistProps {
|
|
12
|
+
/** First name of the signed-in user, when known. */
|
|
13
|
+
userName?: string;
|
|
14
|
+
steps: SetupStep[];
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* "Complete your setup" onboarding card. Shown in place of the dashboard
|
|
18
|
+
* until the user has an entity, a payment, a bank account and an authorized
|
|
19
|
+
* payment.
|
|
20
|
+
*/
|
|
21
|
+
export declare function SetupChecklist({ userName, steps }: SetupChecklistProps): import("react").JSX.Element;
|
|
22
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { TaxYearOption } from './dashboardUtils';
|
|
2
|
+
import { StatePaymentSlice } from './dashboardMockData';
|
|
3
|
+
interface StatePaymentsChartCardProps {
|
|
4
|
+
slices: StatePaymentSlice[];
|
|
5
|
+
/** Owned by the dashboard page — changing it refetches `slices` for that year. */
|
|
6
|
+
taxYear: number;
|
|
7
|
+
taxYearOptions: TaxYearOption[];
|
|
8
|
+
onTaxYearChange: (taxYear: number) => void;
|
|
9
|
+
}
|
|
10
|
+
export declare function StatePaymentsChartCard({ slices, taxYear, taxYearOptions, onTaxYearChange, }: StatePaymentsChartCardProps): import("react").JSX.Element;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { TaxYearOption } from './dashboardUtils';
|
|
2
|
+
interface TaxYearSelectProps {
|
|
3
|
+
value: number;
|
|
4
|
+
options: TaxYearOption[];
|
|
5
|
+
onChange: (value: number) => void;
|
|
6
|
+
}
|
|
7
|
+
/** Calendar-icon year picker sitting in the Federal and State chart headers. */
|
|
8
|
+
export declare function TaxYearSelect({ value, options, onChange }: TaxYearSelectProps): import("react").JSX.Element;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import { DashboardPaymentStatus } from './dashboardUtils';
|
|
2
|
+
export interface AttentionAlert {
|
|
3
|
+
/** Composite `category-id`, unique across both payment categories. */
|
|
4
|
+
id: string;
|
|
5
|
+
/** The payment this alert is about — the View / Re-Submit buttons open it. */
|
|
6
|
+
paymentId: number;
|
|
7
|
+
category: string;
|
|
8
|
+
amount: number;
|
|
9
|
+
/** Why it needs attention, e.g. `Payment Rejected`. */
|
|
10
|
+
reason: string;
|
|
11
|
+
/** Meta line parts, joined with `·` — jurisdiction, tax type, period. */
|
|
12
|
+
details: string[];
|
|
13
|
+
/** Label on the primary (red) action button. */
|
|
14
|
+
actionLabel: string;
|
|
15
|
+
}
|
|
16
|
+
export interface DashboardKpi {
|
|
17
|
+
key: string;
|
|
18
|
+
label: string;
|
|
19
|
+
value: string;
|
|
20
|
+
caption: string;
|
|
21
|
+
tone: 'default' | 'danger';
|
|
22
|
+
}
|
|
23
|
+
export interface RecentPaymentRow {
|
|
24
|
+
id: string;
|
|
25
|
+
jurisdiction: string;
|
|
26
|
+
period: string;
|
|
27
|
+
paymentDate: string;
|
|
28
|
+
/** Drives the badge colour; `statusLabel` is what the badge prints. */
|
|
29
|
+
status: DashboardPaymentStatus;
|
|
30
|
+
statusLabel: string;
|
|
31
|
+
formType: string;
|
|
32
|
+
amount: number;
|
|
33
|
+
}
|
|
34
|
+
export interface UpcomingPaymentRow {
|
|
35
|
+
id: string;
|
|
36
|
+
/** Three-letter month for the date chip, e.g. `JUL`. */
|
|
37
|
+
month: string;
|
|
38
|
+
/** Day of month for the date chip, e.g. `31`. */
|
|
39
|
+
day: string;
|
|
40
|
+
title: string;
|
|
41
|
+
dueLabel: string;
|
|
42
|
+
jurisdiction: string;
|
|
43
|
+
amount: number;
|
|
44
|
+
}
|
|
45
|
+
export interface FederalQuarterPoint {
|
|
46
|
+
label: string;
|
|
47
|
+
amount: number;
|
|
48
|
+
}
|
|
49
|
+
export interface StatePaymentSlice {
|
|
50
|
+
state: string;
|
|
51
|
+
count: number;
|
|
52
|
+
amount: number;
|
|
53
|
+
/** Donut segment + legend dot colour. Category colours, not theme colours. */
|
|
54
|
+
color: string;
|
|
55
|
+
}
|
|
56
|
+
export interface PaymentTypeBar {
|
|
57
|
+
/** Printed verbatim — the design only shows a percentage on some rows. */
|
|
58
|
+
label: string;
|
|
59
|
+
amount: number;
|
|
60
|
+
/** Bar fill width, 0-100. */
|
|
61
|
+
percent: number;
|
|
62
|
+
color: string;
|
|
63
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { DashboardNeedsAttentionItem, DashboardPaymentItem, DashboardUpcomingPayment, FederalQuarterAmount, StateJurisdictionAmount, StatePaymentTypeAmount } from '../../types/dashboard';
|
|
2
|
+
import { AttentionAlert, FederalQuarterPoint, PaymentTypeBar, RecentPaymentRow, StatePaymentSlice, UpcomingPaymentRow } from './dashboardMockData';
|
|
3
|
+
/** `2026-09-26` -> `09-26-2026`, matching the redesigned dashboard's table style. */
|
|
4
|
+
export declare function formatDashboardDate(isoDate: string): string;
|
|
5
|
+
/**
|
|
6
|
+
* item.status/statusLabel are already the backend's canonical dashboard bucket
|
|
7
|
+
* (`"paid" | "scheduled" | "submitted" | "failed" | "draft"`) and its display
|
|
8
|
+
* label — no re-derivation needed, just carried through.
|
|
9
|
+
*/
|
|
10
|
+
export declare function mapRecentPaymentRow(item: DashboardPaymentItem): RecentPaymentRow;
|
|
11
|
+
export declare function mapUpcomingPaymentRow(payment: DashboardUpcomingPayment, today?: Date): UpcomingPaymentRow;
|
|
12
|
+
export declare function mapNeedsAttentionAlerts(items: DashboardNeedsAttentionItem[]): AttentionAlert[];
|
|
13
|
+
export declare function mapFederalQuarterPoints(rows: FederalQuarterAmount[]): FederalQuarterPoint[];
|
|
14
|
+
export declare function mapStatePaymentSlices(rows: StateJurisdictionAmount[]): StatePaymentSlice[];
|
|
15
|
+
export declare function mapPaymentTypeBars(rows: StatePaymentTypeAmount[]): PaymentTypeBar[];
|
|
@@ -20,6 +20,24 @@ export interface PaymentCategorySummary {
|
|
|
20
20
|
percentDone: number;
|
|
21
21
|
}
|
|
22
22
|
export declare function formatDashboardCurrency(amount: number): string;
|
|
23
|
+
/**
|
|
24
|
+
* Currency with cents always shown. The redesigned dashboard tables and charts
|
|
25
|
+
* print `$12,450.00` rather than dropping `.00`, unlike formatDashboardCurrency.
|
|
26
|
+
*/
|
|
27
|
+
export declare function formatDashboardAmount(amount: number): string;
|
|
28
|
+
export interface TaxYearOption {
|
|
29
|
+
/** The year sent to the charts endpoint. */
|
|
30
|
+
value: number;
|
|
31
|
+
label: string;
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* Builds the `Current TY 2026 / TY 2025 / TY 2024` choices for the chart card
|
|
35
|
+
* headers. The numeric `value` is what the dashboard queries key on — the
|
|
36
|
+
* label is display only.
|
|
37
|
+
*/
|
|
38
|
+
export declare function buildTaxYearOptions(currentYear: number): TaxYearOption[];
|
|
39
|
+
/** Compact currency used by the State Payments legend, e.g. `$90.4k`. */
|
|
40
|
+
export declare function formatDashboardCompact(amount: number): string;
|
|
23
41
|
export declare function normalizePaymentStatus(status: string | null): DashboardPaymentStatus;
|
|
24
42
|
export declare function getStatusLabel(status: DashboardPaymentStatus, rawStatus?: string | null): string;
|
|
25
43
|
export declare function mapFederalPaymentToRow(payment: FederalPaymentResponse): DashboardPaymentRow;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { DashboardResponse } from '../../types/dashboard';
|
|
2
|
+
interface UseSetupProgressArgs {
|
|
3
|
+
entityId: number | null;
|
|
4
|
+
entityCount: number;
|
|
5
|
+
dashboard: DashboardResponse | undefined;
|
|
6
|
+
/**
|
|
7
|
+
* Full name of the signed-in user, when the host app supplies one. Embedded
|
|
8
|
+
* hosts own the session, so the widget's own storage is empty there.
|
|
9
|
+
*/
|
|
10
|
+
userName?: string;
|
|
11
|
+
}
|
|
12
|
+
export interface SetupProgress {
|
|
13
|
+
hasEntity: boolean;
|
|
14
|
+
hasPayment: boolean;
|
|
15
|
+
hasBankAccount: boolean;
|
|
16
|
+
hasAuthorizedPayment: boolean;
|
|
17
|
+
isComplete: boolean;
|
|
18
|
+
/** First name of the signed-in user, when the session carries one. */
|
|
19
|
+
userName?: string;
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Whether the four onboarding steps are done.
|
|
23
|
+
*
|
|
24
|
+
* Review & Authorize counts as done once a payment record exists, Draft
|
|
25
|
+
* included: the wizard only persists a payment after the authorization details
|
|
26
|
+
* are filled in, and scheduling happens later from the drafts tab. The API has
|
|
27
|
+
* no separate authorization flag to read.
|
|
28
|
+
*/
|
|
29
|
+
export declare function useSetupProgress({ entityId, entityCount, dashboard, userName, }: UseSetupProgressArgs): SetupProgress;
|
|
30
|
+
export {};
|
|
@@ -2,6 +2,8 @@ import { EntityDetailsResponse } from '../../types/entity';
|
|
|
2
2
|
interface EntityActionsMenuProps {
|
|
3
3
|
entity: EntityDetailsResponse;
|
|
4
4
|
onEdit: (entity: EntityDetailsResponse) => void;
|
|
5
|
+
/** `kebab` is the icon-only trigger used on the entity cards. */
|
|
6
|
+
variant?: 'button' | 'kebab';
|
|
5
7
|
}
|
|
6
|
-
export declare function EntityActionsMenu({ entity, onEdit }: EntityActionsMenuProps): import("react").JSX.Element;
|
|
8
|
+
export declare function EntityActionsMenu({ entity, onEdit, variant }: EntityActionsMenuProps): import("react").JSX.Element;
|
|
7
9
|
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { EntityDetailsResponse } from '../../types/entity';
|
|
2
|
+
interface EntityCardProps {
|
|
3
|
+
entity: EntityDetailsResponse;
|
|
4
|
+
selected: boolean;
|
|
5
|
+
onEdit: (entity: EntityDetailsResponse) => void;
|
|
6
|
+
}
|
|
7
|
+
export declare function EntityCard({ entity, selected, onEdit }: EntityCardProps): import("react").JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export declare const ALL_ENTITY_TYPES = "All";
|
|
2
|
+
interface EntityTypeFilterProps {
|
|
3
|
+
value: string;
|
|
4
|
+
onChange: (entityType: string) => void;
|
|
5
|
+
}
|
|
6
|
+
/** Filter-icon button opening the entity type list. `All` clears the filter. */
|
|
7
|
+
export declare function EntityTypeFilter({ value, onChange }: EntityTypeFilterProps): import("react").JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -1,14 +1,11 @@
|
|
|
1
1
|
import { EntityDetailsResponse } from '../../types/entity';
|
|
2
|
-
export declare function formatEin(idNumber: string): string;
|
|
3
|
-
export declare function formatSsn(idNumber: string): string;
|
|
4
|
-
/** Format a stored 9-digit id for display: SSN for Individual, EIN otherwise. */
|
|
5
|
-
export declare function formatIdNumber(idNumber: string, accountType: string): string;
|
|
6
2
|
/**
|
|
7
|
-
*
|
|
8
|
-
*
|
|
3
|
+
* Taxpayer-id and phone formatting now lives in `@/lib/fieldRules`, alongside
|
|
4
|
+
* the validation rules for the same fields, so the two can never drift apart.
|
|
5
|
+
* Re-exported here because the entity, settings and payment screens already
|
|
6
|
+
* import them from this module.
|
|
9
7
|
*/
|
|
10
|
-
export
|
|
11
|
-
export declare function formatPhone(phoneNumber: string): string;
|
|
8
|
+
export { formatEin, formatSsn, maskEin, maskSsn, maskIdNumber, formatIdNumber, formatIdNumberInput, formatPhone, } from '../../lib/fieldRules';
|
|
12
9
|
export declare function formatJoinedDate(date: string): string;
|
|
13
10
|
export declare function getJoinedYear(date: string): string;
|
|
14
11
|
export declare function matchesEntitySearch(entity: EntityDetailsResponse, query: string): boolean;
|
|
@@ -1,16 +1,14 @@
|
|
|
1
|
-
import { InputHTMLAttributes
|
|
1
|
+
import { InputHTMLAttributes } from 'react';
|
|
2
2
|
interface PhoneInputGroupProps {
|
|
3
3
|
label?: string;
|
|
4
4
|
required?: boolean;
|
|
5
5
|
error?: string;
|
|
6
|
-
countryCodeSelectProps: SelectHTMLAttributes<HTMLSelectElement>;
|
|
7
6
|
phoneInputProps: InputHTMLAttributes<HTMLInputElement>;
|
|
8
7
|
}
|
|
9
8
|
/**
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
* purely visual grouping.
|
|
9
|
+
* Phone number input with a shared focus ring on its wrapper.
|
|
10
|
+
* The country code is not user-editable — forms keep it in state as "+1" and
|
|
11
|
+
* prefix it onto the number when building the API payload.
|
|
14
12
|
*/
|
|
15
|
-
export declare function PhoneInputGroup({ label, required, error,
|
|
13
|
+
export declare function PhoneInputGroup({ label, required, error, phoneInputProps, }: PhoneInputGroupProps): import("react").JSX.Element;
|
|
16
14
|
export {};
|
|
@@ -10,13 +10,17 @@ interface SegmentedControlProps<T extends string> {
|
|
|
10
10
|
options: SegmentedControlOption<T>[];
|
|
11
11
|
value: T;
|
|
12
12
|
onChange: (value: T) => void;
|
|
13
|
+
/** false hugs the option labels instead of filling the column. */
|
|
14
|
+
fullWidth?: boolean;
|
|
15
|
+
/** Fires when any option receives focus — lets a contextual help panel follow the group. */
|
|
16
|
+
onFocus?: () => void;
|
|
13
17
|
}
|
|
14
18
|
/**
|
|
15
19
|
* Accessible segmented control (WAI-ARIA radiogroup pattern) for a small,
|
|
16
|
-
* mutually-exclusive set of options — e.g. Account Type.
|
|
17
|
-
* bordered
|
|
18
|
-
*
|
|
19
|
-
*
|
|
20
|
+
* mutually-exclusive set of options — e.g. Account Type. The options share one
|
|
21
|
+
* bordered track and split it evenly, so the control matches the height and
|
|
22
|
+
* width of an input sitting beside it in the same grid row. Generic — not tied
|
|
23
|
+
* to any specific option set.
|
|
20
24
|
*/
|
|
21
|
-
export declare function SegmentedControl<T extends string>({ label, required, options, value, onChange, }: SegmentedControlProps<T>): import("react").JSX.Element;
|
|
25
|
+
export declare function SegmentedControl<T extends string>({ label, required, options, value, onChange, fullWidth, onFocus, }: SegmentedControlProps<T>): import("react").JSX.Element;
|
|
22
26
|
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function BankIcon(): import("react").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function BusinessIcon(): import("react").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function CheckCircleIcon(): import("react").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function EyeIcon(): import("react").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function EyeOffIcon(): import("react").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function PersonIcon(): import("react").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function XCircleIcon(): import("react").JSX.Element;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { EntityFormValues } from '../../types/entity';
|
|
2
|
+
import { HelpKey } from './entityHelpContent';
|
|
3
|
+
interface EntityAccountTypeRowProps {
|
|
4
|
+
accountType: EntityFormValues['accountType'];
|
|
5
|
+
onAccountTypeChange: (next: EntityFormValues['accountType']) => void;
|
|
6
|
+
isIndividual: boolean;
|
|
7
|
+
filingStatus?: string;
|
|
8
|
+
onFilingStatusChange?: (value: string) => void;
|
|
9
|
+
focusHelp: (key: HelpKey) => () => void;
|
|
10
|
+
resetHelp: () => void;
|
|
11
|
+
/** Off where filing status isn't part of the payload (edit flow). */
|
|
12
|
+
showFilingStatus?: boolean;
|
|
13
|
+
}
|
|
14
|
+
/** Account Type toggle, plus Filing Status for individual accounts. */
|
|
15
|
+
export declare function EntityAccountTypeRow({ accountType, onAccountTypeChange, isIndividual, filingStatus, onFilingStatusChange, focusHelp, resetHelp, showFilingStatus, }: EntityAccountTypeRowProps): import("react").JSX.Element;
|
|
16
|
+
export {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { FieldErrors, UseFormRegister, UseFormRegisterReturn } from 'react-hook-form';
|
|
2
|
+
import { StateOption } from '../../lib/useAddressReference';
|
|
3
|
+
import { EntityFormValues } from '../../types/entity';
|
|
4
|
+
import { HelpKey } from './entityHelpContent';
|
|
5
|
+
interface EntityAddressFieldsProps {
|
|
6
|
+
register: UseFormRegister<EntityFormValues>;
|
|
7
|
+
errors: FieldErrors<EntityFormValues>;
|
|
8
|
+
zipRegister: UseFormRegisterReturn;
|
|
9
|
+
isUS: boolean;
|
|
10
|
+
state: string;
|
|
11
|
+
stateOptions: StateOption[];
|
|
12
|
+
zipStateMismatch: boolean;
|
|
13
|
+
focusHelp: (key: HelpKey) => () => void;
|
|
14
|
+
}
|
|
15
|
+
/** Registered address for the entity — labels and formatting follow the country. */
|
|
16
|
+
export declare function EntityAddressFields({ register, errors, zipRegister, isUS, state, stateOptions, zipStateMismatch, focusHelp, }: EntityAddressFieldsProps): import("react").JSX.Element;
|
|
17
|
+
export {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { FieldErrors, UseFormRegister, UseFormRegisterReturn } from 'react-hook-form';
|
|
2
|
+
import { EntityFormValues } from '../../types/entity';
|
|
3
|
+
import { HelpKey } from './entityHelpContent';
|
|
4
|
+
interface EntityBusinessFieldsProps {
|
|
5
|
+
register: UseFormRegister<EntityFormValues>;
|
|
6
|
+
errors: FieldErrors<EntityFormValues>;
|
|
7
|
+
einRegister: UseFormRegisterReturn;
|
|
8
|
+
phoneRegister: UseFormRegisterReturn;
|
|
9
|
+
accountType: string;
|
|
10
|
+
idLabel: string;
|
|
11
|
+
idPlaceholder: string;
|
|
12
|
+
idMaxLength: number;
|
|
13
|
+
focusHelp: (key: HelpKey) => () => void;
|
|
14
|
+
}
|
|
15
|
+
/** Business account fields: names, contact details, entity type and EIN. */
|
|
16
|
+
export declare function EntityBusinessFields({ register, errors, einRegister, phoneRegister, accountType, idLabel, idPlaceholder, idMaxLength, focusHelp, }: EntityBusinessFieldsProps): import("react").JSX.Element;
|
|
17
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { CreatedEntitySnapshot } from './useEntityForm';
|
|
2
|
+
interface EntityCreatedModalProps {
|
|
3
|
+
created: CreatedEntitySnapshot | null;
|
|
4
|
+
onClose: () => void;
|
|
5
|
+
onGoToDashboard: () => void;
|
|
6
|
+
onStartPayment: () => void;
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* Picks the right success-modal variant for what was just created: business
|
|
10
|
+
* entities get one details page, individuals get the primary taxpayer plus an
|
|
11
|
+
* optional second page for a joint filer.
|
|
12
|
+
*/
|
|
13
|
+
export declare function EntityCreatedModal({ created, onClose, onGoToDashboard, onStartPayment, }: EntityCreatedModalProps): import("react").JSX.Element;
|
|
14
|
+
export {};
|
|
@@ -1 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Add Entity form — business or individual, with the contextual help panel
|
|
3
|
+
* beside it and a success modal once the entity is created. All behaviour
|
|
4
|
+
* lives in useEntityForm; this is layout only.
|
|
5
|
+
*/
|
|
1
6
|
export declare function EntityForm(): import("react").JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { FieldHelp } from './entityHelpContent';
|
|
2
|
+
/**
|
|
3
|
+
* Context panel beside the form. Shows generic guidance until a field with
|
|
4
|
+
* dedicated copy is focused, then swaps in that field's help.
|
|
5
|
+
*/
|
|
6
|
+
export declare function EntityFormHelpPanel({ active }: {
|
|
7
|
+
active: FieldHelp | null;
|
|
8
|
+
}): import("react").JSX.Element;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { UseFormRegisterReturn } from 'react-hook-form';
|
|
2
|
+
interface EntityIdNumberInputProps {
|
|
3
|
+
/** "EIN" for Business, "SSN" for Individual. */
|
|
4
|
+
label: string;
|
|
5
|
+
placeholder: string;
|
|
6
|
+
maxLength: number;
|
|
7
|
+
accountType: string;
|
|
8
|
+
register: UseFormRegisterReturn;
|
|
9
|
+
error?: string;
|
|
10
|
+
onFocus: () => void;
|
|
11
|
+
}
|
|
12
|
+
/** EIN / SSN input — masks the dashes in as the user types. */
|
|
13
|
+
export declare function EntityIdNumberInput({ label, placeholder, maxLength, accountType, register, error, onFocus, }: EntityIdNumberInputProps): import("react").JSX.Element;
|
|
14
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { UseFormRegisterReturn } from 'react-hook-form';
|
|
2
|
+
interface EntityPhoneFieldProps {
|
|
3
|
+
phoneRegister: UseFormRegisterReturn;
|
|
4
|
+
error?: string;
|
|
5
|
+
onFocus: () => void;
|
|
6
|
+
}
|
|
7
|
+
/** National phone number, stripped to digits as the user types. */
|
|
8
|
+
export declare function EntityPhoneField({ phoneRegister, error, onFocus }: EntityPhoneFieldProps): import("react").JSX.Element;
|
|
9
|
+
export {};
|