@layerfi/components 0.1.112 → 0.1.113

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.
@@ -64,13 +64,11 @@ const traditional = require("zustand/traditional");
64
64
  const index = require("effect/index");
65
65
  const effect = require("effect");
66
66
  const useSWRInfinite = require("swr/infinite");
67
- const _ = require("lodash");
68
67
  const useSWRMutation = require("swr/mutation");
69
68
  const react$1 = require("@floating-ui/react");
70
69
  const lucideReact = require("lucide-react");
71
70
  const reactAriaComponents = require("react-aria-components");
72
71
  const useResizeObserver = require("@react-hook/resize-observer");
73
- const reactMergeRefs = require("react-merge-refs");
74
72
  const Select$1 = require("react-select");
75
73
  const CurrencyInput = require("react-currency-input-field");
76
74
  const RDP = require("react-datepicker");
@@ -130,7 +128,7 @@ const LinkedAccountsContext = react.createContext({
130
128
  setAccountsToAddOpeningBalanceInModal: () => {
131
129
  }
132
130
  });
133
- const version = "0.1.112";
131
+ const version = "0.1.113";
134
132
  const pkg = {
135
133
  version
136
134
  };
@@ -173,7 +171,7 @@ const CUSTOM_PREFIX = "Layer-";
173
171
  const CUSTOM_HEADERS = {
174
172
  [`${CUSTOM_PREFIX}React-Version`]: pkg.version
175
173
  };
176
- const get = (url) => (baseUrl, accessToken, options2) => () => fetch(`${baseUrl}${url((options2 == null ? void 0 : options2.params) || {})}`, {
174
+ const get$1 = (url) => (baseUrl, accessToken, options2) => () => fetch(`${baseUrl}${url((options2 == null ? void 0 : options2.params) || {})}`, {
177
175
  headers: __spreadValues({
178
176
  "Authorization": "Bearer " + (accessToken || ""),
179
177
  "Content-Type": "application/json"
@@ -278,28 +276,28 @@ function toDefinedSearchParameters(input) {
278
276
  return [[key, String(value)]];
279
277
  }
280
278
  return [[key, value]];
281
- }).filter(([_2, value]) => value !== "").map(([key, value]) => [toSnakeCase(key), value]);
279
+ }).filter(([_, value]) => value !== "").map(([key, value]) => [toSnakeCase(key), value]);
282
280
  return new URLSearchParams(definedParameterPairs);
283
281
  }
284
- const getBalanceSheet = get(
282
+ const getBalanceSheet = get$1(
285
283
  ({ businessId, effectiveDate }) => {
286
284
  const parameters = toDefinedSearchParameters({ effectiveDate });
287
285
  return `/v1/businesses/${businessId}/reports/balance-sheet?${parameters}`;
288
286
  }
289
287
  );
290
- const getBalanceSheetCSV = get(
288
+ const getBalanceSheetCSV = get$1(
291
289
  ({ businessId, effectiveDate }) => {
292
290
  const parameters = toDefinedSearchParameters({ effectiveDate });
293
291
  return `/v1/businesses/${businessId}/reports/balance-sheet/exports/csv?${parameters}`;
294
292
  }
295
293
  );
296
- const getBalanceSheetExcel = get(
294
+ const getBalanceSheetExcel = get$1(
297
295
  ({ businessId, effectiveDate }) => {
298
296
  const parameters = toDefinedSearchParameters({ effectiveDate });
299
297
  return `/v1/businesses/${businessId}/reports/balance-sheet/exports/excel?${parameters}`;
300
298
  }
301
299
  );
302
- const getBankTransactions = get(
300
+ const getBankTransactions = get$1(
303
301
  ({
304
302
  businessId,
305
303
  cursor,
@@ -333,7 +331,7 @@ const categorizeBankTransaction = put(
333
331
  const matchBankTransaction = put(
334
332
  ({ businessId, bankTransactionId }) => `/v1/businesses/${businessId}/bank-transactions/${bankTransactionId}/match`
335
333
  );
336
- const getBankTransactionsExcel = get(({
334
+ const getBankTransactionsExcel = get$1(({
337
335
  businessId,
338
336
  categorized,
339
337
  direction,
@@ -354,16 +352,16 @@ const getBankTransactionsExcel = get(({
354
352
  });
355
353
  return `/v1/businesses/${businessId}/reports/transactions/exports/excel?${parameters}`;
356
354
  });
357
- const getBankTransactionMetadata = get(
355
+ const getBankTransactionMetadata = get$1(
358
356
  ({ businessId, bankTransactionId }) => `/v1/businesses/${businessId}/bank-transactions/${bankTransactionId}/metadata`
359
357
  );
360
358
  const updateBankTransactionMetadata = put(
361
359
  ({ businessId, bankTransactionId }) => `/v1/businesses/${businessId}/bank-transactions/${bankTransactionId}/metadata`
362
360
  );
363
- const listBankTransactionDocuments = get(
361
+ const listBankTransactionDocuments = get$1(
364
362
  ({ businessId, bankTransactionId }) => `/v1/businesses/${businessId}/bank-transactions/${bankTransactionId}/documents?content_disposition=ATTACHMENT`
365
363
  );
366
- const getBankTransactionDocument = get(
364
+ const getBankTransactionDocument = get$1(
367
365
  ({ businessId, bankTransactionId, documentId }) => `/v1/businesses/${businessId}/bank-transactions/${bankTransactionId}/documents/${documentId}?content_disposition=ATTACHMENT`
368
366
  );
369
367
  const archiveBankTransactionDocument = post(
@@ -386,10 +384,10 @@ const uploadBankTransactionDocument = (baseUrl, accessToken) => ({
386
384
  accessToken
387
385
  );
388
386
  };
389
- const getBills = get(
387
+ const getBills = get$1(
390
388
  ({ businessId, startDate, endDate, status, vendorId, cursor, limit = 15 }) => `/v1/businesses/${businessId}/bills?${vendorId ? `&vendor_id=${vendorId}` : ""}${cursor ? `&cursor=${cursor}` : ""}${startDate ? `&received_at_start=${startDate}` : ""}${endDate ? `&received_at_end=${endDate}` : ""}${status ? `&status=${status}` : ""}&limit=${limit}&sort_by=received_at&sort_order=DESC`
391
389
  );
392
- const getBill = get(
390
+ const getBill = get$1(
393
391
  ({ businessId, billId }) => `/v1/businesses/${businessId}/bills/${billId}`
394
392
  );
395
393
  const updateBill = post(
@@ -401,7 +399,7 @@ const createBill = post(
401
399
  const createBillPayment = post(
402
400
  ({ businessId }) => `/v1/businesses/${businessId}/bills/bill-payments`
403
401
  );
404
- const getBusiness = get(({ businessId }) => `/v1/businesses/${businessId}`);
402
+ const getBusiness = get$1(({ businessId }) => `/v1/businesses/${businessId}`);
405
403
  const updateBusiness = put(
406
404
  ({ businessId }) => `/v1/businesses/${businessId}`
407
405
  );
@@ -414,13 +412,13 @@ const updateAccount = put(
414
412
  const createChildAccount = post(
415
413
  ({ businessId, accountId }) => `/v1/businesses/${businessId}/ledger/accounts/${accountId}/create-child-account`
416
414
  );
417
- const getLedgerAccountsLines = get(
415
+ const getLedgerAccountsLines = get$1(
418
416
  ({ businessId, accountId, includeReversals }) => `/v1/businesses/${businessId}/ledger/accounts/${accountId}/lines${includeReversals === "true" ? "?include_reversals=true" : ""}`
419
417
  );
420
- const getLedgerAccountsEntry = get(
418
+ const getLedgerAccountsEntry = get$1(
421
419
  ({ businessId, entryId }) => `/v1/businesses/${businessId}/ledger/entries/${entryId}`
422
420
  );
423
- const getLedgerAccountBalancesCSV = get(
421
+ const getLedgerAccountBalancesCSV = get$1(
424
422
  ({ businessId }) => `/v1/businesses/${businessId}/ledger/balances/exports/csv`
425
423
  );
426
424
  const createJournalEntries = post(
@@ -429,7 +427,7 @@ const createJournalEntries = post(
429
427
  const reverseJournalEntry = post(
430
428
  ({ businessId, entryId }) => `/v1/businesses/${businessId}/ledger/entries/${entryId}/reverse`
431
429
  );
432
- const getJournalEntriesCSV = get(
430
+ const getJournalEntriesCSV = get$1(
433
431
  ({ businessId }) => `/v1/businesses/${businessId}/ledger/entries/exports/csv`
434
432
  );
435
433
  const syncConnection = post(({ businessId }) => `/v1/businesses/${businessId}/sync`);
@@ -439,7 +437,7 @@ const updateConnectionStatus = post(
439
437
  const updateOpeningBalance = post(
440
438
  ({ businessId, accountId }) => `/v1/businesses/${businessId}/external-accounts/${accountId}/opening-balance`
441
439
  );
442
- const listExternalAccounts = get(({ businessId }) => `/v1/businesses/${businessId}/external-accounts`);
440
+ const listExternalAccounts = get$1(({ businessId }) => `/v1/businesses/${businessId}/external-accounts`);
443
441
  const confirmAccount = post(
444
442
  ({ businessId, accountId }) => `/v1/businesses/${businessId}/external-accounts/${accountId}/confirm`
445
443
  );
@@ -472,13 +470,13 @@ const compareProfitAndLoss = post(
472
470
  );
473
471
  const getProfitAndLossCsv = (apiUrl, accessToken, params) => {
474
472
  const { businessId, startDate, endDate, month, year, tagKey, tagValues, reportingBasis, moneyFormat } = params;
475
- return get(
473
+ return get$1(
476
474
  ({ businessId: businessId2 }) => `/v1/businesses/${businessId2}/reports/profit-and-loss/exports/csv?${startDate ? `start_date=${encodeURIComponent(toLocalDateString(startDate))}` : ""}${endDate ? `&end_date=${encodeURIComponent(toLocalDateString(endDate))}` : ""}${month ? `&month=${month}` : ""}${year ? `&year=${year}` : ""}${reportingBasis ? `&reporting_basis=${reportingBasis}` : ""}${tagKey ? `&tag_key=${tagKey}` : ""}${tagValues ? `&tag_values=${tagValues}` : ""}${moneyFormat ? `&money_format=${moneyFormat}` : ""}`
477
475
  )(apiUrl, accessToken, { params: { businessId } });
478
476
  };
479
477
  const getProfitAndLossExcel = (apiUrl, accessToken, params) => {
480
478
  const { businessId, startDate, endDate, month, year, tagKey, tagValues, reportingBasis, moneyFormat } = params;
481
- return get(
479
+ return get$1(
482
480
  ({ businessId: businessId2 }) => `/v1/businesses/${businessId2}/reports/profit-and-loss/exports/excel?${startDate ? `start_date=${encodeURIComponent(toLocalDateString(startDate))}` : ""}${endDate ? `&end_date=${encodeURIComponent(toLocalDateString(endDate))}` : ""}${month ? `&month=${month}` : ""}${year ? `&year=${year}` : ""}${reportingBasis ? `&reporting_basis=${reportingBasis}` : ""}${tagKey ? `&tag_key=${tagKey}` : ""}${tagValues ? `&tag_values=${tagValues}` : ""}${moneyFormat ? `&money_format=${moneyFormat}` : ""}`
483
481
  )(apiUrl, accessToken, { params: { businessId } });
484
482
  };
@@ -488,22 +486,22 @@ const profitAndLossComparisonCsv = post(
488
486
  const syncFromQuickbooks = post(({ businessId }) => `/v1/businesses/${businessId}/quickbooks/sync-from`);
489
487
  const initQuickbooksOAuth = post(({ businessId }) => `/v1/businesses/${businessId}/quickbooks/authorize`);
490
488
  const unlinkQuickbooksConnection = post(({ businessId }) => `/v1/businesses/${businessId}/quickbooks/unlink`);
491
- const statusOfQuickbooksConnection = get(
489
+ const statusOfQuickbooksConnection = get$1(
492
490
  ({ businessId }) => `/v1/businesses/${businessId}/quickbooks/connection-status`
493
491
  );
494
- const getStatementOfCashFlow = get(
492
+ const getStatementOfCashFlow = get$1(
495
493
  ({ businessId, startDate, endDate }) => {
496
494
  const parameters = toDefinedSearchParameters({ startDate, endDate });
497
495
  return `/v1/businesses/${businessId}/reports/cashflow-statement?${parameters}`;
498
496
  }
499
497
  );
500
- const getCashflowStatementCSV = get(
498
+ const getCashflowStatementCSV = get$1(
501
499
  ({ businessId, startDate, endDate }) => {
502
500
  const parameters = toDefinedSearchParameters({ startDate, endDate });
503
501
  return `/v1/businesses/${businessId}/reports/cashflow-statement/exports/csv?${parameters}`;
504
502
  }
505
503
  );
506
- const getVendors = get(
504
+ const getVendors = get$1(
507
505
  ({ businessId }) => `/v1/businesses/${businessId}/vendors`
508
506
  );
509
507
  const Layer = {
@@ -1409,36 +1407,36 @@ function withCorrectedRange(fn) {
1409
1407
  };
1410
1408
  }
1411
1409
  function buildStore$2() {
1412
- const now = /* @__PURE__ */ new Date();
1410
+ const now2 = /* @__PURE__ */ new Date();
1413
1411
  return zustand.createStore((set) => {
1414
- const apply = (next) => {
1412
+ const apply2 = (next) => {
1415
1413
  set(next);
1416
1414
  return next;
1417
1415
  };
1418
1416
  const setDate = ({ date: date2 }) => {
1419
1417
  const s = RANGE_MODE_LOOKUP.dayPicker.getStartDate({ startDate: date2 });
1420
1418
  const e = RANGE_MODE_LOOKUP.dayPicker.getEndDate({ endDate: date2 });
1421
- return apply({ startDate: s, endDate: e });
1419
+ return apply2({ startDate: s, endDate: e });
1422
1420
  };
1423
1421
  const setDateRange = withCorrectedRange(({ startDate, endDate }) => {
1424
1422
  const s = RANGE_MODE_LOOKUP.dayRangePicker.getStartDate({ startDate });
1425
1423
  const e = RANGE_MODE_LOOKUP.dayRangePicker.getEndDate({ endDate });
1426
- return apply({ startDate: s, endDate: e });
1424
+ return apply2({ startDate: s, endDate: e });
1427
1425
  });
1428
1426
  const setMonth = ({ startDate }) => {
1429
1427
  const s = RANGE_MODE_LOOKUP.monthPicker.getStartDate({ startDate });
1430
1428
  const e = RANGE_MODE_LOOKUP.monthPicker.getEndDate({ endDate: startDate });
1431
- return apply({ startDate: s, endDate: e });
1429
+ return apply2({ startDate: s, endDate: e });
1432
1430
  };
1433
1431
  const setMonthRange = withCorrectedRange(({ startDate, endDate }) => {
1434
1432
  const s = RANGE_MODE_LOOKUP.monthRangePicker.getStartDate({ startDate });
1435
1433
  const e = RANGE_MODE_LOOKUP.monthRangePicker.getEndDate({ endDate });
1436
- return apply({ startDate: s, endDate: e });
1434
+ return apply2({ startDate: s, endDate: e });
1437
1435
  });
1438
1436
  const setYear = ({ startDate }) => {
1439
1437
  const s = RANGE_MODE_LOOKUP.yearPicker.getStartDate({ startDate });
1440
1438
  const e = RANGE_MODE_LOOKUP.yearPicker.getEndDate({ endDate: startDate });
1441
- return apply({ startDate: s, endDate: e });
1439
+ return apply2({ startDate: s, endDate: e });
1442
1440
  };
1443
1441
  const setRangeWithExplicitDisplayMode = ({
1444
1442
  startDate,
@@ -1463,8 +1461,8 @@ function buildStore$2() {
1463
1461
  }
1464
1462
  };
1465
1463
  return {
1466
- startDate: dateFns.startOfMonth(now),
1467
- endDate: clampToPresentOrPast(dateFns.endOfMonth(now)),
1464
+ startDate: dateFns.startOfMonth(now2),
1465
+ endDate: clampToPresentOrPast(dateFns.endOfMonth(now2)),
1468
1466
  actions: {
1469
1467
  setDate,
1470
1468
  setRangeWithExplicitDisplayMode,
@@ -2932,6 +2930,1456 @@ function useGlobalCacheActions() {
2932
2930
  forceReload
2933
2931
  }), [invalidate, patchCache, optimisticUpdate, forceReload]);
2934
2932
  }
2933
+ var freeGlobal = typeof global == "object" && global && global.Object === Object && global;
2934
+ var freeSelf = typeof self == "object" && self && self.Object === Object && self;
2935
+ var root = freeGlobal || freeSelf || Function("return this")();
2936
+ var Symbol$1 = root.Symbol;
2937
+ var objectProto$e = Object.prototype;
2938
+ var hasOwnProperty$b = objectProto$e.hasOwnProperty;
2939
+ var nativeObjectToString$1 = objectProto$e.toString;
2940
+ var symToStringTag$1 = Symbol$1 ? Symbol$1.toStringTag : void 0;
2941
+ function getRawTag(value) {
2942
+ var isOwn = hasOwnProperty$b.call(value, symToStringTag$1), tag = value[symToStringTag$1];
2943
+ try {
2944
+ value[symToStringTag$1] = void 0;
2945
+ var unmasked = true;
2946
+ } catch (e) {
2947
+ }
2948
+ var result = nativeObjectToString$1.call(value);
2949
+ if (unmasked) {
2950
+ if (isOwn) {
2951
+ value[symToStringTag$1] = tag;
2952
+ } else {
2953
+ delete value[symToStringTag$1];
2954
+ }
2955
+ }
2956
+ return result;
2957
+ }
2958
+ var objectProto$d = Object.prototype;
2959
+ var nativeObjectToString = objectProto$d.toString;
2960
+ function objectToString(value) {
2961
+ return nativeObjectToString.call(value);
2962
+ }
2963
+ var nullTag = "[object Null]", undefinedTag = "[object Undefined]";
2964
+ var symToStringTag = Symbol$1 ? Symbol$1.toStringTag : void 0;
2965
+ function baseGetTag(value) {
2966
+ if (value == null) {
2967
+ return value === void 0 ? undefinedTag : nullTag;
2968
+ }
2969
+ return symToStringTag && symToStringTag in Object(value) ? getRawTag(value) : objectToString(value);
2970
+ }
2971
+ function isObjectLike(value) {
2972
+ return value != null && typeof value == "object";
2973
+ }
2974
+ var symbolTag$1 = "[object Symbol]";
2975
+ function isSymbol(value) {
2976
+ return typeof value == "symbol" || isObjectLike(value) && baseGetTag(value) == symbolTag$1;
2977
+ }
2978
+ function arrayMap(array, iteratee) {
2979
+ var index2 = -1, length = array == null ? 0 : array.length, result = Array(length);
2980
+ while (++index2 < length) {
2981
+ result[index2] = iteratee(array[index2], index2, array);
2982
+ }
2983
+ return result;
2984
+ }
2985
+ var isArray = Array.isArray;
2986
+ var symbolProto$1 = Symbol$1 ? Symbol$1.prototype : void 0, symbolToString = symbolProto$1 ? symbolProto$1.toString : void 0;
2987
+ function baseToString(value) {
2988
+ if (typeof value == "string") {
2989
+ return value;
2990
+ }
2991
+ if (isArray(value)) {
2992
+ return arrayMap(value, baseToString) + "";
2993
+ }
2994
+ if (isSymbol(value)) {
2995
+ return symbolToString ? symbolToString.call(value) : "";
2996
+ }
2997
+ var result = value + "";
2998
+ return result == "0" && 1 / value == -Infinity ? "-0" : result;
2999
+ }
3000
+ var reWhitespace = /\s/;
3001
+ function trimmedEndIndex(string) {
3002
+ var index2 = string.length;
3003
+ while (index2-- && reWhitespace.test(string.charAt(index2))) {
3004
+ }
3005
+ return index2;
3006
+ }
3007
+ var reTrimStart = /^\s+/;
3008
+ function baseTrim(string) {
3009
+ return string ? string.slice(0, trimmedEndIndex(string) + 1).replace(reTrimStart, "") : string;
3010
+ }
3011
+ function isObject(value) {
3012
+ var type = typeof value;
3013
+ return value != null && (type == "object" || type == "function");
3014
+ }
3015
+ var NAN = 0 / 0;
3016
+ var reIsBadHex = /^[-+]0x[0-9a-f]+$/i;
3017
+ var reIsBinary = /^0b[01]+$/i;
3018
+ var reIsOctal = /^0o[0-7]+$/i;
3019
+ var freeParseInt = parseInt;
3020
+ function toNumber(value) {
3021
+ if (typeof value == "number") {
3022
+ return value;
3023
+ }
3024
+ if (isSymbol(value)) {
3025
+ return NAN;
3026
+ }
3027
+ if (isObject(value)) {
3028
+ var other = typeof value.valueOf == "function" ? value.valueOf() : value;
3029
+ value = isObject(other) ? other + "" : other;
3030
+ }
3031
+ if (typeof value != "string") {
3032
+ return value === 0 ? value : +value;
3033
+ }
3034
+ value = baseTrim(value);
3035
+ var isBinary = reIsBinary.test(value);
3036
+ return isBinary || reIsOctal.test(value) ? freeParseInt(value.slice(2), isBinary ? 2 : 8) : reIsBadHex.test(value) ? NAN : +value;
3037
+ }
3038
+ function identity(value) {
3039
+ return value;
3040
+ }
3041
+ var asyncTag = "[object AsyncFunction]", funcTag$1 = "[object Function]", genTag = "[object GeneratorFunction]", proxyTag = "[object Proxy]";
3042
+ function isFunction(value) {
3043
+ if (!isObject(value)) {
3044
+ return false;
3045
+ }
3046
+ var tag = baseGetTag(value);
3047
+ return tag == funcTag$1 || tag == genTag || tag == asyncTag || tag == proxyTag;
3048
+ }
3049
+ var coreJsData = root["__core-js_shared__"];
3050
+ var maskSrcKey = function() {
3051
+ var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || "");
3052
+ return uid ? "Symbol(src)_1." + uid : "";
3053
+ }();
3054
+ function isMasked(func) {
3055
+ return !!maskSrcKey && maskSrcKey in func;
3056
+ }
3057
+ var funcProto$2 = Function.prototype;
3058
+ var funcToString$2 = funcProto$2.toString;
3059
+ function toSource(func) {
3060
+ if (func != null) {
3061
+ try {
3062
+ return funcToString$2.call(func);
3063
+ } catch (e) {
3064
+ }
3065
+ try {
3066
+ return func + "";
3067
+ } catch (e) {
3068
+ }
3069
+ }
3070
+ return "";
3071
+ }
3072
+ var reRegExpChar = /[\\^$.*+?()[\]{}|]/g;
3073
+ var reIsHostCtor = /^\[object .+?Constructor\]$/;
3074
+ var funcProto$1 = Function.prototype, objectProto$c = Object.prototype;
3075
+ var funcToString$1 = funcProto$1.toString;
3076
+ var hasOwnProperty$a = objectProto$c.hasOwnProperty;
3077
+ var reIsNative = RegExp(
3078
+ "^" + funcToString$1.call(hasOwnProperty$a).replace(reRegExpChar, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
3079
+ );
3080
+ function baseIsNative(value) {
3081
+ if (!isObject(value) || isMasked(value)) {
3082
+ return false;
3083
+ }
3084
+ var pattern = isFunction(value) ? reIsNative : reIsHostCtor;
3085
+ return pattern.test(toSource(value));
3086
+ }
3087
+ function getValue(object, key) {
3088
+ return object == null ? void 0 : object[key];
3089
+ }
3090
+ function getNative(object, key) {
3091
+ var value = getValue(object, key);
3092
+ return baseIsNative(value) ? value : void 0;
3093
+ }
3094
+ var WeakMap$1 = getNative(root, "WeakMap");
3095
+ var objectCreate = Object.create;
3096
+ var baseCreate = /* @__PURE__ */ function() {
3097
+ function object() {
3098
+ }
3099
+ return function(proto) {
3100
+ if (!isObject(proto)) {
3101
+ return {};
3102
+ }
3103
+ if (objectCreate) {
3104
+ return objectCreate(proto);
3105
+ }
3106
+ object.prototype = proto;
3107
+ var result = new object();
3108
+ object.prototype = void 0;
3109
+ return result;
3110
+ };
3111
+ }();
3112
+ function apply(func, thisArg, args) {
3113
+ switch (args.length) {
3114
+ case 0:
3115
+ return func.call(thisArg);
3116
+ case 1:
3117
+ return func.call(thisArg, args[0]);
3118
+ case 2:
3119
+ return func.call(thisArg, args[0], args[1]);
3120
+ case 3:
3121
+ return func.call(thisArg, args[0], args[1], args[2]);
3122
+ }
3123
+ return func.apply(thisArg, args);
3124
+ }
3125
+ function noop() {
3126
+ }
3127
+ function copyArray(source, array) {
3128
+ var index2 = -1, length = source.length;
3129
+ array || (array = Array(length));
3130
+ while (++index2 < length) {
3131
+ array[index2] = source[index2];
3132
+ }
3133
+ return array;
3134
+ }
3135
+ var HOT_COUNT = 800, HOT_SPAN = 16;
3136
+ var nativeNow = Date.now;
3137
+ function shortOut(func) {
3138
+ var count = 0, lastCalled = 0;
3139
+ return function() {
3140
+ var stamp = nativeNow(), remaining = HOT_SPAN - (stamp - lastCalled);
3141
+ lastCalled = stamp;
3142
+ if (remaining > 0) {
3143
+ if (++count >= HOT_COUNT) {
3144
+ return arguments[0];
3145
+ }
3146
+ } else {
3147
+ count = 0;
3148
+ }
3149
+ return func.apply(void 0, arguments);
3150
+ };
3151
+ }
3152
+ function constant(value) {
3153
+ return function() {
3154
+ return value;
3155
+ };
3156
+ }
3157
+ var defineProperty = function() {
3158
+ try {
3159
+ var func = getNative(Object, "defineProperty");
3160
+ func({}, "", {});
3161
+ return func;
3162
+ } catch (e) {
3163
+ }
3164
+ }();
3165
+ var baseSetToString = !defineProperty ? identity : function(func, string) {
3166
+ return defineProperty(func, "toString", {
3167
+ "configurable": true,
3168
+ "enumerable": false,
3169
+ "value": constant(string),
3170
+ "writable": true
3171
+ });
3172
+ };
3173
+ var setToString = shortOut(baseSetToString);
3174
+ function baseFindIndex(array, predicate, fromIndex, fromRight) {
3175
+ var length = array.length, index2 = fromIndex + -1;
3176
+ while (++index2 < length) {
3177
+ if (predicate(array[index2], index2, array)) {
3178
+ return index2;
3179
+ }
3180
+ }
3181
+ return -1;
3182
+ }
3183
+ function baseIsNaN(value) {
3184
+ return value !== value;
3185
+ }
3186
+ function strictIndexOf(array, value, fromIndex) {
3187
+ var index2 = fromIndex - 1, length = array.length;
3188
+ while (++index2 < length) {
3189
+ if (array[index2] === value) {
3190
+ return index2;
3191
+ }
3192
+ }
3193
+ return -1;
3194
+ }
3195
+ function baseIndexOf(array, value, fromIndex) {
3196
+ return value === value ? strictIndexOf(array, value, fromIndex) : baseFindIndex(array, baseIsNaN, fromIndex);
3197
+ }
3198
+ function arrayIncludes(array, value) {
3199
+ var length = array == null ? 0 : array.length;
3200
+ return !!length && baseIndexOf(array, value, 0) > -1;
3201
+ }
3202
+ var MAX_SAFE_INTEGER$1 = 9007199254740991;
3203
+ var reIsUint = /^(?:0|[1-9]\d*)$/;
3204
+ function isIndex(value, length) {
3205
+ var type = typeof value;
3206
+ length = length == null ? MAX_SAFE_INTEGER$1 : length;
3207
+ return !!length && (type == "number" || type != "symbol" && reIsUint.test(value)) && (value > -1 && value % 1 == 0 && value < length);
3208
+ }
3209
+ function baseAssignValue(object, key, value) {
3210
+ if (key == "__proto__" && defineProperty) {
3211
+ defineProperty(object, key, {
3212
+ "configurable": true,
3213
+ "enumerable": true,
3214
+ "value": value,
3215
+ "writable": true
3216
+ });
3217
+ } else {
3218
+ object[key] = value;
3219
+ }
3220
+ }
3221
+ function eq(value, other) {
3222
+ return value === other || value !== value && other !== other;
3223
+ }
3224
+ var objectProto$b = Object.prototype;
3225
+ var hasOwnProperty$9 = objectProto$b.hasOwnProperty;
3226
+ function assignValue(object, key, value) {
3227
+ var objValue = object[key];
3228
+ if (!(hasOwnProperty$9.call(object, key) && eq(objValue, value)) || value === void 0 && !(key in object)) {
3229
+ baseAssignValue(object, key, value);
3230
+ }
3231
+ }
3232
+ function copyObject(source, props, object, customizer) {
3233
+ var isNew = !object;
3234
+ object || (object = {});
3235
+ var index2 = -1, length = props.length;
3236
+ while (++index2 < length) {
3237
+ var key = props[index2];
3238
+ var newValue = void 0;
3239
+ if (newValue === void 0) {
3240
+ newValue = source[key];
3241
+ }
3242
+ if (isNew) {
3243
+ baseAssignValue(object, key, newValue);
3244
+ } else {
3245
+ assignValue(object, key, newValue);
3246
+ }
3247
+ }
3248
+ return object;
3249
+ }
3250
+ var nativeMax$1 = Math.max;
3251
+ function overRest(func, start, transform) {
3252
+ start = nativeMax$1(start === void 0 ? func.length - 1 : start, 0);
3253
+ return function() {
3254
+ var args = arguments, index2 = -1, length = nativeMax$1(args.length - start, 0), array = Array(length);
3255
+ while (++index2 < length) {
3256
+ array[index2] = args[start + index2];
3257
+ }
3258
+ index2 = -1;
3259
+ var otherArgs = Array(start + 1);
3260
+ while (++index2 < start) {
3261
+ otherArgs[index2] = args[index2];
3262
+ }
3263
+ otherArgs[start] = transform(array);
3264
+ return apply(func, this, otherArgs);
3265
+ };
3266
+ }
3267
+ function baseRest(func, start) {
3268
+ return setToString(overRest(func, start, identity), func + "");
3269
+ }
3270
+ var MAX_SAFE_INTEGER = 9007199254740991;
3271
+ function isLength(value) {
3272
+ return typeof value == "number" && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
3273
+ }
3274
+ function isArrayLike(value) {
3275
+ return value != null && isLength(value.length) && !isFunction(value);
3276
+ }
3277
+ function isIterateeCall(value, index2, object) {
3278
+ if (!isObject(object)) {
3279
+ return false;
3280
+ }
3281
+ var type = typeof index2;
3282
+ if (type == "number" ? isArrayLike(object) && isIndex(index2, object.length) : type == "string" && index2 in object) {
3283
+ return eq(object[index2], value);
3284
+ }
3285
+ return false;
3286
+ }
3287
+ function createAssigner(assigner) {
3288
+ return baseRest(function(object, sources) {
3289
+ var index2 = -1, length = sources.length, customizer = length > 1 ? sources[length - 1] : void 0, guard = length > 2 ? sources[2] : void 0;
3290
+ customizer = assigner.length > 3 && typeof customizer == "function" ? (length--, customizer) : void 0;
3291
+ if (guard && isIterateeCall(sources[0], sources[1], guard)) {
3292
+ customizer = length < 3 ? void 0 : customizer;
3293
+ length = 1;
3294
+ }
3295
+ object = Object(object);
3296
+ while (++index2 < length) {
3297
+ var source = sources[index2];
3298
+ if (source) {
3299
+ assigner(object, source, index2, customizer);
3300
+ }
3301
+ }
3302
+ return object;
3303
+ });
3304
+ }
3305
+ var objectProto$a = Object.prototype;
3306
+ function isPrototype(value) {
3307
+ var Ctor = value && value.constructor, proto = typeof Ctor == "function" && Ctor.prototype || objectProto$a;
3308
+ return value === proto;
3309
+ }
3310
+ function baseTimes(n, iteratee) {
3311
+ var index2 = -1, result = Array(n);
3312
+ while (++index2 < n) {
3313
+ result[index2] = iteratee(index2);
3314
+ }
3315
+ return result;
3316
+ }
3317
+ var argsTag$2 = "[object Arguments]";
3318
+ function baseIsArguments(value) {
3319
+ return isObjectLike(value) && baseGetTag(value) == argsTag$2;
3320
+ }
3321
+ var objectProto$9 = Object.prototype;
3322
+ var hasOwnProperty$8 = objectProto$9.hasOwnProperty;
3323
+ var propertyIsEnumerable$1 = objectProto$9.propertyIsEnumerable;
3324
+ var isArguments = baseIsArguments(/* @__PURE__ */ function() {
3325
+ return arguments;
3326
+ }()) ? baseIsArguments : function(value) {
3327
+ return isObjectLike(value) && hasOwnProperty$8.call(value, "callee") && !propertyIsEnumerable$1.call(value, "callee");
3328
+ };
3329
+ function stubFalse() {
3330
+ return false;
3331
+ }
3332
+ var freeExports$2 = typeof exports == "object" && exports && !exports.nodeType && exports;
3333
+ var freeModule$2 = freeExports$2 && typeof module == "object" && module && !module.nodeType && module;
3334
+ var moduleExports$2 = freeModule$2 && freeModule$2.exports === freeExports$2;
3335
+ var Buffer$1 = moduleExports$2 ? root.Buffer : void 0;
3336
+ var nativeIsBuffer = Buffer$1 ? Buffer$1.isBuffer : void 0;
3337
+ var isBuffer = nativeIsBuffer || stubFalse;
3338
+ var argsTag$1 = "[object Arguments]", arrayTag$1 = "[object Array]", boolTag$1 = "[object Boolean]", dateTag$1 = "[object Date]", errorTag$1 = "[object Error]", funcTag = "[object Function]", mapTag$2 = "[object Map]", numberTag$1 = "[object Number]", objectTag$3 = "[object Object]", regexpTag$1 = "[object RegExp]", setTag$2 = "[object Set]", stringTag$1 = "[object String]", weakMapTag$1 = "[object WeakMap]";
3339
+ var arrayBufferTag$1 = "[object ArrayBuffer]", dataViewTag$2 = "[object DataView]", float32Tag = "[object Float32Array]", float64Tag = "[object Float64Array]", int8Tag = "[object Int8Array]", int16Tag = "[object Int16Array]", int32Tag = "[object Int32Array]", uint8Tag = "[object Uint8Array]", uint8ClampedTag = "[object Uint8ClampedArray]", uint16Tag = "[object Uint16Array]", uint32Tag = "[object Uint32Array]";
3340
+ var typedArrayTags = {};
3341
+ typedArrayTags[float32Tag] = typedArrayTags[float64Tag] = typedArrayTags[int8Tag] = typedArrayTags[int16Tag] = typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] = typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] = typedArrayTags[uint32Tag] = true;
3342
+ typedArrayTags[argsTag$1] = typedArrayTags[arrayTag$1] = typedArrayTags[arrayBufferTag$1] = typedArrayTags[boolTag$1] = typedArrayTags[dataViewTag$2] = typedArrayTags[dateTag$1] = typedArrayTags[errorTag$1] = typedArrayTags[funcTag] = typedArrayTags[mapTag$2] = typedArrayTags[numberTag$1] = typedArrayTags[objectTag$3] = typedArrayTags[regexpTag$1] = typedArrayTags[setTag$2] = typedArrayTags[stringTag$1] = typedArrayTags[weakMapTag$1] = false;
3343
+ function baseIsTypedArray(value) {
3344
+ return isObjectLike(value) && isLength(value.length) && !!typedArrayTags[baseGetTag(value)];
3345
+ }
3346
+ function baseUnary(func) {
3347
+ return function(value) {
3348
+ return func(value);
3349
+ };
3350
+ }
3351
+ var freeExports$1 = typeof exports == "object" && exports && !exports.nodeType && exports;
3352
+ var freeModule$1 = freeExports$1 && typeof module == "object" && module && !module.nodeType && module;
3353
+ var moduleExports$1 = freeModule$1 && freeModule$1.exports === freeExports$1;
3354
+ var freeProcess = moduleExports$1 && freeGlobal.process;
3355
+ var nodeUtil = function() {
3356
+ try {
3357
+ var types = freeModule$1 && freeModule$1.require && freeModule$1.require("util").types;
3358
+ if (types) {
3359
+ return types;
3360
+ }
3361
+ return freeProcess && freeProcess.binding && freeProcess.binding("util");
3362
+ } catch (e) {
3363
+ }
3364
+ }();
3365
+ var nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;
3366
+ var isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;
3367
+ var objectProto$8 = Object.prototype;
3368
+ var hasOwnProperty$7 = objectProto$8.hasOwnProperty;
3369
+ function arrayLikeKeys(value, inherited) {
3370
+ var isArr = isArray(value), isArg = !isArr && isArguments(value), isBuff = !isArr && !isArg && isBuffer(value), isType = !isArr && !isArg && !isBuff && isTypedArray(value), skipIndexes = isArr || isArg || isBuff || isType, result = skipIndexes ? baseTimes(value.length, String) : [], length = result.length;
3371
+ for (var key in value) {
3372
+ if ((inherited || hasOwnProperty$7.call(value, key)) && !(skipIndexes && // Safari 9 has enumerable `arguments.length` in strict mode.
3373
+ (key == "length" || // Node.js 0.10 has enumerable non-index properties on buffers.
3374
+ isBuff && (key == "offset" || key == "parent") || // PhantomJS 2 has enumerable non-index properties on typed arrays.
3375
+ isType && (key == "buffer" || key == "byteLength" || key == "byteOffset") || // Skip index properties.
3376
+ isIndex(key, length)))) {
3377
+ result.push(key);
3378
+ }
3379
+ }
3380
+ return result;
3381
+ }
3382
+ function overArg(func, transform) {
3383
+ return function(arg) {
3384
+ return func(transform(arg));
3385
+ };
3386
+ }
3387
+ var nativeKeys = overArg(Object.keys, Object);
3388
+ var objectProto$7 = Object.prototype;
3389
+ var hasOwnProperty$6 = objectProto$7.hasOwnProperty;
3390
+ function baseKeys(object) {
3391
+ if (!isPrototype(object)) {
3392
+ return nativeKeys(object);
3393
+ }
3394
+ var result = [];
3395
+ for (var key in Object(object)) {
3396
+ if (hasOwnProperty$6.call(object, key) && key != "constructor") {
3397
+ result.push(key);
3398
+ }
3399
+ }
3400
+ return result;
3401
+ }
3402
+ function keys(object) {
3403
+ return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);
3404
+ }
3405
+ function nativeKeysIn(object) {
3406
+ var result = [];
3407
+ if (object != null) {
3408
+ for (var key in Object(object)) {
3409
+ result.push(key);
3410
+ }
3411
+ }
3412
+ return result;
3413
+ }
3414
+ var objectProto$6 = Object.prototype;
3415
+ var hasOwnProperty$5 = objectProto$6.hasOwnProperty;
3416
+ function baseKeysIn(object) {
3417
+ if (!isObject(object)) {
3418
+ return nativeKeysIn(object);
3419
+ }
3420
+ var isProto = isPrototype(object), result = [];
3421
+ for (var key in object) {
3422
+ if (!(key == "constructor" && (isProto || !hasOwnProperty$5.call(object, key)))) {
3423
+ result.push(key);
3424
+ }
3425
+ }
3426
+ return result;
3427
+ }
3428
+ function keysIn(object) {
3429
+ return isArrayLike(object) ? arrayLikeKeys(object, true) : baseKeysIn(object);
3430
+ }
3431
+ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, reIsPlainProp = /^\w*$/;
3432
+ function isKey(value, object) {
3433
+ if (isArray(value)) {
3434
+ return false;
3435
+ }
3436
+ var type = typeof value;
3437
+ if (type == "number" || type == "symbol" || type == "boolean" || value == null || isSymbol(value)) {
3438
+ return true;
3439
+ }
3440
+ return reIsPlainProp.test(value) || !reIsDeepProp.test(value) || object != null && value in Object(object);
3441
+ }
3442
+ var nativeCreate = getNative(Object, "create");
3443
+ function hashClear() {
3444
+ this.__data__ = nativeCreate ? nativeCreate(null) : {};
3445
+ this.size = 0;
3446
+ }
3447
+ function hashDelete(key) {
3448
+ var result = this.has(key) && delete this.__data__[key];
3449
+ this.size -= result ? 1 : 0;
3450
+ return result;
3451
+ }
3452
+ var HASH_UNDEFINED$2 = "__lodash_hash_undefined__";
3453
+ var objectProto$5 = Object.prototype;
3454
+ var hasOwnProperty$4 = objectProto$5.hasOwnProperty;
3455
+ function hashGet(key) {
3456
+ var data = this.__data__;
3457
+ if (nativeCreate) {
3458
+ var result = data[key];
3459
+ return result === HASH_UNDEFINED$2 ? void 0 : result;
3460
+ }
3461
+ return hasOwnProperty$4.call(data, key) ? data[key] : void 0;
3462
+ }
3463
+ var objectProto$4 = Object.prototype;
3464
+ var hasOwnProperty$3 = objectProto$4.hasOwnProperty;
3465
+ function hashHas(key) {
3466
+ var data = this.__data__;
3467
+ return nativeCreate ? data[key] !== void 0 : hasOwnProperty$3.call(data, key);
3468
+ }
3469
+ var HASH_UNDEFINED$1 = "__lodash_hash_undefined__";
3470
+ function hashSet(key, value) {
3471
+ var data = this.__data__;
3472
+ this.size += this.has(key) ? 0 : 1;
3473
+ data[key] = nativeCreate && value === void 0 ? HASH_UNDEFINED$1 : value;
3474
+ return this;
3475
+ }
3476
+ function Hash(entries) {
3477
+ var index2 = -1, length = entries == null ? 0 : entries.length;
3478
+ this.clear();
3479
+ while (++index2 < length) {
3480
+ var entry = entries[index2];
3481
+ this.set(entry[0], entry[1]);
3482
+ }
3483
+ }
3484
+ Hash.prototype.clear = hashClear;
3485
+ Hash.prototype["delete"] = hashDelete;
3486
+ Hash.prototype.get = hashGet;
3487
+ Hash.prototype.has = hashHas;
3488
+ Hash.prototype.set = hashSet;
3489
+ function listCacheClear() {
3490
+ this.__data__ = [];
3491
+ this.size = 0;
3492
+ }
3493
+ function assocIndexOf(array, key) {
3494
+ var length = array.length;
3495
+ while (length--) {
3496
+ if (eq(array[length][0], key)) {
3497
+ return length;
3498
+ }
3499
+ }
3500
+ return -1;
3501
+ }
3502
+ var arrayProto = Array.prototype;
3503
+ var splice = arrayProto.splice;
3504
+ function listCacheDelete(key) {
3505
+ var data = this.__data__, index2 = assocIndexOf(data, key);
3506
+ if (index2 < 0) {
3507
+ return false;
3508
+ }
3509
+ var lastIndex = data.length - 1;
3510
+ if (index2 == lastIndex) {
3511
+ data.pop();
3512
+ } else {
3513
+ splice.call(data, index2, 1);
3514
+ }
3515
+ --this.size;
3516
+ return true;
3517
+ }
3518
+ function listCacheGet(key) {
3519
+ var data = this.__data__, index2 = assocIndexOf(data, key);
3520
+ return index2 < 0 ? void 0 : data[index2][1];
3521
+ }
3522
+ function listCacheHas(key) {
3523
+ return assocIndexOf(this.__data__, key) > -1;
3524
+ }
3525
+ function listCacheSet(key, value) {
3526
+ var data = this.__data__, index2 = assocIndexOf(data, key);
3527
+ if (index2 < 0) {
3528
+ ++this.size;
3529
+ data.push([key, value]);
3530
+ } else {
3531
+ data[index2][1] = value;
3532
+ }
3533
+ return this;
3534
+ }
3535
+ function ListCache(entries) {
3536
+ var index2 = -1, length = entries == null ? 0 : entries.length;
3537
+ this.clear();
3538
+ while (++index2 < length) {
3539
+ var entry = entries[index2];
3540
+ this.set(entry[0], entry[1]);
3541
+ }
3542
+ }
3543
+ ListCache.prototype.clear = listCacheClear;
3544
+ ListCache.prototype["delete"] = listCacheDelete;
3545
+ ListCache.prototype.get = listCacheGet;
3546
+ ListCache.prototype.has = listCacheHas;
3547
+ ListCache.prototype.set = listCacheSet;
3548
+ var Map$1 = getNative(root, "Map");
3549
+ function mapCacheClear() {
3550
+ this.size = 0;
3551
+ this.__data__ = {
3552
+ "hash": new Hash(),
3553
+ "map": new (Map$1 || ListCache)(),
3554
+ "string": new Hash()
3555
+ };
3556
+ }
3557
+ function isKeyable(value) {
3558
+ var type = typeof value;
3559
+ return type == "string" || type == "number" || type == "symbol" || type == "boolean" ? value !== "__proto__" : value === null;
3560
+ }
3561
+ function getMapData(map, key) {
3562
+ var data = map.__data__;
3563
+ return isKeyable(key) ? data[typeof key == "string" ? "string" : "hash"] : data.map;
3564
+ }
3565
+ function mapCacheDelete(key) {
3566
+ var result = getMapData(this, key)["delete"](key);
3567
+ this.size -= result ? 1 : 0;
3568
+ return result;
3569
+ }
3570
+ function mapCacheGet(key) {
3571
+ return getMapData(this, key).get(key);
3572
+ }
3573
+ function mapCacheHas(key) {
3574
+ return getMapData(this, key).has(key);
3575
+ }
3576
+ function mapCacheSet(key, value) {
3577
+ var data = getMapData(this, key), size = data.size;
3578
+ data.set(key, value);
3579
+ this.size += data.size == size ? 0 : 1;
3580
+ return this;
3581
+ }
3582
+ function MapCache(entries) {
3583
+ var index2 = -1, length = entries == null ? 0 : entries.length;
3584
+ this.clear();
3585
+ while (++index2 < length) {
3586
+ var entry = entries[index2];
3587
+ this.set(entry[0], entry[1]);
3588
+ }
3589
+ }
3590
+ MapCache.prototype.clear = mapCacheClear;
3591
+ MapCache.prototype["delete"] = mapCacheDelete;
3592
+ MapCache.prototype.get = mapCacheGet;
3593
+ MapCache.prototype.has = mapCacheHas;
3594
+ MapCache.prototype.set = mapCacheSet;
3595
+ var FUNC_ERROR_TEXT$1 = "Expected a function";
3596
+ function memoize(func, resolver) {
3597
+ if (typeof func != "function" || resolver != null && typeof resolver != "function") {
3598
+ throw new TypeError(FUNC_ERROR_TEXT$1);
3599
+ }
3600
+ var memoized = function() {
3601
+ var args = arguments, key = resolver ? resolver.apply(this, args) : args[0], cache = memoized.cache;
3602
+ if (cache.has(key)) {
3603
+ return cache.get(key);
3604
+ }
3605
+ var result = func.apply(this, args);
3606
+ memoized.cache = cache.set(key, result) || cache;
3607
+ return result;
3608
+ };
3609
+ memoized.cache = new (memoize.Cache || MapCache)();
3610
+ return memoized;
3611
+ }
3612
+ memoize.Cache = MapCache;
3613
+ var MAX_MEMOIZE_SIZE = 500;
3614
+ function memoizeCapped(func) {
3615
+ var result = memoize(func, function(key) {
3616
+ if (cache.size === MAX_MEMOIZE_SIZE) {
3617
+ cache.clear();
3618
+ }
3619
+ return key;
3620
+ });
3621
+ var cache = result.cache;
3622
+ return result;
3623
+ }
3624
+ var rePropName = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g;
3625
+ var reEscapeChar = /\\(\\)?/g;
3626
+ var stringToPath = memoizeCapped(function(string) {
3627
+ var result = [];
3628
+ if (string.charCodeAt(0) === 46) {
3629
+ result.push("");
3630
+ }
3631
+ string.replace(rePropName, function(match, number, quote, subString) {
3632
+ result.push(quote ? subString.replace(reEscapeChar, "$1") : number || match);
3633
+ });
3634
+ return result;
3635
+ });
3636
+ function toString(value) {
3637
+ return value == null ? "" : baseToString(value);
3638
+ }
3639
+ function castPath(value, object) {
3640
+ if (isArray(value)) {
3641
+ return value;
3642
+ }
3643
+ return isKey(value, object) ? [value] : stringToPath(toString(value));
3644
+ }
3645
+ function toKey(value) {
3646
+ if (typeof value == "string" || isSymbol(value)) {
3647
+ return value;
3648
+ }
3649
+ var result = value + "";
3650
+ return result == "0" && 1 / value == -Infinity ? "-0" : result;
3651
+ }
3652
+ function baseGet(object, path) {
3653
+ path = castPath(path, object);
3654
+ var index2 = 0, length = path.length;
3655
+ while (object != null && index2 < length) {
3656
+ object = object[toKey(path[index2++])];
3657
+ }
3658
+ return index2 && index2 == length ? object : void 0;
3659
+ }
3660
+ function get(object, path, defaultValue2) {
3661
+ var result = object == null ? void 0 : baseGet(object, path);
3662
+ return result === void 0 ? defaultValue2 : result;
3663
+ }
3664
+ function arrayPush(array, values) {
3665
+ var index2 = -1, length = values.length, offset = array.length;
3666
+ while (++index2 < length) {
3667
+ array[offset + index2] = values[index2];
3668
+ }
3669
+ return array;
3670
+ }
3671
+ var getPrototype = overArg(Object.getPrototypeOf, Object);
3672
+ var objectTag$2 = "[object Object]";
3673
+ var funcProto = Function.prototype, objectProto$3 = Object.prototype;
3674
+ var funcToString = funcProto.toString;
3675
+ var hasOwnProperty$2 = objectProto$3.hasOwnProperty;
3676
+ var objectCtorString = funcToString.call(Object);
3677
+ function isPlainObject(value) {
3678
+ if (!isObjectLike(value) || baseGetTag(value) != objectTag$2) {
3679
+ return false;
3680
+ }
3681
+ var proto = getPrototype(value);
3682
+ if (proto === null) {
3683
+ return true;
3684
+ }
3685
+ var Ctor = hasOwnProperty$2.call(proto, "constructor") && proto.constructor;
3686
+ return typeof Ctor == "function" && Ctor instanceof Ctor && funcToString.call(Ctor) == objectCtorString;
3687
+ }
3688
+ function stackClear() {
3689
+ this.__data__ = new ListCache();
3690
+ this.size = 0;
3691
+ }
3692
+ function stackDelete(key) {
3693
+ var data = this.__data__, result = data["delete"](key);
3694
+ this.size = data.size;
3695
+ return result;
3696
+ }
3697
+ function stackGet(key) {
3698
+ return this.__data__.get(key);
3699
+ }
3700
+ function stackHas(key) {
3701
+ return this.__data__.has(key);
3702
+ }
3703
+ var LARGE_ARRAY_SIZE$1 = 200;
3704
+ function stackSet(key, value) {
3705
+ var data = this.__data__;
3706
+ if (data instanceof ListCache) {
3707
+ var pairs = data.__data__;
3708
+ if (!Map$1 || pairs.length < LARGE_ARRAY_SIZE$1 - 1) {
3709
+ pairs.push([key, value]);
3710
+ this.size = ++data.size;
3711
+ return this;
3712
+ }
3713
+ data = this.__data__ = new MapCache(pairs);
3714
+ }
3715
+ data.set(key, value);
3716
+ this.size = data.size;
3717
+ return this;
3718
+ }
3719
+ function Stack$1(entries) {
3720
+ var data = this.__data__ = new ListCache(entries);
3721
+ this.size = data.size;
3722
+ }
3723
+ Stack$1.prototype.clear = stackClear;
3724
+ Stack$1.prototype["delete"] = stackDelete;
3725
+ Stack$1.prototype.get = stackGet;
3726
+ Stack$1.prototype.has = stackHas;
3727
+ Stack$1.prototype.set = stackSet;
3728
+ var freeExports = typeof exports == "object" && exports && !exports.nodeType && exports;
3729
+ var freeModule = freeExports && typeof module == "object" && module && !module.nodeType && module;
3730
+ var moduleExports = freeModule && freeModule.exports === freeExports;
3731
+ var Buffer2 = moduleExports ? root.Buffer : void 0;
3732
+ Buffer2 ? Buffer2.allocUnsafe : void 0;
3733
+ function cloneBuffer(buffer, isDeep) {
3734
+ {
3735
+ return buffer.slice();
3736
+ }
3737
+ }
3738
+ function arrayFilter(array, predicate) {
3739
+ var index2 = -1, length = array == null ? 0 : array.length, resIndex = 0, result = [];
3740
+ while (++index2 < length) {
3741
+ var value = array[index2];
3742
+ if (predicate(value, index2, array)) {
3743
+ result[resIndex++] = value;
3744
+ }
3745
+ }
3746
+ return result;
3747
+ }
3748
+ function stubArray() {
3749
+ return [];
3750
+ }
3751
+ var objectProto$2 = Object.prototype;
3752
+ var propertyIsEnumerable = objectProto$2.propertyIsEnumerable;
3753
+ var nativeGetSymbols = Object.getOwnPropertySymbols;
3754
+ var getSymbols = !nativeGetSymbols ? stubArray : function(object) {
3755
+ if (object == null) {
3756
+ return [];
3757
+ }
3758
+ object = Object(object);
3759
+ return arrayFilter(nativeGetSymbols(object), function(symbol) {
3760
+ return propertyIsEnumerable.call(object, symbol);
3761
+ });
3762
+ };
3763
+ function baseGetAllKeys(object, keysFunc, symbolsFunc) {
3764
+ var result = keysFunc(object);
3765
+ return isArray(object) ? result : arrayPush(result, symbolsFunc(object));
3766
+ }
3767
+ function getAllKeys(object) {
3768
+ return baseGetAllKeys(object, keys, getSymbols);
3769
+ }
3770
+ var DataView = getNative(root, "DataView");
3771
+ var Promise$1 = getNative(root, "Promise");
3772
+ var Set$1 = getNative(root, "Set");
3773
+ var mapTag$1 = "[object Map]", objectTag$1 = "[object Object]", promiseTag = "[object Promise]", setTag$1 = "[object Set]", weakMapTag = "[object WeakMap]";
3774
+ var dataViewTag$1 = "[object DataView]";
3775
+ var dataViewCtorString = toSource(DataView), mapCtorString = toSource(Map$1), promiseCtorString = toSource(Promise$1), setCtorString = toSource(Set$1), weakMapCtorString = toSource(WeakMap$1);
3776
+ var getTag$1 = baseGetTag;
3777
+ if (DataView && getTag$1(new DataView(new ArrayBuffer(1))) != dataViewTag$1 || Map$1 && getTag$1(new Map$1()) != mapTag$1 || Promise$1 && getTag$1(Promise$1.resolve()) != promiseTag || Set$1 && getTag$1(new Set$1()) != setTag$1 || WeakMap$1 && getTag$1(new WeakMap$1()) != weakMapTag) {
3778
+ getTag$1 = function(value) {
3779
+ var result = baseGetTag(value), Ctor = result == objectTag$1 ? value.constructor : void 0, ctorString = Ctor ? toSource(Ctor) : "";
3780
+ if (ctorString) {
3781
+ switch (ctorString) {
3782
+ case dataViewCtorString:
3783
+ return dataViewTag$1;
3784
+ case mapCtorString:
3785
+ return mapTag$1;
3786
+ case promiseCtorString:
3787
+ return promiseTag;
3788
+ case setCtorString:
3789
+ return setTag$1;
3790
+ case weakMapCtorString:
3791
+ return weakMapTag;
3792
+ }
3793
+ }
3794
+ return result;
3795
+ };
3796
+ }
3797
+ var Uint8Array2 = root.Uint8Array;
3798
+ function cloneArrayBuffer(arrayBuffer) {
3799
+ var result = new arrayBuffer.constructor(arrayBuffer.byteLength);
3800
+ new Uint8Array2(result).set(new Uint8Array2(arrayBuffer));
3801
+ return result;
3802
+ }
3803
+ function cloneTypedArray(typedArray, isDeep) {
3804
+ var buffer = cloneArrayBuffer(typedArray.buffer);
3805
+ return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length);
3806
+ }
3807
+ function initCloneObject(object) {
3808
+ return typeof object.constructor == "function" && !isPrototype(object) ? baseCreate(getPrototype(object)) : {};
3809
+ }
3810
+ var HASH_UNDEFINED = "__lodash_hash_undefined__";
3811
+ function setCacheAdd(value) {
3812
+ this.__data__.set(value, HASH_UNDEFINED);
3813
+ return this;
3814
+ }
3815
+ function setCacheHas(value) {
3816
+ return this.__data__.has(value);
3817
+ }
3818
+ function SetCache(values) {
3819
+ var index2 = -1, length = values == null ? 0 : values.length;
3820
+ this.__data__ = new MapCache();
3821
+ while (++index2 < length) {
3822
+ this.add(values[index2]);
3823
+ }
3824
+ }
3825
+ SetCache.prototype.add = SetCache.prototype.push = setCacheAdd;
3826
+ SetCache.prototype.has = setCacheHas;
3827
+ function arraySome(array, predicate) {
3828
+ var index2 = -1, length = array == null ? 0 : array.length;
3829
+ while (++index2 < length) {
3830
+ if (predicate(array[index2], index2, array)) {
3831
+ return true;
3832
+ }
3833
+ }
3834
+ return false;
3835
+ }
3836
+ function cacheHas(cache, key) {
3837
+ return cache.has(key);
3838
+ }
3839
+ var COMPARE_PARTIAL_FLAG$5 = 1, COMPARE_UNORDERED_FLAG$3 = 2;
3840
+ function equalArrays(array, other, bitmask, customizer, equalFunc, stack) {
3841
+ var isPartial = bitmask & COMPARE_PARTIAL_FLAG$5, arrLength = array.length, othLength = other.length;
3842
+ if (arrLength != othLength && !(isPartial && othLength > arrLength)) {
3843
+ return false;
3844
+ }
3845
+ var arrStacked = stack.get(array);
3846
+ var othStacked = stack.get(other);
3847
+ if (arrStacked && othStacked) {
3848
+ return arrStacked == other && othStacked == array;
3849
+ }
3850
+ var index2 = -1, result = true, seen = bitmask & COMPARE_UNORDERED_FLAG$3 ? new SetCache() : void 0;
3851
+ stack.set(array, other);
3852
+ stack.set(other, array);
3853
+ while (++index2 < arrLength) {
3854
+ var arrValue = array[index2], othValue = other[index2];
3855
+ if (customizer) {
3856
+ var compared = isPartial ? customizer(othValue, arrValue, index2, other, array, stack) : customizer(arrValue, othValue, index2, array, other, stack);
3857
+ }
3858
+ if (compared !== void 0) {
3859
+ if (compared) {
3860
+ continue;
3861
+ }
3862
+ result = false;
3863
+ break;
3864
+ }
3865
+ if (seen) {
3866
+ if (!arraySome(other, function(othValue2, othIndex) {
3867
+ if (!cacheHas(seen, othIndex) && (arrValue === othValue2 || equalFunc(arrValue, othValue2, bitmask, customizer, stack))) {
3868
+ return seen.push(othIndex);
3869
+ }
3870
+ })) {
3871
+ result = false;
3872
+ break;
3873
+ }
3874
+ } else if (!(arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {
3875
+ result = false;
3876
+ break;
3877
+ }
3878
+ }
3879
+ stack["delete"](array);
3880
+ stack["delete"](other);
3881
+ return result;
3882
+ }
3883
+ function mapToArray(map) {
3884
+ var index2 = -1, result = Array(map.size);
3885
+ map.forEach(function(value, key) {
3886
+ result[++index2] = [key, value];
3887
+ });
3888
+ return result;
3889
+ }
3890
+ function setToArray(set) {
3891
+ var index2 = -1, result = Array(set.size);
3892
+ set.forEach(function(value) {
3893
+ result[++index2] = value;
3894
+ });
3895
+ return result;
3896
+ }
3897
+ var COMPARE_PARTIAL_FLAG$4 = 1, COMPARE_UNORDERED_FLAG$2 = 2;
3898
+ var boolTag = "[object Boolean]", dateTag = "[object Date]", errorTag = "[object Error]", mapTag = "[object Map]", numberTag = "[object Number]", regexpTag = "[object RegExp]", setTag = "[object Set]", stringTag = "[object String]", symbolTag = "[object Symbol]";
3899
+ var arrayBufferTag = "[object ArrayBuffer]", dataViewTag = "[object DataView]";
3900
+ var symbolProto = Symbol$1 ? Symbol$1.prototype : void 0, symbolValueOf = symbolProto ? symbolProto.valueOf : void 0;
3901
+ function equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {
3902
+ switch (tag) {
3903
+ case dataViewTag:
3904
+ if (object.byteLength != other.byteLength || object.byteOffset != other.byteOffset) {
3905
+ return false;
3906
+ }
3907
+ object = object.buffer;
3908
+ other = other.buffer;
3909
+ case arrayBufferTag:
3910
+ if (object.byteLength != other.byteLength || !equalFunc(new Uint8Array2(object), new Uint8Array2(other))) {
3911
+ return false;
3912
+ }
3913
+ return true;
3914
+ case boolTag:
3915
+ case dateTag:
3916
+ case numberTag:
3917
+ return eq(+object, +other);
3918
+ case errorTag:
3919
+ return object.name == other.name && object.message == other.message;
3920
+ case regexpTag:
3921
+ case stringTag:
3922
+ return object == other + "";
3923
+ case mapTag:
3924
+ var convert = mapToArray;
3925
+ case setTag:
3926
+ var isPartial = bitmask & COMPARE_PARTIAL_FLAG$4;
3927
+ convert || (convert = setToArray);
3928
+ if (object.size != other.size && !isPartial) {
3929
+ return false;
3930
+ }
3931
+ var stacked = stack.get(object);
3932
+ if (stacked) {
3933
+ return stacked == other;
3934
+ }
3935
+ bitmask |= COMPARE_UNORDERED_FLAG$2;
3936
+ stack.set(object, other);
3937
+ var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);
3938
+ stack["delete"](object);
3939
+ return result;
3940
+ case symbolTag:
3941
+ if (symbolValueOf) {
3942
+ return symbolValueOf.call(object) == symbolValueOf.call(other);
3943
+ }
3944
+ }
3945
+ return false;
3946
+ }
3947
+ var COMPARE_PARTIAL_FLAG$3 = 1;
3948
+ var objectProto$1 = Object.prototype;
3949
+ var hasOwnProperty$1 = objectProto$1.hasOwnProperty;
3950
+ function equalObjects(object, other, bitmask, customizer, equalFunc, stack) {
3951
+ var isPartial = bitmask & COMPARE_PARTIAL_FLAG$3, objProps = getAllKeys(object), objLength = objProps.length, othProps = getAllKeys(other), othLength = othProps.length;
3952
+ if (objLength != othLength && !isPartial) {
3953
+ return false;
3954
+ }
3955
+ var index2 = objLength;
3956
+ while (index2--) {
3957
+ var key = objProps[index2];
3958
+ if (!(isPartial ? key in other : hasOwnProperty$1.call(other, key))) {
3959
+ return false;
3960
+ }
3961
+ }
3962
+ var objStacked = stack.get(object);
3963
+ var othStacked = stack.get(other);
3964
+ if (objStacked && othStacked) {
3965
+ return objStacked == other && othStacked == object;
3966
+ }
3967
+ var result = true;
3968
+ stack.set(object, other);
3969
+ stack.set(other, object);
3970
+ var skipCtor = isPartial;
3971
+ while (++index2 < objLength) {
3972
+ key = objProps[index2];
3973
+ var objValue = object[key], othValue = other[key];
3974
+ if (customizer) {
3975
+ var compared = isPartial ? customizer(othValue, objValue, key, other, object, stack) : customizer(objValue, othValue, key, object, other, stack);
3976
+ }
3977
+ if (!(compared === void 0 ? objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack) : compared)) {
3978
+ result = false;
3979
+ break;
3980
+ }
3981
+ skipCtor || (skipCtor = key == "constructor");
3982
+ }
3983
+ if (result && !skipCtor) {
3984
+ var objCtor = object.constructor, othCtor = other.constructor;
3985
+ if (objCtor != othCtor && ("constructor" in object && "constructor" in other) && !(typeof objCtor == "function" && objCtor instanceof objCtor && typeof othCtor == "function" && othCtor instanceof othCtor)) {
3986
+ result = false;
3987
+ }
3988
+ }
3989
+ stack["delete"](object);
3990
+ stack["delete"](other);
3991
+ return result;
3992
+ }
3993
+ var COMPARE_PARTIAL_FLAG$2 = 1;
3994
+ var argsTag = "[object Arguments]", arrayTag = "[object Array]", objectTag = "[object Object]";
3995
+ var objectProto = Object.prototype;
3996
+ var hasOwnProperty = objectProto.hasOwnProperty;
3997
+ function baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {
3998
+ var objIsArr = isArray(object), othIsArr = isArray(other), objTag = objIsArr ? arrayTag : getTag$1(object), othTag = othIsArr ? arrayTag : getTag$1(other);
3999
+ objTag = objTag == argsTag ? objectTag : objTag;
4000
+ othTag = othTag == argsTag ? objectTag : othTag;
4001
+ var objIsObj = objTag == objectTag, othIsObj = othTag == objectTag, isSameTag = objTag == othTag;
4002
+ if (isSameTag && isBuffer(object)) {
4003
+ if (!isBuffer(other)) {
4004
+ return false;
4005
+ }
4006
+ objIsArr = true;
4007
+ objIsObj = false;
4008
+ }
4009
+ if (isSameTag && !objIsObj) {
4010
+ stack || (stack = new Stack$1());
4011
+ return objIsArr || isTypedArray(object) ? equalArrays(object, other, bitmask, customizer, equalFunc, stack) : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);
4012
+ }
4013
+ if (!(bitmask & COMPARE_PARTIAL_FLAG$2)) {
4014
+ var objIsWrapped = objIsObj && hasOwnProperty.call(object, "__wrapped__"), othIsWrapped = othIsObj && hasOwnProperty.call(other, "__wrapped__");
4015
+ if (objIsWrapped || othIsWrapped) {
4016
+ var objUnwrapped = objIsWrapped ? object.value() : object, othUnwrapped = othIsWrapped ? other.value() : other;
4017
+ stack || (stack = new Stack$1());
4018
+ return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);
4019
+ }
4020
+ }
4021
+ if (!isSameTag) {
4022
+ return false;
4023
+ }
4024
+ stack || (stack = new Stack$1());
4025
+ return equalObjects(object, other, bitmask, customizer, equalFunc, stack);
4026
+ }
4027
+ function baseIsEqual(value, other, bitmask, customizer, stack) {
4028
+ if (value === other) {
4029
+ return true;
4030
+ }
4031
+ if (value == null || other == null || !isObjectLike(value) && !isObjectLike(other)) {
4032
+ return value !== value && other !== other;
4033
+ }
4034
+ return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);
4035
+ }
4036
+ var COMPARE_PARTIAL_FLAG$1 = 1, COMPARE_UNORDERED_FLAG$1 = 2;
4037
+ function baseIsMatch(object, source, matchData, customizer) {
4038
+ var index2 = matchData.length, length = index2;
4039
+ if (object == null) {
4040
+ return !length;
4041
+ }
4042
+ object = Object(object);
4043
+ while (index2--) {
4044
+ var data = matchData[index2];
4045
+ if (data[2] ? data[1] !== object[data[0]] : !(data[0] in object)) {
4046
+ return false;
4047
+ }
4048
+ }
4049
+ while (++index2 < length) {
4050
+ data = matchData[index2];
4051
+ var key = data[0], objValue = object[key], srcValue = data[1];
4052
+ if (data[2]) {
4053
+ if (objValue === void 0 && !(key in object)) {
4054
+ return false;
4055
+ }
4056
+ } else {
4057
+ var stack = new Stack$1();
4058
+ var result;
4059
+ if (!(result === void 0 ? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG$1 | COMPARE_UNORDERED_FLAG$1, customizer, stack) : result)) {
4060
+ return false;
4061
+ }
4062
+ }
4063
+ }
4064
+ return true;
4065
+ }
4066
+ function isStrictComparable(value) {
4067
+ return value === value && !isObject(value);
4068
+ }
4069
+ function getMatchData(object) {
4070
+ var result = keys(object), length = result.length;
4071
+ while (length--) {
4072
+ var key = result[length], value = object[key];
4073
+ result[length] = [key, value, isStrictComparable(value)];
4074
+ }
4075
+ return result;
4076
+ }
4077
+ function matchesStrictComparable(key, srcValue) {
4078
+ return function(object) {
4079
+ if (object == null) {
4080
+ return false;
4081
+ }
4082
+ return object[key] === srcValue && (srcValue !== void 0 || key in Object(object));
4083
+ };
4084
+ }
4085
+ function baseMatches(source) {
4086
+ var matchData = getMatchData(source);
4087
+ if (matchData.length == 1 && matchData[0][2]) {
4088
+ return matchesStrictComparable(matchData[0][0], matchData[0][1]);
4089
+ }
4090
+ return function(object) {
4091
+ return object === source || baseIsMatch(object, source, matchData);
4092
+ };
4093
+ }
4094
+ function baseHasIn(object, key) {
4095
+ return object != null && key in Object(object);
4096
+ }
4097
+ function hasPath(object, path, hasFunc) {
4098
+ path = castPath(path, object);
4099
+ var index2 = -1, length = path.length, result = false;
4100
+ while (++index2 < length) {
4101
+ var key = toKey(path[index2]);
4102
+ if (!(result = object != null && hasFunc(object, key))) {
4103
+ break;
4104
+ }
4105
+ object = object[key];
4106
+ }
4107
+ if (result || ++index2 != length) {
4108
+ return result;
4109
+ }
4110
+ length = object == null ? 0 : object.length;
4111
+ return !!length && isLength(length) && isIndex(key, length) && (isArray(object) || isArguments(object));
4112
+ }
4113
+ function hasIn(object, path) {
4114
+ return object != null && hasPath(object, path, baseHasIn);
4115
+ }
4116
+ var COMPARE_PARTIAL_FLAG = 1, COMPARE_UNORDERED_FLAG = 2;
4117
+ function baseMatchesProperty(path, srcValue) {
4118
+ if (isKey(path) && isStrictComparable(srcValue)) {
4119
+ return matchesStrictComparable(toKey(path), srcValue);
4120
+ }
4121
+ return function(object) {
4122
+ var objValue = get(object, path);
4123
+ return objValue === void 0 && objValue === srcValue ? hasIn(object, path) : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG);
4124
+ };
4125
+ }
4126
+ function baseProperty(key) {
4127
+ return function(object) {
4128
+ return object == null ? void 0 : object[key];
4129
+ };
4130
+ }
4131
+ function basePropertyDeep(path) {
4132
+ return function(object) {
4133
+ return baseGet(object, path);
4134
+ };
4135
+ }
4136
+ function property(path) {
4137
+ return isKey(path) ? baseProperty(toKey(path)) : basePropertyDeep(path);
4138
+ }
4139
+ function baseIteratee(value) {
4140
+ if (typeof value == "function") {
4141
+ return value;
4142
+ }
4143
+ if (value == null) {
4144
+ return identity;
4145
+ }
4146
+ if (typeof value == "object") {
4147
+ return isArray(value) ? baseMatchesProperty(value[0], value[1]) : baseMatches(value);
4148
+ }
4149
+ return property(value);
4150
+ }
4151
+ function createBaseFor(fromRight) {
4152
+ return function(object, iteratee, keysFunc) {
4153
+ var index2 = -1, iterable = Object(object), props = keysFunc(object), length = props.length;
4154
+ while (length--) {
4155
+ var key = props[++index2];
4156
+ if (iteratee(iterable[key], key, iterable) === false) {
4157
+ break;
4158
+ }
4159
+ }
4160
+ return object;
4161
+ };
4162
+ }
4163
+ var baseFor = createBaseFor();
4164
+ var now = function() {
4165
+ return root.Date.now();
4166
+ };
4167
+ var FUNC_ERROR_TEXT = "Expected a function";
4168
+ var nativeMax = Math.max, nativeMin = Math.min;
4169
+ function debounce(func, wait, options2) {
4170
+ var lastArgs, lastThis, maxWait, result, timerId, lastCallTime, lastInvokeTime = 0, leading = false, maxing = false, trailing = true;
4171
+ if (typeof func != "function") {
4172
+ throw new TypeError(FUNC_ERROR_TEXT);
4173
+ }
4174
+ wait = toNumber(wait) || 0;
4175
+ if (isObject(options2)) {
4176
+ leading = !!options2.leading;
4177
+ maxing = "maxWait" in options2;
4178
+ maxWait = maxing ? nativeMax(toNumber(options2.maxWait) || 0, wait) : maxWait;
4179
+ trailing = "trailing" in options2 ? !!options2.trailing : trailing;
4180
+ }
4181
+ function invokeFunc(time) {
4182
+ var args = lastArgs, thisArg = lastThis;
4183
+ lastArgs = lastThis = void 0;
4184
+ lastInvokeTime = time;
4185
+ result = func.apply(thisArg, args);
4186
+ return result;
4187
+ }
4188
+ function leadingEdge(time) {
4189
+ lastInvokeTime = time;
4190
+ timerId = setTimeout(timerExpired, wait);
4191
+ return leading ? invokeFunc(time) : result;
4192
+ }
4193
+ function remainingWait(time) {
4194
+ var timeSinceLastCall = time - lastCallTime, timeSinceLastInvoke = time - lastInvokeTime, timeWaiting = wait - timeSinceLastCall;
4195
+ return maxing ? nativeMin(timeWaiting, maxWait - timeSinceLastInvoke) : timeWaiting;
4196
+ }
4197
+ function shouldInvoke(time) {
4198
+ var timeSinceLastCall = time - lastCallTime, timeSinceLastInvoke = time - lastInvokeTime;
4199
+ return lastCallTime === void 0 || timeSinceLastCall >= wait || timeSinceLastCall < 0 || maxing && timeSinceLastInvoke >= maxWait;
4200
+ }
4201
+ function timerExpired() {
4202
+ var time = now();
4203
+ if (shouldInvoke(time)) {
4204
+ return trailingEdge(time);
4205
+ }
4206
+ timerId = setTimeout(timerExpired, remainingWait(time));
4207
+ }
4208
+ function trailingEdge(time) {
4209
+ timerId = void 0;
4210
+ if (trailing && lastArgs) {
4211
+ return invokeFunc(time);
4212
+ }
4213
+ lastArgs = lastThis = void 0;
4214
+ return result;
4215
+ }
4216
+ function cancel() {
4217
+ if (timerId !== void 0) {
4218
+ clearTimeout(timerId);
4219
+ }
4220
+ lastInvokeTime = 0;
4221
+ lastArgs = lastCallTime = lastThis = timerId = void 0;
4222
+ }
4223
+ function flush() {
4224
+ return timerId === void 0 ? result : trailingEdge(now());
4225
+ }
4226
+ function debounced() {
4227
+ var time = now(), isInvoking = shouldInvoke(time);
4228
+ lastArgs = arguments;
4229
+ lastThis = this;
4230
+ lastCallTime = time;
4231
+ if (isInvoking) {
4232
+ if (timerId === void 0) {
4233
+ return leadingEdge(lastCallTime);
4234
+ }
4235
+ if (maxing) {
4236
+ clearTimeout(timerId);
4237
+ timerId = setTimeout(timerExpired, wait);
4238
+ return invokeFunc(lastCallTime);
4239
+ }
4240
+ }
4241
+ if (timerId === void 0) {
4242
+ timerId = setTimeout(timerExpired, wait);
4243
+ }
4244
+ return result;
4245
+ }
4246
+ debounced.cancel = cancel;
4247
+ debounced.flush = flush;
4248
+ return debounced;
4249
+ }
4250
+ function assignMergeValue(object, key, value) {
4251
+ if (value !== void 0 && !eq(object[key], value) || value === void 0 && !(key in object)) {
4252
+ baseAssignValue(object, key, value);
4253
+ }
4254
+ }
4255
+ function isArrayLikeObject(value) {
4256
+ return isObjectLike(value) && isArrayLike(value);
4257
+ }
4258
+ function safeGet(object, key) {
4259
+ if (key === "constructor" && typeof object[key] === "function") {
4260
+ return;
4261
+ }
4262
+ if (key == "__proto__") {
4263
+ return;
4264
+ }
4265
+ return object[key];
4266
+ }
4267
+ function toPlainObject(value) {
4268
+ return copyObject(value, keysIn(value));
4269
+ }
4270
+ function baseMergeDeep(object, source, key, srcIndex, mergeFunc, customizer, stack) {
4271
+ var objValue = safeGet(object, key), srcValue = safeGet(source, key), stacked = stack.get(srcValue);
4272
+ if (stacked) {
4273
+ assignMergeValue(object, key, stacked);
4274
+ return;
4275
+ }
4276
+ var newValue = customizer ? customizer(objValue, srcValue, key + "", object, source, stack) : void 0;
4277
+ var isCommon = newValue === void 0;
4278
+ if (isCommon) {
4279
+ var isArr = isArray(srcValue), isBuff = !isArr && isBuffer(srcValue), isTyped = !isArr && !isBuff && isTypedArray(srcValue);
4280
+ newValue = srcValue;
4281
+ if (isArr || isBuff || isTyped) {
4282
+ if (isArray(objValue)) {
4283
+ newValue = objValue;
4284
+ } else if (isArrayLikeObject(objValue)) {
4285
+ newValue = copyArray(objValue);
4286
+ } else if (isBuff) {
4287
+ isCommon = false;
4288
+ newValue = cloneBuffer(srcValue);
4289
+ } else if (isTyped) {
4290
+ isCommon = false;
4291
+ newValue = cloneTypedArray(srcValue);
4292
+ } else {
4293
+ newValue = [];
4294
+ }
4295
+ } else if (isPlainObject(srcValue) || isArguments(srcValue)) {
4296
+ newValue = objValue;
4297
+ if (isArguments(objValue)) {
4298
+ newValue = toPlainObject(objValue);
4299
+ } else if (!isObject(objValue) || isFunction(objValue)) {
4300
+ newValue = initCloneObject(srcValue);
4301
+ }
4302
+ } else {
4303
+ isCommon = false;
4304
+ }
4305
+ }
4306
+ if (isCommon) {
4307
+ stack.set(srcValue, newValue);
4308
+ mergeFunc(newValue, srcValue, srcIndex, customizer, stack);
4309
+ stack["delete"](srcValue);
4310
+ }
4311
+ assignMergeValue(object, key, newValue);
4312
+ }
4313
+ function baseMerge(object, source, srcIndex, customizer, stack) {
4314
+ if (object === source) {
4315
+ return;
4316
+ }
4317
+ baseFor(source, function(srcValue, key) {
4318
+ stack || (stack = new Stack$1());
4319
+ if (isObject(srcValue)) {
4320
+ baseMergeDeep(object, source, key, srcIndex, baseMerge, customizer, stack);
4321
+ } else {
4322
+ var newValue = customizer ? customizer(safeGet(object, key), srcValue, key + "", object, source, stack) : void 0;
4323
+ if (newValue === void 0) {
4324
+ newValue = srcValue;
4325
+ }
4326
+ assignMergeValue(object, key, newValue);
4327
+ }
4328
+ }, keysIn);
4329
+ }
4330
+ var merge = createAssigner(function(object, source, srcIndex) {
4331
+ baseMerge(object, source, srcIndex);
4332
+ });
4333
+ var INFINITY = 1 / 0;
4334
+ var createSet = !(Set$1 && 1 / setToArray(new Set$1([, -0]))[1] == INFINITY) ? noop : function(values) {
4335
+ return new Set$1(values);
4336
+ };
4337
+ var LARGE_ARRAY_SIZE = 200;
4338
+ function baseUniq(array, iteratee, comparator) {
4339
+ var index2 = -1, includes = arrayIncludes, length = array.length, isCommon = true, result = [], seen = result;
4340
+ if (length >= LARGE_ARRAY_SIZE) {
4341
+ var set = iteratee ? null : createSet(array);
4342
+ if (set) {
4343
+ return setToArray(set);
4344
+ }
4345
+ isCommon = false;
4346
+ includes = cacheHas;
4347
+ seen = new SetCache();
4348
+ } else {
4349
+ seen = iteratee ? [] : result;
4350
+ }
4351
+ outer:
4352
+ while (++index2 < length) {
4353
+ var value = array[index2], computed = iteratee ? iteratee(value) : value;
4354
+ value = value !== 0 ? value : 0;
4355
+ if (isCommon && computed === computed) {
4356
+ var seenIndex = seen.length;
4357
+ while (seenIndex--) {
4358
+ if (seen[seenIndex] === computed) {
4359
+ continue outer;
4360
+ }
4361
+ }
4362
+ if (iteratee) {
4363
+ seen.push(computed);
4364
+ }
4365
+ result.push(value);
4366
+ } else if (!includes(seen, computed, comparator)) {
4367
+ if (seen !== result) {
4368
+ seen.push(computed);
4369
+ }
4370
+ result.push(value);
4371
+ }
4372
+ }
4373
+ return result;
4374
+ }
4375
+ function uniqBy(array, iteratee) {
4376
+ return array && array.length ? baseUniq(array, baseIteratee(iteratee)) : [];
4377
+ }
4378
+ var idCounter = 0;
4379
+ function uniqueId(prefix) {
4380
+ var id = ++idCounter;
4381
+ return toString(prefix) + id;
4382
+ }
2935
4383
  const BANK_TRANSACTIONS_TAG_KEY = "#bank-transactions";
2936
4384
  function keyLoader$8(previousPageData, {
2937
4385
  access_token: accessToken,
@@ -3038,7 +4486,7 @@ const useBankTransactionsGlobalCacheActions = () => {
3038
4486
  [invalidate]
3039
4487
  );
3040
4488
  const debouncedInvalidateBankTransactions = react.useMemo(
3041
- () => _.debounce(
4489
+ () => debounce(
3042
4490
  invalidateBankTransactions,
3043
4491
  INVALIDATION_DEBOUNCE_OPTIONS$2.wait,
3044
4492
  {
@@ -3073,7 +4521,7 @@ const useBankTransactionsGlobalCacheActions = () => {
3073
4521
  };
3074
4522
  };
3075
4523
  const BANK_ACCOUNTS_TAG_KEY = "#bank-accounts";
3076
- const getBankAccounts = get(
4524
+ const getBankAccounts = get$1(
3077
4525
  ({ businessId }) => `/v1/businesses/${businessId}/bank-accounts`
3078
4526
  );
3079
4527
  function buildKey$X({
@@ -4486,7 +5934,7 @@ function usePnlDetailLinesInvalidator() {
4486
5934
  [invalidate]
4487
5935
  );
4488
5936
  const debouncedInvalidatePnlDetailLines = react.useMemo(
4489
- () => _.debounce(
5937
+ () => debounce(
4490
5938
  invalidatePnlDetailLines,
4491
5939
  INVALIDATION_DEBOUNCE_OPTIONS$1.wait,
4492
5940
  {
@@ -4512,7 +5960,7 @@ const getProfitAndLossDetailLines = (apiUrl, accessToken, params) => {
4512
5960
  tagValues,
4513
5961
  pnlStructure
4514
5962
  });
4515
- return get(
5963
+ return get$1(
4516
5964
  ({ businessId: businessId2 }) => `/v1/businesses/${businessId2}/reports/profit-and-loss/lines?${queryParams.toString()}`
4517
5965
  )(apiUrl, accessToken, { params: { businessId } });
4518
5966
  };
@@ -4564,7 +6012,7 @@ function buildKey$W({
4564
6012
  };
4565
6013
  }
4566
6014
  }
4567
- const getProfitAndLoss = get(
6015
+ const getProfitAndLoss = get$1(
4568
6016
  ({
4569
6017
  businessId,
4570
6018
  startDate,
@@ -4614,7 +6062,7 @@ const useProfitAndLossReportCacheActions = () => {
4614
6062
  [invalidate]
4615
6063
  );
4616
6064
  const debouncedInvalidateProfitAndLossReport = react.useMemo(
4617
- () => _.debounce(
6065
+ () => debounce(
4618
6066
  invalidateProfitAndLossReport,
4619
6067
  INVALIDATE_DEBOUNCE_OPTIONS$2.wait,
4620
6068
  {
@@ -4676,7 +6124,7 @@ function buildKey$V({
4676
6124
  };
4677
6125
  }
4678
6126
  }
4679
- const getProfitAndLossSummaries = get(
6127
+ const getProfitAndLossSummaries = get$1(
4680
6128
  ({
4681
6129
  businessId,
4682
6130
  startYear,
@@ -4728,7 +6176,7 @@ const useProfitAndLossSummariesCacheActions = () => {
4728
6176
  [invalidate]
4729
6177
  );
4730
6178
  const debouncedInvalidateProfitAndLossSummaries = react.useMemo(
4731
- () => _.debounce(
6179
+ () => debounce(
4732
6180
  invalidateProfitAndLossSummaries,
4733
6181
  INVALIDATE_DEBOUNCE_OPTIONS$1.wait,
4734
6182
  {
@@ -4752,7 +6200,7 @@ const useProfitAndLossGlobalInvalidator = () => {
4752
6200
  yield invalidateProfitAndLossSummaries();
4753
6201
  }), [invalidateProfitAndLossReport, invalidateProfitAndLossSummaries]);
4754
6202
  const debouncedInvalidateProfitAndLoss = react.useMemo(
4755
- () => _.debounce(
6203
+ () => debounce(
4756
6204
  invalidateProfitAndLossReport,
4757
6205
  INVALIDATE_DEBOUNCE_OPTIONS.wait,
4758
6206
  {
@@ -5192,7 +6640,7 @@ const useAugmentedBankTransactions = (params) => {
5192
6640
  }
5193
6641
  };
5194
6642
  }, [anyAccountSyncing, transactionsNotSynced, pollIntervalMs]);
5195
- useTriggerOnChange(data, anyAccountSyncing, (_2) => {
6643
+ useTriggerOnChange(data, anyAccountSyncing, (_) => {
5196
6644
  var _a2;
5197
6645
  clearInterval(intervalIdRef.current);
5198
6646
  setPollIntervalMs(POLL_INTERVAL_AFTER_TXNS_RECEIVED_MS);
@@ -7621,7 +9069,7 @@ function useTruncationDetection(elementRef, options2 = {
7621
9069
  }, [elementRef, checkFirstChild, ...dependencies]);
7622
9070
  const DEBOUNCE_TIME_IN_MS = 450;
7623
9071
  const debouncedCheckTruncation = react.useMemo(
7624
- () => _.debounce(checkTruncation, DEBOUNCE_TIME_IN_MS),
9072
+ () => debounce(checkTruncation, DEBOUNCE_TIME_IN_MS),
7625
9073
  [checkTruncation]
7626
9074
  );
7627
9075
  useResizeObserver(elementRef, debouncedCheckTruncation);
@@ -7631,6 +9079,32 @@ function useTruncationDetection(elementRef, options2 = {
7631
9079
  }, [checkTruncation]);
7632
9080
  return isTruncated;
7633
9081
  }
9082
+ function mergeRefsReact16(refs) {
9083
+ return (value) => {
9084
+ for (const ref of refs) assignRef(ref, value);
9085
+ };
9086
+ }
9087
+ function mergeRefsReact19(refs) {
9088
+ return (value) => {
9089
+ const cleanups = [];
9090
+ for (const ref of refs) {
9091
+ const cleanup = assignRef(ref, value);
9092
+ const isCleanup = typeof cleanup === "function";
9093
+ cleanups.push(isCleanup ? cleanup : () => assignRef(ref, null));
9094
+ }
9095
+ return () => {
9096
+ for (const cleanup of cleanups) cleanup();
9097
+ };
9098
+ };
9099
+ }
9100
+ function assignRef(ref, value) {
9101
+ if (typeof ref === "function") {
9102
+ return ref(value);
9103
+ } else if (ref) {
9104
+ ref.current = value;
9105
+ }
9106
+ }
9107
+ var mergeRefs = parseInt(react.version.split(".")[0], 10) >= 19 ? mergeRefsReact19 : mergeRefsReact16;
7634
9108
  const CLASS_NAME$d = "Layer__Stack";
7635
9109
  const Stack = react.forwardRef(
7636
9110
  function Stack2(_na, ref) {
@@ -7841,7 +9315,7 @@ const Span = react.forwardRef(
7841
9315
  const { className, tooltipContentWidth = "md" } = props;
7842
9316
  const internalRef = react.useRef(null);
7843
9317
  const isTruncated = useTruncationDetection(internalRef, { checkFirstChild: true });
7844
- const mergedRef = reactMergeRefs.mergeRefs([internalRef, forwardedRef]);
9318
+ const mergedRef = mergeRefs([internalRef, forwardedRef]);
7845
9319
  if (props.withTooltip) {
7846
9320
  const dataPropertiesWithEllipsis = __spreadProps(__spreadValues({}, dataProperties), { "data-with-tooltip": true });
7847
9321
  return /* @__PURE__ */ jsxRuntime.jsxs(Tooltip, { disabled: !isTruncated, children: [
@@ -10988,7 +12462,7 @@ function buildKey$Q({
10988
12462
  };
10989
12463
  }
10990
12464
  }
10991
- const getTagDimensionByKey = get(({ businessId, dimensionKey }) => `/v1/businesses/${businessId}/tags/dimensions/key/${dimensionKey}`);
12465
+ const getTagDimensionByKey = get$1(({ businessId, dimensionKey }) => `/v1/businesses/${businessId}/tags/dimensions/key/${dimensionKey}`);
10992
12466
  class TagDimensionByKeySWRResponse {
10993
12467
  constructor(swrResponse) {
10994
12468
  __publicField(this, "swrResponse");
@@ -11201,7 +12675,7 @@ const ListCustomersRawResultSchema = effect.Schema.Struct({
11201
12675
  })
11202
12676
  })
11203
12677
  });
11204
- const listCustomers = get(({
12678
+ const listCustomers = get$1(({
11205
12679
  businessId,
11206
12680
  cursor,
11207
12681
  limit,
@@ -11309,7 +12783,7 @@ const ListVendorsRawResultSchema = effect.Schema.Struct({
11309
12783
  })
11310
12784
  })
11311
12785
  });
11312
- const listVendors = get(({
12786
+ const listVendors = get$1(({
11313
12787
  businessId,
11314
12788
  cursor,
11315
12789
  limit,
@@ -11416,7 +12890,7 @@ function useDebounce(fn) {
11416
12890
  const internalFn = (...args) => {
11417
12891
  internalFnRef.current(...args);
11418
12892
  };
11419
- return _.debounce(
12893
+ return debounce(
11420
12894
  internalFn,
11421
12895
  DEFAULT_WAIT,
11422
12896
  { maxWait: DEFAULT_MAX_WAIT }
@@ -11682,8 +13156,8 @@ function useTagBankTransaction({ bankTransactionId }) {
11682
13156
  const optimisticTagId = uuid.v4();
11683
13157
  void optimisticallyUpdateBankTransactions((bankTransaction) => {
11684
13158
  if (bankTransaction.id === bankTransactionId) {
11685
- const now = /* @__PURE__ */ new Date();
11686
- const nowISOString = now.toISOString();
13159
+ const now2 = /* @__PURE__ */ new Date();
13160
+ const nowISOString = now2.toISOString();
11687
13161
  return __spreadProps(__spreadValues({}, bankTransaction), {
11688
13162
  transaction_tags: [
11689
13163
  ...bankTransaction.transaction_tags,
@@ -11809,7 +13283,7 @@ function useRemoveTagFromBankTransaction({ bankTransactionId }) {
11809
13283
  }
11810
13284
  const range$1 = (start, end) => {
11811
13285
  const length = end - start + 1;
11812
- return Array.from({ length }, (_2, idx) => idx + start);
13286
+ return Array.from({ length }, (_, idx) => idx + start);
11813
13287
  };
11814
13288
  const sleep = (time) => {
11815
13289
  return new Promise((resolve) => setTimeout(resolve, time));
@@ -11990,7 +13464,7 @@ function constrainToKnownBookkeepingStatus(status) {
11990
13464
  }
11991
13465
  return "NOT_PURCHASED";
11992
13466
  }
11993
- const getBookkeepingStatus = get(({ businessId }) => {
13467
+ const getBookkeepingStatus = get$1(({ businessId }) => {
11994
13468
  return `/v1/businesses/${businessId}/bookkeeping/status`;
11995
13469
  });
11996
13470
  const BOOKKEEPING_TAG_KEY = "#bookkeeping";
@@ -13048,7 +14522,7 @@ function buildKey$J({
13048
14522
  };
13049
14523
  }
13050
14524
  }
13051
- const getCategories = get(({ businessId, mode }) => {
14525
+ const getCategories = get$1(({ businessId, mode }) => {
13052
14526
  const parameters = toDefinedSearchParameters({ mode });
13053
14527
  return `/v1/businesses/${businessId}/categories?${parameters}`;
13054
14528
  });
@@ -13419,7 +14893,7 @@ const isSplitsValid = (localSplits) => {
13419
14893
  return validateSplit(localSplits).reduce((acc, splitError) => acc && splitError === void 0, true);
13420
14894
  };
13421
14895
  const getSplitsErrorMessage = (localSplits) => {
13422
- return _.uniqBy(validateSplit(localSplits), (error) => error == null ? void 0 : error.toString()).filter(Boolean)[0] || "";
14896
+ return uniqBy(validateSplit(localSplits), (error) => error == null ? void 0 : error.toString()).filter(Boolean)[0] || "";
13423
14897
  };
13424
14898
  const validateSplit = (localSplits) => {
13425
14899
  const errors = localSplits.map((split) => {
@@ -13431,7 +14905,7 @@ const validateSplit = (localSplits) => {
13431
14905
  }
13432
14906
  return void 0;
13433
14907
  });
13434
- return _.uniqBy(errors, (error) => error == null ? void 0 : error.toString());
14908
+ return uniqBy(errors, (error) => error == null ? void 0 : error.toString());
13435
14909
  };
13436
14910
  const calculateAddSplit = (initialRowSplits) => {
13437
14911
  const newSplit = {
@@ -14078,7 +15552,7 @@ function constrainToKnownBookkeepingPeriodStatus(status) {
14078
15552
  }
14079
15553
  return "BOOKKEEPING_NOT_ACTIVE";
14080
15554
  }
14081
- const getBookkeepingPeriods = get(({ businessId }) => {
15555
+ const getBookkeepingPeriods = get$1(({ businessId }) => {
14082
15556
  return `/v1/businesses/${businessId}/bookkeeping/periods`;
14083
15557
  });
14084
15558
  const BOOKKEEPING_PERIODS_TAG_KEY = "#bookkeeping-periods";
@@ -14242,7 +15716,7 @@ const BookkeepingStatus$1 = ({ status, text, monthNumber, iconOnly }) => {
14242
15716
  )
14243
15717
  ] }));
14244
15718
  };
14245
- const BankTransactionProcessingInfo = () => /* @__PURE__ */ jsxRuntime.jsxs(DeprecatedTooltip, { offset: 12, children: [
15719
+ const BankTransactionsProcessingInfo = () => /* @__PURE__ */ jsxRuntime.jsxs(DeprecatedTooltip, { offset: 12, children: [
14246
15720
  /* @__PURE__ */ jsxRuntime.jsx(DeprecatedTooltipTrigger, { children: /* @__PURE__ */ jsxRuntime.jsx(BookkeepingStatus$1, { status: BookkeepingPeriodStatus.IN_PROGRESS_AWAITING_BOOKKEEPER, text: "Processing" }) }),
14247
15721
  /* @__PURE__ */ jsxRuntime.jsx(DeprecatedTooltipContent, { className: "Layer__tooltip", width: "md", children: "Our team will review and categorize this transaction. We'll reach out if we have any questions about it." })
14248
15722
  ] });
@@ -14393,9 +15867,10 @@ const BankTransactionRow = ({
14393
15867
  () => toDataProperties({ "show-receipt-upload-column": showReceiptUploadColumn }),
14394
15868
  [showReceiptUploadColumn]
14395
15869
  );
15870
+ const colSpan = categorizationEnabled ? 7 : 6;
14396
15871
  return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
14397
15872
  /* @__PURE__ */ jsxRuntime.jsxs("tr", { className: rowClassName, children: [
14398
- /* @__PURE__ */ jsxRuntime.jsx("td", { className: "Layer__table-cell Layer__bank-transactions__checkbox-col", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "Layer__table-cell-content", children: /* @__PURE__ */ jsxRuntime.jsx(
15873
+ categorizationEnabled && /* @__PURE__ */ jsxRuntime.jsx("td", { className: "Layer__table-cell Layer__bank-transactions__checkbox-col", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "Layer__table-cell-content", children: /* @__PURE__ */ jsxRuntime.jsx(
14399
15874
  Checkbox,
14400
15875
  {
14401
15876
  isSelected: isTransactionSelected,
@@ -14559,7 +16034,7 @@ const BankTransactionRow = ({
14559
16034
  children: categorized ? (stringOverrides == null ? void 0 : stringOverrides.updateButtonText) || "Update" : (stringOverrides == null ? void 0 : stringOverrides.approveButtonText) || "Confirm"
14560
16035
  }
14561
16036
  ) : null,
14562
- !categorizationEnabled && !categorized ? /* @__PURE__ */ jsxRuntime.jsx(VStack, { pis: "xs", fluid: true, children: /* @__PURE__ */ jsxRuntime.jsx(BankTransactionProcessingInfo, {}) }) : null,
16037
+ !categorizationEnabled && !categorized ? /* @__PURE__ */ jsxRuntime.jsx(VStack, { pis: "xs", fluid: true, children: /* @__PURE__ */ jsxRuntime.jsx(BankTransactionsProcessingInfo, {}) }) : null,
14563
16038
  /* @__PURE__ */ jsxRuntime.jsx(
14564
16039
  IconButton,
14565
16040
  {
@@ -14580,7 +16055,7 @@ const BankTransactionRow = ({
14580
16055
  }
14581
16056
  )
14582
16057
  ] }),
14583
- /* @__PURE__ */ jsxRuntime.jsx("tr", { children: /* @__PURE__ */ jsxRuntime.jsx("td", { colSpan: 7, className: "Layer__bank-transaction-row__expanded-td", children: /* @__PURE__ */ jsxRuntime.jsx(
16058
+ /* @__PURE__ */ jsxRuntime.jsx("tr", { children: /* @__PURE__ */ jsxRuntime.jsx("td", { colSpan, className: "Layer__bank-transaction-row__expanded-td", children: /* @__PURE__ */ jsxRuntime.jsx(
14584
16059
  ExpandedBankTransactionRow,
14585
16060
  {
14586
16061
  ref: expandedRowRef,
@@ -14636,7 +16111,7 @@ const Assignment = ({ bankTransaction }) => {
14636
16111
  }
14637
16112
  return /* @__PURE__ */ jsxRuntime.jsx(Text, { children: (_d = bankTransaction == null ? void 0 : bankTransaction.category) == null ? void 0 : _d.display_name });
14638
16113
  };
14639
- const BankTransactionListItem = ({
16114
+ const BankTransactionsListItem = ({
14640
16115
  index: index2,
14641
16116
  dateFormat,
14642
16117
  bankTransaction,
@@ -14728,7 +16203,7 @@ const BankTransactionListItem = ({
14728
16203
  ] }),
14729
16204
  /* @__PURE__ */ jsxRuntime.jsxs(HStack, { className: "Layer__bank-transaction-list-item__body", children: [
14730
16205
  /* @__PURE__ */ jsxRuntime.jsxs(HStack, { gap: "sm", className: "Layer__bank-transaction-list-item__body__name", children: [
14731
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "Layer__bank-transaction-list-item__checkbox", children: /* @__PURE__ */ jsxRuntime.jsx(
16206
+ categorizationEnabled && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "Layer__bank-transaction-list-item__checkbox", children: /* @__PURE__ */ jsxRuntime.jsx(
14732
16207
  Checkbox,
14733
16208
  {
14734
16209
  isSelected: isTransactionSelected,
@@ -14752,7 +16227,7 @@ const BankTransactionListItem = ({
14752
16227
  }
14753
16228
  )
14754
16229
  ] }),
14755
- !categorizationEnabled && !categorized ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "Layer__bank-transaction-list-item__processing-info", children: /* @__PURE__ */ jsxRuntime.jsx(BankTransactionProcessingInfo, {}) }) : null,
16230
+ !categorizationEnabled && !categorized ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "Layer__bank-transaction-list-item__processing-info", children: /* @__PURE__ */ jsxRuntime.jsx(BankTransactionsProcessingInfo, {}) }) : null,
14756
16231
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "Layer__bank-transaction-list-item__expanded-row", children: /* @__PURE__ */ jsxRuntime.jsx(
14757
16232
  ExpandedBankTransactionRow,
14758
16233
  {
@@ -14860,7 +16335,7 @@ const useUpsertBankTransactionsDefaultCategories = (bankTransactions) => {
14860
16335
  setOnlyNewTransactionCategories(defaultCategories);
14861
16336
  }, [bankTransactions, setOnlyNewTransactionCategories]);
14862
16337
  };
14863
- const BankTransactionList = ({
16338
+ const BankTransactionsList = ({
14864
16339
  bankTransactions,
14865
16340
  editable,
14866
16341
  removeTransaction,
@@ -14872,8 +16347,10 @@ const BankTransactionList = ({
14872
16347
  }) => {
14873
16348
  const { isAllSelected, isPartiallySelected, onHeaderCheckboxChange } = useBankTransactionsTableCheckboxState({ bankTransactions });
14874
16349
  useUpsertBankTransactionsDefaultCategories(bankTransactions);
16350
+ const bookkeepingStatus = useEffectiveBookkeepingStatus();
16351
+ const categorizationEnabled = isCategorizationEnabledForStatus(bookkeepingStatus);
14875
16352
  return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
14876
- /* @__PURE__ */ jsxRuntime.jsxs(
16353
+ categorizationEnabled && /* @__PURE__ */ jsxRuntime.jsxs(
14877
16354
  HStack,
14878
16355
  {
14879
16356
  gap: "md",
@@ -14897,7 +16374,7 @@ const BankTransactionList = ({
14897
16374
  ),
14898
16375
  /* @__PURE__ */ jsxRuntime.jsx("ul", { className: "Layer__bank-transactions__list", children: bankTransactions == null ? void 0 : bankTransactions.map(
14899
16376
  (bankTransaction, index2) => /* @__PURE__ */ jsxRuntime.jsx(
14900
- BankTransactionListItem,
16377
+ BankTransactionsListItem,
14901
16378
  {
14902
16379
  index: index2,
14903
16380
  dateFormat: DATE_FORMAT$1,
@@ -16014,7 +17491,7 @@ const getAssignedValue = (bankTransaction, renderInAppLink) => {
16014
17491
  }
16015
17492
  return (_d = bankTransaction.category) == null ? void 0 : _d.display_name;
16016
17493
  };
16017
- const BankTransactionMobileListItem = ({
17494
+ const BankTransactionsMobileListItem = ({
16018
17495
  index: index2,
16019
17496
  bankTransaction,
16020
17497
  removeTransaction,
@@ -16137,7 +17614,7 @@ const BankTransactionMobileListItem = ({
16137
17614
  hasReceipts(bankTransaction) ? /* @__PURE__ */ jsxRuntime.jsx(File, { size: 12 }) : null
16138
17615
  ] }),
16139
17616
  categorized && fullAccountName,
16140
- !categorizationEnabled && !categorized ? /* @__PURE__ */ jsxRuntime.jsx(BankTransactionProcessingInfo, {}) : null
17617
+ !categorizationEnabled && !categorized ? /* @__PURE__ */ jsxRuntime.jsx(BankTransactionsProcessingInfo, {}) : null
16141
17618
  ] }),
16142
17619
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: `${className}__heading__amount`, children: [
16143
17620
  /* @__PURE__ */ jsxRuntime.jsxs(
@@ -16214,7 +17691,7 @@ const BankTransactionMobileListItem = ({
16214
17691
  )
16215
17692
  ] });
16216
17693
  };
16217
- const BankTransactionMobileList = ({
17694
+ const BankTransactionsMobileList = ({
16218
17695
  bankTransactions,
16219
17696
  removeTransaction,
16220
17697
  editable,
@@ -16226,7 +17703,7 @@ const BankTransactionMobileList = ({
16226
17703
  const transactionToOpenContextData = useTransactionToOpen();
16227
17704
  return /* @__PURE__ */ jsxRuntime.jsx(TransactionToOpenContext.Provider, { value: transactionToOpenContextData, children: /* @__PURE__ */ jsxRuntime.jsx("ul", { className: "Layer__bank-transactions__mobile-list", children: bankTransactions == null ? void 0 : bankTransactions.map(
16228
17705
  (bankTransaction, index2) => /* @__PURE__ */ jsxRuntime.jsx(
16229
- BankTransactionMobileListItem,
17706
+ BankTransactionsMobileListItem,
16230
17707
  {
16231
17708
  index: index2,
16232
17709
  bankTransaction,
@@ -16248,7 +17725,7 @@ const SkeletonTableLoader = ({
16248
17725
  height = 20,
16249
17726
  width = 100
16250
17727
  }) => {
16251
- return /* @__PURE__ */ jsxRuntime.jsx("tbody", { className: "Layer__skeleton-table-body__loader", children: Array.from({ length: rows }).map((_2, rowIndex) => /* @__PURE__ */ jsxRuntime.jsx("tr", { children: cols.map((col, colIndex) => {
17728
+ return /* @__PURE__ */ jsxRuntime.jsx("tbody", { className: "Layer__skeleton-table-body__loader", children: Array.from({ length: rows }).map((_, rowIndex) => /* @__PURE__ */ jsxRuntime.jsx("tr", { children: cols.map((col, colIndex) => {
16252
17729
  const trim = col.trimLastXRows && rowIndex >= col.trimLastXRows - 1 ? (rowIndex - col.trimLastXRows + 1) * 10 : 0;
16253
17730
  return /* @__PURE__ */ jsxRuntime.jsx(
16254
17731
  "td",
@@ -16340,6 +17817,8 @@ const BankTransactionsTable = ({
16340
17817
  var _a, _b, _c, _d, _e, _f, _g;
16341
17818
  const { isAllSelected, isPartiallySelected, onHeaderCheckboxChange } = useBankTransactionsTableCheckboxState({ bankTransactions });
16342
17819
  useUpsertBankTransactionsDefaultCategories(bankTransactions);
17820
+ const bookkeepingStatus = useEffectiveBookkeepingStatus();
17821
+ const categorizationEnabled = isCategorizationEnabledForStatus(bookkeepingStatus);
16343
17822
  const showReceiptColumn = (_a = showReceiptUploads && (bankTransactions == null ? void 0 : bankTransactions.some(
16344
17823
  (transaction) => {
16345
17824
  var _a2;
@@ -16357,7 +17836,7 @@ const BankTransactionsTable = ({
16357
17836
  className: "Layer__table Layer__bank-transactions__table with-cell-separators",
16358
17837
  children: [
16359
17838
  /* @__PURE__ */ jsxRuntime.jsx("thead", { children: /* @__PURE__ */ jsxRuntime.jsxs("tr", { children: [
16360
- /* @__PURE__ */ jsxRuntime.jsx("th", { className: "Layer__table-header Layer__bank-transactions__checkbox-col", style: { padding: 0 }, children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "Layer__table-cell-content", children: /* @__PURE__ */ jsxRuntime.jsx(
17839
+ categorizationEnabled && /* @__PURE__ */ jsxRuntime.jsx("th", { className: "Layer__table-header Layer__bank-transactions__checkbox-col", style: { padding: 0 }, children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "Layer__table-cell-content", children: /* @__PURE__ */ jsxRuntime.jsx(
16361
17840
  Checkbox,
16362
17841
  {
16363
17842
  isSelected: isAllSelected,
@@ -16802,7 +18281,7 @@ function buildKey$G({
16802
18281
  };
16803
18282
  }
16804
18283
  }
16805
- const getCustomAccounts = get(({ businessId, userCreated }) => {
18284
+ const getCustomAccounts = get$1(({ businessId, userCreated }) => {
16806
18285
  const baseUrl = `/v1/businesses/${businessId}/custom-accounts`;
16807
18286
  if (userCreated !== void 0) {
16808
18287
  return `${baseUrl}?user_created=${userCreated}`;
@@ -19295,7 +20774,7 @@ function buildKey$z({
19295
20774
  };
19296
20775
  }
19297
20776
  }
19298
- const getTagDimensions = get(({ businessId }) => `/v1/businesses/${businessId}/tags/dimensions`);
20777
+ const getTagDimensions = get$1(({ businessId }) => `/v1/businesses/${businessId}/tags/dimensions`);
19299
20778
  const TagDimensionsListSchema = effect.Schema.Array(TagDimensionSchema);
19300
20779
  class TagDimensionsSWRResponse {
19301
20780
  constructor(swrResponse) {
@@ -19404,7 +20883,7 @@ class ListCategorizationRulesSWRResponse {
19404
20883
  return this.swrResponse.mutate;
19405
20884
  }
19406
20885
  }
19407
- const listCategorizationRules = get(({ businessId, externalIds, includeArchived, sortBy, sortOrder, cursor, limit, showTotalCount }) => {
20886
+ const listCategorizationRules = get$1(({ businessId, externalIds, includeArchived, sortBy, sortOrder, cursor, limit, showTotalCount }) => {
19408
20887
  const parameters = toDefinedSearchParameters({
19409
20888
  externalIds,
19410
20889
  includeArchived,
@@ -20620,10 +22099,10 @@ const BankTransactionsTableView = ({
20620
22099
  return data == null ? void 0 : data.slice(firstPageIndex, lastPageIndex);
20621
22100
  }, [currentPage, data, isMonthlyViewMode, pageSize]);
20622
22101
  const [shiftStickyHeader, setShiftStickyHeader] = react.useState(0);
20623
- const debounceShiftStickyHeader = _.debounce(setShiftStickyHeader, 500);
22102
+ const debounceShiftStickyHeader = debounce(setShiftStickyHeader, 500);
20624
22103
  const [listView, setListView] = react.useState(false);
20625
22104
  const [containerWidth, setContainerWidth] = react.useState(0);
20626
- const debounceContainerWidth = _.debounce(setContainerWidth, 500);
22105
+ const debounceContainerWidth = debounce(setContainerWidth, 500);
20627
22106
  const removeTransaction = (bankTransaction) => removeAfterCategorize(bankTransaction);
20628
22107
  const containerRef = useElementSize((_el, _en, size) => {
20629
22108
  if ((size == null ? void 0 : size.height) && (size == null ? void 0 : size.height) >= 90) {
@@ -20699,7 +22178,7 @@ const BankTransactionsTableView = ({
20699
22178
  !isLoadingWithoutData && listView && mobileComponent !== "mobileList" ? /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "Layer__bank-transactions__list-wrapper", children: [
20700
22179
  rulesSuggestionModal,
20701
22180
  /* @__PURE__ */ jsxRuntime.jsx(
20702
- BankTransactionList,
22181
+ BankTransactionsList,
20703
22182
  {
20704
22183
  bankTransactions,
20705
22184
  editable,
@@ -20714,7 +22193,7 @@ const BankTransactionsTableView = ({
20714
22193
  ] }) : null,
20715
22194
  !isLoadingWithoutData && listView && mobileComponent === "mobileList" ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
20716
22195
  /* @__PURE__ */ jsxRuntime.jsx(
20717
- BankTransactionMobileList,
22196
+ BankTransactionsMobileList,
20718
22197
  {
20719
22198
  bankTransactions,
20720
22199
  editable,
@@ -21375,7 +22854,7 @@ const useProfitAndLoss = ({ tagFilter, reportingBasis }) => {
21375
22854
  };
21376
22855
  };
21377
22856
  function range(start, end) {
21378
- return Array.from({ length: end - start }, (_2, index2) => start + index2);
22857
+ return Array.from({ length: end - start }, (_, index2) => start + index2);
21379
22858
  }
21380
22859
  function isArrayWithAtLeastOne(list) {
21381
22860
  return list.length > 0;
@@ -24341,7 +25820,7 @@ const getProfitAndLossDetailLinesExcel = (apiUrl, accessToken, params) => {
24341
25820
  tagValues,
24342
25821
  pnlStructure
24343
25822
  });
24344
- return get(
25823
+ return get$1(
24345
25824
  ({ businessId: businessId2 }) => `/v1/businesses/${businessId2}/reports/profit-and-loss/lines/exports/excel?${queryParams.toString()}`
24346
25825
  )(apiUrl, accessToken, { params: { businessId } });
24347
25826
  };
@@ -24683,13 +26162,13 @@ const generateComparisonPeriods = (startDate, numberOfPeriods, rangeDisplayMode)
24683
26162
  }
24684
26163
  };
24685
26164
  const generateComparisonMonths = (startDate, numberOfMonths) => {
24686
- return Array.from({ length: numberOfMonths }, (_2, index2) => {
26165
+ return Array.from({ length: numberOfMonths }, (_, index2) => {
24687
26166
  const currentMonth = dateFns.subMonths(startDate, numberOfMonths - index2 - 1);
24688
26167
  return { date: currentMonth, label: dateFns.format(currentMonth, "MMM") };
24689
26168
  });
24690
26169
  };
24691
26170
  const generateComparisonYears = (startDate, numberOfYears) => {
24692
- return Array.from({ length: numberOfYears }, (_2, index2) => {
26171
+ return Array.from({ length: numberOfYears }, (_, index2) => {
24693
26172
  const currentMonth = dateFns.subYears(startDate, numberOfYears - index2 - 1);
24694
26173
  return { date: currentMonth, label: dateFns.format(currentMonth, "yyyy") };
24695
26174
  });
@@ -24841,7 +26320,7 @@ const ProfitAndLossCompareTable = ({
24841
26320
  /* @__PURE__ */ jsxRuntime.jsx(TableCell, { isHeaderCell: true }),
24842
26321
  selectedCompareOptions.map((option, i) => /* @__PURE__ */ jsxRuntime.jsxs(react.Fragment, { children: [
24843
26322
  /* @__PURE__ */ jsxRuntime.jsx(TableCell, { primary: true, isHeaderCell: true, children: option.displayName }, option.displayName + "-" + i),
24844
- comparePeriods && Array.from({ length: comparePeriods - 1 }, (_2, index2) => /* @__PURE__ */ jsxRuntime.jsx(TableCell, { isHeaderCell: true }, option.displayName + "-" + index2))
26323
+ comparePeriods && Array.from({ length: comparePeriods - 1 }, (_, index2) => /* @__PURE__ */ jsxRuntime.jsx(TableCell, { isHeaderCell: true }, option.displayName + "-" + index2))
24845
26324
  ] }, option.displayName + "-" + i))
24846
26325
  ] }) }),
24847
26326
  /* @__PURE__ */ jsxRuntime.jsxs(TableBody, { children: [
@@ -24895,7 +26374,7 @@ function useEffectOnMount(fn) {
24895
26374
  if (isMounted && typeof maybeCleanup === "function") {
24896
26375
  cleanup = maybeCleanup;
24897
26376
  }
24898
- } catch (_2) {
26377
+ } catch (_) {
24899
26378
  }
24900
26379
  }))();
24901
26380
  return () => {
@@ -26709,7 +28188,7 @@ class LedgerBalancesSWRResponse {
26709
28188
  return this.swrResponse.mutate;
26710
28189
  }
26711
28190
  }
26712
- const getLedgerAccountBalances = get(
28191
+ const getLedgerAccountBalances = get$1(
26713
28192
  ({ businessId, startDate, endDate }) => {
26714
28193
  const parameters = toDefinedSearchParameters({ startDate, endDate });
26715
28194
  return `/v1/businesses/${businessId}/ledger/balances?${parameters}`;
@@ -26772,7 +28251,7 @@ function useLedgerBalancesCacheActions() {
26772
28251
  };
26773
28252
  }
26774
28253
  const LIST_LEDGER_ENTRIES_TAG_KEY = "#list-ledger-entries";
26775
- const listLedgerEntries = get(({ businessId, sort_by, sort_order, cursor, limit, show_total_count }) => {
28254
+ const listLedgerEntries = get$1(({ businessId, sort_by, sort_order, cursor, limit, show_total_count }) => {
26776
28255
  const parameters = toDefinedSearchParameters({
26777
28256
  sort_by,
26778
28257
  sort_order,
@@ -26872,7 +28351,7 @@ function useLedgerEntriesCacheActions() {
26872
28351
  [forceReload]
26873
28352
  );
26874
28353
  const debouncedInvalidateLedgerEntries = react.useMemo(
26875
- () => _.debounce(
28354
+ () => debounce(
26876
28355
  invalidateLedgerEntries,
26877
28356
  INVALIDATION_DEBOUNCE_OPTIONS.wait,
26878
28357
  {
@@ -27198,7 +28677,7 @@ const useChartOfAccounts = ({ withDates, startDate: initialStartDate, endDate: i
27198
28677
  };
27199
28678
  };
27200
28679
  const LIST_LEDGER_ACCOUNT_LINES_TAG_KEY = "#list-ledger-account-lines";
27201
- const listLedgerAccountLines = get(({
28680
+ const listLedgerAccountLines = get$1(({
27202
28681
  businessId,
27203
28682
  accountId,
27204
28683
  include_entries_before_activation,
@@ -27848,18 +29327,18 @@ const ChartOfAccountsTableContent = ({
27848
29327
  const { accountingConfiguration } = useLayerContext();
27849
29328
  const enableAccountNumbers = !!(accountingConfiguration == null ? void 0 : accountingConfiguration.enableAccountNumbers);
27850
29329
  const allRowKeys = react.useMemo(() => {
27851
- const keys = [];
29330
+ const keys2 = [];
27852
29331
  const collect = (accounts) => {
27853
29332
  for (const account of accounts) {
27854
29333
  const key = `coa-row-${account.accountId}`;
27855
29334
  if (account.subAccounts.length > 0) {
27856
- keys.push(key);
29335
+ keys2.push(key);
27857
29336
  collect(account.subAccounts);
27858
29337
  }
27859
29338
  }
27860
29339
  };
27861
29340
  collect(data.accounts);
27862
- return keys;
29341
+ return keys2;
27863
29342
  }, [data.accounts]);
27864
29343
  react.useEffect(() => {
27865
29344
  if (expandAll === void 0) return;
@@ -31334,7 +32813,7 @@ function TasksMonthSelector() {
31334
32813
  const activeMonthNumber = dateFns.getMonth(date2) + 1;
31335
32814
  const activeYear = dateFns.getYear(date2);
31336
32815
  const monthsData = react.useMemo(() => {
31337
- return Array.from({ length: 12 }, (_2, index2) => {
32816
+ return Array.from({ length: 12 }, (_, index2) => {
31338
32817
  var _a, _b;
31339
32818
  const date22 = dateFns.set(
31340
32819
  /* @__PURE__ */ new Date(),
@@ -31383,7 +32862,7 @@ const useBookkeepingYearsStatus = () => {
31383
32862
  const startYear = dateFns.getYear(activationDate != null ? activationDate : /* @__PURE__ */ new Date());
31384
32863
  const currentYear = (/* @__PURE__ */ new Date()).getFullYear();
31385
32864
  const count = currentYear - startYear + 1;
31386
- return Array.from({ length: count }, (_2, index2) => ({ year: startYear + index2 })).map(({ year }) => {
32865
+ return Array.from({ length: count }, (_, index2) => ({ year: startYear + index2 })).map(({ year }) => {
31387
32866
  const tasks = data == null ? void 0 : data.filter((period) => period.year === year).reduce((acc, period) => acc.concat(period.tasks), []);
31388
32867
  const unresolvedTaskCount = tasks == null ? void 0 : tasks.filter((task) => isIncompleteTask(task)).length;
31389
32868
  return {
@@ -31854,7 +33333,7 @@ const CreateCallBookingBodySchemaDefinition = effect.Schema.Struct({
31854
33333
  )
31855
33334
  });
31856
33335
  effect.Schema.encodeSync(CreateCallBookingBodySchemaDefinition);
31857
- const listCallBookings = get(({ businessId, cursor, limit }) => {
33336
+ const listCallBookings = get$1(({ businessId, cursor, limit }) => {
31858
33337
  const parameters = toDefinedSearchParameters({
31859
33338
  cursor,
31860
33339
  limit,
@@ -31990,7 +33469,7 @@ const isCalendlyLink = (link) => {
31990
33469
  if (!link) return false;
31991
33470
  const hostname = new URL(link.url).hostname;
31992
33471
  return ALLOWED_CALENDLY_HOSTS.includes(hostname) || hostname.endsWith(".calendly.com");
31993
- } catch (_2) {
33472
+ } catch (_) {
31994
33473
  return false;
31995
33474
  }
31996
33475
  };
@@ -32384,10 +33863,10 @@ const LandingPageOffer = ({
32384
33863
  ] }) });
32385
33864
  };
32386
33865
  function mergeHeroContentConfig(defaults, overrides) {
32387
- return _.merge(defaults, overrides);
33866
+ return merge(defaults, overrides);
32388
33867
  }
32389
33868
  function mergeLandingPageConfig(defaults, overrides) {
32390
- return _.merge(defaults, overrides);
33869
+ return merge(defaults, overrides);
32391
33870
  }
32392
33871
  const LandingPage = ({
32393
33872
  platform,
@@ -33031,7 +34510,7 @@ function buildKey$g({
33031
34510
  };
33032
34511
  }
33033
34512
  }
33034
- const getBusinessPersonnel = get(({ businessId }) => `/v1/businesses/${businessId}/personnel`);
34513
+ const getBusinessPersonnel = get$1(({ businessId }) => `/v1/businesses/${businessId}/personnel`);
33035
34514
  function useBusinessPersonnel() {
33036
34515
  const { data } = useAuth();
33037
34516
  const { businessId } = useLayerContext();
@@ -33817,7 +35296,7 @@ function buildKey$c({
33817
35296
  };
33818
35297
  }
33819
35298
  }
33820
- const getBookkeepingConfiguration = get(({ businessId }) => {
35299
+ const getBookkeepingConfiguration = get$1(({ businessId }) => {
33821
35300
  return `/v1/businesses/${businessId}/bookkeeping/config`;
33822
35301
  });
33823
35302
  function useBookkeepingConfiguration() {
@@ -34235,7 +35714,7 @@ const AddToCalendar = ({
34235
35714
  const event = {
34236
35715
  summary: calendarEvent.title,
34237
35716
  description: calendarEvent.description,
34238
- uid: _.uniqueId("ics-"),
35717
+ uid: uniqueId("ics-"),
34239
35718
  stamp: { date: /* @__PURE__ */ new Date() },
34240
35719
  start: { date: startDate },
34241
35720
  end: { date: effectiveEndDate },
@@ -35165,7 +36644,7 @@ const useBillsRecordPayment = ({ refetchAllBills }) => {
35165
36644
  }));
35166
36645
  };
35167
36646
  const removeBillByIndex = (index2) => {
35168
- setBillsToPay((prev) => prev.filter((_2, i) => i !== index2));
36647
+ setBillsToPay((prev) => prev.filter((_, i) => i !== index2));
35169
36648
  };
35170
36649
  const setAmount = (billId, amount) => {
35171
36650
  setBillsToPay((prev) => prev.map((bill) => {
@@ -36283,7 +37762,7 @@ const BillsDetails = ({
36283
37762
  /* @__PURE__ */ jsxRuntime.jsx(form.Field, { name: "line_items", mode: "array", children: (field) => {
36284
37763
  var _a;
36285
37764
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
36286
- (_a = field.state.value) == null ? void 0 : _a.map((_2, i) => {
37765
+ (_a = field.state.value) == null ? void 0 : _a.map((_, i) => {
36287
37766
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "Layer__bill-details__category-row", children: [
36288
37767
  /* @__PURE__ */ jsxRuntime.jsx(form.Field, { name: `line_items[${i}].account_identifier`, children: () => {
36289
37768
  return null;
@@ -37108,7 +38587,7 @@ function buildKey$9(_Qc) {
37108
38587
  }, dateParams);
37109
38588
  }
37110
38589
  }
37111
- const getUnifiedReport = get((_Sc) => {
38590
+ const getUnifiedReport = get$1((_Sc) => {
37112
38591
  var _Tc = _Sc, { businessId, report } = _Tc, dateParams = __objRest(_Tc, ["businessId", "report"]);
37113
38592
  const parameters = toDefinedSearchParameters(__spreadValues({}, dateParams));
37114
38593
  return `/v1/businesses/${businessId}/reports/unified/${report}?${parameters}`;
@@ -38437,7 +39916,7 @@ class ListInvoicesSWRResponse {
38437
39916
  return this.swrResponse.mutate;
38438
39917
  }
38439
39918
  }
38440
- const listInvoices = get(({ businessId, status, query, dueAtStart, dueAtEnd, sortBy, sortOrder, cursor, limit, showTotalCount }) => {
39919
+ const listInvoices = get$1(({ businessId, status, query, dueAtStart, dueAtEnd, sortBy, sortOrder, cursor, limit, showTotalCount }) => {
38441
39920
  const parameters = toDefinedSearchParameters({
38442
39921
  status,
38443
39922
  q: query,
@@ -39038,7 +40517,7 @@ function buildKey$7({
39038
40517
  };
39039
40518
  }
39040
40519
  }
39041
- const getInvoiceSummaryStats = get(({ businessId }) => `/v1/businesses/${businessId}/invoices/summary-stats`);
40520
+ const getInvoiceSummaryStats = get$1(({ businessId }) => `/v1/businesses/${businessId}/invoices/summary-stats`);
39042
40521
  function useInvoiceSummaryStats() {
39043
40522
  const { data } = useAuth();
39044
40523
  const { businessId } = useLayerContext();
@@ -41529,15 +43008,15 @@ const useDataSync = () => {
41529
43008
  );
41530
43009
  };
41531
43010
  const resetCaches = () => {
41532
- const now = Date.now();
43011
+ const now2 = Date.now();
41533
43012
  void invalidateProfitAndLoss();
41534
43013
  setSyncTimestamps({
41535
- [DataModel.BALANCE_SHEET]: now,
41536
- [DataModel.LEDGER_ACCOUNTS]: now,
41537
- [DataModel.LINKED_ACCOUNTS]: now,
41538
- [DataModel.PROFIT_AND_LOSS]: now,
41539
- [DataModel.STATEMENT_OF_CASH_FLOWS]: now,
41540
- [DataModel.BANK_TRANSACTIONS]: now
43014
+ [DataModel.BALANCE_SHEET]: now2,
43015
+ [DataModel.LEDGER_ACCOUNTS]: now2,
43016
+ [DataModel.LINKED_ACCOUNTS]: now2,
43017
+ [DataModel.PROFIT_AND_LOSS]: now2,
43018
+ [DataModel.STATEMENT_OF_CASH_FLOWS]: now2,
43019
+ [DataModel.BANK_TRANSACTIONS]: now2
41541
43020
  });
41542
43021
  };
41543
43022
  return {
@@ -41581,8 +43060,8 @@ function stableHash(arg) {
41581
43060
  table.set(arg, result);
41582
43061
  } else if (constructor === Object) {
41583
43062
  result = "#";
41584
- const keys = Object.keys(arg).sort();
41585
- while ((index2 = keys.pop()) !== void 0) {
43063
+ const keys2 = Object.keys(arg).sort();
43064
+ while ((index2 = keys2.pop()) !== void 0) {
41586
43065
  if (arg[index2] !== void 0) {
41587
43066
  result += index2 + ":" + stableHash(arg[index2]) + ",";
41588
43067
  }
@@ -41665,7 +43144,7 @@ function buildKey({
41665
43144
  };
41666
43145
  }
41667
43146
  }
41668
- const getAccountingConfiguration = get(
43147
+ const getAccountingConfiguration = get$1(
41669
43148
  ({ businessId }) => {
41670
43149
  return `/v1/businesses/${businessId}/accounting-config`;
41671
43150
  }