@burdenoff/microfe-adaptercloud 2026.624.1 → 2026.625.2
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/adaptercloud/components/EmptyState.js +17 -21
- package/dist/adaptercloud/components/EmptyState.js.map +1 -1
- package/dist/adaptercloud/components/InvestmentCard.js +25 -23
- package/dist/adaptercloud/components/InvestmentCard.js.map +1 -1
- package/dist/adaptercloud/components/MetricsCard.js +18 -12
- package/dist/adaptercloud/components/MetricsCard.js.map +1 -1
- package/dist/adaptercloud/components/PageLayout.js +45 -19
- package/dist/adaptercloud/components/PageLayout.js.map +1 -1
- package/dist/adaptercloud/components/RatingDisplay.js +3 -3
- package/dist/adaptercloud/components/RatingDisplay.js.map +1 -1
- package/dist/adaptercloud/components/StatusBadge.js +36 -16
- package/dist/adaptercloud/components/StatusBadge.js.map +1 -1
- package/dist/adaptercloud/pages/HomePage.js +244 -231
- package/dist/adaptercloud/pages/HomePage.js.map +1 -1
- package/dist/adaptercloud/pages/admin/AdminAnalyticsPage.js +121 -113
- package/dist/adaptercloud/pages/admin/AdminAnalyticsPage.js.map +1 -1
- package/dist/adaptercloud/pages/admin/AdminDashboard.js +102 -76
- package/dist/adaptercloud/pages/admin/AdminDashboard.js.map +1 -1
- package/dist/adaptercloud/pages/admin/AdminFinancialPage.js +70 -65
- package/dist/adaptercloud/pages/admin/AdminFinancialPage.js.map +1 -1
- package/dist/adaptercloud/pages/admin/AdminOrdersPage.js +108 -103
- package/dist/adaptercloud/pages/admin/AdminOrdersPage.js.map +1 -1
- package/dist/adaptercloud/pages/admin/AdminProfilePage.js +61 -59
- package/dist/adaptercloud/pages/admin/AdminProfilePage.js.map +1 -1
- package/dist/adaptercloud/pages/admin/AdminSettingsPage.js +119 -105
- package/dist/adaptercloud/pages/admin/AdminSettingsPage.js.map +1 -1
- package/dist/adaptercloud/pages/admin/CartManagementPage.js +165 -160
- package/dist/adaptercloud/pages/admin/CartManagementPage.js.map +1 -1
- package/dist/adaptercloud/pages/admin/UserManagementPage.js +174 -169
- package/dist/adaptercloud/pages/admin/UserManagementPage.js.map +1 -1
- package/dist/adaptercloud/pages/cart-owner/AnalyticsDashboard.js +103 -97
- package/dist/adaptercloud/pages/cart-owner/AnalyticsDashboard.js.map +1 -1
- package/dist/adaptercloud/pages/cart-owner/BusinessSettingsPage.js +186 -172
- package/dist/adaptercloud/pages/cart-owner/BusinessSettingsPage.js.map +1 -1
- package/dist/adaptercloud/pages/cart-owner/CartOwnerDashboard.js +109 -81
- package/dist/adaptercloud/pages/cart-owner/CartOwnerDashboard.js.map +1 -1
- package/dist/adaptercloud/pages/cart-owner/CartOwnerProfilePage.js +111 -109
- package/dist/adaptercloud/pages/cart-owner/CartOwnerProfilePage.js.map +1 -1
- package/dist/adaptercloud/pages/cart-owner/CartServiceConfigPage.js +127 -124
- package/dist/adaptercloud/pages/cart-owner/CartServiceConfigPage.js.map +1 -1
- package/dist/adaptercloud/pages/cart-owner/InventoryManagementPage.js +310 -316
- package/dist/adaptercloud/pages/cart-owner/InventoryManagementPage.js.map +1 -1
- package/dist/adaptercloud/pages/cart-owner/OrderManagementPage.js +251 -257
- package/dist/adaptercloud/pages/cart-owner/OrderManagementPage.js.map +1 -1
- package/dist/adaptercloud/pages/cart-owner/StaffManagementPage.js +142 -148
- package/dist/adaptercloud/pages/cart-owner/StaffManagementPage.js.map +1 -1
- package/dist/adaptercloud/pages/common/HelpSupportPage.js +287 -283
- package/dist/adaptercloud/pages/common/HelpSupportPage.js.map +1 -1
- package/dist/adaptercloud/pages/common/NotificationCenterPage.js +120 -114
- package/dist/adaptercloud/pages/common/NotificationCenterPage.js.map +1 -1
- package/dist/adaptercloud/pages/common/SettingsPage.js +754 -736
- package/dist/adaptercloud/pages/common/SettingsPage.js.map +1 -1
- package/dist/adaptercloud/pages/customer/BookingDetailsPage.js +83 -80
- package/dist/adaptercloud/pages/customer/BookingDetailsPage.js.map +1 -1
- package/dist/adaptercloud/pages/customer/CartDetailPage.js +120 -117
- package/dist/adaptercloud/pages/customer/CartDetailPage.js.map +1 -1
- package/dist/adaptercloud/pages/customer/CartDiscoveryPage.js +231 -226
- package/dist/adaptercloud/pages/customer/CartDiscoveryPage.js.map +1 -1
- package/dist/adaptercloud/pages/customer/CheckoutPage.js +97 -95
- package/dist/adaptercloud/pages/customer/CheckoutPage.js.map +1 -1
- package/dist/adaptercloud/pages/customer/CustomerDashboard.js +418 -389
- package/dist/adaptercloud/pages/customer/CustomerDashboard.js.map +1 -1
- package/dist/adaptercloud/pages/customer/CustomerProfilePage.js +134 -132
- package/dist/adaptercloud/pages/customer/CustomerProfilePage.js.map +1 -1
- package/dist/adaptercloud/pages/customer/DirectServiceBookingPage.js +108 -102
- package/dist/adaptercloud/pages/customer/DirectServiceBookingPage.js.map +1 -1
- package/dist/adaptercloud/pages/customer/FavoritesPage.js +62 -59
- package/dist/adaptercloud/pages/customer/FavoritesPage.js.map +1 -1
- package/dist/adaptercloud/pages/customer/OrderHistoryPage.js +117 -111
- package/dist/adaptercloud/pages/customer/OrderHistoryPage.js.map +1 -1
- package/dist/adaptercloud/pages/customer/OrderTrackingPage.js +71 -68
- package/dist/adaptercloud/pages/customer/OrderTrackingPage.js.map +1 -1
- package/dist/adaptercloud/pages/customer/PaymentMethodsPage.js +97 -81
- package/dist/adaptercloud/pages/customer/PaymentMethodsPage.js.map +1 -1
- package/dist/adaptercloud/pages/customer/ReviewsPage.js +83 -80
- package/dist/adaptercloud/pages/customer/ReviewsPage.js.map +1 -1
- package/dist/adaptercloud/pages/customer/SavedAddressesPage.js +82 -66
- package/dist/adaptercloud/pages/customer/SavedAddressesPage.js.map +1 -1
- package/dist/adaptercloud/pages/investor/InvestmentDetailsPage.js +93 -91
- package/dist/adaptercloud/pages/investor/InvestmentDetailsPage.js.map +1 -1
- package/dist/adaptercloud/pages/investor/InvestmentOpportunitiesPage.js +100 -97
- package/dist/adaptercloud/pages/investor/InvestmentOpportunitiesPage.js.map +1 -1
- package/dist/adaptercloud/pages/investor/InvestorAnalyticsPage.js +83 -81
- package/dist/adaptercloud/pages/investor/InvestorAnalyticsPage.js.map +1 -1
- package/dist/adaptercloud/pages/investor/InvestorDashboard.js +344 -311
- package/dist/adaptercloud/pages/investor/InvestorDashboard.js.map +1 -1
- package/dist/adaptercloud/pages/investor/InvestorInvestmentsPage.js +43 -40
- package/dist/adaptercloud/pages/investor/InvestorInvestmentsPage.js.map +1 -1
- package/dist/adaptercloud/pages/investor/InvestorPortfolioPage.js +59 -57
- package/dist/adaptercloud/pages/investor/InvestorPortfolioPage.js.map +1 -1
- package/dist/adaptercloud/pages/investor/InvestorProfilePage.js +394 -392
- package/dist/adaptercloud/pages/investor/InvestorProfilePage.js.map +1 -1
- package/dist/adaptercloud/pages/worker/TaskDetailsPage.js +354 -324
- package/dist/adaptercloud/pages/worker/TaskDetailsPage.js.map +1 -1
- package/dist/adaptercloud/pages/worker/WorkerDashboard.js +122 -97
- package/dist/adaptercloud/pages/worker/WorkerDashboard.js.map +1 -1
- package/dist/adaptercloud/pages/worker/WorkerOrdersPage.js +107 -104
- package/dist/adaptercloud/pages/worker/WorkerOrdersPage.js.map +1 -1
- package/dist/adaptercloud/pages/worker/WorkerProfilePage.js +109 -107
- package/dist/adaptercloud/pages/worker/WorkerProfilePage.js.map +1 -1
- package/dist/adaptercloud/pages/worker/WorkerSchedulePage.js +94 -90
- package/dist/adaptercloud/pages/worker/WorkerSchedulePage.js.map +1 -1
- package/package.json +3 -3
|
@@ -6,8 +6,9 @@ import { formatCurrency as i, formatNumber as a } from "../../utils/formatters.j
|
|
|
6
6
|
import { useCallback as o, useEffect as s, useMemo as c, useState as l } from "react";
|
|
7
7
|
import { CheckCircle2 as u, Eye as d, FileText as f, IndianRupee as p, MapPin as m, Search as h, Star as g, X as _ } from "lucide-react";
|
|
8
8
|
import { jsx as v, jsxs as y } from "react/jsx-runtime";
|
|
9
|
+
import { EmphasisPanel as b } from "@burdenoff/fe-libs/ui";
|
|
9
10
|
//#region src/adaptercloud/pages/investor/InvestmentOpportunitiesPage.tsx
|
|
10
|
-
var
|
|
11
|
+
var x = [
|
|
11
12
|
{
|
|
12
13
|
id: "opp-001",
|
|
13
14
|
cartId: "cart-005",
|
|
@@ -216,21 +217,21 @@ var b = [
|
|
|
216
217
|
}],
|
|
217
218
|
status: "active"
|
|
218
219
|
}
|
|
219
|
-
],
|
|
220
|
+
], S = {
|
|
220
221
|
totalOpportunities: 24,
|
|
221
222
|
averageReturns: 21.5,
|
|
222
223
|
totalFunded: 156e5,
|
|
223
224
|
successRate: 89
|
|
224
225
|
};
|
|
225
|
-
function
|
|
226
|
+
function C(e) {
|
|
226
227
|
switch (e) {
|
|
227
|
-
case "low": return "bg-
|
|
228
|
-
case "medium": return "bg-
|
|
229
|
-
case "high": return "bg-
|
|
228
|
+
case "low": return "bg-status-success-bg-subtle/20 text-status-success-text";
|
|
229
|
+
case "medium": return "bg-status-warning-bg-subtle/20 text-status-warning-text";
|
|
230
|
+
case "high": return "bg-status-error-bg-subtle/20 text-status-error-text";
|
|
230
231
|
default: return "bg-secondary text-secondary-foreground";
|
|
231
232
|
}
|
|
232
233
|
}
|
|
233
|
-
function
|
|
234
|
+
function w(e) {
|
|
234
235
|
switch (e) {
|
|
235
236
|
case "low": return "Low Risk";
|
|
236
237
|
case "medium": return "Medium Risk";
|
|
@@ -238,11 +239,11 @@ function C(e) {
|
|
|
238
239
|
default: return e;
|
|
239
240
|
}
|
|
240
241
|
}
|
|
241
|
-
function
|
|
242
|
+
function T(e, t) {
|
|
242
243
|
return t > 0 ? Math.min(e / t * 100, 100) : 0;
|
|
243
244
|
}
|
|
244
|
-
function
|
|
245
|
-
let { navigateTo:
|
|
245
|
+
function E() {
|
|
246
|
+
let { navigateTo: E } = e(), [D, O] = l(!0), [k, A] = l(null), [j, M] = l(!1), [N, P] = l(""), [F, I] = l("idle"), [L, R] = l({
|
|
246
247
|
searchQuery: "",
|
|
247
248
|
category: "",
|
|
248
249
|
riskLevel: "",
|
|
@@ -251,25 +252,25 @@ function T() {
|
|
|
251
252
|
sortBy: "featured"
|
|
252
253
|
});
|
|
253
254
|
s(() => {
|
|
254
|
-
let e = setTimeout(() =>
|
|
255
|
+
let e = setTimeout(() => O(!1), 600);
|
|
255
256
|
return () => clearTimeout(e);
|
|
256
257
|
}, []);
|
|
257
|
-
let
|
|
258
|
-
|
|
258
|
+
let z = o((e, t) => {
|
|
259
|
+
R((n) => ({
|
|
259
260
|
...n,
|
|
260
261
|
[e]: t
|
|
261
262
|
}));
|
|
262
|
-
}, []),
|
|
263
|
-
let e = [...
|
|
264
|
-
if (
|
|
265
|
-
let t =
|
|
263
|
+
}, []), B = c(() => {
|
|
264
|
+
let e = [...x];
|
|
265
|
+
if (L.searchQuery.trim()) {
|
|
266
|
+
let t = L.searchQuery.toLowerCase();
|
|
266
267
|
e = e.filter((e) => e.cartName.toLowerCase().includes(t) || e.description.toLowerCase().includes(t) || e.category.toLowerCase().includes(t));
|
|
267
268
|
}
|
|
268
|
-
if (
|
|
269
|
-
let t = parseInt(
|
|
269
|
+
if (L.category && (e = e.filter((e) => e.category === L.category)), L.riskLevel && (e = e.filter((e) => e.riskLevel === L.riskLevel)), L.location && (e = e.filter((e) => e.location.includes(L.location))), L.minimumAmount) {
|
|
270
|
+
let t = parseInt(L.minimumAmount, 10);
|
|
270
271
|
e = e.filter((e) => e.minimumInvestment <= t);
|
|
271
272
|
}
|
|
272
|
-
switch (
|
|
273
|
+
switch (L.sortBy) {
|
|
273
274
|
case "returns":
|
|
274
275
|
e.sort((e, t) => t.expectedReturns - e.expectedReturns);
|
|
275
276
|
break;
|
|
@@ -285,30 +286,30 @@ function T() {
|
|
|
285
286
|
default: break;
|
|
286
287
|
}
|
|
287
288
|
return e;
|
|
288
|
-
}, [
|
|
289
|
-
if (!
|
|
290
|
-
let e = parseInt(
|
|
289
|
+
}, [L]), V = o(() => {
|
|
290
|
+
if (!k || !N) return;
|
|
291
|
+
let e = parseInt(N, 10);
|
|
291
292
|
if (!isNaN(e)) {
|
|
292
|
-
if (e <
|
|
293
|
-
|
|
293
|
+
if (e < k.minimumInvestment) {
|
|
294
|
+
I("error");
|
|
294
295
|
return;
|
|
295
296
|
}
|
|
296
|
-
if (e >
|
|
297
|
-
|
|
297
|
+
if (e > k.maximumInvestment) {
|
|
298
|
+
I("error");
|
|
298
299
|
return;
|
|
299
300
|
}
|
|
300
|
-
|
|
301
|
-
|
|
301
|
+
I("success"), setTimeout(() => {
|
|
302
|
+
M(!1), P(""), I("idle"), E("/investor/portfolio");
|
|
302
303
|
}, 1500);
|
|
303
304
|
}
|
|
304
305
|
}, [
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
]),
|
|
309
|
-
|
|
306
|
+
k,
|
|
307
|
+
N,
|
|
308
|
+
E
|
|
309
|
+
]), H = o((e) => {
|
|
310
|
+
A(e), P(""), I("idle"), M(!0);
|
|
310
311
|
}, []);
|
|
311
|
-
return
|
|
312
|
+
return D ? /* @__PURE__ */ v(n, {
|
|
312
313
|
title: "Investment Opportunities",
|
|
313
314
|
description: "Loading opportunities...",
|
|
314
315
|
children: /* @__PURE__ */ v("div", {
|
|
@@ -324,12 +325,13 @@ function T() {
|
|
|
324
325
|
}) : /* @__PURE__ */ y(n, {
|
|
325
326
|
title: "Investment Opportunities",
|
|
326
327
|
description: "Discover and invest in growing local businesses",
|
|
328
|
+
purpose: "Browse carts that are raising funds to grow — compare their projected returns, funding progress, and risk, then back the ones you believe in. This is where you find your next investment.",
|
|
327
329
|
actions: /* @__PURE__ */ y("span", {
|
|
328
330
|
className: "text-sm text-text-secondary",
|
|
329
|
-
children: [
|
|
331
|
+
children: [B.length, " opportunities"]
|
|
330
332
|
}),
|
|
331
333
|
children: [
|
|
332
|
-
/* @__PURE__ */ y("div", {
|
|
334
|
+
/* @__PURE__ */ v(b, { children: /* @__PURE__ */ y("div", {
|
|
333
335
|
className: "grid grid-cols-2 gap-3 sm:gap-4 lg:grid-cols-4",
|
|
334
336
|
children: [
|
|
335
337
|
/* @__PURE__ */ y("div", {
|
|
@@ -339,7 +341,7 @@ function T() {
|
|
|
339
341
|
children: "Active Opportunities"
|
|
340
342
|
}), /* @__PURE__ */ v("p", {
|
|
341
343
|
className: "text-lg font-bold text-text-primary sm:text-2xl",
|
|
342
|
-
children:
|
|
344
|
+
children: S.totalOpportunities
|
|
343
345
|
})]
|
|
344
346
|
}),
|
|
345
347
|
/* @__PURE__ */ y("div", {
|
|
@@ -348,8 +350,8 @@ function T() {
|
|
|
348
350
|
className: "text-xs text-text-secondary",
|
|
349
351
|
children: "Average Returns"
|
|
350
352
|
}), /* @__PURE__ */ y("p", {
|
|
351
|
-
className: "text-lg font-bold text-
|
|
352
|
-
children: [
|
|
353
|
+
className: "text-lg font-bold text-status-success-text sm:text-2xl",
|
|
354
|
+
children: [S.averageReturns, "%"]
|
|
353
355
|
})]
|
|
354
356
|
}),
|
|
355
357
|
/* @__PURE__ */ y("div", {
|
|
@@ -359,7 +361,7 @@ function T() {
|
|
|
359
361
|
children: "Total Funded"
|
|
360
362
|
}), /* @__PURE__ */ v("p", {
|
|
361
363
|
className: "text-lg font-bold text-text-primary sm:text-2xl",
|
|
362
|
-
children: i(
|
|
364
|
+
children: i(S.totalFunded, {
|
|
363
365
|
minimumFractionDigits: 0,
|
|
364
366
|
notation: "compact"
|
|
365
367
|
})
|
|
@@ -372,13 +374,13 @@ function T() {
|
|
|
372
374
|
children: "Success Rate"
|
|
373
375
|
}), /* @__PURE__ */ y("p", {
|
|
374
376
|
className: "text-lg font-bold text-text-primary sm:text-2xl",
|
|
375
|
-
children: [
|
|
377
|
+
children: [S.successRate, "%"]
|
|
376
378
|
})]
|
|
377
379
|
})
|
|
378
380
|
]
|
|
379
|
-
}),
|
|
381
|
+
}) }),
|
|
380
382
|
/* @__PURE__ */ v("div", {
|
|
381
|
-
className: "mt-6 rounded-lg border border-border-
|
|
383
|
+
className: "mt-6 rounded-lg border border-border-seam bg-bg-surface p-4 sm:p-6 bg-gloss-card shadow-pop",
|
|
382
384
|
children: /* @__PURE__ */ y("div", {
|
|
383
385
|
className: "grid grid-cols-1 gap-3 sm:grid-cols-2 lg:grid-cols-3 xl:grid-cols-6",
|
|
384
386
|
children: [
|
|
@@ -387,14 +389,14 @@ function T() {
|
|
|
387
389
|
children: [/* @__PURE__ */ v(h, { className: "absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-text-secondary" }), /* @__PURE__ */ v("input", {
|
|
388
390
|
type: "text",
|
|
389
391
|
placeholder: "Search opportunities...",
|
|
390
|
-
value:
|
|
391
|
-
onChange: (e) =>
|
|
392
|
+
value: L.searchQuery,
|
|
393
|
+
onChange: (e) => z("searchQuery", e.target.value),
|
|
392
394
|
className: "w-full rounded-lg border border-border-subtle bg-bg-surface py-2 pl-10 pr-4 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
|
|
393
395
|
})]
|
|
394
396
|
}),
|
|
395
397
|
/* @__PURE__ */ y("select", {
|
|
396
|
-
value:
|
|
397
|
-
onChange: (e) =>
|
|
398
|
+
value: L.category,
|
|
399
|
+
onChange: (e) => z("category", e.target.value),
|
|
398
400
|
className: "rounded-lg border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]",
|
|
399
401
|
children: [
|
|
400
402
|
/* @__PURE__ */ v("option", {
|
|
@@ -424,8 +426,8 @@ function T() {
|
|
|
424
426
|
]
|
|
425
427
|
}),
|
|
426
428
|
/* @__PURE__ */ y("select", {
|
|
427
|
-
value:
|
|
428
|
-
onChange: (e) =>
|
|
429
|
+
value: L.riskLevel,
|
|
430
|
+
onChange: (e) => z("riskLevel", e.target.value),
|
|
429
431
|
className: "rounded-lg border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]",
|
|
430
432
|
children: [
|
|
431
433
|
/* @__PURE__ */ v("option", {
|
|
@@ -447,8 +449,8 @@ function T() {
|
|
|
447
449
|
]
|
|
448
450
|
}),
|
|
449
451
|
/* @__PURE__ */ y("select", {
|
|
450
|
-
value:
|
|
451
|
-
onChange: (e) =>
|
|
452
|
+
value: L.minimumAmount,
|
|
453
|
+
onChange: (e) => z("minimumAmount", e.target.value),
|
|
452
454
|
className: "rounded-lg border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]",
|
|
453
455
|
children: [
|
|
454
456
|
/* @__PURE__ */ v("option", {
|
|
@@ -474,8 +476,8 @@ function T() {
|
|
|
474
476
|
]
|
|
475
477
|
}),
|
|
476
478
|
/* @__PURE__ */ y("select", {
|
|
477
|
-
value:
|
|
478
|
-
onChange: (e) =>
|
|
479
|
+
value: L.location,
|
|
480
|
+
onChange: (e) => z("location", e.target.value),
|
|
479
481
|
className: "rounded-lg border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]",
|
|
480
482
|
children: [
|
|
481
483
|
/* @__PURE__ */ v("option", {
|
|
@@ -501,8 +503,8 @@ function T() {
|
|
|
501
503
|
]
|
|
502
504
|
}),
|
|
503
505
|
/* @__PURE__ */ y("select", {
|
|
504
|
-
value:
|
|
505
|
-
onChange: (e) =>
|
|
506
|
+
value: L.sortBy,
|
|
507
|
+
onChange: (e) => z("sortBy", e.target.value),
|
|
506
508
|
className: "rounded-lg border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]",
|
|
507
509
|
children: [
|
|
508
510
|
/* @__PURE__ */ v("option", {
|
|
@@ -530,15 +532,16 @@ function T() {
|
|
|
530
532
|
]
|
|
531
533
|
})
|
|
532
534
|
}),
|
|
533
|
-
|
|
535
|
+
B.length === 0 ? /* @__PURE__ */ v("div", {
|
|
534
536
|
className: "mt-6",
|
|
535
537
|
children: /* @__PURE__ */ v(r, {
|
|
538
|
+
illustration: "empty-search",
|
|
536
539
|
icon: /* @__PURE__ */ v(h, { className: "h-10 w-10" }),
|
|
537
540
|
title: "No opportunities found",
|
|
538
541
|
description: "Try adjusting your filters to find more opportunities",
|
|
539
542
|
action: /* @__PURE__ */ v("button", {
|
|
540
543
|
type: "button",
|
|
541
|
-
onClick: () =>
|
|
544
|
+
onClick: () => R({
|
|
542
545
|
searchQuery: "",
|
|
543
546
|
category: "",
|
|
544
547
|
riskLevel: "",
|
|
@@ -552,8 +555,8 @@ function T() {
|
|
|
552
555
|
})
|
|
553
556
|
}) : /* @__PURE__ */ v("div", {
|
|
554
557
|
className: "mt-6 grid grid-cols-1 gap-4 lg:grid-cols-2",
|
|
555
|
-
children:
|
|
556
|
-
let n =
|
|
558
|
+
children: B.map((e) => {
|
|
559
|
+
let n = T(e.raisedAmount, e.targetAmount);
|
|
557
560
|
return /* @__PURE__ */ y("div", {
|
|
558
561
|
className: "rounded-lg border border-border-subtle bg-bg-surface shadow-sm hover:shadow-md transition-shadow",
|
|
559
562
|
children: [/* @__PURE__ */ y("div", {
|
|
@@ -569,11 +572,11 @@ function T() {
|
|
|
569
572
|
})
|
|
570
573
|
}),
|
|
571
574
|
e.status === "funded" && /* @__PURE__ */ v("div", {
|
|
572
|
-
className: "absolute right-2 top-2 rounded-full bg-
|
|
575
|
+
className: "absolute right-2 top-2 rounded-full bg-status-success-bg-subtle px-2 py-1 text-xs font-medium text-white sm:right-4 sm:top-4 sm:px-3",
|
|
573
576
|
children: "Fully Funded"
|
|
574
577
|
}),
|
|
575
578
|
e.daysLeft > 0 && e.daysLeft <= 7 && /* @__PURE__ */ y("div", {
|
|
576
|
-
className: "absolute left-2 top-2 rounded-full bg-
|
|
579
|
+
className: "absolute left-2 top-2 rounded-full bg-status-error-bg-subtle px-2 py-1 text-xs font-medium text-white sm:left-4 sm:top-4 sm:px-3",
|
|
577
580
|
children: [e.daysLeft, " days left"]
|
|
578
581
|
})
|
|
579
582
|
]
|
|
@@ -599,15 +602,15 @@ function T() {
|
|
|
599
602
|
className: "text-xs text-text-secondary sm:text-sm",
|
|
600
603
|
children: e.category
|
|
601
604
|
}), /* @__PURE__ */ v("span", {
|
|
602
|
-
className: t("rounded-full px-2 py-0.5 text-xs font-medium",
|
|
603
|
-
children:
|
|
605
|
+
className: t("rounded-full px-2 py-0.5 text-xs font-medium", C(e.riskLevel)),
|
|
606
|
+
children: w(e.riskLevel)
|
|
604
607
|
})]
|
|
605
608
|
})
|
|
606
609
|
]
|
|
607
610
|
}), /* @__PURE__ */ y("div", {
|
|
608
611
|
className: "text-left sm:text-right",
|
|
609
612
|
children: [/* @__PURE__ */ y("p", {
|
|
610
|
-
className: "text-xl font-bold text-
|
|
613
|
+
className: "text-xl font-bold text-status-success-text sm:text-2xl",
|
|
611
614
|
children: [e.expectedReturns, "%"]
|
|
612
615
|
}), /* @__PURE__ */ v("p", {
|
|
613
616
|
className: "text-xs text-text-secondary",
|
|
@@ -668,7 +671,7 @@ function T() {
|
|
|
668
671
|
})] }),
|
|
669
672
|
/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ y("div", {
|
|
670
673
|
className: "flex items-center justify-center gap-1",
|
|
671
|
-
children: [/* @__PURE__ */ v(g, { className: "h-3.5 w-3.5 fill-
|
|
674
|
+
children: [/* @__PURE__ */ v(g, { className: "h-3.5 w-3.5 fill-status-warning-text text-status-warning-text" }), /* @__PURE__ */ v("p", {
|
|
672
675
|
className: "text-sm font-bold text-text-primary sm:text-lg",
|
|
673
676
|
children: e.businessMetrics.rating
|
|
674
677
|
})]
|
|
@@ -744,13 +747,13 @@ function T() {
|
|
|
744
747
|
className: "flex flex-col gap-2 sm:flex-row sm:gap-3",
|
|
745
748
|
children: [/* @__PURE__ */ v("button", {
|
|
746
749
|
type: "button",
|
|
747
|
-
onClick: () =>
|
|
750
|
+
onClick: () => H(e),
|
|
748
751
|
disabled: e.status === "funded",
|
|
749
752
|
className: t("flex-1 rounded-lg px-4 py-2.5 text-sm font-medium transition-colors", e.status === "funded" ? "cursor-not-allowed bg-bg-sunken text-text-secondary" : "bg-action-primary-bg text-action-primary-text hover:bg-action-primary-bg/90"),
|
|
750
753
|
children: e.status === "funded" ? "Fully Funded" : "Invest Now"
|
|
751
754
|
}), /* @__PURE__ */ y("button", {
|
|
752
755
|
type: "button",
|
|
753
|
-
onClick: () =>
|
|
756
|
+
onClick: () => E(`/investor/opportunities/${e.id}`),
|
|
754
757
|
className: "flex flex-1 items-center justify-center gap-2 rounded-lg border border-border-subtle px-4 py-2.5 text-sm font-medium text-text-primary hover:bg-accent transition-colors",
|
|
755
758
|
children: [/* @__PURE__ */ v(d, { className: "h-4 w-4" }), "View Details"]
|
|
756
759
|
})]
|
|
@@ -760,27 +763,27 @@ function T() {
|
|
|
760
763
|
}, e.id);
|
|
761
764
|
})
|
|
762
765
|
}),
|
|
763
|
-
|
|
766
|
+
j && k && /* @__PURE__ */ v("div", {
|
|
764
767
|
className: "fixed inset-0 z-50 flex items-center justify-center bg-black/50 p-4",
|
|
765
768
|
children: /* @__PURE__ */ y("div", {
|
|
766
|
-
className: "relative max-h-[90vh] w-full max-w-md overflow-y-auto rounded-lg border border-border-
|
|
769
|
+
className: "relative max-h-[90vh] w-full max-w-md overflow-y-auto rounded-lg border border-border-seam bg-bg-surface p-4 sm:p-6 bg-gloss-card shadow-pop",
|
|
767
770
|
children: [
|
|
768
771
|
/* @__PURE__ */ v("button", {
|
|
769
772
|
type: "button",
|
|
770
773
|
onClick: () => {
|
|
771
|
-
|
|
774
|
+
M(!1), P(""), I("idle");
|
|
772
775
|
},
|
|
773
776
|
className: "absolute right-3 top-3 rounded-lg p-1 text-text-secondary hover:bg-accent transition-colors",
|
|
774
777
|
children: /* @__PURE__ */ v(_, { className: "h-5 w-5" })
|
|
775
778
|
}),
|
|
776
779
|
/* @__PURE__ */ y("h3", {
|
|
777
780
|
className: "mb-4 text-base font-semibold text-text-primary sm:text-lg",
|
|
778
|
-
children: ["Invest in ",
|
|
781
|
+
children: ["Invest in ", k.cartName]
|
|
779
782
|
}),
|
|
780
|
-
|
|
783
|
+
F === "success" ? /* @__PURE__ */ y("div", {
|
|
781
784
|
className: "py-8 text-center",
|
|
782
785
|
children: [
|
|
783
|
-
/* @__PURE__ */ v(u, { className: "mx-auto mb-3 h-12 w-12 text-
|
|
786
|
+
/* @__PURE__ */ v(u, { className: "mx-auto mb-3 h-12 w-12 text-status-success-text" }),
|
|
784
787
|
/* @__PURE__ */ v("p", {
|
|
785
788
|
className: "text-sm font-medium text-text-primary",
|
|
786
789
|
children: "Investment successful!"
|
|
@@ -799,11 +802,11 @@ function T() {
|
|
|
799
802
|
}), /* @__PURE__ */ y("p", {
|
|
800
803
|
className: "text-sm font-medium text-text-primary sm:text-base",
|
|
801
804
|
children: [
|
|
802
|
-
i(
|
|
805
|
+
i(k.minimumInvestment, { minimumFractionDigits: 0 }),
|
|
803
806
|
" ",
|
|
804
807
|
"-",
|
|
805
808
|
" ",
|
|
806
|
-
i(
|
|
809
|
+
i(k.maximumInvestment, { minimumFractionDigits: 0 })
|
|
807
810
|
]
|
|
808
811
|
})] }),
|
|
809
812
|
/* @__PURE__ */ y("div", { children: [
|
|
@@ -815,28 +818,28 @@ function T() {
|
|
|
815
818
|
className: "relative",
|
|
816
819
|
children: [/* @__PURE__ */ v(p, { className: "absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-text-secondary" }), /* @__PURE__ */ v("input", {
|
|
817
820
|
type: "number",
|
|
818
|
-
value:
|
|
821
|
+
value: N,
|
|
819
822
|
onChange: (e) => {
|
|
820
|
-
|
|
823
|
+
P(e.target.value), I("idle");
|
|
821
824
|
},
|
|
822
825
|
placeholder: "Enter amount",
|
|
823
826
|
className: "w-full rounded-lg border border-border-subtle bg-bg-surface py-2 pl-10 pr-4 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
|
|
824
827
|
})]
|
|
825
828
|
}),
|
|
826
|
-
|
|
827
|
-
className: "mt-1 text-xs text-
|
|
829
|
+
F === "error" && /* @__PURE__ */ y("p", {
|
|
830
|
+
className: "mt-1 text-xs text-status-error-text",
|
|
828
831
|
children: [
|
|
829
832
|
"Amount must be between",
|
|
830
833
|
" ",
|
|
831
|
-
i(
|
|
834
|
+
i(k.minimumInvestment, { minimumFractionDigits: 0 }),
|
|
832
835
|
" ",
|
|
833
836
|
"and",
|
|
834
837
|
" ",
|
|
835
|
-
i(
|
|
838
|
+
i(k.maximumInvestment, { minimumFractionDigits: 0 })
|
|
836
839
|
]
|
|
837
840
|
})
|
|
838
841
|
] }),
|
|
839
|
-
|
|
842
|
+
N && !isNaN(parseInt(N, 10)) && parseInt(N, 10) > 0 && /* @__PURE__ */ y("div", {
|
|
840
843
|
className: "rounded-lg border border-border-subtle bg-bg-sunken/50 p-3 sm:p-4",
|
|
841
844
|
children: [/* @__PURE__ */ v("p", {
|
|
842
845
|
className: "mb-2 text-xs text-text-secondary sm:text-sm",
|
|
@@ -851,7 +854,7 @@ function T() {
|
|
|
851
854
|
children: "Investment:"
|
|
852
855
|
}), /* @__PURE__ */ v("span", {
|
|
853
856
|
className: "text-xs font-medium text-text-primary sm:text-sm",
|
|
854
|
-
children: i(parseInt(
|
|
857
|
+
children: i(parseInt(N, 10), { minimumFractionDigits: 0 })
|
|
855
858
|
})]
|
|
856
859
|
}),
|
|
857
860
|
/* @__PURE__ */ y("div", {
|
|
@@ -860,12 +863,12 @@ function T() {
|
|
|
860
863
|
className: "text-xs text-text-primary sm:text-sm",
|
|
861
864
|
children: [
|
|
862
865
|
"Expected Return (",
|
|
863
|
-
|
|
866
|
+
k.expectedReturns,
|
|
864
867
|
"%):"
|
|
865
868
|
]
|
|
866
869
|
}), /* @__PURE__ */ y("span", {
|
|
867
|
-
className: "text-xs font-medium text-
|
|
868
|
-
children: ["+", i(parseInt(
|
|
870
|
+
className: "text-xs font-medium text-status-success-text sm:text-sm",
|
|
871
|
+
children: ["+", i(parseInt(N, 10) * k.expectedReturns / 100, { minimumFractionDigits: 0 })]
|
|
869
872
|
})]
|
|
870
873
|
}),
|
|
871
874
|
/* @__PURE__ */ y("div", {
|
|
@@ -875,7 +878,7 @@ function T() {
|
|
|
875
878
|
children: "Total Value:"
|
|
876
879
|
}), /* @__PURE__ */ v("span", {
|
|
877
880
|
className: "text-xs font-bold text-text-primary sm:text-sm",
|
|
878
|
-
children: i(parseInt(
|
|
881
|
+
children: i(parseInt(N, 10) * (1 + k.expectedReturns / 100), { minimumFractionDigits: 0 })
|
|
879
882
|
})]
|
|
880
883
|
})
|
|
881
884
|
]
|
|
@@ -887,24 +890,24 @@ function T() {
|
|
|
887
890
|
/* @__PURE__ */ y("p", { children: [
|
|
888
891
|
"• Minimum lock-in period:",
|
|
889
892
|
" ",
|
|
890
|
-
|
|
893
|
+
k.investmentTerms.lockInPeriod,
|
|
891
894
|
" months"
|
|
892
895
|
] }),
|
|
893
896
|
/* @__PURE__ */ y("p", { children: [
|
|
894
897
|
"• Dividend frequency:",
|
|
895
898
|
" ",
|
|
896
|
-
|
|
899
|
+
k.investmentTerms.dividendFrequency
|
|
897
900
|
] }),
|
|
898
901
|
/* @__PURE__ */ y("p", { children: [
|
|
899
902
|
"• Your equity stake:",
|
|
900
903
|
" ",
|
|
901
|
-
((parseInt(
|
|
904
|
+
((parseInt(N, 10) || 0) / k.targetAmount * k.investmentTerms.equityOffered).toFixed(2),
|
|
902
905
|
"%"
|
|
903
906
|
] }),
|
|
904
907
|
/* @__PURE__ */ y("p", { children: [
|
|
905
908
|
"• Exit options:",
|
|
906
909
|
" ",
|
|
907
|
-
|
|
910
|
+
k.investmentTerms.exitOptions.join(", ")
|
|
908
911
|
] })
|
|
909
912
|
]
|
|
910
913
|
}),
|
|
@@ -913,15 +916,15 @@ function T() {
|
|
|
913
916
|
children: [/* @__PURE__ */ v("button", {
|
|
914
917
|
type: "button",
|
|
915
918
|
onClick: () => {
|
|
916
|
-
|
|
919
|
+
M(!1), P(""), I("idle");
|
|
917
920
|
},
|
|
918
921
|
className: "flex-1 rounded-lg border border-border-subtle px-4 py-2.5 text-sm font-medium text-text-primary hover:bg-accent transition-colors",
|
|
919
922
|
children: "Cancel"
|
|
920
923
|
}), /* @__PURE__ */ v("button", {
|
|
921
924
|
type: "button",
|
|
922
|
-
onClick:
|
|
923
|
-
disabled: !
|
|
924
|
-
className: t("flex-1 rounded-lg px-4 py-2.5 text-sm font-medium transition-colors", !
|
|
925
|
+
onClick: V,
|
|
926
|
+
disabled: !N || isNaN(parseInt(N, 10)) || parseInt(N, 10) < k.minimumInvestment,
|
|
927
|
+
className: t("flex-1 rounded-lg px-4 py-2.5 text-sm font-medium transition-colors", !N || isNaN(parseInt(N, 10)) || parseInt(N, 10) < k.minimumInvestment ? "cursor-not-allowed bg-bg-sunken text-text-secondary" : "bg-action-primary-bg text-action-primary-text hover:bg-action-primary-bg/90"),
|
|
925
928
|
children: "Confirm Investment"
|
|
926
929
|
})]
|
|
927
930
|
})
|
|
@@ -934,6 +937,6 @@ function T() {
|
|
|
934
937
|
});
|
|
935
938
|
}
|
|
936
939
|
//#endregion
|
|
937
|
-
export {
|
|
940
|
+
export { E as InvestmentOpportunitiesPage };
|
|
938
941
|
|
|
939
942
|
//# sourceMappingURL=InvestmentOpportunitiesPage.js.map
|