File tree Expand file tree Collapse file tree 2 files changed +5
-2
lines changed Expand file tree Collapse file tree 2 files changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -28,6 +28,7 @@ import type {
2828 RetrySendMessage ,
2929 StreamMessage ,
3030} from '../../context/ChannelContext' ;
31+ import type { MentionProps , RenderTextOptions } from '../../utils' ;
3132
3233import type {
3334 CustomTrigger ,
@@ -281,6 +282,8 @@ export type MessageUIComponentProps<
281282 renderText ?: (
282283 text ?: string ,
283284 mentioned_users ?: UserResponse < Us > [ ] ,
285+ MentionComponent ?: React . ComponentType < MentionProps < Us > > ,
286+ options ?: RenderTextOptions ,
284287 ) => JSX . Element | null ;
285288 /** Whether or not the current Message is in a Thread */
286289 threadList ?: boolean ;
Original file line number Diff line number Diff line change @@ -144,15 +144,15 @@ const mentionsMarkdownPlugin = <
144144 return transform ;
145145} ;
146146
147- type MentionProps < Us extends DefaultUserType < Us > = DefaultUserType > = {
147+ export type MentionProps < Us extends DefaultUserType < Us > = DefaultUserType > = {
148148 mentioned_user : UserResponse < Us > ;
149149} ;
150150
151151const Mention = < Us extends DefaultUserType < Us > = DefaultUserType > (
152152 props : PropsWithChildren < Us > ,
153153) => < span className = 'str-chat__message-mention' > { props . children } </ span > ;
154154
155- type RenderTextOptions = {
155+ export type RenderTextOptions = {
156156 customMarkDownRenderers ?: {
157157 [ nodeType : string ] : React . ElementType ;
158158 } ;
You can’t perform that action at this time.
0 commit comments