New feature: Tag Tooltips

Posted under Bugs & Features

Tag tooltips are live on testbooru.

https://testbooru.donmai.us/

Go and test it. Play with it, break it and report back here with any feedbacks or grievances you might have so the feature can be refined further before we put it in the main site.

Key points:

  • it picks the first paragraph and the first embedded asset/post
    • "the first paragraph" means "all text until the first empty new line"
    • 1girl: "An image containing one female character." is the first paragraph, because it's followed by an empty new line
    • this might be changed to show all text but truncating with a fade like wikipedia does so we avoid any scrolling inside the tooltip
  • the image tooltip is shown above if the image is very wide, otherwise on the left. This is subject to change to find the sweet spot (large images should probably be larger to cover the gap), but we need a lot of testing to get it right
  • if there's no meaningful text in a wiki, an embed is not shown, to encourage people to write useful wikis
    • during early tests this seems to be a bit confusing, so it might be changed to contain a placeholder text to encourage people to write better wikis
  • artist tags only show a wiki preview if they already have one, otherwise they just say "Artist.". They don't show embeds either, because we don't want to encourage artist wikis for many reasons
  • animated posts only show a static preview
  • it supports nested tooltips
  • the tooltips work on the sidebar, post tooltips, wiki pages, implication notices, BURs, etc
  • it's disabled by the same "disable tooltips" account setting that already controls post tooltips

Things that need testing:

  • behavior with very large/very tall/weird images/image formats
  • behavior with a lot of text to decide how much/if cutoff is needed
  • behavior with very little test to decide how the image should look like, how much space, etc
  • behavior with weird text, weird characters, weird tag names
  • behavior of very nested tooltips
  • behavior on multiple browser, weird mouse movements, etc
  • places where it doesn't work. If you find them, report here

See pull #6639 for the code details.

Previews:

Updated by nonamethanks

Didn't find any right now, but are there some wiki that have only "Non example" images ? if so, it might show the non example in the tooltip that may induce in error,

Talking about non examples, cutting of after the 1st paragrah and asset/post might cut them off like two side up (which is valuable info here).
Checking two side up specifically, the text gets cut-off way too soon because it keeps only the 1st paragraph.

Wiki

A hairstyle in which two locks of hair are tied up on both sides of the head while the back of the hair hangs normally. The amount of hair tied up doesn't matter, only that the back of the hair falls down loosely.

Not to be confused with twintails, where all of the hair is tied up into two ponytails and nothing is left to fall freely.

Examples include Tohsaka Rin, Ultimate Madoka, Onozuka Komachi, most depictions of Kawashiro Nitori, Nena Trinity, and Souryuu Asuka Langley.

Tooltip

A hairstyle in which two locks of hair are tied up on both sides of the head while the back of the hair hangs normally. The amount of hair tied up doesn't matter, only that the back of the hair falls down loosely.


I don't know if that's something you can easily change and is worth the time to change, the tooltip shows the tag above, which itself will open the same tooltip if you hover over it, minor annoyance though.

Also, imho, wide images below the text would look more aesthetic.


For artist tooltips,

They don't show embeds either, because we don't want to encourage artist wikis for many reasons

Does that include the original character list ? This is something I think would be a plus to see in the tooltip

Updated by Researcher

Researcher said in forum #466534:

Didn't find any right now, but are there some wiki that have only "Non example" images ? if so, it might show the non example in the tooltip that may induce in error,

i feel like the fault would lie on the wiki writer for structuring the page in such a stupid way. it doesn't make sense to provide counterexamples without any actual examples.

Deployed some changes to address the various feedback. Check them out on testbooru.

Our wikis tend to have a single initial line followed by a lot of explanation, so showing a single line doesn't work well. I changed them to fade out after a certain height, like wikipedia does, and I think it looks better for us.

When this goes to betabooru it'll likely only be deployed for dtext embeds at first (forum posts/wiki pages/comments), so people can get used to it and we can get more feedback before it's enabled everywhere else.

mikf said in forum #466460:

Hovering over the tag name inside a tag tooltip opens another tooltip of the same tag.

That's an existing bug that affects user tooltips too. I found it useful in testing to check out stuff like implications from tooltips, but it should probably be disabled everywhere.

1