@linxiraos/pi-wire 1.1.25 → 1.1.27

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/CHANGELOG.md CHANGED
@@ -2,6 +2,20 @@
2
2
 
3
3
  ## [Unreleased]
4
4
 
5
+ ## [1.1.27] - 2026-10-07
6
+
7
+ - 版本线推进至 1.1.27;本版无独立用户可见变化。
8
+
9
+ ### Fixed
10
+
11
+ - Republished as 1.1.2 to reset the `latest` tag after the broken 1.1.0 (no functional change over 1.1.1).
12
+ - Published tarballs now carry real dependency versions instead of Bun's `catalog:` protocol (1.1.0 installs failed with "Unsupported URL Type catalog:").
13
+ - Republished as 1.1.3 to reset the latest tag after the broken 1.1.2 (no functional change over 1.1.1).
14
+
15
+ ## [1.1.26] - 2026-10-03
16
+
17
+ - 版本线推进至 1.1.26;本版无独立用户可见变化。
18
+
5
19
  ## [1.1.25] - 2026-10-03
6
20
 
7
21
  - 版本线推进至 1.1.25;本版无独立用户可见变化。
@@ -68,24 +82,6 @@
68
82
 
69
83
  - 同步 1.1.4 发布线(与 1.1.3 无功能差异)。
70
84
 
71
- ## [1.1.3] - 2026-08-25
72
-
73
- ### Fixed
74
-
75
- - Republished as 1.1.3 to reset the latest tag after the broken 1.1.2 (no functional change over 1.1.1).
76
-
77
- ## [1.1.2] - 2026-08-25
78
-
79
- ### Fixed
80
-
81
- - Republished as 1.1.2 to reset the `latest` tag after the broken 1.1.0 (no functional change over 1.1.1).
82
-
83
- ## [1.1.1] - 2026-08-25
84
-
85
- ### Fixed
86
-
87
- - Published tarballs now carry real dependency versions instead of Bun's `catalog:` protocol (1.1.0 installs failed with "Unsupported URL Type catalog:").
88
-
89
85
  ## [1.1.0] - 2026-08-25
90
86
 
91
87
  ### Changed
@@ -11,9 +11,11 @@
11
11
  * `q` query, `o` open, `f` frame, `b` blob, `t` palette, `x` close. Terminal →
12
12
  * program: `r` reply, `e` event (on the pty's input side).
13
13
  *
14
- * The normative spec is `crates/tern/SURFACE_PROTOCOL.md` in the Stencil
15
- * repository; these types mirror it. Unknown fields and verbs are ignored in
16
- * both directions, so every addition here is optional.
14
+ * The normative spec is the Tern SDK's Surface Protocol and Elements reference
15
+ * (`docs/sdk/src/protocol` and `docs/sdk/src/elements` in the Stencil
16
+ * repository, https://docs.stencil.so/tern/protocol/); these types mirror it.
17
+ * Unknown fields and verbs are ignored in both directions, so every addition
18
+ * here is optional.
17
19
  */
18
20
  /** Protocol version this build speaks. */
19
21
  export declare const TSP_VERSION = 1;
@@ -328,6 +330,9 @@ export interface TspEditorProps {
328
330
  /** The text is code in this language (`python`, `bash`): highlighted, in the mono face. */
329
331
  lang?: string;
330
332
  readonly?: boolean;
333
+ /** Ready to accept an atomic `send` when advertised in `hello.features`.
334
+ * Independent of text editability or keyboard focus; absent or false is not ready. */
335
+ sendable?: boolean;
331
336
  maxLines?: number;
332
337
  }
333
338
  export type TspInputProps = Omit<TspEditorProps, "maxLines">;
@@ -415,7 +420,7 @@ export interface TspPickerItem {
415
420
  export interface TspPickerColumn {
416
421
  id: string;
417
422
  head?: string;
418
- /** `elapsed`: the value is an age in ms at send; Tern clocks it (spec §9). */
423
+ /** `elapsed`: the value is an age in ms at send; Tern clocks it. */
419
424
  format?: "text" | "num" | "price" | "bar" | "time" | "elapsed" | "dim";
420
425
  /** Lower priorities hide first when narrow. */
421
426
  priority?: number;
@@ -932,6 +937,7 @@ export type TspQuery = {
932
937
  v: readonly number[];
933
938
  app: string;
934
939
  ver?: string;
940
+ features?: readonly string[];
935
941
  } | {
936
942
  q: "blobs";
937
943
  ids: readonly string[];
@@ -953,6 +959,8 @@ export type TspReply = {
953
959
  };
954
960
  dark?: boolean;
955
961
  reduceMotion?: boolean;
962
+ /** The user's system reads a 12-hour clock (`false`: 24-hour); absent from older terminals. */
963
+ hour12?: boolean;
956
964
  } | {
957
965
  r: "blobs";
958
966
  have: readonly string[];
@@ -1028,6 +1036,31 @@ export type TspEvent = {
1028
1036
  cursor: number;
1029
1037
  len: number;
1030
1038
  }
1039
+ /**
1040
+ * Undo the last change to the text of `editor`/`input` node `id` through the
1041
+ * program's own undo history (an applied `edit` is one unit, as typing is); a
1042
+ * no-op when there is nothing to undo. Sent only when `hello` lists `"undo"`.
1043
+ */
1044
+ | {
1045
+ ev: "undo";
1046
+ sf: string;
1047
+ id: string;
1048
+ }
1049
+ /**
1050
+ * Submit `text` as one prompt through the addressed composer's ordinary
1051
+ * submission path, without paste or keyboard simulation. Sent only when
1052
+ * the program's `hello.features` includes `"send"` and `sf`/`id` identify
1053
+ * a live editable composer whose `sendable` is exactly true. Writable text
1054
+ * or keyboard focus alone does not imply submission readiness. Blank text is
1055
+ * a no-op; an existing draft is retained for local recall, not appended to
1056
+ * the supplied prompt.
1057
+ */
1058
+ | {
1059
+ ev: "send";
1060
+ sf: string;
1061
+ id: string;
1062
+ text: string;
1063
+ }
1031
1064
  /**
1032
1065
  * The user clicked into node `id` (an `editor`/`input` without the focus, or
1033
1066
  * a `prefs` sheet while the focus is outside it): the program moves its
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "type": "module",
3
3
  "name": "@linxiraos/pi-wire",
4
- "version": "1.1.25",
4
+ "version": "1.1.27",
5
5
  "description": "Shared wire protocol types for omp packages",
6
6
  "homepage": "https://linxira-os.github.io/zeta/",
7
7
  "author": "Can Boluk",
package/src/tsp.ts CHANGED
@@ -11,9 +11,11 @@
11
11
  * `q` query, `o` open, `f` frame, `b` blob, `t` palette, `x` close. Terminal →
12
12
  * program: `r` reply, `e` event (on the pty's input side).
13
13
  *
14
- * The normative spec is `crates/tern/SURFACE_PROTOCOL.md` in the Stencil
15
- * repository; these types mirror it. Unknown fields and verbs are ignored in
16
- * both directions, so every addition here is optional.
14
+ * The normative spec is the Tern SDK's Surface Protocol and Elements reference
15
+ * (`docs/sdk/src/protocol` and `docs/sdk/src/elements` in the Stencil
16
+ * repository, https://docs.stencil.so/tern/protocol/); these types mirror it.
17
+ * Unknown fields and verbs are ignored in both directions, so every addition
18
+ * here is optional.
17
19
  */
18
20
 
19
21
  /** Protocol version this build speaks. */
@@ -357,6 +359,9 @@ export interface TspEditorProps {
357
359
  /** The text is code in this language (`python`, `bash`): highlighted, in the mono face. */
358
360
  lang?: string;
359
361
  readonly?: boolean;
362
+ /** Ready to accept an atomic `send` when advertised in `hello.features`.
363
+ * Independent of text editability or keyboard focus; absent or false is not ready. */
364
+ sendable?: boolean;
360
365
  maxLines?: number;
361
366
  }
362
367
  export type TspInputProps = Omit<TspEditorProps, "maxLines">;
@@ -433,7 +438,7 @@ export interface TspPickerItem {
433
438
  export interface TspPickerColumn {
434
439
  id: string;
435
440
  head?: string;
436
- /** `elapsed`: the value is an age in ms at send; Tern clocks it (spec §9). */
441
+ /** `elapsed`: the value is an age in ms at send; Tern clocks it. */
437
442
  format?: "text" | "num" | "price" | "bar" | "time" | "elapsed" | "dim";
438
443
  /** Lower priorities hide first when narrow. */
439
444
  priority?: number;
@@ -902,7 +907,7 @@ export interface TspPalette {
902
907
 
903
908
  /** Verb `q`. */
904
909
  export type TspQuery =
905
- | { q: "hello"; v: readonly number[]; app: string; ver?: string }
910
+ | { q: "hello"; v: readonly number[]; app: string; ver?: string; features?: readonly string[] }
906
911
  | { q: "blobs"; ids: readonly string[] };
907
912
 
908
913
  /** Verb `r`. */
@@ -920,6 +925,8 @@ export type TspReply =
920
925
  cell?: { w: number; h: number };
921
926
  dark?: boolean;
922
927
  reduceMotion?: boolean;
928
+ /** The user's system reads a 12-hour clock (`false`: 24-hour); absent from older terminals. */
929
+ hour12?: boolean;
923
930
  }
924
931
  | { r: "blobs"; have: readonly string[] };
925
932
 
@@ -948,6 +955,22 @@ export type TspEvent =
948
955
  * text length the terminal saw, a mismatch makes the edit stale).
949
956
  */
950
957
  | { ev: "edit"; sf: string; id: string; from: number; to: number; text: string; cursor: number; len: number }
958
+ /**
959
+ * Undo the last change to the text of `editor`/`input` node `id` through the
960
+ * program's own undo history (an applied `edit` is one unit, as typing is); a
961
+ * no-op when there is nothing to undo. Sent only when `hello` lists `"undo"`.
962
+ */
963
+ | { ev: "undo"; sf: string; id: string }
964
+ /**
965
+ * Submit `text` as one prompt through the addressed composer's ordinary
966
+ * submission path, without paste or keyboard simulation. Sent only when
967
+ * the program's `hello.features` includes `"send"` and `sf`/`id` identify
968
+ * a live editable composer whose `sendable` is exactly true. Writable text
969
+ * or keyboard focus alone does not imply submission readiness. Blank text is
970
+ * a no-op; an existing draft is retained for local recall, not appended to
971
+ * the supplied prompt.
972
+ */
973
+ | { ev: "send"; sf: string; id: string; text: string }
951
974
  /**
952
975
  * The user clicked into node `id` (an `editor`/`input` without the focus, or
953
976
  * a `prefs` sheet while the focus is outside it): the program moves its