diff --git a/packages/backend/src/server/web/ClientServerService.ts b/packages/backend/src/server/web/ClientServerService.ts
index 7c79859e02..99ae1b7af6 100644
--- a/packages/backend/src/server/web/ClientServerService.ts
+++ b/packages/backend/src/server/web/ClientServerService.ts
@@ -476,14 +476,6 @@ export class ClientServerService {
}
});
- // Note Embed
- fastify.get<{ Params: { note: string; } }>('/notes/:note/embed', async (request, reply) => {
- reply.removeHeader('X-Frame-Options');
- reply.header("X-Robots-Tag", "noindex");
-
- return await renderBase(reply);
- });
-
// Page
fastify.get<{ Params: { user: string; page: string; } }>('/@:user/pages/:page', async (request, reply) => {
const { username, host } = Acct.parse(request.params.user);
diff --git a/packages/frontend/package.json b/packages/frontend/package.json
index 1d74a35dda..79fb626a9a 100644
--- a/packages/frontend/package.json
+++ b/packages/frontend/package.json
@@ -39,7 +39,6 @@
"eventemitter3": "5.0.0",
"gsap": "3.11.5",
"idb-keyval": "6.2.0",
- "iframe-resizer": "^4.3.6",
"insert-text-at-cursor": "0.3.0",
"is-file-animated": "1.0.2",
"json5": "2.2.3",
@@ -98,7 +97,6 @@
"@types/estree": "1.0.0",
"@types/gulp": "4.0.10",
"@types/gulp-rename": "2.0.1",
- "@types/iframe-resizer": "^3.5.9",
"@types/matter-js": "0.18.2",
"@types/micromatch": "3.1.1",
"@types/node": "18.15.11",
diff --git a/packages/frontend/src/components/MkNoteDetailed.vue b/packages/frontend/src/components/MkNoteDetailed.vue
index f56c8ec7b1..b9ab366850 100644
--- a/packages/frontend/src/components/MkNoteDetailed.vue
+++ b/packages/frontend/src/components/MkNoteDetailed.vue
@@ -54,11 +54,6 @@
@@ -96,54 +91,32 @@
-
-
-
- {{ appearNote.repliesCount }}
-
-
-
- {{ appearNote.renoteCount }}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
@@ -185,8 +158,6 @@ import { defaultStore, noteViewInterruptors } from '@/store';
import { reactionPicker } from '@/scripts/reaction-picker';
import { extractUrlFromMfm } from '@/scripts/extract-url-from-mfm';
import { $i } from '@/account';
-import { instance } from '@/instance';
-import { openInstanceMenu } from '@/ui/_common_/common';
import { i18n } from '@/i18n';
import { getNoteClipMenu, getNoteMenu } from '@/scripts/get-note-menu';
import { useNoteCapture } from '@/scripts/use-note-capture';
@@ -199,7 +170,6 @@ import MkRippleEffect from '@/components/MkRippleEffect.vue';
const props = defineProps<{
note: misskey.entities.Note;
pinned?: boolean;
- embed?: boolean;
}>();
const inChannel = inject('inChannel', null);
@@ -408,12 +378,12 @@ function onContextmenu(ev: MouseEvent): void {
ev.preventDefault();
react();
} else {
- os.contextMenu(getNoteMenu({ note: note, translating, translation, menuButton, isDeleted, embed: props.embed }), ev).then(focus);
+ os.contextMenu(getNoteMenu({ note: note, translating, translation, menuButton, isDeleted }), ev).then(focus);
}
}
function menu(viaKeyboard = false): void {
- os.popupMenu(getNoteMenu({ note: note, translating, translation, menuButton, isDeleted, embed: props.embed }), menuButton.value, {
+ os.popupMenu(getNoteMenu({ note: note, translating, translation, menuButton, isDeleted }), menuButton.value, {
viaKeyboard,
}).then(focus);
}
@@ -494,10 +464,6 @@ if (appearNote.replyId) {
&:hover > .article > .main > .footer > .button {
opacity: 1;
-
- &:hover {
- text-decoration: none;
- }
}
> .reply-to {
@@ -612,19 +578,6 @@ if (appearNote.replyId) {
word-wrap: anywhere;
}
}
-
- > .instance-info {
- flex-shrink: 0;
- padding-left: 16px;
- width: 39px;
- height: 39px;
-
- img {
- width: 100%;
- height: auto;
- border-radius: 4px;
- }
- }
}
> .main {
@@ -781,10 +734,6 @@ if (appearNote.replyId) {
width: 50px;
height: 50px;
}
- > .instance-info {
- width: 33px;
- height: 33px;
- }
}
> .main {
diff --git a/packages/frontend/src/components/global/MkA.vue b/packages/frontend/src/components/global/MkA.vue
index 901454021d..e3039008f9 100644
--- a/packages/frontend/src/components/global/MkA.vue
+++ b/packages/frontend/src/components/global/MkA.vue
@@ -11,7 +11,6 @@ import { url } from '@/config';
import { popout as popout_ } from '@/scripts/popout';
import { i18n } from '@/i18n';
import { useRouter } from '@/router';
-import { MenuItem } from '@/types/menu';
const props = withDefaults(defineProps<{
to: string;
@@ -34,60 +33,37 @@ const active = $computed(() => {
return resolved.route.name === router.currentRoute.value.name;
});
-function onContextmenu(ev : Event) {
+function onContextmenu(ev) {
const selection = window.getSelection();
- if ((selection && selection.toString() !== '')) return;
-
- let contextMenuItem: MenuItem[] = [];
-
- if (router.currentRoute.value.name?.toLowerCase().includes("embed")) {
- contextMenuItem = [{
- type: 'label',
- text: props.to,
- }, {
- icon: 'ti ti-external-link',
- text: i18n.ts.openInNewTab,
- action: () => {
- window.open(props.to, '_blank');
- },
- }, {
- icon: 'ti ti-link',
- text: i18n.ts.copyLink,
- action: () => {
- copyToClipboard(`${url}${props.to}`);
- },
- }];
- } else {
- contextMenuItem = [{
- type: 'label',
- text: props.to,
- }, {
- icon: 'ti ti-app-window',
- text: i18n.ts.openInWindow,
- action: () => {
- os.pageWindow(props.to);
- },
- }, {
- icon: 'ti ti-player-eject',
- text: i18n.ts.showInPage,
- action: () => {
- router.push(props.to, 'forcePage');
- },
- }, null, {
- icon: 'ti ti-external-link',
- text: i18n.ts.openInNewTab,
- action: () => {
- window.open(props.to, '_blank');
- },
- }, {
- icon: 'ti ti-link',
- text: i18n.ts.copyLink,
- action: () => {
- copyToClipboard(`${url}${props.to}`);
- },
- }];
- }
- os.contextMenu(contextMenuItem, ev);
+ if (selection && selection.toString() !== '') return;
+ os.contextMenu([{
+ type: 'label',
+ text: props.to,
+ }, {
+ icon: 'ti ti-app-window',
+ text: i18n.ts.openInWindow,
+ action: () => {
+ os.pageWindow(props.to);
+ },
+ }, {
+ icon: 'ti ti-player-eject',
+ text: i18n.ts.showInPage,
+ action: () => {
+ router.push(props.to, 'forcePage');
+ },
+ }, null, {
+ icon: 'ti ti-external-link',
+ text: i18n.ts.openInNewTab,
+ action: () => {
+ window.open(props.to, '_blank');
+ },
+ }, {
+ icon: 'ti ti-link',
+ text: i18n.ts.copyLink,
+ action: () => {
+ copyToClipboard(`${url}${props.to}`);
+ },
+ }], ev);
}
function openWindow() {
@@ -103,11 +79,6 @@ function popout() {
}
function nav(ev: MouseEvent) {
- if (router.currentRoute.value.name?.toLowerCase().includes("embed")) {
- window.open(props.to, '_blank');
- return;
- }
-
if (props.behavior === 'browser') {
location.href = props.to;
return;
@@ -127,4 +98,4 @@ function nav(ev: MouseEvent) {
router.push(props.to, ev.ctrlKey ? 'forcePage' : null);
}
-
+
\ No newline at end of file
diff --git a/packages/frontend/src/init.ts b/packages/frontend/src/init.ts
index 03f12a5b26..7809017951 100644
--- a/packages/frontend/src/init.ts
+++ b/packages/frontend/src/init.ts
@@ -187,7 +187,6 @@ try {
} catch (err) {}
const app = createApp(
- window.location.href.includes("/embed") ? defineAsyncComponent(() => import('@/ui/embed.vue')) :
window.location.search === '?zen' ? defineAsyncComponent(() => import('@/ui/zen.vue')) :
!$i ? defineAsyncComponent(() => import('@/ui/visitor.vue')) :
ui === 'deck' ? defineAsyncComponent(() => import('@/ui/deck.vue')) :
diff --git a/packages/frontend/src/pages/note-embed.vue b/packages/frontend/src/pages/note-embed.vue
deleted file mode 100644
index e80425a3e9..0000000000
--- a/packages/frontend/src/pages/note-embed.vue
+++ /dev/null
@@ -1,147 +0,0 @@
-
-
-
-
-
-
-
diff --git a/packages/frontend/src/router.ts b/packages/frontend/src/router.ts
index 964d46608f..c8077edd28 100644
--- a/packages/frontend/src/router.ts
+++ b/packages/frontend/src/router.ts
@@ -30,10 +30,6 @@ export const routes = [{
name: 'note',
path: '/notes/:noteId',
component: page(() => import('./pages/note.vue')),
-}, {
- name: 'noteEmbed',
- path: '/notes/:noteId/embed',
- component: page(() => import('./pages/note-embed.vue')),
}, {
path: '/clips/:clipId',
component: page(() => import('./pages/clip.vue')),
diff --git a/packages/frontend/src/scripts/get-note-menu.ts b/packages/frontend/src/scripts/get-note-menu.ts
index 8bff2d362e..60e2b18a02 100644
--- a/packages/frontend/src/scripts/get-note-menu.ts
+++ b/packages/frontend/src/scripts/get-note-menu.ts
@@ -94,7 +94,6 @@ export function getNoteMenu(props: {
translating: Ref
;
isDeleted: Ref;
currentClip?: misskey.entities.Clip;
- embed?: boolean;
}) {
const isRenote = (
props.note.renote != null &&
@@ -235,7 +234,7 @@ export function getNoteMenu(props: {
}
let menu;
- if ($i && !props.embed) {
+ if ($i) {
const statePromise = os.api('notes/state', {
noteId: appearNote.id,
});
@@ -275,13 +274,11 @@ export function getNoteMenu(props: {
icon: 'ti ti-share',
text: i18n.ts.share,
action: share,
- },
- (!props.embed) ? {
+ }, {
icon: 'ti ti-code',
text: i18n.ts.copyEmbedCode,
action: copyEmbedCode,
- } : undefined,
- instance.translatorAvailable ? {
+ }, instance.translatorAvailable ? {
icon: 'ti ti-language-hiragana',
text: i18n.ts.translate,
action: translate,
@@ -389,7 +386,7 @@ export function getNoteMenu(props: {
action: () => {
window.open(appearNote.url ?? appearNote.uri, '_blank');
},
- } : undefined, (!props.embed) ? {
+ } : undefined, (!appearNote.url && !appearNote.uri) ? {
icon: 'ti ti-code',
text: i18n.ts.copyEmbedCode,
action: copyEmbedCode,
diff --git a/packages/frontend/src/ui/embed.vue b/packages/frontend/src/ui/embed.vue
deleted file mode 100644
index 3df3b9a2ec..0000000000
--- a/packages/frontend/src/ui/embed.vue
+++ /dev/null
@@ -1,43 +0,0 @@
-
-
-
-
-
-
-
-
-
-
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index 521f34d7d9..ff9765b5c4 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -663,9 +663,6 @@ importers:
idb-keyval:
specifier: 6.2.0
version: 6.2.0
- iframe-resizer:
- specifier: ^4.3.6
- version: 4.3.6
insert-text-at-cursor:
specifier: 0.3.0
version: 0.3.0
@@ -835,9 +832,6 @@ importers:
'@types/gulp-rename':
specifier: 2.0.1
version: 2.0.1
- '@types/iframe-resizer':
- specifier: ^3.5.9
- version: 3.5.9
'@types/matter-js':
specifier: 0.18.2
version: 0.18.2
@@ -6599,10 +6593,6 @@ packages:
/@types/http-cache-semantics@4.0.1:
resolution: {integrity: sha512-SZs7ekbP8CN0txVG2xVRH6EgKmEm31BOxA07vkFaETzZz1xh+cbt8BcI0slpymvwhx5dlFnQG2rTlPVQn+iRPQ==}
- /@types/iframe-resizer@3.5.9:
- resolution: {integrity: sha512-RQUBI75F+uXruB95BFpC/8V8lPgJg4MQ6HxOCtAZYBB/h0FNCfrFfb4I+u2pZJIV7sKeszZbFqy1UnGeBMrvsA==}
- dev: true
-
/@types/ioredis@4.28.10:
resolution: {integrity: sha512-69LyhUgrXdgcNDv7ogs1qXZomnfOEnSmrmMFqKgt1XMJxmoOSG/u3wYy13yACIfKuMJ8IhKgHafDO3sx19zVQQ==}
dependencies:
@@ -12536,11 +12526,6 @@ packages:
/ieee754@1.2.1:
resolution: {integrity: sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==}
- /iframe-resizer@4.3.6:
- resolution: {integrity: sha512-wz0WodRIF6eP0oGQa5NIP1yrITAZ59ZJvVaVJqJRjaeCtfm461vy2C3us6CKx0e7pooqpIGLpVMSTzrfAjX9Sg==}
- engines: {node: '>=0.8.0'}
- dev: false
-
/ignore@5.2.4:
resolution: {integrity: sha512-MAb38BcSbH0eHNBxn7ql2NH/kX33OkB3lZ1BNdh7ENeRChHTYsTvWrMubiIAMNS2llXEEgZ1MUOBtXChP3kaFQ==}
engines: {node: '>= 4'}