Project

General

Profile

Feature #2618

Filter out ES results matching section name but not at the leaf level

Added by Ram Kordale about 2 years ago. Updated about 2 years ago.

Status:
Closed
Priority:
Urgent
Assignee:
Target version:
Start date:
09/18/2022
Due date:
09/19/2022
% Done:

100%

Estimated time:
1.50 h
Spent time:

Description

ES matches search terms in section names, content etc based on settings.

With the current settings, when ES matches a section name, it returns results where the actual match is in section name at level D1 which is not at the deepest (leaf) level. This results in undesired user experience such as the example below.

Select 'Python 3 Doc: All' and search for "class".

Multiple entries from 3rd are children of 'Python 3 Doc Library Reference > Python Runtime Services > dataclasses — Data Classes'.

After this ticket, we should end up with this parent document and only one of its child documents with 'Class Variables' as the section name.

Possible solution: I have added two occurrences of removeUnnecessaryChildren in https://docs.google.com/document/d/1-5tjuY4oX3vIiR9xpqwlOCQ-JhBcRxe6CMI5IPGavqQ/edit#. X in removeUnnecessaryChildren can be decided based on what works for the example above.

Also available in: Atom PDF