Skip to content
This repository has been archived by the owner on Mar 8, 2019. It is now read-only.

Component: Project Auto-Complete #1

Open
nerdstein opened this issue Mar 11, 2018 · 3 comments
Open

Component: Project Auto-Complete #1

nerdstein opened this issue Mar 11, 2018 · 3 comments

Comments

@nerdstein
Copy link
Owner

Design reference: https://www.drupal.org/files/issues/2018-03-08/simplytest-ui.png

Create an autocomplete widget for the main project search.

Please use the "node" JSON feeds with filters for modules, themes, and distributions. The Drupal core project (machine name "drupal") should be hardcoded to avoid pulling in the old legacy Drupal core forks found in the feed.

Please note that the feeds are paginated. Some research should be done to pass a partial string filter for the project name and return a filtered set of projects. If this feature does not exist, we can file an issue on the DrupalOrg project and I can write a patch.

Feed URLs:

  1. Themes - https://www.drupal.org/api-d7/node.json?type=project_theme
  2. Modules - https://www.drupal.org/api-d7/node.json?type=project_module
  3. Distributions - https://www.drupal.org/api-d7/node.json?type=project_distribution

Details on the feeds can be found here: https://www.drupal.org/drupalorg/docs/api

@porkloin
Copy link
Contributor

Spent some time last night digging through the RESTWS/drupalorg api docs, and it doesn't appear that there is any way to do any kind of "fuzzy" search. We can filter (https://www.drupal.org/api-d7/node.json?field_project_machine_name=paragraphs), but unless the filtering string exactly matches a project machine name, it returns nothing (https://www.drupal.org/api-d7/node.json?field_project_machine_name=paragra). Likewise, there isn't any sort of query/search exposed over the api (something like https://www.drupal.org/api-d7/node.json?q=paragra). Looks like we'll probably need to file an issue on D.O. to get that implemented!

@nerdstein
Copy link
Owner Author

@porkloin - this makes sense.

We should file an issue here - https://www.drupal.org/project/drupalorg. I am guessing it just needs to be tied to the project name or machine name at this point.

I was able to work on another issue in that queue before to add the author username. I have a sandbox already. I can reuse these things to get the wildcard search in place

@porkloin
Copy link
Contributor

@nerdstein I submitted a patch on the D7 version of RESTWS issue queue: https://www.drupal.org/project/restws/issues/2496595

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants