@github/copilot-sdk 1.0.0-beta.1 → 1.0.0-beta.11

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.
@@ -18,11 +18,15 @@ var __copyProps = (to, from, except, desc) => {
18
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
19
  var extension_exports = {};
20
20
  __export(extension_exports, {
21
+ Canvas: () => import_canvas.Canvas,
22
+ CanvasError: () => import_canvas.CanvasError,
23
+ createCanvas: () => import_canvas.createCanvas,
21
24
  joinSession: () => joinSession
22
25
  });
23
26
  module.exports = __toCommonJS(extension_exports);
24
27
  var import_client = require("./client.js");
25
28
  var import_types = require("./types.js");
29
+ var import_canvas = require("./canvas.js");
26
30
  async function joinSession(config = {}) {
27
31
  const sessionId = process.env.SESSION_ID;
28
32
  if (!sessionId) {
@@ -30,14 +34,19 @@ async function joinSession(config = {}) {
30
34
  "joinSession() is intended for extensions running as child processes of the Copilot CLI."
31
35
  );
32
36
  }
33
- const client = new import_client.CopilotClient({ isChildProcess: true });
37
+ const client = new import_client.CopilotClient({ _internalConnection: { kind: "parent-process" } });
38
+ const { extensionSdkPath: _stripped, ...rest } = config;
39
+ void _stripped;
34
40
  return client.resumeSession(sessionId, {
35
- ...config,
41
+ ...rest,
36
42
  onPermissionRequest: config.onPermissionRequest ?? import_types.defaultJoinSessionPermissionHandler,
37
- disableResume: config.disableResume ?? true
43
+ suppressResumeEvent: config.suppressResumeEvent ?? true
38
44
  });
39
45
  }
40
46
  // Annotate the CommonJS export names for ESM import in node:
41
47
  0 && (module.exports = {
48
+ Canvas,
49
+ CanvasError,
50
+ createCanvas,
42
51
  joinSession
43
52
  });