PluginProbe ʕ •ᴥ•ʔ
Responsive Lightbox & Gallery / 2.5.2
Responsive Lightbox & Gallery v2.5.2
2.7.8 trunk 1.0.0 1.0.1 1.0.1.1 1.0.2 1.0.3 1.0.4 1.1.0 1.1.1 1.1.2 1.2.0 1.2.1 1.2.2 1.2.3 1.3.0 1.3.1 1.3.2 1.3.3 1.3.4 1.3.5 1.3.6 1.4.0 1.4.0.1 1.4.1 1.4.11 1.4.12 1.4.13 1.4.14 1.4.2 1.4.3 1.4.4 1.4.5 1.4.6 1.4.7 1.4.8 1.4.9 1.5.0 1.5.1 1.5.2 1.5.3 1.5.4 1.5.5 1.5.6 1.5.7 1.6.0 1.6.1 1.6.10 1.6.11 1.6.12 1.6.2 1.6.3 1.6.4 1.6.5 1.6.6 1.6.7 1.6.8 1.6.9 1.7.0 1.7.1 1.7.2 2.0 2.0.1 2.0.2 2.0.3 2.0.4 2.0.5 2.1 2.2.0 2.2.1 2.2.2 2.2.3 2.2.3.1 2.3.0 2.3.1 2.3.2 2.3.3 2.3.4 2.3.5 2.4.0 2.4.1 2.4.2 2.4.3 2.4.4 2.4.5 2.4.6 2.4.7 2.4.8 2.4.9 2.5.0 2.5.1 2.5.2 2.5.3 2.5.4 2.5.5 2.6.0 2.6.1 2.7.0 2.7.1 2.7.2 2.7.3 2.7.4 2.7.5 2.7.6 2.7.7
responsive-lightbox / js / admin-plugins.js
responsive-lightbox / js Last commit date
admin-folders.js 1 year ago admin-galleries.js 3 years ago admin-gallery.js 4 years ago admin-media.js 1 year ago admin-plugins.js 3 years ago admin-widgets.js 3 years ago admin.js 3 years ago front-basicmasonry.js 3 years ago front-basicslider.js 1 year ago front.js 1 year ago gutenberg.min.js 4 years ago
admin-plugins.js
71 lines
1 ( function( $ ) {
2
3 // ready event
4 $( function() {
5 // cancel deactivation
6 $( document ).on( 'click', '.rl-deactivate-plugin-cancel', function( e ) {
7 tb_remove();
8
9 return false;
10 } );
11
12 // simple deactivation
13 $( document ).on( 'click', '.rl-deactivate-plugin-simple', function( e ) {
14 // display spinner
15 $( '#rl-deactivation-footer .spinner' ).addClass( 'is-active' );
16 } );
17
18 // deactivation with sending data
19 $( document ).on( 'click', '.rl-deactivate-plugin-data', function( e ) {
20 var spinner = $( '#rl-deactivation-footer .spinner' );
21 var url = $( this ).attr( 'href' );
22
23 // display spinner
24 spinner.addClass( 'is-active' );
25
26 // submit data
27 $.post( ajaxurl, {
28 action: 'rl-deactivate-plugin',
29 option_id: $( 'input[name="rl_deactivation_option"]:checked' ).val(),
30 other: $( 'textarea[name="rl_deactivation_other"]' ).val(),
31 nonce: rlArgsPlugins.nonce
32 } ).done( function( response ) {
33 // deactivate plugin
34 window.location.href = url;
35 } ).fail( function() {
36 // deactivate plugin
37 window.location.href = url;
38 } );
39
40 return false;
41 } );
42
43 // click on deactivation link
44 $( document ).on( 'click', '.rl-deactivate-plugin-modal', function( e ) {
45 tb_show( rlArgsPlugins.deactivate, '#TB_inline?inlineId=rl-deactivation-modal&modal=false' );
46
47 setTimeout( function() {
48 var modalBox = $( '#rl-deactivation-container' ).closest( '#TB_window' );
49
50 if ( modalBox.length > 0 ) {
51 $( modalBox ).addClass( 'rl-deactivation-modal' );
52 $( modalBox ).find( '#TB_closeWindowButton' ).on( 'blur' );
53 }
54 }, 0 );
55
56 return false;
57 } );
58
59 // change radio
60 $( document ).on( 'change', 'input[name="rl_deactivation_option"]', function( e ) {
61 var last = $( 'input[name="rl_deactivation_option"]' ).last().get( 0 );
62
63 // last element?
64 if ( $( this ).get( 0 ) === last )
65 $( '.rl-deactivation-textarea textarea' ).prop( 'disabled', false );
66 else
67 $( '.rl-deactivation-textarea textarea' ).prop( 'disabled', true );
68 } );
69 } );
70
71 } )( jQuery );