diff --git a/public/ui-config.json.example b/public/ui-config.json.example index 403bb68a..585a5319 100644 --- a/public/ui-config.json.example +++ b/public/ui-config.json.example @@ -16,6 +16,7 @@ "badge.descriptions.enabled": true, "motto.max.length": 38, "bot.name.max.length": 15, + "wired.message.max.length": "31", "navigator.room.models": [ { "clubLevel": 0, "tileSize": 104, "name": "a" }, { "clubLevel": 0, "tileSize": 94, "name": "b" }, diff --git a/src/components/wired/views/actions/WiredActionBotTalkToAvatarView.tsx b/src/components/wired/views/actions/WiredActionBotTalkToAvatarView.tsx index f2866e05..178c1983 100644 --- a/src/components/wired/views/actions/WiredActionBotTalkToAvatarView.tsx +++ b/src/components/wired/views/actions/WiredActionBotTalkToAvatarView.tsx @@ -1,5 +1,5 @@ import { FC, useEffect, useState } from 'react'; -import { LocalizeText, WiredFurniType, WIRED_STRING_DELIMETER } from '../../../../api'; +import { GetConfiguration, LocalizeText, WiredFurniType, WIRED_STRING_DELIMETER } from '../../../../api'; import { Column, Flex, Text } from '../../../../common'; import { useWired } from '../../../../hooks'; import { WiredActionBaseView } from './WiredActionBaseView'; @@ -35,7 +35,7 @@ export const WiredActionBotTalkToAvatarView: FC<{}> = props => { LocalizeText('wiredfurni.params.message') } - setMessage(event.target.value) } /> + ('wired.message.max.length') } value={ message } onChange={ event => setMessage(event.target.value) } /> diff --git a/src/components/wired/views/actions/WiredActionBotTalkView.tsx b/src/components/wired/views/actions/WiredActionBotTalkView.tsx index b457c431..6a4f1bb3 100644 --- a/src/components/wired/views/actions/WiredActionBotTalkView.tsx +++ b/src/components/wired/views/actions/WiredActionBotTalkView.tsx @@ -1,5 +1,5 @@ import { FC, useEffect, useState } from 'react'; -import { LocalizeText, WiredFurniType, WIRED_STRING_DELIMETER } from '../../../../api'; +import { GetConfiguration, LocalizeText, WiredFurniType, WIRED_STRING_DELIMETER } from '../../../../api'; import { Column, Flex, Text } from '../../../../common'; import { useWired } from '../../../../hooks'; import { WiredActionBaseView } from './WiredActionBaseView'; @@ -35,7 +35,7 @@ export const WiredActionBotTalkView: FC<{}> = props => { LocalizeText('wiredfurni.params.message') } - setMessage(event.target.value) } /> + ('wired.message.max.length') } value={ message } onChange={ event => setMessage(event.target.value) } /> diff --git a/src/components/wired/views/actions/WiredActionChatView.tsx b/src/components/wired/views/actions/WiredActionChatView.tsx index b570af7f..0a8d18ec 100644 --- a/src/components/wired/views/actions/WiredActionChatView.tsx +++ b/src/components/wired/views/actions/WiredActionChatView.tsx @@ -1,5 +1,5 @@ import { FC, useEffect, useState } from 'react'; -import { LocalizeText, WiredFurniType } from '../../../../api'; +import { GetConfiguration, LocalizeText, WiredFurniType } from '../../../../api'; import { Column, Text } from '../../../../common'; import { useWired } from '../../../../hooks'; import { WiredActionBaseView } from './WiredActionBaseView'; @@ -20,7 +20,7 @@ export const WiredActionChatView: FC<{}> = props => { LocalizeText('wiredfurni.params.message') } - setMessage(event.target.value) } maxLength={ 100 } /> + setMessage(event.target.value) } maxLength={ GetConfiguration('wired.message.max.length') } /> ); diff --git a/src/components/wired/views/actions/WiredActionKickFromRoomView.tsx b/src/components/wired/views/actions/WiredActionKickFromRoomView.tsx index e16b6684..b41bd1b1 100644 --- a/src/components/wired/views/actions/WiredActionKickFromRoomView.tsx +++ b/src/components/wired/views/actions/WiredActionKickFromRoomView.tsx @@ -1,5 +1,5 @@ import { FC, useEffect, useState } from 'react'; -import { LocalizeText, WiredFurniType } from '../../../../api'; +import { GetConfiguration, LocalizeText, WiredFurniType } from '../../../../api'; import { Column, Text } from '../../../../common'; import { useWired } from '../../../../hooks'; import { WiredActionBaseView } from './WiredActionBaseView'; @@ -20,7 +20,7 @@ export const WiredActionKickFromRoomView: FC<{}> = props => { LocalizeText('wiredfurni.params.message') } - setMessage(event.target.value) } maxLength={ 100 } /> + setMessage(event.target.value) } maxLength={ GetConfiguration('wired.message.max.length') } /> ); diff --git a/src/components/wired/views/actions/WiredActionMuteUserView.tsx b/src/components/wired/views/actions/WiredActionMuteUserView.tsx index e34bd60a..4df2d4e4 100644 --- a/src/components/wired/views/actions/WiredActionMuteUserView.tsx +++ b/src/components/wired/views/actions/WiredActionMuteUserView.tsx @@ -1,6 +1,6 @@ import { FC, useEffect, useState } from 'react'; import ReactSlider from 'react-slider'; -import { LocalizeText, WiredFurniType } from '../../../../api'; +import { GetConfiguration, LocalizeText, WiredFurniType } from '../../../../api'; import { Column, Text } from '../../../../common'; import { useWired } from '../../../../hooks'; import { WiredActionBaseView } from './WiredActionBaseView'; @@ -36,7 +36,7 @@ export const WiredActionMuteUserView: FC<{}> = props => { LocalizeText('wiredfurni.params.message') } - setMessage(event.target.value) } maxLength={ 100 } /> + setMessage(event.target.value) } maxLength={ GetConfiguration('wired.message.max.length') } /> );