@hanzo/rooms 0.1.12 → 0.1.14

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/dist/Contents.js CHANGED
@@ -18,6 +18,9 @@ import { BAD } from './lib/mix.js';
18
18
  export function standing(f) {
19
19
  switch (f.status) {
20
20
  case 'ready':
21
+ // Ready means read; while its vectors fill in, search by meaning grows.
22
+ if (f.stage === 'embed' && f.passages)
23
+ return `Indexed · ${f.sections ?? 0} sections · vectors ${Math.floor(((f.embedded ?? 0) / f.passages) * 100)}%`;
21
24
  return `Indexed · ${f.sections ?? 0} sections`;
22
25
  case 'stored':
23
26
  return 'Kept, not indexed';
package/dist/Drive.js CHANGED
@@ -8,6 +8,7 @@ import { useAi } from './lib/ai.js';
8
8
  import { empty, useOpen } from './open.js';
9
9
  import { attach, channel } from './pane.js';
10
10
  import { useRooms } from './host.js';
11
+ import { org } from './lib/session.js';
11
12
  import { Badge, Contents, Hits } from './Contents.js';
12
13
  import { weigh as size } from './lib/attach.js';
13
14
  import { dropped, filesIn, forget, pool, register, search, settled, slug, upload, } from './lib/files.js';
@@ -120,7 +121,10 @@ export function Drive() {
120
121
  const workspace = currentOrg?.displayName || currentOrg?.name || 'hanzo';
121
122
  // THE WORKSPACE'S BUCKET is the one named for the org: where a file put into a
122
123
  // chat lands (lib/files `workspace`), so it is where Drive opens.
123
- const home = currentOrg?.name ? slug(currentOrg.name) : null;
124
+ // The org is the one the chat uploads under (`org()`), read the same way, so
125
+ // the bucket a chat file landed in is the bucket Drive opens.
126
+ const scope = org() ?? currentOrg?.name ?? null;
127
+ const home = scope ? slug(scope) : null;
124
128
  const [navSection, setNavSection] = useState('my-drive');
125
129
  const [viewMode, setViewMode] = useState('list');
126
130
  const [searchQuery, setSearchQuery] = useState('');
@@ -207,7 +211,7 @@ export function Drive() {
207
211
  if (!live)
208
212
  return;
209
213
  setIndex(new Map(list.map((f) => [f.key, f])));
210
- if (list.some((f) => !settled(f)))
214
+ if (list.some((f) => !settled(f) || f.stage === 'embed'))
211
215
  clock = setTimeout(pass, 4000);
212
216
  })
213
217
  .catch(() => { });
@@ -254,9 +258,9 @@ export function Drive() {
254
258
  if (!client)
255
259
  return;
256
260
  empty();
257
- attach(channel({ room, thread: null, agent: null }), [f], { api: client, org: currentOrg?.name ?? null });
261
+ attach(channel({ room, thread: null, agent: null }), [f], { api: client, org: scope });
258
262
  router.push('/chat');
259
- }, [client, room, currentOrg, router]);
263
+ }, [client, room, scope, router]);
260
264
  // WHAT IS AT THIS LEVEL. The store's listing takes `recursive`; passing
261
265
  // `delimiter` (S3's own word) is silently ignored, so a flat listing came
262
266
  // back and every folder read as a file.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hanzo/rooms",
3
- "version": "0.1.12",
3
+ "version": "0.1.14",
4
4
  "description": "The workspace rooms — Home, Chat, Inbox, Contacts, Meet, Cal, Drive, Board, Work, Bots — and the frame that holds them, once, for every Hanzo surface.",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -58,7 +58,7 @@
58
58
  "@hanzo/plans": ">=1.8.9",
59
59
  "@hanzo/ui": ">=8.27.51",
60
60
  "@hanzo/usage": ">=0.1.17",
61
- "@hanzo/voice": ">=0.1.11",
61
+ "@hanzo/voice": ">=0.1.12",
62
62
  "@hanzogui/shell": "^8.3.20",
63
63
  "lucide-react": ">=1.42.0",
64
64
  "react": ">=19.2.8",
@@ -77,7 +77,7 @@
77
77
  "@hanzo/plans": "1.8.9",
78
78
  "@hanzo/ui": "8.27.51",
79
79
  "@hanzo/usage": "0.1.17",
80
- "@hanzo/voice": "0.1.11",
80
+ "@hanzo/voice": "0.1.12",
81
81
  "@hanzogui/config": "8.3.5",
82
82
  "@hanzogui/core": "8.3.5",
83
83
  "@hanzogui/lucide-icons-2": "8.3.5",