There have been some requests to make it possible for Mastodon users to create threads on Lemmy. At the moment this is not possible because Mastodon cant set the title field which is mandatory in Lemmy. The same problem affects other projects like Pleroma or Friendica (where title is optional).
It is unlikely that Mastodon would make any change in this regard, so a workaround in Lemmy would be necessary. I implemented such a workaround which makes the title optional when receiving a federated post, and uses the first line of the content instead. This workaround could also be made configurable per instance or per community.
But to be honest I am not sure the workaround is a good idea in general, as it could result in bad titles, and generally more low-quality posts. Thats why I want to know what the community thinks about it.
Could you show an example screenshot how that looks like? I cant really imagine it working in Lemmy.
Sure I’ll try mocking something up in the browser devtools. On mobile, lemmy displays body text for posts (p.s. I’d like that on desktop too). What I’m talking about is just showing that in the position the title would be, still in an anchor tag so it links to the post but with body text styling instead of in a header.
EDIT: Here’s a quick mockup.
The first and third posts are title-less posts and, to me, look good interspersed with titled posts. To get this, I replaced the entire
h5
element that serves as the post title with<a class="preview-lines" href="{{post.link}}">{{made up body text}}</a>
Thepreview-lines
CSS class applies a visual truncation so even if the text we render is too much it won’t overflow.I don’t know how to write Inferno templates but in Vue this would be
<!-- this is the current markup --> <h5 v-if="post.title"> <a class="text-body" title="Comments" :href="post.link"> {{ post.title }} </a> <button class="btn btn-link text-monospace text-muted small d-inline-block ml-2" data-tippy-content="Expand here"> <svg class="icon icon-inline"> <use xlink:href="#icon-plus-square"></use> <div class="sr-only"><title>plus-square</title></div> </svg> </button> </h5> <!-- this is new markup i'm suggesting --> <a v-else class="preview-lines" :href="post.link"> {{ post.content.substring(0, 250) }} </a>
So you have the same approach of generating a title from the post body. Only you do it on the frontend and not the backend. In Lemmy that might be a bit complicated because the body is already optional, and we would have to somehow encode that either title or body must be set (or both).