From 6372357f812d550a3cd23b32f8540f16bec1b715 Mon Sep 17 00:00:00 2001 From: ThatOneCalculator Date: Thu, 28 Jul 2022 09:24:43 -0700 Subject: [PATCH] Less cluttered notification summary --- CALCKEY.md | 2 +- packages/client/src/scripts/get-note-summary.ts | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/CALCKEY.md b/CALCKEY.md index fb5658428..942fee508 100644 --- a/CALCKEY.md +++ b/CALCKEY.md @@ -21,7 +21,6 @@ ## Work in progress -- Less cluttered notification summary - Admin custom CSS - Improve accesibility score
Current Misskey score is 57/100 @@ -42,6 +41,7 @@ - [Profile background as banner](https://codeberg.org/Freeplay/Misskey-Tweaks/src/branch/main/snippets/profile-background.styl) - Better timeline top bar - Mark as read from notifications widget +- Less cluttered notification summary - Better welcome screen (not logged in) - Ability to turn off "Connection lost" message - Raw instance info only for moderators diff --git a/packages/client/src/scripts/get-note-summary.ts b/packages/client/src/scripts/get-note-summary.ts index 348351206..78967df40 100644 --- a/packages/client/src/scripts/get-note-summary.ts +++ b/packages/client/src/scripts/get-note-summary.ts @@ -6,9 +6,11 @@ import { i18n } from '@/i18n'; * @param {*} note (packされた)投稿 */ export const getNoteSummary = (note: misskey.entities.Note): string => { + /* if (note.deletedAt) { return `(${i18n.ts.deletedNote})`; } + */ let summary = ''; @@ -29,6 +31,8 @@ export const getNoteSummary = (note: misskey.entities.Note): string => { summary += ` (${i18n.ts.poll})`; } + /* + // 返信のとき if (note.replyId) { if (note.reply) { @@ -47,5 +51,7 @@ export const getNoteSummary = (note: misskey.entities.Note): string => { } } + */ + return summary.trim(); };