This repository has been archived by the owner on Nov 28, 2022. It is now read-only.
Fix GhTokenInput not handling keyboard shortcut bug. #1707
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
closes TryGhost/Ghost#11786
It was because ember-power-select was stopping the propagation of the events when ctrl/cmd or meta key is down.
Explanation in more detail
GhTokenInput
usesPowerSelect
component ofember-power-select
internally inapp/components/gh-token-input/select-multiple
.When you open that component, you can find that it calls
stopImmediatePropagation
when ctrl/cmd or meta key is down.Because of that, I had to dispatch event directly to the root of the Ghost admin app.
ember test
from the repo root - will becore/client
if working from the submodule in Ghost).More info can be found by clicking the "guidelines for contributing" link above.