/*
 * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
 * This devtool is neither made for production nor for readable output files.
 * It uses "eval()" calls to create a separate source file in the browser devtools.
 * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
 * or disable the default devtool with "devtool: false".
 * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
 */
var pcf_tools_652ac3f36e1e4bca82eb3c1dc44e6fad;
/******/ (() => { // webpackBootstrap
/******/ 	"use strict";
/******/ 	var __webpack_modules__ = ({

/***/ "./DataSourceAutoComplete/index.ts":
/*!*****************************************!*\
  !*** ./DataSourceAutoComplete/index.ts ***!
  \*****************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   DataSourceAutoComplete: () => (/* binding */ DataSourceAutoComplete)\n/* harmony export */ });\n/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ \"./node_modules/tslib/tslib.es6.js\");\n\nclass DataSourceAutoComplete {\n  /**\r\n   * Empty constructor.\r\n   */\n  constructor() {\n    this.records = [];\n    this.datasources = [];\n    this.rlEntities = [];\n  }\n  /**\r\n   * Used to initialize the control instance. Controls can kick off remote server calls and other initialization actions here.\r\n   * Data-set values are not initialized here, use updateView.\r\n   * @param context The entire property bag available to control via Context Object; It contains values as set up by the customizer mapped to property names defined in the manifest, as well as utility functions.\r\n   * @param notifyOutputChanged A callback method to alert the framework that the control has new outputs ready to be retrieved asynchronously.\r\n   * @param state A piece of data that persists in one session for a single user. Can be set at any point in a controls life cycle by calling 'setControlState' in the Mode interface.\r\n   * @param container If a control is marked control-type='standard', it will receive an empty div element within which it can render its content.\r\n   */\n  init(context, notifyOutputChanged, state, container) {\n    var _a;\n    // Add control initialization code\n    this.notifyOutputChanged = notifyOutputChanged;\n    this.container = container;\n    this.baseUrl = context.page.getClientUrl();\n    this.context = context;\n    var inputContainer = document.createElement(\"div\");\n    inputContainer.className = \"autocomplete\";\n    var heightFix = document.createElement(\"div\");\n    heightFix.className = \"height-fix\";\n    this.inputControl = document.createElement(\"input\");\n    this.inputControl.id = 'input_' + ((_a = this.context.parameters.Field.attributes) === null || _a === void 0 ? void 0 : _a.LogicalName);\n    this.inputControl.placeholder = '---';\n    this.inputControl.autocomplete = \"none\";\n    this.inputControl.addEventListener(\"input\", this.onChange.bind(this));\n    this.inputControl.addEventListener(\"keydown\", this.onKeyDown.bind(this));\n    document.addEventListener(\"click\", this.onDocumentClick.bind(this));\n    inputContainer.appendChild(this.inputControl);\n    container.appendChild(inputContainer);\n    container.appendChild(heightFix);\n    // To fix style issue\n    var style = 'div[role=\"alert\"] {margin-top: 26px !important;}';\n    this.addStyle(style);\n  }\n  /**\r\n   * Called when any value in the property bag has changed. This includes field values, data-sets, global values such as container height and width, offline status, control metadata values such as label, visible, etc.\r\n   * @param context The entire property bag available to control via Context Object; It contains values as set up by the customizer mapped to names defined in the manifest, as well as utility functions\r\n   */\n  updateView(context) {\n    // Add code to update control view\n    this.context = context;\n    this.type = this.context.parameters.Type.raw || \"1\";\n    this.value = this.context.parameters.Field.raw || \"\";\n    if (this.inputControl.value == \"\") this.inputControl.value = this.value;\n    this.fieldLogicalName = this.context.parameters.Field.attributes ? this.context.parameters.Field.attributes.LogicalName : '';\n    this.setFormContext();\n    this.setParentEntity();\n    switch (this.type) {\n      case '1':\n        if (this.records.length === 0) this.populateEntities();\n        break;\n      case '2':\n        if (this.entity && this.entity.length > 0 && this.records.length === 0) this.populateAttributes(this.entity);\n        break;\n      case '3':\n        if (this.entity && this.entity.length > 0 && this.records.length === 0) this.populateRelatedEntities(this.entity);\n        break;\n      case '4':\n        if (this.entity && this.entity.length > 0 && this.relatedEntity && this.relatedEntity.length > 0 && this.records.length === 0) this.populateRelatedEntityAttributes(this.entity);\n        break;\n    }\n  }\n  /**\r\n   * It is called by the framework prior to a control receiving new data.\r\n   * @returns an object based on nomenclature defined in manifest, expecting object[s] for property marked as “bound” or “output”\r\n   */\n  getOutputs() {\n    return {\n      Field: this.value\n    };\n  }\n  /**\r\n   * Called when the control is to be removed from the DOM tree. Controls should use this call for cleanup.\r\n   * i.e. cancelling any pending remote calls, removing listeners, etc.\r\n   */\n  destroy() {\n    // Add code to cleanup control if necessary\n    this.inputControl.removeEventListener(\"input\", this.onChange);\n    this.inputControl.removeEventListener(\"keydown\", this.onKeyDown);\n    document.removeEventListener(\"click\", this.onDocumentClick);\n  }\n  /**\r\n   * Called when input change\r\n   * @param evt\r\n   */\n  onChange() {\n    this.records = this.records.filter(function (item, index, inputArray) {\n      return inputArray.indexOf(item) == index;\n    });\n    if (this.records) {\n      this.populateAutoComplete();\n    }\n    this.notifyOutputChanged();\n  }\n  /**\r\n   * Populate suggestion\r\n   */\n  populateAutoComplete() {\n    var that = this;\n    var a,\n      b,\n      i,\n      val = that.inputControl.value;\n    //check if the input value is contained within the list of records (field names or entity names)\n    if (this.records.indexOf(val) != -1)\n      //update the FIELD value on the form\n      that.value = val;else that.value = \"\";\n    /*close any already open lists of autocompleted values*/\n    that.closeAllLists();\n    if (!val) {\n      return;\n    }\n    that.currentFocus = -1;\n    /*create a DIV element that will contain the items (values):*/\n    a = document.createElement(\"DIV\");\n    a.setAttribute(\"id\", that.inputControl.id + \"autocomplete-list\");\n    a.setAttribute(\"class\", \"autocomplete-items\");\n    /*append the DIV element as a child of the autocomplete container:*/\n    that.inputControl.parentNode.appendChild(a);\n    /*for each item in the array...*/\n    for (i = 0; i < that.records.length; i++) {\n      /*check if the item starts with the same letters as the text field value:*/\n      if (that.records[i].substr(0, val.length).toUpperCase() == val.toUpperCase()) {\n        /*create a DIV element for each matching element:*/\n        b = document.createElement(\"DIV\");\n        /*make the matching letters bold:*/\n        b.innerHTML = \"<strong>\" + that.records[i].substr(0, val.length) + \"</strong>\";\n        b.innerHTML += that.records[i].substr(val.length);\n        /*insert a input field that will hold the current array item's value:*/\n        b.innerHTML += \"<input type='hidden' value='\" + that.records[i] + \"'>\";\n        /*execute a function when someone clicks on the item value (DIV element):*/\n        b.addEventListener(\"click\", function () {\n          /*insert the value for the autocomplete text field:*/\n          that.inputControl.value = this.getElementsByTagName(\"input\")[0].value;\n          that.value = that.inputControl.value;\n          that.setFormContext();\n          if (that.fieldLogicalName) that.formContext.getAttribute(that.fieldLogicalName).setValue(that.value);\n          if (that.type == '3') that.onRelatedEntitySelected();\n          /*close the list of autocompleted values,\r\n          (or any other open lists of autocompleted values:*/\n          that.closeAllLists();\n        });\n        a.appendChild(b);\n      }\n    }\n  }\n  /**\r\n   * Called when key down on input\r\n   * @param evt\r\n   */\n  onKeyDown(evt) {\n    var that = this;\n    var x = document.getElementById(evt.id + \"autocomplete-list\");\n    if (x) x = x.getElementsByTagName(\"div\");\n    if (evt.keyCode == 40) {\n      /*If the arrow DOWN key is pressed,\r\n      increase the currentFocus variable:*/\n      that.currentFocus++;\n      /*and and make the current item more visible:*/\n      that.addActive(x);\n    } else if (evt.keyCode == 38) {\n      //up\n      /*If the arrow UP key is pressed,\r\n      decrease the currentFocus variable:*/\n      that.currentFocus--;\n      /*and and make the current item more visible:*/\n      that.addActive(x);\n    } else if (evt.keyCode == 13) {\n      /*If the ENTER key is pressed, prevent the form from being submitted,*/\n      evt.preventDefault();\n      if (that.currentFocus > -1) {\n        /*and simulate a click on the \"active\" item:*/\n        if (x) x[that.currentFocus].click();\n      }\n    }\n  }\n  /**\r\n   * Called when document click\r\n   * @param evt\r\n   */\n  onDocumentClick(evt) {\n    var that = this;\n    that.closeAllLists(evt.target);\n  }\n  /**\r\n   *\r\n   * @param x\r\n   */\n  addActive(x) {\n    /*a function to classify an item as \"active\":*/\n    if (!x) return false;\n    /*start by removing the \"active\" class on all items:*/\n    this.removeActive(x);\n    if (this.currentFocus >= x.length) this.currentFocus = 0;\n    if (this.currentFocus < 0) this.currentFocus = x.length - 1;\n    /*add class \"autocomplete-active\":*/\n    x[this.currentFocus].classList.add(\"autocomplete-active\");\n  }\n  /**\r\n   *\r\n   * @param x\r\n   */\n  removeActive(x) {\n    /*a function to remove the \"active\" class from all autocomplete items:*/\n    for (var i = 0; i < x.length; i++) {\n      x[i].classList.remove(\"autocomplete-active\");\n    }\n  }\n  /**\r\n   *\r\n   * @param elmnt\r\n   */\n  closeAllLists(elmnt) {\n    /*close all autocomplete lists in the document,\r\n    except the one passed as an argument:*/\n    var x = document.getElementsByClassName(\"autocomplete-items\");\n    for (var i = 0; i < x.length; i++) {\n      if (elmnt != x[i] && elmnt != this.inputControl) {\n        x[i].parentNode.removeChild(x[i]);\n      }\n    }\n  }\n  /**\r\n   * Populate entities\r\n   */\n  populateEntities() {\n    return (0,tslib__WEBPACK_IMPORTED_MODULE_0__.__awaiter)(this, void 0, void 0, function* () {\n      this.records = [];\n      var a = yield this.getEntities();\n      var result = JSON.parse(a);\n      var dataSources = yield this.getDatasources();\n      var dsParsedResult = JSON.parse(dataSources);\n      var listOfExistingDataSources = dsParsedResult.value.map(x => x.maptaskr_name.toLowerCase());\n      for (var i = 0; i < result.value.length; i++) {\n        if (result.value[i].LogicalName !== null) {\n          //only add the LogicalName if it doesnt exist in the list of existing data sources.\n          if (listOfExistingDataSources.indexOf(result.value[i].LogicalName.toLowerCase()) == -1) this.records.push(result.value[i].LogicalName);\n        }\n      }\n    });\n  }\n  /**\r\n   *\r\n   */\n  onRelatedEntitySelected() {\n    var value = this.formContext.getAttribute(this.fieldLogicalName).getValue();\n    var relatedEntity = this.rlEntities.find(c => c.LogicalName == value);\n    if (relatedEntity) {\n      this.formContext.getAttribute('maptaskr_referencingattribute').setValue(relatedEntity.ReferencingAttribute);\n      var dataSource = this.datasources.find(d => d.maptaskr_name == relatedEntity.LogicalName);\n      this.setAddressFields(dataSource);\n      this.setAddressFieldsDisabled(true);\n    }\n  }\n  /**\r\n   * Get entities\r\n   */\n  getEntities() {\n    return (0,tslib__WEBPACK_IMPORTED_MODULE_0__.__awaiter)(this, void 0, void 0, function* () {\n      var param = \"EntityDefinitions?$select=SchemaName,EntitySetName,LogicalName\";\n      return this.request(param);\n    });\n  }\n  /**\r\n   * Populate attributes\r\n   */\n  populateAttributes(entity) {\n    return (0,tslib__WEBPACK_IMPORTED_MODULE_0__.__awaiter)(this, void 0, void 0, function* () {\n      this.records = [];\n      var a = yield this.getAttributes(entity);\n      var result = JSON.parse(a);\n      for (var i = 0; i < result.value.length; i++) {\n        if (result.value[i].LogicalName !== null) {\n          this.records.push(result.value[i].LogicalName);\n        }\n      }\n    });\n  }\n  /**\r\n   * Retreive attributes from server\r\n   * @param entity\r\n   */\n  getAttributes(entity) {\n    return (0,tslib__WEBPACK_IMPORTED_MODULE_0__.__awaiter)(this, void 0, void 0, function* () {\n      var param = \"EntityDefinitions(LogicalName='\" + entity + \"')/Attributes?$select=LogicalName,DisplayName,AttributeType&$filter=AttributeOf%20eq%20null\";\n      return this.request(param);\n    });\n  }\n  /**\r\n   * Populate related entities\r\n   */\n  populateRelatedEntities(entity) {\n    return (0,tslib__WEBPACK_IMPORTED_MODULE_0__.__awaiter)(this, void 0, void 0, function* () {\n      this.records = [];\n      // Entity metadata\n      var metaData = yield this.getEntityMetaData(entity);\n      var entityMetaData = JSON.parse(metaData);\n      var metadataId = entityMetaData.value ? entityMetaData.value[0].MetadataId : undefined;\n      if (!metadataId) return;\n      // Releted entities\n      var result = yield this.getRelatedEntities(metadataId);\n      var parsedRlEntitiesResult = JSON.parse(result);\n      for (var i = 0; i < parsedRlEntitiesResult.value.length; i++) {\n        if (parsedRlEntitiesResult.value[i].ReferencedEntity !== null) {\n          this.records.push(parsedRlEntitiesResult.value[i].ReferencedEntity);\n        }\n      }\n      var dsResult = yield this.getDatasources();\n      var dsParsedResult = JSON.parse(dsResult);\n      this.datasources = dsParsedResult.value;\n      if (this.datasources) this.rlEntities = this.generateRelatedEntities(parsedRlEntitiesResult.value);\n    });\n  }\n  /**\r\n   * Populate related entity attributes\r\n   */\n  populateRelatedEntityAttributes(entity) {\n    return (0,tslib__WEBPACK_IMPORTED_MODULE_0__.__awaiter)(this, void 0, void 0, function* () {\n      this.records = [];\n      // Entity metadata\n      var metaData = yield this.getEntityMetaData(entity);\n      var entityMetaData = JSON.parse(metaData);\n      var metadataId = entityMetaData.value ? entityMetaData.value[0].MetadataId : undefined;\n      if (!metadataId) return;\n      // Releted entities\n      var result = yield this.getRelatedEntities(metadataId);\n      var parsedRlEntitiesResult = JSON.parse(result);\n      for (var i = 0; i < parsedRlEntitiesResult.value.length; i++) {\n        if (parsedRlEntitiesResult.value[i].ReferencedEntity !== null && parsedRlEntitiesResult.value[i].ReferencedEntity == this.relatedEntity) {\n          this.records.push(parsedRlEntitiesResult.value[i].ReferencingAttribute);\n        }\n      }\n    });\n  }\n  /**\r\n   * Get related entities from server\r\n   * @param entity parent\r\n   */\n  getRelatedEntities(metadataId) {\n    return (0,tslib__WEBPACK_IMPORTED_MODULE_0__.__awaiter)(this, void 0, void 0, function* () {\n      var param = \"EntityDefinitions(\" + metadataId + \")/ManyToOneRelationships?$select=ReferencedEntity,ReferencingAttribute,MetadataId,SchemaName\";\n      return this.request(param);\n    });\n  }\n  /**\r\n   * Retreive entity metadata from server\r\n   * @param entity\r\n   */\n  getEntityMetaData(entity) {\n    return (0,tslib__WEBPACK_IMPORTED_MODULE_0__.__awaiter)(this, void 0, void 0, function* () {\n      var param = \"EntityDefinitions?$select=SchemaName,LogicalName,MetadataId&$filter=LogicalName eq '\" + entity + \"'\";\n      return this.request(param);\n    });\n  }\n  /**\r\n   * Get related entities from server\r\n   * @param entity parent\r\n   */\n  getDatasources() {\n    return (0,tslib__WEBPACK_IMPORTED_MODULE_0__.__awaiter)(this, void 0, void 0, function* () {\n      var param = \"maptaskr_datasources\";\n      return this.request(param);\n    });\n  }\n  /**\r\n   * Common call back for api\r\n   * @param param\r\n   */\n  request(param) {\n    var req = new XMLHttpRequest();\n    var baseUrl = this.baseUrl;\n    return new Promise(function (resolve, reject) {\n      req.open(\"GET\", baseUrl + \"/api/data/v9.1/\" + param, true);\n      req.onreadystatechange = function () {\n        if (req.readyState !== 4) return;\n        if (req.status >= 200 && req.status < 300) {\n          // If successful\n          var result = JSON.parse(req.responseText);\n          if (parseInt(result.StatusCode) < 0) {\n            reject({\n              status: result.StatusCode,\n              statusText: result.StatusMessage\n            });\n          }\n          resolve(req.responseText);\n        } else {\n          // If failed\n          reject({\n            status: req.status,\n            statusText: req.statusText\n          });\n        }\n      };\n      req.setRequestHeader(\"OData-MaxVersion\", \"4.0\");\n      req.setRequestHeader(\"OData-Version\", \"4.0\");\n      req.setRequestHeader(\"Accept\", \"application/json\");\n      req.setRequestHeader(\"Content-Type\", \"application/json; charset=utf-8\");\n      req.send();\n    });\n  }\n  /**\r\n   * Set global form context\r\n   */\n  setFormContext() {\n    this.formContext = window.parent.pageContextForPCF ? window.parent.pageContextForPCF : undefined;\n  }\n  /**\r\n   * Set parent entity\r\n   */\n  setParentEntity() {\n    this.entity = this.formContext ? this.formContext.getAttribute('maptaskr_name').getValue() : '';\n    this.relatedEntity = this.formContext ? this.formContext.getAttribute('maptaskr_relatedentity').getValue() : '';\n  }\n  /**\r\n   * Set fields on selecting related entity who has address\r\n   * @param dataSource\r\n   */\n  setAddressFields(dataSource) {\n    this.setFieldValue('maptaskr_addresscomposite', dataSource.maptaskr_addresscomposite);\n    this.setFieldValue('maptaskr_street1', dataSource.maptaskr_street1);\n    this.setFieldValue('maptaskr_street2', dataSource.maptaskr_street2);\n    this.setFieldValue('maptaskr_street3', dataSource.maptaskr_street3);\n    this.setFieldValue('maptaskr_city', dataSource.maptaskr_city);\n    this.setFieldValue('maptaskr_state', dataSource.maptaskr_state);\n    this.setFieldValue('maptaskr_postcode', dataSource.maptaskr_postcode);\n    this.setFieldValue('maptaskr_country', dataSource.maptaskr_country);\n    this.setFieldValue('maptaskr_email', dataSource.maptaskr_email);\n    this.setFieldValue('maptaskr_phonenumber', dataSource.maptaskr_phonenumber);\n    this.setFieldValue('maptaskr_longitude', dataSource.maptaskr_longitude);\n    this.setFieldValue('maptaskr_latitude', dataSource.maptaskr_latitude);\n  }\n  /**\r\n   * Common method to set field value\r\n   * @param fieldName\r\n   * @param fieldValue\r\n   */\n  setFieldValue(fieldName, fieldValue) {\n    var control = this.formContext.getAttribute(fieldName);\n    if (control) control.setValue(fieldValue);\n  }\n  /**\r\n   * Common method to disable fields\r\n   * @param isDisabled\r\n   */\n  setAddressFieldsDisabled(isDisabled) {\n    this.disableField('maptaskr_addresscomposite', isDisabled);\n    this.disableField('maptaskr_street1', isDisabled);\n    this.disableField('maptaskr_street2', isDisabled);\n    this.disableField('maptaskr_street3', isDisabled);\n    this.disableField('maptaskr_city', isDisabled);\n    this.disableField('maptaskr_state', isDisabled);\n    this.disableField('maptaskr_postcode', isDisabled);\n    this.disableField('maptaskr_country', isDisabled);\n    this.disableField('maptaskr_email', isDisabled);\n    this.disableField('maptaskr_phonenumber', isDisabled);\n    this.disableField('maptaskr_longitude', isDisabled);\n    this.disableField('maptaskr_latitude', isDisabled);\n  }\n  /**\r\n   * Common method to make field readonly\r\n   * @param fieldName\r\n   * @param isDisabled\r\n   */\n  disableField(fieldName, isDisabled) {\n    var control = this.formContext.getControl(fieldName);\n    if (control) control.setDisabled(isDisabled);\n  }\n  /**\r\n   * Generate related entities based on parent entity\r\n   * @param relationalEntities\r\n   */\n  generateRelatedEntities(relationalEntities) {\n    var rEntities = [];\n    for (var i = 0; i < this.datasources.length; i++) {\n      var item = relationalEntities.find(r => r.ReferencedEntity == this.datasources[i].maptaskr_name);\n      if (item) {\n        var isExist = rEntities.find(r => r.LogicalName == item.ReferencedEntity);\n        if (!isExist) {\n          rEntities.push({\n            MetadataId: item.MetadataId,\n            LogicalName: item.ReferencedEntity,\n            ReferencingAttribute: item.ReferencingAttribute\n          });\n        }\n      }\n    }\n    return rEntities;\n  }\n  /* Function to add style element */\n  addStyle(styles) {\n    /* Create style document */\n    var css = document.createElement('style');\n    css.type = 'text/css';\n    if (css.styleSheet) css.styleSheet.cssText = styles;else css.appendChild(document.createTextNode(styles));\n    /* Append style to the tag name */\n    document.getElementsByTagName(\"head\")[0].appendChild(css);\n  }\n}\n\n//# sourceURL=webpack://pcf_tools_652ac3f36e1e4bca82eb3c1dc44e6fad/./DataSourceAutoComplete/index.ts?");

/***/ }),

/***/ "./node_modules/tslib/tslib.es6.js":
/*!*****************************************!*\
  !*** ./node_modules/tslib/tslib.es6.js ***!
  \*****************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */   __assign: () => (/* binding */ _assign),\n/* harmony export */   __asyncDelegator: () => (/* binding */ __asyncDelegator),\n/* harmony export */   __asyncGenerator: () => (/* binding */ __asyncGenerator),\n/* harmony export */   __asyncValues: () => (/* binding */ __asyncValues),\n/* harmony export */   __await: () => (/* binding */ __await),\n/* harmony export */   __awaiter: () => (/* binding */ __awaiter),\n/* harmony export */   __classPrivateFieldGet: () => (/* binding */ __classPrivateFieldGet),\n/* harmony export */   __classPrivateFieldIn: () => (/* binding */ __classPrivateFieldIn),\n/* harmony export */   __classPrivateFieldSet: () => (/* binding */ __classPrivateFieldSet),\n/* harmony export */   __createBinding: () => (/* binding */ __createBinding),\n/* harmony export */   __decorate: () => (/* binding */ __decorate),\n/* harmony export */   __esDecorate: () => (/* binding */ __esDecorate),\n/* harmony export */   __exportStar: () => (/* binding */ __exportStar),\n/* harmony export */   __extends: () => (/* binding */ __extends),\n/* harmony export */   __generator: () => (/* binding */ __generator),\n/* harmony export */   __importDefault: () => (/* binding */ __importDefault),\n/* harmony export */   __importStar: () => (/* binding */ __importStar),\n/* harmony export */   __makeTemplateObject: () => (/* binding */ __makeTemplateObject),\n/* harmony export */   __metadata: () => (/* binding */ __metadata),\n/* harmony export */   __param: () => (/* binding */ __param),\n/* harmony export */   __propKey: () => (/* binding */ __propKey),\n/* harmony export */   __read: () => (/* binding */ __read),\n/* harmony export */   __rest: () => (/* binding */ __rest),\n/* harmony export */   __runInitializers: () => (/* binding */ __runInitializers),\n/* harmony export */   __setFunctionName: () => (/* binding */ __setFunctionName),\n/* harmony export */   __spread: () => (/* binding */ __spread),\n/* harmony export */   __spreadArray: () => (/* binding */ __spreadArray),\n/* harmony export */   __spreadArrays: () => (/* binding */ __spreadArrays),\n/* harmony export */   __values: () => (/* binding */ __values),\n/* harmony export */   \"default\": () => (__WEBPACK_DEFAULT_EXPORT__)\n/* harmony export */ });\n/******************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\n/* global Reflect, Promise */\n\nvar _extendStatics = function extendStatics(d, b) {\n  _extendStatics = Object.setPrototypeOf || {\n    __proto__: []\n  } instanceof Array && function (d, b) {\n    d.__proto__ = b;\n  } || function (d, b) {\n    for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p];\n  };\n  return _extendStatics(d, b);\n};\nfunction __extends(d, b) {\n  if (typeof b !== \"function\" && b !== null) throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\n  _extendStatics(d, b);\n  function __() {\n    this.constructor = d;\n  }\n  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n}\nvar _assign = function __assign() {\n  _assign = Object.assign || function __assign(t) {\n    for (var s, i = 1, n = arguments.length; i < n; i++) {\n      s = arguments[i];\n      for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\n    }\n    return t;\n  };\n  return _assign.apply(this, arguments);\n};\n\nfunction __rest(s, e) {\n  var t = {};\n  for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n  if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n    if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n  }\n  return t;\n}\nfunction __decorate(decorators, target, key, desc) {\n  var c = arguments.length,\n    r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc,\n    d;\n  if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n  return c > 3 && r && Object.defineProperty(target, key, r), r;\n}\nfunction __param(paramIndex, decorator) {\n  return function (target, key) {\n    decorator(target, key, paramIndex);\n  };\n}\nfunction __esDecorate(ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {\n  function accept(f) {\n    if (f !== void 0 && typeof f !== \"function\") throw new TypeError(\"Function expected\");\n    return f;\n  }\n  var kind = contextIn.kind,\n    key = kind === \"getter\" ? \"get\" : kind === \"setter\" ? \"set\" : \"value\";\n  var target = !descriptorIn && ctor ? contextIn[\"static\"] ? ctor : ctor.prototype : null;\n  var descriptor = descriptorIn || (target ? Object.getOwnPropertyDescriptor(target, contextIn.name) : {});\n  var _,\n    done = false;\n  for (var i = decorators.length - 1; i >= 0; i--) {\n    var context = {};\n    for (var p in contextIn) context[p] = p === \"access\" ? {} : contextIn[p];\n    for (var p in contextIn.access) context.access[p] = contextIn.access[p];\n    context.addInitializer = function (f) {\n      if (done) throw new TypeError(\"Cannot add initializers after decoration has completed\");\n      extraInitializers.push(accept(f || null));\n    };\n    var result = (0, decorators[i])(kind === \"accessor\" ? {\n      get: descriptor.get,\n      set: descriptor.set\n    } : descriptor[key], context);\n    if (kind === \"accessor\") {\n      if (result === void 0) continue;\n      if (result === null || typeof result !== \"object\") throw new TypeError(\"Object expected\");\n      if (_ = accept(result.get)) descriptor.get = _;\n      if (_ = accept(result.set)) descriptor.set = _;\n      if (_ = accept(result.init)) initializers.unshift(_);\n    } else if (_ = accept(result)) {\n      if (kind === \"field\") initializers.unshift(_);else descriptor[key] = _;\n    }\n  }\n  if (target) Object.defineProperty(target, contextIn.name, descriptor);\n  done = true;\n}\n;\nfunction __runInitializers(thisArg, initializers, value) {\n  var useValue = arguments.length > 2;\n  for (var i = 0; i < initializers.length; i++) {\n    value = useValue ? initializers[i].call(thisArg, value) : initializers[i].call(thisArg);\n  }\n  return useValue ? value : void 0;\n}\n;\nfunction __propKey(x) {\n  return typeof x === \"symbol\" ? x : \"\".concat(x);\n}\n;\nfunction __setFunctionName(f, name, prefix) {\n  if (typeof name === \"symbol\") name = name.description ? \"[\".concat(name.description, \"]\") : \"\";\n  return Object.defineProperty(f, \"name\", {\n    configurable: true,\n    value: prefix ? \"\".concat(prefix, \" \", name) : name\n  });\n}\n;\nfunction __metadata(metadataKey, metadataValue) {\n  if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\n}\nfunction __awaiter(thisArg, _arguments, P, generator) {\n  function adopt(value) {\n    return value instanceof P ? value : new P(function (resolve) {\n      resolve(value);\n    });\n  }\n  return new (P || (P = Promise))(function (resolve, reject) {\n    function fulfilled(value) {\n      try {\n        step(generator.next(value));\n      } catch (e) {\n        reject(e);\n      }\n    }\n    function rejected(value) {\n      try {\n        step(generator[\"throw\"](value));\n      } catch (e) {\n        reject(e);\n      }\n    }\n    function step(result) {\n      result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);\n    }\n    step((generator = generator.apply(thisArg, _arguments || [])).next());\n  });\n}\nfunction __generator(thisArg, body) {\n  var _ = {\n      label: 0,\n      sent: function sent() {\n        if (t[0] & 1) throw t[1];\n        return t[1];\n      },\n      trys: [],\n      ops: []\n    },\n    f,\n    y,\n    t,\n    g;\n  return g = {\n    next: verb(0),\n    \"throw\": verb(1),\n    \"return\": verb(2)\n  }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function () {\n    return this;\n  }), g;\n  function verb(n) {\n    return function (v) {\n      return step([n, v]);\n    };\n  }\n  function step(op) {\n    if (f) throw new TypeError(\"Generator is already executing.\");\n    while (g && (g = 0, op[0] && (_ = 0)), _) try {\n      if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n      if (y = 0, t) op = [op[0] & 2, t.value];\n      switch (op[0]) {\n        case 0:\n        case 1:\n          t = op;\n          break;\n        case 4:\n          _.label++;\n          return {\n            value: op[1],\n            done: false\n          };\n        case 5:\n          _.label++;\n          y = op[1];\n          op = [0];\n          continue;\n        case 7:\n          op = _.ops.pop();\n          _.trys.pop();\n          continue;\n        default:\n          if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) {\n            _ = 0;\n            continue;\n          }\n          if (op[0] === 3 && (!t || op[1] > t[0] && op[1] < t[3])) {\n            _.label = op[1];\n            break;\n          }\n          if (op[0] === 6 && _.label < t[1]) {\n            _.label = t[1];\n            t = op;\n            break;\n          }\n          if (t && _.label < t[2]) {\n            _.label = t[2];\n            _.ops.push(op);\n            break;\n          }\n          if (t[2]) _.ops.pop();\n          _.trys.pop();\n          continue;\n      }\n      op = body.call(thisArg, _);\n    } catch (e) {\n      op = [6, e];\n      y = 0;\n    } finally {\n      f = t = 0;\n    }\n    if (op[0] & 5) throw op[1];\n    return {\n      value: op[0] ? op[1] : void 0,\n      done: true\n    };\n  }\n}\nvar __createBinding = Object.create ? function (o, m, k, k2) {\n  if (k2 === undefined) k2 = k;\n  var desc = Object.getOwnPropertyDescriptor(m, k);\n  if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\n    desc = {\n      enumerable: true,\n      get: function get() {\n        return m[k];\n      }\n    };\n  }\n  Object.defineProperty(o, k2, desc);\n} : function (o, m, k, k2) {\n  if (k2 === undefined) k2 = k;\n  o[k2] = m[k];\n};\nfunction __exportStar(m, o) {\n  for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);\n}\nfunction __values(o) {\n  var s = typeof Symbol === \"function\" && Symbol.iterator,\n    m = s && o[s],\n    i = 0;\n  if (m) return m.call(o);\n  if (o && typeof o.length === \"number\") return {\n    next: function next() {\n      if (o && i >= o.length) o = void 0;\n      return {\n        value: o && o[i++],\n        done: !o\n      };\n    }\n  };\n  throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\n}\nfunction __read(o, n) {\n  var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n  if (!m) return o;\n  var i = m.call(o),\n    r,\n    ar = [],\n    e;\n  try {\n    while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n  } catch (error) {\n    e = {\n      error: error\n    };\n  } finally {\n    try {\n      if (r && !r.done && (m = i[\"return\"])) m.call(i);\n    } finally {\n      if (e) throw e.error;\n    }\n  }\n  return ar;\n}\n\n/** @deprecated */\nfunction __spread() {\n  for (var ar = [], i = 0; i < arguments.length; i++) ar = ar.concat(__read(arguments[i]));\n  return ar;\n}\n\n/** @deprecated */\nfunction __spreadArrays() {\n  for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\n  for (var r = Array(s), k = 0, i = 0; i < il; i++) for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++) r[k] = a[j];\n  return r;\n}\nfunction __spreadArray(to, from, pack) {\n  if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n    if (ar || !(i in from)) {\n      if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n      ar[i] = from[i];\n    }\n  }\n  return to.concat(ar || Array.prototype.slice.call(from));\n}\nfunction __await(v) {\n  return this instanceof __await ? (this.v = v, this) : new __await(v);\n}\nfunction __asyncGenerator(thisArg, _arguments, generator) {\n  if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\n  var g = generator.apply(thisArg, _arguments || []),\n    i,\n    q = [];\n  return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () {\n    return this;\n  }, i;\n  function verb(n) {\n    if (g[n]) i[n] = function (v) {\n      return new Promise(function (a, b) {\n        q.push([n, v, a, b]) > 1 || resume(n, v);\n      });\n    };\n  }\n  function resume(n, v) {\n    try {\n      step(g[n](v));\n    } catch (e) {\n      settle(q[0][3], e);\n    }\n  }\n  function step(r) {\n    r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r);\n  }\n  function fulfill(value) {\n    resume(\"next\", value);\n  }\n  function reject(value) {\n    resume(\"throw\", value);\n  }\n  function settle(f, v) {\n    if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]);\n  }\n}\nfunction __asyncDelegator(o) {\n  var i, p;\n  return i = {}, verb(\"next\"), verb(\"throw\", function (e) {\n    throw e;\n  }), verb(\"return\"), i[Symbol.iterator] = function () {\n    return this;\n  }, i;\n  function verb(n, f) {\n    i[n] = o[n] ? function (v) {\n      return (p = !p) ? {\n        value: __await(o[n](v)),\n        done: false\n      } : f ? f(v) : v;\n    } : f;\n  }\n}\nfunction __asyncValues(o) {\n  if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\n  var m = o[Symbol.asyncIterator],\n    i;\n  return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () {\n    return this;\n  }, i);\n  function verb(n) {\n    i[n] = o[n] && function (v) {\n      return new Promise(function (resolve, reject) {\n        v = o[n](v), settle(resolve, reject, v.done, v.value);\n      });\n    };\n  }\n  function settle(resolve, reject, d, v) {\n    Promise.resolve(v).then(function (v) {\n      resolve({\n        value: v,\n        done: d\n      });\n    }, reject);\n  }\n}\nfunction __makeTemplateObject(cooked, raw) {\n  if (Object.defineProperty) {\n    Object.defineProperty(cooked, \"raw\", {\n      value: raw\n    });\n  } else {\n    cooked.raw = raw;\n  }\n  return cooked;\n}\n;\nvar __setModuleDefault = Object.create ? function (o, v) {\n  Object.defineProperty(o, \"default\", {\n    enumerable: true,\n    value: v\n  });\n} : function (o, v) {\n  o[\"default\"] = v;\n};\nfunction __importStar(mod) {\n  if (mod && mod.__esModule) return mod;\n  var result = {};\n  if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\n  __setModuleDefault(result, mod);\n  return result;\n}\nfunction __importDefault(mod) {\n  return mod && mod.__esModule ? mod : {\n    default: mod\n  };\n}\nfunction __classPrivateFieldGet(receiver, state, kind, f) {\n  if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a getter\");\n  if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot read private member from an object whose class did not declare it\");\n  return kind === \"m\" ? f : kind === \"a\" ? f.call(receiver) : f ? f.value : state.get(receiver);\n}\nfunction __classPrivateFieldSet(receiver, state, value, kind, f) {\n  if (kind === \"m\") throw new TypeError(\"Private method is not writable\");\n  if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a setter\");\n  if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot write private member to an object whose class did not declare it\");\n  return kind === \"a\" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value), value;\n}\nfunction __classPrivateFieldIn(state, receiver) {\n  if (receiver === null || typeof receiver !== \"object\" && typeof receiver !== \"function\") throw new TypeError(\"Cannot use 'in' operator on non-object\");\n  return typeof state === \"function\" ? receiver === state : state.has(receiver);\n}\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({\n  __extends,\n  __assign: _assign,\n  __rest,\n  __decorate,\n  __param,\n  __metadata,\n  __awaiter,\n  __generator,\n  __createBinding,\n  __exportStar,\n  __values,\n  __read,\n  __spread,\n  __spreadArrays,\n  __spreadArray,\n  __await,\n  __asyncGenerator,\n  __asyncDelegator,\n  __asyncValues,\n  __makeTemplateObject,\n  __importStar,\n  __importDefault,\n  __classPrivateFieldGet,\n  __classPrivateFieldSet,\n  __classPrivateFieldIn\n});\n\n//# sourceURL=webpack://pcf_tools_652ac3f36e1e4bca82eb3c1dc44e6fad/./node_modules/tslib/tslib.es6.js?");

/***/ })

/******/ 	});
/************************************************************************/
/******/ 	// The module cache
/******/ 	var __webpack_module_cache__ = {};
/******/ 	
/******/ 	// The require function
/******/ 	function __webpack_require__(moduleId) {
/******/ 		// Check if module is in cache
/******/ 		var cachedModule = __webpack_module_cache__[moduleId];
/******/ 		if (cachedModule !== undefined) {
/******/ 			return cachedModule.exports;
/******/ 		}
/******/ 		// Create a new module (and put it into the cache)
/******/ 		var module = __webpack_module_cache__[moduleId] = {
/******/ 			// no module.id needed
/******/ 			// no module.loaded needed
/******/ 			exports: {}
/******/ 		};
/******/ 	
/******/ 		// Execute the module function
/******/ 		__webpack_modules__[moduleId](module, module.exports, __webpack_require__);
/******/ 	
/******/ 		// Return the exports of the module
/******/ 		return module.exports;
/******/ 	}
/******/ 	
/************************************************************************/
/******/ 	/* webpack/runtime/define property getters */
/******/ 	(() => {
/******/ 		// define getter functions for harmony exports
/******/ 		__webpack_require__.d = (exports, definition) => {
/******/ 			for(var key in definition) {
/******/ 				if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
/******/ 					Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
/******/ 				}
/******/ 			}
/******/ 		};
/******/ 	})();
/******/ 	
/******/ 	/* webpack/runtime/hasOwnProperty shorthand */
/******/ 	(() => {
/******/ 		__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
/******/ 	})();
/******/ 	
/******/ 	/* webpack/runtime/make namespace object */
/******/ 	(() => {
/******/ 		// define __esModule on exports
/******/ 		__webpack_require__.r = (exports) => {
/******/ 			if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
/******/ 				Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
/******/ 			}
/******/ 			Object.defineProperty(exports, '__esModule', { value: true });
/******/ 		};
/******/ 	})();
/******/ 	
/************************************************************************/
/******/ 	
/******/ 	// startup
/******/ 	// Load entry module and return exports
/******/ 	// This entry module can't be inlined because the eval devtool is used.
/******/ 	var __webpack_exports__ = __webpack_require__("./DataSourceAutoComplete/index.ts");
/******/ 	pcf_tools_652ac3f36e1e4bca82eb3c1dc44e6fad = __webpack_exports__;
/******/ 	
/******/ })()
;
if (window.ComponentFramework && window.ComponentFramework.registerControl) {
	ComponentFramework.registerControl('MaptaskrDS.DataSourceAutoComplete', pcf_tools_652ac3f36e1e4bca82eb3c1dc44e6fad.DataSourceAutoComplete);
} else {
	var MaptaskrDS = MaptaskrDS || {};
	MaptaskrDS.DataSourceAutoComplete = pcf_tools_652ac3f36e1e4bca82eb3c1dc44e6fad.DataSourceAutoComplete;
	pcf_tools_652ac3f36e1e4bca82eb3c1dc44e6fad = undefined;
}