Encapsulate `CommandPaletteFilter` and `CommandPaletteInterceptor` (#9402)

This PR refactors the `CommandPaletteFilter` and
`CommandPaletteInterceptor` to better encapsulate their internals.

Previously these globals and their fields were publicly accessible,
which meant that there was a lot of reaching in and making
modifications.

These changes should make it easier to add additional consumers of these
hooks (right now they're primarily used by Vim mode).

Release Notes:

- N/A
55f4c8e51bMarshall Bowers committed on 3/15/2024, 4:37:25 PM· committed by GitHubparentd311a4b
6 files changedLine totals unavailable