@retinalabsllc/zairusjs 21.2.3 → 21.2.8
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.d.mts +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +97 -92
- package/dist/index.mjs +65 -54
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -1359,6 +1359,7 @@ interface UniversalSettings2Props {
|
|
|
1359
1359
|
declare const UniversalSettings2: React.FC<UniversalSettings2Props>;
|
|
1360
1360
|
|
|
1361
1361
|
interface UniversalDeveloperSettingsProps {
|
|
1362
|
+
onBackHref?: string;
|
|
1362
1363
|
initialPublicKey: string;
|
|
1363
1364
|
initialWebhookUrl: string;
|
|
1364
1365
|
isReadOnly?: boolean;
|
package/dist/index.d.ts
CHANGED
|
@@ -1359,6 +1359,7 @@ interface UniversalSettings2Props {
|
|
|
1359
1359
|
declare const UniversalSettings2: React.FC<UniversalSettings2Props>;
|
|
1360
1360
|
|
|
1361
1361
|
interface UniversalDeveloperSettingsProps {
|
|
1362
|
+
onBackHref?: string;
|
|
1362
1363
|
initialPublicKey: string;
|
|
1363
1364
|
initialWebhookUrl: string;
|
|
1364
1365
|
isReadOnly?: boolean;
|
package/dist/index.js
CHANGED
|
@@ -4744,7 +4744,7 @@ var CircularLogo = ({ src, alt, fallbackText }) => {
|
|
|
4744
4744
|
onError: () => setHasError(true),
|
|
4745
4745
|
className: `w-full h-full object-cover transition-opacity duration-300 ${isLoaded ? "opacity-100" : "opacity-0"}`
|
|
4746
4746
|
}
|
|
4747
|
-
)) : /* @__PURE__ */ import_react81.default.createElement("span", { className: "text-xs text-black
|
|
4747
|
+
)) : /* @__PURE__ */ import_react81.default.createElement("span", { className: "text-xs text-black " }, fallbackText.substring(0, 2)));
|
|
4748
4748
|
};
|
|
4749
4749
|
var DEFAULT_NETWORK_REGEX = {
|
|
4750
4750
|
EVM: /^0x[a-fA-F0-9]{40}$/,
|
|
@@ -6278,7 +6278,7 @@ var HomeHuddleCalendar = ({
|
|
|
6278
6278
|
className: "w-8 h-8 flex items-center justify-center rounded-full border border-stone-200 hover:bg-stone-100 outline-none transition-colors"
|
|
6279
6279
|
},
|
|
6280
6280
|
/* @__PURE__ */ import_react93.default.createElement(import_react94.HugeiconsIcon, { icon: import_core_free_icons36.ArrowRight01Icon, size: 16, className: "text-black" })
|
|
6281
|
-
))), /* @__PURE__ */ import_react93.default.createElement("div", { className: "grid grid-cols-7 gap-y-2 gap-x-1" }, DAYS_OF_WEEK2.map((d) => /* @__PURE__ */ import_react93.default.createElement("div", { key: d, className: "text-center text-[11px] text-stone-400 py-2
|
|
6281
|
+
))), /* @__PURE__ */ import_react93.default.createElement("div", { className: "grid grid-cols-7 gap-y-2 gap-x-1" }, DAYS_OF_WEEK2.map((d) => /* @__PURE__ */ import_react93.default.createElement("div", { key: d, className: "text-center text-[11px] text-stone-400 py-2 tracking-widest" }, d)), Array.from({ length: firstDayOffset }).map((_, i) => /* @__PURE__ */ import_react93.default.createElement("div", { key: `empty-${i}` })), Array.from({ length: daysInMonth }).map((_, i) => {
|
|
6282
6282
|
const day = i + 1;
|
|
6283
6283
|
const thisDate = new Date(viewYear, viewMonth, day);
|
|
6284
6284
|
const isSelected = selectedDate.getFullYear() === viewYear && selectedDate.getMonth() === viewMonth && selectedDate.getDate() === day;
|
|
@@ -6300,7 +6300,7 @@ var HomeHuddleCalendar = ({
|
|
|
6300
6300
|
dayEventsCount
|
|
6301
6301
|
)
|
|
6302
6302
|
));
|
|
6303
|
-
}))), /* @__PURE__ */ import_react93.default.createElement("div", { className: "flex flex-col gap-4 bg-white rounded-2xl p-6 relative min-h-37.5" }, /* @__PURE__ */ import_react93.default.createElement("div", { className: "flex items-center justify-between pb-4" }, /* @__PURE__ */ import_react93.default.createElement("h3", { className: "text-sm text-black " }, isSearching ? "Search Results" : `Events for ${selectedDate.toLocaleDateString("en-GB", { day: "numeric", month: "short", year: "numeric" })}`), /* @__PURE__ */ import_react93.default.createElement("span", { className: "text-[10px]
|
|
6303
|
+
}))), /* @__PURE__ */ import_react93.default.createElement("div", { className: "flex flex-col gap-4 bg-white rounded-2xl p-6 relative min-h-37.5" }, /* @__PURE__ */ import_react93.default.createElement("div", { className: "flex items-center justify-between pb-4" }, /* @__PURE__ */ import_react93.default.createElement("h3", { className: "text-sm text-black " }, isSearching ? "Search Results" : `Events for ${selectedDate.toLocaleDateString("en-GB", { day: "numeric", month: "short", year: "numeric" })}`), /* @__PURE__ */ import_react93.default.createElement("span", { className: "text-[10px] tracking-widest text-stone-400 " }, displayedEvents.length, " ", displayedEvents.length === 1 ? "Session" : "Sessions")), /* @__PURE__ */ import_react93.default.createElement("div", { className: "flex flex-col min-w-0 pt-2" }, isLoading ? /* @__PURE__ */ import_react93.default.createElement("div", { className: "py-8 flex flex-col items-center justify-center text-center" }, /* @__PURE__ */ import_react93.default.createElement(import_react94.HugeiconsIcon, { icon: import_core_free_icons36.Loading03Icon, size: 28, className: "animate-spin text-stone-400" })) : displayedEvents.length === 0 ? /* @__PURE__ */ import_react93.default.createElement("div", { className: "py-8 flex flex-col items-center justify-center text-center" }, /* @__PURE__ */ import_react93.default.createElement("p", { className: "text-xs text-stone-400" }, isSearching ? "No sessions found for this search." : "No sessions scheduled for this date.")) : displayedEvents.map((huddle) => /* @__PURE__ */ import_react93.default.createElement(
|
|
6304
6304
|
"div",
|
|
6305
6305
|
{
|
|
6306
6306
|
key: huddle.id,
|
|
@@ -6310,7 +6310,7 @@ var HomeHuddleCalendar = ({
|
|
|
6310
6310
|
/* @__PURE__ */ import_react93.default.createElement(HuddleAvatar2, { timeString: huddle.timeString, status: huddle.status }),
|
|
6311
6311
|
/* @__PURE__ */ import_react93.default.createElement("div", { className: "flex flex-col min-w-0 flex-1" }, /* @__PURE__ */ import_react93.default.createElement("p", { className: "text-sm text-black tracking-tight truncate" }, huddle.name), /* @__PURE__ */ import_react93.default.createElement("span", { className: "text-[11px] text-stone-500 truncate block mt-1 tracking-wide" }, isSearching ? huddle.timeString : huddle.timeString.split("|")[1]?.trim() || huddle.timeString)),
|
|
6312
6312
|
/* @__PURE__ */ import_react93.default.createElement(import_react94.HugeiconsIcon, { icon: import_core_free_icons36.ArrowRight01Icon, size: 14, className: "shrink-0 text-stone-400 group-hover:text-black transition-colors" })
|
|
6313
|
-
)))), huddles.length > 0 && !isLoading && /* @__PURE__ */ import_react93.default.createElement("div", { className: "flex items-center justify-between pt-6 mt-4 mb-2" }, /* @__PURE__ */ import_react93.default.createElement("span", { className: "text-[10px] text-stone-400 tracking-widest
|
|
6313
|
+
)))), huddles.length > 0 && !isLoading && /* @__PURE__ */ import_react93.default.createElement("div", { className: "flex items-center justify-between pt-6 mt-4 mb-2" }, /* @__PURE__ */ import_react93.default.createElement("span", { className: "text-[10px] text-stone-400 tracking-widest " }, "Page ", currentPage, " of ", totalPages === 0 ? 1 : totalPages), /* @__PURE__ */ import_react93.default.createElement("div", { className: "flex items-center gap-2" }, /* @__PURE__ */ import_react93.default.createElement(
|
|
6314
6314
|
"button",
|
|
6315
6315
|
{
|
|
6316
6316
|
onClick: () => onPageChange(currentPage - 1),
|
|
@@ -6348,7 +6348,7 @@ var formatType = (type) => {
|
|
|
6348
6348
|
return type.split("_").map((word) => word.charAt(0).toUpperCase() + word.slice(1).toLowerCase()).join(" ");
|
|
6349
6349
|
};
|
|
6350
6350
|
var ApplicationIcon = ({ icon, sizeClass = "w-10 h-10" }) => {
|
|
6351
|
-
return /* @__PURE__ */ import_react95.default.createElement("div", { className: `relative shrink-0 aspect-square ${sizeClass}` }, /* @__PURE__ */ import_react95.default.createElement("div", { className: "w-full h-full aspect-square rounded-lg bg-neutral-50 flex items-center justify-center overflow-hidden" }, icon ? /* @__PURE__ */ import_react95.default.createElement(import_react96.HugeiconsIcon, { icon, size:
|
|
6351
|
+
return /* @__PURE__ */ import_react95.default.createElement("div", { className: `relative shrink-0 aspect-square ${sizeClass}` }, /* @__PURE__ */ import_react95.default.createElement("div", { className: "w-full h-full aspect-square rounded-lg bg-neutral-50 flex items-center justify-center overflow-hidden" }, icon ? /* @__PURE__ */ import_react95.default.createElement(import_react96.HugeiconsIcon, { icon, size: 18, className: "text-stone-500" }) : /* @__PURE__ */ import_react95.default.createElement("div", { className: "w-4 h-4 rounded-sm bg-stone-300" })));
|
|
6352
6352
|
};
|
|
6353
6353
|
var PageSpinner9 = () => /* @__PURE__ */ import_react95.default.createElement("div", { className: "flex justify-center items-center py-12" }, /* @__PURE__ */ import_react95.default.createElement(import_react96.HugeiconsIcon, { icon: import_core_free_icons37.Loading03Icon, size: 32, className: "animate-spin mb-4 text-black" }));
|
|
6354
6354
|
var UniversalApplicationsPage = ({
|
|
@@ -6374,7 +6374,7 @@ var UniversalApplicationsPage = ({
|
|
|
6374
6374
|
{
|
|
6375
6375
|
key: app.id,
|
|
6376
6376
|
onClick: () => onApplicationClick(app.id),
|
|
6377
|
-
className: "flex flex-row items-center gap-4 py-2 hover:bg-stone-50 transition-colors cursor-pointer group min-w-0 px-3 -mx-3 rounded-
|
|
6377
|
+
className: "flex flex-row items-center gap-4 py-2 hover:bg-stone-50 transition-colors cursor-pointer group min-w-0 px-3 -mx-3 rounded-full"
|
|
6378
6378
|
},
|
|
6379
6379
|
/* @__PURE__ */ import_react95.default.createElement(ApplicationIcon, { icon: app.icon }),
|
|
6380
6380
|
/* @__PURE__ */ import_react95.default.createElement("div", { className: "flex flex-col min-w-0 flex-1" }, /* @__PURE__ */ import_react95.default.createElement("p", { className: "text-sm text-black tracking-tight truncate" }, app.name || "Unnamed Application"), /* @__PURE__ */ import_react95.default.createElement("span", { className: "text-xs text-stone-500 truncate block mt-0.5" }, formatType(app.type), " ", /* @__PURE__ */ import_react95.default.createElement("span", { className: "mx-1 text-stone-300" }, "|"), " ", app.timeString)),
|
|
@@ -6678,8 +6678,9 @@ function RootSidebar({
|
|
|
6678
6678
|
"button",
|
|
6679
6679
|
{
|
|
6680
6680
|
onClick: () => setIsSheetOpen(true),
|
|
6681
|
-
className: "md:hidden fixed bottom-6 left-1/2 -translate-x-1/2 z-40 bg-black text-white px-8 py-
|
|
6681
|
+
className: "md:hidden fixed bottom-6 left-1/2 -translate-x-1/2 z-40 bg-black text-white px-8 py-2 rounded-full shadow-xl flex items-center justify-center gap-2 text-xs tracking-wide outline-none active:scale-95 transition-transform"
|
|
6682
6682
|
},
|
|
6683
|
+
/* @__PURE__ */ import_react99.default.createElement(import_react100.HugeiconsIcon, { icon: import_core_free_icons39.MenuCircleIcon, size: 14 }),
|
|
6683
6684
|
"Open Menu"
|
|
6684
6685
|
), /* @__PURE__ */ import_react99.default.createElement(
|
|
6685
6686
|
"div",
|
|
@@ -6705,29 +6706,29 @@ function RootSidebar({
|
|
|
6705
6706
|
if (onNavClick) onNavClick(e, item.path);
|
|
6706
6707
|
setIsSheetOpen(false);
|
|
6707
6708
|
},
|
|
6708
|
-
className: `flex items-center gap-4 px-5 py-
|
|
6709
|
+
className: `flex items-center gap-4 px-5 py-3 rounded-full transition-colors outline-none ${isCurrentRoute ? "bg-[#fff5f2] text-[#d97757]" : "text-stone-600 hover:bg-stone-50"}`
|
|
6709
6710
|
},
|
|
6710
6711
|
/* @__PURE__ */ import_react99.default.createElement(
|
|
6711
6712
|
import_react100.HugeiconsIcon,
|
|
6712
6713
|
{
|
|
6713
6714
|
icon: item.icon,
|
|
6714
|
-
size:
|
|
6715
|
+
size: 18,
|
|
6715
6716
|
className: isCurrentRoute ? "text-[#d97757]" : "text-stone-400"
|
|
6716
6717
|
}
|
|
6717
6718
|
),
|
|
6718
|
-
/* @__PURE__ */ import_react99.default.createElement("span", { className: "text-
|
|
6719
|
+
/* @__PURE__ */ import_react99.default.createElement("span", { className: "text-xs tracking-wide" }, item.name)
|
|
6719
6720
|
);
|
|
6720
|
-
}), showLogoutAction && /* @__PURE__ */ import_react99.default.createElement("div",
|
|
6721
|
+
}), showLogoutAction && /* @__PURE__ */ import_react99.default.createElement("div", null, /* @__PURE__ */ import_react99.default.createElement(
|
|
6721
6722
|
"button",
|
|
6722
6723
|
{
|
|
6723
6724
|
onClick: () => {
|
|
6724
6725
|
setIsSheetOpen(false);
|
|
6725
6726
|
setShowLogoutDialog(true);
|
|
6726
6727
|
},
|
|
6727
|
-
className: "w-full flex items-center gap-4 px-5 py-
|
|
6728
|
+
className: "w-full flex items-center gap-4 px-5 py-3 rounded-full transition-colors outline-none text-red-600 hover:bg-red-50"
|
|
6728
6729
|
},
|
|
6729
|
-
/* @__PURE__ */ import_react99.default.createElement(import_react100.HugeiconsIcon, { icon: import_core_free_icons39.LogoutCircle02Icon, size:
|
|
6730
|
-
/* @__PURE__ */ import_react99.default.createElement("span", { className: "text-
|
|
6730
|
+
/* @__PURE__ */ import_react99.default.createElement(import_react100.HugeiconsIcon, { icon: import_core_free_icons39.LogoutCircle02Icon, size: 18, className: "text-red-500" }),
|
|
6731
|
+
/* @__PURE__ */ import_react99.default.createElement("span", { className: "text-xs tracking-wide" }, "Log Out")
|
|
6731
6732
|
)))
|
|
6732
6733
|
), showLogoutAction && /* @__PURE__ */ import_react99.default.createElement(
|
|
6733
6734
|
ConfirmationDialog,
|
|
@@ -7123,8 +7124,11 @@ var UniversalSettings2 = ({
|
|
|
7123
7124
|
|
|
7124
7125
|
// src/components/UniversalDeveloperSettings.tsx
|
|
7125
7126
|
var import_react103 = __toESM(require("react"));
|
|
7126
|
-
var import_react_hot_toast20 = require("react-hot-toast");
|
|
7127
|
+
var import_react_hot_toast20 = __toESM(require("react-hot-toast"));
|
|
7128
|
+
var import_react104 = require("@hugeicons/react");
|
|
7129
|
+
var import_core_free_icons41 = require("@hugeicons/core-free-icons");
|
|
7127
7130
|
var UniversalDeveloperSettings = ({
|
|
7131
|
+
onBackHref = "/app",
|
|
7128
7132
|
initialPublicKey,
|
|
7129
7133
|
initialWebhookUrl,
|
|
7130
7134
|
isReadOnly = false,
|
|
@@ -7165,13 +7169,13 @@ AUDDITUR_SECRET_KEY="${secKey}"
|
|
|
7165
7169
|
if (res.success && res.data) {
|
|
7166
7170
|
setPublicKey(res.data.publicKey);
|
|
7167
7171
|
downloadEnvironmentFile(res.data.publicKey, res.data.secretKey);
|
|
7168
|
-
import_react_hot_toast20.
|
|
7172
|
+
import_react_hot_toast20.default.success("Keys generated. Check your downloads folder.");
|
|
7169
7173
|
setIsRollModalOpen(false);
|
|
7170
7174
|
} else {
|
|
7171
|
-
import_react_hot_toast20.
|
|
7175
|
+
import_react_hot_toast20.default.error(res.error || "Uh oh! Something went wrong.");
|
|
7172
7176
|
}
|
|
7173
7177
|
} catch (error) {
|
|
7174
|
-
import_react_hot_toast20.
|
|
7178
|
+
import_react_hot_toast20.default.error("Uh oh! Something went wrong.");
|
|
7175
7179
|
} finally {
|
|
7176
7180
|
setIsGenerating(false);
|
|
7177
7181
|
}
|
|
@@ -7184,40 +7188,41 @@ AUDDITUR_SECRET_KEY="${secKey}"
|
|
|
7184
7188
|
const res = await onSaveWebhook(webhookUrl);
|
|
7185
7189
|
if (res.success && res.data) {
|
|
7186
7190
|
setWebhookUrl(res.data.webhookUrl || "");
|
|
7187
|
-
import_react_hot_toast20.
|
|
7191
|
+
import_react_hot_toast20.default.success("Webhook URL updated.");
|
|
7188
7192
|
} else {
|
|
7189
|
-
import_react_hot_toast20.
|
|
7193
|
+
import_react_hot_toast20.default.error(res.error || "Uh oh! Something went wrong.");
|
|
7190
7194
|
}
|
|
7191
7195
|
} catch (error) {
|
|
7192
|
-
import_react_hot_toast20.
|
|
7196
|
+
import_react_hot_toast20.default.error("Uh oh! Something went wrong.");
|
|
7193
7197
|
} finally {
|
|
7194
7198
|
setIsSavingWebhook(false);
|
|
7195
7199
|
}
|
|
7196
7200
|
};
|
|
7197
7201
|
const hasWebhookChanges = webhookUrl !== initialWebhookUrl;
|
|
7198
7202
|
const isWebhookSaveDisabled = isSavingWebhook || isReadOnly || !hasWebhookChanges;
|
|
7199
|
-
return /* @__PURE__ */ import_react103.default.createElement("div", { className: "
|
|
7203
|
+
return /* @__PURE__ */ import_react103.default.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react103.default.createElement(ManagedToaster, null), /* @__PURE__ */ import_react103.default.createElement("div", { className: "mb-6 flex w-full items-center px-1" }, /* @__PURE__ */ import_react103.default.createElement("a", { href: onBackHref, className: "flex items-center gap-2 text-[#d97757] hover:text-[#d97757] transition-colors text-sm outline-none" }, /* @__PURE__ */ import_react103.default.createElement(import_react104.HugeiconsIcon, { icon: import_core_free_icons41.ArrowLeft01Icon, size: 16 }), " Back")), /* @__PURE__ */ import_react103.default.createElement("div", { className: "flex flex-col gap-1 mb-6 px-1" }, /* @__PURE__ */ import_react103.default.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Developer Settings"), /* @__PURE__ */ import_react103.default.createElement("p", { className: "text-xs text-stone-500" }, "Manage your API credentials and webhook integrations.")), /* @__PURE__ */ import_react103.default.createElement("div", { className: "flex flex-col gap-8 animate-in rounded-2xl p-6 bg-white fade-in duration-300" }, isReadOnly && /* @__PURE__ */ import_react103.default.createElement("div", { className: "flex items-start gap-3 p-4 bg-stone-50 rounded-xl" }, /* @__PURE__ */ import_react103.default.createElement(import_react104.HugeiconsIcon, { icon: import_core_free_icons41.CircleLock02Icon, size: 20, className: "text-stone-500 shrink-0 mt-0.5" }), /* @__PURE__ */ import_react103.default.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ import_react103.default.createElement("span", { className: "text-sm text-black tracking-tight" }, "Access Restricted"), /* @__PURE__ */ import_react103.default.createElement("span", { className: "text-xs text-stone-500 mt-1 leading-relaxed" }, "You lack clearance to modify developer settings. Only Owners, Admins, or Managers can roll keys or update webhooks."))), /* @__PURE__ */ import_react103.default.createElement("div", { className: "flex flex-col gap-8" }, /* @__PURE__ */ import_react103.default.createElement("div", { className: "flex flex-col gap-6" }, /* @__PURE__ */ import_react103.default.createElement("div", { className: "w-full" }, /* @__PURE__ */ import_react103.default.createElement("div", { className: "relative w-full" }, /* @__PURE__ */ import_react103.default.createElement(
|
|
7200
7204
|
TextInput,
|
|
7201
7205
|
{
|
|
7202
7206
|
label: "Public Key",
|
|
7203
7207
|
value: publicKey || "No key generated yet",
|
|
7204
7208
|
onChange: () => {
|
|
7205
7209
|
},
|
|
7206
|
-
disabled: true
|
|
7210
|
+
disabled: true,
|
|
7211
|
+
placeholder: "pk_live_..."
|
|
7207
7212
|
}
|
|
7208
|
-
),
|
|
7209
|
-
|
|
7213
|
+
), !isReadOnly && /* @__PURE__ */ import_react103.default.createElement(
|
|
7214
|
+
"button",
|
|
7210
7215
|
{
|
|
7216
|
+
type: "button",
|
|
7211
7217
|
onClick: () => {
|
|
7212
7218
|
if (publicKey) setIsRollModalOpen(true);
|
|
7213
7219
|
else handleGenerateKeys();
|
|
7214
7220
|
},
|
|
7215
|
-
disabled: isGenerating
|
|
7216
|
-
|
|
7217
|
-
className: "w-fit"
|
|
7221
|
+
disabled: isGenerating,
|
|
7222
|
+
className: "absolute right-2.5 bottom-2.5 w-7 h-7 rounded-lg border border-stone-200 bg-white flex items-center justify-center text-stone-500 hover:text-black hover:border-stone-300 transition-all outline-none shadow-sm disabled:opacity-50"
|
|
7218
7223
|
},
|
|
7219
|
-
|
|
7220
|
-
))), /* @__PURE__ */ import_react103.default.createElement("form", { className: "flex flex-col gap-6
|
|
7224
|
+
isGenerating ? /* @__PURE__ */ import_react103.default.createElement(import_react104.HugeiconsIcon, { icon: import_core_free_icons41.Loading03Icon, size: 14, className: "animate-spin" }) : /* @__PURE__ */ import_react103.default.createElement(import_react104.HugeiconsIcon, { icon: import_core_free_icons41.RefreshIcon, size: 14 })
|
|
7225
|
+
)), /* @__PURE__ */ import_react103.default.createElement("p", { className: "text-xs text-stone-500 mt-2 leading-relaxed" }, "Your public key is used to identify your application. Your secret key will only be shown once upon generation."))), /* @__PURE__ */ import_react103.default.createElement("form", { className: "flex flex-col gap-6 pt-8", onSubmit: handleSaveWebhook, autoComplete: "off" }, /* @__PURE__ */ import_react103.default.createElement("div", { className: "space-y-1.5 w-full" }, /* @__PURE__ */ import_react103.default.createElement(
|
|
7221
7226
|
TextInput,
|
|
7222
7227
|
{
|
|
7223
7228
|
label: "Webhook URL",
|
|
@@ -7227,29 +7232,29 @@ AUDDITUR_SECRET_KEY="${secKey}"
|
|
|
7227
7232
|
placeholder: "https://your-domain.com/webhook",
|
|
7228
7233
|
type: "url"
|
|
7229
7234
|
}
|
|
7230
|
-
), /* @__PURE__ */ import_react103.default.createElement("
|
|
7231
|
-
"button",
|
|
7232
|
-
{
|
|
7233
|
-
type: "button",
|
|
7234
|
-
onClick: () => setWebhookUrl(initialWebhookUrl),
|
|
7235
|
-
className: "text-[11px] tracking-widest text-neutral-500 hover:text-black transition-colors w-full sm:w-auto py-2 sm:py-0 outline-none"
|
|
7236
|
-
},
|
|
7237
|
-
"Cancel"
|
|
7238
|
-
), /* @__PURE__ */ import_react103.default.createElement(
|
|
7235
|
+
), /* @__PURE__ */ import_react103.default.createElement("div", { className: "flex flex-col sm:flex-row sm:items-center justify-between mt-2 gap-2" }, /* @__PURE__ */ import_react103.default.createElement("p", { className: "text-xs text-stone-500 leading-relaxed" }, "We will send secure POST requests to this endpoint when significant events occur. Must use HTTPS."), /* @__PURE__ */ import_react103.default.createElement("span", { className: `text-[10px] tracking-widest ${webhookUrl ? "text-emerald-600" : "text-stone-400"}` }, webhookUrl ? "Active" : "Inactive"))), /* @__PURE__ */ import_react103.default.createElement("div", { className: "flex items-center gap-3" }, /* @__PURE__ */ import_react103.default.createElement(
|
|
7239
7236
|
ThreeDActionButton,
|
|
7240
7237
|
{
|
|
7241
7238
|
type: "submit",
|
|
7242
7239
|
disabled: isWebhookSaveDisabled,
|
|
7243
7240
|
isLoading: isSavingWebhook,
|
|
7244
|
-
className: "
|
|
7241
|
+
className: "w-full sm:w-auto min-w-40"
|
|
7245
7242
|
},
|
|
7246
7243
|
"Save Webhook"
|
|
7244
|
+
), hasWebhookChanges && !isSavingWebhook && !isReadOnly && /* @__PURE__ */ import_react103.default.createElement(
|
|
7245
|
+
"button",
|
|
7246
|
+
{
|
|
7247
|
+
type: "button",
|
|
7248
|
+
onClick: () => setWebhookUrl(initialWebhookUrl),
|
|
7249
|
+
className: "px-4 py-2 text-stone-500 hover:text-black transition-colors outline-none text-xs "
|
|
7250
|
+
},
|
|
7251
|
+
"Cancel"
|
|
7247
7252
|
))))), /* @__PURE__ */ import_react103.default.createElement(
|
|
7248
7253
|
ConfirmationDialog,
|
|
7249
7254
|
{
|
|
7250
7255
|
isOpen: isRollModalOpen && !isReadOnly,
|
|
7251
7256
|
title: "Roll API Keys",
|
|
7252
|
-
message: "Are you sure you want to roll your keys? This will permanently invalidate your current secret key and active
|
|
7257
|
+
message: "Are you sure you want to roll your keys? This will permanently invalidate your current secret key and active integrations.",
|
|
7253
7258
|
confirmText: "Roll Keys",
|
|
7254
7259
|
cancelText: "Cancel",
|
|
7255
7260
|
isProcessing: isGenerating,
|
|
@@ -7261,9 +7266,9 @@ AUDDITUR_SECRET_KEY="${secKey}"
|
|
|
7261
7266
|
};
|
|
7262
7267
|
|
|
7263
7268
|
// src/components/UniversalApplicationPage2.tsx
|
|
7264
|
-
var
|
|
7265
|
-
var
|
|
7266
|
-
var
|
|
7269
|
+
var import_react105 = __toESM(require("react"));
|
|
7270
|
+
var import_react106 = require("@hugeicons/react");
|
|
7271
|
+
var import_core_free_icons42 = require("@hugeicons/core-free-icons");
|
|
7267
7272
|
var UniversalApplicationPage2 = ({
|
|
7268
7273
|
userRole = "MEMBER",
|
|
7269
7274
|
applications,
|
|
@@ -7279,9 +7284,9 @@ var UniversalApplicationPage2 = ({
|
|
|
7279
7284
|
onCreateApplication
|
|
7280
7285
|
}) => {
|
|
7281
7286
|
const canManage = userRole === "ADMIN" || userRole === "MANAGER" || userRole === "OWNER";
|
|
7282
|
-
const [showStatusModal, setShowStatusModal] = (0,
|
|
7283
|
-
const [localSearchQuery, setLocalSearchQuery] = (0,
|
|
7284
|
-
const typingTimer = (0,
|
|
7287
|
+
const [showStatusModal, setShowStatusModal] = (0, import_react105.useState)(false);
|
|
7288
|
+
const [localSearchQuery, setLocalSearchQuery] = (0, import_react105.useState)(searchQuery);
|
|
7289
|
+
const typingTimer = (0, import_react105.useRef)(null);
|
|
7285
7290
|
const handleSearchInput = (e) => {
|
|
7286
7291
|
const val = e.target.value;
|
|
7287
7292
|
setLocalSearchQuery(val);
|
|
@@ -7298,7 +7303,7 @@ var UniversalApplicationPage2 = ({
|
|
|
7298
7303
|
"REJECTED",
|
|
7299
7304
|
"QUERIED"
|
|
7300
7305
|
];
|
|
7301
|
-
return /* @__PURE__ */
|
|
7306
|
+
return /* @__PURE__ */ import_react105.default.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react105.default.createElement("div", { className: "flex flex-col gap-1 mb-8 px-1" }, /* @__PURE__ */ import_react105.default.createElement("div", { className: "flex items-center" }, /* @__PURE__ */ import_react105.default.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Applications Directory")), /* @__PURE__ */ import_react105.default.createElement("p", { className: "text-xs text-stone-500" }, "Search, filter, and track all your organizational applications.")), /* @__PURE__ */ import_react105.default.createElement("div", { className: "flex flex-row flex-nowrap mb-2 items-center justify-between gap-4 w-full px-1" }, /* @__PURE__ */ import_react105.default.createElement("div", { className: "relative flex-1 min-w-0 max-w-full" }, /* @__PURE__ */ import_react105.default.createElement("div", { className: "absolute inset-y-0 left-0 pl-4 flex items-center pointer-events-none" }, /* @__PURE__ */ import_react105.default.createElement(import_react106.HugeiconsIcon, { icon: import_core_free_icons42.Search01Icon, size: 16, className: "text-stone-400" })), /* @__PURE__ */ import_react105.default.createElement(
|
|
7302
7307
|
"input",
|
|
7303
7308
|
{
|
|
7304
7309
|
type: "text",
|
|
@@ -7307,15 +7312,15 @@ var UniversalApplicationPage2 = ({
|
|
|
7307
7312
|
onChange: handleSearchInput,
|
|
7308
7313
|
className: "w-full pl-10 pr-4 py-2.5 bg-white rounded-full text-sm text-black placeholder-stone-400 outline-none transition-colors focus:border-[#d97757] border border-transparent shadow-[0_2px_10px_rgba(0,0,0,0.02)]"
|
|
7309
7314
|
}
|
|
7310
|
-
)), /* @__PURE__ */
|
|
7315
|
+
)), /* @__PURE__ */ import_react105.default.createElement("div", { className: "flex items-center gap-3 w-auto pb-0 shrink-0" }, /* @__PURE__ */ import_react105.default.createElement(
|
|
7311
7316
|
"button",
|
|
7312
7317
|
{
|
|
7313
7318
|
onClick: () => setShowStatusModal(true),
|
|
7314
7319
|
className: "flex items-center justify-center bg-white shadow-[0_2px_10px_rgba(0,0,0,0.02)] w-10 h-10 rounded-full text-stone-500 hover:text-black transition-colors outline-none relative"
|
|
7315
7320
|
},
|
|
7316
|
-
/* @__PURE__ */
|
|
7317
|
-
activeStatusFilter !== "ALL" && /* @__PURE__ */
|
|
7318
|
-
))), /* @__PURE__ */
|
|
7321
|
+
/* @__PURE__ */ import_react105.default.createElement(import_react106.HugeiconsIcon, { icon: import_core_free_icons42.SearchList02Icon, size: 18 }),
|
|
7322
|
+
activeStatusFilter !== "ALL" && /* @__PURE__ */ import_react105.default.createElement("span", { className: "absolute top-2 right-2 w-2 h-2 bg-[#d97757] rounded-full border border-white" })
|
|
7323
|
+
))), /* @__PURE__ */ import_react105.default.createElement("div", { className: "w-full mt-2" }, /* @__PURE__ */ import_react105.default.createElement(
|
|
7319
7324
|
UniversalApplicationsPage,
|
|
7320
7325
|
{
|
|
7321
7326
|
headerTitle: "Recent Filings",
|
|
@@ -7328,7 +7333,7 @@ var UniversalApplicationPage2 = ({
|
|
|
7328
7333
|
onApplicationClick,
|
|
7329
7334
|
onCreateApplication: canManage ? onCreateApplication : void 0
|
|
7330
7335
|
}
|
|
7331
|
-
)), /* @__PURE__ */
|
|
7336
|
+
)), /* @__PURE__ */ import_react105.default.createElement(
|
|
7332
7337
|
ReusableOptions,
|
|
7333
7338
|
{
|
|
7334
7339
|
isOpen: showStatusModal,
|
|
@@ -7345,9 +7350,9 @@ var UniversalApplicationPage2 = ({
|
|
|
7345
7350
|
};
|
|
7346
7351
|
|
|
7347
7352
|
// src/components/UniversalApplicationDetails.tsx
|
|
7348
|
-
var
|
|
7349
|
-
var
|
|
7350
|
-
var
|
|
7353
|
+
var import_react107 = __toESM(require("react"));
|
|
7354
|
+
var import_react108 = require("@hugeicons/react");
|
|
7355
|
+
var import_core_free_icons43 = require("@hugeicons/core-free-icons");
|
|
7351
7356
|
var formatType2 = (type) => type.split("_").map((w) => w[0] + w.slice(1).toLowerCase()).join(" ");
|
|
7352
7357
|
var UniversalApplicationDetails = ({
|
|
7353
7358
|
onBackHref,
|
|
@@ -7355,8 +7360,8 @@ var UniversalApplicationDetails = ({
|
|
|
7355
7360
|
canDelete,
|
|
7356
7361
|
onDeleteSubmit
|
|
7357
7362
|
}) => {
|
|
7358
|
-
const [isDeleting, setIsDeleting] = (0,
|
|
7359
|
-
const [confirmDialog, setConfirmDialog] = (0,
|
|
7363
|
+
const [isDeleting, setIsDeleting] = (0, import_react107.useState)(false);
|
|
7364
|
+
const [confirmDialog, setConfirmDialog] = (0, import_react107.useState)(false);
|
|
7360
7365
|
const isLockedStatus = ["COMPLETED", "PENDING", "REJECTED", "QUERIED"].includes(application.status);
|
|
7361
7366
|
const deletePermitted = canDelete && !isLockedStatus;
|
|
7362
7367
|
const handleDelete = async () => {
|
|
@@ -7368,32 +7373,32 @@ var UniversalApplicationDetails = ({
|
|
|
7368
7373
|
}
|
|
7369
7374
|
setIsDeleting(false);
|
|
7370
7375
|
};
|
|
7371
|
-
return /* @__PURE__ */
|
|
7376
|
+
return /* @__PURE__ */ import_react107.default.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react107.default.createElement(ManagedToaster, null), /* @__PURE__ */ import_react107.default.createElement(
|
|
7372
7377
|
ConfirmationDialog,
|
|
7373
7378
|
{
|
|
7374
7379
|
isOpen: confirmDialog,
|
|
7375
7380
|
title: "Delete Application",
|
|
7376
7381
|
message: "Are you sure you want to permanently delete this application and its assets? This action cannot be undone.",
|
|
7377
|
-
confirmText: "Delete
|
|
7382
|
+
confirmText: "Delete",
|
|
7378
7383
|
cancelText: "Cancel",
|
|
7379
7384
|
isProcessing: isDeleting,
|
|
7380
7385
|
isDestructive: true,
|
|
7381
7386
|
onClose: () => setConfirmDialog(false),
|
|
7382
7387
|
onConfirm: handleDelete
|
|
7383
7388
|
}
|
|
7384
|
-
), /* @__PURE__ */
|
|
7389
|
+
), /* @__PURE__ */ import_react107.default.createElement("div", { className: "mb-6 flex w-full items-center px-1" }, /* @__PURE__ */ import_react107.default.createElement("a", { href: onBackHref, className: "flex items-center gap-2 text-[#d97757] hover:text-[#d97757] transition-colors text-sm outline-none" }, /* @__PURE__ */ import_react107.default.createElement(import_react108.HugeiconsIcon, { icon: import_core_free_icons43.ArrowLeft01Icon, size: 16 }), " Back")), /* @__PURE__ */ import_react107.default.createElement("div", { className: "mb-8 px-1 flex flex-col sm:flex-row sm:items-center justify-between gap-4" }, /* @__PURE__ */ import_react107.default.createElement("div", null, /* @__PURE__ */ import_react107.default.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Application Details"), /* @__PURE__ */ import_react107.default.createElement("p", { className: "text-xs text-stone-500" }, "Review your filing entity and access its workspace.")), /* @__PURE__ */ import_react107.default.createElement("div", { className: "px-4 py-1.5 bg-stone-200 text-stone-600 rounded-full text-xs self-start sm:self-auto tracking-widest " }, application.status)), /* @__PURE__ */ import_react107.default.createElement("div", { className: "flex flex-col gap-8 animate-in rounded-2xl p-6 bg-white fade-in duration-300" }, /* @__PURE__ */ import_react107.default.createElement("div", { className: "flex flex-col gap-1 w-full" }, /* @__PURE__ */ import_react107.default.createElement("label", { className: "text-xs text-stone-400 tracking-[0.2em] block" }, "Target Company"), /* @__PURE__ */ import_react107.default.createElement("span", { className: "text-sm text-black py-2 " }, application.name)), /* @__PURE__ */ import_react107.default.createElement("div", { className: "flex flex-col gap-1 w-full border-t border-stone-100 pt-6" }, /* @__PURE__ */ import_react107.default.createElement("label", { className: "text-xs text-stone-400 tracking-[0.2em] block" }, "Filing Type"), /* @__PURE__ */ import_react107.default.createElement("span", { className: "text-sm text-black py-2" }, formatType2(application.type))), /* @__PURE__ */ import_react107.default.createElement("div", { className: "flex flex-col sm:flex-row items-center gap-3 pt-6 mt-2 border-t border-stone-100" }, /* @__PURE__ */ import_react107.default.createElement("a", { href: `/app/applications/app/${application.id}`, className: "flex-1 w-full py-2.5 bg-[#d97757] text-white rounded-full text-center text-xs transition-colors hover:bg-[#d97757]/90" }, "Open Application"), /* @__PURE__ */ import_react107.default.createElement("a", { href: `/app/applications/assets/${application.id}`, className: "flex-1 w-full py-2.5 bg-transparent border border-stone-200 text-black rounded-full text-center text-xs transition-colors hover:bg-stone-50" }, "Application Assets"), deletePermitted && /* @__PURE__ */ import_react107.default.createElement("button", { onClick: () => setConfirmDialog(true), className: "flex-1 w-full py-2.5 bg-transparent border border-stone-200 text-black rounded-full text-center text-xs transition-colors hover:bg-stone-50" }, "Delete Application"))));
|
|
7385
7390
|
};
|
|
7386
7391
|
|
|
7387
7392
|
// src/components/UniversalCreateApplication.tsx
|
|
7388
|
-
var
|
|
7393
|
+
var import_react109 = __toESM(require("react"));
|
|
7389
7394
|
var import_react_hot_toast21 = __toESM(require("react-hot-toast"));
|
|
7390
|
-
var
|
|
7391
|
-
var
|
|
7395
|
+
var import_react110 = require("@hugeicons/react");
|
|
7396
|
+
var import_core_free_icons44 = require("@hugeicons/core-free-icons");
|
|
7392
7397
|
var MemberAvatar6 = ({ src, sizeClass = "w-10 h-10" }) => {
|
|
7393
|
-
const [loaded, setLoaded] = (0,
|
|
7394
|
-
const [error, setError] = (0,
|
|
7398
|
+
const [loaded, setLoaded] = (0, import_react109.useState)(false);
|
|
7399
|
+
const [error, setError] = (0, import_react109.useState)(false);
|
|
7395
7400
|
const defaultAvatar = "https://storage.googleapis.com/retina-cloud-v2/assets/images/avatar.avif";
|
|
7396
|
-
return /* @__PURE__ */
|
|
7401
|
+
return /* @__PURE__ */ import_react109.default.createElement("div", { className: `relative shrink-0 ${sizeClass}` }, /* @__PURE__ */ import_react109.default.createElement("div", { className: "w-full h-full rounded-lg bg-stone-100 flex items-center justify-center overflow-hidden" }, !loaded && !error && /* @__PURE__ */ import_react109.default.createElement(import_react110.HugeiconsIcon, { icon: import_core_free_icons44.Loading03Icon, className: "animate-spin text-stone-400 absolute", size: 14 }), /* @__PURE__ */ import_react109.default.createElement("img", { src: error || !src ? defaultAvatar : src, alt: "Avatar", className: `w-full h-full object-cover transition-opacity duration-300 ${loaded || error ? "opacity-100" : "opacity-0"}`, onLoad: () => setLoaded(true), onError: () => setError(true) })));
|
|
7397
7402
|
};
|
|
7398
7403
|
var UniversalCreateApplication = ({
|
|
7399
7404
|
onBackHref,
|
|
@@ -7416,32 +7421,32 @@ var UniversalCreateApplication = ({
|
|
|
7416
7421
|
onCreateSubmit
|
|
7417
7422
|
}) => {
|
|
7418
7423
|
const canManage = userRole === "ADMIN" || userRole === "MANAGER" || userRole === "OWNER";
|
|
7419
|
-
const [creationMode, setCreationMode] = (0,
|
|
7424
|
+
const [creationMode, setCreationMode] = (0, import_react109.useState)("EXISTING");
|
|
7420
7425
|
const defaultTypeKey = applicationTypesMeta.length > 0 ? applicationTypesMeta[0].key : "";
|
|
7421
|
-
const [selectedTypeKey, setSelectedTypeKey] = (0,
|
|
7422
|
-
(0,
|
|
7426
|
+
const [selectedTypeKey, setSelectedTypeKey] = (0, import_react109.useState)(defaultTypeKey);
|
|
7427
|
+
(0, import_react109.useEffect)(() => {
|
|
7423
7428
|
if (!selectedTypeKey && applicationTypesMeta.length > 0) {
|
|
7424
7429
|
setSelectedTypeKey(applicationTypesMeta[0].key);
|
|
7425
7430
|
}
|
|
7426
7431
|
}, [applicationTypesMeta, selectedTypeKey]);
|
|
7427
|
-
const [selectedCompanyId, setSelectedCompanyId] = (0,
|
|
7428
|
-
const [newCompanyName, setNewCompanyName] = (0,
|
|
7429
|
-
const [isPrivate, setIsPrivate] = (0,
|
|
7430
|
-
const [selectedParticipants, setSelectedParticipants] = (0,
|
|
7431
|
-
const [isSubmitting, setIsSubmitting] = (0,
|
|
7432
|
-
const [showTypeModal, setShowTypeModal] = (0,
|
|
7433
|
-
const [showMembersModal, setShowMembersModal] = (0,
|
|
7434
|
-
const [showCompaniesModal, setShowCompaniesModal] = (0,
|
|
7435
|
-
const [localMemSearch, setLocalMemSearch] = (0,
|
|
7436
|
-
const memTimer = (0,
|
|
7432
|
+
const [selectedCompanyId, setSelectedCompanyId] = (0, import_react109.useState)(null);
|
|
7433
|
+
const [newCompanyName, setNewCompanyName] = (0, import_react109.useState)("");
|
|
7434
|
+
const [isPrivate, setIsPrivate] = (0, import_react109.useState)(false);
|
|
7435
|
+
const [selectedParticipants, setSelectedParticipants] = (0, import_react109.useState)(/* @__PURE__ */ new Set());
|
|
7436
|
+
const [isSubmitting, setIsSubmitting] = (0, import_react109.useState)(false);
|
|
7437
|
+
const [showTypeModal, setShowTypeModal] = (0, import_react109.useState)(false);
|
|
7438
|
+
const [showMembersModal, setShowMembersModal] = (0, import_react109.useState)(false);
|
|
7439
|
+
const [showCompaniesModal, setShowCompaniesModal] = (0, import_react109.useState)(false);
|
|
7440
|
+
const [localMemSearch, setLocalMemSearch] = (0, import_react109.useState)(membersSearchQuery);
|
|
7441
|
+
const memTimer = (0, import_react109.useRef)(null);
|
|
7437
7442
|
const handleMemSearch = (e) => {
|
|
7438
7443
|
const val = e.target.value;
|
|
7439
7444
|
setLocalMemSearch(val);
|
|
7440
7445
|
if (memTimer.current) clearTimeout(memTimer.current);
|
|
7441
7446
|
memTimer.current = setTimeout(() => onMembersSearchChange(val), 500);
|
|
7442
7447
|
};
|
|
7443
|
-
const [localCompSearch, setLocalCompSearch] = (0,
|
|
7444
|
-
const compTimer = (0,
|
|
7448
|
+
const [localCompSearch, setLocalCompSearch] = (0, import_react109.useState)(companiesSearchQuery);
|
|
7449
|
+
const compTimer = (0, import_react109.useRef)(null);
|
|
7445
7450
|
const handleCompSearch = (e) => {
|
|
7446
7451
|
const val = e.target.value;
|
|
7447
7452
|
setLocalCompSearch(val);
|
|
@@ -7484,9 +7489,9 @@ var UniversalCreateApplication = ({
|
|
|
7484
7489
|
{ id: "EXISTING", label: "Select Company" },
|
|
7485
7490
|
{ id: "NEW", label: "New Company" }
|
|
7486
7491
|
];
|
|
7487
|
-
return /* @__PURE__ */
|
|
7492
|
+
return /* @__PURE__ */ import_react109.default.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react109.default.createElement(ManagedToaster, null), /* @__PURE__ */ import_react109.default.createElement("div", { className: "mb-6 flex w-full items-center px-1" }, /* @__PURE__ */ import_react109.default.createElement("a", { href: onBackHref, className: "flex items-center gap-2 text-[#d97757] hover:text-[#d97757] transition-colors text-sm outline-none" }, /* @__PURE__ */ import_react109.default.createElement(import_react110.HugeiconsIcon, { icon: import_core_free_icons44.ArrowLeft01Icon, size: 16 }), " Back")), /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex flex-col gap-1 mb-6 px-1" }, /* @__PURE__ */ import_react109.default.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Create Application"), /* @__PURE__ */ import_react109.default.createElement("p", { className: "text-xs text-stone-500" }, "Initiate a new registration or filing for a company.")), /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex items-center mb-4 w-full animate-in fade-in duration-300 px-2" }, /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex items-center bg-white rounded-full p-1 sm:p-1.5 max-w-full overflow-x-auto custom-scrollbar" }, modeTabs.map((tab) => {
|
|
7488
7493
|
const isActive = creationMode === tab.id;
|
|
7489
|
-
return /* @__PURE__ */
|
|
7494
|
+
return /* @__PURE__ */ import_react109.default.createElement(
|
|
7490
7495
|
"button",
|
|
7491
7496
|
{
|
|
7492
7497
|
key: tab.id,
|
|
@@ -7497,9 +7502,9 @@ var UniversalCreateApplication = ({
|
|
|
7497
7502
|
},
|
|
7498
7503
|
tab.label
|
|
7499
7504
|
);
|
|
7500
|
-
}))), /* @__PURE__ */
|
|
7505
|
+
}))), /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex flex-col gap-8 animate-in rounded-2xl p-6 bg-white fade-in duration-300" }, /* @__PURE__ */ import_react109.default.createElement("form", { className: "flex flex-col gap-8", onSubmit: handleSubmit, autoComplete: "off" }, !canManage && /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex items-start gap-3 p-4 bg-stone-50 rounded-xl" }, /* @__PURE__ */ import_react109.default.createElement(import_react110.HugeiconsIcon, { icon: import_core_free_icons44.CircleLock02Icon, size: 20, className: "text-stone-500 shrink-0 mt-0.5" }), /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ import_react109.default.createElement("span", { className: "text-sm text-black tracking-tight" }, "Access Restricted"), /* @__PURE__ */ import_react109.default.createElement("span", { className: "text-xs text-stone-500 mt-1 leading-relaxed" }, "You lack clearance to create applications."))), creationMode === "EXISTING" ? /* @__PURE__ */ import_react109.default.createElement("div", { className: "space-y-1.5 w-full" }, /* @__PURE__ */ import_react109.default.createElement("label", { className: "text-xs text-stone-400 tracking-[0.2em] block" }, "Target Company"), /* @__PURE__ */ import_react109.default.createElement("div", { onClick: () => canManage && !isSubmitting && setShowCompaniesModal(true), className: `flex items-center relative w-full border-b border-stone-200 transition-all duration-300 pb-3 pt-3 ${!canManage || isSubmitting ? "opacity-50 pointer-events-none" : "hover:border-black cursor-pointer"}` }, /* @__PURE__ */ import_react109.default.createElement(import_react110.HugeiconsIcon, { icon: import_core_free_icons44.Building03Icon, size: 16, className: "text-stone-400 absolute left-0" }), /* @__PURE__ */ import_react109.default.createElement("span", { className: `w-full pl-8 text-sm truncate block ${activeCompany ? "text-black" : "text-stone-400"}` }, activeCompany ? activeCompany.name : "Select an existing company..."))) : /* @__PURE__ */ import_react109.default.createElement(import_react109.default.Fragment, null, /* @__PURE__ */ import_react109.default.createElement(TextInput, { label: "Company Name", value: newCompanyName, onChange: (val) => setNewCompanyName(val), disabled: isSubmitting || !canManage, placeholder: "e.g. Acme Innovations Ltd.", maxLength: 80 }), /* @__PURE__ */ import_react109.default.createElement("div", { className: `flex items-center justify-between py-2 mt-2 ${!canManage ? "opacity-50 pointer-events-none" : ""}` }, /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ import_react109.default.createElement("span", { className: "text-sm text-black tracking-tight" }, "Private Company"), /* @__PURE__ */ import_react109.default.createElement("span", { className: "text-xs text-stone-500" }, "Only assigned members can view and access its applications.")), /* @__PURE__ */ import_react109.default.createElement("button", { type: "button", onClick: () => setIsPrivate(!isPrivate), disabled: !canManage || isSubmitting, className: `relative w-11 h-6 rounded-full transition-colors outline-none shrink-0 ${isPrivate ? "bg-[#d97757]" : "bg-stone-200"}` }, /* @__PURE__ */ import_react109.default.createElement("div", { className: `absolute top-1 left-1 bg-white w-4 h-4 rounded-full transition-transform ${isPrivate ? "translate-x-5" : "translate-x-0"}` }))), isPrivate && /* @__PURE__ */ import_react109.default.createElement("div", { className: `flex items-center justify-between animate-in fade-in zoom-in-95 duration-200 bg-stone-50 p-4 rounded-xl ${!canManage ? "opacity-50" : ""}` }, /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ import_react109.default.createElement("span", { className: "text-xs text-black tracking-tight" }, "Members"), /* @__PURE__ */ import_react109.default.createElement("span", { className: "text-xs text-[#d97757]" }, selectedParticipants.size, " added")), /* @__PURE__ */ import_react109.default.createElement("button", { type: "button", onClick: () => setShowMembersModal(true), disabled: !canManage || isSubmitting, className: "px-4 py-2 border border-stone-200 text-black text-xs tracking-wide rounded-full hover:bg-white transition-colors outline-none bg-transparent" }, "Manage Access"))), /* @__PURE__ */ import_react109.default.createElement("div", { className: "space-y-1.5 w-full" }, /* @__PURE__ */ import_react109.default.createElement("label", { className: "text-xs text-stone-400 tracking-[0.2em] block" }, "Application Type"), /* @__PURE__ */ import_react109.default.createElement("div", { onClick: () => canManage && !isSubmitting && setShowTypeModal(true), className: `flex items-center relative w-full border-b border-stone-200 transition-all duration-300 pb-3 pt-3 ${!canManage || isSubmitting ? "opacity-50 pointer-events-none" : "hover:border-black cursor-pointer"}` }, /* @__PURE__ */ import_react109.default.createElement(import_react110.HugeiconsIcon, { icon: import_core_free_icons44.File02Icon, size: 16, className: "text-stone-400 absolute left-0" }), /* @__PURE__ */ import_react109.default.createElement("span", { className: "w-full pl-8 text-sm text-black truncate block" }, activeTypeObj?.label || "Select Type..."))), canManage && /* @__PURE__ */ import_react109.default.createElement("div", { className: "pt-6" }, /* @__PURE__ */ import_react109.default.createElement(ThreeDActionButton, { type: "submit", disabled: isSubmitting || !selectedTypeKey || creationMode === "EXISTING" && !selectedCompanyId || creationMode === "NEW" && newCompanyName.length < 2, isLoading: isSubmitting, className: "w-full sm:w-auto min-w-40" }, "Create Application")))), showTypeModal && canManage && /* @__PURE__ */ import_react109.default.createElement("div", { className: "fixed inset-0 z-120 flex items-center justify-center p-4 pointer-events-auto" }, /* @__PURE__ */ import_react109.default.createElement("div", { className: "absolute inset-0 bg-black/30", onClick: () => setShowTypeModal(false) }), /* @__PURE__ */ import_react109.default.createElement("div", { className: "relative w-full max-w-md bg-white rounded-2xl flex flex-col overflow-hidden shadow-2xl animate-in zoom-in-95 duration-200 h-[80vh]" }, /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex items-center justify-between p-5 shrink-0" }, /* @__PURE__ */ import_react109.default.createElement("h3", { className: "text-sm text-black tracking-tight " }, "Application Type"), /* @__PURE__ */ import_react109.default.createElement("button", { onClick: () => setShowTypeModal(false), className: "text-[#d97757] outline-none text-sm" }, "Done")), /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex-1 overflow-y-auto custom-scrollbar p-3 space-y-2" }, applicationTypesMeta.map((item) => {
|
|
7501
7506
|
const isSelected = selectedTypeKey === item.key;
|
|
7502
|
-
return /* @__PURE__ */
|
|
7507
|
+
return /* @__PURE__ */ import_react109.default.createElement(
|
|
7503
7508
|
"div",
|
|
7504
7509
|
{
|
|
7505
7510
|
key: item.key,
|
|
@@ -7508,15 +7513,15 @@ var UniversalCreateApplication = ({
|
|
|
7508
7513
|
},
|
|
7509
7514
|
className: `p-4 rounded-xl cursor-pointer transition-all border ${isSelected ? "bg-white border-[#d97757]" : "bg-stone-50 border-transparent hover:bg-stone-100/60"}`
|
|
7510
7515
|
},
|
|
7511
|
-
/* @__PURE__ */
|
|
7512
|
-
/* @__PURE__ */
|
|
7516
|
+
/* @__PURE__ */ import_react109.default.createElement("div", { className: "flex items-center justify-between gap-2" }, /* @__PURE__ */ import_react109.default.createElement("h4", { className: "text-xs text-black" }, item.label), isSelected && /* @__PURE__ */ import_react109.default.createElement(import_react110.HugeiconsIcon, { icon: import_core_free_icons44.CheckmarkCircle02Icon, size: 16, className: "text-[#d97757] shrink-0" })),
|
|
7517
|
+
/* @__PURE__ */ import_react109.default.createElement("p", { className: "text-[11px] text-stone-500 mt-1 leading-relaxed whitespace-normal wrap-break-word" }, item.desc)
|
|
7513
7518
|
);
|
|
7514
|
-
})))), showCompaniesModal && canManage && /* @__PURE__ */
|
|
7519
|
+
})))), showCompaniesModal && canManage && /* @__PURE__ */ import_react109.default.createElement("div", { className: "fixed inset-0 z-120 flex items-center justify-center p-4 pointer-events-auto" }, /* @__PURE__ */ import_react109.default.createElement("div", { className: "absolute inset-0 bg-black/30", onClick: () => setShowCompaniesModal(false) }), /* @__PURE__ */ import_react109.default.createElement("div", { className: "relative w-full max-w-md bg-white rounded-2xl flex flex-col overflow-hidden shadow-2xl animate-in zoom-in-95 duration-200 h-[80vh]" }, /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex items-center justify-between p-5 shrink-0" }, /* @__PURE__ */ import_react109.default.createElement("h3", { className: "text-sm text-black tracking-tight" }, "Select Company"), /* @__PURE__ */ import_react109.default.createElement("button", { onClick: () => setShowCompaniesModal(false), className: "text-[#d97757] outline-none text-sm" }, "Done")), /* @__PURE__ */ import_react109.default.createElement("div", { className: "p-4 shrink-0" }, /* @__PURE__ */ import_react109.default.createElement("div", { className: "relative w-full" }, /* @__PURE__ */ import_react109.default.createElement(import_react110.HugeiconsIcon, { icon: import_core_free_icons44.Search01Icon, size: 16, className: "text-stone-400 absolute left-4 top-1/2 -translate-y-1/2 pointer-events-none" }), /* @__PURE__ */ import_react109.default.createElement("input", { type: "text", placeholder: "Search companies...", value: localCompSearch, onChange: handleCompSearch, className: "w-full pl-10 pr-4 py-2.5 bg-stone-100 rounded-full focus:border-[#d97757] border border-transparent text-sm text-black outline-none focus:bg-stone-50 transition-colors" }))), /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex-1 overflow-y-auto custom-scrollbar p-2" }, isCompaniesLoading ? /* @__PURE__ */ import_react109.default.createElement("div", { className: "absolute inset-0 flex items-center justify-center" }, /* @__PURE__ */ import_react109.default.createElement(import_react110.HugeiconsIcon, { icon: import_core_free_icons44.Loading03Icon, size: 28, className: "animate-spin text-black" })) : companies.length === 0 ? /* @__PURE__ */ import_react109.default.createElement("div", { className: "p-8 text-center text-xs text-stone-400" }, "No companies available.") : companies.map((comp) => /* @__PURE__ */ import_react109.default.createElement("div", { key: comp.id, onClick: () => {
|
|
7515
7520
|
setSelectedCompanyId(comp.id);
|
|
7516
|
-
}, className: "flex items-center justify-between p-3 rounded-xl cursor-pointer hover:bg-stone-50 transition-colors" }, /* @__PURE__ */
|
|
7521
|
+
}, className: "flex items-center justify-between p-3 rounded-xl cursor-pointer hover:bg-stone-50 transition-colors" }, /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex flex-col min-w-0 flex-1 pl-2" }, /* @__PURE__ */ import_react109.default.createElement("span", { className: "text-sm text-black truncate" }, comp.name), /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex items-center gap-2 mt-0.5" }, /* @__PURE__ */ import_react109.default.createElement("span", { className: "text-[10px] text-stone-500 tracking-widest " }, "Applications: ", comp.applicationsCount || 0), comp.isPrivate && /* @__PURE__ */ import_react109.default.createElement("span", { className: "text-[10px] text-[#d97757] tracking-widest " }, "Private"))), selectedCompanyId === comp.id && /* @__PURE__ */ import_react109.default.createElement(import_react110.HugeiconsIcon, { icon: import_core_free_icons44.CheckmarkCircle02Icon, size: 16, className: "text-[#d97757] mr-2" })))), /* @__PURE__ */ import_react109.default.createElement("div", { className: "p-4 flex items-center justify-between shrink-0 bg-white" }, /* @__PURE__ */ import_react109.default.createElement("span", { className: "text-xs text-stone-400 tracking-widest" }, "Page ", companiesCurrentPage, " of ", companiesTotalPages || 1), /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex gap-1" }, /* @__PURE__ */ import_react109.default.createElement("button", { disabled: companiesCurrentPage <= 1 || isCompaniesLoading, onClick: () => onCompaniesPageChange(companiesCurrentPage - 1), className: "w-7 h-7 flex items-center justify-center rounded-full bg-white border border-stone-200 text-stone-600 disabled:opacity-30 outline-none hover:bg-stone-50" }, /* @__PURE__ */ import_react109.default.createElement(import_react110.HugeiconsIcon, { icon: import_core_free_icons44.ArrowLeft01Icon, size: 12 })), /* @__PURE__ */ import_react109.default.createElement("button", { disabled: companiesCurrentPage >= companiesTotalPages || isCompaniesLoading, onClick: () => onCompaniesPageChange(companiesCurrentPage + 1), className: "w-7 h-7 flex items-center justify-center rounded-full bg-white border border-stone-200 text-stone-600 disabled:opacity-30 outline-none hover:bg-stone-50" }, /* @__PURE__ */ import_react109.default.createElement(import_react110.HugeiconsIcon, { icon: import_core_free_icons44.ArrowRight01Icon, size: 12 })))))), showMembersModal && canManage && /* @__PURE__ */ import_react109.default.createElement("div", { className: "fixed inset-0 z-120 flex items-center justify-center p-4 pointer-events-auto" }, /* @__PURE__ */ import_react109.default.createElement("div", { className: "absolute inset-0 bg-black/30", onClick: () => setShowMembersModal(false) }), /* @__PURE__ */ import_react109.default.createElement("div", { className: "relative w-full max-w-md bg-white rounded-2xl flex flex-col overflow-hidden shadow-2xl animate-in zoom-in-95 duration-200 h-[80vh]" }, /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex items-center justify-between p-5 shrink-0" }, /* @__PURE__ */ import_react109.default.createElement("h3", { className: "text-sm text-black tracking-tight" }, "Assign Members"), /* @__PURE__ */ import_react109.default.createElement("button", { onClick: () => setShowMembersModal(false), className: "text-[#d97757] outline-none text-sm" }, "Done")), /* @__PURE__ */ import_react109.default.createElement("div", { className: "p-4 shrink-0" }, /* @__PURE__ */ import_react109.default.createElement("div", { className: "relative w-full" }, /* @__PURE__ */ import_react109.default.createElement(import_react110.HugeiconsIcon, { icon: import_core_free_icons44.Search01Icon, size: 16, className: "text-stone-400 absolute left-4 top-1/2 -translate-y-1/2 pointer-events-none" }), /* @__PURE__ */ import_react109.default.createElement("input", { type: "text", placeholder: "Search team...", value: localMemSearch, onChange: handleMemSearch, className: "w-full pl-10 pr-4 py-2.5 bg-stone-100 rounded-full focus:border-[#d97757] border border-transparent text-sm text-black outline-none focus:bg-stone-50 transition-colors" }))), /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex-1 overflow-y-auto custom-scrollbar p-2" }, isMembersLoading ? /* @__PURE__ */ import_react109.default.createElement("div", { className: "absolute inset-0 flex items-center justify-center" }, /* @__PURE__ */ import_react109.default.createElement(import_react110.HugeiconsIcon, { icon: import_core_free_icons44.Loading03Icon, size: 28, className: "animate-spin text-black" })) : members.length === 0 ? /* @__PURE__ */ import_react109.default.createElement("div", { className: "p-8 text-center text-xs text-stone-400" }, "No members found.") : members.map((member) => {
|
|
7517
7522
|
const isChecked = selectedParticipants.has(member.userId);
|
|
7518
|
-
return /* @__PURE__ */
|
|
7519
|
-
})), /* @__PURE__ */
|
|
7523
|
+
return /* @__PURE__ */ import_react109.default.createElement("div", { key: member.id, onClick: () => toggleParticipant(member.userId), className: "flex items-center justify-between p-3 rounded-xl cursor-pointer hover:bg-stone-50 transition-colors select-none" }, /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex items-center gap-3 min-w-0 flex-1" }, /* @__PURE__ */ import_react109.default.createElement(MemberAvatar6, { src: member.avatarUrl, sizeClass: "w-9 h-9" }), /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex flex-col min-w-0 flex-1" }, /* @__PURE__ */ import_react109.default.createElement("span", { className: "text-sm text-black truncate" }, member.fullName), /* @__PURE__ */ import_react109.default.createElement("span", { className: "text-xs text-stone-400 capitalize truncate" }, member.role.toLowerCase()))), /* @__PURE__ */ import_react109.default.createElement("div", { className: "shrink-0 pl-3" }, /* @__PURE__ */ import_react109.default.createElement("div", { className: `w-5 h-5 rounded-full flex items-center justify-center transition-colors ${isChecked ? "bg-[#d97757]" : "border border-stone-300 bg-white"}` }, isChecked && /* @__PURE__ */ import_react109.default.createElement(import_react110.HugeiconsIcon, { icon: import_core_free_icons44.Tick02Icon, size: 14, className: "text-white" }))));
|
|
7524
|
+
})), /* @__PURE__ */ import_react109.default.createElement("div", { className: "p-4 flex items-center justify-between shrink-0 bg-white" }, /* @__PURE__ */ import_react109.default.createElement("span", { className: "text-xs text-stone-400 tracking-widest" }, "Page ", membersCurrentPage, " of ", membersTotalPages || 1), /* @__PURE__ */ import_react109.default.createElement("div", { className: "flex gap-1" }, /* @__PURE__ */ import_react109.default.createElement("button", { disabled: membersCurrentPage <= 1 || isMembersLoading, onClick: () => onMembersPageChange(membersCurrentPage - 1), className: "w-7 h-7 flex items-center justify-center rounded-full bg-white border border-stone-200 text-stone-600 disabled:opacity-30 outline-none hover:bg-stone-50" }, /* @__PURE__ */ import_react109.default.createElement(import_react110.HugeiconsIcon, { icon: import_core_free_icons44.ArrowLeft01Icon, size: 12 })), /* @__PURE__ */ import_react109.default.createElement("button", { disabled: membersCurrentPage >= membersTotalPages || isMembersLoading, onClick: () => onMembersPageChange(membersCurrentPage + 1), className: "w-7 h-7 flex items-center justify-center rounded-full bg-white border border-stone-200 text-stone-600 disabled:opacity-30 outline-none hover:bg-stone-50" }, /* @__PURE__ */ import_react109.default.createElement(import_react110.HugeiconsIcon, { icon: import_core_free_icons44.ArrowRight01Icon, size: 12 })))))));
|
|
7520
7525
|
};
|
|
7521
7526
|
// Annotate the CommonJS export names for ESM import in node:
|
|
7522
7527
|
0 && (module.exports = {
|
package/dist/index.mjs
CHANGED
|
@@ -4760,7 +4760,7 @@ var CircularLogo = ({ src, alt, fallbackText }) => {
|
|
|
4760
4760
|
onError: () => setHasError(true),
|
|
4761
4761
|
className: `w-full h-full object-cover transition-opacity duration-300 ${isLoaded ? "opacity-100" : "opacity-0"}`
|
|
4762
4762
|
}
|
|
4763
|
-
)) : /* @__PURE__ */ React48.createElement("span", { className: "text-xs text-black
|
|
4763
|
+
)) : /* @__PURE__ */ React48.createElement("span", { className: "text-xs text-black " }, fallbackText.substring(0, 2)));
|
|
4764
4764
|
};
|
|
4765
4765
|
var DEFAULT_NETWORK_REGEX = {
|
|
4766
4766
|
EVM: /^0x[a-fA-F0-9]{40}$/,
|
|
@@ -6341,7 +6341,7 @@ var HomeHuddleCalendar = ({
|
|
|
6341
6341
|
className: "w-8 h-8 flex items-center justify-center rounded-full border border-stone-200 hover:bg-stone-100 outline-none transition-colors"
|
|
6342
6342
|
},
|
|
6343
6343
|
/* @__PURE__ */ React54.createElement(HugeiconsIcon40, { icon: ArrowRight01Icon15, size: 16, className: "text-black" })
|
|
6344
|
-
))), /* @__PURE__ */ React54.createElement("div", { className: "grid grid-cols-7 gap-y-2 gap-x-1" }, DAYS_OF_WEEK2.map((d) => /* @__PURE__ */ React54.createElement("div", { key: d, className: "text-center text-[11px] text-stone-400 py-2
|
|
6344
|
+
))), /* @__PURE__ */ React54.createElement("div", { className: "grid grid-cols-7 gap-y-2 gap-x-1" }, DAYS_OF_WEEK2.map((d) => /* @__PURE__ */ React54.createElement("div", { key: d, className: "text-center text-[11px] text-stone-400 py-2 tracking-widest" }, d)), Array.from({ length: firstDayOffset }).map((_, i) => /* @__PURE__ */ React54.createElement("div", { key: `empty-${i}` })), Array.from({ length: daysInMonth }).map((_, i) => {
|
|
6345
6345
|
const day = i + 1;
|
|
6346
6346
|
const thisDate = new Date(viewYear, viewMonth, day);
|
|
6347
6347
|
const isSelected = selectedDate.getFullYear() === viewYear && selectedDate.getMonth() === viewMonth && selectedDate.getDate() === day;
|
|
@@ -6363,7 +6363,7 @@ var HomeHuddleCalendar = ({
|
|
|
6363
6363
|
dayEventsCount
|
|
6364
6364
|
)
|
|
6365
6365
|
));
|
|
6366
|
-
}))), /* @__PURE__ */ React54.createElement("div", { className: "flex flex-col gap-4 bg-white rounded-2xl p-6 relative min-h-37.5" }, /* @__PURE__ */ React54.createElement("div", { className: "flex items-center justify-between pb-4" }, /* @__PURE__ */ React54.createElement("h3", { className: "text-sm text-black " }, isSearching ? "Search Results" : `Events for ${selectedDate.toLocaleDateString("en-GB", { day: "numeric", month: "short", year: "numeric" })}`), /* @__PURE__ */ React54.createElement("span", { className: "text-[10px]
|
|
6366
|
+
}))), /* @__PURE__ */ React54.createElement("div", { className: "flex flex-col gap-4 bg-white rounded-2xl p-6 relative min-h-37.5" }, /* @__PURE__ */ React54.createElement("div", { className: "flex items-center justify-between pb-4" }, /* @__PURE__ */ React54.createElement("h3", { className: "text-sm text-black " }, isSearching ? "Search Results" : `Events for ${selectedDate.toLocaleDateString("en-GB", { day: "numeric", month: "short", year: "numeric" })}`), /* @__PURE__ */ React54.createElement("span", { className: "text-[10px] tracking-widest text-stone-400 " }, displayedEvents.length, " ", displayedEvents.length === 1 ? "Session" : "Sessions")), /* @__PURE__ */ React54.createElement("div", { className: "flex flex-col min-w-0 pt-2" }, isLoading ? /* @__PURE__ */ React54.createElement("div", { className: "py-8 flex flex-col items-center justify-center text-center" }, /* @__PURE__ */ React54.createElement(HugeiconsIcon40, { icon: Loading03Icon28, size: 28, className: "animate-spin text-stone-400" })) : displayedEvents.length === 0 ? /* @__PURE__ */ React54.createElement("div", { className: "py-8 flex flex-col items-center justify-center text-center" }, /* @__PURE__ */ React54.createElement("p", { className: "text-xs text-stone-400" }, isSearching ? "No sessions found for this search." : "No sessions scheduled for this date.")) : displayedEvents.map((huddle) => /* @__PURE__ */ React54.createElement(
|
|
6367
6367
|
"div",
|
|
6368
6368
|
{
|
|
6369
6369
|
key: huddle.id,
|
|
@@ -6373,7 +6373,7 @@ var HomeHuddleCalendar = ({
|
|
|
6373
6373
|
/* @__PURE__ */ React54.createElement(HuddleAvatar2, { timeString: huddle.timeString, status: huddle.status }),
|
|
6374
6374
|
/* @__PURE__ */ React54.createElement("div", { className: "flex flex-col min-w-0 flex-1" }, /* @__PURE__ */ React54.createElement("p", { className: "text-sm text-black tracking-tight truncate" }, huddle.name), /* @__PURE__ */ React54.createElement("span", { className: "text-[11px] text-stone-500 truncate block mt-1 tracking-wide" }, isSearching ? huddle.timeString : huddle.timeString.split("|")[1]?.trim() || huddle.timeString)),
|
|
6375
6375
|
/* @__PURE__ */ React54.createElement(HugeiconsIcon40, { icon: ArrowRight01Icon15, size: 14, className: "shrink-0 text-stone-400 group-hover:text-black transition-colors" })
|
|
6376
|
-
)))), huddles.length > 0 && !isLoading && /* @__PURE__ */ React54.createElement("div", { className: "flex items-center justify-between pt-6 mt-4 mb-2" }, /* @__PURE__ */ React54.createElement("span", { className: "text-[10px] text-stone-400 tracking-widest
|
|
6376
|
+
)))), huddles.length > 0 && !isLoading && /* @__PURE__ */ React54.createElement("div", { className: "flex items-center justify-between pt-6 mt-4 mb-2" }, /* @__PURE__ */ React54.createElement("span", { className: "text-[10px] text-stone-400 tracking-widest " }, "Page ", currentPage, " of ", totalPages === 0 ? 1 : totalPages), /* @__PURE__ */ React54.createElement("div", { className: "flex items-center gap-2" }, /* @__PURE__ */ React54.createElement(
|
|
6377
6377
|
"button",
|
|
6378
6378
|
{
|
|
6379
6379
|
onClick: () => onPageChange(currentPage - 1),
|
|
@@ -6415,7 +6415,7 @@ var formatType = (type) => {
|
|
|
6415
6415
|
return type.split("_").map((word) => word.charAt(0).toUpperCase() + word.slice(1).toLowerCase()).join(" ");
|
|
6416
6416
|
};
|
|
6417
6417
|
var ApplicationIcon = ({ icon, sizeClass = "w-10 h-10" }) => {
|
|
6418
|
-
return /* @__PURE__ */ React55.createElement("div", { className: `relative shrink-0 aspect-square ${sizeClass}` }, /* @__PURE__ */ React55.createElement("div", { className: "w-full h-full aspect-square rounded-lg bg-neutral-50 flex items-center justify-center overflow-hidden" }, icon ? /* @__PURE__ */ React55.createElement(HugeiconsIcon41, { icon, size:
|
|
6418
|
+
return /* @__PURE__ */ React55.createElement("div", { className: `relative shrink-0 aspect-square ${sizeClass}` }, /* @__PURE__ */ React55.createElement("div", { className: "w-full h-full aspect-square rounded-lg bg-neutral-50 flex items-center justify-center overflow-hidden" }, icon ? /* @__PURE__ */ React55.createElement(HugeiconsIcon41, { icon, size: 18, className: "text-stone-500" }) : /* @__PURE__ */ React55.createElement("div", { className: "w-4 h-4 rounded-sm bg-stone-300" })));
|
|
6419
6419
|
};
|
|
6420
6420
|
var PageSpinner9 = () => /* @__PURE__ */ React55.createElement("div", { className: "flex justify-center items-center py-12" }, /* @__PURE__ */ React55.createElement(HugeiconsIcon41, { icon: Loading03Icon29, size: 32, className: "animate-spin mb-4 text-black" }));
|
|
6421
6421
|
var UniversalApplicationsPage = ({
|
|
@@ -6441,7 +6441,7 @@ var UniversalApplicationsPage = ({
|
|
|
6441
6441
|
{
|
|
6442
6442
|
key: app.id,
|
|
6443
6443
|
onClick: () => onApplicationClick(app.id),
|
|
6444
|
-
className: "flex flex-row items-center gap-4 py-2 hover:bg-stone-50 transition-colors cursor-pointer group min-w-0 px-3 -mx-3 rounded-
|
|
6444
|
+
className: "flex flex-row items-center gap-4 py-2 hover:bg-stone-50 transition-colors cursor-pointer group min-w-0 px-3 -mx-3 rounded-full"
|
|
6445
6445
|
},
|
|
6446
6446
|
/* @__PURE__ */ React55.createElement(ApplicationIcon, { icon: app.icon }),
|
|
6447
6447
|
/* @__PURE__ */ React55.createElement("div", { className: "flex flex-col min-w-0 flex-1" }, /* @__PURE__ */ React55.createElement("p", { className: "text-sm text-black tracking-tight truncate" }, app.name || "Unnamed Application"), /* @__PURE__ */ React55.createElement("span", { className: "text-xs text-stone-500 truncate block mt-0.5" }, formatType(app.type), " ", /* @__PURE__ */ React55.createElement("span", { className: "mx-1 text-stone-300" }, "|"), " ", app.timeString)),
|
|
@@ -6698,6 +6698,7 @@ import React57, { useState as useState41 } from "react";
|
|
|
6698
6698
|
import Link10 from "next/link";
|
|
6699
6699
|
import { HugeiconsIcon as HugeiconsIcon43 } from "@hugeicons/react";
|
|
6700
6700
|
import {
|
|
6701
|
+
MenuCircleIcon,
|
|
6701
6702
|
LogoutCircle02Icon as LogoutCircle02Icon3
|
|
6702
6703
|
} from "@hugeicons/core-free-icons";
|
|
6703
6704
|
function RootSidebar({
|
|
@@ -6756,8 +6757,9 @@ function RootSidebar({
|
|
|
6756
6757
|
"button",
|
|
6757
6758
|
{
|
|
6758
6759
|
onClick: () => setIsSheetOpen(true),
|
|
6759
|
-
className: "md:hidden fixed bottom-6 left-1/2 -translate-x-1/2 z-40 bg-black text-white px-8 py-
|
|
6760
|
+
className: "md:hidden fixed bottom-6 left-1/2 -translate-x-1/2 z-40 bg-black text-white px-8 py-2 rounded-full shadow-xl flex items-center justify-center gap-2 text-xs tracking-wide outline-none active:scale-95 transition-transform"
|
|
6760
6761
|
},
|
|
6762
|
+
/* @__PURE__ */ React57.createElement(HugeiconsIcon43, { icon: MenuCircleIcon, size: 14 }),
|
|
6761
6763
|
"Open Menu"
|
|
6762
6764
|
), /* @__PURE__ */ React57.createElement(
|
|
6763
6765
|
"div",
|
|
@@ -6783,29 +6785,29 @@ function RootSidebar({
|
|
|
6783
6785
|
if (onNavClick) onNavClick(e, item.path);
|
|
6784
6786
|
setIsSheetOpen(false);
|
|
6785
6787
|
},
|
|
6786
|
-
className: `flex items-center gap-4 px-5 py-
|
|
6788
|
+
className: `flex items-center gap-4 px-5 py-3 rounded-full transition-colors outline-none ${isCurrentRoute ? "bg-[#fff5f2] text-[#d97757]" : "text-stone-600 hover:bg-stone-50"}`
|
|
6787
6789
|
},
|
|
6788
6790
|
/* @__PURE__ */ React57.createElement(
|
|
6789
6791
|
HugeiconsIcon43,
|
|
6790
6792
|
{
|
|
6791
6793
|
icon: item.icon,
|
|
6792
|
-
size:
|
|
6794
|
+
size: 18,
|
|
6793
6795
|
className: isCurrentRoute ? "text-[#d97757]" : "text-stone-400"
|
|
6794
6796
|
}
|
|
6795
6797
|
),
|
|
6796
|
-
/* @__PURE__ */ React57.createElement("span", { className: "text-
|
|
6798
|
+
/* @__PURE__ */ React57.createElement("span", { className: "text-xs tracking-wide" }, item.name)
|
|
6797
6799
|
);
|
|
6798
|
-
}), showLogoutAction && /* @__PURE__ */ React57.createElement("div",
|
|
6800
|
+
}), showLogoutAction && /* @__PURE__ */ React57.createElement("div", null, /* @__PURE__ */ React57.createElement(
|
|
6799
6801
|
"button",
|
|
6800
6802
|
{
|
|
6801
6803
|
onClick: () => {
|
|
6802
6804
|
setIsSheetOpen(false);
|
|
6803
6805
|
setShowLogoutDialog(true);
|
|
6804
6806
|
},
|
|
6805
|
-
className: "w-full flex items-center gap-4 px-5 py-
|
|
6807
|
+
className: "w-full flex items-center gap-4 px-5 py-3 rounded-full transition-colors outline-none text-red-600 hover:bg-red-50"
|
|
6806
6808
|
},
|
|
6807
|
-
/* @__PURE__ */ React57.createElement(HugeiconsIcon43, { icon: LogoutCircle02Icon3, size:
|
|
6808
|
-
/* @__PURE__ */ React57.createElement("span", { className: "text-
|
|
6809
|
+
/* @__PURE__ */ React57.createElement(HugeiconsIcon43, { icon: LogoutCircle02Icon3, size: 18, className: "text-red-500" }),
|
|
6810
|
+
/* @__PURE__ */ React57.createElement("span", { className: "text-xs tracking-wide" }, "Log Out")
|
|
6809
6811
|
)))
|
|
6810
6812
|
), showLogoutAction && /* @__PURE__ */ React57.createElement(
|
|
6811
6813
|
ConfirmationDialog,
|
|
@@ -7207,8 +7209,16 @@ var UniversalSettings2 = ({
|
|
|
7207
7209
|
|
|
7208
7210
|
// src/components/UniversalDeveloperSettings.tsx
|
|
7209
7211
|
import React59, { useState as useState43, useEffect as useEffect24 } from "react";
|
|
7210
|
-
import
|
|
7212
|
+
import toast19 from "react-hot-toast";
|
|
7213
|
+
import { HugeiconsIcon as HugeiconsIcon45 } from "@hugeicons/react";
|
|
7214
|
+
import {
|
|
7215
|
+
ArrowLeft01Icon as ArrowLeft01Icon24,
|
|
7216
|
+
CircleLock02Icon as CircleLock02Icon6,
|
|
7217
|
+
Loading03Icon as Loading03Icon32,
|
|
7218
|
+
RefreshIcon
|
|
7219
|
+
} from "@hugeicons/core-free-icons";
|
|
7211
7220
|
var UniversalDeveloperSettings = ({
|
|
7221
|
+
onBackHref = "/app",
|
|
7212
7222
|
initialPublicKey,
|
|
7213
7223
|
initialWebhookUrl,
|
|
7214
7224
|
isReadOnly = false,
|
|
@@ -7280,28 +7290,29 @@ AUDDITUR_SECRET_KEY="${secKey}"
|
|
|
7280
7290
|
};
|
|
7281
7291
|
const hasWebhookChanges = webhookUrl !== initialWebhookUrl;
|
|
7282
7292
|
const isWebhookSaveDisabled = isSavingWebhook || isReadOnly || !hasWebhookChanges;
|
|
7283
|
-
return /* @__PURE__ */ React59.createElement("div", { className: "
|
|
7293
|
+
return /* @__PURE__ */ React59.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React59.createElement(ManagedToaster, null), /* @__PURE__ */ React59.createElement("div", { className: "mb-6 flex w-full items-center px-1" }, /* @__PURE__ */ React59.createElement("a", { href: onBackHref, className: "flex items-center gap-2 text-[#d97757] hover:text-[#d97757] transition-colors text-sm outline-none" }, /* @__PURE__ */ React59.createElement(HugeiconsIcon45, { icon: ArrowLeft01Icon24, size: 16 }), " Back")), /* @__PURE__ */ React59.createElement("div", { className: "flex flex-col gap-1 mb-6 px-1" }, /* @__PURE__ */ React59.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Developer Settings"), /* @__PURE__ */ React59.createElement("p", { className: "text-xs text-stone-500" }, "Manage your API credentials and webhook integrations.")), /* @__PURE__ */ React59.createElement("div", { className: "flex flex-col gap-8 animate-in rounded-2xl p-6 bg-white fade-in duration-300" }, isReadOnly && /* @__PURE__ */ React59.createElement("div", { className: "flex items-start gap-3 p-4 bg-stone-50 rounded-xl" }, /* @__PURE__ */ React59.createElement(HugeiconsIcon45, { icon: CircleLock02Icon6, size: 20, className: "text-stone-500 shrink-0 mt-0.5" }), /* @__PURE__ */ React59.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ React59.createElement("span", { className: "text-sm text-black tracking-tight" }, "Access Restricted"), /* @__PURE__ */ React59.createElement("span", { className: "text-xs text-stone-500 mt-1 leading-relaxed" }, "You lack clearance to modify developer settings. Only Owners, Admins, or Managers can roll keys or update webhooks."))), /* @__PURE__ */ React59.createElement("div", { className: "flex flex-col gap-8" }, /* @__PURE__ */ React59.createElement("div", { className: "flex flex-col gap-6" }, /* @__PURE__ */ React59.createElement("div", { className: "w-full" }, /* @__PURE__ */ React59.createElement("div", { className: "relative w-full" }, /* @__PURE__ */ React59.createElement(
|
|
7284
7294
|
TextInput,
|
|
7285
7295
|
{
|
|
7286
7296
|
label: "Public Key",
|
|
7287
7297
|
value: publicKey || "No key generated yet",
|
|
7288
7298
|
onChange: () => {
|
|
7289
7299
|
},
|
|
7290
|
-
disabled: true
|
|
7300
|
+
disabled: true,
|
|
7301
|
+
placeholder: "pk_live_..."
|
|
7291
7302
|
}
|
|
7292
|
-
),
|
|
7293
|
-
|
|
7303
|
+
), !isReadOnly && /* @__PURE__ */ React59.createElement(
|
|
7304
|
+
"button",
|
|
7294
7305
|
{
|
|
7306
|
+
type: "button",
|
|
7295
7307
|
onClick: () => {
|
|
7296
7308
|
if (publicKey) setIsRollModalOpen(true);
|
|
7297
7309
|
else handleGenerateKeys();
|
|
7298
7310
|
},
|
|
7299
|
-
disabled: isGenerating
|
|
7300
|
-
|
|
7301
|
-
className: "w-fit"
|
|
7311
|
+
disabled: isGenerating,
|
|
7312
|
+
className: "absolute right-2.5 bottom-2.5 w-7 h-7 rounded-lg border border-stone-200 bg-white flex items-center justify-center text-stone-500 hover:text-black hover:border-stone-300 transition-all outline-none shadow-sm disabled:opacity-50"
|
|
7302
7313
|
},
|
|
7303
|
-
|
|
7304
|
-
))), /* @__PURE__ */ React59.createElement("form", { className: "flex flex-col gap-6
|
|
7314
|
+
isGenerating ? /* @__PURE__ */ React59.createElement(HugeiconsIcon45, { icon: Loading03Icon32, size: 14, className: "animate-spin" }) : /* @__PURE__ */ React59.createElement(HugeiconsIcon45, { icon: RefreshIcon, size: 14 })
|
|
7315
|
+
)), /* @__PURE__ */ React59.createElement("p", { className: "text-xs text-stone-500 mt-2 leading-relaxed" }, "Your public key is used to identify your application. Your secret key will only be shown once upon generation."))), /* @__PURE__ */ React59.createElement("form", { className: "flex flex-col gap-6 pt-8", onSubmit: handleSaveWebhook, autoComplete: "off" }, /* @__PURE__ */ React59.createElement("div", { className: "space-y-1.5 w-full" }, /* @__PURE__ */ React59.createElement(
|
|
7305
7316
|
TextInput,
|
|
7306
7317
|
{
|
|
7307
7318
|
label: "Webhook URL",
|
|
@@ -7311,29 +7322,29 @@ AUDDITUR_SECRET_KEY="${secKey}"
|
|
|
7311
7322
|
placeholder: "https://your-domain.com/webhook",
|
|
7312
7323
|
type: "url"
|
|
7313
7324
|
}
|
|
7314
|
-
), /* @__PURE__ */ React59.createElement("
|
|
7315
|
-
"button",
|
|
7316
|
-
{
|
|
7317
|
-
type: "button",
|
|
7318
|
-
onClick: () => setWebhookUrl(initialWebhookUrl),
|
|
7319
|
-
className: "text-[11px] tracking-widest text-neutral-500 hover:text-black transition-colors w-full sm:w-auto py-2 sm:py-0 outline-none"
|
|
7320
|
-
},
|
|
7321
|
-
"Cancel"
|
|
7322
|
-
), /* @__PURE__ */ React59.createElement(
|
|
7325
|
+
), /* @__PURE__ */ React59.createElement("div", { className: "flex flex-col sm:flex-row sm:items-center justify-between mt-2 gap-2" }, /* @__PURE__ */ React59.createElement("p", { className: "text-xs text-stone-500 leading-relaxed" }, "We will send secure POST requests to this endpoint when significant events occur. Must use HTTPS."), /* @__PURE__ */ React59.createElement("span", { className: `text-[10px] tracking-widest ${webhookUrl ? "text-emerald-600" : "text-stone-400"}` }, webhookUrl ? "Active" : "Inactive"))), /* @__PURE__ */ React59.createElement("div", { className: "flex items-center gap-3" }, /* @__PURE__ */ React59.createElement(
|
|
7323
7326
|
ThreeDActionButton,
|
|
7324
7327
|
{
|
|
7325
7328
|
type: "submit",
|
|
7326
7329
|
disabled: isWebhookSaveDisabled,
|
|
7327
7330
|
isLoading: isSavingWebhook,
|
|
7328
|
-
className: "
|
|
7331
|
+
className: "w-full sm:w-auto min-w-40"
|
|
7329
7332
|
},
|
|
7330
7333
|
"Save Webhook"
|
|
7334
|
+
), hasWebhookChanges && !isSavingWebhook && !isReadOnly && /* @__PURE__ */ React59.createElement(
|
|
7335
|
+
"button",
|
|
7336
|
+
{
|
|
7337
|
+
type: "button",
|
|
7338
|
+
onClick: () => setWebhookUrl(initialWebhookUrl),
|
|
7339
|
+
className: "px-4 py-2 text-stone-500 hover:text-black transition-colors outline-none text-xs "
|
|
7340
|
+
},
|
|
7341
|
+
"Cancel"
|
|
7331
7342
|
))))), /* @__PURE__ */ React59.createElement(
|
|
7332
7343
|
ConfirmationDialog,
|
|
7333
7344
|
{
|
|
7334
7345
|
isOpen: isRollModalOpen && !isReadOnly,
|
|
7335
7346
|
title: "Roll API Keys",
|
|
7336
|
-
message: "Are you sure you want to roll your keys? This will permanently invalidate your current secret key and active
|
|
7347
|
+
message: "Are you sure you want to roll your keys? This will permanently invalidate your current secret key and active integrations.",
|
|
7337
7348
|
confirmText: "Roll Keys",
|
|
7338
7349
|
cancelText: "Cancel",
|
|
7339
7350
|
isProcessing: isGenerating,
|
|
@@ -7346,7 +7357,7 @@ AUDDITUR_SECRET_KEY="${secKey}"
|
|
|
7346
7357
|
|
|
7347
7358
|
// src/components/UniversalApplicationPage2.tsx
|
|
7348
7359
|
import React60, { useState as useState44, useRef as useRef18 } from "react";
|
|
7349
|
-
import { HugeiconsIcon as
|
|
7360
|
+
import { HugeiconsIcon as HugeiconsIcon46 } from "@hugeicons/react";
|
|
7350
7361
|
import {
|
|
7351
7362
|
Search01Icon as Search01Icon9,
|
|
7352
7363
|
SearchList02Icon as SearchList02Icon4
|
|
@@ -7385,7 +7396,7 @@ var UniversalApplicationPage2 = ({
|
|
|
7385
7396
|
"REJECTED",
|
|
7386
7397
|
"QUERIED"
|
|
7387
7398
|
];
|
|
7388
|
-
return /* @__PURE__ */ React60.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React60.createElement("div", { className: "flex flex-col gap-1 mb-8 px-1" }, /* @__PURE__ */ React60.createElement("div", { className: "flex items-center" }, /* @__PURE__ */ React60.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Applications Directory")), /* @__PURE__ */ React60.createElement("p", { className: "text-xs text-stone-500" }, "Search, filter, and track all your organizational applications.")), /* @__PURE__ */ React60.createElement("div", { className: "flex flex-row flex-nowrap mb-2 items-center justify-between gap-4 w-full px-1" }, /* @__PURE__ */ React60.createElement("div", { className: "relative flex-1 min-w-0 max-w-full" }, /* @__PURE__ */ React60.createElement("div", { className: "absolute inset-y-0 left-0 pl-4 flex items-center pointer-events-none" }, /* @__PURE__ */ React60.createElement(
|
|
7399
|
+
return /* @__PURE__ */ React60.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React60.createElement("div", { className: "flex flex-col gap-1 mb-8 px-1" }, /* @__PURE__ */ React60.createElement("div", { className: "flex items-center" }, /* @__PURE__ */ React60.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Applications Directory")), /* @__PURE__ */ React60.createElement("p", { className: "text-xs text-stone-500" }, "Search, filter, and track all your organizational applications.")), /* @__PURE__ */ React60.createElement("div", { className: "flex flex-row flex-nowrap mb-2 items-center justify-between gap-4 w-full px-1" }, /* @__PURE__ */ React60.createElement("div", { className: "relative flex-1 min-w-0 max-w-full" }, /* @__PURE__ */ React60.createElement("div", { className: "absolute inset-y-0 left-0 pl-4 flex items-center pointer-events-none" }, /* @__PURE__ */ React60.createElement(HugeiconsIcon46, { icon: Search01Icon9, size: 16, className: "text-stone-400" })), /* @__PURE__ */ React60.createElement(
|
|
7389
7400
|
"input",
|
|
7390
7401
|
{
|
|
7391
7402
|
type: "text",
|
|
@@ -7400,7 +7411,7 @@ var UniversalApplicationPage2 = ({
|
|
|
7400
7411
|
onClick: () => setShowStatusModal(true),
|
|
7401
7412
|
className: "flex items-center justify-center bg-white shadow-[0_2px_10px_rgba(0,0,0,0.02)] w-10 h-10 rounded-full text-stone-500 hover:text-black transition-colors outline-none relative"
|
|
7402
7413
|
},
|
|
7403
|
-
/* @__PURE__ */ React60.createElement(
|
|
7414
|
+
/* @__PURE__ */ React60.createElement(HugeiconsIcon46, { icon: SearchList02Icon4, size: 18 }),
|
|
7404
7415
|
activeStatusFilter !== "ALL" && /* @__PURE__ */ React60.createElement("span", { className: "absolute top-2 right-2 w-2 h-2 bg-[#d97757] rounded-full border border-white" })
|
|
7405
7416
|
))), /* @__PURE__ */ React60.createElement("div", { className: "w-full mt-2" }, /* @__PURE__ */ React60.createElement(
|
|
7406
7417
|
UniversalApplicationsPage,
|
|
@@ -7433,8 +7444,8 @@ var UniversalApplicationPage2 = ({
|
|
|
7433
7444
|
|
|
7434
7445
|
// src/components/UniversalApplicationDetails.tsx
|
|
7435
7446
|
import React61, { useState as useState45 } from "react";
|
|
7436
|
-
import { HugeiconsIcon as
|
|
7437
|
-
import { ArrowLeft01Icon as
|
|
7447
|
+
import { HugeiconsIcon as HugeiconsIcon47 } from "@hugeicons/react";
|
|
7448
|
+
import { ArrowLeft01Icon as ArrowLeft01Icon25 } from "@hugeicons/core-free-icons";
|
|
7438
7449
|
var formatType2 = (type) => type.split("_").map((w) => w[0] + w.slice(1).toLowerCase()).join(" ");
|
|
7439
7450
|
var UniversalApplicationDetails = ({
|
|
7440
7451
|
onBackHref,
|
|
@@ -7461,26 +7472,26 @@ var UniversalApplicationDetails = ({
|
|
|
7461
7472
|
isOpen: confirmDialog,
|
|
7462
7473
|
title: "Delete Application",
|
|
7463
7474
|
message: "Are you sure you want to permanently delete this application and its assets? This action cannot be undone.",
|
|
7464
|
-
confirmText: "Delete
|
|
7475
|
+
confirmText: "Delete",
|
|
7465
7476
|
cancelText: "Cancel",
|
|
7466
7477
|
isProcessing: isDeleting,
|
|
7467
7478
|
isDestructive: true,
|
|
7468
7479
|
onClose: () => setConfirmDialog(false),
|
|
7469
7480
|
onConfirm: handleDelete
|
|
7470
7481
|
}
|
|
7471
|
-
), /* @__PURE__ */ React61.createElement("div", { className: "mb-6 flex w-full items-center px-1" }, /* @__PURE__ */ React61.createElement("a", { href: onBackHref, className: "flex items-center gap-2 text-[#d97757] hover:text-[#d97757] transition-colors text-sm outline-none" }, /* @__PURE__ */ React61.createElement(
|
|
7482
|
+
), /* @__PURE__ */ React61.createElement("div", { className: "mb-6 flex w-full items-center px-1" }, /* @__PURE__ */ React61.createElement("a", { href: onBackHref, className: "flex items-center gap-2 text-[#d97757] hover:text-[#d97757] transition-colors text-sm outline-none" }, /* @__PURE__ */ React61.createElement(HugeiconsIcon47, { icon: ArrowLeft01Icon25, size: 16 }), " Back")), /* @__PURE__ */ React61.createElement("div", { className: "mb-8 px-1 flex flex-col sm:flex-row sm:items-center justify-between gap-4" }, /* @__PURE__ */ React61.createElement("div", null, /* @__PURE__ */ React61.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Application Details"), /* @__PURE__ */ React61.createElement("p", { className: "text-xs text-stone-500" }, "Review your filing entity and access its workspace.")), /* @__PURE__ */ React61.createElement("div", { className: "px-4 py-1.5 bg-stone-200 text-stone-600 rounded-full text-xs self-start sm:self-auto tracking-widest " }, application.status)), /* @__PURE__ */ React61.createElement("div", { className: "flex flex-col gap-8 animate-in rounded-2xl p-6 bg-white fade-in duration-300" }, /* @__PURE__ */ React61.createElement("div", { className: "flex flex-col gap-1 w-full" }, /* @__PURE__ */ React61.createElement("label", { className: "text-xs text-stone-400 tracking-[0.2em] block" }, "Target Company"), /* @__PURE__ */ React61.createElement("span", { className: "text-sm text-black py-2 " }, application.name)), /* @__PURE__ */ React61.createElement("div", { className: "flex flex-col gap-1 w-full border-t border-stone-100 pt-6" }, /* @__PURE__ */ React61.createElement("label", { className: "text-xs text-stone-400 tracking-[0.2em] block" }, "Filing Type"), /* @__PURE__ */ React61.createElement("span", { className: "text-sm text-black py-2" }, formatType2(application.type))), /* @__PURE__ */ React61.createElement("div", { className: "flex flex-col sm:flex-row items-center gap-3 pt-6 mt-2 border-t border-stone-100" }, /* @__PURE__ */ React61.createElement("a", { href: `/app/applications/app/${application.id}`, className: "flex-1 w-full py-2.5 bg-[#d97757] text-white rounded-full text-center text-xs transition-colors hover:bg-[#d97757]/90" }, "Open Application"), /* @__PURE__ */ React61.createElement("a", { href: `/app/applications/assets/${application.id}`, className: "flex-1 w-full py-2.5 bg-transparent border border-stone-200 text-black rounded-full text-center text-xs transition-colors hover:bg-stone-50" }, "Application Assets"), deletePermitted && /* @__PURE__ */ React61.createElement("button", { onClick: () => setConfirmDialog(true), className: "flex-1 w-full py-2.5 bg-transparent border border-stone-200 text-black rounded-full text-center text-xs transition-colors hover:bg-stone-50" }, "Delete Application"))));
|
|
7472
7483
|
};
|
|
7473
7484
|
|
|
7474
7485
|
// src/components/UniversalCreateApplication.tsx
|
|
7475
7486
|
import React62, { useState as useState46, useRef as useRef19, useEffect as useEffect25 } from "react";
|
|
7476
7487
|
import toast20 from "react-hot-toast";
|
|
7477
|
-
import { HugeiconsIcon as
|
|
7488
|
+
import { HugeiconsIcon as HugeiconsIcon48 } from "@hugeicons/react";
|
|
7478
7489
|
import {
|
|
7479
|
-
ArrowLeft01Icon as
|
|
7490
|
+
ArrowLeft01Icon as ArrowLeft01Icon26,
|
|
7480
7491
|
ArrowRight01Icon as ArrowRight01Icon19,
|
|
7481
|
-
Loading03Icon as
|
|
7492
|
+
Loading03Icon as Loading03Icon33,
|
|
7482
7493
|
Search01Icon as Search01Icon10,
|
|
7483
|
-
CircleLock02Icon as
|
|
7494
|
+
CircleLock02Icon as CircleLock02Icon7,
|
|
7484
7495
|
CheckmarkCircle02Icon as CheckmarkCircle02Icon2,
|
|
7485
7496
|
Building03Icon,
|
|
7486
7497
|
File02Icon,
|
|
@@ -7490,7 +7501,7 @@ var MemberAvatar6 = ({ src, sizeClass = "w-10 h-10" }) => {
|
|
|
7490
7501
|
const [loaded, setLoaded] = useState46(false);
|
|
7491
7502
|
const [error, setError] = useState46(false);
|
|
7492
7503
|
const defaultAvatar = "https://storage.googleapis.com/retina-cloud-v2/assets/images/avatar.avif";
|
|
7493
|
-
return /* @__PURE__ */ React62.createElement("div", { className: `relative shrink-0 ${sizeClass}` }, /* @__PURE__ */ React62.createElement("div", { className: "w-full h-full rounded-lg bg-stone-100 flex items-center justify-center overflow-hidden" }, !loaded && !error && /* @__PURE__ */ React62.createElement(
|
|
7504
|
+
return /* @__PURE__ */ React62.createElement("div", { className: `relative shrink-0 ${sizeClass}` }, /* @__PURE__ */ React62.createElement("div", { className: "w-full h-full rounded-lg bg-stone-100 flex items-center justify-center overflow-hidden" }, !loaded && !error && /* @__PURE__ */ React62.createElement(HugeiconsIcon48, { icon: Loading03Icon33, className: "animate-spin text-stone-400 absolute", size: 14 }), /* @__PURE__ */ React62.createElement("img", { src: error || !src ? defaultAvatar : src, alt: "Avatar", className: `w-full h-full object-cover transition-opacity duration-300 ${loaded || error ? "opacity-100" : "opacity-0"}`, onLoad: () => setLoaded(true), onError: () => setError(true) })));
|
|
7494
7505
|
};
|
|
7495
7506
|
var UniversalCreateApplication = ({
|
|
7496
7507
|
onBackHref,
|
|
@@ -7581,7 +7592,7 @@ var UniversalCreateApplication = ({
|
|
|
7581
7592
|
{ id: "EXISTING", label: "Select Company" },
|
|
7582
7593
|
{ id: "NEW", label: "New Company" }
|
|
7583
7594
|
];
|
|
7584
|
-
return /* @__PURE__ */ React62.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React62.createElement(ManagedToaster, null), /* @__PURE__ */ React62.createElement("div", { className: "mb-6 flex w-full items-center px-1" }, /* @__PURE__ */ React62.createElement("a", { href: onBackHref, className: "flex items-center gap-2 text-[#d97757] hover:text-[#d97757] transition-colors text-sm outline-none" }, /* @__PURE__ */ React62.createElement(
|
|
7595
|
+
return /* @__PURE__ */ React62.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React62.createElement(ManagedToaster, null), /* @__PURE__ */ React62.createElement("div", { className: "mb-6 flex w-full items-center px-1" }, /* @__PURE__ */ React62.createElement("a", { href: onBackHref, className: "flex items-center gap-2 text-[#d97757] hover:text-[#d97757] transition-colors text-sm outline-none" }, /* @__PURE__ */ React62.createElement(HugeiconsIcon48, { icon: ArrowLeft01Icon26, size: 16 }), " Back")), /* @__PURE__ */ React62.createElement("div", { className: "flex flex-col gap-1 mb-6 px-1" }, /* @__PURE__ */ React62.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Create Application"), /* @__PURE__ */ React62.createElement("p", { className: "text-xs text-stone-500" }, "Initiate a new registration or filing for a company.")), /* @__PURE__ */ React62.createElement("div", { className: "flex items-center mb-4 w-full animate-in fade-in duration-300 px-2" }, /* @__PURE__ */ React62.createElement("div", { className: "flex items-center bg-white rounded-full p-1 sm:p-1.5 max-w-full overflow-x-auto custom-scrollbar" }, modeTabs.map((tab) => {
|
|
7585
7596
|
const isActive = creationMode === tab.id;
|
|
7586
7597
|
return /* @__PURE__ */ React62.createElement(
|
|
7587
7598
|
"button",
|
|
@@ -7594,7 +7605,7 @@ var UniversalCreateApplication = ({
|
|
|
7594
7605
|
},
|
|
7595
7606
|
tab.label
|
|
7596
7607
|
);
|
|
7597
|
-
}))), /* @__PURE__ */ React62.createElement("div", { className: "flex flex-col gap-8 animate-in rounded-2xl p-6 bg-white fade-in duration-300" }, /* @__PURE__ */ React62.createElement("form", { className: "flex flex-col gap-8", onSubmit: handleSubmit, autoComplete: "off" }, !canManage && /* @__PURE__ */ React62.createElement("div", { className: "flex items-start gap-3 p-4 bg-stone-50 rounded-xl" }, /* @__PURE__ */ React62.createElement(
|
|
7608
|
+
}))), /* @__PURE__ */ React62.createElement("div", { className: "flex flex-col gap-8 animate-in rounded-2xl p-6 bg-white fade-in duration-300" }, /* @__PURE__ */ React62.createElement("form", { className: "flex flex-col gap-8", onSubmit: handleSubmit, autoComplete: "off" }, !canManage && /* @__PURE__ */ React62.createElement("div", { className: "flex items-start gap-3 p-4 bg-stone-50 rounded-xl" }, /* @__PURE__ */ React62.createElement(HugeiconsIcon48, { icon: CircleLock02Icon7, size: 20, className: "text-stone-500 shrink-0 mt-0.5" }), /* @__PURE__ */ React62.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ React62.createElement("span", { className: "text-sm text-black tracking-tight" }, "Access Restricted"), /* @__PURE__ */ React62.createElement("span", { className: "text-xs text-stone-500 mt-1 leading-relaxed" }, "You lack clearance to create applications."))), creationMode === "EXISTING" ? /* @__PURE__ */ React62.createElement("div", { className: "space-y-1.5 w-full" }, /* @__PURE__ */ React62.createElement("label", { className: "text-xs text-stone-400 tracking-[0.2em] block" }, "Target Company"), /* @__PURE__ */ React62.createElement("div", { onClick: () => canManage && !isSubmitting && setShowCompaniesModal(true), className: `flex items-center relative w-full border-b border-stone-200 transition-all duration-300 pb-3 pt-3 ${!canManage || isSubmitting ? "opacity-50 pointer-events-none" : "hover:border-black cursor-pointer"}` }, /* @__PURE__ */ React62.createElement(HugeiconsIcon48, { icon: Building03Icon, size: 16, className: "text-stone-400 absolute left-0" }), /* @__PURE__ */ React62.createElement("span", { className: `w-full pl-8 text-sm truncate block ${activeCompany ? "text-black" : "text-stone-400"}` }, activeCompany ? activeCompany.name : "Select an existing company..."))) : /* @__PURE__ */ React62.createElement(React62.Fragment, null, /* @__PURE__ */ React62.createElement(TextInput, { label: "Company Name", value: newCompanyName, onChange: (val) => setNewCompanyName(val), disabled: isSubmitting || !canManage, placeholder: "e.g. Acme Innovations Ltd.", maxLength: 80 }), /* @__PURE__ */ React62.createElement("div", { className: `flex items-center justify-between py-2 mt-2 ${!canManage ? "opacity-50 pointer-events-none" : ""}` }, /* @__PURE__ */ React62.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ React62.createElement("span", { className: "text-sm text-black tracking-tight" }, "Private Company"), /* @__PURE__ */ React62.createElement("span", { className: "text-xs text-stone-500" }, "Only assigned members can view and access its applications.")), /* @__PURE__ */ React62.createElement("button", { type: "button", onClick: () => setIsPrivate(!isPrivate), disabled: !canManage || isSubmitting, className: `relative w-11 h-6 rounded-full transition-colors outline-none shrink-0 ${isPrivate ? "bg-[#d97757]" : "bg-stone-200"}` }, /* @__PURE__ */ React62.createElement("div", { className: `absolute top-1 left-1 bg-white w-4 h-4 rounded-full transition-transform ${isPrivate ? "translate-x-5" : "translate-x-0"}` }))), isPrivate && /* @__PURE__ */ React62.createElement("div", { className: `flex items-center justify-between animate-in fade-in zoom-in-95 duration-200 bg-stone-50 p-4 rounded-xl ${!canManage ? "opacity-50" : ""}` }, /* @__PURE__ */ React62.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ React62.createElement("span", { className: "text-xs text-black tracking-tight" }, "Members"), /* @__PURE__ */ React62.createElement("span", { className: "text-xs text-[#d97757]" }, selectedParticipants.size, " added")), /* @__PURE__ */ React62.createElement("button", { type: "button", onClick: () => setShowMembersModal(true), disabled: !canManage || isSubmitting, className: "px-4 py-2 border border-stone-200 text-black text-xs tracking-wide rounded-full hover:bg-white transition-colors outline-none bg-transparent" }, "Manage Access"))), /* @__PURE__ */ React62.createElement("div", { className: "space-y-1.5 w-full" }, /* @__PURE__ */ React62.createElement("label", { className: "text-xs text-stone-400 tracking-[0.2em] block" }, "Application Type"), /* @__PURE__ */ React62.createElement("div", { onClick: () => canManage && !isSubmitting && setShowTypeModal(true), className: `flex items-center relative w-full border-b border-stone-200 transition-all duration-300 pb-3 pt-3 ${!canManage || isSubmitting ? "opacity-50 pointer-events-none" : "hover:border-black cursor-pointer"}` }, /* @__PURE__ */ React62.createElement(HugeiconsIcon48, { icon: File02Icon, size: 16, className: "text-stone-400 absolute left-0" }), /* @__PURE__ */ React62.createElement("span", { className: "w-full pl-8 text-sm text-black truncate block" }, activeTypeObj?.label || "Select Type..."))), canManage && /* @__PURE__ */ React62.createElement("div", { className: "pt-6" }, /* @__PURE__ */ React62.createElement(ThreeDActionButton, { type: "submit", disabled: isSubmitting || !selectedTypeKey || creationMode === "EXISTING" && !selectedCompanyId || creationMode === "NEW" && newCompanyName.length < 2, isLoading: isSubmitting, className: "w-full sm:w-auto min-w-40" }, "Create Application")))), showTypeModal && canManage && /* @__PURE__ */ React62.createElement("div", { className: "fixed inset-0 z-120 flex items-center justify-center p-4 pointer-events-auto" }, /* @__PURE__ */ React62.createElement("div", { className: "absolute inset-0 bg-black/30", onClick: () => setShowTypeModal(false) }), /* @__PURE__ */ React62.createElement("div", { className: "relative w-full max-w-md bg-white rounded-2xl flex flex-col overflow-hidden shadow-2xl animate-in zoom-in-95 duration-200 h-[80vh]" }, /* @__PURE__ */ React62.createElement("div", { className: "flex items-center justify-between p-5 shrink-0" }, /* @__PURE__ */ React62.createElement("h3", { className: "text-sm text-black tracking-tight " }, "Application Type"), /* @__PURE__ */ React62.createElement("button", { onClick: () => setShowTypeModal(false), className: "text-[#d97757] outline-none text-sm" }, "Done")), /* @__PURE__ */ React62.createElement("div", { className: "flex-1 overflow-y-auto custom-scrollbar p-3 space-y-2" }, applicationTypesMeta.map((item) => {
|
|
7598
7609
|
const isSelected = selectedTypeKey === item.key;
|
|
7599
7610
|
return /* @__PURE__ */ React62.createElement(
|
|
7600
7611
|
"div",
|
|
@@ -7605,15 +7616,15 @@ var UniversalCreateApplication = ({
|
|
|
7605
7616
|
},
|
|
7606
7617
|
className: `p-4 rounded-xl cursor-pointer transition-all border ${isSelected ? "bg-white border-[#d97757]" : "bg-stone-50 border-transparent hover:bg-stone-100/60"}`
|
|
7607
7618
|
},
|
|
7608
|
-
/* @__PURE__ */ React62.createElement("div", { className: "flex items-center justify-between gap-2" }, /* @__PURE__ */ React62.createElement("h4", { className: "text-xs text-black" }, item.label), isSelected && /* @__PURE__ */ React62.createElement(
|
|
7619
|
+
/* @__PURE__ */ React62.createElement("div", { className: "flex items-center justify-between gap-2" }, /* @__PURE__ */ React62.createElement("h4", { className: "text-xs text-black" }, item.label), isSelected && /* @__PURE__ */ React62.createElement(HugeiconsIcon48, { icon: CheckmarkCircle02Icon2, size: 16, className: "text-[#d97757] shrink-0" })),
|
|
7609
7620
|
/* @__PURE__ */ React62.createElement("p", { className: "text-[11px] text-stone-500 mt-1 leading-relaxed whitespace-normal wrap-break-word" }, item.desc)
|
|
7610
7621
|
);
|
|
7611
|
-
})))), showCompaniesModal && canManage && /* @__PURE__ */ React62.createElement("div", { className: "fixed inset-0 z-120 flex items-center justify-center p-4 pointer-events-auto" }, /* @__PURE__ */ React62.createElement("div", { className: "absolute inset-0 bg-black/30", onClick: () => setShowCompaniesModal(false) }), /* @__PURE__ */ React62.createElement("div", { className: "relative w-full max-w-md bg-white rounded-2xl flex flex-col overflow-hidden shadow-2xl animate-in zoom-in-95 duration-200 h-[80vh]" }, /* @__PURE__ */ React62.createElement("div", { className: "flex items-center justify-between p-5 shrink-0" }, /* @__PURE__ */ React62.createElement("h3", { className: "text-sm text-black tracking-tight" }, "Select Company"), /* @__PURE__ */ React62.createElement("button", { onClick: () => setShowCompaniesModal(false), className: "text-[#d97757] outline-none text-sm" }, "Done")), /* @__PURE__ */ React62.createElement("div", { className: "p-4 shrink-0" }, /* @__PURE__ */ React62.createElement("div", { className: "relative w-full" }, /* @__PURE__ */ React62.createElement(
|
|
7622
|
+
})))), showCompaniesModal && canManage && /* @__PURE__ */ React62.createElement("div", { className: "fixed inset-0 z-120 flex items-center justify-center p-4 pointer-events-auto" }, /* @__PURE__ */ React62.createElement("div", { className: "absolute inset-0 bg-black/30", onClick: () => setShowCompaniesModal(false) }), /* @__PURE__ */ React62.createElement("div", { className: "relative w-full max-w-md bg-white rounded-2xl flex flex-col overflow-hidden shadow-2xl animate-in zoom-in-95 duration-200 h-[80vh]" }, /* @__PURE__ */ React62.createElement("div", { className: "flex items-center justify-between p-5 shrink-0" }, /* @__PURE__ */ React62.createElement("h3", { className: "text-sm text-black tracking-tight" }, "Select Company"), /* @__PURE__ */ React62.createElement("button", { onClick: () => setShowCompaniesModal(false), className: "text-[#d97757] outline-none text-sm" }, "Done")), /* @__PURE__ */ React62.createElement("div", { className: "p-4 shrink-0" }, /* @__PURE__ */ React62.createElement("div", { className: "relative w-full" }, /* @__PURE__ */ React62.createElement(HugeiconsIcon48, { icon: Search01Icon10, size: 16, className: "text-stone-400 absolute left-4 top-1/2 -translate-y-1/2 pointer-events-none" }), /* @__PURE__ */ React62.createElement("input", { type: "text", placeholder: "Search companies...", value: localCompSearch, onChange: handleCompSearch, className: "w-full pl-10 pr-4 py-2.5 bg-stone-100 rounded-full focus:border-[#d97757] border border-transparent text-sm text-black outline-none focus:bg-stone-50 transition-colors" }))), /* @__PURE__ */ React62.createElement("div", { className: "flex-1 overflow-y-auto custom-scrollbar p-2" }, isCompaniesLoading ? /* @__PURE__ */ React62.createElement("div", { className: "absolute inset-0 flex items-center justify-center" }, /* @__PURE__ */ React62.createElement(HugeiconsIcon48, { icon: Loading03Icon33, size: 28, className: "animate-spin text-black" })) : companies.length === 0 ? /* @__PURE__ */ React62.createElement("div", { className: "p-8 text-center text-xs text-stone-400" }, "No companies available.") : companies.map((comp) => /* @__PURE__ */ React62.createElement("div", { key: comp.id, onClick: () => {
|
|
7612
7623
|
setSelectedCompanyId(comp.id);
|
|
7613
|
-
}, className: "flex items-center justify-between p-3 rounded-xl cursor-pointer hover:bg-stone-50 transition-colors" }, /* @__PURE__ */ React62.createElement("div", { className: "flex flex-col min-w-0 flex-1 pl-2" }, /* @__PURE__ */ React62.createElement("span", { className: "text-sm text-black truncate" }, comp.name), /* @__PURE__ */ React62.createElement("div", { className: "flex items-center gap-2 mt-0.5" }, /* @__PURE__ */ React62.createElement("span", { className: "text-[10px] text-stone-500 tracking-widest
|
|
7624
|
+
}, className: "flex items-center justify-between p-3 rounded-xl cursor-pointer hover:bg-stone-50 transition-colors" }, /* @__PURE__ */ React62.createElement("div", { className: "flex flex-col min-w-0 flex-1 pl-2" }, /* @__PURE__ */ React62.createElement("span", { className: "text-sm text-black truncate" }, comp.name), /* @__PURE__ */ React62.createElement("div", { className: "flex items-center gap-2 mt-0.5" }, /* @__PURE__ */ React62.createElement("span", { className: "text-[10px] text-stone-500 tracking-widest " }, "Applications: ", comp.applicationsCount || 0), comp.isPrivate && /* @__PURE__ */ React62.createElement("span", { className: "text-[10px] text-[#d97757] tracking-widest " }, "Private"))), selectedCompanyId === comp.id && /* @__PURE__ */ React62.createElement(HugeiconsIcon48, { icon: CheckmarkCircle02Icon2, size: 16, className: "text-[#d97757] mr-2" })))), /* @__PURE__ */ React62.createElement("div", { className: "p-4 flex items-center justify-between shrink-0 bg-white" }, /* @__PURE__ */ React62.createElement("span", { className: "text-xs text-stone-400 tracking-widest" }, "Page ", companiesCurrentPage, " of ", companiesTotalPages || 1), /* @__PURE__ */ React62.createElement("div", { className: "flex gap-1" }, /* @__PURE__ */ React62.createElement("button", { disabled: companiesCurrentPage <= 1 || isCompaniesLoading, onClick: () => onCompaniesPageChange(companiesCurrentPage - 1), className: "w-7 h-7 flex items-center justify-center rounded-full bg-white border border-stone-200 text-stone-600 disabled:opacity-30 outline-none hover:bg-stone-50" }, /* @__PURE__ */ React62.createElement(HugeiconsIcon48, { icon: ArrowLeft01Icon26, size: 12 })), /* @__PURE__ */ React62.createElement("button", { disabled: companiesCurrentPage >= companiesTotalPages || isCompaniesLoading, onClick: () => onCompaniesPageChange(companiesCurrentPage + 1), className: "w-7 h-7 flex items-center justify-center rounded-full bg-white border border-stone-200 text-stone-600 disabled:opacity-30 outline-none hover:bg-stone-50" }, /* @__PURE__ */ React62.createElement(HugeiconsIcon48, { icon: ArrowRight01Icon19, size: 12 })))))), showMembersModal && canManage && /* @__PURE__ */ React62.createElement("div", { className: "fixed inset-0 z-120 flex items-center justify-center p-4 pointer-events-auto" }, /* @__PURE__ */ React62.createElement("div", { className: "absolute inset-0 bg-black/30", onClick: () => setShowMembersModal(false) }), /* @__PURE__ */ React62.createElement("div", { className: "relative w-full max-w-md bg-white rounded-2xl flex flex-col overflow-hidden shadow-2xl animate-in zoom-in-95 duration-200 h-[80vh]" }, /* @__PURE__ */ React62.createElement("div", { className: "flex items-center justify-between p-5 shrink-0" }, /* @__PURE__ */ React62.createElement("h3", { className: "text-sm text-black tracking-tight" }, "Assign Members"), /* @__PURE__ */ React62.createElement("button", { onClick: () => setShowMembersModal(false), className: "text-[#d97757] outline-none text-sm" }, "Done")), /* @__PURE__ */ React62.createElement("div", { className: "p-4 shrink-0" }, /* @__PURE__ */ React62.createElement("div", { className: "relative w-full" }, /* @__PURE__ */ React62.createElement(HugeiconsIcon48, { icon: Search01Icon10, size: 16, className: "text-stone-400 absolute left-4 top-1/2 -translate-y-1/2 pointer-events-none" }), /* @__PURE__ */ React62.createElement("input", { type: "text", placeholder: "Search team...", value: localMemSearch, onChange: handleMemSearch, className: "w-full pl-10 pr-4 py-2.5 bg-stone-100 rounded-full focus:border-[#d97757] border border-transparent text-sm text-black outline-none focus:bg-stone-50 transition-colors" }))), /* @__PURE__ */ React62.createElement("div", { className: "flex-1 overflow-y-auto custom-scrollbar p-2" }, isMembersLoading ? /* @__PURE__ */ React62.createElement("div", { className: "absolute inset-0 flex items-center justify-center" }, /* @__PURE__ */ React62.createElement(HugeiconsIcon48, { icon: Loading03Icon33, size: 28, className: "animate-spin text-black" })) : members.length === 0 ? /* @__PURE__ */ React62.createElement("div", { className: "p-8 text-center text-xs text-stone-400" }, "No members found.") : members.map((member) => {
|
|
7614
7625
|
const isChecked = selectedParticipants.has(member.userId);
|
|
7615
|
-
return /* @__PURE__ */ React62.createElement("div", { key: member.id, onClick: () => toggleParticipant(member.userId), className: "flex items-center justify-between p-3 rounded-xl cursor-pointer hover:bg-stone-50 transition-colors select-none" }, /* @__PURE__ */ React62.createElement("div", { className: "flex items-center gap-3 min-w-0 flex-1" }, /* @__PURE__ */ React62.createElement(MemberAvatar6, { src: member.avatarUrl, sizeClass: "w-9 h-9" }), /* @__PURE__ */ React62.createElement("div", { className: "flex flex-col min-w-0 flex-1" }, /* @__PURE__ */ React62.createElement("span", { className: "text-sm text-black truncate" }, member.fullName), /* @__PURE__ */ React62.createElement("span", { className: "text-xs text-stone-400 capitalize truncate" }, member.role.toLowerCase()))), /* @__PURE__ */ React62.createElement("div", { className: "shrink-0 pl-3" }, /* @__PURE__ */ React62.createElement("div", { className: `w-5 h-5 rounded-full flex items-center justify-center transition-colors ${isChecked ? "bg-[#d97757]" : "border border-stone-300 bg-white"}` }, isChecked && /* @__PURE__ */ React62.createElement(
|
|
7616
|
-
})), /* @__PURE__ */ React62.createElement("div", { className: "p-4 flex items-center justify-between shrink-0 bg-white" }, /* @__PURE__ */ React62.createElement("span", { className: "text-xs text-stone-400 tracking-widest" }, "Page ", membersCurrentPage, " of ", membersTotalPages || 1), /* @__PURE__ */ React62.createElement("div", { className: "flex gap-1" }, /* @__PURE__ */ React62.createElement("button", { disabled: membersCurrentPage <= 1 || isMembersLoading, onClick: () => onMembersPageChange(membersCurrentPage - 1), className: "w-7 h-7 flex items-center justify-center rounded-full bg-white border border-stone-200 text-stone-600 disabled:opacity-30 outline-none hover:bg-stone-50" }, /* @__PURE__ */ React62.createElement(
|
|
7626
|
+
return /* @__PURE__ */ React62.createElement("div", { key: member.id, onClick: () => toggleParticipant(member.userId), className: "flex items-center justify-between p-3 rounded-xl cursor-pointer hover:bg-stone-50 transition-colors select-none" }, /* @__PURE__ */ React62.createElement("div", { className: "flex items-center gap-3 min-w-0 flex-1" }, /* @__PURE__ */ React62.createElement(MemberAvatar6, { src: member.avatarUrl, sizeClass: "w-9 h-9" }), /* @__PURE__ */ React62.createElement("div", { className: "flex flex-col min-w-0 flex-1" }, /* @__PURE__ */ React62.createElement("span", { className: "text-sm text-black truncate" }, member.fullName), /* @__PURE__ */ React62.createElement("span", { className: "text-xs text-stone-400 capitalize truncate" }, member.role.toLowerCase()))), /* @__PURE__ */ React62.createElement("div", { className: "shrink-0 pl-3" }, /* @__PURE__ */ React62.createElement("div", { className: `w-5 h-5 rounded-full flex items-center justify-center transition-colors ${isChecked ? "bg-[#d97757]" : "border border-stone-300 bg-white"}` }, isChecked && /* @__PURE__ */ React62.createElement(HugeiconsIcon48, { icon: Tick02Icon5, size: 14, className: "text-white" }))));
|
|
7627
|
+
})), /* @__PURE__ */ React62.createElement("div", { className: "p-4 flex items-center justify-between shrink-0 bg-white" }, /* @__PURE__ */ React62.createElement("span", { className: "text-xs text-stone-400 tracking-widest" }, "Page ", membersCurrentPage, " of ", membersTotalPages || 1), /* @__PURE__ */ React62.createElement("div", { className: "flex gap-1" }, /* @__PURE__ */ React62.createElement("button", { disabled: membersCurrentPage <= 1 || isMembersLoading, onClick: () => onMembersPageChange(membersCurrentPage - 1), className: "w-7 h-7 flex items-center justify-center rounded-full bg-white border border-stone-200 text-stone-600 disabled:opacity-30 outline-none hover:bg-stone-50" }, /* @__PURE__ */ React62.createElement(HugeiconsIcon48, { icon: ArrowLeft01Icon26, size: 12 })), /* @__PURE__ */ React62.createElement("button", { disabled: membersCurrentPage >= membersTotalPages || isMembersLoading, onClick: () => onMembersPageChange(membersCurrentPage + 1), className: "w-7 h-7 flex items-center justify-center rounded-full bg-white border border-stone-200 text-stone-600 disabled:opacity-30 outline-none hover:bg-stone-50" }, /* @__PURE__ */ React62.createElement(HugeiconsIcon48, { icon: ArrowRight01Icon19, size: 12 })))))));
|
|
7617
7628
|
};
|
|
7618
7629
|
export {
|
|
7619
7630
|
AppBento2,
|