Camelot icon indicating copy to clipboard operation
Camelot copied to clipboard

Feature/quick search

Open iksi4prs opened this issue 1 year ago • 4 comments

Filters out item as you time. Can be controlled via settings as was requested here - https://github.com/IngvarX/Camelot/issues/59

image

iksi4prs avatar Nov 12 '23 09:11 iksi4prs

Codecov Report

Attention: 86 lines in your changes are missing coverage. Please review.

Comparison is base (3330b67) 92.89% compared to head (14abb1d) 91.42%.

Files Patch % Lines
...tions/MainWindow/FilePanels/FilesPanelViewModel.cs 31.81% 27 Missing and 3 partials :warning:
...ions/MainWindow/FilePanels/QuickSearchViewModel.cs 47.36% 19 Missing and 1 partial :warning:
...lementations/Settings/KeyboardSettingsViewModel.cs 20.00% 16 Missing :warning:
src/Camelot.Services/QuickSearchService.cs 57.89% 8 Missing :warning:
...ifications/QuickSearch/QuickSearchSpecification.cs 0.00% 6 Missing :warning:
...s/MainWindow/FilePanels/QuickSearchCommandModel.cs 0.00% 6 Missing :warning:

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@            Coverage Diff             @@
##           master      #66      +/-   ##
==========================================
- Coverage   92.89%   91.42%   -1.48%     
==========================================
  Files         185      192       +7     
  Lines        4830     4967     +137     
  Branches      388      403      +15     
==========================================
+ Hits         4487     4541      +54     
- Misses        288      368      +80     
- Partials       55       58       +3     

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov-commenter avatar Nov 12 '23 09:11 codecov-commenter

I will be working on refactoring this PR. It will take me at least a couple of days. Few bugs that I've noticed:

  • Sometimes key selects the first item ([..]) while it shouldn't
  • If you have no items in search Esc is the only way to close the search. If you click on other tab with mouse filtering remains the same and you have to switch back via Tab to close it. Not very convenient

TODOs left:

  • ~~Use commands to call FPVM~~
  • Fix the issue with the parent directory correctly
  • Allow to Esc by clicking on the second tab
  • Add tests
  • Make sure code formatting is ok everywhere
  • ~~Verify that dynamic creation/deletion of files when quick search is on doesn't break anything~~ Verified: broken
  • Check if files filtering code can be improved

IngvarX avatar Nov 13 '23 01:11 IngvarX

Update: I managed to rewrite files filtering code but still need to address selection logic changes. I'll keep the code locally for now because it's working only partially at the moment

IngvarX avatar Nov 27 '23 04:11 IngvarX

Pushed a refactored revision, here is what's left:

  • Fix the issue with the parent directory
  • Allow to Esc by clicking on the second tab/when no files are found
  • ~Fix broken tests and~ add new unit/integration tests

IngvarX avatar Nov 27 '23 07:11 IngvarX