[Refactor/Fix] Fix issue introduced by last commit + refactor code
[Feature] Improve finding of best match for directional navigation
[Feature/Refactor] Further improvement for finding best match for directional navigation + minor refactoring