diff --git a/packages/client/src/components/MkUserSelectDialog.vue b/packages/client/src/components/MkUserSelectDialog.vue index e7407a106..485b3d890 100644 --- a/packages/client/src/components/MkUserSelectDialog.vue +++ b/packages/client/src/components/MkUserSelectDialog.vue @@ -96,6 +96,7 @@ import XModalWindow from "@/components/MkModalWindow.vue"; import * as os from "@/os"; import { defaultStore } from "@/store"; import { i18n } from "@/i18n"; +import { toASCII } from "punycode/"; const emit = defineEmits<{ (ev: "ok", selected: misskey.entities.UserDetailed): void; @@ -117,7 +118,7 @@ const search = () => { } os.api("users/search-by-username-and-host", { username: username, - host: host, + host: toASCII(host), limit: 10, detail: false, }).then((_users) => { diff --git a/packages/client/src/scripts/autocomplete.ts b/packages/client/src/scripts/autocomplete.ts index 99f9dce40..2efa0249a 100644 --- a/packages/client/src/scripts/autocomplete.ts +++ b/packages/client/src/scripts/autocomplete.ts @@ -3,7 +3,7 @@ import getCaretCoordinates from "textarea-caret"; import { toASCII } from "punycode/"; import { popup } from "@/os"; -const mentionRegex = /@(?[a-zA-Z0-9_]+|$)@?(?[a-zA-Z0-9-.]+)?$/g; +const mentionRegex = /@(?[a-zA-Z0-9_]+|$)@?(?[\S]+)?$/g; export class Autocomplete { private suggestion: {