mirror of
https://iceshrimp.dev/limepotato/jormungandr-bite.git
synced 2025-01-27 01:46:25 -07:00
Fix show more button being shown when more than 4 images inside CW
This commit is contained in:
parent
0e931cb080
commit
822c9f0d63
1 changed files with 13 additions and 7 deletions
|
@ -209,13 +209,19 @@ const emit = defineEmits<{
|
||||||
|
|
||||||
const cwButton = ref<HTMLElement>();
|
const cwButton = ref<HTMLElement>();
|
||||||
const showMoreButton = ref<HTMLElement>();
|
const showMoreButton = ref<HTMLElement>();
|
||||||
const isLong =
|
|
||||||
!props.detailedView &&
|
const isLong = !props.detailedView && props.note.cw == null &&
|
||||||
((props.note.cw == null &&
|
(
|
||||||
props.note.text != null &&
|
(
|
||||||
(props.note.text.split("\n").length > 10 ||
|
props.note.text != null &&
|
||||||
props.note.text.length > 800)) ||
|
(
|
||||||
props.note.files.length > 4);
|
props.note.text.split("\n").length > 10 ||
|
||||||
|
props.note.text.length > 800
|
||||||
|
)
|
||||||
|
) ||
|
||||||
|
props.note.files.length > 4
|
||||||
|
)
|
||||||
|
;
|
||||||
|
|
||||||
const collapsed = $ref(props.note.cw == null && isLong);
|
const collapsed = $ref(props.note.cw == null && isLong);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue