From fc77ad9355f74ec4b4b155a9d5624850b3dff351 Mon Sep 17 00:00:00 2001
From: syuilo <4439005+syuilo@users.noreply.github.com>
Date: Mon, 6 May 2024 20:37:04 +0900
Subject: [PATCH] refactor(frontend): provide linkNavigationBehavior
---
packages/frontend/src/components/MkAbuseReport.vue | 2 +-
packages/frontend/src/components/MkLink.vue | 4 ++--
packages/frontend/src/components/MkMention.vue | 4 ++--
packages/frontend/src/components/global/MkA.vue | 12 +++++-------
.../components/global/MkMisskeyFlavoredMarkdown.ts | 10 ++++------
packages/frontend/src/components/global/MkUrl.vue | 4 ++--
6 files changed, 16 insertions(+), 20 deletions(-)
diff --git a/packages/frontend/src/components/MkAbuseReport.vue b/packages/frontend/src/components/MkAbuseReport.vue
index ab65ea7ec7..a28e7c2559 100644
--- a/packages/frontend/src/components/MkAbuseReport.vue
+++ b/packages/frontend/src/components/MkAbuseReport.vue
@@ -20,7 +20,7 @@ SPDX-License-Identifier: AGPL-3.0-only
-
+
{{ i18n.ts.reporter }}: @{{ report.reporter.username }}
diff --git a/packages/frontend/src/components/MkLink.vue b/packages/frontend/src/components/MkLink.vue
index bd1bd0e24a..5d54a58e97 100644
--- a/packages/frontend/src/components/MkLink.vue
+++ b/packages/frontend/src/components/MkLink.vue
@@ -6,7 +6,7 @@ SPDX-License-Identifier: AGPL-3.0-only
@@ -25,7 +25,7 @@ import { MkABehavior } from '@/components/global/MkA.vue';
const props = withDefaults(defineProps<{
url: string;
rel?: null | string;
- behavior?: MkABehavior;
+ navigationBehavior?: MkABehavior;
}>(), {
});
diff --git a/packages/frontend/src/components/MkMention.vue b/packages/frontend/src/components/MkMention.vue
index cbefecf03a..bfb49a416e 100644
--- a/packages/frontend/src/components/MkMention.vue
+++ b/packages/frontend/src/components/MkMention.vue
@@ -4,7 +4,7 @@ SPDX-License-Identifier: AGPL-3.0-only
-->
-
+
@{{ username }}
@@ -26,7 +26,7 @@ import { MkABehavior } from '@/components/global/MkA.vue';
const props = defineProps<{
username: string;
host: string;
- behavior?: MkABehavior;
+ navigationBehavior?: MkABehavior;
}>();
const canonical = props.host === localHost ? `@${props.username}` : `@${props.username}@${toUnicode(props.host)}`;
diff --git a/packages/frontend/src/components/global/MkA.vue b/packages/frontend/src/components/global/MkA.vue
index b64acacc32..d1e9113c48 100644
--- a/packages/frontend/src/components/global/MkA.vue
+++ b/packages/frontend/src/components/global/MkA.vue
@@ -14,7 +14,7 @@ export type MkABehavior = 'window' | 'browser' | null;