import {
  Alert,
  AlertDescription,
  AlertTitle
} from "/build/_shared/chunk-CVH4WEFL.js";
import {
  import_dayjs,
  require_timezone
} from "/build/_shared/chunk-AQ3KUNDV.js";
import {
  SquareArrowUpRight
} from "/build/_shared/chunk-XSZNYPTW.js";
import {
  Badge,
  idShortener
} from "/build/_shared/chunk-KSAJCXX3.js";
import {
  Table,
  TableBody,
  TableCell,
  TableHead,
  TableHeader,
  TableRow
} from "/build/_shared/chunk-F5GZ2BM6.js";
import {
  Select,
  SelectContent,
  SelectGroup,
  SelectItem,
  SelectTrigger,
  SelectValue
} from "/build/_shared/chunk-2HNNZFPR.js";
import "/build/_shared/chunk-3E37RNOA.js";
import "/build/_shared/chunk-JYSNSZA2.js";
import {
  ScrollArea
} from "/build/_shared/chunk-KQSGWVIC.js";
import {
  require_numbro_min
} from "/build/_shared/chunk-TCLIWQBB.js";
import {
  require_dayjs_min
} from "/build/_shared/chunk-RFBEIH4W.js";
import {
  Card,
  CardContent,
  CardHeader,
  CardTitle
} from "/build/_shared/chunk-MR25HKXM.js";
import "/build/_shared/chunk-5HIGY2MY.js";
import {
  PageSubtitle
} from "/build/_shared/chunk-Z534YQLL.js";
import "/build/_shared/chunk-TEUK4AYU.js";
import "/build/_shared/chunk-4EISWT2J.js";
import "/build/_shared/chunk-D7HH3MFR.js";
import "/build/_shared/chunk-L7VKH6VP.js";
import "/build/_shared/chunk-4CHLX6OP.js";
import {
  CircleSlash,
  DollarSign,
  FlaskConical,
  GanttChart,
  Timer
} from "/build/_shared/chunk-EEPFRJZL.js";
import {
  Area,
  AreaChart,
  LineChart,
  ResponsiveContainer,
  Tooltip,
  XAxis,
  YAxis
} from "/build/_shared/chunk-NYUGOXZA.js";
import "/build/_shared/chunk-SMFRBP2T.js";
import {
  PageLayout
} from "/build/_shared/chunk-IVHXUM2B.js";
import {
  TimerIcon,
  cn
} from "/build/_shared/chunk-P2DAPPQF.js";
import "/build/_shared/chunk-AI5FD5Y6.js";
import {
  require_jsx_dev_runtime
} from "/build/_shared/chunk-D5XSJF2M.js";
import {
  Await,
  Link,
  init_esm2 as init_esm,
  useLoaderData,
  useParams,
  useSearchParams
} from "/build/_shared/chunk-VJFCZKPM.js";
import "/build/_shared/chunk-OCFPP4X2.js";
import {
  require_react
} from "/build/_shared/chunk-HWKMUXRS.js";
import {
  withAuth
} from "/build/_shared/chunk-RHQW4WCH.js";
import {
  AnalyticsControllerGetAnalyticsForEnvDateSelectionEnum,
  require_node
} from "/build/_shared/chunk-MDLUSIM2.js";
import "/build/_shared/chunk-EB6A6RVQ.js";
import {
  Routes
} from "/build/_shared/chunk-5222SY3A.js";
import {
  createHotContext,
  init_remix_hmr
} from "/build/_shared/chunk-4FTV3JJX.js";
import "/build/_shared/chunk-YLRAJVC6.js";
import {
  __toESM
} from "/build/_shared/chunk-RODUX5XG.js";

// app/routes/app+/project+/$projectId+/env+/$envId+/dashboard.tsx
init_remix_hmr();
var import_node = __toESM(require_node(), 1);
init_esm();

// app/pages/dashboard/DashboardPage.tsx
init_remix_hmr();
init_esm();
var import_dayjs2 = __toESM(require_dayjs_min(), 1);
var import_numbro = __toESM(require_numbro_min(), 1);
var import_react3 = __toESM(require_react(), 1);

// app/pages/dashboard/DateSelector.tsx
init_remix_hmr();
var import_jsx_dev_runtime = __toESM(require_jsx_dev_runtime(), 1);
if (!window.$RefreshReg$ || !window.$RefreshSig$ || !window.$RefreshRuntime$) {
  console.warn("remix:hmr: React Fast Refresh only works when the Remix compiler is running in development mode.");
} else {
  prevRefreshReg = window.$RefreshReg$;
  prevRefreshSig = window.$RefreshSig$;
  window.$RefreshReg$ = (type, id) => {
    window.$RefreshRuntime$.register(type, '"app/pages/dashboard/DateSelector.tsx"' + id);
  };
  window.$RefreshSig$ = window.$RefreshRuntime$.createSignatureFunctionForTransform;
}
var prevRefreshReg;
var prevRefreshSig;
if (import.meta) {
  import.meta.hot = createHotContext(
    //@ts-expect-error
    "app/pages/dashboard/DateSelector.tsx"
  );
  import.meta.hot.lastModified = "1715882071659.4148";
}
var DateSelector = ({
  selectedValue,
  setSearchParams
}) => {
  return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(Select, { value: selectedValue, onValueChange: (value) => {
    setSearchParams((prev) => {
      prev.set("dateSelection", value);
      return prev;
    });
  }, children: [
    /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(SelectTrigger, { className: "w-[125px]", children: [
      /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(TimerIcon, {}, void 0, false, {
        fileName: "app/pages/dashboard/DateSelector.tsx",
        lineNumber: 35,
        columnNumber: 9
      }, this),
      /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(SelectValue, {}, void 0, false, {
        fileName: "app/pages/dashboard/DateSelector.tsx",
        lineNumber: 36,
        columnNumber: 9
      }, this)
    ] }, void 0, true, {
      fileName: "app/pages/dashboard/DateSelector.tsx",
      lineNumber: 34,
      columnNumber: 7
    }, this),
    /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(SelectContent, { children: /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(SelectGroup, { children: [
      /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(SelectItem, { value: AnalyticsControllerGetAnalyticsForEnvDateSelectionEnum._30Mins, children: "30 mins" }, void 0, false, {
        fileName: "app/pages/dashboard/DateSelector.tsx",
        lineNumber: 40,
        columnNumber: 11
      }, this),
      /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(SelectItem, { value: AnalyticsControllerGetAnalyticsForEnvDateSelectionEnum._1Hr, children: "1 hr" }, void 0, false, {
        fileName: "app/pages/dashboard/DateSelector.tsx",
        lineNumber: 41,
        columnNumber: 11
      }, this),
      /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(SelectItem, { value: AnalyticsControllerGetAnalyticsForEnvDateSelectionEnum._24Hrs, children: "24 hrs" }, void 0, false, {
        fileName: "app/pages/dashboard/DateSelector.tsx",
        lineNumber: 42,
        columnNumber: 11
      }, this),
      /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(SelectItem, { value: AnalyticsControllerGetAnalyticsForEnvDateSelectionEnum._7Days, children: "7 days" }, void 0, false, {
        fileName: "app/pages/dashboard/DateSelector.tsx",
        lineNumber: 43,
        columnNumber: 11
      }, this),
      /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(SelectItem, { value: AnalyticsControllerGetAnalyticsForEnvDateSelectionEnum._1Month, children: "1 month" }, void 0, false, {
        fileName: "app/pages/dashboard/DateSelector.tsx",
        lineNumber: 44,
        columnNumber: 11
      }, this),
      /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(SelectItem, { value: AnalyticsControllerGetAnalyticsForEnvDateSelectionEnum._3Months, children: "3 months" }, void 0, false, {
        fileName: "app/pages/dashboard/DateSelector.tsx",
        lineNumber: 45,
        columnNumber: 11
      }, this),
      /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(SelectItem, { value: AnalyticsControllerGetAnalyticsForEnvDateSelectionEnum.AllTime, children: "All time" }, void 0, false, {
        fileName: "app/pages/dashboard/DateSelector.tsx",
        lineNumber: 46,
        columnNumber: 11
      }, this)
    ] }, void 0, true, {
      fileName: "app/pages/dashboard/DateSelector.tsx",
      lineNumber: 39,
      columnNumber: 9
    }, this) }, void 0, false, {
      fileName: "app/pages/dashboard/DateSelector.tsx",
      lineNumber: 38,
      columnNumber: 7
    }, this)
  ] }, void 0, true, {
    fileName: "app/pages/dashboard/DateSelector.tsx",
    lineNumber: 28,
    columnNumber: 10
  }, this);
};
_c = DateSelector;
var _c;
$RefreshReg$(_c, "DateSelector");
window.$RefreshReg$ = prevRefreshReg;
window.$RefreshSig$ = prevRefreshSig;

// app/pages/dashboard/NoData.tsx
init_remix_hmr();
var import_jsx_dev_runtime2 = __toESM(require_jsx_dev_runtime(), 1);
if (!window.$RefreshReg$ || !window.$RefreshSig$ || !window.$RefreshRuntime$) {
  console.warn("remix:hmr: React Fast Refresh only works when the Remix compiler is running in development mode.");
} else {
  prevRefreshReg = window.$RefreshReg$;
  prevRefreshSig = window.$RefreshSig$;
  window.$RefreshReg$ = (type, id) => {
    window.$RefreshRuntime$.register(type, '"app/pages/dashboard/NoData.tsx"' + id);
  };
  window.$RefreshSig$ = window.$RefreshRuntime$.createSignatureFunctionForTransform;
}
var prevRefreshReg;
var prevRefreshSig;
if (import.meta) {
  import.meta.hot = createHotContext(
    //@ts-expect-error
    "app/pages/dashboard/NoData.tsx"
  );
  import.meta.hot.lastModified = "1711234236153.7783";
}
var NoData = () => {
  return /* @__PURE__ */ (0, import_jsx_dev_runtime2.jsxDEV)("div", { className: "flex h-full items-center justify-center rounded-lg border", children: /* @__PURE__ */ (0, import_jsx_dev_runtime2.jsxDEV)(Alert, { className: "flex w-fit flex-row items-center justify-start gap-4 p-4", children: [
    /* @__PURE__ */ (0, import_jsx_dev_runtime2.jsxDEV)("div", { children: /* @__PURE__ */ (0, import_jsx_dev_runtime2.jsxDEV)(CircleSlash, { size: 20 }, void 0, false, {
      fileName: "app/pages/dashboard/NoData.tsx",
      lineNumber: 27,
      columnNumber: 11
    }, this) }, void 0, false, {
      fileName: "app/pages/dashboard/NoData.tsx",
      lineNumber: 26,
      columnNumber: 9
    }, this),
    /* @__PURE__ */ (0, import_jsx_dev_runtime2.jsxDEV)("div", { className: "flex flex-col", children: [
      /* @__PURE__ */ (0, import_jsx_dev_runtime2.jsxDEV)(AlertTitle, { children: "No Data" }, void 0, false, {
        fileName: "app/pages/dashboard/NoData.tsx",
        lineNumber: 30,
        columnNumber: 11
      }, this),
      /* @__PURE__ */ (0, import_jsx_dev_runtime2.jsxDEV)(AlertDescription, { children: "Try another date filter." }, void 0, false, {
        fileName: "app/pages/dashboard/NoData.tsx",
        lineNumber: 31,
        columnNumber: 11
      }, this)
    ] }, void 0, true, {
      fileName: "app/pages/dashboard/NoData.tsx",
      lineNumber: 29,
      columnNumber: 9
    }, this)
  ] }, void 0, true, {
    fileName: "app/pages/dashboard/NoData.tsx",
    lineNumber: 25,
    columnNumber: 7
  }, this) }, void 0, false, {
    fileName: "app/pages/dashboard/NoData.tsx",
    lineNumber: 24,
    columnNumber: 10
  }, this);
};
_c2 = NoData;
var _c2;
$RefreshReg$(_c2, "NoData");
window.$RefreshReg$ = prevRefreshReg;
window.$RefreshSig$ = prevRefreshSig;

// app/pages/dashboard/RecentLog.tsx
init_remix_hmr();
init_esm();
var import_jsx_dev_runtime3 = __toESM(require_jsx_dev_runtime(), 1);
if (!window.$RefreshReg$ || !window.$RefreshSig$ || !window.$RefreshRuntime$) {
  console.warn("remix:hmr: React Fast Refresh only works when the Remix compiler is running in development mode.");
} else {
  prevRefreshReg = window.$RefreshReg$;
  prevRefreshSig = window.$RefreshSig$;
  window.$RefreshReg$ = (type, id) => {
    window.$RefreshRuntime$.register(type, '"app/pages/dashboard/RecentLog.tsx"' + id);
  };
  window.$RefreshSig$ = window.$RefreshRuntime$.createSignatureFunctionForTransform;
}
var prevRefreshReg;
var prevRefreshSig;
var _s = $RefreshSig$();
if (import.meta) {
  import.meta.hot = createHotContext(
    //@ts-expect-error
    "app/pages/dashboard/RecentLog.tsx"
  );
  import.meta.hot.lastModified = "1715882071659.5679";
}
var RecentLog = ({
  log
}) => {
  _s();
  const params = useParams();
  const {
    variant
  } = idShortener(log.traceId);
  return /* @__PURE__ */ (0, import_jsx_dev_runtime3.jsxDEV)(TableRow, { children: [
    /* @__PURE__ */ (0, import_jsx_dev_runtime3.jsxDEV)(TableCell, { children: log.startTime || log.createdAt }, void 0, false, {
      fileName: "app/pages/dashboard/RecentLog.tsx",
      lineNumber: 37,
      columnNumber: 7
    }, this),
    /* @__PURE__ */ (0, import_jsx_dev_runtime3.jsxDEV)(TableCell, { children: /* @__PURE__ */ (0, import_jsx_dev_runtime3.jsxDEV)(Link, { to: Routes.app.project.env.traceId({
      projectId: params.projectId,
      envId: params.envId,
      traceId: log.traceId,
      logId: log.id
    }), children: /* @__PURE__ */ (0, import_jsx_dev_runtime3.jsxDEV)(Badge, { variant, children: [
      /* @__PURE__ */ (0, import_jsx_dev_runtime3.jsxDEV)(SquareArrowUpRight, {}, void 0, false, {
        fileName: "app/pages/dashboard/RecentLog.tsx",
        lineNumber: 46,
        columnNumber: 13
      }, this),
      "\xA0",
      log.name || "\u2014"
    ] }, void 0, true, {
      fileName: "app/pages/dashboard/RecentLog.tsx",
      lineNumber: 45,
      columnNumber: 11
    }, this) }, void 0, false, {
      fileName: "app/pages/dashboard/RecentLog.tsx",
      lineNumber: 39,
      columnNumber: 9
    }, this) }, void 0, false, {
      fileName: "app/pages/dashboard/RecentLog.tsx",
      lineNumber: 38,
      columnNumber: 7
    }, this),
    /* @__PURE__ */ (0, import_jsx_dev_runtime3.jsxDEV)(TableCell, { children: log.duration ? `${log.duration}s` : "\u2014" }, void 0, false, {
      fileName: "app/pages/dashboard/RecentLog.tsx",
      lineNumber: 52,
      columnNumber: 7
    }, this),
    /* @__PURE__ */ (0, import_jsx_dev_runtime3.jsxDEV)(TableCell, { children: log.totalCost ? `$${log.totalCost}` : "\u2014" }, void 0, false, {
      fileName: "app/pages/dashboard/RecentLog.tsx",
      lineNumber: 53,
      columnNumber: 7
    }, this)
  ] }, void 0, true, {
    fileName: "app/pages/dashboard/RecentLog.tsx",
    lineNumber: 36,
    columnNumber: 10
  }, this);
};
_s(RecentLog, "+jVsTcECDRo3yq2d7EQxlN9Ixog=", false, function() {
  return [useParams];
});
_c3 = RecentLog;
var _c3;
$RefreshReg$(_c3, "RecentLog");
window.$RefreshReg$ = prevRefreshReg;
window.$RefreshSig$ = prevRefreshSig;

// app/pages/dashboard/cards/AnalyticsCard.tsx
init_remix_hmr();
var import_jsx_dev_runtime4 = __toESM(require_jsx_dev_runtime(), 1);
if (!window.$RefreshReg$ || !window.$RefreshSig$ || !window.$RefreshRuntime$) {
  console.warn("remix:hmr: React Fast Refresh only works when the Remix compiler is running in development mode.");
} else {
  prevRefreshReg = window.$RefreshReg$;
  prevRefreshSig = window.$RefreshSig$;
  window.$RefreshReg$ = (type, id) => {
    window.$RefreshRuntime$.register(type, '"app/pages/dashboard/cards/AnalyticsCard.tsx"' + id);
  };
  window.$RefreshSig$ = window.$RefreshRuntime$.createSignatureFunctionForTransform;
}
var prevRefreshReg;
var prevRefreshSig;
if (import.meta) {
  import.meta.hot = createHotContext(
    //@ts-expect-error
    "app/pages/dashboard/cards/AnalyticsCard.tsx"
  );
  import.meta.hot.lastModified = "1710989868863.5889";
}
var AnalyticsCard = ({
  title,
  icon: Icon,
  children
}) => {
  return /* @__PURE__ */ (0, import_jsx_dev_runtime4.jsxDEV)(Card, { className: "flex flex-1 flex-grow flex-col p-8", children: [
    /* @__PURE__ */ (0, import_jsx_dev_runtime4.jsxDEV)(CardHeader, { className: "p-0", children: /* @__PURE__ */ (0, import_jsx_dev_runtime4.jsxDEV)(CardTitle, { children: /* @__PURE__ */ (0, import_jsx_dev_runtime4.jsxDEV)("div", { className: "flex justify-between font-medium", children: [
      title,
      /* @__PURE__ */ (0, import_jsx_dev_runtime4.jsxDEV)(Icon, { size: 20, className: "text-gray-400" }, void 0, false, {
        fileName: "app/pages/dashboard/cards/AnalyticsCard.tsx",
        lineNumber: 32,
        columnNumber: 13
      }, this)
    ] }, void 0, true, {
      fileName: "app/pages/dashboard/cards/AnalyticsCard.tsx",
      lineNumber: 30,
      columnNumber: 11
    }, this) }, void 0, false, {
      fileName: "app/pages/dashboard/cards/AnalyticsCard.tsx",
      lineNumber: 29,
      columnNumber: 9
    }, this) }, void 0, false, {
      fileName: "app/pages/dashboard/cards/AnalyticsCard.tsx",
      lineNumber: 28,
      columnNumber: 7
    }, this),
    /* @__PURE__ */ (0, import_jsx_dev_runtime4.jsxDEV)(CardContent, { className: "mt-2 flex-grow p-0", children }, void 0, false, {
      fileName: "app/pages/dashboard/cards/AnalyticsCard.tsx",
      lineNumber: 36,
      columnNumber: 7
    }, this)
  ] }, void 0, true, {
    fileName: "app/pages/dashboard/cards/AnalyticsCard.tsx",
    lineNumber: 27,
    columnNumber: 10
  }, this);
};
_c4 = AnalyticsCard;
var _c4;
$RefreshReg$(_c4, "AnalyticsCard");
window.$RefreshReg$ = prevRefreshReg;
window.$RefreshSig$ = prevRefreshSig;

// app/pages/dashboard/cards/BaseContent.tsx
init_remix_hmr();

// app/components/ui/skeleton.tsx
init_remix_hmr();
var import_jsx_dev_runtime5 = __toESM(require_jsx_dev_runtime(), 1);
if (!window.$RefreshReg$ || !window.$RefreshSig$ || !window.$RefreshRuntime$) {
  console.warn("remix:hmr: React Fast Refresh only works when the Remix compiler is running in development mode.");
} else {
  prevRefreshReg = window.$RefreshReg$;
  prevRefreshSig = window.$RefreshSig$;
  window.$RefreshReg$ = (type, id) => {
    window.$RefreshRuntime$.register(type, '"app/components/ui/skeleton.tsx"' + id);
  };
  window.$RefreshSig$ = window.$RefreshRuntime$.createSignatureFunctionForTransform;
}
var prevRefreshReg;
var prevRefreshSig;
if (import.meta) {
  import.meta.hot = createHotContext(
    //@ts-expect-error
    "app/components/ui/skeleton.tsx"
  );
  import.meta.hot.lastModified = "1711483346256.9824";
}
function Skeleton({
  className,
  ...props
}) {
  return /* @__PURE__ */ (0, import_jsx_dev_runtime5.jsxDEV)("div", { className: cn("bg-secondary animate-pulse rounded-md", className), ...props }, void 0, false, {
    fileName: "app/components/ui/skeleton.tsx",
    lineNumber: 26,
    columnNumber: 10
  }, this);
}
_c5 = Skeleton;
var _c5;
$RefreshReg$(_c5, "Skeleton");
window.$RefreshReg$ = prevRefreshReg;
window.$RefreshSig$ = prevRefreshSig;

// app/pages/dashboard/cards/BaseContent.tsx
var import_jsx_dev_runtime6 = __toESM(require_jsx_dev_runtime(), 1);
if (!window.$RefreshReg$ || !window.$RefreshSig$ || !window.$RefreshRuntime$) {
  console.warn("remix:hmr: React Fast Refresh only works when the Remix compiler is running in development mode.");
} else {
  prevRefreshReg = window.$RefreshReg$;
  prevRefreshSig = window.$RefreshSig$;
  window.$RefreshReg$ = (type, id) => {
    window.$RefreshRuntime$.register(type, '"app/pages/dashboard/cards/BaseContent.tsx"' + id);
  };
  window.$RefreshSig$ = window.$RefreshRuntime$.createSignatureFunctionForTransform;
}
var prevRefreshReg;
var prevRefreshSig;
if (import.meta) {
  import.meta.hot = createHotContext(
    //@ts-expect-error
    "app/pages/dashboard/cards/BaseContent.tsx"
  );
  import.meta.hot.lastModified = "1711483345998.9153";
}
var BaseContent = ({
  title,
  content: Content,
  percent
}) => /* @__PURE__ */ (0, import_jsx_dev_runtime6.jsxDEV)("div", { className: "flex flex-col", children: [
  /* @__PURE__ */ (0, import_jsx_dev_runtime6.jsxDEV)("div", { className: "flex flex-row gap-2", children: [
    /* @__PURE__ */ (0, import_jsx_dev_runtime6.jsxDEV)("h1", { className: "text-2xl font-bold", children: title }, void 0, false, {
      fileName: "app/pages/dashboard/cards/BaseContent.tsx",
      lineNumber: 28,
      columnNumber: 7
    }, this),
    /* @__PURE__ */ (0, import_jsx_dev_runtime6.jsxDEV)("p", { className: "text-muted-foreground self-end text-base", children: percent ? `${percent}` : "" }, void 0, false, {
      fileName: "app/pages/dashboard/cards/BaseContent.tsx",
      lineNumber: 29,
      columnNumber: 7
    }, this)
  ] }, void 0, true, {
    fileName: "app/pages/dashboard/cards/BaseContent.tsx",
    lineNumber: 27,
    columnNumber: 5
  }, this),
  /* @__PURE__ */ (0, import_jsx_dev_runtime6.jsxDEV)("div", { className: "mt-1", children: Content && /* @__PURE__ */ (0, import_jsx_dev_runtime6.jsxDEV)(Content, {}, void 0, false, {
    fileName: "app/pages/dashboard/cards/BaseContent.tsx",
    lineNumber: 31,
    columnNumber: 41
  }, this) }, void 0, false, {
    fileName: "app/pages/dashboard/cards/BaseContent.tsx",
    lineNumber: 31,
    columnNumber: 5
  }, this)
] }, void 0, true, {
  fileName: "app/pages/dashboard/cards/BaseContent.tsx",
  lineNumber: 26,
  columnNumber: 7
}, this);
_c6 = BaseContent;
var BaseContentSkeleton = () => /* @__PURE__ */ (0, import_jsx_dev_runtime6.jsxDEV)("div", { className: "flex flex-col gap-2", children: [
  /* @__PURE__ */ (0, import_jsx_dev_runtime6.jsxDEV)(Skeleton, { className: "h-7 w-3/4 rounded" }, void 0, false, {
    fileName: "app/pages/dashboard/cards/BaseContent.tsx",
    lineNumber: 35,
    columnNumber: 5
  }, this),
  /* @__PURE__ */ (0, import_jsx_dev_runtime6.jsxDEV)(Skeleton, { className: "h-5 w-1/4 rounded" }, void 0, false, {
    fileName: "app/pages/dashboard/cards/BaseContent.tsx",
    lineNumber: 36,
    columnNumber: 5
  }, this)
] }, void 0, true, {
  fileName: "app/pages/dashboard/cards/BaseContent.tsx",
  lineNumber: 34,
  columnNumber: 42
}, this);
_c22 = BaseContentSkeleton;
var _c6;
var _c22;
$RefreshReg$(_c6, "BaseContent");
$RefreshReg$(_c22, "BaseContentSkeleton");
window.$RefreshReg$ = prevRefreshReg;
window.$RefreshSig$ = prevRefreshSig;

// app/pages/dashboard/DashboardPage.tsx
var import_jsx_dev_runtime7 = __toESM(require_jsx_dev_runtime(), 1);
if (!window.$RefreshReg$ || !window.$RefreshSig$ || !window.$RefreshRuntime$) {
  console.warn("remix:hmr: React Fast Refresh only works when the Remix compiler is running in development mode.");
} else {
  prevRefreshReg = window.$RefreshReg$;
  prevRefreshSig = window.$RefreshSig$;
  window.$RefreshReg$ = (type, id) => {
    window.$RefreshRuntime$.register(type, '"app/pages/dashboard/DashboardPage.tsx"' + id);
  };
  window.$RefreshSig$ = window.$RefreshRuntime$.createSignatureFunctionForTransform;
}
var prevRefreshReg;
var prevRefreshSig;
var _s2 = $RefreshSig$();
if (import.meta) {
  import.meta.hot = createHotContext(
    //@ts-expect-error
    "app/pages/dashboard/DashboardPage.tsx"
  );
  import.meta.hot.lastModified = "1715882071659.2688";
}
var DashboardPage = ({
  analytics,
  logs,
  costHistory
}) => {
  _s2();
  const [searchParams, setSearchParams] = useSearchParams();
  const selectedValue = searchParams.get("dateSelection") || AnalyticsControllerGetAnalyticsForEnvDateSelectionEnum._24Hrs;
  const formatXDates = (tickItem) => {
    const date = (0, import_dayjs2.default)(tickItem);
    const formatMap = {
      [AnalyticsControllerGetAnalyticsForEnvDateSelectionEnum._30Mins]: date.format("h:mm"),
      [AnalyticsControllerGetAnalyticsForEnvDateSelectionEnum._1Hr]: date.format("h:mm"),
      [AnalyticsControllerGetAnalyticsForEnvDateSelectionEnum._24Hrs]: date.format("h:mm"),
      [AnalyticsControllerGetAnalyticsForEnvDateSelectionEnum._7Days]: date.format("MMM D"),
      [AnalyticsControllerGetAnalyticsForEnvDateSelectionEnum._1Month]: date.format("MMM D"),
      [AnalyticsControllerGetAnalyticsForEnvDateSelectionEnum._3Months]: date.format("MMM D"),
      [AnalyticsControllerGetAnalyticsForEnvDateSelectionEnum.AllTime]: date.format("MMM YYYY")
    };
    return formatMap[selectedValue];
  };
  const breadcrumbs = [{
    label: "Dashboard"
  }];
  const subtitle = () => {
    return /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(PageSubtitle, { children: "High-level overview of your traces and experiments." }, void 0, false, {
      fileName: "app/pages/dashboard/DashboardPage.tsx",
      lineNumber: 64,
      columnNumber: 12
    }, this);
  };
  const action = () => {
    return /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(DateSelector, { selectedValue, setSearchParams }, void 0, false, {
      fileName: "app/pages/dashboard/DashboardPage.tsx",
      lineNumber: 67,
      columnNumber: 12
    }, this);
  };
  return /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(PageLayout, { breadcrumbs, subtitle, action, children: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)("div", { className: "flex flex-1 flex-col", children: [
    /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)("div", { className: "flex flex-grow flex-row gap-8", children: [
      /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(AnalyticsCard, { title: "Cost", icon: DollarSign, children: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(import_react3.Suspense, { fallback: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(BaseContentSkeleton, {}, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 74,
        columnNumber: 33
      }, this), children: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(Await, { resolve: analytics, children: (analytics2) => /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(BaseContent, { title: `$${(0, import_numbro.default)(analytics2.cost).format({
        thousandSeparated: true
      })}`, content: () => /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(Badge, { variant: "orange", children: `Max $${analytics2.max.cost}` }, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 78,
        columnNumber: 36
      }, this), percent: analytics2.changes.cost }, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 76,
        columnNumber: 31
      }, this) }, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 75,
        columnNumber: 15
      }, this) }, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 74,
        columnNumber: 13
      }, this) }, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 73,
        columnNumber: 11
      }, this),
      /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(AnalyticsCard, { title: "Latency", icon: Timer, children: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(import_react3.Suspense, { fallback: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(BaseContentSkeleton, {}, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 83,
        columnNumber: 33
      }, this), children: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(Await, { resolve: analytics, children: (analytics2) => /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(BaseContent, { title: `${analytics2.averageLatency}s avg`, content: () => /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(Badge, { variant: "orange", children: `Max ${analytics2.max.latency}s` }, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 85,
        columnNumber: 102
      }, this), percent: analytics2.changes.latency }, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 85,
        columnNumber: 31
      }, this) }, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 84,
        columnNumber: 15
      }, this) }, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 83,
        columnNumber: 13
      }, this) }, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 82,
        columnNumber: 11
      }, this),
      /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(AnalyticsCard, { title: "Traces", icon: GanttChart, children: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(import_react3.Suspense, { fallback: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(BaseContentSkeleton, {}, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 90,
        columnNumber: 33
      }, this), children: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(Await, { resolve: analytics, children: (analytics2) => /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(BaseContent, { title: (0, import_numbro.default)(analytics2.traces).format({
        thousandSeparated: true
      }), percent: analytics2.changes.traces }, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 92,
        columnNumber: 31
      }, this) }, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 91,
        columnNumber: 15
      }, this) }, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 90,
        columnNumber: 13
      }, this) }, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 89,
        columnNumber: 11
      }, this),
      /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(AnalyticsCard, { title: "Experiments", icon: FlaskConical, children: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(import_react3.Suspense, { fallback: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(BaseContentSkeleton, {}, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 99,
        columnNumber: 33
      }, this), children: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(Await, { resolve: analytics, children: (analytics2) => /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(BaseContent, { title: `${analytics2.experimentCount}` }, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 100,
        columnNumber: 56
      }, this) }, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 100,
        columnNumber: 15
      }, this) }, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 99,
        columnNumber: 13
      }, this) }, void 0, false, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 98,
        columnNumber: 11
      }, this)
    ] }, void 0, true, {
      fileName: "app/pages/dashboard/DashboardPage.tsx",
      lineNumber: 72,
      columnNumber: 9
    }, this),
    /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)("div", { className: "mt-8 grid grid-cols-2 gap-8", children: [
      /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)("div", { children: [
        /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)("h1", { className: "mb-4 text-2xl font-medium", children: "Recent Logs" }, void 0, false, {
          fileName: "app/pages/dashboard/DashboardPage.tsx",
          lineNumber: 108,
          columnNumber: 13
        }, this),
        logs.length ? /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(ScrollArea, { className: "h-[32rem] rounded-lg border", type: "scroll", children: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(Table, { children: [
          /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(TableHeader, { children: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(TableRow, { children: [
            /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(TableHead, { children: "Timestamp" }, void 0, false, {
              fileName: "app/pages/dashboard/DashboardPage.tsx",
              lineNumber: 113,
              columnNumber: 23
            }, this),
            /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(TableHead, { children: "Name" }, void 0, false, {
              fileName: "app/pages/dashboard/DashboardPage.tsx",
              lineNumber: 114,
              columnNumber: 23
            }, this),
            /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(TableHead, { children: "Latency" }, void 0, false, {
              fileName: "app/pages/dashboard/DashboardPage.tsx",
              lineNumber: 115,
              columnNumber: 23
            }, this),
            /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(TableHead, { children: "Cost" }, void 0, false, {
              fileName: "app/pages/dashboard/DashboardPage.tsx",
              lineNumber: 116,
              columnNumber: 23
            }, this)
          ] }, void 0, true, {
            fileName: "app/pages/dashboard/DashboardPage.tsx",
            lineNumber: 112,
            columnNumber: 21
          }, this) }, void 0, false, {
            fileName: "app/pages/dashboard/DashboardPage.tsx",
            lineNumber: 111,
            columnNumber: 19
          }, this),
          /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(TableBody, { children: logs.map((log) => /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(RecentLog, { log }, log.id, false, {
            fileName: "app/pages/dashboard/DashboardPage.tsx",
            lineNumber: 120,
            columnNumber: 38
          }, this)) }, void 0, false, {
            fileName: "app/pages/dashboard/DashboardPage.tsx",
            lineNumber: 119,
            columnNumber: 19
          }, this)
        ] }, void 0, true, {
          fileName: "app/pages/dashboard/DashboardPage.tsx",
          lineNumber: 110,
          columnNumber: 17
        }, this) }, void 0, false, {
          fileName: "app/pages/dashboard/DashboardPage.tsx",
          lineNumber: 109,
          columnNumber: 28
        }, this) : /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(NoData, {}, void 0, false, {
          fileName: "app/pages/dashboard/DashboardPage.tsx",
          lineNumber: 123,
          columnNumber: 31
        }, this)
      ] }, void 0, true, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 107,
        columnNumber: 11
      }, this),
      /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)("div", { className: " h-[32rem]", children: [
        /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)("h1", { className: "mb-4 text-2xl font-medium", children: "Cost History" }, void 0, false, {
          fileName: "app/pages/dashboard/DashboardPage.tsx",
          lineNumber: 128,
          columnNumber: 13
        }, this),
        /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(import_react3.Suspense, { fallback: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(ResponsiveContainer, { width: "100%", height: "100%", children: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(LineChart, { data: [] }, void 0, false, {
          fileName: "app/pages/dashboard/DashboardPage.tsx",
          lineNumber: 131,
          columnNumber: 19
        }, this) }, void 0, false, {
          fileName: "app/pages/dashboard/DashboardPage.tsx",
          lineNumber: 130,
          columnNumber: 33
        }, this), children: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(Await, { resolve: costHistory, children: (costHistory2) => {
          if (!costHistory2.costHistory.length) {
            return NoData();
          }
          return /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(ResponsiveContainer, { children: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(AreaChart, { data: costHistory2.costHistory, children: [
            /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)("defs", { children: /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)("linearGradient", { id: "area-gradient", x1: "0", y1: "0", x2: "0", y2: "1", children: [
              /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)("stop", { offset: "0%", stopColor: "var(--primary)", stopOpacity: 0.5 }, void 0, false, {
                fileName: "app/pages/dashboard/DashboardPage.tsx",
                lineNumber: 142,
                columnNumber: 29
              }, this),
              /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)("stop", { offset: "90%", stopColor: "var(--primary)", stopOpacity: 0 }, void 0, false, {
                fileName: "app/pages/dashboard/DashboardPage.tsx",
                lineNumber: 143,
                columnNumber: 29
              }, this)
            ] }, void 0, true, {
              fileName: "app/pages/dashboard/DashboardPage.tsx",
              lineNumber: 141,
              columnNumber: 27
            }, this) }, void 0, false, {
              fileName: "app/pages/dashboard/DashboardPage.tsx",
              lineNumber: 140,
              columnNumber: 25
            }, this),
            /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(XAxis, { dataKey: "intervalStart", type: "category", tickFormatter: formatXDates, stroke: "var(--border)", tick: {
              fill: "var(--muted-foreground)"
            } }, void 0, false, {
              fileName: "app/pages/dashboard/DashboardPage.tsx",
              lineNumber: 146,
              columnNumber: 25
            }, this),
            /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(YAxis, { stroke: "var(--border)", tick: {
              fill: "var(--muted-foreground)"
            }, tickFormatter: (value) => `$${value}` }, void 0, false, {
              fileName: "app/pages/dashboard/DashboardPage.tsx",
              lineNumber: 149,
              columnNumber: 25
            }, this),
            /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(Tooltip, { contentStyle: {
              backgroundColor: "var(--popover)",
              borderRadius: "8px",
              borderColor: "var(--border)"
            }, formatter: (value) => [`$${value}`, "Total Cost"], labelFormatter: (date) => (0, import_dayjs2.default)(date).format("MMM D YYYY H:mm:ss"), cursor: {
              stroke: "var(--muted-foreground)",
              strokeWidth: 2
            } }, void 0, false, {
              fileName: "app/pages/dashboard/DashboardPage.tsx",
              lineNumber: 152,
              columnNumber: 25
            }, this),
            /* @__PURE__ */ (0, import_jsx_dev_runtime7.jsxDEV)(Area, { isAnimationActive: false, type: "monotone", dataKey: "totalCost", dot: false, legendType: "none", strokeWidth: 3, stroke: "var(--primary)", fill: "url(#area-gradient)" }, void 0, false, {
              fileName: "app/pages/dashboard/DashboardPage.tsx",
              lineNumber: 160,
              columnNumber: 25
            }, this)
          ] }, void 0, true, {
            fileName: "app/pages/dashboard/DashboardPage.tsx",
            lineNumber: 139,
            columnNumber: 23
          }, this) }, void 0, false, {
            fileName: "app/pages/dashboard/DashboardPage.tsx",
            lineNumber: 138,
            columnNumber: 24
          }, this);
        } }, void 0, false, {
          fileName: "app/pages/dashboard/DashboardPage.tsx",
          lineNumber: 133,
          columnNumber: 15
        }, this) }, void 0, false, {
          fileName: "app/pages/dashboard/DashboardPage.tsx",
          lineNumber: 130,
          columnNumber: 13
        }, this)
      ] }, void 0, true, {
        fileName: "app/pages/dashboard/DashboardPage.tsx",
        lineNumber: 127,
        columnNumber: 11
      }, this)
    ] }, void 0, true, {
      fileName: "app/pages/dashboard/DashboardPage.tsx",
      lineNumber: 105,
      columnNumber: 9
    }, this)
  ] }, void 0, true, {
    fileName: "app/pages/dashboard/DashboardPage.tsx",
    lineNumber: 70,
    columnNumber: 7
  }, this) }, void 0, false, {
    fileName: "app/pages/dashboard/DashboardPage.tsx",
    lineNumber: 69,
    columnNumber: 10
  }, this);
};
_s2(DashboardPage, "/eCs5CB4FLGAVLeprHBYLwBGf/Q=", false, function() {
  return [useSearchParams];
});
_c7 = DashboardPage;
var _c7;
$RefreshReg$(_c7, "DashboardPage");
window.$RefreshReg$ = prevRefreshReg;
window.$RefreshSig$ = prevRefreshSig;

// app/pages/dashboard/utils.ts
init_remix_hmr();
if (import.meta) {
  import.meta.hot = createHotContext(
    //@ts-expect-error
    "app/pages/dashboard/utils.ts"
  );
  import.meta.hot.lastModified = "1715882071659.7432";
}
var formatLogDates = (logs, timezone) => {
  return logs.map((log) => {
    return {
      ...log,
      createdAt: (0, import_dayjs.default)(log.createdAt).tz(timezone).format("h:mm:ssa"),
      startTime: (0, import_dayjs.default)(log.startTime).tz(timezone).format("h:mm:ssa")
    };
  });
};

// app/routes/app+/project+/$projectId+/env+/$envId+/dashboard.tsx
var import_timezone = __toESM(require_timezone(), 1);
var import_jsx_dev_runtime8 = __toESM(require_jsx_dev_runtime(), 1);
if (!window.$RefreshReg$ || !window.$RefreshSig$ || !window.$RefreshRuntime$) {
  console.warn("remix:hmr: React Fast Refresh only works when the Remix compiler is running in development mode.");
} else {
  prevRefreshReg = window.$RefreshReg$;
  prevRefreshSig = window.$RefreshSig$;
  window.$RefreshReg$ = (type, id) => {
    window.$RefreshRuntime$.register(type, '"app/routes/app+/project+/$projectId+/env+/$envId+/dashboard.tsx"' + id);
  };
  window.$RefreshSig$ = window.$RefreshRuntime$.createSignatureFunctionForTransform;
}
var prevRefreshReg;
var prevRefreshSig;
var _s3 = $RefreshSig$();
if (import.meta) {
  import.meta.hot = createHotContext(
    //@ts-expect-error
    "app/routes/app+/project+/$projectId+/env+/$envId+/dashboard.tsx"
  );
  import.meta.hot.lastModified = "1715882071672.2437";
}
var loader = withAuth(async ({
  request,
  api,
  params
}) => {
  const envId = params.envId;
  const {
    searchParams
  } = new URL(request.url);
  const dateSelectionQuery = searchParams.get("dateSelection") || AnalyticsControllerGetAnalyticsForEnvDateSelectionEnum._24Hrs;
  const analyticsPromise = api.analytics.analyticsControllerGetAnalyticsForEnv({
    envId,
    dateSelection: dateSelectionQuery
  });
  const costHistoryPromise = api.analytics.analyticsControllerGetCostHistoryForEnv({
    envId,
    dateSelection: dateSelectionQuery
  });
  const {
    logs
  } = await api.log.logControllerGetLogsForEnvironment({
    envId,
    take: "25"
  });
  const timezone = await (0, import_timezone.getTimezone)(request);
  const formattedLogs = formatLogDates(logs, timezone);
  return (0, import_node.defer)({
    analytics: analyticsPromise,
    logs: formattedLogs,
    costHistory: costHistoryPromise,
    timezone
  });
});
function DashboardRoute() {
  _s3();
  const {
    analytics,
    logs,
    costHistory,
    timezone
  } = useLoaderData();
  const formattedLogs = timezone ? logs : formatLogDates(logs, timezone);
  return /* @__PURE__ */ (0, import_jsx_dev_runtime8.jsxDEV)(DashboardPage, { analytics, logs: formattedLogs, costHistory }, void 0, false, {
    fileName: "app/routes/app+/project+/$projectId+/env+/$envId+/dashboard.tsx",
    lineNumber: 73,
    columnNumber: 10
  }, this);
}
_s3(DashboardRoute, "CVWYqeo9E7h0JH+mt645y3Ydf2M=", false, function() {
  return [useLoaderData];
});
_c8 = DashboardRoute;
var _c8;
$RefreshReg$(_c8, "DashboardRoute");
window.$RefreshReg$ = prevRefreshReg;
window.$RefreshSig$ = prevRefreshSig;
export {
  DashboardRoute as default
};
//# sourceMappingURL=/build/routes/app+/project+/$projectId+/env+/$envId+/dashboard-6SXIN5LT.js.map
