@brainfish-ai/components 0.13.11 → 0.13.12

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.
@@ -3621,7 +3621,9 @@ const getTargetAnswer = (draft, index) => {
3621
3621
  return draft.at(index ?? -1);
3622
3622
  };
3623
3623
  const getLastTextBlock = (answer) => {
3624
- return answer.blocks.at(-1);
3624
+ const textBlocks = answer.blocks.filter(isMarkdownTextBlock);
3625
+ const lastTextBlock = textBlocks.at(-1);
3626
+ return lastTextBlock;
3625
3627
  };
3626
3628
  const initialState = [];
3627
3629
  const reducer = (draft, action) => {
@@ -6023,4 +6025,4 @@ const ChatSearch = forwardRef(({ featureFlags, ...props }, ref) => /* @__PURE__
6023
6025
  ChatSearch.displayName = "ChatSearch";
6024
6026
 
6025
6027
  export { ChatSearch as C, ChatSearchProvider as a, useIsChatSearchDirty as b, useChatSearch as u };
6026
- //# sourceMappingURL=ChatSearch.D_p1A_71.js.map
6028
+ //# sourceMappingURL=ChatSearch.BDWjpTUP.js.map