braid-ui 1.0.31 → 1.0.33
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.cjs +173 -17
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +46 -44
- package/dist/index.d.ts +46 -44
- package/dist/index.js +173 -17
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -3378,30 +3378,30 @@ zod.z.object({
|
|
|
3378
3378
|
|
|
3379
3379
|
// src/lib/mock-data/business-data.ts
|
|
3380
3380
|
var defaultBusinessProfile = {
|
|
3381
|
-
|
|
3382
|
-
|
|
3383
|
-
|
|
3384
|
-
|
|
3385
|
-
|
|
3386
|
-
|
|
3381
|
+
name: "Acme Corporation",
|
|
3382
|
+
productId: 1,
|
|
3383
|
+
businessIdType: "EIN",
|
|
3384
|
+
idNumber: "12-3456789",
|
|
3385
|
+
dba: "ACME Tech",
|
|
3386
|
+
businessEntityType: "CORPORATION",
|
|
3387
3387
|
incorporationState: "Delaware",
|
|
3388
|
+
formationDate: "2020-01-15",
|
|
3388
3389
|
website: "https://acme.com",
|
|
3389
|
-
email: "contact@acme.com",
|
|
3390
|
-
mobilePhone: "+1 (555) 234-5678",
|
|
3391
3390
|
mcc: "1234",
|
|
3392
3391
|
naics: "123456",
|
|
3392
|
+
mobilePhone: "+1 (555) 234-5678",
|
|
3393
3393
|
achCompanyId: "1234567890",
|
|
3394
|
-
|
|
3395
|
-
|
|
3396
|
-
|
|
3394
|
+
contactPersonFirstName: "John",
|
|
3395
|
+
contactPersonLastName: "Smith",
|
|
3396
|
+
contactPersonEmail: "contact@acme.com",
|
|
3397
|
+
contactPersonPhone: "+1 (555) 123-4567",
|
|
3397
3398
|
address: {
|
|
3398
|
-
|
|
3399
|
-
|
|
3399
|
+
line1: "123 Business Avenue",
|
|
3400
|
+
line2: "Suite 100",
|
|
3400
3401
|
city: "New York",
|
|
3401
3402
|
state: "NY",
|
|
3402
3403
|
postalCode: "10001",
|
|
3403
|
-
|
|
3404
|
-
addressType: "business"
|
|
3404
|
+
countryCode: "US"
|
|
3405
3405
|
}
|
|
3406
3406
|
};
|
|
3407
3407
|
var BusinessProfileCard = ({
|
|
@@ -3693,7 +3693,19 @@ var BusinessProfileCard = ({
|
|
|
3693
3693
|
InfoField,
|
|
3694
3694
|
{
|
|
3695
3695
|
label: "Address",
|
|
3696
|
-
value: formValues?.address ?
|
|
3696
|
+
value: formValues?.address ? (() => {
|
|
3697
|
+
const parts = [];
|
|
3698
|
+
if (formValues.address.line1) parts.push(formValues.address.line1);
|
|
3699
|
+
if (formValues.address.line2) parts.push(formValues.address.line2);
|
|
3700
|
+
const cityStateZip = [
|
|
3701
|
+
formValues.address.city,
|
|
3702
|
+
formValues.address.state,
|
|
3703
|
+
formValues.address.postalCode
|
|
3704
|
+
].filter(Boolean).join(" ");
|
|
3705
|
+
if (cityStateZip) parts.push(cityStateZip);
|
|
3706
|
+
if (formValues.address.countryCode) parts.push(formValues.address.countryCode);
|
|
3707
|
+
return parts.length > 0 ? parts.join(", ") : "-";
|
|
3708
|
+
})() : "-",
|
|
3697
3709
|
layout: "horizontal"
|
|
3698
3710
|
}
|
|
3699
3711
|
),
|
|
@@ -4636,6 +4648,7 @@ var accountColumns = [
|
|
|
4636
4648
|
];
|
|
4637
4649
|
var BusinessDetailView = ({
|
|
4638
4650
|
business,
|
|
4651
|
+
businessProfile,
|
|
4639
4652
|
identityVerification,
|
|
4640
4653
|
businessUBOs,
|
|
4641
4654
|
businessDocuments,
|
|
@@ -4643,6 +4656,7 @@ var BusinessDetailView = ({
|
|
|
4643
4656
|
currentStatus,
|
|
4644
4657
|
isEditingProfile,
|
|
4645
4658
|
onStatusChange,
|
|
4659
|
+
onProfileDataChange,
|
|
4646
4660
|
onToggleProfileEdit,
|
|
4647
4661
|
onNavigateToAccounts,
|
|
4648
4662
|
onNavigateToCounterparty,
|
|
@@ -4692,9 +4706,11 @@ var BusinessDetailView = ({
|
|
|
4692
4706
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
4693
4707
|
BusinessProfileCard,
|
|
4694
4708
|
{
|
|
4709
|
+
data: businessProfile,
|
|
4695
4710
|
identityVerification,
|
|
4696
4711
|
isEditing: isEditingProfile,
|
|
4697
|
-
onToggleEdit: onToggleProfileEdit
|
|
4712
|
+
onToggleEdit: onToggleProfileEdit,
|
|
4713
|
+
onDataChange: onProfileDataChange
|
|
4698
4714
|
}
|
|
4699
4715
|
),
|
|
4700
4716
|
/* @__PURE__ */ jsxRuntime.jsx(UBOCard, { ubos: businessUBOs }),
|
|
@@ -10243,6 +10259,136 @@ var mockBusinessDocuments = {
|
|
|
10243
10259
|
}
|
|
10244
10260
|
]
|
|
10245
10261
|
};
|
|
10262
|
+
|
|
10263
|
+
// src/lib/mock-data/business-profiles-data.ts
|
|
10264
|
+
var mockBusinessProfiles = {
|
|
10265
|
+
"8112488": {
|
|
10266
|
+
name: "RAPIDZ PAY INC",
|
|
10267
|
+
productId: 1,
|
|
10268
|
+
businessIdType: "EIN",
|
|
10269
|
+
idNumber: "12-3456789",
|
|
10270
|
+
dba: "Rapidz Pay",
|
|
10271
|
+
businessEntityType: "CORPORATION",
|
|
10272
|
+
incorporationState: "Delaware",
|
|
10273
|
+
formationDate: "2020-01-15",
|
|
10274
|
+
website: "https://rapidzpay.com",
|
|
10275
|
+
mcc: "6211",
|
|
10276
|
+
naics: "522320",
|
|
10277
|
+
mobilePhone: "+1 (555) 123-4567",
|
|
10278
|
+
achCompanyId: "1234567890",
|
|
10279
|
+
contactPersonFirstName: "John",
|
|
10280
|
+
contactPersonLastName: "Smith",
|
|
10281
|
+
contactPersonEmail: "john.smith@rapidzpay.com",
|
|
10282
|
+
contactPersonPhone: "+1 (555) 234-5678",
|
|
10283
|
+
address: {
|
|
10284
|
+
line1: "123 Business Ave",
|
|
10285
|
+
line2: "Suite 100",
|
|
10286
|
+
city: "New York",
|
|
10287
|
+
state: "NY",
|
|
10288
|
+
postalCode: "10001",
|
|
10289
|
+
countryCode: "US"
|
|
10290
|
+
}
|
|
10291
|
+
},
|
|
10292
|
+
"8111609": {
|
|
10293
|
+
name: "Fern Hyper Growth Llc",
|
|
10294
|
+
productId: 2,
|
|
10295
|
+
businessIdType: "EIN",
|
|
10296
|
+
idNumber: "98-7654321",
|
|
10297
|
+
businessEntityType: "LIMITED_LIABILITY_COMPANY",
|
|
10298
|
+
incorporationState: "California",
|
|
10299
|
+
formationDate: "2019-06-20",
|
|
10300
|
+
website: "https://fernhypergrowth.com",
|
|
10301
|
+
mcc: "5999",
|
|
10302
|
+
naics: "541519",
|
|
10303
|
+
mobilePhone: "+1 (555) 987-6543",
|
|
10304
|
+
contactPersonFirstName: "Jane",
|
|
10305
|
+
contactPersonLastName: "Doe",
|
|
10306
|
+
contactPersonEmail: "jane.doe@fernhypergrowth.com",
|
|
10307
|
+
contactPersonPhone: "+1 (555) 876-5432",
|
|
10308
|
+
address: {
|
|
10309
|
+
line1: "456 Tech Street",
|
|
10310
|
+
city: "San Francisco",
|
|
10311
|
+
state: "CA",
|
|
10312
|
+
postalCode: "94102",
|
|
10313
|
+
countryCode: "US"
|
|
10314
|
+
}
|
|
10315
|
+
},
|
|
10316
|
+
"8111026": {
|
|
10317
|
+
name: "ACEROSGALVANISADOS & PREPINTADOS",
|
|
10318
|
+
productId: 3,
|
|
10319
|
+
businessIdType: "EIN",
|
|
10320
|
+
idNumber: "45-6789012",
|
|
10321
|
+
businessEntityType: "PARTNERSHIP",
|
|
10322
|
+
incorporationState: "Texas",
|
|
10323
|
+
formationDate: "2018-03-10",
|
|
10324
|
+
website: "https://acerosgalvanisados.com",
|
|
10325
|
+
mcc: "5051",
|
|
10326
|
+
naics: "423510",
|
|
10327
|
+
mobilePhone: "+1 (555) 456-7890",
|
|
10328
|
+
contactPersonFirstName: "Carlos",
|
|
10329
|
+
contactPersonLastName: "Rodriguez",
|
|
10330
|
+
contactPersonEmail: "carlos@acerosgalvanisados.com",
|
|
10331
|
+
contactPersonPhone: "+1 (555) 567-8901",
|
|
10332
|
+
address: {
|
|
10333
|
+
line1: "789 Industrial Blvd",
|
|
10334
|
+
city: "Houston",
|
|
10335
|
+
state: "TX",
|
|
10336
|
+
postalCode: "77001",
|
|
10337
|
+
countryCode: "US"
|
|
10338
|
+
}
|
|
10339
|
+
},
|
|
10340
|
+
"8110892": {
|
|
10341
|
+
name: "Tech Solutions Corp",
|
|
10342
|
+
productId: 4,
|
|
10343
|
+
businessIdType: "EIN",
|
|
10344
|
+
idNumber: "23-4567890",
|
|
10345
|
+
businessEntityType: "CORPORATION",
|
|
10346
|
+
incorporationState: "Washington",
|
|
10347
|
+
formationDate: "2021-08-15",
|
|
10348
|
+
website: "https://techsolutions.com",
|
|
10349
|
+
mcc: "7372",
|
|
10350
|
+
naics: "541511",
|
|
10351
|
+
mobilePhone: "+1 (555) 321-0987",
|
|
10352
|
+
achCompanyId: "9876543210",
|
|
10353
|
+
contactPersonFirstName: "Sarah",
|
|
10354
|
+
contactPersonLastName: "Johnson",
|
|
10355
|
+
contactPersonEmail: "sarah.johnson@techsolutions.com",
|
|
10356
|
+
contactPersonPhone: "+1 (555) 432-1098",
|
|
10357
|
+
address: {
|
|
10358
|
+
line1: "321 Tech Park",
|
|
10359
|
+
line2: "Building B",
|
|
10360
|
+
city: "Seattle",
|
|
10361
|
+
state: "WA",
|
|
10362
|
+
postalCode: "98101",
|
|
10363
|
+
countryCode: "US"
|
|
10364
|
+
}
|
|
10365
|
+
},
|
|
10366
|
+
"8110654": {
|
|
10367
|
+
name: "Global Trade Partners LLC",
|
|
10368
|
+
productId: 5,
|
|
10369
|
+
businessIdType: "EIN",
|
|
10370
|
+
idNumber: "67-8901234",
|
|
10371
|
+
dba: "GTP",
|
|
10372
|
+
businessEntityType: "LIMITED_LIABILITY_COMPANY",
|
|
10373
|
+
incorporationState: "Florida",
|
|
10374
|
+
formationDate: "2017-11-01",
|
|
10375
|
+
website: "https://globaltradepartners.com",
|
|
10376
|
+
mcc: "5732",
|
|
10377
|
+
naics: "443142",
|
|
10378
|
+
mobilePhone: "+1 (555) 654-3210",
|
|
10379
|
+
contactPersonFirstName: "Michael",
|
|
10380
|
+
contactPersonLastName: "Chen",
|
|
10381
|
+
contactPersonEmail: "michael.chen@gtp.com",
|
|
10382
|
+
contactPersonPhone: "+1 (555) 765-4321",
|
|
10383
|
+
address: {
|
|
10384
|
+
line1: "555 Trade Center",
|
|
10385
|
+
city: "Miami",
|
|
10386
|
+
state: "FL",
|
|
10387
|
+
postalCode: "33101",
|
|
10388
|
+
countryCode: "US"
|
|
10389
|
+
}
|
|
10390
|
+
}
|
|
10391
|
+
};
|
|
10246
10392
|
var BusinessDetail = () => {
|
|
10247
10393
|
const { id } = reactRouterDom.useParams();
|
|
10248
10394
|
const navigate = reactRouterDom.useNavigate();
|
|
@@ -10251,14 +10397,22 @@ var BusinessDetail = () => {
|
|
|
10251
10397
|
const businessUBOs = id ? mockBusinessUBOs[id] || [] : [];
|
|
10252
10398
|
const businessDocuments = id ? mockBusinessDocuments[id] || [] : [];
|
|
10253
10399
|
const businessAccounts = id ? mockBusinessAccounts[id] || [] : [];
|
|
10400
|
+
const initialProfile = id ? mockBusinessProfiles[id] : void 0;
|
|
10254
10401
|
const [currentStatus, setCurrentStatus] = React15.useState(business?.status || "active");
|
|
10255
10402
|
const [isEditingProfile, setIsEditingProfile] = React15.useState(false);
|
|
10403
|
+
const [businessProfile, setBusinessProfile] = React15.useState(
|
|
10404
|
+
initialProfile
|
|
10405
|
+
);
|
|
10256
10406
|
const handleStatusChange = (newStatus) => {
|
|
10257
10407
|
setCurrentStatus(newStatus);
|
|
10258
10408
|
};
|
|
10259
10409
|
const handleToggleProfileEdit = () => {
|
|
10260
10410
|
setIsEditingProfile(!isEditingProfile);
|
|
10261
10411
|
};
|
|
10412
|
+
const handleProfileDataChange = (updatedProfile) => {
|
|
10413
|
+
setBusinessProfile(updatedProfile);
|
|
10414
|
+
console.log("Profile updated:", updatedProfile);
|
|
10415
|
+
};
|
|
10262
10416
|
const handleNavigateToAccounts = () => {
|
|
10263
10417
|
navigate(`/accounts?customerId=${id}&customerType=business`);
|
|
10264
10418
|
};
|
|
@@ -10278,6 +10432,7 @@ var BusinessDetail = () => {
|
|
|
10278
10432
|
BusinessDetailView,
|
|
10279
10433
|
{
|
|
10280
10434
|
business,
|
|
10435
|
+
businessProfile,
|
|
10281
10436
|
identityVerification,
|
|
10282
10437
|
businessUBOs,
|
|
10283
10438
|
businessDocuments,
|
|
@@ -10285,6 +10440,7 @@ var BusinessDetail = () => {
|
|
|
10285
10440
|
currentStatus,
|
|
10286
10441
|
isEditingProfile,
|
|
10287
10442
|
onStatusChange: handleStatusChange,
|
|
10443
|
+
onProfileDataChange: handleProfileDataChange,
|
|
10288
10444
|
onToggleProfileEdit: handleToggleProfileEdit,
|
|
10289
10445
|
onNavigateToAccounts: handleNavigateToAccounts,
|
|
10290
10446
|
onNavigateToCounterparty: handleNavigateToCounterparty,
|