wu981526092 commited on
Commit
dca7b5d
·
1 Parent(s): b79edb4

Fix session creation - all New buttons now switch to blank state instead of creating session

Browse files
frontend/src/pages/Playground.tsx CHANGED
@@ -67,7 +67,6 @@ export function Playground() {
67
  const {
68
  sessions,
69
  currentSessionId,
70
- createNewSession,
71
  selectSession,
72
  deleteSession,
73
  clearCurrentSession,
@@ -517,7 +516,7 @@ export function Playground() {
517
  {!sessionsCollapsed && <h2 className="font-semibold">Chat Sessions</h2>}
518
  <div className="flex gap-1">
519
  {!sessionsCollapsed && (
520
- <Button onClick={createNewSession} size="sm">
521
  <Plus className="h-4 w-4 mr-1" />
522
  New
523
  </Button>
@@ -535,7 +534,7 @@ export function Playground() {
535
  </div>
536
 
537
  {sessionsCollapsed && (
538
- <Button onClick={createNewSession} size="sm" variant="ghost" className="w-full p-2">
539
  <Plus className="h-4 w-4" />
540
  </Button>
541
  )}
 
67
  const {
68
  sessions,
69
  currentSessionId,
 
70
  selectSession,
71
  deleteSession,
72
  clearCurrentSession,
 
516
  {!sessionsCollapsed && <h2 className="font-semibold">Chat Sessions</h2>}
517
  <div className="flex gap-1">
518
  {!sessionsCollapsed && (
519
+ <Button onClick={clearCurrentSession} size="sm">
520
  <Plus className="h-4 w-4 mr-1" />
521
  New
522
  </Button>
 
534
  </div>
535
 
536
  {sessionsCollapsed && (
537
+ <Button onClick={clearCurrentSession} size="sm" variant="ghost" className="w-full p-2">
538
  <Plus className="h-4 w-4" />
539
  </Button>
540
  )}
static/assets/index-4f9f7431.js ADDED
The diff for this file is too large to render. See raw diff
 
static/assets/index-4f9f7431.js.map ADDED
The diff for this file is too large to render. See raw diff
 
static/index.html CHANGED
@@ -5,7 +5,7 @@
5
  <link rel="icon" type="image/svg+xml" href="/vite.svg" />
6
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
7
  <title>Edge LLM</title>
8
- <script type="module" crossorigin src="/assets/index-2cd7a1a6.js"></script>
9
  <link rel="stylesheet" href="/assets/index-5451caa1.css">
10
  </head>
11
  <body>
 
5
  <link rel="icon" type="image/svg+xml" href="/vite.svg" />
6
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
7
  <title>Edge LLM</title>
8
+ <script type="module" crossorigin src="/assets/index-4f9f7431.js"></script>
9
  <link rel="stylesheet" href="/assets/index-5451caa1.css">
10
  </head>
11
  <body>