Wedge

Public area => The Pub => Features => Topic started by: Arantor on March 4th, 2012, 07:04 PM

Title: Home button
Post by: Arantor on March 4th, 2012, 07:04 PM
While I'd love Wedge to be the base of sites, I know that a significant number of users will be using it as an extra feature on a site they already run, as evidenced by the number of people who want to change where the home tab on the main menu goes.

What I would suggest then is to provide a space to enter a URL into. If the box is empty, all is as it is now, but if the box is filled with a URL, we should put that into the title heading (instead of scripturl) and we should tweak the menu, home would point just to this URL, and what was the home tab will become a "Community" tab with drop downs as we have now.

Thoughts?

(FWIW, XenForo does this.)
Title: Re: Home button
Post by: TE on March 4th, 2012, 07:28 PM
yep, makes sense.
Title: Re: Home button
Post by: spoogs on March 4th, 2012, 07:50 PM
+1
Title: Re: Home button
Post by: Nao on March 4th, 2012, 07:57 PM
Or as an entry in the popup menu for Home? Like when you're on a board.

Maybe also have the main site as the top breadcrumb.
And say Forum instead of Community?
Title: Re: Home button
Post by: Arantor on March 4th, 2012, 08:03 PM
If that were to happen, I'd still make the top level item linking to the main site, then the forum index to be the first item dropdown. (Doing it as a separate tab makes more semantically accurate)

We could do that for the breadcrumb trail in which case, I'd probably make it Site Name > Forum.

I also think Forum is more formal than Community and honestly Community is preferable to me.
Title: Re: Home button
Post by: Nao on March 4th, 2012, 09:50 PM
People may also want to hide the Forum link or rename it. Eg default_index is set to a specific board used as a blog and they just want to link to the blog.
Title: Re: Home button
Post by: Arantor on March 4th, 2012, 10:47 PM
Well, that's the thing... if there's no link specified, it would just be the 'Home' tab as it stands now, without any changes.
Title: Re: Home button
Post by: godboko71 on March 5th, 2012, 02:39 AM
I like this idea a whole heck of allot. I am okay with Community over Forum, I would assume it could be changed in the lang files anyway.
Title: Re: Home button
Post by: Arantor on March 5th, 2012, 02:41 AM
Well, yeah, it would always be changeable in the language files, but the idea of having the separate buttons is the real point here.

It would also, ironically, simplify the work a portal would have to do, too.
Title: Re: Home button
Post by: godboko71 on March 5th, 2012, 02:54 AM
What I meant was its not like it would be hard for people to change the word Community to forum or what ever they wanted. if you added this feature and choose community.
Title: Re: Home button
Post by: Arantor on March 5th, 2012, 02:57 AM
*nods* Indeed not, especially as I'm planning to make the language editor more prominent than it currently is (though I have other matters to solve as far as that goes)
Title: Re: Home button
Post by: Powerbob on March 6th, 2012, 10:12 AM
Quote from godboko71 on March 5th, 2012, 02:54 AM
What I meant was its not like it would be hard for people to change the word Community to forum or what ever they wanted. if you added this feature and choose community.
+1
Title: Re: Home button
Post by: Dismal Shadow on March 6th, 2012, 02:32 PM
Lanuague editor will work in this area. I like 'Community' by default.
Title: Re: Home button
Post by: Arantor on March 6th, 2012, 05:48 PM
:whistle:

Needs an icon for the new 'home' tab because all I've done is created a new extra tab rather than messed with the current home tab, as it were. I'm thinking some kind of 'up' or 'diagonally up/left' arrow to indicate up to the main site?
Title: Re: Home button
Post by: Arantor on March 10th, 2012, 01:26 PM
So, if the house icon stays with the forum menu, what should the icon for the overall site (Home) button be?
Title: Re: Home button
Post by: Nao on March 10th, 2012, 08:28 PM
Same in a different palette?
Title: Re: Home button
Post by: Aaron on March 11th, 2012, 12:50 AM
Why not give the community menu a speech bubble instead?
Title: Re: Home button
Post by: Arantor on March 11th, 2012, 01:05 AM
Well, I was lazy and mindful of a few things. The way it's implemented is that there is the original Home menu and an extra site_home item before it. In the event that the home URL is empty, the site_home item is show = false, and the normal menu is the 'home' item (caption determined the same way). This has the side benefit that all the usual action detection/highlighting the right item works as expected.

In the event that the home URL is populated, this extra menu is show = true, the caption of the regular menu item is also changed, but in all other respects, it's business as usual.

Since the icon is set in CSS, it's keyed off .m_home (which would make the other keyed off .m_site_home)... if we wanted to have the "home button" have the house icon when the extra button is off, but have another icon when not, we'd need to alter the key itself of the menu, so that we can use different CSS for it.

Which would ultimately mean either unsetting and re-inserting a new array item, which isn't the cheapest thing in the world, or we bastardise the menu thusly:

Code: [Select]
'site_home' => array(...),
(empty($settings['home_url']) ? 'home' : 'community') => array(...),

And I'm not even sure that's legal syntax, even if it is, it's ugly. But that's the only ways to do it.
Title: Re: Home button
Post by: Nao on March 11th, 2012, 07:44 AM
You're too concerned about a small detail ;)
Title: Re: Home button
Post by: live627 on March 11th, 2012, 08:00 AM
Ahem... icon,, no icon, icon, icon...  yeah. Either the extra menu item gets an icon or they all go plain text.
Title: Re: Home button
Post by: Nao on March 11th, 2012, 09:30 AM
Again use the same icon. In grayscale.
filter: gray()