@yourgpt/copilot-sdk 2.5.0 → 2.5.1-beta.0

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.
@@ -5690,11 +5690,14 @@ function CopilotProvider(props) {
5690
5690
  async (content, attachments) => {
5691
5691
  debugLog("Sending message:", content);
5692
5692
  setAgentIteration(0);
5693
+ setWasStopped(false);
5693
5694
  await chatRef.current?.sendMessage(content, attachments);
5694
5695
  },
5695
5696
  [debugLog]
5696
5697
  );
5698
+ const [wasStopped, setWasStopped] = React2.useState(false);
5697
5699
  const stop = React2.useCallback(() => {
5700
+ setWasStopped(true);
5698
5701
  chatRef.current?.stop();
5699
5702
  }, []);
5700
5703
  const clearMessages = React2.useCallback(() => {
@@ -5771,6 +5774,7 @@ function CopilotProvider(props) {
5771
5774
  status,
5772
5775
  error,
5773
5776
  isLoading,
5777
+ wasStopped,
5774
5778
  // Chat actions
5775
5779
  sendMessage,
5776
5780
  stop,
@@ -5821,6 +5825,7 @@ function CopilotProvider(props) {
5821
5825
  status,
5822
5826
  error,
5823
5827
  isLoading,
5828
+ wasStopped,
5824
5829
  sendMessage,
5825
5830
  stop,
5826
5831
  clearMessages,
@@ -5983,5 +5988,5 @@ exports.useMessageHistoryContext = useMessageHistoryContext;
5983
5988
  exports.useSkillContext = useSkillContext;
5984
5989
  exports.useTool = useTool;
5985
5990
  exports.useTools = useTools;
5986
- //# sourceMappingURL=chunk-UBDBTEK5.cjs.map
5987
- //# sourceMappingURL=chunk-UBDBTEK5.cjs.map
5991
+ //# sourceMappingURL=chunk-ZYLHGNIG.cjs.map
5992
+ //# sourceMappingURL=chunk-ZYLHGNIG.cjs.map