Skip to main content
Topic: dropdown linktree instead of jump to (Read 14860 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

dropdown linktree instead of jump to

Quote from: emanuele –
 emanuele is thinking of adding a cool thing to the link tree: have you seen how nowadays file manages handle these things? O:) (that would make the "jump to" completely useless)

ETA: even though I have no clear idea how to realize it. :P

The idea is born while writing, so NFI what it should look like, or how to create it.
The basic idea is: click on the arrow (or the board/category name) of the linktree and a dropdown/menu-like appears with the list of boards on the same level.

I would love to have multi level menu-like system able to show subboards too.
Last Edit: December 10, 2012, 05:54:22 pm by emanuele
Bugs creator.
Features destroyer.
Template killer.

Re: dropdown linktree instead of jomp to

Reply #1

Oh no. You can't be serious. Fer chrissake, the jump to is useless anyway. I've never used it in five years except to see what it did. In fact I've just gone and deleted it from my site because nobody else though it was worth keeping anyway, so there was no point running all the crap it required to make it work.
Master of Expletives: Now with improved family f@&king friendliness! :D

Sources code: making easy front end changes difficult since 1873. :P

Re: dropdown linktree instead of jomp to

Reply #2

I think it would be much better on the linktree. After all, that's the exact place that lists your 'path'.

With the sole condition that it doesn't agglomerate the view perhaps... For a small number of boards, I figure it'd be very nice. For a large number of boards and sub-boards... I don't have any good idea how to do it, to be friendly and readable.
The best moment for testing your PR is right after you merge it. Can't miss with that one.

Re: dropdown linktree instead of jomp to

Reply #3

Quote from: emanuele – The basic idea is: click on the arrow (or the board/category name) of the linktree...
Just noting that the last suggestion would not work. The last thing most people would want is to get a drop down when they clicked a nav link.

If you really want to do this (and I'm totally against it) it would have to be done by having an indicator link between the standard nav links. However, at this stage I would greatly prefer of it was not added to default and was trialed as a, you guessed it, offical mod. See if anyone gives a damn before adding bloat. :)
Master of Expletives: Now with improved family f@&king friendliness! :D

Sources code: making easy front end changes difficult since 1873. :P

Re: dropdown linktree instead of jomp to

Reply #4

Quote from: Antechinus –
Quote from: emanuele – The basic idea is: click on the arrow (or the board/category name) of the linktree...
Just noting that the last suggestion would not work. The last thing most people would want is to get a drop down when they clicked a nav link.
Yeah, that may be the reason SMF is full of features nobody knows until one looks at the code... lol

Quote from: Antechinus – If you really want to do this (and I'm totally against it) it would have to be done by having an indicator link between the standard nav links. However, at this stage I would greatly prefer of it was not added to default and was trialed as a, you guessed it, offical mod. See if anyone gives a damn before adding bloat. :)
Oh, well. Since javascript shall be enough to do everything I'll put up the thing to see how it would look, then up to you decide what to do. :P
Bugs creator.
Features destroyer.
Template killer.

Re: dropdown linktree instead of jump to

Reply #5

On a somewhat related note, another option might be to approach things a bit differently. I notice that we now have single category view enabled (which I think is a good option to have).

It would be very easy to also allow an option for a subsiduary menu bar, consisting of links to each single category. This is likely to be far less unwieldy than a list of boards. Could be done several ways.

  • Dropdown from linktree (not real keen on that, for a few reasons)
  • Separate row of tabs across the top of board index (below linktree)
  • Select or similar, wherever it fits best.

Given that the code for churning out the categories is already in BoardIndex.template.php, it seems to me that this is the obvious place for such a gizmo.
Master of Expletives: Now with improved family f@&king friendliness! :D

Sources code: making easy front end changes difficult since 1873. :P

Re: dropdown linktree instead of jump to

Reply #6

Tracked: https://github.com/elkarte/Elkarte/issues/228

Feel free to propose a working nicer alternative than jump to.
The best moment for testing your PR is right after you merge it. Can't miss with that one.

Re: dropdown linktree instead of jump to

Reply #7

 emanuele has been working from time to time on that
I was trying to give the possibility to easily expand the dropdown from the linktree, though not being a js expert I'm having some difficulties... (not to mention that I didn't even start the main thing... :P)
Bugs creator.
Features destroyer.
Template killer.

Re: dropdown linktree instead of jump to

Reply #8

@emanuele do you have some code in hand related to this... seems pretty interesting

Re: dropdown linktree instead of jump to

Reply #9

Nope, I think I started write down something, but it was about 20 lines of code, probably lost in one of the tens of branches I have around, but anyway nothing worth the hassle of reading it.

Anyway, it shouldn't be that complex either: I suppose an ajax call when hovering or clicking the entry (or an arrow close to it) and then a droppy of some kind.
Bugs creator.
Features destroyer.
Template killer.

Re: dropdown linktree instead of jump to

Reply #10

Quote from: emanuele – Nope, I think I started write down something, but it was about 20 lines of code, probably lost in one of the tens of branches I have around, but anyway nothing worth the hassle of reading it.

Anyway, it shouldn't be that complex either: I suppose an ajax call when hovering or clicking the entry (or an arrow close to it) and then a droppy of some kind.
I was thinking of getting the data(of dropdown) with the data of topic/board. Next to names in linktree, add an arrow, and add the data to arrow using ul/li structure. Now using simple css
- by default keep the ul containing the dropdown data hidden,
- and when someone hovers over the arrow, make ul visible

Just a thought.

Re: dropdown linktree instead of jump to

Reply #11

Yes, that was probably my first idea as well, though I think there are a couple of problems with it:
1) the structure of the linktree becomes pretty complex (bad for accessibility),
2) when you are in a topic you have to load the boards and categories structure of all the ancestors while loading the page (that may be quite a bit of overhead).
Bugs creator.
Features destroyer.
Template killer.

Re: dropdown linktree instead of jump to

Reply #12

Quote from: emanuele – Yes, that was probably my first idea as well, though I think there are a couple of problems with it:
1) the structure of the linktree becomes pretty complex (bad for accessibility),
Umm, that can be overcome, we can optimise the HTML structure.

Quote from: emanuele – 2) when you are in a topic you have to load the boards and categories structure of all the ancestors while loading the page (that may be quite a bit of overhead).
This can be a real issue. So, going by your last suggestion,

1. Mouseenter, on arrow/image/whatever we make an ajax call
2. place the data in a array/object of JS
3. and populate the data in container and display it
4. Mouseleave, destroy the container
5. Mouse re-enters, repeat from step 3

Sounds good?

Re: dropdown linktree instead of jump to

Reply #13

I would consider not to destroy the container at step 4, it would save in case of 5 on the same element... if possible, I'm still fighting with ajax... :'(

But yes, it looks good! :D
Bugs creator.
Features destroyer.
Template killer.

Re: dropdown linktree instead of jump to

Reply #14

Quote from: emanuele – I would consider not to destroy the container at step 4, it would save in case of 5 on the same element... if possible, I'm still fighting with ajax... :'(

But yes, it looks good! :D
Lol, I was reading your reply and was playing with linktree(for folders on left hand) of 'Google Drive', and they do exactly the same expect the step 4. So, I'll start implementing this by keep the containers intact on DOM.