fix typos

This commit is contained in:
Hakim El Hattab 2019-04-01 13:11:29 +02:00
parent 94cbfcbdf6
commit e6fa04d485
2 changed files with 16 additions and 14 deletions

View File

@ -146,8 +146,8 @@
// 1.3 2.3 // 1.3 2.3
// //
// If you're on slide 1.3 and navigate right, you will normally move // If you're on slide 1.3 and navigate right, you will normally move
// from 1.3 -> 2.1. With "gridNavigation" enabled the same navigation // from 1.3 -> 2.1. If "grid" is used, the same navigation takes you
// takes you from 1.3 -> 2.3. // from 1.3 -> 2.3.
navigationMode: 'default', navigationMode: 'default',
// Randomizes the order of slides each time the presentation loads // Randomizes the order of slides each time the presentation loads
@ -374,7 +374,8 @@
threshold: 40 threshold: 40
}, },
// Holds information about the keyboard shortcuts (filled in on configuration). // A key:value map of shortcut keyboard keys and descriptions of
// the actions they trigger, generated in #configure()
keyboardShortcuts = {}, keyboardShortcuts = {},
// Holds custom key code mappings // Holds custom key code mappings
@ -1432,24 +1433,25 @@
dom.wrapper.removeAttribute( 'data-navigation-mode' ); dom.wrapper.removeAttribute( 'data-navigation-mode' );
} }
// Define our contextual list of keyboard shortcuts
if( config.navigationMode === 'linear' ) { if( config.navigationMode === 'linear' ) {
keyboardShortcuts['N , SPACE , → , L , ↓ , J'] = 'Next slide'; keyboardShortcuts['→ , ↓ , SPACE , N , L , J'] = 'Next slide';
keyboardShortcuts['P , ← , H , ↑ , K'] = 'Previous slide'; keyboardShortcuts['← , ↑ , P , H , K'] = 'Previous slide';
} }
else { else {
keyboardShortcuts['N , SPACE'] = 'Next slide'; keyboardShortcuts['N , SPACE'] = 'Next slide';
keyboardShortcuts['P'] = 'Previous slide'; keyboardShortcuts['P'] = 'Previous slide';
keyboardShortcuts['← , H'] = 'Navigate left'; keyboardShortcuts['← , H'] = 'Navigate left';
keyboardShortcuts['→ , L'] = 'Navigate right'; keyboardShortcuts['→ , L'] = 'Navigate right';
keyboardShortcuts['↑ , K'] = 'Navigate up'; keyboardShortcuts['↑ , K'] = 'Navigate up';
keyboardShortcuts['↓ , J'] = 'Navigate down'; keyboardShortcuts['↓ , J'] = 'Navigate down';
} }
keyboardShortcuts['Home , ⌘/CTRL ←'] = 'First slide'; keyboardShortcuts['Home , ⌘/CTRL ←'] = 'First slide';
keyboardShortcuts['End , ⌘/CTRL →'] = 'Last slide'; keyboardShortcuts['End , ⌘/CTRL →'] = 'Last slide';
keyboardShortcuts['B , .'] = 'Pause'; keyboardShortcuts['B , .'] = 'Pause';
keyboardShortcuts['F'] = 'Fullscreen'; keyboardShortcuts['F'] = 'Fullscreen';
keyboardShortcuts['ESC, O'] = 'Slide overview'; keyboardShortcuts['ESC, O'] = 'Slide overview';
sync(); sync();
@ -4354,7 +4356,7 @@
if( config.history || !window.history ) { if( config.history || !window.history ) {
window.location.hash = locationHash(); window.location.hash = locationHash();
} }
// If we're configured to refelct the current slide in the // If we're configured to reflect the current slide in the
// URL without pushing to history. // URL without pushing to history.
else if( config.hash ) { else if( config.hash ) {
window.history.replaceState( null, null, '#' + locationHash() ); window.history.replaceState( null, null, '#' + locationHash() );

View File

@ -24,7 +24,7 @@
}, },
"devDependencies": { "devDependencies": {
"express": "^4.16.2", "express": "^4.16.2",
"grunt": "^1.0.4", "grunt": "^1.0.3",
"grunt-cli": "^1.3.2", "grunt-cli": "^1.3.2",
"grunt-autoprefixer": "^3.0.4", "grunt-autoprefixer": "^3.0.4",
"grunt-contrib-connect": "^2.0.0", "grunt-contrib-connect": "^2.0.0",