!function(t){"use strict";var e,a,o,n,i=(e=function(e){if(t(".countdown").length){var a=jQuery(".countdown").data("date");void 0!=a&&""!=a&&(e=a),t(".countdown").countdown({date:e+" 23:5"},function(){t(".countdown .date .text-primary").text("00")})}},a=function(){jQuery(".w3-comment-reply").on("click",function(e){e.preventDefault();var a=t(this).data("commentid");t(this).data("postid");var o=t(this).data("replyto"),n=t(this).parents(".comment .comment-body:first");t("#comment_parent").val(a),t("#commentform").trigger("reset"),t("#cancel-comment-reply").removeClass("d-none"),t("#reply-title").html(o),t("#ReplyFormContainer").insertAfter(n)}),jQuery("#cancel-comment-reply").on("click",function(e){e.preventDefault(),t("#comment_parent").val(0),t("#reply-title").empty(),t("#cancel-comment-reply").addClass("d-none"),t("#ReplyFormContainer").appendTo("#comments-div")})},o=function(){jQuery(".el-ajax-load-more").on("click",function(){var e=baseUrl+"/admin/magic_editors/ajax_load_more",a=jQuery(this).data("order"),o=jQuery(this).data("orderby"),n=jQuery(this).data("no-of-posts"),i=jQuery(this).data("post_with_images"),d=jQuery(this).data("post_category_ids"),r=jQuery(this).data("ajax-container"),s=jQuery(this).data("ajax-view"),c=jQuery(this).data("current-page"),m=jQuery(this),l=jQuery('.el-ajax-load-more[data-ajax-container="'+r+'"]').index(this),p={};void 0!=a&&(p.order=a),void 0!=o&&(p.orderby=o),void 0!=s&&(p.ajax_view=s),void 0!=n&&(p.no_of_posts=n),void 0!=i&&(p.post_with_images=i),void 0!=d&&(p.post_category_ids=d),void 0!=c&&(p.page=c),jQuery.ajax({headers:{"X-CSRF-TOKEN":t('meta[name="csrf-token"]').attr("content")},type:"Post",url:e,data:p,success:function(e){e.html?(jQuery("."+r).eq(l).append(e.html),e.has_more_pages?(c++,m.data("current-page",c)):(t(m).text("No More Posts"),t(m).prop("disabled",!0).addClass("disabled"))):alert("Failed to load more posts.")}})})},n=function(){t(".footer-top").find("h6.widget-title").removeClass("widget-title").addClass("m-b30 footer-title")},{init:function(){e(),a(),o(),n()}});jQuery(document).ready(function(){i.init()})}(jQuery);