This PR is a continuation of the work done in PR #231. It aims to address the incomplete fix I implemented in my previous PR.
The problem addressed by this PR pertains to the handling of 'story' nodes in our component tree. In the current implementation, 'story' nodes, which inherently do not have any children, are incorrectly subjected to a descendants check. This results in the isEmpty flag always being set to true for 'Story' nodes.
Solution
The main changes in this PR include:
Refactoring the search filtering logic into a separate module.
Adding unit tests
While the changes introduced in this PR could have been implemented within the existing component, I chose to refactor them into a separate module, so it's easier to test.
Thanks for submitting a PR for this, and for the test cases! All looks good to me, just made one quick change to match the variable name in the spec file to the function name
Problem
This PR is a continuation of the work done in PR #231. It aims to address the incomplete fix I implemented in my previous PR.
The problem addressed by this PR pertains to the handling of 'story' nodes in our component tree. In the current implementation, 'story' nodes, which inherently do not have any children, are incorrectly subjected to a descendants check. This results in the
isEmpty
flag always being set to true for 'Story' nodes.Solution
The main changes in this PR include:
While the changes introduced in this PR could have been implemented within the existing component, I chose to refactor them into a separate module, so it's easier to test.
Checklist
./bin/test.sh
locally./bin/analyze.sh
locally