diff --git a/src/plugins/roleColorEverywhere/index.tsx b/src/plugins/roleColorEverywhere/index.tsx index 2b4b3e0c7..d50596398 100644 --- a/src/plugins/roleColorEverywhere/index.tsx +++ b/src/plugins/roleColorEverywhere/index.tsx @@ -107,8 +107,8 @@ export default definePlugin({ find: 'tutorialId:"whos-online', replacement: [ { - match: /(#{intl::CHANNEL_MEMBERS_A11Y_LABEL}.+}\):null,).{0,100}?— ",\i\]\}\)\]/, - replace: (_, rest) => `${rest}$self.RoleGroupColor(arguments[0])]` + match: /(#{intl::CHANNEL_MEMBERS_A11Y_LABEL}.+}\):null,).{0,100}?(?:—|\\u2014) ",\i\]\}\)\]/, + replace: "$1$self.RoleGroupColor(arguments[0])]" }, ], predicate: () => settings.store.memberList @@ -117,7 +117,7 @@ export default definePlugin({ find: "#{intl::THREAD_BROWSER_PRIVATE}", replacement: [ { - match: /children:\[\i," — ",\i\]/, + match: /children:\[\i," (?:—|\\u2014) ",\i\]/, replace: "children:[$self.RoleGroupColor(arguments[0])]" }, ],