echoes-vault-opencode 1.0.23 → 1.0.25

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/tui.tsx +19 -6
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "echoes-vault-opencode",
3
- "version": "1.0.23",
3
+ "version": "1.0.25",
4
4
  "description": "EchoesVault — persistent memory plugin for OpenCode. Obsidian-style knowledge base with daily logs, encyclopedia pages, and session resumption.",
5
5
  "type": "module",
6
6
  "main": "index.ts",
package/tui.tsx CHANGED
@@ -12,21 +12,27 @@ const KV = "echoes_vault"
12
12
  let vault: VaultState = { initialized: true, sessionActive: true, pagesCount: 15, lastSession: "2026-07-03" } // Заглушка для теста визуала
13
13
 
14
14
  const tui: TuiPlugin = async (api) => {
15
+ // Инициализацию событий пока оставляем, она написана логично
15
16
  try {
16
17
  const saved = api.kv.get<VaultState>(KV)
17
18
  if (saved) vault = saved
19
+
18
20
  function save() {
19
21
  try { api.kv.set(KV, vault) } catch {}
20
22
  }
23
+
21
24
  api.event.on("session.created", () => {
22
25
  vault.sessionActive = true
23
26
  vault.lastSession = new Date().toISOString().slice(0, 10)
24
27
  save()
25
28
  })
29
+
30
+ // ... остальные события ...
26
31
  } catch (error) {
27
32
  console.error("[echoes-vault] event init failed:", error)
28
33
  }
29
34
 
35
+ // Отрисовка UI
30
36
  api.slots.register({
31
37
  slots: {
32
38
  sidebar_content({ session_id }: { session_id: string }) {
@@ -37,24 +43,31 @@ const tui: TuiPlugin = async (api) => {
37
43
 
38
44
  return (
39
45
  <box flexDirection="column" paddingBottom={1}>
46
+
47
+ {/* Блок 1: Статус хранилища */}
40
48
  <box flexDirection="column" paddingBottom={1}>
49
+ {/* Заголовок (белый, жирный) */}
41
50
  <text bold>EchoesVault</text>
42
51
 
43
- <text color={active ? "success" : "error"}>
52
+ {/* Бледный текст статуса */}
53
+ <text color={active ? "#4caf50" : "gray"}>
44
54
  • {active ? `Active (${title})` : "Disconnected"}
45
55
  </text>
46
- <text color="textMuted">
56
+ <text color="gray">
47
57
  • {count} pages indexed
48
58
  </text>
49
59
  </box>
60
+
61
+ {/* Блок 2: Легенда команд (вместо неработающих кнопок) */}
50
62
  <box flexDirection="column">
51
63
  <text bold>Commands</text>
52
64
 
53
- <text color="textMuted"> /echoes-init (Init vault)</text>
54
- <text color="textMuted"> /echoes-start (Start session)</text>
55
- <text color="textMuted"> /echoes-end (End session)</text>
56
- <text color="textMuted"> /echoes-status (Show status)</text>
65
+ <text color="gray"> /echoes-init (Init vault)</text>
66
+ <text color="gray"> /echoes-start (Start session)</text>
67
+ <text color="gray"> /echoes-end (End session)</text>
68
+ <text color="gray"> /echoes-status (Show status)</text>
57
69
  </box>
70
+
58
71
  </box>
59
72
  )
60
73
  },