@retinalabsllc/zairusjs 21.1.9 → 21.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -1285,7 +1285,7 @@ interface RootSidebarProps {
1285
1285
  showLogoutAction?: boolean;
1286
1286
  onLogout?: () => Promise<void>;
1287
1287
  }
1288
- declare function RootSidebar({ NavItem2s, currentPath, isMobileOpen, closeMobile, onNavClick, avatarSrc, title, subtitle, homeUrl, showWorkspaceSwitcher, workspaces, activeWorkspaceId, onSwitchWorkspace, showLogoutAction, onLogout }: RootSidebarProps): React.JSX.Element;
1288
+ declare function RootSidebar({ NavItem2s, currentPath, isMobileOpen, closeMobile, openMobile, onNavClick, avatarSrc, title, subtitle, homeUrl, showWorkspaceSwitcher, workspaces, activeWorkspaceId, onSwitchWorkspace, showLogoutAction, onLogout }: RootSidebarProps): React.JSX.Element;
1289
1289
 
1290
1290
  interface UniversalMember3 {
1291
1291
  id: string;
@@ -1414,10 +1414,18 @@ interface UniversalCompanyApp {
1414
1414
  id: string;
1415
1415
  name: string;
1416
1416
  isPrivate: boolean;
1417
+ applicationsCount?: number;
1418
+ }
1419
+ interface ApplicationTypeMeta {
1420
+ key: string;
1421
+ label: string;
1422
+ desc: string;
1423
+ available?: boolean;
1417
1424
  }
1418
1425
  interface UniversalCreateApplicationProps {
1419
1426
  onBackHref: string;
1420
1427
  userRole?: string;
1428
+ applicationTypesMeta: ApplicationTypeMeta[];
1421
1429
  members: UniversalMemberApp[];
1422
1430
  isMembersLoading: boolean;
1423
1431
  membersCurrentPage: number;
package/dist/index.d.ts CHANGED
@@ -1285,7 +1285,7 @@ interface RootSidebarProps {
1285
1285
  showLogoutAction?: boolean;
1286
1286
  onLogout?: () => Promise<void>;
1287
1287
  }
1288
- declare function RootSidebar({ NavItem2s, currentPath, isMobileOpen, closeMobile, onNavClick, avatarSrc, title, subtitle, homeUrl, showWorkspaceSwitcher, workspaces, activeWorkspaceId, onSwitchWorkspace, showLogoutAction, onLogout }: RootSidebarProps): React.JSX.Element;
1288
+ declare function RootSidebar({ NavItem2s, currentPath, isMobileOpen, closeMobile, openMobile, onNavClick, avatarSrc, title, subtitle, homeUrl, showWorkspaceSwitcher, workspaces, activeWorkspaceId, onSwitchWorkspace, showLogoutAction, onLogout }: RootSidebarProps): React.JSX.Element;
1289
1289
 
1290
1290
  interface UniversalMember3 {
1291
1291
  id: string;
@@ -1414,10 +1414,18 @@ interface UniversalCompanyApp {
1414
1414
  id: string;
1415
1415
  name: string;
1416
1416
  isPrivate: boolean;
1417
+ applicationsCount?: number;
1418
+ }
1419
+ interface ApplicationTypeMeta {
1420
+ key: string;
1421
+ label: string;
1422
+ desc: string;
1423
+ available?: boolean;
1417
1424
  }
1418
1425
  interface UniversalCreateApplicationProps {
1419
1426
  onBackHref: string;
1420
1427
  userRole?: string;
1428
+ applicationTypesMeta: ApplicationTypeMeta[];
1421
1429
  members: UniversalMemberApp[];
1422
1430
  isMembersLoading: boolean;
1423
1431
  membersCurrentPage: number;
package/dist/index.js CHANGED
@@ -1028,7 +1028,7 @@ var UniversalHuddleDetails = ({
1028
1028
  }
1029
1029
  setIsDeleting(false);
1030
1030
  };
1031
- return /* @__PURE__ */ import_react17.default.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react17.default.createElement(ManagedToaster, null), /* @__PURE__ */ import_react17.default.createElement(
1031
+ return /* @__PURE__ */ import_react17.default.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react17.default.createElement(ManagedToaster, null), /* @__PURE__ */ import_react17.default.createElement(
1032
1032
  ConfirmationDialog,
1033
1033
  {
1034
1034
  isOpen: confirmDialog !== null,
@@ -1947,7 +1947,7 @@ var UniversalHomeView = ({
1947
1947
  const fallbackAvatarUrl = `/api/avatar/?name=${encodeURIComponent(fullName || " ")}&background=ffffff&color=000000&size=100&font-size=0.33`;
1948
1948
  const finalAvatarSrc = avatarSrc || fallbackAvatarUrl;
1949
1949
  const hasUnreadNotifs = notifications.some((n) => !n.isRead);
1950
- return /* @__PURE__ */ import_react34.default.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react34.default.createElement("div", { className: "flex items-center justify-between w-full pb-4 " }, /* @__PURE__ */ import_react34.default.createElement("div", { className: "w-10 h-10 rounded-full bg-white p-0.75 flex items-center justify-center cursor-pointer", onClick: () => router.push("/app/account/me") }, /* @__PURE__ */ import_react34.default.createElement("div", { className: "relative w-full h-full rounded-full overflow-hidden bg-stone-100 flex items-center justify-center" }, !isAvatarLoaded && /* @__PURE__ */ import_react34.default.createElement("div", { className: "absolute inset-0 flex items-center justify-center z-10 bg-stone-100" }, /* @__PURE__ */ import_react34.default.createElement(import_react35.HugeiconsIcon, { icon: import_core_free_icons13.Loading03Icon, size: 16, className: "animate-spin text-black" })), /* @__PURE__ */ import_react34.default.createElement(
1950
+ return /* @__PURE__ */ import_react34.default.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react34.default.createElement("div", { className: "flex items-center justify-between w-full pb-4 " }, /* @__PURE__ */ import_react34.default.createElement("div", { className: "w-10 h-10 rounded-full bg-white p-0.75 flex items-center justify-center cursor-pointer", onClick: () => router.push("/app/account/me") }, /* @__PURE__ */ import_react34.default.createElement("div", { className: "relative w-full h-full rounded-full overflow-hidden bg-stone-100 flex items-center justify-center" }, !isAvatarLoaded && /* @__PURE__ */ import_react34.default.createElement("div", { className: "absolute inset-0 flex items-center justify-center z-10 bg-stone-100" }, /* @__PURE__ */ import_react34.default.createElement(import_react35.HugeiconsIcon, { icon: import_core_free_icons13.Loading03Icon, size: 16, className: "animate-spin text-black" })), /* @__PURE__ */ import_react34.default.createElement(
1951
1951
  "img",
1952
1952
  {
1953
1953
  src: finalAvatarSrc,
@@ -2304,7 +2304,7 @@ var UniversalCardPage = ({
2304
2304
  img.onload = () => setIsBgLoaded(true);
2305
2305
  }, [activeCard?.cardBgSrc]);
2306
2306
  if (!activeCard || sortedCards.length === 0) {
2307
- return /* @__PURE__ */ import_react38.default.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative min-h-100 justify-center" }, /* @__PURE__ */ import_react38.default.createElement("div", { className: "p-6 w-full max-w-md mx-auto text-center" }, /* @__PURE__ */ import_react38.default.createElement("div", { className: "mb-8 flex justify-center" }, /* @__PURE__ */ import_react38.default.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", className: "w-12 h-12 fill-stone-100" }, /* @__PURE__ */ import_react38.default.createElement("path", { fillRule: "evenodd", d: "M2.25 12c0-5.385 4.365-9.75 9.75-9.75s9.75 4.365 9.75 9.75-4.365 9.75-9.75 9.75S2.25 17.385 2.25 12zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z", clipRule: "evenodd" }))), /* @__PURE__ */ import_react38.default.createElement("h1", { className: "text-xl text-black tracking-tight mb-4" }, "No cards available"), /* @__PURE__ */ import_react38.default.createElement("p", { className: "text-sm leading-[1.8] text-stone-600 mb-12" }, "You do not have any active cards on your account.")));
2307
+ return /* @__PURE__ */ import_react38.default.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative min-h-100 justify-center" }, /* @__PURE__ */ import_react38.default.createElement("div", { className: "p-6 w-full max-w-md mx-auto text-center" }, /* @__PURE__ */ import_react38.default.createElement("div", { className: "mb-8 flex justify-center" }, /* @__PURE__ */ import_react38.default.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", className: "w-12 h-12 fill-stone-100" }, /* @__PURE__ */ import_react38.default.createElement("path", { fillRule: "evenodd", d: "M2.25 12c0-5.385 4.365-9.75 9.75-9.75s9.75 4.365 9.75 9.75-4.365 9.75-9.75 9.75S2.25 17.385 2.25 12zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z", clipRule: "evenodd" }))), /* @__PURE__ */ import_react38.default.createElement("h1", { className: "text-xl text-black tracking-tight mb-4" }, "No cards available"), /* @__PURE__ */ import_react38.default.createElement("p", { className: "text-sm leading-[1.8] text-stone-600 mb-12" }, "You do not have any active cards on your account.")));
2308
2308
  }
2309
2309
  const isActivated = activeCard.status === "ACTIVATED";
2310
2310
  const isFrozen = activeCard.status === "FROZEN";
@@ -2332,7 +2332,7 @@ var UniversalCardPage = ({
2332
2332
  const formatTabLabel = (type) => {
2333
2333
  return type.charAt(0).toUpperCase() + type.slice(1).toLowerCase() + " Card";
2334
2334
  };
2335
- return /* @__PURE__ */ import_react38.default.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, sortedCards.length > 1 && /* @__PURE__ */ import_react38.default.createElement("div", { className: "flex items-center justify-center mb-6 w-full px-2 gap-3" }, /* @__PURE__ */ import_react38.default.createElement("div", { className: "flex items-center bg-white rounded-full p-1 max-w-full overflow-x-auto custom-scrollbar" }, sortedCards.map((tab, idx) => /* @__PURE__ */ import_react38.default.createElement(
2335
+ return /* @__PURE__ */ import_react38.default.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, sortedCards.length > 1 && /* @__PURE__ */ import_react38.default.createElement("div", { className: "flex items-center justify-center mb-6 w-full px-2 gap-3" }, /* @__PURE__ */ import_react38.default.createElement("div", { className: "flex items-center bg-white rounded-full p-1 max-w-full overflow-x-auto custom-scrollbar" }, sortedCards.map((tab, idx) => /* @__PURE__ */ import_react38.default.createElement(
2336
2336
  "button",
2337
2337
  {
2338
2338
  key: tab.id,
@@ -5043,7 +5043,7 @@ var UniversalHuddlesPage = ({
5043
5043
  onHuddleClick,
5044
5044
  onCreateHuddle
5045
5045
  }) => {
5046
- return /* @__PURE__ */ import_react83.default.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react83.default.createElement("div", { className: "flex flex-col gap-8 p-6 rounded-2xl bg-white w-full" }, /* @__PURE__ */ import_react83.default.createElement("div", { className: "flex flex-col gap-1" }, /* @__PURE__ */ import_react83.default.createElement("div", { className: "flex flex-row items-center justify-between gap-4" }, /* @__PURE__ */ import_react83.default.createElement("h2", { className: "text-black text-xl tracking-tight" }, headerTitle), /* @__PURE__ */ import_react83.default.createElement(
5046
+ return /* @__PURE__ */ import_react83.default.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react83.default.createElement("div", { className: "flex flex-col gap-8 p-6 rounded-2xl bg-white w-full" }, /* @__PURE__ */ import_react83.default.createElement("div", { className: "flex flex-col gap-1" }, /* @__PURE__ */ import_react83.default.createElement("div", { className: "flex flex-row items-center justify-between gap-4" }, /* @__PURE__ */ import_react83.default.createElement("h2", { className: "text-black text-xl tracking-tight" }, headerTitle), /* @__PURE__ */ import_react83.default.createElement(
5047
5047
  "button",
5048
5048
  {
5049
5049
  onClick: () => onCreateHuddle?.(),
@@ -5412,7 +5412,7 @@ var UniversalHome2 = ({
5412
5412
  setShowLogoutConfirm(false);
5413
5413
  }
5414
5414
  };
5415
- return /* @__PURE__ */ import_react87.default.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react87.default.createElement(
5415
+ return /* @__PURE__ */ import_react87.default.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react87.default.createElement(
5416
5416
  ConfirmationDialog,
5417
5417
  {
5418
5418
  isOpen: showLogoutConfirm,
@@ -6031,7 +6031,7 @@ var UniversalCreateHuddle = ({
6031
6031
  setIsSubmitting(false);
6032
6032
  }
6033
6033
  };
6034
- return /* @__PURE__ */ import_react91.default.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react91.default.createElement(ManagedToaster, null), /* @__PURE__ */ import_react91.default.createElement("div", { className: "mb-6 flex w-full items-center px-1" }, /* @__PURE__ */ import_react91.default.createElement("a", { href: onBackHref, className: "flex items-center gap-2 text-[#d97757] hover:text-[#d97757] transition-colors text-sm outline-none" }, /* @__PURE__ */ import_react91.default.createElement(import_react92.HugeiconsIcon, { icon: import_core_free_icons35.ArrowLeft01Icon, size: 16 }), " Back")), /* @__PURE__ */ import_react91.default.createElement("div", { className: "flex flex-col gap-1 mb-8 px-1" }, /* @__PURE__ */ import_react91.default.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Create Huddle"), /* @__PURE__ */ import_react91.default.createElement("p", { className: "text-xs text-stone-500" }, "Schedule a new workspace huddle and manage participant access.")), /* @__PURE__ */ import_react91.default.createElement("div", { className: "flex flex-col gap-8 animate-in rounded-2xl p-6 bg-white fade-in duration-300" }, /* @__PURE__ */ import_react91.default.createElement("form", { className: "flex flex-col gap-8", onSubmit: handleSubmit, autoComplete: "off" }, !canManage && /* @__PURE__ */ import_react91.default.createElement("div", { className: "flex items-start gap-3 p-4 bg-stone-50 rounded-xl" }, /* @__PURE__ */ import_react91.default.createElement(import_react92.HugeiconsIcon, { icon: import_core_free_icons35.CircleLock02Icon, size: 20, className: "text-stone-500 shrink-0 mt-0.5" }), /* @__PURE__ */ import_react91.default.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ import_react91.default.createElement("span", { className: "text-sm text-black tracking-tight" }, "Access Restricted"), /* @__PURE__ */ import_react91.default.createElement("span", { className: "text-xs text-stone-500 mt-1 leading-relaxed" }, "You do not have sufficient permissions to access this page. Contact organization admin or manager."))), /* @__PURE__ */ import_react91.default.createElement(
6034
+ return /* @__PURE__ */ import_react91.default.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react91.default.createElement(ManagedToaster, null), /* @__PURE__ */ import_react91.default.createElement("div", { className: "mb-6 flex w-full items-center px-1" }, /* @__PURE__ */ import_react91.default.createElement("a", { href: onBackHref, className: "flex items-center gap-2 text-[#d97757] hover:text-[#d97757] transition-colors text-sm outline-none" }, /* @__PURE__ */ import_react91.default.createElement(import_react92.HugeiconsIcon, { icon: import_core_free_icons35.ArrowLeft01Icon, size: 16 }), " Back")), /* @__PURE__ */ import_react91.default.createElement("div", { className: "flex flex-col gap-1 mb-8 px-1" }, /* @__PURE__ */ import_react91.default.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Create Huddle"), /* @__PURE__ */ import_react91.default.createElement("p", { className: "text-xs text-stone-500" }, "Schedule a new workspace huddle and manage participant access.")), /* @__PURE__ */ import_react91.default.createElement("div", { className: "flex flex-col gap-8 animate-in rounded-2xl p-6 bg-white fade-in duration-300" }, /* @__PURE__ */ import_react91.default.createElement("form", { className: "flex flex-col gap-8", onSubmit: handleSubmit, autoComplete: "off" }, !canManage && /* @__PURE__ */ import_react91.default.createElement("div", { className: "flex items-start gap-3 p-4 bg-stone-50 rounded-xl" }, /* @__PURE__ */ import_react91.default.createElement(import_react92.HugeiconsIcon, { icon: import_core_free_icons35.CircleLock02Icon, size: 20, className: "text-stone-500 shrink-0 mt-0.5" }), /* @__PURE__ */ import_react91.default.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ import_react91.default.createElement("span", { className: "text-sm text-black tracking-tight" }, "Access Restricted"), /* @__PURE__ */ import_react91.default.createElement("span", { className: "text-xs text-stone-500 mt-1 leading-relaxed" }, "You do not have sufficient permissions to access this page. Contact organization admin or manager."))), /* @__PURE__ */ import_react91.default.createElement(
6035
6035
  TextInput,
6036
6036
  {
6037
6037
  label: "Huddle Subject",
@@ -6358,7 +6358,7 @@ var UniversalApplicationsPage = ({
6358
6358
  onApplicationClick,
6359
6359
  onCreateApplication
6360
6360
  }) => {
6361
- return /* @__PURE__ */ import_react95.default.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react95.default.createElement("div", { className: "flex flex-col gap-8 p-6 rounded-2xl bg-white w-full" }, /* @__PURE__ */ import_react95.default.createElement("div", { className: "flex flex-col gap-1" }, /* @__PURE__ */ import_react95.default.createElement("div", { className: "flex flex-row items-center justify-between gap-4" }, /* @__PURE__ */ import_react95.default.createElement("h2", { className: "text-black text-xl tracking-tight" }, headerTitle), /* @__PURE__ */ import_react95.default.createElement(
6361
+ return /* @__PURE__ */ import_react95.default.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react95.default.createElement("div", { className: "flex flex-col gap-8 p-6 rounded-2xl bg-white w-full" }, /* @__PURE__ */ import_react95.default.createElement("div", { className: "flex flex-col gap-1" }, /* @__PURE__ */ import_react95.default.createElement("div", { className: "flex flex-row items-center justify-between gap-4" }, /* @__PURE__ */ import_react95.default.createElement("h2", { className: "text-black text-xl tracking-tight" }, headerTitle), /* @__PURE__ */ import_react95.default.createElement(
6362
6362
  "button",
6363
6363
  {
6364
6364
  onClick: () => onCreateApplication?.(),
@@ -6430,7 +6430,7 @@ var UniversalHome3 = ({
6430
6430
  setIsResolving(false);
6431
6431
  }
6432
6432
  };
6433
- return /* @__PURE__ */ import_react97.default.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react97.default.createElement("div", { className: "flex items-center justify-between w-full pb-4" }, /* @__PURE__ */ import_react97.default.createElement("div", { className: "flex items-center gap-2 shrink-0" }, /* @__PURE__ */ import_react97.default.createElement(
6433
+ return /* @__PURE__ */ import_react97.default.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react97.default.createElement("div", { className: "flex items-center justify-between w-full pb-4" }, /* @__PURE__ */ import_react97.default.createElement("div", { className: "flex items-center gap-3" }), /* @__PURE__ */ import_react97.default.createElement("div", { className: "flex items-center gap-2 shrink-0" }, /* @__PURE__ */ import_react97.default.createElement(
6434
6434
  "button",
6435
6435
  {
6436
6436
  onClick: () => router.push("/app/ai"),
@@ -6540,6 +6540,7 @@ function RootSidebar({
6540
6540
  currentPath,
6541
6541
  isMobileOpen,
6542
6542
  closeMobile,
6543
+ openMobile,
6543
6544
  onNavClick,
6544
6545
  avatarSrc,
6545
6546
  title = "App",
@@ -6576,23 +6577,38 @@ function RootSidebar({
6576
6577
  }
6577
6578
  };
6578
6579
  const finalAvatarSrc = avatarSrc || "https://storage.googleapis.com/retina-cloud-v2/assets/images/avatar.avif";
6579
- return /* @__PURE__ */ import_react99.default.createElement(import_react99.default.Fragment, null, /* @__PURE__ */ import_react99.default.createElement(
6580
+ return /* @__PURE__ */ import_react99.default.createElement(import_react99.default.Fragment, null, !isMobileOpen && /* @__PURE__ */ import_react99.default.createElement(
6581
+ "button",
6582
+ {
6583
+ onClick: openMobile,
6584
+ className: "md:hidden fixed left-0 top-1/2 -translate-y-1/2 z-50 bg-white border border-stone-200 border-l-0 shadow-[4px_0_24px_rgba(0,0,0,0.06)] rounded-r-xl py-6 px-1.5 flex items-center justify-center outline-none hover:bg-stone-50 transition-colors",
6585
+ "aria-label": "Open Menu"
6586
+ },
6587
+ /* @__PURE__ */ import_react99.default.createElement(
6588
+ "span",
6589
+ {
6590
+ className: "text-[10px] font-medium uppercase tracking-[0.2em] text-stone-500",
6591
+ style: { writingMode: "vertical-rl", transform: "rotate(180deg)" }
6592
+ },
6593
+ "Open Menu"
6594
+ )
6595
+ ), /* @__PURE__ */ import_react99.default.createElement(
6580
6596
  "div",
6581
6597
  {
6582
- className: `fixed inset-0 bg-black/30 shadow-2xl transition-opacity duration-300 md:hidden z-90 ${isMobileOpen ? "opacity-100 pointer-events-auto" : "opacity-0 pointer-events-none"}`,
6598
+ className: `fixed inset-0 bg-black/40 shadow-2xl transition-opacity duration-300 md:hidden z-90 ${isMobileOpen ? "opacity-100 pointer-events-auto" : "opacity-0 pointer-events-none"}`,
6583
6599
  onClick: closeMobile
6584
6600
  }
6585
6601
  ), /* @__PURE__ */ import_react99.default.createElement(
6586
6602
  "aside",
6587
6603
  {
6588
6604
  className: `
6589
- fixed md:sticky rounded-2xl top-4 md:top-4 md:my-4 left-4 md:left-0 md:ml-4 h-[calc(100dvh-2rem)] bg-white
6605
+ fixed md:sticky top-0 left-0 h-dvh bg-[#212121]
6590
6606
  transition-all duration-300 ease-in-out shrink-0 flex flex-col z-100 md:z-10
6591
6607
  ${isMobileOpen ? "translate-x-0" : "translate-x-[-120%] md:translate-x-0"}
6592
6608
  ${isCollapsed ? "md:w-16 w-64" : "w-64"}
6593
6609
  `
6594
6610
  },
6595
- /* @__PURE__ */ import_react99.default.createElement("div", { className: `flex items-center shrink-0 p-5 ${isCollapsed && !isMobileOpen ? "justify-center" : "justify-between"}` }, /* @__PURE__ */ import_react99.default.createElement(import_link10.default, { href: homeUrl, className: `flex items-center outline-none group min-w-0 ${isCollapsed && !isMobileOpen ? "" : "gap-3 pr-2"}` }, /* @__PURE__ */ import_react99.default.createElement("div", { className: "w-8 h-8 shrink-0 relative rounded-lg overflow-hidden bg-stone-50 flex items-center justify-center" }, !isAvatarLoaded && /* @__PURE__ */ import_react99.default.createElement(import_react100.HugeiconsIcon, { icon: import_core_free_icons39.Loading03Icon, size: 14, className: "animate-spin text-stone-300 absolute" }), /* @__PURE__ */ import_react99.default.createElement(
6611
+ /* @__PURE__ */ import_react99.default.createElement("div", { className: `flex items-center shrink-0 p-5 ${isCollapsed && !isMobileOpen ? "justify-center" : "justify-between"}` }, /* @__PURE__ */ import_react99.default.createElement(import_link10.default, { href: homeUrl, className: `flex items-center outline-none group min-w-0 ${isCollapsed && !isMobileOpen ? "" : "gap-3 pr-2"}` }, /* @__PURE__ */ import_react99.default.createElement("div", { className: "w-8 h-8 shrink-0 relative rounded-lg overflow-hidden bg-white/10 flex items-center justify-center" }, !isAvatarLoaded && /* @__PURE__ */ import_react99.default.createElement(import_react100.HugeiconsIcon, { icon: import_core_free_icons39.Loading03Icon, size: 14, className: "animate-spin text-white/50 absolute" }), /* @__PURE__ */ import_react99.default.createElement(
6596
6612
  "img",
6597
6613
  {
6598
6614
  src: finalAvatarSrc,
@@ -6600,11 +6616,11 @@ function RootSidebar({
6600
6616
  onLoad: () => setIsAvatarLoaded(true),
6601
6617
  className: `w-full h-full object-cover transition-opacity duration-300 ${isAvatarLoaded ? "opacity-100" : "opacity-0"}`
6602
6618
  }
6603
- )), (!isCollapsed || isMobileOpen) && /* @__PURE__ */ import_react99.default.createElement("div", { className: "flex flex-col justify-center min-w-0" }, /* @__PURE__ */ import_react99.default.createElement("span", { className: "text-[13px] font-serif text-black leading-none truncate max-w-32.5 tracking-wide mb-1 group-hover:opacity-70 transition-opacity" }, title), subtitle && /* @__PURE__ */ import_react99.default.createElement("span", { className: "text-[9px] text-neutral-500 truncate max-w-32.5 tracking-[0.2em] leading-none uppercase" }, subtitle))), (!isCollapsed || isMobileOpen) && /* @__PURE__ */ import_react99.default.createElement("div", { className: "md:hidden flex shrink-0" }, /* @__PURE__ */ import_react99.default.createElement(
6619
+ )), (!isCollapsed || isMobileOpen) && /* @__PURE__ */ import_react99.default.createElement("div", { className: "flex flex-col justify-center min-w-0" }, /* @__PURE__ */ import_react99.default.createElement("span", { className: "text-[13px] font-serif text-white leading-none truncate max-w-32.5 tracking-wide mb-1 group-hover:opacity-80 transition-opacity" }, title), subtitle && /* @__PURE__ */ import_react99.default.createElement("span", { className: "text-[9px] text-neutral-400 truncate max-w-32.5 tracking-[0.2em] leading-none uppercase" }, subtitle))), (!isCollapsed || isMobileOpen) && /* @__PURE__ */ import_react99.default.createElement("div", { className: "md:hidden flex shrink-0" }, /* @__PURE__ */ import_react99.default.createElement(
6604
6620
  "button",
6605
6621
  {
6606
6622
  onClick: closeMobile,
6607
- className: "text-neutral-400 hover:text-black transition-colors outline-none",
6623
+ className: "text-neutral-400 hover:text-white transition-colors outline-none",
6608
6624
  "aria-label": "Close Menu"
6609
6625
  },
6610
6626
  /* @__PURE__ */ import_react99.default.createElement(import_react100.HugeiconsIcon, { icon: import_core_free_icons39.CancelCircleIcon, size: 24 })
@@ -6618,7 +6634,7 @@ function RootSidebar({
6618
6634
  key: item.name,
6619
6635
  href: item.path,
6620
6636
  onClick: (e) => onNavClick ? onNavClick(e, item.path) : void 0,
6621
- className: `flex items-center gap-3 px-3 py-2 rounded-full transition-all outline-none group shrink-0 ${isCurrentRoute ? "bg-neutral-100 text-black " : "text-neutral-500 hover:text-black hover:bg-neutral-50"}`,
6637
+ className: `flex items-center gap-3 px-3 py-2 rounded-full transition-all outline-none group shrink-0 ${isCurrentRoute ? "bg-white/10 text-white" : "text-neutral-400 hover:text-white hover:bg-white/5"}`,
6622
6638
  title: isCollapsed && !isMobileOpen ? item.name : void 0
6623
6639
  },
6624
6640
  /* @__PURE__ */ import_react99.default.createElement(
@@ -6626,17 +6642,17 @@ function RootSidebar({
6626
6642
  {
6627
6643
  icon: item.icon,
6628
6644
  size: 18,
6629
- className: `shrink-0 transition-colors ${isCurrentRoute ? "text-black" : "text-neutral-400 group-hover:text-black"}`
6645
+ className: `shrink-0 transition-colors ${isCurrentRoute ? "text-white" : "text-neutral-400 group-hover:text-white"}`
6630
6646
  }
6631
6647
  ),
6632
6648
  (!isCollapsed || isMobileOpen) && /* @__PURE__ */ import_react99.default.createElement("span", { className: "text-xs tracking-wide truncate" }, item.name)
6633
6649
  );
6634
6650
  })),
6635
- /* @__PURE__ */ import_react99.default.createElement("div", { className: "p-4 shrink-0 flex flex-col gap-2 " }, (showWorkspaceSwitcher || showLogoutAction) && /* @__PURE__ */ import_react99.default.createElement("div", { className: `flex gap-2 px-1 pb-2 ${isCollapsed && !isMobileOpen ? "flex-col items-center" : "flex-col items-start md:flex-row md:items-center"}` }, showWorkspaceSwitcher && workspaces && workspaces.length > 0 && /* @__PURE__ */ import_react99.default.createElement(
6651
+ /* @__PURE__ */ import_react99.default.createElement("div", { className: "p-4 shrink-0 flex flex-col gap-2" }, (showWorkspaceSwitcher || showLogoutAction) && /* @__PURE__ */ import_react99.default.createElement("div", { className: `flex gap-2 px-1 pb-2 ${isCollapsed && !isMobileOpen ? "flex-col items-center" : "flex-row items-center"}` }, showWorkspaceSwitcher && workspaces && workspaces.length > 0 && /* @__PURE__ */ import_react99.default.createElement(
6636
6652
  "button",
6637
6653
  {
6638
6654
  onClick: () => setShowSwitcherDialog(true),
6639
- className: "w-8 h-8 shrink-0 rounded-full bg-neutral-50 flex items-center justify-center text-neutral-500 hover:text-black hover:bg-neutral-100 transition-all outline-none",
6655
+ className: "w-8 h-8 shrink-0 rounded-full bg-white/5 flex items-center justify-center text-neutral-400 hover:text-white hover:bg-white/10 transition-all outline-none",
6640
6656
  title: "Switch Workspace"
6641
6657
  },
6642
6658
  /* @__PURE__ */ import_react99.default.createElement(import_react100.HugeiconsIcon, { icon: import_core_free_icons39.UserIcon, size: 16 })
@@ -6644,15 +6660,15 @@ function RootSidebar({
6644
6660
  "button",
6645
6661
  {
6646
6662
  onClick: () => setShowLogoutDialog(true),
6647
- className: "w-8 h-8 shrink-0 rounded-full bg-neutral-50 flex items-center justify-center text-neutral-500 hover:text-black hover:bg-neutral-100 transition-all outline-none",
6663
+ className: "w-8 h-8 shrink-0 rounded-full bg-white/5 flex items-center justify-center text-neutral-400 hover:text-white hover:bg-white/10 transition-all outline-none",
6648
6664
  title: "Secure Logout"
6649
6665
  },
6650
6666
  /* @__PURE__ */ import_react99.default.createElement(import_react100.HugeiconsIcon, { icon: import_core_free_icons39.LogoutCircle02Icon, size: 16 })
6651
- )), /* @__PURE__ */ import_react99.default.createElement("div", { className: "hidden md:block" }, /* @__PURE__ */ import_react99.default.createElement(
6667
+ )), /* @__PURE__ */ import_react99.default.createElement("div", { className: "hidden md:block border-t border-white/5 pt-2" }, /* @__PURE__ */ import_react99.default.createElement(
6652
6668
  "button",
6653
6669
  {
6654
6670
  onClick: () => setIsCollapsed(!isCollapsed),
6655
- className: "flex items-center justify-center md:justify-start gap-3 w-full p-2.5 rounded-full text-neutral-500 hover:text-black hover:bg-neutral-50 transition-colors outline-none"
6671
+ className: "flex items-center justify-center md:justify-start gap-3 w-full p-2.5 rounded-full text-neutral-400 hover:text-white hover:bg-white/5 transition-colors outline-none"
6656
6672
  },
6657
6673
  /* @__PURE__ */ import_react99.default.createElement(import_react100.HugeiconsIcon, { icon: import_core_free_icons39.SidebarLeft01Icon, size: 18, className: "shrink-0 text-neutral-400" }),
6658
6674
  !isCollapsed && /* @__PURE__ */ import_react99.default.createElement("span", { className: "text-xs" }, "Collapse")
@@ -7253,7 +7269,7 @@ var UniversalApplicationPage2 = ({
7253
7269
  "QUERIED",
7254
7270
  "AWAITING_PAYMENT"
7255
7271
  ];
7256
- return /* @__PURE__ */ import_react104.default.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react104.default.createElement("div", { className: "flex flex-col gap-1 mb-8 px-1" }, /* @__PURE__ */ import_react104.default.createElement("div", { className: "flex items-center" }, /* @__PURE__ */ import_react104.default.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Applications Directory")), /* @__PURE__ */ import_react104.default.createElement("p", { className: "text-xs text-stone-500" }, "Search, filter, and track all your organizational applications.")), /* @__PURE__ */ import_react104.default.createElement("div", { className: "flex flex-row flex-nowrap mb-2 items-center justify-between gap-4 w-full px-1" }, /* @__PURE__ */ import_react104.default.createElement("div", { className: "relative flex-1 min-w-0 max-w-full" }, /* @__PURE__ */ import_react104.default.createElement("div", { className: "absolute inset-y-0 left-0 pl-4 flex items-center pointer-events-none" }, /* @__PURE__ */ import_react104.default.createElement(import_react105.HugeiconsIcon, { icon: import_core_free_icons41.Search01Icon, size: 16, className: "text-stone-400" })), /* @__PURE__ */ import_react104.default.createElement(
7272
+ return /* @__PURE__ */ import_react104.default.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react104.default.createElement("div", { className: "flex flex-col gap-1 mb-8 px-1" }, /* @__PURE__ */ import_react104.default.createElement("div", { className: "flex items-center" }, /* @__PURE__ */ import_react104.default.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Applications Directory")), /* @__PURE__ */ import_react104.default.createElement("p", { className: "text-xs text-stone-500" }, "Search, filter, and track all your organizational applications.")), /* @__PURE__ */ import_react104.default.createElement("div", { className: "flex flex-row flex-nowrap mb-2 items-center justify-between gap-4 w-full px-1" }, /* @__PURE__ */ import_react104.default.createElement("div", { className: "relative flex-1 min-w-0 max-w-full" }, /* @__PURE__ */ import_react104.default.createElement("div", { className: "absolute inset-y-0 left-0 pl-4 flex items-center pointer-events-none" }, /* @__PURE__ */ import_react104.default.createElement(import_react105.HugeiconsIcon, { icon: import_core_free_icons41.Search01Icon, size: 16, className: "text-stone-400" })), /* @__PURE__ */ import_react104.default.createElement(
7257
7273
  "input",
7258
7274
  {
7259
7275
  type: "text",
@@ -7323,7 +7339,7 @@ var UniversalApplicationDetails = ({
7323
7339
  }
7324
7340
  setIsDeleting(false);
7325
7341
  };
7326
- return /* @__PURE__ */ import_react106.default.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react106.default.createElement(ManagedToaster, null), /* @__PURE__ */ import_react106.default.createElement(
7342
+ return /* @__PURE__ */ import_react106.default.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react106.default.createElement(ManagedToaster, null), /* @__PURE__ */ import_react106.default.createElement(
7327
7343
  ConfirmationDialog,
7328
7344
  {
7329
7345
  isOpen: confirmDialog,
@@ -7336,7 +7352,7 @@ var UniversalApplicationDetails = ({
7336
7352
  onClose: () => setConfirmDialog(false),
7337
7353
  onConfirm: handleDelete
7338
7354
  }
7339
- ), /* @__PURE__ */ import_react106.default.createElement("div", { className: "mb-6 flex w-full items-center px-1" }, /* @__PURE__ */ import_react106.default.createElement("a", { href: onBackHref, className: "flex items-center gap-2 text-[#d97757] hover:text-[#d97757] transition-colors text-sm outline-none" }, /* @__PURE__ */ import_react106.default.createElement(import_react107.HugeiconsIcon, { icon: import_core_free_icons42.ArrowLeft01Icon, size: 16 }), " Back")), /* @__PURE__ */ import_react106.default.createElement("div", { className: "mb-8 px-1 flex flex-col sm:flex-row sm:items-center justify-between gap-4" }, /* @__PURE__ */ import_react106.default.createElement("div", null, /* @__PURE__ */ import_react106.default.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Application Details"), /* @__PURE__ */ import_react106.default.createElement("p", { className: "text-xs text-stone-500" }, "Review your filing entity and access its workspace.")), /* @__PURE__ */ import_react106.default.createElement("div", { className: "px-4 py-1.5 bg-stone-100 text-stone-600 rounded-full text-xs self-start sm:self-auto uppercase tracking-widest font-medium" }, application.status)), /* @__PURE__ */ import_react106.default.createElement("div", { className: "flex flex-col gap-8 animate-in rounded-2xl p-6 bg-white fade-in duration-300" }, /* @__PURE__ */ import_react106.default.createElement("div", { className: "flex flex-col gap-1 w-full" }, /* @__PURE__ */ import_react106.default.createElement("label", { className: "text-xs text-stone-400 tracking-[0.2em] block" }, "Target Company"), /* @__PURE__ */ import_react106.default.createElement("span", { className: "text-sm text-black py-2 font-medium" }, application.name)), /* @__PURE__ */ import_react106.default.createElement("div", { className: "flex flex-col gap-1 w-full border-t border-stone-100 pt-6" }, /* @__PURE__ */ import_react106.default.createElement("label", { className: "text-xs text-stone-400 tracking-[0.2em] block" }, "Filing Type"), /* @__PURE__ */ import_react106.default.createElement("span", { className: "text-sm text-black py-2" }, formatType2(application.type))), /* @__PURE__ */ import_react106.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_react106.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_react106.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_react106.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"))));
7355
+ ), /* @__PURE__ */ import_react106.default.createElement("div", { className: "mb-6 flex w-full items-center px-1" }, /* @__PURE__ */ import_react106.default.createElement("a", { href: onBackHref, className: "flex items-center gap-2 text-[#d97757] hover:text-[#d97757] transition-colors text-sm outline-none" }, /* @__PURE__ */ import_react106.default.createElement(import_react107.HugeiconsIcon, { icon: import_core_free_icons42.ArrowLeft01Icon, size: 16 }), " Back")), /* @__PURE__ */ import_react106.default.createElement("div", { className: "mb-8 px-1 flex flex-col sm:flex-row sm:items-center justify-between gap-4" }, /* @__PURE__ */ import_react106.default.createElement("div", null, /* @__PURE__ */ import_react106.default.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Application Details"), /* @__PURE__ */ import_react106.default.createElement("p", { className: "text-xs text-stone-500" }, "Review your filing entity and access its workspace.")), /* @__PURE__ */ import_react106.default.createElement("div", { className: "px-4 py-1.5 bg-stone-100 text-stone-600 rounded-full text-xs self-start sm:self-auto uppercase tracking-widest " }, application.status)), /* @__PURE__ */ import_react106.default.createElement("div", { className: "flex flex-col gap-8 animate-in rounded-2xl p-6 bg-white fade-in duration-300" }, /* @__PURE__ */ import_react106.default.createElement("div", { className: "flex flex-col gap-1 w-full" }, /* @__PURE__ */ import_react106.default.createElement("label", { className: "text-xs text-stone-400 tracking-[0.2em] block" }, "Target Company"), /* @__PURE__ */ import_react106.default.createElement("span", { className: "text-sm text-black py-2 " }, application.name)), /* @__PURE__ */ import_react106.default.createElement("div", { className: "flex flex-col gap-1 w-full border-t border-stone-100 pt-6" }, /* @__PURE__ */ import_react106.default.createElement("label", { className: "text-xs text-stone-400 tracking-[0.2em] block" }, "Filing Type"), /* @__PURE__ */ import_react106.default.createElement("span", { className: "text-sm text-black py-2" }, formatType2(application.type))), /* @__PURE__ */ import_react106.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_react106.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_react106.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_react106.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"))));
7340
7356
  };
7341
7357
 
7342
7358
  // src/components/UniversalCreateApplication.tsx
@@ -7350,30 +7366,10 @@ var MemberAvatar6 = ({ src, sizeClass = "w-10 h-10" }) => {
7350
7366
  const defaultAvatar = "https://storage.googleapis.com/retina-cloud-v2/assets/images/avatar.avif";
7351
7367
  return /* @__PURE__ */ import_react108.default.createElement("div", { className: `relative shrink-0 ${sizeClass}` }, /* @__PURE__ */ import_react108.default.createElement("div", { className: "w-full h-full rounded-lg bg-stone-100 flex items-center justify-center overflow-hidden" }, !loaded && !error && /* @__PURE__ */ import_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.Loading03Icon, className: "animate-spin text-stone-400 absolute", size: 14 }), /* @__PURE__ */ import_react108.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) })));
7352
7368
  };
7353
- var APPLICATION_TYPES = [
7354
- "COMPANY_REGISTRATION",
7355
- "BUSINESS_NAME",
7356
- "NGO_INCORPORATION",
7357
- "TRADEMARK",
7358
- "COPYRIGHT",
7359
- "PATENT",
7360
- "NDPC",
7361
- "GDPR",
7362
- "SCUML_CERTIFICATE",
7363
- "TAX_FILING",
7364
- "TIN_APPLICATION",
7365
- "VAT_REGISTRATION",
7366
- "ANNUAL_RETURNS",
7367
- "CHANGE_OF_DIRECTORS",
7368
- "CHANGE_OF_NAME",
7369
- "NAFDAC_REGISTRATION",
7370
- "OTHER"
7371
- ];
7372
- var formatType3 = (type) => type.split("_").map((w) => w[0] + w.slice(1).toLowerCase()).join(" ");
7373
- var FORMATTED_TYPES = APPLICATION_TYPES.map(formatType3);
7374
7369
  var UniversalCreateApplication = ({
7375
7370
  onBackHref,
7376
7371
  userRole = "MEMBER",
7372
+ applicationTypesMeta = [],
7377
7373
  members,
7378
7374
  isMembersLoading,
7379
7375
  membersCurrentPage,
@@ -7392,7 +7388,13 @@ var UniversalCreateApplication = ({
7392
7388
  }) => {
7393
7389
  const canManage = userRole === "ADMIN" || userRole === "MANAGER" || userRole === "OWNER";
7394
7390
  const [creationMode, setCreationMode] = (0, import_react108.useState)("EXISTING");
7395
- const [selectedTypeFormatted, setSelectedTypeFormatted] = (0, import_react108.useState)("Company Registration");
7391
+ const defaultTypeKey = applicationTypesMeta.length > 0 ? applicationTypesMeta[0].key : "";
7392
+ const [selectedTypeKey, setSelectedTypeKey] = (0, import_react108.useState)(defaultTypeKey);
7393
+ (0, import_react108.useEffect)(() => {
7394
+ if (!selectedTypeKey && applicationTypesMeta.length > 0) {
7395
+ setSelectedTypeKey(applicationTypesMeta[0].key);
7396
+ }
7397
+ }, [applicationTypesMeta, selectedTypeKey]);
7396
7398
  const [selectedCompanyId, setSelectedCompanyId] = (0, import_react108.useState)(null);
7397
7399
  const [newCompanyName, setNewCompanyName] = (0, import_react108.useState)("");
7398
7400
  const [isPrivate, setIsPrivate] = (0, import_react108.useState)(false);
@@ -7427,8 +7429,7 @@ var UniversalCreateApplication = ({
7427
7429
  const handleSubmit = async (e) => {
7428
7430
  e.preventDefault();
7429
7431
  if (!canManage) return;
7430
- const rawType = APPLICATION_TYPES[FORMATTED_TYPES.indexOf(selectedTypeFormatted)];
7431
- if (!rawType) return import_react_hot_toast21.default.error("Please select a valid application type.");
7432
+ if (!selectedTypeKey) return import_react_hot_toast21.default.error("Please select a valid application type.");
7432
7433
  if (creationMode === "EXISTING" && !selectedCompanyId) return import_react_hot_toast21.default.error("Please select a company.");
7433
7434
  if (creationMode === "NEW" && newCompanyName.trim().length < 2) return import_react_hot_toast21.default.error("Company name is required.");
7434
7435
  setIsSubmitting(true);
@@ -7441,7 +7442,7 @@ var UniversalCreateApplication = ({
7441
7442
  isPrivate,
7442
7443
  assignedUsers: isPrivate ? Array.from(selectedParticipants) : []
7443
7444
  } : void 0,
7444
- type: rawType
7445
+ type: selectedTypeKey
7445
7446
  });
7446
7447
  } catch (error) {
7447
7448
  import_react_hot_toast21.default.error(error.message || "Failed to create application.");
@@ -7449,12 +7450,43 @@ var UniversalCreateApplication = ({
7449
7450
  }
7450
7451
  };
7451
7452
  const activeCompany = companies.find((c) => c.id === selectedCompanyId);
7452
- return /* @__PURE__ */ import_react108.default.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react108.default.createElement(ManagedToaster, null), /* @__PURE__ */ import_react108.default.createElement("div", { className: "mb-6 flex w-full items-center px-1" }, /* @__PURE__ */ import_react108.default.createElement("a", { href: onBackHref, className: "flex items-center gap-2 text-[#d97757] hover:text-[#d97757] transition-colors text-sm outline-none" }, /* @__PURE__ */ import_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.ArrowLeft01Icon, size: 16 }), " Back")), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex flex-col gap-1 mb-6 px-1" }, /* @__PURE__ */ import_react108.default.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Create Application"), /* @__PURE__ */ import_react108.default.createElement("p", { className: "text-xs text-stone-500" }, "Initiate a new registration or filing for a company.")), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex items-center gap-6 mb-6 px-1" }, /* @__PURE__ */ import_react108.default.createElement("button", { onClick: () => setCreationMode("EXISTING"), disabled: isSubmitting, className: `pb-2 text-sm outline-none transition-colors border-b-2 ${creationMode === "EXISTING" ? "border-black text-black" : "border-transparent text-stone-500 hover:text-black"}` }, "Select Company"), /* @__PURE__ */ import_react108.default.createElement("button", { onClick: () => setCreationMode("NEW"), disabled: isSubmitting, className: `pb-2 text-sm outline-none transition-colors border-b-2 ${creationMode === "NEW" ? "border-black text-black" : "border-transparent text-stone-500 hover:text-black"}` }, "New Company")), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex flex-col gap-8 animate-in rounded-2xl p-6 bg-white fade-in duration-300" }, /* @__PURE__ */ import_react108.default.createElement("form", { className: "flex flex-col gap-8", onSubmit: handleSubmit, autoComplete: "off" }, !canManage && /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex items-start gap-3 p-4 bg-stone-50 rounded-xl" }, /* @__PURE__ */ import_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.CircleLock02Icon, size: 20, className: "text-stone-500 shrink-0 mt-0.5" }), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-sm text-black tracking-tight" }, "Access Restricted"), /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-xs text-stone-500 mt-1 leading-relaxed" }, "You lack clearance to create applications."))), creationMode === "EXISTING" ? /* @__PURE__ */ import_react108.default.createElement("div", { className: "space-y-1.5 w-full" }, /* @__PURE__ */ import_react108.default.createElement("label", { className: "text-xs text-stone-400 tracking-[0.2em] block" }, "Target Company"), /* @__PURE__ */ import_react108.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_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.Building03Icon, size: 16, className: "text-stone-400 absolute left-0" }), /* @__PURE__ */ import_react108.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_react108.default.createElement(import_react108.default.Fragment, null, /* @__PURE__ */ import_react108.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_react108.default.createElement("div", { className: `flex items-center justify-between py-2 mt-2 ${!canManage ? "opacity-50 pointer-events-none" : ""}` }, /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-sm text-black tracking-tight" }, "Private Company"), /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-xs text-stone-500" }, "Only assigned members can view and access its applications.")), /* @__PURE__ */ import_react108.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_react108.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_react108.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_react108.default.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-xs text-black tracking-tight" }, "Assigned Members"), /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-xs text-[#d97757] " }, selectedParticipants.size, " added")), /* @__PURE__ */ import_react108.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_react108.default.createElement("div", { className: "space-y-1.5 w-full" }, /* @__PURE__ */ import_react108.default.createElement("label", { className: "text-xs text-stone-400 tracking-[0.2em] block" }, "Application Type"), /* @__PURE__ */ import_react108.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_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.File02Icon, size: 16, className: "text-stone-400 absolute left-0" }), /* @__PURE__ */ import_react108.default.createElement("span", { className: "w-full pl-8 text-sm text-black truncate block" }, selectedTypeFormatted))), canManage && /* @__PURE__ */ import_react108.default.createElement("div", { className: "pt-6" }, /* @__PURE__ */ import_react108.default.createElement(ThreeDActionButton, { type: "submit", disabled: isSubmitting || creationMode === "EXISTING" && !selectedCompanyId || creationMode === "NEW" && newCompanyName.length < 2, isLoading: isSubmitting, className: "w-full sm:w-auto min-w-40" }, "Create Application")))), canManage && /* @__PURE__ */ import_react108.default.createElement(ReusableOptions, { isOpen: showTypeModal, onClose: () => setShowTypeModal(false), title: "Application Type", options: FORMATTED_TYPES, selectedOption: selectedTypeFormatted, onSelect: (t) => setSelectedTypeFormatted(t), showSearch: true }), showCompaniesModal && canManage && /* @__PURE__ */ import_react108.default.createElement("div", { className: "fixed inset-0 z-120 flex items-center justify-center p-4 pointer-events-auto" }, /* @__PURE__ */ import_react108.default.createElement("div", { className: "absolute inset-0 bg-black/30", onClick: () => setShowCompaniesModal(false) }), /* @__PURE__ */ import_react108.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_react108.default.createElement("div", { className: "flex items-center justify-between p-5 shrink-0" }, /* @__PURE__ */ import_react108.default.createElement("h3", { className: "text-sm text-black tracking-tight" }, "Select Company"), /* @__PURE__ */ import_react108.default.createElement("button", { onClick: () => setShowCompaniesModal(false), className: "text-[#d97757] outline-none text-sm" }, "Close")), /* @__PURE__ */ import_react108.default.createElement("div", { className: "p-4 shrink-0" }, /* @__PURE__ */ import_react108.default.createElement("div", { className: "relative w-full" }, /* @__PURE__ */ import_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.Search01Icon, size: 16, className: "text-stone-400 absolute left-4 top-1/2 -translate-y-1/2 pointer-events-none" }), /* @__PURE__ */ import_react108.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-200 transition-colors" }))), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex-1 overflow-y-auto custom-scrollbar p-2" }, isCompaniesLoading ? /* @__PURE__ */ import_react108.default.createElement("div", { className: "absolute inset-0 flex items-center justify-center" }, /* @__PURE__ */ import_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.Loading03Icon, size: 28, className: "animate-spin text-black" })) : companies.length === 0 ? /* @__PURE__ */ import_react108.default.createElement("div", { className: "p-8 text-center text-xs text-stone-400" }, "No companies available.") : companies.map((comp) => /* @__PURE__ */ import_react108.default.createElement("div", { key: comp.id, onClick: () => {
7453
+ const activeTypeObj = applicationTypesMeta.find((t) => t.key === selectedTypeKey) || applicationTypesMeta[0];
7454
+ const modeTabs = [
7455
+ { id: "EXISTING", label: "Select Company" },
7456
+ { id: "NEW", label: "New Company" }
7457
+ ];
7458
+ return /* @__PURE__ */ import_react108.default.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react108.default.createElement(ManagedToaster, null), /* @__PURE__ */ import_react108.default.createElement("div", { className: "mb-6 flex w-full items-center px-1" }, /* @__PURE__ */ import_react108.default.createElement("a", { href: onBackHref, className: "flex items-center gap-2 text-[#d97757] hover:text-[#d97757] transition-colors text-sm outline-none" }, /* @__PURE__ */ import_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.ArrowLeft01Icon, size: 16 }), " Back")), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex flex-col gap-1 mb-6 px-1" }, /* @__PURE__ */ import_react108.default.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Create Application"), /* @__PURE__ */ import_react108.default.createElement("p", { className: "text-xs text-stone-500" }, "Initiate a new registration or filing for a company.")), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex items-center mb-4 w-full animate-in fade-in duration-300 px-2" }, /* @__PURE__ */ import_react108.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) => {
7459
+ const isActive = creationMode === tab.id;
7460
+ return /* @__PURE__ */ import_react108.default.createElement(
7461
+ "button",
7462
+ {
7463
+ key: tab.id,
7464
+ type: "button",
7465
+ onClick: () => setCreationMode(tab.id),
7466
+ disabled: isSubmitting,
7467
+ className: `px-4 py-1.5 rounded-full text-xs transition-all duration-200 outline-none whitespace-nowrap shrink-0 ${isActive ? "bg-stone-50 text-black" : "text-stone-500 hover:text-black hover:bg-stone-50/50"}`
7468
+ },
7469
+ tab.label
7470
+ );
7471
+ }))), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex flex-col gap-8 animate-in rounded-2xl p-6 bg-white fade-in duration-300" }, /* @__PURE__ */ import_react108.default.createElement("form", { className: "flex flex-col gap-8", onSubmit: handleSubmit, autoComplete: "off" }, !canManage && /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex items-start gap-3 p-4 bg-stone-50 rounded-xl" }, /* @__PURE__ */ import_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.CircleLock02Icon, size: 20, className: "text-stone-500 shrink-0 mt-0.5" }), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-sm text-black tracking-tight" }, "Access Restricted"), /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-xs text-stone-500 mt-1 leading-relaxed" }, "You lack clearance to create applications."))), creationMode === "EXISTING" ? /* @__PURE__ */ import_react108.default.createElement("div", { className: "space-y-1.5 w-full" }, /* @__PURE__ */ import_react108.default.createElement("label", { className: "text-xs text-stone-400 tracking-[0.2em] block" }, "Target Company"), /* @__PURE__ */ import_react108.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_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.Building03Icon, size: 16, className: "text-stone-400 absolute left-0" }), /* @__PURE__ */ import_react108.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_react108.default.createElement(import_react108.default.Fragment, null, /* @__PURE__ */ import_react108.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_react108.default.createElement("div", { className: `flex items-center justify-between py-2 mt-2 ${!canManage ? "opacity-50 pointer-events-none" : ""}` }, /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-sm text-black tracking-tight" }, "Private Company"), /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-xs text-stone-500" }, "Only assigned members can view and access its applications.")), /* @__PURE__ */ import_react108.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_react108.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_react108.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_react108.default.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-xs text-black tracking-tight" }, "Members"), /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-xs text-[#d97757]" }, selectedParticipants.size, " added")), /* @__PURE__ */ import_react108.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_react108.default.createElement("div", { className: "space-y-1.5 w-full" }, /* @__PURE__ */ import_react108.default.createElement("label", { className: "text-xs text-stone-400 tracking-[0.2em] block" }, "Application Type"), /* @__PURE__ */ import_react108.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_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.File02Icon, size: 16, className: "text-stone-400 absolute left-0" }), /* @__PURE__ */ import_react108.default.createElement("span", { className: "w-full pl-8 text-sm text-black truncate block" }, activeTypeObj?.label || "Select Type..."))), canManage && /* @__PURE__ */ import_react108.default.createElement("div", { className: "pt-6" }, /* @__PURE__ */ import_react108.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_react108.default.createElement("div", { className: "fixed inset-0 z-120 flex items-center justify-center p-4 pointer-events-auto" }, /* @__PURE__ */ import_react108.default.createElement("div", { className: "absolute inset-0 bg-black/30", onClick: () => setShowTypeModal(false) }), /* @__PURE__ */ import_react108.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_react108.default.createElement("div", { className: "flex items-center justify-between p-5 shrink-0" }, /* @__PURE__ */ import_react108.default.createElement("h3", { className: "text-sm text-black tracking-tight " }, "Application Type"), /* @__PURE__ */ import_react108.default.createElement("button", { onClick: () => setShowTypeModal(false), className: "text-[#d97757] outline-none text-sm" }, "Done")), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex-1 overflow-y-auto custom-scrollbar p-3 space-y-2" }, applicationTypesMeta.map((item) => {
7472
+ const isSelected = selectedTypeKey === item.key;
7473
+ return /* @__PURE__ */ import_react108.default.createElement(
7474
+ "div",
7475
+ {
7476
+ key: item.key,
7477
+ onClick: () => {
7478
+ setSelectedTypeKey(item.key);
7479
+ },
7480
+ 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"}`
7481
+ },
7482
+ /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex items-center justify-between gap-2" }, /* @__PURE__ */ import_react108.default.createElement("h4", { className: "text-xs text-black" }, item.label), isSelected && /* @__PURE__ */ import_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.CheckmarkCircle02Icon, size: 16, className: "text-[#d97757] shrink-0" })),
7483
+ /* @__PURE__ */ import_react108.default.createElement("p", { className: "text-[11px] text-stone-500 mt-1 leading-relaxed whitespace-normal wrap-break-word" }, item.desc)
7484
+ );
7485
+ })))), showCompaniesModal && canManage && /* @__PURE__ */ import_react108.default.createElement("div", { className: "fixed inset-0 z-120 flex items-center justify-center p-4 pointer-events-auto" }, /* @__PURE__ */ import_react108.default.createElement("div", { className: "absolute inset-0 bg-black/30", onClick: () => setShowCompaniesModal(false) }), /* @__PURE__ */ import_react108.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_react108.default.createElement("div", { className: "flex items-center justify-between p-5 shrink-0" }, /* @__PURE__ */ import_react108.default.createElement("h3", { className: "text-sm text-black tracking-tight" }, "Select Company"), /* @__PURE__ */ import_react108.default.createElement("button", { onClick: () => setShowCompaniesModal(false), className: "text-[#d97757] outline-none text-sm" }, "Done")), /* @__PURE__ */ import_react108.default.createElement("div", { className: "p-4 shrink-0" }, /* @__PURE__ */ import_react108.default.createElement("div", { className: "relative w-full" }, /* @__PURE__ */ import_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.Search01Icon, size: 16, className: "text-stone-400 absolute left-4 top-1/2 -translate-y-1/2 pointer-events-none" }), /* @__PURE__ */ import_react108.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-200 transition-colors" }))), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex-1 overflow-y-auto custom-scrollbar p-2" }, isCompaniesLoading ? /* @__PURE__ */ import_react108.default.createElement("div", { className: "absolute inset-0 flex items-center justify-center" }, /* @__PURE__ */ import_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.Loading03Icon, size: 28, className: "animate-spin text-black" })) : companies.length === 0 ? /* @__PURE__ */ import_react108.default.createElement("div", { className: "p-8 text-center text-xs text-stone-400" }, "No companies available.") : companies.map((comp) => /* @__PURE__ */ import_react108.default.createElement("div", { key: comp.id, onClick: () => {
7453
7486
  setSelectedCompanyId(comp.id);
7454
- setShowCompaniesModal(false);
7455
- }, className: "flex items-center justify-between p-3 rounded-xl cursor-pointer hover:bg-stone-50 transition-colors" }, /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex flex-col min-w-0 flex-1 pl-2" }, /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-sm text-black truncate" }, comp.name), comp.isPrivate && /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-[10px] text-[#d97757] mt-0.5 tracking-widest uppercase" }, "Private")), selectedCompanyId === comp.id && /* @__PURE__ */ import_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.Tick02Icon, size: 16, className: "text-[#d97757] mr-2" })))), /* @__PURE__ */ import_react108.default.createElement("div", { className: "p-4 flex items-center justify-between shrink-0 bg-white" }, /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-xs text-stone-400 tracking-widest" }, "Page ", companiesCurrentPage, " of ", companiesTotalPages || 1), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex gap-1" }, /* @__PURE__ */ import_react108.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_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.ArrowLeft01Icon, size: 12 })), /* @__PURE__ */ import_react108.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_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.ArrowRight01Icon, size: 12 })))))), showMembersModal && canManage && /* @__PURE__ */ import_react108.default.createElement("div", { className: "fixed inset-0 z-120 flex items-center justify-center p-4 pointer-events-auto" }, /* @__PURE__ */ import_react108.default.createElement("div", { className: "absolute inset-0 bg-black/30", onClick: () => setShowMembersModal(false) }), /* @__PURE__ */ import_react108.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_react108.default.createElement("div", { className: "flex items-center justify-between p-5 shrink-0" }, /* @__PURE__ */ import_react108.default.createElement("h3", { className: "text-sm text-black tracking-tight" }, "Assign Members"), /* @__PURE__ */ import_react108.default.createElement("button", { onClick: () => setShowMembersModal(false), className: "text-[#d97757] outline-none text-sm" }, "Done")), /* @__PURE__ */ import_react108.default.createElement("div", { className: "p-4 shrink-0" }, /* @__PURE__ */ import_react108.default.createElement("div", { className: "relative w-full" }, /* @__PURE__ */ import_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.Search01Icon, size: 16, className: "text-stone-400 absolute left-4 top-1/2 -translate-y-1/2 pointer-events-none" }), /* @__PURE__ */ import_react108.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-200 transition-colors" }))), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex-1 overflow-y-auto custom-scrollbar p-2" }, isMembersLoading ? /* @__PURE__ */ import_react108.default.createElement("div", { className: "absolute inset-0 flex items-center justify-center" }, /* @__PURE__ */ import_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.Loading03Icon, size: 28, className: "animate-spin text-black" })) : members.length === 0 ? /* @__PURE__ */ import_react108.default.createElement("div", { className: "p-8 text-center text-xs text-stone-400" }, "No members found.") : members.map((member) => {
7487
+ }, className: "flex items-center justify-between p-3 rounded-xl cursor-pointer hover:bg-stone-50 transition-colors" }, /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex flex-col min-w-0 flex-1 pl-2" }, /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-sm text-black truncate" }, comp.name), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex items-center gap-2 mt-0.5" }, /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-[10px] text-stone-500 tracking-widest uppercase" }, "Applications: ", comp.applicationsCount || 0), comp.isPrivate && /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-[10px] text-[#d97757] tracking-widest uppercase" }, "Private"))), selectedCompanyId === comp.id && /* @__PURE__ */ import_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.CheckmarkCircle02Icon, size: 16, className: "text-[#d97757] mr-2" })))), /* @__PURE__ */ import_react108.default.createElement("div", { className: "p-4 flex items-center justify-between shrink-0 bg-white" }, /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-xs text-stone-400 tracking-widest" }, "Page ", companiesCurrentPage, " of ", companiesTotalPages || 1), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex gap-1" }, /* @__PURE__ */ import_react108.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_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.ArrowLeft01Icon, size: 12 })), /* @__PURE__ */ import_react108.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_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.ArrowRight01Icon, size: 12 })))))), showMembersModal && canManage && /* @__PURE__ */ import_react108.default.createElement("div", { className: "fixed inset-0 z-120 flex items-center justify-center p-4 pointer-events-auto" }, /* @__PURE__ */ import_react108.default.createElement("div", { className: "absolute inset-0 bg-black/30", onClick: () => setShowMembersModal(false) }), /* @__PURE__ */ import_react108.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_react108.default.createElement("div", { className: "flex items-center justify-between p-5 shrink-0" }, /* @__PURE__ */ import_react108.default.createElement("h3", { className: "text-sm text-black tracking-tight" }, "Assign Members"), /* @__PURE__ */ import_react108.default.createElement("button", { onClick: () => setShowMembersModal(false), className: "text-[#d97757] outline-none text-sm" }, "Done")), /* @__PURE__ */ import_react108.default.createElement("div", { className: "p-4 shrink-0" }, /* @__PURE__ */ import_react108.default.createElement("div", { className: "relative w-full" }, /* @__PURE__ */ import_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.Search01Icon, size: 16, className: "text-stone-400 absolute left-4 top-1/2 -translate-y-1/2 pointer-events-none" }), /* @__PURE__ */ import_react108.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-200 transition-colors" }))), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex-1 overflow-y-auto custom-scrollbar p-2" }, isMembersLoading ? /* @__PURE__ */ import_react108.default.createElement("div", { className: "absolute inset-0 flex items-center justify-center" }, /* @__PURE__ */ import_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.Loading03Icon, size: 28, className: "animate-spin text-black" })) : members.length === 0 ? /* @__PURE__ */ import_react108.default.createElement("div", { className: "p-8 text-center text-xs text-stone-400" }, "No members found.") : members.map((member) => {
7456
7488
  const isChecked = selectedParticipants.has(member.userId);
7457
- return /* @__PURE__ */ import_react108.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_react108.default.createElement("div", { className: "flex items-center gap-3 min-w-0 flex-1" }, /* @__PURE__ */ import_react108.default.createElement(MemberAvatar6, { src: member.avatarUrl, sizeClass: "w-9 h-9" }), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex flex-col min-w-0 flex-1" }, /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-sm text-black truncate" }, member.fullName), /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-xs text-stone-400 capitalize truncate" }, member.role.toLowerCase()))), /* @__PURE__ */ import_react108.default.createElement("div", { className: "shrink-0 pl-3" }, /* @__PURE__ */ import_react108.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_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.Tick02Icon, size: 14, className: "text-white" }))));
7489
+ return /* @__PURE__ */ import_react108.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_react108.default.createElement("div", { className: "flex items-center gap-3 min-w-0 flex-1" }, /* @__PURE__ */ import_react108.default.createElement(MemberAvatar6, { src: member.avatarUrl, sizeClass: "w-9 h-9" }), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex flex-col min-w-0 flex-1" }, /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-sm text-black truncate" }, member.fullName), /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-xs text-stone-400 capitalize truncate" }, member.role.toLowerCase()))), /* @__PURE__ */ import_react108.default.createElement("div", { className: "shrink-0 pl-3" }, /* @__PURE__ */ import_react108.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_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.CheckmarkCircle02Icon, size: 14, className: "text-white" }))));
7458
7490
  })), /* @__PURE__ */ import_react108.default.createElement("div", { className: "p-4 flex items-center justify-between shrink-0 bg-white" }, /* @__PURE__ */ import_react108.default.createElement("span", { className: "text-xs text-stone-400 tracking-widest" }, "Page ", membersCurrentPage, " of ", membersTotalPages || 1), /* @__PURE__ */ import_react108.default.createElement("div", { className: "flex gap-1" }, /* @__PURE__ */ import_react108.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_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.ArrowLeft01Icon, size: 12 })), /* @__PURE__ */ import_react108.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_react108.default.createElement(import_react109.HugeiconsIcon, { icon: import_core_free_icons43.ArrowRight01Icon, size: 12 })))))));
7459
7491
  };
7460
7492
  // Annotate the CommonJS export names for ESM import in node:
package/dist/index.mjs CHANGED
@@ -948,7 +948,7 @@ var UniversalHuddleDetails = ({
948
948
  }
949
949
  setIsDeleting(false);
950
950
  };
951
- return /* @__PURE__ */ React11.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React11.createElement(ManagedToaster, null), /* @__PURE__ */ React11.createElement(
951
+ return /* @__PURE__ */ React11.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React11.createElement(ManagedToaster, null), /* @__PURE__ */ React11.createElement(
952
952
  ConfirmationDialog,
953
953
  {
954
954
  isOpen: confirmDialog !== null,
@@ -1899,7 +1899,7 @@ var UniversalHomeView = ({
1899
1899
  const fallbackAvatarUrl = `/api/avatar/?name=${encodeURIComponent(fullName || " ")}&background=ffffff&color=000000&size=100&font-size=0.33`;
1900
1900
  const finalAvatarSrc = avatarSrc || fallbackAvatarUrl;
1901
1901
  const hasUnreadNotifs = notifications.some((n) => !n.isRead);
1902
- return /* @__PURE__ */ React20.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React20.createElement("div", { className: "flex items-center justify-between w-full pb-4 " }, /* @__PURE__ */ React20.createElement("div", { className: "w-10 h-10 rounded-full bg-white p-0.75 flex items-center justify-center cursor-pointer", onClick: () => router.push("/app/account/me") }, /* @__PURE__ */ React20.createElement("div", { className: "relative w-full h-full rounded-full overflow-hidden bg-stone-100 flex items-center justify-center" }, !isAvatarLoaded && /* @__PURE__ */ React20.createElement("div", { className: "absolute inset-0 flex items-center justify-center z-10 bg-stone-100" }, /* @__PURE__ */ React20.createElement(HugeiconsIcon15, { icon: Loading03Icon8, size: 16, className: "animate-spin text-black" })), /* @__PURE__ */ React20.createElement(
1902
+ return /* @__PURE__ */ React20.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React20.createElement("div", { className: "flex items-center justify-between w-full pb-4 " }, /* @__PURE__ */ React20.createElement("div", { className: "w-10 h-10 rounded-full bg-white p-0.75 flex items-center justify-center cursor-pointer", onClick: () => router.push("/app/account/me") }, /* @__PURE__ */ React20.createElement("div", { className: "relative w-full h-full rounded-full overflow-hidden bg-stone-100 flex items-center justify-center" }, !isAvatarLoaded && /* @__PURE__ */ React20.createElement("div", { className: "absolute inset-0 flex items-center justify-center z-10 bg-stone-100" }, /* @__PURE__ */ React20.createElement(HugeiconsIcon15, { icon: Loading03Icon8, size: 16, className: "animate-spin text-black" })), /* @__PURE__ */ React20.createElement(
1903
1903
  "img",
1904
1904
  {
1905
1905
  src: finalAvatarSrc,
@@ -2275,7 +2275,7 @@ var UniversalCardPage = ({
2275
2275
  img.onload = () => setIsBgLoaded(true);
2276
2276
  }, [activeCard?.cardBgSrc]);
2277
2277
  if (!activeCard || sortedCards.length === 0) {
2278
- return /* @__PURE__ */ React22.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative min-h-100 justify-center" }, /* @__PURE__ */ React22.createElement("div", { className: "p-6 w-full max-w-md mx-auto text-center" }, /* @__PURE__ */ React22.createElement("div", { className: "mb-8 flex justify-center" }, /* @__PURE__ */ React22.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", className: "w-12 h-12 fill-stone-100" }, /* @__PURE__ */ React22.createElement("path", { fillRule: "evenodd", d: "M2.25 12c0-5.385 4.365-9.75 9.75-9.75s9.75 4.365 9.75 9.75-4.365 9.75-9.75 9.75S2.25 17.385 2.25 12zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z", clipRule: "evenodd" }))), /* @__PURE__ */ React22.createElement("h1", { className: "text-xl text-black tracking-tight mb-4" }, "No cards available"), /* @__PURE__ */ React22.createElement("p", { className: "text-sm leading-[1.8] text-stone-600 mb-12" }, "You do not have any active cards on your account.")));
2278
+ return /* @__PURE__ */ React22.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative min-h-100 justify-center" }, /* @__PURE__ */ React22.createElement("div", { className: "p-6 w-full max-w-md mx-auto text-center" }, /* @__PURE__ */ React22.createElement("div", { className: "mb-8 flex justify-center" }, /* @__PURE__ */ React22.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", className: "w-12 h-12 fill-stone-100" }, /* @__PURE__ */ React22.createElement("path", { fillRule: "evenodd", d: "M2.25 12c0-5.385 4.365-9.75 9.75-9.75s9.75 4.365 9.75 9.75-4.365 9.75-9.75 9.75S2.25 17.385 2.25 12zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z", clipRule: "evenodd" }))), /* @__PURE__ */ React22.createElement("h1", { className: "text-xl text-black tracking-tight mb-4" }, "No cards available"), /* @__PURE__ */ React22.createElement("p", { className: "text-sm leading-[1.8] text-stone-600 mb-12" }, "You do not have any active cards on your account.")));
2279
2279
  }
2280
2280
  const isActivated = activeCard.status === "ACTIVATED";
2281
2281
  const isFrozen = activeCard.status === "FROZEN";
@@ -2303,7 +2303,7 @@ var UniversalCardPage = ({
2303
2303
  const formatTabLabel = (type) => {
2304
2304
  return type.charAt(0).toUpperCase() + type.slice(1).toLowerCase() + " Card";
2305
2305
  };
2306
- return /* @__PURE__ */ React22.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, sortedCards.length > 1 && /* @__PURE__ */ React22.createElement("div", { className: "flex items-center justify-center mb-6 w-full px-2 gap-3" }, /* @__PURE__ */ React22.createElement("div", { className: "flex items-center bg-white rounded-full p-1 max-w-full overflow-x-auto custom-scrollbar" }, sortedCards.map((tab, idx) => /* @__PURE__ */ React22.createElement(
2306
+ return /* @__PURE__ */ React22.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, sortedCards.length > 1 && /* @__PURE__ */ React22.createElement("div", { className: "flex items-center justify-center mb-6 w-full px-2 gap-3" }, /* @__PURE__ */ React22.createElement("div", { className: "flex items-center bg-white rounded-full p-1 max-w-full overflow-x-auto custom-scrollbar" }, sortedCards.map((tab, idx) => /* @__PURE__ */ React22.createElement(
2307
2307
  "button",
2308
2308
  {
2309
2309
  key: tab.id,
@@ -5063,7 +5063,7 @@ var UniversalHuddlesPage = ({
5063
5063
  onHuddleClick,
5064
5064
  onCreateHuddle
5065
5065
  }) => {
5066
- return /* @__PURE__ */ React49.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React49.createElement("div", { className: "flex flex-col gap-8 p-6 rounded-2xl bg-white w-full" }, /* @__PURE__ */ React49.createElement("div", { className: "flex flex-col gap-1" }, /* @__PURE__ */ React49.createElement("div", { className: "flex flex-row items-center justify-between gap-4" }, /* @__PURE__ */ React49.createElement("h2", { className: "text-black text-xl tracking-tight" }, headerTitle), /* @__PURE__ */ React49.createElement(
5066
+ return /* @__PURE__ */ React49.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React49.createElement("div", { className: "flex flex-col gap-8 p-6 rounded-2xl bg-white w-full" }, /* @__PURE__ */ React49.createElement("div", { className: "flex flex-col gap-1" }, /* @__PURE__ */ React49.createElement("div", { className: "flex flex-row items-center justify-between gap-4" }, /* @__PURE__ */ React49.createElement("h2", { className: "text-black text-xl tracking-tight" }, headerTitle), /* @__PURE__ */ React49.createElement(
5067
5067
  "button",
5068
5068
  {
5069
5069
  onClick: () => onCreateHuddle?.(),
@@ -5448,7 +5448,7 @@ var UniversalHome2 = ({
5448
5448
  setShowLogoutConfirm(false);
5449
5449
  }
5450
5450
  };
5451
- return /* @__PURE__ */ React51.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React51.createElement(
5451
+ return /* @__PURE__ */ React51.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React51.createElement(
5452
5452
  ConfirmationDialog,
5453
5453
  {
5454
5454
  isOpen: showLogoutConfirm,
@@ -6088,7 +6088,7 @@ var UniversalCreateHuddle = ({
6088
6088
  setIsSubmitting(false);
6089
6089
  }
6090
6090
  };
6091
- return /* @__PURE__ */ React53.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React53.createElement(ManagedToaster, null), /* @__PURE__ */ React53.createElement("div", { className: "mb-6 flex w-full items-center px-1" }, /* @__PURE__ */ React53.createElement("a", { href: onBackHref, className: "flex items-center gap-2 text-[#d97757] hover:text-[#d97757] transition-colors text-sm outline-none" }, /* @__PURE__ */ React53.createElement(HugeiconsIcon39, { icon: ArrowLeft01Icon19, size: 16 }), " Back")), /* @__PURE__ */ React53.createElement("div", { className: "flex flex-col gap-1 mb-8 px-1" }, /* @__PURE__ */ React53.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Create Huddle"), /* @__PURE__ */ React53.createElement("p", { className: "text-xs text-stone-500" }, "Schedule a new workspace huddle and manage participant access.")), /* @__PURE__ */ React53.createElement("div", { className: "flex flex-col gap-8 animate-in rounded-2xl p-6 bg-white fade-in duration-300" }, /* @__PURE__ */ React53.createElement("form", { className: "flex flex-col gap-8", onSubmit: handleSubmit, autoComplete: "off" }, !canManage && /* @__PURE__ */ React53.createElement("div", { className: "flex items-start gap-3 p-4 bg-stone-50 rounded-xl" }, /* @__PURE__ */ React53.createElement(HugeiconsIcon39, { icon: CircleLock02Icon4, size: 20, className: "text-stone-500 shrink-0 mt-0.5" }), /* @__PURE__ */ React53.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ React53.createElement("span", { className: "text-sm text-black tracking-tight" }, "Access Restricted"), /* @__PURE__ */ React53.createElement("span", { className: "text-xs text-stone-500 mt-1 leading-relaxed" }, "You do not have sufficient permissions to access this page. Contact organization admin or manager."))), /* @__PURE__ */ React53.createElement(
6091
+ return /* @__PURE__ */ React53.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React53.createElement(ManagedToaster, null), /* @__PURE__ */ React53.createElement("div", { className: "mb-6 flex w-full items-center px-1" }, /* @__PURE__ */ React53.createElement("a", { href: onBackHref, className: "flex items-center gap-2 text-[#d97757] hover:text-[#d97757] transition-colors text-sm outline-none" }, /* @__PURE__ */ React53.createElement(HugeiconsIcon39, { icon: ArrowLeft01Icon19, size: 16 }), " Back")), /* @__PURE__ */ React53.createElement("div", { className: "flex flex-col gap-1 mb-8 px-1" }, /* @__PURE__ */ React53.createElement("h1", { className: "text-black text-xl tracking-tight" }, "Create Huddle"), /* @__PURE__ */ React53.createElement("p", { className: "text-xs text-stone-500" }, "Schedule a new workspace huddle and manage participant access.")), /* @__PURE__ */ React53.createElement("div", { className: "flex flex-col gap-8 animate-in rounded-2xl p-6 bg-white fade-in duration-300" }, /* @__PURE__ */ React53.createElement("form", { className: "flex flex-col gap-8", onSubmit: handleSubmit, autoComplete: "off" }, !canManage && /* @__PURE__ */ React53.createElement("div", { className: "flex items-start gap-3 p-4 bg-stone-50 rounded-xl" }, /* @__PURE__ */ React53.createElement(HugeiconsIcon39, { icon: CircleLock02Icon4, size: 20, className: "text-stone-500 shrink-0 mt-0.5" }), /* @__PURE__ */ React53.createElement("div", { className: "flex flex-col" }, /* @__PURE__ */ React53.createElement("span", { className: "text-sm text-black tracking-tight" }, "Access Restricted"), /* @__PURE__ */ React53.createElement("span", { className: "text-xs text-stone-500 mt-1 leading-relaxed" }, "You do not have sufficient permissions to access this page. Contact organization admin or manager."))), /* @__PURE__ */ React53.createElement(
6092
6092
  TextInput,
6093
6093
  {
6094
6094
  label: "Huddle Subject",
@@ -6425,7 +6425,7 @@ var UniversalApplicationsPage = ({
6425
6425
  onApplicationClick,
6426
6426
  onCreateApplication
6427
6427
  }) => {
6428
- return /* @__PURE__ */ React55.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React55.createElement("div", { className: "flex flex-col gap-8 p-6 rounded-2xl bg-white w-full" }, /* @__PURE__ */ React55.createElement("div", { className: "flex flex-col gap-1" }, /* @__PURE__ */ React55.createElement("div", { className: "flex flex-row items-center justify-between gap-4" }, /* @__PURE__ */ React55.createElement("h2", { className: "text-black text-xl tracking-tight" }, headerTitle), /* @__PURE__ */ React55.createElement(
6428
+ return /* @__PURE__ */ React55.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React55.createElement("div", { className: "flex flex-col gap-8 p-6 rounded-2xl bg-white w-full" }, /* @__PURE__ */ React55.createElement("div", { className: "flex flex-col gap-1" }, /* @__PURE__ */ React55.createElement("div", { className: "flex flex-row items-center justify-between gap-4" }, /* @__PURE__ */ React55.createElement("h2", { className: "text-black text-xl tracking-tight" }, headerTitle), /* @__PURE__ */ React55.createElement(
6429
6429
  "button",
6430
6430
  {
6431
6431
  onClick: () => onCreateApplication?.(),
@@ -6505,7 +6505,7 @@ var UniversalHome3 = ({
6505
6505
  setIsResolving(false);
6506
6506
  }
6507
6507
  };
6508
- return /* @__PURE__ */ React56.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React56.createElement("div", { className: "flex items-center justify-between w-full pb-4" }, /* @__PURE__ */ React56.createElement("div", { className: "flex items-center gap-2 shrink-0" }, /* @__PURE__ */ React56.createElement(
6508
+ return /* @__PURE__ */ React56.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React56.createElement("div", { className: "flex items-center justify-between w-full pb-4" }, /* @__PURE__ */ React56.createElement("div", { className: "flex items-center gap-3" }), /* @__PURE__ */ React56.createElement("div", { className: "flex items-center gap-2 shrink-0" }, /* @__PURE__ */ React56.createElement(
6509
6509
  "button",
6510
6510
  {
6511
6511
  onClick: () => router.push("/app/ai"),
@@ -6622,6 +6622,7 @@ function RootSidebar({
6622
6622
  currentPath,
6623
6623
  isMobileOpen,
6624
6624
  closeMobile,
6625
+ openMobile,
6625
6626
  onNavClick,
6626
6627
  avatarSrc,
6627
6628
  title = "App",
@@ -6658,23 +6659,38 @@ function RootSidebar({
6658
6659
  }
6659
6660
  };
6660
6661
  const finalAvatarSrc = avatarSrc || "https://storage.googleapis.com/retina-cloud-v2/assets/images/avatar.avif";
6661
- return /* @__PURE__ */ React57.createElement(React57.Fragment, null, /* @__PURE__ */ React57.createElement(
6662
+ return /* @__PURE__ */ React57.createElement(React57.Fragment, null, !isMobileOpen && /* @__PURE__ */ React57.createElement(
6663
+ "button",
6664
+ {
6665
+ onClick: openMobile,
6666
+ className: "md:hidden fixed left-0 top-1/2 -translate-y-1/2 z-50 bg-white border border-stone-200 border-l-0 shadow-[4px_0_24px_rgba(0,0,0,0.06)] rounded-r-xl py-6 px-1.5 flex items-center justify-center outline-none hover:bg-stone-50 transition-colors",
6667
+ "aria-label": "Open Menu"
6668
+ },
6669
+ /* @__PURE__ */ React57.createElement(
6670
+ "span",
6671
+ {
6672
+ className: "text-[10px] font-medium uppercase tracking-[0.2em] text-stone-500",
6673
+ style: { writingMode: "vertical-rl", transform: "rotate(180deg)" }
6674
+ },
6675
+ "Open Menu"
6676
+ )
6677
+ ), /* @__PURE__ */ React57.createElement(
6662
6678
  "div",
6663
6679
  {
6664
- className: `fixed inset-0 bg-black/30 shadow-2xl transition-opacity duration-300 md:hidden z-90 ${isMobileOpen ? "opacity-100 pointer-events-auto" : "opacity-0 pointer-events-none"}`,
6680
+ className: `fixed inset-0 bg-black/40 shadow-2xl transition-opacity duration-300 md:hidden z-90 ${isMobileOpen ? "opacity-100 pointer-events-auto" : "opacity-0 pointer-events-none"}`,
6665
6681
  onClick: closeMobile
6666
6682
  }
6667
6683
  ), /* @__PURE__ */ React57.createElement(
6668
6684
  "aside",
6669
6685
  {
6670
6686
  className: `
6671
- fixed md:sticky rounded-2xl top-4 md:top-4 md:my-4 left-4 md:left-0 md:ml-4 h-[calc(100dvh-2rem)] bg-white
6687
+ fixed md:sticky top-0 left-0 h-dvh bg-[#212121]
6672
6688
  transition-all duration-300 ease-in-out shrink-0 flex flex-col z-100 md:z-10
6673
6689
  ${isMobileOpen ? "translate-x-0" : "translate-x-[-120%] md:translate-x-0"}
6674
6690
  ${isCollapsed ? "md:w-16 w-64" : "w-64"}
6675
6691
  `
6676
6692
  },
6677
- /* @__PURE__ */ React57.createElement("div", { className: `flex items-center shrink-0 p-5 ${isCollapsed && !isMobileOpen ? "justify-center" : "justify-between"}` }, /* @__PURE__ */ React57.createElement(Link10, { href: homeUrl, className: `flex items-center outline-none group min-w-0 ${isCollapsed && !isMobileOpen ? "" : "gap-3 pr-2"}` }, /* @__PURE__ */ React57.createElement("div", { className: "w-8 h-8 shrink-0 relative rounded-lg overflow-hidden bg-stone-50 flex items-center justify-center" }, !isAvatarLoaded && /* @__PURE__ */ React57.createElement(HugeiconsIcon43, { icon: Loading03Icon31, size: 14, className: "animate-spin text-stone-300 absolute" }), /* @__PURE__ */ React57.createElement(
6693
+ /* @__PURE__ */ React57.createElement("div", { className: `flex items-center shrink-0 p-5 ${isCollapsed && !isMobileOpen ? "justify-center" : "justify-between"}` }, /* @__PURE__ */ React57.createElement(Link10, { href: homeUrl, className: `flex items-center outline-none group min-w-0 ${isCollapsed && !isMobileOpen ? "" : "gap-3 pr-2"}` }, /* @__PURE__ */ React57.createElement("div", { className: "w-8 h-8 shrink-0 relative rounded-lg overflow-hidden bg-white/10 flex items-center justify-center" }, !isAvatarLoaded && /* @__PURE__ */ React57.createElement(HugeiconsIcon43, { icon: Loading03Icon31, size: 14, className: "animate-spin text-white/50 absolute" }), /* @__PURE__ */ React57.createElement(
6678
6694
  "img",
6679
6695
  {
6680
6696
  src: finalAvatarSrc,
@@ -6682,11 +6698,11 @@ function RootSidebar({
6682
6698
  onLoad: () => setIsAvatarLoaded(true),
6683
6699
  className: `w-full h-full object-cover transition-opacity duration-300 ${isAvatarLoaded ? "opacity-100" : "opacity-0"}`
6684
6700
  }
6685
- )), (!isCollapsed || isMobileOpen) && /* @__PURE__ */ React57.createElement("div", { className: "flex flex-col justify-center min-w-0" }, /* @__PURE__ */ React57.createElement("span", { className: "text-[13px] font-serif text-black leading-none truncate max-w-32.5 tracking-wide mb-1 group-hover:opacity-70 transition-opacity" }, title), subtitle && /* @__PURE__ */ React57.createElement("span", { className: "text-[9px] text-neutral-500 truncate max-w-32.5 tracking-[0.2em] leading-none uppercase" }, subtitle))), (!isCollapsed || isMobileOpen) && /* @__PURE__ */ React57.createElement("div", { className: "md:hidden flex shrink-0" }, /* @__PURE__ */ React57.createElement(
6701
+ )), (!isCollapsed || isMobileOpen) && /* @__PURE__ */ React57.createElement("div", { className: "flex flex-col justify-center min-w-0" }, /* @__PURE__ */ React57.createElement("span", { className: "text-[13px] font-serif text-white leading-none truncate max-w-32.5 tracking-wide mb-1 group-hover:opacity-80 transition-opacity" }, title), subtitle && /* @__PURE__ */ React57.createElement("span", { className: "text-[9px] text-neutral-400 truncate max-w-32.5 tracking-[0.2em] leading-none uppercase" }, subtitle))), (!isCollapsed || isMobileOpen) && /* @__PURE__ */ React57.createElement("div", { className: "md:hidden flex shrink-0" }, /* @__PURE__ */ React57.createElement(
6686
6702
  "button",
6687
6703
  {
6688
6704
  onClick: closeMobile,
6689
- className: "text-neutral-400 hover:text-black transition-colors outline-none",
6705
+ className: "text-neutral-400 hover:text-white transition-colors outline-none",
6690
6706
  "aria-label": "Close Menu"
6691
6707
  },
6692
6708
  /* @__PURE__ */ React57.createElement(HugeiconsIcon43, { icon: CancelCircleIcon15, size: 24 })
@@ -6700,7 +6716,7 @@ function RootSidebar({
6700
6716
  key: item.name,
6701
6717
  href: item.path,
6702
6718
  onClick: (e) => onNavClick ? onNavClick(e, item.path) : void 0,
6703
- className: `flex items-center gap-3 px-3 py-2 rounded-full transition-all outline-none group shrink-0 ${isCurrentRoute ? "bg-neutral-100 text-black " : "text-neutral-500 hover:text-black hover:bg-neutral-50"}`,
6719
+ className: `flex items-center gap-3 px-3 py-2 rounded-full transition-all outline-none group shrink-0 ${isCurrentRoute ? "bg-white/10 text-white" : "text-neutral-400 hover:text-white hover:bg-white/5"}`,
6704
6720
  title: isCollapsed && !isMobileOpen ? item.name : void 0
6705
6721
  },
6706
6722
  /* @__PURE__ */ React57.createElement(
@@ -6708,17 +6724,17 @@ function RootSidebar({
6708
6724
  {
6709
6725
  icon: item.icon,
6710
6726
  size: 18,
6711
- className: `shrink-0 transition-colors ${isCurrentRoute ? "text-black" : "text-neutral-400 group-hover:text-black"}`
6727
+ className: `shrink-0 transition-colors ${isCurrentRoute ? "text-white" : "text-neutral-400 group-hover:text-white"}`
6712
6728
  }
6713
6729
  ),
6714
6730
  (!isCollapsed || isMobileOpen) && /* @__PURE__ */ React57.createElement("span", { className: "text-xs tracking-wide truncate" }, item.name)
6715
6731
  );
6716
6732
  })),
6717
- /* @__PURE__ */ React57.createElement("div", { className: "p-4 shrink-0 flex flex-col gap-2 " }, (showWorkspaceSwitcher || showLogoutAction) && /* @__PURE__ */ React57.createElement("div", { className: `flex gap-2 px-1 pb-2 ${isCollapsed && !isMobileOpen ? "flex-col items-center" : "flex-col items-start md:flex-row md:items-center"}` }, showWorkspaceSwitcher && workspaces && workspaces.length > 0 && /* @__PURE__ */ React57.createElement(
6733
+ /* @__PURE__ */ React57.createElement("div", { className: "p-4 shrink-0 flex flex-col gap-2" }, (showWorkspaceSwitcher || showLogoutAction) && /* @__PURE__ */ React57.createElement("div", { className: `flex gap-2 px-1 pb-2 ${isCollapsed && !isMobileOpen ? "flex-col items-center" : "flex-row items-center"}` }, showWorkspaceSwitcher && workspaces && workspaces.length > 0 && /* @__PURE__ */ React57.createElement(
6718
6734
  "button",
6719
6735
  {
6720
6736
  onClick: () => setShowSwitcherDialog(true),
6721
- className: "w-8 h-8 shrink-0 rounded-full bg-neutral-50 flex items-center justify-center text-neutral-500 hover:text-black hover:bg-neutral-100 transition-all outline-none",
6737
+ className: "w-8 h-8 shrink-0 rounded-full bg-white/5 flex items-center justify-center text-neutral-400 hover:text-white hover:bg-white/10 transition-all outline-none",
6722
6738
  title: "Switch Workspace"
6723
6739
  },
6724
6740
  /* @__PURE__ */ React57.createElement(HugeiconsIcon43, { icon: UserIcon3, size: 16 })
@@ -6726,15 +6742,15 @@ function RootSidebar({
6726
6742
  "button",
6727
6743
  {
6728
6744
  onClick: () => setShowLogoutDialog(true),
6729
- className: "w-8 h-8 shrink-0 rounded-full bg-neutral-50 flex items-center justify-center text-neutral-500 hover:text-black hover:bg-neutral-100 transition-all outline-none",
6745
+ className: "w-8 h-8 shrink-0 rounded-full bg-white/5 flex items-center justify-center text-neutral-400 hover:text-white hover:bg-white/10 transition-all outline-none",
6730
6746
  title: "Secure Logout"
6731
6747
  },
6732
6748
  /* @__PURE__ */ React57.createElement(HugeiconsIcon43, { icon: LogoutCircle02Icon3, size: 16 })
6733
- )), /* @__PURE__ */ React57.createElement("div", { className: "hidden md:block" }, /* @__PURE__ */ React57.createElement(
6749
+ )), /* @__PURE__ */ React57.createElement("div", { className: "hidden md:block border-t border-white/5 pt-2" }, /* @__PURE__ */ React57.createElement(
6734
6750
  "button",
6735
6751
  {
6736
6752
  onClick: () => setIsCollapsed(!isCollapsed),
6737
- className: "flex items-center justify-center md:justify-start gap-3 w-full p-2.5 rounded-full text-neutral-500 hover:text-black hover:bg-neutral-50 transition-colors outline-none"
6753
+ className: "flex items-center justify-center md:justify-start gap-3 w-full p-2.5 rounded-full text-neutral-400 hover:text-white hover:bg-white/5 transition-colors outline-none"
6738
6754
  },
6739
6755
  /* @__PURE__ */ React57.createElement(HugeiconsIcon43, { icon: SidebarLeft01Icon2, size: 18, className: "shrink-0 text-neutral-400" }),
6740
6756
  !isCollapsed && /* @__PURE__ */ React57.createElement("span", { className: "text-xs" }, "Collapse")
@@ -7344,7 +7360,7 @@ var UniversalApplicationPage2 = ({
7344
7360
  "QUERIED",
7345
7361
  "AWAITING_PAYMENT"
7346
7362
  ];
7347
- return /* @__PURE__ */ React60.createElement("div", { className: "w-full max-w-3xl 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(HugeiconsIcon45, { icon: Search01Icon10, size: 16, className: "text-stone-400" })), /* @__PURE__ */ React60.createElement(
7363
+ 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(HugeiconsIcon45, { icon: Search01Icon10, size: 16, className: "text-stone-400" })), /* @__PURE__ */ React60.createElement(
7348
7364
  "input",
7349
7365
  {
7350
7366
  type: "text",
@@ -7414,7 +7430,7 @@ var UniversalApplicationDetails = ({
7414
7430
  }
7415
7431
  setIsDeleting(false);
7416
7432
  };
7417
- return /* @__PURE__ */ React61.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React61.createElement(ManagedToaster, null), /* @__PURE__ */ React61.createElement(
7433
+ return /* @__PURE__ */ React61.createElement("div", { className: "w-full max-w-4xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React61.createElement(ManagedToaster, null), /* @__PURE__ */ React61.createElement(
7418
7434
  ConfirmationDialog,
7419
7435
  {
7420
7436
  isOpen: confirmDialog,
@@ -7427,11 +7443,11 @@ var UniversalApplicationDetails = ({
7427
7443
  onClose: () => setConfirmDialog(false),
7428
7444
  onConfirm: handleDelete
7429
7445
  }
7430
- ), /* @__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(HugeiconsIcon46, { icon: ArrowLeft01Icon24, 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-100 text-stone-600 rounded-full text-xs self-start sm:self-auto uppercase tracking-widest font-medium" }, 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 font-medium" }, 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"))));
7446
+ ), /* @__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(HugeiconsIcon46, { icon: ArrowLeft01Icon24, 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-100 text-stone-600 rounded-full text-xs self-start sm:self-auto uppercase 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"))));
7431
7447
  };
7432
7448
 
7433
7449
  // src/components/UniversalCreateApplication.tsx
7434
- import React62, { useState as useState46, useRef as useRef19 } from "react";
7450
+ import React62, { useState as useState46, useRef as useRef19, useEffect as useEffect26 } from "react";
7435
7451
  import toast20 from "react-hot-toast";
7436
7452
  import { HugeiconsIcon as HugeiconsIcon47 } from "@hugeicons/react";
7437
7453
  import {
@@ -7440,7 +7456,7 @@ import {
7440
7456
  Loading03Icon as Loading03Icon33,
7441
7457
  Search01Icon as Search01Icon11,
7442
7458
  CircleLock02Icon as CircleLock02Icon6,
7443
- Tick02Icon as Tick02Icon4,
7459
+ CheckmarkCircle02Icon as CheckmarkCircle02Icon2,
7444
7460
  Building03Icon,
7445
7461
  File02Icon
7446
7462
  } from "@hugeicons/core-free-icons";
@@ -7450,30 +7466,10 @@ var MemberAvatar6 = ({ src, sizeClass = "w-10 h-10" }) => {
7450
7466
  const defaultAvatar = "https://storage.googleapis.com/retina-cloud-v2/assets/images/avatar.avif";
7451
7467
  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(HugeiconsIcon47, { 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) })));
7452
7468
  };
7453
- var APPLICATION_TYPES = [
7454
- "COMPANY_REGISTRATION",
7455
- "BUSINESS_NAME",
7456
- "NGO_INCORPORATION",
7457
- "TRADEMARK",
7458
- "COPYRIGHT",
7459
- "PATENT",
7460
- "NDPC",
7461
- "GDPR",
7462
- "SCUML_CERTIFICATE",
7463
- "TAX_FILING",
7464
- "TIN_APPLICATION",
7465
- "VAT_REGISTRATION",
7466
- "ANNUAL_RETURNS",
7467
- "CHANGE_OF_DIRECTORS",
7468
- "CHANGE_OF_NAME",
7469
- "NAFDAC_REGISTRATION",
7470
- "OTHER"
7471
- ];
7472
- var formatType3 = (type) => type.split("_").map((w) => w[0] + w.slice(1).toLowerCase()).join(" ");
7473
- var FORMATTED_TYPES = APPLICATION_TYPES.map(formatType3);
7474
7469
  var UniversalCreateApplication = ({
7475
7470
  onBackHref,
7476
7471
  userRole = "MEMBER",
7472
+ applicationTypesMeta = [],
7477
7473
  members,
7478
7474
  isMembersLoading,
7479
7475
  membersCurrentPage,
@@ -7492,7 +7488,13 @@ var UniversalCreateApplication = ({
7492
7488
  }) => {
7493
7489
  const canManage = userRole === "ADMIN" || userRole === "MANAGER" || userRole === "OWNER";
7494
7490
  const [creationMode, setCreationMode] = useState46("EXISTING");
7495
- const [selectedTypeFormatted, setSelectedTypeFormatted] = useState46("Company Registration");
7491
+ const defaultTypeKey = applicationTypesMeta.length > 0 ? applicationTypesMeta[0].key : "";
7492
+ const [selectedTypeKey, setSelectedTypeKey] = useState46(defaultTypeKey);
7493
+ useEffect26(() => {
7494
+ if (!selectedTypeKey && applicationTypesMeta.length > 0) {
7495
+ setSelectedTypeKey(applicationTypesMeta[0].key);
7496
+ }
7497
+ }, [applicationTypesMeta, selectedTypeKey]);
7496
7498
  const [selectedCompanyId, setSelectedCompanyId] = useState46(null);
7497
7499
  const [newCompanyName, setNewCompanyName] = useState46("");
7498
7500
  const [isPrivate, setIsPrivate] = useState46(false);
@@ -7527,8 +7529,7 @@ var UniversalCreateApplication = ({
7527
7529
  const handleSubmit = async (e) => {
7528
7530
  e.preventDefault();
7529
7531
  if (!canManage) return;
7530
- const rawType = APPLICATION_TYPES[FORMATTED_TYPES.indexOf(selectedTypeFormatted)];
7531
- if (!rawType) return toast20.error("Please select a valid application type.");
7532
+ if (!selectedTypeKey) return toast20.error("Please select a valid application type.");
7532
7533
  if (creationMode === "EXISTING" && !selectedCompanyId) return toast20.error("Please select a company.");
7533
7534
  if (creationMode === "NEW" && newCompanyName.trim().length < 2) return toast20.error("Company name is required.");
7534
7535
  setIsSubmitting(true);
@@ -7541,7 +7542,7 @@ var UniversalCreateApplication = ({
7541
7542
  isPrivate,
7542
7543
  assignedUsers: isPrivate ? Array.from(selectedParticipants) : []
7543
7544
  } : void 0,
7544
- type: rawType
7545
+ type: selectedTypeKey
7545
7546
  });
7546
7547
  } catch (error) {
7547
7548
  toast20.error(error.message || "Failed to create application.");
@@ -7549,12 +7550,43 @@ var UniversalCreateApplication = ({
7549
7550
  }
7550
7551
  };
7551
7552
  const activeCompany = companies.find((c) => c.id === selectedCompanyId);
7552
- return /* @__PURE__ */ React62.createElement("div", { className: "w-full max-w-3xl 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(HugeiconsIcon47, { icon: ArrowLeft01Icon25, 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 gap-6 mb-6 px-1" }, /* @__PURE__ */ React62.createElement("button", { onClick: () => setCreationMode("EXISTING"), disabled: isSubmitting, className: `pb-2 text-sm outline-none transition-colors border-b-2 ${creationMode === "EXISTING" ? "border-black text-black" : "border-transparent text-stone-500 hover:text-black"}` }, "Select Company"), /* @__PURE__ */ React62.createElement("button", { onClick: () => setCreationMode("NEW"), disabled: isSubmitting, className: `pb-2 text-sm outline-none transition-colors border-b-2 ${creationMode === "NEW" ? "border-black text-black" : "border-transparent text-stone-500 hover:text-black"}` }, "New Company")), /* @__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(HugeiconsIcon47, { icon: CircleLock02Icon6, 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(HugeiconsIcon47, { 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" }, "Assigned 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(HugeiconsIcon47, { 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" }, selectedTypeFormatted))), canManage && /* @__PURE__ */ React62.createElement("div", { className: "pt-6" }, /* @__PURE__ */ React62.createElement(ThreeDActionButton, { type: "submit", disabled: isSubmitting || creationMode === "EXISTING" && !selectedCompanyId || creationMode === "NEW" && newCompanyName.length < 2, isLoading: isSubmitting, className: "w-full sm:w-auto min-w-40" }, "Create Application")))), canManage && /* @__PURE__ */ React62.createElement(ReusableOptions, { isOpen: showTypeModal, onClose: () => setShowTypeModal(false), title: "Application Type", options: FORMATTED_TYPES, selectedOption: selectedTypeFormatted, onSelect: (t) => setSelectedTypeFormatted(t), showSearch: true }), 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" }, "Close")), /* @__PURE__ */ React62.createElement("div", { className: "p-4 shrink-0" }, /* @__PURE__ */ React62.createElement("div", { className: "relative w-full" }, /* @__PURE__ */ React62.createElement(HugeiconsIcon47, { icon: Search01Icon11, 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-200 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(HugeiconsIcon47, { 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: () => {
7553
+ const activeTypeObj = applicationTypesMeta.find((t) => t.key === selectedTypeKey) || applicationTypesMeta[0];
7554
+ const modeTabs = [
7555
+ { id: "EXISTING", label: "Select Company" },
7556
+ { id: "NEW", label: "New Company" }
7557
+ ];
7558
+ 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(HugeiconsIcon47, { icon: ArrowLeft01Icon25, 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) => {
7559
+ const isActive = creationMode === tab.id;
7560
+ return /* @__PURE__ */ React62.createElement(
7561
+ "button",
7562
+ {
7563
+ key: tab.id,
7564
+ type: "button",
7565
+ onClick: () => setCreationMode(tab.id),
7566
+ disabled: isSubmitting,
7567
+ className: `px-4 py-1.5 rounded-full text-xs transition-all duration-200 outline-none whitespace-nowrap shrink-0 ${isActive ? "bg-stone-50 text-black" : "text-stone-500 hover:text-black hover:bg-stone-50/50"}`
7568
+ },
7569
+ tab.label
7570
+ );
7571
+ }))), /* @__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(HugeiconsIcon47, { icon: CircleLock02Icon6, 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(HugeiconsIcon47, { 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(HugeiconsIcon47, { 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) => {
7572
+ const isSelected = selectedTypeKey === item.key;
7573
+ return /* @__PURE__ */ React62.createElement(
7574
+ "div",
7575
+ {
7576
+ key: item.key,
7577
+ onClick: () => {
7578
+ setSelectedTypeKey(item.key);
7579
+ },
7580
+ 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"}`
7581
+ },
7582
+ /* @__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(HugeiconsIcon47, { icon: CheckmarkCircle02Icon2, size: 16, className: "text-[#d97757] shrink-0" })),
7583
+ /* @__PURE__ */ React62.createElement("p", { className: "text-[11px] text-stone-500 mt-1 leading-relaxed whitespace-normal wrap-break-word" }, item.desc)
7584
+ );
7585
+ })))), 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(HugeiconsIcon47, { icon: Search01Icon11, 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-200 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(HugeiconsIcon47, { 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: () => {
7553
7586
  setSelectedCompanyId(comp.id);
7554
- setShowCompaniesModal(false);
7555
- }, 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), comp.isPrivate && /* @__PURE__ */ React62.createElement("span", { className: "text-[10px] text-[#d97757] mt-0.5 tracking-widest uppercase" }, "Private")), selectedCompanyId === comp.id && /* @__PURE__ */ React62.createElement(HugeiconsIcon47, { icon: Tick02Icon4, 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(HugeiconsIcon47, { icon: ArrowLeft01Icon25, 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(HugeiconsIcon47, { 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(HugeiconsIcon47, { icon: Search01Icon11, 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-200 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(HugeiconsIcon47, { 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) => {
7587
+ }, 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 uppercase" }, "Applications: ", comp.applicationsCount || 0), comp.isPrivate && /* @__PURE__ */ React62.createElement("span", { className: "text-[10px] text-[#d97757] tracking-widest uppercase" }, "Private"))), selectedCompanyId === comp.id && /* @__PURE__ */ React62.createElement(HugeiconsIcon47, { 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(HugeiconsIcon47, { icon: ArrowLeft01Icon25, 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(HugeiconsIcon47, { 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(HugeiconsIcon47, { icon: Search01Icon11, 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-200 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(HugeiconsIcon47, { 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) => {
7556
7588
  const isChecked = selectedParticipants.has(member.userId);
7557
- 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(HugeiconsIcon47, { icon: Tick02Icon4, size: 14, className: "text-white" }))));
7589
+ 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(HugeiconsIcon47, { icon: CheckmarkCircle02Icon2, size: 14, className: "text-white" }))));
7558
7590
  })), /* @__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(HugeiconsIcon47, { icon: ArrowLeft01Icon25, 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(HugeiconsIcon47, { icon: ArrowRight01Icon19, size: 12 })))))));
7559
7591
  };
7560
7592
  export {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@retinalabsllc/zairusjs",
3
- "version": "21.1.9",
3
+ "version": "21.2.1",
4
4
  "description": "A perceptive, Ai data driven Next.js UI component library.",
5
5
  "author": "Retina Labs Company",
6
6
  "license": "MIT",