Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chronology tooltip #523

Merged
merged 29 commits into from
Jun 18, 2024
Merged

Chronology tooltip #523

merged 29 commits into from
Jun 18, 2024

Conversation

towerofnix
Copy link
Member

Moves chronology links from the nav bar, to contribution tooltips.

Prospit & Derse album page. The nav bar is conspicuously clean-looking, with a completely blank right half. A tooltip is hovered over the 'Cover art by Lexxy (lines)' line, showing Lexxy's external links like usual, then a divider line, then two totally new rows. The symbols are a left arrow and a right arrow, the colorized links are to familiar album names, and the detail text reads, Previous/Next cover art by this artist.

Resolves #520.

Design notes and motivating factors, in no particular order:

  • We've done away with the functionality in recent feature addition Album-scoped chronology links! #470 — we currently don't have a way to see the numbered placement of a particular contribution in an album, or even in the entire wiki. However, generally, links which cross into a different album should stand out by their color, and we find that a nicer and simpler way to tell bounds.
  • Lan: "And UI-wise... hopefully this just feels nicer than having this stuff punted into the nav bar, but in particular we want it to make the content itself feel more dynamic and interactive. The content area is where you find particular credits. The idea is that if they're more fun to actually use and interact with, you're going to spend more time reading them, and find a literal excitement or fun enthusiasm in credit/contribution lists." (#hsmusic-chat)
  • Chronology is now more rigidly specific to the particular kind of contribution (i.e, what field it is part of, and thus what part of the UI it's shown in). Album cover art and track art no longer share the same chronology space; as-artist and as-contributor track credits don't, either. This is in lead-up to more interestingly-divided contribution lists. But, even with the current contribution data, you can still browse more particular ranges than before: just the albums an artist is directly credited on; just the banners or wallpapers an artist's done; just album covers; and flash contributions, too.
  • Because chronology info is fit right into content and only shown on demand, we can fit way more of it into a given page. No qualms with automatically collapsing a tall list, or totally skipping certain kinds of contributions out of spacial concern!

Implementation notes:

  • This is a pretty bulky pull request, but the code is also far neater than the previous (and entirely removed) system.
  • In data, we introduce new nextBySameArtist and previousBySameArtist properties on individual contributions, and supporting infrastructure—similar to thingProperty, contributions get a new artistProperty, and this identifies the reverse contribution list to read off the contribution's (singular) artist. It's very similar behavior as old getChronologyRelations, but is more focused (it only treats a single list as chronology), is isolated to the appropriate area (part of data code, not content), and intrinsically true (the previous/next relations can be understood in a vacuum, by any part of code).
    • It currently assumes the reverse contribution list is chronologically sorted (where "chronologically" is in the correct manner for that particular reverse-list). This may bite us in the butt later, but it appears to be working correctly.
    • There are some new supporting data utilities, and we tidied up documentation about data utilities that are related to each other (it's specified in composite/data/index.js, instead of being manually duplicated in related files).
  • In content, we make a number of changes.
    • All content (and client) code directly related to the old system is removed.
    • linkExternalAsIcon is removed and replaced with more compositional helper utilities, generateExternal{Handle,Icon,Platform}.
    • Tooltip content is moved from linkContribution into generateContributionTooltip, and broken into per-section components, generateContributionTooltip{ExternalLink,Chronology}Section.
    • The "kind" of contribution is passed to linkContribution as a slot, which controls which string is used for chronology info (e.g. "previous track art by this artist"). This is controlled by a component on the level of the particular page, generally slotted into generateReleaseInfoContributionsLine or generateContributionList.
  • On the client, in order to support larger tooltips, we did Improve tooltip placement dynamics! #522.

Sorry, this is just maintaining the test paths that exist and
dropping the ones which don't apply anymore.
This is unfortunately necessary to avoid the meaningless
'text-with-tooltip-interaction-cue' class (if there's no
tooltip).
@towerofnix towerofnix merged commit 2205ccb into preview Jun 18, 2024
@towerofnix towerofnix deleted the chronology2 branch June 18, 2024 21:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Move chronology links to contribution tooltip
1 participant