@layerfi/components 0.1.128 → 0.1.129-alpha.1
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 +836 -1211
- package/dist/esm/index.mjs +830 -1204
- package/dist/index.css +113 -133
- package/package.json +1 -1
package/dist/cjs/index.cjs
CHANGED
|
@@ -29,7 +29,6 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
29
29
|
enumerable: true
|
|
30
30
|
}) : target, mod));
|
|
31
31
|
let react = require("react");
|
|
32
|
-
react = __toESM(react);
|
|
33
32
|
let zustand = require("zustand");
|
|
34
33
|
let react_jsx_runtime = require("react/jsx-runtime");
|
|
35
34
|
let react_plaid_link = require("react-plaid-link");
|
|
@@ -223,7 +222,7 @@ const getIntlLocale = (locale) => {
|
|
|
223
222
|
return isSupportedLocale(locale) ? locale : DEFAULT_LOCALE;
|
|
224
223
|
};
|
|
225
224
|
const name = "@layerfi/components";
|
|
226
|
-
const version$1 = "0.1.
|
|
225
|
+
const version$1 = "0.1.129-alpha.1";
|
|
227
226
|
const description = "Layer React Components";
|
|
228
227
|
const main = "dist/cjs/index.cjs";
|
|
229
228
|
const module$1 = "dist/esm/index.mjs";
|
|
@@ -394,13 +393,15 @@ var getCustomHeaders = () => ({
|
|
|
394
393
|
"Layer-Locale": _locale,
|
|
395
394
|
"Layer-React-Version": package_default.version
|
|
396
395
|
});
|
|
397
|
-
const get = (url) => (baseUrl, accessToken, options) => () =>
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
396
|
+
const get = (url) => (baseUrl, accessToken, options) => () => {
|
|
397
|
+
return fetch(`${baseUrl}${url((options === null || options === void 0 ? void 0 : options.params) || {})}`, {
|
|
398
|
+
headers: _objectSpread2({
|
|
399
|
+
"Authorization": "Bearer " + (accessToken || ""),
|
|
400
|
+
"Content-Type": "application/json"
|
|
401
|
+
}, getCustomHeaders()),
|
|
402
|
+
method: "GET"
|
|
403
|
+
}).then((res) => handleResponse(res)).catch((error$38) => handleException(error$38));
|
|
404
|
+
};
|
|
404
405
|
const getText = (url) => (baseUrl, accessToken, options) => () => fetch(`${baseUrl}${url((options === null || options === void 0 ? void 0 : options.params) || {})}`, {
|
|
405
406
|
headers: _objectSpread2({ Authorization: "Bearer " + (accessToken || "") }, getCustomHeaders()),
|
|
406
407
|
method: "GET"
|
|
@@ -1193,6 +1194,7 @@ const label$44 = {
|
|
|
1193
1194
|
"equities": "Equities",
|
|
1194
1195
|
"expenses": "Expenses",
|
|
1195
1196
|
"gross_profit": "Gross Profit",
|
|
1197
|
+
"hide_details": "Hide details",
|
|
1196
1198
|
"id": "Id",
|
|
1197
1199
|
"keep_editing": "Keep editing",
|
|
1198
1200
|
"liabilities": "Liabilities",
|
|
@@ -1219,6 +1221,7 @@ const label$44 = {
|
|
|
1219
1221
|
"row": "Row",
|
|
1220
1222
|
"savings": "Savings",
|
|
1221
1223
|
"select_all": "Select all",
|
|
1224
|
+
"show_details": "Show details",
|
|
1222
1225
|
"source": "Source",
|
|
1223
1226
|
"status": "Status",
|
|
1224
1227
|
"tax_estimates": "Tax estimates",
|
|
@@ -1863,6 +1866,8 @@ const disclaimer$1 = {
|
|
|
1863
1866
|
"content": "The Tax Estimates tool and related content are for informational purposes only, and are not intended as legal, accounting, or tax advice, or a substitute for professional counsel. We are not a financial planner or tax advisor, and users assume sole responsibility for their tax obligations, accuracy of data, and compliance with laws. All calculations are estimated and may contain errors, and are based only on the information you provide to us."
|
|
1864
1867
|
};
|
|
1865
1868
|
const empty$20 = {
|
|
1869
|
+
"no_tax_details": "No tax details",
|
|
1870
|
+
"no_tax_details_description": "No tax details found",
|
|
1866
1871
|
"no_tax_payments_to_display": "There are no tax payments to display.",
|
|
1867
1872
|
"tax_payments": "No tax payments found"
|
|
1868
1873
|
};
|
|
@@ -1870,11 +1875,13 @@ const error$24 = {
|
|
|
1870
1875
|
"disclaimer_required": "You must acknowledge the disclaimer to continue.",
|
|
1871
1876
|
"feature_not_enabled": "Tax estimates are not enabled.",
|
|
1872
1877
|
"load_tax_deadlines": "We couldn't load your tax deadlines",
|
|
1878
|
+
"load_tax_details": "We couldn't load your tax details",
|
|
1873
1879
|
"load_tax_estimates": "We couldn't load your tax estimates",
|
|
1874
1880
|
"load_tax_estimates_summary": "We couldn't load your tax summary",
|
|
1875
1881
|
"load_tax_information": "Unable to load tax information",
|
|
1876
1882
|
"load_tax_payments": "We couldnʼt load your tax payments",
|
|
1877
1883
|
"retrieve_tax_profile": "We couldn’t retrieve your tax profile. Please check your connection and try again.",
|
|
1884
|
+
"while_loading_tax_details": "An error occurred while loading your tax details. Please check your connection and try again.",
|
|
1878
1885
|
"while_loading_tax_estimates": "An error occurred while loading your tax estimates. Please check your connection and try again.",
|
|
1879
1886
|
"while_loading_tax_payments": "An error occurred while loading your tax payments. Please check your connection and try again.",
|
|
1880
1887
|
"while_loading_tax_summary": "An error occurred while loading your tax summary. Please check your connection and try again."
|
|
@@ -1954,6 +1961,9 @@ const label$31 = {
|
|
|
1954
1961
|
"tax_information": "State Tax Information",
|
|
1955
1962
|
"tax_name_estimate_owed": "{{taxName}} Estimate (Owed)",
|
|
1956
1963
|
"tax_name_rate": "{{taxName}} Rate",
|
|
1964
|
+
"tax_details": "Tax Details",
|
|
1965
|
+
"tax_details_amount": "Amount",
|
|
1966
|
+
"tax_details_label": "Label",
|
|
1957
1967
|
"tax_payments": "Tax Payments",
|
|
1958
1968
|
"tax_payments_projected": "Projected Tax Payments",
|
|
1959
1969
|
"tax_profile": "Tax Profile",
|
|
@@ -1973,10 +1983,12 @@ const label$31 = {
|
|
|
1973
1983
|
"taxes_by_state_name": "State Taxes ({{stateName}})",
|
|
1974
1984
|
"taxes_by_state_name_projected": "Projected State Taxes ({{stateName}})",
|
|
1975
1985
|
"taxes_due": "Taxes Due",
|
|
1986
|
+
"taxes_due_at": "Taxes due on {{date}}",
|
|
1976
1987
|
"taxes_owed": "Taxes Owed",
|
|
1977
1988
|
"taxes_owed_projected": "Projected Taxes Owed",
|
|
1978
1989
|
"taxes_paid": "Taxes Paid",
|
|
1979
1990
|
"tip_income": "Tip income",
|
|
1991
|
+
"total_deductions": "Total Deductions",
|
|
1980
1992
|
"total_federal_tax_estimate": "Total Federal Tax Estimate",
|
|
1981
1993
|
"total_paid": "Total Paid",
|
|
1982
1994
|
"total_state_tax_estimate": "Total State Tax Estimate",
|
|
@@ -2786,6 +2798,7 @@ const label$19 = {
|
|
|
2786
2798
|
"equities": "Capitaux propres",
|
|
2787
2799
|
"expenses": "Dépenses",
|
|
2788
2800
|
"gross_profit": "Bénéfice brut",
|
|
2801
|
+
"hide_details": "",
|
|
2789
2802
|
"id": "ID",
|
|
2790
2803
|
"keep_editing": "Continuer à modifier",
|
|
2791
2804
|
"liabilities": "Passifs",
|
|
@@ -2812,6 +2825,7 @@ const label$19 = {
|
|
|
2812
2825
|
"row": "Ligne",
|
|
2813
2826
|
"savings": "Compte d’épargne",
|
|
2814
2827
|
"select_all": "Tout sélectionner",
|
|
2828
|
+
"show_details": "",
|
|
2815
2829
|
"source": "Source",
|
|
2816
2830
|
"status": "Statut",
|
|
2817
2831
|
"tax_estimates": "Estimations fiscales",
|
|
@@ -3456,6 +3470,8 @@ const disclaimer = {
|
|
|
3456
3470
|
"content": "L’outil d’estimation des impôts et le contenu connexe sont fournis à titre informatif seulement et ne constituent pas des conseils juridiques, comptables ou fiscaux, ni un substitut à l’avis d’un professionnel. Nous ne sommes pas un planificateur financier ni un conseiller fiscal, et les utilisateurs assument l’entière responsabilité de leurs obligations fiscales, de l’exactitude des données et du respect des lois. Tous les calculs sont des estimations et peuvent contenir des erreurs. Ils reposent uniquement sur les renseignements que vous nous fournissez."
|
|
3457
3471
|
};
|
|
3458
3472
|
const empty$4 = {
|
|
3473
|
+
"no_tax_details": "",
|
|
3474
|
+
"no_tax_details_description": "",
|
|
3459
3475
|
"no_tax_payments_to_display": "Il n’y a aucun paiement d’impôt à afficher.",
|
|
3460
3476
|
"tax_payments": "Aucun paiement d’impôt trouvé"
|
|
3461
3477
|
};
|
|
@@ -3463,11 +3479,13 @@ const error$5 = {
|
|
|
3463
3479
|
"disclaimer_required": "Vous devez reconnaître l’avis de non-responsabilité pour continuer.",
|
|
3464
3480
|
"feature_not_enabled": "Les estimations d'impôt ne sont pas activées.",
|
|
3465
3481
|
"load_tax_deadlines": "Impossible de charger vos échéances fiscales",
|
|
3482
|
+
"load_tax_details": "",
|
|
3466
3483
|
"load_tax_estimates": "Nous n’avons pas pu charger vos estimations fiscales",
|
|
3467
3484
|
"load_tax_estimates_summary": "Nous n’avons pas pu charger votre sommaire fiscal",
|
|
3468
3485
|
"load_tax_information": "Impossible de charger les renseignements fiscaux",
|
|
3469
3486
|
"load_tax_payments": "Nous n’avons pas pu charger vos paiements d’impôt",
|
|
3470
3487
|
"retrieve_tax_profile": "Nous n’avons pas pu récupérer votre profil fiscal. Veuillez vérifier votre connexion et réessayer.",
|
|
3488
|
+
"while_loading_tax_details": "",
|
|
3471
3489
|
"while_loading_tax_estimates": "Une erreur s’est produite lors du chargement de vos estimations d’impôt. Veuillez vérifier votre connexion et réessayer.",
|
|
3472
3490
|
"while_loading_tax_payments": "Une erreur s’est produite lors du chargement de vos paiements d’impôt. Veuillez vérifier votre connexion et réessayer.",
|
|
3473
3491
|
"while_loading_tax_summary": "Une erreur s’est produite lors du chargement de votre sommaire fiscal. Veuillez vérifier votre connexion et réessayer."
|
|
@@ -3547,6 +3565,9 @@ const label$6 = {
|
|
|
3547
3565
|
"tax_information": "Renseignements sur l'impôt d'État",
|
|
3548
3566
|
"tax_name_estimate_owed": "Estimation de {{taxName}} (à payer)",
|
|
3549
3567
|
"tax_name_rate": "Taux de {{taxName}}",
|
|
3568
|
+
"tax_details": "",
|
|
3569
|
+
"tax_details_amount": "",
|
|
3570
|
+
"tax_details_label": "",
|
|
3550
3571
|
"tax_payments": "Paiements d’impôt",
|
|
3551
3572
|
"tax_payments_projected": "Paiements d’impôt projetés",
|
|
3552
3573
|
"tax_profile": "Profil fiscal",
|
|
@@ -3566,10 +3587,12 @@ const label$6 = {
|
|
|
3566
3587
|
"taxes_by_state_name": "Impôts d’État ({{stateName}})",
|
|
3567
3588
|
"taxes_by_state_name_projected": "Impôts d’État projetés ({{stateName}})",
|
|
3568
3589
|
"taxes_due": "Impôts à payer",
|
|
3590
|
+
"taxes_due_at": "",
|
|
3569
3591
|
"taxes_owed": "Impôts dus",
|
|
3570
3592
|
"taxes_owed_projected": "Impôts dus projetés",
|
|
3571
3593
|
"taxes_paid": "Impôts payés",
|
|
3572
3594
|
"tip_income": "Revenu de pourboires",
|
|
3595
|
+
"total_deductions": "",
|
|
3573
3596
|
"total_federal_tax_estimate": "Estimation totale de l’impôt fédéral",
|
|
3574
3597
|
"total_paid": "Total payé",
|
|
3575
3598
|
"total_state_tax_estimate": "Estimation totale de l’impôt d’État",
|
|
@@ -4029,11 +4052,11 @@ function _objectWithoutProperties(e, t) {
|
|
|
4029
4052
|
}
|
|
4030
4053
|
return i;
|
|
4031
4054
|
}
|
|
4032
|
-
var _excluded$
|
|
4055
|
+
var _excluded$118 = ["_locale"];
|
|
4033
4056
|
var createLocalizedFetcher = (fetcher) => {
|
|
4034
4057
|
if (!fetcher) return null;
|
|
4035
4058
|
return (_ref, ...rest) => {
|
|
4036
|
-
let { _locale: _locale$1 } = _ref, key = _objectWithoutProperties(_ref, _excluded$
|
|
4059
|
+
let { _locale: _locale$1 } = _ref, key = _objectWithoutProperties(_ref, _excluded$118);
|
|
4037
4060
|
setLocaleHeader(_locale$1);
|
|
4038
4061
|
return fetcher(key, ...rest);
|
|
4039
4062
|
};
|
|
@@ -4048,7 +4071,7 @@ const useLocalizedKey = () => {
|
|
|
4048
4071
|
return _objectSpread2(_objectSpread2({}, key), {}, { _locale: locale });
|
|
4049
4072
|
};
|
|
4050
4073
|
};
|
|
4051
|
-
var _excluded$
|
|
4074
|
+
var _excluded$117 = ["trigger"];
|
|
4052
4075
|
var UNLINK_BANK_ACCOUNT_TAG_KEY = "#unlink-bank-account";
|
|
4053
4076
|
var unlinkBankAccount = del(({ businessId, bankAccountId }) => `/v1/businesses/${businessId}/bank-accounts/${bankAccountId}`);
|
|
4054
4077
|
function buildKey$88({ access_token: accessToken, apiUrl, businessId }) {
|
|
@@ -4071,7 +4094,7 @@ function useUnlinkBankAccount() {
|
|
|
4071
4094
|
})), ({ accessToken, apiUrl: apiUrl$1, businessId: businessId$1 }, { arg: bankAccountId }) => unlinkBankAccount(apiUrl$1, accessToken, { params: {
|
|
4072
4095
|
businessId: businessId$1,
|
|
4073
4096
|
bankAccountId
|
|
4074
|
-
} }), { revalidate: false }), { trigger: rawTrigger } = _useSWRMutation, rest = _objectWithoutProperties(_useSWRMutation, _excluded$
|
|
4097
|
+
} }), { revalidate: false }), { trigger: rawTrigger } = _useSWRMutation, rest = _objectWithoutProperties(_useSWRMutation, _excluded$117);
|
|
4075
4098
|
const triggerRef = (0, react.useRef)(rawTrigger);
|
|
4076
4099
|
triggerRef.current = rawTrigger;
|
|
4077
4100
|
return _objectSpread2({ trigger: (0, react.useCallback)((bankAccountId) => triggerRef.current(bankAccountId), []) }, rest);
|
|
@@ -7430,14 +7453,14 @@ const useBankTransactionsFilters = ({ scope, monthlyView, applyGlobalDateRange,
|
|
|
7430
7453
|
dateFilterMode
|
|
7431
7454
|
]);
|
|
7432
7455
|
};
|
|
7433
|
-
var _excluded$
|
|
7456
|
+
var _excluded$116 = ["size"];
|
|
7434
7457
|
var Bell = (_ref) => {
|
|
7435
7458
|
let { size = 18 } = _ref;
|
|
7436
7459
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
7437
7460
|
xmlns: "http://www.w3.org/2000/svg",
|
|
7438
7461
|
viewBox: "0 0 18 18",
|
|
7439
7462
|
fill: "none"
|
|
7440
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
7463
|
+
}, _objectWithoutProperties(_ref, _excluded$116)), {}, {
|
|
7441
7464
|
width: size,
|
|
7442
7465
|
height: size,
|
|
7443
7466
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
@@ -7454,14 +7477,14 @@ var Bell = (_ref) => {
|
|
|
7454
7477
|
}));
|
|
7455
7478
|
};
|
|
7456
7479
|
var Bell_default = Bell;
|
|
7457
|
-
var _excluded$
|
|
7480
|
+
var _excluded$115 = ["size"];
|
|
7458
7481
|
var CreditCard = (_ref) => {
|
|
7459
7482
|
let { size = 12 } = _ref;
|
|
7460
7483
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
7461
7484
|
xmlns: "http://www.w3.org/2000/svg",
|
|
7462
7485
|
viewBox: "0 0 12 12",
|
|
7463
7486
|
fill: "none"
|
|
7464
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
7487
|
+
}, _objectWithoutProperties(_ref, _excluded$115)), {}, {
|
|
7465
7488
|
width: size,
|
|
7466
7489
|
height: size,
|
|
7467
7490
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
@@ -7478,14 +7501,14 @@ var CreditCard = (_ref) => {
|
|
|
7478
7501
|
}));
|
|
7479
7502
|
};
|
|
7480
7503
|
var CreditCard_default = CreditCard;
|
|
7481
|
-
var _excluded$
|
|
7504
|
+
var _excluded$114 = ["size"];
|
|
7482
7505
|
var Folder = (_ref) => {
|
|
7483
7506
|
let { size = 12 } = _ref;
|
|
7484
7507
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("svg", _objectSpread2(_objectSpread2({
|
|
7485
7508
|
xmlns: "http://www.w3.org/2000/svg",
|
|
7486
7509
|
viewBox: "0 0 12 12",
|
|
7487
7510
|
fill: "none"
|
|
7488
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
7511
|
+
}, _objectWithoutProperties(_ref, _excluded$114)), {}, {
|
|
7489
7512
|
width: size,
|
|
7490
7513
|
height: size,
|
|
7491
7514
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
@@ -7497,14 +7520,14 @@ var Folder = (_ref) => {
|
|
|
7497
7520
|
}));
|
|
7498
7521
|
};
|
|
7499
7522
|
var Folder_default = Folder;
|
|
7500
|
-
var _excluded$
|
|
7523
|
+
var _excluded$113 = ["size"];
|
|
7501
7524
|
var Link$2 = (_ref) => {
|
|
7502
7525
|
let { size = 18 } = _ref;
|
|
7503
7526
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
7504
7527
|
xmlns: "http://www.w3.org/2000/svg",
|
|
7505
7528
|
viewBox: "0 0 18 18",
|
|
7506
7529
|
fill: "none"
|
|
7507
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
7530
|
+
}, _objectWithoutProperties(_ref, _excluded$113)), {}, {
|
|
7508
7531
|
width: size,
|
|
7509
7532
|
height: size,
|
|
7510
7533
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
@@ -7528,14 +7551,14 @@ var PlaidIcon = () => {
|
|
|
7528
7551
|
});
|
|
7529
7552
|
};
|
|
7530
7553
|
var PlaidIcon_default = PlaidIcon;
|
|
7531
|
-
var _excluded$
|
|
7554
|
+
var _excluded$112 = ["size"];
|
|
7532
7555
|
var Sunrise = (_ref) => {
|
|
7533
7556
|
let { size = 12 } = _ref;
|
|
7534
7557
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
7535
7558
|
xmlns: "http://www.w3.org/2000/svg",
|
|
7536
7559
|
viewBox: "0 0 12 12",
|
|
7537
7560
|
fill: "none"
|
|
7538
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
7561
|
+
}, _objectWithoutProperties(_ref, _excluded$112)), {}, {
|
|
7539
7562
|
width: size,
|
|
7540
7563
|
height: size,
|
|
7541
7564
|
children: [
|
|
@@ -7612,7 +7635,7 @@ var ChevronRight$2 = (_ref) => {
|
|
|
7612
7635
|
}) }));
|
|
7613
7636
|
};
|
|
7614
7637
|
var ChevronRight_default = ChevronRight$2;
|
|
7615
|
-
var _excluded$
|
|
7638
|
+
var _excluded$111 = [
|
|
7616
7639
|
"className",
|
|
7617
7640
|
"children",
|
|
7618
7641
|
"icon",
|
|
@@ -7624,7 +7647,7 @@ var _excluded$110 = [
|
|
|
7624
7647
|
"download"
|
|
7625
7648
|
];
|
|
7626
7649
|
const IconButton = (_ref) => {
|
|
7627
|
-
let { className, children: _children, icon, active, withBorder = false, href, target, rel, download } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
7650
|
+
let { className, children: _children, icon, active, withBorder = false, href, target, rel, download } = _ref, props = _objectWithoutProperties(_ref, _excluded$111);
|
|
7628
7651
|
const baseClassName$1 = (0, classnames.default)("Layer__icon-btn", `Layer__icon-btn--${active ? "active" : "inactive"}`, withBorder && "Layer__icon-btn--border", className);
|
|
7629
7652
|
if (href) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("a", {
|
|
7630
7653
|
href,
|
|
@@ -7708,10 +7731,10 @@ const useTooltip = ({ initialOpen = false, placement = "top", open: controlledOp
|
|
|
7708
7731
|
data
|
|
7709
7732
|
]);
|
|
7710
7733
|
};
|
|
7711
|
-
var _excluded$
|
|
7734
|
+
var _excluded$110 = ["children"], _excluded2$15 = ["children", "asChild"], _excluded3$6 = ["className", "width"];
|
|
7712
7735
|
const DeprecatedTooltip = (_ref) => {
|
|
7713
7736
|
let { children } = _ref;
|
|
7714
|
-
const tooltip = useTooltip(_objectWithoutProperties(_ref, _excluded$
|
|
7737
|
+
const tooltip = useTooltip(_objectWithoutProperties(_ref, _excluded$110));
|
|
7715
7738
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TooltipContext.Provider, {
|
|
7716
7739
|
value: tooltip,
|
|
7717
7740
|
children
|
|
@@ -7749,7 +7772,7 @@ const DeprecatedTooltipContent = (0, react.forwardRef)(function TooltipContent$1
|
|
|
7749
7772
|
children: props.children
|
|
7750
7773
|
}) })) });
|
|
7751
7774
|
});
|
|
7752
|
-
var _excluded$
|
|
7775
|
+
var _excluded$109 = [
|
|
7753
7776
|
"as",
|
|
7754
7777
|
"className",
|
|
7755
7778
|
"children",
|
|
@@ -7786,7 +7809,7 @@ let TextUseTooltip = /* @__PURE__ */ function(TextUseTooltip$1) {
|
|
|
7786
7809
|
return TextUseTooltip$1;
|
|
7787
7810
|
}({});
|
|
7788
7811
|
const Text = (_ref) => {
|
|
7789
|
-
let { as: Component$1 = "p", className, children, size = TextSize.md, weight = TextWeight.normal, withDeprecatedTooltip: withTooltip, ellipsis, status, pb, invertColor } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
7812
|
+
let { as: Component$1 = "p", className, children, size = TextSize.md, weight = TextWeight.normal, withDeprecatedTooltip: withTooltip, ellipsis, status, pb, invertColor } = _ref, props = _objectWithoutProperties(_ref, _excluded$109);
|
|
7790
7813
|
const dataProperties = toDataProperties({
|
|
7791
7814
|
status,
|
|
7792
7815
|
ellipsis,
|
|
@@ -7909,14 +7932,14 @@ const Badge = ({ icon, onClick, children, tooltip, size = BadgeSize.MEDIUM, vari
|
|
|
7909
7932
|
});
|
|
7910
7933
|
return content;
|
|
7911
7934
|
};
|
|
7912
|
-
var _excluded$
|
|
7935
|
+
var _excluded$108 = ["size"];
|
|
7913
7936
|
var Loader$1 = (_ref) => {
|
|
7914
7937
|
let { size = 18 } = _ref;
|
|
7915
7938
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
7916
7939
|
xmlns: "http://www.w3.org/2000/svg",
|
|
7917
7940
|
viewBox: "0 0 18 18",
|
|
7918
7941
|
fill: "none"
|
|
7919
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
7942
|
+
}, _objectWithoutProperties(_ref, _excluded$108)), {}, {
|
|
7920
7943
|
width: size,
|
|
7921
7944
|
height: size,
|
|
7922
7945
|
children: [
|
|
@@ -7972,7 +7995,7 @@ var Loader$1 = (_ref) => {
|
|
|
7972
7995
|
}));
|
|
7973
7996
|
};
|
|
7974
7997
|
var Loader_default = Loader$1;
|
|
7975
|
-
var _excluded$
|
|
7998
|
+
var _excluded$107 = [
|
|
7976
7999
|
"className",
|
|
7977
8000
|
"children",
|
|
7978
8001
|
"variant",
|
|
@@ -7992,7 +8015,7 @@ let ButtonVariant = /* @__PURE__ */ function(ButtonVariant$1) {
|
|
|
7992
8015
|
return ButtonVariant$1;
|
|
7993
8016
|
}({});
|
|
7994
8017
|
const Button$1 = (_ref) => {
|
|
7995
|
-
let { className, children, variant = ButtonVariant.primary, leftIcon, rightIcon, iconOnly, iconAsPrimary = false, justify = "center", fullWidth, isProcessing, tooltip } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
8018
|
+
let { className, children, variant = ButtonVariant.primary, leftIcon, rightIcon, iconOnly, iconAsPrimary = false, justify = "center", fullWidth, isProcessing, tooltip } = _ref, props = _objectWithoutProperties(_ref, _excluded$107);
|
|
7996
8019
|
const buttonRef = (0, react.useRef)(null);
|
|
7997
8020
|
let justifyContent = "center";
|
|
7998
8021
|
if (justify) justifyContent = justify;
|
|
@@ -8039,14 +8062,14 @@ const Button$1 = (_ref) => {
|
|
|
8039
8062
|
}) : content
|
|
8040
8063
|
}));
|
|
8041
8064
|
};
|
|
8042
|
-
var _excluded$
|
|
8065
|
+
var _excluded$106 = ["size"];
|
|
8043
8066
|
var AlertOctagon = (_ref) => {
|
|
8044
8067
|
let { size = 18 } = _ref;
|
|
8045
8068
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
8046
8069
|
viewBox: "0 0 18 18",
|
|
8047
8070
|
fill: "none",
|
|
8048
8071
|
xmlns: "http://www.w3.org/2000/svg"
|
|
8049
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
8072
|
+
}, _objectWithoutProperties(_ref, _excluded$106)), {}, {
|
|
8050
8073
|
width: size,
|
|
8051
8074
|
height: size,
|
|
8052
8075
|
children: [
|
|
@@ -8072,14 +8095,14 @@ var AlertOctagon = (_ref) => {
|
|
|
8072
8095
|
}));
|
|
8073
8096
|
};
|
|
8074
8097
|
var AlertOctagon_default = AlertOctagon;
|
|
8075
|
-
var _excluded$
|
|
8098
|
+
var _excluded$105 = ["size"];
|
|
8076
8099
|
var CheckCircle$2 = (_ref) => {
|
|
8077
8100
|
let { size = 18 } = _ref;
|
|
8078
8101
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
8079
8102
|
viewBox: "0 0 18 18",
|
|
8080
8103
|
fill: "none",
|
|
8081
8104
|
xmlns: "http://www.w3.org/2000/svg"
|
|
8082
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
8105
|
+
}, _objectWithoutProperties(_ref, _excluded$105)), {}, {
|
|
8083
8106
|
width: size,
|
|
8084
8107
|
height: size,
|
|
8085
8108
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
@@ -8096,14 +8119,14 @@ var CheckCircle$2 = (_ref) => {
|
|
|
8096
8119
|
}));
|
|
8097
8120
|
};
|
|
8098
8121
|
var CheckCircle_default = CheckCircle$2;
|
|
8099
|
-
var _excluded$
|
|
8122
|
+
var _excluded$104 = ["size"];
|
|
8100
8123
|
var RefreshCcw$1 = (_ref) => {
|
|
8101
8124
|
let { size = 18 } = _ref;
|
|
8102
8125
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
8103
8126
|
viewBox: "0 0 18 18",
|
|
8104
8127
|
fill: "none",
|
|
8105
8128
|
xmlns: "http://www.w3.org/2000/svg"
|
|
8106
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
8129
|
+
}, _objectWithoutProperties(_ref, _excluded$104)), {}, {
|
|
8107
8130
|
width: size,
|
|
8108
8131
|
height: size,
|
|
8109
8132
|
children: [
|
|
@@ -8691,7 +8714,7 @@ function BulkSelectionStoreProvider({ children }) {
|
|
|
8691
8714
|
children
|
|
8692
8715
|
});
|
|
8693
8716
|
}
|
|
8694
|
-
var _excluded$
|
|
8717
|
+
var _excluded$103 = [
|
|
8695
8718
|
"align",
|
|
8696
8719
|
"children",
|
|
8697
8720
|
"className",
|
|
@@ -8709,7 +8732,7 @@ var _excluded$102 = [
|
|
|
8709
8732
|
];
|
|
8710
8733
|
var CLASS_NAME$11 = "Layer__Stack";
|
|
8711
8734
|
const Stack = (0, react.forwardRef)(function Stack$2(_ref, ref) {
|
|
8712
|
-
let { align, children, className, direction, gap, justify, overflow, pb, pbs, pbe, pi, pis, pie, fluid } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
8735
|
+
let { align, children, className, direction, gap, justify, overflow, pb, pbs, pbe, pi, pis, pie, fluid } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$103);
|
|
8713
8736
|
const dataProperties = toDataProperties({
|
|
8714
8737
|
align,
|
|
8715
8738
|
direction,
|
|
@@ -9020,7 +9043,7 @@ function useSizeClass() {
|
|
|
9020
9043
|
isDesktop: sizeClass === "desktop"
|
|
9021
9044
|
};
|
|
9022
9045
|
}
|
|
9023
|
-
var _excluded$
|
|
9046
|
+
var _excluded$102 = ["children"], _excluded2$13 = [
|
|
9024
9047
|
"children",
|
|
9025
9048
|
"asChild",
|
|
9026
9049
|
"wordBreak"
|
|
@@ -9031,7 +9054,7 @@ var _excluded$101 = ["children"], _excluded2$13 = [
|
|
|
9031
9054
|
];
|
|
9032
9055
|
const Tooltip = (_ref) => {
|
|
9033
9056
|
let { children } = _ref;
|
|
9034
|
-
const tooltip = useTooltip(_objectWithoutProperties(_ref, _excluded$
|
|
9057
|
+
const tooltip = useTooltip(_objectWithoutProperties(_ref, _excluded$102));
|
|
9035
9058
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TooltipContext.Provider, {
|
|
9036
9059
|
value: tooltip,
|
|
9037
9060
|
children
|
|
@@ -9126,7 +9149,7 @@ function useTruncationDetection(elementRef, options = {
|
|
|
9126
9149
|
}, [checkTruncation]);
|
|
9127
9150
|
return isTruncated;
|
|
9128
9151
|
}
|
|
9129
|
-
var _excluded$
|
|
9152
|
+
var _excluded$101 = [
|
|
9130
9153
|
"align",
|
|
9131
9154
|
"children",
|
|
9132
9155
|
"ellipsis",
|
|
@@ -9141,7 +9164,7 @@ var _excluded$100 = [
|
|
|
9141
9164
|
"weight"
|
|
9142
9165
|
];
|
|
9143
9166
|
function splitTextProps(props) {
|
|
9144
|
-
const { align, children, ellipsis, nonAria, noWrap, pb, pbe, pbs, size, status, variant, weight } = props, restProps = _objectWithoutProperties(props, _excluded$
|
|
9167
|
+
const { align, children, ellipsis, nonAria, noWrap, pb, pbe, pbs, size, status, variant, weight } = props, restProps = _objectWithoutProperties(props, _excluded$101);
|
|
9145
9168
|
return {
|
|
9146
9169
|
children,
|
|
9147
9170
|
dataProperties: toDataProperties({
|
|
@@ -9303,7 +9326,7 @@ function withRenderProp(renderProp, callback) {
|
|
|
9303
9326
|
if (typeof renderProp === "function") return renderProp;
|
|
9304
9327
|
return callback(renderProp);
|
|
9305
9328
|
}
|
|
9306
|
-
var _excluded$
|
|
9329
|
+
var _excluded$100 = [
|
|
9307
9330
|
"children",
|
|
9308
9331
|
"ellipsis",
|
|
9309
9332
|
"icon",
|
|
@@ -9331,7 +9354,7 @@ function ButtonTransparentContent({ children }) {
|
|
|
9331
9354
|
});
|
|
9332
9355
|
}
|
|
9333
9356
|
var Button = (0, react.forwardRef)((_ref, ref) => {
|
|
9334
|
-
let { children, ellipsis, icon, inset, size = "md", variant = "solid", fullWidth = false, flex = false } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
9357
|
+
let { children, ellipsis, icon, inset, size = "md", variant = "solid", fullWidth = false, flex = false } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$100);
|
|
9335
9358
|
const { isPending = false } = restProps;
|
|
9336
9359
|
const dataProperties = toDataProperties({
|
|
9337
9360
|
ellipsis,
|
|
@@ -9352,10 +9375,10 @@ var Button = (0, react.forwardRef)((_ref, ref) => {
|
|
|
9352
9375
|
}));
|
|
9353
9376
|
});
|
|
9354
9377
|
Button.displayName = "Button";
|
|
9355
|
-
var _excluded$
|
|
9378
|
+
var _excluded$99 = ["one", "other"];
|
|
9356
9379
|
const tPlural = (translate, key, _ref) => {
|
|
9357
9380
|
let { one, other } = _ref;
|
|
9358
|
-
return translate(key, _objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$
|
|
9381
|
+
return translate(key, _objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$99)), {}, {
|
|
9359
9382
|
defaultValue_one: one,
|
|
9360
9383
|
defaultValue_other: other
|
|
9361
9384
|
}));
|
|
@@ -10546,7 +10569,7 @@ const useVirtualKeyboardHeight = () => {
|
|
|
10546
10569
|
}, []);
|
|
10547
10570
|
return keyboardHeight;
|
|
10548
10571
|
};
|
|
10549
|
-
var _excluded$
|
|
10572
|
+
var _excluded$98 = ["variant"], _excluded2$12 = [
|
|
10550
10573
|
"variant",
|
|
10551
10574
|
"children",
|
|
10552
10575
|
"slots",
|
|
@@ -10556,7 +10579,7 @@ var _excluded$97 = ["variant"], _excluded2$12 = [
|
|
|
10556
10579
|
];
|
|
10557
10580
|
var MODAL_OVERLAY_CLASS_NAME = `Layer__Portal Layer__ModalOverlay`;
|
|
10558
10581
|
var ModalOverlay = (0, react.forwardRef)((_ref, ref) => {
|
|
10559
|
-
let { variant } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
10582
|
+
let { variant } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$98);
|
|
10560
10583
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.ModalOverlay, _objectSpread2(_objectSpread2(_objectSpread2({}, toDataProperties({ variant })), restProps), {}, {
|
|
10561
10584
|
className: MODAL_OVERLAY_CLASS_NAME,
|
|
10562
10585
|
ref
|
|
@@ -10658,7 +10681,7 @@ function Drawer({ isOpen, onOpenChange, size = "md", flexBlock, flexInline, chil
|
|
|
10658
10681
|
})
|
|
10659
10682
|
});
|
|
10660
10683
|
}
|
|
10661
|
-
var _excluded$
|
|
10684
|
+
var _excluded$97 = [
|
|
10662
10685
|
"align",
|
|
10663
10686
|
"pie",
|
|
10664
10687
|
"pbe",
|
|
@@ -10670,7 +10693,7 @@ var _excluded$96 = [
|
|
|
10670
10693
|
];
|
|
10671
10694
|
var HEADING_CLASS_NAME = "Layer__UI__Heading";
|
|
10672
10695
|
var Heading = (0, react.forwardRef)((_ref, ref) => {
|
|
10673
|
-
let { align, pie, pbe, size, variant, weight, ellipsis, className } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
10696
|
+
let { align, pie, pbe, size, variant, weight, ellipsis, className } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$97);
|
|
10674
10697
|
const dataProperties = toDataProperties({
|
|
10675
10698
|
pbe,
|
|
10676
10699
|
pie,
|
|
@@ -10754,14 +10777,14 @@ function ModalActions({ children }) {
|
|
|
10754
10777
|
children
|
|
10755
10778
|
});
|
|
10756
10779
|
}
|
|
10757
|
-
var _excluded$
|
|
10780
|
+
var _excluded$96 = ["size"];
|
|
10758
10781
|
var AlertCircle$1 = (_ref) => {
|
|
10759
10782
|
let { size = 18 } = _ref;
|
|
10760
10783
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
10761
10784
|
viewBox: "0 0 18 18",
|
|
10762
10785
|
fill: "none",
|
|
10763
10786
|
xmlns: "http://www.w3.org/2000/svg"
|
|
10764
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
10787
|
+
}, _objectWithoutProperties(_ref, _excluded$96)), {}, {
|
|
10765
10788
|
width: size,
|
|
10766
10789
|
height: size,
|
|
10767
10790
|
children: [
|
|
@@ -10787,14 +10810,14 @@ var AlertCircle$1 = (_ref) => {
|
|
|
10787
10810
|
}));
|
|
10788
10811
|
};
|
|
10789
10812
|
var AlertCircle_default = AlertCircle$1;
|
|
10790
|
-
var _excluded$
|
|
10813
|
+
var _excluded$95 = ["size"];
|
|
10791
10814
|
var Save$6 = (_ref) => {
|
|
10792
10815
|
let { size = 18 } = _ref;
|
|
10793
10816
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
10794
10817
|
xmlns: "http://www.w3.org/2000/svg",
|
|
10795
10818
|
viewBox: "0 0 18 18",
|
|
10796
10819
|
fill: "none"
|
|
10797
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
10820
|
+
}, _objectWithoutProperties(_ref, _excluded$95)), {}, {
|
|
10798
10821
|
width: size,
|
|
10799
10822
|
height: size,
|
|
10800
10823
|
children: [
|
|
@@ -10820,7 +10843,7 @@ var Save$6 = (_ref) => {
|
|
|
10820
10843
|
}));
|
|
10821
10844
|
};
|
|
10822
10845
|
var Save_default = Save$6;
|
|
10823
|
-
var _excluded$
|
|
10846
|
+
var _excluded$94 = [
|
|
10824
10847
|
"className",
|
|
10825
10848
|
"processing",
|
|
10826
10849
|
"disabled",
|
|
@@ -10828,7 +10851,7 @@ var _excluded$93 = [
|
|
|
10828
10851
|
"children"
|
|
10829
10852
|
];
|
|
10830
10853
|
const RetryButton = (_ref) => {
|
|
10831
|
-
let { className, processing, disabled, error: error$38, children } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
10854
|
+
let { className, processing, disabled, error: error$38, children } = _ref, props = _objectWithoutProperties(_ref, _excluded$94);
|
|
10832
10855
|
const baseClassName$1 = (0, classnames.default)("Layer__retry-btn", processing ? "Layer__btn--processing" : "", className);
|
|
10833
10856
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button$1, _objectSpread2(_objectSpread2({}, props), {}, {
|
|
10834
10857
|
className: baseClassName$1,
|
|
@@ -10840,7 +10863,7 @@ const RetryButton = (_ref) => {
|
|
|
10840
10863
|
children
|
|
10841
10864
|
}));
|
|
10842
10865
|
};
|
|
10843
|
-
var _excluded$
|
|
10866
|
+
var _excluded$93 = [
|
|
10844
10867
|
"active",
|
|
10845
10868
|
"className",
|
|
10846
10869
|
"processing",
|
|
@@ -10877,7 +10900,7 @@ var buildRightIcon = ({ processing, error: error$38, action: action$44, noIcon }
|
|
|
10877
10900
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Save_default, { size: 16 });
|
|
10878
10901
|
};
|
|
10879
10902
|
const SubmitButton = (_ref) => {
|
|
10880
|
-
let { active, className, processing, disabled, error: error$38, children, action: action$44 = SubmitAction.SAVE, noIcon, variant = ButtonVariant.primary, withRetry, iconAsPrimary = true } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
10903
|
+
let { active, className, processing, disabled, error: error$38, children, action: action$44 = SubmitAction.SAVE, noIcon, variant = ButtonVariant.primary, withRetry, iconAsPrimary = true } = _ref, props = _objectWithoutProperties(_ref, _excluded$93);
|
|
10881
10904
|
const { t } = (0, react_i18next.useTranslation)();
|
|
10882
10905
|
const baseClassName$1 = (0, classnames.default)(active ? "Layer__btn--active" : "", className);
|
|
10883
10906
|
if (withRetry && error$38) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(RetryButton, _objectSpread2(_objectSpread2({}, props), {}, {
|
|
@@ -10900,7 +10923,7 @@ const SubmitButton = (_ref) => {
|
|
|
10900
10923
|
children
|
|
10901
10924
|
}));
|
|
10902
10925
|
};
|
|
10903
|
-
var _excluded$
|
|
10926
|
+
var _excluded$92 = [
|
|
10904
10927
|
"isOpen",
|
|
10905
10928
|
"onOpenChange",
|
|
10906
10929
|
"useDrawer"
|
|
@@ -10966,7 +10989,7 @@ var BaseConfirmationModalContent = (0, react.memo)(function BaseConfirmationModa
|
|
|
10966
10989
|
});
|
|
10967
10990
|
});
|
|
10968
10991
|
function BaseConfirmationModal(_ref) {
|
|
10969
|
-
let { isOpen, onOpenChange, useDrawer = false } = _ref, contentProps = _objectWithoutProperties(_ref, _excluded$
|
|
10992
|
+
let { isOpen, onOpenChange, useDrawer = false } = _ref, contentProps = _objectWithoutProperties(_ref, _excluded$92);
|
|
10970
10993
|
if (useDrawer) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Drawer, {
|
|
10971
10994
|
flexBlock: true,
|
|
10972
10995
|
isOpen,
|
|
@@ -11019,14 +11042,14 @@ const COMBO_BOX_CLASS_NAMES = {
|
|
|
11019
11042
|
MULTI_VALUE: "Layer__ComboBoxMultiValue",
|
|
11020
11043
|
MULTI_VALUE_LABEL: "Layer__ComboBoxMultiValueLabel"
|
|
11021
11044
|
};
|
|
11022
|
-
var _excluded$
|
|
11045
|
+
var _excluded$91 = ["size"];
|
|
11023
11046
|
var Check$6 = (_ref) => {
|
|
11024
11047
|
let { size = 18 } = _ref;
|
|
11025
11048
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("svg", _objectSpread2(_objectSpread2({
|
|
11026
11049
|
viewBox: "0 0 18 18",
|
|
11027
11050
|
fill: "none",
|
|
11028
11051
|
xmlns: "http://www.w3.org/2000/svg"
|
|
11029
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
11052
|
+
}, _objectWithoutProperties(_ref, _excluded$91)), {}, {
|
|
11030
11053
|
width: size,
|
|
11031
11054
|
height: size,
|
|
11032
11055
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
@@ -11038,14 +11061,14 @@ var Check$6 = (_ref) => {
|
|
|
11038
11061
|
}));
|
|
11039
11062
|
};
|
|
11040
11063
|
var Check_default = Check$6;
|
|
11041
|
-
var _excluded$
|
|
11064
|
+
var _excluded$90 = ["size"];
|
|
11042
11065
|
var ChevronDown = (_ref) => {
|
|
11043
11066
|
let { size = 18 } = _ref;
|
|
11044
11067
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("svg", _objectSpread2(_objectSpread2({
|
|
11045
11068
|
viewBox: "0 0 18 18",
|
|
11046
11069
|
fill: "none",
|
|
11047
11070
|
xmlns: "http://www.w3.org/2000/svg"
|
|
11048
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
11071
|
+
}, _objectWithoutProperties(_ref, _excluded$90)), {}, {
|
|
11049
11072
|
width: size,
|
|
11050
11073
|
height: size,
|
|
11051
11074
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
@@ -11057,14 +11080,14 @@ var ChevronDown = (_ref) => {
|
|
|
11057
11080
|
}));
|
|
11058
11081
|
};
|
|
11059
11082
|
var ChevronDown_default = ChevronDown;
|
|
11060
|
-
var _excluded$
|
|
11083
|
+
var _excluded$89 = ["size"];
|
|
11061
11084
|
var X$1 = (_ref) => {
|
|
11062
11085
|
let { size = 18 } = _ref;
|
|
11063
11086
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
11064
11087
|
xmlns: "http://www.w3.org/2000/svg",
|
|
11065
11088
|
viewBox: "0 0 18 18",
|
|
11066
11089
|
fill: "none"
|
|
11067
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
11090
|
+
}, _objectWithoutProperties(_ref, _excluded$89)), {}, {
|
|
11068
11091
|
width: size,
|
|
11069
11092
|
height: size,
|
|
11070
11093
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
@@ -11081,10 +11104,10 @@ var X$1 = (_ref) => {
|
|
|
11081
11104
|
}));
|
|
11082
11105
|
};
|
|
11083
11106
|
var X_default = X$1;
|
|
11084
|
-
var _excluded$
|
|
11107
|
+
var _excluded$88 = ["children"], _excluded2$11 = ["children"], _excluded3$4 = ["children"], _excluded4$3 = ["children"], _excluded5$2 = ["children"], _excluded6$2 = ["children"], _excluded7 = ["children"], _excluded8 = ["children"];
|
|
11085
11108
|
function buildCustomClearIndicator() {
|
|
11086
11109
|
return function CustomClearIndicator(_ref) {
|
|
11087
|
-
let { children } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
11110
|
+
let { children } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$88);
|
|
11088
11111
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_select.components.ClearIndicator, _objectSpread2(_objectSpread2({}, restProps), {}, {
|
|
11089
11112
|
className: COMBO_BOX_CLASS_NAMES.CLEAR_INDICATOR,
|
|
11090
11113
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(X_default, { size: 16 })
|
|
@@ -11290,7 +11313,7 @@ function useCommonComboBoxProps({ className, options, groups, onInputValueChange
|
|
|
11290
11313
|
styles
|
|
11291
11314
|
]);
|
|
11292
11315
|
}
|
|
11293
|
-
var _excluded$
|
|
11316
|
+
var _excluded$87 = [
|
|
11294
11317
|
"className",
|
|
11295
11318
|
"slots",
|
|
11296
11319
|
"isError",
|
|
@@ -11298,7 +11321,7 @@ var _excluded$86 = [
|
|
|
11298
11321
|
"onSelectedValueChange"
|
|
11299
11322
|
];
|
|
11300
11323
|
function ComboBox(_ref) {
|
|
11301
|
-
let { className, slots, isError, selectedValue, onSelectedValueChange } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
11324
|
+
let { className, slots, isError, selectedValue, onSelectedValueChange } = _ref, props = _objectWithoutProperties(_ref, _excluded$87);
|
|
11302
11325
|
const commonSelectProps = useCommonComboBoxProps(_objectSpread2({
|
|
11303
11326
|
className,
|
|
11304
11327
|
slots,
|
|
@@ -11317,13 +11340,13 @@ function ComboBox(_ref) {
|
|
|
11317
11340
|
})]
|
|
11318
11341
|
});
|
|
11319
11342
|
}
|
|
11320
|
-
var _excluded$
|
|
11343
|
+
var _excluded$86 = [
|
|
11321
11344
|
"amount",
|
|
11322
11345
|
"displayPlusSign",
|
|
11323
11346
|
"className"
|
|
11324
11347
|
];
|
|
11325
11348
|
var MoneySpan = (0, react.forwardRef)((_ref, ref) => {
|
|
11326
|
-
let { amount, displayPlusSign, className } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
11349
|
+
let { amount, displayPlusSign, className } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$86);
|
|
11327
11350
|
const { formatCurrencyFromCents: formatCurrencyFromCents$1 } = useIntlFormatter();
|
|
11328
11351
|
const formattedAmount = formatCurrencyFromCents$1(amount, { signDisplay: displayPlusSign ? "always" : "auto" });
|
|
11329
11352
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, _objectSpread2(_objectSpread2({}, restProps), {}, {
|
|
@@ -11640,14 +11663,14 @@ const getDefaultSelectedCategoryForBankTransaction = (bankTransaction, ignoreSug
|
|
|
11640
11663
|
if (hasSuggestions(bankTransaction.categorization_flow)) return convertApiCategorizationToCategoryOrSplitAsOption(bankTransaction.categorization_flow.suggestions[0]);
|
|
11641
11664
|
return null;
|
|
11642
11665
|
};
|
|
11643
|
-
var _excluded$
|
|
11666
|
+
var _excluded$85 = ["size"];
|
|
11644
11667
|
var MinimizeTwo = (_ref) => {
|
|
11645
11668
|
let { size = 18 } = _ref;
|
|
11646
11669
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
11647
11670
|
xmlns: "http://www.w3.org/2000/svg",
|
|
11648
11671
|
viewBox: "0 0 18 18",
|
|
11649
11672
|
fill: "none"
|
|
11650
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
11673
|
+
}, _objectWithoutProperties(_ref, _excluded$85)), {}, {
|
|
11651
11674
|
width: size,
|
|
11652
11675
|
height: size,
|
|
11653
11676
|
children: [
|
|
@@ -11679,14 +11702,14 @@ var MinimizeTwo = (_ref) => {
|
|
|
11679
11702
|
}));
|
|
11680
11703
|
};
|
|
11681
11704
|
var MinimizeTwo_default = MinimizeTwo;
|
|
11682
|
-
var _excluded$
|
|
11705
|
+
var _excluded$84 = ["size"];
|
|
11683
11706
|
var Scissors = (_ref) => {
|
|
11684
11707
|
let { size = 11 } = _ref;
|
|
11685
11708
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
11686
11709
|
viewBox: "0 0 11 11",
|
|
11687
11710
|
fill: "none",
|
|
11688
11711
|
xmlns: "http://www.w3.org/2000/svg"
|
|
11689
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
11712
|
+
}, _objectWithoutProperties(_ref, _excluded$84)), {}, {
|
|
11690
11713
|
width: size,
|
|
11691
11714
|
height: size,
|
|
11692
11715
|
children: [
|
|
@@ -12106,7 +12129,7 @@ var toActionableListOption = (opt) => {
|
|
|
12106
12129
|
value: opt
|
|
12107
12130
|
};
|
|
12108
12131
|
};
|
|
12109
|
-
var _excluded$
|
|
12132
|
+
var _excluded$83 = [
|
|
12110
12133
|
"actionCount",
|
|
12111
12134
|
"className",
|
|
12112
12135
|
"slots",
|
|
@@ -12114,7 +12137,7 @@ var _excluded$82 = [
|
|
|
12114
12137
|
];
|
|
12115
12138
|
var INPUT_GROUP_CLASS_NAME = "Layer__UI__InputGroup";
|
|
12116
12139
|
const InputGroup$1 = (0, react.forwardRef)(function InputGroup$2(_ref, ref) {
|
|
12117
|
-
let { actionCount, className, slots, children } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
12140
|
+
let { actionCount, className, slots, children } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$83);
|
|
12118
12141
|
const combinedClassName = (0, classnames.default)(INPUT_GROUP_CLASS_NAME, className);
|
|
12119
12142
|
const dataProperties = toDataProperties({ "action-count": actionCount });
|
|
12120
12143
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.Group, _objectSpread2(_objectSpread2(_objectSpread2({}, restProps), dataProperties), {}, {
|
|
@@ -12123,10 +12146,10 @@ const InputGroup$1 = (0, react.forwardRef)(function InputGroup$2(_ref, ref) {
|
|
|
12123
12146
|
children
|
|
12124
12147
|
}));
|
|
12125
12148
|
});
|
|
12126
|
-
var _excluded$
|
|
12149
|
+
var _excluded$82 = ["placeholder", "isDisabled"];
|
|
12127
12150
|
var CLASS_NAME$8 = "Layer__MinimalSearchField";
|
|
12128
12151
|
function MinimalSearchField(_ref) {
|
|
12129
|
-
let { placeholder, isDisabled } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
12152
|
+
let { placeholder, isDisabled } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$82);
|
|
12130
12153
|
const { t } = (0, react_i18next.useTranslation)();
|
|
12131
12154
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_aria_components.SearchField, _objectSpread2(_objectSpread2({}, restProps), {}, {
|
|
12132
12155
|
isDisabled,
|
|
@@ -12144,7 +12167,7 @@ function MinimalSearchField(_ref) {
|
|
|
12144
12167
|
})]
|
|
12145
12168
|
}));
|
|
12146
12169
|
}
|
|
12147
|
-
var _excluded$
|
|
12170
|
+
var _excluded$81 = [
|
|
12148
12171
|
"slot",
|
|
12149
12172
|
"className",
|
|
12150
12173
|
"label",
|
|
@@ -12152,7 +12175,7 @@ var _excluded$80 = [
|
|
|
12152
12175
|
];
|
|
12153
12176
|
var CLASS_NAME$7 = "Layer__SearchField";
|
|
12154
12177
|
function SearchField(_ref) {
|
|
12155
|
-
let { slot = "search", className, label: label$50, isDisabled } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
12178
|
+
let { slot = "search", className, label: label$50, isDisabled } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$81);
|
|
12156
12179
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(InputGroup$1, {
|
|
12157
12180
|
slot,
|
|
12158
12181
|
className: (0, classnames.default)(CLASS_NAME$7, className),
|
|
@@ -12658,14 +12681,14 @@ const BankTransactionsBulkActions = ({ isMobileView = false, slotProps }) => {
|
|
|
12658
12681
|
] })
|
|
12659
12682
|
}) });
|
|
12660
12683
|
};
|
|
12661
|
-
var _excluded$
|
|
12684
|
+
var _excluded$80 = ["size"];
|
|
12662
12685
|
var DownloadCloud = (_ref) => {
|
|
12663
12686
|
let { size = 18 } = _ref;
|
|
12664
12687
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
12665
12688
|
xmlns: "http://www.w3.org/2000/svg",
|
|
12666
12689
|
viewBox: "0 0 18 18",
|
|
12667
12690
|
fill: "none"
|
|
12668
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
12691
|
+
}, _objectWithoutProperties(_ref, _excluded$80)), {}, {
|
|
12669
12692
|
width: size,
|
|
12670
12693
|
height: size,
|
|
12671
12694
|
children: [
|
|
@@ -12691,14 +12714,14 @@ var DownloadCloud = (_ref) => {
|
|
|
12691
12714
|
}));
|
|
12692
12715
|
};
|
|
12693
12716
|
var DownloadCloud_default = DownloadCloud;
|
|
12694
|
-
var _excluded$
|
|
12717
|
+
var _excluded$79 = ["size"];
|
|
12695
12718
|
var UploadCloud = (_ref) => {
|
|
12696
12719
|
let { size = 18 } = _ref;
|
|
12697
12720
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
12698
12721
|
viewBox: "0 0 18 18",
|
|
12699
12722
|
fill: "none",
|
|
12700
12723
|
xmlns: "http://www.w3.org/2000/svg"
|
|
12701
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
12724
|
+
}, _objectWithoutProperties(_ref, _excluded$79)), {}, {
|
|
12702
12725
|
width: size,
|
|
12703
12726
|
height: size,
|
|
12704
12727
|
children: [
|
|
@@ -12944,7 +12967,7 @@ function useCustomAccountParseCsv() {
|
|
|
12944
12967
|
file
|
|
12945
12968
|
}).then(({ data: data$1 }) => data$1), { revalidate: false });
|
|
12946
12969
|
}
|
|
12947
|
-
var _excluded$
|
|
12970
|
+
var _excluded$78 = [
|
|
12948
12971
|
"className",
|
|
12949
12972
|
"slots",
|
|
12950
12973
|
"isError",
|
|
@@ -12957,7 +12980,7 @@ var _excluded$77 = [
|
|
|
12957
12980
|
];
|
|
12958
12981
|
var returnTrue = () => true;
|
|
12959
12982
|
function CreatableComboBox(_ref) {
|
|
12960
|
-
let { className, slots, isError, selectedValue, onSelectedValueChange, onCreateOption, formatCreateLabel: formatCreateLabel$3, createOptionPosition = "first", isValidNewOption = returnTrue } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
12983
|
+
let { className, slots, isError, selectedValue, onSelectedValueChange, onCreateOption, formatCreateLabel: formatCreateLabel$3, createOptionPosition = "first", isValidNewOption = returnTrue } = _ref, props = _objectWithoutProperties(_ref, _excluded$78);
|
|
12961
12984
|
const commonSelectProps = useCommonComboBoxProps(_objectSpread2({
|
|
12962
12985
|
className,
|
|
12963
12986
|
slots,
|
|
@@ -12998,14 +13021,14 @@ const CopyTemplateHeadersButtonGroup = ({ headers, className }) => {
|
|
|
12998
13021
|
}, key))
|
|
12999
13022
|
});
|
|
13000
13023
|
};
|
|
13001
|
-
var _excluded$
|
|
13024
|
+
var _excluded$77 = ["size"];
|
|
13002
13025
|
var CloseIcon = (_ref) => {
|
|
13003
13026
|
let { size = 12 } = _ref;
|
|
13004
13027
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
13005
13028
|
viewBox: "0 0 12 12",
|
|
13006
13029
|
fill: "none",
|
|
13007
13030
|
xmlns: "http://www.w3.org/2000/svg"
|
|
13008
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
13031
|
+
}, _objectWithoutProperties(_ref, _excluded$77)), {}, {
|
|
13009
13032
|
width: size,
|
|
13010
13033
|
height: size,
|
|
13011
13034
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
@@ -13236,7 +13259,7 @@ function useCreateCustomAccount() {
|
|
|
13236
13259
|
return Reflect.get(target, prop);
|
|
13237
13260
|
} });
|
|
13238
13261
|
}
|
|
13239
|
-
var _excluded$
|
|
13262
|
+
var _excluded$76 = ["children", "className"], _excluded2$10 = [
|
|
13240
13263
|
"children",
|
|
13241
13264
|
"inline",
|
|
13242
13265
|
"textarea",
|
|
@@ -13245,7 +13268,7 @@ var _excluded$75 = ["children", "className"], _excluded2$10 = [
|
|
|
13245
13268
|
var FORM_CLASS_NAME = "Layer__UI__Form";
|
|
13246
13269
|
const Form = (0, react.forwardRef)(function Form$1(_ref, ref) {
|
|
13247
13270
|
let { children, className } = _ref;
|
|
13248
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.Form, _objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$
|
|
13271
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.Form, _objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$76)), {}, {
|
|
13249
13272
|
className: (0, classnames.default)(FORM_CLASS_NAME, className),
|
|
13250
13273
|
ref,
|
|
13251
13274
|
children
|
|
@@ -13452,10 +13475,10 @@ function useBigDecimalInput({ value, onChange, onBlur, mode, maxValue, maxDecima
|
|
|
13452
13475
|
onPaste
|
|
13453
13476
|
};
|
|
13454
13477
|
}
|
|
13455
|
-
var _excluded$
|
|
13478
|
+
var _excluded$75 = ["inset", "placement"];
|
|
13456
13479
|
var INPUT_CLASS_NAME = "Layer__UI__Input";
|
|
13457
13480
|
const Input$1 = (0, react.forwardRef)(function Input$2(_ref, ref) {
|
|
13458
|
-
let { inset, placement } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
13481
|
+
let { inset, placement } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$75);
|
|
13459
13482
|
const dataProperties = toDataProperties({
|
|
13460
13483
|
inset,
|
|
13461
13484
|
placement
|
|
@@ -13465,7 +13488,7 @@ const Input$1 = (0, react.forwardRef)(function Input$2(_ref, ref) {
|
|
|
13465
13488
|
ref
|
|
13466
13489
|
}));
|
|
13467
13490
|
});
|
|
13468
|
-
var _excluded$
|
|
13491
|
+
var _excluded$74 = [
|
|
13469
13492
|
"mode",
|
|
13470
13493
|
"allowNegative",
|
|
13471
13494
|
"maxValue",
|
|
@@ -13479,7 +13502,7 @@ var DEFAULT_MAX_VALUE$1 = effect.BigDecimal.fromBigInt(BigInt(1e7));
|
|
|
13479
13502
|
var DEFAULT_MIN_DECIMAL_PLACES$1 = 0;
|
|
13480
13503
|
var DEFAULT_MAX_DECIMAL_PLACES$1 = 3;
|
|
13481
13504
|
function FormBigDecimalField(_ref) {
|
|
13482
|
-
let { mode = "decimal", allowNegative = false, maxValue = mode === "percent" ? BIG_DECIMAL_ONE : DEFAULT_MAX_VALUE$1, minDecimalPlaces = mode === "currency" ? 2 : DEFAULT_MIN_DECIMAL_PLACES$1, maxDecimalPlaces = mode === "currency" ? 2 : DEFAULT_MAX_DECIMAL_PLACES$1, slots, placeholder, allowEmpty } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
13505
|
+
let { mode = "decimal", allowNegative = false, maxValue = mode === "percent" ? BIG_DECIMAL_ONE : DEFAULT_MAX_VALUE$1, minDecimalPlaces = mode === "currency" ? 2 : DEFAULT_MIN_DECIMAL_PLACES$1, maxDecimalPlaces = mode === "currency" ? 2 : DEFAULT_MAX_DECIMAL_PLACES$1, slots, placeholder, allowEmpty } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$74);
|
|
13483
13506
|
const { name: name$1, state: state$16, handleChange, handleBlur } = useFieldContext();
|
|
13484
13507
|
const { value } = state$16;
|
|
13485
13508
|
const { inputValue, onInputChange, onInputBlur, onBeforeInput, onPaste } = useBigDecimalInput({
|
|
@@ -13512,7 +13535,7 @@ function FormBigDecimalField(_ref) {
|
|
|
13512
13535
|
})
|
|
13513
13536
|
}));
|
|
13514
13537
|
}
|
|
13515
|
-
var _excluded$
|
|
13538
|
+
var _excluded$73 = [
|
|
13516
13539
|
"children",
|
|
13517
13540
|
"className",
|
|
13518
13541
|
"variant",
|
|
@@ -13526,7 +13549,7 @@ var CHECK_SIZE = {
|
|
|
13526
13549
|
lg: 16
|
|
13527
13550
|
};
|
|
13528
13551
|
function Checkbox(_ref) {
|
|
13529
|
-
let { children, className, variant = "default", size = "sm", isIndeterminate } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
13552
|
+
let { children, className, variant = "default", size = "sm", isIndeterminate } = _ref, props = _objectWithoutProperties(_ref, _excluded$73);
|
|
13530
13553
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.Checkbox, _objectSpread2(_objectSpread2(_objectSpread2({}, (0, react.useMemo)(() => toDataProperties({
|
|
13531
13554
|
size,
|
|
13532
13555
|
variant,
|
|
@@ -13585,7 +13608,7 @@ function FormCheckboxField({ label: label$50, className, inline = false, showLab
|
|
|
13585
13608
|
children: label$50
|
|
13586
13609
|
}) }));
|
|
13587
13610
|
}
|
|
13588
|
-
var _excluded$
|
|
13611
|
+
var _excluded$72 = [
|
|
13589
13612
|
"inline",
|
|
13590
13613
|
"className",
|
|
13591
13614
|
"isReadOnly"
|
|
@@ -13593,7 +13616,7 @@ var _excluded$71 = [
|
|
|
13593
13616
|
const DATE_PICKER_CLASS_NAME = "Layer__UI__DatePicker";
|
|
13594
13617
|
var DATE_FIELD_CLASS_NAME = "Layer__UI__DateField";
|
|
13595
13618
|
const DateField = (0, react.forwardRef)(function DateField$1(_ref, ref) {
|
|
13596
|
-
let { inline, className, isReadOnly } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
13619
|
+
let { inline, className, isReadOnly } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$72);
|
|
13597
13620
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.DateField, _objectSpread2(_objectSpread2(_objectSpread2({}, toDataProperties({
|
|
13598
13621
|
inline,
|
|
13599
13622
|
readonly: isReadOnly
|
|
@@ -13680,10 +13703,10 @@ function FormDateField({ label: label$50, className, inline = false, showLabel =
|
|
|
13680
13703
|
shouldShowErrorMessage && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(FieldError, { children: errorMessage })
|
|
13681
13704
|
] }));
|
|
13682
13705
|
}
|
|
13683
|
-
var _excluded$
|
|
13706
|
+
var _excluded$71 = ["className", "isReadOnly"], _excluded2$7 = ["className"], _excluded3$2 = ["className"], _excluded4$1 = ["className", "size"], _excluded5$1 = ["className"], _excluded6$1 = ["className", "size"];
|
|
13684
13707
|
var CALENDAR_CLASS_NAME = "Layer__UI__Calendar";
|
|
13685
13708
|
const Calendar = (0, react.forwardRef)(function Calendar$1(_ref, ref) {
|
|
13686
|
-
let { className, isReadOnly } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
13709
|
+
let { className, isReadOnly } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$71);
|
|
13687
13710
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.Calendar, _objectSpread2(_objectSpread2(_objectSpread2({}, toDataProperties({ readonly: isReadOnly })), restProps), {}, {
|
|
13688
13711
|
isReadOnly,
|
|
13689
13712
|
className: (0, classnames.default)(CALENDAR_CLASS_NAME, className),
|
|
@@ -13822,10 +13845,10 @@ const DatePickerInput = ({ errorText, variant, onClick, isReadOnly }) => {
|
|
|
13822
13845
|
})]
|
|
13823
13846
|
});
|
|
13824
13847
|
};
|
|
13825
|
-
var _excluded$
|
|
13848
|
+
var _excluded$70 = ["flexInline"];
|
|
13826
13849
|
var POPOVER_CLASS_NAMES = `Layer__Portal Layer__Popover`;
|
|
13827
13850
|
const Popover$2 = (0, react.forwardRef)(function Popover$3(_ref, ref) {
|
|
13828
|
-
let { flexInline = false } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
13851
|
+
let { flexInline = false } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$70);
|
|
13829
13852
|
const dataProperties = toDataProperties({ "flex-inline": flexInline });
|
|
13830
13853
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.Popover, _objectSpread2(_objectSpread2(_objectSpread2({}, restProps), dataProperties), {}, {
|
|
13831
13854
|
className: POPOVER_CLASS_NAMES,
|
|
@@ -13945,7 +13968,7 @@ const fromNonRecursiveBigDecimal = (nrbd) => {
|
|
|
13945
13968
|
const nrbdEquals = (a, b) => {
|
|
13946
13969
|
return effect.BigDecimal.equals(fromNonRecursiveBigDecimal(a), fromNonRecursiveBigDecimal(b));
|
|
13947
13970
|
};
|
|
13948
|
-
var _excluded$
|
|
13971
|
+
var _excluded$69 = [
|
|
13949
13972
|
"mode",
|
|
13950
13973
|
"allowNegative",
|
|
13951
13974
|
"maxValue",
|
|
@@ -13959,7 +13982,7 @@ var DEFAULT_MAX_VALUE = effect.BigDecimal.fromBigInt(BigInt(1e7));
|
|
|
13959
13982
|
var DEFAULT_MIN_DECIMAL_PLACES = 0;
|
|
13960
13983
|
var DEFAULT_MAX_DECIMAL_PLACES = 3;
|
|
13961
13984
|
function FormNonRecursiveBigDecimalField(_ref) {
|
|
13962
|
-
let { mode = "decimal", allowNegative = false, maxValue = mode === "percent" ? BIG_DECIMAL_ONE : DEFAULT_MAX_VALUE, minDecimalPlaces = mode === "currency" ? 2 : DEFAULT_MIN_DECIMAL_PLACES, maxDecimalPlaces = mode === "currency" ? 2 : DEFAULT_MAX_DECIMAL_PLACES, slots, placeholder, allowEmpty } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
13985
|
+
let { mode = "decimal", allowNegative = false, maxValue = mode === "percent" ? BIG_DECIMAL_ONE : DEFAULT_MAX_VALUE, minDecimalPlaces = mode === "currency" ? 2 : DEFAULT_MIN_DECIMAL_PLACES, maxDecimalPlaces = mode === "currency" ? 2 : DEFAULT_MAX_DECIMAL_PLACES, slots, placeholder, allowEmpty } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$69);
|
|
13963
13986
|
const { name: name$1, state: state$16, handleChange, handleBlur } = useFieldContext();
|
|
13964
13987
|
const { value: nrbdValue } = state$16;
|
|
13965
13988
|
const { inputValue, onInputChange, onInputBlur, onBeforeInput, onPaste } = useBigDecimalInput({
|
|
@@ -13994,14 +14017,14 @@ function FormNonRecursiveBigDecimalField(_ref) {
|
|
|
13994
14017
|
})
|
|
13995
14018
|
}));
|
|
13996
14019
|
}
|
|
13997
|
-
var _excluded$
|
|
14020
|
+
var _excluded$68 = [
|
|
13998
14021
|
"inline",
|
|
13999
14022
|
"className",
|
|
14000
14023
|
"isReadOnly"
|
|
14001
14024
|
];
|
|
14002
14025
|
var NUMBER_FIELD_CLASS_NAME = "Layer__UI__NumberField";
|
|
14003
14026
|
const NumberField = (0, react.forwardRef)(function NumberField$1(_ref, ref) {
|
|
14004
|
-
let { inline, className, isReadOnly } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
14027
|
+
let { inline, className, isReadOnly } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$68);
|
|
14005
14028
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.NumberField, _objectSpread2(_objectSpread2(_objectSpread2({ step: 1 }, toDataProperties({
|
|
14006
14029
|
inline,
|
|
14007
14030
|
readonly: isReadOnly
|
|
@@ -14048,7 +14071,7 @@ function FormNumberField({ label: label$50, className, inline = false, showLabel
|
|
|
14048
14071
|
shouldShowErrorMessage && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(FieldError, { children: errorMessage })
|
|
14049
14072
|
] }));
|
|
14050
14073
|
}
|
|
14051
|
-
var _excluded$
|
|
14074
|
+
var _excluded$67 = [
|
|
14052
14075
|
"children",
|
|
14053
14076
|
"className",
|
|
14054
14077
|
"onChange"
|
|
@@ -14058,7 +14081,7 @@ var RADIO_CLASS_NAME = "Layer__Radio";
|
|
|
14058
14081
|
var INDICATOR_SIZE = 10;
|
|
14059
14082
|
function RadioGroup(_ref) {
|
|
14060
14083
|
let { children, className, onChange } = _ref;
|
|
14061
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.RadioGroup, _objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$
|
|
14084
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.RadioGroup, _objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$67)), {}, {
|
|
14062
14085
|
onChange,
|
|
14063
14086
|
className: (0, classnames.default)(RADIO_GROUP_CLASS_NAME, className),
|
|
14064
14087
|
children
|
|
@@ -14167,11 +14190,11 @@ function FormRadioGroupYesNoField({ label: label$50, className, inline = false,
|
|
|
14167
14190
|
}), shouldShowErrorMessage && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(FieldError, { children: errorMessage })]
|
|
14168
14191
|
})] }));
|
|
14169
14192
|
}
|
|
14170
|
-
var _excluded$
|
|
14193
|
+
var _excluded$66 = ["children", "className"];
|
|
14171
14194
|
var SWITCH_CLASS_NAME = "Layer__UI__Switch";
|
|
14172
14195
|
const Switch = (0, react.forwardRef)((_ref, ref) => {
|
|
14173
14196
|
let { children, className } = _ref;
|
|
14174
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.Switch, _objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$
|
|
14197
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.Switch, _objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$66)), {}, {
|
|
14175
14198
|
className: (0, classnames.default)(SWITCH_CLASS_NAME, className),
|
|
14176
14199
|
ref,
|
|
14177
14200
|
children: withRenderProp(children, (node) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", { slot: "indicator" }), node] }))
|
|
@@ -14201,19 +14224,19 @@ function FormSwitchField({ label: label$50, slots, className, inline = false, sh
|
|
|
14201
14224
|
})]
|
|
14202
14225
|
}) }));
|
|
14203
14226
|
}
|
|
14204
|
-
var _excluded$
|
|
14227
|
+
var _excluded$65 = ["resize"];
|
|
14205
14228
|
var TEXTAREA_CLASS_NAME = "Layer__UI__TextArea";
|
|
14206
14229
|
const TextArea = (0, react.forwardRef)(function TextArea$1(_ref, ref) {
|
|
14207
|
-
let { resize = "none" } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
14230
|
+
let { resize = "none" } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$65);
|
|
14208
14231
|
const dataProperties = toDataProperties({ resize });
|
|
14209
14232
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.TextArea, _objectSpread2(_objectSpread2(_objectSpread2({}, restProps), dataProperties), {}, {
|
|
14210
14233
|
className: TEXTAREA_CLASS_NAME,
|
|
14211
14234
|
ref
|
|
14212
14235
|
}));
|
|
14213
14236
|
});
|
|
14214
|
-
var _excluded$
|
|
14237
|
+
var _excluded$64 = ["placeholder"];
|
|
14215
14238
|
function FormTextAreaField(_ref) {
|
|
14216
|
-
let { placeholder } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
14239
|
+
let { placeholder } = _ref, props = _objectWithoutProperties(_ref, _excluded$64);
|
|
14217
14240
|
const { name: name$1, state: state$16, handleChange, handleBlur } = useFieldContext();
|
|
14218
14241
|
const { value } = state$16;
|
|
14219
14242
|
const onChange = (0, react.useCallback)((e) => {
|
|
@@ -14232,9 +14255,9 @@ function FormTextAreaField(_ref) {
|
|
|
14232
14255
|
})
|
|
14233
14256
|
}));
|
|
14234
14257
|
}
|
|
14235
|
-
var _excluded$
|
|
14258
|
+
var _excluded$63 = ["placeholder"];
|
|
14236
14259
|
function FormTextField(_ref) {
|
|
14237
|
-
let { placeholder } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
14260
|
+
let { placeholder } = _ref, props = _objectWithoutProperties(_ref, _excluded$63);
|
|
14238
14261
|
const { name: name$1, state: state$16, handleChange, handleBlur } = useFieldContext();
|
|
14239
14262
|
const { value } = state$16;
|
|
14240
14263
|
const onChange = (0, react.useCallback)((e) => {
|
|
@@ -14331,14 +14354,14 @@ const useCustomAccountForm = ({ onSuccess }) => {
|
|
|
14331
14354
|
isFormValid: (0, __tanstack_react_form.useStore)(form.store, (state$16) => state$16.isValid)
|
|
14332
14355
|
};
|
|
14333
14356
|
};
|
|
14334
|
-
var _excluded$
|
|
14357
|
+
var _excluded$62 = [
|
|
14335
14358
|
"className",
|
|
14336
14359
|
"isInvalid",
|
|
14337
14360
|
"errorMessage",
|
|
14338
14361
|
"leftText"
|
|
14339
14362
|
];
|
|
14340
14363
|
const Input = (_ref) => {
|
|
14341
|
-
let { className, isInvalid, errorMessage, leftText } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
14364
|
+
let { className, isInvalid, errorMessage, leftText } = _ref, props = _objectWithoutProperties(_ref, _excluded$62);
|
|
14342
14365
|
const baseClassName$1 = (0, classnames.default)("Layer__input", isInvalid ? "Layer__input--error" : "", leftText ? "Layer__input--with-left-text" : "", className);
|
|
14343
14366
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(DeprecatedTooltip, {
|
|
14344
14367
|
disabled: !isInvalid || !errorMessage,
|
|
@@ -14366,14 +14389,14 @@ const InputGroup = ({ label: label$50, name: name$1, className, inline, children
|
|
|
14366
14389
|
}), children]
|
|
14367
14390
|
});
|
|
14368
14391
|
};
|
|
14369
|
-
var _excluded$
|
|
14392
|
+
var _excluded$61 = ["size"];
|
|
14370
14393
|
var ChevronDownFill = (_ref) => {
|
|
14371
14394
|
let { size = 18 } = _ref;
|
|
14372
14395
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
14373
14396
|
xmlns: "http://www.w3.org/2000/svg",
|
|
14374
14397
|
viewBox: "0 0 18 18",
|
|
14375
14398
|
fill: "none"
|
|
14376
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
14399
|
+
}, _objectWithoutProperties(_ref, _excluded$61)), {}, {
|
|
14377
14400
|
width: size,
|
|
14378
14401
|
height: size,
|
|
14379
14402
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
@@ -14388,9 +14411,9 @@ var ChevronDownFill = (_ref) => {
|
|
|
14388
14411
|
}));
|
|
14389
14412
|
};
|
|
14390
14413
|
var ChevronDownFill_default = ChevronDownFill;
|
|
14391
|
-
var _excluded$
|
|
14414
|
+
var _excluded$60 = ["children"];
|
|
14392
14415
|
const SelectMenuPortal = (_ref) => {
|
|
14393
|
-
let { children } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
14416
|
+
let { children } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$60);
|
|
14394
14417
|
const dataProperties = toDataProperties({ "react-aria-top-layer": true });
|
|
14395
14418
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_select.components.MenuPortal, _objectSpread2(_objectSpread2({}, restProps), {}, {
|
|
14396
14419
|
innerProps: dataProperties,
|
|
@@ -14430,10 +14453,10 @@ const Select$1 = ({ name: name$1, options, className, classNamePrefix = "Layer__
|
|
|
14430
14453
|
})]
|
|
14431
14454
|
});
|
|
14432
14455
|
};
|
|
14433
|
-
var _excluded$
|
|
14456
|
+
var _excluded$59 = ["className"];
|
|
14434
14457
|
const ErrorText = (_ref) => {
|
|
14435
14458
|
let { className } = _ref;
|
|
14436
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, _objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$
|
|
14459
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, _objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$59)), {}, {
|
|
14437
14460
|
status: "error",
|
|
14438
14461
|
className
|
|
14439
14462
|
}));
|
|
@@ -14754,7 +14777,7 @@ function UploadTransactionsUploadCsvStep({ selectedAccount, onSelectAccount, sel
|
|
|
14754
14777
|
] })]
|
|
14755
14778
|
});
|
|
14756
14779
|
}
|
|
14757
|
-
var _excluded$
|
|
14780
|
+
var _excluded$58 = ["customAccountId"];
|
|
14758
14781
|
var createCustomAccountTransactions = post(({ businessId, customAccountId }) => `/v1/businesses/${businessId}/custom-accounts/${customAccountId}/transactions`);
|
|
14759
14782
|
function buildKey$74({ access_token: accessToken, apiUrl, businessId }) {
|
|
14760
14783
|
if (accessToken && apiUrl) return {
|
|
@@ -14769,7 +14792,7 @@ function useCreateCustomAccountTransactions() {
|
|
|
14769
14792
|
const { data } = useAuth();
|
|
14770
14793
|
const { businessId } = useLayerContext();
|
|
14771
14794
|
return (0, swr_mutation.default)(() => withLocale(buildKey$74(_objectSpread2(_objectSpread2({}, data), {}, { businessId }))), ({ accessToken, apiUrl, businessId: businessId$1 }, _ref) => {
|
|
14772
|
-
let { arg: _ref2 } = _ref, { customAccountId } = _ref2, body = _objectWithoutProperties(_ref2, _excluded$
|
|
14795
|
+
let { arg: _ref2 } = _ref, { customAccountId } = _ref2, body = _objectWithoutProperties(_ref2, _excluded$58);
|
|
14773
14796
|
return createCustomAccountTransactions(apiUrl, accessToken, {
|
|
14774
14797
|
params: {
|
|
14775
14798
|
businessId: businessId$1,
|
|
@@ -14841,7 +14864,7 @@ var unifiedReportColumnFields = {
|
|
|
14841
14864
|
pinning: effect.Schema.optional(TransformedPinningSchema)
|
|
14842
14865
|
};
|
|
14843
14866
|
const UnifiedReportColumnSchema = effect.Schema.Struct(_objectSpread2(_objectSpread2({}, unifiedReportColumnFields), {}, { columns: effect.Schema.optional(effect.Schema.Array(effect.Schema.suspend(() => UnifiedReportColumnSchema))) }));
|
|
14844
|
-
|
|
14867
|
+
const UnifiedCellValueCurrencySchema = effect.Schema.Struct({
|
|
14845
14868
|
type: effect.Schema.Literal("Currency"),
|
|
14846
14869
|
value: effect.Schema.Number
|
|
14847
14870
|
});
|
|
@@ -14849,20 +14872,30 @@ var UnifiedCellValueDateSchema = effect.Schema.Struct({
|
|
|
14849
14872
|
type: effect.Schema.Literal("Date"),
|
|
14850
14873
|
value: effect.Schema.Date
|
|
14851
14874
|
});
|
|
14852
|
-
|
|
14875
|
+
const UnifiedCellValueDecimalSchema = effect.Schema.Struct({
|
|
14853
14876
|
type: effect.Schema.Literal("Decimal"),
|
|
14854
14877
|
value: effect.Schema.Number
|
|
14855
14878
|
});
|
|
14879
|
+
var UnifiedCellValueDurationSchema = effect.Schema.Struct({
|
|
14880
|
+
type: effect.Schema.Literal("Duration"),
|
|
14881
|
+
value: effect.Schema.Number
|
|
14882
|
+
});
|
|
14856
14883
|
var UnifiedCellValueEmptySchema = effect.Schema.Struct({ type: effect.Schema.Literal("Empty") });
|
|
14857
|
-
|
|
14884
|
+
const UnifiedCellValuePercentageSchema = effect.Schema.Struct({
|
|
14885
|
+
type: effect.Schema.Literal("Percentage"),
|
|
14886
|
+
value: effect.Schema.Number
|
|
14887
|
+
});
|
|
14888
|
+
const UnifiedCellValueUnknownSchema = effect.Schema.Struct({
|
|
14858
14889
|
type: effect.Schema.String,
|
|
14859
14890
|
value: effect.Schema.optional(effect.Schema.Unknown)
|
|
14860
14891
|
});
|
|
14861
|
-
var UnifiedCellValueSchema = effect.Schema.Union(UnifiedCellValueCurrencySchema, UnifiedCellValueDateSchema, UnifiedCellValueDecimalSchema, UnifiedCellValueEmptySchema, UnifiedCellValueUnknownSchema);
|
|
14892
|
+
var UnifiedCellValueSchema = effect.Schema.Union(UnifiedCellValueCurrencySchema, UnifiedCellValueDateSchema, UnifiedCellValueDecimalSchema, UnifiedCellValueDurationSchema, UnifiedCellValueEmptySchema, UnifiedCellValuePercentageSchema, UnifiedCellValueUnknownSchema);
|
|
14862
14893
|
const isCurrencyCellValue = (value) => value.type === "Currency";
|
|
14863
14894
|
const isDateCellValue = (value) => value.type === "Date";
|
|
14864
14895
|
const isDecimalCellValue = (value) => value.type === "Decimal";
|
|
14896
|
+
const isDurationCellValue = (value) => value.type === "Duration";
|
|
14865
14897
|
const isEmptyCellValue = (value) => value.type === "Empty";
|
|
14898
|
+
const isPercentageCellValue = (value) => value.type === "Percentage";
|
|
14866
14899
|
var UnifiedCellFormatSchema = effect.Schema.Struct({ bold: effect.Schema.optional(effect.Schema.Boolean) });
|
|
14867
14900
|
var UnifiedReportCellSchema = effect.Schema.Struct({
|
|
14868
14901
|
value: UnifiedCellValueSchema,
|
|
@@ -14882,7 +14915,7 @@ const UnifiedReportSchema = effect.Schema.Struct({
|
|
|
14882
14915
|
columns: effect.Schema.Array(UnifiedReportColumnSchema),
|
|
14883
14916
|
rows: effect.Schema.Array(UnifiedReportRowSchema)
|
|
14884
14917
|
});
|
|
14885
|
-
var _excluded$
|
|
14918
|
+
var _excluded$57 = [
|
|
14886
14919
|
"children",
|
|
14887
14920
|
"className",
|
|
14888
14921
|
"nonAria",
|
|
@@ -14937,8 +14970,8 @@ var toAlignmentDataValue = (alignment) => {
|
|
|
14937
14970
|
}
|
|
14938
14971
|
};
|
|
14939
14972
|
var getClassName = (component, additionalClassNames) => (0, classnames.default)(`${CSS_PREFIX$1}-${component}`, additionalClassNames);
|
|
14940
|
-
var Table = (0, react.forwardRef)((_ref, ref) => {
|
|
14941
|
-
let { children, className, nonAria, slot } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
14973
|
+
var Table$1 = (0, react.forwardRef)((_ref, ref) => {
|
|
14974
|
+
let { children, className, nonAria, slot } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$57);
|
|
14942
14975
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(nonAria ? "table" : react_aria_components.Table, _objectSpread2(_objectSpread2({
|
|
14943
14976
|
className: getClassName(TableSubComponent.Table, className),
|
|
14944
14977
|
slot: slot !== null && slot !== void 0 ? slot : void 0
|
|
@@ -14947,7 +14980,7 @@ var Table = (0, react.forwardRef)((_ref, ref) => {
|
|
|
14947
14980
|
children
|
|
14948
14981
|
}));
|
|
14949
14982
|
});
|
|
14950
|
-
Table.displayName = TableSubComponent.Table;
|
|
14983
|
+
Table$1.displayName = TableSubComponent.Table;
|
|
14951
14984
|
var TableHeaderInner = (_ref2, ref) => {
|
|
14952
14985
|
let { children, className, nonAria } = _ref2, restProps = _objectWithoutProperties(_ref2, _excluded2$5);
|
|
14953
14986
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(nonAria ? "thead" : react_aria_components.TableHeader, _objectSpread2(_objectSpread2({ className: getClassName(TableSubComponent.TableHeader, className) }, restProps), {}, {
|
|
@@ -14964,8 +14997,8 @@ var TableBodyInner = (_ref3, ref) => {
|
|
|
14964
14997
|
children: withRenderProp(children, (node) => node)
|
|
14965
14998
|
}));
|
|
14966
14999
|
};
|
|
14967
|
-
var TableBody = (0, react.forwardRef)(TableBodyInner);
|
|
14968
|
-
TableBody.displayName = TableSubComponent.TableBody;
|
|
15000
|
+
var TableBody$1 = (0, react.forwardRef)(TableBodyInner);
|
|
15001
|
+
TableBody$1.displayName = TableSubComponent.TableBody;
|
|
14969
15002
|
var RowInner = (_ref4, ref) => {
|
|
14970
15003
|
let { children, className, depth = 0, nonAria, id, onAction } = _ref4, restProps = _objectWithoutProperties(_ref4, _excluded4);
|
|
14971
15004
|
const dataProperties = toDataProperties({ depth });
|
|
@@ -14994,7 +15027,7 @@ var Column = (0, react.forwardRef)((_ref5, ref) => {
|
|
|
14994
15027
|
}));
|
|
14995
15028
|
});
|
|
14996
15029
|
Column.displayName = TableSubComponent.Column;
|
|
14997
|
-
var Cell = (0, react.forwardRef)((_ref6, ref) => {
|
|
15030
|
+
var Cell$3 = (0, react.forwardRef)((_ref6, ref) => {
|
|
14998
15031
|
let { children, className, nonAria, id, alignment, pinned } = _ref6, restProps = _objectWithoutProperties(_ref6, _excluded6);
|
|
14999
15032
|
const dataProperties = toDataProperties({
|
|
15000
15033
|
align: toAlignmentDataValue(alignment),
|
|
@@ -15006,7 +15039,7 @@ var Cell = (0, react.forwardRef)((_ref6, ref) => {
|
|
|
15006
15039
|
children: withRenderProp(children, (node) => node)
|
|
15007
15040
|
}));
|
|
15008
15041
|
});
|
|
15009
|
-
Cell.displayName = TableSubComponent.Cell;
|
|
15042
|
+
Cell$3.displayName = TableSubComponent.Cell;
|
|
15010
15043
|
const isLeafColumn = (col) => {
|
|
15011
15044
|
return "cell" in col;
|
|
15012
15045
|
};
|
|
@@ -15087,7 +15120,7 @@ var DEFAULT_TABLE_HEIGHT = DEFAULT_ROW_HEIGHT * DEFAULT_NUM_ROWS + HEADER_HEIGHT
|
|
|
15087
15120
|
var CSS_PREFIX = "Layer__UI__VirtualizedTable";
|
|
15088
15121
|
var EMPTY_ARRAY$5 = [];
|
|
15089
15122
|
const VirtualizedDataTable = ({ columnConfig, data, isLoading, isError, componentName, ariaLabel, slots, shrinkHeightToFitRows = false, height = DEFAULT_TABLE_HEIGHT, rowHeight = DEFAULT_ROW_HEIGHT, overscan = DEFAULT_OVERSCAN }) => {
|
|
15090
|
-
const { EmptyState: EmptyState$
|
|
15123
|
+
const { EmptyState: EmptyState$8, ErrorState: ErrorState$9 } = slots;
|
|
15091
15124
|
const containerRef = (0, react.useRef)(null);
|
|
15092
15125
|
const renderedTableHeight = (0, react.useMemo)(() => {
|
|
15093
15126
|
if (!data) return height;
|
|
@@ -15120,7 +15153,7 @@ const VirtualizedDataTable = ({ columnConfig, data, isLoading, isError, componen
|
|
|
15120
15153
|
align: "center",
|
|
15121
15154
|
justify: "center",
|
|
15122
15155
|
className: `${CSS_PREFIX}__state-container`,
|
|
15123
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ErrorState$
|
|
15156
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ErrorState$9, {})
|
|
15124
15157
|
});
|
|
15125
15158
|
if (isLoading) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(HStack, {
|
|
15126
15159
|
align: "center",
|
|
@@ -15132,7 +15165,7 @@ const VirtualizedDataTable = ({ columnConfig, data, isLoading, isError, componen
|
|
|
15132
15165
|
align: "center",
|
|
15133
15166
|
justify: "center",
|
|
15134
15167
|
className: `${CSS_PREFIX}__state-container`,
|
|
15135
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(EmptyState$
|
|
15168
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(EmptyState$8, {})
|
|
15136
15169
|
});
|
|
15137
15170
|
const virtualItems = rowVirtualizer.getVirtualItems();
|
|
15138
15171
|
const totalSize = rowVirtualizer.getTotalSize();
|
|
@@ -15141,7 +15174,7 @@ const VirtualizedDataTable = ({ columnConfig, data, isLoading, isError, componen
|
|
|
15141
15174
|
ref: containerRef,
|
|
15142
15175
|
style: { height: renderedTableHeight },
|
|
15143
15176
|
"aria-label": ariaLabel,
|
|
15144
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table, {
|
|
15177
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table$1, {
|
|
15145
15178
|
className: (0, classnames.default)(CSS_PREFIX, `Layer__UI__Table__${componentName}`),
|
|
15146
15179
|
"aria-label": ariaLabel,
|
|
15147
15180
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableHeader, {
|
|
@@ -15156,7 +15189,7 @@ const VirtualizedDataTable = ({ columnConfig, data, isLoading, isError, componen
|
|
|
15156
15189
|
children: (0, __tanstack_react_table.flexRender)(header.column.columnDef.header, header.getContext())
|
|
15157
15190
|
}, header.id);
|
|
15158
15191
|
})
|
|
15159
|
-
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableBody, {
|
|
15192
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableBody$1, {
|
|
15160
15193
|
style: { height: totalSize },
|
|
15161
15194
|
children: virtualItems.map((virtualRow) => {
|
|
15162
15195
|
const row = rows[virtualRow.index];
|
|
@@ -15167,7 +15200,7 @@ const VirtualizedDataTable = ({ columnConfig, data, isLoading, isError, componen
|
|
|
15167
15200
|
style: { transform: `translateY(${virtualRow.start}px)` },
|
|
15168
15201
|
children: row.getVisibleCells().map((cell) => {
|
|
15169
15202
|
var _cell$column$columnDe;
|
|
15170
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Cell, {
|
|
15203
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Cell$3, {
|
|
15171
15204
|
alignment: (_cell$column$columnDe = cell.column.columnDef.meta) === null || _cell$column$columnDe === void 0 ? void 0 : _cell$column$columnDe.alignment,
|
|
15172
15205
|
className: (0, classnames.default)(`${CSS_PREFIX}__cell`, `Layer__UI__Table-Cell__${componentName}--${cell.column.id}`),
|
|
15173
15206
|
style: _objectSpread2({}, virtualRow.index === 0 && { borderTop: "none" }),
|
|
@@ -15182,8 +15215,8 @@ const VirtualizedDataTable = ({ columnConfig, data, isLoading, isError, componen
|
|
|
15182
15215
|
};
|
|
15183
15216
|
var ROW_HEIGHT = 52;
|
|
15184
15217
|
var TABLE_HEIGHT = ROW_HEIGHT * 9 - 1;
|
|
15185
|
-
var EmptyState$
|
|
15186
|
-
var ErrorState$
|
|
15218
|
+
var EmptyState$7 = () => null;
|
|
15219
|
+
var ErrorState$8 = () => null;
|
|
15187
15220
|
function ValidateCsvTable({ data, headers, formatters, className }) {
|
|
15188
15221
|
const { t } = (0, react_i18next.useTranslation)();
|
|
15189
15222
|
const sortedData = (0, react.useMemo)(() => [...data].sort((a, b) => {
|
|
@@ -15238,8 +15271,8 @@ function ValidateCsvTable({ data, headers, formatters, className }) {
|
|
|
15238
15271
|
rowHeight: ROW_HEIGHT,
|
|
15239
15272
|
shrinkHeightToFitRows: true,
|
|
15240
15273
|
slots: {
|
|
15241
|
-
EmptyState: EmptyState$
|
|
15242
|
-
ErrorState: ErrorState$
|
|
15274
|
+
EmptyState: EmptyState$7,
|
|
15275
|
+
ErrorState: ErrorState$8
|
|
15243
15276
|
}
|
|
15244
15277
|
})
|
|
15245
15278
|
});
|
|
@@ -16111,7 +16144,7 @@ function useDelayedRemoveBankTransaction({ bankTransaction, onRemove }) {
|
|
|
16111
16144
|
}, [bankTransaction.recently_categorized]);
|
|
16112
16145
|
return (0, react.useMemo)(() => ({ isBeingRemoved }), [isBeingRemoved]);
|
|
16113
16146
|
}
|
|
16114
|
-
var _excluded$
|
|
16147
|
+
var _excluded$56 = ["bankTransactionId"];
|
|
16115
16148
|
var CATEGORIZE_BANK_TRANSACTION_TAG = "#categorize-bank-transaction";
|
|
16116
16149
|
var categorizeBankTransaction = put(({ businessId, bankTransactionId }) => `/v1/businesses/${businessId}/bank-transactions/${bankTransactionId}/categorize`);
|
|
16117
16150
|
function buildKey$73({ access_token: accessToken, apiUrl, businessId }) {
|
|
@@ -16135,7 +16168,7 @@ function useCategorizeBankTransaction() {
|
|
|
16135
16168
|
apiUrl: auth === null || auth === void 0 ? void 0 : auth.apiUrl,
|
|
16136
16169
|
businessId
|
|
16137
16170
|
})), ({ accessToken, apiUrl, businessId: businessId$1 }, _ref) => {
|
|
16138
|
-
let { arg: _ref2 } = _ref, { bankTransactionId } = _ref2, rest = _objectWithoutProperties(_ref2, _excluded$
|
|
16171
|
+
let { arg: _ref2 } = _ref, { bankTransactionId } = _ref2, rest = _objectWithoutProperties(_ref2, _excluded$56);
|
|
16139
16172
|
return categorizeBankTransaction(apiUrl, accessToken, {
|
|
16140
16173
|
params: {
|
|
16141
16174
|
businessId: businessId$1,
|
|
@@ -16201,7 +16234,7 @@ function useCategorizeBankTransactionWithCacheUpdate() {
|
|
|
16201
16234
|
isError
|
|
16202
16235
|
]);
|
|
16203
16236
|
}
|
|
16204
|
-
var _excluded$
|
|
16237
|
+
var _excluded$55 = ["bankTransactionId"];
|
|
16205
16238
|
var matchBankTransaction = put(({ businessId, bankTransactionId }) => `/v1/businesses/${businessId}/bank-transactions/${bankTransactionId}/match`);
|
|
16206
16239
|
var MATCH_BANK_TRANSACTION_TAG = "#match-bank-transaction";
|
|
16207
16240
|
function buildKey$72({ access_token: accessToken, apiUrl, businessId }) {
|
|
@@ -16225,7 +16258,7 @@ function useMatchBankTransaction() {
|
|
|
16225
16258
|
apiUrl: auth === null || auth === void 0 ? void 0 : auth.apiUrl,
|
|
16226
16259
|
businessId
|
|
16227
16260
|
})), ({ accessToken, apiUrl, businessId: businessId$1 }, _ref) => {
|
|
16228
|
-
let { arg: _ref2 } = _ref, { bankTransactionId } = _ref2, body = _objectWithoutProperties(_ref2, _excluded$
|
|
16261
|
+
let { arg: _ref2 } = _ref, { bankTransactionId } = _ref2, body = _objectWithoutProperties(_ref2, _excluded$55);
|
|
16229
16262
|
return matchBankTransaction(apiUrl, accessToken, {
|
|
16230
16263
|
params: {
|
|
16231
16264
|
businessId: businessId$1,
|
|
@@ -16353,14 +16386,14 @@ function useDelayedVisibility({ delay, initialVisibility = false }) {
|
|
|
16353
16386
|
}, []);
|
|
16354
16387
|
return { isVisible };
|
|
16355
16388
|
}
|
|
16356
|
-
var _excluded$
|
|
16389
|
+
var _excluded$54 = ["size"];
|
|
16357
16390
|
var File$1 = (_ref) => {
|
|
16358
16391
|
let { size = 12 } = _ref;
|
|
16359
16392
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
16360
16393
|
xmlns: "http://www.w3.org/2000/svg",
|
|
16361
16394
|
viewBox: "0 0 12 12",
|
|
16362
16395
|
fill: "none"
|
|
16363
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
16396
|
+
}, _objectWithoutProperties(_ref, _excluded$54)), {}, {
|
|
16364
16397
|
width: size,
|
|
16365
16398
|
height: size,
|
|
16366
16399
|
children: [
|
|
@@ -16462,7 +16495,7 @@ const variants = {
|
|
|
16462
16495
|
}
|
|
16463
16496
|
}
|
|
16464
16497
|
};
|
|
16465
|
-
var _excluded$
|
|
16498
|
+
var _excluded$53 = [
|
|
16466
16499
|
"as",
|
|
16467
16500
|
"children",
|
|
16468
16501
|
"variant",
|
|
@@ -16471,7 +16504,7 @@ var _excluded$52 = [
|
|
|
16471
16504
|
"motionKey"
|
|
16472
16505
|
];
|
|
16473
16506
|
function AnimatedPresenceElementInner(_ref, ref) {
|
|
16474
|
-
let { as, children, variant, isOpen, slotProps = { AnimatePresence: { initial: false } }, motionKey } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
16507
|
+
let { as, children, variant, isOpen, slotProps = { AnimatePresence: { initial: false } }, motionKey } = _ref, props = _objectWithoutProperties(_ref, _excluded$53);
|
|
16475
16508
|
const config = variants[variant];
|
|
16476
16509
|
const MotionComponent = motion_react.motion[as !== null && as !== void 0 ? as : "div"];
|
|
16477
16510
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(motion_react.AnimatePresence, _objectSpread2(_objectSpread2({}, slotProps.AnimatePresence), {}, { children: isOpen && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(MotionComponent, _objectSpread2(_objectSpread2({
|
|
@@ -16616,14 +16649,14 @@ function useBookkeepingPeriods() {
|
|
|
16616
16649
|
return Reflect.get(target, prop);
|
|
16617
16650
|
} });
|
|
16618
16651
|
}
|
|
16619
|
-
var _excluded$
|
|
16652
|
+
var _excluded$52 = ["size"];
|
|
16620
16653
|
var Clock$1 = (_ref) => {
|
|
16621
16654
|
let { size = 18 } = _ref;
|
|
16622
16655
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
16623
16656
|
xmlns: "http://www.w3.org/2000/svg",
|
|
16624
16657
|
viewBox: "0 0 18 18",
|
|
16625
16658
|
fill: "none"
|
|
16626
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
16659
|
+
}, _objectWithoutProperties(_ref, _excluded$52)), {}, {
|
|
16627
16660
|
width: size,
|
|
16628
16661
|
height: size,
|
|
16629
16662
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
@@ -17128,14 +17161,14 @@ const useSplitsForm = ({ bankTransaction, selectedCategory, isOpen }) => {
|
|
|
17128
17161
|
saveLocalSplitsToCategoryStore
|
|
17129
17162
|
};
|
|
17130
17163
|
};
|
|
17131
|
-
var _excluded$
|
|
17164
|
+
var _excluded$51 = ["size"];
|
|
17132
17165
|
var ScissorsFullOpen = (_ref) => {
|
|
17133
17166
|
let { size = 12 } = _ref;
|
|
17134
17167
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("svg", _objectSpread2(_objectSpread2({
|
|
17135
17168
|
viewBox: "0 0 12 12",
|
|
17136
17169
|
fill: "none",
|
|
17137
17170
|
xmlns: "http://www.w3.org/2000/svg"
|
|
17138
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
17171
|
+
}, _objectWithoutProperties(_ref, _excluded$51)), {}, {
|
|
17139
17172
|
width: size,
|
|
17140
17173
|
height: size,
|
|
17141
17174
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("g", {
|
|
@@ -17181,14 +17214,14 @@ var ScissorsFullOpen = (_ref) => {
|
|
|
17181
17214
|
}));
|
|
17182
17215
|
};
|
|
17183
17216
|
var ScissorsFullOpen_default = ScissorsFullOpen;
|
|
17184
|
-
var _excluded$
|
|
17217
|
+
var _excluded$50 = ["size"];
|
|
17185
17218
|
var Trash$1 = (_ref) => {
|
|
17186
17219
|
let { size = 18 } = _ref;
|
|
17187
17220
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
17188
17221
|
xmlns: "http://www.w3.org/2000/svg",
|
|
17189
17222
|
viewBox: "0 0 18 18",
|
|
17190
17223
|
fill: "none"
|
|
17191
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
17224
|
+
}, _objectWithoutProperties(_ref, _excluded$50)), {}, {
|
|
17192
17225
|
width: size,
|
|
17193
17226
|
height: size,
|
|
17194
17227
|
children: [
|
|
@@ -17936,9 +17969,9 @@ const ReceiptsProvider = ({ children, bankTransaction, isActive }) => {
|
|
|
17936
17969
|
children
|
|
17937
17970
|
});
|
|
17938
17971
|
};
|
|
17939
|
-
var _excluded$
|
|
17972
|
+
var _excluded$49 = ["size"];
|
|
17940
17973
|
var Eye = (_ref) => {
|
|
17941
|
-
let { size = 18 } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
17974
|
+
let { size = 18 } = _ref, props = _objectWithoutProperties(_ref, _excluded$49);
|
|
17942
17975
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("svg", _objectSpread2(_objectSpread2({
|
|
17943
17976
|
xmlns: "http://www.w3.org/2000/svg",
|
|
17944
17977
|
width: size,
|
|
@@ -18032,9 +18065,9 @@ const FileThumb = ({ url, floatingActions = false, uploadPending, deletePending,
|
|
|
18032
18065
|
}) : null]
|
|
18033
18066
|
});
|
|
18034
18067
|
};
|
|
18035
|
-
var _excluded$
|
|
18068
|
+
var _excluded$48 = ["className", "children"];
|
|
18036
18069
|
const TextButton = (_ref) => {
|
|
18037
|
-
let { className, children } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
18070
|
+
let { className, children } = _ref, props = _objectWithoutProperties(_ref, _excluded$48);
|
|
18038
18071
|
const baseClassName$1 = (0, classnames.default)("Layer__text-btn", className);
|
|
18039
18072
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", _objectSpread2(_objectSpread2({}, props), {}, {
|
|
18040
18073
|
className: baseClassName$1,
|
|
@@ -18080,7 +18113,7 @@ const FileInput = ({ text, onUpload, disabled = false, secondary, iconOnly = fal
|
|
|
18080
18113
|
style: { display: "none" }
|
|
18081
18114
|
})] });
|
|
18082
18115
|
};
|
|
18083
|
-
var _excluded$
|
|
18116
|
+
var _excluded$47 = ["bankTransaction", "isActive"];
|
|
18084
18117
|
var MAX_RECEIPTS_COUNT = 10;
|
|
18085
18118
|
var openReceiptInNewTab = (url, receiptTitle) => (e) => {
|
|
18086
18119
|
e.preventDefault();
|
|
@@ -18101,7 +18134,7 @@ var BankTransactionReceiptsWithProvider = (0, react.forwardRef)((_ref, ref) => {
|
|
|
18101
18134
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ReceiptsProvider, {
|
|
18102
18135
|
bankTransaction,
|
|
18103
18136
|
isActive,
|
|
18104
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(BankTransactionReceipts, _objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$
|
|
18137
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(BankTransactionReceipts, _objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$47)), {}, { ref }))
|
|
18105
18138
|
});
|
|
18106
18139
|
});
|
|
18107
18140
|
BankTransactionReceiptsWithProvider.displayName = "BankTransactionReceiptsWithProvider";
|
|
@@ -18180,14 +18213,14 @@ const getCurrencyFormatConfig = (intl) => {
|
|
|
18180
18213
|
suffix: parts.slice(lastNumberIndex + 1).map((part) => part.value).join("")
|
|
18181
18214
|
};
|
|
18182
18215
|
};
|
|
18183
|
-
var _excluded$
|
|
18216
|
+
var _excluded$46 = [
|
|
18184
18217
|
"onChange",
|
|
18185
18218
|
"className",
|
|
18186
18219
|
"errorMessage",
|
|
18187
18220
|
"isInvalid"
|
|
18188
18221
|
];
|
|
18189
18222
|
const AmountInput = (_ref) => {
|
|
18190
|
-
let { onChange, className, errorMessage, isInvalid } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
18223
|
+
let { onChange, className, errorMessage, isInvalid } = _ref, props = _objectWithoutProperties(_ref, _excluded$46);
|
|
18191
18224
|
const intl = (0, react_intl.useIntl)();
|
|
18192
18225
|
const formatter = useIntlFormatter();
|
|
18193
18226
|
const currencyFormatConfig = (0, react.useMemo)(() => getCurrencyFormatConfig(intl), [intl]);
|
|
@@ -18827,14 +18860,14 @@ const BankTransactionsMobileListItemCheckbox = ({ bulkActionsEnabled, bankTransa
|
|
|
18827
18860
|
})
|
|
18828
18861
|
});
|
|
18829
18862
|
};
|
|
18830
|
-
var _excluded$
|
|
18863
|
+
var _excluded$45 = ["size"];
|
|
18831
18864
|
var Paperclip = (_ref) => {
|
|
18832
18865
|
let { size = 20 } = _ref;
|
|
18833
18866
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("svg", _objectSpread2(_objectSpread2({
|
|
18834
18867
|
xmlns: "http://www.w3.org/2000/svg",
|
|
18835
18868
|
viewBox: "0 0 20 20",
|
|
18836
18869
|
fill: "none"
|
|
18837
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
18870
|
+
}, _objectWithoutProperties(_ref, _excluded$45)), {}, {
|
|
18838
18871
|
width: size,
|
|
18839
18872
|
height: size,
|
|
18840
18873
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
@@ -19914,14 +19947,14 @@ const BankTransactionRow = ({ index, bankTransaction, initialLoad, showDescripti
|
|
|
19914
19947
|
})
|
|
19915
19948
|
}) })] });
|
|
19916
19949
|
};
|
|
19917
|
-
var _excluded$
|
|
19950
|
+
var _excluded$44 = ["size"];
|
|
19918
19951
|
var Inbox = (_ref) => {
|
|
19919
19952
|
let { size = 18 } = _ref;
|
|
19920
19953
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
19921
19954
|
xmlns: "http://www.w3.org/2000/svg",
|
|
19922
19955
|
viewBox: "0 0 18 18",
|
|
19923
19956
|
fill: "none"
|
|
19924
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
19957
|
+
}, _objectWithoutProperties(_ref, _excluded$44)), {}, {
|
|
19925
19958
|
width: size,
|
|
19926
19959
|
height: size,
|
|
19927
19960
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
@@ -20219,14 +20252,14 @@ function useArchiveCategorizationRule() {
|
|
|
20219
20252
|
return Reflect.get(target, prop);
|
|
20220
20253
|
} });
|
|
20221
20254
|
}
|
|
20222
|
-
var _excluded$
|
|
20255
|
+
var _excluded$43 = ["size"];
|
|
20223
20256
|
var BackArrow = (_ref) => {
|
|
20224
20257
|
let { size = 18 } = _ref;
|
|
20225
20258
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("svg", _objectSpread2(_objectSpread2({
|
|
20226
20259
|
viewBox: "0 0 12 12",
|
|
20227
20260
|
fill: "none",
|
|
20228
20261
|
xmlns: "http://www.w3.org/2000/svg"
|
|
20229
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
20262
|
+
}, _objectWithoutProperties(_ref, _excluded$43)), {}, {
|
|
20230
20263
|
width: size,
|
|
20231
20264
|
height: size,
|
|
20232
20265
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
@@ -20323,17 +20356,17 @@ var EMPTY_ARRAY$4 = [];
|
|
|
20323
20356
|
var isSelectionEnabled = (props) => props.selectionMode !== "none" && props.enableSelection;
|
|
20324
20357
|
var isGrouped = (data) => !!data && !Array.isArray(data);
|
|
20325
20358
|
const MobileList = ({ ariaLabel, data, slots, renderItem, onClickItem, isLoading, isError, variant = "default", enableSelection = false, selectionMode = "none", selectedKeys, onSelectionChange }) => {
|
|
20326
|
-
const { EmptyState: EmptyState$
|
|
20359
|
+
const { EmptyState: EmptyState$8, ErrorState: ErrorState$9 } = slots;
|
|
20327
20360
|
const resolvedSelectionMode = isSelectionEnabled({
|
|
20328
20361
|
enableSelection,
|
|
20329
20362
|
selectionMode
|
|
20330
20363
|
}) ? selectionMode : "none";
|
|
20331
20364
|
const resolvedSelectionBehavior = resolvedSelectionMode === "none" ? "toggle" : void 0;
|
|
20332
20365
|
const renderEmptyState = (0, react.useCallback)(() => {
|
|
20333
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(EmptyState$
|
|
20334
|
-
}, [EmptyState$
|
|
20366
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(EmptyState$8, {});
|
|
20367
|
+
}, [EmptyState$8]);
|
|
20335
20368
|
if (isLoading) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(MobileListSkeleton, { variant });
|
|
20336
|
-
if (isError) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ErrorState$
|
|
20369
|
+
if (isError) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ErrorState$9, {});
|
|
20337
20370
|
const renderRow = (item) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(MobileListItem, {
|
|
20338
20371
|
item,
|
|
20339
20372
|
onClickItem,
|
|
@@ -20388,9 +20421,9 @@ const usePaginationRange = ({ totalCount, pageSize, siblingCount = 1, currentPag
|
|
|
20388
20421
|
currentPage
|
|
20389
20422
|
]);
|
|
20390
20423
|
};
|
|
20391
|
-
var _excluded$
|
|
20424
|
+
var _excluded$42 = ["children", "isSelected"];
|
|
20392
20425
|
var PaginationButton = (_ref) => {
|
|
20393
|
-
let { children, isSelected } = _ref, buttonProps = _objectWithoutProperties(_ref, _excluded$
|
|
20426
|
+
let { children, isSelected } = _ref, buttonProps = _objectWithoutProperties(_ref, _excluded$42);
|
|
20394
20427
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button, _objectSpread2(_objectSpread2({
|
|
20395
20428
|
inset: true,
|
|
20396
20429
|
icon: true,
|
|
@@ -20457,11 +20490,11 @@ const Pagination = ({ onPageChange, totalCount, siblingCount = 1, currentPage, p
|
|
|
20457
20490
|
})
|
|
20458
20491
|
});
|
|
20459
20492
|
};
|
|
20460
|
-
var _excluded$
|
|
20493
|
+
var _excluded$41 = ["data", "paginationProps"];
|
|
20461
20494
|
var EMPTY_ARRAY$3 = [];
|
|
20462
20495
|
const PaginatedMobileList = (props) => {
|
|
20463
20496
|
var _data$length;
|
|
20464
|
-
const { data, paginationProps } = props, listProps = _objectWithoutProperties(props, _excluded$
|
|
20497
|
+
const { data, paginationProps } = props, listProps = _objectWithoutProperties(props, _excluded$41);
|
|
20465
20498
|
const { initialPage = 0, onSetPage, pageSize = 20, hasMore, fetchMore, autoResetPageIndexRef } = paginationProps;
|
|
20466
20499
|
const { pageItems, pageIndex, setPage } = usePaginatedList({
|
|
20467
20500
|
data: data !== null && data !== void 0 ? data : EMPTY_ARRAY$3,
|
|
@@ -20626,24 +20659,24 @@ const useColumnPinningStyles = (headerGroups) => {
|
|
|
20626
20659
|
};
|
|
20627
20660
|
const DataTable = ({ isLoading, isError, componentName, ariaLabel, slots, dependencies: dependencies$1, data, headerGroups, numColumns, withClickableRow }) => {
|
|
20628
20661
|
const nonAria = headerGroups.length > 1;
|
|
20629
|
-
const { EmptyState: EmptyState$
|
|
20662
|
+
const { EmptyState: EmptyState$8, ErrorState: ErrorState$9 } = slots;
|
|
20630
20663
|
const { headerRef, pinningStyles } = useColumnPinningStyles(headerGroups);
|
|
20631
20664
|
const isEmptyTable = (data === null || data === void 0 ? void 0 : data.length) === 0;
|
|
20632
20665
|
const renderTableBody = (0, react.useMemo)(() => {
|
|
20633
20666
|
if (isError) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Row, {
|
|
20634
20667
|
className: "Layer__DataTable__EmptyState__Row",
|
|
20635
20668
|
nonAria,
|
|
20636
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Cell, {
|
|
20669
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Cell$3, {
|
|
20637
20670
|
className: "Layer__DataTable__EmptyState__Cell",
|
|
20638
20671
|
colSpan: numColumns,
|
|
20639
20672
|
nonAria,
|
|
20640
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ErrorState$
|
|
20673
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ErrorState$9, {})
|
|
20641
20674
|
})
|
|
20642
20675
|
});
|
|
20643
20676
|
if (isLoading) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Row, {
|
|
20644
20677
|
className: "Layer__DataTable__EmptyState__Row",
|
|
20645
20678
|
nonAria,
|
|
20646
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Cell, {
|
|
20679
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Cell$3, {
|
|
20647
20680
|
className: "Layer__DataTable__EmptyState__Cell",
|
|
20648
20681
|
colSpan: numColumns,
|
|
20649
20682
|
nonAria,
|
|
@@ -20653,11 +20686,11 @@ const DataTable = ({ isLoading, isError, componentName, ariaLabel, slots, depend
|
|
|
20653
20686
|
if (isEmptyTable) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Row, {
|
|
20654
20687
|
className: "Layer__DataTable__EmptyState__Row",
|
|
20655
20688
|
nonAria,
|
|
20656
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Cell, {
|
|
20689
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Cell$3, {
|
|
20657
20690
|
className: "Layer__DataTable__EmptyState__Cell",
|
|
20658
20691
|
colSpan: numColumns,
|
|
20659
20692
|
nonAria,
|
|
20660
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(EmptyState$
|
|
20693
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(EmptyState$8, {})
|
|
20661
20694
|
})
|
|
20662
20695
|
});
|
|
20663
20696
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_jsx_runtime.Fragment, { children: data === null || data === void 0 ? void 0 : data.map((row) => {
|
|
@@ -20670,7 +20703,7 @@ const DataTable = ({ isLoading, isError, componentName, ariaLabel, slots, depend
|
|
|
20670
20703
|
className: isClickable ? "Layer__DataTable__ClickableRow" : void 0,
|
|
20671
20704
|
children: row.getVisibleCells().map((cell) => {
|
|
20672
20705
|
var _cell$column$columnDe;
|
|
20673
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Cell, {
|
|
20706
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Cell$3, {
|
|
20674
20707
|
className: `Layer__UI__Table-Cell__${componentName}--${cell.column.id}`,
|
|
20675
20708
|
alignment: (_cell$column$columnDe = cell.column.columnDef.meta) === null || _cell$column$columnDe === void 0 ? void 0 : _cell$column$columnDe.alignment,
|
|
20676
20709
|
pinned: cell.column.getIsPinned(),
|
|
@@ -20688,15 +20721,15 @@ const DataTable = ({ isLoading, isError, componentName, ariaLabel, slots, depend
|
|
|
20688
20721
|
data,
|
|
20689
20722
|
nonAria,
|
|
20690
20723
|
numColumns,
|
|
20691
|
-
ErrorState$
|
|
20692
|
-
EmptyState$
|
|
20724
|
+
ErrorState$9,
|
|
20725
|
+
EmptyState$8,
|
|
20693
20726
|
withClickableRow,
|
|
20694
20727
|
componentName,
|
|
20695
20728
|
pinningStyles
|
|
20696
20729
|
]);
|
|
20697
20730
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
20698
20731
|
className: "Layer__UI__Table-ScrollContainer",
|
|
20699
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table, {
|
|
20732
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table$1, {
|
|
20700
20733
|
"aria-label": ariaLabel,
|
|
20701
20734
|
className: `Layer__UI__Table__${componentName}`,
|
|
20702
20735
|
nonAria,
|
|
@@ -20719,7 +20752,7 @@ const DataTable = ({ isLoading, isError, componentName, ariaLabel, slots, depend
|
|
|
20719
20752
|
}, header.id);
|
|
20720
20753
|
})
|
|
20721
20754
|
}, headerGroup.id))
|
|
20722
|
-
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableBody, {
|
|
20755
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableBody$1, {
|
|
20723
20756
|
dependencies: dependencies$1,
|
|
20724
20757
|
nonAria,
|
|
20725
20758
|
children: renderTableBody
|
|
@@ -20780,7 +20813,7 @@ var CategorizationRuleColumns = /* @__PURE__ */ function(CategorizationRuleColum
|
|
|
20780
20813
|
CategorizationRuleColumns$1["Delete"] = "Delete";
|
|
20781
20814
|
return CategorizationRuleColumns$1;
|
|
20782
20815
|
}(CategorizationRuleColumns || {});
|
|
20783
|
-
var COMPONENT_NAME$
|
|
20816
|
+
var COMPONENT_NAME$14 = "CategorizationRulesTable";
|
|
20784
20817
|
const CategorizationRulesTable = ({ data, isLoading, isError, paginationProps, options, onDeleteRule, slots }) => {
|
|
20785
20818
|
const { t } = (0, react_i18next.useTranslation)();
|
|
20786
20819
|
const columnConfig = (0, react.useMemo)(() => [
|
|
@@ -20839,7 +20872,7 @@ const CategorizationRulesTable = ({ data, isLoading, isError, paginationProps, o
|
|
|
20839
20872
|
isError,
|
|
20840
20873
|
columnConfig,
|
|
20841
20874
|
paginationProps,
|
|
20842
|
-
componentName: COMPONENT_NAME$
|
|
20875
|
+
componentName: COMPONENT_NAME$14,
|
|
20843
20876
|
slots
|
|
20844
20877
|
});
|
|
20845
20878
|
};
|
|
@@ -21224,14 +21257,14 @@ function RuleUpdatesPromptStep({ ruleSuggestion, close, isDrawer }) {
|
|
|
21224
21257
|
function asMutable(a) {
|
|
21225
21258
|
return a;
|
|
21226
21259
|
}
|
|
21227
|
-
var COMPONENT_NAME$
|
|
21260
|
+
var COMPONENT_NAME$13 = "AffectedTransactionsTable";
|
|
21228
21261
|
var TransactionColumns = /* @__PURE__ */ function(TransactionColumns$1) {
|
|
21229
21262
|
TransactionColumns$1["Date"] = "Date";
|
|
21230
21263
|
TransactionColumns$1["Description"] = "Description";
|
|
21231
21264
|
TransactionColumns$1["Amount"] = "Amount";
|
|
21232
21265
|
return TransactionColumns$1;
|
|
21233
21266
|
}(TransactionColumns || {});
|
|
21234
|
-
var ErrorState$
|
|
21267
|
+
var ErrorState$7 = () => {
|
|
21235
21268
|
const { t } = (0, react_i18next.useTranslation)();
|
|
21236
21269
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(DataState, {
|
|
21237
21270
|
spacing: true,
|
|
@@ -21240,7 +21273,7 @@ var ErrorState$6 = () => {
|
|
|
21240
21273
|
description: t("categorizationRules:error.load_affected_transactions", "There was an error loading the affected transactions")
|
|
21241
21274
|
});
|
|
21242
21275
|
};
|
|
21243
|
-
var EmptyState$
|
|
21276
|
+
var EmptyState$6 = () => {
|
|
21244
21277
|
const { t } = (0, react_i18next.useTranslation)();
|
|
21245
21278
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(DataState, {
|
|
21246
21279
|
spacing: true,
|
|
@@ -21285,7 +21318,7 @@ const AffectedTransactionsTable = ({ transactions, isLoading = false, isError =
|
|
|
21285
21318
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(VStack, {
|
|
21286
21319
|
className: "Layer__AffectedTransactionsTable",
|
|
21287
21320
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(VirtualizedDataTable, {
|
|
21288
|
-
componentName: COMPONENT_NAME$
|
|
21321
|
+
componentName: COMPONENT_NAME$13,
|
|
21289
21322
|
ariaLabel: t("bankTransactions:label.affected_transactions", "Affected transactions"),
|
|
21290
21323
|
columnConfig,
|
|
21291
21324
|
data: transactions,
|
|
@@ -21294,8 +21327,8 @@ const AffectedTransactionsTable = ({ transactions, isLoading = false, isError =
|
|
|
21294
21327
|
height: 500,
|
|
21295
21328
|
shrinkHeightToFitRows: true,
|
|
21296
21329
|
slots: {
|
|
21297
|
-
EmptyState: EmptyState$
|
|
21298
|
-
ErrorState: ErrorState$
|
|
21330
|
+
EmptyState: EmptyState$6,
|
|
21331
|
+
ErrorState: ErrorState$7
|
|
21299
21332
|
}
|
|
21300
21333
|
})
|
|
21301
21334
|
});
|
|
@@ -21425,7 +21458,7 @@ const SuggestedCategorizationRuleUpdatesDialog = ({ isOpen, onOpenChange, ruleSu
|
|
|
21425
21458
|
})] })
|
|
21426
21459
|
});
|
|
21427
21460
|
};
|
|
21428
|
-
var _excluded$
|
|
21461
|
+
var _excluded$40 = [
|
|
21429
21462
|
"onError",
|
|
21430
21463
|
"showTags",
|
|
21431
21464
|
"showCustomerVendor",
|
|
@@ -21435,9 +21468,9 @@ var _excluded$39 = [
|
|
|
21435
21468
|
"renderInAppLink",
|
|
21436
21469
|
"filters"
|
|
21437
21470
|
];
|
|
21438
|
-
var COMPONENT_NAME$
|
|
21471
|
+
var COMPONENT_NAME$12 = "bank-transactions";
|
|
21439
21472
|
const BankTransactions = (_ref) => {
|
|
21440
|
-
let { onError, showTags = false, showCustomerVendor = false, monthlyView = false, applyGlobalDateRange = false, mode, renderInAppLink, filters } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
21473
|
+
let { onError, showTags = false, showCustomerVendor = false, monthlyView = false, applyGlobalDateRange = false, mode, renderInAppLink, filters } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$40);
|
|
21441
21474
|
usePreloadTagDimensions({ isEnabled: showTags });
|
|
21442
21475
|
usePreloadCustomers({ isEnabled: showCustomerVendor });
|
|
21443
21476
|
usePreloadVendors({ isEnabled: showCustomerVendor });
|
|
@@ -21612,7 +21645,7 @@ var BankTransactionsTableView = ({ asWidget = false, pageSize = 20, showDescript
|
|
|
21612
21645
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Container, {
|
|
21613
21646
|
className: (0, classnames.default)("Layer__Public", display === DisplayState.review ? "Layer__bank-transactions--to-review" : "Layer__bank-transactions--categorized"),
|
|
21614
21647
|
transparentBg: listView && mobileComponent === "mobileList",
|
|
21615
|
-
name: COMPONENT_NAME$
|
|
21648
|
+
name: COMPONENT_NAME$12,
|
|
21616
21649
|
asWidget,
|
|
21617
21650
|
ref: containerRef,
|
|
21618
21651
|
children: [
|
|
@@ -21743,9 +21776,9 @@ function QuickbooksContextProvider({ children }) {
|
|
|
21743
21776
|
children
|
|
21744
21777
|
});
|
|
21745
21778
|
}
|
|
21746
|
-
var _excluded$
|
|
21779
|
+
var _excluded$39 = ["size"];
|
|
21747
21780
|
var Cog = (_ref) => {
|
|
21748
|
-
let { size = 12 } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
21781
|
+
let { size = 12 } = _ref, props = _objectWithoutProperties(_ref, _excluded$39);
|
|
21749
21782
|
const id = (0, react.useId)();
|
|
21750
21783
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
21751
21784
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -21776,9 +21809,9 @@ var Cog = (_ref) => {
|
|
|
21776
21809
|
}) })] }));
|
|
21777
21810
|
};
|
|
21778
21811
|
var Cog_default = Cog;
|
|
21779
|
-
var _excluded$
|
|
21812
|
+
var _excluded$38 = ["size"];
|
|
21780
21813
|
var QuickbooksIcon = (_ref) => {
|
|
21781
|
-
let { size = 24 } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
21814
|
+
let { size = 24 } = _ref, props = _objectWithoutProperties(_ref, _excluded$38);
|
|
21782
21815
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
21783
21816
|
xmlns: "http://www.w3.org/2000/svg",
|
|
21784
21817
|
viewBox: "0 0 24 24",
|
|
@@ -21965,14 +21998,14 @@ function IntegrationsQuickbooksUnlinkConfirmationModal({ isOpen, onOpenChange })
|
|
|
21965
21998
|
errorText: t("integrations:error.unlink_failed", "Unlink failed. Please check your connection and try again in a few seconds.")
|
|
21966
21999
|
});
|
|
21967
22000
|
}
|
|
21968
|
-
var _excluded$
|
|
22001
|
+
var _excluded$37 = ["size"];
|
|
21969
22002
|
var MoreVertical = (_ref) => {
|
|
21970
22003
|
let { size = 18 } = _ref;
|
|
21971
22004
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
21972
22005
|
viewBox: "0 0 16 14",
|
|
21973
22006
|
fill: "none",
|
|
21974
22007
|
xmlns: "http://www.w3.org/2000/svg"
|
|
21975
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
22008
|
+
}, _objectWithoutProperties(_ref, _excluded$37)), {}, {
|
|
21976
22009
|
width: size,
|
|
21977
22010
|
height: size,
|
|
21978
22011
|
children: [
|
|
@@ -22055,7 +22088,7 @@ const LinkedAccountOptions = ({ children, config, showLedgerBalance }) => {
|
|
|
22055
22088
|
}), children]
|
|
22056
22089
|
});
|
|
22057
22090
|
};
|
|
22058
|
-
var getBadgeConfig = (quickbooksUiState, hasSynced) => {
|
|
22091
|
+
var getBadgeConfig$1 = (quickbooksUiState, hasSynced) => {
|
|
22059
22092
|
if (!hasSynced) return _objectSpread2({
|
|
22060
22093
|
variant: BadgeVariant.INFO,
|
|
22061
22094
|
icon: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(RefreshCcw_default, { size: 12 })
|
|
@@ -22096,7 +22129,7 @@ const IntegrationsQuickbooksItemThumb = () => {
|
|
|
22096
22129
|
}, [t]);
|
|
22097
22130
|
if (!quickbooksConnectionStatus) return null;
|
|
22098
22131
|
const quickbooksUiState = getQuickbooksConnectionSyncUiState(quickbooksConnectionStatus);
|
|
22099
|
-
const badgeConfig = getBadgeConfig(quickbooksUiState, hasSynced);
|
|
22132
|
+
const badgeConfig = getBadgeConfig$1(quickbooksUiState, hasSynced);
|
|
22100
22133
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(LinkedAccountOptions, {
|
|
22101
22134
|
config: menuConfig,
|
|
22102
22135
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Card, {
|
|
@@ -22135,7 +22168,7 @@ const IntegrationsContent = () => {
|
|
|
22135
22168
|
children: (quickbooksConnectionStatus === null || quickbooksConnectionStatus === void 0 ? void 0 : quickbooksConnectionStatus.is_connected) && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(IntegrationsQuickbooksItemThumb, {})
|
|
22136
22169
|
});
|
|
22137
22170
|
};
|
|
22138
|
-
var COMPONENT_NAME$
|
|
22171
|
+
var COMPONENT_NAME$11 = "integrations";
|
|
22139
22172
|
const Integrations = (props) => {
|
|
22140
22173
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(QuickbooksContextProvider, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(IntegrationsComponent, _objectSpread2({}, props)) });
|
|
22141
22174
|
};
|
|
@@ -22144,7 +22177,7 @@ const IntegrationsComponent = ({ stringOverrides }) => {
|
|
|
22144
22177
|
const { quickbooksConnectionStatus } = (0, react.useContext)(QuickbooksContext);
|
|
22145
22178
|
const isLoading = quickbooksConnectionStatus === void 0;
|
|
22146
22179
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Container, {
|
|
22147
|
-
name: COMPONENT_NAME$
|
|
22180
|
+
name: COMPONENT_NAME$11,
|
|
22148
22181
|
children: [
|
|
22149
22182
|
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Header$3, {
|
|
22150
22183
|
className: "Layer__linked-accounts__header",
|
|
@@ -22166,14 +22199,14 @@ const IntegrationsComponent = ({ stringOverrides }) => {
|
|
|
22166
22199
|
]
|
|
22167
22200
|
});
|
|
22168
22201
|
};
|
|
22169
|
-
var _excluded$
|
|
22202
|
+
var _excluded$36 = ["size"];
|
|
22170
22203
|
var PlusIcon = (_ref) => {
|
|
22171
22204
|
let { size = 14 } = _ref;
|
|
22172
22205
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
22173
22206
|
xmlns: "http://www.w3.org/2000/svg",
|
|
22174
22207
|
viewBox: "0 0 16 16",
|
|
22175
22208
|
fill: "none"
|
|
22176
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
22209
|
+
}, _objectWithoutProperties(_ref, _excluded$36)), {}, {
|
|
22177
22210
|
width: size,
|
|
22178
22211
|
height: size,
|
|
22179
22212
|
children: [
|
|
@@ -22248,14 +22281,14 @@ function useConfirmAndExcludeMultiple({ onSuccess }) {
|
|
|
22248
22281
|
throwOnError: false
|
|
22249
22282
|
});
|
|
22250
22283
|
}
|
|
22251
|
-
var _excluded$
|
|
22284
|
+
var _excluded$35 = ["size"];
|
|
22252
22285
|
var InstitutionIcon = (_ref) => {
|
|
22253
22286
|
let { size = 18 } = _ref;
|
|
22254
22287
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
22255
22288
|
viewBox: "0 0 27 28",
|
|
22256
22289
|
fill: "none",
|
|
22257
22290
|
xmlns: "http://www.w3.org/2000/svg"
|
|
22258
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
22291
|
+
}, _objectWithoutProperties(_ref, _excluded$35)), {}, {
|
|
22259
22292
|
width: size,
|
|
22260
22293
|
height: size,
|
|
22261
22294
|
children: [
|
|
@@ -22781,10 +22814,10 @@ const MenuItem$1 = (0, react.forwardRef)(function MenuItem$2({ children, textVal
|
|
|
22781
22814
|
children
|
|
22782
22815
|
});
|
|
22783
22816
|
});
|
|
22784
|
-
var _excluded$
|
|
22817
|
+
var _excluded$34 = ["children", "status"];
|
|
22785
22818
|
var PILL_CLASS_NAME = "Layer__Pill";
|
|
22786
22819
|
const Pill = (0, react.forwardRef)(function Pill$1(_ref, ref) {
|
|
22787
|
-
let { children, status } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
22820
|
+
let { children, status } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$34);
|
|
22788
22821
|
const dataProperties = toDataProperties({ status });
|
|
22789
22822
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.Button, _objectSpread2(_objectSpread2(_objectSpread2({}, restProps), dataProperties), {}, {
|
|
22790
22823
|
className: PILL_CLASS_NAME,
|
|
@@ -23463,7 +23496,7 @@ function OpeningBalanceModal({ stringOverrides }) {
|
|
|
23463
23496
|
})
|
|
23464
23497
|
});
|
|
23465
23498
|
}
|
|
23466
|
-
var COMPONENT_NAME$
|
|
23499
|
+
var COMPONENT_NAME$10 = "linked-accounts";
|
|
23467
23500
|
const LinkedAccounts = (props) => {
|
|
23468
23501
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(AccountConfirmationStoreProvider, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LinkedAccountsProvider, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LinkedAccountsComponent, _objectSpread2({}, props)) }) });
|
|
23469
23502
|
};
|
|
@@ -23471,7 +23504,7 @@ const LinkedAccountsComponent = ({ asWidget, elevated = false, showLedgerBalance
|
|
|
23471
23504
|
const { t } = (0, react_i18next.useTranslation)();
|
|
23472
23505
|
const { isLoading, error: error$38, isValidating, refetchAccounts } = (0, react.useContext)(LinkedAccountsContext);
|
|
23473
23506
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Container, {
|
|
23474
|
-
name: COMPONENT_NAME$
|
|
23507
|
+
name: COMPONENT_NAME$10,
|
|
23475
23508
|
elevated,
|
|
23476
23509
|
children: [
|
|
23477
23510
|
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Header$3, {
|
|
@@ -23942,7 +23975,7 @@ const useProfitAndLossLTM = ({ tagFilter, reportingBasis, chartWindow }) => {
|
|
|
23942
23975
|
isError
|
|
23943
23976
|
};
|
|
23944
23977
|
};
|
|
23945
|
-
var _excluded$
|
|
23978
|
+
var _excluded$33 = [
|
|
23946
23979
|
"verticalAnchor",
|
|
23947
23980
|
"visibleTicksCount",
|
|
23948
23981
|
"tickFormatter",
|
|
@@ -23951,7 +23984,7 @@ var _excluded$32 = [
|
|
|
23951
23984
|
], _excluded2$4 = ["format"];
|
|
23952
23985
|
var CustomizedYTick = (_ref) => {
|
|
23953
23986
|
let { verticalAnchor: _verticalAnchor, visibleTicksCount: _visibleTicksCount, tickFormatter: _tickFormatter, format: format$1, payload } = _ref;
|
|
23954
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("text", _objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$
|
|
23987
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("text", _objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$33)), {}, {
|
|
23955
23988
|
className: "Layer__ChartYAxis__tick",
|
|
23956
23989
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("tspan", {
|
|
23957
23990
|
dy: "0.355em",
|
|
@@ -24128,7 +24161,7 @@ const ProfitAndLossChartSelectionIndicator = ({ viewBox, selected }) => {
|
|
|
24128
24161
|
height: "calc(100% - 30px)"
|
|
24129
24162
|
});
|
|
24130
24163
|
};
|
|
24131
|
-
var _excluded$
|
|
24164
|
+
var _excluded$32 = ["payload", "fill"];
|
|
24132
24165
|
var BAR_RADIUS$1 = [
|
|
24133
24166
|
2,
|
|
24134
24167
|
2,
|
|
@@ -24148,7 +24181,7 @@ const ProfitAndLossChartBar = ({ dataKey, xAxisId, cellFill, className, barSize,
|
|
|
24148
24181
|
isAnimationActive: barAnimation,
|
|
24149
24182
|
fill: cellFill,
|
|
24150
24183
|
shape: (0, react.useCallback)((props) => {
|
|
24151
|
-
const { payload, fill } = props, restProps = _objectWithoutProperties(props, _excluded$
|
|
24184
|
+
const { payload, fill } = props, restProps = _objectWithoutProperties(props, _excluded$32);
|
|
24152
24185
|
const shouldRound = payload && isOutermostBar(payload, dataKey, xAxisId);
|
|
24153
24186
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(recharts.Rectangle, _objectSpread2(_objectSpread2({}, restProps), {}, {
|
|
24154
24187
|
fill,
|
|
@@ -24210,14 +24243,14 @@ const ProfitAndLossChartLegend = () => {
|
|
|
24210
24243
|
})), [t]))
|
|
24211
24244
|
});
|
|
24212
24245
|
};
|
|
24213
|
-
var _excluded$
|
|
24246
|
+
var _excluded$31 = ["size"];
|
|
24214
24247
|
var BarChart2 = (_ref) => {
|
|
24215
24248
|
let { size = 12 } = _ref;
|
|
24216
24249
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
24217
24250
|
xmlns: "http://www.w3.org/2000/svg",
|
|
24218
24251
|
viewBox: "0 0 12 12",
|
|
24219
24252
|
fill: "none"
|
|
24220
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
24253
|
+
}, _objectWithoutProperties(_ref, _excluded$31)), {}, {
|
|
24221
24254
|
width: size,
|
|
24222
24255
|
height: size,
|
|
24223
24256
|
children: [
|
|
@@ -24260,7 +24293,7 @@ const ProfitAndLossChartStateCard = () => {
|
|
|
24260
24293
|
})]
|
|
24261
24294
|
});
|
|
24262
24295
|
};
|
|
24263
|
-
var _excluded$
|
|
24296
|
+
var _excluded$30 = [
|
|
24264
24297
|
"content",
|
|
24265
24298
|
"cursorWidth",
|
|
24266
24299
|
"animationDuration",
|
|
@@ -24296,7 +24329,7 @@ const ChartTooltipCursor = ({ width, points, height }) => {
|
|
|
24296
24329
|
});
|
|
24297
24330
|
};
|
|
24298
24331
|
const ChartTooltip = (_ref) => {
|
|
24299
|
-
let { content, cursorWidth, animationDuration = 100, animationEasing = "ease-out" } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
24332
|
+
let { content, cursorWidth, animationDuration = 100, animationEasing = "ease-out" } = _ref, props = _objectWithoutProperties(_ref, _excluded$30);
|
|
24300
24333
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(recharts.Tooltip, _objectSpread2({
|
|
24301
24334
|
wrapperClassName: "Layer__ChartTooltip__wrapper",
|
|
24302
24335
|
content,
|
|
@@ -24557,9 +24590,9 @@ const ProfitAndLossChart = ({ tagFilter }) => {
|
|
|
24557
24590
|
}, "pnl-chart"), isSyncing ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ProfitAndLossChartStateCard, {}) : null]
|
|
24558
24591
|
});
|
|
24559
24592
|
};
|
|
24560
|
-
var _excluded$
|
|
24593
|
+
var _excluded$29 = ["className", "textOnly"];
|
|
24561
24594
|
const BackButton = (_ref) => {
|
|
24562
|
-
let { className, textOnly = false } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
24595
|
+
let { className, textOnly = false } = _ref, props = _objectWithoutProperties(_ref, _excluded$29);
|
|
24563
24596
|
const baseClassName$1 = (0, classnames.default)("Layer__btn", "Layer__back-btn", className);
|
|
24564
24597
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", _objectSpread2(_objectSpread2({}, props), {}, {
|
|
24565
24598
|
className: baseClassName$1,
|
|
@@ -24733,7 +24766,7 @@ const DetailedChart = ({ data, isLoading, interactionProps, stylingProps, slots
|
|
|
24733
24766
|
})]
|
|
24734
24767
|
});
|
|
24735
24768
|
};
|
|
24736
|
-
var _excluded$
|
|
24769
|
+
var _excluded$28 = ["size"];
|
|
24737
24770
|
var ClassNames = {
|
|
24738
24771
|
DESC_ARROW: "Layer__SortArrows__DescArrow",
|
|
24739
24772
|
ASC_ARROW: "Layer__SortArrows__AscArrow"
|
|
@@ -24744,7 +24777,7 @@ var SortArrows = (_ref) => {
|
|
|
24744
24777
|
xmlns: "http://www.w3.org/2000/svg",
|
|
24745
24778
|
viewBox: "0 0 12 13",
|
|
24746
24779
|
fill: "none"
|
|
24747
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
24780
|
+
}, _objectWithoutProperties(_ref, _excluded$28)), {}, {
|
|
24748
24781
|
width: size,
|
|
24749
24782
|
height: size,
|
|
24750
24783
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("g", {
|
|
@@ -24882,7 +24915,7 @@ var RegularValueIcon = ({ colorMapping }) => {
|
|
|
24882
24915
|
})
|
|
24883
24916
|
});
|
|
24884
24917
|
};
|
|
24885
|
-
var _excluded$
|
|
24918
|
+
var _excluded$27 = ["data"];
|
|
24886
24919
|
const DetailedTable = ({ stylingProps, sortParams, sortFunction, interactionProps, rows, stringOverrides }) => {
|
|
24887
24920
|
const { t } = (0, react_i18next.useTranslation)();
|
|
24888
24921
|
const setAndToggleSortDirection = (params) => {
|
|
@@ -25013,7 +25046,7 @@ const DetailedTable = ({ stylingProps, sortParams, sortFunction, interactionProp
|
|
|
25013
25046
|
});
|
|
25014
25047
|
};
|
|
25015
25048
|
const DetailedTableWithData = (_ref) => {
|
|
25016
|
-
let { data } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
25049
|
+
let { data } = _ref, props = _objectWithoutProperties(_ref, _excluded$27);
|
|
25017
25050
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(DetailedTable, _objectSpread2({ rows: useDetailedTableRows({ data }) }, props));
|
|
25018
25051
|
};
|
|
25019
25052
|
function useGlobalDatePickerBounds() {
|
|
@@ -25167,9 +25200,9 @@ const LedgerAccountsContext = (0, react.createContext)({
|
|
|
25167
25200
|
hasMore: false,
|
|
25168
25201
|
fetchMore: () => {}
|
|
25169
25202
|
});
|
|
25170
|
-
var _excluded$
|
|
25203
|
+
var _excluded$26 = ["className", "textOnly"];
|
|
25171
25204
|
const CloseButton = (_ref) => {
|
|
25172
|
-
let { className, textOnly = false } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
25205
|
+
let { className, textOnly = false } = _ref, props = _objectWithoutProperties(_ref, _excluded$26);
|
|
25173
25206
|
const baseClassName$1 = (0, classnames.default)("Layer__btn", "Layer__back-btn", className);
|
|
25174
25207
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", _objectSpread2(_objectSpread2({}, props), {}, {
|
|
25175
25208
|
className: baseClassName$1,
|
|
@@ -25199,7 +25232,7 @@ const HeaderRow = ({ className, children, direction, style: style$1 }) => {
|
|
|
25199
25232
|
children
|
|
25200
25233
|
}));
|
|
25201
25234
|
};
|
|
25202
|
-
const Table
|
|
25235
|
+
const Table = ({ componentName, children, borderCollapse = "separate", bottomSpacing = true }) => {
|
|
25203
25236
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
25204
25237
|
className: (0, classnames.default)("Layer__table-wrapper", bottomSpacing && "Layer__table-wrapper--bottom-spacing"),
|
|
25205
25238
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("table", {
|
|
@@ -25208,7 +25241,7 @@ const Table$1 = ({ componentName, children, borderCollapse = "separate", bottomS
|
|
|
25208
25241
|
})
|
|
25209
25242
|
});
|
|
25210
25243
|
};
|
|
25211
|
-
const TableBody
|
|
25244
|
+
const TableBody = ({ children }) => {
|
|
25212
25245
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("tbody", {
|
|
25213
25246
|
className: "Layer__table-body",
|
|
25214
25247
|
children
|
|
@@ -25583,7 +25616,7 @@ const LedgerAccountEntryDetails = ({ stringOverrides }) => {
|
|
|
25583
25616
|
}),
|
|
25584
25617
|
!isLoadingEntry && !isErrorEntry ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
25585
25618
|
className: "Layer__ledger-account__entry-details__line-items",
|
|
25586
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Card, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table
|
|
25619
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Card, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table, {
|
|
25587
25620
|
componentName: "ledger-account__entry-details",
|
|
25588
25621
|
borderCollapse: "collapse",
|
|
25589
25622
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableHead, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableRow, {
|
|
@@ -25600,7 +25633,7 @@ const LedgerAccountEntryDetails = ({ stringOverrides }) => {
|
|
|
25600
25633
|
children: (stringOverrides === null || stringOverrides === void 0 || (_stringOverrides$line3 = stringOverrides.lineItemsTable) === null || _stringOverrides$line3 === void 0 ? void 0 : _stringOverrides$line3.creditColumnHeader) || t("common:label.credit", "Credit")
|
|
25601
25634
|
})
|
|
25602
25635
|
]
|
|
25603
|
-
}) }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableBody
|
|
25636
|
+
}) }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableBody, { children: [entryData === null || entryData === void 0 || (_entryData$line_items2 = entryData.line_items) === null || _entryData$line_items2 === void 0 ? void 0 : _entryData$line_items2.map((item, index) => {
|
|
25604
25637
|
var _item$account;
|
|
25605
25638
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableRow, {
|
|
25606
25639
|
rowKey: `ledger-line-item-${index}`,
|
|
@@ -25649,7 +25682,7 @@ const LedgerAccountEntryDetails = ({ stringOverrides }) => {
|
|
|
25649
25682
|
]
|
|
25650
25683
|
});
|
|
25651
25684
|
};
|
|
25652
|
-
var COMPONENT_NAME$
|
|
25685
|
+
var COMPONENT_NAME$9 = "ProfitAndLossDetailReport";
|
|
25653
25686
|
var PnlDetailColumns = /* @__PURE__ */ function(PnlDetailColumns$1) {
|
|
25654
25687
|
PnlDetailColumns$1["Date"] = "Date";
|
|
25655
25688
|
PnlDetailColumns$1["Type"] = "Type";
|
|
@@ -25659,7 +25692,7 @@ var PnlDetailColumns = /* @__PURE__ */ function(PnlDetailColumns$1) {
|
|
|
25659
25692
|
PnlDetailColumns$1["Balance"] = "Balance";
|
|
25660
25693
|
return PnlDetailColumns$1;
|
|
25661
25694
|
}(PnlDetailColumns || {});
|
|
25662
|
-
var ErrorState$
|
|
25695
|
+
var ErrorState$6 = () => {
|
|
25663
25696
|
const { t } = (0, react_i18next.useTranslation)();
|
|
25664
25697
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(DataState, {
|
|
25665
25698
|
spacing: true,
|
|
@@ -25668,7 +25701,7 @@ var ErrorState$5 = () => {
|
|
|
25668
25701
|
description: t("reports:error.load_pnl_detail_lines", "There was an error loading the profit and loss detail lines")
|
|
25669
25702
|
});
|
|
25670
25703
|
};
|
|
25671
|
-
var EmptyState$
|
|
25704
|
+
var EmptyState$5 = () => {
|
|
25672
25705
|
const { t } = (0, react_i18next.useTranslation)();
|
|
25673
25706
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(DataState, {
|
|
25674
25707
|
spacing: true,
|
|
@@ -25833,7 +25866,7 @@ const ProfitAndLossDetailReport = ({ lineItemName, breadcrumbPath, onClose, onBr
|
|
|
25833
25866
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(VStack, {
|
|
25834
25867
|
className: "Layer__ProfitAndLossDetailReport",
|
|
25835
25868
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(VirtualizedDataTable, {
|
|
25836
|
-
componentName: COMPONENT_NAME$
|
|
25869
|
+
componentName: COMPONENT_NAME$9,
|
|
25837
25870
|
ariaLabel: t("reports:label.line_item_name_detail_lines", "{{lineItemName}} detail lines", { lineItemName }),
|
|
25838
25871
|
columnConfig,
|
|
25839
25872
|
data: rowsWithRunningBalance.lines,
|
|
@@ -25841,8 +25874,8 @@ const ProfitAndLossDetailReport = ({ lineItemName, breadcrumbPath, onClose, onBr
|
|
|
25841
25874
|
isError,
|
|
25842
25875
|
shrinkHeightToFitRows: true,
|
|
25843
25876
|
slots: {
|
|
25844
|
-
EmptyState: EmptyState$
|
|
25845
|
-
ErrorState: ErrorState$
|
|
25877
|
+
EmptyState: EmptyState$5,
|
|
25878
|
+
ErrorState: ErrorState$6
|
|
25846
25879
|
}
|
|
25847
25880
|
}), rowsWithRunningBalance.lines.length > 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(HStack, {
|
|
25848
25881
|
pb: "sm",
|
|
@@ -25954,7 +25987,7 @@ const usePnlDetailedTableRows = ({ data }) => {
|
|
|
25954
25987
|
isDisabled: (item) => UNCATEGORIZED_TYPES.includes(item.name)
|
|
25955
25988
|
});
|
|
25956
25989
|
};
|
|
25957
|
-
var EmptyState$
|
|
25990
|
+
var EmptyState$4 = () => {
|
|
25958
25991
|
const { t } = (0, react_i18next.useTranslation)();
|
|
25959
25992
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
25960
25993
|
className: "Layer__profit-and-loss-detailed-charts__empty-chart",
|
|
@@ -26095,7 +26128,7 @@ const ProfitAndLossDetailedCharts = ({ scope, hideClose = false, showDatePicker
|
|
|
26095
26128
|
}),
|
|
26096
26129
|
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
26097
26130
|
className: "Layer__profit-and-loss-detailed-charts__content",
|
|
26098
|
-
children: isEmpty ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(EmptyState$
|
|
26131
|
+
children: isEmpty ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(EmptyState$4, {}) : /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(DetailedChart, {
|
|
26099
26132
|
data: chartDataWithTotal,
|
|
26100
26133
|
slots: { Header: showDatePicker ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(DetailedChartsDatePickerHeader, {}) : void 0 },
|
|
26101
26134
|
interactionProps: chartInteractionProps,
|
|
@@ -26828,7 +26861,7 @@ const ReportsTableLoader = ({ typeColumnHeader, totalColumnHeader, showHeader =
|
|
|
26828
26861
|
const { t } = (0, react_i18next.useTranslation)();
|
|
26829
26862
|
const typeColumnHeaderText = typeColumnHeader !== null && typeColumnHeader !== void 0 ? typeColumnHeader : t("common:label.type", "Type");
|
|
26830
26863
|
const totalColumnHeaderText = totalColumnHeader !== null && totalColumnHeader !== void 0 ? totalColumnHeader : t("common:label.total", "Total");
|
|
26831
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table
|
|
26864
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table, {
|
|
26832
26865
|
borderCollapse: "collapse",
|
|
26833
26866
|
children: [showHeader && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableHead, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableRow, {
|
|
26834
26867
|
rowKey: "report-table-loader-header",
|
|
@@ -26941,7 +26974,7 @@ const ProfitAndLossCompareTable = ({ stringOverrides }) => {
|
|
|
26941
26974
|
isError,
|
|
26942
26975
|
Loading: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ReportsTableLoader, { showHeader: false }),
|
|
26943
26976
|
Error: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ReportsTableErrorState, { isLoading: isValidating }),
|
|
26944
|
-
children: ({ data: resolvedComparisonData }) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table
|
|
26977
|
+
children: ({ data: resolvedComparisonData }) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table, {
|
|
26945
26978
|
borderCollapse: "collapse",
|
|
26946
26979
|
bottomSpacing: false,
|
|
26947
26980
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableHead, { children: selectedCompareOptions && selectedCompareOptions.length > 1 && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableRow, {
|
|
@@ -26954,7 +26987,7 @@ const ProfitAndLossCompareTable = ({ stringOverrides }) => {
|
|
|
26954
26987
|
isHeaderCell: true,
|
|
26955
26988
|
children: option.displayName
|
|
26956
26989
|
}, option.displayName + "-" + i), comparePeriods && Array.from({ length: comparePeriods - 1 }, (_, index) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableCell, { isHeaderCell: true }, option.displayName + "-" + index))] }, option.displayName + "-" + i))]
|
|
26957
|
-
}) }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableBody
|
|
26990
|
+
}) }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableBody, { children: [
|
|
26958
26991
|
comparePeriods && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableRow, {
|
|
26959
26992
|
rowKey: "",
|
|
26960
26993
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableCell, {
|
|
@@ -27108,10 +27141,10 @@ const ProfitAndLossTableComponent = ({ stringOverrides, onLineItemClick }) => {
|
|
|
27108
27141
|
Loading: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ReportsTableLoader, { showHeader: false }),
|
|
27109
27142
|
Inactive: null,
|
|
27110
27143
|
Error: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ReportsTableErrorState, { isLoading: isValidating }),
|
|
27111
|
-
children: ({ data: data$1 }) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Table
|
|
27144
|
+
children: ({ data: data$1 }) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Table, {
|
|
27112
27145
|
borderCollapse: "collapse",
|
|
27113
27146
|
bottomSpacing: false,
|
|
27114
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableBody
|
|
27147
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableBody, { children: [
|
|
27115
27148
|
renderLineItem({
|
|
27116
27149
|
lineItem: data$1.income,
|
|
27117
27150
|
depth: 0,
|
|
@@ -27220,7 +27253,7 @@ const filterOptionsOrGroups = (source, query) => {
|
|
|
27220
27253
|
}
|
|
27221
27254
|
return { options: [] };
|
|
27222
27255
|
};
|
|
27223
|
-
var _excluded$
|
|
27256
|
+
var _excluded$25 = [
|
|
27224
27257
|
"ariaLabel",
|
|
27225
27258
|
"selectedValue",
|
|
27226
27259
|
"onSelectedValueChange",
|
|
@@ -27231,14 +27264,14 @@ var wrap = (option) => ({
|
|
|
27231
27264
|
id: option.value,
|
|
27232
27265
|
option
|
|
27233
27266
|
});
|
|
27234
|
-
var EmptyState$
|
|
27267
|
+
var EmptyState$3 = () => {
|
|
27235
27268
|
const { t } = (0, react_i18next.useTranslation)();
|
|
27236
27269
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
27237
27270
|
size: "sm",
|
|
27238
27271
|
children: t("common:empty.results", "No results found")
|
|
27239
27272
|
});
|
|
27240
27273
|
};
|
|
27241
|
-
var ErrorState$
|
|
27274
|
+
var ErrorState$5 = () => {
|
|
27242
27275
|
const { t } = (0, react_i18next.useTranslation)();
|
|
27243
27276
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
27244
27277
|
size: "sm",
|
|
@@ -27247,7 +27280,7 @@ var ErrorState$4 = () => {
|
|
|
27247
27280
|
};
|
|
27248
27281
|
const MobileSelectionDrawerList = (_ref) => {
|
|
27249
27282
|
let { ariaLabel, selectedValue, onSelectedValueChange, isLoading = false, isError = false } = _ref;
|
|
27250
|
-
const source = _objectWithoutProperties(_ref, _excluded$
|
|
27283
|
+
const source = _objectWithoutProperties(_ref, _excluded$25);
|
|
27251
27284
|
const data = (0, react.useMemo)(() => {
|
|
27252
27285
|
if (source.groups) return { groups: source.groups.map((group) => ({
|
|
27253
27286
|
label: group.label,
|
|
@@ -27280,8 +27313,8 @@ const MobileSelectionDrawerList = (_ref) => {
|
|
|
27280
27313
|
ariaLabel,
|
|
27281
27314
|
data,
|
|
27282
27315
|
slots: {
|
|
27283
|
-
EmptyState: EmptyState$
|
|
27284
|
-
ErrorState: ErrorState$
|
|
27316
|
+
EmptyState: EmptyState$3,
|
|
27317
|
+
ErrorState: ErrorState$5
|
|
27285
27318
|
},
|
|
27286
27319
|
renderItem,
|
|
27287
27320
|
onClickItem,
|
|
@@ -27290,7 +27323,7 @@ const MobileSelectionDrawerList = (_ref) => {
|
|
|
27290
27323
|
variant: "compact"
|
|
27291
27324
|
});
|
|
27292
27325
|
};
|
|
27293
|
-
var _excluded$
|
|
27326
|
+
var _excluded$24 = [
|
|
27294
27327
|
"ariaLabel",
|
|
27295
27328
|
"heading",
|
|
27296
27329
|
"selectedValue",
|
|
@@ -27304,7 +27337,7 @@ var _excluded$23 = [
|
|
|
27304
27337
|
];
|
|
27305
27338
|
const MobileSelectionDrawerWithTrigger = (_ref) => {
|
|
27306
27339
|
var _selectedValue$label;
|
|
27307
|
-
let { ariaLabel, heading, selectedValue, onSelectedValueChange, placeholder, isLoading = false, isError = false, isDisabled = false, isSearchable = false, searchPlaceholder } = _ref, optionOrGroups = _objectWithoutProperties(_ref, _excluded$
|
|
27340
|
+
let { ariaLabel, heading, selectedValue, onSelectedValueChange, placeholder, isLoading = false, isError = false, isDisabled = false, isSearchable = false, searchPlaceholder } = _ref, optionOrGroups = _objectWithoutProperties(_ref, _excluded$24);
|
|
27308
27341
|
const { t } = (0, react_i18next.useTranslation)();
|
|
27309
27342
|
const { options, groups } = optionOrGroups;
|
|
27310
27343
|
const [isOpen, setIsOpen] = (0, react.useState)(false);
|
|
@@ -27804,7 +27837,7 @@ function TransactionsToReview({ onClick, tagFilter = void 0, variants: variants$
|
|
|
27804
27837
|
})]
|
|
27805
27838
|
});
|
|
27806
27839
|
}
|
|
27807
|
-
var _excluded$
|
|
27840
|
+
var _excluded$23 = ["onTransactionsToReviewClick"];
|
|
27808
27841
|
var SECTION_CLASS_NAMES = `Layer__ProfitAndLossSummaries Layer__component`;
|
|
27809
27842
|
function Internal_ProfitAndLossSummaries({ actionable = false, revenueLabel, stringOverrides, chartColorsList, slots, variants: variants$1 }) {
|
|
27810
27843
|
var _effectiveData$income3, _effectiveData$income4, _effectiveData$income5, _data$netProfit;
|
|
@@ -27911,7 +27944,7 @@ function Internal_ProfitAndLossSummaries({ actionable = false, revenueLabel, str
|
|
|
27911
27944
|
});
|
|
27912
27945
|
}
|
|
27913
27946
|
function ProfitAndLossSummaries(_ref) {
|
|
27914
|
-
let { onTransactionsToReviewClick } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$
|
|
27947
|
+
let { onTransactionsToReviewClick } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$23);
|
|
27915
27948
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Internal_ProfitAndLossSummaries, _objectSpread2(_objectSpread2({}, restProps), {}, { slots: { unstable_AdditionalListItems: onTransactionsToReviewClick ? [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TransactionsToReview, {
|
|
27916
27949
|
variants: restProps.variants,
|
|
27917
27950
|
onClick: onTransactionsToReviewClick
|
|
@@ -28107,7 +28140,7 @@ const BalanceSheetTable = ({ data, config, stringOverrides }) => {
|
|
|
28107
28140
|
})
|
|
28108
28141
|
] }, rowKey + "-" + rowIndex);
|
|
28109
28142
|
};
|
|
28110
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table
|
|
28143
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table, {
|
|
28111
28144
|
borderCollapse: "collapse",
|
|
28112
28145
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableHead, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableRow, {
|
|
28113
28146
|
isHeadRow: true,
|
|
@@ -28120,7 +28153,7 @@ const BalanceSheetTable = ({ data, config, stringOverrides }) => {
|
|
|
28120
28153
|
align: TableCellAlign.RIGHT,
|
|
28121
28154
|
children: (stringOverrides === null || stringOverrides === void 0 ? void 0 : stringOverrides.totalColumnHeader) || "Total"
|
|
28122
28155
|
})]
|
|
28123
|
-
}) }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableBody
|
|
28156
|
+
}) }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableBody, { children: config.map((row, idx) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react.Fragment, { children: data[row.lineItem] && renderLineItem(data[row.lineItem], 0, row.lineItem, idx) }, row.lineItem)) })]
|
|
28124
28157
|
});
|
|
28125
28158
|
};
|
|
28126
28159
|
const GlobalDatePicker = ({ showLabel = false }) => {
|
|
@@ -28387,7 +28420,7 @@ const StatementOfCashFlowTable = ({ data, config, stringOverrides }) => {
|
|
|
28387
28420
|
})
|
|
28388
28421
|
] }, rowKey + "-" + rowIndex);
|
|
28389
28422
|
};
|
|
28390
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table
|
|
28423
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table, {
|
|
28391
28424
|
borderCollapse: "collapse",
|
|
28392
28425
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableHead, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableRow, {
|
|
28393
28426
|
rowKey: "soc-flow-head-row",
|
|
@@ -28400,7 +28433,7 @@ const StatementOfCashFlowTable = ({ data, config, stringOverrides }) => {
|
|
|
28400
28433
|
align: TableCellAlign.RIGHT,
|
|
28401
28434
|
children: (stringOverrides === null || stringOverrides === void 0 ? void 0 : stringOverrides.totalColumnHeader) || t("common:label.total", "Total")
|
|
28402
28435
|
})]
|
|
28403
|
-
}) }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableBody
|
|
28436
|
+
}) }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableBody, { children: config.map((row, idx) => {
|
|
28404
28437
|
if (row.type === "line_item") return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react.Fragment, { children: data[row.lineItem] && renderLineItem(data[row.lineItem], 0, row.lineItem ? row.lineItem : "", idx) }, row.lineItem);
|
|
28405
28438
|
else return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableRow, {
|
|
28406
28439
|
rowKey: row.name + "-" + idx,
|
|
@@ -29183,14 +29216,14 @@ const ChartOfAccountsContext = (0, react.createContext)({
|
|
|
29183
29216
|
changeFormData: () => {},
|
|
29184
29217
|
submitForm: () => {}
|
|
29185
29218
|
});
|
|
29186
|
-
var _excluded$
|
|
29219
|
+
var _excluded$22 = ["size"];
|
|
29187
29220
|
var Plus$8 = (_ref) => {
|
|
29188
29221
|
let { size = 14 } = _ref;
|
|
29189
29222
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
29190
29223
|
xmlns: "http://www.w3.org/2000/svg",
|
|
29191
29224
|
viewBox: "0 0 14 14",
|
|
29192
29225
|
fill: "none"
|
|
29193
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
29226
|
+
}, _objectWithoutProperties(_ref, _excluded$22)), {}, {
|
|
29194
29227
|
width: size,
|
|
29195
29228
|
height: size,
|
|
29196
29229
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
@@ -29510,14 +29543,14 @@ let LedgerAccountNodeType = /* @__PURE__ */ function(LedgerAccountNodeType$1) {
|
|
|
29510
29543
|
LedgerAccountNodeType$1["Parent"] = "Parent";
|
|
29511
29544
|
return LedgerAccountNodeType$1;
|
|
29512
29545
|
}({});
|
|
29513
|
-
var _excluded$
|
|
29546
|
+
var _excluded$21 = ["size"];
|
|
29514
29547
|
var Edit2 = (_ref) => {
|
|
29515
29548
|
let { size = 18 } = _ref;
|
|
29516
29549
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("svg", _objectSpread2(_objectSpread2({
|
|
29517
29550
|
xmlns: "http://www.w3.org/2000/svg",
|
|
29518
29551
|
viewBox: "0 0 18 18",
|
|
29519
29552
|
fill: "none"
|
|
29520
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
29553
|
+
}, _objectWithoutProperties(_ref, _excluded$21)), {}, {
|
|
29521
29554
|
width: size,
|
|
29522
29555
|
height: size,
|
|
29523
29556
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
@@ -29796,7 +29829,7 @@ const ChartOfAccountsTableContent = ({ stringOverrides, data, searchQuery, expan
|
|
|
29796
29829
|
description: t("chartOfAccounts:empty.accounts_match_filters", "No accounts match the current filters. Click \"Add Account\" to create a new one.")
|
|
29797
29830
|
})
|
|
29798
29831
|
});
|
|
29799
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table
|
|
29832
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table, {
|
|
29800
29833
|
componentName: "chart-of-accounts",
|
|
29801
29834
|
children: [
|
|
29802
29835
|
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("colgroup", { children: [
|
|
@@ -29834,7 +29867,7 @@ const ChartOfAccountsTableContent = ({ stringOverrides, data, searchQuery, expan
|
|
|
29834
29867
|
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableCell, { isHeaderCell: true })
|
|
29835
29868
|
]
|
|
29836
29869
|
}) }),
|
|
29837
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableBody
|
|
29870
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableBody, { children: !isError && filteredAccounts.map((account, index) => renderChartOfAccountsDesktopRow({
|
|
29838
29871
|
account,
|
|
29839
29872
|
index,
|
|
29840
29873
|
depth: 0,
|
|
@@ -29853,7 +29886,7 @@ const ChartOfAccountsTableContent = ({ stringOverrides, data, searchQuery, expan
|
|
|
29853
29886
|
cancelLabel: t("common:action.cancel_label", "Cancel")
|
|
29854
29887
|
})] });
|
|
29855
29888
|
};
|
|
29856
|
-
var COMPONENT_NAME$
|
|
29889
|
+
var COMPONENT_NAME$8 = "chart-of-accounts";
|
|
29857
29890
|
const ChartOfAccountsTableWithPanel = ({ view, containerRef, asWidget = false, withDateControl = false, withExpandAllButton = false, showAddAccountButton = true, stringOverrides, templateAccountsEditable }) => {
|
|
29858
29891
|
const { t } = (0, react_i18next.useTranslation)();
|
|
29859
29892
|
const { data, isLoading, addAccount, isError, isValidating, refetch, form } = (0, react.useContext)(ChartOfAccountsContext);
|
|
@@ -29868,21 +29901,21 @@ const ChartOfAccountsTableWithPanel = ({ view, containerRef, asWidget = false, w
|
|
|
29868
29901
|
parentRef: containerRef,
|
|
29869
29902
|
children: [
|
|
29870
29903
|
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Header$1, {
|
|
29871
|
-
className: `Layer__${COMPONENT_NAME$
|
|
29904
|
+
className: `Layer__${COMPONENT_NAME$8}__header`,
|
|
29872
29905
|
asHeader: true,
|
|
29873
29906
|
rounded: true,
|
|
29874
29907
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(HeaderRow, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(HeaderCol, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Heading$1, {
|
|
29875
|
-
className: `Layer__${COMPONENT_NAME$
|
|
29908
|
+
className: `Layer__${COMPONENT_NAME$8}__title`,
|
|
29876
29909
|
size: asWidget ? HeadingSize.view : HeadingSize.primary,
|
|
29877
29910
|
children: (stringOverrides === null || stringOverrides === void 0 ? void 0 : stringOverrides.headerText) || t("chartOfAccounts:label.chart_of_accounts", "Chart of Accounts")
|
|
29878
29911
|
}) }) })
|
|
29879
29912
|
}),
|
|
29880
29913
|
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Header$1, {
|
|
29881
|
-
className: `Layer__${COMPONENT_NAME$
|
|
29914
|
+
className: `Layer__${COMPONENT_NAME$8}__header`,
|
|
29882
29915
|
sticky: true,
|
|
29883
29916
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(HeaderRow, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(HeaderCol, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Heading$1, {
|
|
29884
29917
|
size: HeadingSize.secondary,
|
|
29885
|
-
className: `Layer__${COMPONENT_NAME$
|
|
29918
|
+
className: `Layer__${COMPONENT_NAME$8}__subtitle`,
|
|
29886
29919
|
children: withDateControl || withExpandAllButton ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(HStack, {
|
|
29887
29920
|
align: "center",
|
|
29888
29921
|
gap: "xs",
|
|
@@ -29930,7 +29963,7 @@ const ChartOfAccountsTableWithPanel = ({ view, containerRef, asWidget = false, w
|
|
|
29930
29963
|
})
|
|
29931
29964
|
}) : null,
|
|
29932
29965
|
(!data || isLoading) && !isError ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
29933
|
-
className: `Layer__${COMPONENT_NAME$
|
|
29966
|
+
className: `Layer__${COMPONENT_NAME$8}__loader-container`,
|
|
29934
29967
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Loader, {})
|
|
29935
29968
|
}) : null
|
|
29936
29969
|
]
|
|
@@ -31601,7 +31634,7 @@ const JournalEntryDetails = () => {
|
|
|
31601
31634
|
}),
|
|
31602
31635
|
!isLoadingEntry && !isErrorEntry ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
31603
31636
|
className: "Layer__journal__entry-details__line-items",
|
|
31604
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Card, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table
|
|
31637
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Card, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table, {
|
|
31605
31638
|
componentName: "journal__entry-details",
|
|
31606
31639
|
borderCollapse: "collapse",
|
|
31607
31640
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableHead, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableRow, {
|
|
@@ -31620,7 +31653,7 @@ const JournalEntryDetails = () => {
|
|
|
31620
31653
|
children: t("common:label.credit", "Credit")
|
|
31621
31654
|
})
|
|
31622
31655
|
]
|
|
31623
|
-
}) }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableBody
|
|
31656
|
+
}) }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableBody, { children: [sortedLineItems === null || sortedLineItems === void 0 ? void 0 : sortedLineItems.map((item, index) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableRow, {
|
|
31624
31657
|
rowKey: `ledger-line-item-${index}`,
|
|
31625
31658
|
children: [
|
|
31626
31659
|
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableCell, { children: item.account.name }),
|
|
@@ -31782,7 +31815,7 @@ var JournalTableContent = ({ data, stringOverrides }) => {
|
|
|
31782
31815
|
]
|
|
31783
31816
|
}, rowKey + "-" + index + "-" + subIdx))] }, rowKey + "-" + index);
|
|
31784
31817
|
};
|
|
31785
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table
|
|
31818
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table, {
|
|
31786
31819
|
borderCollapse: "collapse",
|
|
31787
31820
|
componentName: "JournalTable",
|
|
31788
31821
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableHead, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableRow, {
|
|
@@ -31820,10 +31853,10 @@ var JournalTableContent = ({ data, stringOverrides }) => {
|
|
|
31820
31853
|
children: (stringOverrides === null || stringOverrides === void 0 ? void 0 : stringOverrides.creditColumnHeader) || t("common:label.credit", "Credit")
|
|
31821
31854
|
})
|
|
31822
31855
|
]
|
|
31823
|
-
}) }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableBody
|
|
31856
|
+
}) }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableBody, { children: data.map((entry, idx) => renderJournalRow(entry, idx, `journal-row-${entry.id}`, 0)) })]
|
|
31824
31857
|
});
|
|
31825
31858
|
};
|
|
31826
|
-
var COMPONENT_NAME$
|
|
31859
|
+
var COMPONENT_NAME$7 = "journal-table";
|
|
31827
31860
|
const JournalTableWithPanel = ({ containerRef, pageSize = 15, stringOverrides, view }) => {
|
|
31828
31861
|
const { t } = (0, react_i18next.useTranslation)();
|
|
31829
31862
|
const [currentPage, setCurrentPage] = (0, react.useState)(1);
|
|
@@ -31846,25 +31879,25 @@ const JournalTableWithPanel = ({ containerRef, pageSize = 15, stringOverrides, v
|
|
|
31846
31879
|
}
|
|
31847
31880
|
};
|
|
31848
31881
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Panel, {
|
|
31849
|
-
className: `Layer__${COMPONENT_NAME$
|
|
31882
|
+
className: `Layer__${COMPONENT_NAME$7}`,
|
|
31850
31883
|
sidebar: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(JournalSidebar, { parentRef: containerRef }),
|
|
31851
31884
|
sidebarIsOpen: Boolean(selectedEntryId && selectedEntryId !== "new"),
|
|
31852
31885
|
parentRef: containerRef,
|
|
31853
31886
|
children: [
|
|
31854
31887
|
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Header$1, {
|
|
31855
|
-
className: `Layer__${COMPONENT_NAME$
|
|
31888
|
+
className: `Layer__${COMPONENT_NAME$7}__header`,
|
|
31856
31889
|
asHeader: true,
|
|
31857
31890
|
sticky: true,
|
|
31858
31891
|
rounded: true,
|
|
31859
31892
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(HeaderRow, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(HeaderCol, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Heading$1, {
|
|
31860
|
-
className: `Layer__${COMPONENT_NAME$
|
|
31893
|
+
className: `Layer__${COMPONENT_NAME$7}__title`,
|
|
31861
31894
|
size: HeadingSize.view,
|
|
31862
31895
|
children: (stringOverrides === null || stringOverrides === void 0 ? void 0 : stringOverrides.componentTitle) || t("generalLedger:label.journal", "Journal")
|
|
31863
31896
|
}) }) })
|
|
31864
31897
|
}),
|
|
31865
31898
|
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Header$1, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(HeaderRow, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(HeaderCol, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Heading$1, {
|
|
31866
31899
|
size: HeadingSize.secondary,
|
|
31867
|
-
className: `Layer__${COMPONENT_NAME$
|
|
31900
|
+
className: `Layer__${COMPONENT_NAME$7}__subtitle`,
|
|
31868
31901
|
children: (stringOverrides === null || stringOverrides === void 0 ? void 0 : stringOverrides.componentSubtitle) || t("generalLedger:label.entries", "Entries")
|
|
31869
31902
|
}) }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(HeaderCol, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(JournalEntriesDownloadButton, { iconOnly: ["mobile", "tablet"].includes(view) }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button$1, {
|
|
31870
31903
|
onClick: () => toCreateEntry(),
|
|
@@ -31906,7 +31939,7 @@ const JournalTableWithPanel = ({ containerRef, pageSize = 15, stringOverrides, v
|
|
|
31906
31939
|
})
|
|
31907
31940
|
}) : null,
|
|
31908
31941
|
(!data || isLoading) && !isError ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
31909
|
-
className: `Layer__${COMPONENT_NAME$
|
|
31942
|
+
className: `Layer__${COMPONENT_NAME$7}__loader-container`,
|
|
31910
31943
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Loader, {})
|
|
31911
31944
|
}) : null
|
|
31912
31945
|
]
|
|
@@ -32066,14 +32099,14 @@ const TasksHeader = ({ tasksHeader }) => {
|
|
|
32066
32099
|
})
|
|
32067
32100
|
});
|
|
32068
32101
|
};
|
|
32069
|
-
var _excluded$
|
|
32102
|
+
var _excluded$20 = ["size"];
|
|
32070
32103
|
var SmileIcon = (_ref) => {
|
|
32071
32104
|
let { size = 12 } = _ref;
|
|
32072
32105
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
32073
32106
|
viewBox: "0 0 12 12",
|
|
32074
32107
|
fill: "none",
|
|
32075
32108
|
xmlns: "http://www.w3.org/2000/svg"
|
|
32076
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
32109
|
+
}, _objectWithoutProperties(_ref, _excluded$20)), {}, {
|
|
32077
32110
|
width: size,
|
|
32078
32111
|
height: size,
|
|
32079
32112
|
children: [
|
|
@@ -32261,13 +32294,13 @@ function useSubmitUserResponseForTask() {
|
|
|
32261
32294
|
return Reflect.get(target, prop);
|
|
32262
32295
|
} });
|
|
32263
32296
|
}
|
|
32264
|
-
var _excluded$
|
|
32297
|
+
var _excluded$19 = [
|
|
32265
32298
|
"className",
|
|
32266
32299
|
"isInvalid",
|
|
32267
32300
|
"errorMessage"
|
|
32268
32301
|
];
|
|
32269
32302
|
const Textarea = (_ref) => {
|
|
32270
|
-
let { className, isInvalid, errorMessage } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
32303
|
+
let { className, isInvalid, errorMessage } = _ref, props = _objectWithoutProperties(_ref, _excluded$19);
|
|
32271
32304
|
const baseClassName$1 = (0, classnames.default)("Layer__textarea", isInvalid ? "Layer__textarea--error" : "", className);
|
|
32272
32305
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(DeprecatedTooltip, {
|
|
32273
32306
|
disabled: !isInvalid || !errorMessage,
|
|
@@ -32586,34 +32619,28 @@ const TasksList = ({ pageSize = 8, mobile }) => {
|
|
|
32586
32619
|
})] }) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TasksEmptyState, {})
|
|
32587
32620
|
});
|
|
32588
32621
|
};
|
|
32589
|
-
var
|
|
32590
|
-
|
|
32591
|
-
|
|
32622
|
+
var buildLongLabel = (t, formatNumber$1, tasksCount) => tPlural(t, "bookkeeping:label.count_tasks", {
|
|
32623
|
+
count: tasksCount,
|
|
32624
|
+
displayCount: formatNumber$1(tasksCount),
|
|
32625
|
+
one: "{{displayCount}} task",
|
|
32626
|
+
other: "{{displayCount}} tasks"
|
|
32627
|
+
});
|
|
32628
|
+
var getBadgeConfig = (status, tasksCount, t, formatNumber$1) => {
|
|
32592
32629
|
switch (status) {
|
|
32593
32630
|
case BookkeepingPeriodStatus.IN_PROGRESS_AWAITING_BOOKKEEPER:
|
|
32594
32631
|
case BookkeepingPeriodStatus.NOT_STARTED:
|
|
32595
32632
|
case BookkeepingPeriodStatus.CLOSING_IN_REVIEW: return {
|
|
32596
32633
|
color: "info",
|
|
32597
32634
|
icon: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Clock_default, { size: 12 }),
|
|
32598
|
-
label: tasksCount ?
|
|
32599
|
-
count: tasksCount,
|
|
32600
|
-
displayCount: formatNumber$1(tasksCount),
|
|
32601
|
-
one: "{{displayCount}} task",
|
|
32602
|
-
other: "{{displayCount}} tasks"
|
|
32603
|
-
}) : void 0,
|
|
32635
|
+
label: tasksCount ? buildLongLabel(t, formatNumber$1, tasksCount) : void 0,
|
|
32604
32636
|
labelShort: tasksCount ? formatNumber$1(tasksCount) : void 0
|
|
32605
32637
|
};
|
|
32606
32638
|
case BookkeepingPeriodStatus.IN_PROGRESS_AWAITING_CUSTOMER:
|
|
32607
32639
|
case BookkeepingPeriodStatus.CLOSED_OPEN_TASKS: return {
|
|
32608
32640
|
color: "warning",
|
|
32609
|
-
|
|
32610
|
-
|
|
32611
|
-
|
|
32612
|
-
one: "{{displayCount}} task",
|
|
32613
|
-
other: "{{displayCount}} tasks"
|
|
32614
|
-
}) : void 0,
|
|
32615
|
-
labelShort: tasksCount ? formatNumber$1(tasksCount) : void 0,
|
|
32616
|
-
icon: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(AlertCircle_default, { size: 12 })
|
|
32641
|
+
icon: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(AlertCircle_default, { size: 12 }),
|
|
32642
|
+
label: tasksCount ? buildLongLabel(t, formatNumber$1, tasksCount) : void 0,
|
|
32643
|
+
labelShort: tasksCount ? formatNumber$1(tasksCount) : void 0
|
|
32617
32644
|
};
|
|
32618
32645
|
case BookkeepingPeriodStatus.CLOSED_COMPLETE: return {
|
|
32619
32646
|
color: "success",
|
|
@@ -32627,37 +32654,38 @@ var useBadgeConfig = (status, tasksCount) => {
|
|
|
32627
32654
|
});
|
|
32628
32655
|
}
|
|
32629
32656
|
};
|
|
32630
|
-
|
|
32631
|
-
|
|
32657
|
+
var BadgeContent = ({ color, icon, display }) => {
|
|
32658
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(HStack, _objectSpread2(_objectSpread2({ className: "Layer__TasksBadge" }, toDataProperties({
|
|
32659
|
+
status: color,
|
|
32660
|
+
icononly: !display
|
|
32661
|
+
})), {}, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(HStack, {
|
|
32662
|
+
align: "center",
|
|
32663
|
+
justify: "center",
|
|
32664
|
+
className: "Layer__TasksBadge__Icon",
|
|
32665
|
+
"data-status": color,
|
|
32666
|
+
children: icon
|
|
32667
|
+
}), display ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, {
|
|
32668
|
+
className: "Layer__TasksBadge__Label",
|
|
32669
|
+
size: TextSize.sm,
|
|
32670
|
+
status: color,
|
|
32671
|
+
invertColor: color === "warning",
|
|
32672
|
+
weight: TextWeight.bold,
|
|
32673
|
+
children: display
|
|
32674
|
+
}) : null] }));
|
|
32675
|
+
};
|
|
32676
|
+
const TaskStatusBadge = ({ status, tasksCount, isMobile }) => {
|
|
32677
|
+
const { t } = (0, react_i18next.useTranslation)();
|
|
32678
|
+
const { formatNumber: formatNumber$1 } = useIntlFormatter();
|
|
32679
|
+
const badgeConfig = getBadgeConfig(status, tasksCount, t, formatNumber$1);
|
|
32632
32680
|
if (!badgeConfig) return;
|
|
32633
|
-
|
|
32634
|
-
|
|
32635
|
-
|
|
32636
|
-
|
|
32637
|
-
|
|
32638
|
-
|
|
32639
|
-
"data-status": badgeConfig.color,
|
|
32640
|
-
children: badgeConfig.icon
|
|
32641
|
-
}),
|
|
32642
|
-
badgeConfig.label && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, {
|
|
32643
|
-
className: "Layer__tasks__badge__label",
|
|
32644
|
-
size: TextSize.sm,
|
|
32645
|
-
status: badgeConfig.color,
|
|
32646
|
-
invertColor: badgeConfig.color === "warning",
|
|
32647
|
-
weight: TextWeight.bold,
|
|
32648
|
-
children: badgeConfig.label
|
|
32649
|
-
}),
|
|
32650
|
-
badgeConfig.labelShort && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Text, {
|
|
32651
|
-
className: "Layer__tasks__badge__label-short",
|
|
32652
|
-
size: TextSize.sm,
|
|
32653
|
-
status: badgeConfig.color,
|
|
32654
|
-
invertColor: badgeConfig.color === "warning",
|
|
32655
|
-
weight: TextWeight.bold,
|
|
32656
|
-
children: badgeConfig.labelShort
|
|
32657
|
-
})
|
|
32658
|
-
] }));
|
|
32681
|
+
const display = isMobile ? badgeConfig.labelShort : badgeConfig.label;
|
|
32682
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(BadgeContent, {
|
|
32683
|
+
color: badgeConfig.color,
|
|
32684
|
+
icon: badgeConfig.icon,
|
|
32685
|
+
display
|
|
32686
|
+
});
|
|
32659
32687
|
};
|
|
32660
|
-
const TaskMonthTile = ({ data, onClick, active, disabled }) => {
|
|
32688
|
+
const TaskMonthTile = ({ data, onClick, active, disabled, isMobile }) => {
|
|
32661
32689
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", _objectSpread2(_objectSpread2({
|
|
32662
32690
|
className: "Layer__tasks-month-selector__month",
|
|
32663
32691
|
onClick: () => !disabled && onClick(new Date(data.year, data.month - 1, 1))
|
|
@@ -32670,7 +32698,8 @@ const TaskMonthTile = ({ data, onClick, active, disabled }) => {
|
|
|
32670
32698
|
children: data.monthStr
|
|
32671
32699
|
}), data.status && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaskStatusBadge, {
|
|
32672
32700
|
status: data.status,
|
|
32673
|
-
tasksCount: data.total - data.completed
|
|
32701
|
+
tasksCount: data.total - data.completed,
|
|
32702
|
+
isMobile
|
|
32674
32703
|
})] }));
|
|
32675
32704
|
};
|
|
32676
32705
|
function useActiveYearBookkeepingPeriods() {
|
|
@@ -32681,7 +32710,7 @@ function useActiveYearBookkeepingPeriods() {
|
|
|
32681
32710
|
return data === null || data === void 0 ? void 0 : data.filter((period) => period.year === activeYear);
|
|
32682
32711
|
}, [data, activeYear]) };
|
|
32683
32712
|
}
|
|
32684
|
-
function TasksMonthSelector() {
|
|
32713
|
+
function TasksMonthSelector({ isMobile }) {
|
|
32685
32714
|
const { date } = useGlobalDate();
|
|
32686
32715
|
const { formatDate: formatDate$1 } = useIntlFormatter();
|
|
32687
32716
|
const { setMonthByPeriod } = useGlobalDatePeriodAlignedActions();
|
|
@@ -32731,7 +32760,8 @@ function TasksMonthSelector() {
|
|
|
32731
32760
|
}),
|
|
32732
32761
|
data: monthData,
|
|
32733
32762
|
active: monthData.month === activeMonthNumber,
|
|
32734
|
-
disabled: monthData.disabled
|
|
32763
|
+
disabled: monthData.disabled,
|
|
32764
|
+
isMobile
|
|
32735
32765
|
}, idx);
|
|
32736
32766
|
})
|
|
32737
32767
|
});
|
|
@@ -32765,14 +32795,14 @@ const useBookkeepingYearsStatus = () => {
|
|
|
32765
32795
|
isLoading
|
|
32766
32796
|
};
|
|
32767
32797
|
};
|
|
32768
|
-
var _excluded$
|
|
32798
|
+
var _excluded$18 = ["size"];
|
|
32769
32799
|
var ArrowRightCircle = (_ref) => {
|
|
32770
32800
|
let { size = 18 } = _ref;
|
|
32771
32801
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
32772
32802
|
xmlns: "http://www.w3.org/2000/svg",
|
|
32773
32803
|
viewBox: "0 0 18 18",
|
|
32774
32804
|
fill: "none"
|
|
32775
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
32805
|
+
}, _objectWithoutProperties(_ref, _excluded$18)), {}, {
|
|
32776
32806
|
width: size,
|
|
32777
32807
|
height: size,
|
|
32778
32808
|
children: [
|
|
@@ -33099,7 +33129,7 @@ const Tabs = ({ name: name$1, options, selected, onChange }) => {
|
|
|
33099
33129
|
})
|
|
33100
33130
|
});
|
|
33101
33131
|
};
|
|
33102
|
-
const TasksYearsTabs = () => {
|
|
33132
|
+
const TasksYearsTabs = ({ isMobile }) => {
|
|
33103
33133
|
const { date } = useGlobalDate();
|
|
33104
33134
|
const { setMonthByPeriod } = useGlobalDatePeriodAlignedActions();
|
|
33105
33135
|
const { formatDate: formatDate$1 } = useIntlFormatter();
|
|
@@ -33120,11 +33150,16 @@ const TasksYearsTabs = () => {
|
|
|
33120
33150
|
label: formatDate$1(new Date(y.year, 0, 1), DateFormat.Year),
|
|
33121
33151
|
badge: !y.completed && y.unresolvedTasks ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaskStatusBadge, {
|
|
33122
33152
|
status: y.unresolvedTasks ? BookkeepingPeriodStatus.IN_PROGRESS_AWAITING_CUSTOMER : BookkeepingPeriodStatus.CLOSED_COMPLETE,
|
|
33123
|
-
tasksCount: y.unresolvedTasks
|
|
33153
|
+
tasksCount: y.unresolvedTasks,
|
|
33154
|
+
isMobile
|
|
33124
33155
|
}) : null
|
|
33125
33156
|
};
|
|
33126
33157
|
});
|
|
33127
|
-
}, [
|
|
33158
|
+
}, [
|
|
33159
|
+
formatDate$1,
|
|
33160
|
+
yearStatuses,
|
|
33161
|
+
isMobile
|
|
33162
|
+
]),
|
|
33128
33163
|
selected: activeYear.toString(),
|
|
33129
33164
|
onChange: (year) => setCurrentYear(year.target.value)
|
|
33130
33165
|
});
|
|
@@ -33142,6 +33177,7 @@ function Tasks({ mobile = false, tasksHeader, onClickReconnectAccounts, stringOv
|
|
|
33142
33177
|
const { t } = (0, react_i18next.useTranslation)();
|
|
33143
33178
|
const { data, isLoading } = useBookkeepingPeriods();
|
|
33144
33179
|
const { data: callBookings, isLoading: isLoadingCallBookings } = useCallBookings();
|
|
33180
|
+
const { isMobile } = useSizeClass();
|
|
33145
33181
|
const tasksState = (0, react.useMemo)(() => {
|
|
33146
33182
|
var _data$length, _callBookings$some;
|
|
33147
33183
|
if (isLoading || isLoadingCallBookings) return "loading";
|
|
@@ -33178,8 +33214,8 @@ function Tasks({ mobile = false, tasksHeader, onClickReconnectAccounts, stringOv
|
|
|
33178
33214
|
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(P, { children: t("bookkeeping:label.please_contact_support", "If you believe this is an error, please contact support.") })]
|
|
33179
33215
|
}) }),
|
|
33180
33216
|
children: () => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [
|
|
33181
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TasksYearsTabs, {}),
|
|
33182
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TasksMonthSelector, {}),
|
|
33217
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TasksYearsTabs, { isMobile }),
|
|
33218
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TasksMonthSelector, { isMobile }),
|
|
33183
33219
|
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TasksPending, {}),
|
|
33184
33220
|
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TasksList, { mobile })
|
|
33185
33221
|
] })
|
|
@@ -34009,14 +34045,14 @@ function LinkAccountsContent({ onComplete }) {
|
|
|
34009
34045
|
})
|
|
34010
34046
|
});
|
|
34011
34047
|
}
|
|
34012
|
-
var _excluded$
|
|
34048
|
+
var _excluded$17 = ["size"];
|
|
34013
34049
|
var CoffeeIcon = (_ref) => {
|
|
34014
34050
|
let { size = 11 } = _ref;
|
|
34015
34051
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
34016
34052
|
xmlns: "http://www.w3.org/2000/svg",
|
|
34017
34053
|
viewBox: "0 0 12 12",
|
|
34018
34054
|
fill: "none"
|
|
34019
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
34055
|
+
}, _objectWithoutProperties(_ref, _excluded$17)), {}, {
|
|
34020
34056
|
width: size,
|
|
34021
34057
|
height: size,
|
|
34022
34058
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("g", {
|
|
@@ -34065,7 +34101,7 @@ var CoffeeIcon = (_ref) => {
|
|
|
34065
34101
|
}));
|
|
34066
34102
|
};
|
|
34067
34103
|
var Coffee_default = CoffeeIcon;
|
|
34068
|
-
var _excluded$
|
|
34104
|
+
var _excluded$16 = [
|
|
34069
34105
|
"className",
|
|
34070
34106
|
"children",
|
|
34071
34107
|
"variant",
|
|
@@ -34077,7 +34113,7 @@ var _excluded$15 = [
|
|
|
34077
34113
|
"fullWidth"
|
|
34078
34114
|
];
|
|
34079
34115
|
const Link$1 = (_ref) => {
|
|
34080
|
-
let { className, children, variant = ButtonVariant.primary, leftIcon, rightIcon, iconOnly, iconAsPrimary = false, justify = "center", fullWidth } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
34116
|
+
let { className, children, variant = ButtonVariant.primary, leftIcon, rightIcon, iconOnly, iconAsPrimary = false, justify = "center", fullWidth } = _ref, props = _objectWithoutProperties(_ref, _excluded$16);
|
|
34081
34117
|
const linkRef = (0, react.useRef)(null);
|
|
34082
34118
|
let justifyContent = "center";
|
|
34083
34119
|
if (justify) justifyContent = justify;
|
|
@@ -34175,14 +34211,14 @@ const useMileageSummaryGlobalCacheActions = () => {
|
|
|
34175
34211
|
const { invalidate } = useGlobalCacheActions();
|
|
34176
34212
|
return { invalidateMileageSummary: (0, react.useCallback)(() => invalidate(({ tags }) => tags.includes(MILEAGE_SUMMARY_TAG_KEY)), [invalidate]) };
|
|
34177
34213
|
};
|
|
34178
|
-
var _excluded$
|
|
34214
|
+
var _excluded$15 = ["size"];
|
|
34179
34215
|
var ArrowRightCircleAlt = (_ref) => {
|
|
34180
34216
|
let { size = 18 } = _ref;
|
|
34181
34217
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
34182
34218
|
xmlns: "http://www.w3.org/2000/svg",
|
|
34183
34219
|
viewBox: "0 0 18 18",
|
|
34184
34220
|
fill: "none"
|
|
34185
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
34221
|
+
}, _objectWithoutProperties(_ref, _excluded$15)), {}, {
|
|
34186
34222
|
width: size,
|
|
34187
34223
|
height: size,
|
|
34188
34224
|
children: [
|
|
@@ -35463,14 +35499,14 @@ function getCustomerName(customer) {
|
|
|
35463
35499
|
var _ref, _customer$individualN;
|
|
35464
35500
|
return (_ref = (_customer$individualN = customer === null || customer === void 0 ? void 0 : customer.individualName) !== null && _customer$individualN !== void 0 ? _customer$individualN : customer === null || customer === void 0 ? void 0 : customer.companyName) !== null && _ref !== void 0 ? _ref : "Unknown Customer";
|
|
35465
35501
|
}
|
|
35466
|
-
var _excluded$
|
|
35502
|
+
var _excluded$14 = ["size"];
|
|
35467
35503
|
var ChevronRightFill = (_ref) => {
|
|
35468
35504
|
let { size = 18 } = _ref;
|
|
35469
35505
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", _objectSpread2(_objectSpread2({
|
|
35470
35506
|
xmlns: "http://www.w3.org/2000/svg",
|
|
35471
35507
|
viewBox: "0 0 18 18",
|
|
35472
35508
|
fill: "none"
|
|
35473
|
-
}, _objectWithoutProperties(_ref, _excluded$
|
|
35509
|
+
}, _objectWithoutProperties(_ref, _excluded$14)), {}, {
|
|
35474
35510
|
width: size,
|
|
35475
35511
|
height: size,
|
|
35476
35512
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
|
|
@@ -35601,7 +35637,7 @@ const InvoiceStatusCell = ({ invoice, inline = false }) => {
|
|
|
35601
35637
|
})] }))]
|
|
35602
35638
|
});
|
|
35603
35639
|
};
|
|
35604
|
-
var COMPONENT_NAME$
|
|
35640
|
+
var COMPONENT_NAME$6 = "InvoiceTable";
|
|
35605
35641
|
var InvoiceColumns = /* @__PURE__ */ function(InvoiceColumns$1) {
|
|
35606
35642
|
InvoiceColumns$1["SentAt"] = "SentAt";
|
|
35607
35643
|
InvoiceColumns$1["InvoiceNo"] = "InvoiceNo";
|
|
@@ -35843,7 +35879,7 @@ const InvoiceTable = () => {
|
|
|
35843
35879
|
isError,
|
|
35844
35880
|
columnConfig,
|
|
35845
35881
|
paginationProps,
|
|
35846
|
-
componentName: COMPONENT_NAME$
|
|
35882
|
+
componentName: COMPONENT_NAME$6,
|
|
35847
35883
|
slots: {
|
|
35848
35884
|
EmptyState: InvoiceTableEmptyState,
|
|
35849
35885
|
ErrorState: InvoiceTableErrorState
|
|
@@ -37492,9 +37528,9 @@ const useCustomerForm = (props) => {
|
|
|
37492
37528
|
submitError
|
|
37493
37529
|
}), [form, submitError]);
|
|
37494
37530
|
};
|
|
37495
|
-
var _excluded$
|
|
37531
|
+
var _excluded$13 = ["onSuccess", "isReadOnly"];
|
|
37496
37532
|
const CustomerForm = (_ref) => {
|
|
37497
|
-
let { onSuccess, isReadOnly } = _ref, formState = _objectWithoutProperties(_ref, _excluded$
|
|
37533
|
+
let { onSuccess, isReadOnly } = _ref, formState = _objectWithoutProperties(_ref, _excluded$13);
|
|
37498
37534
|
const { t } = (0, react_i18next.useTranslation)();
|
|
37499
37535
|
const { form, submitError } = useCustomerForm(_objectSpread2({ onSuccess }, formState));
|
|
37500
37536
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Form, {
|
|
@@ -38347,10 +38383,10 @@ const useInvoiceForm = (props) => {
|
|
|
38347
38383
|
submitError
|
|
38348
38384
|
]);
|
|
38349
38385
|
};
|
|
38350
|
-
var _excluded$
|
|
38386
|
+
var _excluded$12 = ["isReadOnly"];
|
|
38351
38387
|
const InvoiceForm = (0, react.forwardRef)((props, ref) => {
|
|
38352
38388
|
var _accountingConfig$ena;
|
|
38353
|
-
const _useInvoiceDetail = useInvoiceDetail(), { isReadOnly } = _useInvoiceDetail, viewState = _objectWithoutProperties(_useInvoiceDetail, _excluded$
|
|
38389
|
+
const _useInvoiceDetail = useInvoiceDetail(), { isReadOnly } = _useInvoiceDetail, viewState = _objectWithoutProperties(_useInvoiceDetail, _excluded$12);
|
|
38354
38390
|
const { mode } = viewState;
|
|
38355
38391
|
const { onSuccess, onChangeFormState } = props;
|
|
38356
38392
|
const { businessId } = useLayerContext();
|
|
@@ -38796,7 +38832,7 @@ const InvoiceDetail = () => {
|
|
|
38796
38832
|
})
|
|
38797
38833
|
] });
|
|
38798
38834
|
};
|
|
38799
|
-
var _excluded$
|
|
38835
|
+
var _excluded$11 = [
|
|
38800
38836
|
"className",
|
|
38801
38837
|
"label",
|
|
38802
38838
|
"meterOnly"
|
|
@@ -38807,7 +38843,7 @@ var getClassnameForSubComponent = (className, suffix) => {
|
|
|
38807
38843
|
var METER_CLASS_NAME = "Layer__Meter";
|
|
38808
38844
|
const Meter = (0, react.forwardRef)(function Meter$1(_ref, ref) {
|
|
38809
38845
|
let { className, label: label$50, meterOnly } = _ref;
|
|
38810
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.Meter, _objectSpread2(_objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$
|
|
38846
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.Meter, _objectSpread2(_objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$11)), {}, {
|
|
38811
38847
|
className: (0, classnames.default)(METER_CLASS_NAME, className),
|
|
38812
38848
|
ref
|
|
38813
38849
|
}, meterOnly && { "aria-label": label$50 }), {}, { children: ({ percentage, valueText }) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(VStack, {
|
|
@@ -39029,7 +39065,7 @@ function useStripeAccountStatus() {
|
|
|
39029
39065
|
businessId
|
|
39030
39066
|
}))), ({ accessToken, apiUrl: apiUrl$1, businessId: businessId$1 }) => getStripeAccountStatus(apiUrl$1, accessToken, { params: { businessId: businessId$1 } })().then(effect.Schema.decodeUnknownPromise(StripeAccountStatusResponseSchema)).then(({ data: data$1 }) => data$1)));
|
|
39031
39067
|
}
|
|
39032
|
-
var _excluded$
|
|
39068
|
+
var _excluded$10 = ["variant"];
|
|
39033
39069
|
const BANNER_CLASS_NAMES = {
|
|
39034
39070
|
DEFAULT: "Layer__UI__Banner",
|
|
39035
39071
|
ICON_CONTAINER: "Layer__UI__Banner__iconContainer",
|
|
@@ -39121,7 +39157,7 @@ var Banner = (0, react.forwardRef)(({ variant = "info", title, description: desc
|
|
|
39121
39157
|
});
|
|
39122
39158
|
Banner.displayName = "Banner";
|
|
39123
39159
|
const BannerButton = (_ref) => {
|
|
39124
|
-
let { variant = "outlined-light" } = _ref, rest = _objectWithoutProperties(_ref, _excluded$
|
|
39160
|
+
let { variant = "outlined-light" } = _ref, rest = _objectWithoutProperties(_ref, _excluded$10);
|
|
39125
39161
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button, _objectSpread2({ variant }, rest));
|
|
39126
39162
|
};
|
|
39127
39163
|
const ConnectStripeButton = ({ isError, isMutating, onClick }) => {
|
|
@@ -39254,18 +39290,18 @@ const Invoices = ({ stringOverrides }) => {
|
|
|
39254
39290
|
var InvoicesContent = () => {
|
|
39255
39291
|
return useInvoiceRouteState().route === InvoiceRoute.Detail ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(InvoiceDetail, {}) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(InvoiceOverview, {});
|
|
39256
39292
|
};
|
|
39257
|
-
var _excluded$
|
|
39258
|
-
var COMPONENT_NAME$
|
|
39293
|
+
var _excluded$9 = ["containerRef", "stringOverrides"];
|
|
39294
|
+
var COMPONENT_NAME$5 = "profit-and-loss";
|
|
39259
39295
|
const ProfitAndLossView = (props) => {
|
|
39260
39296
|
const containerRef = (0, react.useRef)(null);
|
|
39261
39297
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Container, {
|
|
39262
|
-
name: COMPONENT_NAME$
|
|
39298
|
+
name: COMPONENT_NAME$5,
|
|
39263
39299
|
ref: containerRef,
|
|
39264
39300
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ProfitAndLoss, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ProfitAndLossPanel, _objectSpread2({ containerRef }, props)) })
|
|
39265
39301
|
});
|
|
39266
39302
|
};
|
|
39267
39303
|
var ProfitAndLossPanel = (_ref) => {
|
|
39268
|
-
let { containerRef, stringOverrides } = _ref, props = _objectWithoutProperties(_ref, _excluded$
|
|
39304
|
+
let { containerRef, stringOverrides } = _ref, props = _objectWithoutProperties(_ref, _excluded$9);
|
|
39269
39305
|
const { t } = (0, react_i18next.useTranslation)();
|
|
39270
39306
|
const { sidebarScope } = (0, react.useContext)(ProfitAndLossContext);
|
|
39271
39307
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Panel, {
|
|
@@ -39274,7 +39310,7 @@ var ProfitAndLossPanel = (_ref) => {
|
|
|
39274
39310
|
parentRef: containerRef,
|
|
39275
39311
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(ProfitAndLoss.Header, {
|
|
39276
39312
|
text: (stringOverrides === null || stringOverrides === void 0 ? void 0 : stringOverrides.header) || t("common:label.profit_loss", "Profit & Loss"),
|
|
39277
|
-
className: `Layer__${COMPONENT_NAME$
|
|
39313
|
+
className: `Layer__${COMPONENT_NAME$5}__header`,
|
|
39278
39314
|
headingClassName: "Layer__profit-and-loss__title"
|
|
39279
39315
|
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Components, _objectSpread2({ stringOverrides }, props))]
|
|
39280
39316
|
});
|
|
@@ -39293,15 +39329,15 @@ var Components = ({ hideChart = false, hideTable = false, stringOverrides }) =>
|
|
|
39293
39329
|
})
|
|
39294
39330
|
});
|
|
39295
39331
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [!hideChart && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
39296
|
-
className: `Layer__${COMPONENT_NAME$
|
|
39332
|
+
className: `Layer__${COMPONENT_NAME$5}__chart_with_summaries`,
|
|
39297
39333
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
39298
|
-
className: `Layer__${COMPONENT_NAME$
|
|
39334
|
+
className: `Layer__${COMPONENT_NAME$5}__chart_with_summaries__summary-col`,
|
|
39299
39335
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(GlobalMonthPicker, {}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ProfitAndLoss.Summaries, {
|
|
39300
39336
|
actionable: true,
|
|
39301
39337
|
stringOverrides: stringOverrides === null || stringOverrides === void 0 ? void 0 : stringOverrides.profitAndLossSummaries
|
|
39302
39338
|
})]
|
|
39303
39339
|
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
39304
|
-
className: `Layer__${COMPONENT_NAME$
|
|
39340
|
+
className: `Layer__${COMPONENT_NAME$5}__chart_with_summaries__chart-col`,
|
|
39305
39341
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ProfitAndLoss.Chart, {})
|
|
39306
39342
|
})]
|
|
39307
39343
|
}), !hideTable && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ProfitAndLossTableWithProvider, { stringOverrides: stringOverrides === null || stringOverrides === void 0 ? void 0 : stringOverrides.profitAndLossTable })] });
|
|
@@ -39486,12 +39522,12 @@ function ExpandableDataTableProvider({ children }) {
|
|
|
39486
39522
|
children
|
|
39487
39523
|
});
|
|
39488
39524
|
}
|
|
39489
|
-
var _excluded$
|
|
39525
|
+
var _excluded$8 = ["children", "className"], _excluded2$3 = ["children"], _excluded3 = ["children"];
|
|
39490
39526
|
var TREE_CLASS_NAME = "Layer__UI__Tree";
|
|
39491
39527
|
var TREE_ITEM_CLASS_NAME = "Layer__UI__TreeItem";
|
|
39492
39528
|
var TreeInner = (_ref, ref) => {
|
|
39493
39529
|
let { children, className } = _ref;
|
|
39494
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.Tree, _objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$
|
|
39530
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_aria_components.Tree, _objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$8)), {}, {
|
|
39495
39531
|
className: (0, classnames.default)(TREE_CLASS_NAME, className),
|
|
39496
39532
|
ref,
|
|
39497
39533
|
children: withRenderProp(children, (node) => node)
|
|
@@ -39771,7 +39807,7 @@ const S3PresignedUrlSchema = effect.Schema.Struct({
|
|
|
39771
39807
|
createdAt: effect.Schema.Date,
|
|
39772
39808
|
documentId: effect.Schema.NullishOr(effect.Schema.UUID)
|
|
39773
39809
|
});
|
|
39774
|
-
var _excluded$
|
|
39810
|
+
var _excluded$7 = ["businessId", "route"], _excluded2$2 = [
|
|
39775
39811
|
"accessToken",
|
|
39776
39812
|
"apiUrl",
|
|
39777
39813
|
"businessId",
|
|
@@ -39779,7 +39815,7 @@ var _excluded$6 = ["businessId", "route"], _excluded2$2 = [
|
|
|
39779
39815
|
];
|
|
39780
39816
|
var getUnifiedReportExcel = get((_ref) => {
|
|
39781
39817
|
let { businessId, route } = _ref;
|
|
39782
|
-
return `/v1/businesses/${businessId}/reports/unified/${route}/exports/excel?${toDefinedSearchParameters(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$
|
|
39818
|
+
return `/v1/businesses/${businessId}/reports/unified/${route}/exports/excel?${toDefinedSearchParameters(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$7)))}`;
|
|
39783
39819
|
});
|
|
39784
39820
|
var getTag$1 = (report) => `#unified-${report}-report-excel`;
|
|
39785
39821
|
var UnifiedReportExcelReturnSchema = effect.Schema.Struct({ data: S3PresignedUrlSchema });
|
|
@@ -39847,7 +39883,7 @@ const UnifiedReportHeaderButtons = () => {
|
|
|
39847
39883
|
]
|
|
39848
39884
|
});
|
|
39849
39885
|
};
|
|
39850
|
-
var _excluded$
|
|
39886
|
+
var _excluded$6 = ["businessId", "route"], _excluded2$1 = [
|
|
39851
39887
|
"accessToken",
|
|
39852
39888
|
"apiUrl",
|
|
39853
39889
|
"businessId",
|
|
@@ -39864,7 +39900,7 @@ function buildKey$25({ access_token: accessToken, apiUrl, businessId, params })
|
|
|
39864
39900
|
}
|
|
39865
39901
|
var getUnifiedReport = get((_ref) => {
|
|
39866
39902
|
let { businessId, route } = _ref;
|
|
39867
|
-
return `/v1/businesses/${businessId}/reports/unified/${route}?${toDefinedSearchParameters(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$
|
|
39903
|
+
return `/v1/businesses/${businessId}/reports/unified/${route}?${toDefinedSearchParameters(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$6)))}`;
|
|
39868
39904
|
});
|
|
39869
39905
|
function useUnifiedReport() {
|
|
39870
39906
|
const withLocale = useLocalizedKey();
|
|
@@ -39889,40 +39925,46 @@ const ExpandButton = ({ isExpanded }) => {
|
|
|
39889
39925
|
"aria-label": isExpanded ? "Collapse row" : "Expand row"
|
|
39890
39926
|
});
|
|
39891
39927
|
};
|
|
39892
|
-
var
|
|
39928
|
+
var INDENT_SIZE_XS = 10;
|
|
39929
|
+
var INDENT_SIZE_SM = 20;
|
|
39930
|
+
var INDENT_SIZE_MD = 40;
|
|
39931
|
+
var CHEVRON_OFFSET_PX = 4;
|
|
39932
|
+
var getRowIndentStyle = ({ depth, canExpand, indentSizePx }) => ({ paddingInlineStart: depth * indentSizePx + (canExpand ? 0 : CHEVRON_OFFSET_PX) });
|
|
39893
39933
|
var EMPTY_ARRAY$1 = [];
|
|
39894
|
-
function ExpandableDataTable({ data, isLoading, isError, columnConfig, componentName, ariaLabel, slots, getSubRows: getSubRows$
|
|
39934
|
+
function ExpandableDataTable({ data, isLoading, isError, columnConfig, componentName, ariaLabel, slots, getSubRows: getSubRows$3, getRowId: getRowId$2, indentSize = "sm" }) {
|
|
39895
39935
|
const { expanded, setExpanded } = (0, react.useContext)(ExpandableDataTableContext);
|
|
39896
39936
|
const wrappedColumnConfig = (0, react.useMemo)(() => {
|
|
39937
|
+
const indentSizePx = indentSize === "xs" ? INDENT_SIZE_XS : indentSize === "md" ? INDENT_SIZE_MD : INDENT_SIZE_SM;
|
|
39897
39938
|
const [first, ...rest] = columnConfig;
|
|
39898
39939
|
if (!first || !isLeafColumn(first)) return columnConfig;
|
|
39899
|
-
const
|
|
39940
|
+
const cellRenderer = first.cell;
|
|
39900
39941
|
return [_objectSpread2(_objectSpread2({}, first), {}, { cell: (row) => {
|
|
39901
39942
|
const canExpand = row.getCanExpand();
|
|
39902
39943
|
const rowIndentStyle = getRowIndentStyle({
|
|
39903
39944
|
canExpand,
|
|
39904
|
-
depth: row.depth
|
|
39945
|
+
depth: row.depth,
|
|
39946
|
+
indentSizePx
|
|
39905
39947
|
});
|
|
39906
39948
|
if (!canExpand) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
39907
39949
|
style: rowIndentStyle,
|
|
39908
|
-
children:
|
|
39950
|
+
children: cellRenderer(row)
|
|
39909
39951
|
});
|
|
39910
39952
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
39911
39953
|
style: rowIndentStyle,
|
|
39912
39954
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(HStack, {
|
|
39913
39955
|
align: "center",
|
|
39914
39956
|
gap: "xs",
|
|
39915
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(ExpandButton, { isExpanded: row.getIsExpanded() }),
|
|
39957
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(ExpandButton, { isExpanded: row.getIsExpanded() }), cellRenderer(row)]
|
|
39916
39958
|
})
|
|
39917
39959
|
});
|
|
39918
39960
|
} }), ...rest];
|
|
39919
|
-
}, [columnConfig]);
|
|
39961
|
+
}, [columnConfig, indentSize]);
|
|
39920
39962
|
const columnDefs = getColumnDefs(wrappedColumnConfig);
|
|
39921
39963
|
const columnPinning = (0, react.useMemo)(() => getColumnPinning(wrappedColumnConfig), [wrappedColumnConfig]);
|
|
39922
39964
|
const table$1 = (0, __tanstack_react_table.useReactTable)({
|
|
39923
39965
|
data: data !== null && data !== void 0 ? data : EMPTY_ARRAY$1,
|
|
39924
39966
|
columns: columnDefs,
|
|
39925
|
-
getSubRows: getSubRows$
|
|
39967
|
+
getSubRows: getSubRows$3,
|
|
39926
39968
|
getCoreRowModel: (0, __tanstack_react_table.getCoreRowModel)(),
|
|
39927
39969
|
getExpandedRowModel: (0, __tanstack_react_table.getExpandedRowModel)(),
|
|
39928
39970
|
state: {
|
|
@@ -39931,7 +39973,7 @@ function ExpandableDataTable({ data, isLoading, isError, columnConfig, component
|
|
|
39931
39973
|
},
|
|
39932
39974
|
onExpandedChange: setExpanded,
|
|
39933
39975
|
autoResetPageIndex: false,
|
|
39934
|
-
getRowId: getRowId$
|
|
39976
|
+
getRowId: getRowId$2
|
|
39935
39977
|
});
|
|
39936
39978
|
const { rows } = table$1.getExpandedRowModel();
|
|
39937
39979
|
const dependencies$1 = (0, react.useMemo)(() => [expanded], [expanded]);
|
|
@@ -39959,6 +40001,23 @@ function ExpandableDataTable({ data, isLoading, isError, columnConfig, component
|
|
|
39959
40001
|
}), [onRowClick, isRowClickable])
|
|
39960
40002
|
});
|
|
39961
40003
|
}
|
|
40004
|
+
var _excluded$5 = [
|
|
40005
|
+
"durationMinutes",
|
|
40006
|
+
"className",
|
|
40007
|
+
"showLessThanOneMinuteForZero"
|
|
40008
|
+
];
|
|
40009
|
+
var DurationSpan = (0, react.forwardRef)((_ref, ref) => {
|
|
40010
|
+
let { durationMinutes, className, showLessThanOneMinuteForZero = false } = _ref, restProps = _objectWithoutProperties(_ref, _excluded$5);
|
|
40011
|
+
const { t } = (0, react_i18next.useTranslation)();
|
|
40012
|
+
const { formatMinutesAsDuration: formatMinutesAsDuration$1 } = useIntlFormatter();
|
|
40013
|
+
const formattedDuration = durationMinutes !== 0 ? formatMinutesAsDuration$1(durationMinutes) : showLessThanOneMinuteForZero ? t("timeTracking:label.less_than_one_minute", "< 1 min") : t("timeTracking:label.zero_minutes", "0 min");
|
|
40014
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, _objectSpread2(_objectSpread2({}, restProps), {}, {
|
|
40015
|
+
className,
|
|
40016
|
+
ref,
|
|
40017
|
+
children: formattedDuration
|
|
40018
|
+
}));
|
|
40019
|
+
});
|
|
40020
|
+
DurationSpan.displayName = "DurationSpan";
|
|
39962
40021
|
const UnifiedReportTableCellContent = ({ cell, column, breadcrumb }) => {
|
|
39963
40022
|
var _cell$format;
|
|
39964
40023
|
const { formatDate: formatDate$1, formatNumber: formatNumber$1 } = useIntlFormatter();
|
|
@@ -39987,6 +40046,13 @@ const UnifiedReportTableCellContent = ({ cell, column, breadcrumb }) => {
|
|
|
39987
40046
|
variant,
|
|
39988
40047
|
children: formatNumber$1(cellValue.value)
|
|
39989
40048
|
});
|
|
40049
|
+
else if (isDurationCellValue(cellValue)) content = /* @__PURE__ */ (0, react_jsx_runtime.jsx)(DurationSpan, {
|
|
40050
|
+
ellipsis: true,
|
|
40051
|
+
weight,
|
|
40052
|
+
variant,
|
|
40053
|
+
durationMinutes: cellValue.value,
|
|
40054
|
+
showLessThanOneMinuteForZero: true
|
|
40055
|
+
});
|
|
39990
40056
|
else if (isEmptyCellValue(cellValue)) return null;
|
|
39991
40057
|
else content = /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
39992
40058
|
ellipsis: true,
|
|
@@ -40052,8 +40118,8 @@ const buildNestedColumnConfig = (columns) => {
|
|
|
40052
40118
|
return makeLeafColumn(col);
|
|
40053
40119
|
});
|
|
40054
40120
|
};
|
|
40055
|
-
const getSubRows$
|
|
40056
|
-
var COMPONENT_NAME$
|
|
40121
|
+
const getSubRows$2 = (row) => row.rows ? asMutable(row.rows) : void 0;
|
|
40122
|
+
var COMPONENT_NAME$4 = "UnifiedReport";
|
|
40057
40123
|
const UnifiedReportTable = () => {
|
|
40058
40124
|
var _report$displayName;
|
|
40059
40125
|
const { t } = (0, react_i18next.useTranslation)();
|
|
@@ -40088,12 +40154,12 @@ const UnifiedReportTable = () => {
|
|
|
40088
40154
|
isLoading: data === void 0 || isLoading,
|
|
40089
40155
|
isError,
|
|
40090
40156
|
columnConfig,
|
|
40091
|
-
componentName: COMPONENT_NAME$
|
|
40157
|
+
componentName: COMPONENT_NAME$4,
|
|
40092
40158
|
slots: {
|
|
40093
40159
|
ErrorState: UnifiedReportErrorState,
|
|
40094
40160
|
EmptyState: UnifiedReportEmptyState
|
|
40095
40161
|
},
|
|
40096
|
-
getSubRows: getSubRows$
|
|
40162
|
+
getSubRows: getSubRows$2,
|
|
40097
40163
|
getRowId: (row) => row.rowKey
|
|
40098
40164
|
});
|
|
40099
40165
|
};
|
|
@@ -40640,7 +40706,7 @@ var ONBOARDING_CALL_COVERAGE_ITEMS = [
|
|
|
40640
40706
|
_objectSpread2({ key: "bookkeeping_process" }, translationKey("callBookings:label.onboarding_cover_bookkeeping_process", "Walk through our bookkeeping process")),
|
|
40641
40707
|
_objectSpread2({ key: "connect_bank_and_cards" }, translationKey("callBookings:label.onboarding_cover_connect_bank_and_cards", "Connect your business bank accounts and credit cards"))
|
|
40642
40708
|
];
|
|
40643
|
-
var EmptyState$
|
|
40709
|
+
var EmptyState$2 = ({ onBookCall }) => {
|
|
40644
40710
|
const { t } = (0, react_i18next.useTranslation)();
|
|
40645
40711
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(VStack, {
|
|
40646
40712
|
gap: "md",
|
|
@@ -40707,7 +40773,7 @@ const CallBooking = ({ callBooking, onBookCall }) => {
|
|
|
40707
40773
|
const countdownLabel = useCallBookingCountdownLabel(callBooking === null || callBooking === void 0 ? void 0 : callBooking.eventStartAt);
|
|
40708
40774
|
if (callBooking == null) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Container, {
|
|
40709
40775
|
name: "CallBooking",
|
|
40710
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(EmptyState$
|
|
40776
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(EmptyState$2, { onBookCall })
|
|
40711
40777
|
});
|
|
40712
40778
|
const isOnboardingCall = callBooking.purpose === CallBookingPurpose.BOOKKEEPING_ONBOARDING;
|
|
40713
40779
|
const purpose = isOnboardingCall ? t("callBookings:label.onboarding_call", "Onboarding call") : t("callBookings:label.ad_hoc_call", "Ad hoc call");
|
|
@@ -40852,7 +40918,7 @@ const useKeepInMobileViewport = () => {
|
|
|
40852
40918
|
};
|
|
40853
40919
|
};
|
|
40854
40920
|
var BookkeepingOverviewTasksContent = ({ callBooking, showCallBookingCard, tasksMobile, tasksStringOverrides, onBookCall, onClickReconnectAccounts }) => {
|
|
40855
|
-
|
|
40921
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [showCallBookingCard && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(CallBooking, {
|
|
40856
40922
|
callBooking,
|
|
40857
40923
|
onBookCall
|
|
40858
40924
|
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Tasks, {
|
|
@@ -40860,14 +40926,6 @@ var BookkeepingOverviewTasksContent = ({ callBooking, showCallBookingCard, tasks
|
|
|
40860
40926
|
stringOverrides: tasksStringOverrides,
|
|
40861
40927
|
onClickReconnectAccounts
|
|
40862
40928
|
})] });
|
|
40863
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Tasks, {
|
|
40864
|
-
mobile: tasksMobile,
|
|
40865
|
-
stringOverrides: tasksStringOverrides,
|
|
40866
|
-
onClickReconnectAccounts
|
|
40867
|
-
}), showCallBookingCard && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(CallBooking, {
|
|
40868
|
-
callBooking,
|
|
40869
|
-
onBookCall
|
|
40870
|
-
})] });
|
|
40871
40929
|
};
|
|
40872
40930
|
const BookkeepingOverview = ({ title, showTitle = true, onClickReconnectAccounts, stringOverrides, slotProps }) => {
|
|
40873
40931
|
var _slotProps$profitAndL, _stringOverrides$prof, _stringOverrides$prof2, _stringOverrides$prof3;
|
|
@@ -41716,7 +41774,7 @@ const TripsTableHeader = ({ onRecordTrip }) => {
|
|
|
41716
41774
|
} }
|
|
41717
41775
|
});
|
|
41718
41776
|
};
|
|
41719
|
-
var COMPONENT_NAME$
|
|
41777
|
+
var COMPONENT_NAME$3 = "TripsTable";
|
|
41720
41778
|
var TripColumns = /* @__PURE__ */ function(TripColumns$1) {
|
|
41721
41779
|
TripColumns$1["TripDate"] = "TripDate";
|
|
41722
41780
|
TripColumns$1["Vehicle"] = "Vehicle";
|
|
@@ -41820,7 +41878,7 @@ const TripsTable = ({ data, isLoading, isError, paginationProps, onDeleteTrip, o
|
|
|
41820
41878
|
isError,
|
|
41821
41879
|
columnConfig,
|
|
41822
41880
|
paginationProps,
|
|
41823
|
-
componentName: COMPONENT_NAME$
|
|
41881
|
+
componentName: COMPONENT_NAME$3,
|
|
41824
41882
|
slots
|
|
41825
41883
|
})]
|
|
41826
41884
|
});
|
|
@@ -43035,7 +43093,7 @@ var HomeOfficeDeductionSchema = effect.Schema.Struct({
|
|
|
43035
43093
|
homeOfficeArea: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.NullishOr(effect.Schema.Number)), effect.Schema.fromKey("home_office_area"))
|
|
43036
43094
|
});
|
|
43037
43095
|
var VehicleDeductionSchema = effect.Schema.Struct({ useMileageDeduction: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.NullishOr(effect.Schema.Boolean)), effect.Schema.fromKey("use_mileage_deduction")) });
|
|
43038
|
-
var DeductionsSchema
|
|
43096
|
+
var DeductionsSchema = effect.Schema.Struct({
|
|
43039
43097
|
homeOffice: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.NullishOr(HomeOfficeDeductionSchema)), effect.Schema.fromKey("home_office")),
|
|
43040
43098
|
vehicle: effect.Schema.NullishOr(VehicleDeductionSchema)
|
|
43041
43099
|
});
|
|
@@ -43054,7 +43112,7 @@ var StateConfigurationSchema = effect.Schema.Struct({
|
|
|
43054
43112
|
var UsConfigurationSchema = effect.Schema.Struct({
|
|
43055
43113
|
federal: effect.Schema.NullishOr(FederalConfigurationSchema),
|
|
43056
43114
|
state: effect.Schema.NullishOr(StateConfigurationSchema),
|
|
43057
|
-
deductions: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.NullishOr(DeductionsSchema
|
|
43115
|
+
deductions: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.NullishOr(DeductionsSchema)), effect.Schema.fromKey("deductions"))
|
|
43058
43116
|
});
|
|
43059
43117
|
const TaxProfileSchema = effect.Schema.Struct({
|
|
43060
43118
|
taxCountryCode: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.NullishOr(effect.Schema.String)), effect.Schema.fromKey("tax_country_code")),
|
|
@@ -43552,108 +43610,22 @@ const StateTaxSection = ({ form, isReadOnly, isDesktop }) => {
|
|
|
43552
43610
|
]
|
|
43553
43611
|
});
|
|
43554
43612
|
};
|
|
43555
|
-
var
|
|
43556
|
-
|
|
43557
|
-
|
|
43558
|
-
|
|
43559
|
-
|
|
43560
|
-
|
|
43561
|
-
|
|
43562
|
-
});
|
|
43563
|
-
var
|
|
43564
|
-
|
|
43565
|
-
|
|
43566
|
-
homeOffice: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.NullishOr(HomeOfficeSchema)), effect.Schema.fromKey("home_office")),
|
|
43567
|
-
qualifiedTipDeduction: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("qualified_tip_deduction")),
|
|
43568
|
-
qualifiedOvertimeDeduction: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("qualified_overtime_deduction")),
|
|
43569
|
-
selfEmploymentTaxDeduction: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("self_employment_tax_deduction")),
|
|
43570
|
-
preAdjustedGrossIncomeDeduction: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("pre_adjusted_gross_income_deduction"))
|
|
43571
|
-
});
|
|
43572
|
-
var IncomeSchema = effect.Schema.Struct({
|
|
43573
|
-
w2Income: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("w2_income")),
|
|
43574
|
-
w2Withholding: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("w2_withholding")),
|
|
43575
|
-
businessRevenue: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("business_revenue")),
|
|
43576
|
-
total: effect.Schema.Number
|
|
43577
|
-
});
|
|
43578
|
-
var AdjustedGrossIncomeSchema = effect.Schema.Struct({
|
|
43579
|
-
income: IncomeSchema,
|
|
43580
|
-
deductions: DeductionsSchema,
|
|
43581
|
-
totalAdjustedGrossIncome: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("total_adjusted_gross_income"))
|
|
43582
|
-
});
|
|
43583
|
-
var MedicareSurtaxSchema = effect.Schema.Struct({
|
|
43584
|
-
medicareSurtaxIncome: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("medicare_surtax_income")),
|
|
43585
|
-
medicareSurtaxRate: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.String), effect.Schema.fromKey("medicare_surtax_rate")),
|
|
43586
|
-
medicareSurtaxOwed: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("medicare_surtax_owed"))
|
|
43587
|
-
});
|
|
43588
|
-
var MedicareTaxSchema = effect.Schema.Struct({
|
|
43589
|
-
medicareIncome: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("medicare_income")),
|
|
43590
|
-
medicareTaxRate: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.String), effect.Schema.fromKey("medicare_tax_rate")),
|
|
43591
|
-
medicareTaxOwed: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("medicare_tax_owed"))
|
|
43592
|
-
});
|
|
43593
|
-
var SocialSecurityTaxSchema = effect.Schema.Struct({
|
|
43594
|
-
socialSecurityIncome: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("social_security_income")),
|
|
43595
|
-
socialSecurityTaxRate: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.String), effect.Schema.fromKey("social_security_tax_rate")),
|
|
43596
|
-
socialSecurityTaxOwed: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("social_security_tax_owed"))
|
|
43597
|
-
});
|
|
43598
|
-
var FederalIncomeTaxSchema = effect.Schema.Struct({
|
|
43599
|
-
federalDeductions: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("federal_deductions")),
|
|
43600
|
-
qualifiedBusinessIncomeDeduction: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("qualified_business_income_deduction")),
|
|
43601
|
-
qbiEffectiveRate: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.String), effect.Schema.fromKey("qbi_effective_rate")),
|
|
43602
|
-
taxableIncome: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("taxable_income")),
|
|
43603
|
-
effectiveFederalTaxRate: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.String), effect.Schema.fromKey("effective_federal_tax_rate")),
|
|
43604
|
-
federalIncomeTaxOwed: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("federal_income_tax_owed"))
|
|
43605
|
-
});
|
|
43606
|
-
var TotalFederalTaxSchema = effect.Schema.Struct({
|
|
43607
|
-
federalIncomeTaxOwed: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("federal_income_tax_owed")),
|
|
43608
|
-
socialSecurityTaxOwed: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("social_security_tax_owed")),
|
|
43609
|
-
medicareTaxOwed: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("medicare_tax_owed")),
|
|
43610
|
-
medicareSurtaxOwed: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("medicare_surtax_owed")),
|
|
43611
|
-
w2Withholdings: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("w2_withholdings")),
|
|
43612
|
-
totalFederalTaxOwed: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("total_federal_tax_owed"))
|
|
43613
|
-
});
|
|
43614
|
-
var UsFederalTaxSchema = effect.Schema.Struct({
|
|
43615
|
-
federalIncomeTax: (0, effect.pipe)(effect.Schema.propertySignature(FederalIncomeTaxSchema), effect.Schema.fromKey("federal_income_tax")),
|
|
43616
|
-
socialSecurityTax: (0, effect.pipe)(effect.Schema.propertySignature(SocialSecurityTaxSchema), effect.Schema.fromKey("social_security_tax")),
|
|
43617
|
-
medicareTax: (0, effect.pipe)(effect.Schema.propertySignature(MedicareTaxSchema), effect.Schema.fromKey("medicare_tax")),
|
|
43618
|
-
medicareSurtax: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.NullishOr(MedicareSurtaxSchema)), effect.Schema.fromKey("medicare_surtax")),
|
|
43619
|
-
totalFederalTax: (0, effect.pipe)(effect.Schema.propertySignature(TotalFederalTaxSchema), effect.Schema.fromKey("total_federal_tax"))
|
|
43620
|
-
});
|
|
43621
|
-
var StateIncomeTaxSchema = effect.Schema.Struct({
|
|
43622
|
-
stateAgi: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("state_agi")),
|
|
43623
|
-
stateDeductions: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("state_deductions")),
|
|
43624
|
-
stateTaxableIncome: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("state_taxable_income")),
|
|
43625
|
-
effectiveStateTaxRate: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.String), effect.Schema.fromKey("effective_state_tax_rate")),
|
|
43626
|
-
stateIncomeTaxOwed: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("state_income_tax_owed"))
|
|
43627
|
-
});
|
|
43628
|
-
var StateAdditionalTaxSchema = effect.Schema.Struct({
|
|
43629
|
-
taxName: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.String), effect.Schema.fromKey("tax_name")),
|
|
43630
|
-
taxRate: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.String), effect.Schema.fromKey("tax_rate")),
|
|
43631
|
-
taxableAmount: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("taxable_amount")),
|
|
43632
|
-
taxOwed: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("tax_owed"))
|
|
43633
|
-
});
|
|
43634
|
-
var TotalStateTaxSchema = effect.Schema.Struct({
|
|
43635
|
-
stateIncomeTaxOwed: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("state_income_tax_owed")),
|
|
43636
|
-
additionalTaxesOwed: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("additional_taxes_owed")),
|
|
43637
|
-
stateWithholdings: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("state_withholdings")),
|
|
43638
|
-
totalStateTaxOwed: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("total_state_tax_owed"))
|
|
43639
|
-
});
|
|
43640
|
-
var UsStateTaxSchema = effect.Schema.Struct({
|
|
43641
|
-
stateCode: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.String), effect.Schema.fromKey("state_code")),
|
|
43642
|
-
stateName: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.String), effect.Schema.fromKey("state_name")),
|
|
43643
|
-
filingStatus: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.String), effect.Schema.fromKey("filing_status")),
|
|
43644
|
-
stateIncomeTax: (0, effect.pipe)(effect.Schema.propertySignature(StateIncomeTaxSchema), effect.Schema.fromKey("state_income_tax")),
|
|
43645
|
-
additionalTaxes: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Array(StateAdditionalTaxSchema)), effect.Schema.fromKey("additional_taxes")),
|
|
43646
|
-
totalStateTax: (0, effect.pipe)(effect.Schema.propertySignature(TotalStateTaxSchema), effect.Schema.fromKey("total_state_tax"))
|
|
43647
|
-
});
|
|
43648
|
-
var TaxesSchema = effect.Schema.Struct({
|
|
43649
|
-
usFederal: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.NullishOr(UsFederalTaxSchema)), effect.Schema.fromKey("us_federal")),
|
|
43650
|
-
usState: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.NullishOr(UsStateTaxSchema)), effect.Schema.fromKey("us_state"))
|
|
43613
|
+
var TaxDetailsValueSchema = effect.Schema.Union(UnifiedCellValueCurrencySchema, UnifiedCellValueDecimalSchema, UnifiedCellValuePercentageSchema, UnifiedCellValueUnknownSchema);
|
|
43614
|
+
var taxDetailsRowFields = {
|
|
43615
|
+
rowKey: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.String), effect.Schema.fromKey("row_key")),
|
|
43616
|
+
label: effect.Schema.String,
|
|
43617
|
+
value: effect.Schema.optional(TaxDetailsValueSchema),
|
|
43618
|
+
operator: effect.Schema.optional(effect.Schema.String)
|
|
43619
|
+
};
|
|
43620
|
+
var TaxDetailsRowSchema = effect.Schema.Struct(_objectSpread2(_objectSpread2({}, taxDetailsRowFields), {}, { breakdown: effect.Schema.optional(effect.Schema.Array(effect.Schema.suspend(() => TaxDetailsRowSchema))) }));
|
|
43621
|
+
var TaxDetailsMetaSchema = effect.Schema.Struct({
|
|
43622
|
+
year: effect.Schema.Number,
|
|
43623
|
+
filingStatus: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.String), effect.Schema.fromKey("filing_status"))
|
|
43651
43624
|
});
|
|
43652
43625
|
var TaxDetailsSchema = effect.Schema.Struct({
|
|
43653
|
-
|
|
43654
|
-
|
|
43655
|
-
|
|
43656
|
-
taxes: TaxesSchema
|
|
43626
|
+
type: effect.Schema.String,
|
|
43627
|
+
meta: TaxDetailsMetaSchema,
|
|
43628
|
+
rows: effect.Schema.Array(TaxDetailsRowSchema)
|
|
43657
43629
|
});
|
|
43658
43630
|
const TaxDetailsResponseSchema = effect.Schema.Struct({ data: TaxDetailsSchema });
|
|
43659
43631
|
var TAX_DETAILS_TAG_KEY = "#tax-details";
|
|
@@ -44135,21 +44107,23 @@ const TaxBanner = ({ uncategorizedCount, uncategorizedAmount }) => {
|
|
|
44135
44107
|
})
|
|
44136
44108
|
});
|
|
44137
44109
|
};
|
|
44138
|
-
|
|
44139
|
-
|
|
44140
|
-
|
|
44141
|
-
|
|
44142
|
-
|
|
44143
|
-
|
|
44144
|
-
|
|
44145
|
-
return
|
|
44146
|
-
|
|
44147
|
-
|
|
44148
|
-
|
|
44110
|
+
const ResponsiveDetailView = ({ name: name$1, slots, children, mobileProps }) => {
|
|
44111
|
+
const { isDesktop } = useSizeClass();
|
|
44112
|
+
if (isDesktop) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(BaseDetailView, {
|
|
44113
|
+
name: name$1,
|
|
44114
|
+
slots,
|
|
44115
|
+
children
|
|
44116
|
+
});
|
|
44117
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(VStack, {
|
|
44118
|
+
className: (0, classnames.default)("Layer__ResponsiveDetailView", mobileProps === null || mobileProps === void 0 ? void 0 : mobileProps.className),
|
|
44119
|
+
gap: "md",
|
|
44120
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(slots.Header, {}), children]
|
|
44121
|
+
});
|
|
44149
44122
|
};
|
|
44150
44123
|
var TaxSummarySectionTypeSchema = effect.Schema.Literal("federal", "state");
|
|
44151
44124
|
var TaxSummarySectionSchema = effect.Schema.Struct({
|
|
44152
44125
|
type: TaxSummarySectionTypeSchema,
|
|
44126
|
+
key: effect.Schema.NullishOr(effect.Schema.String),
|
|
44153
44127
|
label: effect.Schema.String,
|
|
44154
44128
|
total: effect.Schema.Number,
|
|
44155
44129
|
taxesPaid: (0, effect.pipe)(effect.Schema.propertySignature(effect.Schema.Number), effect.Schema.fromKey("taxes_paid")),
|
|
@@ -44207,447 +44181,91 @@ function useTaxSummary({ year, reportingBasis, fullYearProjection, enabled = tru
|
|
|
44207
44181
|
};
|
|
44208
44182
|
}()));
|
|
44209
44183
|
}
|
|
44210
|
-
|
|
44211
|
-
|
|
44212
|
-
|
|
44213
|
-
|
|
44214
|
-
|
|
44215
|
-
|
|
44216
|
-
|
|
44217
|
-
|
|
44218
|
-
|
|
44219
|
-
|
|
44220
|
-
|
|
44221
|
-
})
|
|
44222
|
-
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(AnimatedPresenceElement, {
|
|
44223
|
-
motionKey: "expandable-content",
|
|
44224
|
-
variant: "expand",
|
|
44225
|
-
isOpen: isExpanded,
|
|
44226
|
-
style: { overflow: "hidden" },
|
|
44227
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(VStack, {
|
|
44228
|
-
className: "Layer__ExpandableCard__Content",
|
|
44229
|
-
children
|
|
44230
|
-
})
|
|
44231
|
-
})]
|
|
44232
|
-
});
|
|
44233
|
-
};
|
|
44234
|
-
const ResponsiveDetailView = ({ name: name$1, slots, children, mobileProps }) => {
|
|
44235
|
-
const { isDesktop } = useSizeClass();
|
|
44236
|
-
if (isDesktop) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(BaseDetailView, {
|
|
44237
|
-
name: name$1,
|
|
44238
|
-
slots,
|
|
44239
|
-
children
|
|
44240
|
-
});
|
|
44241
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(VStack, {
|
|
44242
|
-
className: (0, classnames.default)("Layer__ResponsiveDetailView", mobileProps === null || mobileProps === void 0 ? void 0 : mobileProps.className),
|
|
44243
|
-
gap: "md",
|
|
44244
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(slots.Header, {}), children]
|
|
44245
|
-
});
|
|
44246
|
-
};
|
|
44247
|
-
let TaxTableRowVariant = /* @__PURE__ */ function(TaxTableRowVariant$1) {
|
|
44248
|
-
TaxTableRowVariant$1["Standard"] = "standard";
|
|
44249
|
-
TaxTableRowVariant$1["Nested"] = "nested";
|
|
44250
|
-
TaxTableRowVariant$1["SectionTotal"] = "section-total";
|
|
44251
|
-
TaxTableRowVariant$1["Total"] = "total";
|
|
44252
|
-
TaxTableRowVariant$1["Empty"] = "empty";
|
|
44253
|
-
return TaxTableRowVariant$1;
|
|
44254
|
-
}({});
|
|
44255
|
-
var VARIANT_CLASS_MAP = {
|
|
44256
|
-
[TaxTableRowVariant.Standard]: "Layer__TaxTable__Row",
|
|
44257
|
-
[TaxTableRowVariant.Nested]: "Layer__TaxTable__Row Layer__TaxTable__Row--nested",
|
|
44258
|
-
[TaxTableRowVariant.SectionTotal]: "Layer__TaxTable__Row Layer__TaxTable__Row--section-total",
|
|
44259
|
-
[TaxTableRowVariant.Total]: "Layer__TaxTable__Row Layer__TaxTable__Row--total",
|
|
44260
|
-
[TaxTableRowVariant.Empty]: "Layer__TaxTable__Row Layer__TaxTable__Row--empty"
|
|
44261
|
-
};
|
|
44262
|
-
var BOLD_VARIANTS = new Set([TaxTableRowVariant.SectionTotal, TaxTableRowVariant.Total]);
|
|
44263
|
-
const TaxTableRow = ({ label: label$50, value, variant, sign }) => {
|
|
44264
|
-
const { isMobile } = useSizeClass();
|
|
44265
|
-
const isEmpty = variant === TaxTableRowVariant.Empty;
|
|
44266
|
-
const isBold = BOLD_VARIANTS.has(variant);
|
|
44267
|
-
const mobileClass = isMobile ? "Layer__UI__Table-Row--mobile" : "";
|
|
44268
|
-
const className = (0, classnames.default)(VARIANT_CLASS_MAP[variant], mobileClass);
|
|
44269
|
-
const formattedLabel = sign ? `${sign} ${label$50}` : label$50;
|
|
44270
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Row, {
|
|
44271
|
-
className,
|
|
44272
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Cell, { children: !isEmpty && (isBold ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44273
|
-
weight: "bold",
|
|
44274
|
-
children: formattedLabel
|
|
44275
|
-
}) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, { children: formattedLabel })) }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Cell, { children: !isEmpty && (typeof value === "number" ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(MoneySpan, {
|
|
44276
|
-
weight: isBold ? "bold" : void 0,
|
|
44277
|
-
amount: value
|
|
44278
|
-
}) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44279
|
-
weight: isBold ? "bold" : void 0,
|
|
44280
|
-
children: value
|
|
44281
|
-
})) })]
|
|
44282
|
-
});
|
|
44283
|
-
};
|
|
44284
|
-
const AdjustedGrossIncomeTable = ({ data }) => {
|
|
44285
|
-
const { t } = (0, react_i18next.useTranslation)();
|
|
44286
|
-
const { income, deductions, totalAdjustedGrossIncome } = data;
|
|
44287
|
-
const deductionRows = (0, react.useMemo)(() => [
|
|
44288
|
-
{
|
|
44289
|
-
key: "businessExpenses",
|
|
44290
|
-
label: t("taxEstimates:label.deductible_expenses", "Deductible Expenses"),
|
|
44291
|
-
getAmount: (d) => d.businessExpenses
|
|
44292
|
-
},
|
|
44293
|
-
{
|
|
44294
|
-
key: "vehicleExpense",
|
|
44295
|
-
label: t("taxEstimates:label.deductible_mileage_expenses", "Deductible Mileage Expenses"),
|
|
44296
|
-
getAmount: (d) => {
|
|
44297
|
-
var _d$vehicleExpense$amo, _d$vehicleExpense;
|
|
44298
|
-
return (_d$vehicleExpense$amo = (_d$vehicleExpense = d.vehicleExpense) === null || _d$vehicleExpense === void 0 ? void 0 : _d$vehicleExpense.amount) !== null && _d$vehicleExpense$amo !== void 0 ? _d$vehicleExpense$amo : 0;
|
|
44299
|
-
}
|
|
44300
|
-
},
|
|
44301
|
-
{
|
|
44302
|
-
key: "homeOffice",
|
|
44303
|
-
label: t("taxEstimates:label.home_office_deduction", "Home Office Deduction"),
|
|
44304
|
-
getAmount: (d) => {
|
|
44305
|
-
var _d$homeOffice$amount, _d$homeOffice;
|
|
44306
|
-
return (_d$homeOffice$amount = (_d$homeOffice = d.homeOffice) === null || _d$homeOffice === void 0 ? void 0 : _d$homeOffice.amount) !== null && _d$homeOffice$amount !== void 0 ? _d$homeOffice$amount : 0;
|
|
44307
|
-
}
|
|
44308
|
-
},
|
|
44309
|
-
{
|
|
44310
|
-
key: "selfEmploymentTaxDeduction",
|
|
44311
|
-
label: t("taxEstimates:label.self_employment_deduction", "Self-Employment Deduction"),
|
|
44312
|
-
getAmount: (d) => d.selfEmploymentTaxDeduction
|
|
44313
|
-
},
|
|
44314
|
-
{
|
|
44315
|
-
key: "qualifiedTipDeduction",
|
|
44316
|
-
label: t("taxEstimates:label.qualified_tip_deduction", "Qualified Tip Deduction"),
|
|
44317
|
-
getAmount: (d) => d.qualifiedTipDeduction
|
|
44318
|
-
},
|
|
44319
|
-
{
|
|
44320
|
-
key: "qualifiedOvertimeDeduction",
|
|
44321
|
-
label: t("taxEstimates:label.qualified_overtime_deduction", "Qualified Overtime Deduction"),
|
|
44322
|
-
getAmount: (d) => d.qualifiedOvertimeDeduction
|
|
44323
|
-
}
|
|
44324
|
-
], [t]);
|
|
44325
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table, {
|
|
44326
|
-
className: "Layer__TaxTable",
|
|
44327
|
-
"aria-label": t("taxEstimates:label.adjusted_gross_income", "Adjusted Gross Income"),
|
|
44328
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableHeader, {
|
|
44329
|
-
className: "Layer__TaxTable__Header",
|
|
44330
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Row, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Column, {
|
|
44331
|
-
isRowHeader: true,
|
|
44332
|
-
children: t("common:label.description", "Description")
|
|
44333
|
-
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Column, { children: t("common:label.amount", "Amount") })] })
|
|
44334
|
-
}), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableBody, { children: [
|
|
44335
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44336
|
-
label: t("taxEstimates:label.business_income", "Business Income"),
|
|
44337
|
-
value: income.businessRevenue,
|
|
44338
|
-
variant: TaxTableRowVariant.Standard
|
|
44339
|
-
}),
|
|
44340
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44341
|
-
label: t("taxEstimates:label.w2_income", "W-2 Income"),
|
|
44342
|
-
value: income.w2Income,
|
|
44343
|
-
variant: TaxTableRowVariant.Standard
|
|
44344
|
-
}),
|
|
44345
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44346
|
-
label: t("taxEstimates:label.deductions", "Deductions"),
|
|
44347
|
-
value: deductions.preAdjustedGrossIncomeDeduction,
|
|
44348
|
-
variant: TaxTableRowVariant.Standard
|
|
44349
|
-
}),
|
|
44350
|
-
deductionRows.map(({ key, label: label$50, getAmount }) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44351
|
-
label: label$50,
|
|
44352
|
-
sign: "-",
|
|
44353
|
-
value: getAmount(deductions),
|
|
44354
|
-
variant: TaxTableRowVariant.Nested
|
|
44355
|
-
}, key)),
|
|
44356
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44357
|
-
label: t("taxEstimates:label.adjusted_gross_income", "Adjusted Gross Income"),
|
|
44358
|
-
value: totalAdjustedGrossIncome,
|
|
44359
|
-
variant: TaxTableRowVariant.Total
|
|
44360
|
-
})
|
|
44361
|
-
] })]
|
|
44362
|
-
});
|
|
44363
|
-
};
|
|
44364
|
-
const FederalTaxTable = ({ data, adjustedGrossIncome }) => {
|
|
44365
|
-
const { t } = (0, react_i18next.useTranslation)();
|
|
44366
|
-
const { federalIncomeTax, socialSecurityTax, medicareTax, medicareSurtax, totalFederalTax } = data;
|
|
44367
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table, {
|
|
44368
|
-
className: "Layer__TaxTable",
|
|
44369
|
-
"aria-label": t("taxEstimates:label.federal_tax", "Federal Tax"),
|
|
44370
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableHeader, {
|
|
44371
|
-
className: "Layer__TaxTable__Header",
|
|
44372
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Row, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Column, {
|
|
44373
|
-
isRowHeader: true,
|
|
44374
|
-
children: t("common:label.description", "Description")
|
|
44375
|
-
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Column, { children: t("common:label.amount", "Amount") })] })
|
|
44376
|
-
}), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableBody, { children: [
|
|
44377
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44378
|
-
label: t("taxEstimates:label.adjusted_gross_income", "Adjusted Gross Income"),
|
|
44379
|
-
value: adjustedGrossIncome,
|
|
44380
|
-
variant: TaxTableRowVariant.Standard
|
|
44381
|
-
}),
|
|
44382
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44383
|
-
label: t("taxEstimates:label.federal_deductions", "Federal Deductions"),
|
|
44384
|
-
sign: "-",
|
|
44385
|
-
value: federalIncomeTax.federalDeductions,
|
|
44386
|
-
variant: TaxTableRowVariant.Nested
|
|
44387
|
-
}),
|
|
44388
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44389
|
-
label: t("taxEstimates:label.business_income_deduction_rate", "Business Income Deduction ({{rate}})", { rate: federalIncomeTax.qbiEffectiveRate }),
|
|
44390
|
-
sign: "-",
|
|
44391
|
-
value: federalIncomeTax.qualifiedBusinessIncomeDeduction,
|
|
44392
|
-
variant: TaxTableRowVariant.Nested
|
|
44393
|
-
}),
|
|
44394
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44395
|
-
label: t("taxEstimates:label.taxable_income", "Taxable Income"),
|
|
44396
|
-
value: federalIncomeTax.taxableIncome,
|
|
44397
|
-
variant: TaxTableRowVariant.Standard
|
|
44398
|
-
}),
|
|
44399
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44400
|
-
label: t("taxEstimates:label.federal_tax_rate", "Federal Tax Rate"),
|
|
44401
|
-
sign: "×",
|
|
44402
|
-
value: federalIncomeTax.effectiveFederalTaxRate,
|
|
44403
|
-
variant: TaxTableRowVariant.Nested
|
|
44404
|
-
}),
|
|
44405
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44406
|
-
label: t("taxEstimates:label.federal_tax_estimate_owed", "Federal Tax Estimate (Owed)"),
|
|
44407
|
-
value: federalIncomeTax.federalIncomeTaxOwed,
|
|
44408
|
-
variant: TaxTableRowVariant.SectionTotal
|
|
44409
|
-
}),
|
|
44410
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44411
|
-
label: "",
|
|
44412
|
-
value: "",
|
|
44413
|
-
variant: TaxTableRowVariant.Empty
|
|
44414
|
-
}),
|
|
44415
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44416
|
-
label: t("taxEstimates:label.taxable_social_security_income", "Taxable Social Security Income"),
|
|
44417
|
-
value: socialSecurityTax.socialSecurityIncome,
|
|
44418
|
-
variant: TaxTableRowVariant.Standard
|
|
44419
|
-
}),
|
|
44420
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44421
|
-
label: t("taxEstimates:label.social_security_tax_rate", "Social Security Tax Rate"),
|
|
44422
|
-
sign: "×",
|
|
44423
|
-
value: socialSecurityTax.socialSecurityTaxRate,
|
|
44424
|
-
variant: TaxTableRowVariant.Nested
|
|
44425
|
-
}),
|
|
44426
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44427
|
-
label: t("taxEstimates:label.social_security_tax_estimate_owed", "Social Security Tax Estimate (Owed)"),
|
|
44428
|
-
value: socialSecurityTax.socialSecurityTaxOwed,
|
|
44429
|
-
variant: TaxTableRowVariant.SectionTotal
|
|
44430
|
-
}),
|
|
44431
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44432
|
-
label: "",
|
|
44433
|
-
value: "",
|
|
44434
|
-
variant: TaxTableRowVariant.Empty
|
|
44435
|
-
}),
|
|
44436
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44437
|
-
label: t("taxEstimates:label.taxable_medicare_income", "Taxable Medicare Income"),
|
|
44438
|
-
value: medicareTax.medicareIncome,
|
|
44439
|
-
variant: TaxTableRowVariant.Standard
|
|
44440
|
-
}),
|
|
44441
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44442
|
-
label: t("taxEstimates:label.medicare_tax_rate", "Medicare Tax Rate"),
|
|
44443
|
-
sign: "×",
|
|
44444
|
-
value: medicareTax.medicareTaxRate,
|
|
44445
|
-
variant: TaxTableRowVariant.Nested
|
|
44446
|
-
}),
|
|
44447
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44448
|
-
label: t("taxEstimates:label.medicare_tax_estimate_owed", "Medicare Tax Estimate (Owed)"),
|
|
44449
|
-
value: medicareTax.medicareTaxOwed,
|
|
44450
|
-
variant: TaxTableRowVariant.SectionTotal
|
|
44451
|
-
}),
|
|
44452
|
-
medicareSurtax && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [
|
|
44453
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44454
|
-
label: "",
|
|
44455
|
-
value: "",
|
|
44456
|
-
variant: TaxTableRowVariant.Empty
|
|
44457
|
-
}),
|
|
44458
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44459
|
-
label: t("taxEstimates:label.taxable_medicare_surtax_income", "Taxable Medicare Surtax Income"),
|
|
44460
|
-
value: medicareSurtax.medicareSurtaxIncome,
|
|
44461
|
-
variant: TaxTableRowVariant.Standard
|
|
44462
|
-
}),
|
|
44463
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44464
|
-
label: t("taxEstimates:label.medicare_surtax_rate", "Medicare Surtax Rate"),
|
|
44465
|
-
sign: "×",
|
|
44466
|
-
value: medicareSurtax.medicareSurtaxRate,
|
|
44467
|
-
variant: TaxTableRowVariant.Nested
|
|
44468
|
-
}),
|
|
44469
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44470
|
-
label: t("taxEstimates:label.medicare_surtax_estimate_owed", "Medicare Surtax Estimate (Owed)"),
|
|
44471
|
-
value: medicareSurtax.medicareSurtaxOwed,
|
|
44472
|
-
variant: TaxTableRowVariant.SectionTotal
|
|
44473
|
-
})
|
|
44474
|
-
] }),
|
|
44475
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44476
|
-
label: "",
|
|
44477
|
-
value: "",
|
|
44478
|
-
variant: TaxTableRowVariant.Empty
|
|
44479
|
-
}),
|
|
44480
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44481
|
-
label: t("taxEstimates:label.federal_tax_estimate_owed", "Federal Tax Estimate (Owed)"),
|
|
44482
|
-
value: totalFederalTax.federalIncomeTaxOwed,
|
|
44483
|
-
variant: TaxTableRowVariant.Standard
|
|
44484
|
-
}),
|
|
44485
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44486
|
-
label: t("taxEstimates:label.social_security_tax_estimate_owed", "Social Security Tax Estimate (Owed)"),
|
|
44487
|
-
sign: "+",
|
|
44488
|
-
value: totalFederalTax.socialSecurityTaxOwed,
|
|
44489
|
-
variant: TaxTableRowVariant.Nested
|
|
44490
|
-
}),
|
|
44491
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44492
|
-
label: t("taxEstimates:label.medicare_tax_estimate_owed", "Medicare Tax Estimate (Owed)"),
|
|
44493
|
-
sign: "+",
|
|
44494
|
-
value: totalFederalTax.medicareTaxOwed,
|
|
44495
|
-
variant: TaxTableRowVariant.Nested
|
|
44496
|
-
}),
|
|
44497
|
-
medicareSurtax && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44498
|
-
label: t("taxEstimates:label.medicare_surtax_estimate_owed", "Medicare Surtax Estimate (Owed)"),
|
|
44499
|
-
sign: "+",
|
|
44500
|
-
value: totalFederalTax.medicareSurtaxOwed,
|
|
44501
|
-
variant: TaxTableRowVariant.Nested
|
|
44502
|
-
}),
|
|
44503
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44504
|
-
label: t("taxEstimates:label.amount_applied_federal_w2", "Amount Applied from Federal W-2 Withholding"),
|
|
44505
|
-
sign: "-",
|
|
44506
|
-
value: totalFederalTax.w2Withholdings,
|
|
44507
|
-
variant: TaxTableRowVariant.Nested
|
|
44508
|
-
}),
|
|
44509
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44510
|
-
label: t("taxEstimates:label.total_federal_tax_estimate", "Total Federal Tax Estimate"),
|
|
44511
|
-
value: totalFederalTax.totalFederalTaxOwed,
|
|
44512
|
-
variant: TaxTableRowVariant.Total
|
|
44513
|
-
})
|
|
44514
|
-
] })]
|
|
44515
|
-
});
|
|
44184
|
+
var _excluded$1 = [
|
|
44185
|
+
"condition",
|
|
44186
|
+
"cases",
|
|
44187
|
+
"contexts"
|
|
44188
|
+
];
|
|
44189
|
+
const tConditional = (translate, key, _ref) => {
|
|
44190
|
+
let { condition, cases, contexts } = _ref;
|
|
44191
|
+
return translate(key, _objectSpread2(_objectSpread2({}, _objectWithoutProperties(_ref, _excluded$1)), {}, {
|
|
44192
|
+
context: contexts === null || contexts === void 0 ? void 0 : contexts[condition],
|
|
44193
|
+
defaultValue: cases[condition]
|
|
44194
|
+
}));
|
|
44516
44195
|
};
|
|
44517
|
-
|
|
44196
|
+
var AmountWithLabel = ({ slotProps }) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(VStack, {
|
|
44197
|
+
className: "Layer__TaxSummaryCard__AmountWithLabel",
|
|
44198
|
+
gap: "2xs",
|
|
44199
|
+
align: "start",
|
|
44200
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(MoneySpan, _objectSpread2({}, slotProps.MoneySpan)), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Badge, _objectSpread2({
|
|
44201
|
+
size: BadgeSize.SMALL,
|
|
44202
|
+
variant: BadgeVariant.NEUTRAL
|
|
44203
|
+
}, slotProps.Badge))]
|
|
44204
|
+
});
|
|
44205
|
+
const EquationRow = ({ section, size = "md" }) => {
|
|
44518
44206
|
const { t } = (0, react_i18next.useTranslation)();
|
|
44519
|
-
const { stateIncomeTax, additionalTaxes, totalStateTax } = data;
|
|
44520
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Table, {
|
|
44521
|
-
className: "Layer__TaxTable",
|
|
44522
|
-
"aria-label": t("taxEstimates:label.state_tax", "State Tax"),
|
|
44523
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TableHeader, {
|
|
44524
|
-
className: "Layer__TaxTable__Header",
|
|
44525
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Row, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Column, {
|
|
44526
|
-
isRowHeader: true,
|
|
44527
|
-
children: t("common:label.description", "Description")
|
|
44528
|
-
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Column, { children: t("common:label.amount", "Amount") })] })
|
|
44529
|
-
}), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TableBody, { children: [
|
|
44530
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44531
|
-
label: t("taxEstimates:label.state_adjusted_gross_income", "State Adjusted Gross Income"),
|
|
44532
|
-
value: stateIncomeTax.stateAgi,
|
|
44533
|
-
variant: TaxTableRowVariant.Standard
|
|
44534
|
-
}),
|
|
44535
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44536
|
-
label: t("taxEstimates:label.state_deductions", "State Deductions"),
|
|
44537
|
-
sign: "-",
|
|
44538
|
-
value: stateIncomeTax.stateDeductions,
|
|
44539
|
-
variant: TaxTableRowVariant.Nested
|
|
44540
|
-
}),
|
|
44541
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44542
|
-
label: t("taxEstimates:label.state_taxable_income", "State Taxable Income"),
|
|
44543
|
-
value: stateIncomeTax.stateTaxableIncome,
|
|
44544
|
-
variant: TaxTableRowVariant.Standard
|
|
44545
|
-
}),
|
|
44546
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44547
|
-
label: t("taxEstimates:label.state_tax_rate", "State Tax Rate"),
|
|
44548
|
-
sign: "×",
|
|
44549
|
-
value: stateIncomeTax.effectiveStateTaxRate,
|
|
44550
|
-
variant: TaxTableRowVariant.Nested
|
|
44551
|
-
}),
|
|
44552
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44553
|
-
label: t("taxEstimates:label.state_income_tax_estimate_owed", "State Income Tax Estimate (Owed)"),
|
|
44554
|
-
value: stateIncomeTax.stateIncomeTaxOwed,
|
|
44555
|
-
variant: TaxTableRowVariant.SectionTotal
|
|
44556
|
-
}),
|
|
44557
|
-
additionalTaxes.length > 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44558
|
-
label: "",
|
|
44559
|
-
value: "",
|
|
44560
|
-
variant: TaxTableRowVariant.Empty
|
|
44561
|
-
}), additionalTaxes.map((additionalTax, index) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react.default.Fragment, { children: [
|
|
44562
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44563
|
-
label: t("taxEstimates:label.taxable_amount_tax_name", "Taxable Amount for {{taxName}}", { taxName: additionalTax.taxName }),
|
|
44564
|
-
value: additionalTax.taxableAmount,
|
|
44565
|
-
variant: TaxTableRowVariant.Standard
|
|
44566
|
-
}),
|
|
44567
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44568
|
-
label: t("taxEstimates:label.tax_name_rate", "{{taxName}} Rate", { taxName: additionalTax.taxName }),
|
|
44569
|
-
sign: "×",
|
|
44570
|
-
value: additionalTax.taxRate,
|
|
44571
|
-
variant: TaxTableRowVariant.Nested
|
|
44572
|
-
}),
|
|
44573
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44574
|
-
label: t("taxEstimates:label.tax_name_estimate_owed", "{{taxName}} Estimate (Owed)", { taxName: additionalTax.taxName }),
|
|
44575
|
-
value: additionalTax.taxOwed,
|
|
44576
|
-
variant: TaxTableRowVariant.SectionTotal
|
|
44577
|
-
}),
|
|
44578
|
-
index < additionalTaxes.length - 1 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44579
|
-
label: "",
|
|
44580
|
-
value: "",
|
|
44581
|
-
variant: TaxTableRowVariant.Empty
|
|
44582
|
-
})
|
|
44583
|
-
] }, additionalTax.taxName))] }),
|
|
44584
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44585
|
-
label: "",
|
|
44586
|
-
value: "",
|
|
44587
|
-
variant: TaxTableRowVariant.Empty
|
|
44588
|
-
}),
|
|
44589
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44590
|
-
label: t("taxEstimates:label.state_income_tax_estimate_owed", "State Income Tax Estimate (Owed)"),
|
|
44591
|
-
value: totalStateTax.stateIncomeTaxOwed,
|
|
44592
|
-
variant: TaxTableRowVariant.Standard
|
|
44593
|
-
}),
|
|
44594
|
-
additionalTaxes.length > 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44595
|
-
label: t("taxEstimates:label.additional_state_taxes_estimate_owed", "Additional State Taxes Estimate (Owed)"),
|
|
44596
|
-
sign: "+",
|
|
44597
|
-
value: totalStateTax.additionalTaxesOwed,
|
|
44598
|
-
variant: TaxTableRowVariant.Nested
|
|
44599
|
-
}),
|
|
44600
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44601
|
-
label: t("taxEstimates:label.amount_applied_state_withholding", "Amount Applied from State Withholding"),
|
|
44602
|
-
sign: "-",
|
|
44603
|
-
value: totalStateTax.stateWithholdings,
|
|
44604
|
-
variant: TaxTableRowVariant.Nested
|
|
44605
|
-
}),
|
|
44606
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxTableRow, {
|
|
44607
|
-
label: t("taxEstimates:label.total_state_tax_estimate", "Total State Tax Estimate"),
|
|
44608
|
-
value: totalStateTax.totalStateTaxOwed,
|
|
44609
|
-
variant: TaxTableRowVariant.Total
|
|
44610
|
-
})
|
|
44611
|
-
] })]
|
|
44612
|
-
});
|
|
44613
|
-
};
|
|
44614
|
-
const TaxDetailsExpandableCardHeading = ({ title, amount }) => {
|
|
44615
|
-
const { isMobile } = useSizeClass();
|
|
44616
44207
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(HStack, {
|
|
44617
|
-
className: "
|
|
44618
|
-
|
|
44619
|
-
gap: "xs",
|
|
44208
|
+
className: "Layer__TaxSummaryCard__Equation",
|
|
44209
|
+
gap: size === "lg" ? "md" : "sm",
|
|
44620
44210
|
children: [
|
|
44621
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(
|
|
44622
|
-
|
|
44623
|
-
|
|
44211
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(AmountWithLabel, { slotProps: {
|
|
44212
|
+
MoneySpan: {
|
|
44213
|
+
amount: section.total,
|
|
44214
|
+
size
|
|
44215
|
+
},
|
|
44216
|
+
Badge: { children: t("common:label.total", "Total") }
|
|
44217
|
+
} }),
|
|
44218
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44219
|
+
className: "Layer__TaxSummaryCard__Operator",
|
|
44220
|
+
size,
|
|
44221
|
+
variant: "subtle",
|
|
44222
|
+
children: "-"
|
|
44624
44223
|
}),
|
|
44625
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(
|
|
44626
|
-
|
|
44627
|
-
|
|
44628
|
-
|
|
44629
|
-
|
|
44630
|
-
|
|
44224
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(AmountWithLabel, { slotProps: {
|
|
44225
|
+
MoneySpan: {
|
|
44226
|
+
amount: section.taxesPaid,
|
|
44227
|
+
size
|
|
44228
|
+
},
|
|
44229
|
+
Badge: { children: t("taxEstimates:label.taxes_paid", "Taxes Paid") }
|
|
44230
|
+
} }),
|
|
44231
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44232
|
+
className: "Layer__TaxSummaryCard__Operator",
|
|
44233
|
+
size,
|
|
44234
|
+
variant: "subtle",
|
|
44235
|
+
children: "="
|
|
44236
|
+
}),
|
|
44237
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(AmountWithLabel, { slotProps: {
|
|
44238
|
+
MoneySpan: {
|
|
44239
|
+
amount: section.taxesOwed,
|
|
44240
|
+
size,
|
|
44241
|
+
weight: "bold"
|
|
44242
|
+
},
|
|
44243
|
+
Badge: { children: t("taxEstimates:label.taxes_owed", "Taxes Owed") }
|
|
44244
|
+
} })
|
|
44631
44245
|
]
|
|
44632
44246
|
});
|
|
44633
44247
|
};
|
|
44248
|
+
var PlusCircle = () => /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
44249
|
+
className: "Layer__TaxSummaryCard__OperatorCircle",
|
|
44250
|
+
"aria-hidden": true,
|
|
44251
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(PlusIcon_default, { size: 24 })
|
|
44252
|
+
});
|
|
44253
|
+
var ArrowCircle = () => /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
44254
|
+
className: "Layer__TaxSummaryCard__OperatorCircle",
|
|
44255
|
+
"aria-hidden": true,
|
|
44256
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ArrowRightCircle_default, { size: 24 })
|
|
44257
|
+
});
|
|
44634
44258
|
const TaxSummaryCardDesktop = ({ data }) => {
|
|
44635
44259
|
const { t } = (0, react_i18next.useTranslation)();
|
|
44636
44260
|
const { formatDate: formatDate$1 } = useIntlFormatter();
|
|
44637
44261
|
const { fullYearProjection } = useFullYearProjection();
|
|
44638
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(
|
|
44262
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
44639
44263
|
className: "Layer__TaxSummaryCard",
|
|
44640
|
-
children: [
|
|
44641
|
-
|
|
44642
|
-
|
|
44643
|
-
|
|
44644
|
-
align: "center",
|
|
44645
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)(VStack, {
|
|
44646
|
-
justify: "center",
|
|
44647
|
-
align: "center",
|
|
44648
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44264
|
+
children: [
|
|
44265
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(VStack, {
|
|
44266
|
+
className: "Layer__TaxSummaryCard__Cell Layer__TaxSummaryCard__Cell--header",
|
|
44267
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44649
44268
|
size: "md",
|
|
44650
|
-
variant: "subtle",
|
|
44651
44269
|
children: tConditional(t, "taxEstimates:label.taxes_owed", {
|
|
44652
44270
|
condition: fullYearProjection ? "projected" : "default",
|
|
44653
44271
|
cases: {
|
|
@@ -44656,95 +44274,75 @@ const TaxSummaryCardDesktop = ({ data }) => {
|
|
|
44656
44274
|
},
|
|
44657
44275
|
contexts: { projected: "projected" }
|
|
44658
44276
|
})
|
|
44659
|
-
})
|
|
44277
|
+
})
|
|
44278
|
+
}),
|
|
44279
|
+
data.sections.map((section, index) => {
|
|
44280
|
+
var _section$key;
|
|
44281
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(HStack, {
|
|
44282
|
+
className: "Layer__TaxSummaryCard__Cell Layer__TaxSummaryCard__Cell--header Layer__TaxSummaryCard__Cell--bordered",
|
|
44283
|
+
align: "center",
|
|
44284
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
44285
|
+
className: "Layer__TaxSummaryCard__OperatorIconAnchor",
|
|
44286
|
+
children: index === 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ArrowCircle, {}) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(PlusCircle, {})
|
|
44287
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44288
|
+
size: "md",
|
|
44289
|
+
children: section.label
|
|
44290
|
+
})]
|
|
44291
|
+
}, (_section$key = section.key) !== null && _section$key !== void 0 ? _section$key : section.label);
|
|
44292
|
+
}),
|
|
44293
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)(VStack, {
|
|
44294
|
+
className: "Layer__TaxSummaryCard__Cell",
|
|
44295
|
+
gap: "2xs",
|
|
44296
|
+
align: "start",
|
|
44297
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(MoneySpan, {
|
|
44660
44298
|
size: "xl",
|
|
44661
44299
|
weight: "bold",
|
|
44662
44300
|
amount: data.projectedTaxesOwed
|
|
44663
|
-
})
|
|
44664
|
-
}), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(VStack, {
|
|
44665
|
-
align: "center",
|
|
44666
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44301
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44667
44302
|
size: "sm",
|
|
44668
44303
|
variant: "subtle",
|
|
44669
|
-
children: t("taxEstimates:label.
|
|
44670
|
-
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44671
|
-
size: "md",
|
|
44672
|
-
children: formatDate$1(data.taxesDueAt)
|
|
44304
|
+
children: t("taxEstimates:label.taxes_due_at", "Taxes due on {{date}}", { date: formatDate$1(data.taxesDueAt) })
|
|
44673
44305
|
})]
|
|
44674
|
-
})
|
|
44675
|
-
|
|
44676
|
-
|
|
44677
|
-
|
|
44678
|
-
|
|
44679
|
-
|
|
44680
|
-
|
|
44681
|
-
|
|
44682
|
-
|
|
44683
|
-
|
|
44684
|
-
variant: "subtle",
|
|
44685
|
-
children: section.label
|
|
44686
|
-
}),
|
|
44687
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(MoneySpan, {
|
|
44688
|
-
size: "xl",
|
|
44689
|
-
weight: "bold",
|
|
44690
|
-
amount: section.taxesOwed
|
|
44691
|
-
}),
|
|
44692
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44693
|
-
size: "md",
|
|
44694
|
-
variant: "subtle",
|
|
44695
|
-
children: "="
|
|
44696
|
-
}),
|
|
44697
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(MoneySpan, {
|
|
44698
|
-
size: "lg",
|
|
44699
|
-
amount: section.total
|
|
44700
|
-
}),
|
|
44701
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44702
|
-
size: "md",
|
|
44703
|
-
variant: "subtle",
|
|
44704
|
-
children: "-"
|
|
44705
|
-
}),
|
|
44706
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(MoneySpan, {
|
|
44707
|
-
size: "lg",
|
|
44708
|
-
amount: section.taxesPaid
|
|
44709
|
-
}),
|
|
44710
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {}),
|
|
44711
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {}),
|
|
44712
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44713
|
-
size: "sm",
|
|
44714
|
-
variant: "subtle",
|
|
44715
|
-
children: t("common:label.total", "Total")
|
|
44716
|
-
}),
|
|
44717
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {}),
|
|
44718
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44719
|
-
size: "sm",
|
|
44720
|
-
variant: "subtle",
|
|
44721
|
-
children: t("taxEstimates:label.taxes_paid", "Taxes Paid")
|
|
44722
|
-
})
|
|
44723
|
-
]
|
|
44724
|
-
}, section.label))
|
|
44306
|
+
}),
|
|
44307
|
+
data.sections.map((section) => {
|
|
44308
|
+
var _section$key2;
|
|
44309
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(VStack, {
|
|
44310
|
+
className: "Layer__TaxSummaryCard__Cell Layer__TaxSummaryCard__Cell--bordered",
|
|
44311
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(EquationRow, {
|
|
44312
|
+
section,
|
|
44313
|
+
size: "md"
|
|
44314
|
+
})
|
|
44315
|
+
}, (_section$key2 = section.key) !== null && _section$key2 !== void 0 ? _section$key2 : section.label);
|
|
44725
44316
|
})
|
|
44726
|
-
|
|
44317
|
+
]
|
|
44727
44318
|
});
|
|
44728
44319
|
};
|
|
44320
|
+
var SectionEquation = ({ section }) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(VStack, {
|
|
44321
|
+
className: "Layer__TaxSummaryCard__MobileSection",
|
|
44322
|
+
gap: "xs",
|
|
44323
|
+
align: "start",
|
|
44324
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44325
|
+
size: "sm",
|
|
44326
|
+
variant: "subtle",
|
|
44327
|
+
children: section.label
|
|
44328
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(EquationRow, { section })]
|
|
44329
|
+
});
|
|
44729
44330
|
const TaxSummaryCardMobile = ({ data }) => {
|
|
44730
44331
|
const { t } = (0, react_i18next.useTranslation)();
|
|
44731
44332
|
const { formatDate: formatDate$1 } = useIntlFormatter();
|
|
44732
44333
|
const { fullYearProjection } = useFullYearProjection();
|
|
44733
|
-
|
|
44734
|
-
|
|
44735
|
-
|
|
44736
|
-
children:
|
|
44737
|
-
className: "
|
|
44738
|
-
|
|
44739
|
-
|
|
44740
|
-
|
|
44741
|
-
|
|
44742
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)(VStack, {
|
|
44743
|
-
justify: "center",
|
|
44334
|
+
const [isExpanded, setIsExpanded] = (0, react.useState)(false);
|
|
44335
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Card, {
|
|
44336
|
+
className: "Layer__card--reset Layer__TaxSummaryCard--mobile",
|
|
44337
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(VStack, {
|
|
44338
|
+
className: "Layer__TaxSummaryCard__MobileCard",
|
|
44339
|
+
gap: "md",
|
|
44340
|
+
children: [
|
|
44341
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)(HStack, {
|
|
44342
|
+
justify: "space-between",
|
|
44744
44343
|
align: "center",
|
|
44745
44344
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44746
|
-
size: "
|
|
44747
|
-
variant: "subtle",
|
|
44345
|
+
size: "sm",
|
|
44748
44346
|
children: tConditional(t, "taxEstimates:label.taxes_owed", {
|
|
44749
44347
|
condition: fullYearProjection ? "projected" : "default",
|
|
44750
44348
|
cases: {
|
|
@@ -44753,81 +44351,62 @@ const TaxSummaryCardMobile = ({ data }) => {
|
|
|
44753
44351
|
},
|
|
44754
44352
|
contexts: { projected: "projected" }
|
|
44755
44353
|
})
|
|
44756
|
-
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(
|
|
44757
|
-
size: "xl",
|
|
44758
|
-
weight: "bold",
|
|
44759
|
-
amount: data.projectedTaxesOwed
|
|
44760
|
-
})]
|
|
44761
|
-
}), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(VStack, {
|
|
44762
|
-
align: "center",
|
|
44763
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44354
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44764
44355
|
size: "sm",
|
|
44765
44356
|
variant: "subtle",
|
|
44766
|
-
children: t("taxEstimates:label.
|
|
44767
|
-
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44768
|
-
size: "md",
|
|
44769
|
-
children: formatDate$1(data.taxesDueAt)
|
|
44357
|
+
children: t("taxEstimates:label.taxes_due_at", "Taxes due on {{date}}", { date: formatDate$1(data.taxesDueAt) })
|
|
44770
44358
|
})]
|
|
44771
|
-
})
|
|
44772
|
-
|
|
44773
|
-
|
|
44774
|
-
|
|
44775
|
-
|
|
44776
|
-
|
|
44777
|
-
|
|
44778
|
-
className: "
|
|
44779
|
-
|
|
44780
|
-
|
|
44781
|
-
|
|
44782
|
-
|
|
44783
|
-
|
|
44784
|
-
|
|
44785
|
-
|
|
44786
|
-
|
|
44787
|
-
|
|
44788
|
-
|
|
44789
|
-
|
|
44790
|
-
|
|
44791
|
-
|
|
44792
|
-
|
|
44793
|
-
|
|
44794
|
-
|
|
44795
|
-
|
|
44796
|
-
size: "md",
|
|
44797
|
-
amount: section.total
|
|
44798
|
-
}),
|
|
44799
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44800
|
-
size: "sm",
|
|
44801
|
-
variant: "subtle",
|
|
44802
|
-
children: "-"
|
|
44803
|
-
}),
|
|
44804
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(MoneySpan, {
|
|
44805
|
-
size: "md",
|
|
44806
|
-
amount: section.taxesPaid
|
|
44807
|
-
}),
|
|
44808
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {}),
|
|
44809
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {}),
|
|
44810
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44811
|
-
size: "sm",
|
|
44812
|
-
variant: "subtle",
|
|
44813
|
-
children: t("common:label.total", "Total")
|
|
44814
|
-
}),
|
|
44815
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {}),
|
|
44816
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44817
|
-
size: "sm",
|
|
44818
|
-
variant: "subtle",
|
|
44819
|
-
children: t("taxEstimates:label.taxes_paid", "Taxes Paid")
|
|
44820
|
-
})
|
|
44821
|
-
]
|
|
44822
|
-
}, section.label))
|
|
44823
|
-
})
|
|
44824
|
-
})]
|
|
44359
|
+
}),
|
|
44360
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(MoneySpan, {
|
|
44361
|
+
size: "xl",
|
|
44362
|
+
weight: "bold",
|
|
44363
|
+
amount: data.projectedTaxesOwed
|
|
44364
|
+
}),
|
|
44365
|
+
isExpanded && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(VStack, {
|
|
44366
|
+
className: "Layer__TaxSummaryCard__MobileSections",
|
|
44367
|
+
gap: "md",
|
|
44368
|
+
children: data.sections.map((section) => {
|
|
44369
|
+
var _section$key;
|
|
44370
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(SectionEquation, { section }, (_section$key = section.key) !== null && _section$key !== void 0 ? _section$key : section.label);
|
|
44371
|
+
})
|
|
44372
|
+
}),
|
|
44373
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(HStack, {
|
|
44374
|
+
className: "Layer__TaxSummaryCard__MobileToggleWrapper",
|
|
44375
|
+
justify: "center",
|
|
44376
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Button, {
|
|
44377
|
+
variant: "text",
|
|
44378
|
+
onClick: () => setIsExpanded((prev) => !prev),
|
|
44379
|
+
children: isExpanded ? t("common:label.hide_details", "Hide details") : t("common:label.show_details", "Show details")
|
|
44380
|
+
})
|
|
44381
|
+
})
|
|
44382
|
+
]
|
|
44383
|
+
})
|
|
44825
44384
|
});
|
|
44826
44385
|
};
|
|
44827
|
-
|
|
44828
|
-
|
|
44829
|
-
|
|
44830
|
-
|
|
44386
|
+
var TAX_SUMMARY_CARD_DESKTOP_BREAKPOINT = 1200;
|
|
44387
|
+
const TaxSummaryCard = () => {
|
|
44388
|
+
const { t } = (0, react_i18next.useTranslation)();
|
|
44389
|
+
const { year } = useTaxEstimatesYear();
|
|
44390
|
+
const { fullYearProjection } = useFullYearProjection();
|
|
44391
|
+
const { data, isLoading, isError } = useTaxSummary({
|
|
44392
|
+
year,
|
|
44393
|
+
fullYearProjection
|
|
44394
|
+
});
|
|
44395
|
+
const [viewportWidth] = useWindowSize();
|
|
44396
|
+
const isDesktop = viewportWidth >= TAX_SUMMARY_CARD_DESKTOP_BREAKPOINT;
|
|
44397
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ConditionalBlock, {
|
|
44398
|
+
isLoading,
|
|
44399
|
+
isError,
|
|
44400
|
+
data,
|
|
44401
|
+
Loading: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Loader, {}),
|
|
44402
|
+
Error: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(DataState, {
|
|
44403
|
+
status: DataStateStatus.failed,
|
|
44404
|
+
title: t("taxEstimates:error.load_tax_estimates_summary", "We couldn't load your tax summary"),
|
|
44405
|
+
description: t("taxEstimates:error.while_loading_tax_summary", "An error occurred while loading your tax summary. Please check your connection and try again."),
|
|
44406
|
+
spacing: true
|
|
44407
|
+
}),
|
|
44408
|
+
children: ({ data: summary }) => isDesktop ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxSummaryCardDesktop, { data: summary }) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxSummaryCardMobile, { data: summary })
|
|
44409
|
+
});
|
|
44831
44410
|
};
|
|
44832
44411
|
const ResponsiveDetailHeader = ({ title, description: description$1 }) => {
|
|
44833
44412
|
const { isDesktop } = useSizeClass();
|
|
@@ -44970,120 +44549,144 @@ const TaxEstimatesHeader = ({ type }) => {
|
|
|
44970
44549
|
})]
|
|
44971
44550
|
});
|
|
44972
44551
|
};
|
|
44973
|
-
|
|
44974
|
-
|
|
44975
|
-
|
|
44552
|
+
const Operator = ({ sign }) => {
|
|
44553
|
+
if (!sign) return null;
|
|
44554
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
44555
|
+
className: "Layer__TaxDetails__Operator",
|
|
44556
|
+
size: "lg",
|
|
44557
|
+
variant: "subtle",
|
|
44558
|
+
"aria-hidden": "true",
|
|
44559
|
+
children: sign
|
|
44560
|
+
});
|
|
44561
|
+
};
|
|
44562
|
+
var TaxDetailsColumns = /* @__PURE__ */ function(TaxDetailsColumns$1) {
|
|
44563
|
+
TaxDetailsColumns$1["Label"] = "Label";
|
|
44564
|
+
TaxDetailsColumns$1["Amount"] = "Amount";
|
|
44565
|
+
return TaxDetailsColumns$1;
|
|
44566
|
+
}(TaxDetailsColumns || {});
|
|
44567
|
+
var COMPONENT_NAME$2 = "TaxDetails";
|
|
44568
|
+
var MobileExpandableCardsWrapper = ({ children, className }) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Card, {
|
|
44569
|
+
className: `Layer__card--reset ${className !== null && className !== void 0 ? className : ""}`,
|
|
44976
44570
|
children
|
|
44977
44571
|
});
|
|
44978
|
-
|
|
44572
|
+
var EmptyState$1 = () => {
|
|
44573
|
+
const { t } = (0, react_i18next.useTranslation)();
|
|
44574
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(DataState, {
|
|
44575
|
+
status: DataStateStatus.allDone,
|
|
44576
|
+
title: t("taxEstimates:empty.no_tax_details", "No tax details"),
|
|
44577
|
+
description: t("taxEstimates:empty.no_tax_details_description", "No tax details found"),
|
|
44578
|
+
spacing: true
|
|
44579
|
+
});
|
|
44580
|
+
};
|
|
44581
|
+
var ErrorState$4 = () => {
|
|
44582
|
+
const { t } = (0, react_i18next.useTranslation)();
|
|
44583
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(DataState, {
|
|
44584
|
+
status: DataStateStatus.failed,
|
|
44585
|
+
title: t("taxEstimates:error.load_tax_details", "We couldn't load your tax details"),
|
|
44586
|
+
description: t("taxEstimates:error.while_loading_tax_details", "An error occurred while loading your tax details. Please check your connection and try again."),
|
|
44587
|
+
spacing: true
|
|
44588
|
+
});
|
|
44589
|
+
};
|
|
44590
|
+
var TaxDetailsRowLabelCell = (row) => {
|
|
44591
|
+
if (row.original.operator !== void 0 && row.original.operator !== null) return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(HStack, {
|
|
44592
|
+
className: "Layer__TaxDetails__TaxDetailsRow--operator",
|
|
44593
|
+
align: "center",
|
|
44594
|
+
gap: "md",
|
|
44595
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(Operator, { sign: row.original.operator }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, { children: row.original.label })]
|
|
44596
|
+
});
|
|
44597
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, { children: row.original.label });
|
|
44598
|
+
};
|
|
44599
|
+
var makeAmountCellRenderer = ({ formatNumber: formatNumber$1, formatPercent: formatPercent$1 }) => {
|
|
44600
|
+
return function TaxDetailsAmountCell(row) {
|
|
44601
|
+
const { value } = row.original;
|
|
44602
|
+
if (value === void 0) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, { children: "-" });
|
|
44603
|
+
if (isPercentageCellValue(value)) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, { children: formatPercent$1(value.value, {
|
|
44604
|
+
maximumFractionDigits: 2,
|
|
44605
|
+
minimumFractionDigits: 2
|
|
44606
|
+
}) });
|
|
44607
|
+
if (isCurrencyCellValue(value)) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(MoneySpan, { amount: value.value });
|
|
44608
|
+
if (isDecimalCellValue(value)) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, { children: formatNumber$1(value.value, {
|
|
44609
|
+
maximumFractionDigits: 2,
|
|
44610
|
+
minimumFractionDigits: 0
|
|
44611
|
+
}) });
|
|
44612
|
+
const raw = value.value;
|
|
44613
|
+
if (typeof raw === "string" || typeof raw === "number" || typeof raw === "boolean") return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, { children: String(raw) });
|
|
44614
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, { children: "-" });
|
|
44615
|
+
};
|
|
44616
|
+
};
|
|
44617
|
+
var useColumnConfig = () => {
|
|
44618
|
+
const { t } = (0, react_i18next.useTranslation)();
|
|
44619
|
+
const { formatNumber: formatNumber$1, formatPercent: formatPercent$1 } = useIntlFormatter();
|
|
44620
|
+
return (0, react.useMemo)(() => [{
|
|
44621
|
+
id: TaxDetailsColumns.Label,
|
|
44622
|
+
header: t("taxEstimates:label.tax_details_label", "Label"),
|
|
44623
|
+
cell: TaxDetailsRowLabelCell,
|
|
44624
|
+
isRowHeader: true
|
|
44625
|
+
}, {
|
|
44626
|
+
id: TaxDetailsColumns.Amount,
|
|
44627
|
+
header: t("taxEstimates:label.tax_details_amount", "Amount"),
|
|
44628
|
+
cell: makeAmountCellRenderer({
|
|
44629
|
+
formatNumber: formatNumber$1,
|
|
44630
|
+
formatPercent: formatPercent$1
|
|
44631
|
+
})
|
|
44632
|
+
}], [
|
|
44633
|
+
t,
|
|
44634
|
+
formatNumber$1,
|
|
44635
|
+
formatPercent$1
|
|
44636
|
+
]);
|
|
44637
|
+
};
|
|
44638
|
+
var getSubRows$1 = (row) => {
|
|
44639
|
+
return row.breakdown ? asMutable(row.breakdown) : void 0;
|
|
44640
|
+
};
|
|
44641
|
+
var getRowId$1 = (row) => {
|
|
44642
|
+
return row.rowKey;
|
|
44643
|
+
};
|
|
44644
|
+
function TaxDetailsContent() {
|
|
44979
44645
|
const { t } = (0, react_i18next.useTranslation)();
|
|
44980
44646
|
const { year } = useTaxEstimatesYear();
|
|
44981
44647
|
const { fullYearProjection } = useFullYearProjection();
|
|
44982
|
-
const projectedCondition = fullYearProjection ? "projected" : "default";
|
|
44983
44648
|
const { data, isLoading, isError } = useTaxDetails({
|
|
44984
44649
|
year,
|
|
44985
44650
|
fullYearProjection
|
|
44986
44651
|
});
|
|
44987
|
-
const { data: summaryData, isLoading: isSummaryLoading } = useTaxSummary({
|
|
44988
|
-
year,
|
|
44989
|
-
fullYearProjection
|
|
44990
|
-
});
|
|
44991
44652
|
const { isDesktop } = useSizeClass();
|
|
44992
|
-
const
|
|
44993
|
-
taxableIncome: true,
|
|
44994
|
-
federalTaxes: true,
|
|
44995
|
-
stateTaxes: true
|
|
44996
|
-
});
|
|
44997
|
-
const toggleExpanded = (0, react.useCallback)((key) => {
|
|
44998
|
-
setExpanded((prev) => _objectSpread2(_objectSpread2({}, prev), {}, { [key]: !prev[key] }));
|
|
44999
|
-
}, []);
|
|
44653
|
+
const columnConfig = useColumnConfig();
|
|
45000
44654
|
const ExpandableCardsWrapper = isDesktop ? VStack : MobileExpandableCardsWrapper;
|
|
44655
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ConditionalBlock, {
|
|
44656
|
+
isLoading,
|
|
44657
|
+
isError,
|
|
44658
|
+
data,
|
|
44659
|
+
Loading: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Loader, {}),
|
|
44660
|
+
Error: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ErrorState$4, {}),
|
|
44661
|
+
children: ({ data: details }) => {
|
|
44662
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ExpandableCardsWrapper, {
|
|
44663
|
+
className: "Layer__TaxDetails__ExpandableCardsWrapper",
|
|
44664
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ExpandableDataTableProvider, { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ExpandableDataTable, {
|
|
44665
|
+
componentName: COMPONENT_NAME$2,
|
|
44666
|
+
ariaLabel: t("taxEstimates:label.tax_details", "Tax Details"),
|
|
44667
|
+
data: asMutable(details.rows),
|
|
44668
|
+
columnConfig,
|
|
44669
|
+
isLoading,
|
|
44670
|
+
isError,
|
|
44671
|
+
indentSize: isDesktop ? "sm" : "xs",
|
|
44672
|
+
slots: {
|
|
44673
|
+
EmptyState: EmptyState$1,
|
|
44674
|
+
ErrorState: ErrorState$4
|
|
44675
|
+
},
|
|
44676
|
+
getSubRows: getSubRows$1,
|
|
44677
|
+
getRowId: getRowId$1
|
|
44678
|
+
}) })
|
|
44679
|
+
});
|
|
44680
|
+
}
|
|
44681
|
+
});
|
|
44682
|
+
}
|
|
44683
|
+
var TaxDetailsHeader = () => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxEstimatesHeader, { type: TaxEstimatesHeaderType.Estimates });
|
|
44684
|
+
const TaxDetails = () => {
|
|
45001
44685
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(ResponsiveDetailView, {
|
|
45002
44686
|
name: "TaxDetails",
|
|
45003
44687
|
slots: { Header: TaxDetailsHeader },
|
|
45004
44688
|
mobileProps: { className: "Layer__TaxDetails--mobile" },
|
|
45005
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(
|
|
45006
|
-
isLoading: isSummaryLoading,
|
|
45007
|
-
isError,
|
|
45008
|
-
data: summaryData,
|
|
45009
|
-
Loading: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Loader, {}),
|
|
45010
|
-
Error: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(DataState, {
|
|
45011
|
-
status: DataStateStatus.failed,
|
|
45012
|
-
title: t("taxEstimates:error.load_tax_estimates_summary", "We couldn't load your tax summary"),
|
|
45013
|
-
description: t("taxEstimates:error.while_loading_tax_summary", "An error occurred while loading your tax summary. Please check your connection and try again."),
|
|
45014
|
-
spacing: true
|
|
45015
|
-
}),
|
|
45016
|
-
children: ({ data: summary }) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxSummaryCard, { data: summary })
|
|
45017
|
-
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ConditionalBlock, {
|
|
45018
|
-
isLoading,
|
|
45019
|
-
isError,
|
|
45020
|
-
data,
|
|
45021
|
-
Loading: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Loader, {}),
|
|
45022
|
-
Error: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(DataState, {
|
|
45023
|
-
status: DataStateStatus.failed,
|
|
45024
|
-
title: t("taxEstimates:error.load_tax_estimates", "We couldn't load your tax estimates"),
|
|
45025
|
-
description: t("taxEstimates:error.while_loading_tax_estimates", "An error occurred while loading your tax estimates. Please check your connection and try again."),
|
|
45026
|
-
spacing: true
|
|
45027
|
-
}),
|
|
45028
|
-
children: ({ data: details }) => {
|
|
45029
|
-
const usFederal = details.taxes.usFederal;
|
|
45030
|
-
const usState = details.taxes.usState;
|
|
45031
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(ExpandableCardsWrapper, { children: [
|
|
45032
|
-
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(ExpandableCard, {
|
|
45033
|
-
isExpanded: expanded.taxableIncome,
|
|
45034
|
-
onToggleExpanded: () => toggleExpanded("taxableIncome"),
|
|
45035
|
-
slots: { Heading: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxDetailsExpandableCardHeading, {
|
|
45036
|
-
title: tConditional(t, "taxEstimates:label.taxable_business_income", {
|
|
45037
|
-
condition: projectedCondition,
|
|
45038
|
-
cases: {
|
|
45039
|
-
default: "Taxable Business Income",
|
|
45040
|
-
projected: "Projected Taxable Business Income"
|
|
45041
|
-
},
|
|
45042
|
-
contexts: { projected: "projected" }
|
|
45043
|
-
}),
|
|
45044
|
-
amount: details.adjustedGrossIncome.totalAdjustedGrossIncome
|
|
45045
|
-
}) },
|
|
45046
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(AdjustedGrossIncomeTable, { data: details.adjustedGrossIncome })
|
|
45047
|
-
}),
|
|
45048
|
-
usFederal && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ExpandableCard, {
|
|
45049
|
-
isExpanded: expanded.federalTaxes,
|
|
45050
|
-
onToggleExpanded: () => toggleExpanded("federalTaxes"),
|
|
45051
|
-
slots: { Heading: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxDetailsExpandableCardHeading, {
|
|
45052
|
-
title: tConditional(t, "taxEstimates:label.federal_taxes", {
|
|
45053
|
-
condition: projectedCondition,
|
|
45054
|
-
cases: {
|
|
45055
|
-
default: "Federal Taxes",
|
|
45056
|
-
projected: "Projected Federal Taxes"
|
|
45057
|
-
},
|
|
45058
|
-
contexts: { projected: "projected" }
|
|
45059
|
-
}),
|
|
45060
|
-
amount: usFederal.totalFederalTax.totalFederalTaxOwed
|
|
45061
|
-
}) },
|
|
45062
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(FederalTaxTable, {
|
|
45063
|
-
data: usFederal,
|
|
45064
|
-
adjustedGrossIncome: details.adjustedGrossIncome.totalAdjustedGrossIncome
|
|
45065
|
-
})
|
|
45066
|
-
}),
|
|
45067
|
-
usState && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ExpandableCard, {
|
|
45068
|
-
isExpanded: expanded.stateTaxes,
|
|
45069
|
-
onToggleExpanded: () => toggleExpanded("stateTaxes"),
|
|
45070
|
-
slots: { Heading: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxDetailsExpandableCardHeading, {
|
|
45071
|
-
title: tConditional(t, "taxEstimates:label.taxes_by_state_name", {
|
|
45072
|
-
condition: projectedCondition,
|
|
45073
|
-
cases: {
|
|
45074
|
-
default: "State Taxes ({{stateName}})",
|
|
45075
|
-
projected: "Projected State Taxes ({{stateName}})"
|
|
45076
|
-
},
|
|
45077
|
-
contexts: { projected: "projected" },
|
|
45078
|
-
stateName: usState.stateName
|
|
45079
|
-
}),
|
|
45080
|
-
amount: usState.totalStateTax.totalStateTaxOwed
|
|
45081
|
-
}) },
|
|
45082
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(StateTaxTable, { data: usState })
|
|
45083
|
-
})
|
|
45084
|
-
] });
|
|
45085
|
-
}
|
|
45086
|
-
})]
|
|
44689
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxSummaryCard, {}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TaxDetailsContent, {})]
|
|
45087
44690
|
});
|
|
45088
44691
|
};
|
|
45089
44692
|
const resolveCategoryColor = ({ key }) => {
|
|
@@ -46211,6 +45814,30 @@ const useCatalogServicesGlobalCacheActions = () => {
|
|
|
46211
45814
|
forceReloadCatalogServices: (0, react.useCallback)(() => forceReload(({ tags }) => tags.includes(CATALOG_SERVICES_TAG_KEY)), [forceReload])
|
|
46212
45815
|
};
|
|
46213
45816
|
};
|
|
45817
|
+
const ExpandableCard = ({ children, isExpanded, onToggleExpanded, slots }) => {
|
|
45818
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Card, {
|
|
45819
|
+
className: "Layer__ExpandableCard",
|
|
45820
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
|
|
45821
|
+
type: "button",
|
|
45822
|
+
className: "Layer__ExpandableCard__Header",
|
|
45823
|
+
onClick: onToggleExpanded,
|
|
45824
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(HStack, {
|
|
45825
|
+
justify: "space-between",
|
|
45826
|
+
align: "center",
|
|
45827
|
+
children: [slots.Heading, /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ExpandButton, { isExpanded })]
|
|
45828
|
+
})
|
|
45829
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(AnimatedPresenceElement, {
|
|
45830
|
+
motionKey: "expandable-content",
|
|
45831
|
+
variant: "expand",
|
|
45832
|
+
isOpen: isExpanded,
|
|
45833
|
+
style: { overflow: "hidden" },
|
|
45834
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(VStack, {
|
|
45835
|
+
className: "Layer__ExpandableCard__Content",
|
|
45836
|
+
children
|
|
45837
|
+
})
|
|
45838
|
+
})]
|
|
45839
|
+
});
|
|
45840
|
+
};
|
|
46214
45841
|
var ARCHIVE_CATALOG_SERVICE_TAG_KEY = "#archive-catalog-service";
|
|
46215
45842
|
var ArchiveCatalogServiceResponseSchema = effect.Schema.Struct({ data: CatalogServiceSchema });
|
|
46216
45843
|
var archiveCatalogService = post(({ businessId, serviceId }) => `/v1/businesses/${businessId}/catalog/services/${serviceId}/archive`);
|
|
@@ -48042,10 +47669,10 @@ var TimeEntryDateCell = (0, react.memo)(function TimeEntryDateCell$1({ date }) {
|
|
|
48042
47669
|
return formatCalendarDate(date, formatDate$1);
|
|
48043
47670
|
});
|
|
48044
47671
|
var TimeEntryDurationCell = (0, react.memo)(function TimeEntryDurationCell$1({ durationMinutes }) {
|
|
48045
|
-
|
|
48046
|
-
|
|
48047
|
-
|
|
48048
|
-
|
|
47672
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(DurationSpan, {
|
|
47673
|
+
durationMinutes,
|
|
47674
|
+
showLessThanOneMinuteForZero: true
|
|
47675
|
+
});
|
|
48049
47676
|
});
|
|
48050
47677
|
var TimeEntryActionsCell = (0, react.memo)(function TimeEntryActionsCell$1({ entry }) {
|
|
48051
47678
|
const { t } = (0, react_i18next.useTranslation)();
|
|
@@ -48598,7 +48225,7 @@ var TimeTrackingStatsLegendSwatch = ({ color }) => /* @__PURE__ */ (0, react_jsx
|
|
|
48598
48225
|
})
|
|
48599
48226
|
});
|
|
48600
48227
|
var TimeTrackingStatsBreakdown = (0, react.memo)(function TimeTrackingStatsBreakdown$1({ entries }) {
|
|
48601
|
-
const {
|
|
48228
|
+
const { formatPercent: formatPercent$1 } = useIntlFormatter();
|
|
48602
48229
|
const chartData = (0, react.useMemo)(() => buildStackedChartData(entries), [entries]);
|
|
48603
48230
|
const chartTotalMinutes = (0, react.useMemo)(() => entries.reduce((total, entry) => total + entry.totalMinutes, 0), [entries]);
|
|
48604
48231
|
const chartKey = entries.map((entry) => entry.key).join("|");
|
|
@@ -48673,10 +48300,10 @@ var TimeTrackingStatsBreakdown = (0, react.memo)(function TimeTrackingStatsBreak
|
|
|
48673
48300
|
className: "Layer__TimeTrackingStats__LegendMeta",
|
|
48674
48301
|
gap: "2xs",
|
|
48675
48302
|
align: "baseline",
|
|
48676
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(
|
|
48303
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(DurationSpan, {
|
|
48677
48304
|
className: "Layer__TimeTrackingStats__LegendDuration",
|
|
48678
48305
|
size: "sm",
|
|
48679
|
-
|
|
48306
|
+
durationMinutes: totalMinutes
|
|
48680
48307
|
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Span, {
|
|
48681
48308
|
className: "Layer__TimeTrackingStats__LegendPercentage",
|
|
48682
48309
|
size: "sm",
|
|
@@ -48690,9 +48317,7 @@ var TimeTrackingStatsBreakdown = (0, react.memo)(function TimeTrackingStatsBreak
|
|
|
48690
48317
|
});
|
|
48691
48318
|
function TimeTrackingStatsContent({ summary }) {
|
|
48692
48319
|
const { t } = (0, react_i18next.useTranslation)();
|
|
48693
|
-
const { formatMinutesAsDuration: formatMinutesAsDuration$1 } = useIntlFormatter();
|
|
48694
48320
|
const serviceBreakdown = (0, react.useMemo)(() => buildServiceBreakdown(summary.byService, t("timeTracking:label.other", "Other")), [summary.byService, t]);
|
|
48695
|
-
const totalDurationDisplay = summary.totalMinutes > 0 ? formatMinutesAsDuration$1(summary.totalMinutes) : t("timeTracking:label.zero_minutes", "0 min");
|
|
48696
48321
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(VStack, {
|
|
48697
48322
|
className: "Layer__TimeTrackingStats__Content",
|
|
48698
48323
|
gap: "lg",
|
|
@@ -48724,10 +48349,10 @@ function TimeTrackingStatsContent({ summary }) {
|
|
|
48724
48349
|
size: "sm",
|
|
48725
48350
|
variant: "subtle",
|
|
48726
48351
|
children: t("common:label.this_period", "This Period")
|
|
48727
|
-
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(
|
|
48352
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(DurationSpan, {
|
|
48728
48353
|
className: "Layer__TimeTrackingStats__SummaryValue",
|
|
48729
48354
|
weight: "bold",
|
|
48730
|
-
|
|
48355
|
+
durationMinutes: summary.totalMinutes
|
|
48731
48356
|
})]
|
|
48732
48357
|
})]
|
|
48733
48358
|
})]
|