nunocoracao / blowfish

Personal Website & Blog Theme for Hugo

Home Page:https://blowfish.page

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

๐Ÿ–Œ๏ธ Long ToCs not shown fully

wermos opened this issue ยท comments

Description

A good example of the bug is in the documentation itself, here. When the table of contents is really long, it is impossible to see all the options until you scroll to the bottom of the page.

Expected behavior

One relatively simple solution I can think of, is to make the ToC scrollable, independent of the main page's scroll.

Screenshots

image

In the above screenshot, it is not possible to see the text below "Firebase" until you scroll to the bottom of the page.

Desktop (please complete the following information):
Even though I don't think it's applicable here, I'll fill it regardless.

  • OS: Windows 11 23H2, OS Build 22361.3447
  • Browser: Edge
  • Version: 124.0.2478.80 (Official build) (64-bit)

The table of content definitely should NOT be scrollable independently of the main page's content. It would look very bad.

My proposed solution was just the first thing that came to mind. I am open to other solutions.

Hi,

Even if we are a minority, may we disagree on the bold (subjective) statement "(...it) should NOT be scrollable (...) It would look very bad" ?!

Typing "Best Practices" + "Table of Contents" in your preferred search engine may show you how many (different) opinions you can have about the "how to do things properly".

That being said, the purpose of a ToC is to provide a way to be able to "jump" quickly anywhere in your document (online / offline ... or even printed = your fingers doing the same job as your browser ๐Ÿ˜…).

So, even if a majority disagree, some of us may be allowed to think that making it available only partially (I agree the configuration page of Blowfish website is not that big ๐Ÿ˜… ... but it was just an example) is not the best/expected behavior.

The same way, @nunocoracao may not give a damn about it, think it's too much work for a too small audience ... or have other priorities ๐Ÿคท

In worst case, we'll have to switch to another (rare) theme providing this kind of feature, mainly for docs (like Doks) or learning (ex.: Relearn), but, on a more subjective point of view, most of them are not as nice/polished as Blowfish ๐Ÿ˜…

On a more constructive note (having filled the issue #1455, marked as closed a little too fast ๐Ÿ˜‡, for the very same reasons), may I propose: (in order of priority, as I see them)

  1. at least a smartTOCPosition configuration entry, so those producing big documents can benefit from a "full ToC" placed at the beginning/end, the same way Blowfish handles posts series = the behavior / responsiveness / etc. being already implemented, it should be easily adapted ๐Ÿค”

  2. to keep the ToC "in sync" with the main content (the anchor in the main panel should be visible in the ToC lateral panel)

  3. a smartTOCBehavior configuration entry, allowing collapsible and/or scrollable ... for those who like it that way ๐Ÿ˜…

May I end by saying that the choice should always be given to users. But time being such a rare commodity, as always, @nunocoracao will have the final say ... thanks for considering this ๐Ÿ™‡

Even if we are a minority, may we disagree on the bold (subjective) statement "(...it) should NOT be scrollable (...) It would look very bad" ?!

Typing "Best Practices" + "Table of Contents" in your preferred search engine may show you how many (different) opinions you can have about the "how to do things properly".

I have never seen a scrollable table of contents placed in similar way like the one in Blowfish. I suppose that's for a reason, because it would be an objectively bad design choice. If you think otherwise then show some examples on other websites and implement it in Blowfish as a proof of concept.