@signalcore/ui 1.0.0-beta.0 → 1.0.0-beta.2

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.
Files changed (114) hide show
  1. package/README.md +8 -1
  2. package/dist/AgentAbout.js +7 -4
  3. package/dist/AgentAbout.js.map +1 -1
  4. package/dist/AgentChat.js +10 -2
  5. package/dist/AgentChat.js.map +1 -1
  6. package/dist/AgentTasks.js +2 -1
  7. package/dist/AgentTasks.js.map +1 -1
  8. package/dist/VoiceCall.js +1 -1
  9. package/dist/VoiceCall.js.map +1 -1
  10. package/dist/about.d.ts +34 -144
  11. package/dist/about.js +6 -8
  12. package/dist/about.js.map +1 -1
  13. package/dist/automation/cron.d.ts +1 -1
  14. package/dist/automation/cron.js.map +1 -1
  15. package/dist/automation/marks.js +7 -3
  16. package/dist/automation/marks.js.map +1 -1
  17. package/dist/automation/messages.d.ts +2 -0
  18. package/dist/automation/messages.js +2 -0
  19. package/dist/automation/messages.js.map +1 -1
  20. package/dist/automation/types.d.ts +25 -128
  21. package/dist/automation/types.js +36 -0
  22. package/dist/automation/types.js.map +1 -0
  23. package/dist/automation/when.d.ts +1 -1
  24. package/dist/automation/when.js +5 -1
  25. package/dist/automation/when.js.map +1 -1
  26. package/dist/blocks.d.ts +23 -1
  27. package/dist/browser.js +2 -2
  28. package/dist/browser.js.map +1 -1
  29. package/dist/call.d.ts +1 -1
  30. package/dist/call.js.map +1 -1
  31. package/dist/contract.d.ts +262 -0
  32. package/dist/credentials.js.map +1 -1
  33. package/dist/dev.js +1 -1
  34. package/dist/dev.js.map +1 -1
  35. package/dist/es.js +9 -1
  36. package/dist/es.js.map +1 -1
  37. package/dist/index.d.ts +3 -3
  38. package/dist/index.js +2 -1
  39. package/dist/kit/AudioPlayer.js +1 -1
  40. package/dist/kit/AudioPlayer.js.map +1 -1
  41. package/dist/kit/Choices.js +1 -1
  42. package/dist/kit/Choices.js.map +1 -1
  43. package/dist/kit/FileField.js +1 -1
  44. package/dist/kit/FileField.js.map +1 -1
  45. package/dist/kit/Popover.js.map +1 -1
  46. package/dist/kit/Tile.d.ts +1 -1
  47. package/dist/kit/Tile.js +1 -1
  48. package/dist/kit/Tile.js.map +1 -1
  49. package/dist/kit/messages.d.ts +13 -0
  50. package/dist/kit/messages.js +7 -1
  51. package/dist/kit/messages.js.map +1 -1
  52. package/dist/kit/uploads.d.ts +2 -1
  53. package/dist/kit/uploads.js +1 -1
  54. package/dist/kit/uploads.js.map +1 -1
  55. package/dist/kit/waveform.js.map +1 -1
  56. package/dist/markdown.js.map +1 -1
  57. package/dist/marks.js +2 -3
  58. package/dist/marks.js.map +1 -1
  59. package/dist/surface/Markdown.js +1 -1
  60. package/dist/surface/Markdown.js.map +1 -1
  61. package/dist/surface/Surface.js +43 -4
  62. package/dist/surface/Surface.js.map +1 -1
  63. package/dist/surface/scope.d.ts +1 -1
  64. package/dist/surface/scope.js.map +1 -1
  65. package/dist/surface/values.js +1 -1
  66. package/dist/surface/values.js.map +1 -1
  67. package/dist/tint.d.ts +1 -1
  68. package/dist/tint.js +1 -1
  69. package/dist/tint.js.map +1 -1
  70. package/dist/types.d.ts +7 -0
  71. package/dist/types.js.map +1 -1
  72. package/dist/usePolled.js +1 -1
  73. package/dist/usePolled.js.map +1 -1
  74. package/dist/voice/webgl.js +1 -1
  75. package/dist/voice/webgl.js.map +1 -1
  76. package/dist/widget.js +14 -14
  77. package/package.json +1 -1
  78. package/src/AgentAbout.tsx +10 -3
  79. package/src/AgentChat.tsx +20 -3
  80. package/src/AgentTasks.tsx +2 -2
  81. package/src/VoiceCall.tsx +1 -1
  82. package/src/about.ts +42 -144
  83. package/src/automation/cron.ts +1 -1
  84. package/src/automation/marks.tsx +6 -2
  85. package/src/automation/messages.ts +4 -0
  86. package/src/automation/types.ts +58 -118
  87. package/src/automation/when.ts +3 -1
  88. package/src/blocks.ts +25 -0
  89. package/src/browser.ts +4 -4
  90. package/src/call.ts +1 -1
  91. package/src/contract.ts +1720 -0
  92. package/src/credentials.ts +2 -2
  93. package/src/dev.ts +1 -1
  94. package/src/es.ts +8 -0
  95. package/src/index.ts +2 -0
  96. package/src/kit/AudioPlayer.tsx +1 -1
  97. package/src/kit/Choices.tsx +1 -1
  98. package/src/kit/FileField.tsx +1 -1
  99. package/src/kit/Popover.tsx +1 -1
  100. package/src/kit/Tile.tsx +1 -1
  101. package/src/kit/messages.ts +20 -0
  102. package/src/kit/uploads.ts +2 -2
  103. package/src/kit/waveform.ts +1 -1
  104. package/src/markdown.ts +1 -1
  105. package/src/marks.tsx +3 -123
  106. package/src/styles.css +24 -0
  107. package/src/surface/Markdown.tsx +1 -1
  108. package/src/surface/Surface.tsx +53 -4
  109. package/src/surface/scope.ts +3 -1
  110. package/src/surface/values.ts +5 -5
  111. package/src/tint.ts +1 -1
  112. package/src/types.ts +8 -0
  113. package/src/usePolled.ts +2 -2
  114. package/src/voice/webgl.ts +1 -1
package/src/blocks.ts CHANGED
@@ -100,6 +100,30 @@ export interface AutomationBlock {
100
100
  view: AutomationView | null;
101
101
  }
102
102
 
103
+ /**
104
+ * How the connection an app's card asked for stands: its name and logo, and where the person
105
+ * authorizes it while it waits for them.
106
+ */
107
+ export interface ConnectView {
108
+ title: string;
109
+ icon: string | null;
110
+ status: "pending" | "active" | "error" | "disconnected";
111
+ url: string | null;
112
+ }
113
+
114
+ /**
115
+ * An app for the person to connect, drawn by the platform alone (the agent's `connect_app`,
116
+ * never composed): its name and logo, the line the agent wrote of what it will do with it, and
117
+ * the button that opens its consent page; the API fills in `connection`, and the card changes
118
+ * live as it does (waiting, working, failed). Null while there is none yet.
119
+ */
120
+ export interface ConnectBlock {
121
+ type: "connect";
122
+ app: string;
123
+ purpose: string;
124
+ connection: ConnectView | null;
125
+ }
126
+
103
127
  // --- Action -------------------------------------------------------------------------------
104
128
 
105
129
  /** One thing the person can do: pressing it sends `action`, or, with `url`, opens that page. */
@@ -238,6 +262,7 @@ export type Block =
238
262
  | ImageBlock
239
263
  | AutomationBlock
240
264
  | FileBlock
265
+ | ConnectBlock
241
266
  | ButtonBlock
242
267
  | ChoiceBlock
243
268
  | FormBlock;
package/src/browser.ts CHANGED
@@ -6,7 +6,7 @@
6
6
  import type { BrowserFrame, BrowserInput, Message } from "./types";
7
7
 
8
8
  /** The action that hands the person the browser; the turn waits on it until they give it back. */
9
- export const HAND_OVER = "browser_hand_over";
9
+ const HAND_OVER = "browser_hand_over";
10
10
 
11
11
  /**
12
12
  * The browser's screen as it comes: the latest picture, and whoever watches. Kept out of the
@@ -66,7 +66,7 @@ export function siteOf(url: string): { host: string; rest: string } {
66
66
  }
67
67
  }
68
68
 
69
- export interface Size {
69
+ interface Size {
70
70
  width: number;
71
71
  height: number;
72
72
  }
@@ -86,7 +86,7 @@ export function pointOf(
86
86
  }
87
87
 
88
88
  /** DevTools' mask of the keys held with another: Alt 1, Ctrl 2, Meta 4, Shift 8. */
89
- export function modifiersOf(event: {
89
+ function modifiersOf(event: {
90
90
  altKey: boolean;
91
91
  ctrlKey: boolean;
92
92
  metaKey: boolean;
@@ -268,7 +268,7 @@ export function bytesOf(base64: string): Uint8Array<ArrayBuffer> {
268
268
  }
269
269
 
270
270
  /** Draws a picture on a canvas, unless a newer one comes while it is still being decoded. */
271
- export interface Painter {
271
+ interface Painter {
272
272
  paint: (jpeg: string) => void;
273
273
  dispose: () => void;
274
274
  }
package/src/call.ts CHANGED
@@ -34,7 +34,7 @@ export type CallProblem =
34
34
  | "unsupported"
35
35
  /** Calls aren't set up where the agent works (the API refused with `no_calls`). */
36
36
  | "off"
37
- /** The agent takes no calls: a squad's builder (`builder`). */
37
+ /** The agent takes no calls: the builder (`builder`). */
38
38
  | "builder"
39
39
  /** The API wouldn't make the call, for any other reason it named. */
40
40
  | "refused"