@layerfi/components 0.1.108-alpha → 0.1.108
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/cjs/index.cjs +2737 -2549
- package/dist/esm/index.mjs +2731 -2543
- package/dist/index.css +120 -142
- package/dist/index.d.ts +263 -34
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -2798,21 +2798,6 @@ declare module '@layerfi/components/components/DetailReportBreadcrumb/DetailRepo
|
|
|
2798
2798
|
}
|
|
2799
2799
|
export const DetailReportBreadcrumb: ({ breadcrumbs, subtitle, onBreadcrumbClick, }: DetailReportBreadcrumbProps) => import("react/jsx-runtime").JSX.Element;
|
|
2800
2800
|
|
|
2801
|
-
}
|
|
2802
|
-
declare module '@layerfi/components/components/DetailReportHeader/DetailReportHeader' {
|
|
2803
|
-
import { ReactNode } from 'react';
|
|
2804
|
-
export interface DetailReportHeaderProps {
|
|
2805
|
-
title: ReactNode;
|
|
2806
|
-
onClose: () => void;
|
|
2807
|
-
className?: string;
|
|
2808
|
-
}
|
|
2809
|
-
export const DetailReportHeader: ({ title, onClose, className, }: DetailReportHeaderProps) => import("react/jsx-runtime").JSX.Element;
|
|
2810
|
-
|
|
2811
|
-
}
|
|
2812
|
-
declare module '@layerfi/components/components/DetailReportHeader/index' {
|
|
2813
|
-
export { DetailReportHeader } from '@layerfi/components/components/DetailReportHeader/DetailReportHeader';
|
|
2814
|
-
export type { DetailReportHeaderProps } from '@layerfi/components/components/DetailReportHeader/DetailReportHeader';
|
|
2815
|
-
|
|
2816
2801
|
}
|
|
2817
2802
|
declare module '@layerfi/components/components/DetailsList/DetailsList' {
|
|
2818
2803
|
import { ReactNode } from 'react';
|
|
@@ -3720,12 +3705,12 @@ declare module '@layerfi/components/components/Invoices/Modal/InvoiceRefundModal
|
|
|
3720
3705
|
}
|
|
3721
3706
|
declare module '@layerfi/components/components/Invoices/Modal/InvoiceResetModal' {
|
|
3722
3707
|
import { ModalProps } from '@layerfi/components/components/ui/Modal/Modal';
|
|
3723
|
-
import type
|
|
3708
|
+
import { type Invoice } from '@layerfi/components/features/invoices/invoiceSchemas';
|
|
3724
3709
|
type InvoiceResetModalProps = Pick<ModalProps, 'isOpen' | 'onOpenChange'> & {
|
|
3725
|
-
|
|
3710
|
+
invoice: Invoice;
|
|
3726
3711
|
onSuccess: (invoice: Invoice) => void;
|
|
3727
3712
|
};
|
|
3728
|
-
export function InvoiceResetModal({ isOpen, onOpenChange,
|
|
3713
|
+
export function InvoiceResetModal({ isOpen, onOpenChange, invoice, onSuccess }: InvoiceResetModalProps): import("react/jsx-runtime").JSX.Element;
|
|
3729
3714
|
export {};
|
|
3730
3715
|
|
|
3731
3716
|
}
|
|
@@ -4677,6 +4662,19 @@ declare module '@layerfi/components/components/ProfitAndLossDetailReport/ProfitA
|
|
|
4677
4662
|
}
|
|
4678
4663
|
export const ProfitAndLossDetailReport: ({ lineItemName, breadcrumbPath, onClose, onBreadcrumbClick, stringOverrides, }: ProfitAndLossDetailReportProps) => import("react/jsx-runtime").JSX.Element;
|
|
4679
4664
|
|
|
4665
|
+
}
|
|
4666
|
+
declare module '@layerfi/components/components/ProfitAndLossDetailedCharts/DetailReportModal' {
|
|
4667
|
+
import { type ProfitAndLossDetailReportProps } from '@layerfi/components/components/ProfitAndLossDetailReport/ProfitAndLossDetailReport';
|
|
4668
|
+
import { type SelectedLineItem } from '@layerfi/components/components/ProfitAndLossReport/ProfitAndLossReport';
|
|
4669
|
+
export interface DetailReportModalProps {
|
|
4670
|
+
isOpen: boolean;
|
|
4671
|
+
onOpenChange: (isOpen: boolean) => void;
|
|
4672
|
+
selectedItem: SelectedLineItem | null;
|
|
4673
|
+
onBreadcrumbClick?: (lineItemName: string) => void;
|
|
4674
|
+
stringOverrides?: ProfitAndLossDetailReportProps['stringOverrides'];
|
|
4675
|
+
}
|
|
4676
|
+
export function DetailReportModal({ isOpen, onOpenChange, selectedItem, onBreadcrumbClick, stringOverrides, }: DetailReportModalProps): import("react/jsx-runtime").JSX.Element;
|
|
4677
|
+
|
|
4680
4678
|
}
|
|
4681
4679
|
declare module '@layerfi/components/components/ProfitAndLossDetailedCharts/DetailedChart' {
|
|
4682
4680
|
import { SidebarScope } from '@layerfi/components/hooks/useProfitAndLoss/useProfitAndLoss';
|
|
@@ -4714,13 +4712,14 @@ declare module '@layerfi/components/components/ProfitAndLossDetailedCharts/Detai
|
|
|
4714
4712
|
sortBy: (scope: Scope, field: string, direction?: SortDirection) => void;
|
|
4715
4713
|
chartColorsList?: string[];
|
|
4716
4714
|
stringOverrides?: DetailedTableStringOverrides;
|
|
4715
|
+
onValueClick?: (item: PnlChartLineItem) => void;
|
|
4717
4716
|
}
|
|
4718
4717
|
export interface TypeColorMapping {
|
|
4719
4718
|
color: string;
|
|
4720
4719
|
opacity: number;
|
|
4721
4720
|
}
|
|
4722
4721
|
export const mapTypesToColors: (data: PnlChartLineItem[], colorList?: string[]) => TypeColorMapping[];
|
|
4723
|
-
export const DetailedTable: ({ filteredData, sidebarScope, filters, sortBy, hoveredItem, setHoveredItem, chartColorsList, stringOverrides, }: DetailedTableProps) => import("react/jsx-runtime").JSX.Element;
|
|
4722
|
+
export const DetailedTable: ({ filteredData, sidebarScope, filters, sortBy, hoveredItem, setHoveredItem, chartColorsList, stringOverrides, onValueClick, }: DetailedTableProps) => import("react/jsx-runtime").JSX.Element;
|
|
4724
4723
|
|
|
4725
4724
|
}
|
|
4726
4725
|
declare module '@layerfi/components/components/ProfitAndLossDetailedCharts/Filters' {
|
|
@@ -4738,8 +4737,10 @@ declare module '@layerfi/components/components/ProfitAndLossDetailedCharts/Filte
|
|
|
4738
4737
|
declare module '@layerfi/components/components/ProfitAndLossDetailedCharts/ProfitAndLossDetailedCharts' {
|
|
4739
4738
|
import { SidebarScope } from '@layerfi/components/hooks/useProfitAndLoss/useProfitAndLoss';
|
|
4740
4739
|
import { DetailedTableStringOverrides } from '@layerfi/components/components/ProfitAndLossDetailedCharts/DetailedTable';
|
|
4740
|
+
import type { ProfitAndLossDetailReportProps } from '@layerfi/components/components/ProfitAndLossDetailReport/ProfitAndLossDetailReport';
|
|
4741
4741
|
export interface ProfitAndLossDetailedChartsStringOverrides {
|
|
4742
4742
|
detailedTableStringOverrides?: DetailedTableStringOverrides;
|
|
4743
|
+
detailReportStringOverrides?: ProfitAndLossDetailReportProps['stringOverrides'];
|
|
4743
4744
|
}
|
|
4744
4745
|
export const ProfitAndLossDetailedCharts: ({ scope, hideClose, showDatePicker, chartColorsList, stringOverrides, }: {
|
|
4745
4746
|
scope?: SidebarScope;
|
|
@@ -4796,6 +4797,7 @@ declare module '@layerfi/components/components/ProfitAndLossReport/ProfitAndLoss
|
|
|
4796
4797
|
import { View as ViewType } from '@layerfi/components/types/general';
|
|
4797
4798
|
import { ReportsStringOverrides } from '@layerfi/components/views/Reports/Reports';
|
|
4798
4799
|
import type { TimeRangePickerConfig } from '@layerfi/components/views/Reports/reportTypes';
|
|
4800
|
+
import { BreadcrumbItem } from '@layerfi/components/components/DetailReportBreadcrumb/DetailReportBreadcrumb';
|
|
4799
4801
|
import { LinkingMetadata } from '@layerfi/components/contexts/InAppLinkContext';
|
|
4800
4802
|
type ViewBreakpoint = ViewType | undefined;
|
|
4801
4803
|
export type ProfitAndLossReportProps = {
|
|
@@ -4803,6 +4805,10 @@ declare module '@layerfi/components/components/ProfitAndLossReport/ProfitAndLoss
|
|
|
4803
4805
|
view?: ViewBreakpoint;
|
|
4804
4806
|
renderInAppLink?: (source: LinkingMetadata) => ReactNode;
|
|
4805
4807
|
} & TimeRangePickerConfig;
|
|
4808
|
+
export type SelectedLineItem = {
|
|
4809
|
+
lineItemName: string;
|
|
4810
|
+
breadcrumbPath: BreadcrumbItem[];
|
|
4811
|
+
};
|
|
4806
4812
|
export const ProfitAndLossReport: ({ stringOverrides, allowedDatePickerModes, datePickerMode, defaultDatePickerMode, customDateRanges, csvMoneyFormat, view, renderInAppLink, }: ProfitAndLossReportProps) => import("react/jsx-runtime").JSX.Element;
|
|
4807
4813
|
export {};
|
|
4808
4814
|
|
|
@@ -5306,16 +5312,19 @@ declare module '@layerfi/components/components/Tasks/TasksList' {
|
|
|
5306
5312
|
pageSize?: number;
|
|
5307
5313
|
mobile?: boolean;
|
|
5308
5314
|
};
|
|
5309
|
-
export
|
|
5315
|
+
export const TasksList: ({ pageSize, mobile }: TasksListProps) => import("react/jsx-runtime").JSX.Element;
|
|
5310
5316
|
export {};
|
|
5311
5317
|
|
|
5312
5318
|
}
|
|
5313
5319
|
declare module '@layerfi/components/components/Tasks/TasksListItem' {
|
|
5314
5320
|
import { type UserVisibleTask } from '@layerfi/components/utils/bookkeeping/tasks/bookkeepingTasksFilters';
|
|
5315
|
-
|
|
5321
|
+
type TasksListItemProps = {
|
|
5316
5322
|
task: UserVisibleTask;
|
|
5317
5323
|
defaultOpen: boolean;
|
|
5318
|
-
|
|
5324
|
+
onExpandTask?: (isOpen: boolean) => void;
|
|
5325
|
+
};
|
|
5326
|
+
export const TasksListItem: import("react").ForwardRefExoticComponent<TasksListItemProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
5327
|
+
export {};
|
|
5319
5328
|
|
|
5320
5329
|
}
|
|
5321
5330
|
declare module '@layerfi/components/components/Tasks/TasksListMobile' {
|
|
@@ -6035,7 +6044,7 @@ declare module '@layerfi/components/components/ui/Meter/Meter' {
|
|
|
6035
6044
|
declare module '@layerfi/components/components/ui/Modal/Modal' {
|
|
6036
6045
|
import { type ComponentProps } from 'react';
|
|
6037
6046
|
import { type DialogProps, type ModalOverlayProps } from 'react-aria-components';
|
|
6038
|
-
type ModalSize = 'md' | 'lg';
|
|
6047
|
+
type ModalSize = 'md' | 'lg' | 'xl';
|
|
6039
6048
|
type ModalVariant = 'center' | 'drawer' | 'mobile-drawer';
|
|
6040
6049
|
const ModalOverlay: import("react").ForwardRefExoticComponent<Omit<ModalOverlayProps, "className"> & {
|
|
6041
6050
|
variant: ModalVariant;
|
|
@@ -6075,14 +6084,15 @@ declare module '@layerfi/components/components/ui/Modal/ModalSlots' {
|
|
|
6075
6084
|
onClose?: () => void;
|
|
6076
6085
|
};
|
|
6077
6086
|
export const ModalTitleWithClose: import("react").ForwardRefExoticComponent<ModalTitleWithCloseProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
6078
|
-
export const ModalHeading: import("react").ForwardRefExoticComponent<Omit<Omit<
|
|
6087
|
+
export const ModalHeading: import("react").ForwardRefExoticComponent<Omit<Omit<import("react-aria-components").HeadingProps & {
|
|
6079
6088
|
align?: "center";
|
|
6080
6089
|
pbe?: import("@layerfi/components/components/ui/sharedUITypes").Spacing;
|
|
6081
6090
|
pie?: import("@layerfi/components/components/ui/sharedUITypes").Spacing;
|
|
6082
6091
|
size?: "2xs" | "xs" | "sm" | "lg" | "xl";
|
|
6083
6092
|
variant?: "subtle";
|
|
6084
6093
|
weight?: "normal" | "bold";
|
|
6085
|
-
|
|
6094
|
+
ellipsis?: true;
|
|
6095
|
+
} & import("react").RefAttributes<HTMLHeadingElement>, "slot" | "level">, "ref"> & import("react").RefAttributes<HTMLHeadingElement>>;
|
|
6086
6096
|
export const ModalDescription: import("react").ForwardRefExoticComponent<Omit<Omit<Pick<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLParagraphElement>, HTMLParagraphElement>, "ref">, "id" | "slot"> & {
|
|
6087
6097
|
nonAria?: true;
|
|
6088
6098
|
} & import("@layerfi/components/components/ui/Typography/Text").TextStyleProps & {
|
|
@@ -6231,6 +6241,7 @@ declare module '@layerfi/components/components/ui/TagGroup/TagGroup' {
|
|
|
6231
6241
|
|
|
6232
6242
|
}
|
|
6233
6243
|
declare module '@layerfi/components/components/ui/Typography/Heading' {
|
|
6244
|
+
import { HeadingProps as ReactAriaHeadingProps } from 'react-aria-components';
|
|
6234
6245
|
import type { Spacing } from '@layerfi/components/components/ui/sharedUITypes';
|
|
6235
6246
|
type HeadingDataProps = {
|
|
6236
6247
|
align?: 'center';
|
|
@@ -6239,8 +6250,9 @@ declare module '@layerfi/components/components/ui/Typography/Heading' {
|
|
|
6239
6250
|
size?: '2xs' | 'xs' | 'sm' | 'lg' | 'xl';
|
|
6240
6251
|
variant?: 'subtle';
|
|
6241
6252
|
weight?: 'normal' | 'bold';
|
|
6253
|
+
ellipsis?: true;
|
|
6242
6254
|
};
|
|
6243
|
-
const Heading: import("react").ForwardRefExoticComponent<
|
|
6255
|
+
const Heading: import("react").ForwardRefExoticComponent<ReactAriaHeadingProps & HeadingDataProps & import("react").RefAttributes<HTMLHeadingElement>>;
|
|
6244
6256
|
export { Heading };
|
|
6245
6257
|
|
|
6246
6258
|
}
|
|
@@ -7212,6 +7224,11 @@ declare module '@layerfi/components/features/customers/components/CustomerSelect
|
|
|
7212
7224
|
export function CustomerSelector({ selectedCustomer, onSelectedCustomerChange, placeholder, isReadOnly, inline, className, }: CustomerSelectorProps): import("react/jsx-runtime").JSX.Element;
|
|
7213
7225
|
export {};
|
|
7214
7226
|
|
|
7227
|
+
}
|
|
7228
|
+
declare module '@layerfi/components/features/customers/util' {
|
|
7229
|
+
import type { Customer } from '@layerfi/components/schemas/customer';
|
|
7230
|
+
export function getCustomerName(customer?: Customer | null): string;
|
|
7231
|
+
|
|
7215
7232
|
}
|
|
7216
7233
|
declare module '@layerfi/components/features/forms/components/BaseFormTextField' {
|
|
7217
7234
|
import type { PropsWithChildren } from 'react';
|
|
@@ -7348,8 +7365,9 @@ declare module '@layerfi/components/features/invoices/api/useListInvoices' {
|
|
|
7348
7365
|
type ListInvoicesBaseParams = {
|
|
7349
7366
|
businessId: string;
|
|
7350
7367
|
};
|
|
7351
|
-
type ListInvoicesFilterParams = {
|
|
7368
|
+
export type ListInvoicesFilterParams = {
|
|
7352
7369
|
status?: ReadonlyArray<InvoiceStatus>;
|
|
7370
|
+
query?: string;
|
|
7353
7371
|
dueAtStart?: Date;
|
|
7354
7372
|
dueAtEnd?: Date;
|
|
7355
7373
|
};
|
|
@@ -7672,7 +7690,7 @@ declare module '@layerfi/components/features/invoices/api/useListInvoices' {
|
|
|
7672
7690
|
};
|
|
7673
7691
|
};
|
|
7674
7692
|
}>;
|
|
7675
|
-
export function useListInvoices({ status, dueAtStart, dueAtEnd, sortBy, sortOrder, limit, showTotalCount, }?: ListInvoicesOptions): ListInvoicesSWRResponse;
|
|
7693
|
+
export function useListInvoices({ status, query, dueAtStart, dueAtEnd, sortBy, sortOrder, limit, showTotalCount, }?: ListInvoicesOptions): ListInvoicesSWRResponse;
|
|
7676
7694
|
export function useInvoicesGlobalCacheActions(): {
|
|
7677
7695
|
patchInvoiceByKey: (updatedInvoice: Invoice) => Promise<({
|
|
7678
7696
|
readonly data: readonly {
|
|
@@ -7971,6 +7989,191 @@ declare module '@layerfi/components/features/invoices/api/useRefundInvoice' {
|
|
|
7971
7989
|
export const useRefundInvoice: ({ invoiceId }: UseRefundInvoiceProps) => RefundInvoiceSWRResponse;
|
|
7972
7990
|
export {};
|
|
7973
7991
|
|
|
7992
|
+
}
|
|
7993
|
+
declare module '@layerfi/components/features/invoices/api/useResetInvoice' {
|
|
7994
|
+
import type { Key } from 'swr';
|
|
7995
|
+
import { type SWRMutationResponse } from 'swr/mutation';
|
|
7996
|
+
import { Schema } from 'effect';
|
|
7997
|
+
const ResetInvoiceReturnSchema: Schema.Struct<{
|
|
7998
|
+
data: Schema.Struct<{
|
|
7999
|
+
id: typeof Schema.UUID;
|
|
8000
|
+
businessId: Schema.PropertySignature<":", string, "business_id", ":", string, false, never>;
|
|
8001
|
+
externalId: Schema.PropertySignature<":", string | null, "external_id", ":", string | null, false, never>;
|
|
8002
|
+
status: Schema.transform<typeof Schema.NonEmptyTrimmedString, Schema.SchemaClass<import("@layerfi/components/features/invoices/invoiceSchemas").InvoiceStatus, import("../invoiceSchemas").InvoiceStatus, never>>;
|
|
8003
|
+
sentAt: Schema.PropertySignature<":", Date | null, "sent_at", ":", string | null, false, never>;
|
|
8004
|
+
dueAt: Schema.PropertySignature<":", Date | null, "due_at", ":", string | null, false, never>;
|
|
8005
|
+
paidAt: Schema.PropertySignature<":", Date | null, "paid_at", ":", string | null, false, never>;
|
|
8006
|
+
voidedAt: Schema.PropertySignature<":", Date | null, "voided_at", ":", string | null, false, never>;
|
|
8007
|
+
invoiceNumber: Schema.PropertySignature<":", string | null, "invoice_number", ":", string | null, false, never>;
|
|
8008
|
+
recipientName: Schema.PropertySignature<":", string | null, "recipient_name", ":", string | null, false, never>;
|
|
8009
|
+
customer: Schema.NullOr<Schema.Struct<{
|
|
8010
|
+
id: typeof Schema.UUID;
|
|
8011
|
+
externalId: Schema.PropertySignature<":", string | null, "external_id", ":", string | null, false, never>;
|
|
8012
|
+
individualName: Schema.PropertySignature<":", string | null, "individual_name", ":", string | null, false, never>;
|
|
8013
|
+
companyName: Schema.PropertySignature<":", string | null, "company_name", ":", string | null, false, never>;
|
|
8014
|
+
email: Schema.NullOr<typeof Schema.String>;
|
|
8015
|
+
mobilePhone: Schema.PropertySignature<":", string | null, "mobile_phone", ":", string | null, false, never>;
|
|
8016
|
+
officePhone: Schema.PropertySignature<":", string | null, "office_phone", ":", string | null, false, never>;
|
|
8017
|
+
addressString: Schema.PropertySignature<":", string | null, "address_string", ":", string | null, false, never>;
|
|
8018
|
+
status: Schema.transform<typeof Schema.NonEmptyTrimmedString, Schema.SchemaClass<"ACTIVE" | "ARCHIVED", "ACTIVE" | "ARCHIVED", never>>;
|
|
8019
|
+
memo: Schema.NullOr<typeof Schema.String>;
|
|
8020
|
+
_local: Schema.optional<Schema.Struct<{
|
|
8021
|
+
isOptimistic: typeof Schema.Boolean;
|
|
8022
|
+
}>>;
|
|
8023
|
+
}>>;
|
|
8024
|
+
lineItems: Schema.PropertySignature<":", readonly {
|
|
8025
|
+
readonly id: string;
|
|
8026
|
+
readonly externalId: string | null;
|
|
8027
|
+
readonly memo: string | null;
|
|
8028
|
+
readonly description: string | null;
|
|
8029
|
+
readonly invoiceId: string;
|
|
8030
|
+
readonly product: string | null;
|
|
8031
|
+
readonly subtotal: number;
|
|
8032
|
+
readonly quantity: import("effect/BigDecimal").BigDecimal;
|
|
8033
|
+
readonly unitPrice: number;
|
|
8034
|
+
readonly discountAmount: number;
|
|
8035
|
+
readonly salesTaxTotal: number;
|
|
8036
|
+
readonly totalAmount: number;
|
|
8037
|
+
}[], "line_items", ":", readonly {
|
|
8038
|
+
readonly id: string;
|
|
8039
|
+
readonly external_id: string | null;
|
|
8040
|
+
readonly memo: string | null;
|
|
8041
|
+
readonly description: string | null;
|
|
8042
|
+
readonly invoice_id: string;
|
|
8043
|
+
readonly product: string | null;
|
|
8044
|
+
readonly subtotal: number;
|
|
8045
|
+
readonly quantity: string;
|
|
8046
|
+
readonly unit_price: number;
|
|
8047
|
+
readonly discount_amount: number;
|
|
8048
|
+
readonly sales_taxes_total: number;
|
|
8049
|
+
readonly total_amount: number;
|
|
8050
|
+
}[], false, never>;
|
|
8051
|
+
subtotal: typeof Schema.Number;
|
|
8052
|
+
additionalDiscount: Schema.PropertySignature<":", number, "additional_discount", ":", number, false, never>;
|
|
8053
|
+
additionalSalesTaxesTotal: Schema.PropertySignature<":", number, "additional_sales_taxes_total", ":", number, false, never>;
|
|
8054
|
+
totalAmount: Schema.PropertySignature<":", number, "total_amount", ":", number, false, never>;
|
|
8055
|
+
outstandingBalance: Schema.PropertySignature<":", number, "outstanding_balance", ":", number, false, never>;
|
|
8056
|
+
importedAt: Schema.PropertySignature<":", Date, "imported_at", ":", string, false, never>;
|
|
8057
|
+
updatedAt: Schema.PropertySignature<":", Date | null, "updated_at", ":", string | null, false, never>;
|
|
8058
|
+
memo: Schema.NullOr<typeof Schema.String>;
|
|
8059
|
+
}>;
|
|
8060
|
+
}>;
|
|
8061
|
+
type ResetInvoiceReturn = typeof ResetInvoiceReturnSchema.Type;
|
|
8062
|
+
type ResetInvoiceSWRMutationResponse = SWRMutationResponse<ResetInvoiceReturn, unknown, Key, never>;
|
|
8063
|
+
class ResetInvoiceSWRResponse {
|
|
8064
|
+
private swrResponse;
|
|
8065
|
+
constructor(swrResponse: ResetInvoiceSWRMutationResponse);
|
|
8066
|
+
get data(): {
|
|
8067
|
+
readonly data: {
|
|
8068
|
+
readonly id: string;
|
|
8069
|
+
readonly externalId: string | null;
|
|
8070
|
+
readonly status: import("@layerfi/components/features/invoices/invoiceSchemas").InvoiceStatus;
|
|
8071
|
+
readonly memo: string | null;
|
|
8072
|
+
readonly customer: {
|
|
8073
|
+
readonly id: string;
|
|
8074
|
+
readonly externalId: string | null;
|
|
8075
|
+
readonly individualName: string | null;
|
|
8076
|
+
readonly companyName: string | null;
|
|
8077
|
+
readonly email: string | null;
|
|
8078
|
+
readonly mobilePhone: string | null;
|
|
8079
|
+
readonly officePhone: string | null;
|
|
8080
|
+
readonly addressString: string | null;
|
|
8081
|
+
readonly status: "ACTIVE" | "ARCHIVED";
|
|
8082
|
+
readonly memo: string | null;
|
|
8083
|
+
readonly _local?: {
|
|
8084
|
+
readonly isOptimistic: boolean;
|
|
8085
|
+
} | undefined;
|
|
8086
|
+
} | null;
|
|
8087
|
+
readonly invoiceNumber: string | null;
|
|
8088
|
+
readonly recipientName: string | null;
|
|
8089
|
+
readonly businessId: string;
|
|
8090
|
+
readonly lineItems: readonly {
|
|
8091
|
+
readonly id: string;
|
|
8092
|
+
readonly externalId: string | null;
|
|
8093
|
+
readonly memo: string | null;
|
|
8094
|
+
readonly description: string | null;
|
|
8095
|
+
readonly invoiceId: string;
|
|
8096
|
+
readonly product: string | null;
|
|
8097
|
+
readonly subtotal: number;
|
|
8098
|
+
readonly quantity: import("effect/BigDecimal").BigDecimal;
|
|
8099
|
+
readonly unitPrice: number;
|
|
8100
|
+
readonly discountAmount: number;
|
|
8101
|
+
readonly salesTaxTotal: number;
|
|
8102
|
+
readonly totalAmount: number;
|
|
8103
|
+
}[];
|
|
8104
|
+
readonly updatedAt: Date | null;
|
|
8105
|
+
readonly subtotal: number;
|
|
8106
|
+
readonly paidAt: Date | null;
|
|
8107
|
+
readonly totalAmount: number;
|
|
8108
|
+
readonly sentAt: Date | null;
|
|
8109
|
+
readonly dueAt: Date | null;
|
|
8110
|
+
readonly voidedAt: Date | null;
|
|
8111
|
+
readonly additionalDiscount: number;
|
|
8112
|
+
readonly additionalSalesTaxesTotal: number;
|
|
8113
|
+
readonly outstandingBalance: number;
|
|
8114
|
+
readonly importedAt: Date;
|
|
8115
|
+
};
|
|
8116
|
+
} | undefined;
|
|
8117
|
+
get trigger(): import("swr/mutation").TriggerWithoutArgs<{
|
|
8118
|
+
readonly data: {
|
|
8119
|
+
readonly id: string;
|
|
8120
|
+
readonly externalId: string | null;
|
|
8121
|
+
readonly status: import("@layerfi/components/features/invoices/invoiceSchemas").InvoiceStatus;
|
|
8122
|
+
readonly memo: string | null;
|
|
8123
|
+
readonly customer: {
|
|
8124
|
+
readonly id: string;
|
|
8125
|
+
readonly externalId: string | null;
|
|
8126
|
+
readonly individualName: string | null;
|
|
8127
|
+
readonly companyName: string | null;
|
|
8128
|
+
readonly email: string | null;
|
|
8129
|
+
readonly mobilePhone: string | null;
|
|
8130
|
+
readonly officePhone: string | null;
|
|
8131
|
+
readonly addressString: string | null;
|
|
8132
|
+
readonly status: "ACTIVE" | "ARCHIVED";
|
|
8133
|
+
readonly memo: string | null;
|
|
8134
|
+
readonly _local?: {
|
|
8135
|
+
readonly isOptimistic: boolean;
|
|
8136
|
+
} | undefined;
|
|
8137
|
+
} | null;
|
|
8138
|
+
readonly invoiceNumber: string | null;
|
|
8139
|
+
readonly recipientName: string | null;
|
|
8140
|
+
readonly businessId: string;
|
|
8141
|
+
readonly lineItems: readonly {
|
|
8142
|
+
readonly id: string;
|
|
8143
|
+
readonly externalId: string | null;
|
|
8144
|
+
readonly memo: string | null;
|
|
8145
|
+
readonly description: string | null;
|
|
8146
|
+
readonly invoiceId: string;
|
|
8147
|
+
readonly product: string | null;
|
|
8148
|
+
readonly subtotal: number;
|
|
8149
|
+
readonly quantity: import("effect/BigDecimal").BigDecimal;
|
|
8150
|
+
readonly unitPrice: number;
|
|
8151
|
+
readonly discountAmount: number;
|
|
8152
|
+
readonly salesTaxTotal: number;
|
|
8153
|
+
readonly totalAmount: number;
|
|
8154
|
+
}[];
|
|
8155
|
+
readonly updatedAt: Date | null;
|
|
8156
|
+
readonly subtotal: number;
|
|
8157
|
+
readonly paidAt: Date | null;
|
|
8158
|
+
readonly totalAmount: number;
|
|
8159
|
+
readonly sentAt: Date | null;
|
|
8160
|
+
readonly dueAt: Date | null;
|
|
8161
|
+
readonly voidedAt: Date | null;
|
|
8162
|
+
readonly additionalDiscount: number;
|
|
8163
|
+
readonly additionalSalesTaxesTotal: number;
|
|
8164
|
+
readonly outstandingBalance: number;
|
|
8165
|
+
readonly importedAt: Date;
|
|
8166
|
+
};
|
|
8167
|
+
}, unknown, Key, never>;
|
|
8168
|
+
get isMutating(): boolean;
|
|
8169
|
+
get isError(): boolean;
|
|
8170
|
+
}
|
|
8171
|
+
type UseResetInvoiceProps = {
|
|
8172
|
+
invoiceId: string;
|
|
8173
|
+
};
|
|
8174
|
+
export const useResetInvoice: ({ invoiceId }: UseResetInvoiceProps) => ResetInvoiceSWRResponse;
|
|
8175
|
+
export {};
|
|
8176
|
+
|
|
7974
8177
|
}
|
|
7975
8178
|
declare module '@layerfi/components/features/invoices/api/useUpsertDedicatedInvoicePayment' {
|
|
7976
8179
|
import type { Key } from 'swr';
|
|
@@ -10177,6 +10380,15 @@ declare module '@layerfi/components/hooks/useLinkedAccounts/useListExternalAccou
|
|
|
10177
10380
|
export const EXTERNAL_ACCOUNTS_TAG_KEY = "#external-accounts";
|
|
10178
10381
|
export function useListExternalAccounts(): import("swr").SWRResponse<import("../../types/linked_accounts").LinkedAccount[], any, any>;
|
|
10179
10382
|
|
|
10383
|
+
}
|
|
10384
|
+
declare module '@layerfi/components/hooks/useMediaQuery' {
|
|
10385
|
+
/**
|
|
10386
|
+
* Hook to track media query matches
|
|
10387
|
+
* @param query - CSS media query string (e.g., '(max-width: 768px)')
|
|
10388
|
+
* @returns boolean indicating if the media query matches
|
|
10389
|
+
*/
|
|
10390
|
+
export function useMediaQuery(query: string): boolean;
|
|
10391
|
+
|
|
10180
10392
|
}
|
|
10181
10393
|
declare module '@layerfi/components/hooks/usePaginationRange/usePaginationRange' {
|
|
10182
10394
|
export enum Dots {
|
|
@@ -11121,6 +11333,7 @@ declare module '@layerfi/components/hooks/useProfitAndLoss/schemas' {
|
|
|
11121
11333
|
}
|
|
11122
11334
|
declare module '@layerfi/components/hooks/useProfitAndLoss/useProfitAndLoss' {
|
|
11123
11335
|
import { ReportingBasis, SortDirection } from '@layerfi/components/types';
|
|
11336
|
+
import { type PnlChartLineItem } from '@layerfi/components/utils/profitAndLossUtils';
|
|
11124
11337
|
export type Scope = 'expenses' | 'revenue';
|
|
11125
11338
|
export type SidebarScope = Scope | undefined;
|
|
11126
11339
|
export type PnlTagFilter = {
|
|
@@ -11222,9 +11435,9 @@ declare module '@layerfi/components/hooks/useProfitAndLoss/useProfitAndLoss' {
|
|
|
11222
11435
|
readonly lineItems: readonly import("@layerfi/components/utils/schema/utils").LineItem[];
|
|
11223
11436
|
} | null;
|
|
11224
11437
|
} | undefined;
|
|
11225
|
-
filteredDataRevenue: never[] |
|
|
11438
|
+
filteredDataRevenue: never[] | PnlChartLineItem[];
|
|
11226
11439
|
filteredTotalRevenue: number | undefined;
|
|
11227
|
-
filteredDataExpenses: never[] |
|
|
11440
|
+
filteredDataExpenses: never[] | PnlChartLineItem[];
|
|
11228
11441
|
filteredTotalExpenses: number | undefined;
|
|
11229
11442
|
isLoading: boolean;
|
|
11230
11443
|
isValidating: boolean;
|
|
@@ -12065,6 +12278,21 @@ declare module '@layerfi/components/hooks/useReceipts/useReceipts' {
|
|
|
12065
12278
|
export const useReceipts: UseReceipts;
|
|
12066
12279
|
export {};
|
|
12067
12280
|
|
|
12281
|
+
}
|
|
12282
|
+
declare module '@layerfi/components/hooks/useResponsiveColumnVisibility' {
|
|
12283
|
+
import type { VisibilityState } from '@tanstack/react-table';
|
|
12284
|
+
export interface ResponsiveColumnConfig {
|
|
12285
|
+
/** Columns to show on mobile (max-width: 768px) */
|
|
12286
|
+
mobileColumns: string[];
|
|
12287
|
+
/** Columns to show on desktop (min-width: 769px) */
|
|
12288
|
+
desktopColumns: string[];
|
|
12289
|
+
}
|
|
12290
|
+
/**
|
|
12291
|
+
* Hook to manage responsive column visibility for tables
|
|
12292
|
+
* Returns a columnVisibility state object that can be passed to TanStack Table
|
|
12293
|
+
*/
|
|
12294
|
+
export function useResponsiveColumnVisibility(config: ResponsiveColumnConfig): VisibilityState;
|
|
12295
|
+
|
|
12068
12296
|
}
|
|
12069
12297
|
declare module '@layerfi/components/hooks/useStatementOfCashFlow/useStatementOfCashFlow' {
|
|
12070
12298
|
export function useStatementOfCashFlow({ startDate, endDate, }: {
|
|
@@ -12764,8 +12992,9 @@ declare module '@layerfi/components/providers/InvoiceStore/InvoiceStoreProvider'
|
|
|
12764
12992
|
import type { Invoice } from '@layerfi/components/features/invoices/invoiceSchemas';
|
|
12765
12993
|
import { type InvoiceStatusOption } from '@layerfi/components/components/Invoices/InvoiceTable/InvoiceTable';
|
|
12766
12994
|
import type { InvoiceFormMode } from '@layerfi/components/components/Invoices/InvoiceForm/InvoiceForm';
|
|
12767
|
-
type
|
|
12995
|
+
export type InvoiceTableFilters = {
|
|
12768
12996
|
status: InvoiceStatusOption;
|
|
12997
|
+
query: string;
|
|
12769
12998
|
};
|
|
12770
12999
|
export enum InvoiceRoute {
|
|
12771
13000
|
Table = "Table",
|
|
@@ -12780,9 +13009,9 @@ declare module '@layerfi/components/providers/InvoiceStore/InvoiceStoreProvider'
|
|
|
12780
13009
|
type InvoiceRouteState = InvoiceDetailRouteState | InvoiceTableRouteState;
|
|
12781
13010
|
export function useInvoiceRouteState(): InvoiceRouteState;
|
|
12782
13011
|
export function useInvoiceDetail(): InvoiceFormMode;
|
|
12783
|
-
export function
|
|
12784
|
-
|
|
12785
|
-
|
|
13012
|
+
export function useInvoiceTableFilters(): {
|
|
13013
|
+
tableFilters: InvoiceTableFilters;
|
|
13014
|
+
setTableFilters: (patchFilters: Partial<InvoiceTableFilters>) => void;
|
|
12786
13015
|
};
|
|
12787
13016
|
export function useInvoiceNavigation(): {
|
|
12788
13017
|
toCreateInvoice: () => void;
|