-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Deprecate confusing option names #1692
Merged
Merged
Changes from 2 commits
Commits
Show all changes
16 commits
Select commit
Hold shift + click to select a range
1b7481b
Revert "Revert "Deprecate confusing option names""
Hypnosphi 2233afd
Produce warning only in development
Hypnosphi 42c2c32
Merge branch 'master' into deprecate-left-down
Hypnosphi a6bd343
Merge remote-tracking branch 'upstream/master' into deprecate-left-down
Hypnosphi b222423
Merge remote-tracking branch 'upstream/deprecate-left-down' into depr…
Hypnosphi 1ad0dec
String literals in features enum
Hypnosphi c54d4e8
Merge branch 'master' into deprecate-left-down
Hypnosphi 30b02e7
merge master
Hypnosphi b977189
Merge remote-tracking branch 'upstream/master' into deprecate-left-down
Hypnosphi 4cf8e68
Merge branch 'master' into deprecate-left-down
Hypnosphi 5bebf15
Merge branch 'master' into deprecate-left-down
Hypnosphi bb21744
Merge branch 'master' into deprecate-left-down
Hypnosphi eee06c4
Merge branch 'master' into deprecate-left-down
Hypnosphi ed9327e
Merge branch 'master' into deprecate-left-down
Hypnosphi 5cd67ff
Merge remote-tracking branch 'upstream/release/3.3' into deprecate-le…
Hypnosphi 26307a0
Update addons/options README
Hypnosphi File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,14 +2,14 @@ import keycode from 'keycode'; | |
|
||
export const features = { | ||
FULLSCREEN: 1, | ||
DOWN_PANEL: 2, | ||
LEFT_PANEL: 3, | ||
ADDON_PANEL: 2, | ||
NAVIGATION_PANEL: 3, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why everywhere it's called "Stories Panel" but here is "Navigation Panel"? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. My bad, skipped when refactoring |
||
SHORTCUTS_HELP: 4, | ||
ESCAPE: 5, | ||
NEXT_STORY: 6, | ||
PREV_STORY: 7, | ||
SHOW_SEARCH: 8, | ||
DOWN_PANEL_IN_RIGHT: 9, | ||
ADDON_PANEL_IN_RIGHT: 9, | ||
}; | ||
|
||
export function isModifierPressed(e) { | ||
|
@@ -42,10 +42,10 @@ export default function handle(e) { | |
return features.FULLSCREEN; | ||
case keycode('D'): | ||
e.preventDefault(); | ||
return features.DOWN_PANEL; | ||
return features.ADDON_PANEL; | ||
case keycode('L'): | ||
e.preventDefault(); | ||
return features.LEFT_PANEL; | ||
return features.NAVIGATION_PANEL; | ||
case keycode('right'): | ||
e.preventDefault(); | ||
return features.NEXT_STORY; | ||
|
@@ -57,7 +57,7 @@ export default function handle(e) { | |
return features.SHOW_SEARCH; | ||
case keycode('J'): | ||
e.preventDefault(); | ||
return features.DOWN_PANEL_IN_RIGHT; | ||
return features.ADDON_PANEL_IN_RIGHT; | ||
default: | ||
return false; | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe it's a good time to also switch from numbers to literals here, what do you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice idea