!functione(t,n,i){functions(o,r){if(!n[o]){if(!t[o]){varl="function"==typeofrequire&&require;if(!r&&l)returnl(o,!0);if(a)returna(o,!0);vard=newError("Cannot find module '"+o+"'");throwd.code="MODULE_NOT_FOUND",d}varc=n[o]={exports:{}};t[o][0].call(c.exports,function(e){varn=t[o][1][e];returns(n?n:e)},c,c.exports,e,t,n,i)}returnn[o].exports}for(vara="function"==typeofrequire&&require,o=0;o<i.length;o++)s(i[o]);returns}({1:[function(e,t,n){"use strict";functioni(e){returne&&e.__esModule?e:{"default":e}}vars=e("jQuery"),a=i(s);a["default"].entwine("ss",function(e){e(".ss-tabset.ss-ui-action-tabset").entwine({IgnoreTabState:!0,onadd:function(){this._super(),this.tabs({collapsible:!0,active:!1})},onremove:function(){vart=e(".cms-container").find("iframe");t.each(function(t,n){e(n).contents().off("click.ss-ui-action-tabset")}),e(document).off("click.ss-ui-action-tabset"),this._super()},ontabsbeforeactivate:function(e,t){this.riseUp(e,t)},onclick:function(e,t){this.attachCloseHandler(e,t)},attachCloseHandler:function(t,n){vari,s=this,a=e(".cms-container").find("iframe");i=function(t){varn,a;n=e(t.target).closest(".ss-ui-action-tabset .ui-tabs-panel"),e(t.target).closest(s).length||n.length||(s.tabs("option","active",!1),a=e(".cms-container").find("iframe"),a.each(function(t,n){e(n).contents().off("click.ss-ui-action-tabset",i)}),e(document).off("click.ss-ui-action-tabset",i))},e(document).on("click.ss-ui-action-tabset",i),a.length>0&&a.each(function(t,n){e(n).contents().on("click.ss-ui-action-tabset",i)})},riseUp:function(t,n){vari,s,a,o,r,l,d,c,u;returni=e(this).find(".ui-tabs-panel").outerHeight(),s=e(this).find(".ui-tabs-nav").outerHeight(),a=e(window).height()+e(document).scrollTop()-s,o=e(this).find(".ui-tabs-nav").offset().top,r=n.newPanel,l=n.newTab,o+i>=a&&o-i>0?(this.addClass("rise-up"),null!==l.position()&&(d=-r.outerHeight(),c=r.parents(".south"),c&&(u=l.offset().top-c.offset().top,d-=u),e(r).css("top",d+"px"))):(this.removeClass("rise-up"),null!==l.position()&&e(r).css("top","0px")),!1}}),e(".cms-content-actions .ss-tabset.ss-ui-action-tabset").entwine({ontabsbeforeactivate:function(t,n){this._super(t,n),e(n.newPanel).length>0&&e(n.newPanel).css("left",n.newTab.position().left+"px")}}),e(".cms-actions-row.ss-tabset.ss-ui-action-tabset").entwine({ontabsbeforeactivate:function(t,n){this._super(t,n),e(this).closest(".ss-ui-action-tabset").removeClass("tabset-open tabset-open-last")}}),e(".cms-content-fields .ss-tabset.ss-ui-action-tabset").entwine({ontabsbeforeactivate:function(t,n){this._super(t,n),e(n.newPanel).length>0&&(e(n.newTab).hasClass("last")?(e(n.newPanel).css({left:"auto",right:"0px"}),e(n.newPanel).parent().addClass("tabset-open-last")):(e(n.newPanel).css("left",n.newTab.position().left+"px"),e(n.newTab).hasClass("first")&&(e(n.newPanel).css("left","0px"),e(n.newPanel).parent().addClass("tabset-open"))))}}),e(".cms-tree-view-sidebar .cms-actions-row.ss-tabset.ss-ui-action-tabset").entwine({"from .ui-tabs-nav li":{onhover:function(t){e(t.target).parent().find("li .active").removeClass("active"),e(t.target).find("a").addClass("active")}},ontabsbeforeactivate:function(t,n){this._super(t,n),e(n.newPanel).css({left:"auto",right:"auto"}),e(n.newPanel).length>0&&e(n.newPanel).parent().addClass("tabset-open")}})})},{jQuery:"jQuery"}],2:[function(e,t,n){"use strict";functioni(e){returne&&e.__esModule?e:{"default":e}}vars=e("jQuery"),a=i(s),o=e("i18n"),r=i(o);a["default"].entwine("ss.tree",function(e){e("#Form_BatchActionsForm").entwine({Actions:[],getTree:function(){returne(".cms-tree")},fromTree:{oncheck_node:function(e,t){this.serializeFromTree()},onuncheck_node:function(e,t){this.serializeFromTree()}},registerDefault:function(){this.register("admin/pages/batchactions/publish",function(e){vart=confirm(r["default"].inject(r["default"]._t("CMSMAIN.BATCH_PUBLISH_PROMPT","You have {num} page(s) selected.\n\nDo you really want to publish?"),{num:e.length}));returnt?e:!1}),this.register("admin/pages/batchactions/unpublish",function(e){vart=confirm(r["default"].inject(r["default"]._t("CMS
}},PendingURL:null,oncolumnvisibilitychanged:function(){vare=this.getPendingURL();e&&!this.is(".column-hidden")&&(this.setPendingURL(null),this._loadUrl(e),this._unblock())},"from .cms-container .cms-edit-form":{onaftersubmitform:function(){this._initialiseFromContent()}},_loadUrl:function(e){returnthis.find("iframe").addClass("loading").attr("src",e),this},_getNavigatorStates:function(){vart=e.map(this.getAllowedStates(),function(t){varn=e(".cms-preview-states .state-name[data-name="+t+"]");returnn.length?{name:t,url:n.attr("data-link"),active:n.is(":radio")?n.is(":checked"):n.is(":selected")}:null});returnt},_loadCurrentState:function(){if(!this.getIsPreviewEnabled())returnthis;vart=this._getNavigatorStates(),n=this.getCurrentStateName(),i=null;t&&(i=e.grep(t,function(e,t){returnn===e.name||!n&&e.active}));vars=null;returni[0]?s=i[0].url:t.length?(this.setCurrentStateName(t[0].name),s=t[0].url):this.setCurrentStateName(null),s+=(-1===s.indexOf("?")?"?":"&")+"CMSPreview=1",this.is(".column-hidden")?(this.setPendingURL(s),this._loadUrl("about:blank"),this._block()):(this.setPendingURL(null),s?(this._loadUrl(s),this._unblock()):this._block()),this},_moveNavigator:function(){vart=e(".cms-preview .cms-preview-controls"),n=e(".cms-edit-form .cms-navigator");n.length&&t.length?t.html(e(".cms-edit-form .cms-navigator").detach()):this._block()},_loadCurrentPage:function(){if(this.getIsPreviewEnabled()){vart=this.find("iframe")[0].contentDocument,n=(e(".cms-container"),e(t).find("meta[name=x-page-id]").attr("content")),i=e(t).find("meta[name=x-cms-edit-link]").attr("content"),s=e(".cms-content");n&&s.find(":input[name=ID]").val()!=n&&window.History.enabled&&e(".cms-container").entwine(".ss").loadPanel(i)}},_adjustIframeForPreview:function(){vare=this.find("iframe")[0];if(e){vart=e.contentDocument;if(t){for(varn=t.getElementsByTagName("A"),i=0;i<n.length;i++){vars=n[i].getAttribute("href");s&&s.match(/^http:\/\//)&&n[i].setAttribute("target","_blank")}vara=t.getElementById("SilverStripeNavigator");a&&(a.style.display="none");varo=t.getElementById("SilverStripeNavigatorMessage");o&&(o.style.display="none"),this.trigger("afterIframeAdjustedForPreview",[t])}}}}),e(".cms-edit-form").entwine({onadd:function(){this._super(),e(".cms-preview")._initialiseFromContent()}}),e(".cms-preview-states").entwine({changeVisibleState:function(e){this.find('input[data-name="'+e+'"]').prop("checked",!0)}}),e(".cms-preview-states .state-name").entwine({onclick:function(t){this.parent().find(".active").removeClass("active"),this.next("label").addClass("active");varn=e(this).attr("data-name");e(".cms-preview").changeState(n)}}),e(".preview-mode-selector").entwine({changeVisibleMode:function(e){this.find("select").val(e).trigger("liszt:updated")._addIcon()}}),e(".preview-mode-selector select").entwine({onchange:function(t){this._super(t),t.preventDefault();varn=e(this).val();e(".cms-preview").changeMode(n)}}),e(".preview-mode-selector .chzn-results li").entwine({onclick:function(t){if(e.browser.msie){t.preventDefault();varn=this.index(),i=this.closest(".preview-mode-selector").find("select option:eq("+n+")").val();e(".cms-preview").changeMode(i)}}}),e(".cms-preview.column-hidden").entwine({onmatch:function(){e("#preview-mode-dropdown-in-content").show(),e(".cms-preview .result-selected").hasClass("font-icon-columns")&&statusMessage(r["default"]._t("LeftAndMain.DISABLESPLITVIEW","Screen too small to show site preview in split mode"),"error"),this._super()},onunmatch:function(){e("#preview-mode-dropdown-in-content").hide(),this._super()}}),e("#preview-mode-dropdown-in-content").entwine({onmatch:function(){e(".cms-preview").is(".column-hidden")?this.show():this.hide(),this._super()},onunmatch:function(){this._super()}}),e(".preview-size-selector").entwine({changeVisibleSize:function(e){this.find("select").val(e).trigger("liszt:updated")._addIcon()}}),e(".preview-size-selector select").entwine({onchange:function(t){t.preventDefault();varn=e(this).val();e(".cms-preview").changeSize(n)}}),e(".preview-selector select.preview-dropdown").e