@burdenoff/microfe-labsofscience 2026.626.1 → 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.
Files changed (172) hide show
  1. package/dist/index.js +4 -4
  2. package/dist/labsofscience/LabsOfScienceRoot.js +68 -124
  3. package/dist/labsofscience/LabsOfScienceRoot.js.map +1 -1
  4. package/dist/labsofscience/LabsOfScienceRoutes.js +61 -185
  5. package/dist/labsofscience/LabsOfScienceRoutes.js.map +1 -1
  6. package/dist/labsofscience/components/QueryStates.js +40 -0
  7. package/dist/labsofscience/components/QueryStates.js.map +1 -0
  8. package/dist/labsofscience/components/StatusBadge.js +40 -23
  9. package/dist/labsofscience/components/StatusBadge.js.map +1 -1
  10. package/dist/labsofscience/context/LabsOfScienceContext.js +22 -30
  11. package/dist/labsofscience/context/LabsOfScienceContext.js.map +1 -1
  12. package/dist/labsofscience/hooks/useLabsOfScienceApi.js +500 -172
  13. package/dist/labsofscience/hooks/useLabsOfScienceApi.js.map +1 -1
  14. package/dist/labsofscience/pages/OverviewPage.js +195 -0
  15. package/dist/labsofscience/pages/OverviewPage.js.map +1 -0
  16. package/dist/labsofscience/pages/datasets/DatasetDetailPage.js +162 -0
  17. package/dist/labsofscience/pages/datasets/DatasetDetailPage.js.map +1 -0
  18. package/dist/labsofscience/pages/datasets/DatasetFormDialog.js +137 -0
  19. package/dist/labsofscience/pages/datasets/DatasetFormDialog.js.map +1 -0
  20. package/dist/labsofscience/pages/datasets/DatasetsListPage.js +155 -0
  21. package/dist/labsofscience/pages/datasets/DatasetsListPage.js.map +1 -0
  22. package/dist/labsofscience/pages/experiments/ExperimentDetailPage.js +220 -0
  23. package/dist/labsofscience/pages/experiments/ExperimentDetailPage.js.map +1 -0
  24. package/dist/labsofscience/pages/experiments/ExperimentFormDialog.js +170 -0
  25. package/dist/labsofscience/pages/experiments/ExperimentFormDialog.js.map +1 -0
  26. package/dist/labsofscience/pages/experiments/ExperimentsListPage.js +134 -0
  27. package/dist/labsofscience/pages/experiments/ExperimentsListPage.js.map +1 -0
  28. package/dist/labsofscience/pages/experiments/RunDialogs.js +180 -0
  29. package/dist/labsofscience/pages/experiments/RunDialogs.js.map +1 -0
  30. package/dist/labsofscience/pages/instruments/InstrumentDetailPage.js +130 -0
  31. package/dist/labsofscience/pages/instruments/InstrumentDetailPage.js.map +1 -0
  32. package/dist/labsofscience/pages/instruments/InstrumentFormDialog.js +132 -0
  33. package/dist/labsofscience/pages/instruments/InstrumentFormDialog.js.map +1 -0
  34. package/dist/labsofscience/pages/instruments/InstrumentsListPage.js +126 -0
  35. package/dist/labsofscience/pages/instruments/InstrumentsListPage.js.map +1 -0
  36. package/dist/labsofscience/pages/inventory/AdjustInventoryDialog.js +89 -0
  37. package/dist/labsofscience/pages/inventory/AdjustInventoryDialog.js.map +1 -0
  38. package/dist/labsofscience/pages/inventory/InventoryDetailPage.js +138 -0
  39. package/dist/labsofscience/pages/inventory/InventoryDetailPage.js.map +1 -0
  40. package/dist/labsofscience/pages/inventory/InventoryFormDialog.js +211 -0
  41. package/dist/labsofscience/pages/inventory/InventoryFormDialog.js.map +1 -0
  42. package/dist/labsofscience/pages/inventory/InventoryListPage.js +178 -0
  43. package/dist/labsofscience/pages/inventory/InventoryListPage.js.map +1 -0
  44. package/dist/labsofscience/pages/notebook/NotebookEntryFormDialog.js +118 -0
  45. package/dist/labsofscience/pages/notebook/NotebookEntryFormDialog.js.map +1 -0
  46. package/dist/labsofscience/pages/notebook/NotebookListPage.js +144 -0
  47. package/dist/labsofscience/pages/notebook/NotebookListPage.js.map +1 -0
  48. package/dist/labsofscience/pages/pipelines/PipelineFormDialog.js +146 -0
  49. package/dist/labsofscience/pages/pipelines/PipelineFormDialog.js.map +1 -0
  50. package/dist/labsofscience/pages/pipelines/PipelinesPage.js +212 -0
  51. package/dist/labsofscience/pages/pipelines/PipelinesPage.js.map +1 -0
  52. package/dist/labsofscience/pages/pipelines/RunPipelineDialog.js +109 -0
  53. package/dist/labsofscience/pages/pipelines/RunPipelineDialog.js.map +1 -0
  54. package/dist/labsofscience/pages/projects/ProjectDetailPage.js +174 -0
  55. package/dist/labsofscience/pages/projects/ProjectDetailPage.js.map +1 -0
  56. package/dist/labsofscience/pages/projects/ProjectFormDialog.js +169 -0
  57. package/dist/labsofscience/pages/projects/ProjectFormDialog.js.map +1 -0
  58. package/dist/labsofscience/pages/projects/ProjectsListPage.js +141 -0
  59. package/dist/labsofscience/pages/projects/ProjectsListPage.js.map +1 -0
  60. package/dist/labsofscience/pages/protocols/ProtocolDetailPage.js +133 -0
  61. package/dist/labsofscience/pages/protocols/ProtocolDetailPage.js.map +1 -0
  62. package/dist/labsofscience/pages/protocols/ProtocolFormDialog.js +151 -0
  63. package/dist/labsofscience/pages/protocols/ProtocolFormDialog.js.map +1 -0
  64. package/dist/labsofscience/pages/protocols/ProtocolsListPage.js +140 -0
  65. package/dist/labsofscience/pages/protocols/ProtocolsListPage.js.map +1 -0
  66. package/dist/labsofscience/pages/shared/DetailComponents.js +64 -0
  67. package/dist/labsofscience/pages/shared/DetailComponents.js.map +1 -0
  68. package/dist/labsofscience/pages/shared/tags.js +16 -0
  69. package/dist/labsofscience/pages/shared/tags.js.map +1 -0
  70. package/dist/labsofscience/store/labsofscienceStore.js +6 -11
  71. package/dist/labsofscience/store/labsofscienceStore.js.map +1 -1
  72. package/dist/labsofscience/utils/formatters.js +28 -13
  73. package/dist/labsofscience/utils/formatters.js.map +1 -1
  74. package/package.json +1 -1
  75. package/dist/labsofscience/components/InvestmentCard.js +0 -98
  76. package/dist/labsofscience/components/InvestmentCard.js.map +0 -1
  77. package/dist/labsofscience/components/RatingDisplay.js +0 -35
  78. package/dist/labsofscience/components/RatingDisplay.js.map +0 -1
  79. package/dist/labsofscience/mocks/data.js +0 -1517
  80. package/dist/labsofscience/mocks/data.js.map +0 -1
  81. package/dist/labsofscience/mocks/users.js +0 -34
  82. package/dist/labsofscience/mocks/users.js.map +0 -1
  83. package/dist/labsofscience/pages/HomePage.js +0 -940
  84. package/dist/labsofscience/pages/HomePage.js.map +0 -1
  85. package/dist/labsofscience/pages/admin/AdminAnalyticsPage.js +0 -651
  86. package/dist/labsofscience/pages/admin/AdminAnalyticsPage.js.map +0 -1
  87. package/dist/labsofscience/pages/admin/AdminDashboard.js +0 -672
  88. package/dist/labsofscience/pages/admin/AdminDashboard.js.map +0 -1
  89. package/dist/labsofscience/pages/admin/AdminFinancialPage.js +0 -427
  90. package/dist/labsofscience/pages/admin/AdminFinancialPage.js.map +0 -1
  91. package/dist/labsofscience/pages/admin/AdminOrdersPage.js +0 -665
  92. package/dist/labsofscience/pages/admin/AdminOrdersPage.js.map +0 -1
  93. package/dist/labsofscience/pages/admin/AdminProfilePage.js +0 -261
  94. package/dist/labsofscience/pages/admin/AdminProfilePage.js.map +0 -1
  95. package/dist/labsofscience/pages/admin/AdminSettingsPage.js +0 -651
  96. package/dist/labsofscience/pages/admin/AdminSettingsPage.js.map +0 -1
  97. package/dist/labsofscience/pages/admin/CartManagementPage.js +0 -874
  98. package/dist/labsofscience/pages/admin/CartManagementPage.js.map +0 -1
  99. package/dist/labsofscience/pages/admin/UserManagementPage.js +0 -898
  100. package/dist/labsofscience/pages/admin/UserManagementPage.js.map +0 -1
  101. package/dist/labsofscience/pages/cart-owner/AnalyticsDashboard.js +0 -839
  102. package/dist/labsofscience/pages/cart-owner/AnalyticsDashboard.js.map +0 -1
  103. package/dist/labsofscience/pages/cart-owner/BusinessSettingsPage.js +0 -705
  104. package/dist/labsofscience/pages/cart-owner/BusinessSettingsPage.js.map +0 -1
  105. package/dist/labsofscience/pages/cart-owner/CartOwnerDashboard.js +0 -791
  106. package/dist/labsofscience/pages/cart-owner/CartOwnerDashboard.js.map +0 -1
  107. package/dist/labsofscience/pages/cart-owner/CartOwnerProfilePage.js +0 -891
  108. package/dist/labsofscience/pages/cart-owner/CartOwnerProfilePage.js.map +0 -1
  109. package/dist/labsofscience/pages/cart-owner/CartServiceConfigPage.js +0 -636
  110. package/dist/labsofscience/pages/cart-owner/CartServiceConfigPage.js.map +0 -1
  111. package/dist/labsofscience/pages/cart-owner/InventoryManagementPage.js +0 -911
  112. package/dist/labsofscience/pages/cart-owner/InventoryManagementPage.js.map +0 -1
  113. package/dist/labsofscience/pages/cart-owner/OrderManagementPage.js +0 -879
  114. package/dist/labsofscience/pages/cart-owner/OrderManagementPage.js.map +0 -1
  115. package/dist/labsofscience/pages/cart-owner/StaffManagementPage.js +0 -839
  116. package/dist/labsofscience/pages/cart-owner/StaffManagementPage.js.map +0 -1
  117. package/dist/labsofscience/pages/common/HelpSupportPage.js +0 -1324
  118. package/dist/labsofscience/pages/common/HelpSupportPage.js.map +0 -1
  119. package/dist/labsofscience/pages/common/NotificationCenterPage.js +0 -672
  120. package/dist/labsofscience/pages/common/NotificationCenterPage.js.map +0 -1
  121. package/dist/labsofscience/pages/common/SettingsPage.js +0 -973
  122. package/dist/labsofscience/pages/common/SettingsPage.js.map +0 -1
  123. package/dist/labsofscience/pages/customer/BookingDetailsPage.js +0 -637
  124. package/dist/labsofscience/pages/customer/BookingDetailsPage.js.map +0 -1
  125. package/dist/labsofscience/pages/customer/CartDetailPage.js +0 -653
  126. package/dist/labsofscience/pages/customer/CartDetailPage.js.map +0 -1
  127. package/dist/labsofscience/pages/customer/CartDiscoveryPage.js +0 -559
  128. package/dist/labsofscience/pages/customer/CartDiscoveryPage.js.map +0 -1
  129. package/dist/labsofscience/pages/customer/CheckoutPage.js +0 -530
  130. package/dist/labsofscience/pages/customer/CheckoutPage.js.map +0 -1
  131. package/dist/labsofscience/pages/customer/CustomerDashboard.js +0 -531
  132. package/dist/labsofscience/pages/customer/CustomerDashboard.js.map +0 -1
  133. package/dist/labsofscience/pages/customer/CustomerProfilePage.js +0 -658
  134. package/dist/labsofscience/pages/customer/CustomerProfilePage.js.map +0 -1
  135. package/dist/labsofscience/pages/customer/DirectServiceBookingPage.js +0 -633
  136. package/dist/labsofscience/pages/customer/DirectServiceBookingPage.js.map +0 -1
  137. package/dist/labsofscience/pages/customer/FavoritesPage.js +0 -484
  138. package/dist/labsofscience/pages/customer/FavoritesPage.js.map +0 -1
  139. package/dist/labsofscience/pages/customer/OrderHistoryPage.js +0 -445
  140. package/dist/labsofscience/pages/customer/OrderHistoryPage.js.map +0 -1
  141. package/dist/labsofscience/pages/customer/OrderTrackingPage.js +0 -425
  142. package/dist/labsofscience/pages/customer/OrderTrackingPage.js.map +0 -1
  143. package/dist/labsofscience/pages/customer/PaymentMethodsPage.js +0 -495
  144. package/dist/labsofscience/pages/customer/PaymentMethodsPage.js.map +0 -1
  145. package/dist/labsofscience/pages/customer/ReviewsPage.js +0 -613
  146. package/dist/labsofscience/pages/customer/ReviewsPage.js.map +0 -1
  147. package/dist/labsofscience/pages/customer/SavedAddressesPage.js +0 -450
  148. package/dist/labsofscience/pages/customer/SavedAddressesPage.js.map +0 -1
  149. package/dist/labsofscience/pages/investor/InvestmentDetailsPage.js +0 -881
  150. package/dist/labsofscience/pages/investor/InvestmentDetailsPage.js.map +0 -1
  151. package/dist/labsofscience/pages/investor/InvestmentOpportunitiesPage.js +0 -946
  152. package/dist/labsofscience/pages/investor/InvestmentOpportunitiesPage.js.map +0 -1
  153. package/dist/labsofscience/pages/investor/InvestorAnalyticsPage.js +0 -687
  154. package/dist/labsofscience/pages/investor/InvestorAnalyticsPage.js.map +0 -1
  155. package/dist/labsofscience/pages/investor/InvestorDashboard.js +0 -455
  156. package/dist/labsofscience/pages/investor/InvestorDashboard.js.map +0 -1
  157. package/dist/labsofscience/pages/investor/InvestorInvestmentsPage.js +0 -406
  158. package/dist/labsofscience/pages/investor/InvestorInvestmentsPage.js.map +0 -1
  159. package/dist/labsofscience/pages/investor/InvestorPortfolioPage.js +0 -575
  160. package/dist/labsofscience/pages/investor/InvestorPortfolioPage.js.map +0 -1
  161. package/dist/labsofscience/pages/investor/InvestorProfilePage.js +0 -1070
  162. package/dist/labsofscience/pages/investor/InvestorProfilePage.js.map +0 -1
  163. package/dist/labsofscience/pages/worker/TaskDetailsPage.js +0 -537
  164. package/dist/labsofscience/pages/worker/TaskDetailsPage.js.map +0 -1
  165. package/dist/labsofscience/pages/worker/WorkerDashboard.js +0 -665
  166. package/dist/labsofscience/pages/worker/WorkerDashboard.js.map +0 -1
  167. package/dist/labsofscience/pages/worker/WorkerOrdersPage.js +0 -681
  168. package/dist/labsofscience/pages/worker/WorkerOrdersPage.js.map +0 -1
  169. package/dist/labsofscience/pages/worker/WorkerProfilePage.js +0 -692
  170. package/dist/labsofscience/pages/worker/WorkerProfilePage.js.map +0 -1
  171. package/dist/labsofscience/pages/worker/WorkerSchedulePage.js +0 -588
  172. package/dist/labsofscience/pages/worker/WorkerSchedulePage.js.map +0 -1
@@ -1,946 +0,0 @@
1
- import { useLabsOfScience as e } from "../../context/LabsOfScienceContext.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, TrendingUp 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/labsofscience/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-subtle text-status-success-text";
229
- case "medium": return "bg-status-warning-bg-subtle text-status-warning-text";
230
- case "high": return "bg-status-error-bg-subtle 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
- actions: /* @__PURE__ */ b("span", {
329
- className: "text-sm text-text-secondary",
330
- children: [H.length, " opportunities"]
331
- }),
332
- children: [
333
- /* @__PURE__ */ y(S, {
334
- icon: /* @__PURE__ */ y(_, { className: "h-4 w-4" }),
335
- className: "mb-6",
336
- children: "Put your money to work in real local carts. Browse vetted businesses raising funds, compare expected returns, funding progress and minimum tickets, then back the ones you believe in — every opportunity here is a chance to earn while helping a neighbourhood vendor grow."
337
- }),
338
- /* @__PURE__ */ b(x, {
339
- className: "grid grid-cols-2 gap-3 sm:gap-4 lg:grid-cols-4",
340
- children: [
341
- /* @__PURE__ */ b("div", {
342
- className: "rounded-lg border border-border-seam bg-bg-surface p-3 sm:p-4",
343
- children: [/* @__PURE__ */ y("p", {
344
- className: "text-xs text-text-secondary",
345
- children: "Active Opportunities"
346
- }), /* @__PURE__ */ y("p", {
347
- className: "text-lg font-bold text-text-primary sm:text-2xl",
348
- children: w.totalOpportunities
349
- })]
350
- }),
351
- /* @__PURE__ */ b("div", {
352
- className: "rounded-lg border border-border-seam bg-bg-surface p-3 sm:p-4",
353
- children: [/* @__PURE__ */ y("p", {
354
- className: "text-xs text-text-secondary",
355
- children: "Average Returns"
356
- }), /* @__PURE__ */ b("p", {
357
- className: "text-lg font-bold text-status-success-text sm:text-2xl",
358
- children: [w.averageReturns, "%"]
359
- })]
360
- }),
361
- /* @__PURE__ */ b("div", {
362
- className: "rounded-lg border border-border-seam bg-bg-surface p-3 sm:p-4",
363
- children: [/* @__PURE__ */ y("p", {
364
- className: "text-xs text-text-secondary",
365
- children: "Total Funded"
366
- }), /* @__PURE__ */ y("p", {
367
- className: "text-lg font-bold text-text-primary sm:text-2xl",
368
- children: i(w.totalFunded, {
369
- minimumFractionDigits: 0,
370
- notation: "compact"
371
- })
372
- })]
373
- }),
374
- /* @__PURE__ */ b("div", {
375
- className: "rounded-lg border border-border-seam bg-bg-surface p-3 sm:p-4",
376
- children: [/* @__PURE__ */ y("p", {
377
- className: "text-xs text-text-secondary",
378
- children: "Success Rate"
379
- }), /* @__PURE__ */ b("p", {
380
- className: "text-lg font-bold text-text-primary sm:text-2xl",
381
- children: [w.successRate, "%"]
382
- })]
383
- })
384
- ]
385
- }),
386
- /* @__PURE__ */ y("div", {
387
- className: "mt-6 rounded-lg border border-border-seam bg-bg-surface p-4 sm:p-6",
388
- children: /* @__PURE__ */ b("div", {
389
- className: "grid grid-cols-1 gap-3 sm:grid-cols-2 lg:grid-cols-3 xl:grid-cols-6",
390
- children: [
391
- /* @__PURE__ */ b("div", {
392
- className: "relative sm:col-span-2 lg:col-span-1",
393
- 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", {
394
- type: "text",
395
- placeholder: "Search opportunities...",
396
- value: z.searchQuery,
397
- onChange: (e) => V("searchQuery", e.target.value),
398
- 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)]"
399
- })]
400
- }),
401
- /* @__PURE__ */ b("select", {
402
- value: z.category,
403
- onChange: (e) => V("category", e.target.value),
404
- 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)]",
405
- children: [
406
- /* @__PURE__ */ y("option", {
407
- value: "",
408
- children: "All Categories"
409
- }),
410
- /* @__PURE__ */ y("option", {
411
- value: "Healthy Food",
412
- children: "Healthy Food"
413
- }),
414
- /* @__PURE__ */ y("option", {
415
- value: "Fast Food",
416
- children: "Fast Food"
417
- }),
418
- /* @__PURE__ */ y("option", {
419
- value: "Fusion Food",
420
- children: "Fusion Food"
421
- }),
422
- /* @__PURE__ */ y("option", {
423
- value: "Beverages",
424
- children: "Beverages"
425
- }),
426
- /* @__PURE__ */ y("option", {
427
- value: "Street Food",
428
- children: "Street Food"
429
- })
430
- ]
431
- }),
432
- /* @__PURE__ */ b("select", {
433
- value: z.riskLevel,
434
- onChange: (e) => V("riskLevel", e.target.value),
435
- 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)]",
436
- children: [
437
- /* @__PURE__ */ y("option", {
438
- value: "",
439
- children: "All Risk Levels"
440
- }),
441
- /* @__PURE__ */ y("option", {
442
- value: "low",
443
- children: "Low Risk"
444
- }),
445
- /* @__PURE__ */ y("option", {
446
- value: "medium",
447
- children: "Medium Risk"
448
- }),
449
- /* @__PURE__ */ y("option", {
450
- value: "high",
451
- children: "High Risk"
452
- })
453
- ]
454
- }),
455
- /* @__PURE__ */ b("select", {
456
- value: z.minimumAmount,
457
- onChange: (e) => V("minimumAmount", e.target.value),
458
- 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)]",
459
- children: [
460
- /* @__PURE__ */ y("option", {
461
- value: "",
462
- children: "Any Amount"
463
- }),
464
- /* @__PURE__ */ y("option", {
465
- value: "15000",
466
- children: "Under ₹15,000"
467
- }),
468
- /* @__PURE__ */ y("option", {
469
- value: "25000",
470
- children: "Under ₹25,000"
471
- }),
472
- /* @__PURE__ */ y("option", {
473
- value: "50000",
474
- children: "Under ₹50,000"
475
- }),
476
- /* @__PURE__ */ y("option", {
477
- value: "100000",
478
- children: "Under ₹1,00,000"
479
- })
480
- ]
481
- }),
482
- /* @__PURE__ */ b("select", {
483
- value: z.location,
484
- onChange: (e) => V("location", e.target.value),
485
- 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)]",
486
- children: [
487
- /* @__PURE__ */ y("option", {
488
- value: "",
489
- children: "All Locations"
490
- }),
491
- /* @__PURE__ */ y("option", {
492
- value: "Whitefield",
493
- children: "Whitefield"
494
- }),
495
- /* @__PURE__ */ y("option", {
496
- value: "Koramangala",
497
- children: "Koramangala"
498
- }),
499
- /* @__PURE__ */ y("option", {
500
- value: "Indiranagar",
501
- children: "Indiranagar"
502
- }),
503
- /* @__PURE__ */ y("option", {
504
- value: "Electronic City",
505
- children: "Electronic City"
506
- })
507
- ]
508
- }),
509
- /* @__PURE__ */ b("select", {
510
- value: z.sortBy,
511
- onChange: (e) => V("sortBy", e.target.value),
512
- 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)]",
513
- children: [
514
- /* @__PURE__ */ y("option", {
515
- value: "featured",
516
- children: "Featured"
517
- }),
518
- /* @__PURE__ */ y("option", {
519
- value: "returns",
520
- children: "Highest Returns"
521
- }),
522
- /* @__PURE__ */ y("option", {
523
- value: "funding",
524
- children: "Most Funded"
525
- }),
526
- /* @__PURE__ */ y("option", {
527
- value: "closing",
528
- children: "Closing Soon"
529
- }),
530
- /* @__PURE__ */ y("option", {
531
- value: "minimum",
532
- children: "Lowest Minimum"
533
- })
534
- ]
535
- })
536
- ]
537
- })
538
- }),
539
- H.length === 0 ? /* @__PURE__ */ y("div", {
540
- className: "mt-6",
541
- children: /* @__PURE__ */ y(r, {
542
- illustration: "empty-search",
543
- icon: /* @__PURE__ */ y(h, { className: "h-10 w-10" }),
544
- title: "No opportunities found",
545
- description: "Try adjusting your filters to find more opportunities",
546
- action: /* @__PURE__ */ y("button", {
547
- type: "button",
548
- onClick: () => B({
549
- searchQuery: "",
550
- category: "",
551
- riskLevel: "",
552
- minimumAmount: "",
553
- location: "",
554
- sortBy: "featured"
555
- }),
556
- 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",
557
- children: "Clear Filters"
558
- })
559
- })
560
- }) : /* @__PURE__ */ y("div", {
561
- className: "mt-6 grid grid-cols-1 gap-4 lg:grid-cols-2",
562
- children: H.map((e) => {
563
- let n = D(e.raisedAmount, e.targetAmount);
564
- return /* @__PURE__ */ b("div", {
565
- className: "rounded-lg border border-border-seam bg-bg-surface shadow-sm hover:shadow-md transition-shadow",
566
- children: [/* @__PURE__ */ b("div", {
567
- className: "relative",
568
- children: [
569
- /* @__PURE__ */ y("div", {
570
- className: "h-40 w-full overflow-hidden rounded-t-lg bg-bg-sunken sm:h-48",
571
- children: /* @__PURE__ */ y("img", {
572
- src: e.image,
573
- alt: e.cartName,
574
- className: "h-full w-full object-cover",
575
- loading: "lazy"
576
- })
577
- }),
578
- e.status === "funded" && /* @__PURE__ */ y("div", {
579
- className: "absolute right-2 top-2 rounded-full bg-status-success-bg px-2 py-1 text-xs font-medium text-white sm:right-4 sm:top-4 sm:px-3",
580
- children: "Fully Funded"
581
- }),
582
- e.daysLeft > 0 && e.daysLeft <= 7 && /* @__PURE__ */ b("div", {
583
- className: "absolute left-2 top-2 rounded-full bg-status-error-bg px-2 py-1 text-xs font-medium text-white sm:left-4 sm:top-4 sm:px-3",
584
- children: [e.daysLeft, " days left"]
585
- })
586
- ]
587
- }), /* @__PURE__ */ b("div", {
588
- className: "p-4 sm:p-6",
589
- children: [
590
- /* @__PURE__ */ b("div", {
591
- className: "mb-4 flex flex-col gap-3 sm:flex-row sm:items-start sm:justify-between",
592
- children: [/* @__PURE__ */ b("div", {
593
- className: "flex-1",
594
- children: [
595
- /* @__PURE__ */ y("h3", {
596
- className: "text-base font-semibold text-text-primary sm:text-xl",
597
- children: e.cartName
598
- }),
599
- /* @__PURE__ */ b("p", {
600
- className: "text-xs text-text-secondary sm:text-sm",
601
- children: ["by ", e.cartOwner]
602
- }),
603
- /* @__PURE__ */ b("div", {
604
- className: "mt-2 flex flex-wrap items-center gap-2",
605
- children: [/* @__PURE__ */ y("span", {
606
- className: "text-xs text-text-secondary sm:text-sm",
607
- children: e.category
608
- }), /* @__PURE__ */ y("span", {
609
- className: t("rounded-full px-2 py-0.5 text-xs font-medium", T(e.riskLevel)),
610
- children: E(e.riskLevel)
611
- })]
612
- })
613
- ]
614
- }), /* @__PURE__ */ b("div", {
615
- className: "text-left sm:text-right",
616
- children: [/* @__PURE__ */ b("p", {
617
- className: "text-xl font-bold text-status-success-text sm:text-2xl",
618
- children: [e.expectedReturns, "%"]
619
- }), /* @__PURE__ */ y("p", {
620
- className: "text-xs text-text-secondary",
621
- children: "Expected Returns"
622
- })]
623
- })]
624
- }),
625
- /* @__PURE__ */ y("p", {
626
- className: "mb-4 text-sm leading-relaxed text-text-secondary line-clamp-2",
627
- children: e.description
628
- }),
629
- /* @__PURE__ */ b("div", {
630
- className: "mb-4",
631
- children: [
632
- /* @__PURE__ */ b("div", {
633
- className: "mb-1 flex justify-between text-xs sm:text-sm",
634
- children: [/* @__PURE__ */ b("span", {
635
- className: "font-medium text-text-primary",
636
- children: [
637
- i(e.raisedAmount, { minimumFractionDigits: 0 }),
638
- " ",
639
- "raised"
640
- ]
641
- }), /* @__PURE__ */ b("span", {
642
- className: "text-text-secondary",
643
- children: ["of ", i(e.targetAmount, { minimumFractionDigits: 0 })]
644
- })]
645
- }),
646
- /* @__PURE__ */ y("div", {
647
- className: "h-2 w-full overflow-hidden rounded-full bg-bg-sunken",
648
- children: /* @__PURE__ */ y("div", {
649
- className: "h-full rounded-full bg-action-primary-bg transition-all duration-300",
650
- style: { width: `${n}%` }
651
- })
652
- }),
653
- /* @__PURE__ */ b("div", {
654
- className: "mt-1 flex justify-between text-xs text-text-secondary",
655
- children: [/* @__PURE__ */ b("span", { children: [e.investorCount, " investors"] }), /* @__PURE__ */ b("span", { children: [n.toFixed(0), "% funded"] })]
656
- })
657
- ]
658
- }),
659
- /* @__PURE__ */ b("div", {
660
- className: "mb-4 grid grid-cols-3 gap-2 text-center sm:gap-4",
661
- children: [
662
- /* @__PURE__ */ b("div", { children: [/* @__PURE__ */ y("p", {
663
- className: "text-sm font-bold text-text-primary sm:text-lg",
664
- children: i(e.minimumInvestment, { minimumFractionDigits: 0 })
665
- }), /* @__PURE__ */ y("p", {
666
- className: "text-xs text-text-secondary",
667
- children: "Min Investment"
668
- })] }),
669
- /* @__PURE__ */ b("div", { children: [/* @__PURE__ */ b("p", {
670
- className: "text-sm font-bold text-text-primary sm:text-lg",
671
- children: [e.paybackPeriod, " mo"]
672
- }), /* @__PURE__ */ y("p", {
673
- className: "text-xs text-text-secondary",
674
- children: "Payback Period"
675
- })] }),
676
- /* @__PURE__ */ b("div", { children: [/* @__PURE__ */ b("div", {
677
- className: "flex items-center justify-center gap-1",
678
- children: [/* @__PURE__ */ y(g, { className: "h-3.5 w-3.5 fill-status-warning-text text-status-warning-text" }), /* @__PURE__ */ y("p", {
679
- className: "text-sm font-bold text-text-primary sm:text-lg",
680
- children: e.businessMetrics.rating
681
- })]
682
- }), /* @__PURE__ */ y("p", {
683
- className: "text-xs text-text-secondary",
684
- children: "Rating"
685
- })] })
686
- ]
687
- }),
688
- /* @__PURE__ */ b("div", {
689
- className: "mb-4 border-t border-border-seam pt-3 sm:pt-4",
690
- children: [/* @__PURE__ */ y("p", {
691
- className: "mb-2 text-xs font-medium text-text-secondary sm:text-sm",
692
- children: "Business Performance"
693
- }), /* @__PURE__ */ b("div", {
694
- className: "grid grid-cols-1 gap-2 text-xs sm:grid-cols-2 sm:text-sm",
695
- children: [
696
- /* @__PURE__ */ b("div", {
697
- className: "flex justify-between",
698
- children: [/* @__PURE__ */ y("span", {
699
- className: "text-text-secondary",
700
- children: "Monthly Revenue:"
701
- }), /* @__PURE__ */ y("span", {
702
- className: "font-medium text-text-primary",
703
- children: i(e.businessMetrics.monthlyRevenue, { minimumFractionDigits: 0 })
704
- })]
705
- }),
706
- /* @__PURE__ */ b("div", {
707
- className: "flex justify-between",
708
- children: [/* @__PURE__ */ y("span", {
709
- className: "text-text-secondary",
710
- children: "Gross Margin:"
711
- }), /* @__PURE__ */ b("span", {
712
- className: "font-medium text-text-primary",
713
- children: [e.financials.grossMargin, "%"]
714
- })]
715
- }),
716
- /* @__PURE__ */ b("div", {
717
- className: "flex justify-between",
718
- children: [/* @__PURE__ */ y("span", {
719
- className: "text-text-secondary",
720
- children: "Monthly Orders:"
721
- }), /* @__PURE__ */ y("span", {
722
- className: "font-medium text-text-primary",
723
- children: a(e.businessMetrics.monthlyOrders)
724
- })]
725
- }),
726
- /* @__PURE__ */ b("div", {
727
- className: "flex justify-between",
728
- children: [/* @__PURE__ */ y("span", {
729
- className: "text-text-secondary",
730
- children: "Net Margin:"
731
- }), /* @__PURE__ */ b("span", {
732
- className: "font-medium text-text-primary",
733
- children: [e.financials.netMargin, "%"]
734
- })]
735
- })
736
- ]
737
- })]
738
- }),
739
- /* @__PURE__ */ y("div", {
740
- className: "mb-4 border-t border-border-seam pt-3",
741
- children: /* @__PURE__ */ b("div", {
742
- className: "flex items-center gap-1.5 text-xs text-text-secondary",
743
- children: [/* @__PURE__ */ y(f, { className: "h-3.5 w-3.5" }), /* @__PURE__ */ b("span", { children: [e.documents.length, " documents available"] })]
744
- })
745
- }),
746
- /* @__PURE__ */ b("div", {
747
- className: "mb-4 flex items-center gap-1.5 text-xs text-text-secondary",
748
- children: [/* @__PURE__ */ y(m, { className: "h-3.5 w-3.5" }), /* @__PURE__ */ y("span", { children: e.location })]
749
- }),
750
- /* @__PURE__ */ b("div", {
751
- className: "flex flex-col gap-2 sm:flex-row sm:gap-3",
752
- children: [/* @__PURE__ */ y("button", {
753
- type: "button",
754
- onClick: () => W(e),
755
- disabled: e.status === "funded",
756
- 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"),
757
- children: e.status === "funded" ? "Fully Funded" : "Invest Now"
758
- }), /* @__PURE__ */ b("button", {
759
- type: "button",
760
- onClick: () => O(`/investor/opportunities/${e.id}`),
761
- 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",
762
- children: [/* @__PURE__ */ y(d, { className: "h-4 w-4" }), "View Details"]
763
- })]
764
- })
765
- ]
766
- })]
767
- }, e.id);
768
- })
769
- }),
770
- N && j && /* @__PURE__ */ y("div", {
771
- className: "fixed inset-0 z-50 flex items-center justify-center bg-black/50 p-4",
772
- children: /* @__PURE__ */ b("div", {
773
- 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",
774
- children: [
775
- /* @__PURE__ */ y("button", {
776
- type: "button",
777
- onClick: () => {
778
- P(!1), I(""), R("idle");
779
- },
780
- className: "absolute right-3 top-3 rounded-lg p-1 text-text-secondary hover:bg-accent transition-colors",
781
- children: /* @__PURE__ */ y(v, { className: "h-5 w-5" })
782
- }),
783
- /* @__PURE__ */ b("h3", {
784
- className: "mb-4 text-base font-semibold text-text-primary sm:text-lg",
785
- children: ["Invest in ", j.cartName]
786
- }),
787
- L === "success" ? /* @__PURE__ */ b("div", {
788
- className: "py-8 text-center",
789
- children: [
790
- /* @__PURE__ */ y(u, { className: "mx-auto mb-3 h-12 w-12 text-status-success-text" }),
791
- /* @__PURE__ */ y("p", {
792
- className: "text-sm font-medium text-text-primary",
793
- children: "Investment successful!"
794
- }),
795
- /* @__PURE__ */ y("p", {
796
- className: "mt-1 text-xs text-text-secondary",
797
- children: "Redirecting to your portfolio..."
798
- })
799
- ]
800
- }) : /* @__PURE__ */ b("div", {
801
- className: "space-y-4",
802
- children: [
803
- /* @__PURE__ */ b("div", { children: [/* @__PURE__ */ y("p", {
804
- className: "mb-1 text-xs text-text-secondary sm:text-sm",
805
- children: "Investment Range"
806
- }), /* @__PURE__ */ b("p", {
807
- className: "text-sm font-medium text-text-primary sm:text-base",
808
- children: [
809
- i(j.minimumInvestment, { minimumFractionDigits: 0 }),
810
- " ",
811
- "-",
812
- " ",
813
- i(j.maximumInvestment, { minimumFractionDigits: 0 })
814
- ]
815
- })] }),
816
- /* @__PURE__ */ b("div", { children: [
817
- /* @__PURE__ */ y("label", {
818
- className: "mb-1 block text-xs font-medium text-text-primary sm:text-sm",
819
- children: "Investment Amount"
820
- }),
821
- /* @__PURE__ */ b("div", {
822
- className: "relative",
823
- 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", {
824
- type: "number",
825
- value: F,
826
- onChange: (e) => {
827
- I(e.target.value), R("idle");
828
- },
829
- placeholder: "Enter amount",
830
- 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)]"
831
- })]
832
- }),
833
- L === "error" && /* @__PURE__ */ b("p", {
834
- className: "mt-1 text-xs text-status-error-text",
835
- children: [
836
- "Amount must be between",
837
- " ",
838
- i(j.minimumInvestment, { minimumFractionDigits: 0 }),
839
- " ",
840
- "and",
841
- " ",
842
- i(j.maximumInvestment, { minimumFractionDigits: 0 })
843
- ]
844
- })
845
- ] }),
846
- F && !isNaN(parseInt(F, 10)) && parseInt(F, 10) > 0 && /* @__PURE__ */ b("div", {
847
- className: "rounded-lg border border-border-seam bg-bg-sunken/50 p-3 sm:p-4",
848
- children: [/* @__PURE__ */ y("p", {
849
- className: "mb-2 text-xs text-text-secondary sm:text-sm",
850
- children: "Expected Returns"
851
- }), /* @__PURE__ */ b("div", {
852
- className: "space-y-1.5",
853
- children: [
854
- /* @__PURE__ */ b("div", {
855
- className: "flex justify-between",
856
- children: [/* @__PURE__ */ y("span", {
857
- className: "text-xs text-text-primary sm:text-sm",
858
- children: "Investment:"
859
- }), /* @__PURE__ */ y("span", {
860
- className: "text-xs font-medium text-text-primary sm:text-sm",
861
- children: i(parseInt(F, 10), { minimumFractionDigits: 0 })
862
- })]
863
- }),
864
- /* @__PURE__ */ b("div", {
865
- className: "flex justify-between",
866
- children: [/* @__PURE__ */ b("span", {
867
- className: "text-xs text-text-primary sm:text-sm",
868
- children: [
869
- "Expected Return (",
870
- j.expectedReturns,
871
- "%):"
872
- ]
873
- }), /* @__PURE__ */ b("span", {
874
- className: "text-xs font-medium text-status-success-text sm:text-sm",
875
- children: ["+", i(parseInt(F, 10) * j.expectedReturns / 100, { minimumFractionDigits: 0 })]
876
- })]
877
- }),
878
- /* @__PURE__ */ b("div", {
879
- className: "flex justify-between border-t border-border-seam pt-2",
880
- children: [/* @__PURE__ */ y("span", {
881
- className: "text-xs font-medium text-text-primary sm:text-sm",
882
- children: "Total Value:"
883
- }), /* @__PURE__ */ y("span", {
884
- className: "text-xs font-bold text-text-primary sm:text-sm",
885
- children: i(parseInt(F, 10) * (1 + j.expectedReturns / 100), { minimumFractionDigits: 0 })
886
- })]
887
- })
888
- ]
889
- })]
890
- }),
891
- /* @__PURE__ */ b("div", {
892
- className: "space-y-1 text-xs text-text-secondary sm:text-sm",
893
- children: [
894
- /* @__PURE__ */ b("p", { children: [
895
- "• Minimum lock-in period:",
896
- " ",
897
- j.investmentTerms.lockInPeriod,
898
- " months"
899
- ] }),
900
- /* @__PURE__ */ b("p", { children: [
901
- "• Dividend frequency:",
902
- " ",
903
- j.investmentTerms.dividendFrequency
904
- ] }),
905
- /* @__PURE__ */ b("p", { children: [
906
- "• Your equity stake:",
907
- " ",
908
- ((parseInt(F, 10) || 0) / j.targetAmount * j.investmentTerms.equityOffered).toFixed(2),
909
- "%"
910
- ] }),
911
- /* @__PURE__ */ b("p", { children: [
912
- "• Exit options:",
913
- " ",
914
- j.investmentTerms.exitOptions.join(", ")
915
- ] })
916
- ]
917
- }),
918
- /* @__PURE__ */ b("div", {
919
- className: "flex flex-col gap-2 pt-2 sm:flex-row sm:gap-3",
920
- children: [/* @__PURE__ */ y("button", {
921
- type: "button",
922
- onClick: () => {
923
- P(!1), I(""), R("idle");
924
- },
925
- 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",
926
- children: "Cancel"
927
- }), /* @__PURE__ */ y("button", {
928
- type: "button",
929
- onClick: U,
930
- disabled: !F || isNaN(parseInt(F, 10)) || parseInt(F, 10) < j.minimumInvestment,
931
- 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"),
932
- children: "Confirm Investment"
933
- })]
934
- })
935
- ]
936
- })
937
- ]
938
- })
939
- })
940
- ]
941
- });
942
- }
943
- //#endregion
944
- export { O as InvestmentOpportunitiesPage };
945
-
946
- //# sourceMappingURL=InvestmentOpportunitiesPage.js.map