@hasna/assistants 1.1.11 → 1.1.13

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.
@@ -1,5 +1,14 @@
1
1
  {
2
- "tasks": [],
2
+ "tasks": [
3
+ {
4
+ "id": "f14a3078-c44b-41ef-8e1d-ee37e4568c82",
5
+ "description": "Test task for Andrei",
6
+ "status": "pending",
7
+ "priority": "normal",
8
+ "createdAt": 1770542415358,
9
+ "isRecurringTemplate": false
10
+ }
11
+ ],
3
12
  "paused": false,
4
13
  "autoRun": true
5
14
  }
package/dist/index.js CHANGED
@@ -79300,7 +79300,7 @@ ${repoUrl}/issues/new
79300
79300
  context.setProjectContext(projectContext);
79301
79301
  }
79302
79302
  }
79303
- var VERSION = "1.1.11";
79303
+ var VERSION = "1.1.13";
79304
79304
  var init_builtin = __esm(async () => {
79305
79305
  init_src2();
79306
79306
  init_store();
@@ -205109,7 +205109,7 @@ function formatRelativeTime5(isoDate) {
205109
205109
  return `${minutes}m ago`;
205110
205110
  return `${seconds}s ago`;
205111
205111
  }
205112
- function ChannelsPanel({ manager, onClose }) {
205112
+ function ChannelsPanel({ manager, onClose, activePersonId, activePersonName }) {
205113
205113
  const [mode, setMode] = import_react46.useState("list");
205114
205114
  const [channels2, setChannels] = import_react46.useState([]);
205115
205115
  const [selectedIndex, setSelectedIndex] = import_react46.useState(0);
@@ -205151,12 +205151,9 @@ function ChannelsPanel({ manager, onClose }) {
205151
205151
  setMode("members");
205152
205152
  }
205153
205153
  };
205154
- useSafeInput((input, key) => {
205155
- if (mode === "create-name" || mode === "create-desc" || mode === "invite")
205156
- return;
205157
- if (mode === "chat" && !key.escape)
205158
- return;
205159
- if (key.escape || input === "q") {
205154
+ const isTextEntry = mode === "create-name" || mode === "create-desc" || mode === "invite" || mode === "chat";
205155
+ useSafeInput((_input, key) => {
205156
+ if (key.escape) {
205160
205157
  if (mode === "list") {
205161
205158
  onClose();
205162
205159
  } else {
@@ -205164,8 +205161,11 @@ function ChannelsPanel({ manager, onClose }) {
205164
205161
  setSelectedChannel(null);
205165
205162
  setStatusMessage(null);
205166
205163
  }
205167
- return;
205168
205164
  }
205165
+ });
205166
+ useSafeInput((input, key) => {
205167
+ if (key.escape)
205168
+ return;
205169
205169
  if (mode === "list") {
205170
205170
  if (key.upArrow || input === "k") {
205171
205171
  setSelectedIndex((prev) => Math.max(0, prev - 1));
@@ -205195,6 +205195,8 @@ function ChannelsPanel({ manager, onClose }) {
205195
205195
  const ch2 = channels2[selectedIndex];
205196
205196
  setSelectedChannel(manager.getChannel(ch2.id));
205197
205197
  setMode("delete-confirm");
205198
+ } else if (input === "q") {
205199
+ onClose();
205198
205200
  } else if (input === "r") {
205199
205201
  loadChannels();
205200
205202
  setStatusMessage("Refreshed");
@@ -205228,7 +205230,7 @@ function ChannelsPanel({ manager, onClose }) {
205228
205230
  setMode("list");
205229
205231
  }
205230
205232
  }
205231
- });
205233
+ }, { isActive: !isTextEntry });
205232
205234
  const header = /* @__PURE__ */ jsx_dev_runtime23.jsxDEV(Box_default, {
205233
205235
  borderStyle: "single",
205234
205236
  borderColor: "blue",
@@ -205391,7 +205393,7 @@ function ChannelsPanel({ manager, onClose }) {
205391
205393
  onChange: setChatInput,
205392
205394
  onSubmit: () => {
205393
205395
  if (chatInput.trim()) {
205394
- const result = manager.send(selectedChannel.id, chatInput.trim());
205396
+ const result = activePersonId && activePersonName ? manager.sendAs(selectedChannel.id, chatInput.trim(), activePersonId, activePersonName) : manager.send(selectedChannel.id, chatInput.trim());
205395
205397
  if (result.success) {
205396
205398
  setChatInput("");
205397
205399
  const updated = manager.readMessages(selectedChannel.id, 50);
@@ -205698,18 +205700,20 @@ function PeoplePanel({ manager, onClose }) {
205698
205700
  import_react47.useEffect(() => {
205699
205701
  loadPeople();
205700
205702
  }, []);
205701
- useSafeInput((input, key) => {
205702
- if (mode === "create-name" || mode === "create-email")
205703
- return;
205704
- if (key.escape || input === "q") {
205703
+ const isTextEntry = mode === "create-name" || mode === "create-email";
205704
+ useSafeInput((_input, key) => {
205705
+ if (key.escape) {
205705
205706
  if (mode === "list") {
205706
205707
  onClose();
205707
205708
  } else {
205708
205709
  setMode("list");
205709
205710
  setStatusMessage(null);
205710
205711
  }
205711
- return;
205712
205712
  }
205713
+ });
205714
+ useSafeInput((input, key) => {
205715
+ if (key.escape)
205716
+ return;
205713
205717
  if (mode === "list") {
205714
205718
  if (key.upArrow || input === "k") {
205715
205719
  setSelectedIndex((prev) => Math.max(0, prev - 1));
@@ -205774,7 +205778,7 @@ function PeoplePanel({ manager, onClose }) {
205774
205778
  setMode("list");
205775
205779
  }
205776
205780
  }
205777
- });
205781
+ }, { isActive: !isTextEntry });
205778
205782
  const header = /* @__PURE__ */ jsx_dev_runtime24.jsxDEV(Box_default, {
205779
205783
  borderStyle: "single",
205780
205784
  borderColor: "green",
@@ -206814,6 +206818,26 @@ function OnboardingPanel({
206814
206818
  });
206815
206819
  const [enabledConnectors, setEnabledConnectors] = import_react51.useState(() => new Set(discoveredConnectors));
206816
206820
  const [connectorKeysNeeded] = import_react51.useState([]);
206821
+ const currentStepRef = import_react51.useRef(currentStep);
206822
+ currentStepRef.current = currentStep;
206823
+ const { setRawMode, isRawModeSupported } = use_stdin_default();
206824
+ import_react51.useEffect(() => {
206825
+ if (isRawModeSupported && setRawMode) {
206826
+ setRawMode(true);
206827
+ }
206828
+ const handleData = (data) => {
206829
+ const s6 = data.toString();
206830
+ if (s6 === "\x1B") {
206831
+ if (currentStepRef.current === "welcome") {
206832
+ onCancel();
206833
+ }
206834
+ }
206835
+ };
206836
+ process.stdin.on("data", handleData);
206837
+ return () => {
206838
+ process.stdin.removeListener("data", handleData);
206839
+ };
206840
+ }, [onCancel, isRawModeSupported, setRawMode]);
206817
206841
  const [connectorKeys, setConnectorKeys] = import_react51.useState({});
206818
206842
  const [connectorKeyIndex, setConnectorKeyIndex] = import_react51.useState(0);
206819
206843
  const [connectorKeyValue, setConnectorKeyValue] = import_react51.useState("");
@@ -219550,7 +219574,9 @@ When done, report the result.`);
219550
219574
  }
219551
219575
  return /* @__PURE__ */ jsx_dev_runtime43.jsxDEV(ChannelsPanel, {
219552
219576
  manager: channelsManager,
219553
- onClose: () => setShowChannelsPanel(false)
219577
+ onClose: () => setShowChannelsPanel(false),
219578
+ activePersonId: activeSession?.client.getPeopleManager?.()?.getActivePersonId?.() || undefined,
219579
+ activePersonName: activeSession?.client.getPeopleManager?.()?.getActivePerson?.()?.name || undefined
219554
219580
  }, undefined, false, undefined, this);
219555
219581
  }
219556
219582
  if (showPeoplePanel) {
@@ -220341,7 +220367,7 @@ Interactive Mode:
220341
220367
  // packages/terminal/src/index.tsx
220342
220368
  var jsx_dev_runtime44 = __toESM(require_jsx_dev_runtime(), 1);
220343
220369
  setRuntime(bunRuntime);
220344
- var VERSION4 = "1.1.11";
220370
+ var VERSION4 = "1.1.13";
220345
220371
  var SYNC_START = "\x1B[?2026h";
220346
220372
  var SYNC_END = "\x1B[?2026l";
220347
220373
  function enableSynchronizedOutput() {
@@ -220481,4 +220507,4 @@ export {
220481
220507
  main
220482
220508
  };
220483
220509
 
220484
- //# debugId=7F1186F284FAEEDE64756E2164756E21
220510
+ //# debugId=1CAB81672590576764756E2164756E21