Last modified: 2010-06-11 21:35:11 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T25869, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 23869 - Allow users to change which sections of the sidebar menu are opened by default
Allow users to change which sections of the sidebar menu are opened by default
Status: RESOLVED WORKSFORME
Product: MediaWiki extensions
Classification: Unclassified
UsabilityInitiative (Other open bugs)
unspecified
All All
: Normal enhancement (vote)
: ---
Assigned To: Trevor Parscal
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2010-06-10 00:14 UTC by Nux
Modified: 2010-06-11 21:35 UTC (History)
4 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Nux 2010-06-10 00:14:26 UTC
Currently the first section is opened by default, which is fine for readers, but not for editors. This is because on pl.wiki we've decided to use the first sections for readers and the second one for editors.

Some solutions:
1. Make the last state permanent at least on one computer (e.g. with cookies that would be valid for a week).
2. Add some save-state button near the menu which would save that state to the database (to be permanent on other computers of the user).
3. List sections of the menu (as defined on the wiki) in one of the sections of preferences. On the list you could simply choose which sections should be opened.
Comment 1 Roan Kattouw 2010-06-10 16:29:29 UTC
(In reply to comment #0)
> Currently the first section is opened by default, which is fine for readers,
> but not for editors. This is because on pl.wiki we've decided to use the first
> sections for readers and the second one for editors.
> 
> Some solutions:
> 1. Make the last state permanent at least on one computer (e.g. with cookies
> that would be valid for a week).
Already done. This feature was improved recently, with the cookies now valid for 30 days.

> 2. Add some save-state button near the menu which would save that state to the
> database (to be permanent on other computers of the user).
Considered doing this earlier, not gonna do it.

> 3. List sections of the menu (as defined on the wiki) in one of the sections of
> preferences. On the list you could simply choose which sections should be
> opened.
This is not really very different from #2, and undesirable for many of the same reasons.
Comment 2 Platonides 2010-06-10 16:38:55 UTC
It could not only check the cookie, but also a javascript variable. Then it could be customized in the user vector.js, as well as per wiki.
Comment 3 Nux 2010-06-10 21:24:41 UTC
I think #1 with long term cookies should work, but... Do you refresh the cookies validity?

Let's say today is 2010-07-01 and let's say the default state is:
Interaction - shown, Toolbox - shown, Print/export - shown, Languages - shown

1. @2010-07-01 user sets his favourite sidebar state as: Interaction - hidden, Toolbox - shown, Print/export - hidden, Languages - shown.
2. @2010-07-10 user decides he would like to have languages hidden.
3. @2010-08-02 user logs in and?...
a) sees: Interaction - shown, Toolbox - shown, Print/export - shown, Languages - hidden
b) sees: Interaction - hidden, Toolbox - shown, Print/export - hidden, Languages - hidden

I would expect b), but if cookies are not refreshed a) will happen.
Comment 4 Platonides 2010-06-10 21:27:50 UTC
Clicking on one section doesn't touch the other cookies.
Comment 5 Nux 2010-06-11 08:40:46 UTC
I think you've misunderstood my point. The point was to refresh cookies on each page load.

Algorithm:
var usabCookies = usab.getAllOurCookies();
foreach (usabCookies as cookie)
{
  usab.addCookie(cookie.name, cookie.value, usab.defaultCookieDurtation);
}

And as seems it's not done like that, so that doesn't work for me/us (there are some concerns on our feedback page already).
Comment 6 Roan Kattouw 2010-06-11 19:07:35 UTC
(In reply to comment #5)
> I think you've misunderstood my point. The point was to refresh cookies on each
> page load.
> 
> Algorithm:
> var usabCookies = usab.getAllOurCookies();
> foreach (usabCookies as cookie)
> {
>   usab.addCookie(cookie.name, cookie.value, usab.defaultCookieDurtation);
> }
> 
> And as seems it's not done like that, so that doesn't work for me/us (there are
> some concerns on our feedback page already).
Our code does do this. Whenever it processes a cookie to decide whether to show or hide a section, it renews it. This means cookies get refreshed on every page view where they're used (so viewing a page without a languages section will not renew the cookie for the languages section).

Also, the cookies' expiry time is now 30 days. If you're having trouble with this, it's probably not due to expiring cookies as the code that makes these cookies expire after 30 days was deployed less than 30 days ago.
Comment 7 Nux 2010-06-11 21:35:11 UTC
OK, sorry. Just tested this and it seems to work as expected. Thanks.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links