@hanzo/app 0.2.13 → 0.2.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/Drive.js +2 -2
- package/dist/Orgs.js +1 -1
- package/dist/Palette.js +3 -3
- package/dist/RightPane.d.ts +1 -1
- package/dist/RightPane.js +2 -2
- package/dist/Shell.js +1 -1
- package/dist/bots/api.js +1 -1
- package/dist/lib/home.js +1 -1
- package/dist/lib/todo.js +1 -1
- package/package.json +1 -1
package/dist/Drive.js
CHANGED
|
@@ -153,14 +153,14 @@ export function Drive() {
|
|
|
153
153
|
const fileInputRef = useRef(null);
|
|
154
154
|
const folderInputRef = useRef(null);
|
|
155
155
|
const dragCounter = useRef(0);
|
|
156
|
-
// PROJECTS are the org's own, from the platform. `/v1/
|
|
156
|
+
// PROJECTS are the org's own, from the platform. `/v1/project` answers every
|
|
157
157
|
// project this org owns; nothing stands in for it when it answers nothing.
|
|
158
158
|
useEffect(() => {
|
|
159
159
|
if (!ready || !client)
|
|
160
160
|
return;
|
|
161
161
|
let live = true;
|
|
162
162
|
client.http
|
|
163
|
-
.json({ path: '/v1/
|
|
163
|
+
.json({ path: '/v1/project' })
|
|
164
164
|
.then((ps) => live && setProjects(Array.isArray(ps) ? ps : []))
|
|
165
165
|
.catch(() => live && setProjects([]));
|
|
166
166
|
return () => {
|
package/dist/Orgs.js
CHANGED
|
@@ -176,7 +176,7 @@ export function Orgs({ children, front = false, forward, signup = false, }) {
|
|
|
176
176
|
if (!slug)
|
|
177
177
|
return;
|
|
178
178
|
client.http
|
|
179
|
-
.json({ method: 'POST', path: '/v1/
|
|
179
|
+
.json({ method: 'POST', path: '/v1/project/fork', body: { slug } })
|
|
180
180
|
.then((made) => {
|
|
181
181
|
if (made?.id)
|
|
182
182
|
window.location.assign(dev());
|
package/dist/Palette.js
CHANGED
|
@@ -23,7 +23,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
23
23
|
// here as the reader types: the conversations store (hanzoai/agent) answers its
|
|
24
24
|
// whole list and searches nothing, titles or words, so a title is all there is
|
|
25
25
|
// to find a chat by. The chats are the sidebar's last read (thread.tsx
|
|
26
|
-
// `useThreadList`), drawn at once; the projects (`/v1/
|
|
26
|
+
// `useThreadList`), drawn at once; the projects (`/v1/project`), the active
|
|
27
27
|
// skills (`/v1/tool/skills?activated=true`), the connectors
|
|
28
28
|
// (`/v1/tool/mcp/servers`) and the agents (crew.tsx) arrive while the reader
|
|
29
29
|
// types, and a read the palette closes on is aborted.
|
|
@@ -164,7 +164,7 @@ function useRead(path, shape) {
|
|
|
164
164
|
const obj = (v) => (v && typeof v === 'object' ? v : {});
|
|
165
165
|
const str = (v) => (typeof v === 'string' ? v : '');
|
|
166
166
|
const list = (v) => (Array.isArray(v) ? v : []);
|
|
167
|
-
/** `/v1/
|
|
167
|
+
/** `/v1/project`: a project by its slug, found by its name, slug and repository. */
|
|
168
168
|
/**
|
|
169
169
|
* The builder as a frame without it holds it (hanzo.team's Shell): nobody signed
|
|
170
170
|
* in to it, so `useSessions` reads no runs. The hook reads `api`, `token`, `org`
|
|
@@ -191,7 +191,7 @@ export function Palette({ onClose, go, actions: frame = [], mode = 'chat', host,
|
|
|
191
191
|
const [keys, setKeys] = useState(false);
|
|
192
192
|
const { threads } = useThreadList();
|
|
193
193
|
const { agents } = useCrew();
|
|
194
|
-
const repos = useRead('/v1/
|
|
194
|
+
const repos = useRead('/v1/project', projects);
|
|
195
195
|
const known = useRead('/v1/tool/skills?activated=true', skills);
|
|
196
196
|
const plugged = useRead('/v1/tool/mcp/servers', connectors);
|
|
197
197
|
const signOut = useSignOut();
|
package/dist/RightPane.d.ts
CHANGED
|
@@ -45,7 +45,7 @@ export declare function useSections({ at, said, held, deck, onCreate }: {
|
|
|
45
45
|
onCreate: () => void;
|
|
46
46
|
}): Section[];
|
|
47
47
|
/**
|
|
48
|
-
* The organization's sites, as an empty tab suggests them: `GET /v1/
|
|
48
|
+
* The organization's sites, as an empty tab suggests them: `GET /v1/project`,
|
|
49
49
|
* every row with a live address. Read once a conversation; nothing on a refusal.
|
|
50
50
|
*/
|
|
51
51
|
export declare function useSites(): {
|
package/dist/RightPane.js
CHANGED
|
@@ -223,7 +223,7 @@ export function useSections({ at, said, held, deck, onCreate }) {
|
|
|
223
223
|
}, [at, made, took, done, deck, ai, onCreate, t]);
|
|
224
224
|
}
|
|
225
225
|
/**
|
|
226
|
-
* The organization's sites, as an empty tab suggests them: `GET /v1/
|
|
226
|
+
* The organization's sites, as an empty tab suggests them: `GET /v1/project`,
|
|
227
227
|
* every row with a live address. Read once a conversation; nothing on a refusal.
|
|
228
228
|
*/
|
|
229
229
|
export function useSites() {
|
|
@@ -232,7 +232,7 @@ export function useSites() {
|
|
|
232
232
|
const [rows, setRows] = useState([]);
|
|
233
233
|
useEffect(() => {
|
|
234
234
|
const stop = new AbortController();
|
|
235
|
-
fetch(`${api()}/v1/
|
|
235
|
+
fetch(`${api()}/v1/project`, { headers: scope(), signal: stop.signal })
|
|
236
236
|
.then((r) => (r.ok ? r.json() : null))
|
|
237
237
|
.then((body) => {
|
|
238
238
|
if (stop.signal.aborted)
|
package/dist/Shell.js
CHANGED
|
@@ -490,7 +490,7 @@ function Projects({ filter, onPick, }) {
|
|
|
490
490
|
let live = true;
|
|
491
491
|
setWrong(null);
|
|
492
492
|
client.http
|
|
493
|
-
.json({ path: "/v1/
|
|
493
|
+
.json({ path: "/v1/project" })
|
|
494
494
|
.then((found) => live && setRows(Array.isArray(found) ? found : []))
|
|
495
495
|
.catch((e) => {
|
|
496
496
|
if (!live)
|
package/dist/bots/api.js
CHANGED
|
@@ -69,7 +69,7 @@ export const tools = (c) => rpc(c, 'tools/list').then((r) => r.tools ?? []);
|
|
|
69
69
|
export const call = (c, name, op, input = {}) => rpc(c, 'tools/call', { name, arguments: { op, input } }).then((r) => (r.content ?? []).map((p) => p.text ?? '').join('\n'));
|
|
70
70
|
/** Starts one autonomous coding run against a repo in the caller's org. */
|
|
71
71
|
export const workOn = (c, params) => c.http.json({ method: 'POST', path: '/v1/agents/coding', body: params });
|
|
72
|
-
export const projects = (c, signal) => c.http.json({ path: '/v1/
|
|
72
|
+
export const projects = (c, signal) => c.http.json({ path: '/v1/project', signal });
|
|
73
73
|
export const secrets = (c, path, signal) => c.http.collection('secrets', { path: '/v1/kms/secrets', query: { path }, signal });
|
|
74
74
|
export const connectors = (c, signal) => c.http.collection('connectors', { path: '/v1/integrations/connectors', signal });
|
|
75
75
|
export const grant = (c, id, kind) => c.http.json({ method: 'POST', path: `/v1/sandbox/${encodeURIComponent(id)}/${kind}/ticket` });
|
package/dist/lib/home.js
CHANGED
|
@@ -38,7 +38,7 @@ import { settings } from './host.js';
|
|
|
38
38
|
export const invite = () => site(settings('members'));
|
|
39
39
|
/** The org's projects, newest first. */
|
|
40
40
|
export async function projects(client, signal) {
|
|
41
|
-
const rows = await client.http.json({ path: '/v1/
|
|
41
|
+
const rows = await client.http.json({ path: '/v1/project', signal });
|
|
42
42
|
if (!Array.isArray(rows))
|
|
43
43
|
return [];
|
|
44
44
|
return [...rows].sort((a, b) => (b.updatedAt ?? 0) - (a.updatedAt ?? 0));
|
package/dist/lib/todo.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hanzo/app",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.14",
|
|
4
4
|
"description": "Hanzo's app: the shell and its apps (Home, Chat, Inbox, Contacts, Meet, Calendar, Drive, Board, Work, Bots), once, for every Hanzo surface.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|