Problem/Motivation

The module listing filter only surfaces name matches from open category buckets.

Extend___Drupal_D8_Dev.png

When a category bucket is closed, modules that match the name filter are not surfaced.

Extend___Drupal_D8_Dev-2.png

The end user is left with the impression that no modules matched their filter query.

The visibility of a module in the list should not be a criteria for it to be included in a filtered search. The reason a user employes filtering is so that they don't have to scan the list of available modules. If they must first scan the list and make sure that the category that contains the module they want to find is open, then the point of filter is undermined.

Proposed resolution

Surface any module that matches the filter query, regardless of the open state of it's containing category.
Open any closed category buckets that contain a matching module while a filter query is active. Close the category buckets that had been closed before a filter was applied after a filter is removed.

Remaining tasks

Propose a patch.

User interface changes

Filtering will be more useful and match a user's mental model for how a search is supposed to work.

API changes

None.

#2058321: Move the 'place block' UI into the block listing

Original report by jessebeach

Comments

tim.plunkett’s picture

Status: Active » Needs review
StatusFileSize
new713 bytes

There are code comments and incorrect code implying this was always intended. It's just that .show() doesn't work for details.

jessebeach’s picture

Issue tags: +sprint, +Spark
StatusFileSize
new1.78 KB
new1.12 KB

I've added some code to remember what details regions were closed before filtering started, so they can be returned to a closed state after filtering is removed.

tim.plunkett’s picture

Status: Needs review » Reviewed & tested by the community
Issue tags: +JavaScript, +Quick fix

That is slick. I manually tested, it works great.

jibran’s picture

+1 RTBC

nod_’s picture

+1 as well

wim leers’s picture

Nice :)

webchick’s picture

Status: Reviewed & tested by the community » Needs work

I just tested the steps in the OP on simplytest.me (after testing locally and seeing the same thing) on the modules page, but didn't see the reported behaviour. If I collapse "core" and search for "actions" it still says "No results found." Did I do something wrong?

webchick’s picture

tim.plunkett’s picture

StatusFileSize
new15.69 KB

I'm surprised that happened with simplytest, but your browser could still be caching the old JS.
If you're using Chrome, the web dev tools (console, firebug, whatever you call it) has an option to disable the JS cache
Screen Shot 2013-08-09 at 11.12.29 AM.png
When doing this, the patch works as intended.

webchick’s picture

Ok, to clarify what I was seeing, this behaviour is broken in Firefox (using latest 23.0 release on OS X). It works fine in Safari in Chrome, though.

nod_’s picture

Status: Needs work » Needs review
StatusFileSize
new4.72 KB

problems on FF were because of the collapsible polyfill kind of thing we're using for details. It uses jQuery to set style="display:none" or block instead of using the open attribute like it's supposed to.

patch gets rid of the animations for details and use open to say what's visible or not when it's useful.

nod_’s picture

StatusFileSize
new4.66 KB

forgot to remove a line.

webchick’s picture

Awesome, that fixed my problem! Can't really speak to the JS changes though, so leaving at needs review.

webchick’s picture

Hm, still a bit of weirdness. I'll try to explain.

1. Collapse "Core"
2. Mis-type "actions" as "acrions".
3. All of the stuff below the search box goes away (as expected; there's no "acrions" module).
4. Backspace to just "ac" in order to correct the typo.

Expected: Core + "Actions" should appear below the search box. Actual: nothing happens.

Interestingly, if you backspace all the way back to just "a", things start appearing in the table again. Weird.

I'm not 100% sure if this is coming from this patch though or a pre-existing behaviour, so not marking "needs work" yet.

nod_’s picture

StatusFileSize
new1.19 KB
new4.85 KB

fixed the undocumented "feature" from #14.

Attached a quick & dirty interdiff, sue me :p

nod_’s picture

wim leers’s picture

Issue tags: -JavaScript, -Quick fix, -sprint, -Spark
wim leers’s picture

nod_’s picture

Issue summary: View changes
StatusFileSize
new1.89 KB
mgifford’s picture

Status: Needs review » Needs work
Issue tags: +Needs reroll
Related issues: +#2056089: UI problems on the Modules/Extend page

8 months.. Not surprisingly it doesn't seem to want to apply.

stefank’s picture

Assigned: Unassigned » stefank
Issue tags: -Needs reroll
StatusFileSize
new1.57 KB

Re-roll of #19.

stefank’s picture

Assigned: stefank » Unassigned
Status: Needs work » Needs review
nod_’s picture

small nitpick, indent missing from .removeAttr() and .attr() other than that it's good to go, thanks!

stefank’s picture

StatusFileSize
new1.58 KB

Indent fixed. Thanks

nod_’s picture

Status: Needs review » Reviewed & tested by the community

Made the original patch and all but we're starved for reviewers so RTBC. Still works as intended.

( edit ) apologies, I didn't make the original patch, tim and jesse did.

alexpott’s picture

Status: Reviewed & tested by the community » Fixed

Committed 0a66db1 and pushed to 8.x. Thanks!

  • alexpott committed 0a66db1 on 8.x
    Issue #2060573 by nod_, stefank, jessebeach, tim.plunkett: Fixed...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.