text: !function(s){"use strict";redux.field_objects=redux.field_objects||{},redux.field_objects.slides=redux.field_objects.slides||{},s(document).ready(function(){}),redux.field_objects.slides.init=function(e){e||(e=s(document).find(".redux-group-tab:visible").find(".redux-container-slides:visible")),s(e).each(function(){var e=s(this);redux.field_objects.media.init(e);var i=e;e.hasClass("redux-field-container")||(i=e.parents(".redux-field-container:first")),i.is(":hidden")||(i.hasClass("redux-container-slides")&&i.addClass("redux-field-init"),i.hasClass("redux-field-init")&&(i.removeClass("redux-field-init"),e.find(".redux-slides-remove").on("click",function(){if(redux_change(s(this)),s(this).parent().siblings().find('input[type="text"]').val(""),s(this).parent().siblings().find("textarea").val(""),s(this).parent().siblings().find('input[type="hidden"]').val(""),1<s(this).parents(".redux-container-slides:first").find(".redux-slides-accordion-group").length)s(this).parents(".redux-slides-accordion-group:first").slideUp("medium",function(){s(this).remove()});else{var e=s(this).parent(".redux-slides-accordion").data("new-content-title");s(this).parents(".redux-slides-accordion-group:first").find(".remove-image").click(),s(this).parents(".redux-container-slides:first").find(".redux-slides-accordion-group:last").find(".redux-slides-header").text(e)}}),e.find(".redux-slides-add").off("click").click(function(){var e=s(this).prev().find(".redux-slides-accordion-group:last").clone(!0),i=1*s(e).find(".slide-title").attr("name").match(/[0-9]+(?!.*[0-9])/)+1;s(e).find('input[type="text"], input[type="hidden"], textarea').each(function(){s(this).attr("name",jQuery(this).attr("name").replace(/[0-9]+(?!.*[0-9])/,i)).attr("id",s(this).attr("id").replace(/[0-9]+(?!.*[0-9])/,i)),s(this).val(""),s(this).hasClass("slide-sort")&&s(this).val(i)});var t=s(this).prev().data("new-content-title");s(e).find(".screenshot").removeAttr("style"),s(e).find(".screenshot").addClass("hide"),s(e).find(".screenshot a").attr("href",""),s(e).find(".remove-image").addClass("hide"),s(e).find(".redux-slides-image").attr("src","").removeAttr("id"),s(e).find("h3").text("").append('<span class="redux-slides-header">'+t+'</span><span class="ui-accordion-header-icon ui-icon ui-icon-plus"></span>'),s(this).prev().append(e)}),e.find(".slide-title").keyup(function(e){var i=e.target.value;s(this).parents().eq(3).find(".redux-slides-header").text(i)}),e.find(".redux-slides-accordion").accordion({header:"> div > fieldset > h3",collapsible:!0,active:!1,heightStyle:"content",icons:{header:"ui-icon-plus",activeHeader:"ui-icon-minus"}}).sortable({axis:"y",handle:"h3",connectWith:".redux-slides-accordion",start:function(e,i){i.placeholder.height(i.item.height()),i.placeholder.width(i.item.width())},placeholder:"ui-state-highlight",stop:function(e,i){i.item.children("h3").triggerHandler("focusout"),s("input.slide-sort").each(function(e){s(this).val(e)})}})))})}}(jQuery);
  