Version Description
- Feature: Configure whether to automatically generate each secondary instance or not
- Feature: Improved license updater to allow for re-checking and re-registration when necessary, and show expiration date
- Enhancement: Touch-off close setting now applies to search dropdown as well as menu panel
- Security hardening: Rewrite fragment handling to remove potential DOM-based (client-side) XSS (thanks, Martin Hall!)
Download this release
Release Info
Developer | sevenspark |
Plugin | ShiftNav – Responsive Mobile Menu |
Version | 1.6 |
Comparing to | |
See all releases |
Code changes from version 1.5.2 to 1.6
- Gruntfile.js +37 -8
- admin/settings.config.php +33 -33
- assets/js/shiftnav.js +69 -51
- assets/js/shiftnav.min.js +24 -24
- includes/functions.php +24 -23
- languages/shiftnav.pot +667 -17
- package.json +4 -0
- readme.txt +12 -6
- shiftnav-responsive-mobile-menu.php +8 -9
Gruntfile.js
CHANGED
@@ -1,5 +1,7 @@
|
|
1 |
module.exports = function(grunt) {
|
2 |
|
|
|
|
|
3 |
// Project configuration.
|
4 |
grunt.initConfig({
|
5 |
pkg: grunt.file.readJSON('package.json'),
|
@@ -30,17 +32,44 @@ module.exports = function(grunt) {
|
|
30 |
*/
|
31 |
},
|
32 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
33 |
'closure-compiler': {
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
maxBuffer: 500,
|
39 |
options: {
|
|
|
40 |
compilation_level: 'SIMPLE_OPTIMIZATIONS',
|
41 |
-
|
|
|
|
|
|
|
|
|
42 |
}
|
43 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
44 |
},
|
45 |
|
46 |
less: {
|
@@ -83,7 +112,7 @@ module.exports = function(grunt) {
|
|
83 |
//grunt.loadNpmTasks('grunt-contrib-uglify');
|
84 |
grunt.loadNpmTasks( 'grunt-contrib-less' );
|
85 |
grunt.loadNpmTasks( 'grunt-contrib-cssmin' );
|
86 |
-
grunt.loadNpmTasks( 'grunt-closure-compiler' );
|
87 |
grunt.loadNpmTasks( 'grunt-wp-i18n' );
|
88 |
|
89 |
grunt.registerTask('css', ['less','cssmin']);
|
@@ -94,4 +123,4 @@ module.exports = function(grunt) {
|
|
94 |
// Default task(s).
|
95 |
grunt.registerTask('default', ['less','closure-compiler','makepot']);
|
96 |
|
97 |
-
};
|
1 |
module.exports = function(grunt) {
|
2 |
|
3 |
+
require('google-closure-compiler').grunt(grunt);
|
4 |
+
|
5 |
// Project configuration.
|
6 |
grunt.initConfig({
|
7 |
pkg: grunt.file.readJSON('package.json'),
|
32 |
*/
|
33 |
},
|
34 |
|
35 |
+
// 'closure-compiler': {
|
36 |
+
// frontend: {
|
37 |
+
// closurePath: '/usr/local/opt/closure-compiler/libexec/closure-compiler-v20170521.jar',
|
38 |
+
// js: 'assets/js/*.js',
|
39 |
+
// jsOutputFile: 'assets/js/shiftnav.min.js',
|
40 |
+
// maxBuffer: 500,
|
41 |
+
// options: {
|
42 |
+
// compilation_level: 'SIMPLE_OPTIMIZATIONS',
|
43 |
+
// language_in: 'ECMASCRIPT5_STRICT'
|
44 |
+
// }
|
45 |
+
// }
|
46 |
+
// },
|
47 |
'closure-compiler': {
|
48 |
+
shiftnavjs: {
|
49 |
+
files: {
|
50 |
+
'assets/js/shiftnav.min.js': ['assets/js/shiftnav.js']
|
51 |
+
},
|
|
|
52 |
options: {
|
53 |
+
//js: ['assets/js/shiftnav.js'],
|
54 |
compilation_level: 'SIMPLE_OPTIMIZATIONS',
|
55 |
+
//js_output_file: 'assets/js/shiftnav.min.js',
|
56 |
+
output_wrapper: '',
|
57 |
+
debug: false,
|
58 |
+
language_in: 'ECMASCRIPT5_STRICT',
|
59 |
+
language_out: 'ECMASCRIPT5_STRICT'
|
60 |
}
|
61 |
}
|
62 |
+
//my_target: {
|
63 |
+
// files: {
|
64 |
+
// 'assets/js/shiftnav.min.js': ['assets/js/*.js']
|
65 |
+
// }
|
66 |
+
// // options: {
|
67 |
+
// compilation_level: 'SIMPLE',
|
68 |
+
// language_in: 'ECMASCRIPT5_STRICT',
|
69 |
+
// create_source_map: 'assets/js/shiftnavtest.min.js.map'//,
|
70 |
+
// //output_wrapper: '(function(){\n%output%\n}).call(this)\n//# sourceMappingURL=output.min.js.map'
|
71 |
+
// }
|
72 |
+
//}
|
73 |
},
|
74 |
|
75 |
less: {
|
112 |
//grunt.loadNpmTasks('grunt-contrib-uglify');
|
113 |
grunt.loadNpmTasks( 'grunt-contrib-less' );
|
114 |
grunt.loadNpmTasks( 'grunt-contrib-cssmin' );
|
115 |
+
//grunt.loadNpmTasks( 'grunt-closure-compiler' );
|
116 |
grunt.loadNpmTasks( 'grunt-wp-i18n' );
|
117 |
|
118 |
grunt.registerTask('css', ['less','cssmin']);
|
123 |
// Default task(s).
|
124 |
grunt.registerTask('default', ['less','closure-compiler','makepot']);
|
125 |
|
126 |
+
};
|
admin/settings.config.php
CHANGED
@@ -38,11 +38,11 @@ function shiftnav_get_settings_fields(){
|
|
38 |
<p class="shiftnav-sub-desc shiftnav-desc-mini" >Click to select, then <strong><em>⌘+c</em></strong> or <strong><em>ctrl+c</em></strong> to copy to clipboard</p>
|
39 |
<p class="shiftnav-sub-desc shiftnav-desc-understated">Pick the appropriate code and add to your template or content where you want the toggle to appear. The menu panel itself is loaded automatically. You can add the toggle code as many times as you like.</p>
|
40 |
';
|
41 |
-
|
42 |
|
43 |
|
44 |
$fields = array(
|
45 |
-
|
46 |
|
47 |
$prefix.'shiftnav-main' => array(
|
48 |
|
@@ -65,7 +65,7 @@ function shiftnav_get_settings_fields(){
|
|
65 |
),
|
66 |
|
67 |
|
68 |
-
|
69 |
|
70 |
30 => array(
|
71 |
'name' => 'edge',
|
@@ -146,7 +146,7 @@ function shiftnav_get_settings_fields(){
|
|
146 |
*/
|
147 |
|
148 |
),
|
149 |
-
// array(
|
150 |
// 'name' => 'section_toggle',
|
151 |
// 'label' => '<h4 class="shiftnav-settings-section">'.__( 'Top Bar Toggle Settings' , 'shiftnav' ).'</h4>',
|
152 |
// 'desc' => '<span class="shiftnav-desc-understated">'.__( 'These settings control the main ShiftNav toggle' , 'shiftnav' ).'</span>',
|
@@ -340,7 +340,7 @@ function shiftnav_get_settings_fields(){
|
|
340 |
'customizer' => true,
|
341 |
'customizer_section' => 'styles',
|
342 |
),
|
343 |
-
|
344 |
|
345 |
/*
|
346 |
array(
|
@@ -358,16 +358,16 @@ function shiftnav_get_settings_fields(){
|
|
358 |
'default' => array( 'all' => 'all' )
|
359 |
),
|
360 |
*/
|
361 |
-
|
362 |
),
|
363 |
-
|
364 |
);
|
365 |
-
|
366 |
$fields = apply_filters( 'shiftnav_settings_panel_fields' , $fields );
|
367 |
|
368 |
$fields[$prefix.'general'] = array(
|
369 |
-
|
370 |
-
10 => array(
|
371 |
'name' => 'css_tweaks',
|
372 |
'label' => __( 'CSS Tweaks' , 'shiftnav' ),
|
373 |
'desc' => __( 'Add custom CSS here, which will be printed in the site head.' , 'shiftnav' ),
|
@@ -391,7 +391,7 @@ function shiftnav_get_settings_fields(){
|
|
391 |
'default' => ''
|
392 |
),
|
393 |
|
394 |
-
40 => array(
|
395 |
'name' => 'footer_content',
|
396 |
'label' => __( 'Footer Content' , 'shiftnav' ),
|
397 |
'desc' => __( 'Add HTML or Shortcodes here and it will be injected at the wp_footer() hook. Useful for fixed position elements' , 'shiftnav' ),
|
@@ -451,9 +451,9 @@ function shiftnav_get_settings_fields(){
|
|
451 |
'default' => 'default',
|
452 |
),
|
453 |
|
454 |
-
|
455 |
|
456 |
-
|
|
|
457 |
'name' => 'disable_transforms',
|
458 |
'label' => __( 'Disable Transforms & Transitions' , 'shiftnav' ),
|
459 |
'desc' => __( 'Disable CSS3 transformations and transitions. This will disable smooth animations, but may work better on browsers that don\'t properly implement CSS3 transforms, especially old non-standard Android browsers. Note that ShiftNav attempts to detect these browsers and fall back automatically, but some browsers have incomplete implementations of CSS3 transforms, which produce false positives when testing.' , 'shiftnav' ),
|
@@ -464,7 +464,7 @@ function shiftnav_get_settings_fields(){
|
|
464 |
100 => array(
|
465 |
'name' => 'touch_off_close',
|
466 |
'label' => __( 'Touch-off close', 'shiftnav' ),
|
467 |
-
'desc' => __( 'Close the ShiftNav panel when touching any content not in the panel.', 'shiftnav' ),
|
468 |
'type' => 'checkbox',
|
469 |
'default' => 'on'
|
470 |
),
|
@@ -478,7 +478,7 @@ function shiftnav_get_settings_fields(){
|
|
478 |
'default' => 100,
|
479 |
),
|
480 |
|
481 |
-
|
482 |
|
483 |
160 => array(
|
484 |
'name' => 'open_current',
|
@@ -486,7 +486,7 @@ function shiftnav_get_settings_fields(){
|
|
486 |
'desc' => __( 'Open the submenu of the current menu item on page load (accordion submenus only).', 'shiftnav' ),
|
487 |
'type' => 'checkbox',
|
488 |
'default' => 'off'
|
489 |
-
),
|
490 |
|
491 |
170 => array(
|
492 |
'name' => 'collapse_accordions',
|
@@ -503,7 +503,7 @@ function shiftnav_get_settings_fields(){
|
|
503 |
'type' => 'checkbox',
|
504 |
'default' => 'on'
|
505 |
),
|
506 |
-
|
507 |
|
508 |
190 => array(
|
509 |
'name' => 'active_on_hover',
|
@@ -554,7 +554,7 @@ function shiftnav_get_settings_fields(){
|
|
554 |
'type' => 'checkbox',
|
555 |
'default' => 'on'
|
556 |
),
|
557 |
-
|
558 |
220 => array(
|
559 |
'name' => 'admin_tips',
|
560 |
'label' => __( 'Show Tips to Admins', 'shiftnav' ),
|
@@ -620,8 +620,8 @@ function shiftnav_get_settings_fields(){
|
|
620 |
'default' => 'off'
|
621 |
),
|
622 |
|
623 |
-
|
624 |
-
|
625 |
/*
|
626 |
array(
|
627 |
'name' => 'multicheck',
|
@@ -647,7 +647,7 @@ function shiftnav_get_settings_fields(){
|
|
647 |
)
|
648 |
)
|
649 |
*/
|
650 |
-
|
651 |
);
|
652 |
|
653 |
|
@@ -661,7 +661,7 @@ function shiftnav_get_settings_fields(){
|
|
661 |
foreach( $fields as $section_id => $section_fields ){
|
662 |
ksort( $fields[$section_id] );
|
663 |
}
|
664 |
-
|
665 |
$fields = apply_filters( 'shiftnav_settings_panel_fields_after' , $fields );
|
666 |
|
667 |
return $fields;
|
@@ -735,14 +735,14 @@ function shiftnav_settings_panel_resets( $fields = array() ){
|
|
735 |
function shiftnav_admin_init() {
|
736 |
|
737 |
$prefix = SHIFTNAV_PREFIX;
|
738 |
-
|
739 |
$sections = shiftnav_get_settings_sections();
|
740 |
$fields = shiftnav_get_settings_fields();
|
741 |
|
742 |
//set up defaults so they are accessible
|
743 |
_SHIFTNAV()->set_defaults( $fields );
|
744 |
|
745 |
-
|
746 |
$settings_api = _SHIFTNAV()->settings_api();
|
747 |
|
748 |
//set sections and fields
|
@@ -776,7 +776,7 @@ function shiftnav_admin_menu() {
|
|
776 |
);
|
777 |
//add_options_page( 'Settings API', 'Settings API', 'manage_options', 'settings_api_test', 'shiftnav_plugin_page' );
|
778 |
}
|
779 |
-
|
780 |
add_action( 'admin_menu', 'shiftnav_admin_menu' );
|
781 |
|
782 |
|
@@ -838,13 +838,13 @@ function shiftnav_settings_panel() {
|
|
838 |
}
|
839 |
|
840 |
do_action( 'shiftnav_settings_panel' );
|
841 |
-
|
842 |
$settings_api = _SHIFTNAV()->settings_api();
|
843 |
-
|
844 |
?>
|
845 |
|
846 |
<div class="wrap shiftnav-wrap">
|
847 |
-
|
848 |
<?php settings_errors(); ?>
|
849 |
|
850 |
<div class="shiftnav-settings-links">
|
@@ -855,13 +855,13 @@ function shiftnav_settings_panel() {
|
|
855 |
|
856 |
<?php
|
857 |
|
858 |
-
do_action( 'shiftnav_settings_before' );
|
859 |
-
|
860 |
$settings_api->show_navigation();
|
861 |
$settings_api->show_forms();
|
862 |
|
863 |
do_action( 'shiftnav_settings_after' );
|
864 |
-
|
865 |
?>
|
866 |
|
867 |
</div>
|
@@ -893,7 +893,7 @@ function shiftnav_op( $option, $section, $default = null ) {
|
|
893 |
if( $section == '__current_instance__' ){
|
894 |
$section = _SHIFTNAV()->get_current_instance();
|
895 |
}
|
896 |
-
|
897 |
$options = get_option( SHIFTNAV_PREFIX.$section );
|
898 |
|
899 |
if ( isset( $options[$option] ) ) {
|
@@ -952,4 +952,4 @@ add_action( 'shiftnav_settings_before' , 'shiftnav_check_menu_assignment' );
|
|
952 |
|
953 |
function shiftnav_allow_html( $str ){
|
954 |
return $str;
|
955 |
-
}
|
38 |
<p class="shiftnav-sub-desc shiftnav-desc-mini" >Click to select, then <strong><em>⌘+c</em></strong> or <strong><em>ctrl+c</em></strong> to copy to clipboard</p>
|
39 |
<p class="shiftnav-sub-desc shiftnav-desc-understated">Pick the appropriate code and add to your template or content where you want the toggle to appear. The menu panel itself is loaded automatically. You can add the toggle code as many times as you like.</p>
|
40 |
';
|
41 |
+
|
42 |
|
43 |
|
44 |
$fields = array(
|
45 |
+
|
46 |
|
47 |
$prefix.'shiftnav-main' => array(
|
48 |
|
65 |
),
|
66 |
|
67 |
|
68 |
+
|
69 |
|
70 |
30 => array(
|
71 |
'name' => 'edge',
|
146 |
*/
|
147 |
|
148 |
),
|
149 |
+
// array(
|
150 |
// 'name' => 'section_toggle',
|
151 |
// 'label' => '<h4 class="shiftnav-settings-section">'.__( 'Top Bar Toggle Settings' , 'shiftnav' ).'</h4>',
|
152 |
// 'desc' => '<span class="shiftnav-desc-understated">'.__( 'These settings control the main ShiftNav toggle' , 'shiftnav' ).'</span>',
|
340 |
'customizer' => true,
|
341 |
'customizer_section' => 'styles',
|
342 |
),
|
343 |
+
|
344 |
|
345 |
/*
|
346 |
array(
|
358 |
'default' => array( 'all' => 'all' )
|
359 |
),
|
360 |
*/
|
361 |
+
|
362 |
),
|
363 |
+
|
364 |
);
|
365 |
+
|
366 |
$fields = apply_filters( 'shiftnav_settings_panel_fields' , $fields );
|
367 |
|
368 |
$fields[$prefix.'general'] = array(
|
369 |
+
|
370 |
+
10 => array(
|
371 |
'name' => 'css_tweaks',
|
372 |
'label' => __( 'CSS Tweaks' , 'shiftnav' ),
|
373 |
'desc' => __( 'Add custom CSS here, which will be printed in the site head.' , 'shiftnav' ),
|
391 |
'default' => ''
|
392 |
),
|
393 |
|
394 |
+
40 => array(
|
395 |
'name' => 'footer_content',
|
396 |
'label' => __( 'Footer Content' , 'shiftnav' ),
|
397 |
'desc' => __( 'Add HTML or Shortcodes here and it will be injected at the wp_footer() hook. Useful for fixed position elements' , 'shiftnav' ),
|
451 |
'default' => 'default',
|
452 |
),
|
453 |
|
|
|
454 |
|
455 |
+
|
456 |
+
90 => array(
|
457 |
'name' => 'disable_transforms',
|
458 |
'label' => __( 'Disable Transforms & Transitions' , 'shiftnav' ),
|
459 |
'desc' => __( 'Disable CSS3 transformations and transitions. This will disable smooth animations, but may work better on browsers that don\'t properly implement CSS3 transforms, especially old non-standard Android browsers. Note that ShiftNav attempts to detect these browsers and fall back automatically, but some browsers have incomplete implementations of CSS3 transforms, which produce false positives when testing.' , 'shiftnav' ),
|
464 |
100 => array(
|
465 |
'name' => 'touch_off_close',
|
466 |
'label' => __( 'Touch-off close', 'shiftnav' ),
|
467 |
+
'desc' => __( 'Close the ShiftNav panel or search dropdown when touching any content not in the panel.', 'shiftnav' ),
|
468 |
'type' => 'checkbox',
|
469 |
'default' => 'on'
|
470 |
),
|
478 |
'default' => 100,
|
479 |
),
|
480 |
|
481 |
+
|
482 |
|
483 |
160 => array(
|
484 |
'name' => 'open_current',
|
486 |
'desc' => __( 'Open the submenu of the current menu item on page load (accordion submenus only).', 'shiftnav' ),
|
487 |
'type' => 'checkbox',
|
488 |
'default' => 'off'
|
489 |
+
),
|
490 |
|
491 |
170 => array(
|
492 |
'name' => 'collapse_accordions',
|
503 |
'type' => 'checkbox',
|
504 |
'default' => 'on'
|
505 |
),
|
506 |
+
|
507 |
|
508 |
190 => array(
|
509 |
'name' => 'active_on_hover',
|
554 |
'type' => 'checkbox',
|
555 |
'default' => 'on'
|
556 |
),
|
557 |
+
|
558 |
220 => array(
|
559 |
'name' => 'admin_tips',
|
560 |
'label' => __( 'Show Tips to Admins', 'shiftnav' ),
|
620 |
'default' => 'off'
|
621 |
),
|
622 |
|
623 |
+
|
624 |
+
|
625 |
/*
|
626 |
array(
|
627 |
'name' => 'multicheck',
|
647 |
)
|
648 |
)
|
649 |
*/
|
650 |
+
|
651 |
);
|
652 |
|
653 |
|
661 |
foreach( $fields as $section_id => $section_fields ){
|
662 |
ksort( $fields[$section_id] );
|
663 |
}
|
664 |
+
|
665 |
$fields = apply_filters( 'shiftnav_settings_panel_fields_after' , $fields );
|
666 |
|
667 |
return $fields;
|
735 |
function shiftnav_admin_init() {
|
736 |
|
737 |
$prefix = SHIFTNAV_PREFIX;
|
738 |
+
|
739 |
$sections = shiftnav_get_settings_sections();
|
740 |
$fields = shiftnav_get_settings_fields();
|
741 |
|
742 |
//set up defaults so they are accessible
|
743 |
_SHIFTNAV()->set_defaults( $fields );
|
744 |
|
745 |
+
|
746 |
$settings_api = _SHIFTNAV()->settings_api();
|
747 |
|
748 |
//set sections and fields
|
776 |
);
|
777 |
//add_options_page( 'Settings API', 'Settings API', 'manage_options', 'settings_api_test', 'shiftnav_plugin_page' );
|
778 |
}
|
779 |
+
|
780 |
add_action( 'admin_menu', 'shiftnav_admin_menu' );
|
781 |
|
782 |
|
838 |
}
|
839 |
|
840 |
do_action( 'shiftnav_settings_panel' );
|
841 |
+
|
842 |
$settings_api = _SHIFTNAV()->settings_api();
|
843 |
+
|
844 |
?>
|
845 |
|
846 |
<div class="wrap shiftnav-wrap">
|
847 |
+
|
848 |
<?php settings_errors(); ?>
|
849 |
|
850 |
<div class="shiftnav-settings-links">
|
855 |
|
856 |
<?php
|
857 |
|
858 |
+
do_action( 'shiftnav_settings_before' );
|
859 |
+
|
860 |
$settings_api->show_navigation();
|
861 |
$settings_api->show_forms();
|
862 |
|
863 |
do_action( 'shiftnav_settings_after' );
|
864 |
+
|
865 |
?>
|
866 |
|
867 |
</div>
|
893 |
if( $section == '__current_instance__' ){
|
894 |
$section = _SHIFTNAV()->get_current_instance();
|
895 |
}
|
896 |
+
|
897 |
$options = get_option( SHIFTNAV_PREFIX.$section );
|
898 |
|
899 |
if ( isset( $options[$option] ) ) {
|
952 |
|
953 |
function shiftnav_allow_html( $str ){
|
954 |
return $str;
|
955 |
+
}
|
assets/js/shiftnav.js
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
/*
|
2 |
* ShiftNav.js
|
3 |
-
*
|
4 |
* http://shiftnav.io
|
5 |
*
|
6 |
* Copyright Chris Mavricos, SevenSpark http://sevenspark.com
|
@@ -33,10 +33,10 @@
|
|
33 |
var shift_supports = (function() {
|
34 |
var div = document.createElement('div'),
|
35 |
vendors = 'Khtml Ms O Moz Webkit'.split(' ');
|
36 |
-
|
37 |
|
38 |
return function(prop) {
|
39 |
-
|
40 |
var len = vendors.length;
|
41 |
|
42 |
if ( prop in div.style ) return true;
|
@@ -44,7 +44,7 @@ var shift_supports = (function() {
|
|
44 |
prop = prop.replace(/^[a-z]/, function(val) {
|
45 |
return val.toUpperCase();
|
46 |
});
|
47 |
-
|
48 |
while(len--) {
|
49 |
if ( vendors[len] + prop in div.style ) {
|
50 |
return true;
|
@@ -84,7 +84,7 @@ var shift_supports = (function() {
|
|
84 |
this._name = pluginName;
|
85 |
|
86 |
this.touchenabled = ('ontouchstart' in window) || (navigator.maxTouchPoints > 0) || (navigator.msMaxTouchPoints > 0);
|
87 |
-
|
88 |
if( window.navigator.pointerEnabled ){
|
89 |
this.touchStart = 'pointerdown';
|
90 |
this.touchEnd = 'pointerup';
|
@@ -101,7 +101,7 @@ var shift_supports = (function() {
|
|
101 |
this.touchMove = 'touchmove';
|
102 |
}
|
103 |
|
104 |
-
this.toggleevent = this.touchEnd == 'touchend' ? this.touchEnd + ' click' : this.touchEnd; //add click except for IE
|
105 |
//this.toggleevent = 'click';
|
106 |
this.transitionend = 'transitionend.shiftnav webkitTransitionEnd.shiftnav msTransitionEnd.shiftnav oTransitionEnd.shiftnav';
|
107 |
|
@@ -109,7 +109,7 @@ var shift_supports = (function() {
|
|
109 |
if( this.settings.clicktest ) this.touchEnd = 'click';
|
110 |
|
111 |
this.init();
|
112 |
-
|
113 |
}
|
114 |
|
115 |
Plugin.prototype = {
|
@@ -140,17 +140,17 @@ var shift_supports = (function() {
|
|
140 |
/* Initalizers */
|
141 |
|
142 |
initializeShiftNav: function(){
|
143 |
-
|
144 |
var $body = $('body'),
|
145 |
plugin = this;
|
146 |
|
147 |
//Only enable the site once
|
148 |
if( !$body.hasClass( 'shiftnav-enabled' ) ){
|
149 |
-
|
150 |
$body.addClass( 'shiftnav-enabled' );
|
151 |
if( shiftnav_data.lock_body == 'on' ) $body.addClass( 'shiftnav-lock' );
|
152 |
if( shiftnav_data.lock_body_x == 'on' ) $body.addClass( 'shiftnav-lock-x' );
|
153 |
-
|
154 |
if( shiftnav_data.shift_body != 'off' ){
|
155 |
if( shiftnav_data.shift_body_wrapper != '' ){
|
156 |
$( shiftnav_data.shift_body_wrapper ).addClass( 'shiftnav-wrap' );
|
@@ -171,7 +171,7 @@ var shift_supports = (function() {
|
|
171 |
|
172 |
//Pad top when either using the Full Bar & Auto Gap, or if override is enabled
|
173 |
var $main_toggle = $( '#shiftnav-toggle-main' );
|
174 |
-
if( ( !$main_toggle.hasClass( 'shiftnav-toggle-style-burger_only') && $main_toggle.hasClass( 'shiftnav-togglebar-gap-auto' ) ) ||
|
175 |
$main_toggle.hasClass( 'shiftnav-togglebar-gap-on' ) ){
|
176 |
var toggleHeight = $main_toggle.outerHeight();
|
177 |
$wrap.css( 'padding-top' , toggleHeight );
|
@@ -182,7 +182,7 @@ var shift_supports = (function() {
|
|
182 |
|
183 |
//Setup non-transform
|
184 |
//Some browsers provide false positives for feature detection, so we have to do browser detection as well, sadly
|
185 |
-
var fpos = false; //falsePositive -
|
186 |
var ua = navigator.userAgent.toLowerCase();
|
187 |
|
188 |
//Many mobile Android browsers are dumb
|
@@ -195,7 +195,7 @@ var shift_supports = (function() {
|
|
195 |
else if( /chrome/.test( ua ) ) fpos = false;
|
196 |
//Firefox on 4+ is good
|
197 |
else if( /firefox/.test( ua ) ) fpos = false;
|
198 |
-
|
199 |
//always allow Chrome
|
200 |
//else if( /chrome/.test( ua ) ) fpos = false;
|
201 |
//Android 4.4+ is okay
|
@@ -227,22 +227,29 @@ var shift_supports = (function() {
|
|
227 |
$drop.find( '.shiftnav-search-input' ).focus();
|
228 |
|
229 |
//Close on click-off - can't do this immediately because IE is so damn dumb
|
230 |
-
|
231 |
-
|
232 |
-
|
233 |
-
|
234 |
-
|
235 |
-
|
|
|
|
|
236 |
}
|
237 |
});
|
238 |
$( '.shiftnav-searchbar-drop' ).on( this.toggleevent , function( e ){
|
239 |
e.stopPropagation();
|
240 |
});
|
241 |
-
|
242 |
-
|
243 |
-
|
244 |
-
|
245 |
-
|
|
|
|
|
|
|
|
|
|
|
246 |
var toggle_clicked;
|
247 |
$( '.shiftnav-searchbar-toggle' ).on( 'mousedown' , function( e ){
|
248 |
toggle_clicked = true;
|
@@ -257,7 +264,7 @@ var shift_supports = (function() {
|
|
257 |
$( window ).shiftsmartresize( function(){
|
258 |
$( '.shiftnav' ).css( 'max-height' , window.innerHeight );
|
259 |
});
|
260 |
-
|
261 |
}
|
262 |
|
263 |
this.$shiftnav.appendTo( 'body' );
|
@@ -288,9 +295,9 @@ var shift_supports = (function() {
|
|
288 |
if( plugin.settings.open_current ){
|
289 |
$( '.shiftnav .shiftnav-sub-accordion.current-menu-item, .shiftnav .shiftnav-sub-accordion.current-menu-ancestor' ).addClass( 'shiftnav-active' );
|
290 |
}
|
291 |
-
|
292 |
},
|
293 |
-
|
294 |
initializeTargets: function(){
|
295 |
|
296 |
var plugin = this;
|
@@ -366,22 +373,22 @@ var shift_supports = (function() {
|
|
366 |
$shiftnav.off( 'mouseout.shift-submenu-toggle' );
|
367 |
},
|
368 |
|
369 |
-
|
370 |
initializeRetractors: function() {
|
371 |
|
372 |
if( !this.settings.retractors ) return; //Don't initialize if retractors are disabled
|
373 |
var plugin = this;
|
374 |
-
|
375 |
//set up the retractors
|
376 |
this.$shiftnav.on( 'mouseup.shiftnav' , '.shiftnav-retract' , function(e){ plugin.handleSubmenuRetractorEnd( e , this, plugin); } );
|
377 |
},
|
378 |
|
379 |
|
380 |
initializeResponsiveToggle: function(){
|
381 |
-
|
382 |
var plugin = this;
|
383 |
|
384 |
-
|
385 |
this.$toggles.on( 'click' , 'a', function(e){ //this.toggleevent,
|
386 |
//allow link to be clicked but don't propagate so toggle won't activate
|
387 |
e.stopPropagation();
|
@@ -397,7 +404,7 @@ var shift_supports = (function() {
|
|
397 |
toggle: function( $toggle , plugin , e ){
|
398 |
e.preventDefault();
|
399 |
e.stopPropagation();
|
400 |
-
|
401 |
//Ignore click events when toggle is disabled to avoid both touch and click events firing
|
402 |
if( e.originalEvent.type == 'click' && $(this).data( 'disableToggle' ) ){
|
403 |
return;
|
@@ -412,12 +419,12 @@ var shift_supports = (function() {
|
|
412 |
var toggle_id = $toggle.attr( 'id' );
|
413 |
var tag = toggle_id == 'shiftnav-toggle-main' ? '[Main Toggle Bar]' : '"'+$(this).text()+'"';
|
414 |
|
415 |
-
//When clicking on main toggle, and the menu is open,
|
416 |
//but it's not the main panel, close whichever panel is actually open instead
|
417 |
if( ( ( toggle_id == 'shiftnav-toggle-main-button' ) ||
|
418 |
-
( toggle_id == 'shiftnav-toggle-main' ) ) &&
|
419 |
$( 'body' ).hasClass( 'shiftnav-open' ) ){
|
420 |
-
//Close all shiftnavs
|
421 |
$( '.shiftnav.shiftnav-open-target' ).shiftnav( 'closeShiftNav' );
|
422 |
}
|
423 |
else{
|
@@ -436,7 +443,7 @@ var shift_supports = (function() {
|
|
436 |
return false;
|
437 |
},
|
438 |
|
439 |
-
|
440 |
|
441 |
openShiftNav: function( tag ){
|
442 |
|
@@ -450,7 +457,7 @@ var shift_supports = (function() {
|
|
450 |
.removeClass( 'shiftnav-open-right shiftnav-open-left' )
|
451 |
.addClass( this.openclass )
|
452 |
.addClass( 'shiftnav-transitioning' );
|
453 |
-
|
454 |
//console.log( 'close ' + $( '.shiftnav-open-target' ).attr( 'id' ) );
|
455 |
$( '.shiftnav-open-target' ).removeClass( 'shiftnav-open-target' );
|
456 |
this.$shiftnav
|
@@ -463,13 +470,13 @@ var shift_supports = (function() {
|
|
463 |
|
464 |
this.disableTouchoffClose();
|
465 |
this.initializeTouchoffClose();
|
466 |
-
|
467 |
},
|
468 |
|
469 |
closeShiftNav: function(){
|
470 |
|
471 |
var plugin = this;
|
472 |
-
|
473 |
$( 'body' )
|
474 |
.removeClass( this.openclass )
|
475 |
.addClass( 'shiftnav-transitioning' );
|
@@ -499,7 +506,7 @@ var shift_supports = (function() {
|
|
499 |
|
500 |
handleMouseActivation: function( e , activator , plugin ){
|
501 |
if( plugin.settings.debug ) console.log( 'handleMouseover, add mouseout', e );
|
502 |
-
|
503 |
var $li = $( activator ).parent();
|
504 |
|
505 |
if( $li.hasClass( 'shiftnav-active' ) ){
|
@@ -513,7 +520,7 @@ var shift_supports = (function() {
|
|
513 |
//$li.on( 'mouseout.shift-submenu-toggle' , function( e ){ plugin.handleMouseout( e , this , plugin ); } );
|
514 |
},
|
515 |
|
516 |
-
|
517 |
handleSubmenuRetractorEnd: function( e , li , plugin ){
|
518 |
e.preventDefault();
|
519 |
e.stopPropagation();
|
@@ -525,7 +532,7 @@ var shift_supports = (function() {
|
|
525 |
|
526 |
},
|
527 |
|
528 |
-
|
529 |
|
530 |
handleTouchoffClose: function( e , _this , plugin ){
|
531 |
|
@@ -553,7 +560,7 @@ var shift_supports = (function() {
|
|
553 |
/* Controllers */
|
554 |
scrollPanel: function( y ){
|
555 |
if( shiftnav_data.scroll_panel == 'off' ) return 0;
|
556 |
-
|
557 |
if( typeof y == 'undefined' ){
|
558 |
return this.$shiftnav.find( '.shiftnav-inner' ).scrollTop();
|
559 |
}
|
@@ -568,12 +575,12 @@ var shift_supports = (function() {
|
|
568 |
//plugin.setMinimumHeight( 'open' , $li );
|
569 |
|
570 |
if( $li.hasClass( 'shiftnav-sub-shift' ) ){
|
571 |
-
|
572 |
$li.siblings( '.shiftnav-active' ).removeClass( 'shiftnav-active' );
|
573 |
-
|
574 |
//switch to position absolute, then delay activation below due to Firefox browser bug
|
575 |
$li.toggleClass( 'shiftnav-caulk' );
|
576 |
-
|
577 |
plugin.$shiftnav.addClass( 'shiftnav-sub-shift-active' );
|
578 |
|
579 |
}
|
@@ -604,7 +611,7 @@ var shift_supports = (function() {
|
|
604 |
plugin.scrollPanel( scrollPanelTo );
|
605 |
//plugin.scrollPanel( 0 );
|
606 |
}, 100 );
|
607 |
-
|
608 |
}, 1 );
|
609 |
}
|
610 |
},
|
@@ -635,7 +642,7 @@ var shift_supports = (function() {
|
|
635 |
plugin.closeSubmenu( _$li.find( '.shiftnav-active' ) , tag+'_recursive' , plugin );
|
636 |
});
|
637 |
}
|
638 |
-
|
639 |
//Actually remove the active class, which causes the submenu to close
|
640 |
$li.removeClass( 'shiftnav-active' );
|
641 |
|
@@ -657,7 +664,7 @@ var shift_supports = (function() {
|
|
657 |
$li.closest( 'ul' ).addClass( 'shiftnav-sub-active-current' );
|
658 |
|
659 |
$li.trigger( 'shiftnav-close-submenu' ); //API
|
660 |
-
|
661 |
},
|
662 |
|
663 |
closeAllSubmenus: function(){
|
@@ -754,8 +761,13 @@ var shift_supports = (function() {
|
|
754 |
//Highlight item
|
755 |
var hash = window.location.hash;
|
756 |
if( hash.substring(1,2) == '.' ) hash = hash.substring(1);
|
757 |
-
|
758 |
-
|
|
|
|
|
|
|
|
|
|
|
759 |
if( $li.length ){
|
760 |
//console.log( $li );
|
761 |
$li.siblings().removeClass( 'current-menu-item' ).removeClass( 'current-menu-ancestor' );
|
@@ -766,4 +778,10 @@ var shift_supports = (function() {
|
|
766 |
$( '.shiftnav' ).trigger( 'shiftnav-loaded' );
|
767 |
}
|
768 |
|
|
|
|
|
|
|
|
|
|
|
|
|
769 |
})(jQuery);
|
1 |
/*
|
2 |
* ShiftNav.js
|
3 |
+
*
|
4 |
* http://shiftnav.io
|
5 |
*
|
6 |
* Copyright Chris Mavricos, SevenSpark http://sevenspark.com
|
33 |
var shift_supports = (function() {
|
34 |
var div = document.createElement('div'),
|
35 |
vendors = 'Khtml Ms O Moz Webkit'.split(' ');
|
36 |
+
|
37 |
|
38 |
return function(prop) {
|
39 |
+
|
40 |
var len = vendors.length;
|
41 |
|
42 |
if ( prop in div.style ) return true;
|
44 |
prop = prop.replace(/^[a-z]/, function(val) {
|
45 |
return val.toUpperCase();
|
46 |
});
|
47 |
+
|
48 |
while(len--) {
|
49 |
if ( vendors[len] + prop in div.style ) {
|
50 |
return true;
|
84 |
this._name = pluginName;
|
85 |
|
86 |
this.touchenabled = ('ontouchstart' in window) || (navigator.maxTouchPoints > 0) || (navigator.msMaxTouchPoints > 0);
|
87 |
+
|
88 |
if( window.navigator.pointerEnabled ){
|
89 |
this.touchStart = 'pointerdown';
|
90 |
this.touchEnd = 'pointerup';
|
101 |
this.touchMove = 'touchmove';
|
102 |
}
|
103 |
|
104 |
+
this.toggleevent = this.touchEnd == 'touchend' ? this.touchEnd + ' click' : this.touchEnd; //add click except for IE
|
105 |
//this.toggleevent = 'click';
|
106 |
this.transitionend = 'transitionend.shiftnav webkitTransitionEnd.shiftnav msTransitionEnd.shiftnav oTransitionEnd.shiftnav';
|
107 |
|
109 |
if( this.settings.clicktest ) this.touchEnd = 'click';
|
110 |
|
111 |
this.init();
|
112 |
+
|
113 |
}
|
114 |
|
115 |
Plugin.prototype = {
|
140 |
/* Initalizers */
|
141 |
|
142 |
initializeShiftNav: function(){
|
143 |
+
|
144 |
var $body = $('body'),
|
145 |
plugin = this;
|
146 |
|
147 |
//Only enable the site once
|
148 |
if( !$body.hasClass( 'shiftnav-enabled' ) ){
|
149 |
+
|
150 |
$body.addClass( 'shiftnav-enabled' );
|
151 |
if( shiftnav_data.lock_body == 'on' ) $body.addClass( 'shiftnav-lock' );
|
152 |
if( shiftnav_data.lock_body_x == 'on' ) $body.addClass( 'shiftnav-lock-x' );
|
153 |
+
|
154 |
if( shiftnav_data.shift_body != 'off' ){
|
155 |
if( shiftnav_data.shift_body_wrapper != '' ){
|
156 |
$( shiftnav_data.shift_body_wrapper ).addClass( 'shiftnav-wrap' );
|
171 |
|
172 |
//Pad top when either using the Full Bar & Auto Gap, or if override is enabled
|
173 |
var $main_toggle = $( '#shiftnav-toggle-main' );
|
174 |
+
if( ( !$main_toggle.hasClass( 'shiftnav-toggle-style-burger_only') && $main_toggle.hasClass( 'shiftnav-togglebar-gap-auto' ) ) ||
|
175 |
$main_toggle.hasClass( 'shiftnav-togglebar-gap-on' ) ){
|
176 |
var toggleHeight = $main_toggle.outerHeight();
|
177 |
$wrap.css( 'padding-top' , toggleHeight );
|
182 |
|
183 |
//Setup non-transform
|
184 |
//Some browsers provide false positives for feature detection, so we have to do browser detection as well, sadly
|
185 |
+
var fpos = false; //falsePositive -
|
186 |
var ua = navigator.userAgent.toLowerCase();
|
187 |
|
188 |
//Many mobile Android browsers are dumb
|
195 |
else if( /chrome/.test( ua ) ) fpos = false;
|
196 |
//Firefox on 4+ is good
|
197 |
else if( /firefox/.test( ua ) ) fpos = false;
|
198 |
+
|
199 |
//always allow Chrome
|
200 |
//else if( /chrome/.test( ua ) ) fpos = false;
|
201 |
//Android 4.4+ is okay
|
227 |
$drop.find( '.shiftnav-search-input' ).focus();
|
228 |
|
229 |
//Close on click-off - can't do this immediately because IE is so damn dumb
|
230 |
+
if( plugin.settings.touchOffClose ){
|
231 |
+
setTimeout( function(){
|
232 |
+
$( 'body' ).on( 'click.shiftnav-searchbar-drop' , function( e ){
|
233 |
+
$( '.shiftnav-searchbar-drop' ).removeClass( 'shiftnav-searchbar-drop-open' );
|
234 |
+
$( 'body' ).off( 'click.shiftnav-searchbar-drop' );
|
235 |
+
});
|
236 |
+
}, 100);
|
237 |
+
}
|
238 |
}
|
239 |
});
|
240 |
$( '.shiftnav-searchbar-drop' ).on( this.toggleevent , function( e ){
|
241 |
e.stopPropagation();
|
242 |
});
|
243 |
+
|
244 |
+
//When the dropdown loses focus, close it it touch off close is enabled
|
245 |
+
if( this.settings.touchOffClose ){
|
246 |
+
$( '.shiftnav-searchbar-drop .shiftnav-search-input').on( 'blur' , function( e ){
|
247 |
+
if( $( this ).val() == '' && !toggle_clicked ){
|
248 |
+
$( this ).parents( '.shiftnav-searchbar-drop' ).removeClass( 'shiftnav-searchbar-drop-open' );
|
249 |
+
}
|
250 |
+
});
|
251 |
+
}
|
252 |
+
|
253 |
var toggle_clicked;
|
254 |
$( '.shiftnav-searchbar-toggle' ).on( 'mousedown' , function( e ){
|
255 |
toggle_clicked = true;
|
264 |
$( window ).shiftsmartresize( function(){
|
265 |
$( '.shiftnav' ).css( 'max-height' , window.innerHeight );
|
266 |
});
|
267 |
+
|
268 |
}
|
269 |
|
270 |
this.$shiftnav.appendTo( 'body' );
|
295 |
if( plugin.settings.open_current ){
|
296 |
$( '.shiftnav .shiftnav-sub-accordion.current-menu-item, .shiftnav .shiftnav-sub-accordion.current-menu-ancestor' ).addClass( 'shiftnav-active' );
|
297 |
}
|
298 |
+
|
299 |
},
|
300 |
+
|
301 |
initializeTargets: function(){
|
302 |
|
303 |
var plugin = this;
|
373 |
$shiftnav.off( 'mouseout.shift-submenu-toggle' );
|
374 |
},
|
375 |
|
376 |
+
|
377 |
initializeRetractors: function() {
|
378 |
|
379 |
if( !this.settings.retractors ) return; //Don't initialize if retractors are disabled
|
380 |
var plugin = this;
|
381 |
+
|
382 |
//set up the retractors
|
383 |
this.$shiftnav.on( 'mouseup.shiftnav' , '.shiftnav-retract' , function(e){ plugin.handleSubmenuRetractorEnd( e , this, plugin); } );
|
384 |
},
|
385 |
|
386 |
|
387 |
initializeResponsiveToggle: function(){
|
388 |
+
|
389 |
var plugin = this;
|
390 |
|
391 |
+
|
392 |
this.$toggles.on( 'click' , 'a', function(e){ //this.toggleevent,
|
393 |
//allow link to be clicked but don't propagate so toggle won't activate
|
394 |
e.stopPropagation();
|
404 |
toggle: function( $toggle , plugin , e ){
|
405 |
e.preventDefault();
|
406 |
e.stopPropagation();
|
407 |
+
|
408 |
//Ignore click events when toggle is disabled to avoid both touch and click events firing
|
409 |
if( e.originalEvent.type == 'click' && $(this).data( 'disableToggle' ) ){
|
410 |
return;
|
419 |
var toggle_id = $toggle.attr( 'id' );
|
420 |
var tag = toggle_id == 'shiftnav-toggle-main' ? '[Main Toggle Bar]' : '"'+$(this).text()+'"';
|
421 |
|
422 |
+
//When clicking on main toggle, and the menu is open,
|
423 |
//but it's not the main panel, close whichever panel is actually open instead
|
424 |
if( ( ( toggle_id == 'shiftnav-toggle-main-button' ) ||
|
425 |
+
( toggle_id == 'shiftnav-toggle-main' ) ) &&
|
426 |
$( 'body' ).hasClass( 'shiftnav-open' ) ){
|
427 |
+
//Close all shiftnavs
|
428 |
$( '.shiftnav.shiftnav-open-target' ).shiftnav( 'closeShiftNav' );
|
429 |
}
|
430 |
else{
|
443 |
return false;
|
444 |
},
|
445 |
|
446 |
+
|
447 |
|
448 |
openShiftNav: function( tag ){
|
449 |
|
457 |
.removeClass( 'shiftnav-open-right shiftnav-open-left' )
|
458 |
.addClass( this.openclass )
|
459 |
.addClass( 'shiftnav-transitioning' );
|
460 |
+
|
461 |
//console.log( 'close ' + $( '.shiftnav-open-target' ).attr( 'id' ) );
|
462 |
$( '.shiftnav-open-target' ).removeClass( 'shiftnav-open-target' );
|
463 |
this.$shiftnav
|
470 |
|
471 |
this.disableTouchoffClose();
|
472 |
this.initializeTouchoffClose();
|
473 |
+
|
474 |
},
|
475 |
|
476 |
closeShiftNav: function(){
|
477 |
|
478 |
var plugin = this;
|
479 |
+
|
480 |
$( 'body' )
|
481 |
.removeClass( this.openclass )
|
482 |
.addClass( 'shiftnav-transitioning' );
|
506 |
|
507 |
handleMouseActivation: function( e , activator , plugin ){
|
508 |
if( plugin.settings.debug ) console.log( 'handleMouseover, add mouseout', e );
|
509 |
+
|
510 |
var $li = $( activator ).parent();
|
511 |
|
512 |
if( $li.hasClass( 'shiftnav-active' ) ){
|
520 |
//$li.on( 'mouseout.shift-submenu-toggle' , function( e ){ plugin.handleMouseout( e , this , plugin ); } );
|
521 |
},
|
522 |
|
523 |
+
|
524 |
handleSubmenuRetractorEnd: function( e , li , plugin ){
|
525 |
e.preventDefault();
|
526 |
e.stopPropagation();
|
532 |
|
533 |
},
|
534 |
|
535 |
+
|
536 |
|
537 |
handleTouchoffClose: function( e , _this , plugin ){
|
538 |
|
560 |
/* Controllers */
|
561 |
scrollPanel: function( y ){
|
562 |
if( shiftnav_data.scroll_panel == 'off' ) return 0;
|
563 |
+
|
564 |
if( typeof y == 'undefined' ){
|
565 |
return this.$shiftnav.find( '.shiftnav-inner' ).scrollTop();
|
566 |
}
|
575 |
//plugin.setMinimumHeight( 'open' , $li );
|
576 |
|
577 |
if( $li.hasClass( 'shiftnav-sub-shift' ) ){
|
578 |
+
|
579 |
$li.siblings( '.shiftnav-active' ).removeClass( 'shiftnav-active' );
|
580 |
+
|
581 |
//switch to position absolute, then delay activation below due to Firefox browser bug
|
582 |
$li.toggleClass( 'shiftnav-caulk' );
|
583 |
+
|
584 |
plugin.$shiftnav.addClass( 'shiftnav-sub-shift-active' );
|
585 |
|
586 |
}
|
611 |
plugin.scrollPanel( scrollPanelTo );
|
612 |
//plugin.scrollPanel( 0 );
|
613 |
}, 100 );
|
614 |
+
|
615 |
}, 1 );
|
616 |
}
|
617 |
},
|
642 |
plugin.closeSubmenu( _$li.find( '.shiftnav-active' ) , tag+'_recursive' , plugin );
|
643 |
});
|
644 |
}
|
645 |
+
|
646 |
//Actually remove the active class, which causes the submenu to close
|
647 |
$li.removeClass( 'shiftnav-active' );
|
648 |
|
664 |
$li.closest( 'ul' ).addClass( 'shiftnav-sub-active-current' );
|
665 |
|
666 |
$li.trigger( 'shiftnav-close-submenu' ); //API
|
667 |
+
|
668 |
},
|
669 |
|
670 |
closeAllSubmenus: function(){
|
761 |
//Highlight item
|
762 |
var hash = window.location.hash;
|
763 |
if( hash.substring(1,2) == '.' ) hash = hash.substring(1);
|
764 |
+
|
765 |
+
//Sanitize any hash string, just in case. These ar all the valid URL fragment characters, anything else gets stripped
|
766 |
+
hash = hash.replace( /[^#a-z0-9!$&'()*+,;=]/gi , '' ); //hash = hash.replace(/\W/g,
|
767 |
+
|
768 |
+
//var $li = $( '.shiftnav .shiftnav-target[data-shiftnav-scrolltarget="'+hash+'"]' ).parent();
|
769 |
+
//Do it this way to avoid passing user-editable content into the $() function - find() is safer
|
770 |
+
var $li = $( '.shiftnav' ).find( '.shiftnav-target[data-shiftnav-scrolltarget="'+hash+'"]' ).parent();
|
771 |
if( $li.length ){
|
772 |
//console.log( $li );
|
773 |
$li.siblings().removeClass( 'current-menu-item' ).removeClass( 'current-menu-ancestor' );
|
778 |
$( '.shiftnav' ).trigger( 'shiftnav-loaded' );
|
779 |
}
|
780 |
|
781 |
+
function escapeHtml(str) {
|
782 |
+
var div = document.createElement('div');
|
783 |
+
div.appendChild(document.createTextNode(str));
|
784 |
+
return div.innerHTML;
|
785 |
+
}
|
786 |
+
|
787 |
})(jQuery);
|
assets/js/shiftnav.min.js
CHANGED
@@ -1,27 +1,27 @@
|
|
1 |
-
(function(b,
|
2 |
-
var shift_supports=function(){var b=document.createElement("div"),
|
3 |
-
(function(b,g,
|
4 |
this.touchMove="MSPointerMove"):(this.touchStart="touchstart",this.touchEnd="touchend",this.touchMove="touchmove");this.toggleevent="touchend"==this.touchEnd?this.touchEnd+" click":this.touchEnd;this.transitionend="transitionend.shiftnav webkitTransitionEnd.shiftnav msTransitionEnd.shiftnav oTransitionEnd.shiftnav";this.settings.clicktest&&(this.touchEnd="click");this.init()}var l={mouseEvents:!0,retractors:!0,touchOffClose:!0,clicktest:!1,windowstest:!1,debug:!1,open_current:!1,collapse_accordions:!1,
|
5 |
scroll_offset:100,disable_transforms:!1};k.prototype={init:function(){this.$shiftnav.removeClass("shiftnav-nojs");this.$toggles=b('.shiftnav-toggle[data-shiftnav-target="'+this.$shiftnav.data("shiftnav-id")+'"]');this.initializeShiftNav();this.initializeTargets();this.initializeSubmenuToggleMouseEvents();this.initializeRetractors();this.initializeResponsiveToggle()},initializeShiftNav:function(){var a=b("body"),d=this;if(!a.hasClass("shiftnav-enabled")){a.addClass("shiftnav-enabled");"on"==shiftnav_data.lock_body&&
|
6 |
a.addClass("shiftnav-lock");"on"==shiftnav_data.lock_body_x&&a.addClass("shiftnav-lock-x");"off"!=shiftnav_data.shift_body?""!=shiftnav_data.shift_body_wrapper?b(shiftnav_data.shift_body_wrapper).addClass("shiftnav-wrap"):(a.wrapInner('<div class="shiftnav-wrap"></div>'),b("video[autoplay]").each(function(){b(this).get(0).play()})):a.addClass("shiftnav-disable-shift-body");b("#shiftnav-toggle-main, #wpadminbar, .shiftnav-fixed-left, .shiftnav-fixed-right").appendTo("body");var c=b(".shiftnav-wrap"),
|
7 |
-
|
8 |
-
(c=!1));(!shift_supports("transform")||c||d.settings.disable_transforms)&&a.addClass("shiftnav-no-transforms");b(".shiftnav-searchbar-toggle").on(this.toggleevent,function(a){a.stopPropagation();a.preventDefault();a=b(this).next(".shiftnav-searchbar-drop");a.hasClass("shiftnav-searchbar-drop-open")?(a.removeClass("shiftnav-searchbar-drop-open"),b("body").off("click.shiftnav-searchbar-drop")):(a.addClass("shiftnav-searchbar-drop-open"),a.find(".shiftnav-search-input").focus(),
|
9 |
-
function(a){b(".shiftnav-searchbar-drop").removeClass("shiftnav-searchbar-drop-open");b("body").off("click.shiftnav-searchbar-drop")})},100))});b(".shiftnav-searchbar-drop").on(this.toggleevent,function(a){a.stopPropagation()});b(".shiftnav-searchbar-drop .shiftnav-search-input").on("blur",function(a){""!=b(this).val()||
|
10 |
-
function(a){
|
11 |
-
b(this).css({height:a,width:a})});d.settings.open_current&&b(".shiftnav .shiftnav-sub-accordion.current-menu-item, .shiftnav .shiftnav-sub-accordion.current-menu-ancestor").addClass("shiftnav-active")},initializeTargets:function(){var a=this;this.$shiftnav.find(".shiftnav-scrollto").removeClass("current-menu-item").removeClass("current-menu-ancestor");this.$shiftnav.on("click",
|
12 |
-
b(this).parent(".menu-item"),d.siblings().removeClass("current-menu-item").removeClass("current-menu-ancestor"),d.addClass("current-menu-item"),d=
|
13 |
-
a):a.openSubmenu(d,"disabledLink",a))})},initializeSubmenuToggleMouseEvents:function(){if(this.settings.mouseEvents&&!this.settings.clicktest&&!this.settings.windowstest){this.settings.debug&&console.log("initializeSubmenuToggleMouseEvents");var a=this;this.$shiftnav.on("mouseup.shift-submenu-toggle",".shiftnav-submenu-activation",function(b){a.handleMouseActivation(b,this,a)})}},disableSubmenuToggleMouseEvents:function(){this.settings.debug&&
|
14 |
-
|
15 |
-
|
16 |
-
1E3));return!1}},openShiftNav:function(a){var d=this;this.settings.debug&&console.log("openShiftNav "+(a||"?"));b("body").removeClass("shiftnav-open-right shiftnav-open-left").addClass(this.openclass).addClass("shiftnav-transitioning");b(".shiftnav-open-target").removeClass("shiftnav-open-target");this.$shiftnav.addClass("shiftnav-open-target").on(d.transitionend,function(){b("body").removeClass("shiftnav-transitioning");b(this).off(d.transitionend)});
|
17 |
-
closeShiftNav:function(){var a=this;b("body").removeClass(this.openclass).addClass("shiftnav-transitioning");this.$shiftnav.removeClass("shiftnav-open-target").on(a.transitionend,function(){b("body").removeClass("shiftnav-transitioning");b(this).off(a.transitionend)});this.disableTouchoffClose()},initializeTouchoffClose:function(){if(this.settings.touchOffClose){var a=this;b(
|
18 |
-
handleMouseActivation:function(a,d,c){c.settings.debug&&console.log("handleMouseover, add mouseout",a);a=b(d).parent();a.hasClass("shiftnav-active")?c.closeSubmenu(a,"mouseActivate",c):c.openSubmenu(a,"mouseActivate",c)},handleSubmenuRetractorEnd:function(a,d,c){a.preventDefault();a.stopPropagation();a=b(d).parent("ul").parent("li");c.closeSubmenu(a,"handleSubmenuRetractor",c);c.settings.debug&&console.log("handleSubmenuRetractorEnd "+
|
19 |
-
0!==b(a.target).parents().add(b(a.target)).filter(".shiftnav, .shiftnav-toggle, .shiftnav-ignore").length||(c.settings.debug&&console.log("touchoff close ",a),a.preventDefault(),a.stopPropagation(),c.closeShiftNav(),c.disableTouchoffClose())},scrollPanel:function(a){if("off"==shiftnav_data.scroll_panel)return 0;if("undefined"==typeof a)return this.$shiftnav.find(".shiftnav-inner").scrollTop();this.$shiftnav.find(".shiftnav-inner").scrollTop(a)},
|
20 |
-
(a.hasClass("shiftnav-sub-shift")?(a.siblings(".shiftnav-active").removeClass("shiftnav-active"),a.toggleClass("shiftnav-caulk"),c.$shiftnav.addClass("shiftnav-sub-shift-active")):c.settings.collapse_accordions&&a.siblings(".shiftnav-active").removeClass("shiftnav-active"),a.parents("ul").removeClass("shiftnav-sub-active-current"),a.find("> ul").addClass("shiftnav-sub-active").addClass("shiftnav-sub-active-current"),setTimeout(function(){a.addClass("shiftnav-active");
|
21 |
-
a.removeClass("shiftnav-caulk");setTimeout(function(){var b=c.scrollPanel();a.data("scroll-back",b);b=a.offset().top+b;c.scrollPanel(b)},100)},1))},closeSubmenu:function(a,d,c){this.settings.debug&&console.log("closeSubmenu "+a.find(">a").text()+" ["+d+"]");a.hasClass("menu-item-has-children")&&a.hasClass("shiftnav-active")&&(a.addClass("shiftnav-in-transition"),a.each(function(){var a=b(this),e=a.find("> ul");e.on(c.transitionend+"_closesubmenu",function(){c.settings.debug&&
|
22 |
-
a.removeClass("shiftnav-in-transition");e.off(c.transitionend+"_closesubmenu")});c.closeSubmenu(a.find(".shiftnav-active"),d+"_recursive",c)}));a.removeClass("shiftnav-active");if(a.hasClass("shiftnav-sub-shift")){0==a.parents(".shiftnav-sub-shift").length&&c.$shiftnav.removeClass("shiftnav-sub-shift-active");var e=a.data("scroll-back");"undefined"!==e&&c.scrollPanel(e)}a.find("> ul").removeClass("shiftnav-sub-active").removeClass("shiftnav-sub-active-current");
|
23 |
-
a.trigger("shiftnav-close-submenu")},closeAllSubmenus:function(){b(this.element).find("li.menu-item-has-children").removeClass("shiftnav-active")}};b.fn.shiftnav=function(a){var d=arguments;if(a===
|
24 |
-
1)));"destroy"===a&&b.data(this,"plugin_shiftnav",null)});return c!==
|
25 |
-
(function(b){function
|
26 |
-
!0:!1});if("."==window.location.hash.substring(1,2)&&(
|
27 |
-
var
|
1 |
+
'use strict';(function(b,f){var g=function(b,f,g){var a;return function(){var d=this,c=arguments;a?clearTimeout(a):g&&b.apply(d,c);a=setTimeout(function(){g||b.apply(d,c);a=null},f||100)}};jQuery.fn[f]=function(b){return b?this.bind("resize",g(b)):this.trigger(f)}})(jQuery,"shiftsmartresize");
|
2 |
+
var shift_supports=function(){var b=document.createElement("div"),f=["Khtml","Ms","O","Moz","Webkit"];return function(g){var e=f.length;if(g in b.style)return!0;for(g=g.replace(/^[a-z]/,function(b){return b.toUpperCase()});e--;)if(f[e]+g in b.style)return!0;return!1}}();
|
3 |
+
(function(b,f,g,e){function k(a,d){this.element=a;this.$shiftnav=b(this.element);this.$menu=this.$shiftnav.find("ul.shiftnav-menu");this.settings=b.extend({},l,d);this._defaults=l;this._name="shiftnav";this.touchenabled="ontouchstart"in f||0<navigator.maxTouchPoints||0<navigator.msMaxTouchPoints;f.navigator.pointerEnabled?(this.touchStart="pointerdown",this.touchEnd="pointerup",this.touchMove="pointermove"):f.navigator.msPointerEnabled?(this.touchStart="MSPointerDown",this.touchEnd="MSPointerUp",
|
4 |
this.touchMove="MSPointerMove"):(this.touchStart="touchstart",this.touchEnd="touchend",this.touchMove="touchmove");this.toggleevent="touchend"==this.touchEnd?this.touchEnd+" click":this.touchEnd;this.transitionend="transitionend.shiftnav webkitTransitionEnd.shiftnav msTransitionEnd.shiftnav oTransitionEnd.shiftnav";this.settings.clicktest&&(this.touchEnd="click");this.init()}var l={mouseEvents:!0,retractors:!0,touchOffClose:!0,clicktest:!1,windowstest:!1,debug:!1,open_current:!1,collapse_accordions:!1,
|
5 |
scroll_offset:100,disable_transforms:!1};k.prototype={init:function(){this.$shiftnav.removeClass("shiftnav-nojs");this.$toggles=b('.shiftnav-toggle[data-shiftnav-target="'+this.$shiftnav.data("shiftnav-id")+'"]');this.initializeShiftNav();this.initializeTargets();this.initializeSubmenuToggleMouseEvents();this.initializeRetractors();this.initializeResponsiveToggle()},initializeShiftNav:function(){var a=b("body"),d=this;if(!a.hasClass("shiftnav-enabled")){a.addClass("shiftnav-enabled");"on"==shiftnav_data.lock_body&&
|
6 |
a.addClass("shiftnav-lock");"on"==shiftnav_data.lock_body_x&&a.addClass("shiftnav-lock-x");"off"!=shiftnav_data.shift_body?""!=shiftnav_data.shift_body_wrapper?b(shiftnav_data.shift_body_wrapper).addClass("shiftnav-wrap"):(a.wrapInner('<div class="shiftnav-wrap"></div>'),b("video[autoplay]").each(function(){b(this).get(0).play()})):a.addClass("shiftnav-disable-shift-body");b("#shiftnav-toggle-main, #wpadminbar, .shiftnav-fixed-left, .shiftnav-fixed-right").appendTo("body");var c=b(".shiftnav-wrap"),
|
7 |
+
h=b("#shiftnav-toggle-main");if(!h.hasClass("shiftnav-toggle-style-burger_only")&&h.hasClass("shiftnav-togglebar-gap-auto")||h.hasClass("shiftnav-togglebar-gap-on")){var e=h.outerHeight();c.css("padding-top",e);h.addClass("shiftnav-togglebar-gap-on");"off"==shiftnav_data.shift_body&&a.css("padding-top",e)}else b("body").hasClass("admin-bar")&&b("html").addClass("shiftnav-nogap");c=!1;h=navigator.userAgent.toLowerCase();/android/.test(h)&&(c=!0,/android [1-3]/.test(h)?c=!0:/chrome/.test(h)?c=!1:/firefox/.test(h)&&
|
8 |
+
(c=!1));(!shift_supports("transform")||c||d.settings.disable_transforms)&&a.addClass("shiftnav-no-transforms");b(".shiftnav-searchbar-toggle").on(this.toggleevent,function(a){a.stopPropagation();a.preventDefault();a=b(this).next(".shiftnav-searchbar-drop");a.hasClass("shiftnav-searchbar-drop-open")?(a.removeClass("shiftnav-searchbar-drop-open"),b("body").off("click.shiftnav-searchbar-drop")):(a.addClass("shiftnav-searchbar-drop-open"),a.find(".shiftnav-search-input").focus(),d.settings.touchOffClose&&
|
9 |
+
setTimeout(function(){b("body").on("click.shiftnav-searchbar-drop",function(a){b(".shiftnav-searchbar-drop").removeClass("shiftnav-searchbar-drop-open");b("body").off("click.shiftnav-searchbar-drop")})},100))});b(".shiftnav-searchbar-drop").on(this.toggleevent,function(a){a.stopPropagation()});if(this.settings.touchOffClose)b(".shiftnav-searchbar-drop .shiftnav-search-input").on("blur",function(a){""!=b(this).val()||g||b(this).parents(".shiftnav-searchbar-drop").removeClass("shiftnav-searchbar-drop-open")});
|
10 |
+
var g;b(".shiftnav-searchbar-toggle").on("mousedown",function(a){g=!0});b(".shiftnav-searchbar-toggle").on("mouseup",function(a){g=!1});b(".shiftnav").css("max-height",f.innerHeight);b(f).shiftsmartresize(function(){b(".shiftnav").css("max-height",f.innerHeight)})}this.$shiftnav.appendTo("body");this.$shiftnav.hasClass("shiftnav-right-edge")?this.edge="right":this.edge="left";this.openclass="shiftnav-open shiftnav-open-"+this.edge;this.$shiftnav.find(".shiftnav-panel-close").on("click",function(){d.closeShiftNav()});
|
11 |
+
this.$shiftnav.find(".shiftnav-submenu-activation").each(function(){var a=b(this).siblings(".shiftnav-target").outerHeight();b(this).css({height:a,width:a})});d.settings.open_current&&b(".shiftnav .shiftnav-sub-accordion.current-menu-item, .shiftnav .shiftnav-sub-accordion.current-menu-ancestor").addClass("shiftnav-active")},initializeTargets:function(){var a=this;this.$shiftnav.find(".shiftnav-scrollto").removeClass("current-menu-item").removeClass("current-menu-ancestor");this.$shiftnav.on("click",
|
12 |
+
".shiftnav-target",function(d){var c=b(this).data("shiftnav-scrolltarget");if(c){var h=b(c).first();if(0<h.length)return d=b(this).parent(".menu-item"),d.siblings().removeClass("current-menu-item").removeClass("current-menu-ancestor"),d.addClass("current-menu-item"),d=h.offset().top,d-=a.settings.scroll_offset,b("html,body").animate({scrollTop:d},1E3,"swing",function(){a.closeShiftNav()}),!1;(h=b(this).attr("href"))&&-1==h.indexOf("#")&&(-1==c.indexOf("#")&&(c="#"+c),f.location=h+c,d.preventDefault())}else b(this).is("span")&&
|
13 |
+
(d=b(this).parent(".menu-item"),d.hasClass("shiftnav-active")?a.closeSubmenu(d,"disabledLink",a):a.openSubmenu(d,"disabledLink",a))})},initializeSubmenuToggleMouseEvents:function(){if(this.settings.mouseEvents&&!this.settings.clicktest&&!this.settings.windowstest){this.settings.debug&&console.log("initializeSubmenuToggleMouseEvents");var a=this;this.$shiftnav.on("mouseup.shift-submenu-toggle",".shiftnav-submenu-activation",function(b){a.handleMouseActivation(b,this,a)})}},disableSubmenuToggleMouseEvents:function(){this.settings.debug&&
|
14 |
+
console.log("disableSubmenuToggleMouseEvents");$shiftnav.off("mouseover.shift-submenu-toggle");$shiftnav.off("mouseout.shift-submenu-toggle")},initializeRetractors:function(){if(this.settings.retractors){var a=this;this.$shiftnav.on("mouseup.shiftnav",".shiftnav-retract",function(b){a.handleSubmenuRetractorEnd(b,this,a)})}},initializeResponsiveToggle:function(){var a=this;this.$toggles.on("click","a",function(a){a.stopPropagation()});this.$toggles.on("click",function(d){a.toggle(b(this),a,d)})},toggle:function(a,
|
15 |
+
d,c){c.preventDefault();c.stopPropagation();if("click"!=c.originalEvent.type||!b(this).data("disableToggle")){if(d.$shiftnav.hasClass("shiftnav-open-target"))d.closeShiftNav();else{a=a.attr("id");var h="shiftnav-toggle-main"==a?"[Main Toggle Bar]":'"'+b(this).text()+'"';"shiftnav-toggle-main-button"!=a&&"shiftnav-toggle-main"!=a||!b("body").hasClass("shiftnav-open")?d.openShiftNav("toggle: "+h):b(".shiftnav.shiftnav-open-target").shiftnav("closeShiftNav")}"click"!=c.originalEvent.type&&(b(this).data("disableToggle",
|
16 |
+
!0),setTimeout(function(){b(this).data("disableToggle",!1)},1E3));return!1}},openShiftNav:function(a){var d=this;this.settings.debug&&console.log("openShiftNav "+(a||"?"));b("body").removeClass("shiftnav-open-right shiftnav-open-left").addClass(this.openclass).addClass("shiftnav-transitioning");b(".shiftnav-open-target").removeClass("shiftnav-open-target");this.$shiftnav.addClass("shiftnav-open-target").on(d.transitionend,function(){b("body").removeClass("shiftnav-transitioning");b(this).off(d.transitionend)});
|
17 |
+
this.disableTouchoffClose();this.initializeTouchoffClose()},closeShiftNav:function(){var a=this;b("body").removeClass(this.openclass).addClass("shiftnav-transitioning");this.$shiftnav.removeClass("shiftnav-open-target").on(a.transitionend,function(){b("body").removeClass("shiftnav-transitioning");b(this).off(a.transitionend)});this.disableTouchoffClose()},initializeTouchoffClose:function(){if(this.settings.touchOffClose){var a=this;b(g).on("click.shiftnav "+this.touchEnd+".shiftnav",function(b){a.handleTouchoffClose(b,
|
18 |
+
this,a)})}},disableTouchoffClose:function(){b(g).off(".shiftnav")},handleMouseActivation:function(a,d,c){c.settings.debug&&console.log("handleMouseover, add mouseout",a);a=b(d).parent();a.hasClass("shiftnav-active")?c.closeSubmenu(a,"mouseActivate",c):c.openSubmenu(a,"mouseActivate",c)},handleSubmenuRetractorEnd:function(a,d,c){a.preventDefault();a.stopPropagation();a=b(d).parent("ul").parent("li");c.closeSubmenu(a,"handleSubmenuRetractor",c);c.settings.debug&&console.log("handleSubmenuRetractorEnd "+
|
19 |
+
a.find("> a").text())},handleTouchoffClose:function(a,d,c){b("body").is(".shiftnav-transitioning")||0!==b(a.target).parents().add(b(a.target)).filter(".shiftnav, .shiftnav-toggle, .shiftnav-ignore").length||(c.settings.debug&&console.log("touchoff close ",a),a.preventDefault(),a.stopPropagation(),c.closeShiftNav(),c.disableTouchoffClose())},scrollPanel:function(a){if("off"==shiftnav_data.scroll_panel)return 0;if("undefined"==typeof a)return this.$shiftnav.find(".shiftnav-inner").scrollTop();this.$shiftnav.find(".shiftnav-inner").scrollTop(a)},
|
20 |
+
openSubmenu:function(a,b,c){a.hasClass("shiftnav-active")||(a.hasClass("shiftnav-sub-shift")?(a.siblings(".shiftnav-active").removeClass("shiftnav-active"),a.toggleClass("shiftnav-caulk"),c.$shiftnav.addClass("shiftnav-sub-shift-active")):c.settings.collapse_accordions&&a.siblings(".shiftnav-active").removeClass("shiftnav-active"),a.parents("ul").removeClass("shiftnav-sub-active-current"),a.find("> ul").addClass("shiftnav-sub-active").addClass("shiftnav-sub-active-current"),setTimeout(function(){a.addClass("shiftnav-active");
|
21 |
+
a.trigger("shiftnav-open-submenu");a.removeClass("shiftnav-caulk");setTimeout(function(){var b=c.scrollPanel();a.data("scroll-back",b);b=a.offset().top+b;c.scrollPanel(b)},100)},1))},closeSubmenu:function(a,d,c){this.settings.debug&&console.log("closeSubmenu "+a.find(">a").text()+" ["+d+"]");a.hasClass("menu-item-has-children")&&a.hasClass("shiftnav-active")&&(a.addClass("shiftnav-in-transition"),a.each(function(){var a=b(this),e=a.find("> ul");e.on(c.transitionend+"_closesubmenu",function(){c.settings.debug&&
|
22 |
+
console.log("finished submenu close transition");a.removeClass("shiftnav-in-transition");e.off(c.transitionend+"_closesubmenu")});c.closeSubmenu(a.find(".shiftnav-active"),d+"_recursive",c)}));a.removeClass("shiftnav-active");if(a.hasClass("shiftnav-sub-shift")){0==a.parents(".shiftnav-sub-shift").length&&c.$shiftnav.removeClass("shiftnav-sub-shift-active");var e=a.data("scroll-back");"undefined"!==e&&c.scrollPanel(e)}a.find("> ul").removeClass("shiftnav-sub-active").removeClass("shiftnav-sub-active-current");
|
23 |
+
a.closest("ul").addClass("shiftnav-sub-active-current");a.trigger("shiftnav-close-submenu")},closeAllSubmenus:function(){b(this.element).find("li.menu-item-has-children").removeClass("shiftnav-active")}};b.fn.shiftnav=function(a){var d=arguments;if(a===e||"object"===typeof a)return this.each(function(){b.data(this,"plugin_shiftnav")||b.data(this,"plugin_shiftnav",new k(this,a))});if("string"===typeof a&&"_"!==a[0]&&"init"!==a){var c;this.each(function(){var e=b.data(this,"plugin_shiftnav");e instanceof
|
24 |
+
k&&"function"===typeof e[a]&&(c=e[a].apply(e,Array.prototype.slice.call(d,1)));"destroy"===a&&b.data(this,"plugin_shiftnav",null)});return c!==e?c:this}}})(jQuery,window,document);
|
25 |
+
(function(b){function f(e){if(!g){g=!0;"undefined"!=typeof console&&"window.load"==e&&console.log("ShiftNav initialized via "+e);b(".shiftnav-loading").remove();jQuery(".shiftnav").shiftnav({open_current:"on"==shiftnav_data.open_current?!0:!1,collapse_accordions:"on"==shiftnav_data.collapse_accordions?!0:!1,breakpoint:parseInt(shiftnav_data.breakpoint),touchOffClose:"on"==shiftnav_data.touch_off_close?!0:!1,scroll_offset:shiftnav_data.scroll_offset,disable_transforms:"on"==shiftnav_data.disable_transforms?
|
26 |
+
!0:!1});if("."==window.location.hash.substring(1,2)&&(e=b(window.location.hash.substring(1)),e.length)){var f=e.offset().top-shiftnav_data.scroll_offset;e.length&&window.scrollTo(0,f)}window.location.hash&&(e=window.location.hash,"."==e.substring(1,2)&&(e=e.substring(1)),e=e.replace(/[^#a-z0-9!$&'()*+,;=]/gi,""),e=b(".shiftnav").find('.shiftnav-target[data-shiftnav-scrolltarget="'+e+'"]').parent(),e.length&&(e.siblings().removeClass("current-menu-item").removeClass("current-menu-ancestor"),e.addClass("current-menu-item")));
|
27 |
+
b(".shiftnav").trigger("shiftnav-loaded")}}var g=!1;jQuery(function(b){f("document.ready")});b(window).on("load",function(){f("window.load")})})(jQuery);
|
includes/functions.php
CHANGED
@@ -34,8 +34,9 @@ function shiftnav_inject_css(){
|
|
34 |
if( $toggle_breakpoint != '' ){
|
35 |
if( is_numeric( $toggle_breakpoint ) ) $toggle_breakpoint.='px';
|
36 |
$css.= "\t@media only screen and (min-width:{$toggle_breakpoint}){ ";
|
37 |
-
|
38 |
-
|
|
|
39 |
$css.= "}\n";
|
40 |
|
41 |
$hide_theme_menu = shiftnav_op( 'hide_theme_menu', 'togglebar' );
|
@@ -45,7 +46,7 @@ function shiftnav_inject_css(){
|
|
45 |
$css.= "$hide_theme_menu{ display:none !important; } ";
|
46 |
$css.= "}\n";
|
47 |
}
|
48 |
-
|
49 |
$hide_ubermenu = shiftnav_op( 'hide_ubermenu', 'togglebar' );
|
50 |
if( $hide_ubermenu == 'on' ){
|
51 |
$toggle_breakpoint = ( (int) $toggle_breakpoint ) - 1;
|
@@ -65,21 +66,21 @@ function shiftnav_inject_css(){
|
|
65 |
// if( $tweaks != '' ){
|
66 |
// $css.= "\n\n\t/* Custom CSS Tweaks */\n\t".$tweaks;
|
67 |
// }
|
68 |
-
|
69 |
|
70 |
$css.= shiftnav_get_custom_styles();
|
71 |
|
72 |
|
73 |
/**
|
74 |
-
*
|
75 |
**/
|
76 |
|
77 |
if( $css != '' ): ?>
|
78 |
|
79 |
-
<!-- ShiftNav CSS
|
80 |
================================================================ -->
|
81 |
<style type="text/css" id="shiftnav-dynamic-css">
|
82 |
-
|
83 |
<?php echo $css; ?>
|
84 |
|
85 |
</style>
|
@@ -113,7 +114,7 @@ function shiftnav_direct_injection(){
|
|
113 |
$disable_toggle = true;
|
114 |
add_action( 'shiftnav_toggle_before_content' , 'shiftnav_main_toggle_burger' , 10 , 3 );
|
115 |
}
|
116 |
-
|
117 |
|
118 |
$togglebar_gap = shiftnav_op( 'togglebar_gap' , 'togglebar' );
|
119 |
$toggle_class.= ' shiftnav-togglebar-gap-'.$togglebar_gap;
|
@@ -128,13 +129,13 @@ function shiftnav_direct_injection(){
|
|
128 |
</div> */
|
129 |
|
130 |
$main_toggle_target = apply_filters( 'shiftnav_main_toggle_target' , 'shiftnav-main' );
|
131 |
-
|
132 |
$content = false;
|
133 |
if( $main_toggle_style != 'burger_only' ) $content = shiftnav_main_toggle_content();
|
134 |
-
|
135 |
|
136 |
shiftnav_toggle( $main_toggle_target , $content , array(
|
137 |
-
'id' => 'shiftnav-toggle-main' ,
|
138 |
'el' => 'div',
|
139 |
'class' => $toggle_class,
|
140 |
'disable_toggle' => $disable_toggle,
|
@@ -148,8 +149,8 @@ function shiftnav_direct_injection(){
|
|
148 |
}
|
149 |
|
150 |
if( shiftnav_op( 'display_main' , 'shiftnav-main' ) == 'on' ){
|
151 |
-
shiftnav( 'shiftnav-main' , array(
|
152 |
-
'theme_location' => 'shiftnav' ,
|
153 |
'edge' => shiftnav_op( 'edge' , 'shiftnav-main' ),
|
154 |
));
|
155 |
}
|
@@ -159,13 +160,13 @@ function shiftnav_direct_injection(){
|
|
159 |
}
|
160 |
|
161 |
/*
|
162 |
-
if( current_user_can( 'manage_options') ):
|
163 |
?>
|
164 |
<div class="shiftnav-loading">
|
165 |
<h5>ShiftNav is waiting to load...</h5>
|
166 |
<div class="shiftnav-loading-message">
|
167 |
-
<p>If this message does not disappear, it means you have a javascript
|
168 |
-
issue on your site which is preventing ShiftNav's script from running.
|
169 |
You'll need to resolve that issue in order for ShiftNav to work properly.
|
170 |
</p>
|
171 |
<p>Check for javascript errors by opening up your browser's javascript console.</p>
|
@@ -186,7 +187,7 @@ function shiftnav_main_toggle_burger( $main_toggle , $target_id , $id ){
|
|
186 |
if( $main_toggle ){
|
187 |
$main_toggle_target = apply_filters( 'shiftnav_main_toggle_target' , 'shiftnav-main' );
|
188 |
shiftnav_toggle( $main_toggle_target , '<i class="fa fa-bars"></i>' , array(
|
189 |
-
'id' => 'shiftnav-toggle-main-button' ,
|
190 |
'el' => 'div',
|
191 |
'class' => 'shiftnav-toggle-burger',
|
192 |
'actions' => false, //if we ran the actions, we'd enter into a weird fifth dimension and collapse the universe
|
@@ -233,8 +234,8 @@ function _shiftnav_toggle( $target_id , $content = '', $args = array() ){
|
|
233 |
if( !$disable_toggle ) $class = 'shiftnav-toggle shiftnav-toggle-'.$target_id.' '.$class;
|
234 |
|
235 |
echo "<$el ";
|
236 |
-
if( $id ): ?>id="<?php echo $id; ?>"<?php endif;
|
237 |
-
?> class="<?php echo $class; ?>" data-shiftnav-target="<?php echo $target_id; ?>"><?php
|
238 |
if( $actions ) do_action( 'shiftnav_toggle_before_content' , $main_toggle , $target_id , $id );
|
239 |
if( $icon ) echo '<i class="fa fa-'.$icon.'"></i> ';
|
240 |
echo apply_filters( 'shiftnav_toggle_content' , $content , $target_id , $id );
|
@@ -303,7 +304,7 @@ function shiftnav_load_assets(){
|
|
303 |
//Load custom.css
|
304 |
//$load_custom_css = shiftnav_op( 'load_custom_css' , 'general' );
|
305 |
//if( $load_custom_css == 'on' ) wp_enqueue_style( 'shiftnav-custom' , SHIFTNAV_URL . 'custom/custom.css' );
|
306 |
-
|
307 |
|
308 |
wp_enqueue_script( 'jquery' );
|
309 |
if( SCRIPT_DEBUG ){
|
@@ -313,7 +314,7 @@ function shiftnav_load_assets(){
|
|
313 |
wp_enqueue_script( 'shiftnav' , $assets.'js/shiftnav.min.js' , array( 'jquery' ) , SHIFTNAV_VERSION , true );
|
314 |
}
|
315 |
|
316 |
-
wp_localize_script( 'shiftnav' , 'shiftnav_data' , array(
|
317 |
'shift_body' => shiftnav_op( 'shift_body' , 'general' ),
|
318 |
'shift_body_wrapper' => shiftnav_op( 'shift_body_wrapper' , 'general' ),
|
319 |
'lock_body' => shiftnav_op( 'lock_body' , 'general' ),
|
@@ -322,6 +323,7 @@ function shiftnav_load_assets(){
|
|
322 |
'collapse_accordions' => shiftnav_op( 'collapse_accordions' , 'general' ),
|
323 |
'scroll_panel' => shiftnav_op( 'scroll_panel' , 'general' ),
|
324 |
'breakpoint' => shiftnav_op( 'breakpoint' , 'togglebar' ),
|
|
|
325 |
|
326 |
'touch_off_close' => shiftnav_op( 'touch_off_close' , 'general' ),
|
327 |
'scroll_offset' => shiftnav_op( 'scroll_offset' , 'general' ),
|
@@ -459,7 +461,7 @@ function shiftnav_get_menu_args( $args , $id = 0 ){
|
|
459 |
|
460 |
//Active Highlight
|
461 |
if( shiftnav_op( 'active_highlight' , 'general' ) == 'on' ) $args['menu_class'].= ' shiftnav-active-highlight';
|
462 |
-
|
463 |
|
464 |
return $args;
|
465 |
|
@@ -494,4 +496,3 @@ function shiftp( $d ){
|
|
494 |
echo '</pre>';
|
495 |
|
496 |
}
|
497 |
-
|
34 |
if( $toggle_breakpoint != '' ){
|
35 |
if( is_numeric( $toggle_breakpoint ) ) $toggle_breakpoint.='px';
|
36 |
$css.= "\t@media only screen and (min-width:{$toggle_breakpoint}){ ";
|
37 |
+
//Set the padding-top to 0 above the breakpoint, because it gets set to the toggle height below the breakpoint
|
38 |
+
$css.= "#shiftnav-toggle-main, .shiftnav-toggle-mobile{ display:none; } .shiftnav-wrap { padding-top:0 !important; } ";
|
39 |
+
if( shiftnav_op( 'shift_body' , 'general' ) == 'off' ) $css.= "body.shiftnav-disable-shift-body{ padding-top:0 !important; } ";
|
40 |
$css.= "}\n";
|
41 |
|
42 |
$hide_theme_menu = shiftnav_op( 'hide_theme_menu', 'togglebar' );
|
46 |
$css.= "$hide_theme_menu{ display:none !important; } ";
|
47 |
$css.= "}\n";
|
48 |
}
|
49 |
+
|
50 |
$hide_ubermenu = shiftnav_op( 'hide_ubermenu', 'togglebar' );
|
51 |
if( $hide_ubermenu == 'on' ){
|
52 |
$toggle_breakpoint = ( (int) $toggle_breakpoint ) - 1;
|
66 |
// if( $tweaks != '' ){
|
67 |
// $css.= "\n\n\t/* Custom CSS Tweaks */\n\t".$tweaks;
|
68 |
// }
|
69 |
+
|
70 |
|
71 |
$css.= shiftnav_get_custom_styles();
|
72 |
|
73 |
|
74 |
/**
|
75 |
+
*
|
76 |
**/
|
77 |
|
78 |
if( $css != '' ): ?>
|
79 |
|
80 |
+
<!-- ShiftNav CSS
|
81 |
================================================================ -->
|
82 |
<style type="text/css" id="shiftnav-dynamic-css">
|
83 |
+
|
84 |
<?php echo $css; ?>
|
85 |
|
86 |
</style>
|
114 |
$disable_toggle = true;
|
115 |
add_action( 'shiftnav_toggle_before_content' , 'shiftnav_main_toggle_burger' , 10 , 3 );
|
116 |
}
|
117 |
+
|
118 |
|
119 |
$togglebar_gap = shiftnav_op( 'togglebar_gap' , 'togglebar' );
|
120 |
$toggle_class.= ' shiftnav-togglebar-gap-'.$togglebar_gap;
|
129 |
</div> */
|
130 |
|
131 |
$main_toggle_target = apply_filters( 'shiftnav_main_toggle_target' , 'shiftnav-main' );
|
132 |
+
|
133 |
$content = false;
|
134 |
if( $main_toggle_style != 'burger_only' ) $content = shiftnav_main_toggle_content();
|
135 |
+
|
136 |
|
137 |
shiftnav_toggle( $main_toggle_target , $content , array(
|
138 |
+
'id' => 'shiftnav-toggle-main' ,
|
139 |
'el' => 'div',
|
140 |
'class' => $toggle_class,
|
141 |
'disable_toggle' => $disable_toggle,
|
149 |
}
|
150 |
|
151 |
if( shiftnav_op( 'display_main' , 'shiftnav-main' ) == 'on' ){
|
152 |
+
shiftnav( 'shiftnav-main' , array(
|
153 |
+
'theme_location' => 'shiftnav' ,
|
154 |
'edge' => shiftnav_op( 'edge' , 'shiftnav-main' ),
|
155 |
));
|
156 |
}
|
160 |
}
|
161 |
|
162 |
/*
|
163 |
+
if( current_user_can( 'manage_options') ):
|
164 |
?>
|
165 |
<div class="shiftnav-loading">
|
166 |
<h5>ShiftNav is waiting to load...</h5>
|
167 |
<div class="shiftnav-loading-message">
|
168 |
+
<p>If this message does not disappear, it means you have a javascript
|
169 |
+
issue on your site which is preventing ShiftNav's script from running.
|
170 |
You'll need to resolve that issue in order for ShiftNav to work properly.
|
171 |
</p>
|
172 |
<p>Check for javascript errors by opening up your browser's javascript console.</p>
|
187 |
if( $main_toggle ){
|
188 |
$main_toggle_target = apply_filters( 'shiftnav_main_toggle_target' , 'shiftnav-main' );
|
189 |
shiftnav_toggle( $main_toggle_target , '<i class="fa fa-bars"></i>' , array(
|
190 |
+
'id' => 'shiftnav-toggle-main-button' ,
|
191 |
'el' => 'div',
|
192 |
'class' => 'shiftnav-toggle-burger',
|
193 |
'actions' => false, //if we ran the actions, we'd enter into a weird fifth dimension and collapse the universe
|
234 |
if( !$disable_toggle ) $class = 'shiftnav-toggle shiftnav-toggle-'.$target_id.' '.$class;
|
235 |
|
236 |
echo "<$el ";
|
237 |
+
if( $id ): ?>id="<?php echo $id; ?>"<?php endif;
|
238 |
+
?> class="<?php echo $class; ?>" data-shiftnav-target="<?php echo $target_id; ?>"><?php
|
239 |
if( $actions ) do_action( 'shiftnav_toggle_before_content' , $main_toggle , $target_id , $id );
|
240 |
if( $icon ) echo '<i class="fa fa-'.$icon.'"></i> ';
|
241 |
echo apply_filters( 'shiftnav_toggle_content' , $content , $target_id , $id );
|
304 |
//Load custom.css
|
305 |
//$load_custom_css = shiftnav_op( 'load_custom_css' , 'general' );
|
306 |
//if( $load_custom_css == 'on' ) wp_enqueue_style( 'shiftnav-custom' , SHIFTNAV_URL . 'custom/custom.css' );
|
307 |
+
|
308 |
|
309 |
wp_enqueue_script( 'jquery' );
|
310 |
if( SCRIPT_DEBUG ){
|
314 |
wp_enqueue_script( 'shiftnav' , $assets.'js/shiftnav.min.js' , array( 'jquery' ) , SHIFTNAV_VERSION , true );
|
315 |
}
|
316 |
|
317 |
+
wp_localize_script( 'shiftnav' , 'shiftnav_data' , array(
|
318 |
'shift_body' => shiftnav_op( 'shift_body' , 'general' ),
|
319 |
'shift_body_wrapper' => shiftnav_op( 'shift_body_wrapper' , 'general' ),
|
320 |
'lock_body' => shiftnav_op( 'lock_body' , 'general' ),
|
323 |
'collapse_accordions' => shiftnav_op( 'collapse_accordions' , 'general' ),
|
324 |
'scroll_panel' => shiftnav_op( 'scroll_panel' , 'general' ),
|
325 |
'breakpoint' => shiftnav_op( 'breakpoint' , 'togglebar' ),
|
326 |
+
'v' => SHIFTNAV_VERSION,
|
327 |
|
328 |
'touch_off_close' => shiftnav_op( 'touch_off_close' , 'general' ),
|
329 |
'scroll_offset' => shiftnav_op( 'scroll_offset' , 'general' ),
|
461 |
|
462 |
//Active Highlight
|
463 |
if( shiftnav_op( 'active_highlight' , 'general' ) == 'on' ) $args['menu_class'].= ' shiftnav-active-highlight';
|
464 |
+
|
465 |
|
466 |
return $args;
|
467 |
|
496 |
echo '</pre>';
|
497 |
|
498 |
}
|
|
languages/shiftnav.pot
CHANGED
@@ -1,10 +1,10 @@
|
|
1 |
-
# Copyright (C) 2017
|
2 |
-
# This file is distributed under the same license as the
|
3 |
msgid ""
|
4 |
msgstr ""
|
5 |
-
"Project-Id-Version: \n"
|
6 |
"Report-Msgid-Bugs-To: http://wordpress.org/support/plugin/shiftnav\n"
|
7 |
-
"POT-Creation-Date: 2017-06-
|
8 |
"MIME-Version: 1.0\n"
|
9 |
"Content-Type: text/plain; charset=utf-8\n"
|
10 |
"Content-Transfer-Encoding: 8bit\n"
|
@@ -38,7 +38,7 @@ msgid ""
|
|
38 |
"entirely."
|
39 |
msgstr ""
|
40 |
|
41 |
-
#: admin/settings.config.php:72
|
42 |
msgid "Edge"
|
43 |
msgstr ""
|
44 |
|
@@ -46,19 +46,19 @@ msgstr ""
|
|
46 |
msgid "Which edge of the viewport should the ShiftNav panel appear on?"
|
47 |
msgstr ""
|
48 |
|
49 |
-
#: admin/settings.config.php:88
|
50 |
msgid "Skin"
|
51 |
msgstr ""
|
52 |
|
53 |
-
#: admin/settings.config.php:99
|
54 |
msgid "Indent Always Visible Submenus"
|
55 |
msgstr ""
|
56 |
|
57 |
-
#: admin/settings.config.php:100
|
58 |
msgid "Check this to indent submenu items of always-visible submenus"
|
59 |
msgstr ""
|
60 |
|
61 |
-
#: admin/settings.config.php:109
|
62 |
msgid "Display Site Title"
|
63 |
msgstr ""
|
64 |
|
@@ -66,11 +66,11 @@ msgstr ""
|
|
66 |
msgid "Display the site title in the menu panel"
|
67 |
msgstr ""
|
68 |
|
69 |
-
#: admin/settings.config.php:119
|
70 |
msgid "Display Panel Close Button"
|
71 |
msgstr ""
|
72 |
|
73 |
-
#: admin/settings.config.php:120
|
74 |
msgid "Display an × close button in the upper right of the ShiftNav panel"
|
75 |
msgstr ""
|
76 |
|
@@ -150,7 +150,7 @@ msgid ""
|
|
150 |
"specific UberMenu ID."
|
151 |
msgstr ""
|
152 |
|
153 |
-
#: admin/settings.config.php:209
|
154 |
msgid "Toggle Content"
|
155 |
msgstr ""
|
156 |
|
@@ -376,7 +376,9 @@ msgid "Touch-off close"
|
|
376 |
msgstr ""
|
377 |
|
378 |
#: admin/settings.config.php:467
|
379 |
-
msgid "
|
|
|
|
|
380 |
msgstr ""
|
381 |
|
382 |
#: admin/settings.config.php:475
|
@@ -625,7 +627,7 @@ msgid ""
|
|
625 |
"but item should not be displayed in ShiftNav"
|
626 |
msgstr ""
|
627 |
|
628 |
-
#: admin/settings.menu.php:334
|
629 |
msgid "Submenu Type"
|
630 |
msgstr ""
|
631 |
|
@@ -636,11 +638,12 @@ msgid ""
|
|
636 |
"\"Accordion\" or \"Shift\" with the Pro version."
|
637 |
msgstr ""
|
638 |
|
639 |
-
#: admin/settings.menu.php:339
|
640 |
msgid "Menu Default"
|
641 |
msgstr ""
|
642 |
|
643 |
-
#: admin/settings.menu.php:340
|
|
|
644 |
msgid "Always visible"
|
645 |
msgstr ""
|
646 |
|
@@ -688,6 +691,653 @@ msgstr ""
|
|
688 |
msgid "Back"
|
689 |
msgstr ""
|
690 |
|
691 |
-
#: includes/functions.php:
|
692 |
msgid "ShiftNav [Main]"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
693 |
msgstr ""
|
1 |
+
# Copyright (C) 2017 Chris Mavricos, SevenSpark
|
2 |
+
# This file is distributed under the same license as the ShiftNav Pro - Responsive Mobile Menu package.
|
3 |
msgid ""
|
4 |
msgstr ""
|
5 |
+
"Project-Id-Version: ShiftNav Pro - Responsive Mobile Menu 1.6\n"
|
6 |
"Report-Msgid-Bugs-To: http://wordpress.org/support/plugin/shiftnav\n"
|
7 |
+
"POT-Creation-Date: 2017-06-25 01:55:30+00:00\n"
|
8 |
"MIME-Version: 1.0\n"
|
9 |
"Content-Type: text/plain; charset=utf-8\n"
|
10 |
"Content-Transfer-Encoding: 8bit\n"
|
38 |
"entirely."
|
39 |
msgstr ""
|
40 |
|
41 |
+
#: admin/settings.config.php:72 pro/admin/settings.pro.php:378
|
42 |
msgid "Edge"
|
43 |
msgstr ""
|
44 |
|
46 |
msgid "Which edge of the viewport should the ShiftNav panel appear on?"
|
47 |
msgstr ""
|
48 |
|
49 |
+
#: admin/settings.config.php:88 pro/admin/settings.pro.php:402
|
50 |
msgid "Skin"
|
51 |
msgstr ""
|
52 |
|
53 |
+
#: admin/settings.config.php:99 pro/admin/settings.pro.php:430
|
54 |
msgid "Indent Always Visible Submenus"
|
55 |
msgstr ""
|
56 |
|
57 |
+
#: admin/settings.config.php:100 pro/admin/settings.pro.php:431
|
58 |
msgid "Check this to indent submenu items of always-visible submenus"
|
59 |
msgstr ""
|
60 |
|
61 |
+
#: admin/settings.config.php:109 pro/admin/settings.pro.php:450
|
62 |
msgid "Display Site Title"
|
63 |
msgstr ""
|
64 |
|
66 |
msgid "Display the site title in the menu panel"
|
67 |
msgstr ""
|
68 |
|
69 |
+
#: admin/settings.config.php:119 pro/admin/settings.pro.php:470
|
70 |
msgid "Display Panel Close Button"
|
71 |
msgstr ""
|
72 |
|
73 |
+
#: admin/settings.config.php:120 pro/admin/settings.pro.php:471
|
74 |
msgid "Display an × close button in the upper right of the ShiftNav panel"
|
75 |
msgstr ""
|
76 |
|
150 |
"specific UberMenu ID."
|
151 |
msgstr ""
|
152 |
|
153 |
+
#: admin/settings.config.php:209 pro/admin/settings.pro.php:440
|
154 |
msgid "Toggle Content"
|
155 |
msgstr ""
|
156 |
|
376 |
msgstr ""
|
377 |
|
378 |
#: admin/settings.config.php:467
|
379 |
+
msgid ""
|
380 |
+
"Close the ShiftNav panel or search dropdown when touching any content not "
|
381 |
+
"in the panel."
|
382 |
msgstr ""
|
383 |
|
384 |
#: admin/settings.config.php:475
|
627 |
"but item should not be displayed in ShiftNav"
|
628 |
msgstr ""
|
629 |
|
630 |
+
#: admin/settings.menu.php:334 pro/admin/item.settings.pro.php:41
|
631 |
msgid "Submenu Type"
|
632 |
msgstr ""
|
633 |
|
638 |
"\"Accordion\" or \"Shift\" with the Pro version."
|
639 |
msgstr ""
|
640 |
|
641 |
+
#: admin/settings.menu.php:339 pro/admin/item.settings.pro.php:46
|
642 |
msgid "Menu Default"
|
643 |
msgstr ""
|
644 |
|
645 |
+
#: admin/settings.menu.php:340 pro/admin/item.settings.pro.php:47
|
646 |
+
#: pro/admin/settings.pro.php:206 pro/admin/settings.pro.php:418
|
647 |
msgid "Always visible"
|
648 |
msgstr ""
|
649 |
|
691 |
msgid "Back"
|
692 |
msgstr ""
|
693 |
|
694 |
+
#: includes/functions.php:280
|
695 |
msgid "ShiftNav [Main]"
|
696 |
+
msgstr ""
|
697 |
+
|
698 |
+
#: pro/admin/item.settings.pro.php:9
|
699 |
+
msgid "Icon"
|
700 |
+
msgstr ""
|
701 |
+
|
702 |
+
#: pro/admin/item.settings.pro.php:17
|
703 |
+
msgid "Custom Icon Class"
|
704 |
+
msgstr ""
|
705 |
+
|
706 |
+
#: pro/admin/item.settings.pro.php:33
|
707 |
+
msgid "Custom URL"
|
708 |
+
msgstr ""
|
709 |
+
|
710 |
+
#: pro/admin/item.settings.pro.php:36
|
711 |
+
msgid ""
|
712 |
+
"Customize your link URL - you can use shortcodes here. Your setting will "
|
713 |
+
"be escaped with the esc_url() function"
|
714 |
+
msgstr ""
|
715 |
+
|
716 |
+
#: pro/admin/item.settings.pro.php:44
|
717 |
+
msgid ""
|
718 |
+
"Overrides the default submenu type, which can be set in the Control Panel "
|
719 |
+
"for each menu. "
|
720 |
+
msgstr ""
|
721 |
+
|
722 |
+
#: pro/admin/item.settings.pro.php:48 pro/admin/settings.pro.php:207
|
723 |
+
#: pro/admin/settings.pro.php:419
|
724 |
+
msgid "Accordion"
|
725 |
+
msgstr ""
|
726 |
+
|
727 |
+
#: pro/admin/item.settings.pro.php:49 pro/admin/settings.pro.php:208
|
728 |
+
#: pro/admin/settings.pro.php:420
|
729 |
+
msgid "Shift"
|
730 |
+
msgstr ""
|
731 |
+
|
732 |
+
#: pro/admin/settings.pro.php:202 pro/admin/settings.pro.php:414
|
733 |
+
msgid "Submenu Type Default"
|
734 |
+
msgstr ""
|
735 |
+
|
736 |
+
#: pro/admin/settings.pro.php:203 pro/admin/settings.pro.php:415
|
737 |
+
msgid ""
|
738 |
+
"This submenu type will be used by any Menu Item whose Submenu Type is set "
|
739 |
+
"to \"Menu Default\""
|
740 |
+
msgstr ""
|
741 |
+
|
742 |
+
#: pro/admin/settings.pro.php:218 pro/admin/settings.pro.php:392
|
743 |
+
msgid "Disable Menu"
|
744 |
+
msgstr ""
|
745 |
+
|
746 |
+
#: pro/admin/settings.pro.php:219
|
747 |
+
msgid ""
|
748 |
+
"Check this to disable the menu entirely; the panel will still be displayed "
|
749 |
+
"and can be used for custom content"
|
750 |
+
msgstr ""
|
751 |
+
|
752 |
+
#: pro/admin/settings.pro.php:228 pro/admin/settings.pro.php:480
|
753 |
+
msgid "Top Image"
|
754 |
+
msgstr ""
|
755 |
+
|
756 |
+
#: pro/admin/settings.pro.php:238 pro/admin/settings.pro.php:490
|
757 |
+
msgid "Pad Image"
|
758 |
+
msgstr ""
|
759 |
+
|
760 |
+
#: pro/admin/settings.pro.php:239 pro/admin/settings.pro.php:491
|
761 |
+
msgid ""
|
762 |
+
"Add padding to align image with menu item text. Uncheck to expand to the "
|
763 |
+
"edges of the panel."
|
764 |
+
msgstr ""
|
765 |
+
|
766 |
+
#: pro/admin/settings.pro.php:248 pro/admin/settings.pro.php:500
|
767 |
+
msgid "Image Link (URL)"
|
768 |
+
msgstr ""
|
769 |
+
|
770 |
+
#: pro/admin/settings.pro.php:249 pro/admin/settings.pro.php:501
|
771 |
+
msgid "Make the image a link to this URL."
|
772 |
+
msgstr ""
|
773 |
+
|
774 |
+
#: pro/admin/settings.pro.php:258 pro/admin/settings.pro.php:510
|
775 |
+
msgid "Custom Content Before Menu"
|
776 |
+
msgstr ""
|
777 |
+
|
778 |
+
#: pro/admin/settings.pro.php:269 pro/admin/settings.pro.php:521
|
779 |
+
msgid "Custom Content After Menu"
|
780 |
+
msgstr ""
|
781 |
+
|
782 |
+
#: pro/admin/settings.pro.php:287
|
783 |
+
msgid "Toggle Content Left Edge"
|
784 |
+
msgstr ""
|
785 |
+
|
786 |
+
#: pro/admin/settings.pro.php:288
|
787 |
+
msgid ""
|
788 |
+
"For the Full Bar toggle style, this content will appear at the left edge of "
|
789 |
+
"the toggle bar, to the right of the toggle icon. To pad your custom "
|
790 |
+
"content vertically, use the class <code>shiftnav-toggle-main-block</code>."
|
791 |
+
msgstr ""
|
792 |
+
|
793 |
+
#: pro/admin/settings.pro.php:299
|
794 |
+
msgid "Toggle Content Right Edge"
|
795 |
+
msgstr ""
|
796 |
+
|
797 |
+
#: pro/admin/settings.pro.php:300
|
798 |
+
msgid ""
|
799 |
+
"For the Full Bar toggle style, this content will appear at the right edge "
|
800 |
+
"of the toggle bar. To pad your custom content vertically, use the class "
|
801 |
+
"<code>shiftnav-toggle-main-block</code>."
|
802 |
+
msgstr ""
|
803 |
+
|
804 |
+
#: pro/admin/settings.pro.php:334
|
805 |
+
msgid "Integration Code"
|
806 |
+
msgstr ""
|
807 |
+
|
808 |
+
#: pro/admin/settings.pro.php:340
|
809 |
+
msgid "Instance Name"
|
810 |
+
msgstr ""
|
811 |
+
|
812 |
+
#: pro/admin/settings.pro.php:349
|
813 |
+
msgid "Automatically Generate Panel"
|
814 |
+
msgstr ""
|
815 |
+
|
816 |
+
#: pro/admin/settings.pro.php:350
|
817 |
+
msgid ""
|
818 |
+
"Automatically generate this ShiftNav instance. It'll be added to each page "
|
819 |
+
"of the site"
|
820 |
+
msgstr ""
|
821 |
+
|
822 |
+
#: pro/admin/settings.pro.php:358
|
823 |
+
msgid "Display Menu"
|
824 |
+
msgstr ""
|
825 |
+
|
826 |
+
#: pro/admin/settings.pro.php:368
|
827 |
+
msgid "Theme Location"
|
828 |
+
msgstr ""
|
829 |
+
|
830 |
+
#: pro/admin/settings.pro.php:369
|
831 |
+
msgid ""
|
832 |
+
"Select the Theme Location to display. The Menu setting will override this "
|
833 |
+
"setting if a menu is selected."
|
834 |
+
msgstr ""
|
835 |
+
|
836 |
+
#: pro/admin/settings.pro.php:379
|
837 |
+
msgid "Select which edge of your site to display the menu on"
|
838 |
+
msgstr ""
|
839 |
+
|
840 |
+
#: pro/admin/settings.pro.php:393
|
841 |
+
msgid ""
|
842 |
+
"Check this to disable the menu entirely; the panel can be used for custom "
|
843 |
+
"content"
|
844 |
+
msgstr ""
|
845 |
+
|
846 |
+
#: pro/admin/settings.pro.php:403
|
847 |
+
msgid "Select which skin to use for this instance"
|
848 |
+
msgstr ""
|
849 |
+
|
850 |
+
#: pro/admin/settings.pro.php:441
|
851 |
+
msgid ""
|
852 |
+
"Enter the content to be displayed in the toggle, which you will insert into "
|
853 |
+
"your template with the integration code at the top of this tab."
|
854 |
+
msgstr ""
|
855 |
+
|
856 |
+
#: pro/admin/settings.pro.php:451
|
857 |
+
msgid "Display the site title in the menu"
|
858 |
+
msgstr ""
|
859 |
+
|
860 |
+
#: pro/admin/settings.pro.php:460
|
861 |
+
msgid "Display Instance Name"
|
862 |
+
msgstr ""
|
863 |
+
|
864 |
+
#: pro/admin/settings.pro.php:461
|
865 |
+
msgid "Display the instance name in the menu"
|
866 |
+
msgstr ""
|
867 |
+
|
868 |
+
#: pro/admin/settings.pro.php:549
|
869 |
+
msgid "Delete Instance"
|
870 |
+
msgstr ""
|
871 |
+
|
872 |
+
#: pro/admin/settings.pro.php:550
|
873 |
+
msgid "Permanently Delete Instance"
|
874 |
+
msgstr ""
|
875 |
+
|
876 |
+
#: pro/admin/settings.pro.php:584
|
877 |
+
msgid "Panel Background Color"
|
878 |
+
msgstr ""
|
879 |
+
|
880 |
+
#: pro/admin/settings.pro.php:595
|
881 |
+
msgid "Panel Default Font Color"
|
882 |
+
msgstr ""
|
883 |
+
|
884 |
+
#: pro/admin/settings.pro.php:596
|
885 |
+
msgid ""
|
886 |
+
"The default font color for custom content within the panel (menu-specific "
|
887 |
+
"styles will override this for menu items)"
|
888 |
+
msgstr ""
|
889 |
+
|
890 |
+
#: pro/admin/settings.pro.php:611
|
891 |
+
msgid "Panel Title Font Color"
|
892 |
+
msgstr ""
|
893 |
+
|
894 |
+
#: pro/admin/settings.pro.php:612
|
895 |
+
msgid "The font color for the header/title within the panel."
|
896 |
+
msgstr ""
|
897 |
+
|
898 |
+
#: pro/admin/settings.pro.php:622
|
899 |
+
msgid "Panel Title Font Size"
|
900 |
+
msgstr ""
|
901 |
+
|
902 |
+
#: pro/admin/settings.pro.php:623 pro/admin/settings.pro.php:848
|
903 |
+
msgid "The font size for the header/title within the panel."
|
904 |
+
msgstr ""
|
905 |
+
|
906 |
+
#: pro/admin/settings.pro.php:633
|
907 |
+
msgid "Panel Title Text Alignment"
|
908 |
+
msgstr ""
|
909 |
+
|
910 |
+
#: pro/admin/settings.pro.php:634
|
911 |
+
msgid "The alignment of the text in the header/title within the panel."
|
912 |
+
msgstr ""
|
913 |
+
|
914 |
+
#: pro/admin/settings.pro.php:637 pro/admin/settings.pro.php:654
|
915 |
+
#: pro/admin/settings.pro.php:767 pro/admin/settings.pro.php:937
|
916 |
+
#: pro/admin/settings.pro.php:1023
|
917 |
+
msgid "Defaut"
|
918 |
+
msgstr ""
|
919 |
+
|
920 |
+
#: pro/admin/settings.pro.php:638 pro/admin/settings.pro.php:938
|
921 |
+
msgid "Center"
|
922 |
+
msgstr ""
|
923 |
+
|
924 |
+
#: pro/admin/settings.pro.php:639 pro/admin/settings.pro.php:939
|
925 |
+
msgid "Left"
|
926 |
+
msgstr ""
|
927 |
+
|
928 |
+
#: pro/admin/settings.pro.php:640 pro/admin/settings.pro.php:940
|
929 |
+
msgid "Right"
|
930 |
+
msgstr ""
|
931 |
+
|
932 |
+
#: pro/admin/settings.pro.php:650
|
933 |
+
msgid "Panel Title Font Weight"
|
934 |
+
msgstr ""
|
935 |
+
|
936 |
+
#: pro/admin/settings.pro.php:651
|
937 |
+
msgid "The font weight of the text in the header/title within the panel."
|
938 |
+
msgstr ""
|
939 |
+
|
940 |
+
#: pro/admin/settings.pro.php:655 pro/admin/settings.pro.php:768
|
941 |
+
#: pro/admin/settings.pro.php:1024
|
942 |
+
msgid "Normal"
|
943 |
+
msgstr ""
|
944 |
+
|
945 |
+
#: pro/admin/settings.pro.php:656 pro/admin/settings.pro.php:769
|
946 |
+
#: pro/admin/settings.pro.php:1025
|
947 |
+
msgid "Bold"
|
948 |
+
msgstr ""
|
949 |
+
|
950 |
+
#: pro/admin/settings.pro.php:673
|
951 |
+
msgid "Menu Item Background Color"
|
952 |
+
msgstr ""
|
953 |
+
|
954 |
+
#: pro/admin/settings.pro.php:674
|
955 |
+
msgid ""
|
956 |
+
"The color of the menu item background. Normally not necessary to set "
|
957 |
+
"unless you want it to differ from the panel background"
|
958 |
+
msgstr ""
|
959 |
+
|
960 |
+
#: pro/admin/settings.pro.php:682
|
961 |
+
msgid "Menu Item Font Color"
|
962 |
+
msgstr ""
|
963 |
+
|
964 |
+
#: pro/admin/settings.pro.php:683
|
965 |
+
msgid "The color of the menu item text."
|
966 |
+
msgstr ""
|
967 |
+
|
968 |
+
#: pro/admin/settings.pro.php:693
|
969 |
+
msgid "Menu Item Background Color [Active]"
|
970 |
+
msgstr ""
|
971 |
+
|
972 |
+
#: pro/admin/settings.pro.php:694
|
973 |
+
msgid "The color of the menu item background when activated."
|
974 |
+
msgstr ""
|
975 |
+
|
976 |
+
#: pro/admin/settings.pro.php:702
|
977 |
+
msgid "Menu Item Font Color [Active]"
|
978 |
+
msgstr ""
|
979 |
+
|
980 |
+
#: pro/admin/settings.pro.php:703
|
981 |
+
msgid "The color of the menu item text when activated."
|
982 |
+
msgstr ""
|
983 |
+
|
984 |
+
#: pro/admin/settings.pro.php:713
|
985 |
+
msgid "Menu Item Background Color [Current]"
|
986 |
+
msgstr ""
|
987 |
+
|
988 |
+
#: pro/admin/settings.pro.php:714
|
989 |
+
msgid "The background color of current menu items."
|
990 |
+
msgstr ""
|
991 |
+
|
992 |
+
#: pro/admin/settings.pro.php:722
|
993 |
+
msgid "Menu Item Font Color [Current]"
|
994 |
+
msgstr ""
|
995 |
+
|
996 |
+
#: pro/admin/settings.pro.php:723
|
997 |
+
msgid "The font color of current menu items"
|
998 |
+
msgstr ""
|
999 |
+
|
1000 |
+
#: pro/admin/settings.pro.php:733
|
1001 |
+
msgid "Menu Item Background Color [Highlight]"
|
1002 |
+
msgstr ""
|
1003 |
+
|
1004 |
+
#: pro/admin/settings.pro.php:734
|
1005 |
+
msgid "The background color of highlighted menu items."
|
1006 |
+
msgstr ""
|
1007 |
+
|
1008 |
+
#: pro/admin/settings.pro.php:742
|
1009 |
+
msgid "Menu Item Font Color [Highlight]"
|
1010 |
+
msgstr ""
|
1011 |
+
|
1012 |
+
#: pro/admin/settings.pro.php:743
|
1013 |
+
msgid "The color of highlighted menu items"
|
1014 |
+
msgstr ""
|
1015 |
+
|
1016 |
+
#: pro/admin/settings.pro.php:754
|
1017 |
+
msgid "Menu Item Font Size"
|
1018 |
+
msgstr ""
|
1019 |
+
|
1020 |
+
#: pro/admin/settings.pro.php:755
|
1021 |
+
msgid "The size of the menu item text."
|
1022 |
+
msgstr ""
|
1023 |
+
|
1024 |
+
#: pro/admin/settings.pro.php:763
|
1025 |
+
msgid "Menu Item Font Weight"
|
1026 |
+
msgstr ""
|
1027 |
+
|
1028 |
+
#: pro/admin/settings.pro.php:764
|
1029 |
+
msgid "The weight of the menu item text."
|
1030 |
+
msgstr ""
|
1031 |
+
|
1032 |
+
#: pro/admin/settings.pro.php:777
|
1033 |
+
msgid "Menu Item Padding"
|
1034 |
+
msgstr ""
|
1035 |
+
|
1036 |
+
#: pro/admin/settings.pro.php:778
|
1037 |
+
msgid "The padding around the menu item text."
|
1038 |
+
msgstr ""
|
1039 |
+
|
1040 |
+
#: pro/admin/settings.pro.php:786
|
1041 |
+
msgid "Menu Item Top Border Color"
|
1042 |
+
msgstr ""
|
1043 |
+
|
1044 |
+
#: pro/admin/settings.pro.php:787
|
1045 |
+
msgid "The color of the top border of the menu item."
|
1046 |
+
msgstr ""
|
1047 |
+
|
1048 |
+
#: pro/admin/settings.pro.php:795
|
1049 |
+
msgid "Menu Item Top Border Color [Active]"
|
1050 |
+
msgstr ""
|
1051 |
+
|
1052 |
+
#: pro/admin/settings.pro.php:796
|
1053 |
+
msgid "The color of the top border of an active menu item."
|
1054 |
+
msgstr ""
|
1055 |
+
|
1056 |
+
#: pro/admin/settings.pro.php:804
|
1057 |
+
msgid "Menu Item Bottom Border Color"
|
1058 |
+
msgstr ""
|
1059 |
+
|
1060 |
+
#: pro/admin/settings.pro.php:805
|
1061 |
+
msgid "The color of the bottom border of the menu item."
|
1062 |
+
msgstr ""
|
1063 |
+
|
1064 |
+
#: pro/admin/settings.pro.php:814
|
1065 |
+
msgid "Menu Item Bottom Border Color [Active]"
|
1066 |
+
msgstr ""
|
1067 |
+
|
1068 |
+
#: pro/admin/settings.pro.php:815
|
1069 |
+
msgid "The color of the bottom border of the active menu item."
|
1070 |
+
msgstr ""
|
1071 |
+
|
1072 |
+
#: pro/admin/settings.pro.php:824 pro/admin/settings.pro.php:1000
|
1073 |
+
msgid "Disable Menu Item Borders"
|
1074 |
+
msgstr ""
|
1075 |
+
|
1076 |
+
#: pro/admin/settings.pro.php:825 pro/admin/settings.pro.php:1001
|
1077 |
+
msgid "Remove the borders between menu items."
|
1078 |
+
msgstr ""
|
1079 |
+
|
1080 |
+
#: pro/admin/settings.pro.php:835
|
1081 |
+
msgid "Disable Menu Item Text Shadow"
|
1082 |
+
msgstr ""
|
1083 |
+
|
1084 |
+
#: pro/admin/settings.pro.php:836
|
1085 |
+
msgid "Remove the text shadow on the menu items."
|
1086 |
+
msgstr ""
|
1087 |
+
|
1088 |
+
#: pro/admin/settings.pro.php:847
|
1089 |
+
msgid "Top Level Menu Item Text Transform"
|
1090 |
+
msgstr ""
|
1091 |
+
|
1092 |
+
#: pro/admin/settings.pro.php:851
|
1093 |
+
msgid "Default"
|
1094 |
+
msgstr ""
|
1095 |
+
|
1096 |
+
#: pro/admin/settings.pro.php:852
|
1097 |
+
msgid "None"
|
1098 |
+
msgstr ""
|
1099 |
+
|
1100 |
+
#: pro/admin/settings.pro.php:853
|
1101 |
+
msgid "Uppercase"
|
1102 |
+
msgstr ""
|
1103 |
+
|
1104 |
+
#: pro/admin/settings.pro.php:868
|
1105 |
+
msgid "Menu Item Activator Button Background"
|
1106 |
+
msgstr ""
|
1107 |
+
|
1108 |
+
#: pro/admin/settings.pro.php:869
|
1109 |
+
msgid "The background color of the button used to open and close the submenus"
|
1110 |
+
msgstr ""
|
1111 |
+
|
1112 |
+
#: pro/admin/settings.pro.php:877
|
1113 |
+
msgid "Menu Item Activator Button Background [Active]"
|
1114 |
+
msgstr ""
|
1115 |
+
|
1116 |
+
#: pro/admin/settings.pro.php:878
|
1117 |
+
msgid ""
|
1118 |
+
"The active background color of the button used to open and close the "
|
1119 |
+
"submenus"
|
1120 |
+
msgstr ""
|
1121 |
+
|
1122 |
+
#: pro/admin/settings.pro.php:886
|
1123 |
+
msgid "Menu Item Activator Arrow Color"
|
1124 |
+
msgstr ""
|
1125 |
+
|
1126 |
+
#: pro/admin/settings.pro.php:887
|
1127 |
+
msgid "The arrow color of the button used to open and close the submenus"
|
1128 |
+
msgstr ""
|
1129 |
+
|
1130 |
+
#: pro/admin/settings.pro.php:895
|
1131 |
+
msgid "Menu Item Activator Arrow Color [Active]"
|
1132 |
+
msgstr ""
|
1133 |
+
|
1134 |
+
#: pro/admin/settings.pro.php:896
|
1135 |
+
msgid "The active arrow color of the button used to open and close the submenus"
|
1136 |
+
msgstr ""
|
1137 |
+
|
1138 |
+
#: pro/admin/settings.pro.php:915
|
1139 |
+
msgid "Submenu Retractor / Back Button Background"
|
1140 |
+
msgstr ""
|
1141 |
+
|
1142 |
+
#: pro/admin/settings.pro.php:916
|
1143 |
+
msgid "The background color of the submenu retractor button"
|
1144 |
+
msgstr ""
|
1145 |
+
|
1146 |
+
#: pro/admin/settings.pro.php:924
|
1147 |
+
msgid "Submenu Retractor / Back Button Font Color"
|
1148 |
+
msgstr ""
|
1149 |
+
|
1150 |
+
#: pro/admin/settings.pro.php:925
|
1151 |
+
msgid "The font color of the submenu retractor button"
|
1152 |
+
msgstr ""
|
1153 |
+
|
1154 |
+
#: pro/admin/settings.pro.php:933
|
1155 |
+
msgid "Submenu Retractor / Back Button Alignment"
|
1156 |
+
msgstr ""
|
1157 |
+
|
1158 |
+
#: pro/admin/settings.pro.php:934
|
1159 |
+
msgid "The alignment of the submenu retractor button text"
|
1160 |
+
msgstr ""
|
1161 |
+
|
1162 |
+
#: pro/admin/settings.pro.php:952
|
1163 |
+
msgid "Submenu Background Color"
|
1164 |
+
msgstr ""
|
1165 |
+
|
1166 |
+
#: pro/admin/settings.pro.php:953
|
1167 |
+
msgid "The background color of the submenu"
|
1168 |
+
msgstr ""
|
1169 |
+
|
1170 |
+
#: pro/admin/settings.pro.php:962
|
1171 |
+
msgid "Submenu Item Background Color"
|
1172 |
+
msgstr ""
|
1173 |
+
|
1174 |
+
#: pro/admin/settings.pro.php:963
|
1175 |
+
msgid "The background color of the individual submenu items"
|
1176 |
+
msgstr ""
|
1177 |
+
|
1178 |
+
#: pro/admin/settings.pro.php:972
|
1179 |
+
msgid "Submenu Item Font Color"
|
1180 |
+
msgstr ""
|
1181 |
+
|
1182 |
+
#: pro/admin/settings.pro.php:973
|
1183 |
+
msgid "The font color of the submenu items"
|
1184 |
+
msgstr ""
|
1185 |
+
|
1186 |
+
#: pro/admin/settings.pro.php:981
|
1187 |
+
msgid "Submenu Item Top Border Color"
|
1188 |
+
msgstr ""
|
1189 |
+
|
1190 |
+
#: pro/admin/settings.pro.php:982
|
1191 |
+
msgid "The color of the submenu item top border"
|
1192 |
+
msgstr ""
|
1193 |
+
|
1194 |
+
#: pro/admin/settings.pro.php:990
|
1195 |
+
msgid "Submenu Item Bottom Border Color"
|
1196 |
+
msgstr ""
|
1197 |
+
|
1198 |
+
#: pro/admin/settings.pro.php:991
|
1199 |
+
msgid "The color of the bottom border of the submenu items"
|
1200 |
+
msgstr ""
|
1201 |
+
|
1202 |
+
#: pro/admin/settings.pro.php:1010
|
1203 |
+
msgid "Submenu Item Font Size"
|
1204 |
+
msgstr ""
|
1205 |
+
|
1206 |
+
#: pro/admin/settings.pro.php:1011
|
1207 |
+
msgid "The font size of the submenu items"
|
1208 |
+
msgstr ""
|
1209 |
+
|
1210 |
+
#: pro/admin/settings.pro.php:1019
|
1211 |
+
msgid "Submenu Item Font Weight"
|
1212 |
+
msgstr ""
|
1213 |
+
|
1214 |
+
#: pro/admin/settings.pro.php:1020
|
1215 |
+
msgid "The font weight of the submenu items"
|
1216 |
+
msgstr ""
|
1217 |
+
|
1218 |
+
#: pro/admin/settings.pro.php:1036
|
1219 |
+
msgid "Font Family"
|
1220 |
+
msgstr ""
|
1221 |
+
|
1222 |
+
#: pro/admin/settings.pro.php:1037
|
1223 |
+
msgid ""
|
1224 |
+
"The font family the panel. This should be a system font or else the font "
|
1225 |
+
"assets should already be loaded on your site, via @font-face or Google "
|
1226 |
+
"Fonts for example."
|
1227 |
+
msgstr ""
|
1228 |
+
|
1229 |
+
#: pro/search.php:23 pro/search.php:66
|
1230 |
+
msgid "Search..."
|
1231 |
+
msgstr ""
|
1232 |
+
|
1233 |
+
#: pro/updates/EDD_SL_Plugin_Updater.php:177
|
1234 |
+
msgid ""
|
1235 |
+
"There is a new version of %1$s available. <a target=\"_blank\" "
|
1236 |
+
"class=\"thickbox\" href=\"%2$s\">View version %3$s details</a>."
|
1237 |
+
msgstr ""
|
1238 |
+
|
1239 |
+
#: pro/updates/EDD_SL_Plugin_Updater.php:184
|
1240 |
+
msgid ""
|
1241 |
+
"There is a new version of %1$s available. <a target=\"_blank\" "
|
1242 |
+
"class=\"thickbox\" href=\"%2$s\">View version %3$s details</a> or <a "
|
1243 |
+
"href=\"%4$s\">update now</a>."
|
1244 |
+
msgstr ""
|
1245 |
+
|
1246 |
+
#: pro/updates/EDD_SL_Plugin_Updater.php:324
|
1247 |
+
msgid "You do not have permission to install plugin updates"
|
1248 |
+
msgstr ""
|
1249 |
+
|
1250 |
+
#: pro/updates/EDD_SL_Plugin_Updater.php:324
|
1251 |
+
msgid "Error"
|
1252 |
+
msgstr ""
|
1253 |
+
|
1254 |
+
#: pro/updates/backup.php:167
|
1255 |
+
msgid ""
|
1256 |
+
"ShiftNav: Could not restore custom.css file, as the directory is not "
|
1257 |
+
"writable. You can manually restore the file from the "
|
1258 |
+
"wp-content/uploads/shiftnav_backups directory"
|
1259 |
+
msgstr ""
|
1260 |
+
|
1261 |
+
#: pro/updates/backup.php:170
|
1262 |
+
msgid "ShiftNav: Successfully restored custom.css file"
|
1263 |
+
msgstr ""
|
1264 |
+
|
1265 |
+
#: pro/updates/backup.php:181
|
1266 |
+
msgid ""
|
1267 |
+
"ShiftNav: Could not restore custom.less file, as the directory is not "
|
1268 |
+
"writable. You can manually restore the file from the "
|
1269 |
+
"wp-content/uploads/shiftnav_backups directory"
|
1270 |
+
msgstr ""
|
1271 |
+
|
1272 |
+
#: pro/updates/backup.php:184
|
1273 |
+
msgid "ShiftNav: Successfully restored custom.less file"
|
1274 |
+
msgstr ""
|
1275 |
+
|
1276 |
+
#: pro/updates/backup.php:195
|
1277 |
+
msgid ""
|
1278 |
+
"ShiftNav: Could not restore custom.js file, as the directory is not "
|
1279 |
+
"writable. You can manually restore the file from the "
|
1280 |
+
"wp-content/uploads/shiftnav_backups directory"
|
1281 |
+
msgstr ""
|
1282 |
+
|
1283 |
+
#: pro/updates/backup.php:198
|
1284 |
+
msgid "ShiftNav: Successfully restored custom.js file"
|
1285 |
+
msgstr ""
|
1286 |
+
|
1287 |
+
#: pro/updates/updater.php:44
|
1288 |
+
msgid "Updates"
|
1289 |
+
msgstr ""
|
1290 |
+
|
1291 |
+
#: pro/updates/updater.php:56
|
1292 |
+
msgid "Enter your license code to receive updates"
|
1293 |
+
msgstr ""
|
1294 |
+
|
1295 |
+
#: pro/updates/updater.php:96
|
1296 |
+
msgid "License Invalid"
|
1297 |
+
msgstr ""
|
1298 |
+
|
1299 |
+
#: pro/updates/updater.php:105
|
1300 |
+
msgid "License Expired"
|
1301 |
+
msgstr ""
|
1302 |
+
|
1303 |
+
#: pro/updates/updater.php:110
|
1304 |
+
msgid "License is valid"
|
1305 |
+
msgstr ""
|
1306 |
+
|
1307 |
+
#: pro/updates/updater.php:166
|
1308 |
+
msgid "Backup custom assets"
|
1309 |
+
msgstr ""
|
1310 |
+
|
1311 |
+
#: pro/updates/updater.php:167
|
1312 |
+
msgid ""
|
1313 |
+
"Automatically backup custom.css and custom.less so that they can be "
|
1314 |
+
"restored after updating the plugin"
|
1315 |
+
msgstr ""
|
1316 |
+
|
1317 |
+
#: pro/updates/updater.php:175
|
1318 |
+
msgid "Automatic backups status"
|
1319 |
+
msgstr ""
|
1320 |
+
|
1321 |
+
#: pro/updates/updater.php:193
|
1322 |
+
msgid "License Code"
|
1323 |
+
msgstr ""
|
1324 |
+
|
1325 |
+
#. Plugin Name of the plugin/theme
|
1326 |
+
msgid "ShiftNav Pro - Responsive Mobile Menu"
|
1327 |
+
msgstr ""
|
1328 |
+
|
1329 |
+
#. Plugin URI of the plugin/theme
|
1330 |
+
msgid "http://shiftnav.io"
|
1331 |
+
msgstr ""
|
1332 |
+
|
1333 |
+
#. Description of the plugin/theme
|
1334 |
+
msgid "An off-canvas mobile menu for WordPress with advanced functionality"
|
1335 |
+
msgstr ""
|
1336 |
+
|
1337 |
+
#. Author of the plugin/theme
|
1338 |
+
msgid "Chris Mavricos, SevenSpark"
|
1339 |
+
msgstr ""
|
1340 |
+
|
1341 |
+
#. Author URI of the plugin/theme
|
1342 |
+
msgid "http://sevenspark.com"
|
1343 |
msgstr ""
|
package.json
CHANGED
@@ -9,5 +9,9 @@
|
|
9 |
"grunt-contrib-nodeunit": "~0.4.1",
|
10 |
"grunt-contrib-uglify": "~0.5.0",
|
11 |
"grunt-wp-i18n": "^0.4.8"
|
|
|
|
|
|
|
|
|
12 |
}
|
13 |
}
|
9 |
"grunt-contrib-nodeunit": "~0.4.1",
|
10 |
"grunt-contrib-uglify": "~0.5.0",
|
11 |
"grunt-wp-i18n": "^0.4.8"
|
12 |
+
},
|
13 |
+
"dependencies": {
|
14 |
+
"google-closure-compiler": "^20170521.0.0",
|
15 |
+
"grunt-closure-compiler": "0.0.21"
|
16 |
}
|
17 |
}
|
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Donate link: http://shiftnav.io/pro
|
|
4 |
Tags: responsive, menu, navigation, mobile, off-canvas, app, slide, sidebar
|
5 |
Requires at least: 4.0
|
6 |
Tested up to: 4.8
|
7 |
-
Stable tag: 1.
|
8 |
License: GPLv2
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -40,7 +40,7 @@ ShiftNav will open with a slide transition with browsers that support it. For b
|
|
40 |
|
41 |
== Installation ==
|
42 |
|
43 |
-
Install ShiftNav just like any other WordPress plugin.
|
44 |
|
45 |
<a href="http://sevenspark.com/docs/shiftnav-setup">Full Installation & Setup Instructions</a>
|
46 |
|
@@ -57,6 +57,14 @@ Please see the [ShiftNav Quick Setup Guide](http://sevenspark.com/docs/shiftnav-
|
|
57 |
== Changelog ==
|
58 |
|
59 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
60 |
= 1.5.2 =
|
61 |
|
62 |
* Enhancement: Reorganize code to better handle deferred and async javascript
|
@@ -65,10 +73,9 @@ Please see the [ShiftNav Quick Setup Guide](http://sevenspark.com/docs/shiftnav-
|
|
65 |
|
66 |
|
67 |
|
68 |
-
|
69 |
= 1.5.1.2 =
|
70 |
|
71 |
-
* UX Enhancement: Main toggle now closes open secondary menu
|
72 |
* jQuery 3 Compatibility Enhancement: Change .size() calls to .length
|
73 |
* Fix: Remove extraneous closing tag when using UberMenu Menu Segments in ShiftNav
|
74 |
|
@@ -91,7 +98,7 @@ Please see the [ShiftNav Quick Setup Guide](http://sevenspark.com/docs/shiftnav-
|
|
91 |
* Enhancement: Translations can be set in wp-content/languages folder
|
92 |
* Enhancement: Enable or Disable Gap override
|
93 |
* Enhancement: Stronger CSS resets to try to avoid styles from badly coded themes
|
94 |
-
* Various minor enhancements: admin bar line height, remove divs inside spans, remove ShiftNav waiting to load message (use window.load fallback), better arrangement/order of settings,
|
95 |
|
96 |
* [Pro] Feature: Disable Text on individual menu items (can use Icon only items now)
|
97 |
* [Pro] Feature: Search shortcode post_type now configurable
|
@@ -217,4 +224,3 @@ Version 1.3 includes new features and enhancements
|
|
217 |
= 0.1 =
|
218 |
|
219 |
Initial Beta Release
|
220 |
-
|
4 |
Tags: responsive, menu, navigation, mobile, off-canvas, app, slide, sidebar
|
5 |
Requires at least: 4.0
|
6 |
Tested up to: 4.8
|
7 |
+
Stable tag: 1.6
|
8 |
License: GPLv2
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
40 |
|
41 |
== Installation ==
|
42 |
|
43 |
+
Install ShiftNav just like any other WordPress plugin.
|
44 |
|
45 |
<a href="http://sevenspark.com/docs/shiftnav-setup">Full Installation & Setup Instructions</a>
|
46 |
|
57 |
== Changelog ==
|
58 |
|
59 |
|
60 |
+
= 1.6 =
|
61 |
+
|
62 |
+
* Feature: Configure whether to automatically generate each secondary instance or not
|
63 |
+
* Feature: Improved license updater to allow for re-checking and re-registration when necessary, and show expiration date
|
64 |
+
* Enhancement: Touch-off close setting now applies to search dropdown as well as menu panel
|
65 |
+
* Security hardening: Rewrite fragment handling to remove potential DOM-based (client-side) XSS (thanks, Martin Hall!)
|
66 |
+
|
67 |
+
|
68 |
= 1.5.2 =
|
69 |
|
70 |
* Enhancement: Reorganize code to better handle deferred and async javascript
|
73 |
|
74 |
|
75 |
|
|
|
76 |
= 1.5.1.2 =
|
77 |
|
78 |
+
* UX Enhancement: Main toggle now closes open secondary menu
|
79 |
* jQuery 3 Compatibility Enhancement: Change .size() calls to .length
|
80 |
* Fix: Remove extraneous closing tag when using UberMenu Menu Segments in ShiftNav
|
81 |
|
98 |
* Enhancement: Translations can be set in wp-content/languages folder
|
99 |
* Enhancement: Enable or Disable Gap override
|
100 |
* Enhancement: Stronger CSS resets to try to avoid styles from badly coded themes
|
101 |
+
* Various minor enhancements: admin bar line height, remove divs inside spans, remove ShiftNav waiting to load message (use window.load fallback), better arrangement/order of settings,
|
102 |
|
103 |
* [Pro] Feature: Disable Text on individual menu items (can use Icon only items now)
|
104 |
* [Pro] Feature: Search shortcode post_type now configurable
|
224 |
= 0.1 =
|
225 |
|
226 |
Initial Beta Release
|
|
shiftnav-responsive-mobile-menu.php
CHANGED
@@ -6,7 +6,7 @@ Description: An off-canvas mobile menu for WordPress
|
|
6 |
Author: Chris Mavricos, SevenSpark
|
7 |
Author URI: http://sevenspark.com
|
8 |
License: GPLv2
|
9 |
-
Version: 1.
|
10 |
*/
|
11 |
|
12 |
/* Copyright 2014-2017 Chris Mavricos, SevenSpark */
|
@@ -53,7 +53,7 @@ final class ShiftNav {
|
|
53 |
// Plugin version
|
54 |
|
55 |
if( ! defined( 'SHIFTNAV_VERSION' ) )
|
56 |
-
define( 'SHIFTNAV_VERSION', '1.
|
57 |
|
58 |
if( ! defined( 'SHIFTNAV_PRO' ) )
|
59 |
define( 'SHIFTNAV_PRO', false );
|
@@ -96,13 +96,13 @@ final class ShiftNav {
|
|
96 |
|
97 |
//URLS
|
98 |
define( 'SHIFTNAV_SUPPORT_URL' , 'http://sevenspark.com/help' );
|
99 |
-
|
100 |
|
101 |
define( 'SHIFTNAV_PREFIX' , 'shiftnav_' );
|
102 |
}
|
103 |
|
104 |
private function includes() {
|
105 |
-
|
106 |
require_once SHIFTNAV_DIR . 'includes/ShiftNavWalker.class.php';
|
107 |
//require_once SHIFTNAV_DIR . 'includes/icons.php';
|
108 |
require_once SHIFTNAV_DIR . 'includes/functions.php';
|
@@ -178,7 +178,7 @@ final class ShiftNav {
|
|
178 |
if( self::$settings_defaults == null ) self::set_defaults( shiftnav_get_settings_fields() );
|
179 |
|
180 |
if( $section != null && isset( self::$settings_defaults[$section] ) ) return self::$settings_defaults[$section];
|
181 |
-
|
182 |
return self::$settings_defaults;
|
183 |
}
|
184 |
|
@@ -229,7 +229,7 @@ final class ShiftNav {
|
|
229 |
self::$display_now = apply_filters( 'shiftnav_display_now' , $display );
|
230 |
}
|
231 |
|
232 |
-
return self::$display_now;
|
233 |
|
234 |
}
|
235 |
|
@@ -293,14 +293,14 @@ final class ShiftNav {
|
|
293 |
}
|
294 |
|
295 |
/*
|
296 |
-
* If the class already exists, and we're running ShiftNav Pro,
|
297 |
* ShiftNav free needs to be deactivated
|
298 |
*/
|
299 |
elseif ( defined( 'SHIFTNAV_PRO' ) && SHIFTNAV_PRO ) :
|
300 |
|
301 |
function deactivate_shiftnav() {
|
302 |
if ( is_plugin_active('shiftnav-responsive-mobile-menu/shiftnav-responsive-mobile-menu.php') ) {
|
303 |
-
deactivate_plugins('shiftnav-responsive-mobile-menu/shiftnav-responsive-mobile-menu.php');
|
304 |
}
|
305 |
}
|
306 |
add_action( 'admin_init', 'deactivate_shiftnav' );
|
@@ -320,4 +320,3 @@ if( !function_exists( '_SHIFTNAV' ) ){
|
|
320 |
}
|
321 |
_SHIFTNAV();
|
322 |
}
|
323 |
-
|
6 |
Author: Chris Mavricos, SevenSpark
|
7 |
Author URI: http://sevenspark.com
|
8 |
License: GPLv2
|
9 |
+
Version: 1.6
|
10 |
*/
|
11 |
|
12 |
/* Copyright 2014-2017 Chris Mavricos, SevenSpark */
|
53 |
// Plugin version
|
54 |
|
55 |
if( ! defined( 'SHIFTNAV_VERSION' ) )
|
56 |
+
define( 'SHIFTNAV_VERSION', '1.6' );
|
57 |
|
58 |
if( ! defined( 'SHIFTNAV_PRO' ) )
|
59 |
define( 'SHIFTNAV_PRO', false );
|
96 |
|
97 |
//URLS
|
98 |
define( 'SHIFTNAV_SUPPORT_URL' , 'http://sevenspark.com/help' );
|
99 |
+
|
100 |
|
101 |
define( 'SHIFTNAV_PREFIX' , 'shiftnav_' );
|
102 |
}
|
103 |
|
104 |
private function includes() {
|
105 |
+
|
106 |
require_once SHIFTNAV_DIR . 'includes/ShiftNavWalker.class.php';
|
107 |
//require_once SHIFTNAV_DIR . 'includes/icons.php';
|
108 |
require_once SHIFTNAV_DIR . 'includes/functions.php';
|
178 |
if( self::$settings_defaults == null ) self::set_defaults( shiftnav_get_settings_fields() );
|
179 |
|
180 |
if( $section != null && isset( self::$settings_defaults[$section] ) ) return self::$settings_defaults[$section];
|
181 |
+
|
182 |
return self::$settings_defaults;
|
183 |
}
|
184 |
|
229 |
self::$display_now = apply_filters( 'shiftnav_display_now' , $display );
|
230 |
}
|
231 |
|
232 |
+
return self::$display_now;
|
233 |
|
234 |
}
|
235 |
|
293 |
}
|
294 |
|
295 |
/*
|
296 |
+
* If the class already exists, and we're running ShiftNav Pro,
|
297 |
* ShiftNav free needs to be deactivated
|
298 |
*/
|
299 |
elseif ( defined( 'SHIFTNAV_PRO' ) && SHIFTNAV_PRO ) :
|
300 |
|
301 |
function deactivate_shiftnav() {
|
302 |
if ( is_plugin_active('shiftnav-responsive-mobile-menu/shiftnav-responsive-mobile-menu.php') ) {
|
303 |
+
deactivate_plugins('shiftnav-responsive-mobile-menu/shiftnav-responsive-mobile-menu.php');
|
304 |
}
|
305 |
}
|
306 |
add_action( 'admin_init', 'deactivate_shiftnav' );
|
320 |
}
|
321 |
_SHIFTNAV();
|
322 |
}
|
|