-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow for a user-triggered search in Block Directory #23894
Comments
Right on! Thanks for working through this flow, @bph. I do like the black button most because it aligns with the "Browse" button currently used. I put together a prototype to help convey this flow. FeedbackShould the "Search Block Directory" button show the block directory blocks below what was already installed and searched for (as I have it in the prototype)? Or should it replace the entire inserter below the tabs as it does when the first search is performed? |
Thanks for this! There were some relevant conversions about this same problem here: |
Thanks @mapk That's a great prototype:-) You captured it nicely. I favor. that the block directory results are displayed underneath already installed blocks that are available for this particular keyword search. Then the user can compare the various preview, if available, and decide if a new block is really better than what they have. |
Interesting discussion #22149
Both scenarios would play out somewhat in the inserter around search results. For block Directory to work / show up in the editor, we need to assume that the person using the search does have plugin install privileges. |
I agree. :)
Just noting: we check for privileges before we show any Block Directory results but that currently only happens when we don't find any blocks and the search is about to begin. |
You're right Shaun. A more subtle link would be better. Here's a go. Another thing to explore is what happens if a pattern or reusable block is listed in the results, but no blocks? Is there an automatic block directory search triggered still? If so do we show both the block directory results and the patterns or reusable blocks? Basically something like @shaunandrews mocked up here. |
The ability to be able to search the Block Directory, even if results are returned, would be extremely useful. If I search for 'images' for example, the Block Inserter will simply show me the core image related blocks. What do I do if if I the core blocks aren't suited to my task and I want to explore other options? I like the solutions proposed by @bph above, but would like to add another suggestion, based on #4. Have the button after the search results, but above the tip, in the block inserter. |
I love @maddisondesigns button idea for this. It really feels that not having the button, doesn't contribute well to discovery of more new blocks that are in the WordPress directory. What do you think? Do you have enough to get this into your development queue? @ryelle @tellyworth @StevenDufresne |
I agree, having a button here would do a lot for discovery. I started a PR a bit ago which does include a button to load more blocks from the block directory (the design there comes from #22149): I want to revisit that in the next few days, I'll make sure to drop a comment here when it's ready for testing 🙂 |
Oh, that's wonderful. Thank you @ryelle - Looking forward to testing this. |
When I was looking for a 'card' block, there wasn't one available on my site and it triggered automatically the Block Directory search. Once the Card block was installed and used on my site, it was always showing up for the 'card' search. But I found this card now a bit limiting and I would want to see what else is in the block directory and find another one, that I previously saw in the list offered.
For now, a user would need to experiment with the keywords to actually trigger another Block Directory search and that would be quite cumbersome. Sooner or later the automatic triggers won't cover all use cases.
I did explored some possible placements for the "Search in Block Directory" link/button
001 Link next to the search box
It would be a good place for discovery. It just feels a bit crowded.
002 bottom of the search results
That's possible. Still has some issues. Mainly it's too disconnected from the search.
Also, a link would indicate it'll take a user away and out of the block editor to a different site, and a user might be hesitant to use it for that reason.
003 a button on bottom
This placement feels do able and reminded me on the "Browse all" button new to the canvas inserter
004 button area on bottom
It feels like it was always there, haha... if you like the idea of a user-triggered Block Directory search.
###5 a black button on the bottom
That last one is just a variation on the background color to be consistent with the "Browse all" button on the other inserter.
###6 Blue button underneath search box
I had second thoughts about the placement on the bottom of the search result, as people might not find it. They might not scroll all the way through the list of results. It looks a bit heavy underneath the search box, but people won't miss it there.... haha.
Those are just a few possibilities. I like number 006 if we can make it work, and number 005 if we have to go on the bottom. But honestly none of them feel right yet. Maybe I just need to give it time? What do you think?
The text was updated successfully, but these errors were encountered: