@burdenoff/microfe-subscriberbot 2026.626.2 → 2026.628.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.js +4 -4
- package/dist/subscriberbot/SubscriberBotRoot.js +61 -133
- package/dist/subscriberbot/SubscriberBotRoot.js.map +1 -1
- package/dist/subscriberbot/SubscriberBotRoutes.js +56 -187
- package/dist/subscriberbot/SubscriberBotRoutes.js.map +1 -1
- package/dist/subscriberbot/components/StateViews.js +49 -0
- package/dist/subscriberbot/components/StateViews.js.map +1 -0
- package/dist/subscriberbot/components/StatusBadge.js +45 -47
- package/dist/subscriberbot/components/StatusBadge.js.map +1 -1
- package/dist/subscriberbot/context/SubscriberBotContext.js +22 -30
- package/dist/subscriberbot/context/SubscriberBotContext.js.map +1 -1
- package/dist/subscriberbot/hooks/useSubscriberBotApi.js +342 -195
- package/dist/subscriberbot/hooks/useSubscriberBotApi.js.map +1 -1
- package/dist/subscriberbot/index.js +1 -1
- package/dist/subscriberbot/pages/DashboardPage.js +269 -0
- package/dist/subscriberbot/pages/DashboardPage.js.map +1 -0
- package/dist/subscriberbot/pages/InboxPage.js +186 -0
- package/dist/subscriberbot/pages/InboxPage.js.map +1 -0
- package/dist/subscriberbot/pages/InvoicesPage.js +211 -0
- package/dist/subscriberbot/pages/InvoicesPage.js.map +1 -0
- package/dist/subscriberbot/pages/WorkflowsPage.js +236 -0
- package/dist/subscriberbot/pages/WorkflowsPage.js.map +1 -0
- package/dist/subscriberbot/pages/agents/AgentDetailPage.js +160 -0
- package/dist/subscriberbot/pages/agents/AgentDetailPage.js.map +1 -0
- package/dist/subscriberbot/pages/agents/AgentNewPage.js +140 -0
- package/dist/subscriberbot/pages/agents/AgentNewPage.js.map +1 -0
- package/dist/subscriberbot/pages/agents/AgentsListPage.js +178 -0
- package/dist/subscriberbot/pages/agents/AgentsListPage.js.map +1 -0
- package/dist/subscriberbot/pages/providers/ProviderDetailPage.js +179 -0
- package/dist/subscriberbot/pages/providers/ProviderDetailPage.js.map +1 -0
- package/dist/subscriberbot/pages/providers/ProviderNewPage.js +185 -0
- package/dist/subscriberbot/pages/providers/ProviderNewPage.js.map +1 -0
- package/dist/subscriberbot/pages/providers/ProvidersListPage.js +254 -0
- package/dist/subscriberbot/pages/providers/ProvidersListPage.js.map +1 -0
- package/dist/subscriberbot/pages/relationships/RelationshipDetailPage.js +306 -0
- package/dist/subscriberbot/pages/relationships/RelationshipDetailPage.js.map +1 -0
- package/dist/subscriberbot/pages/relationships/RelationshipNewPage.js +253 -0
- package/dist/subscriberbot/pages/relationships/RelationshipNewPage.js.map +1 -0
- package/dist/subscriberbot/pages/relationships/RelationshipsListPage.js +248 -0
- package/dist/subscriberbot/pages/relationships/RelationshipsListPage.js.map +1 -0
- package/dist/subscriberbot/utils/formatters.js +50 -32
- package/dist/subscriberbot/utils/formatters.js.map +1 -1
- package/package.json +1 -1
- package/dist/subscriberbot/components/InvestmentCard.js +0 -97
- package/dist/subscriberbot/components/InvestmentCard.js.map +0 -1
- package/dist/subscriberbot/components/RatingDisplay.js +0 -35
- package/dist/subscriberbot/components/RatingDisplay.js.map +0 -1
- package/dist/subscriberbot/mocks/data.js +0 -1517
- package/dist/subscriberbot/mocks/data.js.map +0 -1
- package/dist/subscriberbot/mocks/users.js +0 -34
- package/dist/subscriberbot/mocks/users.js.map +0 -1
- package/dist/subscriberbot/pages/HomePage.js +0 -930
- package/dist/subscriberbot/pages/HomePage.js.map +0 -1
- package/dist/subscriberbot/pages/admin/AdminAnalyticsPage.js +0 -651
- package/dist/subscriberbot/pages/admin/AdminAnalyticsPage.js.map +0 -1
- package/dist/subscriberbot/pages/admin/AdminDashboard.js +0 -679
- package/dist/subscriberbot/pages/admin/AdminDashboard.js.map +0 -1
- package/dist/subscriberbot/pages/admin/AdminFinancialPage.js +0 -427
- package/dist/subscriberbot/pages/admin/AdminFinancialPage.js.map +0 -1
- package/dist/subscriberbot/pages/admin/AdminOrdersPage.js +0 -665
- package/dist/subscriberbot/pages/admin/AdminOrdersPage.js.map +0 -1
- package/dist/subscriberbot/pages/admin/AdminProfilePage.js +0 -261
- package/dist/subscriberbot/pages/admin/AdminProfilePage.js.map +0 -1
- package/dist/subscriberbot/pages/admin/AdminSettingsPage.js +0 -654
- package/dist/subscriberbot/pages/admin/AdminSettingsPage.js.map +0 -1
- package/dist/subscriberbot/pages/admin/CartManagementPage.js +0 -874
- package/dist/subscriberbot/pages/admin/CartManagementPage.js.map +0 -1
- package/dist/subscriberbot/pages/admin/UserManagementPage.js +0 -898
- package/dist/subscriberbot/pages/admin/UserManagementPage.js.map +0 -1
- package/dist/subscriberbot/pages/cart-owner/AnalyticsDashboard.js +0 -839
- package/dist/subscriberbot/pages/cart-owner/AnalyticsDashboard.js.map +0 -1
- package/dist/subscriberbot/pages/cart-owner/BusinessSettingsPage.js +0 -705
- package/dist/subscriberbot/pages/cart-owner/BusinessSettingsPage.js.map +0 -1
- package/dist/subscriberbot/pages/cart-owner/CartOwnerDashboard.js +0 -802
- package/dist/subscriberbot/pages/cart-owner/CartOwnerDashboard.js.map +0 -1
- package/dist/subscriberbot/pages/cart-owner/CartOwnerProfilePage.js +0 -891
- package/dist/subscriberbot/pages/cart-owner/CartOwnerProfilePage.js.map +0 -1
- package/dist/subscriberbot/pages/cart-owner/CartServiceConfigPage.js +0 -633
- package/dist/subscriberbot/pages/cart-owner/CartServiceConfigPage.js.map +0 -1
- package/dist/subscriberbot/pages/cart-owner/InventoryManagementPage.js +0 -910
- package/dist/subscriberbot/pages/cart-owner/InventoryManagementPage.js.map +0 -1
- package/dist/subscriberbot/pages/cart-owner/OrderManagementPage.js +0 -879
- package/dist/subscriberbot/pages/cart-owner/OrderManagementPage.js.map +0 -1
- package/dist/subscriberbot/pages/cart-owner/StaffManagementPage.js +0 -838
- package/dist/subscriberbot/pages/cart-owner/StaffManagementPage.js.map +0 -1
- package/dist/subscriberbot/pages/common/HelpSupportPage.js +0 -1323
- package/dist/subscriberbot/pages/common/HelpSupportPage.js.map +0 -1
- package/dist/subscriberbot/pages/common/NotificationCenterPage.js +0 -672
- package/dist/subscriberbot/pages/common/NotificationCenterPage.js.map +0 -1
- package/dist/subscriberbot/pages/common/SettingsPage.js +0 -973
- package/dist/subscriberbot/pages/common/SettingsPage.js.map +0 -1
- package/dist/subscriberbot/pages/customer/BookingDetailsPage.js +0 -626
- package/dist/subscriberbot/pages/customer/BookingDetailsPage.js.map +0 -1
- package/dist/subscriberbot/pages/customer/CartDetailPage.js +0 -654
- package/dist/subscriberbot/pages/customer/CartDetailPage.js.map +0 -1
- package/dist/subscriberbot/pages/customer/CartDiscoveryPage.js +0 -555
- package/dist/subscriberbot/pages/customer/CartDiscoveryPage.js.map +0 -1
- package/dist/subscriberbot/pages/customer/CheckoutPage.js +0 -529
- package/dist/subscriberbot/pages/customer/CheckoutPage.js.map +0 -1
- package/dist/subscriberbot/pages/customer/CustomerDashboard.js +0 -532
- package/dist/subscriberbot/pages/customer/CustomerDashboard.js.map +0 -1
- package/dist/subscriberbot/pages/customer/CustomerProfilePage.js +0 -630
- package/dist/subscriberbot/pages/customer/CustomerProfilePage.js.map +0 -1
- package/dist/subscriberbot/pages/customer/DirectServiceBookingPage.js +0 -633
- package/dist/subscriberbot/pages/customer/DirectServiceBookingPage.js.map +0 -1
- package/dist/subscriberbot/pages/customer/FavoritesPage.js +0 -484
- package/dist/subscriberbot/pages/customer/FavoritesPage.js.map +0 -1
- package/dist/subscriberbot/pages/customer/OrderHistoryPage.js +0 -446
- package/dist/subscriberbot/pages/customer/OrderHistoryPage.js.map +0 -1
- package/dist/subscriberbot/pages/customer/OrderTrackingPage.js +0 -394
- package/dist/subscriberbot/pages/customer/OrderTrackingPage.js.map +0 -1
- package/dist/subscriberbot/pages/customer/PaymentMethodsPage.js +0 -495
- package/dist/subscriberbot/pages/customer/PaymentMethodsPage.js.map +0 -1
- package/dist/subscriberbot/pages/customer/ReviewsPage.js +0 -613
- package/dist/subscriberbot/pages/customer/ReviewsPage.js.map +0 -1
- package/dist/subscriberbot/pages/customer/SavedAddressesPage.js +0 -450
- package/dist/subscriberbot/pages/customer/SavedAddressesPage.js.map +0 -1
- package/dist/subscriberbot/pages/investor/InvestmentDetailsPage.js +0 -886
- package/dist/subscriberbot/pages/investor/InvestmentDetailsPage.js.map +0 -1
- package/dist/subscriberbot/pages/investor/InvestmentOpportunitiesPage.js +0 -947
- package/dist/subscriberbot/pages/investor/InvestmentOpportunitiesPage.js.map +0 -1
- package/dist/subscriberbot/pages/investor/InvestorAnalyticsPage.js +0 -687
- package/dist/subscriberbot/pages/investor/InvestorAnalyticsPage.js.map +0 -1
- package/dist/subscriberbot/pages/investor/InvestorDashboard.js +0 -451
- package/dist/subscriberbot/pages/investor/InvestorDashboard.js.map +0 -1
- package/dist/subscriberbot/pages/investor/InvestorInvestmentsPage.js +0 -406
- package/dist/subscriberbot/pages/investor/InvestorInvestmentsPage.js.map +0 -1
- package/dist/subscriberbot/pages/investor/InvestorPortfolioPage.js +0 -575
- package/dist/subscriberbot/pages/investor/InvestorPortfolioPage.js.map +0 -1
- package/dist/subscriberbot/pages/investor/InvestorProfilePage.js +0 -1070
- package/dist/subscriberbot/pages/investor/InvestorProfilePage.js.map +0 -1
- package/dist/subscriberbot/pages/worker/TaskDetailsPage.js +0 -535
- package/dist/subscriberbot/pages/worker/TaskDetailsPage.js.map +0 -1
- package/dist/subscriberbot/pages/worker/WorkerDashboard.js +0 -666
- package/dist/subscriberbot/pages/worker/WorkerDashboard.js.map +0 -1
- package/dist/subscriberbot/pages/worker/WorkerOrdersPage.js +0 -681
- package/dist/subscriberbot/pages/worker/WorkerOrdersPage.js.map +0 -1
- package/dist/subscriberbot/pages/worker/WorkerProfilePage.js +0 -692
- package/dist/subscriberbot/pages/worker/WorkerProfilePage.js.map +0 -1
- package/dist/subscriberbot/pages/worker/WorkerSchedulePage.js +0 -588
- package/dist/subscriberbot/pages/worker/WorkerSchedulePage.js.map +0 -1
|
@@ -1,947 +0,0 @@
|
|
|
1
|
-
import { useSubscriberBot as e } from "../../context/SubscriberBotContext.js";
|
|
2
|
-
import { cn as t } from "../../utils/cn.js";
|
|
3
|
-
import { PageLayout as n } from "../../components/PageLayout.js";
|
|
4
|
-
import { EmptyState as r } from "../../components/EmptyState.js";
|
|
5
|
-
import { formatCurrency as i, formatNumber as a } from "../../utils/formatters.js";
|
|
6
|
-
import { useCallback as o, useEffect as s, useMemo as c, useState as l } from "react";
|
|
7
|
-
import { CheckCircle2 as u, Eye as d, FileText as f, IndianRupee as p, MapPin as m, Search as h, Star as g, Target as _, X as v } from "lucide-react";
|
|
8
|
-
import { jsx as y, jsxs as b } from "react/jsx-runtime";
|
|
9
|
-
import { EmphasisPanel as x, PagePurpose as S } from "@burdenoff/fe-libs/ui";
|
|
10
|
-
//#region src/subscriberbot/pages/investor/InvestmentOpportunitiesPage.tsx
|
|
11
|
-
var C = [
|
|
12
|
-
{
|
|
13
|
-
id: "opp-001",
|
|
14
|
-
cartId: "cart-005",
|
|
15
|
-
cartName: "Organic Salad Bar",
|
|
16
|
-
cartOwner: "Sarah Johnson",
|
|
17
|
-
description: "Premium organic salad bar serving health-conscious customers in tech parks. Looking to expand to 3 new locations.",
|
|
18
|
-
targetAmount: 5e5,
|
|
19
|
-
raisedAmount: 325e3,
|
|
20
|
-
minimumInvestment: 25e3,
|
|
21
|
-
maximumInvestment: 1e5,
|
|
22
|
-
investorCount: 8,
|
|
23
|
-
daysLeft: 15,
|
|
24
|
-
expectedReturns: 22,
|
|
25
|
-
paybackPeriod: 36,
|
|
26
|
-
riskLevel: "low",
|
|
27
|
-
category: "Healthy Food",
|
|
28
|
-
location: "Whitefield, Bangalore",
|
|
29
|
-
image: "https://images.unsplash.com/photo-1512621776951-a57141f2eefd?w=400",
|
|
30
|
-
businessMetrics: {
|
|
31
|
-
monthlyRevenue: 28e4,
|
|
32
|
-
monthlyOrders: 1800,
|
|
33
|
-
averageOrderValue: 156,
|
|
34
|
-
rating: 4.9,
|
|
35
|
-
reviewCount: 342,
|
|
36
|
-
operatingSince: "2022-03-15"
|
|
37
|
-
},
|
|
38
|
-
financials: {
|
|
39
|
-
grossMargin: 65,
|
|
40
|
-
netMargin: 28,
|
|
41
|
-
monthlyExpenses: 78e3,
|
|
42
|
-
breakEvenAchieved: !0
|
|
43
|
-
},
|
|
44
|
-
investmentTerms: {
|
|
45
|
-
equityOffered: 25,
|
|
46
|
-
dividendFrequency: "monthly",
|
|
47
|
-
lockInPeriod: 24,
|
|
48
|
-
exitOptions: [
|
|
49
|
-
"Buyback",
|
|
50
|
-
"Secondary Sale",
|
|
51
|
-
"IPO"
|
|
52
|
-
]
|
|
53
|
-
},
|
|
54
|
-
documents: [
|
|
55
|
-
{
|
|
56
|
-
name: "Business Plan",
|
|
57
|
-
type: "PDF",
|
|
58
|
-
uploadedOn: "2024-06-01"
|
|
59
|
-
},
|
|
60
|
-
{
|
|
61
|
-
name: "Financial Statements",
|
|
62
|
-
type: "PDF",
|
|
63
|
-
uploadedOn: "2024-06-01"
|
|
64
|
-
},
|
|
65
|
-
{
|
|
66
|
-
name: "Legal Documents",
|
|
67
|
-
type: "PDF",
|
|
68
|
-
uploadedOn: "2024-06-01"
|
|
69
|
-
}
|
|
70
|
-
],
|
|
71
|
-
status: "active"
|
|
72
|
-
},
|
|
73
|
-
{
|
|
74
|
-
id: "opp-002",
|
|
75
|
-
cartId: "cart-006",
|
|
76
|
-
cartName: "Midnight Munchies",
|
|
77
|
-
cartOwner: "Ravi Mehta",
|
|
78
|
-
description: "Late-night food delivery cart specializing in comfort food for night shift workers and students. Operating near IT corridors.",
|
|
79
|
-
targetAmount: 3e5,
|
|
80
|
-
raisedAmount: 18e4,
|
|
81
|
-
minimumInvestment: 15e3,
|
|
82
|
-
maximumInvestment: 75e3,
|
|
83
|
-
investorCount: 12,
|
|
84
|
-
daysLeft: 22,
|
|
85
|
-
expectedReturns: 18,
|
|
86
|
-
paybackPeriod: 30,
|
|
87
|
-
riskLevel: "medium",
|
|
88
|
-
category: "Fast Food",
|
|
89
|
-
location: "Electronic City, Bangalore",
|
|
90
|
-
image: "https://images.unsplash.com/photo-1565299624946-b28f40a0ae38?w=400",
|
|
91
|
-
businessMetrics: {
|
|
92
|
-
monthlyRevenue: 195e3,
|
|
93
|
-
monthlyOrders: 1200,
|
|
94
|
-
averageOrderValue: 163,
|
|
95
|
-
rating: 4.7,
|
|
96
|
-
reviewCount: 256,
|
|
97
|
-
operatingSince: "2023-01-10"
|
|
98
|
-
},
|
|
99
|
-
financials: {
|
|
100
|
-
grossMargin: 58,
|
|
101
|
-
netMargin: 22,
|
|
102
|
-
monthlyExpenses: 65e3,
|
|
103
|
-
breakEvenAchieved: !0
|
|
104
|
-
},
|
|
105
|
-
investmentTerms: {
|
|
106
|
-
equityOffered: 20,
|
|
107
|
-
dividendFrequency: "quarterly",
|
|
108
|
-
lockInPeriod: 18,
|
|
109
|
-
exitOptions: ["Buyback", "Secondary Sale"]
|
|
110
|
-
},
|
|
111
|
-
documents: [{
|
|
112
|
-
name: "Business Plan",
|
|
113
|
-
type: "PDF",
|
|
114
|
-
uploadedOn: "2024-06-05"
|
|
115
|
-
}, {
|
|
116
|
-
name: "Market Analysis",
|
|
117
|
-
type: "PDF",
|
|
118
|
-
uploadedOn: "2024-06-05"
|
|
119
|
-
}],
|
|
120
|
-
status: "active"
|
|
121
|
-
},
|
|
122
|
-
{
|
|
123
|
-
id: "opp-003",
|
|
124
|
-
cartId: "cart-007",
|
|
125
|
-
cartName: "Fusion Street Tacos",
|
|
126
|
-
cartOwner: "Maria Rodriguez",
|
|
127
|
-
description: "Innovative fusion taco cart combining Mexican and Indian flavors. Winner of Street Food Awards 2023.",
|
|
128
|
-
targetAmount: 4e5,
|
|
129
|
-
raisedAmount: 4e5,
|
|
130
|
-
minimumInvestment: 2e4,
|
|
131
|
-
maximumInvestment: 8e4,
|
|
132
|
-
investorCount: 15,
|
|
133
|
-
daysLeft: 0,
|
|
134
|
-
expectedReturns: 25,
|
|
135
|
-
paybackPeriod: 24,
|
|
136
|
-
riskLevel: "low",
|
|
137
|
-
category: "Fusion Food",
|
|
138
|
-
location: "Indiranagar, Bangalore",
|
|
139
|
-
image: "https://images.unsplash.com/photo-1551504734-5ee1c4a1479b?w=400",
|
|
140
|
-
businessMetrics: {
|
|
141
|
-
monthlyRevenue: 32e4,
|
|
142
|
-
monthlyOrders: 2100,
|
|
143
|
-
averageOrderValue: 152,
|
|
144
|
-
rating: 4.8,
|
|
145
|
-
reviewCount: 512,
|
|
146
|
-
operatingSince: "2021-08-20"
|
|
147
|
-
},
|
|
148
|
-
financials: {
|
|
149
|
-
grossMargin: 68,
|
|
150
|
-
netMargin: 32,
|
|
151
|
-
monthlyExpenses: 85e3,
|
|
152
|
-
breakEvenAchieved: !0
|
|
153
|
-
},
|
|
154
|
-
investmentTerms: {
|
|
155
|
-
equityOffered: 30,
|
|
156
|
-
dividendFrequency: "monthly",
|
|
157
|
-
lockInPeriod: 12,
|
|
158
|
-
exitOptions: ["Buyback", "Franchise Conversion"]
|
|
159
|
-
},
|
|
160
|
-
documents: [{
|
|
161
|
-
name: "Business Plan",
|
|
162
|
-
type: "PDF",
|
|
163
|
-
uploadedOn: "2024-05-20"
|
|
164
|
-
}, {
|
|
165
|
-
name: "Awards & Recognition",
|
|
166
|
-
type: "PDF",
|
|
167
|
-
uploadedOn: "2024-05-20"
|
|
168
|
-
}],
|
|
169
|
-
status: "funded"
|
|
170
|
-
},
|
|
171
|
-
{
|
|
172
|
-
id: "opp-004",
|
|
173
|
-
cartId: "cart-008",
|
|
174
|
-
cartName: "Bubble Tea Express",
|
|
175
|
-
cartOwner: "Chen Wei",
|
|
176
|
-
description: "Trendy bubble tea cart with proprietary recipes. Planning expansion through franchise model.",
|
|
177
|
-
targetAmount: 6e5,
|
|
178
|
-
raisedAmount: 12e4,
|
|
179
|
-
minimumInvestment: 3e4,
|
|
180
|
-
maximumInvestment: 15e4,
|
|
181
|
-
investorCount: 4,
|
|
182
|
-
daysLeft: 45,
|
|
183
|
-
expectedReturns: 20,
|
|
184
|
-
paybackPeriod: 36,
|
|
185
|
-
riskLevel: "high",
|
|
186
|
-
category: "Beverages",
|
|
187
|
-
location: "Koramangala, Bangalore",
|
|
188
|
-
image: "https://images.unsplash.com/photo-1558857563-b371033873b8?w=400",
|
|
189
|
-
businessMetrics: {
|
|
190
|
-
monthlyRevenue: 15e4,
|
|
191
|
-
monthlyOrders: 900,
|
|
192
|
-
averageOrderValue: 167,
|
|
193
|
-
rating: 4.6,
|
|
194
|
-
reviewCount: 189,
|
|
195
|
-
operatingSince: "2023-11-01"
|
|
196
|
-
},
|
|
197
|
-
financials: {
|
|
198
|
-
grossMargin: 72,
|
|
199
|
-
netMargin: 18,
|
|
200
|
-
monthlyExpenses: 55e3,
|
|
201
|
-
breakEvenAchieved: !1
|
|
202
|
-
},
|
|
203
|
-
investmentTerms: {
|
|
204
|
-
equityOffered: 35,
|
|
205
|
-
dividendFrequency: "quarterly",
|
|
206
|
-
lockInPeriod: 36,
|
|
207
|
-
exitOptions: ["Franchise Sale", "Acquisition"]
|
|
208
|
-
},
|
|
209
|
-
documents: [{
|
|
210
|
-
name: "Franchise Plan",
|
|
211
|
-
type: "PDF",
|
|
212
|
-
uploadedOn: "2024-06-10"
|
|
213
|
-
}, {
|
|
214
|
-
name: "Recipe Patents",
|
|
215
|
-
type: "PDF",
|
|
216
|
-
uploadedOn: "2024-06-10"
|
|
217
|
-
}],
|
|
218
|
-
status: "active"
|
|
219
|
-
}
|
|
220
|
-
], w = {
|
|
221
|
-
totalOpportunities: 24,
|
|
222
|
-
averageReturns: 21.5,
|
|
223
|
-
totalFunded: 156e5,
|
|
224
|
-
successRate: 89
|
|
225
|
-
};
|
|
226
|
-
function T(e) {
|
|
227
|
-
switch (e) {
|
|
228
|
-
case "low": return "bg-status-success-bg/20 text-status-success-text";
|
|
229
|
-
case "medium": return "bg-status-warning-bg/20 text-status-warning-text";
|
|
230
|
-
case "high": return "bg-status-error-bg/20 text-status-error-text";
|
|
231
|
-
default: return "bg-secondary text-secondary-foreground";
|
|
232
|
-
}
|
|
233
|
-
}
|
|
234
|
-
function E(e) {
|
|
235
|
-
switch (e) {
|
|
236
|
-
case "low": return "Low Risk";
|
|
237
|
-
case "medium": return "Medium Risk";
|
|
238
|
-
case "high": return "High Risk";
|
|
239
|
-
default: return e;
|
|
240
|
-
}
|
|
241
|
-
}
|
|
242
|
-
function D(e, t) {
|
|
243
|
-
return t > 0 ? Math.min(e / t * 100, 100) : 0;
|
|
244
|
-
}
|
|
245
|
-
function O() {
|
|
246
|
-
let { navigateTo: O } = e(), [k, A] = l(!0), [j, M] = l(null), [N, P] = l(!1), [F, I] = l(""), [L, R] = l("idle"), [z, B] = l({
|
|
247
|
-
searchQuery: "",
|
|
248
|
-
category: "",
|
|
249
|
-
riskLevel: "",
|
|
250
|
-
minimumAmount: "",
|
|
251
|
-
location: "",
|
|
252
|
-
sortBy: "featured"
|
|
253
|
-
});
|
|
254
|
-
s(() => {
|
|
255
|
-
let e = setTimeout(() => A(!1), 600);
|
|
256
|
-
return () => clearTimeout(e);
|
|
257
|
-
}, []);
|
|
258
|
-
let V = o((e, t) => {
|
|
259
|
-
B((n) => ({
|
|
260
|
-
...n,
|
|
261
|
-
[e]: t
|
|
262
|
-
}));
|
|
263
|
-
}, []), H = c(() => {
|
|
264
|
-
let e = [...C];
|
|
265
|
-
if (z.searchQuery.trim()) {
|
|
266
|
-
let t = z.searchQuery.toLowerCase();
|
|
267
|
-
e = e.filter((e) => e.cartName.toLowerCase().includes(t) || e.description.toLowerCase().includes(t) || e.category.toLowerCase().includes(t));
|
|
268
|
-
}
|
|
269
|
-
if (z.category && (e = e.filter((e) => e.category === z.category)), z.riskLevel && (e = e.filter((e) => e.riskLevel === z.riskLevel)), z.location && (e = e.filter((e) => e.location.includes(z.location))), z.minimumAmount) {
|
|
270
|
-
let t = parseInt(z.minimumAmount, 10);
|
|
271
|
-
e = e.filter((e) => e.minimumInvestment <= t);
|
|
272
|
-
}
|
|
273
|
-
switch (z.sortBy) {
|
|
274
|
-
case "returns":
|
|
275
|
-
e.sort((e, t) => t.expectedReturns - e.expectedReturns);
|
|
276
|
-
break;
|
|
277
|
-
case "funding":
|
|
278
|
-
e.sort((e, t) => t.raisedAmount / t.targetAmount - e.raisedAmount / e.targetAmount);
|
|
279
|
-
break;
|
|
280
|
-
case "closing":
|
|
281
|
-
e.sort((e, t) => e.daysLeft - t.daysLeft);
|
|
282
|
-
break;
|
|
283
|
-
case "minimum":
|
|
284
|
-
e.sort((e, t) => e.minimumInvestment - t.minimumInvestment);
|
|
285
|
-
break;
|
|
286
|
-
default: break;
|
|
287
|
-
}
|
|
288
|
-
return e;
|
|
289
|
-
}, [z]), U = o(() => {
|
|
290
|
-
if (!j || !F) return;
|
|
291
|
-
let e = parseInt(F, 10);
|
|
292
|
-
if (!isNaN(e)) {
|
|
293
|
-
if (e < j.minimumInvestment) {
|
|
294
|
-
R("error");
|
|
295
|
-
return;
|
|
296
|
-
}
|
|
297
|
-
if (e > j.maximumInvestment) {
|
|
298
|
-
R("error");
|
|
299
|
-
return;
|
|
300
|
-
}
|
|
301
|
-
R("success"), setTimeout(() => {
|
|
302
|
-
P(!1), I(""), R("idle"), O("/investor/portfolio");
|
|
303
|
-
}, 1500);
|
|
304
|
-
}
|
|
305
|
-
}, [
|
|
306
|
-
j,
|
|
307
|
-
F,
|
|
308
|
-
O
|
|
309
|
-
]), W = o((e) => {
|
|
310
|
-
M(e), I(""), R("idle"), P(!0);
|
|
311
|
-
}, []);
|
|
312
|
-
return k ? /* @__PURE__ */ y(n, {
|
|
313
|
-
title: "Investment Opportunities",
|
|
314
|
-
description: "Loading opportunities...",
|
|
315
|
-
children: /* @__PURE__ */ y("div", {
|
|
316
|
-
className: "flex items-center justify-center py-20",
|
|
317
|
-
children: /* @__PURE__ */ b("div", {
|
|
318
|
-
className: "text-center",
|
|
319
|
-
children: [/* @__PURE__ */ y("div", { className: "mx-auto mb-4 h-12 w-12 animate-spin rounded-full border-b-2 border-primary" }), /* @__PURE__ */ y("p", {
|
|
320
|
-
className: "text-sm text-text-secondary",
|
|
321
|
-
children: "Loading opportunities..."
|
|
322
|
-
})]
|
|
323
|
-
})
|
|
324
|
-
})
|
|
325
|
-
}) : /* @__PURE__ */ b(n, {
|
|
326
|
-
title: "Investment Opportunities",
|
|
327
|
-
description: "Discover and invest in growing local businesses",
|
|
328
|
-
titleGradient: !0,
|
|
329
|
-
actions: /* @__PURE__ */ b("span", {
|
|
330
|
-
className: "text-sm text-text-secondary",
|
|
331
|
-
children: [H.length, " opportunities"]
|
|
332
|
-
}),
|
|
333
|
-
children: [
|
|
334
|
-
/* @__PURE__ */ y(S, {
|
|
335
|
-
icon: /* @__PURE__ */ y(_, { className: "h-4 w-4" }),
|
|
336
|
-
className: "mb-6",
|
|
337
|
-
children: "Where you find your next investment. Browse local carts actively raising capital, each with its expected returns, funding progress and risk level laid out clearly. Filter by category, return or risk to match your strategy, then open any opportunity to review the full pitch before you commit."
|
|
338
|
-
}),
|
|
339
|
-
/* @__PURE__ */ b(x, {
|
|
340
|
-
className: "grid grid-cols-2 gap-3 sm:gap-4 lg:grid-cols-4",
|
|
341
|
-
children: [
|
|
342
|
-
/* @__PURE__ */ b("div", {
|
|
343
|
-
className: "rounded-lg border border-border-seam bg-bg-surface p-3 sm:p-4",
|
|
344
|
-
children: [/* @__PURE__ */ y("p", {
|
|
345
|
-
className: "text-xs text-text-secondary",
|
|
346
|
-
children: "Active Opportunities"
|
|
347
|
-
}), /* @__PURE__ */ y("p", {
|
|
348
|
-
className: "text-lg font-bold text-text-primary sm:text-2xl",
|
|
349
|
-
children: w.totalOpportunities
|
|
350
|
-
})]
|
|
351
|
-
}),
|
|
352
|
-
/* @__PURE__ */ b("div", {
|
|
353
|
-
className: "rounded-lg border border-border-seam bg-bg-surface p-3 sm:p-4",
|
|
354
|
-
children: [/* @__PURE__ */ y("p", {
|
|
355
|
-
className: "text-xs text-text-secondary",
|
|
356
|
-
children: "Average Returns"
|
|
357
|
-
}), /* @__PURE__ */ b("p", {
|
|
358
|
-
className: "text-lg font-bold text-status-success-text sm:text-2xl",
|
|
359
|
-
children: [w.averageReturns, "%"]
|
|
360
|
-
})]
|
|
361
|
-
}),
|
|
362
|
-
/* @__PURE__ */ b("div", {
|
|
363
|
-
className: "rounded-lg border border-border-seam bg-bg-surface p-3 sm:p-4",
|
|
364
|
-
children: [/* @__PURE__ */ y("p", {
|
|
365
|
-
className: "text-xs text-text-secondary",
|
|
366
|
-
children: "Total Funded"
|
|
367
|
-
}), /* @__PURE__ */ y("p", {
|
|
368
|
-
className: "text-lg font-bold text-text-primary sm:text-2xl",
|
|
369
|
-
children: i(w.totalFunded, {
|
|
370
|
-
minimumFractionDigits: 0,
|
|
371
|
-
notation: "compact"
|
|
372
|
-
})
|
|
373
|
-
})]
|
|
374
|
-
}),
|
|
375
|
-
/* @__PURE__ */ b("div", {
|
|
376
|
-
className: "rounded-lg border border-border-seam bg-bg-surface p-3 sm:p-4",
|
|
377
|
-
children: [/* @__PURE__ */ y("p", {
|
|
378
|
-
className: "text-xs text-text-secondary",
|
|
379
|
-
children: "Success Rate"
|
|
380
|
-
}), /* @__PURE__ */ b("p", {
|
|
381
|
-
className: "text-lg font-bold text-text-primary sm:text-2xl",
|
|
382
|
-
children: [w.successRate, "%"]
|
|
383
|
-
})]
|
|
384
|
-
})
|
|
385
|
-
]
|
|
386
|
-
}),
|
|
387
|
-
/* @__PURE__ */ y("div", {
|
|
388
|
-
className: "mt-6 rounded-lg border border-border-seam bg-bg-surface p-4 sm:p-6",
|
|
389
|
-
children: /* @__PURE__ */ b("div", {
|
|
390
|
-
className: "grid grid-cols-1 gap-3 sm:grid-cols-2 lg:grid-cols-3 xl:grid-cols-6",
|
|
391
|
-
children: [
|
|
392
|
-
/* @__PURE__ */ b("div", {
|
|
393
|
-
className: "relative sm:col-span-2 lg:col-span-1",
|
|
394
|
-
children: [/* @__PURE__ */ y(h, { className: "absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-text-secondary" }), /* @__PURE__ */ y("input", {
|
|
395
|
-
type: "text",
|
|
396
|
-
placeholder: "Search opportunities...",
|
|
397
|
-
value: z.searchQuery,
|
|
398
|
-
onChange: (e) => V("searchQuery", e.target.value),
|
|
399
|
-
className: "w-full rounded-lg border border-border-seam 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)]"
|
|
400
|
-
})]
|
|
401
|
-
}),
|
|
402
|
-
/* @__PURE__ */ b("select", {
|
|
403
|
-
value: z.category,
|
|
404
|
-
onChange: (e) => V("category", e.target.value),
|
|
405
|
-
className: "rounded-lg border border-border-seam bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]",
|
|
406
|
-
children: [
|
|
407
|
-
/* @__PURE__ */ y("option", {
|
|
408
|
-
value: "",
|
|
409
|
-
children: "All Categories"
|
|
410
|
-
}),
|
|
411
|
-
/* @__PURE__ */ y("option", {
|
|
412
|
-
value: "Healthy Food",
|
|
413
|
-
children: "Healthy Food"
|
|
414
|
-
}),
|
|
415
|
-
/* @__PURE__ */ y("option", {
|
|
416
|
-
value: "Fast Food",
|
|
417
|
-
children: "Fast Food"
|
|
418
|
-
}),
|
|
419
|
-
/* @__PURE__ */ y("option", {
|
|
420
|
-
value: "Fusion Food",
|
|
421
|
-
children: "Fusion Food"
|
|
422
|
-
}),
|
|
423
|
-
/* @__PURE__ */ y("option", {
|
|
424
|
-
value: "Beverages",
|
|
425
|
-
children: "Beverages"
|
|
426
|
-
}),
|
|
427
|
-
/* @__PURE__ */ y("option", {
|
|
428
|
-
value: "Street Food",
|
|
429
|
-
children: "Street Food"
|
|
430
|
-
})
|
|
431
|
-
]
|
|
432
|
-
}),
|
|
433
|
-
/* @__PURE__ */ b("select", {
|
|
434
|
-
value: z.riskLevel,
|
|
435
|
-
onChange: (e) => V("riskLevel", e.target.value),
|
|
436
|
-
className: "rounded-lg border border-border-seam bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]",
|
|
437
|
-
children: [
|
|
438
|
-
/* @__PURE__ */ y("option", {
|
|
439
|
-
value: "",
|
|
440
|
-
children: "All Risk Levels"
|
|
441
|
-
}),
|
|
442
|
-
/* @__PURE__ */ y("option", {
|
|
443
|
-
value: "low",
|
|
444
|
-
children: "Low Risk"
|
|
445
|
-
}),
|
|
446
|
-
/* @__PURE__ */ y("option", {
|
|
447
|
-
value: "medium",
|
|
448
|
-
children: "Medium Risk"
|
|
449
|
-
}),
|
|
450
|
-
/* @__PURE__ */ y("option", {
|
|
451
|
-
value: "high",
|
|
452
|
-
children: "High Risk"
|
|
453
|
-
})
|
|
454
|
-
]
|
|
455
|
-
}),
|
|
456
|
-
/* @__PURE__ */ b("select", {
|
|
457
|
-
value: z.minimumAmount,
|
|
458
|
-
onChange: (e) => V("minimumAmount", e.target.value),
|
|
459
|
-
className: "rounded-lg border border-border-seam bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]",
|
|
460
|
-
children: [
|
|
461
|
-
/* @__PURE__ */ y("option", {
|
|
462
|
-
value: "",
|
|
463
|
-
children: "Any Amount"
|
|
464
|
-
}),
|
|
465
|
-
/* @__PURE__ */ y("option", {
|
|
466
|
-
value: "15000",
|
|
467
|
-
children: "Under ₹15,000"
|
|
468
|
-
}),
|
|
469
|
-
/* @__PURE__ */ y("option", {
|
|
470
|
-
value: "25000",
|
|
471
|
-
children: "Under ₹25,000"
|
|
472
|
-
}),
|
|
473
|
-
/* @__PURE__ */ y("option", {
|
|
474
|
-
value: "50000",
|
|
475
|
-
children: "Under ₹50,000"
|
|
476
|
-
}),
|
|
477
|
-
/* @__PURE__ */ y("option", {
|
|
478
|
-
value: "100000",
|
|
479
|
-
children: "Under ₹1,00,000"
|
|
480
|
-
})
|
|
481
|
-
]
|
|
482
|
-
}),
|
|
483
|
-
/* @__PURE__ */ b("select", {
|
|
484
|
-
value: z.location,
|
|
485
|
-
onChange: (e) => V("location", e.target.value),
|
|
486
|
-
className: "rounded-lg border border-border-seam bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]",
|
|
487
|
-
children: [
|
|
488
|
-
/* @__PURE__ */ y("option", {
|
|
489
|
-
value: "",
|
|
490
|
-
children: "All Locations"
|
|
491
|
-
}),
|
|
492
|
-
/* @__PURE__ */ y("option", {
|
|
493
|
-
value: "Whitefield",
|
|
494
|
-
children: "Whitefield"
|
|
495
|
-
}),
|
|
496
|
-
/* @__PURE__ */ y("option", {
|
|
497
|
-
value: "Koramangala",
|
|
498
|
-
children: "Koramangala"
|
|
499
|
-
}),
|
|
500
|
-
/* @__PURE__ */ y("option", {
|
|
501
|
-
value: "Indiranagar",
|
|
502
|
-
children: "Indiranagar"
|
|
503
|
-
}),
|
|
504
|
-
/* @__PURE__ */ y("option", {
|
|
505
|
-
value: "Electronic City",
|
|
506
|
-
children: "Electronic City"
|
|
507
|
-
})
|
|
508
|
-
]
|
|
509
|
-
}),
|
|
510
|
-
/* @__PURE__ */ b("select", {
|
|
511
|
-
value: z.sortBy,
|
|
512
|
-
onChange: (e) => V("sortBy", e.target.value),
|
|
513
|
-
className: "rounded-lg border border-border-seam bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]",
|
|
514
|
-
children: [
|
|
515
|
-
/* @__PURE__ */ y("option", {
|
|
516
|
-
value: "featured",
|
|
517
|
-
children: "Featured"
|
|
518
|
-
}),
|
|
519
|
-
/* @__PURE__ */ y("option", {
|
|
520
|
-
value: "returns",
|
|
521
|
-
children: "Highest Returns"
|
|
522
|
-
}),
|
|
523
|
-
/* @__PURE__ */ y("option", {
|
|
524
|
-
value: "funding",
|
|
525
|
-
children: "Most Funded"
|
|
526
|
-
}),
|
|
527
|
-
/* @__PURE__ */ y("option", {
|
|
528
|
-
value: "closing",
|
|
529
|
-
children: "Closing Soon"
|
|
530
|
-
}),
|
|
531
|
-
/* @__PURE__ */ y("option", {
|
|
532
|
-
value: "minimum",
|
|
533
|
-
children: "Lowest Minimum"
|
|
534
|
-
})
|
|
535
|
-
]
|
|
536
|
-
})
|
|
537
|
-
]
|
|
538
|
-
})
|
|
539
|
-
}),
|
|
540
|
-
H.length === 0 ? /* @__PURE__ */ y("div", {
|
|
541
|
-
className: "mt-6",
|
|
542
|
-
children: /* @__PURE__ */ y(r, {
|
|
543
|
-
illustration: "empty-search",
|
|
544
|
-
icon: /* @__PURE__ */ y(h, { className: "h-10 w-10" }),
|
|
545
|
-
title: "No opportunities found",
|
|
546
|
-
description: "Try adjusting your filters to find more opportunities",
|
|
547
|
-
action: /* @__PURE__ */ y("button", {
|
|
548
|
-
type: "button",
|
|
549
|
-
onClick: () => B({
|
|
550
|
-
searchQuery: "",
|
|
551
|
-
category: "",
|
|
552
|
-
riskLevel: "",
|
|
553
|
-
minimumAmount: "",
|
|
554
|
-
location: "",
|
|
555
|
-
sortBy: "featured"
|
|
556
|
-
}),
|
|
557
|
-
className: "rounded-lg bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 transition-colors",
|
|
558
|
-
children: "Clear Filters"
|
|
559
|
-
})
|
|
560
|
-
})
|
|
561
|
-
}) : /* @__PURE__ */ y("div", {
|
|
562
|
-
className: "mt-6 grid grid-cols-1 gap-4 lg:grid-cols-2",
|
|
563
|
-
children: H.map((e) => {
|
|
564
|
-
let n = D(e.raisedAmount, e.targetAmount);
|
|
565
|
-
return /* @__PURE__ */ b("div", {
|
|
566
|
-
className: "rounded-lg border border-border-seam bg-bg-surface shadow-sm hover:shadow-md transition-shadow",
|
|
567
|
-
children: [/* @__PURE__ */ b("div", {
|
|
568
|
-
className: "relative",
|
|
569
|
-
children: [
|
|
570
|
-
/* @__PURE__ */ y("div", {
|
|
571
|
-
className: "h-40 w-full overflow-hidden rounded-t-lg bg-bg-sunken sm:h-48",
|
|
572
|
-
children: /* @__PURE__ */ y("img", {
|
|
573
|
-
src: e.image,
|
|
574
|
-
alt: e.cartName,
|
|
575
|
-
className: "h-full w-full object-cover",
|
|
576
|
-
loading: "lazy"
|
|
577
|
-
})
|
|
578
|
-
}),
|
|
579
|
-
e.status === "funded" && /* @__PURE__ */ y("div", {
|
|
580
|
-
className: "absolute right-2 top-2 rounded-full bg-status-success-text px-2 py-1 text-xs font-medium text-text-inverse sm:right-4 sm:top-4 sm:px-3",
|
|
581
|
-
children: "Fully Funded"
|
|
582
|
-
}),
|
|
583
|
-
e.daysLeft > 0 && e.daysLeft <= 7 && /* @__PURE__ */ b("div", {
|
|
584
|
-
className: "absolute left-2 top-2 rounded-full bg-status-error-text px-2 py-1 text-xs font-medium text-text-inverse sm:left-4 sm:top-4 sm:px-3",
|
|
585
|
-
children: [e.daysLeft, " days left"]
|
|
586
|
-
})
|
|
587
|
-
]
|
|
588
|
-
}), /* @__PURE__ */ b("div", {
|
|
589
|
-
className: "p-4 sm:p-6",
|
|
590
|
-
children: [
|
|
591
|
-
/* @__PURE__ */ b("div", {
|
|
592
|
-
className: "mb-4 flex flex-col gap-3 sm:flex-row sm:items-start sm:justify-between",
|
|
593
|
-
children: [/* @__PURE__ */ b("div", {
|
|
594
|
-
className: "flex-1",
|
|
595
|
-
children: [
|
|
596
|
-
/* @__PURE__ */ y("h3", {
|
|
597
|
-
className: "text-base font-semibold text-text-primary sm:text-xl",
|
|
598
|
-
children: e.cartName
|
|
599
|
-
}),
|
|
600
|
-
/* @__PURE__ */ b("p", {
|
|
601
|
-
className: "text-xs text-text-secondary sm:text-sm",
|
|
602
|
-
children: ["by ", e.cartOwner]
|
|
603
|
-
}),
|
|
604
|
-
/* @__PURE__ */ b("div", {
|
|
605
|
-
className: "mt-2 flex flex-wrap items-center gap-2",
|
|
606
|
-
children: [/* @__PURE__ */ y("span", {
|
|
607
|
-
className: "text-xs text-text-secondary sm:text-sm",
|
|
608
|
-
children: e.category
|
|
609
|
-
}), /* @__PURE__ */ y("span", {
|
|
610
|
-
className: t("rounded-full px-2 py-0.5 text-xs font-medium", T(e.riskLevel)),
|
|
611
|
-
children: E(e.riskLevel)
|
|
612
|
-
})]
|
|
613
|
-
})
|
|
614
|
-
]
|
|
615
|
-
}), /* @__PURE__ */ b("div", {
|
|
616
|
-
className: "text-left sm:text-right",
|
|
617
|
-
children: [/* @__PURE__ */ b("p", {
|
|
618
|
-
className: "text-xl font-bold text-status-success-text sm:text-2xl",
|
|
619
|
-
children: [e.expectedReturns, "%"]
|
|
620
|
-
}), /* @__PURE__ */ y("p", {
|
|
621
|
-
className: "text-xs text-text-secondary",
|
|
622
|
-
children: "Expected Returns"
|
|
623
|
-
})]
|
|
624
|
-
})]
|
|
625
|
-
}),
|
|
626
|
-
/* @__PURE__ */ y("p", {
|
|
627
|
-
className: "mb-4 text-sm leading-relaxed text-text-secondary line-clamp-2",
|
|
628
|
-
children: e.description
|
|
629
|
-
}),
|
|
630
|
-
/* @__PURE__ */ b("div", {
|
|
631
|
-
className: "mb-4",
|
|
632
|
-
children: [
|
|
633
|
-
/* @__PURE__ */ b("div", {
|
|
634
|
-
className: "mb-1 flex justify-between text-xs sm:text-sm",
|
|
635
|
-
children: [/* @__PURE__ */ b("span", {
|
|
636
|
-
className: "font-medium text-text-primary",
|
|
637
|
-
children: [
|
|
638
|
-
i(e.raisedAmount, { minimumFractionDigits: 0 }),
|
|
639
|
-
" ",
|
|
640
|
-
"raised"
|
|
641
|
-
]
|
|
642
|
-
}), /* @__PURE__ */ b("span", {
|
|
643
|
-
className: "text-text-secondary",
|
|
644
|
-
children: ["of ", i(e.targetAmount, { minimumFractionDigits: 0 })]
|
|
645
|
-
})]
|
|
646
|
-
}),
|
|
647
|
-
/* @__PURE__ */ y("div", {
|
|
648
|
-
className: "h-2 w-full overflow-hidden rounded-full bg-bg-sunken",
|
|
649
|
-
children: /* @__PURE__ */ y("div", {
|
|
650
|
-
className: "h-full rounded-full bg-action-primary-bg transition-all duration-300",
|
|
651
|
-
style: { width: `${n}%` }
|
|
652
|
-
})
|
|
653
|
-
}),
|
|
654
|
-
/* @__PURE__ */ b("div", {
|
|
655
|
-
className: "mt-1 flex justify-between text-xs text-text-secondary",
|
|
656
|
-
children: [/* @__PURE__ */ b("span", { children: [e.investorCount, " investors"] }), /* @__PURE__ */ b("span", { children: [n.toFixed(0), "% funded"] })]
|
|
657
|
-
})
|
|
658
|
-
]
|
|
659
|
-
}),
|
|
660
|
-
/* @__PURE__ */ b("div", {
|
|
661
|
-
className: "mb-4 grid grid-cols-3 gap-2 text-center sm:gap-4",
|
|
662
|
-
children: [
|
|
663
|
-
/* @__PURE__ */ b("div", { children: [/* @__PURE__ */ y("p", {
|
|
664
|
-
className: "text-sm font-bold text-text-primary sm:text-lg",
|
|
665
|
-
children: i(e.minimumInvestment, { minimumFractionDigits: 0 })
|
|
666
|
-
}), /* @__PURE__ */ y("p", {
|
|
667
|
-
className: "text-xs text-text-secondary",
|
|
668
|
-
children: "Min Investment"
|
|
669
|
-
})] }),
|
|
670
|
-
/* @__PURE__ */ b("div", { children: [/* @__PURE__ */ b("p", {
|
|
671
|
-
className: "text-sm font-bold text-text-primary sm:text-lg",
|
|
672
|
-
children: [e.paybackPeriod, " mo"]
|
|
673
|
-
}), /* @__PURE__ */ y("p", {
|
|
674
|
-
className: "text-xs text-text-secondary",
|
|
675
|
-
children: "Payback Period"
|
|
676
|
-
})] }),
|
|
677
|
-
/* @__PURE__ */ b("div", { children: [/* @__PURE__ */ b("div", {
|
|
678
|
-
className: "flex items-center justify-center gap-1",
|
|
679
|
-
children: [/* @__PURE__ */ y(g, { className: "h-3.5 w-3.5 fill-status-warning-text text-status-warning-text" }), /* @__PURE__ */ y("p", {
|
|
680
|
-
className: "text-sm font-bold text-text-primary sm:text-lg",
|
|
681
|
-
children: e.businessMetrics.rating
|
|
682
|
-
})]
|
|
683
|
-
}), /* @__PURE__ */ y("p", {
|
|
684
|
-
className: "text-xs text-text-secondary",
|
|
685
|
-
children: "Rating"
|
|
686
|
-
})] })
|
|
687
|
-
]
|
|
688
|
-
}),
|
|
689
|
-
/* @__PURE__ */ b("div", {
|
|
690
|
-
className: "mb-4 border-t border-border-seam pt-3 sm:pt-4",
|
|
691
|
-
children: [/* @__PURE__ */ y("p", {
|
|
692
|
-
className: "mb-2 text-xs font-medium text-text-secondary sm:text-sm",
|
|
693
|
-
children: "Business Performance"
|
|
694
|
-
}), /* @__PURE__ */ b("div", {
|
|
695
|
-
className: "grid grid-cols-1 gap-2 text-xs sm:grid-cols-2 sm:text-sm",
|
|
696
|
-
children: [
|
|
697
|
-
/* @__PURE__ */ b("div", {
|
|
698
|
-
className: "flex justify-between",
|
|
699
|
-
children: [/* @__PURE__ */ y("span", {
|
|
700
|
-
className: "text-text-secondary",
|
|
701
|
-
children: "Monthly Revenue:"
|
|
702
|
-
}), /* @__PURE__ */ y("span", {
|
|
703
|
-
className: "font-medium text-text-primary",
|
|
704
|
-
children: i(e.businessMetrics.monthlyRevenue, { minimumFractionDigits: 0 })
|
|
705
|
-
})]
|
|
706
|
-
}),
|
|
707
|
-
/* @__PURE__ */ b("div", {
|
|
708
|
-
className: "flex justify-between",
|
|
709
|
-
children: [/* @__PURE__ */ y("span", {
|
|
710
|
-
className: "text-text-secondary",
|
|
711
|
-
children: "Gross Margin:"
|
|
712
|
-
}), /* @__PURE__ */ b("span", {
|
|
713
|
-
className: "font-medium text-text-primary",
|
|
714
|
-
children: [e.financials.grossMargin, "%"]
|
|
715
|
-
})]
|
|
716
|
-
}),
|
|
717
|
-
/* @__PURE__ */ b("div", {
|
|
718
|
-
className: "flex justify-between",
|
|
719
|
-
children: [/* @__PURE__ */ y("span", {
|
|
720
|
-
className: "text-text-secondary",
|
|
721
|
-
children: "Monthly Orders:"
|
|
722
|
-
}), /* @__PURE__ */ y("span", {
|
|
723
|
-
className: "font-medium text-text-primary",
|
|
724
|
-
children: a(e.businessMetrics.monthlyOrders)
|
|
725
|
-
})]
|
|
726
|
-
}),
|
|
727
|
-
/* @__PURE__ */ b("div", {
|
|
728
|
-
className: "flex justify-between",
|
|
729
|
-
children: [/* @__PURE__ */ y("span", {
|
|
730
|
-
className: "text-text-secondary",
|
|
731
|
-
children: "Net Margin:"
|
|
732
|
-
}), /* @__PURE__ */ b("span", {
|
|
733
|
-
className: "font-medium text-text-primary",
|
|
734
|
-
children: [e.financials.netMargin, "%"]
|
|
735
|
-
})]
|
|
736
|
-
})
|
|
737
|
-
]
|
|
738
|
-
})]
|
|
739
|
-
}),
|
|
740
|
-
/* @__PURE__ */ y("div", {
|
|
741
|
-
className: "mb-4 border-t border-border-seam pt-3",
|
|
742
|
-
children: /* @__PURE__ */ b("div", {
|
|
743
|
-
className: "flex items-center gap-1.5 text-xs text-text-secondary",
|
|
744
|
-
children: [/* @__PURE__ */ y(f, { className: "h-3.5 w-3.5" }), /* @__PURE__ */ b("span", { children: [e.documents.length, " documents available"] })]
|
|
745
|
-
})
|
|
746
|
-
}),
|
|
747
|
-
/* @__PURE__ */ b("div", {
|
|
748
|
-
className: "mb-4 flex items-center gap-1.5 text-xs text-text-secondary",
|
|
749
|
-
children: [/* @__PURE__ */ y(m, { className: "h-3.5 w-3.5" }), /* @__PURE__ */ y("span", { children: e.location })]
|
|
750
|
-
}),
|
|
751
|
-
/* @__PURE__ */ b("div", {
|
|
752
|
-
className: "flex flex-col gap-2 sm:flex-row sm:gap-3",
|
|
753
|
-
children: [/* @__PURE__ */ y("button", {
|
|
754
|
-
type: "button",
|
|
755
|
-
onClick: () => W(e),
|
|
756
|
-
disabled: e.status === "funded",
|
|
757
|
-
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"),
|
|
758
|
-
children: e.status === "funded" ? "Fully Funded" : "Invest Now"
|
|
759
|
-
}), /* @__PURE__ */ b("button", {
|
|
760
|
-
type: "button",
|
|
761
|
-
onClick: () => O(`/investor/opportunities/${e.id}`),
|
|
762
|
-
className: "flex flex-1 items-center justify-center gap-2 rounded-lg border border-border-seam px-4 py-2.5 text-sm font-medium text-text-primary hover:bg-accent transition-colors",
|
|
763
|
-
children: [/* @__PURE__ */ y(d, { className: "h-4 w-4" }), "View Details"]
|
|
764
|
-
})]
|
|
765
|
-
})
|
|
766
|
-
]
|
|
767
|
-
})]
|
|
768
|
-
}, e.id);
|
|
769
|
-
})
|
|
770
|
-
}),
|
|
771
|
-
N && j && /* @__PURE__ */ y("div", {
|
|
772
|
-
className: "fixed inset-0 z-50 flex items-center justify-center bg-bg-canvas/50 p-4",
|
|
773
|
-
children: /* @__PURE__ */ b("div", {
|
|
774
|
-
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",
|
|
775
|
-
children: [
|
|
776
|
-
/* @__PURE__ */ y("button", {
|
|
777
|
-
type: "button",
|
|
778
|
-
onClick: () => {
|
|
779
|
-
P(!1), I(""), R("idle");
|
|
780
|
-
},
|
|
781
|
-
className: "absolute right-3 top-3 rounded-lg p-1 text-text-secondary hover:bg-accent transition-colors",
|
|
782
|
-
children: /* @__PURE__ */ y(v, { className: "h-5 w-5" })
|
|
783
|
-
}),
|
|
784
|
-
/* @__PURE__ */ b("h3", {
|
|
785
|
-
className: "mb-4 text-base font-semibold text-text-primary sm:text-lg",
|
|
786
|
-
children: ["Invest in ", j.cartName]
|
|
787
|
-
}),
|
|
788
|
-
L === "success" ? /* @__PURE__ */ b("div", {
|
|
789
|
-
className: "py-8 text-center",
|
|
790
|
-
children: [
|
|
791
|
-
/* @__PURE__ */ y(u, { className: "mx-auto mb-3 h-12 w-12 text-status-success-text" }),
|
|
792
|
-
/* @__PURE__ */ y("p", {
|
|
793
|
-
className: "text-sm font-medium text-text-primary",
|
|
794
|
-
children: "Investment successful!"
|
|
795
|
-
}),
|
|
796
|
-
/* @__PURE__ */ y("p", {
|
|
797
|
-
className: "mt-1 text-xs text-text-secondary",
|
|
798
|
-
children: "Redirecting to your portfolio..."
|
|
799
|
-
})
|
|
800
|
-
]
|
|
801
|
-
}) : /* @__PURE__ */ b("div", {
|
|
802
|
-
className: "space-y-4",
|
|
803
|
-
children: [
|
|
804
|
-
/* @__PURE__ */ b("div", { children: [/* @__PURE__ */ y("p", {
|
|
805
|
-
className: "mb-1 text-xs text-text-secondary sm:text-sm",
|
|
806
|
-
children: "Investment Range"
|
|
807
|
-
}), /* @__PURE__ */ b("p", {
|
|
808
|
-
className: "text-sm font-medium text-text-primary sm:text-base",
|
|
809
|
-
children: [
|
|
810
|
-
i(j.minimumInvestment, { minimumFractionDigits: 0 }),
|
|
811
|
-
" ",
|
|
812
|
-
"-",
|
|
813
|
-
" ",
|
|
814
|
-
i(j.maximumInvestment, { minimumFractionDigits: 0 })
|
|
815
|
-
]
|
|
816
|
-
})] }),
|
|
817
|
-
/* @__PURE__ */ b("div", { children: [
|
|
818
|
-
/* @__PURE__ */ y("label", {
|
|
819
|
-
className: "mb-1 block text-xs font-medium text-text-primary sm:text-sm",
|
|
820
|
-
children: "Investment Amount"
|
|
821
|
-
}),
|
|
822
|
-
/* @__PURE__ */ b("div", {
|
|
823
|
-
className: "relative",
|
|
824
|
-
children: [/* @__PURE__ */ y(p, { className: "absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-text-secondary" }), /* @__PURE__ */ y("input", {
|
|
825
|
-
type: "number",
|
|
826
|
-
value: F,
|
|
827
|
-
onChange: (e) => {
|
|
828
|
-
I(e.target.value), R("idle");
|
|
829
|
-
},
|
|
830
|
-
placeholder: "Enter amount",
|
|
831
|
-
className: "w-full rounded-lg border border-border-seam 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)]"
|
|
832
|
-
})]
|
|
833
|
-
}),
|
|
834
|
-
L === "error" && /* @__PURE__ */ b("p", {
|
|
835
|
-
className: "mt-1 text-xs text-status-error-text",
|
|
836
|
-
children: [
|
|
837
|
-
"Amount must be between",
|
|
838
|
-
" ",
|
|
839
|
-
i(j.minimumInvestment, { minimumFractionDigits: 0 }),
|
|
840
|
-
" ",
|
|
841
|
-
"and",
|
|
842
|
-
" ",
|
|
843
|
-
i(j.maximumInvestment, { minimumFractionDigits: 0 })
|
|
844
|
-
]
|
|
845
|
-
})
|
|
846
|
-
] }),
|
|
847
|
-
F && !isNaN(parseInt(F, 10)) && parseInt(F, 10) > 0 && /* @__PURE__ */ b("div", {
|
|
848
|
-
className: "rounded-lg border border-border-seam bg-bg-sunken/50 p-3 sm:p-4",
|
|
849
|
-
children: [/* @__PURE__ */ y("p", {
|
|
850
|
-
className: "mb-2 text-xs text-text-secondary sm:text-sm",
|
|
851
|
-
children: "Expected Returns"
|
|
852
|
-
}), /* @__PURE__ */ b("div", {
|
|
853
|
-
className: "space-y-1.5",
|
|
854
|
-
children: [
|
|
855
|
-
/* @__PURE__ */ b("div", {
|
|
856
|
-
className: "flex justify-between",
|
|
857
|
-
children: [/* @__PURE__ */ y("span", {
|
|
858
|
-
className: "text-xs text-text-primary sm:text-sm",
|
|
859
|
-
children: "Investment:"
|
|
860
|
-
}), /* @__PURE__ */ y("span", {
|
|
861
|
-
className: "text-xs font-medium text-text-primary sm:text-sm",
|
|
862
|
-
children: i(parseInt(F, 10), { minimumFractionDigits: 0 })
|
|
863
|
-
})]
|
|
864
|
-
}),
|
|
865
|
-
/* @__PURE__ */ b("div", {
|
|
866
|
-
className: "flex justify-between",
|
|
867
|
-
children: [/* @__PURE__ */ b("span", {
|
|
868
|
-
className: "text-xs text-text-primary sm:text-sm",
|
|
869
|
-
children: [
|
|
870
|
-
"Expected Return (",
|
|
871
|
-
j.expectedReturns,
|
|
872
|
-
"%):"
|
|
873
|
-
]
|
|
874
|
-
}), /* @__PURE__ */ b("span", {
|
|
875
|
-
className: "text-xs font-medium text-status-success-text sm:text-sm",
|
|
876
|
-
children: ["+", i(parseInt(F, 10) * j.expectedReturns / 100, { minimumFractionDigits: 0 })]
|
|
877
|
-
})]
|
|
878
|
-
}),
|
|
879
|
-
/* @__PURE__ */ b("div", {
|
|
880
|
-
className: "flex justify-between border-t border-border-seam pt-2",
|
|
881
|
-
children: [/* @__PURE__ */ y("span", {
|
|
882
|
-
className: "text-xs font-medium text-text-primary sm:text-sm",
|
|
883
|
-
children: "Total Value:"
|
|
884
|
-
}), /* @__PURE__ */ y("span", {
|
|
885
|
-
className: "text-xs font-bold text-text-primary sm:text-sm",
|
|
886
|
-
children: i(parseInt(F, 10) * (1 + j.expectedReturns / 100), { minimumFractionDigits: 0 })
|
|
887
|
-
})]
|
|
888
|
-
})
|
|
889
|
-
]
|
|
890
|
-
})]
|
|
891
|
-
}),
|
|
892
|
-
/* @__PURE__ */ b("div", {
|
|
893
|
-
className: "space-y-1 text-xs text-text-secondary sm:text-sm",
|
|
894
|
-
children: [
|
|
895
|
-
/* @__PURE__ */ b("p", { children: [
|
|
896
|
-
"• Minimum lock-in period:",
|
|
897
|
-
" ",
|
|
898
|
-
j.investmentTerms.lockInPeriod,
|
|
899
|
-
" months"
|
|
900
|
-
] }),
|
|
901
|
-
/* @__PURE__ */ b("p", { children: [
|
|
902
|
-
"• Dividend frequency:",
|
|
903
|
-
" ",
|
|
904
|
-
j.investmentTerms.dividendFrequency
|
|
905
|
-
] }),
|
|
906
|
-
/* @__PURE__ */ b("p", { children: [
|
|
907
|
-
"• Your equity stake:",
|
|
908
|
-
" ",
|
|
909
|
-
((parseInt(F, 10) || 0) / j.targetAmount * j.investmentTerms.equityOffered).toFixed(2),
|
|
910
|
-
"%"
|
|
911
|
-
] }),
|
|
912
|
-
/* @__PURE__ */ b("p", { children: [
|
|
913
|
-
"• Exit options:",
|
|
914
|
-
" ",
|
|
915
|
-
j.investmentTerms.exitOptions.join(", ")
|
|
916
|
-
] })
|
|
917
|
-
]
|
|
918
|
-
}),
|
|
919
|
-
/* @__PURE__ */ b("div", {
|
|
920
|
-
className: "flex flex-col gap-2 pt-2 sm:flex-row sm:gap-3",
|
|
921
|
-
children: [/* @__PURE__ */ y("button", {
|
|
922
|
-
type: "button",
|
|
923
|
-
onClick: () => {
|
|
924
|
-
P(!1), I(""), R("idle");
|
|
925
|
-
},
|
|
926
|
-
className: "flex-1 rounded-lg border border-border-seam px-4 py-2.5 text-sm font-medium text-text-primary hover:bg-accent transition-colors",
|
|
927
|
-
children: "Cancel"
|
|
928
|
-
}), /* @__PURE__ */ y("button", {
|
|
929
|
-
type: "button",
|
|
930
|
-
onClick: U,
|
|
931
|
-
disabled: !F || isNaN(parseInt(F, 10)) || parseInt(F, 10) < j.minimumInvestment,
|
|
932
|
-
className: t("flex-1 rounded-lg px-4 py-2.5 text-sm font-medium transition-colors", !F || isNaN(parseInt(F, 10)) || parseInt(F, 10) < j.minimumInvestment ? "cursor-not-allowed bg-bg-sunken text-text-secondary" : "bg-action-primary-bg text-action-primary-text hover:bg-action-primary-bg/90"),
|
|
933
|
-
children: "Confirm Investment"
|
|
934
|
-
})]
|
|
935
|
-
})
|
|
936
|
-
]
|
|
937
|
-
})
|
|
938
|
-
]
|
|
939
|
-
})
|
|
940
|
-
})
|
|
941
|
-
]
|
|
942
|
-
});
|
|
943
|
-
}
|
|
944
|
-
//#endregion
|
|
945
|
-
export { O as InvestmentOpportunitiesPage };
|
|
946
|
-
|
|
947
|
-
//# sourceMappingURL=InvestmentOpportunitiesPage.js.map
|