enhance: 自動でたたまれる機能が返信先や引用RNにも適用されるように (#10989)

* 返信、引用RNでMFMがあったら自動で隠すように

* Update CHANGELOG.md

* Update MkSubNoteContent.vue

* refactor: avoid `Boolean`

* docs: update CHANGELOG.md

---------

Co-authored-by: Acid Chicken (硫酸鶏) <root@acid-chicken.com>
This commit is contained in:
kabo2468 2023-07-21 18:58:57 +09:00 committed by GitHub
parent b3358f0a8b
commit a8cd8ed99e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 25 additions and 16 deletions

View file

@ -31,16 +31,13 @@ import MkMediaList from '@/components/MkMediaList.vue';
import MkPoll from '@/components/MkPoll.vue';
import { i18n } from '@/i18n';
import { $i } from '@/account';
import { shouldCollapsed } from '@/scripts/collapsed';
const props = defineProps<{
note: misskey.entities.Note;
}>();
const isLong =
props.note.cw == null && props.note.text != null && (
(props.note.text.split('\n').length > 9) ||
(props.note.text.length > 500)
);
const isLong = shouldCollapsed(props.note);
const collapsed = $ref(isLong);
</script>