summaryrefslogtreecommitdiff
path: root/packages/frontend/src/components/MkPoll.vue
diff options
context:
space:
mode:
authorかっこかり <67428053+kakkokari-gtyih@users.noreply.github.com>2024-07-14 17:28:34 +0900
committerGitHub <noreply@github.com>2024-07-14 17:28:34 +0900
commit722acf5986bda0ddea3a4724d171e4d553037bbf (patch)
tree955f756222a40fec97a22563e4c3f3e7d25e8b6f /packages/frontend/src/components/MkPoll.vue
parentci: ワークフローが更新されたときにもワークフローが起... (diff)
downloadmisskey-722acf5986bda0ddea3a4724d171e4d553037bbf.tar.gz
misskey-722acf5986bda0ddea3a4724d171e4d553037bbf.tar.bz2
misskey-722acf5986bda0ddea3a4724d171e4d553037bbf.zip
fix(frontend): follow-up of #13089 (#14206)
* fix(frontend): #13089 を修正 * fix * 正規表現を強化 * fix
Diffstat (limited to 'packages/frontend/src/components/MkPoll.vue')
-rw-r--r--packages/frontend/src/components/MkPoll.vue9
1 files changed, 5 insertions, 4 deletions
diff --git a/packages/frontend/src/components/MkPoll.vue b/packages/frontend/src/components/MkPoll.vue
index 82e2a605f1..72bd8f4f6c 100644
--- a/packages/frontend/src/components/MkPoll.vue
+++ b/packages/frontend/src/components/MkPoll.vue
@@ -36,6 +36,7 @@ import { misskeyApi } from '@/scripts/misskey-api.js';
import { i18n } from '@/i18n.js';
import { host } from '@/config.js';
import { useInterval } from '@/scripts/use-interval.js';
+import type { OpenOnRemoteOptions } from '@/scripts/please-login.js';
const props = defineProps<{
noteId: string;
@@ -61,10 +62,10 @@ const timer = computed(() => i18n.tsx._poll[
const showResult = ref(props.readOnly || isVoted.value);
-const pleaseLoginContext = {
+const pleaseLoginContext = computed<OpenOnRemoteOptions>(() => ({
type: 'lookup',
- path: `https://${host}/notes/${props.note.id}`,
-} as const;
+ url: `https://${host}/notes/${props.noteId}`,
+}));
// 期限付きアンケート
if (props.poll.expiresAt) {
@@ -82,7 +83,7 @@ if (props.poll.expiresAt) {
}
const vote = async (id) => {
- pleaseLogin(undefined, pleaseLoginContext);
+ pleaseLogin(undefined, pleaseLoginContext.value);
if (props.readOnly || closed.value || isVoted.value) return;