File tree Expand file tree Collapse file tree 3 files changed +14
-7
lines changed Expand file tree Collapse file tree 3 files changed +14
-7
lines changed Original file line number Diff line number Diff line change 6262 "peerDependencies" : {
6363 "react" : " ^18.0.0 || ^17.0.0 || ^16.8.0" ,
6464 "react-dom" : " ^18.0.0 || ^17.0.0 || ^16.8.0" ,
65- "stream-chat" : " ^6.9 .0"
65+ "stream-chat" : " ^7.1 .0"
6666 },
6767 "files" : [
6868 " dist" ,
167167 "rollup-plugin-visualizer" : " ^4.2.0" ,
168168 "semantic-release" : " ^19.0.2" ,
169169 "semantic-release-cli" : " ^5.4.4" ,
170- "stream-chat" : " ^6.9 .0" ,
170+ "stream-chat" : " ^7.1 .0" ,
171171 "style-loader" : " ^2.0.0" ,
172172 "ts-jest" : " ^26.5.1" ,
173173 "tslib" : " 2.3.0" ,
Original file line number Diff line number Diff line change @@ -524,6 +524,8 @@ const ChannelInner = <
524524 return queryResponse . messages . length ;
525525 } ;
526526
527+ const clearHighlightedMessageTimeoutId = useRef < ReturnType < typeof setTimeout > | null > ( null ) ;
528+
527529 const jumpToMessage = async ( messageId : string , messageLimit = 100 ) => {
528530 dispatch ( { loadingMore : true , type : 'setLoadingMore' } ) ;
529531 await channel . state . loadMessageIntoState ( messageId , undefined , messageLimit ) ;
@@ -542,7 +544,12 @@ const ChannelInner = <
542544 type : 'jumpToMessageFinished' ,
543545 } ) ;
544546
545- setTimeout ( ( ) => {
547+ if ( clearHighlightedMessageTimeoutId . current ) {
548+ clearTimeout ( clearHighlightedMessageTimeoutId . current ) ;
549+ }
550+
551+ clearHighlightedMessageTimeoutId . current = setTimeout ( ( ) => {
552+ clearHighlightedMessageTimeoutId . current = null ;
546553 dispatch ( { type : 'clearHighlightedMessage' } ) ;
547554 } , 500 ) ;
548555 } ;
Original file line number Diff line number Diff line change @@ -16050,10 +16050,10 @@ stream-browserify@^2.0.1:
1605016050 inherits "~2.0.1"
1605116051 readable-stream "^2.0.2"
1605216052
16053- stream-chat@^6.9 .0:
16054- version "6.9 .0"
16055- resolved "https://registry.yarnpkg.com/stream-chat/-/stream-chat-6.9 .0.tgz#cc5c8e68849b36a891178b6b39cd150fc8a69ddf "
16056- integrity sha512-GERt6ohbMucs1mOFY6xoU3p9gl0oEQieod09hSiaRnHG++LP//SQafYlSyE9v2n368VQcc6OSiP5tAinBWafJw ==
16053+ stream-chat@^7.1 .0:
16054+ version "7.1 .0"
16055+ resolved "https://registry.yarnpkg.com/stream-chat/-/stream-chat-7.1 .0.tgz#b5dc7f999d32aa257bb2458d5c57116acb4a656f "
16056+ integrity sha512-MY3dXFbF5xIGKjXE6qHAjzLQkjMeZARCWl22EP7qkVDH0fCzuhRO2MR5L3MaatX3rrUj7MkkLc0Mw0rqjY7PPw ==
1605716057 dependencies:
1605816058 "@babel/runtime" "^7.16.3"
1605916059 "@types/jsonwebtoken" "^8.5.6"
You can’t perform that action at this time.
0 commit comments