copilotz 1.0.0-rc.50 → 1.0.0-rc.51
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/AGENTS.md +4 -4
- package/CHANGELOG.md +11 -0
- package/README.md +2 -2
- package/hosts/web/toolkit/waveform.d.ts +3 -1
- package/hosts/web/toolkit/waveform.js +5 -2
- package/package.json +1 -1
- package/plugins/agents/chat/views/web/composer.d.ts +14 -1
- package/plugins/agents/chat/views/web/composer.js +31 -11
- package/plugins/compute/computers/program/version.d.ts +1 -1
- package/plugins/compute/computers/program/version.js +1 -1
- package/plugins/compute/computers/program/workloads/search.d.ts +1 -1
- package/plugins/compute/computers/resources/downloads.js +1 -1
package/AGENTS.md
CHANGED
|
@@ -4,7 +4,7 @@ A guide for coding agents (Claude Code, Codex, Cursor, Gemini) building an app w
|
|
|
4
4
|
it whole before you write code. The last section is for work on Copilotz itself.
|
|
5
5
|
|
|
6
6
|
It ships in the package (`node_modules/copilotz/AGENTS.md`, and `@copilotz/copilotz` on JSR) and
|
|
7
|
-
goes with `copilotz@1.0.0-rc.
|
|
7
|
+
goes with `copilotz@1.0.0-rc.51`. Every docs page is Markdown at
|
|
8
8
|
`https://copilotz.com/docs/<slug>.md`, and https://copilotz.com/llms.txt lists them all. When you're
|
|
9
9
|
unsure of a name, fetch its page or read the package's types (`node_modules/copilotz/**/*.d.ts`).
|
|
10
10
|
Don't guess.
|
|
@@ -64,12 +64,12 @@ There's no project generator. Set a project up as the docs' courses do, on Node
|
|
|
64
64
|
```sh
|
|
65
65
|
mkdir my-app && cd my-app
|
|
66
66
|
npm init -y && npm pkg set type=module
|
|
67
|
-
npm install copilotz@1.0.0-rc.
|
|
67
|
+
npm install copilotz@1.0.0-rc.51 react@19 react-dom@19
|
|
68
68
|
npm install -D typescript @types/node @types/react @types/react-dom esbuild
|
|
69
69
|
```
|
|
70
70
|
|
|
71
71
|
Pin the version: npm's `latest` tag still points at an early release candidate. On Deno, run
|
|
72
|
-
`deno add jsr:@copilotz/copilotz` and map `"copilotz": "jsr:@copilotz/copilotz@^1.0.0-rc.
|
|
72
|
+
`deno add jsr:@copilotz/copilotz` and map `"copilotz": "jsr:@copilotz/copilotz@^1.0.0-rc.51"` in
|
|
73
73
|
`deno.json`, so imports read the same.
|
|
74
74
|
|
|
75
75
|
Node runs `.ts` files as they are, so there's no build step. It doesn't run `.tsx`: tests that load
|
|
@@ -108,7 +108,7 @@ line `@AGENTS.md` (Claude Code reads `CLAUDE.md`, and follows the import). Keep
|
|
|
108
108
|
```markdown
|
|
109
109
|
# AGENTS.md
|
|
110
110
|
|
|
111
|
-
This app runs on Copilotz (copilotz@1.0.0-rc.
|
|
111
|
+
This app runs on Copilotz (copilotz@1.0.0-rc.51). Read node_modules/copilotz/AGENTS.md first;
|
|
112
112
|
https://copilotz.com/llms.txt lists the docs, as Markdown.
|
|
113
113
|
|
|
114
114
|
- `npm test` runs every test offline, with a scripted model: run it after each change.
|
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,14 @@
|
|
|
1
|
+
## 1.0.0-rc.51 — 2026-11-16
|
|
2
|
+
|
|
3
|
+
**Phones.**
|
|
4
|
+
|
|
5
|
+
- **A voice message records on an iPhone.** The live waveform's bars are scaled to their level, not
|
|
6
|
+
animated. Safari on iOS kept memory for every transition the bars started, many times a second,
|
|
7
|
+
until iOS closed the page, within a minute of recording, and the recording with it.
|
|
8
|
+
- **On a touch screen, Enter starts a new line in chat's composer**, as the keyboard's return key
|
|
9
|
+
says, and the Send button sends (so does Enter with ⌘ or Ctrl, from a keyboard attached to it). On
|
|
10
|
+
a computer, Enter still sends, and the hint about the keys shows only there.
|
|
11
|
+
|
|
1
12
|
## 1.0.0-rc.50 — 2026-11-15
|
|
2
13
|
|
|
3
14
|
What rebuilding real systems on rc.49 asked of Copilotz: a retail point of sale (Open Source Point
|
package/README.md
CHANGED
|
@@ -152,7 +152,7 @@ ana sees: Tue 10:00, Wed 15:00
|
|
|
152
152
|
```sh
|
|
153
153
|
npm install copilotz@next # Node 24+ (npm, pnpm, yarn)
|
|
154
154
|
bun add copilotz@next # Bun
|
|
155
|
-
deno add jsr:@copilotz/copilotz@^1.0.0-rc.
|
|
155
|
+
deno add jsr:@copilotz/copilotz@^1.0.0-rc.51 # Deno 2.9+ (or `deno add npm:copilotz@next`)
|
|
156
156
|
```
|
|
157
157
|
|
|
158
158
|
Until 1.0, the release candidates are on npm's `next` tag, and a plain `npm install copilotz` or
|
|
@@ -166,7 +166,7 @@ OPENAI_API_KEY=sk-… node salon.ts # or bun salon.ts, or deno run -A salon.t
|
|
|
166
166
|
```
|
|
167
167
|
|
|
168
168
|
On Deno, map the name `copilotz` in `deno.json`
|
|
169
|
-
(`"copilotz": "jsr:@copilotz/copilotz@^1.0.0-rc.
|
|
169
|
+
(`"copilotz": "jsr:@copilotz/copilotz@^1.0.0-rc.51"`) so the imports read the same everywhere.
|
|
170
170
|
Copilotz runs on Node 24+, Deno 2.9+ and Bun, and it's built on web standards for Cloudflare Workers
|
|
171
171
|
and the browser.
|
|
172
172
|
|
|
@@ -7,7 +7,9 @@
|
|
|
7
7
|
* position as a slider: a click or a drag seeks, and so do the arrow keys
|
|
8
8
|
* (by `step`), Page Up and Down, Home and End. `live` draws levels as they
|
|
9
9
|
* come instead, unscaled, the newest at the end and the oldest falling off
|
|
10
|
-
* the start.
|
|
10
|
+
* the start. Its bars are scaled, never animated: they change many times a
|
|
11
|
+
* second, and a CSS transition started that often grows Safari's memory
|
|
12
|
+
* until iOS closes the page (an iPhone, recording for half a minute).
|
|
11
13
|
*
|
|
12
14
|
* ```tsx
|
|
13
15
|
* <Waveform peaks={peaks} progress={0.4} onSeek={seek} label="Position" valueText="0:04 of 0:10" />
|
|
@@ -8,7 +8,9 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
8
8
|
* position as a slider: a click or a drag seeks, and so do the arrow keys
|
|
9
9
|
* (by `step`), Page Up and Down, Home and End. `live` draws levels as they
|
|
10
10
|
* come instead, unscaled, the newest at the end and the oldest falling off
|
|
11
|
-
* the start.
|
|
11
|
+
* the start. Its bars are scaled, never animated: they change many times a
|
|
12
|
+
* second, and a CSS transition started that often grows Safari's memory
|
|
13
|
+
* until iOS closes the page (an iPhone, recording for half a minute).
|
|
12
14
|
*
|
|
13
15
|
* ```tsx
|
|
14
16
|
* <Waveform peaks={peaks} progress={0.4} onSeek={seek} label="Position" valueText="0:04 of 0:10" />
|
|
@@ -28,7 +30,8 @@ const SHEET = sheet("waveform", `
|
|
|
28
30
|
.copilotz-waveform-seek:focus-visible { outline-offset: 4px; }
|
|
29
31
|
.copilotz-waveform[aria-disabled=true] { cursor: default; }
|
|
30
32
|
.copilotz-waveform-live { justify-content: flex-end; gap: 2px; overflow: hidden; }
|
|
31
|
-
.copilotz-waveform-live i { flex: none; width: 3px;
|
|
33
|
+
.copilotz-waveform-live i { flex: none; width: 3px; height: 100%; transform: scaleY(var(--level)); opacity: .9;
|
|
34
|
+
transition: none; }
|
|
32
35
|
.copilotz-waveform-live i.copilotz-waveform-idle { opacity: .22; }
|
|
33
36
|
`);
|
|
34
37
|
/** How tall a bar is at least, of the waveform's height, so silence still shows. */
|
package/package.json
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Where you type. Enter sends, Shift+Enter starts a new line, Escape stops
|
|
3
|
-
* the agents working
|
|
3
|
+
* the agents working; on a touch screen, Enter starts a new line and the
|
|
4
|
+
* Send button sends (`sends`). It grows with what you write, and takes files from the
|
|
4
5
|
* clip, a paste or a drop, and a voice message from the microphone: recorded
|
|
5
6
|
* here, listened back, then sent, with words or without. Audio is
|
|
6
7
|
* transcribed as it's sent, which says so; if that fails, nothing went, and
|
|
@@ -53,6 +54,18 @@ export type Mentioned = {
|
|
|
53
54
|
agents: Mentionable[];
|
|
54
55
|
clear(): void;
|
|
55
56
|
};
|
|
57
|
+
/**
|
|
58
|
+
* Whether a key sends what's typed. On a computer (`fine`), Enter does, and
|
|
59
|
+
* Shift+Enter starts a new line. On a touch screen, Enter starts a new line,
|
|
60
|
+
* as its keyboard's return key says, and the Send button sends; so does
|
|
61
|
+
* Enter with ⌘ or Ctrl, from a keyboard attached to it.
|
|
62
|
+
*/
|
|
63
|
+
export declare const sends: (key: {
|
|
64
|
+
key: string;
|
|
65
|
+
shiftKey: boolean;
|
|
66
|
+
metaKey: boolean;
|
|
67
|
+
ctrlKey: boolean;
|
|
68
|
+
}, fine: boolean) => boolean;
|
|
56
69
|
export declare function Composer(props: {
|
|
57
70
|
/**
|
|
58
71
|
* Uploads a file to send (`chat.attach`), on its own: each as it's chosen,
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
2
|
/**
|
|
3
3
|
* Where you type. Enter sends, Shift+Enter starts a new line, Escape stops
|
|
4
|
-
* the agents working
|
|
4
|
+
* the agents working; on a touch screen, Enter starts a new line and the
|
|
5
|
+
* Send button sends (`sends`). It grows with what you write, and takes files from the
|
|
5
6
|
* clip, a paste or a drop, and a voice message from the microphone: recorded
|
|
6
7
|
* here, listened back, then sent, with words or without. Audio is
|
|
7
8
|
* transcribed as it's sent, which says so; if that fails, nothing went, and
|
|
@@ -44,6 +45,23 @@ const none = () => undefined;
|
|
|
44
45
|
const audio = (type) => type.startsWith("audio/");
|
|
45
46
|
/** Why transcribing failed, without what the notice already says. */
|
|
46
47
|
const reason = (error) => message(error).replace(/^Couldn't transcribe [^:]*:\s*/, "");
|
|
48
|
+
/** A mouse or a trackpad: a computer, whose keyboard sends with Enter. */
|
|
49
|
+
const FINE = "(pointer: fine)";
|
|
50
|
+
const pointer = {
|
|
51
|
+
subscribe(changed) {
|
|
52
|
+
const query = matchMedia(FINE);
|
|
53
|
+
query.addEventListener("change", changed);
|
|
54
|
+
return () => query.removeEventListener("change", changed);
|
|
55
|
+
},
|
|
56
|
+
fine: () => matchMedia(FINE).matches,
|
|
57
|
+
};
|
|
58
|
+
/**
|
|
59
|
+
* Whether a key sends what's typed. On a computer (`fine`), Enter does, and
|
|
60
|
+
* Shift+Enter starts a new line. On a touch screen, Enter starts a new line,
|
|
61
|
+
* as its keyboard's return key says, and the Send button sends; so does
|
|
62
|
+
* Enter with ⌘ or Ctrl, from a keyboard attached to it.
|
|
63
|
+
*/
|
|
64
|
+
export const sends = (key, fine) => key.key === "Enter" && !key.shiftKey && (fine || key.metaKey || key.ctrlKey);
|
|
47
65
|
export function Composer(props) {
|
|
48
66
|
const [text, setText] = useState(props.initial ?? "");
|
|
49
67
|
const [files, setFiles] = useState([]);
|
|
@@ -77,13 +95,13 @@ export function Composer(props) {
|
|
|
77
95
|
const notes = Object.values(props.notes ?? {})
|
|
78
96
|
.filter((note) => !!note?.view)
|
|
79
97
|
.sort((a, b) => (a.order ?? 0) - (b.order ?? 0));
|
|
80
|
-
const fine = () =>
|
|
98
|
+
const fine = useSyncExternalStore(pointer.subscribe, pointer.fine, () => true);
|
|
81
99
|
// Ready to type after what's there, where there's a keyboard (on a phone, it waits for a tap).
|
|
82
100
|
useEffect(() => {
|
|
83
101
|
const take = typeof props.autoFocus === "function"
|
|
84
102
|
? props.autoFocus()
|
|
85
103
|
: props.autoFocus ?? true;
|
|
86
|
-
if (fine
|
|
104
|
+
if (fine && take) {
|
|
87
105
|
area.current?.focus();
|
|
88
106
|
area.current?.setSelectionRange(text.length, text.length);
|
|
89
107
|
}
|
|
@@ -159,7 +177,7 @@ export function Composer(props) {
|
|
|
159
177
|
}
|
|
160
178
|
return uploaded;
|
|
161
179
|
};
|
|
162
|
-
const typeOn = () => requestAnimationFrame(() => fine
|
|
180
|
+
const typeOn = () => requestAnimationFrame(() => fine && area.current?.focus());
|
|
163
181
|
const remove = (gone) => {
|
|
164
182
|
if (gone.preview)
|
|
165
183
|
URL.revokeObjectURL(gone.preview);
|
|
@@ -176,7 +194,7 @@ export function Composer(props) {
|
|
|
176
194
|
const dropRecording = () => {
|
|
177
195
|
setRecorder(undefined);
|
|
178
196
|
setFailed(undefined);
|
|
179
|
-
requestAnimationFrame(() => fine
|
|
197
|
+
requestAnimationFrame(() => fine ? area.current?.focus() : mic.current?.querySelector("button")?.focus());
|
|
180
198
|
};
|
|
181
199
|
const uploading = files.some((f) => !f.uploaded && !f.error);
|
|
182
200
|
const blocked = !!sending || uploading || files.some((f) => f.error);
|
|
@@ -337,7 +355,7 @@ export function Composer(props) {
|
|
|
337
355
|
return setClosed(typing.start);
|
|
338
356
|
}
|
|
339
357
|
}
|
|
340
|
-
if (event
|
|
358
|
+
if (sends(event, fine) && !event.nativeEvent.isComposing) {
|
|
341
359
|
event.preventDefault();
|
|
342
360
|
void submit();
|
|
343
361
|
}
|
|
@@ -396,7 +414,7 @@ export function Composer(props) {
|
|
|
396
414
|
(f.uploaded ? size(f.size) : f.read ? say("uploading") : say("reading")) })] }), _jsx(IconButton, { icon: "close", size: "sm", label: say("remove", { name: f.name }), onClick: () => remove(f), disabled: !!sending })] }, f.id))) }))
|
|
397
415
|
: null, recording
|
|
398
416
|
? (_jsx(Recorder, { state: recording, busy: !!sending, focus: true, onStop: () => void recorder?.stop(), onSend: () => void submit(), onDelete: dropRecording, onRestart: startRecording }))
|
|
399
|
-
: null, _jsxs("div", { className: "chat-box-text", hidden: live, children: [_jsx("label", { className: "copilotz-sr", htmlFor: id, children: say("message") }), _jsx(Textarea, { id: id, ref: area, rows: 1, bare: true, autoGrow: true, className: "chat-input", value: text, placeholder: take ? say("addMessage") : props.placeholder ?? say("message"), enterKeyHint: "send", readOnly: !!sending, "aria-autocomplete": props.agents?.length ? "list" : undefined, "aria-controls": props.agents?.length ? list : undefined, "aria-activedescendant": listing ? optionId(list, active) : undefined, onChange: (event) => {
|
|
417
|
+
: null, _jsxs("div", { className: "chat-box-text", hidden: live, children: [_jsx("label", { className: "copilotz-sr", htmlFor: id, children: say("message") }), _jsx(Textarea, { id: id, ref: area, rows: 1, bare: true, autoGrow: true, className: "chat-input", value: text, placeholder: take ? say("addMessage") : props.placeholder ?? say("message"), enterKeyHint: fine ? "send" : "enter", readOnly: !!sending, "aria-autocomplete": props.agents?.length ? "list" : undefined, "aria-controls": props.agents?.length ? list : undefined, "aria-activedescendant": listing ? optionId(list, active) : undefined, onChange: (event) => {
|
|
400
418
|
setText(event.target.value);
|
|
401
419
|
setCaret(event.target.selectionStart);
|
|
402
420
|
setRefused(undefined);
|
|
@@ -419,8 +437,10 @@ export function Composer(props) {
|
|
|
419
437
|
area.current?.setSelectionRange(s.length, s.length);
|
|
420
438
|
});
|
|
421
439
|
}, children: s }) }, s))) }))
|
|
422
|
-
: null, _jsxs("p", { className: "chat-hint", children: [props.note,
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
440
|
+
: null, _jsxs("p", { className: "chat-hint", children: [props.note, fine
|
|
441
|
+
? (_jsx("span", { className: "chat-keys", children: say.nodes("keysHint", {
|
|
442
|
+
enter: _jsx(Kbd, { children: say("keyEnter") }),
|
|
443
|
+
shift: _jsx(Kbd, { children: say("keyShift") }),
|
|
444
|
+
}) }))
|
|
445
|
+
: null] })] }) }));
|
|
426
446
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/** The computer program's version, as `computer.info` and `--version` say it, and its builds are named. */
|
|
2
|
-
export declare const VERSION = "1.0.0-rc.
|
|
2
|
+
export declare const VERSION = "1.0.0-rc.51";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/** The computer program's version, as `computer.info` and `--version` say it, and its builds are named. */
|
|
2
|
-
export const VERSION = "1.0.0-rc.
|
|
2
|
+
export const VERSION = "1.0.0-rc.51";
|
|
@@ -10,7 +10,7 @@ export type BrowserSearch = (input: SearchInput & {
|
|
|
10
10
|
blocked: boolean;
|
|
11
11
|
}>;
|
|
12
12
|
/** Who the fetch says it is: itself, not a browser it isn't. */
|
|
13
|
-
export declare const AGENT = "copilotz-computer/1.0.0-rc.
|
|
13
|
+
export declare const AGENT = "copilotz-computer/1.0.0-rc.51";
|
|
14
14
|
/** The results in a DuckDuckGo HTML page, in order. */
|
|
15
15
|
export declare function parseResults(html: string, base?: string): SearchResult[];
|
|
16
16
|
/** Whether a page is DuckDuckGo turning a robot away. */
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
*
|
|
15
15
|
* ```ts
|
|
16
16
|
* plugins: [...plugins, await computerDownloads()]
|
|
17
|
-
* plugins: [...plugins, await computerDownloads({ dir: "dist/computer/1.0.0-rc.
|
|
17
|
+
* plugins: [...plugins, await computerDownloads({ dir: "dist/computer/1.0.0-rc.51" })]
|
|
18
18
|
* plugins: [...plugins, await computerDownloads({ url: "https://downloads.example.com/computer/" })]
|
|
19
19
|
* ```
|
|
20
20
|
*/
|