@@ -13,8 +13,8 @@ jQuery(document).ready(function($) {
13
13
} )
14
14
$ ( '.accordion' ) . each ( function ( ) {
15
15
if ( $ ( this ) . find ( 'button.expand-all' ) . length > 0 ) {
16
- let items = $ ( this ) . find ( ".accordion-group" ) ;
17
- let open = $ ( this ) . find ( ".accordion-body.open" ) ;
16
+ var items = $ ( this ) . find ( ".accordion-group" ) ;
17
+ var open = $ ( this ) . find ( ".accordion-body.open" ) ;
18
18
if ( items . length == open . length ) {
19
19
$ ( this ) . find ( 'button.expand-all' ) . attr ( "data-status" , 'open' ) . data ( 'status' , 'open' ) . html ( __ ( 'Collapse All' , 'rrze-elements' ) ) ;
20
20
//$(this).find('button.expand-all').attr("data-status", 'open').data('status', 'open').html(accordionToggle.collapse_all);
@@ -25,8 +25,8 @@ jQuery(document).ready(function($) {
25
25
26
26
$ ( '.accordion-toggle' ) . bind ( 'mousedown' , function ( event ) {
27
27
event . preventDefault ( ) ;
28
- let $accordion = $ ( this ) . attr ( 'href' ) ;
29
- let $name = $ ( this ) . data ( 'name' ) ;
28
+ var $accordion = $ ( this ) . attr ( 'href' ) ;
29
+ var $name = $ ( this ) . data ( 'name' ) ;
30
30
toggleAccordion ( $accordion ) ;
31
31
// Put name attribute in URL path if available, else href
32
32
if ( typeof ( $name ) !== 'undefined' ) {
@@ -39,8 +39,8 @@ jQuery(document).ready(function($) {
39
39
// Keyboard navigation for accordions
40
40
$ ( '.accordion-toggle' ) . keydown ( function ( event ) {
41
41
if ( event . keyCode == 32 ) {
42
- let $accordion = $ ( this ) . attr ( 'href' ) ;
43
- let $name = $ ( this ) . data ( 'name' ) ;
42
+ var $accordion = $ ( this ) . attr ( 'href' ) ;
43
+ var $name = $ ( this ) . data ( 'name' ) ;
44
44
toggleAccordion ( $accordion ) ;
45
45
if ( typeof ( $name ) !== 'undefined' ) {
46
46
window . history . replaceState ( null , null , '#' + $name ) ;
@@ -51,23 +51,23 @@ jQuery(document).ready(function($) {
51
51
} ) ;
52
52
53
53
function toggleAccordion ( $accordion ) {
54
- let $thisgroup = $ ( $accordion ) . closest ( '.accordion-group' ) ;
55
- let $othergroups = $ ( $accordion ) . closest ( '.accordion' ) . find ( '.accordion-group' ) . not ( $thisgroup ) ;
54
+ var $thisgroup = $ ( $accordion ) . closest ( '.accordion-group' ) ;
55
+ var $othergroups = $ ( $accordion ) . closest ( '.accordion' ) . find ( '.accordion-group' ) . not ( $thisgroup ) ;
56
56
$ ( $othergroups ) . children ( '.accordion-heading' ) . children ( ' .accordion-toggle' ) . removeClass ( 'active' ) ;
57
57
$ ( $othergroups ) . children ( '.accordion-body' ) . not ( '.accordion-body.stayopen' ) . slideUp ( ) ;
58
58
$ ( $thisgroup ) . children ( '.accordion-heading' ) . children ( '.accordion-toggle' ) . toggleClass ( 'active' ) ;
59
59
$ ( $thisgroup ) . children ( '.accordion-body' ) . slideToggle ( ) ;
60
60
// refresh Slick Gallery
61
- let $slick = $ ( $thisgroup ) . find ( "div.slick-slider" ) ;
61
+ var $slick = $ ( $thisgroup ) . find ( "div.slick-slider" ) ;
62
62
if ( $slick . length < 0 ) {
63
63
$slick . slick ( "refresh" ) ;
64
64
}
65
65
}
66
66
67
67
function openAnchorAccordion ( $target ) {
68
68
if ( $target . closest ( '.accordion' ) . parent ( ) . closest ( '.accordion-group' ) ) {
69
- let $thisgroup = $ ( $target ) . closest ( '.accordion-group' ) ;
70
- let $othergroups = $ ( $target ) . closest ( '.accordion' ) . find ( '.accordion-group' ) . not ( $thisgroup ) ;
69
+ var $thisgroup = $ ( $target ) . closest ( '.accordion-group' ) ;
70
+ var $othergroups = $ ( $target ) . closest ( '.accordion' ) . find ( '.accordion-group' ) . not ( $thisgroup ) ;
71
71
$ ( $othergroups ) . find ( '.accordion-toggle' ) . removeClass ( 'active' ) ;
72
72
$ ( $othergroups ) . find ( '.accordion-body' ) . not ( '.accordion-body.stayopen' ) . slideUp ( ) ;
73
73
$ ( $thisgroup ) . find ( '.accordion-toggle:first' ) . not ( '.active' ) . addClass ( 'active' ) ;
@@ -76,24 +76,24 @@ jQuery(document).ready(function($) {
76
76
$ ( $thisgroup ) . parents ( '.accordion-group' ) . find ( '.accordion-toggle:first' ) . not ( '.active' ) . addClass ( 'active' ) ;
77
77
$ ( $thisgroup ) . parents ( '.accordion-body' ) . slideDown ( ) ;
78
78
}
79
- let offset = $target . offset ( ) ;
80
- let $scrolloffset = offset . top - 300 ;
79
+ var offset = $target . offset ( ) ;
80
+ var $scrolloffset = offset . top - 300 ;
81
81
$ ( 'html,body' ) . animate ( {
82
82
scrollTop : $scrolloffset
83
83
} , 'slow' ) ;
84
84
}
85
85
86
86
if ( window . location . hash ) {
87
- let identifier = window . location . hash . split ( '_' ) [ 0 ] ;
88
- let inpagenum = window . location . hash . split ( '_' ) [ 1 ] ;
87
+ var identifier = window . location . hash . split ( '_' ) [ 0 ] ;
88
+ var inpagenum = window . location . hash . split ( '_' ) [ 1 ] ;
89
89
if ( identifier == '#collapse' ) {
90
90
if ( $ . isNumeric ( inpagenum ) ) {
91
- let $findid = 'collapse_' + inpagenum ;
92
- let $target = $ ( 'body' ) . find ( '#' + $findid ) ;
91
+ var $findid = 'collapse_' + inpagenum ;
92
+ var $target = $ ( 'body' ) . find ( '#' + $findid ) ;
93
93
}
94
94
} else {
95
- let $findname = window . location . hash . replace ( '\#' , '' ) ;
96
- let $target = $ ( 'body' ) . find ( 'div[name=' + $findname + ']' ) ;
95
+ var $findname = window . location . hash . replace ( '\#' , '' ) ;
96
+ var $target = $ ( 'body' ) . find ( 'div[name=' + $findname + ']' ) ;
97
97
}
98
98
if ( $target . length > 0 ) {
99
99
openAnchorAccordion ( $target ) ;
@@ -106,17 +106,17 @@ jQuery(document).ready(function($) {
106
106
if ( ( $ ( '[id^=accordion-]' ) . length ) &&
107
107
( ! $ ( this ) . hasClass ( "accordion-toggle" ) ) &&
108
108
( ! $ ( this ) . hasClass ( "accordion-tabs-nav-toggle" ) ) ) {
109
- let $hash = $ ( this ) . prop ( "hash" ) ;
110
- let identifier = $hash . split ( '_' ) [ 0 ] ;
111
- let inpagenum = $hash . split ( '_' ) [ 1 ] ;
109
+ var $hash = $ ( this ) . prop ( "hash" ) ;
110
+ var identifier = $hash . split ( '_' ) [ 0 ] ;
111
+ var inpagenum = $hash . split ( '_' ) [ 1 ] ;
112
112
if ( identifier == '#collapse' ) {
113
113
if ( $ . isNumeric ( inpagenum ) ) {
114
- let $findid = 'collapse_' + inpagenum ;
115
- let $target = $ ( 'body' ) . find ( '#' + $findid ) ;
114
+ var $findid = 'collapse_' + inpagenum ;
115
+ var $target = $ ( 'body' ) . find ( '#' + $findid ) ;
116
116
}
117
117
} else {
118
- let $findname = identifier . replace ( '\#' , '' ) ;
119
- let $target = $ ( 'body' ) . find ( 'div[name=' + $findname + ']' ) ;
118
+ var $findname = identifier . replace ( '\#' , '' ) ;
119
+ var $target = $ ( 'body' ) . find ( 'div[name=' + $findname + ']' ) ;
120
120
}
121
121
if ( $target ) {
122
122
openAnchorAccordion ( $target ) ;
@@ -125,7 +125,7 @@ jQuery(document).ready(function($) {
125
125
} ) ;
126
126
127
127
$ ( '.expand-all' ) . click ( function ( e ) {
128
- let $thisgroup = $ ( this ) . closest ( '.accordion' ) ;
128
+ var $thisgroup = $ ( this ) . closest ( '.accordion' ) ;
129
129
if ( $ ( this ) . data ( 'status' ) === 'open' ) {
130
130
$ ( $thisgroup ) . find ( '.accordion-body' ) . slideUp ( ) ;
131
131
$ ( $thisgroup ) . find ( '.accordion-toggle' ) . removeClass ( 'active' ) ;
@@ -140,7 +140,7 @@ jQuery(document).ready(function($) {
140
140
// Assistant tabs
141
141
$ ( '.assistant-tabs-nav a' ) . bind ( 'click' , function ( event ) {
142
142
event . preventDefault ( ) ;
143
- let pane = $ ( this ) . attr ( 'href' ) ;
143
+ var pane = $ ( this ) . attr ( 'href' ) ;
144
144
$ ( this ) . parents ( 'ul' ) . find ( 'a' ) . removeClass ( 'active' ) ;
145
145
$ ( this ) . addClass ( 'active' ) ;
146
146
$ ( this ) . parents ( '.assistant-tabs' ) . find ( '.assistant-tab-pane' ) . removeClass ( 'assistant-tab-pane-active' ) ;
@@ -150,7 +150,7 @@ jQuery(document).ready(function($) {
150
150
// Keyboard navigation for assistant tabs
151
151
$ ( '.assistant-tabs-nav a' ) . keydown ( 'click' , function ( event ) {
152
152
if ( event . keyCode == 32 ) {
153
- let pane = $ ( this ) . attr ( 'href' ) ;
153
+ var pane = $ ( this ) . attr ( 'href' ) ;
154
154
$ ( this ) . parents ( 'ul' ) . find ( 'a' ) . removeClass ( 'active' ) ;
155
155
$ ( this ) . addClass ( 'active' ) ;
156
156
$ ( this ) . parents ( '.assistant-tabs' ) . find ( '.assistant-tab-pane' ) . removeClass ( 'assistant-tab-pane-active' ) ;
0 commit comments