diff --git a/ts/components/CallLinkAddNameModal.tsx b/ts/components/CallLinkAddNameModal.tsx index f983c72736fe..fb243ab29ecf 100644 --- a/ts/components/CallLinkAddNameModal.tsx +++ b/ts/components/CallLinkAddNameModal.tsx @@ -9,6 +9,7 @@ import { Avatar, AvatarSize } from './Avatar'; import { Input } from './Input'; import { CallLinkNameMaxByteLength, + CallLinkNameMaxLength, type CallLinkType, } from '../types/CallLink'; import { getColorForCallLink } from '../util/getColorForCallLink'; @@ -113,6 +114,7 @@ export function CallLinkAddNameModal({ onChange={handleNameInputChange} moduleClassName="CallLinkAddNameModal__Input" maxByteCount={CallLinkNameMaxByteLength} + maxLengthCount={CallLinkNameMaxLength} /> diff --git a/ts/types/CallLink.ts b/ts/types/CallLink.ts index 2822ea5b1aed..12a2f98b7605 100644 --- a/ts/types/CallLink.ts +++ b/ts/types/CallLink.ts @@ -21,6 +21,7 @@ export type CallLinkUpdateData = Readonly<{ */ export const CallLinkNameMaxByteLength = 120; +export const CallLinkNameMaxLength = 32; export const callLinkNameSchema = z.string().refine(input => { return byteLength(input) <= 120;