mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-12-19 09:50:15 +01:00
13 lines
415 B
TypeScript
13 lines
415 B
TypeScript
|
|
import React from 'react';
|
||
|
|
import AnnouncerContext from '~/Providers/AnnouncerContext';
|
||
|
|
|
||
|
|
interface LiveMessengerProps {
|
||
|
|
children: (context: React.ContextType<typeof AnnouncerContext>) => React.ReactNode;
|
||
|
|
}
|
||
|
|
|
||
|
|
const LiveMessenger: React.FC<LiveMessengerProps> = ({ children }) => (
|
||
|
|
<AnnouncerContext.Consumer>{(contextProps) => children(contextProps)}</AnnouncerContext.Consumer>
|
||
|
|
);
|
||
|
|
|
||
|
|
export default LiveMessenger;
|