Compare commits
4 Commits
0b9fb1e412
...
7f88144dcb
Author | SHA1 | Date |
---|---|---|
Natty | 7f88144dcb | |
Natty | fb4973eb8b | |
Natty | 0648b9ff9f | |
Natty | 45594d6d91 |
20
Dockerfile
20
Dockerfile
|
@ -18,17 +18,17 @@ RUN corepack enable
|
||||||
|
|
||||||
WORKDIR /misskey
|
WORKDIR /misskey
|
||||||
|
|
||||||
COPY --link ["pnpm-lock.yaml", "pnpm-workspace.yaml", "package.json", "./"]
|
COPY ["pnpm-lock.yaml", "pnpm-workspace.yaml", "package.json", "./"]
|
||||||
COPY --link ["scripts", "./scripts"]
|
COPY ["scripts", "./scripts"]
|
||||||
COPY --link ["packages/backend/package.json", "./packages/backend/"]
|
COPY ["packages/backend/package.json", "./packages/backend/"]
|
||||||
COPY --link ["packages/frontend/package.json", "./packages/frontend/"]
|
COPY ["packages/frontend/package.json", "./packages/frontend/"]
|
||||||
COPY --link ["packages/sw/package.json", "./packages/sw/"]
|
COPY ["packages/sw/package.json", "./packages/sw/"]
|
||||||
COPY --link ["packages/misskey-js/package.json", "./packages/misskey-js/"]
|
COPY ["packages/misskey-js/package.json", "./packages/misskey-js/"]
|
||||||
|
|
||||||
RUN --mount=type=cache,target=/root/.local/share/pnpm/store,sharing=locked \
|
RUN --mount=type=cache,target=/root/.local/share/pnpm/store,sharing=locked \
|
||||||
pnpm i --frozen-lockfile --aggregate-output
|
pnpm i --frozen-lockfile --aggregate-output
|
||||||
|
|
||||||
COPY --link . ./
|
COPY . ./
|
||||||
|
|
||||||
ARG NODE_ENV=production
|
ARG NODE_ENV=production
|
||||||
|
|
||||||
|
@ -48,9 +48,9 @@ RUN corepack enable
|
||||||
|
|
||||||
WORKDIR /misskey
|
WORKDIR /misskey
|
||||||
|
|
||||||
COPY --link ["pnpm-lock.yaml", "pnpm-workspace.yaml", "package.json", "./"]
|
COPY ["pnpm-lock.yaml", "pnpm-workspace.yaml", "package.json", "./"]
|
||||||
COPY --link ["scripts", "./scripts"]
|
COPY ["scripts", "./scripts"]
|
||||||
COPY --link ["packages/backend/package.json", "./packages/backend/"]
|
COPY ["packages/backend/package.json", "./packages/backend/"]
|
||||||
|
|
||||||
RUN --mount=type=cache,target=/root/.local/share/pnpm/store,sharing=locked \
|
RUN --mount=type=cache,target=/root/.local/share/pnpm/store,sharing=locked \
|
||||||
pnpm i --frozen-lockfile --aggregate-output
|
pnpm i --frozen-lockfile --aggregate-output
|
||||||
|
|
|
@ -45,6 +45,7 @@ pin: "Pin to profile"
|
||||||
unpin: "Unpin from profile"
|
unpin: "Unpin from profile"
|
||||||
copyContent: "Copy contents"
|
copyContent: "Copy contents"
|
||||||
copyLink: "Copy link"
|
copyLink: "Copy link"
|
||||||
|
copyLinkRemote: "Copy remote link"
|
||||||
copyLinkRenote: "Copy renote link"
|
copyLinkRenote: "Copy renote link"
|
||||||
delete: "Delete"
|
delete: "Delete"
|
||||||
deleteAndEdit: "Delete and edit"
|
deleteAndEdit: "Delete and edit"
|
||||||
|
|
|
@ -11,12 +11,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||||
v-hotkey="keymap"
|
v-hotkey="keymap"
|
||||||
:class="$style.root"
|
:class="$style.root"
|
||||||
>
|
>
|
||||||
<div v-if="appearNote.reply && appearNote.reply.replyId">
|
|
||||||
<div v-if="!conversationLoaded" style="padding: 16px">
|
|
||||||
<MkButton style="margin: 0 auto;" primary rounded @click="loadConversation">{{ i18n.ts.loadConversation }}</MkButton>
|
|
||||||
</div>
|
|
||||||
<MkNoteSub v-for="note in conversation" :key="note.id" :class="$style.replyToMore" :note="note"/>
|
<MkNoteSub v-for="note in conversation" :key="note.id" :class="$style.replyToMore" :note="note"/>
|
||||||
</div>
|
|
||||||
<MkNoteSub v-if="appearNote.reply" :note="appearNote.reply" :class="$style.replyTo"/>
|
<MkNoteSub v-if="appearNote.reply" :note="appearNote.reply" :class="$style.replyTo"/>
|
||||||
<div v-if="isRenote" :class="$style.renote">
|
<div v-if="isRenote" :class="$style.renote">
|
||||||
<MkAvatar :class="$style.renoteAvatar" :user="note.user" link preview/>
|
<MkAvatar :class="$style.renoteAvatar" :user="note.user" link preview/>
|
||||||
|
@ -146,9 +141,6 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<div v-if="tab === 'replies'" :class="$style.tab_replies">
|
<div v-if="tab === 'replies'" :class="$style.tab_replies">
|
||||||
<div v-if="!repliesLoaded" style="padding: 16px">
|
|
||||||
<MkButton style="margin: 0 auto;" primary rounded @click="loadReplies">{{ i18n.ts.loadReplies }}</MkButton>
|
|
||||||
</div>
|
|
||||||
<MkNoteSub v-for="note in replies" :key="note.id" :note="note" :class="$style.reply" :detail="true"/>
|
<MkNoteSub v-for="note in replies" :key="note.id" :note="note" :class="$style.reply" :detail="true"/>
|
||||||
</div>
|
</div>
|
||||||
<div v-else-if="tab === 'renotes'" :class="$style.tab_renotes">
|
<div v-else-if="tab === 'renotes'" :class="$style.tab_renotes">
|
||||||
|
@ -460,22 +452,14 @@ function blur() {
|
||||||
el.value.blur();
|
el.value.blur();
|
||||||
}
|
}
|
||||||
|
|
||||||
const repliesLoaded = ref(false);
|
os.api('notes/children', {
|
||||||
|
|
||||||
function loadReplies() {
|
|
||||||
repliesLoaded.value = true;
|
|
||||||
os.api('notes/children', {
|
|
||||||
noteId: appearNote.id,
|
noteId: appearNote.id,
|
||||||
limit: 30,
|
limit: 30,
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
replies.value = res;
|
replies.value = res;
|
||||||
});
|
});
|
||||||
}
|
|
||||||
|
|
||||||
const conversationLoaded = ref(false);
|
if (appearNote.replyId) {
|
||||||
|
|
||||||
function loadConversation() {
|
|
||||||
conversationLoaded.value = true;
|
|
||||||
os.api('notes/conversation', {
|
os.api('notes/conversation', {
|
||||||
noteId: appearNote.replyId,
|
noteId: appearNote.replyId,
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
|
|
|
@ -118,6 +118,17 @@ export function getCopyNoteLinkMenu(note: misskey.entities.Note, text: string):
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export function getCopyNoteLinkRemoteMenu(note: misskey.entities.Note, text: string): MenuItem {
|
||||||
|
return (note.url || note.uri) ? {
|
||||||
|
icon: 'ti ti-link',
|
||||||
|
text,
|
||||||
|
action: (): void => {
|
||||||
|
copyToClipboard(note.url || note.uri);
|
||||||
|
os.success();
|
||||||
|
},
|
||||||
|
} : undefined;
|
||||||
|
}
|
||||||
|
|
||||||
export function getNoteMenu(props: {
|
export function getNoteMenu(props: {
|
||||||
note: Misskey.entities.Note;
|
note: Misskey.entities.Note;
|
||||||
menuButton: Ref<HTMLElement>;
|
menuButton: Ref<HTMLElement>;
|
||||||
|
@ -273,6 +284,7 @@ export function getNoteMenu(props: {
|
||||||
text: i18n.ts.copyContent,
|
text: i18n.ts.copyContent,
|
||||||
action: copyContent,
|
action: copyContent,
|
||||||
}, getCopyNoteLinkMenu(appearNote, i18n.ts.copyLink)
|
}, getCopyNoteLinkMenu(appearNote, i18n.ts.copyLink)
|
||||||
|
, getCopyNoteLinkRemoteMenu(appearNote, i18n.ts.copyLinkRemote)
|
||||||
, (appearNote.url || appearNote.uri) ? {
|
, (appearNote.url || appearNote.uri) ? {
|
||||||
icon: 'ti ti-external-link',
|
icon: 'ti ti-external-link',
|
||||||
text: i18n.ts.showOnRemote,
|
text: i18n.ts.showOnRemote,
|
||||||
|
@ -377,6 +389,7 @@ export function getNoteMenu(props: {
|
||||||
text: i18n.ts.copyContent,
|
text: i18n.ts.copyContent,
|
||||||
action: copyContent,
|
action: copyContent,
|
||||||
}, getCopyNoteLinkMenu(appearNote, i18n.ts.copyLink)
|
}, getCopyNoteLinkMenu(appearNote, i18n.ts.copyLink)
|
||||||
|
, getCopyNoteLinkRemoteMenu(appearNote, i18n.ts.copyLinkRemote)
|
||||||
, (appearNote.url || appearNote.uri) ? {
|
, (appearNote.url || appearNote.uri) ? {
|
||||||
icon: 'ti ti-external-link',
|
icon: 'ti ti-external-link',
|
||||||
text: i18n.ts.showOnRemote,
|
text: i18n.ts.showOnRemote,
|
||||||
|
|
Loading…
Reference in New Issue