Changeset 1187379
- Timestamp:
- 06/25/2015 08:41:07 AM (11 years ago)
- Location:
- acf-fold-flexible-content
- Files:
-
- 3 edited
- 10 copied
-
tags/1.1.6 (copied) (copied from acf-fold-flexible-content/trunk)
-
tags/1.1.6/acf-fold-flexible.php (copied) (copied from acf-fold-flexible-content/trunk/acf-fold-flexible.php)
-
tags/1.1.6/css (copied) (copied from acf-fold-flexible-content/trunk/css)
-
tags/1.1.6/css/acf-fold-flexible.admin.css (copied) (copied from acf-fold-flexible-content/trunk/css/acf-fold-flexible.admin.css)
-
tags/1.1.6/js (copied) (copied from acf-fold-flexible-content/trunk/js)
-
tags/1.1.6/js/acf-fold-flexible.admin.js (copied) (copied from acf-fold-flexible-content/trunk/js/acf-fold-flexible.admin.js) (3 diffs)
-
tags/1.1.6/js/acf-fold-flexible.tooltip.js (copied) (copied from acf-fold-flexible-content/trunk/js/acf-fold-flexible.tooltip.js)
-
tags/1.1.6/readme.md (copied) (copied from acf-fold-flexible-content/trunk/readme.md) (1 diff)
-
tags/1.1.6/readme.txt (copied) (copied from acf-fold-flexible-content/trunk/readme.txt) (1 diff)
-
tags/1.1.6/screenshot-1.png (copied) (copied from acf-fold-flexible-content/trunk/screenshot-1.png)
-
trunk/js/acf-fold-flexible.admin.js (modified) (3 diffs)
-
trunk/readme.md (modified) (1 diff)
-
trunk/readme.txt (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
acf-fold-flexible-content/tags/1.1.6/js/acf-fold-flexible.admin.js
r1089798 r1187379 4 4 5 5 $(function() { 6 7 var acfpro = false; 8 9 // Detect ACF Pro 10 if($("#acf-pro-input-css").length) { 11 acfpro = true; 12 } 6 13 7 14 // Check if ACF Flexible Content fields exists at all … … 17 24 labels.each(function() { 18 25 19 // Check open/closed state20 if($(this).parent().attr("data-toggle")) {21 if($(this).parent().attr("data-toggle") !== 'open') {22 $(this).addClass('open');23 } else{24 $(this).removeClass('open');25 $(this).parent().attr('data-toggle', 'closed');26 }26 // Fold everything 27 $(this).removeClass('open'); 28 $(this).parent().attr('data-toggle', 'closed'); 29 30 if(acfpro) { 31 $(this).nextAll('.row-layout').first().hide(); 32 } else { 33 $(this).nextAll('.row_layout').first().hide(); 27 34 } 28 35 … … 91 98 92 99 // Open/Close panels 93 $('.acf-postbox').on('click', '.acf-fc-layout-handle', function() { 100 $(document).on('click', '.acf-fc-layout-handle', function() { 101 94 102 var toggle_list = $(this); 95 if(toggle_list.parent().attr("data-toggle") === 'open') { 96 toggle_list.removeClass('open'); 103 104 // Toggle open class 105 if(acfpro) { 106 if($(this).next().next('.row-layout').css("display") == "none") { 107 toggle_list.removeClass('open'); 108 } else { 109 toggle_list.addClass('open'); 110 } 97 111 } else { 98 toggle_list.addClass('open'); 112 if($(this).next('.row_layout').css("display") == "none") { 113 toggle_list.removeClass('open'); 114 } else { 115 toggle_list.addClass('open'); 116 } 117 99 118 } 119 100 120 }); 101 121 -
acf-fold-flexible-content/tags/1.1.6/readme.md
r1162813 r1187379 25 25 26 26 ## Changelog 27 + 1.1.6: Fold everything from start. No longer check open/closed state. Better support for ACF Pro. 28 + 1.1.5: No longer check open/closed state 29 + 1.1.4: Fixed an issue were the tooltips didn't work together with Gravity forms. 27 30 + 1.1.3: Fixed an issue were the tooltips didn't work like expected on regular ACF. ACF Pro was fine. Now both! 28 31 + 1.1.2: Fixed an issue were newly added field layouts did not get icon tooltips. Also fixed so newly added don't always stay blue, not until clicked. -
acf-fold-flexible-content/tags/1.1.6/readme.txt
r1162826 r1187379 34 34 == Changelog == 35 35 36 = 1.1.6 = 37 Fold everything from start. No longer check open/closed state. Better support for ACF Pro. 38 39 = 1.1.5 = 40 No longer check open/closed state 41 36 42 = 1.1.4 = 37 43 Fixed an issue were the tooltips didn't work together with Gravity forms. -
acf-fold-flexible-content/trunk/js/acf-fold-flexible.admin.js
r1089798 r1187379 4 4 5 5 $(function() { 6 7 var acfpro = false; 8 9 // Detect ACF Pro 10 if($("#acf-pro-input-css").length) { 11 acfpro = true; 12 } 6 13 7 14 // Check if ACF Flexible Content fields exists at all … … 17 24 labels.each(function() { 18 25 19 // Check open/closed state20 if($(this).parent().attr("data-toggle")) {21 if($(this).parent().attr("data-toggle") !== 'open') {22 $(this).addClass('open');23 } else{24 $(this).removeClass('open');25 $(this).parent().attr('data-toggle', 'closed');26 }26 // Fold everything 27 $(this).removeClass('open'); 28 $(this).parent().attr('data-toggle', 'closed'); 29 30 if(acfpro) { 31 $(this).nextAll('.row-layout').first().hide(); 32 } else { 33 $(this).nextAll('.row_layout').first().hide(); 27 34 } 28 35 … … 91 98 92 99 // Open/Close panels 93 $('.acf-postbox').on('click', '.acf-fc-layout-handle', function() { 100 $(document).on('click', '.acf-fc-layout-handle', function() { 101 94 102 var toggle_list = $(this); 95 if(toggle_list.parent().attr("data-toggle") === 'open') { 96 toggle_list.removeClass('open'); 103 104 // Toggle open class 105 if(acfpro) { 106 if($(this).next().next('.row-layout').css("display") == "none") { 107 toggle_list.removeClass('open'); 108 } else { 109 toggle_list.addClass('open'); 110 } 97 111 } else { 98 toggle_list.addClass('open'); 112 if($(this).next('.row_layout').css("display") == "none") { 113 toggle_list.removeClass('open'); 114 } else { 115 toggle_list.addClass('open'); 116 } 117 99 118 } 119 100 120 }); 101 121 -
acf-fold-flexible-content/trunk/readme.md
r1162813 r1187379 25 25 26 26 ## Changelog 27 + 1.1.6: Fold everything from start. No longer check open/closed state. Better support for ACF Pro. 28 + 1.1.5: No longer check open/closed state 29 + 1.1.4: Fixed an issue were the tooltips didn't work together with Gravity forms. 27 30 + 1.1.3: Fixed an issue were the tooltips didn't work like expected on regular ACF. ACF Pro was fine. Now both! 28 31 + 1.1.2: Fixed an issue were newly added field layouts did not get icon tooltips. Also fixed so newly added don't always stay blue, not until clicked. -
acf-fold-flexible-content/trunk/readme.txt
r1162826 r1187379 34 34 == Changelog == 35 35 36 = 1.1.6 = 37 Fold everything from start. No longer check open/closed state. Better support for ACF Pro. 38 39 = 1.1.5 = 40 No longer check open/closed state 41 36 42 = 1.1.4 = 37 43 Fixed an issue were the tooltips didn't work together with Gravity forms.
Note: See TracChangeset
for help on using the changeset viewer.