import { aw as head, au as escape_html, a6 as derived, ax as ensure_array_like } from './index2-BLq4EEng.js';
import { g as goto } from './client-dJTdv51U.js';
import { E as EmptyState, R as RefreshSvg, c as clearCache } from './cache-De-MXr04.js';
import { S as SettingsSvg } from './settings-Dv3Esboo.js';
import './markdown-W_mTBct0.js';
import { o as onDestroy } from './index-server-CdDI4vgN.js';
import { B as Button } from './Button-DmE4ENkb.js';
import { I as Icon } from './Icon-By4fwUeB.js';
import { S as Shimmer } from './Shimmer-Bo1CUNAU.js';
import { S as SvelteMap, a as SvelteSet } from './index-server2-BJrT0wnA.js';
import './root-Ce8FGAoU.js';
import './index-L-OMOXY-.js';
import './state.svelte-DCKkPJr6.js';
import 'dompurify';
import 'marked';

const DEFAULT_INJECTION_POLICY = {
  humanGraceMs: 5e3,
  injectConfidence: 0.7,
  maxAutoActions: 8,
  minIntervalMs: 3e4
};
const MAX_COMMAND_LENGTH = 400;
const DANGEROUS_PATTERNS = [
  /\brm\s+-[a-z]*r[a-z]*f?\s+(\/|~|\/\*|\$home)/i,
  // rm -rf /, rm -rf ~, rm -rf /*
  /\brm\s+-[a-z]*f[a-z]*r?\s+(\/|~|\/\*|\$home)/i,
  // rm -fr variants
  /:\(\)\s*\{\s*:\s*\|\s*:\s*&\s*\}\s*;\s*:/,
  // classic fork bomb :(){ :|:& };:
  /\bdd\b[^\n]*\bof=\/dev\//i,
  // dd of=/dev/...
  />\s*\/dev\/(sd|nvme|disk|hd)/i,
  // redirect onto a raw disk
  /\bmkfs(\.[a-z0-9]+)?\b/i,
  // mkfs, mkfs.ext4, ...
  /\b(shutdown|reboot|halt|poweroff)\b/i
  // power state
];
function decideInjection(state, consensus, now, policy = DEFAULT_INJECTION_POLICY, opts = {}) {
  const top = consensus.steps[0];
  if (!top) {
    return { act: false, reason: "no consensus step" };
  }
  if (top.tentative && !opts.allowTentative) {
    return { act: false, reason: "consensus is tentative (no quorum)" };
  }
  if (!state.isManaged) {
    return { act: false, reason: "terminal is external / read-only (cannot inject)" };
  }
  if (state.lastEventType !== "agent-idle") {
    return { act: false, reason: `agent not idle (last event: ${state.lastEventType})` };
  }
  if (now - state.lastActivityAt < policy.humanGraceMs) {
    return { act: false, reason: "recent activity — within human grace window" };
  }
  if (now - state.lastInjectedAt < policy.minIntervalMs) {
    return { act: false, reason: "rate-limited (min inject interval)" };
  }
  if (state.autoActionCount >= policy.maxAutoActions) {
    return { act: false, reason: "circuit breaker — max consecutive auto-actions reached" };
  }
  if (top.confidence < policy.injectConfidence) {
    return { act: false, reason: `confidence ${top.confidence.toFixed(2)} below floor` };
  }
  if (state.lastActedStep !== null && normalizeStep(top.text) === state.lastActedStep) {
    return { act: false, reason: "already acted on this step" };
  }
  return { act: true, reason: "idle + high-confidence consensus", step: top };
}
function guardCommand(command, lastInjectedCommand) {
  const trimmed = command.trim();
  if (trimmed.length === 0) {
    return { command: trimmed, reason: "empty command", safe: false };
  }
  if (/[\r\n]/.test(command)) {
    return {
      command: trimmed,
      reason: "multi-line command rejected (single command only)",
      safe: false
    };
  }
  if (trimmed.length > MAX_COMMAND_LENGTH) {
    return { command: trimmed, reason: `command too long (> ${MAX_COMMAND_LENGTH})`, safe: false };
  }
  for (const pattern of DANGEROUS_PATTERNS) {
    if (pattern.test(trimmed)) {
      return { command: trimmed, reason: "matches a dangerous-command pattern", safe: false };
    }
  }
  if (lastInjectedCommand !== null && trimmed === lastInjectedCommand.trim()) {
    return { command: trimmed, reason: "duplicate of last injected command", safe: false };
  }
  return { command: trimmed, reason: "ok", safe: true };
}
function normalizeStep(text) {
  return text.toLowerCase().trim().replace(/\s+/g, " ").replace(/[.,;:!?]+$/, "");
}
const AUTONOMY_KEY = "shooter_autonomy";
const POLL_INTERVAL_MS = 6e3;
const RECONNECT_MS = 3e3;
const OPEN_TIMEOUT_MS = 5e3;
const MAX_ACTIONS = 40;
const IDLE_RESUME_WINDOW_MS = 12e4;
const AGENT_SUBMIT_DELAY_MS = 120;
const SAFE_ID = /^[A-Za-z0-9_-]+$/;
const SAFE_COMMAND_HEADS = /* @__PURE__ */ new Set([
  "bun",
  "cargo",
  "cat",
  "deno",
  "echo",
  "eslint",
  "git",
  "go",
  "jest",
  "ls",
  "make",
  "node",
  "npm",
  "npx",
  "pnpm",
  "prettier",
  "pwd",
  "python",
  "python3",
  "tsc",
  "vitest",
  "yarn"
]);
const AGENT_COMMANDS = /* @__PURE__ */ new Set(["claude", "opencode"]);
class AutopilotDriver {
  actions = [];
  enabled = false;
  apiKey = "";
  deps;
  eventsWs = null;
  pollTimer = null;
  reconnectTimer = null;
  started = false;
  // eslint-disable-next-line svelte/prefer-svelte-reactivity -- internal, non-reactive bookkeeping
  terminals = /* @__PURE__ */ new Map();
  constructor(deps) {
    this.deps = {
      now: deps?.now ?? (() => Date.now()),
      produceCommand: deps?.produceCommand ?? defaultProduceCommand
    };
    this.enabled = readPersistedAutonomy();
  }
  setEnabled(value) {
    this.enabled = value;
    try {
      localStorage.setItem(AUTONOMY_KEY, JSON.stringify({ enabled: value }));
    } catch {
    }
  }
  start(apiKey) {
    this.apiKey = apiKey;
    if (this.started) {
      return;
    }
    this.started = true;
    if (typeof window !== "undefined") {
      window.addEventListener("shooter:wake", this.onWake);
    }
    void this.connectEvents();
    void this.refresh();
    this.pollTimer = setInterval(() => void this.refresh(), POLL_INTERVAL_MS);
  }
  stop() {
    this.started = false;
    if (typeof window !== "undefined") {
      window.removeEventListener("shooter:wake", this.onWake);
    }
    if (this.pollTimer) {
      clearInterval(this.pollTimer);
      this.pollTimer = null;
    }
    if (this.reconnectTimer) {
      clearTimeout(this.reconnectTimer);
      this.reconnectTimer = null;
    }
    if (this.eventsWs) {
      this.eventsWs.onclose = null;
      this.eventsWs.close();
      this.eventsWs = null;
    }
    for (const rt of this.terminals.values()) {
      rt.injectSocket?.close();
      rt.injectSocket = null;
    }
  }
  async connectEvents() {
    const ticket = await this.getTicket();
    if (!ticket || !this.started) {
      return;
    }
    const wsBase = window.location.origin.replace(/^http/, "ws");
    const ws = new WebSocket(`${wsBase}/ws/events?ticket=${ticket}`);
    this.eventsWs = ws;
    ws.onmessage = (msg) => {
      try {
        const raw = JSON.parse(msg.data);
        if (raw && typeof raw === "object") {
          this.handleEvent(raw);
        }
      } catch {
      }
    };
    ws.onclose = () => {
      this.eventsWs = null;
      if (this.started) {
        this.scheduleReconnect();
      }
    };
    ws.onerror = () => {
    };
  }
  createRuntime(terminalId) {
    const rt = {
      autoActionCount: 0,
      busy: false,
      command: "",
      completed: false,
      consensus: null,
      injectSocket: null,
      isManaged: false,
      lastActedStep: null,
      lastActivityAt: 0,
      lastCommand: null,
      lastEventAt: 0,
      lastEventType: "",
      lastInjectedAt: 0,
      recentOutput: ""
    };
    this.terminals.set(terminalId, rt);
    return rt;
  }
  async evaluate(terminalId) {
    if (!this.enabled) {
      return;
    }
    const rt = this.terminals.get(terminalId);
    if (!rt || rt.busy || !rt.consensus || rt.completed) {
      return;
    }
    const state = {
      autoActionCount: rt.autoActionCount,
      isManaged: rt.isManaged,
      lastActedStep: rt.lastActedStep,
      lastActivityAt: rt.lastActivityAt,
      lastEventType: rt.lastEventType,
      lastInjectedAt: rt.lastInjectedAt
    };
    const decision = decideInjection(state, rt.consensus, this.deps.now(), void 0, { allowTentative: isAgentCommand(rt.command) });
    if (!decision.act || !decision.step) {
      return;
    }
    rt.busy = true;
    try {
      const isAgent = isAgentCommand(rt.command);
      let command;
      try {
        command = await this.deps.produceCommand({
          apiKey: this.apiKey,
          isAgentTerminal: isAgent,
          recentOutput: rt.recentOutput,
          step: decision.step,
          terminalId
        });
      } catch {
        command = null;
      }
      if (!command) {
        this.log(terminalId, "skipped", `no command for: ${decision.step.text.slice(0, 60)}`);
        return;
      }
      const candidate = isAgent ? command.replace(/\s*[\r\n]+\s*/g, " ").trim() : command;
      const verdict = guardCommand(candidate, rt.lastCommand);
      if (!verdict.safe) {
        rt.lastActedStep = normalizeStep(decision.step.text);
        this.log(terminalId, "skipped", `guard: ${verdict.reason}`);
        return;
      }
      const ok = await this.inject(terminalId, verdict.command);
      if (ok) {
        rt.lastInjectedAt = this.deps.now();
        rt.lastCommand = verdict.command;
        rt.lastActedStep = normalizeStep(decision.step.text);
        rt.autoActionCount += 1;
        this.log(terminalId, "injected", verdict.command);
      } else {
        this.log(terminalId, "error", `inject failed: ${verdict.command}`);
      }
    } finally {
      rt.busy = false;
    }
  }
  async fetchSummaries() {
    try {
      const res = await fetch("/api/summaries?limit=30", { headers: { Authorization: `Bearer ${this.apiKey}` } });
      if (!res.ok) {
        return;
      }
      const body = await res.json();
      const latest = /* @__PURE__ */ new Set();
      for (const rec of body.summaries ?? []) {
        const tid = rec.terminalId;
        if (!tid || latest.has(tid)) {
          continue;
        }
        const rt = this.terminals.get(tid);
        if (!rt) {
          continue;
        }
        latest.add(tid);
        rt.consensus = { agentCount: 5, quorum: 3, steps: parseSteps(rec.nextSteps) };
        const createdMs = Date.parse(rec.createdAt);
        if (rec.status === "completed") {
          if (!Number.isFinite(createdMs) || createdMs >= rt.lastEventAt) {
            rt.completed = true;
          }
        } else {
          rt.completed = false;
        }
        if (rec.trigger === "agent-idle" && Number.isFinite(createdMs) && createdMs >= rt.lastEventAt && this.deps.now() - createdMs < IDLE_RESUME_WINDOW_MS) {
          rt.lastEventType = "agent-idle";
        }
      }
    } catch {
    }
  }
  async fetchTerminals() {
    try {
      const res = await fetch("/api/terminals", { headers: { Authorization: `Bearer ${this.apiKey}` } });
      if (!res.ok) {
        return;
      }
      const body = await res.json();
      const seen = /* @__PURE__ */ new Set();
      for (const t of body.terminals ?? []) {
        if (t.exitedAt !== null || t.status === "exited") {
          continue;
        }
        seen.add(t.id);
        const rt = this.terminals.get(t.id) ?? this.createRuntime(t.id);
        rt.isManaged = true;
        rt.command = t.command ?? "";
      }
      for (const id of [...this.terminals.keys()]) {
        if (!seen.has(id)) {
          this.terminals.get(id)?.injectSocket?.close();
          this.terminals.delete(id);
        }
      }
    } catch {
    }
  }
  async getTicket() {
    try {
      const res = await fetch("/api/ws-ticket", {
        headers: { Authorization: `Bearer ${this.apiKey}` },
        method: "POST"
      });
      if (!res.ok) {
        return null;
      }
      const { ticket } = await res.json();
      return ticket;
    } catch {
      return null;
    }
  }
  handleEvent(raw) {
    const type = typeof raw.type === "string" ? raw.type : "";
    const terminalId = typeof raw.terminalId === "string" ? raw.terminalId : "";
    if (!type || type === "welcome" || !terminalId) {
      return;
    }
    const rt = this.terminals.get(terminalId);
    if (!rt) {
      return;
    }
    rt.lastEventType = type;
    rt.lastEventAt = this.deps.now();
    if (type !== "agent-idle" && type !== "agent-question") {
      rt.lastActivityAt = this.deps.now();
    }
    if (type === "tool-started") {
      rt.completed = false;
    }
    if (type === "tool-completed" && raw.success === true) {
      rt.autoActionCount = 0;
    }
    if (type === "agent-idle" && this.enabled) {
      void this.evaluate(terminalId);
    }
  }
  async inject(terminalId, command) {
    const rt = this.terminals.get(terminalId);
    if (!rt) {
      return false;
    }
    if (!SAFE_ID.test(terminalId)) {
      return false;
    }
    let ws = rt.injectSocket;
    if (!ws || ws.readyState > WebSocket.OPEN) {
      const ticket = await this.getTicket();
      if (!ticket) {
        return false;
      }
      const wsBase = window.location.origin.replace(/^http/, "ws");
      ws = new WebSocket(`${wsBase}/ws/terminal/${encodeURIComponent(terminalId)}?ticket=${encodeURIComponent(ticket)}`);
      rt.injectSocket = ws;
      const opened = await waitForOpen(ws);
      if (!opened) {
        rt.injectSocket = null;
        return false;
      }
    }
    if (ws.readyState !== WebSocket.OPEN) {
      return false;
    }
    if (isAgentCommand(rt.command)) {
      const prompt = command.replace(/\s*[\r\n]+\s*/g, " ").trim();
      if (!prompt) {
        return false;
      }
      ws.send(JSON.stringify({ data: prompt, type: "input" }));
      await delay(AGENT_SUBMIT_DELAY_MS);
      if (ws.readyState !== WebSocket.OPEN) {
        return false;
      }
      ws.send(JSON.stringify({ data: "\r", type: "input" }));
      return true;
    }
    ws.send(JSON.stringify({ data: `${command}\r`, type: "input" }));
    return true;
  }
  log(terminalId, kind, detail) {
    this.actions = [
      { at: this.deps.now(), detail, kind, terminalId },
      ...this.actions
    ].slice(0, MAX_ACTIONS);
  }
  onWake = () => {
    void this.refresh();
  };
  async refresh() {
    if (!this.apiKey) {
      return;
    }
    await Promise.allSettled([this.fetchTerminals(), this.fetchSummaries()]);
    if (this.enabled) {
      for (const id of this.terminals.keys()) {
        void this.evaluate(id);
      }
    }
  }
  scheduleReconnect() {
    if (this.reconnectTimer) {
      return;
    }
    this.reconnectTimer = setTimeout(
      () => {
        this.reconnectTimer = null;
        void this.connectEvents();
      },
      RECONNECT_MS
    );
  }
}
async function defaultProduceCommand(input) {
  if (input.isAgentTerminal) {
    const prompt = input.step.text.trim();
    return prompt.length > 0 ? prompt : null;
  }
  const native = await tryNativeDecide(input);
  if (native) {
    return native;
  }
  const litellm = await litellmProduceCommand(input);
  if (litellm) {
    return litellm;
  }
  const text = input.step.text.trim();
  const backticked = /`([^`]+)`/.exec(text);
  if (backticked) {
    return backticked[1].trim();
  }
  const head2 = text.split(/\s+/)[0]?.toLowerCase();
  if (head2 && SAFE_COMMAND_HEADS.has(head2) && !/[\r\n]/.test(text) && text.length < 80) {
    return text;
  }
  return null;
}
function delay(ms) {
  return new Promise((resolve) => {
    setTimeout(resolve, ms);
  });
}
function isAgentCommand(command) {
  const firstToken = command.trim().split(/\s+/)[0] ?? "";
  const base = firstToken.split("/").pop() ?? "";
  return AGENT_COMMANDS.has(base);
}
async function litellmProduceCommand(input) {
  const base = readProcessEnv("LITELLM_BASE_URL");
  if (!base || !input.apiKey) {
    return null;
  }
  const model = readProcessEnv("LITELLM_MODEL") || "open-large-sa";
  const userPrompt = `Recent terminal output:
${input.recentOutput.slice(-2e3)}

Suggested next step: ${input.step.text}

Reply with ONLY the single shell command to run next — no prose, no backticks, no explanation.`;
  try {
    const res = await fetch("/api/neurolink-proxy", {
      body: JSON.stringify({
        body: {
          max_tokens: 60,
          messages: [
            {
              content: "You are a coding-session copilot. Output ONLY the next shell command.",
              role: "system"
            },
            { content: userPrompt, role: "user" }
          ],
          model,
          temperature: 0
        },
        headers: {},
        provider: "litellm",
        url: `${base}/chat/completions`
      }),
      headers: {
        Authorization: `Bearer ${input.apiKey}`,
        "Content-Type": "application/json"
      },
      method: "POST"
    });
    if (!res.ok) {
      return null;
    }
    const data = await res.json();
    const content = data.choices?.[0]?.message?.content;
    if (typeof content !== "string") {
      return null;
    }
    const cmd = content.trim().replace(/^`+|`+$/g, "").trim();
    return cmd.length > 0 ? cmd : null;
  } catch {
    return null;
  }
}
function parseSteps(json) {
  try {
    const parsed = JSON.parse(json);
    if (!Array.isArray(parsed)) {
      return [];
    }
    return parsed.filter((el) => typeof el === "object" && el !== null && typeof el.text === "string" && typeof el.confidence === "number");
  } catch {
    return [];
  }
}
function readPersistedAutonomy() {
  if (typeof localStorage === "undefined") {
    return false;
  }
  try {
    const raw = localStorage.getItem(AUTONOMY_KEY);
    if (!raw) {
      return false;
    }
    const parsed = JSON.parse(raw);
    return Boolean(parsed?.enabled);
  } catch {
    return false;
  }
}
function readProcessEnv(key) {
  const proc = window["process"];
  const value = proc?.env?.[key];
  return typeof value === "string" ? value : "";
}
function tryNativeDecide(input) {
  const bridge = window.ShooterBridge;
  if (typeof bridge?.agentDecide !== "function") {
    return Promise.resolve(null);
  }
  const ctx = `Recent terminal output:
${input.recentOutput.slice(-2e3)}

Suggested next step: ${input.step.text}

Reply with the single shell command to run next.`;
  return bridge.agentDecide(ctx).then((c) => typeof c === "string" && c.trim().length > 0 ? c.trim() : null).catch(() => null);
}
function waitForOpen(ws) {
  if (ws.readyState === WebSocket.OPEN) {
    return Promise.resolve(true);
  }
  return new Promise((resolve) => {
    const timer = setTimeout(
      () => {
        ws.close();
        resolve(false);
      },
      OPEN_TIMEOUT_MS
    );
    ws.addEventListener("open", () => {
      clearTimeout(timer);
      resolve(true);
    });
    ws.addEventListener("error", () => {
      clearTimeout(timer);
      ws.close();
      resolve(false);
    });
  });
}
new AutopilotDriver();
const ACTIVE_THRESHOLD_MS = 3e4;
let sessions = [];
const summarizers = new SvelteMap();
const sessionSockets = new SvelteMap();
const pendingSessionSockets = new SvelteSet();
function disconnect() {
  for (const [, sock] of sessionSockets) {
    sock.onclose = null;
    sock.close();
  }
  sessionSockets.clear();
  pendingSessionSockets.clear();
  summarizers.clear();
}
function getCards() {
  const now = Date.now();
  return sortSessions(sessions).map((s) => {
    const createdMs = Date.parse(s.createdAt);
    const lastEventTs = s.events.length > 0 ? Date.parse(s.events[s.events.length - 1].timestamp) : 0;
    return {
      ...s,
      duration: now - createdMs,
      goal: s.goal,
      // Ensure goal is mapped
      isActive: lastEventTs > 0 && now - lastEventTs < ACTIVE_THRESHOLD_MS,
      isSummarizing: s.isSummarizing,
      // Ensure isSummarizing is mapped
      summary: s.summary
      // Ensure summary is mapped
    };
  });
}
function sortSessions(list) {
  return [...list].sort((a, b) => {
    const order = { error: 2, exited: 3, idle: 1, running: 0 };
    const rankA = order[a.status];
    const rankB = order[b.status];
    if (rankA !== rankB) {
      return rankA - rankB;
    }
    if (a.status !== "exited" && b.status !== "exited") {
      return b.createdAt.localeCompare(a.createdAt);
    }
    const exitA = a.exitedAt ?? a.createdAt;
    const exitB = b.exitedAt ?? b.createdAt;
    return exitB.localeCompare(exitA);
  });
}
function _page($$renderer, $$props) {
  $$renderer.component(($$renderer2) => {
    let projects = [];
    let loading = false;
    const cards = derived(getCards);
    onDestroy(() => {
      disconnect();
    });
    async function fetchSessions(append = false, bustCache = false) {
      {
        return;
      }
    }
    async function forceRefresh() {
      loading = true;
      clearCache("shooter_projects");
      await fetchSessions(false, true);
    }
    function navigateToConfig() {
      void goto();
    }
    function totalSessionCount() {
      return projects.reduce((sum, p) => sum + p.sessionCount, 0);
    }
    head("1uha8ag", $$renderer2, ($$renderer3) => {
      $$renderer3.title(($$renderer4) => {
        $$renderer4.push(`<title>Dashboard - Shooter</title>`);
      });
      $$renderer3.push(`<meta name="description" content="Active terminals and Claude Code sessions"/>`);
    });
    $$renderer2.push(`<main class="main"><div class="page-header"><div class="page-header-content"><div><h1 class="page-title">Dashboard</h1> <p class="page-description">Active terminals and Claude Code sessions</p></div> <div class="page-actions">`);
    Button($$renderer2, {
      classes: "btn-secondary",
      onclick: forceRefresh,
      disabled: loading,
      children: ($$renderer3) => {
        Icon($$renderer3, { svg: RefreshSvg, classes: "icon-14" });
        $$renderer3.push(`<!----> Refresh`);
      },
      $$slots: { default: true }
    });
    $$renderer2.push(`<!----></div></div> `);
    if (projects.length > 0) {
      $$renderer2.push("<!--[0-->");
      $$renderer2.push(`<div class="stats-bar svelte-1uha8ag"><div class="stat-chip svelte-1uha8ag"><span class="stat-value svelte-1uha8ag">${escape_html(projects.length)}</span> <span class="stat-label svelte-1uha8ag">${escape_html(projects.length === 1 ? "project" : "projects")}</span></div> <div class="stat-chip svelte-1uha8ag"><span class="stat-value svelte-1uha8ag">${escape_html(totalSessionCount())}</span> <span class="stat-label svelte-1uha8ag">${escape_html(totalSessionCount() === 1 ? "session" : "sessions")}</span></div> `);
      if (cards().length > 0) {
        $$renderer2.push("<!--[0-->");
        $$renderer2.push(`<div class="stat-chip stat-chip-active svelte-1uha8ag"><span class="stat-value svelte-1uha8ag">${escape_html(cards().length)}</span> <span class="stat-label svelte-1uha8ag">active</span></div>`);
      } else {
        $$renderer2.push("<!--[-1-->");
      }
      $$renderer2.push(`<!--]--></div>`);
    } else {
      $$renderer2.push("<!--[-1-->");
    }
    $$renderer2.push(`<!--]--></div> `);
    {
      $$renderer2.push("<!--[-1-->");
    }
    $$renderer2.push(`<!--]--> `);
    if (loading && projects.length === 0 && cards().length === 0) {
      $$renderer2.push("<!--[0-->");
      $$renderer2.push(`<div class="loading-container"><!--[-->`);
      const each_array = ensure_array_like(Array(3));
      for (let i = 0, $$length = each_array.length; i < $$length; i++) {
        each_array[i];
        Shimmer($$renderer2, { classes: "shimmer-card" });
      }
      $$renderer2.push(`<!--]--></div>`);
    } else {
      $$renderer2.push("<!--[1-->");
      {
        let icon = function($$renderer3) {
          Icon($$renderer3, { svg: SettingsSvg, classes: "icon-24" });
        };
        EmptyState($$renderer2, {
          title: "Configuration Required",
          description: "Set up your API credentials to start tracking sessions",
          icon,
          children: ($$renderer3) => {
            Button($$renderer3, {
              classes: "btn-primary",
              onclick: navigateToConfig,
              text: "Configure Settings"
            });
          }
        });
      }
    }
    $$renderer2.push(`<!--]--></main>`);
  });
}

export { _page as default };
//# sourceMappingURL=_page.svelte-Bl1gvo0Q.js.map
