@ -7,6 +7,7 @@ import HStack from 'pl-fe/components/ui/hstack';
|
||||
import Stack from 'pl-fe/components/ui/stack';
|
||||
import Text from 'pl-fe/components/ui/text';
|
||||
import { useAppSelector } from 'pl-fe/hooks/use-app-selector';
|
||||
import { useInstance } from 'pl-fe/hooks/use-instance';
|
||||
import { usePlFeConfig } from 'pl-fe/hooks/use-pl-fe-config';
|
||||
|
||||
import type { Chat } from 'pl-api';
|
||||
@ -16,6 +17,7 @@ interface IChatListShoutboxInterface {
|
||||
}
|
||||
|
||||
const ChatListShoutbox: React.FC<IChatListShoutboxInterface> = ({ onClick }) => {
|
||||
const instance = useInstance();
|
||||
const { logo } = usePlFeConfig();
|
||||
const messages = useAppSelector((state) => state.shoutbox.messages);
|
||||
|
||||
@ -43,7 +45,7 @@ const ChatListShoutbox: React.FC<IChatListShoutboxInterface> = ({ onClick }) =>
|
||||
<Stack alignItems='start' className='overflow-hidden'>
|
||||
<div className='flex w-full grow items-center space-x-1'>
|
||||
<Text weight='bold' size='sm' align='left' truncate>
|
||||
<FormattedMessage id='chat_list_item_shoutbox' defaultMessage='Instance shoutbox' />
|
||||
<FormattedMessage id='chat_list_item_shoutbox' defaultMessage='{instance} shoutbox' values={{ instance: instance.title }} />
|
||||
</Text>
|
||||
</div>
|
||||
|
||||
|
||||
@ -7,12 +7,14 @@ import HStack from 'pl-fe/components/ui/hstack';
|
||||
import IconButton from 'pl-fe/components/ui/icon-button';
|
||||
import Stack from 'pl-fe/components/ui/stack';
|
||||
import Text from 'pl-fe/components/ui/text';
|
||||
import { useInstance } from 'pl-fe/hooks/use-instance';
|
||||
import { usePlFeConfig } from 'pl-fe/hooks/use-pl-fe-config';
|
||||
|
||||
import Shoutbox from '../../shoutbox';
|
||||
|
||||
const ChatPageShoutbox = () => {
|
||||
const history = useHistory();
|
||||
const instance = useInstance();
|
||||
const { logo } = usePlFeConfig();
|
||||
|
||||
return (
|
||||
@ -32,7 +34,7 @@ const ChatPageShoutbox = () => {
|
||||
<Stack alignItems='start' className='h-11 overflow-hidden'>
|
||||
<div className='flex w-full grow items-center space-x-1'>
|
||||
<Text weight='bold' size='sm' align='left' truncate>
|
||||
<FormattedMessage id='chat_list_item_shoutbox' defaultMessage='Instance shoutbox' />
|
||||
<FormattedMessage id='chat_list_item_shoutbox' defaultMessage='{instance} shoutbox' values={{ instance: instance.title }} />
|
||||
</Text>
|
||||
</div>
|
||||
</Stack>
|
||||
|
||||
@ -7,6 +7,7 @@ import Icon from 'pl-fe/components/ui/icon';
|
||||
import Stack from 'pl-fe/components/ui/stack';
|
||||
import Text from 'pl-fe/components/ui/text';
|
||||
import { ChatWidgetScreens, useChatContext } from 'pl-fe/contexts/chat-context';
|
||||
import { useInstance } from 'pl-fe/hooks/use-instance';
|
||||
import { usePlFeConfig } from 'pl-fe/hooks/use-pl-fe-config';
|
||||
|
||||
import Shoutbox from '../shoutbox';
|
||||
@ -15,6 +16,7 @@ import ChatPaneHeader from './chat-pane-header';
|
||||
|
||||
const ShoutboxWindow = () => {
|
||||
const { changeScreen, isOpen, toggleChatPane } = useChatContext();
|
||||
const instance = useInstance();
|
||||
const { logo } = usePlFeConfig();
|
||||
|
||||
const closeChat = () => {
|
||||
@ -43,7 +45,7 @@ const ShoutboxWindow = () => {
|
||||
<Stack alignItems='start'>
|
||||
<div className='flex grow items-center space-x-1'>
|
||||
<Text size='sm' weight='bold' truncate>
|
||||
<FormattedMessage id='chat_list_item_shoutbox' defaultMessage='Instance shoutbox' />
|
||||
<FormattedMessage id='chat_list_item_shoutbox' defaultMessage='{instance} shoutbox' values={{ instance: instance.title }} />
|
||||
</Text>
|
||||
</div>
|
||||
</Stack>
|
||||
|
||||
@ -273,7 +273,7 @@
|
||||
"chat_composer.unblock": "Unblock",
|
||||
"chat_list_item.blocked_you": "This user has blocked you",
|
||||
"chat_list_item.blocking": "You have blocked this user",
|
||||
"chat_list_item_shoutbox": "Instance shoutbox",
|
||||
"chat_list_item_shoutbox": "{instance} shoutbox",
|
||||
"chat_message_list.blocked": "You blocked this user",
|
||||
"chat_message_list.blocked_by": "You are blocked by",
|
||||
"chat_message_list.network_failure.action": "Try again",
|
||||
|
||||
Reference in New Issue
Block a user