loki-mode 6.64.3 → 6.65.0
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/SKILL.md +2 -2
- package/VERSION +1 -1
- package/autonomy/run.sh +125 -12
- package/dashboard/__init__.py +1 -1
- package/docs/INSTALLATION.md +1 -1
- package/mcp/__init__.py +1 -1
- package/package.json +1 -1
- package/web-app/dist/assets/{Badge-CecAeNGh.js → Badge-B5HgOamf.js} +1 -1
- package/web-app/dist/assets/{Button-BAwZY3QB.js → Button-Dr_x-zc5.js} +1 -1
- package/web-app/dist/assets/{Card-3YIYrz1X.js → Card-Kc9YONqh.js} +1 -1
- package/web-app/dist/assets/{HomePage-DYS0zqqT.js → HomePage-BtsaYGRR.js} +1 -1
- package/web-app/dist/assets/{LoginPage-D5Jj_Q44.js → LoginPage-D7RmxUWG.js} +1 -1
- package/web-app/dist/assets/{NotFoundPage-DLG6ORdp.js → NotFoundPage-D5Gd5Q79.js} +1 -1
- package/web-app/dist/assets/{ProjectPage-D-ZyzZUT.js → ProjectPage-DQHsCc2_.js} +21 -21
- package/web-app/dist/assets/{ProjectsPage-CMacaz1V.js → ProjectsPage-CUdwe4_n.js} +1 -1
- package/web-app/dist/assets/{SettingsPage-B9XKC6ge.js → SettingsPage-4zGDgdk5.js} +1 -1
- package/web-app/dist/assets/{TemplatesPage-Bq8ASiy4.js → TemplatesPage-BR2QjKqV.js} +1 -1
- package/web-app/dist/assets/{TerminalOutput-rQ65EXIP.js → TerminalOutput-Bk9csYRz.js} +1 -1
- package/web-app/dist/assets/{arrow-left-BcsRbWot.js → arrow-left-BuMZs13c.js} +1 -1
- package/web-app/dist/assets/{clock-DUeIWW98.js → clock-JjJ4Yqbk.js} +1 -1
- package/web-app/dist/assets/{external-link-lxSyZieU.js → external-link-jWUgVKgO.js} +1 -1
- package/web-app/dist/assets/{index-Cyfnu-vw.js → index-pa3JgPvH.js} +2 -2
- package/web-app/dist/index.html +1 -1
package/SKILL.md
CHANGED
|
@@ -3,7 +3,7 @@ name: loki-mode
|
|
|
3
3
|
description: Multi-agent autonomous startup system. Triggers on "Loki Mode". Takes PRD to deployed product with minimal human intervention. Requires --dangerously-skip-permissions flag.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
# Loki Mode v6.
|
|
6
|
+
# Loki Mode v6.65.0
|
|
7
7
|
|
|
8
8
|
**You are an autonomous agent. You make decisions. You do not ask questions. You do not stop.**
|
|
9
9
|
|
|
@@ -267,4 +267,4 @@ The following features are documented in skill modules but not yet fully automat
|
|
|
267
267
|
| Quality gates 3-reviewer system | Implemented (v5.35.0) | 5 specialist reviewers in `skills/quality-gates.md`; execution in run.sh |
|
|
268
268
|
| Benchmarks (HumanEval, SWE-bench) | Infrastructure only | Runner scripts and datasets exist in `benchmarks/`; no published results |
|
|
269
269
|
|
|
270
|
-
**v6.
|
|
270
|
+
**v6.65.0 | [Autonomi](https://www.autonomi.dev/) flagship product | ~260 lines core**
|
package/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
6.
|
|
1
|
+
6.65.0
|
package/autonomy/run.sh
CHANGED
|
@@ -8798,10 +8798,24 @@ populate_prd_queue() {
|
|
|
8798
8798
|
return 0
|
|
8799
8799
|
fi
|
|
8800
8800
|
|
|
8801
|
+
# Prefer the original project PRD over generated quick-prd.md
|
|
8802
|
+
# quick-prd.md contains boilerplate that produces garbage tasks
|
|
8803
|
+
local effective_prd="$prd_file"
|
|
8804
|
+
if [[ "$prd_file" == *"quick-prd.md" ]] || [[ "$prd_file" == *"chat-prd.md" ]]; then
|
|
8805
|
+
# Look for the real PRD in the project root
|
|
8806
|
+
for candidate in "PRD.md" "prd.md" "requirements.md" "REQUIREMENTS.md" "spec.md" "SPEC.md"; do
|
|
8807
|
+
if [[ -f "$candidate" ]]; then
|
|
8808
|
+
effective_prd="$candidate"
|
|
8809
|
+
log_info "Using project PRD ($candidate) instead of generated $prd_file"
|
|
8810
|
+
break
|
|
8811
|
+
fi
|
|
8812
|
+
done
|
|
8813
|
+
fi
|
|
8814
|
+
|
|
8801
8815
|
log_step "Parsing PRD into structured tasks..."
|
|
8802
8816
|
mkdir -p ".loki/queue"
|
|
8803
8817
|
|
|
8804
|
-
LOKI_PRD_FILE="$
|
|
8818
|
+
LOKI_PRD_FILE="$effective_prd" python3 << 'PRD_PARSE_EOF'
|
|
8805
8819
|
import json, re, os, sys
|
|
8806
8820
|
|
|
8807
8821
|
prd_path = os.environ.get("LOKI_PRD_FILE", "")
|
|
@@ -8836,17 +8850,67 @@ for line in content.split("\n"):
|
|
|
8836
8850
|
project_name = m.group(1).strip()
|
|
8837
8851
|
break
|
|
8838
8852
|
|
|
8839
|
-
#
|
|
8853
|
+
# Helper: strip numbered prefixes like "4." or "4.1" or "6.3.2" from section names
|
|
8854
|
+
def strip_numbering(name):
|
|
8855
|
+
return re.sub(r'^\d+(\.\d+)*\.?\s*', '', name).strip()
|
|
8856
|
+
|
|
8857
|
+
# Find feature/requirement sections -- expanded keywords for real-world PRDs
|
|
8840
8858
|
feature_keywords = [
|
|
8841
8859
|
"features", "requirements", "key features", "core features",
|
|
8842
8860
|
"functional requirements", "user stories", "deliverables",
|
|
8843
|
-
"scope", "functionality", "capabilities", "modules"
|
|
8861
|
+
"project scope", "functionality", "capabilities", "modules",
|
|
8862
|
+
# Real-world PRD section names:
|
|
8863
|
+
"specification", "backend", "frontend", "api", "endpoints",
|
|
8864
|
+
"components", "services", "implementation", "architecture",
|
|
8865
|
+
"build instructions", "interface", "phase",
|
|
8866
|
+
"database", "data model", "workflow",
|
|
8867
|
+
"screens", "routes", "views", "controllers", "models",
|
|
8868
|
+
"pipeline", "integration", "scaffolding", "deploy",
|
|
8844
8869
|
]
|
|
8845
8870
|
|
|
8846
|
-
#
|
|
8871
|
+
# Meta sections to skip (applied after stripping numbered prefixes).
|
|
8872
|
+
# Skip check runs BEFORE keyword matching so meta sections are never extracted.
|
|
8873
|
+
skip_keywords = {
|
|
8874
|
+
"table of contents", "overview", "introduction", "summary",
|
|
8875
|
+
"executive summary", "appendix", "references", "changelog",
|
|
8876
|
+
"future roadmap", "out of scope", "environment variables",
|
|
8877
|
+
"risks", "mitigations", "success metrics", "timeline",
|
|
8878
|
+
"glossary", "terminology", "revision history",
|
|
8879
|
+
"target audience", "tech stack", "technology", "deployment",
|
|
8880
|
+
"non-functional", "problem statement", "value proposition",
|
|
8881
|
+
"background", "metrics", "roadmap",
|
|
8882
|
+
}
|
|
8883
|
+
|
|
8884
|
+
def is_skip_section(name):
|
|
8885
|
+
"""Check if a section name (after stripping numbers) matches a meta/skip section."""
|
|
8886
|
+
clean = strip_numbering(name).lower()
|
|
8887
|
+
if clean in skip_keywords:
|
|
8888
|
+
return True
|
|
8889
|
+
# Also check substring match for skip keywords
|
|
8890
|
+
for sk in skip_keywords:
|
|
8891
|
+
if sk in clean:
|
|
8892
|
+
return True
|
|
8893
|
+
return False
|
|
8894
|
+
|
|
8895
|
+
# Also skip the document title (H1 heading captured as a section name)
|
|
8896
|
+
h1_title = None
|
|
8897
|
+
for line in content.split("\n"):
|
|
8898
|
+
m = re.match(r'^#\s+(.+)', line)
|
|
8899
|
+
if m:
|
|
8900
|
+
h1_title = m.group(1).strip()
|
|
8901
|
+
break
|
|
8902
|
+
|
|
8903
|
+
# Extract features from bullet points in feature sections (keyword-matched)
|
|
8847
8904
|
features = []
|
|
8848
8905
|
for section_name, section_content in sections.items():
|
|
8849
|
-
|
|
8906
|
+
# Skip meta sections first (takes priority over keyword match)
|
|
8907
|
+
if is_skip_section(section_name):
|
|
8908
|
+
continue
|
|
8909
|
+
# Skip the document title section
|
|
8910
|
+
if h1_title and section_name == h1_title:
|
|
8911
|
+
continue
|
|
8912
|
+
clean_name = strip_numbering(section_name).lower()
|
|
8913
|
+
is_feature_section = any(kw in clean_name for kw in feature_keywords)
|
|
8850
8914
|
if is_feature_section:
|
|
8851
8915
|
# Extract numbered items or bullet points
|
|
8852
8916
|
for line in section_content.split("\n"):
|
|
@@ -8859,22 +8923,71 @@ for section_name, section_content in sections.items():
|
|
|
8859
8923
|
if raw_line and raw_line[0] in (' ', '\t'):
|
|
8860
8924
|
continue
|
|
8861
8925
|
feature_text = m.group(1).strip()
|
|
8926
|
+
# Skip boilerplate template lines
|
|
8927
|
+
boilerplate = {
|
|
8928
|
+
"complete the task described above",
|
|
8929
|
+
"follow existing code patterns and conventions",
|
|
8930
|
+
"write tests if applicable",
|
|
8931
|
+
"do not break existing functionality",
|
|
8932
|
+
"task is completed as described",
|
|
8933
|
+
"no errors or regressions introduced",
|
|
8934
|
+
"code follows project conventions",
|
|
8935
|
+
"keep changes minimal and focused",
|
|
8936
|
+
"do not refactor unrelated code",
|
|
8937
|
+
}
|
|
8938
|
+
if feature_text.lower() in boilerplate:
|
|
8939
|
+
continue
|
|
8862
8940
|
if len(feature_text) > 10: # Skip very short lines
|
|
8863
8941
|
features.append({
|
|
8864
8942
|
"title": feature_text,
|
|
8865
8943
|
"section": section_name,
|
|
8866
8944
|
})
|
|
8867
8945
|
|
|
8868
|
-
#
|
|
8946
|
+
# Also extract ### sub-headings from feature sections as tasks
|
|
8947
|
+
for section_name, section_content in sections.items():
|
|
8948
|
+
if is_skip_section(section_name):
|
|
8949
|
+
continue
|
|
8950
|
+
if h1_title and section_name == h1_title:
|
|
8951
|
+
continue
|
|
8952
|
+
clean_name = strip_numbering(section_name).lower()
|
|
8953
|
+
is_feature_section = any(kw in clean_name for kw in feature_keywords)
|
|
8954
|
+
if is_feature_section:
|
|
8955
|
+
for line in section_content.split("\n"):
|
|
8956
|
+
sub_match = re.match(r'^###\s+(.+)', line)
|
|
8957
|
+
if sub_match:
|
|
8958
|
+
sub_title = strip_numbering(sub_match.group(1).strip())
|
|
8959
|
+
if len(sub_title) > 5:
|
|
8960
|
+
# Avoid duplicates
|
|
8961
|
+
if not any(f["title"] == sub_title for f in features):
|
|
8962
|
+
features.append({"title": sub_title, "section": section_name})
|
|
8963
|
+
|
|
8964
|
+
# Fallback: if no features found via keyword matching, extract ### sub-headings
|
|
8965
|
+
# from ALL non-meta sections
|
|
8869
8966
|
if not features:
|
|
8870
|
-
skip_sections = {"overview", "introduction", "summary", "target audience",
|
|
8871
|
-
"tech stack", "technology", "deployment", "timeline",
|
|
8872
|
-
"out of scope", "non-functional", "appendix", "references",
|
|
8873
|
-
"problem statement", "value proposition", "background"}
|
|
8874
8967
|
for section_name, section_content in sections.items():
|
|
8875
|
-
if section_name
|
|
8968
|
+
if is_skip_section(section_name):
|
|
8969
|
+
continue
|
|
8970
|
+
if h1_title and section_name == h1_title:
|
|
8971
|
+
continue
|
|
8972
|
+
for line in section_content.split("\n"):
|
|
8973
|
+
sub_match = re.match(r'^###\s+(.+)', line)
|
|
8974
|
+
if sub_match:
|
|
8975
|
+
sub_title = strip_numbering(sub_match.group(1).strip())
|
|
8976
|
+
if len(sub_title) > 5:
|
|
8977
|
+
if not any(f["title"] == sub_title for f in features):
|
|
8978
|
+
features.append({"title": sub_title, "section": section_name})
|
|
8979
|
+
|
|
8980
|
+
# Final fallback: extract from ## headings that are non-meta sections
|
|
8981
|
+
if not features:
|
|
8982
|
+
for section_name, section_content in sections.items():
|
|
8983
|
+
if is_skip_section(section_name):
|
|
8984
|
+
continue
|
|
8985
|
+
if h1_title and section_name == h1_title:
|
|
8986
|
+
continue
|
|
8987
|
+
clean_name = strip_numbering(section_name)
|
|
8988
|
+
if len(section_content) > 20 and len(clean_name) > 5:
|
|
8876
8989
|
features.append({
|
|
8877
|
-
"title":
|
|
8990
|
+
"title": clean_name,
|
|
8878
8991
|
"section": "Requirements",
|
|
8879
8992
|
})
|
|
8880
8993
|
|
package/dashboard/__init__.py
CHANGED
package/docs/INSTALLATION.md
CHANGED
package/mcp/__init__.py
CHANGED
package/package.json
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{c as m,r,j as e}from"./index-
|
|
1
|
+
import{c as m,r,j as e}from"./index-pa3JgPvH.js";import{C as g,a as p}from"./clock-JjJ4Yqbk.js";/**
|
|
2
2
|
* @license lucide-react v0.577.0 - ISC
|
|
3
3
|
*
|
|
4
4
|
* This source code is licensed under the ISC license.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as s}from"./index-
|
|
1
|
+
import{j as s}from"./index-pa3JgPvH.js";const n={none:"p-0",sm:"p-3",md:"p-4",lg:"p-6"};function p({hover:e=!1,padding:d="md",className:t="",children:a,onClick:r}){return s.jsx("div",{role:r?"button":void 0,tabIndex:r?0:void 0,onClick:r,onKeyDown:r?o=>{(o.key==="Enter"||o.key===" ")&&(o.preventDefault(),r())}:void 0,className:["bg-white border border-[#ECEAE3] rounded-[5px] shadow-card",e&&"hover:shadow-card-hover transition-shadow duration-200",r&&"cursor-pointer",n[d],t].filter(Boolean).join(" "),children:a})}export{p as C};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as e,r as l,a as h,u as be,b as ge}from"./index-
|
|
1
|
+
import{j as e,r as l,a as h,u as be,b as ge}from"./index-pa3JgPvH.js";import{u as I,B as je}from"./Badge-B5HgOamf.js";import{P as ve,a as Ne,S as ye,E as C,T as we}from"./TerminalOutput-Bk9csYRz.js";import"./clock-JjJ4Yqbk.js";function ke(t){if(t<60)return`${Math.round(t)}s`;if(t<3600)return`${Math.floor(t/60)}m ${Math.round(t%60)}s`;const s=Math.floor(t/3600),n=Math.floor(t%3600/60);return`${s}h ${n}m`}function Se(t,s){if(!t||t<=0)return"--";const n={simple:{opus:1,haiku:1,total:3},standard:{opus:2,haiku:2,total:5},complex:{opus:3,haiku:3,total:8}},r=n[s]||n.standard;return t<=r.opus?"Opus":t>r.total-r.haiku?"Haiku":"Sonnet"}function Ce({status:t,prdSummary:s,onStop:n,onPause:r,onResume:a,isPaused:c}){const i=t?Se(t.iteration??0,t.complexity||"standard"):"--",o=c??(t==null?void 0:t.paused)??!1;return e.jsxs("div",{className:"card px-5 py-3 flex items-center gap-6 text-sm",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("span",{className:"text-xs text-muted uppercase tracking-wider font-medium",children:"Phase"}),e.jsx("span",{className:"font-mono font-semibold text-ink",children:(t==null?void 0:t.phase)||"idle"})]}),e.jsx("div",{className:"w-px h-5 bg-border"}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("span",{className:"text-xs text-muted uppercase tracking-wider font-medium",children:"Complexity"}),e.jsx("span",{className:`font-mono font-semibold ${(t==null?void 0:t.complexity)==="complex"?"text-warning":(t==null?void 0:t.complexity)==="simple"?"text-success":"text-ink"}`,children:(t==null?void 0:t.complexity)||"standard"})]}),e.jsx("div",{className:"w-px h-5 bg-border"}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("span",{className:"text-xs text-muted uppercase tracking-wider font-medium",children:"Model"}),e.jsx("span",{className:`font-mono font-semibold px-2 py-0.5 rounded-md text-xs ${i==="Opus"?"bg-primary/10 text-primary":i==="Haiku"?"bg-success/10 text-success":"bg-primary/10 text-primary"}`,children:i})]}),e.jsx("div",{className:"w-px h-5 bg-border"}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("span",{className:"text-xs text-muted uppercase tracking-wider font-medium",children:"Tasks"}),e.jsx("span",{className:"font-mono text-ink",children:t!=null&&t.current_task?e.jsx("span",{className:"text-xs",children:t.current_task}):e.jsx("span",{className:"text-muted",children:"--"})}),((t==null?void 0:t.pending_tasks)??0)>0&&e.jsxs("span",{className:"text-xs text-primary font-mono",children:["+",t==null?void 0:t.pending_tasks," pending"]})]}),s&&e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"w-px h-5 bg-border"}),e.jsxs("div",{className:"flex items-center gap-2 min-w-0",children:[e.jsx("span",{className:"text-xs text-muted uppercase tracking-wider font-medium flex-shrink-0",children:"Building"}),e.jsx("span",{className:"text-xs font-mono text-ink truncate max-w-[220px]",title:s,children:s.length>60?s.slice(0,60)+"...":s})]})]}),e.jsx("div",{className:"flex-1"}),((t==null?void 0:t.uptime)??0)>0&&e.jsx("span",{className:"font-mono text-xs text-muted",children:ke((t==null?void 0:t.uptime)??0)}),(r||a)&&e.jsxs("button",{onClick:o?a:r,className:"flex items-center gap-1.5 px-4 py-1.5 rounded-btn text-xs font-semibold border border-warning/30 text-warning hover:bg-warning/10 transition-colors",children:[o?e.jsx(ve,{size:14}):e.jsx(Ne,{size:14}),o?"Resume":"Pause"]}),n&&e.jsxs("button",{onClick:n,className:"flex items-center gap-1.5 px-4 py-1.5 rounded-btn text-xs font-semibold bg-danger/10 text-danger border border-danger/20 hover:bg-danger/20 transition-colors",children:[e.jsx(ye,{size:14}),"Stop"]})]})}function Ee({status:t}){const s=[{label:"Iteration",value:t?t.iteration.toString():"--",color:"text-primary"},{label:"Agents",value:t?t.running_agents.toString():"--",color:t&&t.running_agents>0?"text-success":"text-muted"},{label:"Pending",value:t?t.pending_tasks.toString():"--",color:t&&t.pending_tasks>0?"text-warning":"text-muted"},{label:"Provider",value:(t==null?void 0:t.provider)||"--",color:"text-primary"}];return e.jsx("div",{className:"grid grid-cols-4 gap-3",children:s.map(n=>e.jsxs("div",{className:"card p-4 text-center",children:[e.jsx("div",{className:`text-2xl font-bold font-mono ${n.color}`,children:n.value}),e.jsx("div",{className:"text-xs text-muted font-medium mt-1 uppercase tracking-wider",children:n.label})]},n.label))})}function Pe({plan:t,loading:s,onConfirm:n,onCancel:r}){return e.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/30 backdrop-blur-sm",children:e.jsxs("div",{className:"card w-full max-w-lg mx-4 p-6 rounded-card shadow-card-hover",children:[e.jsx("h2",{className:"text-lg font-bold text-ink mb-4",children:"Build Estimate"}),s?e.jsxs("div",{className:"flex flex-col items-center py-8 gap-3",children:[e.jsx("div",{className:"w-8 h-8 border-2 border-primary border-t-transparent rounded-full animate-spin"}),e.jsx("p",{className:"text-sm text-muted",children:"Analyzing PRD..."}),e.jsxs("div",{className:"flex gap-3 mt-4",children:[e.jsx("button",{onClick:r,className:"px-4 py-2 text-sm font-medium text-muted hover:text-ink transition-colors",children:"Cancel"}),e.jsx("button",{onClick:n,className:"px-4 py-2 text-sm font-medium text-primary hover:text-primary/80 transition-colors underline",children:"Skip analysis, build now"})]})]}):t?e.jsxs(e.Fragment,{children:[t.returncode!==0&&e.jsxs("div",{className:"mb-4 px-3 py-2 rounded-btn bg-warning/10 border border-warning/20 text-warning text-xs",children:["loki plan exited with code ",t.returncode," - showing partial results"]}),e.jsxs("div",{className:"grid grid-cols-2 gap-3 mb-4",children:[e.jsxs("div",{className:"card rounded-card p-3",children:[e.jsx("div",{className:"text-xs font-semibold text-muted-accessible uppercase tracking-wider mb-1",children:"Complexity"}),e.jsx("div",{className:"text-base font-bold text-ink capitalize",children:t.complexity})]}),e.jsxs("div",{className:"card rounded-card p-3",children:[e.jsx("div",{className:"text-xs font-semibold text-muted-accessible uppercase tracking-wider mb-1",children:"Est. Cost"}),e.jsx("div",{className:"text-base font-bold text-ink",children:t.cost_estimate})]}),e.jsxs("div",{className:"card rounded-card p-3",children:[e.jsx("div",{className:"text-xs font-semibold text-muted-accessible uppercase tracking-wider mb-1",children:"Iterations"}),e.jsx("div",{className:"text-base font-bold text-ink",children:t.iterations})]}),e.jsxs("div",{className:"card rounded-card p-3",children:[e.jsx("div",{className:"text-xs font-semibold text-muted-accessible uppercase tracking-wider mb-1",children:"Phases"}),e.jsx("div",{className:"text-xs text-ink capitalize",children:t.phases.join(", ")})]})]}),t.output_text&&e.jsxs("details",{className:"mb-4",children:[e.jsx("summary",{className:"text-xs text-muted cursor-pointer hover:text-ink transition-colors",children:"Raw output"}),e.jsx("pre",{className:"mt-2 text-xs font-mono text-muted-accessible bg-black/5 rounded-card p-3 overflow-auto max-h-40 whitespace-pre-wrap",children:t.output_text})]}),e.jsxs("div",{className:"flex gap-3 justify-end",children:[e.jsx("button",{onClick:r,className:"px-4 py-2 text-sm font-medium text-muted hover:text-ink transition-colors",children:"Cancel"}),e.jsx("button",{onClick:n,className:"px-5 py-2 rounded-card text-sm font-semibold bg-primary text-white hover:bg-primary/90 transition-all shadow-button",children:"Start Build"})]})]}):e.jsx("div",{className:"text-sm text-muted py-4",children:"No plan data available."})]})})}function _e({onSubmit:t,running:s,error:n,provider:r,onProviderChange:a,initialPrd:c}){const[i,o]=l.useState(""),[m,b]=l.useState(""),[f,y]=l.useState("claude"),[d,g]=l.useState(""),j=r??f,[v,w]=l.useState(!1),[k,T]=l.useState([]),[x,E]=l.useState(!1),[N,M]=l.useState(!1),[P,A]=l.useState(!1),[z,_]=l.useState(null),[F,$]=l.useState(!1),[O,B]=l.useState(!1);l.useEffect(()=>{h.getTemplates().then(p=>{T(p),E(!1)}).catch(()=>{T([]),E(!0)})},[]),l.useEffect(()=>{c&&o(c)},[c]),l.useEffect(()=>{if(c)return;const p=localStorage.getItem("loki-prd-draft");p&&o(p),h.getPrdPrefill().then(({content:L})=>{L&&o(L)}).catch(()=>{})},[c]),l.useEffect(()=>{i.trim()?localStorage.setItem("loki-prd-draft",i):localStorage.removeItem("loki-prd-draft")},[i]);const R=l.useCallback(async(p,L)=>{b(L),w(!1);try{const G=await h.getTemplateContent(p);o(G.content)}catch{o(`# ${L}
|
|
2
2
|
|
|
3
3
|
## Overview
|
|
4
4
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{g as r,u as o,r as c,j as e}from"./index-
|
|
1
|
+
import{g as r,u as o,r as c,j as e}from"./index-pa3JgPvH.js";function x(){const{user:l,loading:t,login:i,isLocalMode:n}=r(),s=o();return c.useEffect(()=>{!t&&(l||n)&&s("/",{replace:!0})},[l,t,n,s]),t?e.jsx("div",{className:"h-screen bg-[#FAF9F6] flex items-center justify-center text-[#6B6960] text-sm",children:"Loading..."}):e.jsx("div",{className:"h-screen bg-[#FAF9F6] flex items-center justify-center",children:e.jsxs("div",{className:"w-full max-w-sm mx-auto px-6",children:[e.jsxs("div",{className:"text-center mb-8",children:[e.jsx("h1",{className:"font-heading text-3xl font-bold text-[#36342E] mb-1",children:"Purple Lab"}),e.jsx("p",{className:"text-sm text-[#6B6960]",children:"Autonomous agent workspace powered by Loki"})]}),e.jsxs("div",{className:"bg-white rounded-lg border border-[#ECEAE3] shadow-sm p-6 space-y-4",children:[e.jsx("h2",{className:"text-base font-medium text-[#36342E] text-center",children:"Sign in to continue"}),e.jsxs("button",{type:"button",onClick:()=>i("github"),className:"w-full flex items-center justify-center gap-2 px-4 py-2.5 rounded-[5px] border border-[#ECEAE3] bg-[#24292f] text-white text-sm font-medium hover:bg-[#1b1f23] transition-colors",children:[e.jsx("svg",{className:"w-5 h-5",fill:"currentColor",viewBox:"0 0 24 24",children:e.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M12 2C6.477 2 2 6.484 2 12.017c0 4.425 2.865 8.18 6.839 9.504.5.092.682-.217.682-.483 0-.237-.008-.868-.013-1.703-2.782.605-3.369-1.343-3.369-1.343-.454-1.158-1.11-1.466-1.11-1.466-.908-.62.069-.608.069-.608 1.003.07 1.531 1.032 1.531 1.032.892 1.53 2.341 1.088 2.91.832.092-.647.35-1.088.636-1.338-2.22-.253-4.555-1.113-4.555-4.951 0-1.093.39-1.988 1.029-2.688-.103-.253-.446-1.272.098-2.65 0 0 .84-.27 2.75 1.026A9.564 9.564 0 0112 6.844c.85.004 1.705.115 2.504.337 1.909-1.296 2.747-1.027 2.747-1.027.546 1.379.202 2.398.1 2.651.64.7 1.028 1.595 1.028 2.688 0 3.848-2.339 4.695-4.566 4.943.359.309.678.92.678 1.855 0 1.338-.012 2.419-.012 2.747 0 .268.18.58.688.482A10.019 10.019 0 0022 12.017C22 6.484 17.522 2 12 2z"})}),"Sign in with GitHub"]}),e.jsxs("button",{type:"button",onClick:()=>i("google"),className:"w-full flex items-center justify-center gap-2 px-4 py-2.5 rounded-[5px] border border-[#ECEAE3] bg-white text-[#36342E] text-sm font-medium hover:bg-[#F8F4F0] transition-colors",children:[e.jsxs("svg",{className:"w-5 h-5",viewBox:"0 0 24 24",children:[e.jsx("path",{fill:"#4285F4",d:"M22.56 12.25c0-.78-.07-1.53-.2-2.25H12v4.26h5.92a5.06 5.06 0 01-2.2 3.32v2.77h3.57c2.08-1.92 3.28-4.74 3.28-8.1z"}),e.jsx("path",{fill:"#34A853",d:"M12 23c2.97 0 5.46-.98 7.28-2.66l-3.57-2.77c-.98.66-2.23 1.06-3.71 1.06-2.86 0-5.29-1.93-6.16-4.53H2.18v2.84C3.99 20.53 7.7 23 12 23z"}),e.jsx("path",{fill:"#FBBC05",d:"M5.84 14.09c-.22-.66-.35-1.36-.35-2.09s.13-1.43.35-2.09V7.07H2.18C1.43 8.55 1 10.22 1 12s.43 3.45 1.18 4.93l2.85-2.22.81-.62z"}),e.jsx("path",{fill:"#EA4335",d:"M12 5.38c1.62 0 3.06.56 4.21 1.64l3.15-3.15C17.45 2.09 14.97 1 12 1 7.7 1 3.99 3.47 2.18 7.07l3.66 2.84c.87-2.6 3.3-4.53 6.16-4.53z"})]}),"Sign in with Google"]}),e.jsxs("div",{className:"relative",children:[e.jsx("div",{className:"absolute inset-0 flex items-center",children:e.jsx("div",{className:"w-full border-t border-[#ECEAE3]"})}),e.jsx("div",{className:"relative flex justify-center text-xs",children:e.jsx("span",{className:"bg-white px-2 text-[#939084]",children:"or"})})]}),e.jsx("button",{type:"button",onClick:()=>s("/"),className:"w-full text-center text-sm text-[#6B6960] hover:text-[#553DE9] transition-colors py-1",children:"Continue without account (local mode)"})]}),e.jsx("p",{className:"text-xs text-[#939084] text-center mt-4",children:"Local mode stores everything on your machine. Sign in for cloud sync and collaboration."})]})})}export{x as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as e,L as t,H as s}from"./index-
|
|
1
|
+
import{j as e,L as t,H as s}from"./index-pa3JgPvH.js";import{A as o}from"./arrow-left-BuMZs13c.js";function i(){return e.jsxs("div",{className:"flex flex-col items-center justify-center h-full min-h-[60vh] p-8 text-center",children:[e.jsx("div",{className:"text-6xl font-heading font-bold text-primary/20 mb-4",children:"404"}),e.jsx("h1",{className:"text-h3 font-heading font-bold text-ink mb-2",children:"Page not found"}),e.jsx("p",{className:"text-sm text-muted-accessible mb-6 max-w-xs",children:"The page you are looking for does not exist or has been moved."}),e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsxs("button",{onClick:()=>window.history.back(),className:"inline-flex items-center gap-1.5 px-4 py-2 text-xs font-medium rounded-btn border border-border text-secondary hover:bg-hover transition-colors",children:[e.jsx(o,{size:14}),"Go Back"]}),e.jsxs(t,{to:"/",className:"inline-flex items-center gap-1.5 px-4 py-2 text-xs font-medium rounded-btn bg-primary text-white hover:bg-[#4432c4] transition-colors shadow-button",children:[e.jsx(s,{size:14}),"Home"]})]})]})}export{i as default};
|