From 1873c0f7d4a44a83b044751ce8edd9c67ee6041a Mon Sep 17 00:00:00 2001 From: "P. Douglas Reeder" Date: Fri, 27 Sep 2024 21:55:21 -0400 Subject: [PATCH] Pronouns may also be separated by comma or space --- src/react-components/room/AvatarSettingsContent.js | 1 + src/storage/store.js | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/react-components/room/AvatarSettingsContent.js b/src/react-components/room/AvatarSettingsContent.js index 9a238f0b9e..5b3d9840b5 100644 --- a/src/react-components/room/AvatarSettingsContent.js +++ b/src/react-components/room/AvatarSettingsContent.js @@ -27,6 +27,7 @@ export function AvatarSettingsContent({ label={} value={displayName} pattern={displayNamePattern} + placeholder="separated by slashes or commas" spellCheck="false" required onChange={onChangeDisplayName} diff --git a/src/storage/store.js b/src/storage/store.js index dd7fc35eae..89887fa375 100644 --- a/src/storage/store.js +++ b/src/storage/store.js @@ -65,7 +65,7 @@ export const SCHEMA = { properties: { displayName: { type: "string", pattern: "^[A-Za-z0-9_~\\s\\-]{3,32}$" }, avatarId: { type: "string" }, - pronouns: { type: "string", pattern: "^([a-zA-Z]{1,32}\\/){0,4}[a-zA-Z]{1,32}$" }, + pronouns: { type: "string", pattern: "^([a-zA-Z]{1,32}[\\/, ]\\s?){0,4}[a-zA-Z]{1,32}$" }, // personalAvatarId is obsolete, but we need it here for backwards compatibility. personalAvatarId: { type: "string" } }