claude-memory-admin 1.10.0 → 1.10.1

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "claude-memory-admin",
3
- "version": "1.10.0",
3
+ "version": "1.10.1",
4
4
  "description": "Browse, audit and prune the auto memory Claude Code keeps under ~/.claude/projects",
5
5
  "keywords": [
6
6
  "claude",
package/public/ui.mjs CHANGED
@@ -277,6 +277,8 @@ export const contextTags = 'mb-1 flex flex-wrap gap-1.5';
277
277
  export const contextFile = 'font-mono text-2xs break-words text-fg';
278
278
  export const contextSize = 'font-mono text-2xs whitespace-nowrap text-fg-subtle';
279
279
  export const contextRowButton = 'flex w-full cursor-pointer items-baseline justify-between gap-3.5 border-0 border-b border-line bg-transparent px-1 py-1.5 text-left transition-colors last:border-b-0 hover:bg-surface-sunken';
280
+ export const contextRowStatic = 'flex w-full items-baseline justify-between gap-3.5 border-0 border-b border-line px-1 py-1.5 text-left last:border-b-0';
281
+ export const toolMissingBody = 'mb-2.5 px-1';
280
282
  export const contextCaret = 'mr-1.5 inline-block font-mono text-2xs text-fg-subtle';
281
283
  export const contextBody = 'mb-1.5 max-h-[28rem] overflow-y-auto rounded-md border border-line bg-surface-sunken px-3.5 py-2.5';
282
284
 
@@ -41,7 +41,7 @@ function segmentVisible(tab, segment, store) {
41
41
  }
42
42
  if (segment === 'instructions') return global || hasProjectDir(store);
43
43
  if (segment === 'cost') return global;
44
- if (segment === 'tools') return state.tools.some((tool) => tool.found);
44
+ if (segment === 'tools') return state.tools.length > 0;
45
45
  if (global) return false;
46
46
  if (segment === 'sessions') return Boolean(store.sessions?.count);
47
47
  return true;
@@ -15,6 +15,7 @@ const PANELS = {
15
15
  };
16
16
 
17
17
  const installed = () => state.tools.filter((tool) => tool.found && PANELS[tool.id]);
18
+ const missing = () => state.tools.filter((tool) => !tool.found && PANELS[tool.id]);
18
19
 
19
20
  const openKey = (id) => `toolOpen:${id}`;
20
21
  const isOpen = (id) => localStorage.getItem(openKey(id)) === '1';
@@ -126,19 +127,46 @@ function accordion(container, tool, slot) {
126
127
  container.append(panel);
127
128
  }
128
129
 
130
+ function notInstalled(container, tool) {
131
+ container.append(node('div', { class: ui.contextRowStatic }, [
132
+ node('div', { class: ui.contextMain }, [
133
+ node('div', { class: ui.contextFile, text: tool.label }),
134
+ ]),
135
+ node('div', { class: ui.contextSize, text: 'not installed' }),
136
+ ]));
137
+
138
+ container.append(node('div', { class: ui.toolMissingBody }, [
139
+ node('p', { class: ui.noteTight, text: tool.blurb }),
140
+ node('a', {
141
+ class: ui.linkButton,
142
+ href: tool.repo,
143
+ target: '_blank',
144
+ rel: 'noopener noreferrer',
145
+ text: 'View on GitHub \u2197',
146
+ }),
147
+ ]));
148
+ }
149
+
129
150
  export function renderTools(container) {
130
- const tools = installed();
131
- if (!tools.length) return;
151
+ const found = installed();
152
+ const absent = missing();
153
+ if (!found.length && !absent.length) return;
132
154
 
133
- if (!state.aux.tools && localStorage.getItem(OPT_IN) === '1') start({ remember: false });
134
- if (!state.aux.tools) return gate(container, tools);
155
+ if (found.length && !state.aux.tools && localStorage.getItem(OPT_IN) === '1') start({ remember: false });
156
+ const opted = Boolean(state.aux.tools);
135
157
 
136
- container.append(node('div', { class: ui.listBar }, [
158
+ const bar = [
137
159
  node('span', { class: ui.sectionLabelInline, text: 'Companion tools' }),
138
160
  node('span', { class: ui.listSpacer }),
139
- node('button', { class: ui.buttonSmall, text: 'Re-read', onclick: readAll }),
140
- node('button', { class: ui.buttonSmall, text: 'Turn off', onclick: turnOff }),
141
- ]));
161
+ ];
162
+ if (found.length && opted) {
163
+ bar.push(node('button', { class: ui.buttonSmall, text: 'Re-read', onclick: readAll }));
164
+ bar.push(node('button', { class: ui.buttonSmall, text: 'Turn off', onclick: turnOff }));
165
+ }
166
+ container.append(node('div', { class: ui.listBar }, bar));
167
+
168
+ if (found.length && !opted) gate(container, found);
169
+ else for (const tool of found) accordion(container, tool, state.aux.tools[tool.id]);
142
170
 
143
- for (const tool of tools) accordion(container, tool, state.aux.tools[tool.id]);
171
+ for (const tool of absent) notInstalled(container, tool);
144
172
  }