@layerfi/components 0.1.125 → 0.1.126-alpha.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.css CHANGED
@@ -1630,17 +1630,6 @@
1630
1630
  }
1631
1631
  .Layer__ComboBoxPlaceholder--error {
1632
1632
  color: var(--color-danger);
1633
- }.Layer__MoneySpan {
1634
- white-space: nowrap;
1635
- }
1636
- .Layer__MoneySpan[data-positive]::before {
1637
- content: "$";
1638
- }
1639
- .Layer__MoneySpan[data-negative]::before {
1640
- content: "-$";
1641
- }
1642
- .Layer__MoneySpan[data-display-plus-sign]::before {
1643
- content: "+$";
1644
1633
  }.Layer__datetime {
1645
1634
  display: inline-flex;
1646
1635
  gap: var(--spacing-md);
@@ -5800,12 +5789,6 @@
5800
5789
  padding: var(--spacing-2xs);
5801
5790
  color: var(--label-color);
5802
5791
  }
5803
- .Layer__amount-input--align-left {
5804
- text-align: left;
5805
- }
5806
- .Layer__amount-input--align-right {
5807
- text-align: right;
5808
- }
5809
5792
  .Layer__textarea {
5810
5793
  box-sizing: border-box;
5811
5794
  min-height: 100px;
@@ -6061,61 +6044,6 @@
6061
6044
  border: 1px solid var(--input-border-color);
6062
6045
  font-size: 14px;
6063
6046
  }
6064
- .Layer__profit-and-loss-date-picker__button {
6065
- position: relative;
6066
- z-index: 3;
6067
- display: flex;
6068
- align-items: center;
6069
- justify-content: center;
6070
- padding: 0.25rem;
6071
- border-radius: var(--input-border-radius);
6072
- border: 0;
6073
- background-color: var(--color-base-0);
6074
- text-align: center;
6075
- }
6076
- .Layer__profit-and-loss-date-picker__button:active {
6077
- background-color: var(--color-base-0);
6078
- }
6079
- .Layer__profit-and-loss-date-picker__button-icon path {
6080
- stroke: var(--color-base-900);
6081
- }
6082
- .Layer__profit-and-loss-date-picker__label {
6083
- position: relative;
6084
- display: flex;
6085
- flex: 1;
6086
- align-items: center;
6087
- justify-content: flex-start;
6088
- width: 33%;
6089
- padding: 0 var(--spacing-xs);
6090
- padding-left: 20px;
6091
- font-size: 14px;
6092
- text-align: center;
6093
- transition: opacity 0.7s ease-in-out, transform 0.4s ease-in-out;
6094
- }
6095
- .Layer__profit-and-loss-date-picker__labels-container {
6096
- position: absolute;
6097
- display: flex;
6098
- width: 660px;
6099
- }
6100
- .Layer__profit-and-loss-date-picker__effect-blur {
6101
- position: absolute;
6102
- z-index: 2;
6103
- right: -10px;
6104
- bottom: 1px;
6105
- height: 100%;
6106
- width: 120px;
6107
- background: linear-gradient(-90deg, #fff 50%, rgba(255, 255, 255, 0) 100%);
6108
- }
6109
- .Layer__input-with-badge {
6110
- position: relative;
6111
- display: flex;
6112
- align-items: center;
6113
- }
6114
- .Layer__input-with-badge .Layer__badge {
6115
- position: absolute;
6116
- z-index: 1;
6117
- right: 8px;
6118
- }
6119
6047
  .Layer__input--static-value {
6120
6048
  padding: 0 calc(var(--spacing-xs) + 1px);
6121
6049
  }
@@ -6325,14 +6253,6 @@
6325
6253
  justify-content: flex-end;
6326
6254
  text-align: right;
6327
6255
  }
6328
- .Layer__table .Layer__table-cell.Layer__table-cell-amount--positive .Layer__table-cell-content::before {
6329
- content: "$";
6330
- flex-shrink: 0;
6331
- }
6332
- .Layer__table .Layer__table-cell.Layer__table-cell-amount--negative .Layer__table-cell-content::before {
6333
- content: "-$";
6334
- flex-shrink: 0;
6335
- }
6336
6256
  .Layer__table .Layer__table-cell .Layer__table-cell-content {
6337
6257
  box-sizing: border-box;
6338
6258
  position: relative;
@@ -7807,10 +7727,6 @@ tbody .Layer__table__empty-row:first-child {
7807
7727
  .Layer__table.Layer__bank-transactions__table {
7808
7728
  overflow: auto;
7809
7729
  }
7810
- .Layer__table.Layer__bank-transactions__table .Layer__bank-transaction__submit-btn,
7811
- .Layer__table.Layer__bank-transactions__table .Layer__bank-transaction__retry-btn {
7812
- width: 122px;
7813
- }
7814
7730
  .Layer__table .Layer__table-header.Layer__bank-transactions__documents-col {
7815
7731
  --right-adjust: calc(65ch + 2px);
7816
7732
  }
package/dist/index.d.ts CHANGED
@@ -7,6 +7,9 @@ declare const AccountingConfigurationSchema: Schema.Struct<{
7
7
  id: typeof Schema.UUID;
8
8
  enableAccountNumbers: Schema.PropertySignature<":", boolean, "enable_account_numbers", ":", boolean, false, never>;
9
9
  enableCustomerManagement: Schema.PropertySignature<":", boolean, "enable_customer_management", ":", boolean, false, never>;
10
+ taxEstimatesUserAgreementAt: Schema.PropertySignature<":", Date | null | undefined, "tax_estimates_user_agreement_at", ":", string | null | undefined, false, never>;
11
+ enableTaxEstimates: Schema.PropertySignature<":", boolean, "enable_tax_estimates", ":", boolean, false, never>;
12
+ enableMileageTracking: Schema.PropertySignature<":", boolean, "enable_mileage_tracking", ":", boolean, false, never>;
10
13
  enableStripeOnboarding: Schema.PropertySignature<":", boolean, "enable_stripe_onboarding", ":", boolean, false, never>;
11
14
  platformDisplayTags: Schema.PropertySignature<":", readonly {
12
15
  readonly id: string;
@@ -14,9 +17,9 @@ declare const AccountingConfigurationSchema: Schema.Struct<{
14
17
  readonly displayName: string | null | undefined;
15
18
  readonly strictness: "BALANCING" | "NON_BALANCING";
16
19
  readonly definedValues: readonly {
17
- readonly value: string;
18
20
  readonly id: string;
19
21
  readonly key: string;
22
+ readonly value: string;
20
23
  readonly displayName: string | null | undefined;
21
24
  readonly archivedAt: Date | null | undefined;
22
25
  }[];
@@ -29,9 +32,9 @@ declare const AccountingConfigurationSchema: Schema.Struct<{
29
32
  readonly display_name: string | null | undefined;
30
33
  readonly strictness: string;
31
34
  readonly defined_values: readonly {
32
- readonly value: string;
33
35
  readonly id: string;
34
36
  readonly key: string;
37
+ readonly value: string;
35
38
  readonly display_name: string | null | undefined;
36
39
  readonly archived_at: string | null | undefined;
37
40
  }[];
@@ -218,6 +221,7 @@ declare type BaseLayerProviderProps = {
218
221
  appId?: string;
219
222
  appSecret?: string;
220
223
  businessAccessToken?: string;
224
+ locale?: SupportedLocale;
221
225
  theme?: LayerThemeConfig;
222
226
  usePlaidSandbox?: boolean;
223
227
  onError?: (error: LayerError) => void;
@@ -263,23 +267,12 @@ declare interface BreadcrumbItem {
263
267
  display_name: string;
264
268
  }
265
269
 
266
- declare interface Business {
267
- id: string;
268
- activation_at?: string;
269
- archived_at?: string;
270
- entity_type?: EntityType;
271
- external_id?: string;
272
- imported_at?: string;
273
- industry?: string;
274
- legal_name?: string;
275
- phone_number?: string;
276
- sms_categorization_start_date?: string;
277
- sms_enabled?: boolean;
278
- tin?: string;
279
- type?: string;
280
- updated_at?: string;
281
- us_state?: USStateCode;
282
- }
270
+ declare type Business = typeof BusinessSchema.Type;
271
+
272
+ declare const BusinessSchema: Schema.Struct<{
273
+ id: typeof Schema.UUID;
274
+ activationAt: Schema.PropertySignature<":", Date, "activation_at", ":", string, false, never>;
275
+ }>;
283
276
 
284
277
  export declare const ChartOfAccounts: (props: ChartOfAccountsProps) => JSX_2.Element;
285
278
 
@@ -299,7 +292,6 @@ declare interface ChartOfAccountsFormStringOverrides {
299
292
 
300
293
  declare interface ChartOfAccountsOptions {
301
294
  templateAccountsEditable?: boolean;
302
- showReversalEntries?: boolean;
303
295
  showAddAccountButton?: boolean;
304
296
  }
305
297
 
@@ -310,7 +302,6 @@ declare interface ChartOfAccountsProps {
310
302
  stringOverrides?: ChartOfAccountsStringOverrides;
311
303
  showAddAccountButton?: boolean;
312
304
  templateAccountsEditable?: boolean;
313
- showReversalEntries?: boolean;
314
305
  renderInAppLink?: (source: LinkingMetadata) => ReactNode;
315
306
  }
316
307
 
@@ -432,33 +423,6 @@ export declare enum DisplayState {
432
423
  categorized = "categorized"
433
424
  }
434
425
 
435
- declare const ENTITY_TYPES_CONFIG: readonly [{
436
- readonly i18nKey: string;
437
- readonly defaultValue: string;
438
- readonly ns?: string;
439
- readonly value: "SOLE_PROP";
440
- }, {
441
- readonly i18nKey: string;
442
- readonly defaultValue: string;
443
- readonly ns?: string;
444
- readonly value: "C_CORP";
445
- }, {
446
- readonly i18nKey: string;
447
- readonly defaultValue: string;
448
- readonly ns?: string;
449
- readonly value: "LLC";
450
- }, {
451
- readonly i18nKey: string;
452
- readonly defaultValue: string;
453
- readonly ns?: string;
454
- readonly value: "S_CORP";
455
- }, {
456
- readonly i18nKey: string;
457
- readonly defaultValue: string;
458
- readonly ns?: string;
459
- readonly value: "PARTNERSHIP";
460
- }];
461
-
462
426
  export declare enum EntityName {
463
427
  Unknown = "Unknown",
464
428
  BankTransaction = "Bank Transaction",
@@ -484,8 +448,6 @@ export declare enum EntityName {
484
448
  CustomerCredit = "Customer Credit"
485
449
  }
486
450
 
487
- declare type EntityType = (typeof ENTITY_TYPES_CONFIG)[number]['value'];
488
-
489
451
  declare type EnumWithUnknownValues<T extends string> = T | UnknownEnumValue;
490
452
 
491
453
  declare type Environment = 'production' | 'sandbox' | 'staging' | 'internalStaging';
@@ -734,7 +696,7 @@ declare type LayerErrorScope = 'BankTransaction' | 'ChartOfAccounts';
734
696
 
735
697
  declare type LayerErrorType = 'unauthenticated' | 'api' | 'render';
736
698
 
737
- export declare const LayerProvider: (props: PropsWithChildren<LayerProviderProps>) => JSX_2.Element;
699
+ export declare const LayerProvider: ({ appId, appSecret, businessAccessToken, locale, usePlaidSandbox, ...restProps }: PropsWithChildren<LayerProviderProps>) => JSX_2.Element;
738
700
 
739
701
  declare type LayerProviderProps = LayerProviderPropsWithLayerEnv | LayerProviderPropsWithEnvironmentConfigOverride;
740
702
 
@@ -1068,6 +1030,11 @@ declare interface StatementOfCashFlowTableStringOverrides {
1068
1030
 
1069
1031
  declare type StrictReportingBasis = 'CASH' | 'CASH_COLLECTED' | 'ACCRUAL';
1070
1032
 
1033
+ export declare enum SupportedLocale {
1034
+ enUS = "en-US",
1035
+ frCA = "fr-CA"
1036
+ }
1037
+
1071
1038
  declare interface TagComparisonOption {
1072
1039
  displayName: string;
1073
1040
  tagFilterConfig: TagViewConfig;
@@ -1150,272 +1117,8 @@ export declare const unstable_MileageTracking: ({ showTitle }: {
1150
1117
 
1151
1118
  export declare const unstable_UnifiedReports: ({ dateSelectionMode }: UnifiedReportProps) => JSX_2.Element;
1152
1119
 
1153
- declare const US_STATES_CONFIG: readonly [{
1154
- readonly i18nKey: string;
1155
- readonly defaultValue: string;
1156
- readonly ns?: string;
1157
- readonly value: "AL";
1158
- }, {
1159
- readonly i18nKey: string;
1160
- readonly defaultValue: string;
1161
- readonly ns?: string;
1162
- readonly value: "AK";
1163
- }, {
1164
- readonly i18nKey: string;
1165
- readonly defaultValue: string;
1166
- readonly ns?: string;
1167
- readonly value: "AZ";
1168
- }, {
1169
- readonly i18nKey: string;
1170
- readonly defaultValue: string;
1171
- readonly ns?: string;
1172
- readonly value: "AR";
1173
- }, {
1174
- readonly i18nKey: string;
1175
- readonly defaultValue: string;
1176
- readonly ns?: string;
1177
- readonly value: "CA";
1178
- }, {
1179
- readonly i18nKey: string;
1180
- readonly defaultValue: string;
1181
- readonly ns?: string;
1182
- readonly value: "CO";
1183
- }, {
1184
- readonly i18nKey: string;
1185
- readonly defaultValue: string;
1186
- readonly ns?: string;
1187
- readonly value: "CT";
1188
- }, {
1189
- readonly i18nKey: string;
1190
- readonly defaultValue: string;
1191
- readonly ns?: string;
1192
- readonly value: "DE";
1193
- }, {
1194
- readonly i18nKey: string;
1195
- readonly defaultValue: string;
1196
- readonly ns?: string;
1197
- readonly value: "DC";
1198
- }, {
1199
- readonly i18nKey: string;
1200
- readonly defaultValue: string;
1201
- readonly ns?: string;
1202
- readonly value: "FL";
1203
- }, {
1204
- readonly i18nKey: string;
1205
- readonly defaultValue: string;
1206
- readonly ns?: string;
1207
- readonly value: "GA";
1208
- }, {
1209
- readonly i18nKey: string;
1210
- readonly defaultValue: string;
1211
- readonly ns?: string;
1212
- readonly value: "HI";
1213
- }, {
1214
- readonly i18nKey: string;
1215
- readonly defaultValue: string;
1216
- readonly ns?: string;
1217
- readonly value: "ID";
1218
- }, {
1219
- readonly i18nKey: string;
1220
- readonly defaultValue: string;
1221
- readonly ns?: string;
1222
- readonly value: "IL";
1223
- }, {
1224
- readonly i18nKey: string;
1225
- readonly defaultValue: string;
1226
- readonly ns?: string;
1227
- readonly value: "IN";
1228
- }, {
1229
- readonly i18nKey: string;
1230
- readonly defaultValue: string;
1231
- readonly ns?: string;
1232
- readonly value: "IA";
1233
- }, {
1234
- readonly i18nKey: string;
1235
- readonly defaultValue: string;
1236
- readonly ns?: string;
1237
- readonly value: "KS";
1238
- }, {
1239
- readonly i18nKey: string;
1240
- readonly defaultValue: string;
1241
- readonly ns?: string;
1242
- readonly value: "KY";
1243
- }, {
1244
- readonly i18nKey: string;
1245
- readonly defaultValue: string;
1246
- readonly ns?: string;
1247
- readonly value: "LA";
1248
- }, {
1249
- readonly i18nKey: string;
1250
- readonly defaultValue: string;
1251
- readonly ns?: string;
1252
- readonly value: "ME";
1253
- }, {
1254
- readonly i18nKey: string;
1255
- readonly defaultValue: string;
1256
- readonly ns?: string;
1257
- readonly value: "MD";
1258
- }, {
1259
- readonly i18nKey: string;
1260
- readonly defaultValue: string;
1261
- readonly ns?: string;
1262
- readonly value: "MA";
1263
- }, {
1264
- readonly i18nKey: string;
1265
- readonly defaultValue: string;
1266
- readonly ns?: string;
1267
- readonly value: "MI";
1268
- }, {
1269
- readonly i18nKey: string;
1270
- readonly defaultValue: string;
1271
- readonly ns?: string;
1272
- readonly value: "MN";
1273
- }, {
1274
- readonly i18nKey: string;
1275
- readonly defaultValue: string;
1276
- readonly ns?: string;
1277
- readonly value: "MS";
1278
- }, {
1279
- readonly i18nKey: string;
1280
- readonly defaultValue: string;
1281
- readonly ns?: string;
1282
- readonly value: "MO";
1283
- }, {
1284
- readonly i18nKey: string;
1285
- readonly defaultValue: string;
1286
- readonly ns?: string;
1287
- readonly value: "MT";
1288
- }, {
1289
- readonly i18nKey: string;
1290
- readonly defaultValue: string;
1291
- readonly ns?: string;
1292
- readonly value: "NE";
1293
- }, {
1294
- readonly i18nKey: string;
1295
- readonly defaultValue: string;
1296
- readonly ns?: string;
1297
- readonly value: "NV";
1298
- }, {
1299
- readonly i18nKey: string;
1300
- readonly defaultValue: string;
1301
- readonly ns?: string;
1302
- readonly value: "NH";
1303
- }, {
1304
- readonly i18nKey: string;
1305
- readonly defaultValue: string;
1306
- readonly ns?: string;
1307
- readonly value: "NJ";
1308
- }, {
1309
- readonly i18nKey: string;
1310
- readonly defaultValue: string;
1311
- readonly ns?: string;
1312
- readonly value: "NM";
1313
- }, {
1314
- readonly i18nKey: string;
1315
- readonly defaultValue: string;
1316
- readonly ns?: string;
1317
- readonly value: "NY";
1318
- }, {
1319
- readonly i18nKey: string;
1320
- readonly defaultValue: string;
1321
- readonly ns?: string;
1322
- readonly value: "NC";
1323
- }, {
1324
- readonly i18nKey: string;
1325
- readonly defaultValue: string;
1326
- readonly ns?: string;
1327
- readonly value: "ND";
1328
- }, {
1329
- readonly i18nKey: string;
1330
- readonly defaultValue: string;
1331
- readonly ns?: string;
1332
- readonly value: "OH";
1333
- }, {
1334
- readonly i18nKey: string;
1335
- readonly defaultValue: string;
1336
- readonly ns?: string;
1337
- readonly value: "OK";
1338
- }, {
1339
- readonly i18nKey: string;
1340
- readonly defaultValue: string;
1341
- readonly ns?: string;
1342
- readonly value: "OR";
1343
- }, {
1344
- readonly i18nKey: string;
1345
- readonly defaultValue: string;
1346
- readonly ns?: string;
1347
- readonly value: "PA";
1348
- }, {
1349
- readonly i18nKey: string;
1350
- readonly defaultValue: string;
1351
- readonly ns?: string;
1352
- readonly value: "RI";
1353
- }, {
1354
- readonly i18nKey: string;
1355
- readonly defaultValue: string;
1356
- readonly ns?: string;
1357
- readonly value: "SC";
1358
- }, {
1359
- readonly i18nKey: string;
1360
- readonly defaultValue: string;
1361
- readonly ns?: string;
1362
- readonly value: "SD";
1363
- }, {
1364
- readonly i18nKey: string;
1365
- readonly defaultValue: string;
1366
- readonly ns?: string;
1367
- readonly value: "TN";
1368
- }, {
1369
- readonly i18nKey: string;
1370
- readonly defaultValue: string;
1371
- readonly ns?: string;
1372
- readonly value: "TX";
1373
- }, {
1374
- readonly i18nKey: string;
1375
- readonly defaultValue: string;
1376
- readonly ns?: string;
1377
- readonly value: "UT";
1378
- }, {
1379
- readonly i18nKey: string;
1380
- readonly defaultValue: string;
1381
- readonly ns?: string;
1382
- readonly value: "VT";
1383
- }, {
1384
- readonly i18nKey: string;
1385
- readonly defaultValue: string;
1386
- readonly ns?: string;
1387
- readonly value: "VA";
1388
- }, {
1389
- readonly i18nKey: string;
1390
- readonly defaultValue: string;
1391
- readonly ns?: string;
1392
- readonly value: "WA";
1393
- }, {
1394
- readonly i18nKey: string;
1395
- readonly defaultValue: string;
1396
- readonly ns?: string;
1397
- readonly value: "WV";
1398
- }, {
1399
- readonly i18nKey: string;
1400
- readonly defaultValue: string;
1401
- readonly ns?: string;
1402
- readonly value: "WI";
1403
- }, {
1404
- readonly i18nKey: string;
1405
- readonly defaultValue: string;
1406
- readonly ns?: string;
1407
- readonly value: "WY";
1408
- }, {
1409
- readonly i18nKey: string;
1410
- readonly defaultValue: string;
1411
- readonly ns?: string;
1412
- readonly value: "PR";
1413
- }];
1414
-
1415
1120
  export declare const useLayerContext: () => LayerContextShape;
1416
1121
 
1417
- declare type USStateCode = (typeof US_STATES_CONFIG)[number]['value'];
1418
-
1419
1122
  declare type Variants = Partial<{
1420
1123
  size: SizeVariant;
1421
1124
  }>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@layerfi/components",
3
- "version": "0.1.125",
3
+ "version": "0.1.126-alpha.1",
4
4
  "description": "Layer React Components",
5
5
  "main": "dist/cjs/index.cjs",
6
6
  "module": "dist/esm/index.mjs",
@@ -113,6 +113,7 @@
113
113
  "react-currency-input-field": "^3.10.0",
114
114
  "react-dropzone": "^14.3.8",
115
115
  "react-i18next": "^16.5.6",
116
+ "react-intl": "^7.1.14",
116
117
  "react-merge-refs": "^3.0.2",
117
118
  "react-plaid-link": "^4.0.1",
118
119
  "react-select": "^5.10.1",
@@ -122,4 +123,4 @@
122
123
  "uuid": "^11.1.0",
123
124
  "zustand": "^5.0.4"
124
125
  }
125
- }
126
+ }