Open-CSP / WikiSearchFront

Front-end for the WikiSearch extension.
GNU General Public License v2.0
4 stars 6 forks source link

Would it be possible to implement a filter by category ? #8

Open bertrandgorge opened 1 year ago

bertrandgorge commented 1 year ago

Hello,

I have a number of pages that are organized by category, with multiple depth: https://wiki.tripleperformance.fr/wiki/Maladies

Using a semantic query like [[Category:My category]] it is possible to get all pages in the category and subcategories. I'm not sure how I can use that feature with WikiSearchFront ?

robis24 commented 1 year ago

I'm not familiar with the workings of categories, could you maybe post the output of format=debug of your ask query?

bertrandgorge commented 1 year ago

Generally speaking, when you have nested categories, like:

A
   A.1
   A.2
B
   B.1 

Then a page in A.2 will be matched by the syntax: {{#ask: [[Category:A]] }}

What would be nice is that on the left, in the search facets, you could have something like:

|@Category:A 

In which case a nested drop down would show A, A.1 and A.2 and filter as such.