{"version":3,"sources":["webpack:///2sxc.api.min.js","webpack:///webpack/bootstrap cfb9aa2c6d162ac392b3","webpack:///./2sxc-api/js/2sxc.api.ts","webpack:///./2sxc-api/js/ToSic.Sxc.Controller.ts","webpack:///./2sxc-api/js/ToSic.Sxc.Instance.ts","webpack:///./2sxc-api/js/ToSic.Sxc.Data.ts","webpack:///./2sxc-api/js/ToSic.Sxc.WebApi.ts","webpack:///./2sxc-api/js/ToSic.Sxc.TotalPopup.ts","webpack:///./2sxc-api/js/ToSic.Sxc.Url.ts"],"names":["modules","__webpack_require__","moduleId","installedModules","exports","module","i","l","call","m","c","d","name","getter","o","Object","defineProperty","configurable","enumerable","get","n","__esModule","object","property","prototype","hasOwnProperty","p","s","__webpack_exports__","value","__WEBPACK_IMPORTED_MODULE_0__ToSic_Sxc_Controller__","window","$2sxc","SxcController","id","cbid","_controllers","Error","idTuple","autoFind","cacheKey","_data","__WEBPACK_IMPORTED_MODULE_0__ToSic_Sxc_Instance__","$","ServicesFramework","buildSxcController","urlManager","__WEBPACK_IMPORTED_MODULE_2__ToSic_Sxc_Url__","debug","load","uncache","addOn","sysinfo","version","description","beta","totalPopup","__WEBPACK_IMPORTED_MODULE_1__ToSic_Sxc_TotalPopup__","urlParams","parts","getUrl","url","preventUnmin","r","replace","indexOf","domElement","containerTag","closest","iid","getAttribute","SxcInstanceWithInternals","__WEBPACK_IMPORTED_MODULE_0__ToSic_Sxc_Data__","__WEBPACK_IMPORTED_MODULE_1__ToSic_Sxc_WebApi__","__extends","this","extendStatics","setPrototypeOf","__proto__","Array","b","__","constructor","create","SxcInstance","dnnSf","serviceScopes","serviceRoot","getServiceRoot","webApi","resolveServiceUrl","virtualPath","scope","split","toLowerCase","substring","showDetailedHttpError","result","console","log","status","config","infoText","srvResp","responseText","JSON","parse","data","msg","Message","msgDet","MessageDetail","ExceptionMessage","alert","SxcInstanceWithEditing","_super","_this","manage","_manage","initInstance","e","error","_translateInit","isEditMode","_isEditMode","source","isLoaded","lastRefresh","recreate","resetCache","SxcDataWithInternals","controller","undefined","List","sourceUrl","params","origSuccess","success","dataSetName","in","Default","Date","_triggerLoaded","request","statusText","preventAutoFail","reload","then","on","events","callback","bind","trigger","one","SxcWebApiWithInternals","settingsOrUrl","post","delete","put","settings","method","controllerAction","controllerName","actionName","action","length","defaults","extend","sf","promise","ajax","async","dataType","stringify","contentType","type","getActionUrl","beforeSend","xhr","setRequestHeader","setModuleHeaders","fail","param","TotalPopup","frame","open","z","top","parent","wrapper","document","createElement","setAttribute","body","appendChild","ifrm","className","close","frm","parentNode","removeChild","closeThis","UrlParamManager","strResult","searchRx","RegExp","results","exec","location","search","hash","matches","pathname","match","reverse","decodeURIComponent","require","found","message"],"mappings":"CAAS,SAAUA,GCInB,QAAAC,GAAAC,GAGA,GAAAC,EAAAD,GACA,MAAAC,GAAAD,GAAAE,OAGA,IAAAC,GAAAF,EAAAD,IACAI,EAAAJ,EACAK,GAAA,EACAH,WAUA,OANAJ,GAAAE,GAAAM,KAAAH,EAAAD,QAAAC,IAAAD,QAAAH,GAGAI,EAAAE,GAAA,EAGAF,EAAAD,QAvBA,GAAAD,KA4BAF,GAAAQ,EAAAT,EAGAC,EAAAS,EAAAP,EAGAF,EAAAU,EAAA,SAAAP,EAAAQ,EAAAC,GACAZ,EAAAa,EAAAV,EAAAQ,IACAG,OAAAC,eAAAZ,EAAAQ,GACAK,cAAA,EACAC,YAAA,EACAC,IAAAN,KAMAZ,EAAAmB,EAAA,SAAAf,GACA,GAAAQ,GAAAR,KAAAgB,WACA,WAA2B,MAAAhB,GAAA,SAC3B,WAAiC,MAAAA,GAEjC,OADAJ,GAAAU,EAAAE,EAAA,IAAAA,GACAA,GAIAZ,EAAAa,EAAA,SAAAQ,EAAAC,GAAsD,MAAAR,QAAAS,UAAAC,eAAAjB,KAAAc,EAAAC,IAGtDtB,EAAAyB,EAAA,GAGAzB,IAAA0B,EAAA,KDMM,SAAUtB,EAAQuB,EAAqB3B,GAE7C,YACAc,QAAOC,eA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.min.js","sourcesContent":["/******/ (function(modules) { // webpackBootstrap\n/******/ \t// The module cache\n/******/ \tvar installedModules = {};\n/******/\n/******/ \t// The require function\n/******/ \tfunction __webpack_require__(moduleId) {\n/******/\n/******/ \t\t// Check if module is in cache\n/******/ \t\tif(installedModules[moduleId]) {\n/******/ \t\t\treturn installedModules[moduleId].exports;\n/******/ \t\t}\n/******/ \t\t// Create a new module (and put it into the cache)\n/******/ \t\tvar module = installedModules[moduleId] = {\n/******/ \t\t\ti: moduleId,\n/******/ \t\t\tl: false,\n/******/ \t\t\texports: {}\n/******/ \t\t};\n/******/\n/******/ \t\t// Execute the module function\n/******/ \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n/******/\n/******/ \t\t// Flag the module as loaded\n/******/ \t\tmodule.l = true;\n/******/\n/******/ \t\t// Return the exports of the module\n/******/ \t\treturn module.exports;\n/******/ \t}\n/******/\n/******/\n/******/ \t// expose the modules object (__webpack_modules__)\n/******/ \t__webpack_require__.m = modules;\n/******/\n/******/ \t// expose the module cache\n/******/ \t__webpack_require__.c = installedModules;\n/******/\n/******/ \t// define getter function for harmony exports\n/******/ \t__webpack_require__.d = function(exports, name, getter) {\n/******/ \t\tif(!__webpack_require__.o(exports, name)) {\n/******/ \t\t\tObject.defineProperty(exports, name, {\n/******/ \t\t\t\tconfigurable: false,\n/******/ \t\t\t\tenumerable: true,\n/******/ \t\t\t\tget: getter\n/******/ \t\t\t});\n/******/ \t\t}\n/******/ \t};\n/******/\n/******/ \t// getDefaultExport function for compatibility with non-harmony modules\n/******/ \t__webpack_require__.n = function(module) {\n/******/ \t\tvar getter = module && module.__esModule ?\n/******/ \t\t\tfunction getDefault() { return module['default']; } :\n/******/ \t\t\tfunction getModuleExports() { return module; };\n/******/ \t\t__webpack_require__.d(getter, 'a', getter);\n/******/ \t\treturn getter;\n/******/ \t};\n/******/\n/******/ \t// Object.prototype.hasOwnProperty.call\n/******/ \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n/******/\n/******/ \t// __webpack_public_path__\n/******/ \t__webpack_require__.p = \"\";\n/******/\n/******/ \t// Load entry module and return exports\n/******/ \treturn __webpack_require__(__webpack_require__.s = 0);\n/******/ })\n/************************************************************************/\n/******/ ([\n/* 0 */\n/***/ (function(module, __webpack_exports__, __webpack_require__) {\n\n\"use strict\";\nObject.defineProperty(__webpack_exports__, \"__esModule\", { value: true });\n/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__ToSic_Sxc_Controller__ = __webpack_require__(1);\n\r\nif (!window.$2sxc)\r\n window.$2sxc = Object(__WEBPACK_IMPORTED_MODULE_0__ToSic_Sxc_Controller__[\"a\" /* buildSxcController */])();\r\n\n\n/***/ }),\n/* 1 */\n/***/ (function(module, __webpack_exports__, __webpack_require__) {\n\n\"use strict\";\n/* harmony export (immutable) */ __webpack_exports__[\"a\"] = buildSxcController;\n/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__ToSic_Sxc_Instance__ = __webpack_require__(2);\n/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__ToSic_Sxc_TotalPopup__ = __webpack_require__(5);\n/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__ToSic_Sxc_Url__ = __webpack_require__(6);\n\r\n\r\n\r\nfunction SxcController(id, cbid) {\r\n var $2sxc = window.$2sxc;\r\n if (!$2sxc._controllers)\r\n throw new Error(\"$2sxc not initialized yet\");\r\n if (typeof id === \"object\") {\r\n var idTuple = autoFind(id);\r\n id = idTuple[0];\r\n cbid = idTuple[1];\r\n }\r\n if (!cbid)\r\n cbid = id;\r\n var cacheKey = id + \":\" + cbid;\r\n if ($2sxc._controllers[cacheKey])\r\n return $2sxc._controllers[cacheKey];\r\n if (!$2sxc._data[cacheKey])\r\n $2sxc._data[cacheKey] = {};\r\n return ($2sxc._controllers[cacheKey]\r\n = new __WEBPACK_IMPORTED_MODULE_0__ToSic_Sxc_Instance__[\"a\" /* SxcInstanceWithInternals */](id, cbid, cacheKey, $2sxc, $.ServicesFramework));\r\n}\r\nfunction buildSxcController() {\r\n var urlManager = new __WEBPACK_IMPORTED_MODULE_2__ToSic_Sxc_Url__[\"a\" /* UrlParamManager */]();\r\n var debug = {\r\n load: (urlManager.get(\"debug\") === \"true\"),\r\n uncache: urlManager.get(\"sxcver\"),\r\n };\r\n var addOn = {\r\n _controllers: {},\r\n sysinfo: {\r\n version: \"09.05.02\",\r\n description: \"The 2sxc Controller object - read more about it on 2sxc.org\",\r\n },\r\n beta: {},\r\n _data: {},\r\n totalPopup: new __WEBPACK_IMPORTED_MODULE_1__ToSic_Sxc_TotalPopup__[\"a\" /* TotalPopup */](),\r\n urlParams: urlManager,\r\n debug: debug,\r\n parts: {\r\n getUrl: function (url, preventUnmin) {\r\n var r = (preventUnmin || !debug.load) ? url : url.replace(\".min\", \"\");\r\n if (debug.uncache && r.indexOf(\"sxcver\") === -1)\r\n r = r + ((r.indexOf(\"?\") === -1) ? \"?\" : \"&\") + \"sxcver=\" + debug.uncache;\r\n return r;\r\n },\r\n },\r\n };\r\n for (var property in addOn)\r\n if (addOn.hasOwnProperty(property))\r\n SxcController[property] = addOn[property];\r\n return SxcController;\r\n}\r\nfunction autoFind(domElement) {\r\n var containerTag = $(domElement).closest(\".sc-content-block\")[0];\r\n if (!containerTag)\r\n return null;\r\n var iid = containerTag.getAttribute(\"data-cb-instance\");\r\n var cbid = containerTag.getAttribute(\"data-cb-id\");\r\n if (!iid || !cbid)\r\n return null;\r\n return [iid, cbid];\r\n}\r\n\n\n/***/ }),\n/* 2 */\n/***/ (function(module, __webpack_exports__, __webpack_require__) {\n\n\"use strict\";\n/* unused harmony export SxcInstance */\n/* unused harmony export SxcInstanceWithEditing */\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return SxcInstanceWithInternals; });\n/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__ToSic_Sxc_Data__ = __webpack_require__(3);\n/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__ToSic_Sxc_WebApi__ = __webpack_require__(4);\nvar __extends = (this && this.__extends) || (function () {\r\n var extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\r\n return function (d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n };\r\n})();\r\n\r\n\r\nvar SxcInstance = (function () {\r\n function SxcInstance(id, cbid, dnnSf) {\r\n this.id = id;\r\n this.cbid = cbid;\r\n this.dnnSf = dnnSf;\r\n this.serviceScopes = [\"app\", \"app-sys\", \"app-api\", \"app-query\", \"app-content\", \"eav\", \"view\", \"dnn\"];\r\n this.serviceRoot = dnnSf(id).getServiceRoot(\"2sxc\");\r\n this.webApi = new __WEBPACK_IMPORTED_MODULE_1__ToSic_Sxc_WebApi__[\"a\" /* SxcWebApiWithInternals */](this, id, cbid);\r\n }\r\n SxcInstance.prototype.resolveServiceUrl = function (virtualPath) {\r\n var scope = virtualPath.split(\"/\")[0].toLowerCase();\r\n if (this.serviceScopes.indexOf(scope) === -1)\r\n return virtualPath;\r\n return this.serviceRoot + scope + \"/\" + virtualPath.substring(virtualPath.indexOf(\"/\") + 1);\r\n };\r\n SxcInstance.prototype.showDetailedHttpError = function (result) {\r\n if (window.console)\r\n console.log(result);\r\n if (result.status === 404 &&\r\n result.config &&\r\n result.config.url &&\r\n result.config.url.indexOf(\"/dist/i18n/\") > -1) {\r\n if (window.console)\r\n console.log(\"just fyi: failed to load language resource; will have to use default\");\r\n return result;\r\n }\r\n if (result.status === 0 || result.status === -1)\r\n return result;\r\n var infoText = \"Had an error talking to the server (status \" + result.status + \").\";\r\n var srvResp = result.responseText\r\n ? JSON.parse(result.responseText)\r\n : result.data;\r\n if (srvResp) {\r\n var msg = srvResp.Message;\r\n if (msg)\r\n infoText += \"\\nMessage: \" + msg;\r\n var msgDet = srvResp.MessageDetail || srvResp.ExceptionMessage;\r\n if (msgDet)\r\n infoText += \"\\nDetail: \" + msgDet;\r\n if (msgDet && msgDet.indexOf(\"No action was found\") === 0)\r\n if (msgDet.indexOf(\"that matches the name\") > 0)\r\n infoText += \"\\n\\nTip from 2sxc: you probably got the action-name wrong in your JS.\";\r\n else if (msgDet.indexOf(\"that matches the request.\") > 0)\r\n infoText += \"\\n\\nTip from 2sxc: Seems like the parameters are the wrong amount or type.\";\r\n if (msg && msg.indexOf(\"Controller\") === 0 && msg.indexOf(\"not found\") > 0)\r\n infoText +=\r\n \"\\n\\nTip from 2sxc: you probably spelled the controller name wrong or forgot to remove the word 'controller' from the call in JS. To call a controller called 'DemoController' only use 'Demo'.\";\r\n }\r\n infoText += \"\\n\\nif you are an advanced user you can learn more about what went wrong - discover how on 2sxc.org/help?tag=debug\";\r\n alert(infoText);\r\n return result;\r\n };\r\n return SxcInstance;\r\n}());\r\n\r\nvar SxcInstanceWithEditing = (function (_super) {\r\n __extends(SxcInstanceWithEditing, _super);\r\n function SxcInstanceWithEditing(id, cbid, $2sxc, dnnSf) {\r\n var _this = _super.call(this, id, cbid, dnnSf) || this;\r\n _this.id = id;\r\n _this.cbid = cbid;\r\n _this.$2sxc = $2sxc;\r\n _this.dnnSf = dnnSf;\r\n _this.manage = null;\r\n try {\r\n if ($2sxc._manage)\r\n $2sxc._manage.initInstance(_this);\r\n }\r\n catch (e) {\r\n console.error('error in 2sxc - will only log but not throw', e);\r\n }\r\n if ($2sxc._translateInit && _this.manage)\r\n $2sxc._translateInit(_this.manage);\r\n return _this;\r\n }\r\n SxcInstanceWithEditing.prototype.isEditMode = function () {\r\n return this.manage && this.manage._isEditMode();\r\n };\r\n return SxcInstanceWithEditing;\r\n}(SxcInstance));\r\n\r\nvar SxcInstanceWithInternals = (function (_super) {\r\n __extends(SxcInstanceWithInternals, _super);\r\n function SxcInstanceWithInternals(id, cbid, cacheKey, $2sxc, dnnSf) {\r\n var _this = _super.call(this, id, cbid, $2sxc, dnnSf) || this;\r\n _this.id = id;\r\n _this.cbid = cbid;\r\n _this.cacheKey = cacheKey;\r\n _this.$2sxc = $2sxc;\r\n _this.dnnSf = dnnSf;\r\n _this.source = null;\r\n _this.isLoaded = false;\r\n _this.lastRefresh = null;\r\n _this.data = new __WEBPACK_IMPORTED_MODULE_0__ToSic_Sxc_Data__[\"a\" /* SxcDataWithInternals */](_this);\r\n return _this;\r\n }\r\n SxcInstanceWithInternals.prototype.recreate = function (resetCache) {\r\n if (resetCache)\r\n delete this.$2sxc._controllers[this.cacheKey];\r\n return this.$2sxc(this.id, this.cbid);\r\n };\r\n return SxcInstanceWithInternals;\r\n}(SxcInstanceWithEditing));\r\n\r\n\n\n/***/ }),\n/* 3 */\n/***/ (function(module, __webpack_exports__, __webpack_require__) {\n\n\"use strict\";\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return SxcDataWithInternals; });\nvar SxcDataWithInternals = (function () {\r\n function SxcDataWithInternals(controller) {\r\n this.controller = controller;\r\n this.source = undefined;\r\n this[\"in\"] = {};\r\n this.List = [];\r\n }\r\n SxcDataWithInternals.prototype.sourceUrl = function (params) {\r\n var url = this.controller.resolveServiceUrl(\"app-sys/appcontent/GetContentBlockData\");\r\n if (typeof params === \"string\")\r\n url += \"&\" + params;\r\n return url;\r\n };\r\n SxcDataWithInternals.prototype.load = function (source) {\r\n var _this = this;\r\n if (source && source.List) {\r\n return this.controller.data;\r\n }\r\n else {\r\n if (!source)\r\n source = {};\r\n if (!source.url)\r\n source.url = this.controller.data.sourceUrl();\r\n source.origSuccess = source.success;\r\n source.success = function (data) {\r\n for (var dataSetName in data) {\r\n if (data.hasOwnProperty(dataSetName))\r\n if (data[dataSetName].List !== null) {\r\n _this.controller.data.in[dataSetName] = data[dataSetName];\r\n _this.controller.data.in[dataSetName].name = dataSetName;\r\n }\r\n }\r\n if (_this.controller.data.in.Default)\r\n _this.List = _this.in.Default.List;\r\n if (source.origSuccess)\r\n source.origSuccess(_this);\r\n _this.controller.isLoaded = true;\r\n _this.controller.lastRefresh = new Date();\r\n _this._triggerLoaded();\r\n };\r\n source.error = function (request) { alert(request.statusText); };\r\n source.preventAutoFail = true;\r\n this.source = source;\r\n return this.reload();\r\n }\r\n };\r\n SxcDataWithInternals.prototype.reload = function () {\r\n this.controller.webApi.get(this.source)\r\n .then(this.source.success, this.source.error);\r\n return this;\r\n };\r\n SxcDataWithInternals.prototype.on = function (events, callback) {\r\n return $(this).bind(\"2scLoad\", callback)[0]._triggerLoaded();\r\n };\r\n SxcDataWithInternals.prototype._triggerLoaded = function () {\r\n return this.controller.isLoaded\r\n ? $(this).trigger(\"2scLoad\", [this])[0]\r\n : this;\r\n };\r\n SxcDataWithInternals.prototype.one = function (events, callback) {\r\n if (!this.controller.isLoaded)\r\n return $(this).one(\"2scLoad\", callback)[0];\r\n callback({}, this);\r\n return this;\r\n };\r\n return SxcDataWithInternals;\r\n}());\r\n\r\n\n\n/***/ }),\n/* 4 */\n/***/ (function(module, __webpack_exports__, __webpack_require__) {\n\n\"use strict\";\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return SxcWebApiWithInternals; });\nvar SxcWebApiWithInternals = (function () {\r\n function SxcWebApiWithInternals(controller, id, cbid) {\r\n this.controller = controller;\r\n this.id = id;\r\n this.cbid = cbid;\r\n }\r\n SxcWebApiWithInternals.prototype.get = function (settingsOrUrl, params, data, preventAutoFail) {\r\n return this.request(settingsOrUrl, params, data, preventAutoFail, \"GET\");\r\n };\r\n SxcWebApiWithInternals.prototype.post = function (settingsOrUrl, params, data, preventAutoFail) {\r\n return this.request(settingsOrUrl, params, data, preventAutoFail, \"POST\");\r\n };\r\n SxcWebApiWithInternals.prototype.delete = function (settingsOrUrl, params, data, preventAutoFail) {\r\n return this.request(settingsOrUrl, params, data, preventAutoFail, \"DELETE\");\r\n };\r\n SxcWebApiWithInternals.prototype.put = function (settingsOrUrl, params, data, preventAutoFail) {\r\n return this.request(settingsOrUrl, params, data, preventAutoFail, \"PUT\");\r\n };\r\n SxcWebApiWithInternals.prototype.request = function (settings, params, data, preventAutoFail, method) {\r\n if (typeof params !== \"object\" && typeof params !== \"undefined\")\r\n params = { id: params };\r\n if (typeof settings === \"string\") {\r\n var controllerAction = settings.split(\"/\");\r\n var controllerName = controllerAction[0];\r\n var actionName = controllerAction[1];\r\n if (controllerName === \"\" || actionName === \"\")\r\n alert(\"Error: controller or action not defined. Will continue with likely errors.\");\r\n settings = {\r\n controller: controllerName,\r\n action: actionName,\r\n params: params,\r\n data: data,\r\n url: controllerAction.length > 2 ? settings : null,\r\n preventAutoFail: preventAutoFail,\r\n };\r\n }\r\n var defaults = {\r\n method: method === null ? \"POST\" : method,\r\n params: null,\r\n preventAutoFail: false,\r\n };\r\n settings = $.extend({}, defaults, settings);\r\n var sf = $.ServicesFramework(this.id);\r\n var cbid = this.cbid;\r\n var promise = $.ajax({\r\n async: true,\r\n dataType: settings.dataType || \"json\",\r\n data: JSON.stringify(settings.data),\r\n contentType: \"application/json\",\r\n type: settings.method,\r\n url: this.getActionUrl(settings),\r\n beforeSend: function (xhr) {\r\n xhr.setRequestHeader(\"ContentBlockId\", cbid);\r\n sf.setModuleHeaders(xhr);\r\n },\r\n });\r\n if (!settings.preventAutoFail)\r\n promise.fail(this.controller.showDetailedHttpError);\r\n return promise;\r\n };\r\n SxcWebApiWithInternals.prototype.getActionUrl = function (settings) {\r\n var sf = $.ServicesFramework(this.id);\r\n var base = (settings.url)\r\n ? this.controller.resolveServiceUrl(settings.url)\r\n : sf.getServiceRoot(\"2sxc\") + \"app/auto/api/\" + settings.controller + \"/\" + settings.action;\r\n return base + (settings.params === null ? \"\" : (\"?\" + $.param(settings.params)));\r\n };\r\n return SxcWebApiWithInternals;\r\n}());\r\n\r\n\n\n/***/ }),\n/* 5 */\n/***/ (function(module, __webpack_exports__, __webpack_require__) {\n\n\"use strict\";\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return TotalPopup; });\nvar TotalPopup = (function () {\r\n function TotalPopup() {\r\n this.frame = undefined;\r\n this.callback = undefined;\r\n }\r\n TotalPopup.prototype.open = function (url, callback) {\r\n var z = 10000010;\r\n var p = window;\r\n while (p !== window.top && z < 10000100) {\r\n z++;\r\n p = p.parent;\r\n }\r\n var wrapper = document.createElement(\"div\");\r\n wrapper.setAttribute(\"style\", \" top: 0;left: 0;width: 100%;height: 100%; position:fixed; z-index:\" + z);\r\n document.body.appendChild(wrapper);\r\n var ifrm = document.createElement(\"iframe\");\r\n ifrm.setAttribute(\"allowtransparency\", \"true\");\r\n ifrm.setAttribute(\"style\", \"top: 0;left: 0;width: 100%;height: 100%;\");\r\n ifrm.setAttribute(\"src\", url);\r\n wrapper.appendChild(ifrm);\r\n document.body.className += \" sxc-popup-open\";\r\n this.frame = ifrm;\r\n this.callback = callback;\r\n };\r\n TotalPopup.prototype.close = function () {\r\n if (this.frame) {\r\n document.body.className = document.body.className.replace(\"sxc-popup-open\", \"\");\r\n var frm = this.frame;\r\n frm.parentNode.parentNode.removeChild(frm.parentNode);\r\n this.callback();\r\n }\r\n };\r\n TotalPopup.prototype.closeThis = function () {\r\n window.parent.$2sxc.totalPopup.close();\r\n };\r\n return TotalPopup;\r\n}());\r\n\r\n\n\n/***/ }),\n/* 6 */\n/***/ (function(module, __webpack_exports__, __webpack_require__) {\n\n\"use strict\";\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return UrlParamManager; });\nvar UrlParamManager = (function () {\r\n function UrlParamManager() {\r\n }\r\n UrlParamManager.prototype.get = function (name) {\r\n name = name.replace(/[\\[]/, \"\\\\[\").replace(/[\\]]/, \"\\\\]\");\r\n var searchRx = new RegExp(\"[\\\\?&]\" + name + \"=([^&#]*)\", \"i\");\r\n var results = searchRx.exec(location.search);\r\n var strResult;\r\n if (results === null) {\r\n var hashRx = new RegExp(\"[#&]\" + name + \"=([^&#]*)\", \"i\");\r\n results = hashRx.exec(location.hash);\r\n }\r\n if (results === null) {\r\n var matches = window.location.pathname.match(new RegExp(\"/\" + name + \"/([^/]+)\", \"i\"));\r\n if (matches && matches.length > 1)\r\n strResult = matches.reverse()[0];\r\n }\r\n else\r\n strResult = results[1];\r\n return strResult === null || strResult === undefined\r\n ? \"\"\r\n : decodeURIComponent(strResult.replace(/\\+/g, \" \"));\r\n };\r\n UrlParamManager.prototype.require = function (name) {\r\n var found = this.get(name);\r\n if (found === \"\") {\r\n var message = \"Required parameter (\" + name + \") missing from url - cannot continue\";\r\n alert(message);\r\n throw message;\r\n }\r\n return found;\r\n };\r\n return UrlParamManager;\r\n}());\r\n\r\n\n\n/***/ })\n/******/ ]);\n\n\n// WEBPACK FOOTER //\n// 2sxc.api.min.js"," \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, {\n \t\t\t\tconfigurable: false,\n \t\t\t\tenumerable: true,\n \t\t\t\tget: getter\n \t\t\t});\n \t\t}\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 0);\n\n\n\n// WEBPACK FOOTER //\n// webpack/bootstrap cfb9aa2c6d162ac392b3","// this is the 2sxc-javascript API\r\n// 2sxc will include this automatically when a user has edit-rights\r\n// a template developer will typically use this to use the data-api to read 2sxc-data from the server\r\n// read more about this in the wiki: https://github.com/2sic/2sxc/wiki/JavaScript-%242sxc\r\n\r\nimport { buildSxcController, Window } from \"./ToSic.Sxc.Controller\";\r\n\r\n// ReSharper disable InconsistentNaming\r\ndeclare const window: Window;\r\n\r\nif (!window.$2sxc) // prevent double execution\r\n window.$2sxc = buildSxcController();\r\n\r\n// ReSharper restore InconsistentNaming\r\n\n\n\n// WEBPACK FOOTER //\n// ./2sxc-api/js/2sxc.api.ts","// ReSharper disable InconsistentNaming\r\n\r\nimport { SxcInstance, SxcInstanceWithEditing, SxcInstanceWithInternals } from \"./ToSic.Sxc.Instance\";\r\nimport { TotalPopup } from \"./ToSic.Sxc.TotalPopup\";\r\nimport { UrlParamManager } from \"./ToSic.Sxc.Url\";\r\n\r\nexport interface Window { $2sxc: SxcController | SxcControllerWithInternals; }\r\n\r\ndeclare const $: any;\r\ndeclare const window: Window;\r\n\r\n/**\r\n * This is the interface for the main $2sxc object on the window\r\n */\r\nexport interface SxcController {\r\n /**\r\n * returns a 2sxc-instance of the id or html-tag passed in\r\n * @param id\r\n * @param cbid\r\n * @returns {}\r\n */\r\n (id: number | HTMLElement, cbid?: number): SxcInstance | SxcInstanceWithInternals,\r\n\r\n /**\r\n * system information, mainly for checking which version of 2sxc is running\r\n * note: it's not always updated reliably, but it helps when debugging\r\n */\r\n sysinfo: {\r\n /**\r\n * the version using the ##.##.## syntax\r\n */\r\n version: string,\r\n\r\n /**\r\n * a short text description, for people who have no idea what this is\r\n */\r\n description: string,\r\n };\r\n}\r\n\r\n/**\r\n * returns a 2sxc-instance of the id or html-tag passed in\r\n * @param id\r\n * @param cbid\r\n * @returns {}\r\n */\r\nfunction SxcController(id: number | HTMLElement, cbid?: number): SxcInstanceWithInternals {\r\n const $2sxc = window.$2sxc as SxcControllerWithInternals;\r\n if (!$2sxc._controllers)\r\n throw new Error(\"$2sxc not initialized yet\");\r\n\r\n // if it's a dom-element, use auto-find\r\n if (typeof id === \"object\") {\r\n const idTuple = autoFind(id);\r\n id = idTuple[0];\r\n cbid = idTuple[1];\r\n }\r\n\r\n if (!cbid) cbid = id; // if content-block is unknown, use id of module\r\n const cacheKey = id + \":\" + cbid; // neutralize the id from old \"34\" format to the new \"35:353\" format\r\n\r\n // either get the cached controller from previous calls, or create a new one\r\n if ($2sxc._controllers[cacheKey]) return $2sxc._controllers[cacheKey];\r\n\r\n // also init the data-cache in case it's ever needed\r\n if (!$2sxc._data[cacheKey]) $2sxc._data[cacheKey] = {};\r\n\r\n return ($2sxc._controllers[cacheKey]\r\n = new SxcInstanceWithInternals(id, cbid, cacheKey, $2sxc, $.ServicesFramework));\r\n}\r\n\r\n/**\r\n * Build a SXC Controller for the page. Should only ever be executed once\r\n */\r\nexport function buildSxcController(): SxcController | SxcControllerWithInternals {\r\n const urlManager = new UrlParamManager();\r\n const debug = {\r\n load: (urlManager.get(\"debug\") === \"true\"),\r\n uncache: urlManager.get(\"sxcver\"),\r\n };\r\n\r\n const addOn: any = {\r\n _controllers: {} as any,\r\n sysinfo: {\r\n version: \"09.05.02\",\r\n description: \"The 2sxc Controller object - read more about it on 2sxc.org\",\r\n },\r\n beta: {},\r\n _data: {},\r\n // this creates a full-screen iframe-popup and provides a close-command to finish the dialog as needed\r\n totalPopup: new TotalPopup(),\r\n urlParams: urlManager,\r\n // note: I would like to remove this from $2sxc, but it's currently\r\n // used both in the inpage-edit and in the dialogs\r\n // debug state which is needed in various places\r\n debug,\r\n // mini-helpers to manage 2sxc parts, a bit like a dependency loader\r\n // which will optimize to load min/max depending on debug state\r\n parts: {\r\n getUrl(url: string, preventUnmin: boolean) {\r\n let r = (preventUnmin || !debug.load) ? url : url.replace(\".min\", \"\"); // use min or not\r\n if (debug.uncache && r.indexOf(\"sxcver\") === -1)\r\n r = r + ((r.indexOf(\"?\") === -1) ? \"?\" : \"&\") + \"sxcver=\" + debug.uncache;\r\n return r;\r\n },\r\n },\r\n };\r\n for (const property in addOn)\r\n if (addOn.hasOwnProperty(property))\r\n SxcController[property] = addOn[property] as any;\r\n return SxcController as any as SxcControllerWithInternals;\r\n}\r\n\r\nfunction autoFind(domElement: HTMLElement): [number, number] {\r\n const containerTag = $(domElement).closest(\".sc-content-block\")[0];\r\n if (!containerTag) return null;\r\n const iid = containerTag.getAttribute(\"data-cb-instance\");\r\n const cbid = containerTag.getAttribute(\"data-cb-id\");\r\n if (!iid || !cbid) return null;\r\n return [iid, cbid];\r\n}\r\n\r\nexport interface SxcControllerWithInternals extends SxcController {\r\n (id: number | HTMLElement, cbid?: number): SxcInstance | SxcInstanceWithInternals;\r\n totalPopup: TotalPopup;\r\n urlParams: UrlParamManager;\r\n beta: any;\r\n _controllers: any;\r\n _data: any;\r\n _manage: any;\r\n _translateInit: any;\r\n debug: any;\r\n parts: any;\r\n\r\n}\r\n\r\n// ReSharper restore InconsistentNaming\r\n\n\n\n// WEBPACK FOOTER //\n// ./2sxc-api/js/ToSic.Sxc.Controller.ts","\r\nimport { SxcController, SxcControllerWithInternals } from \"./ToSic.Sxc.Controller\";\r\nimport { SxcDataWithInternals } from \"./ToSic.Sxc.Data\";\r\nimport { SxcWebApiWithInternals } from \"./ToSic.Sxc.WebApi\";\r\n/**\r\n * The typical sxc-instance object for a specific DNN module or content-block\r\n */\r\nexport class SxcInstance {\r\n /**\r\n * helpers for ajax calls\r\n */\r\n webApi: SxcWebApiWithInternals;\r\n protected serviceRoot: string;\r\n private readonly serviceScopes = [\"app\", \"app-sys\", \"app-api\", \"app-query\", \"app-content\", \"eav\", \"view\", \"dnn\"];\r\n\r\n constructor(\r\n /**\r\n * the sxc-instance ID, which is usually the DNN Module Id\r\n */\r\n public id: number,\r\n\r\n /**\r\n * content-block ID, which is either the module ID, or the content-block definitiion entity ID\r\n * this is an advanced concept you usually don't care about, otherwise you should research it\r\n */\r\n public cbid: number,\r\n protected readonly dnnSf: any,\r\n ) {\r\n this.serviceRoot = dnnSf(id).getServiceRoot(\"2sxc\");\r\n this.webApi = new SxcWebApiWithInternals(this, id, cbid);\r\n }\r\n\r\n /**\r\n * converts a short api-call path like \"/app/Blog/query/xyz\" to the DNN full path\r\n * which varies from installation to installation like \"/desktopmodules/api/2sxc/app/...\"\r\n * @param virtualPath\r\n * @returns mapped path\r\n */\r\n resolveServiceUrl(virtualPath: string) {\r\n const scope = virtualPath.split(\"/\")[0].toLowerCase();\r\n\r\n // stop if it's not one of our special paths\r\n if (this.serviceScopes.indexOf(scope) === -1)\r\n return virtualPath;\r\n\r\n return this.serviceRoot + scope + \"/\" + virtualPath.substring(virtualPath.indexOf(\"/\") + 1);\r\n }\r\n\r\n\r\n // Show a nice error with more infos around 2sxc\r\n showDetailedHttpError(result: any): any {\r\n if (window.console)\r\n console.log(result);\r\n\r\n if (result.status === 404 &&\r\n result.config &&\r\n result.config.url &&\r\n result.config.url.indexOf(\"/dist/i18n/\") > -1) {\r\n if (window.console)\r\n console.log(\"just fyi: failed to load language resource; will have to use default\");\r\n return result;\r\n }\r\n\r\n\r\n // if it's an unspecified 0-error, it's probably not an error but a cancelled request,\r\n // (happens when closing popups containing angularJS)\r\n if (result.status === 0 || result.status === -1)\r\n return result;\r\n\r\n // let's try to show good messages in most cases\r\n let infoText = \"Had an error talking to the server (status \" + result.status + \").\";\r\n const srvResp = result.responseText\r\n ? JSON.parse(result.responseText) // for jquery ajax errors\r\n : result.data; // for angular $http\r\n if (srvResp) {\r\n const msg = srvResp.Message;\r\n if (msg) infoText += \"\\nMessage: \" + msg;\r\n const msgDet = srvResp.MessageDetail || srvResp.ExceptionMessage;\r\n if (msgDet) infoText += \"\\nDetail: \" + msgDet;\r\n\r\n\r\n if (msgDet && msgDet.indexOf(\"No action was found\") === 0)\r\n if (msgDet.indexOf(\"that matches the name\") > 0)\r\n infoText += \"\\n\\nTip from 2sxc: you probably got the action-name wrong in your JS.\";\r\n else if (msgDet.indexOf(\"that matches the request.\") > 0)\r\n infoText += \"\\n\\nTip from 2sxc: Seems like the parameters are the wrong amount or type.\";\r\n\r\n if (msg && msg.indexOf(\"Controller\") === 0 && msg.indexOf(\"not found\") > 0)\r\n infoText +=\r\n // tslint:disable-next-line:max-line-length\r\n \"\\n\\nTip from 2sxc: you probably spelled the controller name wrong or forgot to remove the word 'controller' from the call in JS. To call a controller called 'DemoController' only use 'Demo'.\";\r\n\r\n }\r\n // tslint:disable-next-line:max-line-length\r\n infoText += \"\\n\\nif you are an advanced user you can learn more about what went wrong - discover how on 2sxc.org/help?tag=debug\";\r\n alert(infoText);\r\n\r\n return result;\r\n }\r\n}\r\n\r\n/**\r\n * Enhanced sxc instance with additional editing functionality\r\n * Use this, if you intend to run content-management commands like \"edit\" from your JS directly\r\n */\r\nexport class SxcInstanceWithEditing extends SxcInstance {\r\n /**\r\n * manage object which provides access to additional content-management features\r\n * it only exists if 2sxc is in edit mode (otherwise the JS are not included for these features)\r\n */\r\n manage: any = null; // initialize correctly later on\r\n\r\n constructor(\r\n public id: number,\r\n public cbid: number,\r\n// ReSharper disable once InconsistentNaming\r\n protected $2sxc: SxcControllerWithInternals,\r\n protected readonly dnnSf: any,\r\n ) {\r\n super(id, cbid, dnnSf);\r\n\r\n // add manage property, but not within initializer, because inside the manage-initializer it may reference 2sxc again\r\n try { // sometimes the manage can't be built, like before installing\r\n if ($2sxc._manage) $2sxc._manage.initInstance(this);\r\n } catch (e) {\r\n console.error('error in 2sxc - will only log but not throw', e);\r\n // throw e;\r\n }\r\n\r\n // this only works when manage exists (not installing) and translator exists too\r\n if ($2sxc._translateInit && this.manage) $2sxc._translateInit(this.manage); // init translate, not really nice, but ok for now\r\n\r\n }\r\n\r\n /**\r\n * checks if we're currently in edit mode\r\n * @returns {boolean}\r\n */\r\n isEditMode() {\r\n return this.manage && this.manage._isEditMode();\r\n }\r\n\r\n}\r\n\r\nexport class SxcInstanceWithInternals extends SxcInstanceWithEditing {\r\n data: SxcDataWithInternals;\r\n source: any = null;\r\n isLoaded = false;\r\n lastRefresh: Date = null;\r\n\r\n constructor(\r\n public id: number,\r\n public cbid: number,\r\n private cacheKey: string,\r\n// ReSharper disable once InconsistentNaming\r\n protected $2sxc: SxcControllerWithInternals,\r\n protected readonly dnnSf: any,\r\n ) {\r\n super(id, cbid, $2sxc, dnnSf);\r\n this.data = new SxcDataWithInternals(this);\r\n }\r\n\r\n recreate(resetCache: boolean): SxcInstanceWithInternals {\r\n if (resetCache) delete this.$2sxc._controllers[this.cacheKey]; // clear cache\r\n return this.$2sxc(this.id, this.cbid) as any as SxcInstanceWithInternals; // generate new\r\n }\r\n}\r\n\n\n\n// WEBPACK FOOTER //\n// ./2sxc-api/js/ToSic.Sxc.Instance.ts","import { SxcInstanceWithInternals } from \"./ToSic.Sxc.Instance\";\r\n\r\ndeclare const $: any;\r\n\r\n\r\nexport class SxcDataWithInternals {\r\n source: any = undefined;\r\n\r\n // in-streams\r\n \"in\": any = {};\r\n\r\n // will hold the default stream ([\"in\"][\"Default\"].List\r\n List: any = [];\r\n\r\n constructor(\r\n private controller: SxcInstanceWithInternals,\r\n ) {\r\n\r\n }\r\n\r\n // source path defaulting to current page + optional params\r\n sourceUrl(params?: string): string {\r\n let url = this.controller.resolveServiceUrl(\"app-sys/appcontent/GetContentBlockData\");\r\n if (typeof params === \"string\") // text like 'id=7'\r\n url += \"&\" + params;\r\n return url;\r\n }\r\n\r\n\r\n // load data via ajax\r\n load(source?: any) {\r\n // if source is already the data, set it\r\n if (source && source.List) {\r\n // 2017-09-05 2dm: discoverd a call to an inexisting function\r\n // since this is an old API which is being deprecated, please don't fix unless we get active feedback\r\n // controller.data.setData(source);\r\n return this.controller.data;\r\n } else {\r\n if (!source)\r\n source = {};\r\n if (!source.url)\r\n source.url = this.controller.data.sourceUrl();\r\n source.origSuccess = source.success;\r\n source.success = (data: any) => {\r\n\r\n for (const dataSetName in data) {\r\n if (data.hasOwnProperty(dataSetName))\r\n if (data[dataSetName].List !== null) {\r\n this.controller.data.in[dataSetName] = data[dataSetName];\r\n this.controller.data.in[dataSetName].name = dataSetName;\r\n }\r\n }\r\n\r\n if (this.controller.data.in.Default)\r\n // 2017-09-05 2dm: previously wrote it to controller.List, but this is almost certainly a mistake\r\n // since it's an old API which is being deprecated, we won't fix it\r\n this.List = this.in.Default.List;\r\n\r\n if (source.origSuccess)\r\n source.origSuccess(this);\r\n\r\n this.controller.isLoaded = true;\r\n this.controller.lastRefresh = new Date();\r\n (this as any)._triggerLoaded();\r\n };\r\n source.error = (request: any) => { alert(request.statusText); };\r\n source.preventAutoFail = true; // use our fail message\r\n this.source = source;\r\n return this.reload();\r\n }\r\n }\r\n\r\n reload(): SxcDataWithInternals {\r\n this.controller.webApi.get(this.source)\r\n .then(this.source.success, this.source.error);\r\n return this;\r\n }\r\n\r\n on(events: Event, callback: () => void): Promise {\r\n return $(this).bind(\"2scLoad\", callback)[0]._triggerLoaded();\r\n }\r\n\r\n _triggerLoaded(): Promise {\r\n return this.controller.isLoaded\r\n ? $(this).trigger(\"2scLoad\", [this])[0]\r\n : this;\r\n }\r\n\r\n one(events: Event, callback: (x: any, y: any) => void): SxcDataWithInternals {\r\n if (!this.controller.isLoaded)\r\n return $(this).one(\"2scLoad\", callback)[0];\r\n callback({}, this);\r\n return this;\r\n }\r\n}\r\n\n\n\n// WEBPACK FOOTER //\n// ./2sxc-api/js/ToSic.Sxc.Data.ts","\r\ndeclare const $: any;\r\nimport { SxcInstance } from \"./ToSic.Sxc.Instance\";\r\n\r\n/**\r\n * helper API to run ajax / REST calls to the server\r\n * it will ensure that the headers etc. are set correctly\r\n * and that urls are rewritten\r\n */\r\nexport class SxcWebApiWithInternals {\r\n constructor(\r\n private readonly controller: SxcInstance,\r\n private readonly id: number,\r\n private readonly cbid: number,\r\n ) {\r\n\r\n }\r\n /**\r\n * returns an http-get promise\r\n * @param settingsOrUrl the url to get\r\n * @param params jQuery style ajax parameters\r\n * @param data jQuery style data for post/put requests\r\n * @param preventAutoFail\r\n * @returns {Promise} jQuery ajax promise object\r\n */\r\n get(settingsOrUrl: string | any, params?: any, data?: any, preventAutoFail?: boolean): any {\r\n return this.request(settingsOrUrl, params, data, preventAutoFail, \"GET\");\r\n }\r\n\r\n /**\r\n * returns an http-get promise\r\n * @param settingsOrUrl the url to get\r\n * @param params jQuery style ajax parameters\r\n * @param data jQuery style data for post/put requests\r\n * @param preventAutoFail\r\n * @returns {Promise} jQuery ajax promise object\r\n */\r\n post(settingsOrUrl: string | any, params?: any, data?: any, preventAutoFail?: boolean): any {\r\n return this.request(settingsOrUrl, params, data, preventAutoFail, \"POST\");\r\n }\r\n\r\n /**\r\n * returns an http-get promise\r\n * @param settingsOrUrl the url to get\r\n * @param params jQuery style ajax parameters\r\n * @param data jQuery style data for post/put requests\r\n * @param preventAutoFail\r\n * @returns {Promise} jQuery ajax promise object\r\n */\r\n delete(settingsOrUrl: string | any, params?: any, data?: any, preventAutoFail?: boolean): any {\r\n return this.request(settingsOrUrl, params, data, preventAutoFail, \"DELETE\");\r\n }\r\n\r\n /**\r\n * returns an http-get promise\r\n * @param settingsOrUrl the url to get\r\n * @param params jQuery style ajax parameters\r\n * @param data jQuery style data for post/put requests\r\n * @param preventAutoFail\r\n * @returns {Promise} jQuery ajax promise object\r\n */\r\n put(settingsOrUrl: string | any, params?: any, data?: any, preventAutoFail?: boolean): any {\r\n return this.request(settingsOrUrl, params, data, preventAutoFail, \"PUT\");\r\n }\r\n\r\n private request(settings: string | any, params: any, data: any, preventAutoFail: boolean, method: string): any {\r\n\r\n // url parameter: autoconvert a single value (instead of object of values) to an id=... parameter\r\n // tslint:disable-next-line:curly\r\n if (typeof params !== \"object\" && typeof params !== \"undefined\")\r\n params = { id: params };\r\n\r\n // if the first parameter is a string, resolve settings\r\n if (typeof settings === \"string\") {\r\n const controllerAction = settings.split(\"/\");\r\n const controllerName = controllerAction[0];\r\n const actionName = controllerAction[1];\r\n\r\n if (controllerName === \"\" || actionName === \"\")\r\n alert(\"Error: controller or action not defined. Will continue with likely errors.\");\r\n\r\n settings = {\r\n controller: controllerName,\r\n action: actionName,\r\n params,\r\n data,\r\n url: controllerAction.length > 2 ? settings : null,\r\n preventAutoFail,\r\n };\r\n }\r\n\r\n const defaults = {\r\n method: method === null ? \"POST\" : method,\r\n params: null as any,\r\n preventAutoFail: false,\r\n };\r\n settings = $.extend({}, defaults, settings);\r\n const sf = $.ServicesFramework(this.id);\r\n const cbid = this.cbid; // must read here, as the \"this\" will change inside the method\r\n\r\n const promise = $.ajax({\r\n async: true,\r\n dataType: settings.dataType || \"json\", // default is json if not specified\r\n data: JSON.stringify(settings.data),\r\n contentType: \"application/json\",\r\n type: settings.method,\r\n url: this.getActionUrl(settings),\r\n beforeSend(xhr: any) {\r\n xhr.setRequestHeader(\"ContentBlockId\", cbid);\r\n sf.setModuleHeaders(xhr);\r\n },\r\n });\r\n\r\n if (!settings.preventAutoFail)\r\n promise.fail(this.controller.showDetailedHttpError);\r\n\r\n return promise;\r\n }\r\n\r\n private getActionUrl(settings: any): string {\r\n const sf = $.ServicesFramework(this.id);\r\n const base = (settings.url)\r\n ? this.controller.resolveServiceUrl(settings.url)\r\n : sf.getServiceRoot(\"2sxc\") + \"app/auto/api/\" + settings.controller + \"/\" + settings.action;\r\n return base + (settings.params === null ? \"\" : (\"?\" + $.param(settings.params)));\r\n }\r\n\r\n}\r\n\n\n\n// WEBPACK FOOTER //\n// ./2sxc-api/js/ToSic.Sxc.WebApi.ts","\r\nexport class TotalPopup {\r\n frame: any = undefined;\r\n callback: any = undefined;\r\n\r\n open(url: string, callback: () => void): void {\r\n // count parents to see how high the z-index needs to be\r\n let z = 10000010; // Needs at least 10000000 to be on top of the DNN9 bar\r\n let p = window;\r\n while (p !== window.top && z < 10000100) {\r\n z++;\r\n p = p.parent;\r\n }\r\n\r\n const wrapper = document.createElement(\"div\");\r\n wrapper.setAttribute(\"style\", \" top: 0;left: 0;width: 100%;height: 100%; position:fixed; z-index:\" + z);\r\n document.body.appendChild(wrapper);\r\n\r\n const ifrm = document.createElement(\"iframe\");\r\n ifrm.setAttribute(\"allowtransparency\", \"true\");\r\n ifrm.setAttribute(\"style\", \"top: 0;left: 0;width: 100%;height: 100%;\");\r\n ifrm.setAttribute(\"src\", url);\r\n wrapper.appendChild(ifrm);\r\n document.body.className += \" sxc-popup-open\";\r\n this.frame = ifrm;\r\n this.callback = callback;\r\n }\r\n\r\n close(): void {\r\n if (this.frame) {\r\n document.body.className = document.body.className.replace(\"sxc-popup-open\", \"\");\r\n const frm = this.frame;\r\n frm.parentNode.parentNode.removeChild(frm.parentNode);\r\n this.callback();\r\n }\r\n }\r\n\r\n closeThis(): void {\r\n (window.parent as any).$2sxc.totalPopup.close();\r\n }\r\n\r\n}\r\n\n\n\n// WEBPACK FOOTER //\n// ./2sxc-api/js/ToSic.Sxc.TotalPopup.ts","\r\n export class UrlParamManager {\r\n get(name: string) {\r\n // warning: this method is duplicated in 2 places - keep them in sync.\r\n // locations are eav and 2sxc4ng\r\n name = name.replace(/[\\[]/, \"\\\\[\").replace(/[\\]]/, \"\\\\]\");\r\n const searchRx = new RegExp(\"[\\\\?&]\" + name + \"=([^&#]*)\", \"i\");\r\n let results = searchRx.exec(location.search);\r\n let strResult: string;\r\n\r\n if (results === null) {\r\n const hashRx = new RegExp(\"[#&]\" + name + \"=([^&#]*)\", \"i\");\r\n results = hashRx.exec(location.hash);\r\n }\r\n\r\n // if nothing found, try normal URL because DNN places parameters in /key/value notation\r\n if (results === null) {\r\n // Otherwise try parts of the URL\r\n const matches = window.location.pathname.match(new RegExp(\"/\" + name + \"/([^/]+)\", \"i\"));\r\n\r\n // Check if we found anything, if we do find it, we must reverse the\r\n // results so we get the \"last\" one in case there are multiple hits\r\n if (matches && matches.length > 1)\r\n strResult = matches.reverse()[0];\r\n } else\r\n strResult = results[1];\r\n\r\n return strResult === null || strResult === undefined\r\n ? \"\"\r\n : decodeURIComponent(strResult.replace(/\\+/g, \" \"));\r\n }\r\n\r\n require(name: string) {\r\n const found = this.get(name);\r\n if (found === \"\") {\r\n const message = `Required parameter (${name}) missing from url - cannot continue`;\r\n alert(message);\r\n throw message;\r\n }\r\n return found;\r\n }\r\n }\r\n\n\n\n// WEBPACK FOOTER //\n// ./2sxc-api/js/ToSic.Sxc.Url.ts"],"sourceRoot":""}