HEX
Server: Microsoft-IIS/10.0
System: Windows NT ITPWINWEBSVR22 10.0 build 20348 (Windows Server 2022) AMD64
User: www.conferencesearch.co.uk (0)
PHP: 8.3.30
Disabled: NONE
Upload Files
File: D:/web/matomo.circ/plugins/Dashboard/vue/dist/Dashboard.umd.min.js
(function(e,t){"object"===typeof exports&&"object"===typeof module?module.exports=t(require("CoreHome"),require("vue")):"function"===typeof define&&define.amd?define(["CoreHome"],t):"object"===typeof exports?exports["Dashboard"]=t(require("CoreHome"),require("vue")):e["Dashboard"]=t(e["CoreHome"],e["Vue"])})("undefined"!==typeof self?self:this,(function(e,t){return function(e){var t={};function o(r){if(t[r])return t[r].exports;var a=t[r]={i:r,l:!1,exports:{}};return e[r].call(a.exports,a,a.exports,o),a.l=!0,a.exports}return o.m=e,o.c=t,o.d=function(e,t,r){o.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},o.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},o.t=function(e,t){if(1&t&&(e=o(e)),8&t)return e;if(4&t&&"object"===typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(o.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var a in e)o.d(r,a,function(t){return e[t]}.bind(null,a));return r},o.n=function(e){var t=e&&e.__esModule?function(){return e["default"]}:function(){return e};return o.d(t,"a",t),t},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.p="plugins/Dashboard/vue/dist/",o(o.s="fae3")}({"19dc":function(t,o){t.exports=e},"8bbf":function(e,o){e.exports=t},fae3:function(e,t,o){"use strict";if(o.r(t),o.d(t,"DashboardStore",(function(){return b})),o.d(t,"Dashboard",(function(){return k})),o.d(t,"DashboardSettings",(function(){return $})),"undefined"!==typeof window){var r=window.document.currentScript,a=r&&r.src.match(/(.+\/)[^/]+\.js(\?.*)?$/);a&&(o.p=a[1])}var n=o("8bbf"),i=o("19dc");function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function d(e,t){for(var o=0;o<t.length;o++){var r=t[o];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function c(e,t,o){return t&&d(e.prototype,t),o&&d(e,o),e}function l(e,t,o){return t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}
/*!
 * Matomo - free/libre analytics platform
 *
 * @link    https://matomo.org
 * @license https://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
 */var u=function(){function e(){var t=this;s(this,e),l(this,"privateState",Object(n["reactive"])({dashboards:[]})),l(this,"state",Object(n["computed"])((function(){return Object(n["readonly"])(t.privateState)}))),l(this,"dashboards",Object(n["computed"])((function(){return t.state.value.dashboards}))),l(this,"dashboardsPromise",null)}return c(e,[{key:"getDashboard",value:function(e){return this.getAllDashboards().then((function(t){return t.find((function(t){return parseInt("".concat(t.id),10)===parseInt("".concat(e),10)}))}))}},{key:"getDashboardLayout",value:function(e){return i["AjaxHelper"].fetch({module:"Dashboard",action:"getDashboardLayout",idDashboard:e},{withTokenInUrl:!0})}},{key:"reloadAllDashboards",value:function(){return this.dashboardsPromise=null,this.getAllDashboards()}},{key:"getAllDashboards",value:function(){var e=this;return this.dashboardsPromise||(this.dashboardsPromise=i["AjaxHelper"].fetch({method:"Dashboard.getDashboards",filter_limit:"-1"}).then((function(t){return t&&(e.privateState.dashboards=t),e.dashboards.value}))),this.dashboardsPromise}}]),e}(),b=new u;function h(e,t){return D(e)||v(e,t)||m(e,t)||f()}function f(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function m(e,t){if(e){if("string"===typeof e)return p(e,t);var o=Object.prototype.toString.call(e).slice(8,-1);return"Object"===o&&e.constructor&&(o=e.constructor.name),"Map"===o||"Set"===o?Array.from(e):"Arguments"===o||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o)?p(e,t):void 0}}function p(e,t){(null==t||t>e.length)&&(t=e.length);for(var o=0,r=new Array(t);o<t;o++)r[o]=e[o];return r}function v(e,t){var o=null==e?null:"undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=o){var r,a,n=[],i=!0,s=!1;try{for(o=o.call(e);!(i=(r=o.next()).done);i=!0)if(n.push(r.value),t&&n.length===t)break}catch(d){s=!0,a=d}finally{try{i||null==o["return"]||o["return"]()}finally{if(s)throw a}}return n}}function D(e){if(Array.isArray(e))return e}
/*!
 * Matomo - free/libre analytics platform
 *
 * @link    https://matomo.org
 * @license https://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
 */var g=window,y=g.$;function w(e,t,o){var r=y(".dashboardSettings");r.show(),window.initTopControls(),y("#topBars").length||(r.after(y("#Dashboard")),y("#Dashboard ul li").removeClass("active"),y("#Dashboard_embeddedIndex_".concat(e)).addClass("active")),window.widgetsHelper.getAvailableWidgets(),y("#dashboardWidgetsArea").off("dashboardempty",window.showEmptyDashboardNotification).on("dashboardempty",window.showEmptyDashboardNotification).dashboard({idDashboard:e,layout:o,name:t?t.name:""});var a=y("#columnPreview").find(">div");a.each((function(){var e=[];y("div",this).each((function(){e.push(this.className.replace(/width-/,""))})),y(this).attr("layout",e.join("-"))})),a.off("click.renderDashboard"),a.on("click.renderDashboard",(function(){a.removeClass("choosen"),y(this).addClass("choosen")}))}function O(e){return new Promise((function(e){return setTimeout(e)})).then((function(){return Promise.resolve(window.widgetsHelper.firstGetAvailableWidgetsCall)})).then((function(){var t=y("#dashboardWidgetsArea");return t.dashboard("destroyWidgets"),t.empty(),Promise.all([b.getDashboard(e),b.getDashboardLayout(e)])})).then((function(t){var o=h(t,2),r=o[0],a=o[1];return new Promise((function(t){y((function(){w(e,r,a),t()}))}))}))}function j(){y(".top_controls .dashboard-manager").hide(),y("#dashboardWidgetsArea").dashboard("destroy")}function A(e){"Widgetize"!==e.module&&"Dashboard_Dashboard"!==e.category&&j()}function S(e){O(e)}var k={mounted:function(e,t){O(t.value.idDashboard),Object(n["watch"])((function(){return i["MatomoUrl"].parsed.value}),(function(e){A(e)})),i["Matomo"].on("Dashboard.loadDashboard",S)},unmounted:function(){A(i["MatomoUrl"].parsed.value),i["Matomo"].off("Dashboard.loadDashboard",S)}},C=["title"],E=Object(n["createElementVNode"])("span",{class:"icon icon-chevron-down"},null,-1),_={class:"dropdown positionInViewport"},N={class:"submenu"},x={class:"addWidget"},T=Object(n["createElementVNode"])("ul",{class:"widgetpreview-categorylist"},null,-1),P={class:"manageDashboard"},M=["onClick","disabled","title","data-action"],W=["onClick","disabled","title","data-action"],U=Object(n["createElementVNode"])("ul",{class:"widgetpreview-widgetlist"},null,-1),V=Object(n["createElementVNode"])("div",{class:"widgetpreview-preview"},null,-1);function H(e,t,o,r,a,i){var s=Object(n["resolveDirective"])("expand-on-click"),d=Object(n["resolveDirective"])("tooltips");return Object(n["withDirectives"])((Object(n["openBlock"])(),Object(n["createElementBlock"])("div",{ref:"root",class:"dashboard-manager piwikSelector borderedControl piwikTopControl dashboardSettings",onClick:t[0]||(t[0]=function(t){return e.onOpen()})},[Object(n["createElementVNode"])("a",{class:"title",title:e.translate("Dashboard_ManageDashboard"),tabindex:"4",ref:"expander"},[E,Object(n["createTextVNode"])(Object(n["toDisplayString"])(e.translate("Dashboard_Dashboard")),1)],8,C),Object(n["createElementVNode"])("div",_,[Object(n["createElementVNode"])("ul",N,[Object(n["createElementVNode"])("li",null,[Object(n["createElementVNode"])("div",x,Object(n["toDisplayString"])(e.translate("Dashboard_AddAWidget")),1),T]),Object(n["createElementVNode"])("li",null,[Object(n["createElementVNode"])("div",P,Object(n["toDisplayString"])(e.translate("Dashboard_ManageDashboard")),1),Object(n["createElementVNode"])("ul",null,[(Object(n["openBlock"])(!0),Object(n["createElementBlock"])(n["Fragment"],null,Object(n["renderList"])(e.dashboardActions,(function(t,o){return Object(n["openBlock"])(),Object(n["createElementBlock"])("li",{key:o,onClick:function(t){return e.onClickAction(t,o)},disabled:e.isActionDisabled[o]?"disabled":void 0,title:e.actionTooltips[o]||void 0,"data-action":o},Object(n["toDisplayString"])(e.translate(t)),9,M)})),128))])]),(Object(n["openBlock"])(!0),Object(n["createElementBlock"])(n["Fragment"],null,Object(n["renderList"])(e.generalActions,(function(t,o){return Object(n["openBlock"])(),Object(n["createElementBlock"])("li",{key:o,onClick:function(t){return e.onClickAction(t,o)},class:"generalAction",disabled:e.isActionDisabled[o]?"disabled":void 0,title:e.actionTooltips[o]||void 0,"data-action":o},Object(n["toDisplayString"])(e.translate(t)),9,W)})),128))]),U,V])],512)),[[s,{expander:"expander",onClosed:e.onClose}],[d,{show:!1}]])}var I=window,B=I.$;function L(e){return!B("#dashboardWidgetsArea").find('[widgetId="'.concat(e,'"]')).length}function q(e){window.MATOMO_DASHBOARD_SETTINGS_WIDGET_SELECTED_NOOP||B("#dashboardWidgetsArea").dashboard("addWidget",e.uniqueId,1,e.parameters,!0,!1)}var R=Object(n["defineComponent"])({directives:{ExpandOnClick:i["ExpandOnClick"],Tooltips:i["Tooltips"]},data:function(){return{isActionDisabled:{},actionTooltips:{}}},setup:function(){var e=Object(n["ref"])(null),t=Object(n["ref"])(null),o=function(){e.value.widgetPreview({isWidgetAvailable:L,onSelect:function(e){window.widgetsHelper.getWidgetObjectFromUniqueId(e,(function(e){t.value.click(),q(e)}))},resetOnSelect:!0})};return Object(n["onMounted"])((function(){i["Matomo"].postEvent("Dashboard.DashboardSettings.mounted",t.value),e.value=B(t.value),o(),i["Matomo"].on("WidgetsStore.reloaded",(function(){o()})),e.value.hide()})),{root:t,rootJQuery:e}},computed:{isUserNotAnonymous:function(){return!!i["Matomo"].userLogin&&"anonymous"!==i["Matomo"].userLogin},isSuperUser:function(){return this.isUserNotAnonymous&&i["Matomo"].hasSuperUserAccess},isUserHasSomeAdminAccess:function(){return this.isUserNotAnonymous&&i["Matomo"].userHasSomeAdminAccess},dashboardActions:function(){var e={resetDashboard:"Dashboard_ResetDashboard",showChangeDashboardLayoutDialog:"Dashboard_ChangeDashboardLayout"};return this.isUserNotAnonymous&&(e.renameDashboard="Dashboard_RenameDashboard",e.removeDashboard="Dashboard_RemoveDashboard"),this.isSuperUser&&(e.setAsDefaultWidgets="Dashboard_SetAsDefaultWidgets"),this.isUserHasSomeAdminAccess&&(e.copyDashboardToUser="Dashboard_CopyDashboardToUser"),e},generalActions:function(){var e={};return this.isUserNotAnonymous&&(e.createDashboard="Dashboard_CreateNewDashboard"),e}},methods:{onClickAction:function(e,t){e.target.getAttribute("disabled")||window[t]()},onOpen:function(){B("#dashboardWidgetsArea").dashboard("isDefaultDashboard")?(this.isActionDisabled.removeDashboard=!0,this.actionTooltips.removeDashboard=Object(i["translate"])("Dashboard_RemoveDefaultDashboardNotPossible")):(this.isActionDisabled.removeDashboard=!1,this.actionTooltips.removeDashboard=void 0)},onClose:function(){this.rootJQuery.widgetPreview("reset")}}});R.render=H;var $=R;
/*!
 * Matomo - free/libre analytics platform
 *
 * @link    https://matomo.org
 * @license https://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
 */}})}));
//# sourceMappingURL=Dashboard.umd.min.js.map