1!function(e){var n=window.megashop,o=n.blog=n.blog||{},t=n.Update,c=n.ComponentRegistry,i=n.ModalUtil,a=n.SlideDownUtil,l=n.PageSeparatorBuilder,r=n.LazyLoad,s=(o.BlogStream=c.register(function(e){return e.select(".c-blog-stream")},function(o){var c={lazy_load:r(o),initEventListeners:function(){o.on("click",".c-blog-stream__more-button",function(){o.addClass("c-blog-stream_lazy-load"),c.lazy_load.watch()}),o.on("loading@megashop:c-lazy-load",function(){o.addClass("c-blog-stream_loading")}),o.on("loaded@megashop:c-lazy-load",function(i,a){var r=n.config.language.page_number.replace(/(.+)%page%(.+)%pages_count%/,"$1"+c.lazy_load.getPage()+"$2"+c.lazy_load.getCountPages());o.removeClass("c-blog-stream_loading"),o.find(".c-blog-stream__posts-container").append(l.create(r)).append(e(a).find(".c-blog-posts, .l-posts-thumbs")),o.find(".c-blog-stream__pagination-container").replaceWith(e(a).find(".c-blog-stream__pagination-container")),t(o)}),o.on("error@megashop:c-lazy-load",function(){o.removeClass("c-blog-stream_loading")}),o.on("done@megashop:c-lazy-load",function(){o.addClass("c-blog-stream_lazy-load-done")})}};c.initEventListeners()}),o.BlogCommentsContainer=c.register(function(e){return e.select(".c-blog-comments-container")},function(n,t){var c={initEventListeners:function(){n.find(".c-blog-comments-container__add-comment-button-container").on("click",function(){i.openContent(e(o.comment_form))}),n.find(".c-blog-comments-container__more-button").on("click",function(){n.addClass("c-blog-comments-container_show-all")})},initGlobalEventListeners:function(){e(document).on("added@megashop:c-blog-comment-form",".c-blog-comment-form",c.handleAddComment),e(document).on("added@megashop:c-blog-comment-reply-form",".c-blog-comment-reply-form",c.handleAddCommentReply)},destroyGlobalEventListeners:function(){e(document).off("added@megashop:c-blog-comment-form",".c-blog-comment-form",c.handleAddComment),e(document).off("added@megashop:c-blog-comment-reply-form",".c-blog-comment-reply-form",c.handleAddCommentReply)},handleAddComment:function(o,c){var i=n.find(".c-blog-comments"),a=e('<div class="c-blog-comments__item"></div>');a.html(c.template),i.prepend(a),n.find(".c-blog-comments-container__header-text").html(c.count_str),t.updateState()},handleAddCommentReply:function(e,o){n.find(".c-blog-comments-container__header-text").html(o.count_str)}};return e.extend(t,{updateState:function(){n.toggleClass("c-blog-comments-container_has-comments",n.find(".c-blog-comments__item").length>0)}}),c.initEventListeners(),c.initGlobalEventListeners(),function(){c.destroyGlobalEventListeners()}}),o.BlogComments=c.register(function(e){return e.select(".c-blog-comments")},function(e){(function(){e.find(".c-blog-comments__more-button").on("click",function(){e.addClass("c-blog-comments_show-all")})})()}),o.BlogCommentForm=c.register(function(e){return e.select(".c-blog-comment-form")},function(e){(function(){e.on("success@megashop:c-ajax-form",function(n,o){"ok"===o.status&&(e.trigger("added@megashop:c-blog-comment-form",o.data),i.close())}),e.on("error@megashop:c-ajax-form",function(){window.location.reload()})})()}),o.BlogComment=c.register(function(e){return e.select(".c-blog-comment")},function(n,c){var i={id:n.data("comment_id"),is_open_reply_form:!1,initEventListeners:function(){n.children(".c-blog-comment__info-container").find(".c-blog-comment__reply-button").on("click",function(){if(!i.is_open_reply_form){var a=e(o.comment_reply_form);s(a).setParentId(i.id);var l=n.children(".c-blog-comment__comments-container"),r=e('<div class="c-blog-comment__comment-container"></div>');r.html(a).prependTo(l),t(r),i.is_open_reply_form=!0,c.updateState(),a.on("close@megashop:c-blog-comment-reply-form",function(){r.remove(),i.is_open_reply_form=!1,c.updateState()}),a.on("added@megashop:c-blog-comment-reply-form",function(e,n){r.html(n.template),r.appendTo(l),i.is_open_reply_form=!1,c.updateState()})}})}};e.extend(c,{updateState:function(){n.toggleClass("c-blog-comment_has-reply",n.find(".c-blog-comment__comment-container").length>0)}}),i.initEventListeners()}),o.BlogCommentReplyForm=c.register(function(e){return e.select(".c-blog-comment-reply-form")},function(n,o){var t=function(){n.on("success@megashop:c-ajax-form",function(e,o){"ok"===o.status&&n.trigger("added@megashop:c-blog-comment-reply-form",o.data)}),n.on("error@megashop:c-ajax-form",function(){window.location.reload()}),n.find(".c-blog-comment-reply-form__close-button").on("click",function(){n.trigger("close@megashop:c-blog-comment-reply-form")})};e.extend(o,{setParentId:function(e){n.find(".c-blog-comment-reply-form__parent-input").val(e)}}),t()}));o.BlogSidebarTimelineYear=c.register(function(e){return e.select(".c-blog-sidebar-timeline-year")},function(n,o){var t={initEventListeners:function(){n.find(".c-blog-sidebar-timeline-year__header-container").on("click",function(){o.toggle()})},initGlobalEventListeners:function(){e(document).on("open@megashop:c-blog-sidebar-timeline-year",".c-blog-sidebar-timeline-year",t.handleOpen)},destroyGlobalEventListeners:function(){e(document).off("open@megashop:c-blog-sidebar-timeline-year",".c-blog-sidebar-timeline-year",t.handleOpen)},handleOpen:function(){e(this).is(n)||o.close()}};return e.extend(o,{toggle:function(){n.hasClass("c-blog-sidebar-timeline-year_open")?o.close():o.open()},open:function(){var e=n.find(".c-blog-sidebar-timeline-year__content-container");n.trigger("open@megashop:c-blog-sidebar-timeline-year"),a.show(e).then(function(){n.removeClass("c-blog-sidebar-timeline-year_process-open")}),n.removeClass("c-blog-sidebar-timeline-year_process-close"),n.offset(),n.addClass("c-blog-sidebar-timeline-year_process-open"),n.addClass("c-blog-sidebar-timeline-year_open")},close:function(){var e=n.find(".c-blog-sidebar-timeline-year__content-container");n.trigger("close@megashop:c-blog-sidebar-timeline-year"),a.hide(e).then(function(){n.removeClass("c-blog-sidebar-timeline-year_process-close")}),n.removeClass("c-blog-sidebar-timeline-year_process-open"),n.offset(),n.addClass("c-blog-sidebar-timeline-year_process-close"),n.removeClass("c-blog-sidebar-timeline-year_open")}}),t.initEventListeners(),t.initGlobalEventListeners(),function(){t.destroyGlobalEventListeners()}});o.BlogCategorySelect=c.register(function(e){return e.find(".r-blog-category-select")},function(e){(function(){e.on("change",function(){window.location=e.val()})})()}),o.BlogYearSelect=c.register(function(e){return e.find(".r-blog-year-select")},function(e){(function(){e.on("change",function(){window.location=e.val()})})()}),o.BlogMonthSelect=c.register(function(e){return e.find(".r-blog-month-select")},function(e){(function(){e.on("change",function(){window.location=e.val()})})()})}(jQuery);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.